@wave3d/element 0.8.0 → 0.9.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.
package/dist/index.d.ts CHANGED
@@ -1,4 +1,4 @@
1
- import { FallbackReason, SnapshotOptions, StudioConfig, StudioConfig as StudioConfig$1, WaveHandle, WaveHandle as WaveHandle$1, WaveRenderer } from "@wave3d/core";
1
+ import { FallbackReason, SnapshotOptions, StudioConfig, StudioConfig as StudioConfig$1, TiltStatus, WaveHandle, WaveHandle as WaveHandle$1, WaveRenderer } from "@wave3d/core";
2
2
  //#region src/index.d.ts
3
3
  declare const ElementBase: typeof HTMLElement;
4
4
  /**
@@ -13,6 +13,18 @@ declare class Wave3DElement extends ElementBase {
13
13
  static get observedAttributes(): string[];
14
14
  /** The live shell handle (null before connect / after disconnect). */
15
15
  get handle(): WaveHandle$1 | null;
16
+ /**
17
+ * Explicitly ask for the device-orientation sensor. OPTIONAL, and on iOS it opens a modal
18
+ * permission dialog — nothing calls it for you, and a decorative scene should simply go without
19
+ * tilt there. CALL IT FROM A USER GESTURE (iOS grants the sensor only from inside a tap handler)
20
+ * and only once `wave3d-ready` has fired — before that there is no renderer to ask, and the replayed
21
+ * request has left the gesture.
22
+ */
23
+ enableTilt(): Promise<boolean>;
24
+ /** Where the tilt sensor stands. `"prompt"` is exactly when a tap-to-enable affordance helps. */
25
+ tiltStatus(): TiltStatus;
26
+ /** Take the next orientation reading as the neutral pose (the reader has changed grip). */
27
+ recenterTilt(): void;
16
28
  /** Programmatic config, merged last (over the `preset`/`src`/`config` attributes). */
17
29
  get config(): Partial<StudioConfig$1>;
18
30
  set config(value: Partial<StudioConfig$1>);
package/dist/index.js CHANGED
@@ -8,7 +8,8 @@ const OBSERVED = [
8
8
  "poster-fit",
9
9
  "paused",
10
10
  "lazy",
11
- "webgl"
11
+ "webgl",
12
+ "backend"
12
13
  ];
13
14
  const ElementBase = typeof HTMLElement !== "undefined" ? HTMLElement : function Wave3DElementBase() {};
14
15
  /**
@@ -29,6 +30,24 @@ var Wave3DElement = class extends ElementBase {
29
30
  get handle() {
30
31
  return this.#handle;
31
32
  }
33
+ /**
34
+ * Explicitly ask for the device-orientation sensor. OPTIONAL, and on iOS it opens a modal
35
+ * permission dialog — nothing calls it for you, and a decorative scene should simply go without
36
+ * tilt there. CALL IT FROM A USER GESTURE (iOS grants the sensor only from inside a tap handler)
37
+ * and only once `wave3d-ready` has fired — before that there is no renderer to ask, and the replayed
38
+ * request has left the gesture.
39
+ */
40
+ enableTilt() {
41
+ return this.#handle?.enableTilt() ?? Promise.resolve(false);
42
+ }
43
+ /** Where the tilt sensor stands. `"prompt"` is exactly when a tap-to-enable affordance helps. */
44
+ tiltStatus() {
45
+ return this.#handle?.tiltStatus() ?? "prompt";
46
+ }
47
+ /** Take the next orientation reading as the neutral pose (the reader has changed grip). */
48
+ recenterTilt() {
49
+ this.#handle?.recenterTilt();
50
+ }
32
51
  /** Programmatic config, merged last (over the `preset`/`src`/`config` attributes). */
