{"$schema":"https://ui.shadcn.com/schema/registry-item.json","name":"cast-iron-bench-vice-lock-switch-with-a-tommy-bar-that-winds-the-jaws-shut-on-an-oak-block","type":"registry:component","title":"Cast Iron Bench Vice Lock Switch with a Tommy Bar That Winds the Jaws Shut on an Oak Block","description":"On/off switch drawn as a blue engineer's vice: switching on winds the jaw along its slide until it bites an oak block. Free React code and HTML to copy.","dependencies":[],"files":[{"path":"components/we-inc/cast-iron-bench-vice-lock-switch-with-a-tommy-bar-that-winds-the-jaws-shut-on-an-oak-block.tsx","type":"registry:component","content":"import { useEffect, useRef, useState } from \"react\";\nimport type { MouseEvent as ReactMouseEvent } from \"react\";\n\n// What the switch controls, and the line shown for each state.\nconst LABEL = \"Lock layout\";\nconst NOTES = { on: \"Clamped. Nothing moves until the jaws open.\", off: \"Open. Sections can be dragged around the page.\" };\nconst START_ON = true;\nconst DEMO = true; // the vice opens and shuts by itself when idle. Set to false for a real setting.\nconst PAINT = [\"#79a8ee\", \"#2d63b6\", \"#143568\"]; // enamel: lit, body, shaded\nconst TURNS = 3.25; // turns of the bar from fully open to biting\nconst OPEN = 96; // jaw gap when open\nconst BLOCK = 54; // width of the oak block the jaws close on\n\nexport default function CastIronBenchViceSwitch() {\n  const canvas = useRef<HTMLCanvasElement>(null);\n  const pad = useRef<HTMLButtonElement>(null);\n  const [on, setOn] = useState(START_ON);\n  const api = useRef<{ toggle: () => void } | null>(null);\n\n  useEffect(() => {\n    const cv = canvas.current, btn = pad.current;\n    if (!cv || !btn) return;\n    const ctx = cv.getContext(\"2d\");\n    if (!ctx) return;\n    const reduce = window.matchMedia(\"(prefers-reduced-motion: reduce)\").matches;\n    const dpr = Math.min(2, window.devicePixelRatio || 1);\n    let W = 0, H = 0, k = 1, ox = 0, oy = 0;\n\n    let seed = 23;\n    const rnd = () => { seed = (seed * 16807) % 2147483647; return seed / 2147483647; };\n    // Hammered enamel: small pools of lighter and darker paint.\n    const ham = document.createElement(\"canvas\");\n    ham.width = ham.height = 220;\n    const hx2 = ham.getContext(\"2d\");\n    if (hx2) for (let i = 0; i < 3200; i++) {\n      const x = rnd() * 220, y = rnd() * 220, r = 0.5 + rnd() * 2.1, light = rnd() > 0.5;\n      for (const [dx, dy] of [[0, 0], [220, 0], [0, 220], [-220, 0], [0, -220]]) {\n        hx2.beginPath(); hx2.ellipse(x + dx, y + dy, r, r * (0.6 + rnd() * 0.4), rnd() * 3, 0, Math.PI * 2);\n        hx2.fillStyle = light ? `rgba(190,220,255,${0.04 + rnd() * 0.1})` : `rgba(0,10,40,${0.04 + rnd() * 0.11})`; hx2.fill();\n      }\n    }\n    const hammer = ctx.createPattern(ham, \"repeat\");\n    const grainA = Array.from({ length: 40 }, () => rnd());\n\n    const s = { p: START_ON ? (DEMO ? 0.8 : 1) : 0, v: 0, target: START_ON ? (DEMO ? 0.8 : 1) : 0, on: START_ON, drag: false, raw: 0, jolt: 0, joltV: 0 };\n\n    const layout = () => {\n      W = cv.clientWidth; H = cv.clientHeight;\n      k = Math.min(W / 560, H / 318, 1.75);\n      ox = W / 2 - 292 * k; oy = H / 2 - 266 * k;\n      cv.width = Math.round(W * dpr); cv.height = Math.round(H * dpr);\n    };\n\n    const rr = (x: number, y: number, w: number, h: number, r: number) => {\n      ctx.beginPath(); ctx.moveTo(x + r, y); ctx.arcTo(x + w, y, x + w, y + h, r); ctx.arcTo(x + w, y + h, x, y + h, r);\n      ctx.arcTo(x, y + h, x, y, r); ctx.arcTo(x, y, x + w, y, r); ctx.closePath();\n    };\n    const glow = (blur: number, dx: number, dy: number, a: number) => { ctx.shadowColor = `rgba(0,0,0,${a})`; ctx.shadowBlur = blur * dpr * k; ctx.shadowOffsetX = dx * dpr * k; ctx.shadowOffsetY = dy * dpr * k; };\n\n    // Painted iron: a body gradient, the hammered texture, then soft light on the upper edges and shade on the lower.\n    const casting = (build: () => void, g: number[]) => {\n      const grad = ctx.createLinearGradient(g[0], g[1], g[2], g[3]);\n      grad.addColorStop(0, PAINT[0]); grad.addColorStop(0.32, PAINT[1]); grad.addColorStop(1, PAINT[2]);\n      build(); ctx.fillStyle = grad; ctx.fill();\n      ctx.save(); ctx.clip();\n      if (hammer) { ctx.fillStyle = hammer; ctx.fillRect(-200, 100, 900, 320); }\n      // Wet-look gloss where the lamp sits on the enamel.\n      const gl = ctx.createRadialGradient(g[0] + 14, g[1] + 22, 2, g[0] + 14, g[1] + 22, 74);\n      gl.addColorStop(0, \"rgba(235,245,255,0.5)\"); gl.addColorStop(0.35, \"rgba(235,245,255,0.12)\"); gl.addColorStop(1, \"rgba(235,245,255,0)\");\n      ctx.fillStyle = gl; ctx.fillRect(-200, 100, 900, 320);\n      ctx.lineJoin = \"round\";\n      ctx.translate(1.3, 2.4); build();\n      ctx.lineWidth = 9; ctx.strokeStyle = \"rgba(210,232,255,0.12)\"; ctx.stroke();\n      ctx.lineWidth = 2; ctx.strokeStyle = \"rgba(225,240,255,0.55)\"; ctx.stroke();\n      ctx.translate(-2.8, -5.2); build();\n      ctx.lineWidth = 12; ctx.strokeStyle = \"rgba(2,10,30,0.2)\"; ctx.stroke();\n      ctx.lineWidth = 2.4; ctx.strokeStyle = \"rgba(2,10,30,0.5)\"; ctx.stroke();\n      ctx.restore();\n      build(); ctx.lineWidth = 0.9; ctx.strokeStyle = \"rgba(2,6,16,0.7)\"; ctx.stroke();\n    };\n    // Bright steel bar lying left to right.\n    const bar = (x: number, y: number, w: number, h: number, r = 1.5) => {\n      const g = ctx.createLinearGradient(0, y, 0, y + h);\n      g.addColorStop(0, \"#5d636b\"); g.addColorStop(0.14, \"#dfe3e7\"); g.addColorStop(0.3, \"#ffffff\"); g.addColorStop(0.52, \"#b4bac1\"); g.addColorStop(0.84, \"#676d76\"); g.addColorStop(1, \"#33373d\");\n      rr(x, y, w, h, r); ctx.fillStyle = g; ctx.fill(); ctx.lineWidth = 0.8; ctx.strokeStyle = \"rgba(4,6,10,0.9)\"; ctx.stroke();\n    };\n    const ball = (x: number, y: number, r: number) => {\n      const g = ctx.createRadialGradient(x - r * 0.38, y - r * 0.42, r * 0.08, x, y, r);\n      g.addColorStop(0, \"#ffffff\"); g.addColorStop(0.22, \"#e2e6ea\"); g.addColorStop(0.6, \"#8d949d\"); g.addColorStop(0.88, \"#3f444b\"); g.addColorStop(1, \"#6d737b\");\n      ctx.beginPath(); ctx.arc(x, y, r, 0, Math.PI * 2); ctx.fillStyle = g; ctx.fill(); ctx.lineWidth = 0.8; ctx.strokeStyle = \"rgba(4,6,10,0.9)\"; ctx.stroke();\n    };\n    const plate = (x: number) => {\n      const g = ctx.createLinearGradient(x, 0, x + 8, 0);\n      g.addColorStop(0, \"#f3f5f7\"); g.addColorStop(0.4, \"#b9bec5\"); g.addColorStop(1, \"#5a6068\");\n      rr(x, 173, 8, 40, 1); ctx.fillStyle = g; ctx.fill(); ctx.lineWidth = 0.8; ctx.strokeStyle = \"rgba(4,6,10,0.9)\"; ctx.stroke();\n      for (let y = 176; y < 211; y += 2.2) { ctx.fillStyle = \"rgba(10,14,20,0.4)\"; ctx.fillRect(x + 0.6, y, 6.8, 0.7); }\n      ctx.fillStyle = \"rgba(255,255,255,0.8)\"; ctx.fillRect(x + 0.6, 173.6, 6.8, 0.9);\n    };\n    const bolt = (x: number) => {\n      rr(x - 15, 334, 30, 4, 1); ctx.fillStyle = \"#7d838b\"; ctx.fill(); ctx.lineWidth = 0.7; ctx.strokeStyle = \"rgba(4,6,10,0.9)\"; ctx.stroke();\n      const g = ctx.createLinearGradient(x - 11, 0, x + 11, 0);\n      g.addColorStop(0, \"#8f959d\"); g.addColorStop(0.27, \"#9aa0a8\"); g.addColorStop(0.28, \"#eef0f3\"); g.addColorStop(0.7, \"#c6cbd1\"); g.addColorStop(0.71, \"#6c727a\"); g.addColorStop(1, \"#484d55\");\n      rr(x - 11, 323, 22, 11, 1.5); ctx.fillStyle = g; ctx.fill(); ctx.stroke();\n      ctx.fillStyle = \"rgba(255,255,255,0.7)\"; ctx.fillRect(x - 10, 323.7, 20, 0.9);\n    };\n\n    const fixedBody = () => {\n      ctx.beginPath(); ctx.moveTo(308, 172); ctx.lineTo(348, 172); ctx.quadraticCurveTo(362, 172, 366, 187); ctx.lineTo(371, 206); ctx.lineTo(450, 206);\n      ctx.quadraticCurveTo(464, 206, 464, 220); ctx.lineTo(462, 238); ctx.quadraticCurveTo(458, 268, 448, 292); ctx.quadraticCurveTo(442, 318, 452, 338);\n      ctx.lineTo(490, 338); ctx.quadraticCurveTo(502, 338, 502, 349); ctx.lineTo(502, 360); ctx.lineTo(228, 360); ctx.lineTo(228, 349); ctx.quadraticCurveTo(228, 338, 240, 338);\n      ctx.lineTo(272, 338); ctx.quadraticCurveTo(298, 322, 300, 292); ctx.lineTo(300, 222); ctx.lineTo(308, 222); ctx.closePath();\n    };\n    const movingBody = () => {\n      ctx.beginPath(); ctx.moveTo(292, 172); ctx.lineTo(254, 172); ctx.quadraticCurveTo(238, 172, 233, 190); ctx.lineTo(226, 224); ctx.quadraticCurveTo(218, 230, 218, 240);\n      ctx.lineTo(218, 278); ctx.quadraticCurveTo(218, 288, 228, 288); ctx.lineTo(282, 288); ctx.quadraticCurveTo(292, 288, 292, 278); ctx.closePath();\n    };\n\n    const draw = () => {\n      ctx.setTransform(dpr, 0, 0, dpr, 0, 0);\n      ctx.clearRect(0, 0, W, H);\n      ctx.translate(ox + s.jolt * k, oy); ctx.scale(k, k);\n      const p = s.p, gap = OPEN - Math.min(p, 1.02) * (OPEN - BLOCK), th = p * TURNS * Math.PI * 2 + 0.5;\n\n      // The bench block the vice is bolted to.\n      ctx.save(); glow(34, 0, 26, 0.7); rr(44, 362, 496, 40, 5); ctx.fillStyle = \"#1d130b\"; ctx.fill(); ctx.restore();\n      const wood = ctx.createLinearGradient(0, 360, 0, 404);\n      wood.addColorStop(0, \"#c08d58\"); wood.addColorStop(0.08, \"#93663c\"); wood.addColorStop(0.55, \"#6b4626\"); wood.addColorStop(1, \"#3a2513\");\n      rr(40, 360, 504, 44, 5); ctx.fillStyle = wood; ctx.fill();\n      ctx.save(); ctx.clip();\n      for (let i = 0; i < 16; i++) {\n        const y = 363 + i * 2.6 + grainA[i] * 1.6;\n        ctx.beginPath(); ctx.moveTo(40, y);\n        for (let x = 40; x <= 544; x += 42) ctx.lineTo(x, y + Math.sin(x * 0.011 + grainA[i + 16] * 9) * 1.5);\n        ctx.lineWidth = 0.5 + grainA[i + 8] * 0.9; ctx.strokeStyle = grainA[i] > 0.4 ? `rgba(30,16,6,${0.2 + grainA[i] * 0.3})` : \"rgba(240,200,150,0.14)\"; ctx.stroke();\n      }\n      ctx.fillStyle = \"rgba(255,226,180,0.55)\"; ctx.fillRect(40, 360, 504, 1.2);\n      const foot = ctx.createLinearGradient(0, 360, 0, 367);\n      foot.addColorStop(0, \"rgba(0,0,0,0.5)\"); foot.addColorStop(1, \"rgba(0,0,0,0)\");\n      ctx.fillStyle = foot; ctx.fillRect(229, 360, 272, 7);\n      ctx.restore();\n      rr(40, 360, 504, 44, 5); ctx.lineWidth = 1; ctx.strokeStyle = \"rgba(10,6,2,0.9)\"; ctx.stroke();\n\n      // The slide the front jaw rides on, and the oak block standing on it.\n      ctx.save(); glow(10, 0, 6, 0.5); bar(300 - gap - 30, 238, gap + 60, 34, 2); ctx.restore();\n      ctx.fillStyle = \"rgba(10,14,20,0.35)\"; ctx.fillRect(300 - gap - 30, 253, gap + 60, 1);\n      const bw = BLOCK - Math.max(0, p - 1) * 30, bx0 = 300 - bw;\n      const oak = ctx.createLinearGradient(bx0, 0, bx0 + bw, 0);\n      oak.addColorStop(0, \"#c99555\"); oak.addColorStop(0.2, \"#e3b877\"); oak.addColorStop(0.7, \"#d3a463\"); oak.addColorStop(1, \"#a97a41\");\n      ctx.save(); glow(8, 3, 2, 0.5); ctx.beginPath(); ctx.rect(bx0, 136, bw, 102); ctx.fillStyle = oak; ctx.fill(); ctx.restore();\n      ctx.save(); ctx.beginPath(); ctx.rect(bx0, 136, bw, 102); ctx.clip();\n      for (let i = 0; i < 20; i++) {\n        const x = bx0 + (i / 20) * bw + grainA[i] * 2;\n        ctx.beginPath(); ctx.moveTo(x, 136);\n        for (let y = 136; y <= 238; y += 17) ctx.lineTo(x + Math.sin(y * 0.03 + grainA[i + 20] * 8) * 1.6, y);\n        ctx.lineWidth = 0.4 + grainA[i + 10] * 1.1; ctx.strokeStyle = `rgba(110,66,20,${0.12 + grainA[i] * 0.3})`; ctx.stroke();\n      }\n      const top = ctx.createLinearGradient(0, 136, 0, 150);\n      top.addColorStop(0, \"rgba(255,240,205,0.75)\"); top.addColorStop(0.16, \"rgba(255,240,205,0.12)\"); top.addColorStop(1, \"rgba(255,240,205,0)\");\n      ctx.fillStyle = top; ctx.fillRect(bx0, 136, bw, 14);\n      // Carpenter's pencil: a cut line and the tick that says which side is waste.\n      ctx.strokeStyle = \"rgba(40,36,34,0.7)\"; ctx.lineWidth = 0.9; ctx.beginPath(); ctx.moveTo(bx0, 156); ctx.lineTo(bx0 + bw, 155.4); ctx.stroke();\n      ctx.beginPath(); ctx.moveTo(bx0 + bw * 0.42, 150); ctx.lineTo(bx0 + bw * 0.5, 155.6); ctx.lineTo(bx0 + bw * 0.62, 143); ctx.stroke();\n      ctx.restore();\n      ctx.beginPath(); ctx.rect(bx0, 136, bw, 102); ctx.lineWidth = 0.8; ctx.strokeStyle = \"rgba(50,28,6,0.85)\"; ctx.stroke();\n\n      // Back jaw, anvil and foot: one casting.\n      ctx.save(); glow(16, 5, 9, 0.5); fixedBody(); ctx.fillStyle = PAINT[2]; ctx.fill(); ctx.restore();\n      casting(fixedBody, [300, 170, 470, 372]);\n      bar(373, 203.5, 76, 5, 1.5);\n      // A recessed panel with the size cast into it.\n      rr(318, 242, 112, 40, 6); ctx.lineWidth = 2.4; ctx.strokeStyle = \"rgba(2,10,30,0.45)\"; ctx.stroke();\n      rr(319, 243.4, 112, 40, 6); ctx.lineWidth = 1; ctx.strokeStyle = \"rgba(200,225,255,0.4)\"; ctx.stroke();\n      ctx.font = \"800 23px ui-sans-serif, system-ui, Helvetica, Arial, sans-serif\"; ctx.textAlign = \"center\"; ctx.textBaseline = \"middle\";\n      ctx.fillStyle = \"rgba(2,10,30,0.6)\"; ctx.fillText(\"No. 4\", 375.2, 264.6);\n      ctx.fillStyle = \"rgba(215,232,255,0.7)\"; ctx.fillText(\"No. 4\", 373.1, 262.1);\n      ctx.fillStyle = PAINT[1]; ctx.fillText(\"No. 4\", 374, 263.2);\n      bolt(250); bolt(477);\n      plate(300);\n\n      // Front jaw: it and everything on it move together.\n      ctx.save(); ctx.translate(-gap, 0);\n      ctx.save(); glow(14, 4, 8, 0.5); movingBody(); ctx.fillStyle = PAINT[2]; ctx.fill(); ctx.restore();\n      casting(movingBody, [226, 168, 300, 300]);\n      plate(292);\n      // The tommy bar tumbles through the screw head: the far half is drawn first, the near half last.\n      const hx = 190, hy = 256, R = 78, c = Math.cos(th), z = Math.sin(th);\n      const half = (sign: number) => {\n        const ey = hy - sign * R * c, depth = sign * z, w = 9.5 * (1 + depth * 0.1);\n        const g = ctx.createLinearGradient(hx - w / 2, 0, hx + w / 2, 0);\n        g.addColorStop(0, \"#565c64\"); g.addColorStop(0.3, \"#ffffff\"); g.addColorStop(0.55, \"#b6bcc3\"); g.addColorStop(1, \"#3a3f46\");\n        ctx.save(); glow(8, 5, 5, 0.45);\n        ctx.beginPath(); ctx.rect(hx - w / 2, Math.min(hy, ey), w, Math.abs(ey - hy)); ctx.fillStyle = g; ctx.fill();\n        ball(hx, ey, 10.5 * (1 + depth * 0.14)); ctx.restore();\n      };\n      half(z >= 0 ? -1 : 1);\n      bar(202, 242, 17, 30, 2);\n      bar(176, 245, 27, 24, 5);\n      ctx.beginPath(); ctx.ellipse(hx, hy, 5.2, 6.6, 0, 0, Math.PI * 2); ctx.fillStyle = \"rgba(6,8,12,0.75)\"; ctx.fill();\n      half(z >= 0 ? 1 : -1);\n      ctx.restore();\n    };\n\n    let raf = 0, last = 0, t0 = 0, seen = true, touched = -1e9, demoAt = 450;\n    const flip = (next: boolean) => { if (s.on !== next) { s.on = next; setOn(next); } };\n    const frame = (now: number) => {\n      raf = 0;\n      if (!t0) { t0 = now; last = now; }\n      const dt = Math.min(0.033, (now - last) / 1000); last = now;\n      const t = now - t0;\n      if (DEMO && now - touched > 6000 && !s.drag && t > demoAt) {\n        if (s.target > 0.5 && s.target < 1) { s.target = 1; demoAt = t + 4300; }\n        else { s.target = s.target === 1 ? 0 : 1; flip(s.target === 1); demoAt = t + (s.target === 1 ? 4300 : 2400); }\n      }\n      const was = s.p;\n      if (s.drag) { const np = s.p + (s.raw - s.p) * Math.min(1, dt * 26); s.v = (np - s.p) / Math.max(dt, 0.001); s.p = np; }\n      else {\n        // Winding takes a moment: the spring that drives it is speed-limited like a hand on the bar.\n        s.v += (70 * (s.target - s.p) - 15 * s.v) * dt; s.v = Math.max(-1.25, Math.min(1.25, s.v)); s.p += s.v * dt;\n      }\n      if (was < 1 && s.p >= 1) { s.joltV += 55 + Math.abs(s.v) * 60; if (!s.drag) { s.p = 1 + Math.min(0.02, s.v * 0.012); s.v *= -0.2; } }\n      s.joltV += (-900 * s.jolt - 34 * s.joltV) * dt; s.jolt += s.joltV * dt;\n      draw();\n      if (seen && !document.hidden) raf = requestAnimationFrame(frame);\n    };\n    const wake = () => { if (!raf && !reduce) { last = performance.now(); raf = requestAnimationFrame(frame); } };\n    const still = () => { if (!s.drag) s.p = s.target; s.v = 0; s.jolt = 0; draw(); };\n\n    api.current = { toggle: () => { touched = performance.now(); const next = !s.on; flip(next); s.target = next ? 1 : 0; if (reduce) still(); else wake(); } };\n    layout();\n    if (reduce) { s.p = s.target = START_ON ? 1 : 0; still(); } else wake();\n\n    let startX = 0, startP = 0, moved = 0;\n    const onDown = (e: PointerEvent) => { touched = performance.now(); s.drag = true; startX = e.clientX; startP = s.p; s.raw = s.p; moved = 0; btn.setPointerCapture(e.pointerId); wake(); };\n    const onMove = (e: PointerEvent) => {\n      if (!s.drag) return;\n      touched = performance.now(); moved = Math.max(moved, Math.abs(e.clientX - startX));\n      let p = startP + (e.clientX - startX) / (150 * k);\n      if (p > 1) p = 1 + (p - 1) * 0.04; // the block does not give\n      s.raw = Math.max(0, p);\n      if (reduce) { s.p = Math.min(1, s.raw); draw(); }\n    };\n    const onUp = () => {\n      if (!s.drag) return;\n      s.drag = false; touched = performance.now();\n      const next = moved < 5 ? !s.on : s.p > 0.6; // a tap toggles, a drag decides by where the jaw was left\n      flip(next); s.target = next ? 1 : 0;\n      if (reduce) still();\n    };\n    btn.addEventListener(\"pointerdown\", onDown);\n    btn.addEventListener(\"pointermove\", onMove);\n    btn.addEventListener(\"pointerup\", onUp);\n    btn.addEventListener(\"pointercancel\", onUp);\n    const ro = new ResizeObserver(() => { layout(); if (reduce) still(); else { draw(); wake(); } });\n    ro.observe(cv);\n    const io = new IntersectionObserver(([entry]) => { seen = entry.isIntersecting; if (seen) wake(); });\n    io.observe(cv);\n    const onVis = () => { if (!document.hidden) wake(); };\n    document.addEventListener(\"visibilitychange\", onVis);\n    return () => {\n      cancelAnimationFrame(raf); api.current = null;\n      btn.removeEventListener(\"pointerdown\", onDown); btn.removeEventListener(\"pointermove\", onMove);\n      btn.removeEventListener(\"pointerup\", onUp); btn.removeEventListener(\"pointercancel\", onUp);\n      ro.disconnect(); io.disconnect(); document.removeEventListener(\"visibilitychange\", onVis);\n    };\n  }, []);\n\n  // Pointer taps are handled on release above; this catches Enter and Space, which arrive as a click with no detail.\n  const onClick = (e: ReactMouseEvent) => { if (e.detail === 0) api.current?.toggle(); };\n\n  return (\n    <div className=\"flex min-h-[600px] w-full flex-col items-center justify-center bg-[#0f1013] bg-[radial-gradient(80%_60%_at_50%_40%,#2a2c33_0%,#16171b_48%,#0f1013_100%)] px-3 py-10 sm:min-h-[760px] sm:px-8\">\n      <div className=\"relative w-full max-w-[940px]\">\n        <canvas ref={canvas} aria-hidden=\"true\" className=\"block h-[270px] w-full sm:h-[560px]\" />\n        <button\n          ref={pad}\n          type=\"button\"\n          role=\"switch\"\n          aria-checked={on}\n          aria-label={LABEL}\n          aria-describedby=\"bench-vice-switch-note\"\n          onClick={onClick}\n          className=\"absolute inset-0 cursor-grab touch-pan-y select-none rounded-3xl outline-none focus-visible:ring-2 focus-visible:ring-[#79a8ee] active:cursor-grabbing\"\n        />\n      </div>\n      <p id=\"bench-vice-switch-note\" aria-live=\"polite\" className=\"mt-2 max-w-[440px] text-center font-mono text-[11px] uppercase leading-5 tracking-[0.16em] text-zinc-400\">\n        <span className=\"text-zinc-100\">{LABEL}</span>\n        <span className=\"mx-2 text-zinc-600\">/</span>\n        <span className=\"text-zinc-100\">{on ? \"On\" : \"Off\"}</span>\n        <br />\n        {on ? NOTES.on : NOTES.off}\n      </p>\n    </div>\n  );\n}\n"}]}
