@wistia/ui 0.18.0-beta.9dd31b7e.fa98d59 → 0.18.0-beta.c3ba0640.3c7bbc3

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 CHANGED
@@ -1,6 +1,6 @@
1
1
 
2
2
  /*
3
- * @license @wistia/ui v0.18.0-beta.9dd31b7e.fa98d59
3
+ * @license @wistia/ui v0.18.0-beta.c3ba0640.3c7bbc3
4
4
  *
5
5
  * Copyright (c) 2024-2025, Wistia, Inc. and its affiliates.
6
6
  *
@@ -14990,7 +14990,6 @@ var FormField = ({
14990
14990
  id: computedId,
14991
14991
  label: isIntegratedLabel ? label : void 0,
14992
14992
  "aria-describedby": ariaDescribedby,
14993
- "aria-invalid": (0, import_type_guards49.isNotNil)(computedError),
14994
14993
  ...props
14995
14994
  };
14996
14995
  if ((0, import_type_guards49.isUndefined)(value) && (0, import_type_guards49.isNotUndefined)(defaultValue)) {
@@ -15012,7 +15011,8 @@ var FormField = ({
15012
15011
  childProps = {
15013
15012
  ...childProps,
15014
15013
  name: computedName,
15015
- onChange: handleChange
15014
+ onChange: handleChange,
15015
+ "aria-invalid": (0, import_type_guards49.isNotNil)(error)
15016
15016
  };
15017
15017
  }
15018
15018
  import_react73.Children.only(children);
@@ -17678,7 +17678,7 @@ var StyledThumbnailBadge = import_styled_components123.styled.div`
17678
17678
  align-items: center;
17679
17679
  background-color: rgb(0 0 0 / 50%);
17680
17680
  border-radius: var(--wui-border-radius-01);
17681
- bottom: var(--wui-space-01);
17681
+ bottom: var(--wui-thumbnail-badge-offset);
17682
17682
  color: var(--wui-color-text-on-fill);
17683
17683
  display: flex;
17684
17684
  font-size: var(--wui-typography-body-4-size);
@@ -17686,7 +17686,7 @@ var StyledThumbnailBadge = import_styled_components123.styled.div`
17686
17686
  gap: var(--wui-space-01);
17687
17687
  padding: 0 var(--wui-space-01);
17688
17688
  position: absolute;
17689
- right: var(--wui-space-01);
17689
+ right: var(--wui-thumbnail-badge-offset);
17690
17690
  z-index: 1;
17691
17691
 
17692
17692
  svg {
@@ -18011,7 +18011,15 @@ var ThumbnailImage = ({ thumbnailImageType, thumbnailUrl }) => {
18011
18011
  }
18012
18012
  );
18013
18013
  };
18014
+ var StyledThumbnailContainer = import_styled_components126.styled.div`
18015
+ container-type: inline-size;
18016
+ aspect-ratio: 16 / 9;
18017
+ width: ${({ $width }) => $width};
18018
+ display: flex;
18019
+ `;
18014
18020
  var StyledThumbnail = import_styled_components126.styled.div`
18021
+ --wui-thumbnail-badge-offset: var(--wui-space-01);
18022
+
18015
18023
  background-image: ${({ $backgroundUrl }) => (0, import_type_guards74.isNotNil)($backgroundUrl) ? `url('${$backgroundUrl}')` : void 0};
18016
18024
  ${({ $backgroundUrl, $gradientBackground }) => (
18017
18025
  // if we don't have $backgroundUrl show a gradient
@@ -18019,16 +18027,35 @@ var StyledThumbnail = import_styled_components126.styled.div`
18019
18027
  )};
18020
18028
  background-position: center center;
18021
18029
  background-size: cover;
18030
+ width: 100%;
18022
18031
  aspect-ratio: 16 / 9;
18023
- display: flex;
18024
18032
  overflow: hidden;
18025
18033
  position: relative;
18026
- width: ${({ $width }) => $width};
18034
+ display: flex;
18035
+
18027
18036
  ${({ $isScrubbable }) => $isScrubbable && "cursor: pointer;"}
18028
18037
 
18029
18038
  &,
18030
18039
  img {
18031
- border-radius: calc(8% * (9 / 16)) / 8%;
18040
+ border-radius: var(--wui-border-radius-02);
18041
+ }
18042
+
18043
+ @container (min-width: 200px) {
18044
+ &,
18045
+ img {
18046
+ border-radius: var(--wui-border-radius-03);
18047
+ }
18048
+
18049
+ --wui-thumbnail-badge-offset: var(--wui-space-02);
18050
+ }
18051
+
18052
+ @container (min-width: 400px) {
18053
+ &,
18054
+ img {
18055
+ border-radius: var(--wui-border-radius-05);
18056
+ }
18057
+
18058
+ --wui-thumbnail-badge-offset: var(--wui-space-03);
18032
18059
  }
18033
18060
  `;
18034
18061
  var StoryboardRenderer = ({
@@ -18152,7 +18179,7 @@ var Thumbnail = (0, import_react100.forwardRef)(
18152
18179
  } else {
18153
18180
  thumbnailContent = null;
18154
18181
  }
18155
- return /* @__PURE__ */ (0, import_jsx_runtime327.jsxs)(
18182
+ return /* @__PURE__ */ (0, import_jsx_runtime327.jsx)(StyledThumbnailContainer, { $width: width, children: /* @__PURE__ */ (0, import_jsx_runtime327.jsxs)(
18156
18183
  StyledThumbnail,
18157
18184
  {
18158
18185
  ref,
@@ -18170,7 +18197,7 @@ var Thumbnail = (0, import_react100.forwardRef)(
18170
18197
  thumbnailContent
18171
18198
  ]
18172
18199
  }
18173
- );
18200
+ ) });
18174
18201
  }
18175
18202
  );
18176
18203
  Thumbnail.displayName = "Thumbnail_UI";