hyperframes 0.8.4 → 0.8.5

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.
@@ -1,4 +1,4 @@
1
- import{n as Qi}from"./index-KH4Y5JCd.js";/*!
1
+ import{n as Qi}from"./index-Cx_UrhoW.js";/*!
2
2
  * Copyright (c) 2026-present, Vanilagy and contributors
3
3
  *
4
4
  * This Source Code Form is subject to the terms of the Mozilla Public
@@ -1 +1 @@
1
- import{g as P}from"./index-KH4Y5JCd.js";function j(c,d){for(var s=0;s<d.length;s++){const a=d[s];if(typeof a!="string"&&!Array.isArray(a)){for(const i in a)if(i!=="default"&&!(i in c)){const l=Object.getOwnPropertyDescriptor(a,i);l&&Object.defineProperty(c,i,l.get?l:{enumerable:!0,get:()=>a[i]})}}}return Object.freeze(Object.defineProperty(c,Symbol.toStringTag,{value:"Module"}))}var v={},w;function k(){if(w)return v;w=1,Object.defineProperty(v,"__esModule",{value:!0}),v.default=d;var c=window.OfflineAudioContext||window.webkitOfflineAudioContext;function d(e){var r=a(e);return r.start(0),[i,y,O(e.sampleRate),s].reduce(function(t,o){return o(t)},r.buffer.getChannelData(0))}function s(e){return e.sort(function(r,t){return t.count-r.count}).splice(0,5)[0].tempo}function a(e){var r=e.length,t=e.numberOfChannels,o=e.sampleRate,n=new c(t,r,o),u=n.createBufferSource();u.buffer=e;var f=n.createBiquadFilter();return f.type="lowpass",u.connect(f),f.connect(n.destination),u}function i(e){for(var r=[],t=.9,o=.3,n=15;r.length<n&&t>=o;)r=l(e,t),t-=.05;if(r.length<n)throw new Error("Could not find enough samples for a reliable detection.");return r}function l(e,r){for(var t=[],o=0,n=e.length;o<n;o+=1)e[o]>r&&(t.push(o),o+=1e4);return t}function y(e){var r=[];return e.forEach(function(t,o){for(var n=function(x){var g=e[o+x]-t,_=r.some(function(h){if(h.interval===g)return h.count+=1});_||r.push({interval:g,count:1})},u=0;u<10;u+=1)n(u)}),r}function O(e){return function(r){var t=[];return r.forEach(function(o){if(o.interval!==0){for(var n=60/(o.interval/e);n<90;)n*=2;for(;n>180;)n/=2;n=Math.round(n);var u=t.some(function(f){if(f.tempo===n)return f.count+=o.count});u||t.push({tempo:n,count:o.count})}}),t}}return v}var p,b;function q(){return b||(b=1,p=k().default),p}var m=q();const A=P(m),D=j({__proto__:null,default:A},[m]);export{D as i};
1
+ import{g as P}from"./index-Cx_UrhoW.js";function j(c,d){for(var s=0;s<d.length;s++){const a=d[s];if(typeof a!="string"&&!Array.isArray(a)){for(const i in a)if(i!=="default"&&!(i in c)){const l=Object.getOwnPropertyDescriptor(a,i);l&&Object.defineProperty(c,i,l.get?l:{enumerable:!0,get:()=>a[i]})}}}return Object.freeze(Object.defineProperty(c,Symbol.toStringTag,{value:"Module"}))}var v={},w;function k(){if(w)return v;w=1,Object.defineProperty(v,"__esModule",{value:!0}),v.default=d;var c=window.OfflineAudioContext||window.webkitOfflineAudioContext;function d(e){var r=a(e);return r.start(0),[i,y,O(e.sampleRate),s].reduce(function(t,o){return o(t)},r.buffer.getChannelData(0))}function s(e){return e.sort(function(r,t){return t.count-r.count}).splice(0,5)[0].tempo}function a(e){var r=e.length,t=e.numberOfChannels,o=e.sampleRate,n=new c(t,r,o),u=n.createBufferSource();u.buffer=e;var f=n.createBiquadFilter();return f.type="lowpass",u.connect(f),f.connect(n.destination),u}function i(e){for(var r=[],t=.9,o=.3,n=15;r.length<n&&t>=o;)r=l(e,t),t-=.05;if(r.length<n)throw new Error("Could not find enough samples for a reliable detection.");return r}function l(e,r){for(var t=[],o=0,n=e.length;o<n;o+=1)e[o]>r&&(t.push(o),o+=1e4);return t}function y(e){var r=[];return e.forEach(function(t,o){for(var n=function(x){var g=e[o+x]-t,_=r.some(function(h){if(h.interval===g)return h.count+=1});_||r.push({interval:g,count:1})},u=0;u<10;u+=1)n(u)}),r}function O(e){return function(r){var t=[];return r.forEach(function(o){if(o.interval!==0){for(var n=60/(o.interval/e);n<90;)n*=2;for(;n>180;)n/=2;n=Math.round(n);var u=t.some(function(f){if(f.tempo===n)return f.count+=o.count});u||t.push({tempo:n,count:o.count})}}),t}}return v}var p,b;function q(){return b||(b=1,p=k().default),p}var m=q();const A=P(m),D=j({__proto__:null,default:A},[m]);export{D as i};
@@ -5,7 +5,7 @@
5
5
  <meta name="viewport" content="width=device-width, initial-scale=1.0, viewport-fit=cover" />
6
6
  <link rel="icon" type="image/svg+xml" href="/favicon.svg" />
7
7
  <title>HyperFrames Studio</title>
8
- <script type="module" crossorigin src="/assets/index-KH4Y5JCd.js"></script>
8
+ <script type="module" crossorigin src="/assets/index-Cx_UrhoW.js"></script>
9
9
  <link rel="stylesheet" crossorigin href="/assets/index-DcF4s1PG.css">
10
10
  </head>
11
11
  <body>
@@ -21832,12 +21832,14 @@ function buildCompositionThumbnailUrl({
21832
21832
  duration = 5,
21833
21833
  selector,
21834
21834
  selectorIndex,
21835
- origin
21835
+ origin,
21836
+ output
21836
21837
  }) {
21837
21838
  const thumbnailBase = previewUrl.replace("/preview/comp/", "/thumbnail/").replace(/\/preview$/, "/thumbnail/index.html");
21838
21839
  const thumbnailUrl2 = new URL(thumbnailBase, origin);
21839
21840
  thumbnailUrl2.searchParams.set("t", (seekTime + duration / 2).toFixed(2));
21840
21841
  thumbnailUrl2.searchParams.set("v", THUMBNAIL_URL_VERSION);
21842
+ if (output) thumbnailUrl2.searchParams.set("output", output);
21841
21843
  if (selector) {
21842
21844
  thumbnailUrl2.searchParams.set("selector", selector);
21843
21845
  if (selectorIndex != null && selectorIndex > 0) {
@@ -81033,11 +81035,11 @@ function FramePoster({
81033
81035
  src,
81034
81036
  seconds,
81035
81037
  title,
81036
- fit = "cover",
81038
+ surface = "tile",
81037
81039
  posterVersion
81038
81040
  }) {
81039
81041
  const [failed2, setFailed] = useState140(false);
81040
- useEffect126(() => setFailed(false), [src, seconds, posterVersion]);
81042
+ useEffect126(() => setFailed(false), [src, seconds, posterVersion, surface]);
81041
81043
  if (failed2) {
81042
81044
  return /* @__PURE__ */ jsx195("div", { className: "flex h-full w-full items-center justify-center text-[11px] text-neutral-600", children: "Preview unavailable" });
