@wistia/ui 0.18.0-beta.3a151a03.96acbe5 → 0.18.0-beta.3b5be3b3.9e2fe2f
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.cjs +19 -21
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.mts +0 -11
- package/dist/index.d.ts +0 -11
- package/dist/index.mjs +19 -21
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
package/dist/index.d.mts
CHANGED
|
@@ -4108,7 +4108,6 @@ declare const gradients: {
|
|
|
4108
4108
|
};
|
|
4109
4109
|
type GradientNameType = keyof typeof gradients;
|
|
4110
4110
|
|
|
4111
|
-
type AspectRatioType = 'square' | 'wide';
|
|
4112
4111
|
type Storyboard = {
|
|
4113
4112
|
__typename?: string;
|
|
4114
4113
|
aspectRatio: number;
|
|
@@ -4151,11 +4150,6 @@ type ThumbnailProps = Omit<ComponentPropsWithoutRef<'div'>, 'children'> & {
|
|
|
4151
4150
|
* Example: '180px'
|
|
4152
4151
|
*/
|
|
4153
4152
|
height?: string;
|
|
4154
|
-
/**
|
|
4155
|
-
* The aspect ratio of the thumbnail container.
|
|
4156
|
-
* 'wide' maps to 16:9 ratio, 'square' maps to 1:1 ratio.
|
|
4157
|
-
*/
|
|
4158
|
-
aspectRatio?: AspectRatioType;
|
|
4159
4153
|
};
|
|
4160
4154
|
/**
|
|
4161
4155
|
* A `Thumbnail` is a small, reduced-size version of an image or video used as a preview or representative image.
|
|
@@ -4191,11 +4185,6 @@ declare const Thumbnail: react.ForwardRefExoticComponent<Omit<Omit<react.Detaile
|
|
|
4191
4185
|
* Example: '180px'
|
|
4192
4186
|
*/
|
|
4193
4187
|
height?: string;
|
|
4194
|
-
/**
|
|
4195
|
-
* The aspect ratio of the thumbnail container.
|
|
4196
|
-
* 'wide' maps to 16:9 ratio, 'square' maps to 1:1 ratio.
|
|
4197
|
-
*/
|
|
4198
|
-
aspectRatio?: AspectRatioType;
|
|
4199
4188
|
} & react.RefAttributes<HTMLDivElement>>;
|
|
4200
4189
|
|
|
4201
4190
|
type ThumbnailCollageProps = {
|
package/dist/index.d.ts
CHANGED
|
@@ -4108,7 +4108,6 @@ declare const gradients: {
|
|
|
4108
4108
|
};
|
|
4109
4109
|
type GradientNameType = keyof typeof gradients;
|
|
4110
4110
|
|
|
4111
|
-
type AspectRatioType = 'square' | 'wide';
|
|
4112
4111
|
type Storyboard = {
|
|
4113
4112
|
__typename?: string;
|
|
4114
4113
|
aspectRatio: number;
|
|
@@ -4151,11 +4150,6 @@ type ThumbnailProps = Omit<ComponentPropsWithoutRef<'div'>, 'children'> & {
|
|
|
4151
4150
|
* Example: '180px'
|
|
4152
4151
|
*/
|
|
4153
4152
|
height?: string;
|
|
4154
|
-
/**
|
|
4155
|
-
* The aspect ratio of the thumbnail container.
|
|
4156
|
-
* 'wide' maps to 16:9 ratio, 'square' maps to 1:1 ratio.
|
|
4157
|
-
*/
|
|
4158
|
-
aspectRatio?: AspectRatioType;
|
|
4159
4153
|
};
|
|
4160
4154
|
/**
|
|
4161
4155
|
* A `Thumbnail` is a small, reduced-size version of an image or video used as a preview or representative image.
|
|
@@ -4191,11 +4185,6 @@ declare const Thumbnail: react.ForwardRefExoticComponent<Omit<Omit<react.Detaile
|
|
|
4191
4185
|
* Example: '180px'
|
|
4192
4186
|
*/
|
|
4193
4187
|
height?: string;
|
|
4194
|
-
/**
|
|
4195
|
-
* The aspect ratio of the thumbnail container.
|
|
4196
|
-
* 'wide' maps to 16:9 ratio, 'square' maps to 1:1 ratio.
|
|
4197
|
-
*/
|
|
4198
|
-
aspectRatio?: AspectRatioType;
|
|
4199
4188
|
} & react.RefAttributes<HTMLDivElement>>;
|
|
4200
4189
|
|
|
4201
4190
|
type ThumbnailCollageProps = {
|
package/dist/index.mjs
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
|
|
2
2
|
/*
|
|
3
|
-
* @license @wistia/ui v0.18.0-beta.
|
|
3
|
+
* @license @wistia/ui v0.18.0-beta.3b5be3b3.9e2fe2f
|
|
4
4
|
*
|
|
5
5
|
* Copyright (c) 2024-2025, Wistia, Inc. and its affiliates.
|
|
6
6
|
*
|
|
@@ -7724,6 +7724,7 @@ var StyledButton = styled5.button`
|
|
|
7724
7724
|
${({ $variant }) => buttonVariantsStyles[$variant]}
|
|
7725
7725
|
${({ $unstyled }) => !$unstyled && buttonBaseStyles}
|
|
7726
7726
|
${({ $fullWidth }) => $fullWidth && "width: 100%;"}
|
|
7727
|
+
align-self: flex-start;
|
|
7727
7728
|
text-align: center;
|
|
7728
7729
|
`;
|
|
7729
7730
|
var StyledButtonContent = styled5.div`
|
|
@@ -8939,6 +8940,10 @@ var ButtonGroupComponent = styled14.div`
|
|
|
8939
8940
|
justify-content: ${({ $align }) => getAlignment($align)};
|
|
8940
8941
|
width: ${({ $fullWidth }) => $fullWidth ? "100%" : "auto"};
|
|
8941
8942
|
|
|
8943
|
+
${StyledButton} {
|
|
8944
|
+
align-self: unset;
|
|
8945
|
+
}
|
|
8946
|
+
|
|
8942
8947
|
${mq.smAndUp} {
|
|
8943
8948
|
flex-direction: row;
|
|
8944
8949
|
}
|
|
@@ -17845,14 +17850,6 @@ var ThumbnailStoryboardViewer = ({
|
|
|
17845
17850
|
|
|
17846
17851
|
// src/components/Thumbnail/Thumbnail.tsx
|
|
17847
17852
|
import { jsx as jsx325, jsxs as jsxs69 } from "react/jsx-runtime";
|
|
17848
|
-
var WIDE_ASPECT_RATIO = 16 / 9;
|
|
17849
|
-
var SQUARE_ASPECT_RATIO = 1;
|
|
17850
|
-
var getAspectRatioValue = (aspectRatio) => {
|
|
17851
|
-
if (aspectRatio === "square") {
|
|
17852
|
-
return SQUARE_ASPECT_RATIO;
|
|
17853
|
-
}
|
|
17854
|
-
return WIDE_ASPECT_RATIO;
|
|
17855
|
-
};
|
|
17856
17853
|
var WideThumbnailImage = styled106.img`
|
|
17857
17854
|
height: 100%;
|
|
17858
17855
|
object-fit: cover;
|
|
@@ -17891,7 +17888,7 @@ var StyledThumbnail = styled106.div`
|
|
|
17891
17888
|
)};
|
|
17892
17889
|
background-position: center center;
|
|
17893
17890
|
background-size: cover;
|
|
17894
|
-
aspect-ratio:
|
|
17891
|
+
aspect-ratio: 16 / 9;
|
|
17895
17892
|
display: flex;
|
|
17896
17893
|
overflow: hidden;
|
|
17897
17894
|
position: relative;
|
|
@@ -17900,10 +17897,7 @@ var StyledThumbnail = styled106.div`
|
|
|
17900
17897
|
|
|
17901
17898
|
&,
|
|
17902
17899
|
img {
|
|
17903
|
-
border-radius:
|
|
17904
|
-
const heightPercentage = 8 / $aspectRatio;
|
|
17905
|
-
return `calc(8% * (1 / ${$aspectRatio})) / ${heightPercentage}%`;
|
|
17906
|
-
}};
|
|
17900
|
+
border-radius: calc(8% * (9 / 16)) / 8%;
|
|
17907
17901
|
}
|
|
17908
17902
|
`;
|
|
17909
17903
|
var StoryboardRenderer = ({
|
|
@@ -17911,10 +17905,17 @@ var StoryboardRenderer = ({
|
|
|
17911
17905
|
width,
|
|
17912
17906
|
percent,
|
|
17913
17907
|
cursorPosition,
|
|
17914
|
-
isStoryboardReady
|
|
17915
|
-
aspectRatio
|
|
17908
|
+
isStoryboardReady
|
|
17916
17909
|
}) => {
|
|
17917
|
-
const {
|
|
17910
|
+
const {
|
|
17911
|
+
url,
|
|
17912
|
+
width: sbWidth,
|
|
17913
|
+
height: sbHeight,
|
|
17914
|
+
frameHeight,
|
|
17915
|
+
frameWidth,
|
|
17916
|
+
frameCount,
|
|
17917
|
+
aspectRatio
|
|
17918
|
+
} = storyboard;
|
|
17918
17919
|
const targetWidth = isString4(width) ? parseInt(width, 10) : Number(width);
|
|
17919
17920
|
const effectiveCursorPosition = isStoryboardReady ? cursorPosition : null;
|
|
17920
17921
|
return /* @__PURE__ */ jsx325(
|
|
@@ -17928,7 +17929,7 @@ var StoryboardRenderer = ({
|
|
|
17928
17929
|
storyboardHeight: sbHeight,
|
|
17929
17930
|
storyboardUrl: url,
|
|
17930
17931
|
storyboardWidth: sbWidth,
|
|
17931
|
-
targetAspectRatio:
|
|
17932
|
+
targetAspectRatio: aspectRatio,
|
|
17932
17933
|
targetWidth
|
|
17933
17934
|
}
|
|
17934
17935
|
);
|
|
@@ -17951,7 +17952,6 @@ var Thumbnail = forwardRef37(
|
|
|
17951
17952
|
children,
|
|
17952
17953
|
storyboard,
|
|
17953
17954
|
height,
|
|
17954
|
-
aspectRatio = "wide",
|
|
17955
17955
|
...props
|
|
17956
17956
|
}, ref) => {
|
|
17957
17957
|
const [percent, setPercent] = useState26(0);
|
|
@@ -18003,7 +18003,6 @@ var Thumbnail = forwardRef37(
|
|
|
18003
18003
|
thumbnailContent = /* @__PURE__ */ jsx325(
|
|
18004
18004
|
StoryboardRenderer,
|
|
18005
18005
|
{
|
|
18006
|
-
aspectRatio,
|
|
18007
18006
|
cursorPosition,
|
|
18008
18007
|
isStoryboardReady,
|
|
18009
18008
|
percent,
|
|
@@ -18027,7 +18026,6 @@ var Thumbnail = forwardRef37(
|
|
|
18027
18026
|
{
|
|
18028
18027
|
ref,
|
|
18029
18028
|
...props,
|
|
18030
|
-
$aspectRatio: getAspectRatioValue(aspectRatio),
|
|
18031
18029
|
$backgroundUrl: backgroundUrl,
|
|
18032
18030
|
$gradientBackground: gradientBackground,
|
|
18033
18031
|
$isScrubbable: isScrubbable,
|