@liforma/client 0.4.14 → 0.4.16

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.
Files changed (80) hide show
  1. package/CHANGELOG.md +12 -0
  2. package/dist/next/index.js +625 -602
  3. package/dist/next/index.js.map +1 -1
  4. package/dist/next/react/ExperienceThumbnail.d.ts.map +1 -1
  5. package/dist/next/thumbnail/avatarPlate.d.ts +11 -0
  6. package/dist/next/thumbnail/avatarPlate.d.ts.map +1 -0
  7. package/dist/next/thumbnail/avatarPlate.test.d.ts +2 -0
  8. package/dist/next/thumbnail/avatarPlate.test.d.ts.map +1 -0
  9. package/dist/next/thumbnail/expandAssetUrl.d.ts +3 -2
  10. package/dist/next/thumbnail/expandAssetUrl.d.ts.map +1 -1
  11. package/dist/next/thumbnail/index.d.ts +2 -0
  12. package/dist/next/thumbnail/index.d.ts.map +1 -1
  13. package/dist/next/thumbnail/toGalleryThumbUrl.d.ts +7 -3
  14. package/dist/next/thumbnail/toGalleryThumbUrl.d.ts.map +1 -1
  15. package/dist/next/thumbnail.js +211 -200
  16. package/dist/next/thumbnail.js.map +1 -1
  17. package/dist/next/v2/embed/protocol.d.ts +7 -7
  18. package/dist/next/v2/embed/protocol.d.ts.map +1 -1
  19. package/dist/next/v2/experience.d.ts +8 -5
  20. package/dist/next/v2/experience.d.ts.map +1 -1
  21. package/dist/next/v2/types/sessionLaunch.d.ts +6 -0
  22. package/dist/next/v2/types/sessionLaunch.d.ts.map +1 -1
  23. package/dist/npm/index.js +506 -490
  24. package/dist/npm/index.js.map +1 -1
  25. package/dist/npm/thumbnail/avatarPlate.d.ts +11 -0
  26. package/dist/npm/thumbnail/avatarPlate.d.ts.map +1 -0
  27. package/dist/npm/thumbnail/expandAssetUrl.d.ts +3 -2
  28. package/dist/npm/thumbnail/expandAssetUrl.d.ts.map +1 -1
  29. package/dist/npm/thumbnail/index.d.ts +2 -0
  30. package/dist/npm/thumbnail/index.d.ts.map +1 -1
  31. package/dist/npm/thumbnail/index.js +123 -110
  32. package/dist/npm/thumbnail/index.js.map +1 -1
  33. package/dist/npm/thumbnail/toGalleryThumbUrl.d.ts +7 -3
  34. package/dist/npm/thumbnail/toGalleryThumbUrl.d.ts.map +1 -1
  35. package/dist/npm/v2/embed/protocol.d.ts +7 -7
  36. package/dist/npm/v2/embed/protocol.d.ts.map +1 -1
  37. package/dist/npm/v2/experience.d.ts +8 -5
  38. package/dist/npm/v2/experience.d.ts.map +1 -1
  39. package/dist/npm/v2/index.d.ts +1 -1
  40. package/dist/npm/v2/index.d.ts.map +1 -1
  41. package/dist/npm/v2/liforma-experience-thumbnail.d.ts.map +1 -1
  42. package/dist/npm/v2/npm.d.ts +1 -1
  43. package/dist/npm/v2/npm.d.ts.map +1 -1
  44. package/dist/npm/v2/types/index.d.ts +1 -1
  45. package/dist/npm/v2/types/index.d.ts.map +1 -1
  46. package/dist/npm/v2/types/sessionLaunch.d.ts +6 -0
  47. package/dist/npm/v2/types/sessionLaunch.d.ts.map +1 -1
  48. package/dist/react/component/experienceComponentRuntime.d.ts +3 -1
  49. package/dist/react/component/experienceComponentRuntime.d.ts.map +1 -1
  50. package/dist/react/component/experienceComponentTypes.d.ts +6 -4
  51. package/dist/react/component/experienceComponentTypes.d.ts.map +1 -1
  52. package/dist/react/index.js +733 -704
  53. package/dist/react/index.js.map +1 -1
  54. package/dist/react/react/Experience.d.ts.map +1 -1
  55. package/dist/react/react/ExperienceThumbnail.d.ts.map +1 -1
  56. package/dist/react/thumbnail/avatarPlate.d.ts +11 -0
  57. package/dist/react/thumbnail/avatarPlate.d.ts.map +1 -0
  58. package/dist/react/thumbnail/avatarPlate.test.d.ts +2 -0
  59. package/dist/react/thumbnail/avatarPlate.test.d.ts.map +1 -0
  60. package/dist/react/thumbnail/expandAssetUrl.d.ts +3 -2
  61. package/dist/react/thumbnail/expandAssetUrl.d.ts.map +1 -1
  62. package/dist/react/thumbnail/index.d.ts +2 -0
  63. package/dist/react/thumbnail/index.d.ts.map +1 -1
  64. package/dist/react/thumbnail/toGalleryThumbUrl.d.ts +7 -3
  65. package/dist/react/thumbnail/toGalleryThumbUrl.d.ts.map +1 -1
  66. package/dist/react/thumbnail.js +211 -200
  67. package/dist/react/thumbnail.js.map +1 -1
  68. package/dist/react/v2/embed/protocol.d.ts +7 -7
  69. package/dist/react/v2/embed/protocol.d.ts.map +1 -1
  70. package/dist/react/v2/experience.d.ts +8 -5
  71. package/dist/react/v2/experience.d.ts.map +1 -1
  72. package/dist/react/v2/types/sessionLaunch.d.ts +6 -0
  73. package/dist/react/v2/types/sessionLaunch.d.ts.map +1 -1
  74. package/dist/sdk/v2/client.js +3 -3
  75. package/dist/sdk/v2/client.js.map +1 -1
  76. package/dist/sdk/v2/thumbnail.js +2 -2
  77. package/dist/sdk/v2/thumbnail.js.map +1 -1
  78. package/dist/svelte/Experience.svelte +4 -0
  79. package/dist/svelte/ExperienceThumbnail.svelte +3 -0
  80. package/package.json +1 -1
@@ -0,0 +1,11 @@
1
+ /** Avatar colour-plate tiers published on the CDN (`/avatars/{id}/{tier}/…`). */
2
+ export declare const THUMBNAIL_AVATAR_PLATE_SIZES: readonly ["256", "512", "1024"];
3
+ export type ThumbnailAvatarPlateSize = (typeof THUMBNAIL_AVATAR_PLATE_SIZES)[number];
4
+ /**
5
+ * Pick avatar CDN tier from the host CSS box.
6
+ * Unmeasured boxes stay on `256` (gallery default). Hosts larger than a 256
7
+ * plate use `512`; spotlight-scale hosts (long edge above 512) use `1024`.
8
+ */
9
+ export declare function pickThumbnailAvatarPlateSize(width: number, height: number): ThumbnailAvatarPlateSize;
10
+ export declare function rewriteThumbnailAvatarPlateSize(url: string, size: ThumbnailAvatarPlateSize): string;
11
+ //# sourceMappingURL=avatarPlate.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"avatarPlate.d.ts","sourceRoot":"","sources":["../../../src/thumbnail/avatarPlate.ts"],"names":[],"mappings":"AAAA,iFAAiF;AACjF,eAAO,MAAM,4BAA4B,iCAAkC,CAAC;AAC5E,MAAM,MAAM,wBAAwB,GAAG,CAAC,OAAO,4BAA4B,CAAC,CAAC,MAAM,CAAC,CAAC;AAIrF;;;;GAIG;AACH,wBAAgB,4BAA4B,CAC3C,KAAK,EAAE,MAAM,EACb,MAAM,EAAE,MAAM,GACZ,wBAAwB,CAQ1B;AAED,wBAAgB,+BAA+B,CAC9C,GAAG,EAAE,MAAM,EACX,IAAI,EAAE,wBAAwB,GAC5B,MAAM,CAOR"}
@@ -1,3 +1,4 @@
1
+ import { type ThumbnailAvatarPlateSize } from './avatarPlate';
1
2
  import { type ThumbnailLocationPlateSize } from './locationPlate';
