Communitygithub.com

COTA-App/LandingPage

Apple 人機介面設計指引中關於佈局與導覽元件的說明。當使用者詢問「側邊欄」、「分割畫面」、「分頁列」、「分頁檢視」、「捲動檢視」、「視窗設計」、「面板」、「列表檢視」、「表格檢視」、「直欄檢視」、「大綱檢視」、「導覽結構」、「應用程式佈局」、「方塊」、「裝飾物」或如何在 Apple 應用程式中以階層方式組織內容時,請使用此技能。

LandingPage 是什麼?

此技能 (COTA-App/LandingPage) 概括了 Apple 人機介面設計指引 (HIG) 中關於佈局與導覽元件的核心原則,並提供一份完整的參考索引與導覽模式選擇指南。它幫助開發者根據應用程式的資訊架構與目標平台,選擇最合適的導覽模式(如分頁列、側邊欄、分割畫面或直欄檢視),並確保介面能無縫適應不同螢幕尺寸(從 iPhone 到 iPad 再到 Mac 與 visionOS),同時支援 iPad 多工處理與動態字型等無障礙功能。該技能主要用於 Apple 平台(iOS/iPadOS/macOS/visionOS)的 UI/UX 設計與開發。其運作方式是透過結構化的檢查清單、參考文件連結以及明確的輸出格式,引導使用者逐步釐清應用程式需求,並推導出最佳的佈局方案。

相容平台✓Claude Code~Codex CLI~Cursor
npx skills add https://github.com/COTA-App/LandingPage/tree/HEAD/.claude/skills/hig-components-layout

在你喜歡的 AI 中提問

開啟一個已預先載入此 Agent Skill 的新對話。

說明文件

Apple HIG:佈局與導覽元件

檢查 .claude/apple-design-context.md 後再提問。使用現有上下文,僅詢問尚未涵蓋的資訊。

關鍵原則

  1. 階層式組織。 將資訊從廣泛類別結構化到具體細節。側邊欄用於頂層區段,列表用於可瀏覽項目,詳細檢視用於個別內容。

  2. 使用標準導覽模式。 分頁列用於同層級區段間的平面導覽(iPhone)。側邊欄用於深層階層式導覽(iPad、Mac)。將模式與資訊架構和平台相匹配。

  3. 適應螢幕尺寸。 iPad 上的三直欄佈局在 iPhone 上折疊為單一直欄。使用尺寸類別和自適應 API (NavigationSplitView) 實現自動適應。

  4. 在 iPad 上支援多工處理。 優雅地回應「分割顯示」、「滑動置前」和「舞台管理器」。在每個分割比例和尺寸類別轉換時進行測試。

  5. 在 visionOS 上保持空間一致性。 共享空間中的視窗、立體物件和裝飾物。可預測地定位。使用裝飾物放置工具列和控制項,而不遮擋內容。

  6. 對溢出內容使用捲動檢視。 對離散內容單元啟用翻頁。在適當位置支援「下拉重新整理」。尊重安全區域。

  7. 保持導覽可預測。 使用者應始終知道他們在哪裡、如何到達以及如何返回。使用返回按鈕、麵包屑導覽和清晰的區段標題。

  8. 優先使用系統元件。 UINavigationController、UISplitViewController、NavigationSplitView 和 TabView 提供了內建的適應性、無障礙功能和狀態還原功能。

參考索引

參考文件主題關鍵內容
sidebars.md側邊欄來源列表、選取狀態、可折疊區段、iPad/Mac 模式
column-views.md直欄檢視Finder 風格的瀏覽、透過直欄逐步揭露資訊
outline-views.md大綱檢視可展開的階層、揭露三角形、樹狀結構
split-views.md分割檢視雙/三直欄佈局、NavigationSplitView、自適應折疊
tab-views.md分頁檢視分段分頁、頁面樣式分頁、macOS 分頁分組
tab-bars.md分頁列底部分頁列 (iOS)、徽章計數、最大分頁數
scroll-views.md捲動檢視翻頁、捲動指示器、內容內縮、下拉重新整理
windows.md視窗macOS/visionOS 視窗管理、大小調整、全螢幕、還原
panels.md面板檢查器面板、工具面板、浮動面板、macOS 慣例
lists-and-tables.md列表與表格純文字/分組/內嵌分組樣式、滑動操作、區段標頭
boxes.md方塊內容分組容器、標籤方塊、macOS 分組
ornaments.md裝飾物visionOS 工具列附件、定位、可見性

導覽模式選擇

