@livo-tv/blocks 1.1.0 → 1.3.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/README.md +23 -0
- package/dist/index.cjs +630 -128
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +82 -1
- package/dist/index.d.ts +82 -1
- package/dist/index.js +568 -70
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -41,6 +41,29 @@ import { VideoPlayer } from "@livo-tv/blocks";
|
|
|
41
41
|
|
|
42
42
|
The package is reporting-agnostic. Wire `onError` / `onFirstPlay` in the app.
|
|
43
43
|
|
|
44
|
+
## Curtains
|
|
45
|
+
|
|
46
|
+
`CurtainPicker` is presentational. Apps load the catalog, upload, and confirm deletes; the block only renders tiles and calls back.
|
|
47
|
+
|
|
48
|
+
```tsx
|
|
49
|
+
import { CurtainPicker, CurtainPickerSkeleton } from "@livo-tv/blocks";
|
|
50
|
+
|
|
51
|
+
<CurtainPicker
|
|
52
|
+
curtains={curtains}
|
|
53
|
+
value={curtainId}
|
|
54
|
+
onChange={setCurtainId}
|
|
55
|
+
allowNone
|
|
56
|
+
groupByOwner
|
|
57
|
+
variant="compact"
|
|
58
|
+
onMakeDefault={setDefault}
|
|
59
|
+
onDelete={requestDelete}
|
|
60
|
+
canDelete={(curtain) => curtain.ownerType === "organization"}
|
|
61
|
+
labels={t.raw("curtains.picker")}
|
|
62
|
+
/>;
|
|
63
|
+
```
|
|
64
|
+
|
|
65
|
+
Image tiles use the asset URL. Video tiles show a muted looping preview only while the card is on screen, and freeze on `prefers-reduced-motion`. `variant="compact"` is a selected preview plus a dense thumbnail grid (thumbs stay frozen). Pass `isDefault` on each item (org setting or platform flag). Use `CurtainPickerSkeleton` for a layout-matched loading state.
|
|
66
|
+
|
|
44
67
|
## Avatar
|
|
45
68
|
|
|
46
69
|
```tsx
|