{
  "id": "motion:motion-turntable",
  "slug": "motion-turntable",
  "kind": "motion",
  "title": {
    "ja": "ターンテーブル",
    "en": "Scroll-driven character turnaround"
  },
  "aiName": "Scroll-driven character turnaround",
  "summary": {
    "ja": "スクロールで人物が回り、正面・斜め・横・背面が入れ替わる",
    "en": "A figure turns as you scroll, swapping its front, three-quarter, side and back views"
  },
  "number": 61,
  "group": "media-depth",
  "techniques": [
    "scroll-progress",
    "position-sticky",
    "svg"
  ],
  "rules": [
    {
      "ja": "絵の差し替えは幅が 0 の瞬間だけ。半分の幅で替えると、別人が回り込んだように見える",
      "en": "Swap the picture only at zero width; swapping at half width looks like someone else stepping in"
    },
    {
      "ja": "向き別の絵は同じキャンバス・同じ足元の高さで描く。足元が揃わないと回る間に人物が上下する",
      "en": "Draw every view on the same canvas with the same foot line, or the figure bobs as it turns"
    },
    {
      "ja": "動きを減らす設定では、4 枚を横に並べて止める",
      "en": "With reduced motion on, show the four views side by side and stop"
    }
  ],
  "reproduction": {
    "prompt": {
      "ja": "ターンテーブル — Scroll-driven character turnaround\n\nキャラクターの向き別の絵 4 枚（正面・斜め・横・背面）を、スクロールに合わせて 1 枚ずつ回して見せる。区画の高さは 400vh、中の箱は 100vh の sticky にする。\n--p を 0.04〜0.96 の範囲で 4 等分し、それぞれの区間で 1 枚を見せる。区間の境目の前後 7%（1 枚分の長さに対して）では、絵の横幅を `scaleX` で 1 → 0 → 1 と縮めて広げ、幅が 0 になった瞬間に次の絵へ差し替える。縮み方は sin のなめらかさにする。\n左に大きな番号（01 / 04）と向きの名前、下に 4 枚の小さな絵を並べて今の 1 枚に下線を引く。足元には楕円の上に 36 本の目盛りを置き、--p に合わせて 1 周回し、手前の目盛りだけを濃くする。\nCSS と素の JavaScript だけで実装し、ライブラリは使わない。\n\n外すと崩れる点:\n- 絵の差し替えは幅が 0 の瞬間だけ。半分の幅で替えると、別人が回り込んだように見える\n- 向き別の絵は同じキャンバス・同じ足元の高さで描く。足元が揃わないと回る間に人物が上下する\n- 動きを減らす設定では、4 枚を横に並べて止める\n\n動く実物（1 ファイルで完結する HTML）: https://design-vault.pages.dev/designs/motion-turntable/demo.html",
      "en": "Scroll-driven character turnaround — Scroll-driven character turnaround\n\nShow four turnaround views of a character (front, three-quarter, side, back) one at a time as the page scrolls. Make the section 400vh tall and the box inside a 100vh sticky element.\nSplit --p between 0.04 and 0.96 into four equal spans, one view each. Within 7% of a view's span on either side of a boundary, squeeze the figure with `scaleX` from 1 to 0 and back to 1, and swap to the next view at the moment the width is 0. Use a sine curve for the squeeze.\nPut a large counter (01 / 04) and the view's name on the left, and a row of the four small views below with the current one underlined. Under the feet, place 36 ticks on an ellipse that turn once over --p, with only the near ticks drawn dark.\nImplement with CSS and plain JavaScript only; do not use a library.\n\nDo not drop:\n- Swap the picture only at zero width; swapping at half width looks like someone else stepping in\n- Draw every view on the same canvas with the same foot line, or the figure bobs as it turns\n- With reduced motion on, show the four views side by side and stop\n\nA working example (one self-contained HTML file): https://design-vault.pages.dev/designs/motion-turntable/demo.html"
    },
    "code": {
      "url": "https://design-vault.pages.dev/designs/motion-turntable/demo.html",
      "html": "<!doctype html>\n<html lang=\"ja\">\n<head>\n<meta charset=\"utf-8\">\n<meta name=\"viewport\" content=\"width=device-width, initial-scale=1\">\n<title>61 ターンテーブル — Scroll-driven character turnaround</title>\n<style>\n/* dv-motion-base:start */\n:root {\n  --ground: #FFFFFF;\n  --surface: #F3F5F8;\n  --ink: #14181F;\n  --muted: #5A6472;\n  --accent: #1F5FA8;\n  --rule: #D8DDE4;\n  --accent-soft: color-mix(in srgb, var(--accent) 12%, var(--ground));\n  --accent-mid: color-mix(in srgb, var(--accent) 45%, var(--ground));\n  --shade: color-mix(in srgb, var(--ink) 14%, transparent);\n\n  --font: \"Zen Kaku Gothic New\", \"Hiragino Sans\", \"Noto Sans JP\", \"Yu Gothic\", system-ui, sans-serif;\n  --mono: ui-monospace, \"SF Mono\", Menlo, Consolas, monospace;\n\n  --t-label: 13px;\n  --t-body: 16px;\n  --t-lead: 20px;\n  --t-h2: 32px;\n  --t-h1: clamp(40px, 7vw, 72px);\n\n  --s1: 4px;\n  --s2: 8px;\n  --s3: 16px;\n  --s4: 24px;\n  --s5: 40px;\n  --s6: 64px;\n  --s7: 104px;\n\n  --radius: 12px;\n  --ease: cubic-bezier(.2, .7, .2, 1);\n  --dur: .7s;\n  --measure: 1080px;\n}\n*, *::before, *::after { box-sizing: border-box; }\nhtml { -webkit-text-size-adjust: 100%; }\nbody {\n  margin: 0;\n  background: var(--ground);\n  color: var(--ink);\n  font-family: var(--font);\n  font-size: var(--t-body);\n  line-height: 1.7;\n  font-feature-settings: \"palt\";\n  overflow-x: hidden;\n}\nh1, h2, h3, p, ul, ol, figure { margin: 0; padding: 0; }\nul, ol { list-style: none; }\n.dv-wrap { width: min(100% - 2 * var(--s4), var(--measure)); margin-inline: auto; }\n.dv-label {\n  min-height: 72vh;\n  display: grid;\n  align-content: center;\n  gap: var(--s3);\n  padding-block: var(--s6);\n  border-bottom: 1px solid var(--rule);\n}\n.dv-num { font-family: var(--mono); font-size: var(--t-lead); font-weight: 700; color: var(--accent); letter-spacing: .04em; }\n.dv-name { font-size: var(--t-h1); font-weight: 700; line-height: 1.15; letter-spacing: .01em; }\n.dv-ai { font-family: var(--mono); font-size: var(--t-lead); color: var(--muted); }\n.dv-desc { font-size: var(--t-lead); color: var(--ink); }\n.dv-hint { font-size: var(--t-label); color: var(--muted); letter-spacing: .12em; margin-top: var(--s4); }\n.dv-stage { padding-block: var(--s7); }\n.dv-h2 { font-size: var(--t-h2); font-weight: 700; line-height: 1.3; }\n.dv-lead { font-size: var(--t-lead); color: var(--muted); }\n.dv-eyebrow { font-family: var(--mono); font-size: var(--t-label); color: var(--accent); letter-spacing: .12em; text-transform: uppercase; }\n.dv-card { background: var(--surface); border: 1px solid var(--rule); border-radius: var(--radius); padding: var(--s4); }\n.dv-ph {\n  border-radius: var(--radius);\n  background: linear-gradient(135deg, var(--accent-soft), var(--accent-mid) 60%, var(--accent));\n  aspect-ratio: 16 / 9;\n}\n.dv-ph--alt { background: linear-gradient(200deg, var(--surface), var(--accent-soft) 55%, var(--accent-mid)); }\n.dv-ph--ink { background: linear-gradient(160deg, var(--ink), color-mix(in srgb, var(--ink) 55%, var(--accent))); }\n.dv-end {\n  min-height: 60vh;\n  display: grid;\n  place-items: center;\n  border-top: 1px solid var(--rule);\n  color: var(--muted);\n  font-family: var(--mono);\n  font-size: var(--t-label);\n  letter-spacing: .12em;\n}\n/* dv-motion-base:end */\n\n/* ---- この演出だけの CSS。色は var(--…) か color-mix() のみ ---- */\n.f-ink { fill: var(--ink); }\n.f-face { fill: var(--surface); }\n.f-accent { fill: var(--accent); }\n.f-arm { stroke: var(--ink); stroke-width: 30; stroke-linecap: round; fill: none; }\n.tt-zone { height: 400vh; }\n.tt-box {\n  position: sticky; top: 0; height: 100vh; display: grid; align-items: center;\n  grid-template-columns: minmax(0, 1fr) minmax(0, 1.3fr); gap: var(--s4); overflow: clip;\n}\n.tt-count { font-family: var(--mono); font-weight: 700; line-height: 1; }\n.tt-num { font-size: clamp(72px, 16vw, 200px); color: var(--ink); letter-spacing: -.04em; }\n.tt-of { font-size: var(--t-lead); color: var(--muted); margin-top: var(--s2); }\n.tt-view { font-size: var(--t-h2); font-weight: 700; margin-top: var(--s4); }\n.tt-stand { position: relative; height: 82vh; display: grid; justify-items: center; }\n.tt-band { position: absolute; inset: 6% 26% 8%; background: var(--accent-soft); border-radius: var(--radius); }\n.tt-fig { position: relative; height: 74vh; width: 29.6vh; transform: scaleX(var(--w, 1)); }\n.tt-fig svg { width: 100%; height: 100%; display: block; overflow: visible; }\n.tt-floor { position: absolute; left: 50%; bottom: 2vh; width: min(36vh, 90%); transform: translateX(-50%); overflow: visible; }\n.tt-floor ellipse { fill: none; stroke: var(--rule); stroke-width: 2; }\n.tt-floor line { stroke: var(--ink); stroke-width: 2; }\n.tt-strip { grid-column: 1 / -1; display: flex; gap: var(--s3); justify-content: center; align-self: end; padding-bottom: var(--s4); }\n.tt-thumb { width: 40px; height: 100px; opacity: .3; border-bottom: 4px solid transparent; padding-bottom: var(--s1); }\n.tt-thumb svg { width: 100%; height: 100%; display: block; }\n.tt-thumb.is-on { opacity: 1; border-color: var(--accent); }\n.tt-box { grid-template-rows: 1fr auto; }\n@media (max-width: 600px) {\n  .tt-box { grid-template-columns: minmax(0, .8fr) minmax(0, 1.2fr); }\n  .tt-stand { height: 64vh; }\n  .tt-fig { height: 58vh; width: 23.2vh; }\n}\n@media (prefers-reduced-motion: reduce) {\n  .tt-zone { height: auto; }\n  .tt-box { position: static; height: auto; }\n  .tt-stand, .tt-count { display: none; }\n  .tt-strip { grid-column: 1 / -1; padding-block: var(--s6); gap: var(--s5); }\n  .tt-thumb { width: min(18vw, 120px); height: auto; aspect-ratio: 2 / 5; opacity: 1; border-color: transparent; }\n  .tt-thumb.is-on { border-color: transparent; }\n}\n</style>\n</head>\n<body data-motion-number=\"61\">\n<header class=\"dv-label\">\n  <div class=\"dv-wrap\">\n    <p class=\"dv-num\">61</p>\n    <h1 class=\"dv-name\">ターンテーブル</h1>\n    <p class=\"dv-ai\">Scroll-driven character turnaround</p>\n    <p class=\"dv-desc\">スクロールで人物が回り、正面・斜め・横・背面が入れ替わる</p>\n    <p class=\"dv-hint\">SCROLL ↓</p>\n  </div>\n</header>\n\n<svg width=\"0\" height=\"0\" style=\"position: absolute\" aria-hidden=\"true\">\n  <symbol id=\"fig-front\" viewBox=\"0 0 400 1000\">\n    <path class=\"f-ink\" d=\"M128 120 Q120 40 200 34 Q280 40 272 120 L292 430 L108 430 Z\"/>\n    <rect class=\"f-ink\" x=\"182\" y=\"210\" width=\"36\" height=\"50\"/>\n    <ellipse class=\"f-face\" cx=\"200\" cy=\"150\" rx=\"60\" ry=\"72\"/>\n    <path class=\"f-ink\" d=\"M140 118 Q200 60 262 118 L262 96 Q200 40 138 96 Z\"/>\n    <ellipse class=\"f-ink\" cx=\"176\" cy=\"158\" rx=\"7\" ry=\"11\"/><ellipse class=\"f-ink\" cx=\"224\" cy=\"158\" rx=\"7\" ry=\"11\"/>\n    <path class=\"f-accent\" d=\"M232 70 l40 -26 l6 36 Z M232 70 l-6 -40 l40 16 Z\"/>\n    <path class=\"f-ink\" d=\"M128 252 L272 252 L240 520 L160 520 Z\"/>\n    <path class=\"f-accent\" d=\"M160 520 L240 520 L296 712 L104 712 Z\"/>\n    <rect class=\"f-ink\" x=\"158\" y=\"712\" width=\"30\" height=\"236\"/><rect class=\"f-ink\" x=\"212\" y=\"712\" width=\"30\" height=\"236\"/>\n    <ellipse class=\"f-ink\" cx=\"170\" cy=\"956\" rx=\"30\" ry=\"16\"/><ellipse class=\"f-ink\" cx=\"230\" cy=\"956\" rx=\"30\" ry=\"16\"/>\n    <path class=\"f-arm\" d=\"M136 262 L104 516\"/><path class=\"f-arm\" d=\"M264 262 L300 496\"/>\n    <rect class=\"f-accent\" x=\"282\" y=\"478\" width=\"42\" height=\"58\" rx=\"6\"/>\n  </symbol>\n  <symbol id=\"fig-34\" viewBox=\"0 0 400 1000\">\n    <path class=\"f-ink\" d=\"M136 120 Q132 40 206 34 Q276 42 268 120 L282 430 L116 430 Z\"/>\n    <rect class=\"f-ink\" x=\"186\" y=\"210\" width=\"34\" height=\"50\"/>\n    <ellipse class=\"f-face\" cx=\"214\" cy=\"150\" rx=\"52\" ry=\"72\"/>\n    <path class=\"f-ink\" d=\"M156 116 Q214 62 268 116 L268 94 Q210 42 152 94 Z\"/>\n    <ellipse class=\"f-ink\" cx=\"200\" cy=\"158\" rx=\"6\" ry=\"11\"/><ellipse class=\"f-ink\" cx=\"240\" cy=\"158\" rx=\"6\" ry=\"11\"/>\n    <path class=\"f-accent\" d=\"M226 70 l36 -24 l6 34 Z M226 70 l-6 -38 l36 14 Z\"/>\n    <path class=\"f-ink\" d=\"M140 252 L264 252 L238 520 L166 520 Z\"/>\n    <path class=\"f-accent\" d=\"M166 520 L238 520 L286 712 L118 712 Z\"/>\n    <rect class=\"f-ink\" x=\"166\" y=\"712\" width=\"28\" height=\"236\"/><rect class=\"f-ink\" x=\"214\" y=\"712\" width=\"28\" height=\"236\"/>\n    <ellipse class=\"f-ink\" cx=\"184\" cy=\"956\" rx=\"28\" ry=\"16\"/><ellipse class=\"f-ink\" cx=\"236\" cy=\"956\" rx=\"30\" ry=\"16\"/>\n    <path class=\"f-arm\" d=\"M146 262 L122 512\"/><path class=\"f-arm\" d=\"M256 262 L284 496\"/>\n    <rect class=\"f-accent\" x=\"266\" y=\"478\" width=\"38\" height=\"58\" rx=\"6\"/>\n  </symbol>\n  <symbol id=\"fig-side\" viewBox=\"0 0 400 1000\">\n    <path class=\"f-ink\" d=\"M150 120 Q150 40 214 36 Q262 44 258 120 L246 420 L150 420 Z\"/>\n    <path class=\"f-face\" d=\"M210 92 Q262 96 266 150 L276 170 L264 176 Q262 214 222 222 L206 222 Z\"/>\n    <ellipse class=\"f-ink\" cx=\"244\" cy=\"156\" rx=\"5\" ry=\"10\"/>\n    <path class=\"f-accent\" d=\"M196 66 l-34 -30 l-6 34 Z\"/>\n    <rect class=\"f-ink\" x=\"194\" y=\"214\" width=\"30\" height=\"46\"/>\n    <path class=\"f-ink\" d=\"M168 252 L246 252 L236 520 L172 520 Z\"/>\n    <path class=\"f-accent\" d=\"M172 520 L236 520 L266 712 L142 712 Z\"/>\n    <rect class=\"f-ink\" x=\"186\" y=\"712\" width=\"32\" height=\"236\"/>\n    <path class=\"f-ink\" d=\"M186 948 L248 948 Q252 970 230 970 L186 970 Z\"/>\n    <path class=\"f-arm\" d=\"M208 266 L222 500\"/>\n    <rect class=\"f-accent\" x=\"204\" y=\"484\" width=\"44\" height=\"56\" rx=\"6\"/>\n  </symbol>\n  <symbol id=\"fig-back\" viewBox=\"0 0 400 1000\">\n    <path class=\"f-ink\" d=\"M128 120 Q120 40 200 34 Q280 40 272 120 L292 430 L108 430 Z\"/>\n    <rect class=\"f-ink\" x=\"182\" y=\"210\" width=\"36\" height=\"50\"/>\n    <path class=\"f-accent\" d=\"M232 70 l40 -26 l6 36 Z M232 70 l-6 -40 l40 16 Z\"/>\n    <path class=\"f-ink\" d=\"M128 252 L272 252 L240 520 L160 520 Z\"/>\n    <path class=\"f-accent\" d=\"M160 520 L240 520 L296 712 L104 712 Z\"/>\n    <rect class=\"f-ink\" x=\"158\" y=\"712\" width=\"30\" height=\"236\"/><rect class=\"f-ink\" x=\"212\" y=\"712\" width=\"30\" height=\"236\"/>\n    <ellipse class=\"f-ink\" cx=\"170\" cy=\"956\" rx=\"30\" ry=\"16\"/><ellipse class=\"f-ink\" cx=\"230\" cy=\"956\" rx=\"30\" ry=\"16\"/>\n    <path class=\"f-arm\" d=\"M136 262 L104 516\"/><path class=\"f-arm\" d=\"M264 262 L300 496\"/>\n  </symbol>\n</svg>\n<main class=\"dv-stage\">\n  <div class=\"dv-wrap\">\n    <section class=\"tt-zone\" data-progress=\"pin\">\n      <div class=\"tt-box\">\n        <div class=\"tt-count\">\n          <p class=\"tt-num\"><span class=\"tt-i\">01</span></p>\n          <p class=\"tt-of\">/ 04</p>\n          <p class=\"tt-view\">正面</p>\n        </div>\n        <div class=\"tt-stand\">\n          <div class=\"tt-band\"></div>\n          <div class=\"tt-fig\"><svg viewBox=\"0 0 400 1000\" role=\"img\" aria-label=\"代役の人物\"><use href=\"#fig-front\"/></svg></div>\n          <svg class=\"tt-floor\" viewBox=\"-180 -40 360 80\" aria-hidden=\"true\"><ellipse rx=\"170\" ry=\"28\"/><g class=\"tt-ticks\"></g></svg>\n        </div>\n        <div class=\"tt-strip\">\n        <figure class=\"tt-thumb\" aria-label=\"正面\"><svg viewBox=\"0 0 400 1000\"><use href=\"#fig-front\"/></svg></figure>\n        <figure class=\"tt-thumb\" aria-label=\"斜め\"><svg viewBox=\"0 0 400 1000\"><use href=\"#fig-34\"/></svg></figure>\n        <figure class=\"tt-thumb\" aria-label=\"横\"><svg viewBox=\"0 0 400 1000\"><use href=\"#fig-side\"/></svg></figure>\n        <figure class=\"tt-thumb\" aria-label=\"背面\"><svg viewBox=\"0 0 400 1000\"><use href=\"#fig-back\"/></svg></figure>\n        </div>\n      </div>\n    </section>\n  </div>\n</main>\n\n<footer class=\"dv-end\">END — 61 ターンテーブル</footer>\n\n<script>\n/* dv-motion-helpers:start */\nconst dvReduce = matchMedia('(prefers-reduced-motion: reduce)').matches;\ndocument.documentElement.classList.add('js');\n\n/**\n * 画面に入った要素へ .is-in を付ける。\n * data-reveal=\"repeat\" の要素は画面を出たら外す（何度でも再生）。\n */\nfunction dvReveal(selector = '[data-reveal]', { threshold = 0.2, rootMargin = '0px 0px -8% 0px' } = {}) {\n  const els = [...document.querySelectorAll(selector)];\n  if (dvReduce || !('IntersectionObserver' in window)) {\n    els.forEach((el) => el.classList.add('is-in'));\n    return;\n  }\n  const io = new IntersectionObserver((entries) => {\n    for (const e of entries) {\n      if (e.isIntersecting) {\n        e.target.classList.add('is-in');\n        if (e.target.dataset.reveal !== 'repeat') io.unobserve(e.target);\n      } else if (e.target.dataset.reveal === 'repeat') {\n        e.target.classList.remove('is-in');\n      }\n    }\n  }, { threshold, rootMargin });\n  els.forEach((el) => io.observe(el));\n}\n\n/**\n * スクロール量を 0〜1 にして、各 [data-progress] 要素の CSS 変数 --p に書く。\n *   data-progress=\"through\" : 要素の上端が画面の下端に来たとき 0、下端が画面の上端を抜けたとき 1\n *   data-progress=\"pin\"     : 要素の上端が画面の上端に来たとき 0、下端が画面の下端に来たとき 1\n *                             （中に position: sticky の箱を持つ、背の高い区画用）\n *   data-progress=\"page\"    : ページ全体のスクロール量\n * onUpdate(el, p) を渡すと、値が変わるたびに呼ばれる。\n */\nfunction dvProgress(onUpdate) {\n  const els = [...document.querySelectorAll('[data-progress]')];\n  const clamp = (n) => Math.min(1, Math.max(0, n));\n  let queued = false;\n  const measure = () => {\n    queued = false;\n    const vh = window.innerHeight;\n    for (const el of els) {\n      const r = el.getBoundingClientRect();\n      let p;\n      if (el.dataset.progress === 'pin') p = r.height > vh ? -r.top / (r.height - vh) : 0;\n      else if (el.dataset.progress === 'page') {\n        const max = document.documentElement.scrollHeight - vh;\n        p = max > 0 ? window.scrollY / max : 0;\n      } else p = (vh - r.top) / (vh + r.height);\n      p = clamp(p);\n      el.style.setProperty('--p', p.toFixed(4));\n      if (onUpdate) onUpdate(el, p);\n    }\n  };\n  const request = () => {\n    if (!queued) { queued = true; requestAnimationFrame(measure); }\n  };\n  addEventListener('scroll', request, { passive: true });\n  addEventListener('resize', request);\n  measure();\n}\n/* dv-motion-helpers:end */\n\n/* ---- この演出だけの JS ---- */\n// 向き別の絵を、進み p に合わせて 1 枚ずつ回して見せる。境目では幅を 1 → 0 → 1 にし、幅 0 の瞬間に絵を差し替える。\nconst VIEWS = [['front', '正面'], ['34', '斜め'], ['side', '横'], ['back', '背面']];\nconst SPAN = [0.04, 0.96], TURN = 0.14;\nfunction turnAt(p, n) {\n  const pos = Math.min(n - 1e-9, Math.max(0, ((p - SPAN[0]) / (SPAN[1] - SPAN[0])) * n));\n  const i = Math.floor(pos), f = pos - i, half = TURN / 2;\n  let w = 1;\n  if (i > 0 && f < half) w = f / half;\n  else if (i < n - 1 && f > 1 - half) w = (1 - f) / half;\n  return { i, w: Math.sin((w * Math.PI) / 2) };\n}\nconst zone = document.querySelector('.tt-zone');\nconst fig = zone.querySelector('.tt-fig'), use = fig.querySelector('use');\nconst ticks = zone.querySelector('.tt-ticks');\nconst NS = 'http://www.w3.org/2000/svg';\nconst marks = Array.from({ length: 36 }, (_, k) => {\n  const l = document.createElementNS(NS, 'line');\n  ticks.appendChild(l);\n  return l;\n});\nlet shown = -1;\ndvProgress((el, p) => {\n  const { i, w } = turnAt(dvReduce ? 1 : p, VIEWS.length);\n  fig.style.setProperty('--w', w.toFixed(4));\n  if (i !== shown) {\n    shown = i;\n    use.setAttribute('href', `#fig-${VIEWS[i][0]}`);\n    zone.querySelector('.tt-i').textContent = String(i + 1).padStart(2, '0');\n    zone.querySelector('.tt-view').textContent = VIEWS[i][1];\n    zone.querySelectorAll('.tt-thumb').forEach((t, k) => t.classList.toggle('is-on', k === i));\n  }\n  // 足元の目盛りは p に合わせて 1 周する。手前の目盛りだけを濃くする。\n  marks.forEach((l, k) => {\n    const a = ((k * 10 + p * 360) * Math.PI) / 180, x = Math.cos(a) * 170, y = Math.sin(a) * 28;\n    l.setAttribute('x1', x.toFixed(1)); l.setAttribute('x2', x.toFixed(1));\n    l.setAttribute('y1', y.toFixed(1)); l.setAttribute('y2', (y + (k % 3 ? 7 : 13)).toFixed(1));\n    l.style.opacity = Math.sin(a) > 0 ? 0.85 : 0.2;\n  });\n});\n</script>\n</body>\n</html>\n"
    }
  },
  "license": "Original",
  "catalogVersion": 1,
  "designSchemaVersion": 2,
  "capabilities": [
    "live-preview",
    "copy-prompt",
    "get-code"
  ],
  "reusePolicy": "construction-reuse",
  "urls": {
    "ja": "https://design-vault.pages.dev/designs/motion-turntable",
    "en": "https://design-vault.pages.dev/en/designs/motion-turntable",
    "json": "https://design-vault.pages.dev/ai/assets/motion-turntable.json",
    "designJson": null
  }
}