@wistia/ui 0.14.11 → 0.14.12-beta.04c4b6af.aa61237
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 +16 -13
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.mts +7 -3
- package/dist/index.d.ts +7 -3
- package/dist/index.mjs +16 -13
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
package/dist/index.cjs
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
|
|
2
2
|
/*
|
|
3
|
-
* @license @wistia/ui v0.14.
|
|
3
|
+
* @license @wistia/ui v0.14.12-beta.04c4b6af.aa61237
|
|
4
4
|
*
|
|
5
5
|
* Copyright (c) 2024-2025, Wistia, Inc. and its affiliates.
|
|
6
6
|
*
|
|
@@ -9490,14 +9490,14 @@ var Checkbox = (0, import_react38.forwardRef)(
|
|
|
9490
9490
|
const contextValue = checkboxGroupContext?.value;
|
|
9491
9491
|
const checkboxName = name ?? contextName;
|
|
9492
9492
|
const handleOnChange = onChange ?? contextOnChange;
|
|
9493
|
-
const
|
|
9493
|
+
const isChecked = (0, import_type_guards31.isNotUndefined)(value) && contextValue ? contextValue.includes(value) : checked;
|
|
9494
9494
|
return /* @__PURE__ */ (0, import_jsx_runtime221.jsxs)(StyledCheckboxWrapper, { disabled, children: [
|
|
9495
9495
|
/* @__PURE__ */ (0, import_jsx_runtime221.jsx)(
|
|
9496
9496
|
StyledHiddenCheckboxInput,
|
|
9497
9497
|
{
|
|
9498
9498
|
...props,
|
|
9499
9499
|
ref,
|
|
9500
|
-
|
|
9500
|
+
checked: isChecked,
|
|
9501
9501
|
disabled,
|
|
9502
9502
|
id: computedId,
|
|
9503
9503
|
name: checkboxName,
|
|
@@ -14746,8 +14746,6 @@ var import_type_guards52 = require("@wistia/type-guards");
|
|
|
14746
14746
|
var import_jsx_runtime285 = require("react/jsx-runtime");
|
|
14747
14747
|
var ProgressBarWrapper = import_styled_components92.default.div`
|
|
14748
14748
|
--progress-bar-height: 8px;
|
|
14749
|
-
--progress-bar-indicator-color: var(--wui-color-bg-fill);
|
|
14750
|
-
--progress-bar-background-color: var(--wui-color-bg-surface-secondary);
|
|
14751
14749
|
|
|
14752
14750
|
display: flex;
|
|
14753
14751
|
align-items: center;
|
|
@@ -14769,7 +14767,8 @@ var ProgressBarLabel = import_styled_components92.default.div`
|
|
|
14769
14767
|
flex-shrink: 0;
|
|
14770
14768
|
`;
|
|
14771
14769
|
var StyledProgressIndicator = (0, import_styled_components92.default)(import_react_progress.Indicator)`
|
|
14772
|
-
|
|
14770
|
+
${({ $colorScheme }) => getColorScheme($colorScheme)}
|
|
14771
|
+
background-color: var(--wui-color-bg-fill);
|
|
14773
14772
|
width: 100%;
|
|
14774
14773
|
height: 100%;
|
|
14775
14774
|
border-top-right-radius: var(--wui-border-radius-rounded);
|
|
@@ -14778,9 +14777,10 @@ var StyledProgressIndicator = (0, import_styled_components92.default)(import_rea
|
|
|
14778
14777
|
transform: ${({ $progress, $max }) => getTranslateValue($progress, $max)};
|
|
14779
14778
|
`;
|
|
14780
14779
|
var StyledProgressBar = (0, import_styled_components92.default)(import_react_progress.Root)`
|
|
14780
|
+
${({ $colorScheme }) => getColorScheme($colorScheme)}
|
|
14781
14781
|
position: relative;
|
|
14782
14782
|
overflow: hidden;
|
|
14783
|
-
background: var(--
|
|
14783
|
+
background-color: var(--wui-color-bg-surface-secondary);
|
|
14784
14784
|
border-radius: var(--wui-border-radius-rounded);
|
|
14785
14785
|
width: 100%;
|
|
14786
14786
|
height: var(--progress-bar-height);
|
|
@@ -14794,6 +14794,7 @@ var ProgressBar = ({
|
|
|
14794
14794
|
children,
|
|
14795
14795
|
labelLeft,
|
|
14796
14796
|
labelRight,
|
|
14797
|
+
colorScheme = "inherit",
|
|
14797
14798
|
...props
|
|
14798
14799
|
}) => {
|
|
14799
14800
|
return /* @__PURE__ */ (0, import_jsx_runtime285.jsxs)(ProgressBarWrapper, { children: [
|
|
@@ -14801,12 +14802,14 @@ var ProgressBar = ({
|
|
|
14801
14802
|
/* @__PURE__ */ (0, import_jsx_runtime285.jsx)(
|
|
14802
14803
|
StyledProgressBar,
|
|
14803
14804
|
{
|
|
14805
|
+
$colorScheme: colorScheme,
|
|
14804
14806
|
max,
|
|
14805
14807
|
value: progress,
|
|
14806
14808
|
...props,
|
|
14807
14809
|
children: /* @__PURE__ */ (0, import_jsx_runtime285.jsx)(
|
|
14808
14810
|
StyledProgressIndicator,
|
|
14809
14811
|
{
|
|
14812
|
+
$colorScheme: colorScheme,
|
|
14810
14813
|
$max: max,
|
|
14811
14814
|
$progress: progress
|
|
14812
14815
|
}
|
|
@@ -14945,7 +14948,7 @@ var Radio = (0, import_react72.forwardRef)(
|
|
|
14945
14948
|
const contextValue = radioGroupContext?.value;
|
|
14946
14949
|
const radioName = name ?? contextName;
|
|
14947
14950
|
const handleOnChange = onChange ?? contextOnChange;
|
|
14948
|
-
const
|
|
14951
|
+
const isChecked = (0, import_type_guards53.isNotUndefined)(value) && (0, import_type_guards53.isNotUndefined)(contextValue) ? contextValue === value : checked;
|
|
14949
14952
|
return /* @__PURE__ */ (0, import_jsx_runtime286.jsxs)(
|
|
14950
14953
|
StyledRadioWrapper,
|
|
14951
14954
|
{
|
|
@@ -14957,14 +14960,14 @@ var Radio = (0, import_react72.forwardRef)(
|
|
|
14957
14960
|
{
|
|
14958
14961
|
...props,
|
|
14959
14962
|
ref,
|
|
14963
|
+
checked: isChecked,
|
|
14960
14964
|
disabled,
|
|
14961
14965
|
id: computedId,
|
|
14962
14966
|
name: radioName,
|
|
14963
14967
|
onChange: handleOnChange,
|
|
14964
14968
|
required,
|
|
14965
14969
|
type: "radio",
|
|
14966
|
-
value
|
|
14967
|
-
...(0, import_type_guards53.isNotUndefined)(defaultChecked) ? { defaultChecked } : { checked }
|
|
14970
|
+
value
|
|
14968
14971
|
}
|
|
14969
14972
|
),
|
|
14970
14973
|
/* @__PURE__ */ (0, import_jsx_runtime286.jsx)(
|
|
@@ -15128,7 +15131,7 @@ var RadioCardRoot = (0, import_react73.forwardRef)(
|
|
|
15128
15131
|
const contextValue = radioGroupContext?.value;
|
|
15129
15132
|
const radioName = name ?? contextName;
|
|
15130
15133
|
const handleOnChange = onChange ?? contextOnChange;
|
|
15131
|
-
const
|
|
15134
|
+
const isChecked = (0, import_type_guards54.isNotUndefined)(value) && (0, import_type_guards54.isNotUndefined)(contextValue) ? contextValue === value : checked;
|
|
15132
15135
|
return /* @__PURE__ */ (0, import_jsx_runtime287.jsxs)(
|
|
15133
15136
|
StyledCard2,
|
|
15134
15137
|
{
|
|
@@ -15141,13 +15144,13 @@ var RadioCardRoot = (0, import_react73.forwardRef)(
|
|
|
15141
15144
|
{
|
|
15142
15145
|
...props,
|
|
15143
15146
|
ref,
|
|
15147
|
+
checked: isChecked,
|
|
15144
15148
|
disabled,
|
|
15145
15149
|
id: computedId,
|
|
15146
15150
|
name: radioName,
|
|
15147
15151
|
onChange: handleOnChange,
|
|
15148
15152
|
type: "radio",
|
|
15149
|
-
value
|
|
15150
|
-
...(0, import_type_guards54.isNotUndefined)(defaultChecked) ? { defaultChecked } : { checked }
|
|
15153
|
+
value
|
|
15151
15154
|
}
|
|
15152
15155
|
),
|
|
15153
15156
|
children
|