33
52
  get config() {
34
53
  return this.#config;
@@ -60,6 +79,7 @@ var Wave3DElement = class extends ElementBase {
60
79
  posterFit: this.getAttribute("poster-fit") ?? void 0,
61
80
  lazy: this.#boolAttr("lazy"),
62
81
  webgl: this.getAttribute("webgl") ?? void 0,
82
+ backend: this.getAttribute("backend") ?? void 0,
63
83
  paused: this.#boolAttr("paused"),
64
84
  onReady: (renderer) => this.dispatchEvent(new CustomEvent("wave3d-ready", { detail: renderer })),
65
85
  onFallback: (reason) => this.dispatchEvent(new CustomEvent("wave3d-fallback", { detail: reason }))
package/dist/index.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","names":["#handle","#config","#scheduleUpdate","#mount","#debounce","#boolAttr","#buildConfig","#update"],"sources":["../src/index.ts"],"sourcesContent":["import { createWave } from \"@wave3d/core\";\nimport type {\n StudioConfig,\n WaveHandle,\n WaveOptions,\n WaveRenderer,\n FallbackReason,\n} from \"@wave3d/core\";\n\nconst OBSERVED = [\n \"config\",\n \"src\",\n \"preset\",\n \"poster\",\n \"poster-fit\",\n \"paused\",\n \"lazy\",\n \"webgl\",\n] as const;\n\n// SSR-safe base: `class extends HTMLElement` evaluates HTMLElement at import time, which throws\n// under Node. Fall back to a dummy base there — the element is never instantiated server-side\n// (register() is guarded), so the missing DOM methods are never called.\nconst ElementBase: typeof HTMLElement =\n typeof HTMLElement !== \"undefined\"\n ? HTMLElement\n : (function Wave3DElementBase() {} as unknown as typeof HTMLElement);\n\n/**\n * `<wave-3d>` — the framework-agnostic drop-in (Vue/Svelte/plain HTML). Light DOM, `display:block`.\n * Attributes: `config` (JSON), `src` (URL to a config JSON), `preset` (name), `poster`,\n * `poster-fit` (`fill` | `cover` | `contain`), `paused`, `lazy`, `webgl`. Also a `config` property\n * and a read-only `handle` getter. Emits `wave3d-ready` (detail = renderer) and `wave3d-fallback`\n * (detail = reason) events.\n */\nexport class Wave3DElement extends ElementBase {\n static get observedAttributes(): string[] {\n return [...OBSERVED];\n }\n\n #handle: WaveHandle | null = null;\n #config: Partial<StudioConfig> = {};\n #debounce?: ReturnType<typeof setTimeout>;\n\n /** The live shell handle (null before connect / after disconnect). */\n get handle(): WaveHandle | null {\n return this.#handle;\n }\n\n /** Programmatic config, merged last (over the `preset`/`src`/`config` attributes). */\n get config(): Partial<StudioConfig> {\n return this.#config;\n }\n set config(value: Partial<StudioConfig>) {\n this.#config = value ?? {};\n this.#scheduleUpdate();\n }\n\n connectedCallback(): void {\n if (!this.style.display) this.style.display = \"block\";\n void this.#mount();\n }\n\n disconnectedCallback(): void {\n clearTimeout(this.#debounce);\n this.#handle?.destroy();\n this.#handle = null;\n }\n\n attributeChangedCallback(name: string): void {\n if (!this.#handle) return;\n if (name === \"paused\") {\n if (this.#boolAttr(\"paused\")) this.#handle.pause();\n else this.#handle.play();\n } else {\n this.#scheduleUpdate();\n }\n }\n\n async #mount(): Promise<void> {\n const config = await this.#buildConfig();\n if (!this.isConnected) return; // disconnected while the config resolved\n const options: WaveOptions = {\n poster: this.getAttribute(\"poster\") ?? undefined,\n posterFit: (this.getAttribute(\"poster-fit\") as WaveOptions[\"posterFit\"]) ?? undefined,\n lazy: this.#boolAttr(\"lazy\"),\n webgl: (this.getAttribute(\"webgl\") as WaveOptions[\"webgl\"]) ?? undefined,\n paused: this.#boolAttr(\"paused\"),\n onReady: (renderer: WaveRenderer) =>\n this.dispatchEvent(new CustomEvent(\"wave3d-ready\", { detail: renderer })),\n onFallback: (reason: FallbackReason) =>\n this.dispatchEvent(new CustomEvent(\"wave3d-fallback\", { detail: reason })),\n };\n this.#handle = createWave(this, config, options);\n }\n\n /** default ← preset ← src JSON ← config attribute ← config property. */\n async #buildConfig(): Promise<Partial<StudioConfig>> {\n let base: Partial<StudioConfig> = {};\n const presetName = this.getAttribute(\"preset\");\n if (presetName) {\n const { PRESETS } = await import(\"@wave3d/core/presets\");\n base = PRESETS[presetName]?.() ?? {};\n }\n const src = this.getAttribute(\"src\");\n if (src) {\n try {\n base = { ...base, ...(await fetch(src).then((r) => r.json())) };\n } catch {\n // ignore a failed/invalid config fetch — fall through to whatever we have\n }\n }\n base = { ...base, ...parseJson(this.getAttribute(\"config\")), ...this.#config };\n return base;\n }\n\n #scheduleUpdate(): void {\n clearTimeout(this.#debounce);\n this.#debounce = setTimeout(() => {\n void this.#update();\n }, 50);\n }\n\n async #update(): Promise<void> {\n const handle = this.#handle;\n if (!handle) return;\n handle.set(await this.#buildConfig());\n }\n\n /** Presence = true; `\"false\"`/`\"0\"` = false; absent = undefined (shell default). */\n #boolAttr(name: string): boolean | undefined {\n if (!this.hasAttribute(name)) return undefined;\n const value = this.getAttribute(name);\n return value !== \"false\" && value !== \"0\";\n }\n}\n\nfunction parseJson(json: string | null): Partial<StudioConfig> {\n if (!json) return {};\n try {\n return JSON.parse(json) as Partial<StudioConfig>;\n } catch {\n return {};\n }\n}\n\n/** Define the element (idempotent, SSR/Node-import-safe). */\nexport function register(tag = \"wave-3d\"): void {\n if (typeof window === \"undefined\" || typeof customElements === \"undefined\") return;\n if (!customElements.get(tag)) customElements.define(tag, Wave3DElement);\n}\n\n// Self-register on import so a bare `import \"@wave3d/element\"` makes <wave-3d> work. Guarded so\n// importing under Node (SSR) is a no-op rather than a ReferenceError.\nregister();\n\nexport type {\n StudioConfig,\n WaveHandle,\n WaveRenderer,\n FallbackReason,\n SnapshotOptions,\n} from \"@wave3d/core\";\n"],"mappings":";;AASA,MAAM,WAAW;CACf;CACA;CACA;CACA;CACA;CACA;CACA;CACA;AACF;AAKA,MAAM,cACJ,OAAO,gBAAgB,cACnB,cACC,SAAS,oBAAoB,CAAC;;;;;;;;AASrC,IAAa,gBAAb,cAAmC,YAAY;CAC7C,WAAW,qBAA+B;EACxC,OAAO,CAAC,GAAG,QAAQ;CACrB;CAEA,UAA6B;CAC7B,UAAiC,CAAC;CAClC;;CAGA,IAAI,SAA4B;EAC9B,OAAO,KAAKA;CACd;;CAGA,IAAI,SAAgC;EAClC,OAAO,KAAKC;CACd;CACA,IAAI,OAAO,OAA8B;EACvC,KAAKA,UAAU,SAAS,CAAC;EACzB,KAAKC,gBAAgB;CACvB;CAEA,oBAA0B;EACxB,IAAI,CAAC,KAAK,MAAM,SAAS,KAAK,MAAM,UAAU;EAC9C,KAAUC,OAAO;CACnB;CAEA,uBAA6B;EAC3B,aAAa,KAAKC,SAAS;EAC3B,KAAKJ,SAAS,QAAQ;EACtB,KAAKA,UAAU;CACjB;CAEA,yBAAyB,MAAoB;EAC3C,IAAI,CAAC,KAAKA,SAAS;EACnB,IAAI,SAAS,UACX,IAAI,KAAKK,UAAU,QAAQ,GAAG,KAAKL,QAAQ,MAAM;OAC5C,KAAKA,QAAQ,KAAK;OAEvB,KAAKE,gBAAgB;CAEzB;CAEA,MAAMC,SAAwB;EAC5B,MAAM,SAAS,MAAM,KAAKG,aAAa;EACvC,IAAI,CAAC,KAAK,aAAa;EACvB,MAAM,UAAuB;GAC3B,QAAQ,KAAK,aAAa,QAAQ,KAAK,KAAA;G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;AACF;AAEA,SAAS,UAAU,MAA4C;CAC7D,IAAI,CAAC,MAAM,OAAO,CAAC;CACnB,IAAI;EACF,OAAO,KAAK,MAAM,IAAI;CACxB,QAAQ;EACN,OAAO,CAAC;CACV;AACF;;AAGA,SAAgB,SAAS,MAAM,WAAiB;CAC9C,IAAI,OAAO,WAAW,eAAe,OAAO,mBAAmB,aAAa;CAC5E,IAAI,CAAC,eAAe,IAAI,GAAG,GAAG,eAAe,OAAO,KAAK,aAAa;AACxE;AAIA,SAAS"}
1
+ {"version":3,"file":"index.js","names":["#handle","#config","#scheduleUpdate","#mount","#debounce","#boolAttr","#buildConfig","#update"],"sources":["../src/index.ts"],"sourcesContent":["import { createWave } from \"@wave3d/core\";\nimport type {\n StudioConfig,\n TiltStatus,\n WaveHandle,\n WaveOptions,\n WaveRenderer,\n FallbackReason,\n} from \"@wave3d/core\";\n\nconst OBSERVED = [\n \"config\",\n \"src\",\n \"preset\",\n \"poster\",\n \"poster-fit\",\n \"paused\",\n \"lazy\",\n \"webgl\",\n \"backend\",\n] as const;\n\n// SSR-safe base: `class extends HTMLElement` evaluates HTMLElement at import time, which throws\n// under Node. Fall back to a dummy base there — the element is never instantiated server-side\n// (register() is guarded), so the missing DOM methods are never called.\nconst ElementBase: typeof HTMLElement =\n typeof HTMLElement !== \"undefined\"\n ? HTMLElement\n : (function Wave3DElementBase() {} as unknown as typeof HTMLElement);\n\n/**\n * `<wave-3d>` — the framework-agnostic drop-in (Vue/Svelte/plain HTML). Light DOM, `display:block`.\n * Attributes: `config` (JSON), `src` (URL to a config JSON), `preset` (name), `poster`,\n * `poster-fit` (`fill` | `cover` | `contain`), `paused`, `lazy`, `webgl`. Also a `config` property\n * and a read-only `handle` getter. Emits `wave3d-ready` (detail = renderer) and `wave3d-fallback`\n * (detail = reason) events.\n */\nexport class Wave3DElement extends ElementBase {\n static get observedAttributes(): string[] {\n return [...OBSERVED];\n }\n\n #handle: WaveHandle | null = null;\n #config: Partial<StudioConfig> = {};\n #debounce?: ReturnType<typeof setTimeout>;\n\n /** The live shell handle (null before connect / after disconnect). */\n get handle(): WaveHandle | null {\n return this.#handle;\n }\n\n /**\n * Explicitly ask for the device-orientation sensor. OPTIONAL, and on iOS it opens a modal\n * permission dialog — nothing calls it for you, and a decorative scene should simply go without\n * tilt there. CALL IT FROM A USER GESTURE (iOS grants the sensor only from inside a tap handler)\n * and only once `wave3d-ready` has fired — before that there is no renderer to ask, and the replayed\n * request has left the gesture.\n */\n enableTilt(): Promise<boolean> {\n return this.#handle?.enableTilt() ?? Promise.resolve(false);\n }\n\n /** Where the tilt sensor stands. `\"prompt\"` is exactly when a tap-to-enable affordance helps. */\n tiltStatus(): TiltStatus {\n return this.#handle?.tiltStatus() ?? \"prompt\";\n }\n\n /** Take the next orientation reading as the neutral pose (the reader has changed grip). */\n recenterTilt(): void {\n this.#handle?.recenterTilt();\n }\n\n /** Programmatic config, merged last (over the `preset`/`src`/`config` attributes). */\n get config(): Partial<StudioConfig> {\n return this.#config;\n }\n set config(value: Partial<StudioConfig>) {\n this.#config = value ?? {};\n this.#scheduleUpdate();\n }\n\n connectedCallback(): void {\n if (!this.style.display) this.style.display = \"block\";\n void this.#mount();\n }\n\n disconnectedCallback(): void {\n clearTimeout(this.#debounce);\n this.#handle?.destroy();\n this.#handle = null;\n }\n\n attributeChangedCallback(name: string): void {\n if (!this.#handle) return;\n if (name === \"paused\") {\n if (this.#boolAttr(\"paused\")) this.#handle.pause();\n else this.#handle.play();\n } else {\n this.#scheduleUpdate();\n }\n }\n\n async #mount(): Promise<void> {\n const config = await this.#buildConfig();\n if (!this.isConnected) return; // disconnected while the config resolved\n const options: WaveOptions = {\n poster: this.getAttribute(\"poster\") ?? undefined,\n posterFit: (this.getAttribute(\"poster-fit\") as WaveOptions[\"posterFit\"]) ?? undefined,\n lazy: this.#boolAttr(\"lazy\"),\n webgl: (this.getAttribute(\"webgl\") as WaveOptions[\"webgl\"]) ?? undefined,\n // Default \"webgl\": anything else fetches the TSL backend chunk, so it stays opt-in.\n backend: (this.getAttribute(\"backend\") as WaveOptions[\"backend\"]) ?? undefined,\n paused: this.#boolAttr(\"paused\"),\n onReady: (renderer: WaveRenderer) =>\n this.dispatchEvent(new CustomEvent(\"wave3d-ready\", { detail: renderer })),\n onFallback: (reason: FallbackReason) =>\n this.dispatchEvent(new CustomEvent(\"wave3d-fallback\", { detail: reason })),\n };\n this.#handle = createWave(this, config, options);\n }\n\n /** default ← preset ← src JSON ← config attribute ← config property. */\n async #buildConfig(): Promise<Partial<StudioConfig>> {\n let base: Partial<StudioConfig> = {};\n const presetName = this.getAttribute(\"preset\");\n if (presetName) {\n const { PRESETS } = await import(\"@wave3d/core/presets\");\n base = PRESETS[presetName]?.() ?? {};\n }\n const src = this.getAttribute(\"src\");\n if (src) {\n try {\n base = { ...base, ...(await fetch(src).then((r) => r.json())) };\n } catch {\n // ignore a failed/invalid config fetch — fall through to whatever we have\n }\n }\n base = { ...base, ...parseJson(this.getAttribute(\"config\")), ...this.#config };\n return base;\n }\n\n #scheduleUpdate(): void {\n clearTimeout(this.#debounce);\n this.#debounce = setTimeout(() => {\n void this.#update();\n }, 50);\n }\n\n async #update(): Promise<void> {\n const handle = this.#handle;\n if (!handle) return;\n handle.set(await this.#buildConfig());\n }\n\n /** Presence = true; `\"false\"`/`\"0\"` = false; absent = undefined (shell default). */\n #boolAttr(name: string): boolean | undefined {\n if (!this.hasAttribute(name)) return undefined;\n const value = this.getAttribute(name);\n return value !== \"false\" && value !== \"0\";\n }\n}\n\nfunction parseJson(json: string | null): Partial<StudioConfig> {\n if (!json) return {};\n try {\n return JSON.parse(json) as Partial<StudioConfig>;\n } catch {\n return {};\n }\n}\n\n/** Define the element (idempotent, SSR/Node-import-safe). */\nexport function register(tag = \"wave-3d\"): void {\n if (typeof window === \"undefined\" || typeof customElements === \"undefined\") return;\n if (!customElements.get(tag)) customElements.define(tag, Wave3DElement);\n}\n\n// Self-register on import so a bare `import \"@wave3d/element\"` makes <wave-3d> work. Guarded so\n// importing under Node (SSR) is a no-op rather than a ReferenceError.\nregister();\n\nexport type {\n StudioConfig,\n WaveHandle,\n WaveRenderer,\n FallbackReason,\n SnapshotOptions,\n} from \"@wave3d/core\";\n"],"mappings":";;AAUA,MAAM,WAAW;CACf;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;AACF;AAKA,MAAM,cACJ,OAAO,gBAAgB,cACnB,cACC,SAAS,oBAAoB,CAAC;;;;;;;;AASrC,IAAa,gBAAb,cAAmC,YAAY;CAC7C,WAAW,qBAA+B;EACxC,OAAO,CAAC,GAAG,QAAQ;CACrB;CAEA,UAA6B;CAC7B,UAAiC,CAAC;CAClC;;CAGA,IAAI,SAA4B;EAC9B,OAAO,KAAKA;CACd;;;;;;;;CASA,aAA+B;EAC7B,OAAO,KAAKA,SAAS,WAAW,KAAK,QAAQ,QAAQ,KAAK;CAC5D;;CAGA,aAAyB;EACvB,OAAO,KAAKA,SAAS,WAAW,KAAK;CACvC;;CAGA,eAAqB;EACnB,KAAKA,SAAS,aAAa;CAC7B;;CAGA,IAAI,SAAgC;EAClC,OAAO,KAAKC;CACd;CACA,IAAI,OAAO,OAA8B;EACvC,KAAKA,UAAU,SAAS,CAAC;EACzB,KAAKC,gBAAgB;CACvB;CAEA,oBAA0B;EACxB,IAAI,CAAC,KAAK,MAAM,SAAS,KAAK,MAAM,UAAU;EAC9C,KAAUC,OAAO;CACnB;CAEA,uBAA6B;EAC3B,aAAa,KAAKC,SAAS;EAC3B,KAAKJ,SAAS,QAAQ;EACtB,KAAKA,UAAU;CACjB;CAEA,yBAAyB,MAAoB;EAC3C,IAAI,CAAC,KAAKA,SAAS;EACnB,IAAI,SAAS,UACX,IAAI,KAAKK,UAAU,QAAQ,GAAG,KAAKL,QAAQ,MAAM;OAC5C,KAAKA,QAAQ,KAAK;OAEvB,KAAKE,gBAAgB;CAEzB;CAEA,MAAMC,SAAwB;EAC5B,MAAM,SAAS,MAAM,KAAKG,aAAa;EACvC,IAAI,CAAC,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,IAAI,CAAC,KAAK,aAAa,IAAI,GAAG,OAAO,KAAA;EACrC,MAAM,QAAQ,KAAK,aAAa,IAAI;EACpC,OAAO,UAAU,WAAW,UAAU;CACxC;AACF;AAEA,SAAS,UAAU,MAA4C;CAC7D,IAAI,CAAC,MAAM,OAAO,CAAC;CACnB,IAAI;EACF,OAAO,KAAK,MAAM,IAAI;CACxB,QAAQ;EACN,OAAO,CAAC;CACV;AACF;;AAGA,SAAgB,SAAS,MAAM,WAAiB;CAC9C,IAAI,OAAO,WAAW,eAAe,OAAO,mBAAmB,aAAa;CAC5E,IAAI,CAAC,eAAe,IAAI,GAAG,GAAG,eAAe,OAAO,KAAK,aAAa;AACxE;AAIA,SAAS"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@wave3d/element",
3
- "version": "0.8.0",
3
+ "version": "0.9.0",
4
4
  "description": "Drop-in animated 3D gradient wave for Vue, Svelte, or plain HTML: the <wave-3d> custom element",
5
5
  "keywords": [
6
6
  "background",
@@ -40,7 +40,7 @@
40
40
  "access": "public"
41
41
  },
42
42
  "dependencies": {
43
- "@wave3d/core": "^0.8.0"
43
+ "@wave3d/core": "^0.9.0"
44
44
  },
45
45
  "peerDependencies": {
46
46
  "@types/three": ">=0.180",