/qadri-3d:web3d-model-viewerfrom qadri-3d
Embedding 3D products with the ‹model-viewer› web component instead of three.js: AR on iOS and Android, posters, hotspots, variants, material edits. Use for product pages and to decide model-viewer versus three.js. Routes to `threejs-model-inspect`.
Ships in qadri-3d. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
Read when SKILL.md points to them.
<model-viewer> or three.js?<model-viewer> (@google/model-viewer 4.4, Apache-2.0) is one HTML element that shows a glTF with orbit controls,
good default lighting, lazy loading, accessibility, and one-tap AR on Android (Scene Viewer, WebXR) and iOS (Quick
Look). For a product page it is usually the right answer, and hand-written three.js is more code for a worse
result. Decide first:
| Need | Use |
|---|---|
| Show a product, rotate it, view it in AR, swap colors | <model-viewer> |
| Hotspot labels on parts, a few camera presets, play a clip | <model-viewer> |
| Custom shaders, post-processing, physics, many models in one scene, games | three.js or R3F |
| Scroll-driven camera flights | three.js (threejs-scroll) |
Inspect and optimize the model first (threejs-model-inspect, then threejs-model-optimize with web or
configurator). model-viewer decodes Draco, meshopt and KTX2 by itself.
Add the element, from the CDN or npm i @google/model-viewer (import "@google/model-viewer";):
<script type="module" src="https://cdn.jsdelivr.net/npm/@google/[email protected]/dist/model-viewer.min.js"></script>
<model-viewer src="/models/chair.glb" alt="Oak lounge chair, three-quarter view" poster="/models/chair.webp"
camera-controls touch-action="pan-y" shadow-intensity="1" tone-mapping="commerce" ar ar-modes="webxr scene-viewer quick-look"
style="width: 100%; height: 480px"></model-viewer>
alt is required for accessibility; poster shows instantly while the model loads; loading="lazy" (default
auto) defers offscreen models. tone-mapping="commerce" keeps product colors faithful. Size it with CSS; it
has no intrinsic size.
Add features from references/recipes.md as needed: AR setup, hotspots, variants and material colors, camera
presets, animation, events.
Test AR on a real phone of each platform; desktop shows only the button logic.
poster: the area stays blank until a multi-megabyte model arrives..glb alone in old Safari versions; provide ios-src with a USDZ when Quick Look
rejects the generated file.touch-action left at its default on mobile pages that must scroll past the model; set pan-y.Next: threejs-model-inspect before any model goes into the element.
What SKILL.md sets; muted values are Claude Code's defaults
npx claudepluginhub qadri-uk/claude-skills --plugin qadri-3d71 skills in this plugin
/360-product-spinAdd a 360° product spin (a draggable image sequence) to a product page, and produce the frames by photographing the product on a turntable or rendering a 3D model with three.js. Use when the user wants a 360 view, a spin or rotating product photos, "turn the product around", a 360 product viewer, sprite sheets for product rotation, or has product photos but no 3D model. Uses the zero-dependency Spin360 web component./3d-3d-cloth-materialBuild convincing woven cloth in Three.js, with a thread-level weave normal map, sheen and anisotropic highlights, folds that never stretch the texture, hems with thickness, stitches, seams, frayed edges, fold occlusion, dye and wear variation, and light passing through thin fabric. Use for linen, silk, wool, canvas, curtains, banners, cloaks, tablecloths, tapestries or any 3D drape that currently looks like a plastic sheet, a stretched texture, or a flat coloured plane./3d-3d-falling-leavesBuild recognizable falling leaves in world space using instanced geometry, independent tumble, coupled sideways drift, shared wind, scene occlusion, and camera-aware recycling. Use for 3D autumn leaves or drifting foliage in Three.js and similar scenes; use falling-leaves for a 2D canvas overlay.Other plugins' skills for the same job