apple-design
Fungsinya
Skill ini membagikan prinsip dari presentasi desain Apple dan menerapkannya pada antarmuka web. Cocok untuk pengembang dan desainer yang ingin interaksi seret, geser, dan lembar terasa fisik serta responsif.
Kapan dipakai
- βSaat Anda membangun atau meninjau antarmuka berbasis gestur seperti seret, geser, atau lembar.
- βSaat Anda ingin animasi pegas yang bisa diinterupsi dan diarahkan ulang.
- βSaat Anda perlu mendukung pengaturan gerakan yang dikurangi atau menyempurnakan tipografi dan material.
Link skill
https://github.com/spree/spree/blob/main/.agents/skills/apple-design/SKILL.mdSalin lalu tempelkan ke AI Anda (Claude, ChatGPT, atau Cursor) dan minta AI mengikuti instruksinya.
Cara pakai
Cara paling mudah: salin pesan ini dan tempelkan ke AI Anda. AI akan membaca skill dan mengikuti instruksinya.
Pesan siap tempel
Untuk Claude Code, Codex, atau Cursor: jalankan di folder proyek, lalu skill langsung terpasang.
Unduh SKILL.md lalu taruh di folder skill agen Anda.
Contoh permintaan ke AI
βBuat lembar bawah ini mengikuti jari saya, membawa momentum, dan terasa alami saat saya melepasnya.β
5 skill baru setiap minggu. 1 menit baca.
Cara kerjanya
Agent menerapkan serangkaian prinsip: gerakan dimulai dari nilai di layar saat ini, mempertahankan kecepatan pengguna, dan bisa dipegang lalu dibalik kapan saja. Ia memakai pegas dan peristiwa input web untuk mencapainya.
Konten teknis (SKILL.md asli)
Teks asli dari pembuat, dalam bahasa Inggris, langsung dari GitHub.
Apple Design
How Apple builds interfaces that stop feeling like a computer and start feeling like an extension of you. This knowledge comes from Apple's WWDC design talks β chiefly Designing Fluid Interfaces (WWDC 2018) β distilled and translated into the web platform (CSS, Pointer Events, requestAnimationFrame, spring libraries like Motion/Framer Motion).
The through-line: an interface feels alive when motion starts from the current on-screen value, inherits the user's velocity, projects momentum forward, and can be grabbed and reversed at any instant. Springs are the tool that makes all of this natural, because they are inherently interruptible and velocity-aware.
The Core Idea
"When we align the interface to the way we think and move, something magical happens β it stops feeling like a computer and starts feeling like a seamless extension of us."
An interface is fluid when it behaves like the physical world: things respond instantly, move continuously, carry momentum, resist at boundaries, and can be redirected mid-motion. Everything below is a way to get closer to that.
Apple frames design as serving four human needs: safety/predictability, understanding, achievement, and joy. Every rule here serves one of them.
1. Response β kill latency
The moment lag appears, the feeling of directness "falls off a cliff." Response is the foundation everything else is built on.
- Respond on pointer-down, not on release. Highlight a button the instant it's pressed. Waiting for
click/touch-up to show feedback feels dead. - Be vigilant about every latency. Audit debounces, artificial timers, transition waits, and the ~300ms tap delay. Anything on the input path that isn't essential is a regression.
- Feedback must be continuous during the interaction, not just at the end. For a drag, slider, or drawer, update the UI 1:1 with the pointer the whole way through β never animate only when the gesture completes.
/* Feedback lives on the press, and it's instant */
.button:active {
transform: scale(0.97);
transition: transform 100ms ease-out;
}
2. Direct manipulation β 1:1 tracking
"Touch and content should move together."
When the user drags something, it must stay glued to the finger β and respect the offset from where they grabbed it. Snapping to the element's center on grab breaks the illusion immediately.
- Use Pointer Events with
setPointerCaptureso tracking continues even when the pointer leaves the element's bounds. - Track a short velocity/position history (last few
pointermoveevents), not just the current point β you'll need velocity at release.
el.addEventListener('pointerdown', (e) => {
el.setPointerCapture(e.pointerId);
const grabOffset = e.clientY - el.getBoundingClientRect().top; // respect where they grabbed
// ...track position + timestamp history for velocity
});
3. Interruptibility β the single most important principle
"The thought and the gesture happen in parallel."
Every animation must be interruptible and redirectable at any moment. A user must be able to grab a moving element mid-flight and reverse it without waiting for the animation to finish. A closing modal the user grabs again should follow the finger β not finish closing first, then reopen.
- Never lock out input during a transition.
- Always animate from the presentation (current) value, never the target value. On interrupt, read the element's live on-screen transform and start the new animation from there. Starting from the logical/target value causes a visible jump.
- Avoid CSS transitions and
@keyframesfor anything gesture-driven β they can't be smoothly grabbed and reversed mid-flight. Springs animate from the current value by default, which is exactly what interruption needs. - When a gesture reverses, blend velocity β don't hard-cut it. Replacing one animation with another at a reversal creates a velocity discontinuity, a "brick wall." Spring libraries that carry velocity through a re-target avoid it. (This is what iOS's additive animations do natively; on the web, choose a spring library that re-targets from the current velocity.)
- Decompose 2D motion into independent X and Y springs. A single spring on a 2D distance desyncs when X and Y have different velocities.
4. Behavior over animation β use springs
"Think of animation as a conversation between you and the object, not something prescribed by the interfac
Pertanyaan umum
Apakah ini hanya untuk perangkat Apple?
Tidak. Skill ini menerjemahkan prinsip desain Apple ke alat web seperti CSS, Pointer Events, dan pustaka pegas.
Apa artinya bisa diinterupsi?
Gerakan bisa dipegang dan dibalik di tengah jalan, daripada harus selesai dulu.
Apakah ia mencakup gerakan yang dikurangi?
Ya. Skill ini menyertakan panduan untuk pengaturan gerakan yang dikurangi.
Detail
Deskripsi asli dari pembuat
Apple's approach to interface design and fluid, physical motion, translated for the web. Use when building or reviewing gesture-driven UI, spring animations, drag/swipe/sheet interactions, momentum and interruptible transitions, translucent materials and depth, typography (optical sizing, tracking, leading), reduced-motion, or the design foundations (feedback, spatial consistency, restraint) behind Apple-style interfaces.
repo: spree/spree
Popularitas
- Bintang GitHub
- 16k
- Peringkat
- #10874
- Lisensi
- BSD-3-Clause
- Diperbarui
- 2/11/2026
Komentar
- β¦
Skill lain dari repositori ini
animate
16kMembuat animasi dari awal dengan memutuskan dulu apakah sebuah elemen perlu bergerak, lalu memilih tujuan, waktu, dan kurva sebelum menulis kodenya.
animation-vocabulary
16kMengubah deskripsi animasi atau efek gerakan yang samar menjadi nama teknisnya yang tepat, sehingga Anda tahu apa yang harus diminta.
find-animation-opportunities
16kMencari antarmuka untuk tempat yang akan diuntungkan oleh gerakan dan menolak sisanya. Memberikan daftar pendek saran animasi yang tepat tanpa mengubah kode.
improve-animations
16kMengaudit animasi basis kode dan menulis rencana yang diprioritaskan agar bisa dijalankan agent lain. Hanya membuat rencana; tidak mengubah kode sumber.
Skill serupa
canvas
394kMemungkinkan agent Anda menampilkan widget visual yang di-hosting di panel Mac yang terhubung, lalu menyembunyikan panel atau memindahkannya ke halaman lain.
control-ui
394kMembantu agent Anda mengatur dan memecahkan masalah OpenClaw Control UI, termasuk sesi, dasbor, dan Gateway yang terhubung.
diagram-maker
394kMembantu agent Anda membuat diagram yang jelas sebagai SVG, HTML, atau Excalidraw yang dapat diedit untuk proses, arsitektur sistem, dan sketsa papan tulis.