應用程式結構推薦模式平台適應
3-5 個同層級頂層區段分頁列iPhone:底部分頁列。iPad:側邊欄 (.sidebarAdaptable,iPadOS 18+)。Mac:側邊欄或工具列分頁
深層階層式內容側邊欄 + NavigationSplitViewiPhone:單一直欄堆疊。iPad:二/三直欄。Mac:完整多直欄
深層檔案/資料夾樹直欄檢視Mac:Finder 風格。iPad:可適應。iPhone:推入導覽
平面列表與詳細內容分割檢視 (雙直欄)iPhone:推入/彈出堆疊。iPad/Mac:主要 + 詳細直欄
含檢查器的文件式應用程式視窗 + 面板Mac:帶檢查器的主視窗。iPad:表單或彈出視窗
含工具的空間應用程式視窗 + 裝飾物visionOS:視窗上的裝飾物。其他平台:工具列

佈局適應檢查清單

  • 緊湊寬度 (iPhone 直向): 導覽是否折疊為單一堆疊?分頁列是否可見?
  • 一般寬度 (iPad 橫向、Mac): 導覽是否展開為側邊欄 + 詳細內容?空間是否充分利用?
  • 多工處理 (iPad): 是否適應每個分割比例?是否能在「滑動置前」中運作?
  • 無障礙功能: 是否支援所有尺寸的動態字型?VoiceOver 順序是否合乎邏輯?
  • 方向: 內容是否能在直向和橫向之間重新排列?
  • visionOS: 視窗是否以人體工學方式定位?裝飾物是否易於觸及?深度是否具有意義?

輸出格式

  1. 推薦的導覽模式,附帶針對應用程式資訊架構的理由。
  2. 佈局階層,從根容器向下排列 (例如:TabView > NavigationSplitView > List > Detail)。
  3. 平台適應,跨目標平台和尺寸類別。
  4. 尺寸類別行為,在每個轉換點。

建議提問

  1. 應用程式的資訊架構是什麼?(區段、階層深度、頂層類別?)
  2. 有多少個頂層區段?
  3. 目標平台有哪些?
  4. 是否需要在 iPad 上支援多工處理?
  5. 使用 SwiftUI 還是 UIKit?

相關技能

  • hig-foundations -- 佈局間距、邊距、安全區域、對齊
  • hig-platforms -- 平台特定的導覽慣例
  • hig-patterns -- 多工處理、全螢幕和啟動模式
  • hig-components-content -- 佈局容器內顯示的內容

由 Raintree Technology 建構 · 更多開發者工具

Individual skills in this repo

This repo contains 4 individual skills — each has its own dedicated page.

COTA-App/LandingPage

>- Apple Human Interface Guidelines for content display components. Use this skill when the user asks about "charts component", "collection view", "image view", "web view", "color well", "image well", "activity view", "lockup", "data visualization", "content display", displaying images, rendering web content, color pickers, or presenting collections of items in Apple apps. Also use when the user says "how should I display charts", "what's the best way to show images", "should I use a web view", "how do I build a grid of items", "what component shows media", or "how do I present a share sheet". Cross-references: hig-foundations for color/typography/accessibility, hig-patterns for data visualization patterns, hig-components-layout for structural containers, hig-platforms for platform-specific component behavior.

COTA-App/LandingPage

>- Apple HIG guidance for selection and input controls including pickers, toggles, sliders, steppers, segmented controls, combo boxes, text fields, text views, labels, token fields, virtual keyboards, rating indicators, and gauges. Use this skill when the user says "picker or segmented control," "how should my form look," "what keyboard type should I use," "toggle vs checkbox," or asks about picker design, toggle, switch, slider, stepper, text field, text input, segmented control, combo box, label, token field, virtual keyboard, rating indicator, gauge, form design, input validation, or control state management. Cross-references: hig-components-menus, hig-components-dialogs, hig-components-search.

COTA-App/LandingPage

>- Apple Human Interface Guidelines design foundations. Use this skill when the user asks about "HIG color", "Apple typography", "SF Symbols", "dark mode guidelines", "accessible design", "Apple design foundations", "app icon", "layout guidelines", "materials", "motion", "privacy", "right to left", "RTL", "inclusive design", branding, images, spatial layout, or writing style. Also use when the user says "my colors look wrong in dark mode", "what font should I use", "is my app accessible enough", "how do I support Dynamic Type", "what contrast ratio do I need", "how do I pick system colors", or "my icons don't match the system style". Cross-references: hig-platforms for platform-specific guidance, hig-patterns for interaction patterns, hig-components-layout for structural components, hig-components-content for display.

COTA-App/LandingPage

>- Apple Human Interface Guidelines interaction and UX patterns. Use this skill when the user asks about "onboarding flow", "user onboarding", "app launch", "loading state", "drag and drop", "search pattern", "settings design", "notifications", "modality", "multitasking", "feedback pattern", "haptics", "undo redo", "file management", data entry, sharing, collaboration, full screen, audio, video, haptic feedback, ratings, printing, help, or account management in Apple apps. Also use when the user says "how should onboarding work", "my app takes too long to load", "should I use a modal here", "how do I handle errors", "when should I ask for permissions", "how to show progress", or "what's the right way to confirm a delete". Cross-references: hig-foundations for underlying principles, hig-platforms for platform specifics, hig-components-layout for navigation, hig-components-content for data display.

相關技能