Communitygithub.com

SwiftUI Liquid Glass (iOS 26+)

iOS 26+ Liquid Glass APIを使用して、SwiftUIの機能を実装、レビュー、または改善します。新しいSwiftUI UIにLiquid Glassを採用する場合、既存の機能をLiquid Glassにリファクタリングする場合、またはLiquid Glassの使用が正しいか、パフォーマンスとデザインの一貫性を確認する場合に使用します。

SwiftUI Liquid Glass (iOS 26+) とは?

このスキルは、iOS 26以降で利用可能なApple純正のLiquid Glass APIに完全準拠したSwiftUI機能を構築、レビュー、または改善するための包括的なガイドラインを提供します。 主な機能として、`glassEffect`モディファイア、`GlassEffectContainer`、ガラスボタンスタイルなどのネイティブAPIを優先的に使用し、Appleのデザインガイダンスに従います。ワークフローは「既存機能のレビュー」「機能の改善」「新機能の実装」の3つのパスに分かれており、それぞれに適した手順が定義されています。 コードスニペットでは、`glassEffect(.regular.interactive(), in: .rect(cornerRadius: 16))` の適用方法や、`GlassEffectContainer`による複数のガラス要素のグループ化、`buttonStyle(.glassProminent)` によるガラスボタンの実装例が示されています。また、iOS 26未満のフォールバックとして `#available(iOS 26, *)` による分岐と `background(.ultraThinMaterial)` を使用した代替UIの提供方法も含まれています。 このスキルはClaude Code、Cursor、CodexなどのAIエージェントで利用可能で、開発者がLiquid Glassを正しく効率的に導入するための実践的なガイドとして機能します。

対応~Claude Code~Codex CLI~Cursor
npx skills add https://github.com/ComeOnOliver/skillshub/tree/HEAD/skills/aiskillstore/marketplace/dimillian/swiftui-liquid-glass

お気に入りのAIに質問する

このエージェントスキルを事前に読み込んだ状態で新しいチャットを開きます。

ドキュメント

SwiftUI Liquid Glass

概要

このスキルは、iOS 26以降のLiquid Glass APIに完全準拠したSwiftUI機能を構築またはレビューするために使用します。ネイティブAPI(glassEffect、GlassEffectContainer、ガラスボタンスタイル)とAppleのデザインガイダンスを優先してください。使用法は一貫性を保ち、必要に応じてインタラクティブにし、パフォーマンスに注意してください。

ワークフロー決定木

リクエストに応じて適切なパスを選択してください。

1) 既存の機能をレビューする

  • Liquid Glassを使用すべき箇所と使用すべきでない箇所を調査します。
  • 正しいモディファイアの順序、シェイプの使用法、コンテナの配置を確認します。
  • iOS 26以降の可用性処理と適切なフォールバックを確認します。

2) Liquid Glassを用いて機能を改善する

  • ガラス処理の対象コンポーネント(サーフェス、チップ、ボタン、カード)を特定します。
  • 複数のガラス要素が存在する場合は GlassEffectContainer を使用するようリファクタリングします。
  • タップ可能またはフォーカス可能な要素にのみインタラクティブガラスを導入します。

3) Liquid Glassを用いて新機能を実装する

  • 最初にガラスサーフェスとインタラクションを設計します(シェイプ、プロミネンス、グループ化)。
  • レイアウト/外観モディファイアの後にガラスモディファイアを追加します。
  • ビュー階層がアニメーションとともに変化する場合にのみ、モーフィングトランジションを追加します。

コアガイドライン

  • カスタムブラーよりもネイティブのLiquid Glass APIを優先してください。
  • 複数のガラス要素が共存する場合は GlassEffectContainer を使用してください。
  • .glassEffect(...) はレイアウトおよび視覚モディファイアの後に適用してください。
  • タッチ/ポインターに応答する要素には .interactive() を使用してください。
  • 関連する要素間でシェイプを統一し、調和のとれた外観にしてください。
  • #available(iOS 26, *) でガードし、非ガラスのフォールバックを提供してください。

レビューチェックリスト

  • 可用性: #available(iOS 26, *) が存在し、フォールバックUIが提供されていること。
  • 構成: 複数のガラスビューが GlassEffectContainer でラップされていること。
  • モディファイア順序: glassEffect がレイアウト/外観モディファイアの後に適用されていること。
  • インタラクティビティ: interactive() はユーザーインタラクションが存在する場合のみ使用されていること。
  • トランジション: glassEffectID が @Namespace と共にモーフィングに使用されていること。
  • 一貫性: 機能全体でシェイプ、ティント、スペーシングが揃っていること。

実装チェックリスト

  • 対象要素と望ましいガラスのプロミネンスを定義します。
  • グループ化されたガラス要素を GlassEffectContainer でラップし、スペーシングを調整します。
  • 必要に応じて .glassEffect(.regular.tint(...).interactive(), in: .rect(cornerRadius: ...)) を使用します。
  • アクションには .buttonStyle(.glass) / .buttonStyle(.glassProminent) を使用します。
  • ビュー階層が変更される場合、glassEffectID を使用してモーフィングトランジションを追加します。
  • 古いiOSバージョン向けにフォールバックマテリアルとビジュアルを提供します。

クイックスニペット

以下のパターンを直接使用し、シェイプ、ティント、スペーシングを調整してください。

