@wistia/ui 0.15.14-beta.1e41934b.72b042b → 0.15.14-beta.6458a247.692f16f
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 +17 -9
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.mts +6 -2
- package/dist/index.d.ts +6 -2
- package/dist/index.mjs +17 -9
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
package/dist/index.d.mts
CHANGED
|
@@ -171,7 +171,7 @@ declare const useOnClickOutside: (ref: RefObject<HTMLElement | null | undefined>
|
|
|
171
171
|
|
|
172
172
|
declare const usePreviousValue: <T>(value: T) => T | undefined;
|
|
173
173
|
|
|
174
|
-
declare const colorSchemeOptions: readonly ["
|
|
174
|
+
declare const colorSchemeOptions: readonly ["standard", "inherit", "error", "info", "success", "warning", "blue", "green", "orange", "pink", "purple", "red", "yellow", "vendor-hubspot", "vendor-marketo", "vendor-pardot"];
|
|
175
175
|
type ColorSchemeTypes = (typeof colorSchemeOptions)[number];
|
|
176
176
|
type ColorSchemeWrapperProps = ComponentPropsWithoutRef<'div'> & {
|
|
177
177
|
/**
|
|
@@ -2373,6 +2373,10 @@ type FormFieldProps = ComponentPropsWithoutRef<'div'> & {
|
|
|
2373
2373
|
* The name attribute of the field. It will map to the form data passed into `useFormState`.
|
|
2374
2374
|
*/
|
|
2375
2375
|
name: string;
|
|
2376
|
+
/**
|
|
2377
|
+
* Use if label describes a required form component
|
|
2378
|
+
*/
|
|
2379
|
+
required?: boolean;
|
|
2376
2380
|
/**
|
|
2377
2381
|
* A value that overrides the basic value. This should pair with `onChange`.
|
|
2378
2382
|
*/
|
|
@@ -2386,7 +2390,7 @@ type FormFieldProps = ComponentPropsWithoutRef<'div'> & {
|
|
|
2386
2390
|
* FormField is a compound component that combines a label, form control, and optional description and error message.
|
|
2387
2391
|
*/
|
|
2388
2392
|
declare const FormField: {
|
|
2389
|
-
({ children, description, error, id, label, labelPosition, name, value, ...props }: FormFieldProps): JSX$1.Element;
|
|
2393
|
+
({ children, description, error, id, label, labelPosition, name, required, value, ...props }: FormFieldProps): JSX$1.Element;
|
|
2390
2394
|
displayName: string;
|
|
2391
2395
|
};
|
|
2392
2396
|
|
package/dist/index.d.ts
CHANGED
|
@@ -171,7 +171,7 @@ declare const useOnClickOutside: (ref: RefObject<HTMLElement | null | undefined>
|
|
|
171
171
|
|
|
172
172
|
declare const usePreviousValue: <T>(value: T) => T | undefined;
|
|
173
173
|
|
|
174
|
-
declare const colorSchemeOptions: readonly ["
|
|
174
|
+
declare const colorSchemeOptions: readonly ["standard", "inherit", "error", "info", "success", "warning", "blue", "green", "orange", "pink", "purple", "red", "yellow", "vendor-hubspot", "vendor-marketo", "vendor-pardot"];
|
|
175
175
|
type ColorSchemeTypes = (typeof colorSchemeOptions)[number];
|
|
176
176
|
type ColorSchemeWrapperProps = ComponentPropsWithoutRef<'div'> & {
|
|
177
177
|
/**
|
|
@@ -2373,6 +2373,10 @@ type FormFieldProps = ComponentPropsWithoutRef<'div'> & {
|
|
|
2373
2373
|
* The name attribute of the field. It will map to the form data passed into `useFormState`.
|
|
2374
2374
|
*/
|
|
2375
2375
|
name: string;
|
|
2376
|
+
/**
|
|
2377
|
+
* Use if label describes a required form component
|
|
2378
|
+
*/
|
|
2379
|
+
required?: boolean;
|
|
2376
2380
|
/**
|
|
2377
2381
|
* A value that overrides the basic value. This should pair with `onChange`.
|
|
2378
2382
|
*/
|
|
@@ -2386,7 +2390,7 @@ type FormFieldProps = ComponentPropsWithoutRef<'div'> & {
|
|
|
2386
2390
|
* FormField is a compound component that combines a label, form control, and optional description and error message.
|
|
2387
2391
|
*/
|
|
2388
2392
|
declare const FormField: {
|
|
2389
|
-
({ children, description, error, id, label, labelPosition, name, value, ...props }: FormFieldProps): JSX$1.Element;
|
|
2393
|
+
({ children, description, error, id, label, labelPosition, name, required, value, ...props }: FormFieldProps): JSX$1.Element;
|
|
2390
2394
|
displayName: string;
|
|
2391
2395
|
};
|
|
2392
2396
|
|
package/dist/index.mjs
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
|
|
2
2
|
/*
|
|
3
|
-
* @license @wistia/ui v0.15.14-beta.
|
|
3
|
+
* @license @wistia/ui v0.15.14-beta.6458a247.692f16f
|
|
4
4
|
*
|
|
5
5
|
* Copyright (c) 2024-2025, Wistia, Inc. and its affiliates.
|
|
6
6
|
*
|
|
@@ -822,7 +822,7 @@ import { css as css4 } from "styled-components";
|
|
|
822
822
|
|
|
823
823
|
// src/css/designTokens/colorSchemes.tsx
|
|
824
824
|
import { css as css3 } from "styled-components";
|
|
825
|
-
var
|
|
825
|
+
var standardColorScheme = css3`
|
|
826
826
|
--wui-color-base-1: var(--wui-gray-1);
|
|
827
827
|
--wui-color-base-2: var(--wui-gray-2);
|
|
828
828
|
--wui-color-base-3: var(--wui-gray-3);
|
|
@@ -1344,7 +1344,7 @@ var baseAliasTokens = css4`
|
|
|
1344
1344
|
`;
|
|
1345
1345
|
var colorAliasTokens = css4`
|
|
1346
1346
|
--wui-color-bg-app: var(--wui-app-background);
|
|
1347
|
-
${
|
|
1347
|
+
${standardColorScheme}
|
|
1348
1348
|
${baseAliasTokens}
|
|
1349
1349
|
/* --- Semantic --- */
|
|
1350
1350
|
/* Error */
|
|
@@ -3123,7 +3123,7 @@ Ellipsis.displayName = "Ellipsis_UI";
|
|
|
3123
3123
|
// src/private/helpers/getColorScheme/getColorScheme.ts
|
|
3124
3124
|
import { css as css15 } from "styled-components";
|
|
3125
3125
|
var colorSchemes = {
|
|
3126
|
-
|
|
3126
|
+
standard: standardColorScheme,
|
|
3127
3127
|
blue: blueColorScheme,
|
|
3128
3128
|
green: greenColorScheme,
|
|
3129
3129
|
red: redColorScheme,
|
|
@@ -7959,7 +7959,7 @@ var StyledLabel = styled6.span`
|
|
|
7959
7959
|
var ActionButton = forwardRef3(
|
|
7960
7960
|
({
|
|
7961
7961
|
icon,
|
|
7962
|
-
colorScheme = "
|
|
7962
|
+
colorScheme = "standard",
|
|
7963
7963
|
disabled = false,
|
|
7964
7964
|
hoverColorScheme,
|
|
7965
7965
|
variant = "default",
|
|
@@ -8074,7 +8074,7 @@ Image.displayName = "Image_UI";
|
|
|
8074
8074
|
// src/components/ColorSchemeWrapper/ColorSchemeWrapper.tsx
|
|
8075
8075
|
import styled8 from "styled-components";
|
|
8076
8076
|
import { jsx as jsx203 } from "react/jsx-runtime";
|
|
8077
|
-
var defaultColorSchemeOptions = ["
|
|
8077
|
+
var defaultColorSchemeOptions = ["standard", "inherit"];
|
|
8078
8078
|
var semanticColorSchemeOptions = ["error", "info", "success", "warning"];
|
|
8079
8079
|
var brandColorSchemeOptions = [
|
|
8080
8080
|
"blue",
|
|
@@ -13197,7 +13197,7 @@ var MenuItemButton = forwardRef18(({ children, appearance, command, icon, ...pro
|
|
|
13197
13197
|
...props,
|
|
13198
13198
|
ref,
|
|
13199
13199
|
$isGated: appearance === "gated",
|
|
13200
|
-
colorScheme: colorScheme ?? "
|
|
13200
|
+
colorScheme: colorScheme ?? "inherit",
|
|
13201
13201
|
fullWidth: true,
|
|
13202
13202
|
unstyled: true,
|
|
13203
13203
|
children: [
|
|
@@ -14787,6 +14787,7 @@ var FormField = ({
|
|
|
14787
14787
|
label,
|
|
14788
14788
|
labelPosition,
|
|
14789
14789
|
name,
|
|
14790
|
+
required = false,
|
|
14790
14791
|
value,
|
|
14791
14792
|
...props
|
|
14792
14793
|
}) => {
|
|
@@ -14836,7 +14837,14 @@ var FormField = ({
|
|
|
14836
14837
|
...props,
|
|
14837
14838
|
"data-label-position": labelPosition ?? formState.labelPosition,
|
|
14838
14839
|
children: [
|
|
14839
|
-
!isIntegratedLabel && /* @__PURE__ */ jsx283(
|
|
14840
|
+
!isIntegratedLabel && /* @__PURE__ */ jsx283(
|
|
14841
|
+
Label,
|
|
14842
|
+
{
|
|
14843
|
+
htmlFor: computedId,
|
|
14844
|
+
required,
|
|
14845
|
+
children: label
|
|
14846
|
+
}
|
|
14847
|
+
),
|
|
14840
14848
|
isNotNil28(description) ? /* @__PURE__ */ jsx283(FormControlLabelDescription, { id: descriptionId, children: description }) : null,
|
|
14841
14849
|
cloneElement8(children, childProps),
|
|
14842
14850
|
isNotNil28(computedError) ? /* @__PURE__ */ jsxs46(Fragment9, { children: [
|
|
@@ -16856,6 +16864,7 @@ var StyledTrigger2 = styled91(Trigger3)`
|
|
|
16856
16864
|
outline: 1px solid var(--wui-input-color-border);
|
|
16857
16865
|
outline-offset: -2px;
|
|
16858
16866
|
border-radius: var(--wui-input-border-radius);
|
|
16867
|
+
min-width: 200px;
|
|
16859
16868
|
text-align: left;
|
|
16860
16869
|
display: inline-flex;
|
|
16861
16870
|
align-items: center;
|
|
@@ -16999,7 +17008,6 @@ var StyledItem = styled92(Item)`
|
|
|
16999
17008
|
align-items: ${({ $checkmarkVerticalAlign }) => $checkmarkVerticalAlign === "center" ? "center" : "flex-start"};
|
|
17000
17009
|
background-color: transparent;
|
|
17001
17010
|
display: flex;
|
|
17002
|
-
gap: var(--wui-space-01);
|
|
17003
17011
|
padding: var(--wui-select-option-padding);
|
|
17004
17012
|
justify-content: space-between;
|
|
17005
17013
|
font-size: var(--font-size);
|