2
3
  /** Default origin for Liforma gallery plates (catalog paths have no host). */
3
4
  export declare const DEFAULT_THUMBNAIL_CDN_BASE_URL = "https://cdn.liforma.ai";
@@ -11,7 +12,7 @@ export declare function normalizeThumbnailCdnBaseUrl(cdnBaseUrl?: string): strin
11
12
  export declare function expandThumbnailLocationUrl(ref: string, locationPlateSize: ThumbnailLocationPlateSize, cdnBaseUrl?: string): string;
12
13
  /**
13
14
  * Expand a catalog avatar path (or keep a full URL) onto the public CDN.
14
- * `/avatars/{id}` → `{cdn}/avatars/{id}/256/{id}_neutral.webp`
15
+ * `/avatars/{id}` → `{cdn}/avatars/{id}/{tier}/{id}_neutral.webp`
15
16
  */
16
- export declare function expandThumbnailAvatarUrl(ref: string, cdnBaseUrl?: string): string;
17
+ export declare function expandThumbnailAvatarUrl(ref: string, cdnBaseUrl?: string, avatarPlateSize?: ThumbnailAvatarPlateSize): string;
17
18
  //# sourceMappingURL=expandAssetUrl.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"expandAssetUrl.d.ts","sourceRoot":"","sources":["../../../src/thumbnail/expandAssetUrl.ts"],"names":[],"mappings":"AAAA,OAAO,EAEN,KAAK,0BAA0B,EAC/B,MAAM,iBAAiB,CAAC;AAEzB,8EAA8E;AAC9E,eAAO,MAAM,8BAA8B,2BAA2B,CAAC;AAIvE,wBAAgB,4BAA4B,CAAC,UAAU,CAAC,EAAE,MAAM,GAAG,MAAM,CAGxE;AAsBD;;;;;GAKG;AACH,wBAAgB,0BAA0B,CACzC,GAAG,EAAE,MAAM,EACX,iBAAiB,EAAE,0BAA0B,EAC7C,UAAU,CAAC,EAAE,MAAM,GACjB,MAAM,CA6BR;AAED;;;GAGG;AACH,wBAAgB,wBAAwB,CAAC,GAAG,EAAE,MAAM,EAAE,UAAU,CAAC,EAAE,MAAM,GAAG,MAAM,CAgCjF"}