if #available(iOS 26, *) {
    Text("Hello")
        .padding()
        .glassEffect(.regular.interactive(), in: .rect(cornerRadius: 16))
} else {
    Text("Hello")
        .padding()
        .background(.ultraThinMaterial, in: RoundedRectangle(cornerRadius: 16))
}
GlassEffectContainer(spacing: 24) {
    HStack(spacing: 24) {
        Image(systemName: "scribble.variable")
            .frame(width: 72, height: 72)
            .font(.system(size: 32))
            .glassEffect()
        Image(systemName: "eraser.fill")
            .frame(width: 72, height: 72)
            .font(.system(size: 32))
            .glassEffect()
    }
}
Button("Confirm") { }
    .buttonStyle(.glassProminent)

リソース

  • リファレンスガイド: references/liquid-glass.md
  • 最新のAPI詳細についてはAppleのドキュメントを推奨します。

Individual skills in this repo

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

ComeOnOliver/skillshub

Create stunning, animation-rich HTML presentations from scratch or by converting PowerPoint files. Use when the user wants to build a presentation, convert a PPT/PPTX to web, or create slides for a talk/pitch. Helps non-designers discover their aesthetic through visual exploration rather than abstract choices.

ComeOnOliver/skillshub

Next.js 16+ 和 Turbopack — 增量打包、文件系统缓存、开发速度,以及何时使用 Turbopack 与 webpack。

ComeOnOliver/skillshub

SwiftUI architecture patterns, state management with @Observable, view composition, navigation, performance optimization, and modern iOS/macOS UI best practices.

ComeOnOliver/skillshub

See, Understand, Act on video and audio. See- ingest from local files, URLs, RTSP/live feeds, or live record desktop; return realtime context and playable stream links. Understand- extract frames, build visual/semantic/temporal indexes, and search moments with timestamps and auto-clips. Act- transcode and normalize (codec, fps, resolution, aspect ratio), perform timeline edits (subtitles, text/image overlays, branding, audio overlays, dubbing, translation), generate media assets (image, audio, video), and create real time alerts for events from live streams or desktop capture.

ComeOnOliver/skillshub

AI-assisted video editing workflows for cutting, structuring, and augmenting real footage. Covers the full pipeline from raw capture through FFmpeg, Remotion, ElevenLabs, fal.ai, and final polish in Descript or CapCut. Use when the user wants to edit video, cut footage, create vlogs, or build video content.

ComeOnOliver/skillshub

Next.js 15 애플리케이션을 위한 프론트엔드 개발 가이드라인. React 19, TypeScript, Shadcn/ui, Tailwind CSS를 사용한 모던 패턴. Server Components, Client Components, App Router, 파일 구조, Shadcn/ui 컴포넌트, 성능 최적화, TypeScript 모범 사례 포함. 컴포넌트, 페이지, 기능 생성, 데이터 페칭, 스타일링, 라우팅, 프론트엔드 코드 작업 시 사용.

ComeOnOliver/skillshub

Provides Tamagui patterns for config v4, compiler optimization, styled context, and cross-platform styling. Must use when working with Tamagui projects (tamagui.config.ts, @tamagui imports).

ComeOnOliver/skillshub

Create distinctive, production-grade frontend interfaces with high design quality. Use this skill when the user asks to build web components, pages, or applications. Generates creative, polished code that avoids generic AI aesthetics.

ComeOnOliver/skillshub

Create high-converting, visually distinctive landing pages. Use when building marketing pages, product launches, SaaS homepages, or any single-page conversion-focused website. Guides section-by-section composition with anti-AI-slop principles.

ComeOnOliver/skillshub

Auto-loaded context for Portfolio Buddy 2 development. Use for ANY task involving: React 19 development, TypeScript, portfolio analysis features, metrics calculations, trading strategy comparison, or working with the Portfolio Buddy 2 codebase. Contains tech stack, known issues, and architectural constraints.

ComeOnOliver/skillshub

Next.js development tooling via MCP. Inspect routes, components, build info, and debug Next.js apps. Use when working on Next.js applications, debugging routing, or inspecting app structure. NOT for general React or non-Next.js projects.

ComeOnOliver/skillshub

Implement UI using Shadcn MCP (atoms/theme) and 21st.dev MCP (complex sections). Use when adding buttons, layouts, or generating landing pages.

ComeOnOliver/skillshub

A conceptual skill for building an API client in Next.js that handles JWT tokens

ComeOnOliver/skillshub

Best practices and patterns for Next.js App Router, Server Actions, and Routing in this project.

ComeOnOliver/skillshub

The Design System, Theme, and UX rules for the Physical AI Hub.

ComeOnOliver/skillshub

Comprehensive frontend development skill for building modern, performant web applications using ReactJS, NextJS, TypeScript, Tailwind CSS. Includes component scaffolding, performance optimization, bundle analysis, and UI best practices. Use when developing frontend features, optimizing performance, implementing UI/UX designs, managing state, or reviewing frontend code.

ComeOnOliver/skillshub

This document captures learnings from fixing keyboard navigation issues when floating components (Select, DropdownMenu, Popover) have CSS open/close animations.

ComeOnOliver/skillshub

Build Next.js 16 applications with correct patterns and distinctive design. Use when creating pages, layouts, dynamic routes, upgrading from Next.js 15, or implementing proxy.ts. Covers breaking changes (async params/searchParams, Turbopack, cacheComponents) and frontend aesthetics. NOT when building non-React or backend-only applications.

ComeOnOliver/skillshub

Comprehensive Framer Motion animation library for React. Covers motion components, variants, gestures, page transitions, and scroll animations. Use when adding animations to React/Next.js applications.

ComeOnOliver/skillshub

Build interfaces that resonate, not just render. This skill enforces bold, intentional

関連スキル