@fluentui/react-input 0.0.0-nightlyf8be6a7c6520220106.1 → 0.0.0
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/CHANGELOG.json +561 -18
- package/CHANGELOG.md +213 -49
- package/README.md +32 -0
- package/Spec-styling.md +8 -8
- package/Spec-variants.md +2 -2
- package/dist/{react-input.d.ts → index.d.ts} +16 -22
- package/{lib → dist}/tsdoc-metadata.json +0 -0
- package/lib/Input.js.map +1 -1
- package/lib/components/Input/Input.js +6 -8
- package/lib/components/Input/Input.js.map +1 -1
- package/lib/components/Input/Input.types.js.map +1 -1
- package/lib/components/Input/index.js.map +1 -1
- package/lib/components/Input/renderInput.js +4 -4
- package/lib/components/Input/renderInput.js.map +1 -1
- package/lib/components/Input/useInput.js +3 -5
- package/lib/components/Input/useInput.js.map +1 -1
- package/lib/components/Input/useInputStyles.js +106 -93
- package/lib/components/Input/useInputStyles.js.map +1 -1
- package/lib/index.js +1 -1
- package/lib/index.js.map +1 -1
- package/lib-commonjs/Input.js.map +1 -1
- package/lib-commonjs/components/Input/Input.js +3 -5
- package/lib-commonjs/components/Input/Input.js.map +1 -1
- package/lib-commonjs/components/Input/Input.types.js.map +1 -1
- package/lib-commonjs/components/Input/index.js.map +1 -1
- package/lib-commonjs/components/Input/renderInput.js +6 -6
- package/lib-commonjs/components/Input/renderInput.js.map +1 -1
- package/lib-commonjs/components/Input/useInput.js +5 -7
- package/lib-commonjs/components/Input/useInput.js.map +1 -1
- package/lib-commonjs/components/Input/useInputStyles.js +112 -98
- package/lib-commonjs/components/Input/useInputStyles.js.map +1 -1
- package/lib-commonjs/index.js +32 -2
- package/lib-commonjs/index.js.map +1 -1
- package/package.json +18 -24
- package/lib/Input.d.ts +0 -1
- package/lib/components/Input/Input.d.ts +0 -8
- package/lib/components/Input/Input.types.d.ts +0 -84
- package/lib/components/Input/index.d.ts +0 -5
- package/lib/components/Input/renderInput.d.ts +0 -5
- package/lib/components/Input/useInput.d.ts +0 -12
- package/lib/components/Input/useInputStyles.d.ts +0 -6
- package/lib/index.d.ts +0 -1
- package/lib-commonjs/Input.d.ts +0 -1
- package/lib-commonjs/components/Input/Input.d.ts +0 -8
- package/lib-commonjs/components/Input/Input.types.d.ts +0 -84
- package/lib-commonjs/components/Input/index.d.ts +0 -5
- package/lib-commonjs/components/Input/renderInput.d.ts +0 -5
- package/lib-commonjs/components/Input/useInput.d.ts +0 -12
- package/lib-commonjs/components/Input/useInputStyles.d.ts +0 -6
- package/lib-commonjs/index.d.ts +0 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../../src/components/Input/useInputStyles.ts"],"names":[],"mappings":"AAAA,mBAAqB,YAArB,EAAmC,UAAnC,QAAqD,6BAArD;AAIA,OAAO,MAAM,cAAc,GAAG,WAAvB,C,CAEP;;AACA,MAAM,iBAAiB,GAAG;AACxB,EAAA,GAAG,EAAE,KADmB;AAExB,EAAA,EAAE,EAAE,KAFoB;AAGxB,EAAA,MAAM,EAAE,KAHgB;AAIxB,EAAA,CAAC,EAAE,KAJqB;AAKxB,EAAA,MAAM,EAAE,MALgB;AAMxB,EAAA,CAAC,EAAE;AANqB,CAA1B;AAQA,MAAM,eAAe,GAAG;AACtB,EAAA,SAAS,EAAE,OADW;AAEtB,EAAA,MAAM,EAAE;AAFc,CAAxB;AAIA,MAAM,YAAY,GAAG;AACnB,EAAA,aAAa,EAAE,2BADI;AAEnB,EAAA,aAAa,EAAE;AAFI,CAArB;AAIA,MAAM,YAAY,GAAG;AACnB;AACA,EAAA,KAAK,EAAG,KAAD,KAAmB;AACxB,IAAA,QAAQ,EAAE,KAAK,CAAC,eADQ;AAExB,IAAA,UAAU,EAAE,KAAK,CAAC;AAFM,GAAnB,CAFY;AAMnB,EAAA,QAAQ,EAAG,KAAD,KAAmB;AAC3B,IAAA,QAAQ,EAAE,KAAK,CAAC,eADW;AAE3B,IAAA,UAAU,EAAE,KAAK,CAAC;AAFS,GA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AAD,IAAa,MAAb,IAAuB,UAAU,CAAC,iBARD,EASjC,MAAM,IAAI,UAAU,CAAC,MATY,EAUjC,QAAQ,IAAI,UAAU,CAAC,QAVU,EAWjC,KAAK,CAAC,IAAN,CAAW,SAXsB,CAAnC;EAcA,KAAK,CAAC,KAAN,CAAY,SAAZ,GAAwB,YAAY,CAClC,eAAe,CAAC,KADkB,EAElC,WAAW,CAAC,IAFsB,EAGlC,WAAW,CAAC,IAAD,CAHuB,EAIlC,QAAQ,IAAI,WAAW,CAAC,QAJU,EAKlC,KAAK,CAAC,KAAN,CAAY,SALsB,CAApC;EAQA,MAAM,cAAc,GAAG,CAAC,aAAa,CAAC,IAAf,EAAqB,QAAQ,IAAI,aAAa,CAAC,QAA/C,EAAyD,aAAa,CAAC,IAAD,CAAtE,CAAvB;;EACA,IAAI,KAAK,CAAC,aAAV,EAAyB;IACvB,KAAK,CAAC,aAAN,CAAoB,SAApB,GAAgC,YAAY,CAC1C,eAAe,CAAC,aAD0B,EAE1C,GAAG,cAFuC,EAG1C,KAAK,CAAC,aAAN,CAAoB,SAHsB,CAA5C;EAKD;;EACD,IAAI,KAAK,CAAC,YAAV,EAAwB;IACtB,KAAK,CAAC,YAAN,CAAmB,SAAnB,GAA+B,YAAY,CACzC,eAAe,CAAC,YADyB,EAEzC,GAAG,cAFsC,EAGzC,KAAK,CAAC,YAAN,CAAmB,SAHsB,CAA3C;EAKD;;EAED,OAAO,KAAP;AACD,CAhDM","sourcesContent":["import { makeStyles, mergeClasses, shorthands } from '@griffel/react';\nimport { tokens, typographyStyles } from '@fluentui/react-theme';\nimport type { InputSlots, InputState } from './Input.types';\nimport type { SlotClassNames } from '@fluentui/react-utilities';\n\nexport const inputClassNames: SlotClassNames<InputSlots> = {\n root: 'fui-Input',\n input: 'fui-Input__input',\n contentBefore: 'fui-Input__contentBefore',\n contentAfter: 'fui-Input__contentAfter',\n};\n\n// TODO(sharing) use theme values once available\nconst contentSizes = {\n // TODO: This 400 style is not in the typography styles.\n // May need a design change\n 400: {\n fontSize: tokens.fontSizeBase400,\n lineHeight: tokens.lineHeightBase400,\n },\n};\n// TODO(sharing) should these be shared somewhere?\nconst fieldHeights = {\n small: '24px',\n medium: '32px',\n large: '40px',\n};\n\nconst useRootStyles = makeStyles({\n base: {\n display: 'inline-flex',\n alignItems: 'center',\n flexWrap: 'nowrap',\n ...shorthands.gap(tokens.spacingHorizontalXXS),\n fontFamily: tokens.fontFamilyBase,\n ...shorthands.borderRadius(tokens.borderRadiusMedium), // used for all but underline\n position: 'relative',\n boxSizing: 'border-box',\n },\n interactive: {\n // This is all for the bottom focus border.\n // It's supposed to be 2px flat all the way across and match the radius of the field's corners.\n '::after': {\n boxSizing: 'border-box',\n content: '\"\"',\n position: 'absolute',\n left: '-1px',\n bottom: '-1px',\n right: '-1px',\n\n // Maintaining the correct corner radius:\n // Use the whole border-radius as the height and only put radii on the bottom corners.\n // (Otherwise the radius would be automatically reduced to fit available space.)\n // max() ensures the focus border still shows up even if someone sets tokens.borderRadiusMedium to 0.\n height: `max(2px, ${tokens.borderRadiusMedium})`,\n borderBottomLeftRadius: tokens.borderRadiusMedium,\n borderBottomRightRadius: tokens.borderRadiusMedium,\n\n // Flat 2px border:\n // By default borderBottom will cause little \"horns\" on the ends. The clipPath trims them off.\n // (This could be done without trimming using `background: linear-gradient(...)`, but using\n // borderBottom makes it easier for people to override the color if needed.)\n ...shorthands.borderBottom('2px', 'solid', tokens.colorCompoundBrandStroke),\n clipPath: 'inset(calc(100% - 2px) 0 0 0)',\n\n // Animation for focus OUT\n transform: 'scaleX(0)',\n transitionProperty: 'transform',\n transitionDuration: tokens.durationUltraFast,\n transitionDelay: tokens.curveAccelerateMid,\n },\n ':focus-within::after': {\n // Animation for focus IN\n transform: 'scaleX(1)',\n transitionProperty: 'transform',\n transitionDuration: tokens.durationNormal,\n transitionDelay: tokens.curveDecelerateMid,\n },\n ':focus-within:active::after': {\n // This is if the user clicks the field again while it's already focused\n borderBottomColor: tokens.colorCompoundBrandStrokePressed,\n },\n ':focus-within': {\n outlineWidth: '2px',\n outlineStyle: 'solid',\n outlineColor: 'transparent',\n },\n },\n small: {\n minHeight: fieldHeights.small,\n ...shorthands.padding('0', tokens.spacingHorizontalSNudge),\n ...typographyStyles.caption1,\n },\n medium: {\n minHeight: fieldHeights.medium,\n ...shorthands.padding('0', tokens.spacingHorizontalMNudge),\n ...typographyStyles.body1,\n },\n large: {\n minHeight: fieldHeights.large,\n ...shorthands.padding('0', tokens.spacingHorizontalM),\n ...contentSizes[400],\n ...shorthands.gap(tokens.spacingHorizontalSNudge),\n },\n outline: {\n backgroundColor: tokens.colorNeutralBackground1,\n ...shorthands.border('1px', 'solid', tokens.colorNeutralStroke1),\n borderBottomColor: tokens.colorNeutralStrokeAccessible,\n },\n outlineInteractive: {\n ':hover': {\n ...shorthands.borderColor(tokens.colorNeutralStroke1Hover),\n borderBottomColor: tokens.colorNeutralStrokeAccessibleHover,\n },\n // DO NOT add a space between the selectors! It changes the behavior of make-styles.\n ':active,:focus-within': {\n ...shorthands.borderColor(tokens.colorNeutralStroke1Pressed),\n borderBottomColor: tokens.colorNeutralStrokeAccessiblePressed,\n },\n },\n underline: {\n backgroundColor: tokens.colorTransparentBackground,\n ...shorthands.borderRadius(0), // corners look strange if rounded\n ...shorthands.borderBottom('1px', 'solid', tokens.colorNeutralStrokeAccessible),\n },\n underlineInteractive: {\n ':hover': {\n borderBottomColor: tokens.colorNeutralStrokeAccessibleHover,\n },\n // DO NOT add a space between the selectors! It changes the behavior of make-styles.\n ':active,:focus-within': {\n borderBottomColor: tokens.colorNeutralStrokeAccessiblePressed,\n },\n '::after': shorthands.borderRadius(0), // remove rounded corners from focus underline\n },\n filled: {\n boxShadow: tokens.shadow2, // optional shadow for filled appearances\n ...shorthands.border('1px', 'solid', tokens.colorTransparentStroke),\n },\n filledInteractive: {\n // DO NOT add a space between the selectors! It changes the behavior of make-styles.\n ':hover,:focus-within': {\n // also handles pressed border color (:active)\n ...shorthands.borderColor(tokens.colorTransparentStrokeInteractive),\n },\n },\n 'filled-darker': {\n backgroundColor: tokens.colorNeutralBackground3,\n },\n 'filled-lighter': {\n backgroundColor: tokens.colorNeutralBackground1,\n },\n disabled: {\n cursor: 'not-allowed',\n backgroundColor: tokens.colorTransparentBackground,\n ...shorthands.border('1px', 'solid', tokens.colorNeutralStrokeDisabled),\n ...shorthands.borderRadius(tokens.borderRadiusMedium), // because underline doesn't usually have a radius\n '@media (forced-colors: active)': {\n ...shorthands.borderColor('GrayText'),\n },\n },\n});\n\nconst useInputElementStyles = makeStyles({\n base: {\n boxSizing: 'border-box',\n flexGrow: 1,\n minWidth: 0, // required to make the input shrink to fit the wrapper\n ...shorthands.borderStyle('none'), // input itself never has a border (this is handled by inputWrapper)\n ...shorthands.padding('0', tokens.spacingHorizontalXXS),\n color: tokens.colorNeutralForeground1,\n // Use literal \"transparent\" (not from the theme) to always let the color from the root show through\n backgroundColor: 'transparent',\n\n '::placeholder': {\n color: tokens.colorNeutralForeground4,\n opacity: 1, // browser style override\n },\n\n outlineStyle: 'none', // disable default browser outline\n },\n small: {\n // This is set on root but doesn't inherit\n ...typographyStyles.caption1,\n },\n medium: {\n ...typographyStyles.body1,\n },\n large: {\n ...contentSizes[400],\n ...shorthands.padding('0', tokens.spacingHorizontalSNudge),\n },\n disabled: {\n color: tokens.colorNeutralForegroundDisabled,\n backgroundColor: tokens.colorTransparentBackground,\n cursor: 'not-allowed',\n '::placeholder': {\n color: tokens.colorNeutralForegroundDisabled,\n },\n },\n});\n\nconst useContentStyles = makeStyles({\n base: {\n boxSizing: 'border-box',\n color: tokens.colorNeutralForeground3, // \"icon color\" in design spec\n // special case styling for icons (most common case) to ensure they're centered vertically\n '> svg': { display: 'block' },\n },\n disabled: {\n color: tokens.colorNeutralForegroundDisabled,\n },\n // Ensure resizable icons show up with the proper font size\n small: {\n '> svg': { fontSize: '16px' },\n },\n medium: {\n '> svg': { fontSize: '20px' },\n },\n large: {\n '> svg': { fontSize: '24px' },\n },\n});\n\n/**\n * Apply styling to the Input slots based on the state\n */\nexport const useInputStyles_unstable = (state: InputState): InputState => {\n const { size, appearance } = state;\n const disabled = state.input.disabled;\n const filled = appearance.startsWith('filled');\n\n const rootStyles = useRootStyles();\n const inputStyles = useInputElementStyles();\n const contentStyles = useContentStyles();\n\n state.root.className = mergeClasses(\n inputClassNames.root,\n rootStyles.base,\n rootStyles[size],\n rootStyles[appearance],\n !disabled && rootStyles.interactive,\n !disabled && appearance === 'outline' && rootStyles.outlineInteractive,\n !disabled && appearance === 'underline' && rootStyles.underlineInteractive,\n !disabled && filled && rootStyles.filledInteractive,\n filled && rootStyles.filled,\n disabled && rootStyles.disabled,\n state.root.className,\n );\n\n state.input.className = mergeClasses(\n inputClassNames.input,\n inputStyles.base,\n inputStyles[size],\n disabled && inputStyles.disabled,\n state.input.className,\n );\n\n const contentClasses = [contentStyles.base, disabled && contentStyles.disabled, contentStyles[size]];\n if (state.contentBefore) {\n state.contentBefore.className = mergeClasses(\n inputClassNames.contentBefore,\n ...contentClasses,\n state.contentBefore.className,\n );\n }\n if (state.contentAfter) {\n state.contentAfter.className = mergeClasses(\n inputClassNames.contentAfter,\n ...contentClasses,\n state.contentAfter.className,\n );\n }\n\n return state;\n};\n"],"sourceRoot":"../src/"}
|
package/lib/index.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export
|
|
1
|
+
export { Input, inputClassNames, renderInput_unstable, useInputStyles_unstable, useInput_unstable } from './Input';
|
|
2
2
|
//# sourceMappingURL=index.js.map
|
package/lib/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"../src/","sources":["index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,EAAE,eAAe,EAAE,oBAAoB,EAAE,uBAAuB,EAAE,iBAAiB,EAAE,MAAM,SAAS,CAAC","sourcesContent":["export { Input, inputClassNames, renderInput_unstable, useInputStyles_unstable, useInput_unstable } from './Input';\nexport type { InputOnChangeData, InputProps, InputSlots, InputState } from './Input';\n"]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["
|
|
1
|
+
{"version":3,"sources":["Input.ts"],"names":[],"mappings":";;;;;;;;AAAA,OAAA,CAAA,YAAA,CAAA,OAAA,CAAA,0BAAA,CAAA,EAAA,OAAA","sourcesContent":["export * from './components/Input/index';\n"],"sourceRoot":"../src/"}
|
|
@@ -14,15 +14,13 @@ const renderInput_1 = /*#__PURE__*/require("./renderInput");
|
|
|
14
14
|
const useInputStyles_1 = /*#__PURE__*/require("./useInputStyles");
|
|
15
15
|
/**
|
|
16
16
|
* The Input component allows people to enter and edit text.
|
|
17
|
-
*
|
|
18
|
-
* ⚠️ **This component is still in alpha (unstable) status. APIs may change before the final release.**
|
|
19
17
|
*/
|
|
20
18
|
|
|
21
19
|
|
|
22
20
|
exports.Input = /*#__PURE__*/React.forwardRef((props, ref) => {
|
|
23
|
-
const state = useInput_1.
|
|
24
|
-
useInputStyles_1.
|
|
25
|
-
return renderInput_1.
|
|
21
|
+
const state = useInput_1.useInput_unstable(props, ref);
|
|
22
|
+
useInputStyles_1.useInputStyles_unstable(state);
|
|
23
|
+
return renderInput_1.renderInput_unstable(state);
|
|
26
24
|
});
|
|
27
25
|
exports.Input.displayName = 'Input';
|
|
28
26
|
//# sourceMappingURL=Input.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["
|
|
1
|
+
{"version":3,"sources":["components/Input/Input.tsx"],"names":[],"mappings":";;;;;;;AAAA,MAAA,KAAA,gBAAA,OAAA,CAAA,OAAA,CAAA;;AACA,MAAA,UAAA,gBAAA,OAAA,CAAA,YAAA,CAAA;;AACA,MAAA,aAAA,gBAAA,OAAA,CAAA,eAAA,CAAA;;AACA,MAAA,gBAAA,gBAAA,OAAA,CAAA,kBAAA,CAAA;AAIA;;AAEG;;;AACU,OAAA,CAAA,KAAA,gBAAyC,KAAK,CAAC,UAAN,CAAiB,CAAC,KAAD,EAAQ,GAAR,KAAe;EACpF,MAAM,KAAK,GAAG,UAAA,CAAA,iBAAA,CAAkB,KAAlB,EAAyB,GAAzB,CAAd;EAEA,gBAAA,CAAA,uBAAA,CAAwB,KAAxB;EACA,OAAO,aAAA,CAAA,oBAAA,CAAqB,KAArB,CAAP;AACD,CALqD,CAAzC;AAOb,OAAA,CAAA,KAAA,CAAM,WAAN,GAAoB,OAApB","sourcesContent":["import * as React from 'react';\nimport { useInput_unstable } from './useInput';\nimport { renderInput_unstable } from './renderInput';\nimport { useInputStyles_unstable } from './useInputStyles';\nimport type { InputProps } from './Input.types';\nimport type { ForwardRefComponent } from '@fluentui/react-utilities';\n\n/**\n * The Input component allows people to enter and edit text.\n */\nexport const Input: ForwardRefComponent<InputProps> = React.forwardRef((props, ref) => {\n const state = useInput_unstable(props, ref);\n\n useInputStyles_unstable(state);\n return renderInput_unstable(state);\n});\n\nInput.displayName = 'Input';\n"],"sourceRoot":"../src/"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":[],"names":[],"mappings":"","sourceRoot":""}
|
|
1
|
+
{"version":3,"sources":[],"names":[],"mappings":"","sourceRoot":"../src/"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["
|
|
1
|
+
{"version":3,"sources":["components/Input/index.ts"],"names":[],"mappings":";;;;;;;;AAAA,OAAA,CAAA,YAAA,CAAA,OAAA,CAAA,SAAA,CAAA,EAAA,OAAA;;AACA,OAAA,CAAA,YAAA,CAAA,OAAA,CAAA,eAAA,CAAA,EAAA,OAAA;;AACA,OAAA,CAAA,YAAA,CAAA,OAAA,CAAA,eAAA,CAAA,EAAA,OAAA;;AACA,OAAA,CAAA,YAAA,CAAA,OAAA,CAAA,YAAA,CAAA,EAAA,OAAA;;AACA,OAAA,CAAA,YAAA,CAAA,OAAA,CAAA,kBAAA,CAAA,EAAA,OAAA","sourcesContent":["export * from './Input';\nexport * from './Input.types';\nexport * from './renderInput';\nexport * from './useInput';\nexport * from './useInputStyles';\n"],"sourceRoot":"../src/"}
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
Object.defineProperty(exports, "__esModule", {
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
|
-
exports.
|
|
6
|
+
exports.renderInput_unstable = void 0;
|
|
7
7
|
|
|
8
8
|
const React = /*#__PURE__*/require("react");
|
|
9
9
|
|
|
@@ -13,17 +13,17 @@ const react_utilities_1 = /*#__PURE__*/require("@fluentui/react-utilities");
|
|
|
13
13
|
*/
|
|
14
14
|
|
|
15
15
|
|
|
16
|
-
const
|
|
16
|
+
const renderInput_unstable = state => {
|
|
17
17
|
const {
|
|
18
18
|
slots,
|
|
19
19
|
slotProps
|
|
20
|
-
} = react_utilities_1.getSlots(state
|
|
20
|
+
} = react_utilities_1.getSlots(state);
|
|
21
21
|
return React.createElement(slots.root, { ...slotProps.root
|
|
22
|
-
}, React.createElement(slots.contentBefore, { ...slotProps.contentBefore
|
|
22
|
+
}, slots.contentBefore && React.createElement(slots.contentBefore, { ...slotProps.contentBefore
|
|
23
23
|
}), React.createElement(slots.input, { ...slotProps.input
|
|
24
|
-
}), React.createElement(slots.contentAfter, { ...slotProps.contentAfter
|
|
24
|
+
}), slots.contentAfter && React.createElement(slots.contentAfter, { ...slotProps.contentAfter
|
|
25
25
|
}));
|
|
26
26
|
};
|
|
27
27
|
|
|
28
|
-
exports.
|
|
28
|
+
exports.renderInput_unstable = renderInput_unstable;
|
|
29
29
|
//# sourceMappingURL=renderInput.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["
|
|
1
|
+
{"version":3,"sources":["components/Input/renderInput.tsx"],"names":[],"mappings":";;;;;;;AAAA,MAAA,KAAA,gBAAA,OAAA,CAAA,OAAA,CAAA;;AACA,MAAA,iBAAA,gBAAA,OAAA,CAAA,2BAAA,CAAA;AAGA;;AAEG;;;AACI,MAAM,oBAAoB,GAAI,KAAD,IAAsB;EACxD,MAAM;IAAE,KAAF;IAAS;EAAT,IAAuB,iBAAA,CAAA,QAAA,CAAqB,KAArB,CAA7B;EACA,OACE,KAAA,CAAA,aAAA,CAAC,KAAK,CAAC,IAAP,EAAW,EAAA,GAAK,SAAS,CAAC;EAAf,CAAX,EACG,KAAK,CAAC,aAAN,IAAuB,KAAA,CAAA,aAAA,CAAC,KAAK,CAAC,aAAP,EAAoB,EAAA,GAAK,SAAS,CAAC;EAAf,CAApB,CAD1B,EAEE,KAAA,CAAA,aAAA,CAAC,KAAK,CAAC,KAAP,EAAY,EAAA,GAAK,SAAS,CAAC;EAAf,CAAZ,CAFF,EAGG,KAAK,CAAC,YAAN,IAAsB,KAAA,CAAA,aAAA,CAAC,KAAK,CAAC,YAAP,EAAmB,EAAA,GAAK,SAAS,CAAC;EAAf,CAAnB,CAHzB,CADF;AAOD,CATM;;AAAM,OAAA,CAAA,oBAAA,GAAoB,oBAApB","sourcesContent":["import * as React from 'react';\nimport { getSlots } from '@fluentui/react-utilities';\nimport type { InputSlots, InputState } from './Input.types';\n\n/**\n * Render the final JSX of Input\n */\nexport const renderInput_unstable = (state: InputState) => {\n const { slots, slotProps } = getSlots<InputSlots>(state);\n return (\n <slots.root {...slotProps.root}>\n {slots.contentBefore && <slots.contentBefore {...slotProps.contentBefore} />}\n <slots.input {...slotProps.input} />\n {slots.contentAfter && <slots.contentAfter {...slotProps.contentAfter} />}\n </slots.root>\n );\n};\n"],"sourceRoot":"../src/"}
|
|
@@ -3,25 +3,24 @@
|
|
|
3
3
|
Object.defineProperty(exports, "__esModule", {
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
|
-
exports.
|
|
6
|
+
exports.useInput_unstable = void 0;
|
|
7
7
|
|
|
8
8
|
const react_utilities_1 = /*#__PURE__*/require("@fluentui/react-utilities");
|
|
9
9
|
/**
|
|
10
10
|
* Create the state required to render Input.
|
|
11
11
|
*
|
|
12
|
-
* The returned state can be modified with hooks such as
|
|
13
|
-
* before being passed to
|
|
12
|
+
* The returned state can be modified with hooks such as useInputStyles_unstable,
|
|
13
|
+
* before being passed to renderInput_unstable.
|
|
14
14
|
*
|
|
15
15
|
* @param props - props from this instance of Input
|
|
16
16
|
* @param ref - reference to `<input>` element of Input
|
|
17
17
|
*/
|
|
18
18
|
|
|
19
19
|
|
|
20
|
-
const
|
|
20
|
+
const useInput_unstable = (props, ref) => {
|
|
21
21
|
const {
|
|
22
22
|
size = 'medium',
|
|
23
23
|
appearance = 'outline',
|
|
24
|
-
inline = false,
|
|
25
24
|
onChange
|
|
26
25
|
} = props;
|
|
27
26
|
const [value, setValue] = react_utilities_1.useControllableState({
|
|
@@ -37,7 +36,6 @@ const useInput = (props, ref) => {
|
|
|
37
36
|
const state = {
|
|
38
37
|
size,
|
|
39
38
|
appearance,
|
|
40
|
-
inline,
|
|
41
39
|
components: {
|
|
42
40
|
root: 'span',
|
|
43
41
|
input: 'input',
|
|
@@ -70,5 +68,5 @@ const useInput = (props, ref) => {
|
|
|
70
68
|
return state;
|
|
71
69
|
};
|
|
72
70
|
|
|
73
|
-
exports.
|
|
71
|
+
exports.useInput_unstable = useInput_unstable;
|
|
74
72
|
//# sourceMappingURL=useInput.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["
|
|
1
|
+
{"version":3,"sources":["components/Input/useInput.ts"],"names":[],"mappings":";;;;;;;AACA,MAAA,iBAAA,gBAAA,OAAA,CAAA,2BAAA,CAAA;AAQA;;;;;;;;AAQG;;;AACI,MAAM,iBAAiB,GAAG,CAAC,KAAD,EAAoB,GAApB,KAAoE;EACnG,MAAM;IAAE,IAAI,GAAG,QAAT;IAAmB,UAAU,GAAG,SAAhC;IAA2C;EAA3C,IAAwD,KAA9D;EAEA,MAAM,CAAC,KAAD,EAAQ,QAAR,IAAoB,iBAAA,CAAA,oBAAA,CAAqB;IAC7C,KAAK,EAAE,KAAK,CAAC,KADgC;IAE7C,YAAY,EAAE,KAAK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AAK,EAAE;IAAT,CAAP,CAAR;IACA,QAAQ,CAAC,QAAD,CAAR;EACD,CAJsB,CAAvB;EAMA,OAAO,KAAP;AACD,CAhDM;;AAAM,OAAA,CAAA,iBAAA,GAAiB,iBAAjB","sourcesContent":["import * as React from 'react';\nimport {\n getPartitionedNativeProps,\n resolveShorthand,\n useControllableState,\n useEventCallback,\n} from '@fluentui/react-utilities';\nimport type { InputProps, InputState } from './Input.types';\n\n/**\n * Create the state required to render Input.\n *\n * The returned state can be modified with hooks such as useInputStyles_unstable,\n * before being passed to renderInput_unstable.\n *\n * @param props - props from this instance of Input\n * @param ref - reference to `<input>` element of Input\n */\nexport const useInput_unstable = (props: InputProps, ref: React.Ref<HTMLInputElement>): InputState => {\n const { size = 'medium', appearance = 'outline', onChange } = props;\n\n const [value, setValue] = useControllableState({\n state: props.value,\n defaultState: props.defaultValue,\n initialState: undefined,\n });\n\n const nativeProps = getPartitionedNativeProps({\n props,\n primarySlotTagName: 'input',\n excludedPropNames: ['size', 'onChange', 'value', 'defaultValue'],\n });\n\n const state: InputState = {\n size,\n appearance,\n components: {\n root: 'span',\n input: 'input',\n contentBefore: 'span',\n contentAfter: 'span',\n },\n input: resolveShorthand(props.input, {\n required: true,\n defaultProps: {\n type: 'text',\n ref,\n ...nativeProps.primary,\n },\n }),\n contentAfter: resolveShorthand(props.contentAfter),\n contentBefore: resolveShorthand(props.contentBefore),\n root: resolveShorthand(props.root, {\n required: true,\n defaultProps: nativeProps.root,\n }),\n };\n\n state.input.value = value;\n state.input.onChange = useEventCallback(ev => {\n const newValue = ev.target.value;\n onChange?.(ev, { value: newValue });\n setValue(newValue);\n });\n\n return state;\n};\n"],"sourceRoot":"../src/"}
|
|
@@ -3,43 +3,26 @@
|
|
|
3
3
|
Object.defineProperty(exports, "__esModule", {
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
|
-
exports.
|
|
6
|
+
exports.useInputStyles_unstable = exports.inputClassNames = void 0;
|
|
7
7
|
|
|
8
|
-
const
|
|
8
|
+
const react_1 = /*#__PURE__*/require("@griffel/react");
|
|
9
9
|
|
|
10
|
-
|
|
10
|
+
const react_theme_1 = /*#__PURE__*/require("@fluentui/react-theme");
|
|
11
|
+
|
|
12
|
+
exports.inputClassNames = {
|
|
13
|
+
root: 'fui-Input',
|
|
14
|
+
input: 'fui-Input__input',
|
|
15
|
+
contentBefore: 'fui-Input__contentBefore',
|
|
16
|
+
contentAfter: 'fui-Input__contentAfter'
|
|
17
|
+
}; // TODO(sharing) use theme values once available
|
|
11
18
|
|
|
12
|
-
const horizontalSpacing = {
|
|
13
|
-
xxs: '2px',
|
|
14
|
-
xs: '4px',
|
|
15
|
-
sNudge: '6px',
|
|
16
|
-
s: '8px',
|
|
17
|
-
mNudge: '10px',
|
|
18
|
-
m: '12px'
|
|
19
|
-
};
|
|
20
|
-
const motionDurations = {
|
|
21
|
-
ultraFast: '0.05s',
|
|
22
|
-
normal: '0.2s'
|
|
23
|
-
};
|
|
24
|
-
const motionCurves = {
|
|
25
|
-
accelerateMid: 'cubic-bezier(0.7,0,1,0.5)',
|
|
26
|
-
decelerateMid: 'cubic-bezier(0.1,0.9,0.2,1)'
|
|
27
|
-
};
|
|
28
19
|
const contentSizes = {
|
|
29
|
-
// TODO
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
fontSize: theme.fontSizeBase200,
|
|
36
|
-
lineHeight: theme.lineHeightBase200
|
|
37
|
-
}),
|
|
38
|
-
// eslint-disable-next-line @typescript-eslint/naming-convention
|
|
39
|
-
400: theme => ({
|
|
40
|
-
fontSize: theme.fontSizeBase400,
|
|
41
|
-
lineHeight: theme.lineHeightBase400
|
|
42
|
-
})
|
|
20
|
+
// TODO: This 400 style is not in the typography styles.
|
|
21
|
+
// May need a design change
|
|
22
|
+
400: {
|
|
23
|
+
fontSize: react_theme_1.tokens.fontSizeBase400,
|
|
24
|
+
lineHeight: react_theme_1.tokens.lineHeightBase400
|
|
25
|
+
}
|
|
43
26
|
}; // TODO(sharing) should these be shared somewhere?
|
|
44
27
|
|
|
45
28
|
const fieldHeights = {
|
|
@@ -48,13 +31,13 @@ const fieldHeights = {
|
|
|
48
31
|
large: '40px'
|
|
49
32
|
};
|
|
50
33
|
|
|
51
|
-
const useRootStyles = /*#__PURE__*/
|
|
34
|
+
const useRootStyles = /*#__PURE__*/react_1.__styles({
|
|
52
35
|
"base": {
|
|
53
|
-
"mc9l5x": "
|
|
36
|
+
"mc9l5x": "ftuwxu6",
|
|
54
37
|
"Bt984gj": "f122n59",
|
|
55
38
|
"Eh141a": "flvyvdh",
|
|
56
|
-
"i8kkvl": "
|
|
57
|
-
"Belr9w4": "
|
|
39
|
+
"i8kkvl": "f14mj54c",
|
|
40
|
+
"Belr9w4": "fiut8dr",
|
|
58
41
|
"Bahqtrf": "fk6fouc",
|
|
59
42
|
"Bbmb7ep": ["f1aa9q02", "f16jpd5f"],
|
|
60
43
|
"Beyfa6y": ["f16jpd5f", "f1aa9q02"],
|
|
@@ -64,60 +47,64 @@ const useRootStyles = /*#__PURE__*/react_make_styles_1.__styles({
|
|
|
64
47
|
"B7ck84d": "f1ewtqcl"
|
|
65
48
|
},
|
|
66
49
|
"interactive": {
|
|
67
|
-
"
|
|
68
|
-
"
|
|
69
|
-
"
|
|
70
|
-
"
|
|
71
|
-
"
|
|
72
|
-
"
|
|
73
|
-
"
|
|
74
|
-
"
|
|
75
|
-
"
|
|
76
|
-
"
|
|
77
|
-
"
|
|
78
|
-
"
|
|
79
|
-
"
|
|
80
|
-
"
|
|
81
|
-
"
|
|
82
|
-
"
|
|
83
|
-
"
|
|
84
|
-
"
|
|
85
|
-
"
|
|
86
|
-
"
|
|
87
|
-
"
|
|
88
|
-
"
|
|
50
|
+
"li1rpt": "f1gw3sf2",
|
|
51
|
+
"Bsft5z2": "f13zj6fq",
|
|
52
|
+
"E3zdtr": "f1mdlcz9",
|
|
53
|
+
"Eqx8gd": ["f1a7op3", "f1cjjd47"],
|
|
54
|
+
"By385i5": "f1gboi2j",
|
|
55
|
+
"B1piin3": ["f1cjjd47", "f1a7op3"],
|
|
56
|
+
"Dlnsje": "f145g4dw",
|
|
57
|
+
"d9w3h3": ["f1kp91vd", "f1ibwz09"],
|
|
58
|
+
"B3778ie": ["f1ibwz09", "f1kp91vd"],
|
|
59
|
+
"Bcgy8vk": "f1cb6c3",
|
|
60
|
+
"Bw17bha": "f1lh990p",
|
|
61
|
+
"B1q35kw": "f1jc6hxc",
|
|
62
|
+
"Gjdm7m": "f13evtba",
|
|
63
|
+
"b1kco5": "f1yk9hq",
|
|
64
|
+
"Ba2ppi3": "fhwpy7i",
|
|
65
|
+
"F2fol1": "f14ee0xe",
|
|
66
|
+
"lck23g": "f1xhbsuh",
|
|
67
|
+
"umuwi5": "fjw5xc1",
|
|
68
|
+
"Blcqepd": "f1xdyd5c",
|
|
69
|
+
"nplu4u": "fatpbeo",
|
|
70
|
+
"Bioka5o": "fb7uyps",
|
|
71
|
+
"Bercvud": "f1ibeo51",
|
|
72
|
+
"Bbr2w1p": "f14a1fxs",
|
|
73
|
+
"Bduesf4": "f3e99gv",
|
|
74
|
+
"Bpq79vn": "fhljsf7"
|
|
89
75
|
},
|
|
90
76
|
"small": {
|
|
91
77
|
"sshi5w": "f1pha7fy",
|
|
92
78
|
"z8tnut": "f1g0x7ka",
|
|
93
|
-
"z189sj": ["
|
|
79
|
+
"z189sj": ["fdw0yi8", "fk8j09s"],
|
|
94
80
|
"Byoj8tv": "f1qch9an",
|
|
95
|
-
"uwmqm3": ["
|
|
81
|
+
"uwmqm3": ["fk8j09s", "fdw0yi8"],
|
|
82
|
+
"Bahqtrf": "fk6fouc",
|
|
96
83
|
"Be2twd7": "fy9rknc",
|
|
84
|
+
"Bhrd7zp": "figsok6",
|
|
97
85
|
"Bg96gwp": "fwrc4pm"
|
|
98
86
|
},
|
|
99
87
|
"medium": {
|
|
100
88
|
"sshi5w": "f1nxs5xn",
|
|
101
89
|
"z8tnut": "f1g0x7ka",
|
|
102
|
-
"z189sj": ["
|
|
90
|
+
"z189sj": ["f11gcy0p", "f1ng84yb"],
|
|
103
91
|
"Byoj8tv": "f1qch9an",
|
|
104
|
-
"uwmqm3": ["
|
|
92
|
+
"uwmqm3": ["f1ng84yb", "f11gcy0p"],
|
|
93
|
+
"Bahqtrf": "fk6fouc",
|
|
105
94
|
"Be2twd7": "fkhj508",
|
|
95
|
+
"Bhrd7zp": "figsok6",
|
|
106
96
|
"Bg96gwp": "f1i3iumi"
|
|
107
97
|
},
|
|
108
98
|
"large": {
|
|
109
99
|
"sshi5w": "f1w5jphr",
|
|
110
100
|
"z8tnut": "f1g0x7ka",
|
|
111
|
-
"z189sj": ["
|
|
101
|
+
"z189sj": ["fw5db7e", "f1uw59to"],
|
|
112
102
|
"Byoj8tv": "f1qch9an",
|
|
113
|
-
"uwmqm3": ["
|
|
103
|
+
"uwmqm3": ["f1uw59to", "fw5db7e"],
|
|
114
104
|
"Be2twd7": "fod5ikn",
|
|
115
105
|
"Bg96gwp": "faaz57k",
|
|
116
|
-
"i8kkvl": "
|
|
117
|
-
"Belr9w4": "
|
|
118
|
-
},
|
|
119
|
-
"inline": {
|
|
120
|
-
"mc9l5x": "ftuwxu6"
|
|
106
|
+
"i8kkvl": "f1rjii52",
|
|
107
|
+
"Belr9w4": "f1r7g2jn"
|
|
121
108
|
},
|
|
122
109
|
"outline": {
|
|
123
110
|
"De3pzq": "fxugw4r",
|
|
@@ -157,10 +144,10 @@ const useRootStyles = /*#__PURE__*/react_make_styles_1.__styles({
|
|
|
157
144
|
"underlineInteractive": {
|
|
158
145
|
"oetu4i": "f1l4zc64",
|
|
159
146
|
"Be8ivqh": "f1klwx88",
|
|
160
|
-
"
|
|
161
|
-
"
|
|
162
|
-
"
|
|
163
|
-
"
|
|
147
|
+
"B3778ie": ["f1nf3wye", "feulmo5"],
|
|
148
|
+
"d9w3h3": ["feulmo5", "f1nf3wye"],
|
|
149
|
+
"Bl18szs": ["f18vqdqu", "f53nyzz"],
|
|
150
|
+
"B4j8arr": ["f53nyzz", "f18vqdqu"]
|
|
164
151
|
},
|
|
165
152
|
"filled": {
|
|
166
153
|
"E5pizo": "fyed02w",
|
|
@@ -183,14 +170,15 @@ const useRootStyles = /*#__PURE__*/react_make_styles_1.__styles({
|
|
|
183
170
|
"nagaa4": "f1tpwn32",
|
|
184
171
|
"B1yhkcb": ["fsrcdbj", "f17blpuu"]
|
|
185
172
|
},
|
|
186
|
-
"
|
|
173
|
+
"filled-darker": {
|
|
187
174
|
"De3pzq": "f16xq7d1"
|
|
188
175
|
},
|
|
189
|
-
"
|
|
176
|
+
"filled-lighter": {
|
|
190
177
|
"De3pzq": "fxugw4r"
|
|
191
178
|
},
|
|
192
179
|
"disabled": {
|
|
193
180
|
"Bceei9c": "fdrzuqr",
|
|
181
|
+
"De3pzq": "f1c21dwh",
|
|
194
182
|
"B4j52fo": "f5ogflp",
|
|
195
183
|
"Bekrc4i": ["f1hqa2wf", "finvdd3"],
|
|
196
184
|
"Bn0qgzm": "f1f09k3d",
|
|
@@ -206,48 +194,66 @@ const useRootStyles = /*#__PURE__*/react_make_styles_1.__styles({
|
|
|
206
194
|
"Bbmb7ep": ["f1aa9q02", "f16jpd5f"],
|
|
207
195
|
"Beyfa6y": ["f16jpd5f", "f1aa9q02"],
|
|
208
196
|
"B7oj6ja": ["f1jar5jt", "fyu767a"],
|
|
209
|
-
"Btl43ni": ["fyu767a", "f1jar5jt"]
|
|
197
|
+
"Btl43ni": ["fyu767a", "f1jar5jt"],
|
|
198
|
+
"Bjwas2f": "fg455y9",
|
|
199
|
+
"Bn1d65q": ["f1rvyvqg", "f14g86mu"],
|
|
200
|
+
"Bxeuatn": "f1cwzwz",
|
|
201
|
+
"n51gp8": ["f14g86mu", "f1rvyvqg"]
|
|
210
202
|
}
|
|
211
203
|
}, {
|
|
212
|
-
"d": [".
|
|
213
|
-
"w": [".
|
|
214
|
-
"h": [".fvcxoqz:hover{border-top-color:var(--colorNeutralStroke1Hover);}", ".f1ub3y4t:hover{border-right-color:var(--colorNeutralStroke1Hover);}", ".f1m52nbi:hover{border-left-color:var(--colorNeutralStroke1Hover);}", ".f1l4zc64:hover{border-bottom-color:var(--colorNeutralStrokeAccessibleHover);}", ".ftmjh5b:hover,.ftmjh5b:focus-within{border-top-color:var(--colorTransparentStrokeInteractive);}", ".f17blpuu:hover,.f17blpuu:focus-within{border-right-color:var(--colorTransparentStrokeInteractive);}", ".fsrcdbj:hover
|
|
215
|
-
"a": [".f8vnjqi:active,.f8vnjqi:focus-within{border-top-color:var(--colorNeutralStroke1Pressed);}", ".fz1etlk:active,.fz1etlk:focus-within{border-right-color:var(--colorNeutralStroke1Pressed);}", ".f1hc16gm:active
|
|
204
|
+
"d": [".ftuwxu6{display:-webkit-inline-box;display:-webkit-inline-flex;display:-ms-inline-flexbox;display:inline-flex;}", ".f122n59{-webkit-align-items:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center;}", ".flvyvdh{-webkit-box-flex-wrap:nowrap;-webkit-flex-wrap:nowrap;-ms-flex-wrap:nowrap;flex-wrap:nowrap;}", ".f14mj54c{-webkit-column-gap:var(--spacingHorizontalXXS);column-gap:var(--spacingHorizontalXXS);}", ".fiut8dr{row-gap:var(--spacingHorizontalXXS);}", ".fk6fouc{font-family:var(--fontFamilyBase);}", ".f1aa9q02{border-bottom-right-radius:var(--borderRadiusMedium);}", ".f16jpd5f{border-bottom-left-radius:var(--borderRadiusMedium);}", ".f1jar5jt{border-top-right-radius:var(--borderRadiusMedium);}", ".fyu767a{border-top-left-radius:var(--borderRadiusMedium);}", ".f10pi13n{position:relative;}", ".f1ewtqcl{box-sizing:border-box;}", ".f1gw3sf2::after{box-sizing:border-box;}", ".f13zj6fq::after{content:\"\";}", ".f1mdlcz9::after{position:absolute;}", ".f1a7op3::after{left:-1px;}", ".f1cjjd47::after{right:-1px;}", ".f1gboi2j::after{bottom:-1px;}", ".f145g4dw::after{height:max(2px, var(--borderRadiusMedium));}", ".f1kp91vd::after{border-bottom-left-radius:var(--borderRadiusMedium);}", ".f1ibwz09::after{border-bottom-right-radius:var(--borderRadiusMedium);}", ".f1cb6c3::after{border-bottom-width:2px;}", ".f1lh990p::after{border-bottom-style:solid;}", ".f1jc6hxc::after{border-bottom-color:var(--colorCompoundBrandStroke);}", ".f13evtba::after{-webkit-clip-path:inset(calc(100% - 2px) 0 0 0);clip-path:inset(calc(100% - 2px) 0 0 0);}", ".f1yk9hq::after{-webkit-transform:scaleX(0);-moz-transform:scaleX(0);-ms-transform:scaleX(0);transform:scaleX(0);}", ".fhwpy7i::after{transition-property:transform;}", ".f14ee0xe::after{transition-duration:var(--durationUltraFast);}", ".f1xhbsuh::after{transition-delay:var(--curveAccelerateMid);}", ".f1pha7fy{min-height:24px;}", ".f1g0x7ka{padding-top:0;}", ".fdw0yi8{padding-right:var(--spacingHorizontalSNudge);}", ".fk8j09s{padding-left:var(--spacingHorizontalSNudge);}", ".f1qch9an{padding-bottom:0;}", ".fy9rknc{font-size:var(--fontSizeBase200);}", ".figsok6{font-weight:var(--fontWeightRegular);}", ".fwrc4pm{line-height:var(--lineHeightBase200);}", ".f1nxs5xn{min-height:32px;}", ".f11gcy0p{padding-right:var(--spacingHorizontalMNudge);}", ".f1ng84yb{padding-left:var(--spacingHorizontalMNudge);}", ".fkhj508{font-size:var(--fontSizeBase300);}", ".f1i3iumi{line-height:var(--lineHeightBase300);}", ".f1w5jphr{min-height:40px;}", ".fw5db7e{padding-right:var(--spacingHorizontalM);}", ".f1uw59to{padding-left:var(--spacingHorizontalM);}", ".fod5ikn{font-size:var(--fontSizeBase400);}", ".faaz57k{line-height:var(--lineHeightBase400);}", ".f1rjii52{-webkit-column-gap:var(--spacingHorizontalSNudge);column-gap:var(--spacingHorizontalSNudge);}", ".f1r7g2jn{row-gap:var(--spacingHorizontalSNudge);}", ".fxugw4r{background-color:var(--colorNeutralBackground1);}", ".f5ogflp{border-top-width:1px;}", ".f1hqa2wf{border-right-width:1px;}", ".finvdd3{border-left-width:1px;}", ".f1f09k3d{border-bottom-width:1px;}", ".fzkkow9{border-top-style:solid;}", ".fcdblym{border-right-style:solid;}", ".fjik90z{border-left-style:solid;}", ".fg706s2{border-bottom-style:solid;}", ".fj3muxo{border-top-color:var(--colorNeutralStroke1);}", ".f1akhkt{border-right-color:var(--colorNeutralStroke1);}", ".f1lxtadh{border-left-color:var(--colorNeutralStroke1);}", ".f1c1zstj{border-bottom-color:var(--colorNeutralStrokeAccessible);}", ".f1c21dwh{background-color:var(--colorTransparentBackground);}", ".f1krrbdw{border-bottom-right-radius:0;}", ".f1deotkl{border-bottom-left-radius:0;}", ".f10ostut{border-top-right-radius:0;}", ".f1ozlkrg{border-top-left-radius:0;}", ".f1nf3wye::after{border-bottom-right-radius:0;}", ".feulmo5::after{border-bottom-left-radius:0;}", ".f18vqdqu::after{border-top-right-radius:0;}", ".f53nyzz::after{border-top-left-radius:0;}", ".fyed02w{box-shadow:var(--shadow2);}", ".fghlq4f{border-top-color:var(--colorTransparentStroke);}", ".f1gn591s{border-right-color:var(--colorTransparentStroke);}", ".fjscplz{border-left-color:var(--colorTransparentStroke);}", ".fb073pr{border-bottom-color:var(--colorTransparentStroke);}", ".f16xq7d1{background-color:var(--colorNeutralBackground3);}", ".fdrzuqr{cursor:not-allowed;}", ".f1jj8ep1{border-top-color:var(--colorNeutralStrokeDisabled);}", ".f15xbau{border-right-color:var(--colorNeutralStrokeDisabled);}", ".fy0fskl{border-left-color:var(--colorNeutralStrokeDisabled);}", ".f4ikngz{border-bottom-color:var(--colorNeutralStrokeDisabled);}"],
|
|
205
|
+
"w": [".fjw5xc1:focus-within::after{-webkit-transform:scaleX(1);-moz-transform:scaleX(1);-ms-transform:scaleX(1);transform:scaleX(1);}", ".f1xdyd5c:focus-within::after{transition-property:transform;}", ".fatpbeo:focus-within::after{transition-duration:var(--durationNormal);}", ".fb7uyps:focus-within::after{transition-delay:var(--curveDecelerateMid);}", ".f1ibeo51:focus-within:active::after{border-bottom-color:var(--colorCompoundBrandStrokePressed);}", ".f14a1fxs:focus-within{outline-width:2px;}", ".f3e99gv:focus-within{outline-style:solid;}", ".fhljsf7:focus-within{outline-color:transparent;}"],
|
|
206
|
+
"h": [".fvcxoqz:hover{border-top-color:var(--colorNeutralStroke1Hover);}", ".f1ub3y4t:hover{border-right-color:var(--colorNeutralStroke1Hover);}", ".f1m52nbi:hover{border-left-color:var(--colorNeutralStroke1Hover);}", ".f1l4zc64:hover{border-bottom-color:var(--colorNeutralStrokeAccessibleHover);}", ".ftmjh5b:hover,.ftmjh5b:focus-within{border-top-color:var(--colorTransparentStrokeInteractive);}", ".f17blpuu:hover,.f17blpuu:focus-within{border-right-color:var(--colorTransparentStrokeInteractive);}", ".fsrcdbj:hover,.fsrcdbj:focus-within{border-left-color:var(--colorTransparentStrokeInteractive);}", ".f1tpwn32:hover,.f1tpwn32:focus-within{border-bottom-color:var(--colorTransparentStrokeInteractive);}"],
|
|
207
|
+
"a": [".f8vnjqi:active,.f8vnjqi:focus-within{border-top-color:var(--colorNeutralStroke1Pressed);}", ".fz1etlk:active,.fz1etlk:focus-within{border-right-color:var(--colorNeutralStroke1Pressed);}", ".f1hc16gm:active,.f1hc16gm:focus-within{border-left-color:var(--colorNeutralStroke1Pressed);}", ".f1klwx88:active,.f1klwx88:focus-within{border-bottom-color:var(--colorNeutralStrokeAccessiblePressed);}"],
|
|
208
|
+
"m": [["@media (forced-colors: active){.fg455y9{border-top-color:GrayText;}}", {
|
|
209
|
+
"m": "(forced-colors: active)"
|
|
210
|
+
}], ["@media (forced-colors: active){.f1rvyvqg{border-right-color:GrayText;}.f14g86mu{border-left-color:GrayText;}}", {
|
|
211
|
+
"m": "(forced-colors: active)"
|
|
212
|
+
}], ["@media (forced-colors: active){.f1cwzwz{border-bottom-color:GrayText;}}", {
|
|
213
|
+
"m": "(forced-colors: active)"
|
|
214
|
+
}], ["@media (forced-colors: active){.f14g86mu{border-left-color:GrayText;}.f1rvyvqg{border-right-color:GrayText;}}", {
|
|
215
|
+
"m": "(forced-colors: active)"
|
|
216
|
+
}]]
|
|
216
217
|
});
|
|
217
218
|
|
|
218
|
-
const useInputElementStyles = /*#__PURE__*/
|
|
219
|
+
const useInputElementStyles = /*#__PURE__*/react_1.__styles({
|
|
219
220
|
"base": {
|
|
220
221
|
"B7ck84d": "f1ewtqcl",
|
|
221
222
|
"Bh6795r": "fqerorx",
|
|
223
|
+
"Bf4jedk": "fy77jfu",
|
|
222
224
|
"icvyot": "f1ern45e",
|
|
223
225
|
"vrafjx": ["f1n71otn", "f1deefiw"],
|
|
224
226
|
"oivjwe": "f1h8hb77",
|
|
225
227
|
"wvpqe5": ["f1deefiw", "f1n71otn"],
|
|
226
228
|
"z8tnut": "f1g0x7ka",
|
|
227
|
-
"z189sj": ["
|
|
229
|
+
"z189sj": ["ffczdla", "fgiv446"],
|
|
228
230
|
"Byoj8tv": "f1qch9an",
|
|
229
|
-
"uwmqm3": ["
|
|
231
|
+
"uwmqm3": ["fgiv446", "ffczdla"],
|
|
230
232
|
"sj55zd": "f19n0e5",
|
|
231
233
|
"De3pzq": "f3rmtva",
|
|
232
234
|
"yvdlaj": "fwyc1cq",
|
|
233
235
|
"B3o7kgh": "f13ta7ih",
|
|
234
|
-
"
|
|
236
|
+
"oeaueh": "f1s6fcnf"
|
|
235
237
|
},
|
|
236
238
|
"small": {
|
|
239
|
+
"Bahqtrf": "fk6fouc",
|
|
237
240
|
"Be2twd7": "fy9rknc",
|
|
241
|
+
"Bhrd7zp": "figsok6",
|
|
238
242
|
"Bg96gwp": "fwrc4pm"
|
|
239
243
|
},
|
|
240
244
|
"medium": {
|
|
245
|
+
"Bahqtrf": "fk6fouc",
|
|
241
246
|
"Be2twd7": "fkhj508",
|
|
247
|
+
"Bhrd7zp": "figsok6",
|
|
242
248
|
"Bg96gwp": "f1i3iumi"
|
|
243
249
|
},
|
|
244
250
|
"large": {
|
|
245
251
|
"Be2twd7": "fod5ikn",
|
|
246
252
|
"Bg96gwp": "faaz57k",
|
|
247
253
|
"z8tnut": "f1g0x7ka",
|
|
248
|
-
"z189sj": ["
|
|
254
|
+
"z189sj": ["fdw0yi8", "fk8j09s"],
|
|
249
255
|
"Byoj8tv": "f1qch9an",
|
|
250
|
-
"uwmqm3": ["
|
|
256
|
+
"uwmqm3": ["fk8j09s", "fdw0yi8"]
|
|
251
257
|
},
|
|
252
258
|
"disabled": {
|
|
253
259
|
"sj55zd": "f1s2aq7o",
|
|
@@ -256,11 +262,10 @@ const useInputElementStyles = /*#__PURE__*/react_make_styles_1.__styles({
|
|
|
256
262
|
"yvdlaj": "fahhnxm"
|
|
257
263
|
}
|
|
258
264
|
}, {
|
|
259
|
-
"d": [".f1ewtqcl{box-sizing:border-box;}", ".fqerorx{-webkit-box-flex:1;-webkit-flex-grow:1;-ms-flex-positive:1;flex-grow:1;}", ".f1ern45e{border-top-style:none;}", ".f1n71otn{border-right-style:none;}", ".f1deefiw{border-left-style:none;}", ".f1h8hb77{border-bottom-style:none;}", ".f1g0x7ka{padding-top:0;}", ".
|
|
260
|
-
"i": [".f2hkw1w:focus-visible{outline-style:none;}"]
|
|
265
|
+
"d": [".f1ewtqcl{box-sizing:border-box;}", ".fqerorx{-webkit-box-flex:1;-webkit-flex-grow:1;-ms-flex-positive:1;flex-grow:1;}", ".fy77jfu{min-width:0;}", ".f1ern45e{border-top-style:none;}", ".f1n71otn{border-right-style:none;}", ".f1deefiw{border-left-style:none;}", ".f1h8hb77{border-bottom-style:none;}", ".f1g0x7ka{padding-top:0;}", ".ffczdla{padding-right:var(--spacingHorizontalXXS);}", ".fgiv446{padding-left:var(--spacingHorizontalXXS);}", ".f1qch9an{padding-bottom:0;}", ".f19n0e5{color:var(--colorNeutralForeground1);}", ".f3rmtva{background-color:transparent;}", ".fwyc1cq::-webkit-input-placeholder{color:var(--colorNeutralForeground4);}", ".fwyc1cq::-moz-placeholder{color:var(--colorNeutralForeground4);}", ".f13ta7ih::-webkit-input-placeholder{opacity:1;}", ".f13ta7ih::-moz-placeholder{opacity:1;}", ".f1s6fcnf{outline-style:none;}", ".fk6fouc{font-family:var(--fontFamilyBase);}", ".fy9rknc{font-size:var(--fontSizeBase200);}", ".figsok6{font-weight:var(--fontWeightRegular);}", ".fwrc4pm{line-height:var(--lineHeightBase200);}", ".fkhj508{font-size:var(--fontSizeBase300);}", ".f1i3iumi{line-height:var(--lineHeightBase300);}", ".fod5ikn{font-size:var(--fontSizeBase400);}", ".faaz57k{line-height:var(--lineHeightBase400);}", ".fdw0yi8{padding-right:var(--spacingHorizontalSNudge);}", ".fk8j09s{padding-left:var(--spacingHorizontalSNudge);}", ".f1s2aq7o{color:var(--colorNeutralForegroundDisabled);}", ".f1c21dwh{background-color:var(--colorTransparentBackground);}", ".fdrzuqr{cursor:not-allowed;}", ".fahhnxm::-webkit-input-placeholder{color:var(--colorNeutralForegroundDisabled);}", ".fahhnxm::-moz-placeholder{color:var(--colorNeutralForegroundDisabled);}"]
|
|
261
266
|
});
|
|
262
267
|
|
|
263
|
-
const useContentStyles = /*#__PURE__*/
|
|
268
|
+
const useContentStyles = /*#__PURE__*/react_1.__styles({
|
|
264
269
|
"base": {
|
|
265
270
|
"B7ck84d": "f1ewtqcl",
|
|
266
271
|
"sj55zd": "f11d4kpn",
|
|
@@ -268,16 +273,25 @@ const useContentStyles = /*#__PURE__*/react_make_styles_1.__styles({
|
|
|
268
273
|
},
|
|
269
274
|
"disabled": {
|
|
270
275
|
"sj55zd": "f1s2aq7o"
|
|
276
|
+
},
|
|
277
|
+
"small": {
|
|
278
|
+
"kwki1k": "f3u2cy0"
|
|
279
|
+
},
|
|
280
|
+
"medium": {
|
|
281
|
+
"kwki1k": "f1oqplr0"
|
|
282
|
+
},
|
|
283
|
+
"large": {
|
|
284
|
+
"kwki1k": "fa420co"
|
|
271
285
|
}
|
|
272
286
|
}, {
|
|
273
|
-
"d": [".f1ewtqcl{box-sizing:border-box;}", ".f11d4kpn{color:var(--colorNeutralForeground3);}", ".fyuhxbn>svg{display:block;}", ".f1s2aq7o{color:var(--colorNeutralForegroundDisabled);}"]
|
|
287
|
+
"d": [".f1ewtqcl{box-sizing:border-box;}", ".f11d4kpn{color:var(--colorNeutralForeground3);}", ".fyuhxbn>svg{display:block;}", ".f1s2aq7o{color:var(--colorNeutralForegroundDisabled);}", ".f3u2cy0>svg{font-size:16px;}", ".f1oqplr0>svg{font-size:20px;}", ".fa420co>svg{font-size:24px;}"]
|
|
274
288
|
});
|
|
275
289
|
/**
|
|
276
290
|
* Apply styling to the Input slots based on the state
|
|
277
291
|
*/
|
|
278
292
|
|
|
279
293
|
|
|
280
|
-
const
|
|
294
|
+
const useInputStyles_unstable = state => {
|
|
281
295
|
const {
|
|
282
296
|
size,
|
|
283
297
|
appearance
|
|
@@ -287,20 +301,20 @@ const useInputStyles = state => {
|
|
|
287
301
|
const rootStyles = useRootStyles();
|
|
288
302
|
const inputStyles = useInputElementStyles();
|
|
289
303
|
const contentStyles = useContentStyles();
|
|
290
|
-
state.root.className =
|
|
291
|
-
state.input.className =
|
|
292
|
-
const contentClasses = [contentStyles.base, disabled && contentStyles.disabled];
|
|
304
|
+
state.root.className = react_1.mergeClasses(exports.inputClassNames.root, rootStyles.base, rootStyles[size], rootStyles[appearance], !disabled && rootStyles.interactive, !disabled && appearance === 'outline' && rootStyles.outlineInteractive, !disabled && appearance === 'underline' && rootStyles.underlineInteractive, !disabled && filled && rootStyles.filledInteractive, filled && rootStyles.filled, disabled && rootStyles.disabled, state.root.className);
|
|
305
|
+
state.input.className = react_1.mergeClasses(exports.inputClassNames.input, inputStyles.base, inputStyles[size], disabled && inputStyles.disabled, state.input.className);
|
|
306
|
+
const contentClasses = [contentStyles.base, disabled && contentStyles.disabled, contentStyles[size]];
|
|
293
307
|
|
|
294
308
|
if (state.contentBefore) {
|
|
295
|
-
state.contentBefore.className =
|
|
309
|
+
state.contentBefore.className = react_1.mergeClasses(exports.inputClassNames.contentBefore, ...contentClasses, state.contentBefore.className);
|
|
296
310
|
}
|
|
297
311
|
|
|
298
312
|
if (state.contentAfter) {
|
|
299
|
-
state.contentAfter.className =
|
|
313
|
+
state.contentAfter.className = react_1.mergeClasses(exports.inputClassNames.contentAfter, ...contentClasses, state.contentAfter.className);
|
|
300
314
|
}
|
|
301
315
|
|
|
302
316
|
return state;
|
|
303
317
|
};
|
|
304
318
|
|
|
305
|
-
exports.
|
|
319
|
+
exports.useInputStyles_unstable = useInputStyles_unstable;
|
|
306
320
|
//# sourceMappingURL=useInputStyles.js.map
|