reifyui 0.10.0 → 0.10.1

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
@@ -679,8 +679,12 @@ export interface TimelineClip {
679
679
  label?: string;
680
680
  /** Tooltip. Falls back to `label`. */
681
681
  title?: string;
682
- /** Artwork filling the block — a poster frame, a waveform. */
682
+ /** Artwork filling the block, tiled at a fixed tile size — a poster frame, a waveform. */
683
683
  poster?: string;
684
+ /** A playable file. Used only when there is no `poster`: its FIRST FRAME is shown, which is a
685
+ * real frame of the real clip rather than a stand-in. Loaded with preload="metadata", so the
686
+ * whole file is not fetched to paint one frame. */
687
+ video?: string;
684
688
  /** Shown centred when there is no poster. */
685
689
  glyph?: ReactNode;
686
690
  /** Small pill at the top left, e.g. an index. */
package/dist/index.js CHANGED
@@ -4431,7 +4431,18 @@ function Clip({
4431
4431
  clip.poster ? /* @__PURE__ */ jsx25("span", { className: "rui-tl-strip", style: {
4432
4432
  backgroundImage: `url("${String(clip.poster).replace(/"/g, '\\"')}")`,
4433
4433
  backgroundSize: `${tileW}px 100%`
4434
- } }) : /* @__PURE__ */ jsx25("span", { className: "rui-tl-blank", "aria-hidden": "true", children: clip.glyph }),
4434
+ } }) : clip.video ? /* @__PURE__ */ jsx25(
4435
+ "video",
4436
+ {
4437
+ className: "rui-tl-frame",
4438
+ src: clip.video,
4439
+ preload: "metadata",
4440
+ muted: true,
4441
+ playsInline: true,
4442
+ tabIndex: -1,
4443
+ "aria-hidden": "true"
4444
+ }
4445
+ ) : /* @__PURE__ */ jsx25("span", { className: "rui-tl-blank", "aria-hidden": "true", children: clip.glyph }),
4435
4446
  clip.badge && /* @__PURE__ */ jsx25("span", { className: "rui-tl-badge", children: clip.badge }),
4436
4447
  known && width > 46 && /* @__PURE__ */ jsx25("span", { className: "rui-tl-dur", children: durationLabel(clip.duration) }),
4437
4448
  clip.label && width > 104 && /* @__PURE__ */ jsx25("span", { className: "rui-tl-name", children: clip.label }),