@displayxr/inline3d-tools 0.0.1 → 0.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,29 @@
1
+ <!doctype html>
2
+ <html lang="en">
3
+ <head>
4
+ <meta charset="utf-8">
5
+ <meta name="viewport" content="width=device-width, initial-scale=1">
6
+ <title>__TITLE__</title>
7
+ <link rel="stylesheet" href="./style.css">
8
+ <!-- Exact pins. Bump them together, and only after reading the SDK CHANGELOG. -->
9
+ <script type="importmap">
10
+ { "imports": {
11
+ "three": "https://cdn.jsdelivr.net/npm/three@0.180.0/build/three.module.js",
12
+ "three/addons/": "https://cdn.jsdelivr.net/npm/three@0.180.0/examples/jsm/",
13
+ "@displayxr/inline3d": "https://cdn.jsdelivr.net/npm/@displayxr/inline3d@1.52.3/js/inline3d.js",
14
+ "@displayxr/inline3d/three": "https://cdn.jsdelivr.net/npm/@displayxr/inline3d@1.52.3/js/inline3d-three.js"
15
+ } }
16
+ </script>
17
+ </head>
18
+ <body>
19
+ <main>
20
+ <h1>__TITLE__</h1>
21
+ <div class="stage">
22
+ <canvas id="stage"></canvas>
23
+ <div id="cover">loading…</div>
24
+ </div>
25
+ <p id="status">starting…</p>
26
+ </main>
27
+ <script type="module" src="./app.js"></script>
28
+ </body>
29
+ </html>
@@ -0,0 +1,17 @@
1
+ /* Page styles for the inline-3D template. The woven canvas and its ancestors carry NO filter,
2
+ opacity < 1, mask, clip-path, blend mode, backdrop-filter, scale/rotate transform, border,
3
+ border-radius or box-shadow: any of those breaks or distorts the weave. */
4
+ :root { color-scheme: light; --bg: #e7e4de; --ink: #23262b; }
5
+ html, body { margin: 0; background: var(--bg); color: var(--ink); font: 16px/1.6 system-ui, -apple-system, "Segoe UI", sans-serif; }
6
+ main { max-width: 880px; margin: 0 auto; padding: 32px 16px 64px; }
7
+ h1 { font-size: 28px; margin: 0 0 6px; }
8
+
9
+ /* The stage: the canvas box is the shape the viewer sees (here 16:9). */
10
+ .stage { position: relative; width: 100%; max-width: 840px; aspect-ratio: 16 / 9; }
11
+ #stage { display: block; width: 100%; height: 100%; will-change: transform; } /* a compositor layer from the first paint */
12
+
13
+ /* The cover sits ON TOP of the canvas (never behind) and is removed with a hard cut, never faded. */
14
+ #cover { position: absolute; inset: 0; background: var(--bg); display: grid; place-items: center; font-size: 14px; opacity: 1; }
15
+
16
+ /* Text stays HTML, next to (or partially over) the tile, at a readable size. */
17
+ #status { margin: 8px 0 0; font-size: 14px; color: #555b63; }
@@ -0,0 +1,20 @@
1
+ <!doctype html>
2
+ <html lang="en">
3
+ <head>
4
+ <meta charset="utf-8">
5
+ <meta name="viewport" content="width=device-width, initial-scale=1">
6
+ <title>__TITLE__</title>
7
+ <link rel="stylesheet" href="/style.css">
8
+ </head>
9
+ <body>
10
+ <main>
11
+ <h1>__TITLE__</h1>
12
+ <div class="stage">
13
+ <canvas id="stage"></canvas>
14
+ <div id="cover">loading…</div>
15
+ </div>
16
+ <p id="status">starting…</p>
17
+ </main>
18
+ <script type="module" src="/app.js"></script>
19
+ </body>
20
+ </html>
@@ -0,0 +1,18 @@
1
+ {
2
+ "name": "__NAME__",
3
+ "private": true,
4
+ "version": "0.1.0",
5
+ "type": "module",
6
+ "scripts": {
7
+ "dev": "vite",
8
+ "build": "vite build",
9
+ "preview": "vite preview"
10
+ },
11
+ "dependencies": {
12
+ "@displayxr/inline3d": "1.52.3",
13
+ "three": "0.180.0"
14
+ },
15
+ "devDependencies": {
16
+ "vite": "6.3.5"
17
+ }
18
+ }