@retoo/scena 0.1.0 → 0.1.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 +17 -17
- package/dist/scena.cjs.js +6 -5
- package/dist/scena.es.js +5 -5
- package/dist/scena.min.cjs.js +103 -103
- package/dist/scena.min.es.js +9 -9
- package/dist/scena.min.umd.js +52 -52
- package/dist/scena.umd.js +6 -5
- package/package.json +1 -1
package/dist/index.d.ts
CHANGED
|
@@ -1,5 +1,3 @@
|
|
|
1
|
-
export { default as Scena } from './app/entrypoint/ui/Scena.svelte';
|
|
2
|
-
|
|
3
1
|
/** Event names emitted by the scena widget event bus. */
|
|
4
2
|
declare enum ScenaEvent {
|
|
5
3
|
/** Fired when the scena instance is destroyed. */
|
|
@@ -1183,22 +1181,11 @@ declare function useScenaVisibility(config: UseScenaConfigReturns, eventEmitter:
|
|
|
1183
1181
|
*/
|
|
1184
1182
|
declare function useScenaResponsive(config: UseScenaConfigReturns, configOverrides: UseScenaOverridesReturns): UseScenaResponsiveReturns;
|
|
1185
1183
|
|
|
1186
|
-
/**
|
|
1187
|
-
* Returns the custom element constructor if it has already been registered.
|
|
1188
|
-
*
|
|
1189
|
-
* @returns The registered `CustomElementConstructor`, or `undefined` if not yet defined.
|
|
1190
|
-
*/
|
|
1191
|
-
declare function getScenaElement(): CustomElementConstructor | undefined;
|
|
1192
|
-
/**
|
|
1193
|
-
* Registers the `<scena-video-widget>` custom element in the browser.
|
|
1194
|
-
*
|
|
1195
|
-
* Safe to call multiple times — skips registration if the element is already defined.
|
|
1196
|
-
*/
|
|
1197
|
-
declare function defineScenaElement(): void;
|
|
1198
|
-
|
|
1199
1184
|
/** The HTML tag name used for the scena custom element. */
|
|
1200
1185
|
type ScenaElementTag = 'scena-video-widget';
|
|
1201
1186
|
|
|
1187
|
+
declare const TAG_NAME: ScenaElementTag;
|
|
1188
|
+
|
|
1202
1189
|
/**
|
|
1203
1190
|
* SSR-safe `HTMLElement` constructor.
|
|
1204
1191
|
*
|
|
@@ -1209,6 +1196,19 @@ type ScenaElementTag = 'scena-video-widget';
|
|
|
1209
1196
|
*/
|
|
1210
1197
|
declare const SAFE_HTML_ELEMENT: typeof HTMLElement;
|
|
1211
1198
|
|
|
1199
|
+
/**
|
|
1200
|
+
* Returns the custom element constructor if it has already been registered.
|
|
1201
|
+
*
|
|
1202
|
+
* @returns The registered `CustomElementConstructor`, or `undefined` if not yet defined.
|
|
1203
|
+
*/
|
|
1204
|
+
declare function getScenaElement(): CustomElementConstructor | undefined;
|
|
1205
|
+
/**
|
|
1206
|
+
* Registers the `<scena-video-widget>` custom element in the browser.
|
|
1207
|
+
*
|
|
1208
|
+
* Safe to call multiple times — skips registration if the element is already defined.
|
|
1209
|
+
*/
|
|
1210
|
+
declare function defineScenaElement(): void;
|
|
1211
|
+
|
|
1212
1212
|
/**
|
|
1213
1213
|
* Custom HTML element that wraps the scena video widget.
|
|
1214
1214
|
*
|
|
@@ -1279,5 +1279,5 @@ interface ScenaContext {
|
|
|
1279
1279
|
declare const getScenaContext: () => ScenaContext;
|
|
1280
1280
|
declare const setScenaContext: (context: ScenaContext) => ScenaContext;
|
|
1281
1281
|
|
|
1282
|
-
export { ComponentAriaHaspopup, ComponentAriaPressed, ComponentPlacement, ComponentPosition, ComponentShape, ComponentSize, OverrideLayer, ScenaButtonAriaHaspopup, ScenaButtonAriaPressed, ScenaButtonShape, ScenaButtonType, ScenaButtonVariant, ScenaCtaButtonPlacement, ScenaElement, ScenaEvent, ScenaVideoCrossOrigin, ScenaVideoPreload, ScenaVideoProgressVariant, ScenaVideoState, defineScenaElement, getScenaContext, getScenaElement, getScenaVideoContext, scenaProgressCircleThicknessMap, scenaProgressLineThicknessMap, setScenaContext, setScenaVideoContext, useEventEmitter, useProgressCircle, useProgressLine, useScena, useScenaConfig, useScenaOverrides, useScenaPreview, useScenaResponsive, useScenaVisibility, useVideoController };
|
|
1283
|
-
export type { ComponentAriaProps, ComponentClasses, ComponentRef, ComponentSnippet, ComponentSnippetReturn, ComponentStyles, ScenaApi, ScenaButtonComponentClasses, ScenaButtonComponentStyles, ScenaButtonElements, ScenaButtonEvents, ScenaButtonProps, ScenaButtonSnippets, ScenaCloseButtonComponentClasses, ScenaCloseButtonComponentHtml, ScenaCloseButtonComponentStyles, ScenaCloseButtonElements, ScenaCloseButtonProps, ScenaCloseButtonRef, ScenaComponents, ScenaConfig, ScenaConfigFeatures, ScenaConfigOverrides, ScenaContainerCustomClasses, ScenaContainerCustomStyles, ScenaContainerElements, ScenaContainerProps, ScenaContainerRef, ScenaContainerSnippets, ScenaContext, ScenaCtaButtonAdaptive, ScenaCtaButtonComponentClasses, ScenaCtaButtonComponentHtml, ScenaCtaButtonComponentStyles, ScenaCtaButtonElements, ScenaCtaButtonProps, ScenaCtaButtonRef, ScenaElementTag, ScenaEventEmitter, ScenaEventHandler, ScenaEventMap, ScenaFeatures, ScenaIconCustomClasses, ScenaIconCustomStyles, ScenaIconElements, ScenaIconProps, ScenaIconSnippets, ScenaInstance, ScenaLoaderCustomClasses, ScenaLoaderCustomStyles, ScenaLoaderElements, ScenaLoaderProps, ScenaOverrides, ScenaPreviewApi, ScenaPreviewConfig, ScenaProgressCircleComponentClasses, ScenaProgressCircleComponentStyles, ScenaProgressCircleElements, ScenaProgressCircleEvents, ScenaProgressCircleProps, ScenaProgressComponentThickness, ScenaProgressLineComponentClasses, ScenaProgressLineComponentStyles, ScenaProgressLineElements, ScenaProgressLineEvents, ScenaProgressLineProps, ScenaProgressThickness, ScenaProps, ScenaRef, ScenaResponsiveApi, ScenaResponsiveConfig, ScenaTarget, ScenaVideoCallbacks, ScenaVideoComponentClasses, ScenaVideoComponentStyles, ScenaVideoContainerCustomClasses, ScenaVideoContainerCustomStyles, ScenaVideoContainerElements, ScenaVideoContainerProps, ScenaVideoContainerRef, ScenaVideoContainerSnippets, ScenaVideoContext, ScenaVideoControlsComponentAria, ScenaVideoControlsComponentClasses, ScenaVideoControlsComponentHtml, ScenaVideoControlsComponentStyles, ScenaVideoControlsElements, ScenaVideoControlsProps, ScenaVideoControlsRef, ScenaVideoData, ScenaVideoElements, ScenaVideoEventOptions, ScenaVideoEventOptionsWithError, ScenaVideoEventOptionsWithEvent, ScenaVideoLoaderComponentClasses, ScenaVideoLoaderComponentHtml, ScenaVideoLoaderComponentStyles, ScenaVideoLoaderElements, ScenaVideoLoaderProps, ScenaVideoLoaderRef, ScenaVideoMethods, ScenaVideoProgressComponentClasses, ScenaVideoProgressComponentStyles, ScenaVideoProgressComponentThickness, ScenaVideoProgressElements, ScenaVideoProgressProps, ScenaVideoProgressRef, ScenaVideoProgressThickness, ScenaVideoProgressThicknessMap, ScenaVideoProps, ScenaVideoRef, ScenaVideoSnippets, ScenaVideoVolumeComponentAria, ScenaVideoVolumeComponentClasses, ScenaVideoVolumeComponentHtml, ScenaVideoVolumeComponentStyles, ScenaVideoVolumeElements, ScenaVideoVolumeProps, ScenaVideoVolumeRef, ScenaVisibilityApi, ScenaVisibilityConfig, UseProgressCircleEvents, UseProgressCircleProps, UseProgressCircleReturn, UseProgressCircleReturnEvents, UseProgressLineEvents, UseProgressLineProps, UseProgressLineReturn, UseProgressLineReturnEvents, UseScenaConfigReturns, UseScenaOverridesReturns, UseScenaPreviewOptions, UseScenaPreviewReturns, UseScenaResponsiveReturns, UseScenaReturns, UseScenaVisibilityReturns, UseVideoControllerOptions, UseVideoControllerReturns };
|
|
1282
|
+
export { ComponentAriaHaspopup, ComponentAriaPressed, ComponentPlacement, ComponentPosition, ComponentShape, ComponentSize, OverrideLayer, SAFE_HTML_ELEMENT, ScenaButtonAriaHaspopup, ScenaButtonAriaPressed, ScenaButtonShape, ScenaButtonType, ScenaButtonVariant, ScenaCtaButtonPlacement, ScenaElement, ScenaEvent, ScenaVideoCrossOrigin, ScenaVideoPreload, ScenaVideoProgressVariant, ScenaVideoState, TAG_NAME, defineScenaElement, getScenaContext, getScenaElement, getScenaVideoContext, scenaProgressCircleThicknessMap, scenaProgressLineThicknessMap, setScenaContext, setScenaVideoContext, useEventEmitter, useProgressCircle, useProgressLine, useScena, useScenaConfig, useScenaOverrides, useScenaPreview, useScenaResponsive, useScenaVisibility, useVideoController };
|
|
1283
|
+
export type { ComponentAriaProps, ComponentClasses, ComponentRef, ComponentSnippet, ComponentSnippetReturn, ComponentStyles, ScenaApi, ScenaButtonComponentClasses, ScenaButtonComponentStyles, ScenaButtonElements, ScenaButtonEvents, ScenaButtonProps, ScenaButtonSnippets, ScenaCloseButtonComponentClasses, ScenaCloseButtonComponentHtml, ScenaCloseButtonComponentStyles, ScenaCloseButtonElements, ScenaCloseButtonProps, ScenaCloseButtonRef, ScenaComponents, ScenaConfig, ScenaConfigFeatures, ScenaConfigOverrides, ScenaContainerCustomClasses, ScenaContainerCustomStyles, ScenaContainerElements, ScenaContainerProps, ScenaContainerRef, ScenaContainerSnippets, ScenaContext, ScenaCtaButtonAdaptive, ScenaCtaButtonComponentClasses, ScenaCtaButtonComponentHtml, ScenaCtaButtonComponentStyles, ScenaCtaButtonElements, ScenaCtaButtonProps, ScenaCtaButtonRef, ScenaElementTag, ScenaEventEmitter, ScenaEventHandler, ScenaEventMap, ScenaFeatures, ScenaIconCustomClasses, ScenaIconCustomStyles, ScenaIconElements, ScenaIconProps, ScenaIconSnippets, ScenaInstance, ScenaLoaderCustomClasses, ScenaLoaderCustomStyles, ScenaLoaderElements, ScenaLoaderProps, ScenaOverrides, ScenaPreviewApi, ScenaPreviewBehavior, ScenaPreviewConfig, ScenaProgressCircleComponentClasses, ScenaProgressCircleComponentStyles, ScenaProgressCircleElements, ScenaProgressCircleEvents, ScenaProgressCircleProps, ScenaProgressComponentThickness, ScenaProgressLineComponentClasses, ScenaProgressLineComponentStyles, ScenaProgressLineElements, ScenaProgressLineEvents, ScenaProgressLineProps, ScenaProgressThickness, ScenaProps, ScenaRef, ScenaResponsiveApi, ScenaResponsiveConfig, ScenaTarget, ScenaVideoCallbacks, ScenaVideoComponentClasses, ScenaVideoComponentStyles, ScenaVideoContainerCustomClasses, ScenaVideoContainerCustomStyles, ScenaVideoContainerElements, ScenaVideoContainerProps, ScenaVideoContainerRef, ScenaVideoContainerSnippets, ScenaVideoContext, ScenaVideoControlsComponentAria, ScenaVideoControlsComponentClasses, ScenaVideoControlsComponentHtml, ScenaVideoControlsComponentStyles, ScenaVideoControlsElements, ScenaVideoControlsProps, ScenaVideoControlsRef, ScenaVideoData, ScenaVideoElements, ScenaVideoEventOptions, ScenaVideoEventOptionsWithError, ScenaVideoEventOptionsWithEvent, ScenaVideoLoaderComponentClasses, ScenaVideoLoaderComponentHtml, ScenaVideoLoaderComponentStyles, ScenaVideoLoaderElements, ScenaVideoLoaderProps, ScenaVideoLoaderRef, ScenaVideoMethods, ScenaVideoProgressComponentClasses, ScenaVideoProgressComponentStyles, ScenaVideoProgressComponentThickness, ScenaVideoProgressElements, ScenaVideoProgressProps, ScenaVideoProgressRef, ScenaVideoProgressThickness, ScenaVideoProgressThicknessMap, ScenaVideoProps, ScenaVideoRef, ScenaVideoSnippets, ScenaVideoVolumeComponentAria, ScenaVideoVolumeComponentClasses, ScenaVideoVolumeComponentHtml, ScenaVideoVolumeComponentStyles, ScenaVideoVolumeElements, ScenaVideoVolumeProps, ScenaVideoVolumeRef, ScenaVisibilityApi, ScenaVisibilityConfig, UseProgressCircleEvents, UseProgressCircleProps, UseProgressCircleReturn, UseProgressCircleReturnEvents, UseProgressLineEvents, UseProgressLineProps, UseProgressLineReturn, UseProgressLineReturnEvents, UseScenaConfigReturns, UseScenaOverridesReturns, UseScenaPreviewOptions, UseScenaPreviewReturns, UseScenaResponsiveReturns, UseScenaReturns, UseScenaVisibilityReturns, UseVideoControllerOptions, UseVideoControllerReturns };
|
package/dist/scena.cjs.js
CHANGED
|
@@ -7464,7 +7464,7 @@ function useScena() {
|
|
|
7464
7464
|
}
|
|
7465
7465
|
return {
|
|
7466
7466
|
NAME: "@retoo/scena",
|
|
7467
|
-
VERSION: "0.0
|
|
7467
|
+
VERSION: "0.1.0",
|
|
7468
7468
|
mount: mount$1,
|
|
7469
7469
|
unmount: unmount$1
|
|
7470
7470
|
};
|
|
@@ -7852,12 +7852,12 @@ function useScenaResponsive(config, configOverrides) {
|
|
|
7852
7852
|
/** Register matchMedia listeners for each breakpoint */
|
|
7853
7853
|
for (const breakpoint of sortedBreakpoints) {
|
|
7854
7854
|
/** Create media query for current breakpoint */
|
|
7855
|
-
const
|
|
7855
|
+
const mql = window.matchMedia(`(max-width: ${breakpoint}px)`);
|
|
7856
7856
|
/** Handler that recalculates active breakpoint */
|
|
7857
7857
|
const handler = () => update(sortedBreakpoints, responsiveConfig);
|
|
7858
|
-
|
|
7858
|
+
mql.addEventListener("change", handler);
|
|
7859
7859
|
cleanups.push(() => {
|
|
7860
|
-
|
|
7860
|
+
mql.removeEventListener("change", handler);
|
|
7861
7861
|
});
|
|
7862
7862
|
}
|
|
7863
7863
|
/** Run initial evaluation to set the correct breakpoint on mount */
|
|
@@ -8034,7 +8034,7 @@ exports.ComponentPosition = ComponentPosition;
|
|
|
8034
8034
|
exports.ComponentShape = ComponentShape;
|
|
8035
8035
|
exports.ComponentSize = ComponentSize;
|
|
8036
8036
|
exports.OverrideLayer = OverrideLayer;
|
|
8037
|
-
exports.
|
|
8037
|
+
exports.SAFE_HTML_ELEMENT = SAFE_HTML_ELEMENT;
|
|
8038
8038
|
exports.ScenaButtonAriaHaspopup = ScenaButtonAriaHaspopup;
|
|
8039
8039
|
exports.ScenaButtonAriaPressed = ScenaButtonAriaPressed;
|
|
8040
8040
|
exports.ScenaButtonShape = ScenaButtonShape;
|
|
@@ -8047,6 +8047,7 @@ exports.ScenaVideoCrossOrigin = ScenaVideoCrossOrigin;
|
|
|
8047
8047
|
exports.ScenaVideoPreload = ScenaVideoPreload;
|
|
8048
8048
|
exports.ScenaVideoProgressVariant = ScenaVideoProgressVariant;
|
|
8049
8049
|
exports.ScenaVideoState = ScenaVideoState;
|
|
8050
|
+
exports.TAG_NAME = TAG_NAME;
|
|
8050
8051
|
exports.defineScenaElement = defineScenaElement;
|
|
8051
8052
|
exports.getScenaContext = getScenaContext;
|
|
8052
8053
|
exports.getScenaElement = getScenaElement;
|
package/dist/scena.es.js
CHANGED
|
@@ -7463,7 +7463,7 @@ function useScena() {
|
|
|
7463
7463
|
}
|
|
7464
7464
|
return {
|
|
7465
7465
|
NAME: "@retoo/scena",
|
|
7466
|
-
VERSION: "0.0
|
|
7466
|
+
VERSION: "0.1.0",
|
|
7467
7467
|
mount: mount$1,
|
|
7468
7468
|
unmount: unmount$1
|
|
7469
7469
|
};
|
|
@@ -7851,12 +7851,12 @@ function useScenaResponsive(config, configOverrides) {
|
|
|
7851
7851
|
/** Register matchMedia listeners for each breakpoint */
|
|
7852
7852
|
for (const breakpoint of sortedBreakpoints) {
|
|
7853
7853
|
/** Create media query for current breakpoint */
|
|
7854
|
-
const
|
|
7854
|
+
const mql = window.matchMedia(`(max-width: ${breakpoint}px)`);
|
|
7855
7855
|
/** Handler that recalculates active breakpoint */
|
|
7856
7856
|
const handler = () => update(sortedBreakpoints, responsiveConfig);
|
|
7857
|
-
|
|
7857
|
+
mql.addEventListener("change", handler);
|
|
7858
7858
|
cleanups.push(() => {
|
|
7859
|
-
|
|
7859
|
+
mql.removeEventListener("change", handler);
|
|
7860
7860
|
});
|
|
7861
7861
|
}
|
|
7862
7862
|
/** Run initial evaluation to set the correct breakpoint on mount */
|
|
@@ -8026,4 +8026,4 @@ if (isBrowser) {
|
|
|
8026
8026
|
window.defineScenaElement = defineScenaElement;
|
|
8027
8027
|
}
|
|
8028
8028
|
//#endregion
|
|
8029
|
-
export { ComponentAriaHaspopup, ComponentAriaPressed, ComponentPlacement, ComponentPosition, ComponentShape, ComponentSize, OverrideLayer,
|
|
8029
|
+
export { ComponentAriaHaspopup, ComponentAriaPressed, ComponentPlacement, ComponentPosition, ComponentShape, ComponentSize, OverrideLayer, SAFE_HTML_ELEMENT, ScenaButtonAriaHaspopup, ScenaButtonAriaPressed, ScenaButtonShape, ScenaButtonType, ScenaButtonVariant, ScenaCtaButtonPlacement, ScenaElement, ScenaEvent, ScenaVideoCrossOrigin, ScenaVideoPreload, ScenaVideoProgressVariant, ScenaVideoState, TAG_NAME, defineScenaElement, getScenaContext, getScenaElement, getScenaVideoContext, scenaProgressCircleThicknessMap, scenaProgressLineThicknessMap, setScenaContext, setScenaVideoContext, useEventEmitter, useProgressCircle, useProgressLine, useScena, useScenaConfig, useScenaOverrides, useScenaPreview, useScenaResponsive, useScenaVisibility, useVideoController };
|