81043
81045
  }
@@ -81045,7 +81047,11 @@ function FramePoster({
81045
81047
  previewUrl: `/api/projects/${projectId}/preview/comp/${src}`,
81046
81048
  seekTime: seconds,
81047
81049
  duration: 0,
81048
- origin: window.location.origin
81050
+ origin: window.location.origin,
81051
+ // The normal 240x135 preview is unreadable in the contact sheet, while source
81052
+ // density is unbounded across all tiles. Give tiles a capped review density
81053
+ // and reserve true source output for the single focus hero.
81054
+ output: surface === "hero" ? "source" : "storyboard"
81049
81055
  });
81050
81056
  if (posterVersion) {
81051
81057
  const withVersion = new URL(url, window.location.origin);
@@ -81060,7 +81066,7 @@ function FramePoster({
81060
81066
  draggable: false,
81061
81067
  loading: "lazy",
81062
81068
  onError: () => setFailed(true),
81063
- className: `h-full w-full ${fit === "contain" ? "object-contain" : "object-cover"}`
81069
+ className: `h-full w-full ${surface === "hero" ? "object-contain" : "object-cover"}`
81064
81070
  }
81065
81071
  );
81066
81072
  }
@@ -81581,7 +81587,7 @@ function StoryboardFrameFocus({
81581
81587
  src: frame.src,
81582
81588
  seconds: posterTime(frame),
81583
81589
  title,
81584
- fit: "contain",
81590
+ surface: "hero",
81585
81591
  posterVersion
81586
81592
  }
81587
81593
  ) : /* @__PURE__ */ jsx201(FramePlan, { frame }) }) }),