1
+ {"version":3,"file":"expandAssetUrl.d.ts","sourceRoot":"","sources":["../../../src/thumbnail/expandAssetUrl.ts"],"names":[],"mappings":"AAAA,OAAO,EAEN,KAAK,wBAAwB,EAC7B,MAAM,eAAe,CAAC;AACvB,OAAO,EAEN,KAAK,0BAA0B,EAC/B,MAAM,iBAAiB,CAAC;AAEzB,8EAA8E;AAC9E,eAAO,MAAM,8BAA8B,2BAA2B,CAAC;AAIvE,wBAAgB,4BAA4B,CAAC,UAAU,CAAC,EAAE,MAAM,GAAG,MAAM,CAGxE;AAsBD;;;;;GAKG;AACH,wBAAgB,0BAA0B,CACzC,GAAG,EAAE,MAAM,EACX,iBAAiB,EAAE,0BAA0B,EAC7C,UAAU,CAAC,EAAE,MAAM,GACjB,MAAM,CA6BR;AAED;;;GAGG;AACH,wBAAgB,wBAAwB,CACvC,GAAG,EAAE,MAAM,EACX,UAAU,CAAC,EAAE,MAAM,EACnB,eAAe,GAAE,wBAAgC,GAC/C,MAAM,CAiCR"}
@@ -2,6 +2,8 @@ export type { GalleryThumb, ExperienceThumbnailBaseProps, ThumbnailInteractionKi
2
2
  export { thumbnailFitClass } from './types';
3
3
  export { toGalleryThumbUrl, resolveThumbnailLayers } from './toGalleryThumbUrl';
4
4
  export { DEFAULT_THUMBNAIL_CDN_BASE_URL, expandThumbnailAvatarUrl, expandThumbnailLocationUrl, normalizeThumbnailCdnBaseUrl } from './expandAssetUrl';
5
+ export { pickThumbnailAvatarPlateSize, rewriteThumbnailAvatarPlateSize, THUMBNAIL_AVATAR_PLATE_SIZES } from './avatarPlate';
6
+ export type { ThumbnailAvatarPlateSize } from './avatarPlate';
5
7
  export { pickThumbnailLocationPlateSize, rewriteThumbnailLocationPlateSize, attachThumbnailBox, THUMBNAIL_LOCATION_PLATE_SIZES } from './locationPlate';
6
8
  export type { ThumbnailLocationPlateSize } from './locationPlate';
7
9
  export { resolveThumbnailInteraction, resolvePlayerBaseUrl, buildHostedLaunchUrl, resolveThumbnailHref } from './hostedLaunchUrl';
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/thumbnail/index.ts"],"names":[],"mappings":"AAAA,YAAY,EAAE,YAAY,EAAE,4BAA4B,EAAE,wBAAwB,EAAE,MAAM,SAAS,CAAC;AACpG,OAAO,EAAE,iBAAiB,EAAE,MAAM,SAAS,CAAC;AAC5C,OAAO,EAAE,iBAAiB,EAAE,sBAAsB,EAAE,MAAM,qBAAqB,CAAC;AAChF,OAAO,EACN,8BAA8B,EAC9B,wBAAwB,EACxB,0BAA0B,EAC1B,4BAA4B,EAC5B,MAAM,kBAAkB,CAAC;AAC1B,OAAO,EACN,8BAA8B,EAC9B,iCAAiC,EACjC,kBAAkB,EAClB,8BAA8B,EAC9B,MAAM,iBAAiB,CAAC;AACzB,YAAY,EAAE,0BAA0B,EAAE,MAAM,iBAAiB,CAAC;AAClE,OAAO,EACN,2BAA2B,EAC3B,oBAAoB,EACpB,oBAAoB,EACpB,oBAAoB,EACpB,MAAM,mBAAmB,CAAC;AAC3B,OAAO,EACN,eAAe,EACf,gBAAgB,EAChB,wBAAwB,EACxB,MAAM,YAAY,CAAC;AACpB,OAAO,EACN,oBAAoB,EACpB,iBAAiB,EACjB,6BAA6B,EAC7B,4BAA4B,EAC5B,MAAM,sBAAsB,CAAC;AAC9B,OAAO,EACN,2BAA2B,EAC3B,+BAA+B,EAC/B,0BAA0B,EAC1B,MAAM,kBAAkB,CAAC;AAC1B,OAAO,EAAE,uBAAuB,EAAE,MAAM,2BAA2B,CAAC;AACpE,OAAO,EAAE,wBAAwB,EAAE,MAAM,UAAU,CAAC;AACpD,OAAO,EAAE,+BAA+B,EAAE,MAAM,gBAAgB,CAAC;AACjE,OAAO,EACN,oBAAoB,EACpB,kBAAkB,EAClB,mCAAmC,EACnC,iCAAiC,EACjC,iBAAiB,EACjB,cAAc,EACd,MAAM,iBAAiB,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/thumbnail/index.ts"],"names":[],"mappings":"AAAA,YAAY,EAAE,YAAY,EAAE,4BAA4B,EAAE,wBAAwB,EAAE,MAAM,SAAS,CAAC;AACpG,OAAO,EAAE,iBAAiB,EAAE,MAAM,SAAS,CAAC;AAC5C,OAAO,EAAE,iBAAiB,EAAE,sBAAsB,EAAE,MAAM,qBAAqB,CAAC;AAChF,OAAO,EACN,8BAA8B,EAC9B,wBAAwB,EACxB,0BAA0B,EAC1B,4BAA4B,EAC5B,MAAM,kBAAkB,CAAC;AAC1B,OAAO,EACN,4BAA4B,EAC5B,+BAA+B,EAC/B,4BAA4B,EAC5B,MAAM,eAAe,CAAC;AACvB,YAAY,EAAE,wBAAwB,EAAE,MAAM,eAAe,CAAC;AAC9D,OAAO,EACN,8BAA8B,EAC9B,iCAAiC,EACjC,kBAAkB,EAClB,8BAA8B,EAC9B,MAAM,iBAAiB,CAAC;AACzB,YAAY,EAAE,0BAA0B,EAAE,MAAM,iBAAiB,CAAC;AAClE,OAAO,EACN,2BAA2B,EAC3B,oBAAoB,EACpB,oBAAoB,EACpB,oBAAoB,EACpB,MAAM,mBAAmB,CAAC;AAC3B,OAAO,EACN,eAAe,EACf,gBAAgB,EAChB,wBAAwB,EACxB,MAAM,YAAY,CAAC;AACpB,OAAO,EACN,oBAAoB,EACpB,iBAAiB,EACjB,6BAA6B,EAC7B,4BAA4B,EAC5B,MAAM,sBAAsB,CAAC;AAC9B,OAAO,EACN,2BAA2B,EAC3B,+BAA+B,EAC/B,0BAA0B,EAC1B,MAAM,kBAAkB,CAAC;AAC1B,OAAO,EAAE,uBAAuB,EAAE,MAAM,2BAA2B,CAAC;AACpE,OAAO,EAAE,wBAAwB,EAAE,MAAM,UAAU,CAAC;AACpD,OAAO,EAAE,+BAA+B,EAAE,MAAM,gBAAgB,CAAC;AACjE,OAAO,EACN,oBAAoB,EACpB,kBAAkB,EAClB,mCAAmC,EACnC,iCAAiC,EACjC,iBAAiB,EACjB,cAAc,EACd,MAAM,iBAAiB,CAAC"}
@@ -3,21 +3,37 @@ function e(e) {
3
3
  return e === "face" ? "liforma-et--fit-face" : e === "medium" ? "liforma-et--fit-medium" : "";
4
4
  }
5
5
  //#endregion
6
- //#region src/thumbnail/locationPlate.ts
6
+ //#region src/thumbnail/avatarPlate.ts
7
7
  var t = [
8
+ "256",
9
+ "512",
10
+ "1024"
11
+ ], n = /(\/avatars\/[^/]+\/)(\d+)(\/)/i;
12
+ function r(e, t) {
13
+ if (!Number.isFinite(e) || !Number.isFinite(t) || e < 1 || t < 1) return "256";
14
+ let n = Math.max(e, t);
15
+ return n > 512 ? "1024" : n > 280 ? "512" : "256";
16
+ }
17
+ function i(e, t) {
18
+ let r = e.trim();
19
+ return r && r.replace(n, (e, n, r, i) => `${n}${t}${i}`);
20
+ }
21
+ //#endregion
22
+ //#region src/thumbnail/locationPlate.ts
23
+ var a = [
8
24
  "256x256",
9
25
  "400x225",
10
26
  "800x450",
11
27
  "1672x941"
12
- ], n = /(-)(\d+x\d+)(\.(?:webp|avif))(\?|$)/i;
13
- function r(e, t) {
28
+ ], o = /(-)(\d+x\d+)(\.(?:webp|avif))(\?|$)/i;
29
+ function s(e, t) {
14
30
  return !Number.isFinite(e) || !Number.isFinite(t) || e < 1 || t < 1 || e <= t ? "256x256" : t <= 225 ? "400x225" : e > 800 || t > 450 ? "1672x941" : "800x450";
15
31
  }
16
- function i(e, t) {
17
- let r = e.trim();
18
- return r && r.replace(n, (e, n, r, i, a) => `${n}${t}${i}${a}`);
32
+ function c(e, t) {
33
+ let n = e.trim();
34
+ return n && n.replace(o, (e, n, r, i, a) => `${n}${t}${i}${a}`);
19
35
  }
20
- function a(e, t) {
36
+ function l(e, t) {
21
37
  let n = () => {
22
38
  t(e.clientWidth, e.clientHeight);
23
39
  };
@@ -27,17 +43,17 @@ function a(e, t) {
27
43
  }
28
44
  //#endregion
29
45
  //#region src/thumbnail/expandAssetUrl.ts
30
- var o = "https://cdn.liforma.ai", s = /-(256x256|400x225|400x450|800x450|836x971|1672x941|167x94)$/i;
31
- function c(e) {
46
+ var u = "https://cdn.liforma.ai", d = /-(256x256|400x225|400x450|800x450|836x971|1672x941|167x94)$/i;
47
+ function f(e) {
32
48
  return e?.trim().replace(/\/$/, "") || "https://cdn.liforma.ai";
33
49
  }
34
- function l(e) {
50
+ function p(e) {
35
51
  return /^https?:\/\//i.test(e) || e.startsWith("//");
36
52
  }
37
- function u(e) {
53
+ function m(e) {
38
54
  return e.startsWith("//") ? `https:${e}` : e;
39
55
  }
40
- function d(e) {
56
+ function h(e) {
41
57
  let t = e.indexOf("?");
42
58
  return t === -1 ? {
43
59
  pathname: e,
@@ -47,51 +63,48 @@ function d(e) {
47
63
  search: e.slice(t)
48
64
  };
49
65
  }
50
- function f(e, t, n = "") {
66
+ function g(e, t, n = "") {
51
67
  return `${e}${t.startsWith("/") ? t : `/${t}`}${n}`;
52
68
  }
53
- function p(e, t, n) {
69
+ function _(e, t, n) {
54
70
  let r = e.trim();
55
71
  if (!r) return r;
56
- let a = c(n);
57
- if (l(r)) return i(u(r), t);
58
- let { pathname: o, search: p } = d(r.replace(/\\/g, "/")), m = o;
59
- if (!m.startsWith("/")) m = `/locations/${m.replace(/^locations\//i, "")}`;
60
- else if (!/^\/locations\//i.test(m)) return /^\/avatars\//i.test(m) ? f(a, m, p) : r;
61
- if (/\.webp$/i.test(m) && !s.test(m.replace(/\.webp$/i, ""))) return f(a, m, p);
62
- let h = m.replace(/^\/locations\//i, "").replace(/\.webp$/i, "");
63
- return h = h.replace(s, ""), `${a}/locations/${h}-${t}.webp${p}`;
64
- }
65
- function m(e, t) {
66
- let n = e.trim();
67
- if (!n) return n;
68
- let r = c(t);
69
- if (l(n)) return u(n);
70
- let { pathname: i, search: a } = d(n.replace(/\\/g, "/")), o = i;
71
- if (!o.startsWith("/")) if (/^avatars\//i.test(o)) o = `/${o}`;
72
- else if (/^[^/]+$/.test(o) && !a) return `${r}/avatars/${o}/256/${o}_neutral.webp`;
73
- else return n;
74
- if (!/^\/avatars\//i.test(o)) return n;
75
- let s = o.replace(/^\/avatars\//i, "").replace(/\/+$/, "");
76
- return s && !s.includes("/") && !a ? `${r}/avatars/${s}/256/${s}_neutral.webp` : f(r, o, a);
72
+ let i = f(n);
73
+ if (p(r)) return c(m(r), t);
74
+ let { pathname: a, search: o } = h(r.replace(/\\/g, "/")), s = a;
75
+ if (!s.startsWith("/")) s = `/locations/${s.replace(/^locations\//i, "")}`;
76
+ else if (!/^\/locations\//i.test(s)) return /^\/avatars\//i.test(s) ? g(i, s, o) : r;
77
+ if (/\.webp$/i.test(s) && !d.test(s.replace(/\.webp$/i, ""))) return g(i, s, o);
78
+ let l = s.replace(/^\/locations\//i, "").replace(/\.webp$/i, "");
79
+ return l = l.replace(d, ""), `${i}/locations/${l}-${t}.webp${o}`;
80
+ }
81
+ function v(e, t, n = "256") {
82
+ let r = e.trim();
83
+ if (!r) return r;
84
+ let a = f(t), o = n;
85
+ if (p(r)) return i(m(r), o);
86
+ let { pathname: s, search: c } = h(r.replace(/\\/g, "/")), l = s;
87
+ if (!l.startsWith("/")) if (/^avatars\//i.test(l)) l = `/${l}`;
88
+ else if (/^[^/]+$/.test(l) && !c) return `${a}/avatars/${l}/${o}/${l}_neutral.webp`;
89
+ else return r;
90
+ if (!/^\/avatars\//i.test(l)) return r;
91
+ let u = l.replace(/^\/avatars\//i, "").replace(/\/+$/, "");
92
+ return u && !u.includes("/") && !c ? `${a}/avatars/${u}/${o}/${u}_neutral.webp` : i(g(a, l, c), o);
77
93
  }
78
94
  //#endregion
79
95
  //#region src/thumbnail/toGalleryThumbUrl.ts
80
- var h = /(\/avatars\/[^/]+\/)(\d+)(\/)/i, g = /_CH(\.webp)/i;
81
- function ee(e) {
96
+ var y = /_CH(\.webp)/i;
97
+ function b(e) {
82
98
  return /\/locations\//i.test(e) || /^locations\//i.test(e) ? !0 : /^https?:\/\//i.test(e) || e.startsWith("//") || /^\/?avatars\//i.test(e) || e.startsWith("/") ? !1 : e.includes("/");
83
99
  }
84
- function _(e, t = "256x256", n) {
85
- let r = e.trim();
86
- if (!r) return r;
87
- if (ee(r)) return p(r, t, n);
88
- let i = m(r, n);
89
- return i = i.replace(h, (e, t, n, r) => n === "256" ? `${t}${n}${r}` : `${t}256${r}`), i.replace(g, "_neutral$1");
100
+ function x(e, t = "256x256", n, r = "256") {
101
+ let i = e.trim();
102
+ return i && (b(i) ? _(i, t, n) : v(i, n, r).replace(y, "_neutral$1"));
90
103
  }
91
- function v(e) {
104
+ function S(e) {
92
105
  let t = e.avatarImage?.trim() || e.galleryThumb?.avatarImage?.trim() || "";
93
106
  if (!t) return null;
94
- let n = e.backgroundImage?.trim() || e.galleryThumb?.backgroundImage?.trim() || "", r = e.foregroundImage?.trim() || e.galleryThumb?.foregroundImage?.trim() || "", i = e.fallbackImage?.trim() || "", a = e.locationPlateSize ?? "256x256", o = c(e.cdnBaseUrl), s = e.normalize !== !1, l = (e) => !s && /^https?:\/\//i.test(e.trim()) ? e.trim() : _(e, a, o), u = (e) => !s && /^https?:\/\//i.test(e.trim()) ? e.trim() : p(e, a, o);
107
+ let n = e.backgroundImage?.trim() || e.galleryThumb?.backgroundImage?.trim() || "", r = e.foregroundImage?.trim() || e.galleryThumb?.foregroundImage?.trim() || "", i = e.fallbackImage?.trim() || "", a = e.locationPlateSize ?? "256x256", o = e.avatarPlateSize ?? "256", s = f(e.cdnBaseUrl), c = e.normalize !== !1, l = (e) => !c && /^https?:\/\//i.test(e.trim()) ? e.trim() : x(e, a, s, o), u = (e) => !c && /^https?:\/\//i.test(e.trim()) ? e.trim() : _(e, a, s);
95
108
  return {
96
109
  avatarImage: l(t),
97
110
  ...n ? { backgroundImage: u(n) } : {},
@@ -101,7 +114,7 @@ function v(e) {
101
114
  }
102
115
  //#endregion
103
116
  //#region src/shims/localStack.ts
104
- function y() {
117
+ function ee() {
105
118
  if (globalThis.__LIFORMA_STACK === "local") return !0;
106
119
  if (typeof location > "u") return !1;
107
120
  try {
@@ -112,25 +125,25 @@ function y() {
112
125
  }
113
126
  //#endregion
114
127
  //#region src/thumbnail/hostedLaunchUrl.ts
115
- var b = "https://player.liforma.ai", te = "http://localhost:3002";
116
- function ne(e) {
128
+ var C = "https://player.liforma.ai", te = "http://localhost:3002";
129
+ function w(e) {
117
130
  return e.href?.trim() ? "anchor" : e.hasClickHandler ? "button" : e.experienceId?.trim() ? "anchor" : "presentational";
118
131
  }
119
- function x(e) {
132
+ function T(e) {
120
133
  let t = e?.trim();
121
- return t ? t.replace(/\/$/, "") : y() ? te : b;
134
+ return t ? t.replace(/\/$/, "") : ee() ? te : C;
122
135
  }
123
- function S(e) {
124
- let t = e.experienceId.trim(), n = x(e.playerBaseUrl), r = new URL(`${n}/${encodeURIComponent(t)}`), i = e.returnUrl?.trim();
136
+ function E(e) {
137
+ let t = e.experienceId.trim(), n = T(e.playerBaseUrl), r = new URL(`${n}/${encodeURIComponent(t)}`), i = e.returnUrl?.trim();
125
138
  return i && r.searchParams.set("returnUrl", i), r.toString();
126
139
  }
127
- function C(e) {
140
+ function D(e) {
128
141
  let t = e.href?.trim();
129
142
  if (t) return t;
130
143
  let n = e.experienceId?.trim();
131
144
  if (!n) return;
132
145
  let r = e.returnUrl?.trim();
133
- return !r && e.useCurrentPageAsReturnUrl && typeof window < "u" && (r = window.location.href), S({
146
+ return !r && e.useCurrentPageAsReturnUrl && typeof window < "u" && (r = window.location.href), E({
134
147
  experienceId: n,
135
148
  ...r ? { returnUrl: r } : {},
136
149
  playerBaseUrl: e.playerBaseUrl
@@ -138,60 +151,60 @@ function C(e) {
138
151
  }
139
152
  //#endregion
140
153
  //#region src/thumbnail/thumbLoadScheduler.ts
141
- var w = 4, T = 160;
142
- function E() {
154
+ var O = 4, ne = 160;
155
+ function k() {
143
156
  return typeof window > "u" ? !1 : window.matchMedia("(hover: none), (pointer: coarse)").matches;
144
157
  }
145
- var D = 0, O = [];
146
- function k() {
147
- return E() ? 4 : Infinity;
158
+ var A = 0, j = [];
159
+ function M() {
160
+ return k() ? 4 : Infinity;
148
161
  }
149
- function A() {
150
- return E() ? 160 : 0;
162
+ function N() {
163
+ return k() ? 160 : 0;
151
164
  }
152
- function j() {
153
- let e = k();
154
- for (; D < e && O.length > 0;) {
155
- let e = O.shift();
165
+ function P() {
166
+ let e = M();
167
+ for (; A < e && j.length > 0;) {
168
+ let e = j.shift();
156
169
  if (!e || e.cancelled) continue;
157
- D += 1, e.start();
158
- let t = A();
170
+ A += 1, e.start();
171
+ let t = N();
159
172
  if (t <= 0) {
160
- D = Math.max(0, D - 1);
173
+ A = Math.max(0, A - 1);
161
174
  continue;
162
175
  }
163
176
  window.setTimeout(() => {
164
- D = Math.max(0, D - 1), j();
177
+ A = Math.max(0, A - 1), P();
165
178
  }, t);
166
179
  }
167
180
  }
168
- function M(e) {
169
- if (!E()) return e(), () => {};
181
+ function F(e) {
182
+ if (!k()) return e(), () => {};
170
183
  let t = {
171
184
  start: e,
172
185
  cancelled: !1
173
186
  };
174
- return O.push(t), j(), () => {
187
+ return j.push(t), P(), () => {
175
188
  t.cancelled = !0;
176
189
  };
177
190
  }
178
191
  //#endregion
179
192
  //#region src/thumbnail/lazyLoad.ts
180
- function N() {
181
- return E() ? "96px 0px" : "280px 0px";
193
+ function I() {
194
+ return k() ? "96px 0px" : "280px 0px";
182
195
  }
183
- function P(e) {
196
+ function re(e) {
184
197
  let t = e.trim().split(/\s+/)[0] ?? "0px", n = Number.parseFloat(t);
185
198
  return Number.isFinite(n) ? Math.abs(n) : 280;
186
199
  }
187
- function F(e, t) {
200
+ function L(e, t) {
188
201
  if (typeof window > "u") return !1;
189
202
  let n = e.getBoundingClientRect();
190
203
  return n.bottom >= -t && n.top <= window.innerHeight + t;
191
204
  }
192
- function I(e, t) {
193
- let { onVisibleChange: n } = t, r = t.rootMargin ?? N(), i = P(r), a = !1, o = !1, s = null, c = () => {
194
- o || (s?.(), s = M(() => {
205
+ function R(e, t) {
206
+ let { onVisibleChange: n } = t, r = t.rootMargin ?? I(), i = re(r), a = !1, o = !1, s = null, c = () => {
207
+ o || (s?.(), s = F(() => {
195
208
  s = null, o = !0, n(!0);
196
209
  }));
197
210
  }, l = (e) => {
@@ -213,11 +226,11 @@ function I(e, t) {
213
226
  rootMargin: r,
214
227
  threshold: 0
215
228
  });
216
- return u.observe(e), F(e, i) && l(!0), () => {
229
+ return u.observe(e), L(e, i) && l(!0), () => {
217
230
  s?.(), s = null, u.disconnect();
218
231
  };
219
232
  }
220
- function L(e, t) {
233
+ function z(e, t) {
221
234
  let n = () => t();
222
235
  return e.complete ? queueMicrotask(n) : (e.addEventListener("load", n, { once: !0 }), e.addEventListener("error", n, { once: !0 })), () => {
223
236
  e.removeEventListener("load", n), e.removeEventListener("error", n);
@@ -225,49 +238,49 @@ function L(e, t) {
225
238
  }
226
239
  //#endregion
227
240
  //#region src/thumbnail/scrollParallax.ts
228
- function R() {
241
+ function B() {
229
242
  return typeof window > "u" || window.matchMedia("(prefers-reduced-motion: reduce)").matches ? !1 : window.matchMedia("(hover: none), (pointer: coarse)").matches;
230
243
  }
231
- function z(e, t) {
244
+ function V(e, t) {
232
245
  return ((e.top + e.height / 2) / Math.max(t, 1) - .5) * 2;
233
246
  }
234
- var B = /* @__PURE__ */ new Set(), V = !1, H = 0;
235
- function U() {
236
- if (H = 0, B.size === 0 || typeof window > "u") return;
247
+ var H = /* @__PURE__ */ new Set(), U = !1, W = 0;
248
+ function G() {
249
+ if (W = 0, H.size === 0 || typeof window > "u") return;
237
250
  let e = window.innerHeight;
238
- for (let t of B) {
251
+ for (let t of H) {
239
252
  if (t.pointerActive?.()) continue;
240
253
  let n = t.element.getBoundingClientRect();
241
- n.bottom < -64 || n.top > e + 64 || t.onParallax(z(n, e));
254
+ n.bottom < -64 || n.top > e + 64 || t.onParallax(V(n, e));
242
255
  }
243
256
  }
244
- function W() {
245
- H === 0 && (H = requestAnimationFrame(U));
257
+ function K() {
258
+ W === 0 && (W = requestAnimationFrame(G));
246
259
  }
247
- function G() {
248
- V || typeof window > "u" || (V = !0, window.addEventListener("scroll", W, { passive: !0 }), window.addEventListener("resize", W, { passive: !0 }));
260
+ function q() {
261
+ U || typeof window > "u" || (U = !0, window.addEventListener("scroll", K, { passive: !0 }), window.addEventListener("resize", K, { passive: !0 }));
249
262
  }
250
- function K() {
251
- B.size > 0 || !V || typeof window > "u" || (V = !1, H !== 0 && (cancelAnimationFrame(H), H = 0), window.removeEventListener("scroll", W), window.removeEventListener("resize", W));
263
+ function J() {
264
+ H.size > 0 || !U || typeof window > "u" || (U = !1, W !== 0 && (cancelAnimationFrame(W), W = 0), window.removeEventListener("scroll", K), window.removeEventListener("resize", K));
252
265
  }
253
- function q(e, t) {
254
- if (!R()) return () => {};
266
+ function Y(e, t) {
267
+ if (!B()) return () => {};
255
268
  let n = {
256
269
  element: e,
257
270
  onParallax: t.onParallax,
258
271
  pointerActive: t.pointerActive
259
272
  };
260
- return B.add(n), G(), n.pointerActive?.() || t.onParallax(z(e.getBoundingClientRect(), window.innerHeight)), () => {
261
- B.delete(n), K();
273
+ return H.add(n), q(), n.pointerActive?.() || t.onParallax(V(e.getBoundingClientRect(), window.innerHeight)), () => {
274
+ H.delete(n), J();
262
275
  };
263
276
  }
264
277
  //#endregion
265
278
  //#region src/thumbnail/attachThumbnailParallax.ts
266
- function J(e) {
279
+ function ie(e) {
267
280
  let t = 0, n = 0, r = !1, i = !1, a = !1, o = () => {
268
281
  let a = r || i;
269
282
  e.classList.toggle("liforma-et--parallax", a), e.classList.toggle("liforma-et--scroll-parallax", i), e.style.setProperty("--liforma-et-parallax-x", String(t)), e.style.setProperty("--liforma-et-parallax-y", String(n));
270
- }, s = q(e, {
283
+ }, s = Y(e, {
271
284
  onParallax: (e) => {
272
285
  i = !0, a || (t = e, n = 0, o());
273
286
  },
@@ -280,7 +293,7 @@ function J(e) {
280
293
  a = !0, e.pointerType === "mouse" && (r = !0), o();
281
294
  }, u = () => {
282
295
  let s = a;
283
- a = !1, r = !1, i && s ? (t = z(e.getBoundingClientRect(), window.innerHeight), n = 0) : i || (t = 0, n = 0), o();
296
+ a = !1, r = !1, i && s ? (t = V(e.getBoundingClientRect(), window.innerHeight), n = 0) : i || (t = 0, n = 0), o();
284
297
  }, d = (e) => {
285
298
  e.pointerType === "mouse" && (r = !0, o());
286
299
  }, f = () => {
@@ -292,8 +305,8 @@ function J(e) {
292
305
  }
293
306
  //#endregion
294
307
  //#region src/thumbnail/styles.ts
295
- var Y = ":host {\n display: block;\n width: 100%;\n height: 100%;\n min-height: 0;\n}\n\n.liforma-et {\n --liforma-et-parallax-x: 0;\n --liforma-et-parallax-y: 0;\n --liforma-et-bg-scale: 1;\n --liforma-et-fg-scale: 1;\n --liforma-et-avatar-scale: 1;\n --liforma-et-bg-shift: 0px;\n --liforma-et-fg-shift: 0px;\n --liforma-et-avatar-shift: 0px;\n --liforma-et-reveal-duration: 420ms;\n\n box-sizing: border-box;\n position: relative;\n display: block;\n width: 100%;\n height: 100%;\n min-height: 0;\n margin: 0;\n padding: 0;\n border: 0;\n border-radius: 0;\n overflow: hidden;\n background: #111;\n color: inherit;\n text-decoration: none;\n cursor: inherit;\n -webkit-tap-highlight-color: transparent;\n}\n\na.liforma-et,\nbutton.liforma-et {\n cursor: pointer;\n}\n\nbutton.liforma-et {\n font: inherit;\n appearance: none;\n}\n\n.liforma-et__placeholder {\n position: absolute;\n inset: 0;\n z-index: 0;\n background:\n radial-gradient(120% 90% at 50% 0%, rgba(255, 255, 255, 0.06), transparent 58%),\n linear-gradient(180deg, #1a1a1a 0%, #101010 100%);\n opacity: 1;\n transition: opacity var(--liforma-et-reveal-duration) ease;\n}\n\n.liforma-et--revealed .liforma-et__placeholder {\n opacity: 0;\n}\n\n.liforma-et__media {\n opacity: 0;\n transition: opacity var(--liforma-et-reveal-duration) ease;\n}\n\n.liforma-et__media--ready {\n opacity: 1;\n}\n\n.liforma-et__background {\n position: absolute;\n inset: 0;\n z-index: 1;\n width: 100%;\n height: 100%;\n object-fit: cover;\n object-position: center center;\n transform: translate(\n calc(var(--liforma-et-parallax-x) * var(--liforma-et-bg-shift)),\n calc(var(--liforma-et-parallax-y) * var(--liforma-et-bg-shift))\n )\n scale(var(--liforma-et-bg-scale));\n transform-origin: center center;\n transition:\n opacity var(--liforma-et-reveal-duration) ease,\n transform 160ms ease;\n}\n\n.liforma-et__avatar {\n position: relative;\n z-index: 2;\n display: block;\n width: 100%;\n height: 100%;\n object-fit: contain;\n object-position: center bottom;\n transform: scale(var(--liforma-et-avatar-scale))\n translate(\n calc(var(--liforma-et-parallax-x) * var(--liforma-et-avatar-shift)),\n calc(var(--liforma-et-parallax-y) * var(--liforma-et-avatar-shift))\n );\n transform-origin: center center;\n transition:\n opacity var(--liforma-et-reveal-duration) ease,\n transform 160ms ease;\n}\n\n/* Gallery plates are typically square in a square tile — contain vs cover is a no-op\n without a zoom. Scale the whole scene from the upper third so Face matches\n player fit (location + avatar crop together). */\n.liforma-et--fit-face {\n --liforma-et-avatar-scale: 1.85;\n --liforma-et-bg-scale: 1.85;\n --liforma-et-fg-scale: 1.85;\n}\n\n.liforma-et--fit-face .liforma-et__avatar,\n.liforma-et--fit-face .liforma-et__background,\n.liforma-et--fit-face .liforma-et__foreground {\n transform-origin: 50% 18%;\n}\n\n.liforma-et--fit-face .liforma-et__avatar {\n object-fit: cover;\n object-position: 50% 18%;\n}\n\n/* Bust / medium: less zoom than face so upper chest stays in frame (player 3.75H window). */\n.liforma-et--fit-medium {\n --liforma-et-avatar-scale: 1.35;\n --liforma-et-bg-scale: 1.35;\n --liforma-et-fg-scale: 1.35;\n}\n\n.liforma-et--fit-medium .liforma-et__avatar,\n.liforma-et--fit-medium .liforma-et__background,\n.liforma-et--fit-medium .liforma-et__foreground {\n transform-origin: 50% 28%;\n}\n\n.liforma-et--fit-medium .liforma-et__avatar {\n object-fit: cover;\n object-position: 50% 28%;\n}\n\n.liforma-et__foreground {\n position: absolute;\n inset: 0;\n z-index: 3;\n width: 100%;\n height: 100%;\n object-fit: cover;\n object-position: center center;\n pointer-events: none;\n transform: translate(\n calc(var(--liforma-et-parallax-x) * var(--liforma-et-fg-shift) * -1),\n calc(var(--liforma-et-parallax-y) * var(--liforma-et-fg-shift) * -1)\n )\n scale(var(--liforma-et-fg-scale));\n transform-origin: center center;\n transition:\n opacity var(--liforma-et-reveal-duration) ease,\n transform 160ms ease;\n}\n\n.liforma-et--parallax {\n --liforma-et-bg-scale: 1.08;\n --liforma-et-fg-scale: 1.05;\n --liforma-et-avatar-scale: 1.08;\n --liforma-et-bg-shift: 10px;\n --liforma-et-fg-shift: 4px;\n --liforma-et-avatar-shift: 4px;\n}\n\n/* Promote layers only while parallax is active — avoids N compositor surfaces on galleries. */\n.liforma-et--parallax .liforma-et__background,\n.liforma-et--parallax .liforma-et__foreground,\n.liforma-et--parallax .liforma-et__avatar {\n will-change: transform;\n}\n\n.liforma-et--parallax.liforma-et--fit-face {\n --liforma-et-avatar-scale: 1.95;\n --liforma-et-bg-scale: 1.95;\n --liforma-et-fg-scale: 1.95;\n --liforma-et-avatar-shift: 0px;\n}\n\n.liforma-et--parallax.liforma-et--fit-medium {\n --liforma-et-avatar-scale: 1.42;\n --liforma-et-bg-scale: 1.42;\n --liforma-et-fg-scale: 1.42;\n --liforma-et-avatar-shift: 0px;\n}\n\n.liforma-et--scroll-parallax .liforma-et__background,\n.liforma-et--scroll-parallax .liforma-et__foreground,\n.liforma-et--scroll-parallax .liforma-et__avatar {\n transition: opacity var(--liforma-et-reveal-duration) ease;\n}\n\n@media (prefers-reduced-motion: reduce) {\n .liforma-et {\n --liforma-et-reveal-duration: 0ms;\n }\n\n .liforma-et--parallax {\n --liforma-et-bg-scale: 1;\n --liforma-et-fg-scale: 1;\n --liforma-et-avatar-scale: 1;\n --liforma-et-bg-shift: 0px;\n --liforma-et-fg-shift: 0px;\n --liforma-et-avatar-shift: 0px;\n }\n\n .liforma-et--parallax.liforma-et--fit-face {\n --liforma-et-avatar-scale: 1.85;\n --liforma-et-bg-scale: 1.85;\n --liforma-et-fg-scale: 1.85;\n }\n\n .liforma-et__background,\n .liforma-et__foreground,\n .liforma-et__avatar {\n transition: none;\n }\n}", X = !1;
296
- function re(e) {
308
+ var ae = ":host {\n display: block;\n width: 100%;\n height: 100%;\n min-height: 0;\n}\n\n.liforma-et {\n --liforma-et-parallax-x: 0;\n --liforma-et-parallax-y: 0;\n --liforma-et-bg-scale: 1;\n --liforma-et-fg-scale: 1;\n --liforma-et-avatar-scale: 1;\n --liforma-et-bg-shift: 0px;\n --liforma-et-fg-shift: 0px;\n --liforma-et-avatar-shift: 0px;\n --liforma-et-reveal-duration: 420ms;\n\n box-sizing: border-box;\n position: relative;\n display: block;\n width: 100%;\n height: 100%;\n min-height: 0;\n margin: 0;\n padding: 0;\n border: 0;\n border-radius: 0;\n overflow: hidden;\n background: #111;\n color: inherit;\n text-decoration: none;\n cursor: inherit;\n -webkit-tap-highlight-color: transparent;\n}\n\na.liforma-et,\nbutton.liforma-et {\n cursor: pointer;\n}\n\nbutton.liforma-et {\n font: inherit;\n appearance: none;\n}\n\n.liforma-et__placeholder {\n position: absolute;\n inset: 0;\n z-index: 0;\n background:\n radial-gradient(120% 90% at 50% 0%, rgba(255, 255, 255, 0.06), transparent 58%),\n linear-gradient(180deg, #1a1a1a 0%, #101010 100%);\n opacity: 1;\n transition: opacity var(--liforma-et-reveal-duration) ease;\n}\n\n.liforma-et--revealed .liforma-et__placeholder {\n opacity: 0;\n}\n\n.liforma-et__media {\n opacity: 0;\n transition: opacity var(--liforma-et-reveal-duration) ease;\n}\n\n.liforma-et__media--ready {\n opacity: 1;\n}\n\n.liforma-et__background {\n position: absolute;\n inset: 0;\n z-index: 1;\n width: 100%;\n height: 100%;\n object-fit: cover;\n object-position: center center;\n transform: translate(\n calc(var(--liforma-et-parallax-x) * var(--liforma-et-bg-shift)),\n calc(var(--liforma-et-parallax-y) * var(--liforma-et-bg-shift))\n )\n scale(var(--liforma-et-bg-scale));\n transform-origin: center center;\n transition:\n opacity var(--liforma-et-reveal-duration) ease,\n transform 160ms ease;\n}\n\n.liforma-et__avatar {\n position: relative;\n z-index: 2;\n display: block;\n width: 100%;\n height: 100%;\n object-fit: contain;\n object-position: center bottom;\n transform: scale(var(--liforma-et-avatar-scale))\n translate(\n calc(var(--liforma-et-parallax-x) * var(--liforma-et-avatar-shift)),\n calc(var(--liforma-et-parallax-y) * var(--liforma-et-avatar-shift))\n );\n transform-origin: center center;\n transition:\n opacity var(--liforma-et-reveal-duration) ease,\n transform 160ms ease;\n}\n\n/* Gallery plates are typically square in a square tile — contain vs cover is a no-op\n without a zoom. Scale the whole scene from the upper third so Face matches\n player fit (location + avatar crop together). */\n.liforma-et--fit-face {\n --liforma-et-avatar-scale: 1.85;\n --liforma-et-bg-scale: 1.85;\n --liforma-et-fg-scale: 1.85;\n}\n\n.liforma-et--fit-face .liforma-et__avatar,\n.liforma-et--fit-face .liforma-et__background,\n.liforma-et--fit-face .liforma-et__foreground {\n transform-origin: 50% 18%;\n}\n\n.liforma-et--fit-face .liforma-et__avatar {\n object-fit: cover;\n object-position: 50% 18%;\n}\n\n/* Bust / medium: less zoom than face so upper chest stays in frame (player 3.75H window). */\n.liforma-et--fit-medium {\n --liforma-et-avatar-scale: 1.35;\n --liforma-et-bg-scale: 1.35;\n --liforma-et-fg-scale: 1.35;\n}\n\n.liforma-et--fit-medium .liforma-et__avatar,\n.liforma-et--fit-medium .liforma-et__background,\n.liforma-et--fit-medium .liforma-et__foreground {\n transform-origin: 50% 28%;\n}\n\n.liforma-et--fit-medium .liforma-et__avatar {\n object-fit: cover;\n object-position: 50% 28%;\n}\n\n.liforma-et__foreground {\n position: absolute;\n inset: 0;\n z-index: 3;\n width: 100%;\n height: 100%;\n object-fit: cover;\n object-position: center center;\n pointer-events: none;\n transform: translate(\n calc(var(--liforma-et-parallax-x) * var(--liforma-et-fg-shift) * -1),\n calc(var(--liforma-et-parallax-y) * var(--liforma-et-fg-shift) * -1)\n )\n scale(var(--liforma-et-fg-scale));\n transform-origin: center center;\n transition:\n opacity var(--liforma-et-reveal-duration) ease,\n transform 160ms ease;\n}\n\n.liforma-et--parallax {\n --liforma-et-bg-scale: 1.08;\n --liforma-et-fg-scale: 1.05;\n --liforma-et-avatar-scale: 1.08;\n --liforma-et-bg-shift: 10px;\n --liforma-et-fg-shift: 4px;\n --liforma-et-avatar-shift: 4px;\n}\n\n/* Promote layers only while parallax is active — avoids N compositor surfaces on galleries. */\n.liforma-et--parallax .liforma-et__background,\n.liforma-et--parallax .liforma-et__foreground,\n.liforma-et--parallax .liforma-et__avatar {\n will-change: transform;\n}\n\n.liforma-et--parallax.liforma-et--fit-face {\n --liforma-et-avatar-scale: 1.95;\n --liforma-et-bg-scale: 1.95;\n --liforma-et-fg-scale: 1.95;\n --liforma-et-avatar-shift: 0px;\n}\n\n.liforma-et--parallax.liforma-et--fit-medium {\n --liforma-et-avatar-scale: 1.42;\n --liforma-et-bg-scale: 1.42;\n --liforma-et-fg-scale: 1.42;\n --liforma-et-avatar-shift: 0px;\n}\n\n.liforma-et--scroll-parallax .liforma-et__background,\n.liforma-et--scroll-parallax .liforma-et__foreground,\n.liforma-et--scroll-parallax .liforma-et__avatar {\n transition: opacity var(--liforma-et-reveal-duration) ease;\n}\n\n@media (prefers-reduced-motion: reduce) {\n .liforma-et {\n --liforma-et-reveal-duration: 0ms;\n }\n\n .liforma-et--parallax {\n --liforma-et-bg-scale: 1;\n --liforma-et-fg-scale: 1;\n --liforma-et-avatar-scale: 1;\n --liforma-et-bg-shift: 0px;\n --liforma-et-fg-shift: 0px;\n --liforma-et-avatar-shift: 0px;\n }\n\n .liforma-et--parallax.liforma-et--fit-face {\n --liforma-et-avatar-scale: 1.85;\n --liforma-et-bg-scale: 1.85;\n --liforma-et-fg-scale: 1.85;\n }\n\n .liforma-et__background,\n .liforma-et__foreground,\n .liforma-et__avatar {\n transition: none;\n }\n}", X = !1;
309
+ function oe(e) {
297
310
  if (typeof document > "u" || X) return;
298
311
  if (document.querySelector("style[data-liforma-et]")) {
299
312
  X = !0;
@@ -304,7 +317,7 @@ function re(e) {
304
317
  }
305
318
  //#endregion
306
319
  //#region src/thumbnail/plateDelivery.ts
307
- var ie = "data:image/avif;base64,AAAAIGZ0eXBhdmlmAAAAAGF2aWZtaWYxbWlhZk1BMUIAAADybWV0YQAAAAAAAAAoaGRscgAAAAAAAAAAcGljdAAAAAAAAAAAAAAAAGxpYmF2aWYAAAAADnBpdG0AAAAAAAEAAAAeaWxvYwAAAABEAAABAAEAAAABAAABGgAAAB0AAAAoaWluZgAAAAAAAQAAABppbmZlAgAAAAABAABhdjAxQ29sb3IAAAAAamlwcnAAAABLaXBjbwAAABRpc3BlAAAAAAAAAAEAAAABAAAAEHBpeGkAAAAAAwgICAAAAAxhdjFDgQ0MAAAAABNjb2xybmNseAACAAIAAYAAAAAXaXBtYQAAAAAAAAABAAEEAQKDBAAAACVtZGF0EgAKCBgANogQEAwgMg8f8D///8WfhwB8+ErK42A=", Z = null;
320
+ var se = "data:image/avif;base64,AAAAIGZ0eXBhdmlmAAAAAGF2aWZtaWYxbWlhZk1BMUIAAADybWV0YQAAAAAAAAAoaGRscgAAAAAAAAAAcGljdAAAAAAAAAAAAAAAAGxpYmF2aWYAAAAADnBpdG0AAAAAAAEAAAAeaWxvYwAAAABEAAABAAEAAAABAAABGgAAAB0AAAAoaWluZgAAAAAAAQAAABppbmZlAgAAAAABAABhdjAxQ29sb3IAAAAAamlwcnAAAABLaXBjbwAAABRpc3BlAAAAAAAAAAEAAAABAAAAEHBpeGkAAAAAAwgICAAAAAxhdjFDgQ0MAAAAABNjb2xybmNseAACAAIAAYAAAAAXaXBtYQAAAAAAAAABAAEEAQKDBAAAACVtZGF0EgAKCBgANogQEAwgMg8f8D///8WfhwB8+ErK42A=", Z = null;
308
321
  function Q(e) {
309
322
  let t = e.trim();
310
323
  if (!t || t.startsWith("blob:") || t.startsWith("data:")) return !1;
@@ -318,26 +331,26 @@ function $(e) {
318
331
  let n = e.slice(0, t), r = e.slice(t);
319
332
  return `${n.replace(/\.webp$/i, ".avif")}${r}`;
320
333
  }
321
- function ae() {
334
+ function ce() {
322
335
  return typeof Image > "u" ? Promise.resolve(!1) : (Z ||= new Promise((e) => {
323
336
  let t = new Image();
324
- t.onload = () => e(t.naturalWidth > 0 && t.naturalHeight > 0), t.onerror = () => e(!1), t.src = ie;
337
+ t.onload = () => e(t.naturalWidth > 0 && t.naturalHeight > 0), t.onerror = () => e(!1), t.src = se;
325
338
  }), Z);
326
339
  }
327
- function oe(e, t) {
340
+ function le(e, t) {
328
341
  return t ? $(e) ?? e : e;
329
342
  }
330
- function se(e) {
343
+ function ue(e) {
331
344
  let t = e.trim(), n = t.search(/[?#]/), r = n < 0 ? t : t.slice(0, n);
332
345
  if (!/\.avif$/i.test(r)) return null;
333
346
  let i = r.replace(/\.avif$/i, ".webp");
334
347
  return n < 0 ? i : `${i}${t.slice(n)}`;
335
348
  }
336
- function ce(e) {
349
+ function de(e) {
337
350
  let t = e.trim();
338
351
  return /-400x225\.(webp|avif)(?:$|[?#])/i.test(t) ? t.replace(/-400x225\.(webp|avif)/i, "-800x450.$1") : null;
339
352
  }
340
353
  //#endregion
341
- export { w as COARSE_THUMB_LOAD_CONCURRENCY, T as COARSE_THUMB_LOAD_STAGGER_MS, o as DEFAULT_THUMBNAIL_CDN_BASE_URL, Y as EXPERIENCE_THUMBNAIL_CSS, t as THUMBNAIL_LOCATION_PLATE_SIZES, L as attachImageReady, I as attachLazyThumb, q as attachScrollLinkedParallax, a as attachThumbnailBox, J as attachThumbnailParallax, S as buildHostedLaunchUrl, re as ensureExperienceThumbnailStyles, m as expandThumbnailAvatarUrl, p as expandThumbnailLocationUrl, N as getDefaultLazyRootMargin, z as horizontalParallaxFromViewportY, Q as isColourPlateWebpUrl, c as normalizeThumbnailCdnBaseUrl, r as pickThumbnailLocationPlateSize, E as prefersCoarsePointer, R as prefersScrollLinkedParallax, x as resolvePlayerBaseUrl, C as resolveThumbnailHref, ne as resolveThumbnailInteraction, v as resolveThumbnailLayers, i as rewriteThumbnailLocationPlateSize, M as scheduleThumbLoad, ae as supportsAvifDecode, se as thumbnailColourPlateWebpFallbackUrl, e as thumbnailFitClass, ce as thumbnailLocationPlateFallbackUrl, oe as thumbnailPlateSrc, $ as toAvifPlateUrl, _ as toGalleryThumbUrl };
354
+ export { O as COARSE_THUMB_LOAD_CONCURRENCY, ne as COARSE_THUMB_LOAD_STAGGER_MS, u as DEFAULT_THUMBNAIL_CDN_BASE_URL, ae as EXPERIENCE_THUMBNAIL_CSS, t as THUMBNAIL_AVATAR_PLATE_SIZES, a as THUMBNAIL_LOCATION_PLATE_SIZES, z as attachImageReady, R as attachLazyThumb, Y as attachScrollLinkedParallax, l as attachThumbnailBox, ie as attachThumbnailParallax, E as buildHostedLaunchUrl, oe as ensureExperienceThumbnailStyles, v as expandThumbnailAvatarUrl, _ as expandThumbnailLocationUrl, I as getDefaultLazyRootMargin, V as horizontalParallaxFromViewportY, Q as isColourPlateWebpUrl, f as normalizeThumbnailCdnBaseUrl, r as pickThumbnailAvatarPlateSize, s as pickThumbnailLocationPlateSize, k as prefersCoarsePointer, B as prefersScrollLinkedParallax, T as resolvePlayerBaseUrl, D as resolveThumbnailHref, w as resolveThumbnailInteraction, S as resolveThumbnailLayers, i as rewriteThumbnailAvatarPlateSize, c as rewriteThumbnailLocationPlateSize, F as scheduleThumbLoad, ce as supportsAvifDecode, ue as thumbnailColourPlateWebpFallbackUrl, e as thumbnailFitClass, de as thumbnailLocationPlateFallbackUrl, le as thumbnailPlateSrc, $ as toAvifPlateUrl, x as toGalleryThumbUrl };
342
355
 
343
356
  //# sourceMappingURL=index.js.map