@digital-ai/dot-components 2.13.0 → 2.14.1
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/CHANGE_LOG.md +42 -7
- package/index.d.ts +1 -0
- package/index.esm.js +34 -20
- package/index.umd.js +39 -21
- package/lib/components/auto-complete/AutoComplete.d.ts +2 -1
- package/lib/components/auto-complete/AutoComplete.stories.d.ts +1 -1
- package/lib/components/date-picker/DatePicker.d.ts +1 -1
- package/lib/components/input-form-fields/InputFormFields.propTypes.d.ts +3 -1
- package/lib/components/input-form-fields/InputFormFields.styles.d.ts +1 -0
- package/lib/components/input-form-fields/InputText.d.ts +2 -2
- package/lib/components/input-form-fields/InputText.stories.d.ts +3 -1
- package/lib/components/input-form-fields/common.styles.d.ts +4 -3
- package/lib/components/time-picker/TimePicker.d.ts +1 -1
- package/lib/theme-provider/ThemeProvider.d.ts +13 -10
- package/lib/theme-provider/interfaces.d.ts +56 -0
- package/package.json +1 -1
package/CHANGE_LOG.md
CHANGED
|
@@ -1,5 +1,32 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
+
## [2.14.1](https://www.npmjs.com/package/@digital-ai/dot-components) (09/01/2023)
|
|
4
|
+
|
|
5
|
+
[Full Changelog](https://digital-ai.github.io/dot-components/?path=/story/introduction--page/digital-ai/dot-components/compare/2.14.0...2.14.1)
|
|
6
|
+
|
|
7
|
+
**Fixed bugs:**
|
|
8
|
+
|
|
9
|
+
- D-26312 Fix wrong style selector for read-only autocomplete [\#1603](https://github.com/digital-ai/dot-components/pull/1603) ([angel-git](https://github.com/angel-git))
|
|
10
|
+
|
|
11
|
+
## [2.14.0](https://www.npmjs.com/package/@digital-ai/dot-components) (08/25/2023)
|
|
12
|
+
|
|
13
|
+
[Full Changelog](https://digital-ai.github.io/dot-components/?path=/story/introduction--page/digital-ai/dot-components/compare/2.13.0...2.14.0)
|
|
14
|
+
|
|
15
|
+
**Features:**
|
|
16
|
+
|
|
17
|
+
- S-85164: `DotInputText` - support native `min` and `max` properties [\#1593](https://github.com/digital-ai/dot-components/pull/1593) ([dmiletic85](https://github.com/dmiletic85))
|
|
18
|
+
- S-95238 `DotAutocomplete` - Expose native `isOptionEqualToValue` [\#1592](https://github.com/digital-ai/dot-components/pull/1592) ([dmiletic85](https://github.com/dmiletic85))
|
|
19
|
+
|
|
20
|
+
**Fixed bugs:**
|
|
21
|
+
|
|
22
|
+
- D-26285: Fix DotDraggable items: wrong position [\#1599](https://github.com/digital-ai/dot-components/pull/1599) ([angel-git](https://github.com/angel-git))
|
|
23
|
+
- D-26238 `DotTable`, `DotTableActions`: duplicated actions and incorrect `onRowClick` triggering [\#1591](https://github.com/digital-ai/dot-components/pull/1591) ([dmiletic85](https://github.com/dmiletic85))
|
|
24
|
+
- D-23137: update read-only styles for various input fields [\#1580](https://github.com/digital-ai/dot-components/pull/1580) ([CWSites](https://github.com/CWSites))
|
|
25
|
+
|
|
26
|
+
**Misc:**
|
|
27
|
+
|
|
28
|
+
- S-94771: modifying placement of modules and interfaces [\#1588](https://github.com/digital-ai/dot-components/pull/1588) ([CWSites](https://github.com/CWSites))
|
|
29
|
+
|
|
3
30
|
## [2.13.0](https://www.npmjs.com/package/@digital-ai/dot-components) (08/13/2023)
|
|
4
31
|
|
|
5
32
|
[Full Changelog](https://digital-ai.github.io/dot-components/?path=/story/introduction--page/digital-ai/dot-components/compare/2.12.1...2.13.0)
|
|
@@ -558,6 +585,10 @@
|
|
|
558
585
|
|
|
559
586
|
[Full Changelog](https://digital-ai.github.io/dot-components/?path=/story/introduction--page/digital-ai/dot-components/compare/2.0.0-rc.3...1.21.5)
|
|
560
587
|
|
|
588
|
+
**Fixed bugs:**
|
|
589
|
+
|
|
590
|
+
- D-22889: `DotInputText` Fix multiline issues [\#1276](https://github.com/digital-ai/dot-components/pull/1276) ([dmiletic85](https://github.com/dmiletic85))
|
|
591
|
+
|
|
561
592
|
**Misc:**
|
|
562
593
|
|
|
563
594
|
- Changed Agility icons in dot font [\#1282](https://github.com/digital-ai/dot-components/pull/1282) ([pauldigitalai](https://github.com/pauldigitalai))
|
|
@@ -585,10 +616,6 @@
|
|
|
585
616
|
|
|
586
617
|
- S-87871 Expose callback when sidebar collapses/expands [\#1274](https://github.com/digital-ai/dot-components/pull/1274) ([angel-git](https://github.com/angel-git))
|
|
587
618
|
|
|
588
|
-
**Fixed bugs:**
|
|
589
|
-
|
|
590
|
-
- D-22889: `DotInputText` Fix multiline issues [\#1276](https://github.com/digital-ai/dot-components/pull/1276) ([dmiletic85](https://github.com/dmiletic85))
|
|
591
|
-
|
|
592
619
|
## [1.21.3](https://www.npmjs.com/package/@digital-ai/dot-components) (09/28/2022)
|
|
593
620
|
|
|
594
621
|
[Full Changelog](https://digital-ai.github.io/dot-components/?path=/story/introduction--page/digital-ai/dot-components/compare/2.0.0-rc.2...1.21.3)
|
|
@@ -633,7 +660,6 @@
|
|
|
633
660
|
|
|
634
661
|
- Release Candidate Workflow [\#1251](https://github.com/digital-ai/dot-components/pull/1251) ([CWSites](https://github.com/CWSites))
|
|
635
662
|
- S-85001: add support for react 18 [\#1244](https://github.com/digital-ai/dot-components/pull/1244) ([CWSites](https://github.com/CWSites))
|
|
636
|
-
- S-86694: Extract agility theme [\#1242](https://github.com/digital-ai/dot-components/pull/1242) ([CWSites](https://github.com/CWSites))
|
|
637
663
|
|
|
638
664
|
## [1.21.1](https://www.npmjs.com/package/@digital-ai/dot-components) (08/31/2022)
|
|
639
665
|
|
|
@@ -644,6 +670,10 @@
|
|
|
644
670
|
- D-22238 Add focus state for Avatar With Tooltip [\#1248](https://github.com/digital-ai/dot-components/pull/1248) ([nikolinadapic](https://github.com/nikolinadapic))
|
|
645
671
|
- S-87031: Extended DotPill props to support account list changes [\#1247](https://github.com/digital-ai/dot-components/pull/1247) ([ryangamble](https://github.com/ryangamble))
|
|
646
672
|
|
|
673
|
+
**Misc:**
|
|
674
|
+
|
|
675
|
+
- S-86694: Extract agility theme [\#1242](https://github.com/digital-ai/dot-components/pull/1242) ([CWSites](https://github.com/CWSites))
|
|
676
|
+
|
|
647
677
|
## [1.21.0](https://www.npmjs.com/package/@digital-ai/dot-components) (08/22/2022)
|
|
648
678
|
|
|
649
679
|
[Full Changelog](https://digital-ai.github.io/dot-components/?path=/story/introduction--page/digital-ai/dot-components/compare/1.20.0...1.21.0)
|
|
@@ -838,6 +868,10 @@
|
|
|
838
868
|
|
|
839
869
|
[Full Changelog](https://digital-ai.github.io/dot-components/?path=/story/introduction--page/digital-ai/dot-components/compare/1.11.3...1.12.0)
|
|
840
870
|
|
|
871
|
+
**Breaking changes:**
|
|
872
|
+
|
|
873
|
+
- S-82342: Upgrade MUI to v5 [\#1079](https://github.com/digital-ai/dot-components/pull/1079) ([CWSites](https://github.com/CWSites))
|
|
874
|
+
|
|
841
875
|
**Features:**
|
|
842
876
|
|
|
843
877
|
- S-82910: `DotTypography`: Add more Storybook examples [\#1092](https://github.com/digital-ai/dot-components/pull/1092) ([dmiletic85](https://github.com/dmiletic85))
|
|
@@ -1036,6 +1070,7 @@
|
|
|
1036
1070
|
**Misc:**
|
|
1037
1071
|
|
|
1038
1072
|
- S-76846: storybook updates `develop` [\#935](https://github.com/digital-ai/dot-components/pull/935) ([CWSites](https://github.com/CWSites))
|
|
1073
|
+
- S-76846: Storybook updates [\#931](https://github.com/digital-ai/dot-components/pull/931) ([CWSites](https://github.com/CWSites))
|
|
1039
1074
|
|
|
1040
1075
|
## [1.6.1](https://www.npmjs.com/package/@digital-ai/dot-components) (01/10/2022)
|
|
1041
1076
|
|
|
@@ -1185,6 +1220,7 @@
|
|
|
1185
1220
|
|
|
1186
1221
|
**Features:**
|
|
1187
1222
|
|
|
1223
|
+
- S-80473: Expose onFocus and onBlur callbacks for DotInputText and DotInputSelect components [\#832](https://github.com/digital-ai/dot-components/pull/832) ([selsemore](https://github.com/selsemore))
|
|
1188
1224
|
- S-80268: `DotDynamicForm` improvements [\#821](https://github.com/digital-ai/dot-components/pull/821) ([dmiletic85](https://github.com/dmiletic85))
|
|
1189
1225
|
|
|
1190
1226
|
**Fixed bugs:**
|
|
@@ -1198,7 +1234,6 @@
|
|
|
1198
1234
|
|
|
1199
1235
|
**Features:**
|
|
1200
1236
|
|
|
1201
|
-
- S-80473: Expose onFocus and onBlur callbacks for DotInputText and DotInputSelect components [\#832](https://github.com/digital-ai/dot-components/pull/832) ([selsemore](https://github.com/selsemore))
|
|
1202
1237
|
- S-80369: Create `ProgressButton` component [\#822](https://github.com/digital-ai/dot-components/pull/822) ([dmiletic85](https://github.com/dmiletic85))
|
|
1203
1238
|
- S-79696: change size of collapse icon button, add tooltip [\#819](https://github.com/digital-ai/dot-components/pull/819) ([CWSites](https://github.com/CWSites))
|
|
1204
1239
|
- S-80264: Agility wrapper sandbox documentation [\#810](https://github.com/digital-ai/dot-components/pull/810) ([CWSites](https://github.com/CWSites))
|
|
@@ -1235,6 +1270,7 @@
|
|
|
1235
1270
|
- S-80109: Expose built-in `leaveDelay`, `onClose`, `open` props on `DotTooltip` component [\#786](https://github.com/digital-ai/dot-components/pull/786) ([dmiletic85](https://github.com/dmiletic85))
|
|
1236
1271
|
- S-76907: update ButtonToggle styles, update unit tests and add e2e tests [\#785](https://github.com/digital-ai/dot-components/pull/785) ([CWSites](https://github.com/CWSites))
|
|
1237
1272
|
- S-80048: product wrapper demo [\#782](https://github.com/digital-ai/dot-components/pull/782) ([CWSites](https://github.com/CWSites))
|
|
1273
|
+
- S-79985: temporarily remove react-jsonschema-form from library [\#776](https://github.com/digital-ai/dot-components/pull/776) ([TheKeithStewart](https://github.com/TheKeithStewart))
|
|
1238
1274
|
|
|
1239
1275
|
## [1.3.2](https://www.npmjs.com/package/@digital-ai/dot-components) (11/05/2021)
|
|
1240
1276
|
|
|
@@ -1248,7 +1284,6 @@
|
|
|
1248
1284
|
**Misc:**
|
|
1249
1285
|
|
|
1250
1286
|
- Patch release [\#780](https://github.com/digital-ai/dot-components/pull/780) ([TheKeithStewart](https://github.com/TheKeithStewart))
|
|
1251
|
-
- S-79985: temporarily remove react-jsonschema-form from library [\#776](https://github.com/digital-ai/dot-components/pull/776) ([TheKeithStewart](https://github.com/TheKeithStewart))
|
|
1252
1287
|
- Add submitButtonProps prop to DotJsonSchemaForm component [\#775](https://github.com/digital-ai/dot-components/pull/775) ([selsemore](https://github.com/selsemore))
|
|
1253
1288
|
- S-76893: Webpack 4 - update peer dependencies [\#768](https://github.com/digital-ai/dot-components/pull/768) ([CWSites](https://github.com/CWSites))
|
|
1254
1289
|
- S-79957: improve husky [\#765](https://github.com/digital-ai/dot-components/pull/765) ([CWSites](https://github.com/CWSites))
|
package/index.d.ts
CHANGED
|
@@ -3,3 +3,4 @@ export * as lightColors from './lib/theme-provider/colors/light-theme-colors';
|
|
|
3
3
|
export * as themeVariables from './lib/theme-provider/common/variables';
|
|
4
4
|
export type { ThemeProviderProps } from './lib/theme-provider/ThemeProvider';
|
|
5
5
|
export { avatarColors, DotThemeProvider, typographyOptions, } from './lib/theme-provider/ThemeProvider';
|
|
6
|
+
export * from './lib/theme-provider/interfaces';
|
package/index.esm.js
CHANGED
|
@@ -212,6 +212,7 @@ const DotAccordion = ({
|
|
|
212
212
|
const formHelperTextRootStyles = theme => css(["font-family:", ";font-size:", "px;font-weight:400;margin:", ";display:flex;align-items:flex-end;&:not(.Mui-error){color:", ";}&.read-only .MuiOutlinedInput-root:hover > fieldset{border-color:", ";}"], theme.typography.fontFamily, theme.typography.body2.fontSize, theme.spacing(0.5, 0, 0, 1.5), theme.palette.grey[400], theme.palette.layer.n200);
|
|
213
213
|
const adornmentIconStyles = () => css(["font-size:24px;height:24px;padding:0;width:24px;"]);
|
|
214
214
|
const pickerInputStyles = theme => css(["label:not(.MuiInputLabel-shrink){top:-5px;}.MuiInputBase-root{margin-bottom:0;.dot-error-icon{margin-right:", ";color:", ";}.dot-icon{", ";}}.MuiInputBase-input{height:", ";padding:", ";}.MuiFormHelperText-root{", ";}"], theme.spacing(0.5), theme.palette.error.main, adornmentIconStyles(), theme.spacing(2), theme.spacing(1.5, 0, 1.5, 2), formHelperTextRootStyles(theme));
|
|
215
|
+
const readOnlyStyles = theme => css(["background:", ";color:", ";border-color:", ";-webkit-text-fill-color:", ";input.Mui-disabled{-webkit-text-fill-color:", ";}.dot-chip{background:", ";opacity:1;}"], theme.palette.grey[50], theme.palette.grey[500], theme.palette.grey[300], theme.palette.grey[500], theme.palette.grey[500], theme.palette.layer.n0);
|
|
215
216
|
|
|
216
217
|
const rootClassName$13 = 'dot-text-field';
|
|
217
218
|
const rootSelectClassName = 'dot-select-field';
|
|
@@ -221,6 +222,7 @@ const warningClassName = 'dot-warning';
|
|
|
221
222
|
const successClassName = 'dot-success';
|
|
222
223
|
const adornmentIconClassName = 'dot-adornment-icon';
|
|
223
224
|
const fieldsetClassName = 'MuiOutlinedInput-notchedOutline';
|
|
225
|
+
const readOnlyClassName$1 = 'read-only';
|
|
224
226
|
const StyledAdornment = styled(InputAdornment).withConfig({
|
|
225
227
|
displayName: "InputFormFieldsstyles__StyledAdornment",
|
|
226
228
|
componentId: "sc-1mbn9f0-0"
|
|
@@ -230,7 +232,7 @@ const StyledInputLabel = styled(InputLabel).withConfig({
|
|
|
230
232
|
componentId: "sc-1mbn9f0-1"
|
|
231
233
|
})(["", ""], ({
|
|
232
234
|
theme
|
|
233
|
-
}) => css(["&.", "{margin-bottom:", ";transform:none;&.Mui-disabled .dot-typography{color:
|
|
235
|
+
}) => css(["&.", "{margin-bottom:", ";transform:none;&.Mui-disabled .dot-typography{color:", ";}&.Mui-error .dot-typography{color:", ";}.dot-typography{display:inline;}}"], labelClassName, theme.spacing(0.5), theme.palette.layer.n700, theme.palette.error.main));
|
|
234
236
|
const StyledTextFieldContainer = styled.div.withConfig({
|
|
235
237
|
displayName: "InputFormFieldsstyles__StyledTextFieldContainer",
|
|
236
238
|
componentId: "sc-1mbn9f0-2"
|
|
@@ -241,7 +243,7 @@ const StyledTextField = styled(TextField).withConfig({
|
|
|
241
243
|
})(["", ""], ({
|
|
242
244
|
theme,
|
|
243
245
|
InputProps
|
|
244
|
-
}) => css(["&.", "{.MuiInputBase-root{margin-bottom:0;}.MuiInputBase-input{box-sizing:content-box;}.MuiOutlinedInput-input{padding:", ";}.MuiInputBase-inputSizeSmall{padding-top:10.5px;padding-bottom:10.5px;&:not(textarea){height:19px;}}.MuiInputBase-inputMultiline{padding:0;}}&.", " .", "{margin-right:", ";}&.", ",&.", "{.", "{color:", ";p{font-size:", "px;margin:0;}.dot-icon i{margin-top:-2px;}}.MuiInputBase-root{margin-bottom:0;}.MuiInputBase-inputSizeSmall:not(textarea){height:19px;padding-top:10.5px;padding-bottom:10.5px;}select.dot-select{padding-left:", ";}.MuiSelect-select:focus{background-color:transparent;}.MuiSelect-icon{right:", ";}&.", "{.MuiOutlinedInput-notchedOutline{border-color:", ";}.MuiFormLabel-root.Mui-focused{color:", ";}.", " .dot-icon{color:", ";}}&.", "{.MuiInputLabel-outlined.MuiInputLabel-shrink{color:", ";}.", " .dot-icon{color:", ";}}&.", "{.MuiOutlinedInput-notchedOutline{border-color:", ";}.MuiInputLabel-outlined.MuiInputLabel-shrink{color:", ";}.", " .dot-icon{color:", ";}}.MuiOutlinedInput-adornedStart{padding-left:12px;&.", " .", "{border-color:", ";}}.MuiInputLabel-outlined.MuiInputLabel-shrink{color:", ";}.MuiInputBase-inputAdornedStart{padding-left:12px;}.MuiInputBase-inputAdornedEnd{padding-right:12px;}.MuiFormHelperText-root{", ";}}"], rootClassName$13, InputProps.startAdornment ? `18px 12px 18px 0px` : `18px 12px`, rootSelectClassName, adornmentIconClassName, theme.spacing(2), rootSelectClassName, rootClassName$13, adornmentIconClassName, theme.palette.layer.n700, theme.typography.body2.fontSize, theme.spacing(1.5), InputProps.endAdornment ? `44px` : `12px`, successClassName, theme.palette.secondary.main, theme.palette.grey[700], adornmentIconClassName, theme.palette.secondary.main, errorClassName, theme.palette.error.main, adornmentIconClassName, theme.palette.error.main, warningClassName, theme.palette.warning.main, theme.palette.grey[700], adornmentIconClassName, theme.palette.warning.main, warningClassName, fieldsetClassName, theme.palette.warning[500], theme.palette.grey[700], formHelperTextRootStyles(theme)));
|
|
246
|
+
}) => css(["&.", "{.MuiInputBase-root{margin-bottom:0;}.MuiInputBase-input{box-sizing:content-box;}.MuiOutlinedInput-input{padding:", ";}.MuiInputBase-inputSizeSmall{padding-top:10.5px;padding-bottom:10.5px;&:not(textarea){height:19px;}}.MuiInputBase-inputMultiline{padding:0;}.MuiInputLabel-root.Mui-disabled{color:", ";}&.", " .MuiInputBase-root,.MuiInputBase-root.Mui-disabled{", ";}}.dot-select,.dot-input{&.", ",&.Mui-disabled{", ";}}&.", " .", "{margin-right:", ";}&.", ",&.", "{.", "{color:", ";p{font-size:", "px;margin:0;}.dot-icon i{margin-top:-2px;}}.MuiInputBase-root{margin-bottom:0;}.MuiInputBase-inputSizeSmall:not(textarea){height:19px;padding-top:10.5px;padding-bottom:10.5px;}select.dot-select{padding-left:", ";}.MuiSelect-select:focus:not(.", "){background-color:transparent;}.MuiSelect-icon{right:", ";}&.", "{.MuiOutlinedInput-notchedOutline{border-color:", ";}.MuiFormLabel-root.Mui-focused{color:", ";}.", " .dot-icon{color:", ";}}&.", "{.MuiInputLabel-outlined.MuiInputLabel-shrink{color:", ";}.", " .dot-icon{color:", ";}}&.", "{.MuiOutlinedInput-notchedOutline{border-color:", ";}.MuiInputLabel-outlined.MuiInputLabel-shrink{color:", ";}.", " .dot-icon{color:", ";}}.MuiOutlinedInput-adornedStart{padding-left:12px;&.", " .", "{border-color:", ";}}.MuiInputLabel-outlined.MuiInputLabel-shrink{color:", ";}.MuiInputBase-inputAdornedStart{padding-left:12px;}.MuiInputBase-inputAdornedEnd{padding-right:12px;}.MuiFormHelperText-root{", ";}}"], rootClassName$13, InputProps.startAdornment ? `18px 12px 18px 0px` : `18px 12px`, theme.palette.layer.n500, readOnlyClassName$1, readOnlyStyles(theme), readOnlyClassName$1, readOnlyStyles(theme), rootSelectClassName, adornmentIconClassName, theme.spacing(2), rootSelectClassName, rootClassName$13, adornmentIconClassName, theme.palette.layer.n700, theme.typography.body2.fontSize, theme.spacing(1.5), readOnlyClassName$1, InputProps.endAdornment ? `44px` : `12px`, successClassName, theme.palette.secondary.main, theme.palette.grey[700], adornmentIconClassName, theme.palette.secondary.main, errorClassName, theme.palette.error.main, adornmentIconClassName, theme.palette.error.main, warningClassName, theme.palette.warning.main, theme.palette.grey[700], adornmentIconClassName, theme.palette.warning.main, warningClassName, fieldsetClassName, theme.palette.warning[500], theme.palette.grey[700], formHelperTextRootStyles(theme)));
|
|
245
247
|
|
|
246
248
|
const rootClassName$12 = 'dot-action-toolbar';
|
|
247
249
|
const StyledToolbar = styled(Toolbar).withConfig({
|
|
@@ -2936,7 +2938,9 @@ const DotInputText = ({
|
|
|
2936
2938
|
id,
|
|
2937
2939
|
inputRef,
|
|
2938
2940
|
label,
|
|
2941
|
+
max,
|
|
2939
2942
|
maxRows,
|
|
2943
|
+
min,
|
|
2940
2944
|
minRows,
|
|
2941
2945
|
multiline: _multiline = false,
|
|
2942
2946
|
name,
|
|
@@ -2963,7 +2967,7 @@ const DotInputText = ({
|
|
|
2963
2967
|
const hasEndAdornmentIcon = endIcon || _error || hasWarning || hasSuccess;
|
|
2964
2968
|
// This state is used only with debounce feature enabled
|
|
2965
2969
|
const [inputTextState, setInputTextState] = useState(hasDebounce && getInitialState(value));
|
|
2966
|
-
const rootStyles = useStylesWithRootClass(rootClassName$13, hasError, hasWarning, hasSuccess, _readOnly
|
|
2970
|
+
const rootStyles = useStylesWithRootClass(rootClassName$13, hasError, hasWarning, hasSuccess, _readOnly && readOnlyClassName$1);
|
|
2967
2971
|
// Used to control text value from the consumer component
|
|
2968
2972
|
// when debounce feature is enabled
|
|
2969
2973
|
useEffect(() => {
|
|
@@ -3016,6 +3020,7 @@ const DotInputText = ({
|
|
|
3016
3020
|
}), void 0);
|
|
3017
3021
|
};
|
|
3018
3022
|
const wrapperClassName = useStylesWithRootClass(_fullWidth !== false ? 'dot-input-text--fullwidth' : '', className);
|
|
3023
|
+
const inputClassName = useStylesWithRootClass('dot-input', _readOnly && readOnlyClassName$1);
|
|
3019
3024
|
return jsxs(StyledTextFieldContainer, Object.assign({
|
|
3020
3025
|
className: wrapperClassName
|
|
3021
3026
|
}, {
|
|
@@ -3039,7 +3044,6 @@ const DotInputText = ({
|
|
|
3039
3044
|
defaultValue: defaultInputValue,
|
|
3040
3045
|
disabled: _disabled,
|
|
3041
3046
|
error: _error,
|
|
3042
|
-
focused: _readOnly ? false : undefined,
|
|
3043
3047
|
fullWidth: _fullWidth,
|
|
3044
3048
|
helperText: helperText,
|
|
3045
3049
|
id: id,
|
|
@@ -3048,8 +3052,10 @@ const DotInputText = ({
|
|
|
3048
3052
|
},
|
|
3049
3053
|
inputProps: {
|
|
3050
3054
|
'data-testid': dataTestId,
|
|
3051
|
-
className:
|
|
3052
|
-
readOnly: _readOnly
|
|
3055
|
+
className: inputClassName,
|
|
3056
|
+
readOnly: _readOnly,
|
|
3057
|
+
max,
|
|
3058
|
+
min
|
|
3053
3059
|
},
|
|
3054
3060
|
inputRef: inputRef,
|
|
3055
3061
|
label: persistentLabel ? null : label,
|
|
@@ -4298,7 +4304,7 @@ const StyledAutocomplete = styled(Autocomplete).withConfig({
|
|
|
4298
4304
|
componentId: "j2sgjy-0"
|
|
4299
4305
|
})(["", ""], ({
|
|
4300
4306
|
theme
|
|
4301
|
-
}) => css(["&.", "{&.", " .dot-text-field .", "{height:56px;padding-left:", ";}.", "{padding-top:", ";padding-bottom:", ";}.dot-chip:first-child{margin-left:", ";}.dot-text-field{.", "{min-height:", ";}.warning-icon{color:", ";}.error-icon{color:", ";}}}"], rootClassName$I, inputMediumClassName, inputRootClassName, theme.spacing(2), inputRootClassName, theme.spacing(0), theme.spacing(0), theme.spacing(0), inputRootClassName, theme.spacing(5), theme.palette.warning.main, theme.palette.error.main));
|
|
4307
|
+
}) => css(["&.", "{&.", " .dot-text-field .", "{height:56px;padding-left:", ";}.MuiInputBase-root.Mui-disabled,.", " .MuiInputBase-root{", ";}.", "{padding-top:", ";padding-bottom:", ";}.dot-chip:first-child{margin-left:", ";}.dot-text-field{.", "{min-height:", ";}.warning-icon{color:", ";}.error-icon{color:", ";}}}"], rootClassName$I, inputMediumClassName, inputRootClassName, theme.spacing(2), readOnlyClassName$1, readOnlyStyles(theme), inputRootClassName, theme.spacing(0), theme.spacing(0), theme.spacing(0), inputRootClassName, theme.spacing(5), theme.palette.warning.main, theme.palette.error.main));
|
|
4302
4308
|
|
|
4303
4309
|
const rootClassName$H = 'dot-chip';
|
|
4304
4310
|
const StyledChip = styled(Chip).withConfig({
|
|
@@ -4440,6 +4446,7 @@ const DotAutoComplete = ({
|
|
|
4440
4446
|
inputId,
|
|
4441
4447
|
inputRef,
|
|
4442
4448
|
inputValue,
|
|
4449
|
+
isOptionEqualToValue,
|
|
4443
4450
|
label,
|
|
4444
4451
|
loading,
|
|
4445
4452
|
maxHeight,
|
|
@@ -4473,7 +4480,7 @@ const DotAutoComplete = ({
|
|
|
4473
4480
|
const preventDuplicateInsertion = actionItem === null || actionItem === void 0 ? void 0 : actionItem.preventDuplicateInsertion;
|
|
4474
4481
|
const textFieldWarningClassName = !_error && _warning && warningClassName;
|
|
4475
4482
|
const rootClasses = useStylesWithRootClass(rootClassName$I, _size === 'medium' && inputMediumClassName, className);
|
|
4476
|
-
const textFieldRootClasses = useStylesWithRootClass(rootClassName$13, _readOnly &&
|
|
4483
|
+
const textFieldRootClasses = useStylesWithRootClass(rootClassName$13, _readOnly && readOnlyClassName$1, textFieldWarningClassName);
|
|
4477
4484
|
const inputRootClasses = useStylesWithRootClass(inputRootClassName, !_dense && inputMediumClassName);
|
|
4478
4485
|
let highlightedOption = null;
|
|
4479
4486
|
let textFieldInput;
|
|
@@ -4659,6 +4666,7 @@ const DotAutoComplete = ({
|
|
|
4659
4666
|
getOptionDisabled: checkIfOptionDisabled,
|
|
4660
4667
|
groupBy: _group ? option => option.group : undefined,
|
|
4661
4668
|
inputValue: inputValue,
|
|
4669
|
+
isOptionEqualToValue: isOptionEqualToValue,
|
|
4662
4670
|
ListboxComponent: ListboxComponent,
|
|
4663
4671
|
loading: loading,
|
|
4664
4672
|
multiple: _multiple,
|
|
@@ -4711,7 +4719,6 @@ const DotAutoComplete = ({
|
|
|
4711
4719
|
root: textFieldRootClasses
|
|
4712
4720
|
},
|
|
4713
4721
|
error: _error,
|
|
4714
|
-
focused: _readOnly ? false : undefined,
|
|
4715
4722
|
helperText: helperText,
|
|
4716
4723
|
id: inputId,
|
|
4717
4724
|
inputProps: Object.assign(Object.assign({}, inputProps), {
|
|
@@ -6213,7 +6220,8 @@ const DotInputSelect = ({
|
|
|
6213
6220
|
const hasWarning = !_error && _warning && warningClassName;
|
|
6214
6221
|
const hasSuccess = !_error && !_warning && success && successClassName;
|
|
6215
6222
|
const endAdornment = endIcon || endText;
|
|
6216
|
-
const
|
|
6223
|
+
const inputStyles = useStylesWithRootClass('dot-select', _readOnly && readOnlyClassName$1);
|
|
6224
|
+
const rootStyles = useStylesWithRootClass(rootSelectClassName, hasSuccess, hasWarning);
|
|
6217
6225
|
const getOption = option => {
|
|
6218
6226
|
return typeof option === 'string' ? option : option.option;
|
|
6219
6227
|
};
|
|
@@ -6249,12 +6257,12 @@ const DotInputSelect = ({
|
|
|
6249
6257
|
readOnly: _readOnly,
|
|
6250
6258
|
open: _readOnly ? false : undefined
|
|
6251
6259
|
},
|
|
6260
|
+
"aria-label": ariaLabel || label,
|
|
6252
6261
|
autoFocus: autoFocus,
|
|
6253
6262
|
className: rootStyles,
|
|
6254
6263
|
defaultValue: defaultValue,
|
|
6255
6264
|
disabled: _disabled,
|
|
6256
6265
|
error: _error,
|
|
6257
|
-
focused: _readOnly ? false : undefined,
|
|
6258
6266
|
fullWidth: _fullWidth,
|
|
6259
6267
|
helperText: helperText,
|
|
6260
6268
|
id: id,
|
|
@@ -6264,7 +6272,7 @@ const DotInputSelect = ({
|
|
|
6264
6272
|
inputProps: {
|
|
6265
6273
|
'aria-label': ariaLabel,
|
|
6266
6274
|
'data-testid': dataTestId,
|
|
6267
|
-
className:
|
|
6275
|
+
className: inputStyles,
|
|
6268
6276
|
readOnly: _readOnly
|
|
6269
6277
|
},
|
|
6270
6278
|
inputRef: inputRef,
|
|
@@ -6276,6 +6284,7 @@ const DotInputSelect = ({
|
|
|
6276
6284
|
onFocus: onFocus,
|
|
6277
6285
|
onKeyDown: onKeyDown,
|
|
6278
6286
|
required: required,
|
|
6287
|
+
role: "textbox",
|
|
6279
6288
|
select: true,
|
|
6280
6289
|
size: _size,
|
|
6281
6290
|
value: value,
|
|
@@ -7423,7 +7432,7 @@ const DotInlineEdit = ({
|
|
|
7423
7432
|
onKeyDown: !readOnly ? event => handleKeyPress(event) : undefined,
|
|
7424
7433
|
ref: inlineEditRef,
|
|
7425
7434
|
role: _ariaRole,
|
|
7426
|
-
tabIndex:
|
|
7435
|
+
tabIndex: _tabIndex,
|
|
7427
7436
|
typography: _typography
|
|
7428
7437
|
}, {
|
|
7429
7438
|
children: editing ? renderEditMode() : renderViewMode()
|
|
@@ -9028,7 +9037,6 @@ const getMenuItem = action => {
|
|
|
9028
9037
|
"data-testid": action['data-testid'],
|
|
9029
9038
|
disabled: action.disabled,
|
|
9030
9039
|
startIcon: startIcon,
|
|
9031
|
-
onClick: action.onClick,
|
|
9032
9040
|
type: "text"
|
|
9033
9041
|
}, {
|
|
9034
9042
|
children: action.label
|
|
@@ -9101,21 +9109,27 @@ const DotTableActions = ({
|
|
|
9101
9109
|
}
|
|
9102
9110
|
};
|
|
9103
9111
|
const toggleMenu = event => {
|
|
9112
|
+
event.stopPropagation();
|
|
9104
9113
|
setAnchorEl(event.currentTarget);
|
|
9105
9114
|
setMenuOpen(!menuOpen);
|
|
9106
9115
|
};
|
|
9107
|
-
const onSelect = (
|
|
9116
|
+
const onSelect = (event, _menuId, itemKey) => {
|
|
9117
|
+
event.stopPropagation();
|
|
9108
9118
|
selectionMap[itemKey].onClick(null);
|
|
9109
9119
|
};
|
|
9110
9120
|
const onLeave = () => {
|
|
9111
9121
|
setMenuOpen(false);
|
|
9112
9122
|
};
|
|
9123
|
+
const handleTableActionClick = (event, action) => {
|
|
9124
|
+
event.stopPropagation();
|
|
9125
|
+
action.onClick(event);
|
|
9126
|
+
};
|
|
9113
9127
|
const renderTableActions = () => {
|
|
9114
9128
|
return actions && actions.map((action, index) => index < 2 && jsx(DotTableAction, {
|
|
9115
9129
|
iconId: action.iconId,
|
|
9116
9130
|
label: action.label,
|
|
9117
9131
|
tooltip: action.tooltip || action.label,
|
|
9118
|
-
onClick: action
|
|
9132
|
+
onClick: e => handleTableActionClick(e, action)
|
|
9119
9133
|
}, `action-${index}`));
|
|
9120
9134
|
};
|
|
9121
9135
|
return jsxs(Fragment, {
|
|
@@ -9126,6 +9140,7 @@ const DotTableActions = ({
|
|
|
9126
9140
|
children: [!showMenu && renderTableActions(), (showMenu || actions.length > 2) && jsx(DotIconButton, {
|
|
9127
9141
|
ariaLabel: "more options",
|
|
9128
9142
|
className: "dot-table-action-icon",
|
|
9143
|
+
"data-testid": "dot-table-action-icon",
|
|
9129
9144
|
iconId: "options",
|
|
9130
9145
|
iconSize: "small",
|
|
9131
9146
|
onClick: toggleMenu,
|
|
@@ -9580,7 +9595,7 @@ const StyledDraggableList = styled.div.withConfig({
|
|
|
9580
9595
|
})(["", ""], ({
|
|
9581
9596
|
theme,
|
|
9582
9597
|
draggableHandle
|
|
9583
|
-
}) => css(["&.", "{padding:", ";.", "{.dot-icon{color:", ";}&.react-draggable-dragging{background-color:", ";}&.with-default-cursor{cursor:default;}&.with-handle-grab-cursor ", "{cursor:grab;}}}"], rootClassName$3, theme.spacing(1, 0), listItemClassName, theme.palette.layer.n700, theme.palette.grey[50], draggableHandle));
|
|
9598
|
+
}) => css(["&.", "{padding:", ";position:relative;.", "{.dot-icon{color:", ";}&.react-draggable-dragging{background-color:", ";}&.with-default-cursor{cursor:default;}&.with-handle-grab-cursor ", "{cursor:grab;}}}"], rootClassName$3, theme.spacing(1, 0), listItemClassName, theme.palette.layer.n700, theme.palette.grey[50], draggableHandle));
|
|
9584
9599
|
|
|
9585
9600
|
const getOrderedListItems = (layout, listItems) => {
|
|
9586
9601
|
if (!listItems || !layout) return [];
|
|
@@ -9733,7 +9748,7 @@ const StyledDatePicker = styled(DatePicker).withConfig({
|
|
|
9733
9748
|
componentId: "sc-1to4suu-1"
|
|
9734
9749
|
})(["", ""], ({
|
|
9735
9750
|
theme
|
|
9736
|
-
}) => css(["&.", "{", ";}"], rootClassName$1, pickerInputStyles(theme)));
|
|
9751
|
+
}) => css(["&.", "{", ";.Mui-disabled.MuiInputBase-root,&.read-only .MuiInputBase-root{", ";}.MuiFormLabel-root{color:", ";}}"], rootClassName$1, pickerInputStyles(theme), readOnlyStyles(theme), theme.palette.layer.n500));
|
|
9737
9752
|
const StyledPickersDay = styled(PickersDay).withConfig({
|
|
9738
9753
|
displayName: "DatePickerstyles__StyledPickersDay",
|
|
9739
9754
|
componentId: "sc-1to4suu-2"
|
|
@@ -10016,7 +10031,7 @@ const StyledTimePicker = styled(TimePicker).withConfig({
|
|
|
10016
10031
|
componentId: "sc-17aptuh-1"
|
|
10017
10032
|
})(["", ""], ({
|
|
10018
10033
|
theme
|
|
10019
|
-
}) => css(["&.", "{", ";}"], rootClassName, pickerInputStyles(theme)));
|
|
10034
|
+
}) => css(["&.", "{", ";.Mui-disabled.MuiInputBase-root,&.read-only .MuiInputBase-root{", ";}.MuiFormLabel-root{color:", ";}}"], rootClassName, pickerInputStyles(theme), readOnlyStyles(theme), theme.palette.layer.n500));
|
|
10020
10035
|
|
|
10021
10036
|
dayjs.extend(utc);
|
|
10022
10037
|
const DEFAULT_PICKER_TIME_FORMAT = 'HH:mm';
|
|
@@ -10313,7 +10328,6 @@ const DotTimePicker = ({
|
|
|
10313
10328
|
required: _required,
|
|
10314
10329
|
helperText,
|
|
10315
10330
|
error,
|
|
10316
|
-
focused: isComponentReadOnly ? false : undefined,
|
|
10317
10331
|
InputProps: {
|
|
10318
10332
|
endAdornment: jsxs(Fragment, {
|
|
10319
10333
|
children: [error && jsx(DotIcon, {
|
package/index.umd.js
CHANGED
|
@@ -360,7 +360,10 @@
|
|
|
360
360
|
var pickerInputStyles = function pickerInputStyles(theme) {
|
|
361
361
|
return styled.css(templateObject_3$d || (templateObject_3$d = __makeTemplateObject(["\n label:not(.MuiInputLabel-shrink) {\n top: -5px;\n }\n\n .MuiInputBase-root {\n margin-bottom: 0;\n\n .dot-error-icon {\n margin-right: ", ";\n color: ", ";\n }\n\n .dot-icon {\n ", ";\n }\n }\n\n .MuiInputBase-input {\n height: ", ";\n padding: ", ";\n }\n\n .MuiFormHelperText-root {\n ", ";\n }\n"], ["\n label:not(.MuiInputLabel-shrink) {\n top: -5px;\n }\n\n .MuiInputBase-root {\n margin-bottom: 0;\n\n .dot-error-icon {\n margin-right: ", ";\n color: ", ";\n }\n\n .dot-icon {\n ", ";\n }\n }\n\n .MuiInputBase-input {\n height: ", ";\n padding: ", ";\n }\n\n .MuiFormHelperText-root {\n ", ";\n }\n"])), theme.spacing(0.5), theme.palette.error.main, adornmentIconStyles(), theme.spacing(2), theme.spacing(1.5, 0, 1.5, 2), formHelperTextRootStyles(theme));
|
|
362
362
|
};
|
|
363
|
-
var
|
|
363
|
+
var readOnlyStyles = function readOnlyStyles(theme) {
|
|
364
|
+
return styled.css(templateObject_4$b || (templateObject_4$b = __makeTemplateObject(["\n background: ", ";\n color: ", ";\n border-color: ", ";\n -webkit-text-fill-color: ", ";\n\n input.Mui-disabled {\n -webkit-text-fill-color: ", ";\n }\n\n .dot-chip {\n background: ", ";\n opacity: 1;\n }\n"], ["\n background: ", ";\n color: ", ";\n border-color: ", ";\n -webkit-text-fill-color: ", ";\n\n input.Mui-disabled {\n -webkit-text-fill-color: ", ";\n }\n\n .dot-chip {\n background: ", ";\n opacity: 1;\n }\n"])), theme.palette.grey[50], theme.palette.grey[500], theme.palette.grey[300], theme.palette.grey[500], theme.palette.grey[500], theme.palette.layer.n0);
|
|
365
|
+
};
|
|
366
|
+
var templateObject_1$1a, templateObject_2$15, templateObject_3$d, templateObject_4$b;
|
|
364
367
|
|
|
365
368
|
var rootClassName$13 = 'dot-text-field';
|
|
366
369
|
var rootSelectClassName = 'dot-select-field';
|
|
@@ -370,6 +373,7 @@
|
|
|
370
373
|
var successClassName = 'dot-success';
|
|
371
374
|
var adornmentIconClassName = 'dot-adornment-icon';
|
|
372
375
|
var fieldsetClassName = 'MuiOutlinedInput-notchedOutline';
|
|
376
|
+
var readOnlyClassName$1 = 'read-only';
|
|
373
377
|
var StyledAdornment = styled__default["default"](material.InputAdornment).withConfig({
|
|
374
378
|
displayName: "InputFormFieldsstyles__StyledAdornment",
|
|
375
379
|
componentId: "sc-1mbn9f0-0"
|
|
@@ -379,7 +383,7 @@
|
|
|
379
383
|
componentId: "sc-1mbn9f0-1"
|
|
380
384
|
})(templateObject_3$c || (templateObject_3$c = __makeTemplateObject(["\n ", "\n"], ["\n ", "\n"])), function (_a) {
|
|
381
385
|
var theme = _a.theme;
|
|
382
|
-
return styled.css(templateObject_2$14 || (templateObject_2$14 = __makeTemplateObject(["\n &.", " {\n margin-bottom: ", ";\n transform: none;\n\n &.Mui-disabled .dot-typography {\n color:
|
|
386
|
+
return styled.css(templateObject_2$14 || (templateObject_2$14 = __makeTemplateObject(["\n &.", " {\n margin-bottom: ", ";\n transform: none;\n\n &.Mui-disabled .dot-typography {\n color: ", ";\n }\n\n &.Mui-error .dot-typography {\n color: ", ";\n }\n\n .dot-typography {\n display: inline;\n }\n }\n "], ["\n &.", " {\n margin-bottom: ", ";\n transform: none;\n\n &.Mui-disabled .dot-typography {\n color: ", ";\n }\n\n &.Mui-error .dot-typography {\n color: ", ";\n }\n\n .dot-typography {\n display: inline;\n }\n }\n "])), labelClassName, theme.spacing(0.5), theme.palette.layer.n700, theme.palette.error.main);
|
|
383
387
|
});
|
|
384
388
|
var StyledTextFieldContainer = styled__default["default"].div.withConfig({
|
|
385
389
|
displayName: "InputFormFieldsstyles__StyledTextFieldContainer",
|
|
@@ -391,7 +395,7 @@
|
|
|
391
395
|
})(templateObject_6$1 || (templateObject_6$1 = __makeTemplateObject(["\n ", "\n"], ["\n ", "\n"])), function (_a) {
|
|
392
396
|
var theme = _a.theme,
|
|
393
397
|
InputProps = _a.InputProps;
|
|
394
|
-
return styled.css(templateObject_5$3 || (templateObject_5$3 = __makeTemplateObject(["\n &.", " {\n .MuiInputBase-root {\n margin-bottom: 0;\n }\n .MuiInputBase-input {\n box-sizing: content-box;\n }\n .MuiOutlinedInput-input {\n padding: ", ";\n }\n .MuiInputBase-inputSizeSmall {\n padding-top: 10.5px;\n padding-bottom: 10.5px;\n\n &:not(textarea) {\n /* padding above and below together is 21px, and total height should be 40px */\n height: 19px;\n }\n }\n .MuiInputBase-inputMultiline {\n padding: 0;\n }\n }\n\n &.", " .", " {\n // inputSelect has an arrow so we need spacing for end adornment\n margin-right: ", ";\n }\n\n &.", ", &.", " {\n .", " {\n color: ", ";\n p {\n font-size: ", "px;\n margin: 0;\n }\n\n .dot-icon i {\n margin-top: -2px;\n }\n }\n\n .MuiInputBase-root {\n margin-bottom: 0;\n }\n\n .MuiInputBase-inputSizeSmall:not(textarea) {\n height: 19px;\n padding-top: 10.5px;\n padding-bottom: 10.5px;\n }\n\n select.dot-select {\n padding-left: ", ";\n }\n\n .MuiSelect-select:focus {\n background-color: transparent;\n }\n\n .MuiSelect-icon {\n right: ", ";\n }\n\n &.", " {\n .MuiOutlinedInput-notchedOutline {\n border-color: ", ";\n }\n\n .MuiFormLabel-root.Mui-focused {\n color: ", ";\n }\n\n .", " .dot-icon {\n color: ", ";\n }\n }\n\n &.", " {\n .MuiInputLabel-outlined.MuiInputLabel-shrink {\n color: ", ";\n }\n\n .", " .dot-icon {\n color: ", ";\n }\n }\n\n &.", " {\n .MuiOutlinedInput-notchedOutline {\n border-color: ", ";\n }\n\n .MuiInputLabel-outlined.MuiInputLabel-shrink {\n color: ", ";\n }\n\n .", " .dot-icon {\n color: ", ";\n }\n }\n\n .MuiOutlinedInput-adornedStart {\n padding-left: 12px;\n\n &.", " .", " {\n border-color: ", ";\n }\n }\n\n .MuiInputLabel-outlined.MuiInputLabel-shrink {\n color: ", ";\n }\n\n .MuiInputBase-inputAdornedStart {\n padding-left: 12px;\n }\n .MuiInputBase-inputAdornedEnd {\n padding-right: 12px;\n }\n .MuiFormHelperText-root {\n ", ";\n }\n }\n "], ["\n &.", " {\n .MuiInputBase-root {\n margin-bottom: 0;\n }\n .MuiInputBase-input {\n box-sizing: content-box;\n }\n .MuiOutlinedInput-input {\n padding: ", ";\n }\n .MuiInputBase-inputSizeSmall {\n padding-top: 10.5px;\n padding-bottom: 10.5px;\n\n &:not(textarea) {\n /* padding above and below together is 21px, and total height should be 40px */\n height: 19px;\n }\n }\n .MuiInputBase-inputMultiline {\n padding: 0;\n }\n }\n\n &.", " .", " {\n // inputSelect has an arrow so we need spacing for end adornment\n margin-right: ", ";\n }\n\n &.", ", &.", " {\n .", " {\n color: ", ";\n p {\n font-size: ", "px;\n margin: 0;\n }\n\n .dot-icon i {\n margin-top: -2px;\n }\n }\n\n .MuiInputBase-root {\n margin-bottom: 0;\n }\n\n .MuiInputBase-inputSizeSmall:not(textarea) {\n height: 19px;\n padding-top: 10.5px;\n padding-bottom: 10.5px;\n }\n\n select.dot-select {\n padding-left: ", ";\n }\n\n .MuiSelect-select:focus {\n background-color: transparent;\n }\n\n .MuiSelect-icon {\n right: ", ";\n }\n\n &.", " {\n .MuiOutlinedInput-notchedOutline {\n border-color: ", ";\n }\n\n .MuiFormLabel-root.Mui-focused {\n color: ", ";\n }\n\n .", " .dot-icon {\n color: ", ";\n }\n }\n\n &.", " {\n .MuiInputLabel-outlined.MuiInputLabel-shrink {\n color: ", ";\n }\n\n .", " .dot-icon {\n color: ", ";\n }\n }\n\n &.", " {\n .MuiOutlinedInput-notchedOutline {\n border-color: ", ";\n }\n\n .MuiInputLabel-outlined.MuiInputLabel-shrink {\n color: ", ";\n }\n\n .", " .dot-icon {\n color: ", ";\n }\n }\n\n .MuiOutlinedInput-adornedStart {\n padding-left: 12px;\n\n &.", " .", " {\n border-color: ", ";\n }\n }\n\n .MuiInputLabel-outlined.MuiInputLabel-shrink {\n color: ", ";\n }\n\n .MuiInputBase-inputAdornedStart {\n padding-left: 12px;\n }\n .MuiInputBase-inputAdornedEnd {\n padding-right: 12px;\n }\n .MuiFormHelperText-root {\n ", ";\n }\n }\n "])), rootClassName$13, InputProps.startAdornment ? "18px 12px 18px 0px" : "18px 12px", rootSelectClassName, adornmentIconClassName, theme.spacing(2), rootSelectClassName, rootClassName$13, adornmentIconClassName, theme.palette.layer.n700, theme.typography.body2.fontSize, theme.spacing(1.5), InputProps.endAdornment ? "44px" : "12px", successClassName, theme.palette.secondary.main, theme.palette.grey[700], adornmentIconClassName, theme.palette.secondary.main, errorClassName, theme.palette.error.main, adornmentIconClassName, theme.palette.error.main, warningClassName, theme.palette.warning.main, theme.palette.grey[700], adornmentIconClassName, theme.palette.warning.main, warningClassName, fieldsetClassName, theme.palette.warning[500], theme.palette.grey[700], formHelperTextRootStyles(theme));
|
|
398
|
+
return styled.css(templateObject_5$3 || (templateObject_5$3 = __makeTemplateObject(["\n &.", " {\n .MuiInputBase-root {\n margin-bottom: 0;\n }\n .MuiInputBase-input {\n box-sizing: content-box;\n }\n .MuiOutlinedInput-input {\n padding: ", ";\n }\n .MuiInputBase-inputSizeSmall {\n padding-top: 10.5px;\n padding-bottom: 10.5px;\n\n &:not(textarea) {\n /* padding above and below together is 21px, and total height should be 40px */\n height: 19px;\n }\n }\n .MuiInputBase-inputMultiline {\n padding: 0;\n }\n .MuiInputLabel-root.Mui-disabled {\n color: ", ";\n }\n &.", " .MuiInputBase-root,\n .MuiInputBase-root.Mui-disabled {\n ", ";\n }\n }\n\n .dot-select,\n .dot-input {\n &.", ", &.Mui-disabled {\n ", ";\n }\n }\n\n &.", " .", " {\n // inputSelect has an arrow so we need spacing for end adornment\n margin-right: ", ";\n }\n\n &.", ", &.", " {\n .", " {\n color: ", ";\n p {\n font-size: ", "px;\n margin: 0;\n }\n\n .dot-icon i {\n margin-top: -2px;\n }\n }\n\n .MuiInputBase-root {\n margin-bottom: 0;\n }\n\n .MuiInputBase-inputSizeSmall:not(textarea) {\n height: 19px;\n padding-top: 10.5px;\n padding-bottom: 10.5px;\n }\n\n select.dot-select {\n padding-left: ", ";\n }\n\n .MuiSelect-select:focus:not(.", ") {\n background-color: transparent;\n }\n\n .MuiSelect-icon {\n right: ", ";\n }\n\n &.", " {\n .MuiOutlinedInput-notchedOutline {\n border-color: ", ";\n }\n\n .MuiFormLabel-root.Mui-focused {\n color: ", ";\n }\n\n .", " .dot-icon {\n color: ", ";\n }\n }\n\n &.", " {\n .MuiInputLabel-outlined.MuiInputLabel-shrink {\n color: ", ";\n }\n\n .", " .dot-icon {\n color: ", ";\n }\n }\n\n &.", " {\n .MuiOutlinedInput-notchedOutline {\n border-color: ", ";\n }\n\n .MuiInputLabel-outlined.MuiInputLabel-shrink {\n color: ", ";\n }\n\n .", " .dot-icon {\n color: ", ";\n }\n }\n\n .MuiOutlinedInput-adornedStart {\n padding-left: 12px;\n\n &.", " .", " {\n border-color: ", ";\n }\n }\n\n .MuiInputLabel-outlined.MuiInputLabel-shrink {\n color: ", ";\n }\n\n .MuiInputBase-inputAdornedStart {\n padding-left: 12px;\n }\n .MuiInputBase-inputAdornedEnd {\n padding-right: 12px;\n }\n .MuiFormHelperText-root {\n ", ";\n }\n }\n "], ["\n &.", " {\n .MuiInputBase-root {\n margin-bottom: 0;\n }\n .MuiInputBase-input {\n box-sizing: content-box;\n }\n .MuiOutlinedInput-input {\n padding: ", ";\n }\n .MuiInputBase-inputSizeSmall {\n padding-top: 10.5px;\n padding-bottom: 10.5px;\n\n &:not(textarea) {\n /* padding above and below together is 21px, and total height should be 40px */\n height: 19px;\n }\n }\n .MuiInputBase-inputMultiline {\n padding: 0;\n }\n .MuiInputLabel-root.Mui-disabled {\n color: ", ";\n }\n &.", " .MuiInputBase-root,\n .MuiInputBase-root.Mui-disabled {\n ", ";\n }\n }\n\n .dot-select,\n .dot-input {\n &.", ", &.Mui-disabled {\n ", ";\n }\n }\n\n &.", " .", " {\n // inputSelect has an arrow so we need spacing for end adornment\n margin-right: ", ";\n }\n\n &.", ", &.", " {\n .", " {\n color: ", ";\n p {\n font-size: ", "px;\n margin: 0;\n }\n\n .dot-icon i {\n margin-top: -2px;\n }\n }\n\n .MuiInputBase-root {\n margin-bottom: 0;\n }\n\n .MuiInputBase-inputSizeSmall:not(textarea) {\n height: 19px;\n padding-top: 10.5px;\n padding-bottom: 10.5px;\n }\n\n select.dot-select {\n padding-left: ", ";\n }\n\n .MuiSelect-select:focus:not(.", ") {\n background-color: transparent;\n }\n\n .MuiSelect-icon {\n right: ", ";\n }\n\n &.", " {\n .MuiOutlinedInput-notchedOutline {\n border-color: ", ";\n }\n\n .MuiFormLabel-root.Mui-focused {\n color: ", ";\n }\n\n .", " .dot-icon {\n color: ", ";\n }\n }\n\n &.", " {\n .MuiInputLabel-outlined.MuiInputLabel-shrink {\n color: ", ";\n }\n\n .", " .dot-icon {\n color: ", ";\n }\n }\n\n &.", " {\n .MuiOutlinedInput-notchedOutline {\n border-color: ", ";\n }\n\n .MuiInputLabel-outlined.MuiInputLabel-shrink {\n color: ", ";\n }\n\n .", " .dot-icon {\n color: ", ";\n }\n }\n\n .MuiOutlinedInput-adornedStart {\n padding-left: 12px;\n\n &.", " .", " {\n border-color: ", ";\n }\n }\n\n .MuiInputLabel-outlined.MuiInputLabel-shrink {\n color: ", ";\n }\n\n .MuiInputBase-inputAdornedStart {\n padding-left: 12px;\n }\n .MuiInputBase-inputAdornedEnd {\n padding-right: 12px;\n }\n .MuiFormHelperText-root {\n ", ";\n }\n }\n "])), rootClassName$13, InputProps.startAdornment ? "18px 12px 18px 0px" : "18px 12px", theme.palette.layer.n500, readOnlyClassName$1, readOnlyStyles(theme), readOnlyClassName$1, readOnlyStyles(theme), rootSelectClassName, adornmentIconClassName, theme.spacing(2), rootSelectClassName, rootClassName$13, adornmentIconClassName, theme.palette.layer.n700, theme.typography.body2.fontSize, theme.spacing(1.5), readOnlyClassName$1, InputProps.endAdornment ? "44px" : "12px", successClassName, theme.palette.secondary.main, theme.palette.grey[700], adornmentIconClassName, theme.palette.secondary.main, errorClassName, theme.palette.error.main, adornmentIconClassName, theme.palette.error.main, warningClassName, theme.palette.warning.main, theme.palette.grey[700], adornmentIconClassName, theme.palette.warning.main, warningClassName, fieldsetClassName, theme.palette.warning[500], theme.palette.grey[700], formHelperTextRootStyles(theme));
|
|
395
399
|
});
|
|
396
400
|
var templateObject_1$19, templateObject_2$14, templateObject_3$c, templateObject_4$a, templateObject_5$3, templateObject_6$1;
|
|
397
401
|
|
|
@@ -3266,7 +3270,9 @@
|
|
|
3266
3270
|
id = _a.id,
|
|
3267
3271
|
inputRef = _a.inputRef,
|
|
3268
3272
|
label = _a.label,
|
|
3273
|
+
max = _a.max,
|
|
3269
3274
|
maxRows = _a.maxRows,
|
|
3275
|
+
min = _a.min,
|
|
3270
3276
|
minRows = _a.minRows,
|
|
3271
3277
|
_f = _a.multiline,
|
|
3272
3278
|
multiline = _f === void 0 ? false : _f,
|
|
@@ -3300,7 +3306,7 @@
|
|
|
3300
3306
|
var _m = React.useState(hasDebounce && getInitialState(value)),
|
|
3301
3307
|
inputTextState = _m[0],
|
|
3302
3308
|
setInputTextState = _m[1];
|
|
3303
|
-
var rootStyles = useStylesWithRootClass(rootClassName$13, hasError, hasWarning, hasSuccess, readOnly
|
|
3309
|
+
var rootStyles = useStylesWithRootClass(rootClassName$13, hasError, hasWarning, hasSuccess, readOnly && readOnlyClassName$1);
|
|
3304
3310
|
// Used to control text value from the consumer component
|
|
3305
3311
|
// when debounce feature is enabled
|
|
3306
3312
|
React.useEffect(function () {
|
|
@@ -3355,6 +3361,7 @@
|
|
|
3355
3361
|
}), void 0);
|
|
3356
3362
|
};
|
|
3357
3363
|
var wrapperClassName = useStylesWithRootClass(fullWidth !== false ? 'dot-input-text--fullwidth' : '', className);
|
|
3364
|
+
var inputClassName = useStylesWithRootClass('dot-input', readOnly && readOnlyClassName$1);
|
|
3358
3365
|
return jsxRuntime.jsxs(StyledTextFieldContainer, __assign({
|
|
3359
3366
|
className: wrapperClassName
|
|
3360
3367
|
}, {
|
|
@@ -3378,7 +3385,6 @@
|
|
|
3378
3385
|
defaultValue: defaultInputValue,
|
|
3379
3386
|
disabled: disabled,
|
|
3380
3387
|
error: error,
|
|
3381
|
-
focused: readOnly ? false : undefined,
|
|
3382
3388
|
fullWidth: fullWidth,
|
|
3383
3389
|
helperText: helperText,
|
|
3384
3390
|
id: id,
|
|
@@ -3387,8 +3393,10 @@
|
|
|
3387
3393
|
},
|
|
3388
3394
|
inputProps: {
|
|
3389
3395
|
'data-testid': dataTestId,
|
|
3390
|
-
className:
|
|
3391
|
-
readOnly: readOnly
|
|
3396
|
+
className: inputClassName,
|
|
3397
|
+
readOnly: readOnly,
|
|
3398
|
+
max: max,
|
|
3399
|
+
min: min
|
|
3392
3400
|
},
|
|
3393
3401
|
inputRef: inputRef,
|
|
3394
3402
|
label: persistentLabel ? null : label,
|
|
@@ -4727,7 +4735,7 @@
|
|
|
4727
4735
|
componentId: "j2sgjy-0"
|
|
4728
4736
|
})(templateObject_2$I || (templateObject_2$I = __makeTemplateObject(["\n ", "\n"], ["\n ", "\n"])), function (_a) {
|
|
4729
4737
|
var theme = _a.theme;
|
|
4730
|
-
return styled.css(templateObject_1$L || (templateObject_1$L = __makeTemplateObject(["\n &.", " {\n &.", " .dot-text-field .", " {\n height: 56px;\n padding-left: ", ";\n }\n\n .", " {\n /* Override only top/bottom, but preserve left/right padding */\n padding-top: ", ";\n padding-bottom: ", ";\n }\n\n .dot-chip:first-child {\n margin-left: ", ";\n }\n\n .dot-text-field {\n .", " {\n min-height: ", ";\n }\n\n .warning-icon {\n color: ", ";\n }\n .error-icon {\n color: ", ";\n }\n }\n }\n "], ["\n &.", " {\n &.", " .dot-text-field .", " {\n height: 56px;\n padding-left: ", ";\n }\n\n .", " {\n /* Override only top/bottom, but preserve left/right padding */\n padding-top: ", ";\n padding-bottom: ", ";\n }\n\n .dot-chip:first-child {\n margin-left: ", ";\n }\n\n .dot-text-field {\n .", " {\n min-height: ", ";\n }\n\n .warning-icon {\n color: ", ";\n }\n .error-icon {\n color: ", ";\n }\n }\n }\n "])), rootClassName$I, inputMediumClassName, inputRootClassName, theme.spacing(2), inputRootClassName, theme.spacing(0), theme.spacing(0), theme.spacing(0), inputRootClassName, theme.spacing(5), theme.palette.warning.main, theme.palette.error.main);
|
|
4738
|
+
return styled.css(templateObject_1$L || (templateObject_1$L = __makeTemplateObject(["\n &.", " {\n &.", " .dot-text-field .", " {\n height: 56px;\n padding-left: ", ";\n }\n\n .MuiInputBase-root.Mui-disabled,\n .", " .MuiInputBase-root {\n ", ";\n }\n\n .", " {\n /* Override only top/bottom, but preserve left/right padding */\n padding-top: ", ";\n padding-bottom: ", ";\n }\n\n .dot-chip:first-child {\n margin-left: ", ";\n }\n\n .dot-text-field {\n .", " {\n min-height: ", ";\n }\n\n .warning-icon {\n color: ", ";\n }\n .error-icon {\n color: ", ";\n }\n }\n }\n "], ["\n &.", " {\n &.", " .dot-text-field .", " {\n height: 56px;\n padding-left: ", ";\n }\n\n .MuiInputBase-root.Mui-disabled,\n .", " .MuiInputBase-root {\n ", ";\n }\n\n .", " {\n /* Override only top/bottom, but preserve left/right padding */\n padding-top: ", ";\n padding-bottom: ", ";\n }\n\n .dot-chip:first-child {\n margin-left: ", ";\n }\n\n .dot-text-field {\n .", " {\n min-height: ", ";\n }\n\n .warning-icon {\n color: ", ";\n }\n .error-icon {\n color: ", ";\n }\n }\n }\n "])), rootClassName$I, inputMediumClassName, inputRootClassName, theme.spacing(2), readOnlyClassName$1, readOnlyStyles(theme), inputRootClassName, theme.spacing(0), theme.spacing(0), theme.spacing(0), inputRootClassName, theme.spacing(5), theme.palette.warning.main, theme.palette.error.main);
|
|
4731
4739
|
});
|
|
4732
4740
|
var templateObject_1$L, templateObject_2$I;
|
|
4733
4741
|
|
|
@@ -4894,6 +4902,7 @@
|
|
|
4894
4902
|
inputId = _a.inputId,
|
|
4895
4903
|
inputRef = _a.inputRef,
|
|
4896
4904
|
inputValue = _a.inputValue,
|
|
4905
|
+
isOptionEqualToValue = _a.isOptionEqualToValue,
|
|
4897
4906
|
label = _a.label,
|
|
4898
4907
|
loading = _a.loading,
|
|
4899
4908
|
maxHeight = _a.maxHeight,
|
|
@@ -4938,7 +4947,7 @@
|
|
|
4938
4947
|
var preventDuplicateInsertion = actionItem === null || actionItem === void 0 ? void 0 : actionItem.preventDuplicateInsertion;
|
|
4939
4948
|
var textFieldWarningClassName = !error && warning && warningClassName;
|
|
4940
4949
|
var rootClasses = useStylesWithRootClass(rootClassName$I, size === 'medium' && inputMediumClassName, className);
|
|
4941
|
-
var textFieldRootClasses = useStylesWithRootClass(rootClassName$13, readOnly &&
|
|
4950
|
+
var textFieldRootClasses = useStylesWithRootClass(rootClassName$13, readOnly && readOnlyClassName$1, textFieldWarningClassName);
|
|
4942
4951
|
var inputRootClasses = useStylesWithRootClass(inputRootClassName, !dense && inputMediumClassName);
|
|
4943
4952
|
var highlightedOption = null;
|
|
4944
4953
|
var textFieldInput;
|
|
@@ -5131,6 +5140,7 @@
|
|
|
5131
5140
|
return option.group;
|
|
5132
5141
|
} : undefined,
|
|
5133
5142
|
inputValue: inputValue,
|
|
5143
|
+
isOptionEqualToValue: isOptionEqualToValue,
|
|
5134
5144
|
ListboxComponent: ListboxComponent,
|
|
5135
5145
|
loading: loading,
|
|
5136
5146
|
multiple: multiple,
|
|
@@ -5185,7 +5195,6 @@
|
|
|
5185
5195
|
root: textFieldRootClasses
|
|
5186
5196
|
},
|
|
5187
5197
|
error: error,
|
|
5188
|
-
focused: readOnly ? false : undefined,
|
|
5189
5198
|
helperText: helperText,
|
|
5190
5199
|
id: inputId,
|
|
5191
5200
|
inputProps: __assign(__assign({}, inputProps), {
|
|
@@ -6762,7 +6771,8 @@
|
|
|
6762
6771
|
var hasWarning = !error && warning && warningClassName;
|
|
6763
6772
|
var hasSuccess = !error && !warning && success && successClassName;
|
|
6764
6773
|
var endAdornment = endIcon || endText;
|
|
6765
|
-
var
|
|
6774
|
+
var inputStyles = useStylesWithRootClass('dot-select', readOnly && readOnlyClassName$1);
|
|
6775
|
+
var rootStyles = useStylesWithRootClass(rootSelectClassName, hasSuccess, hasWarning);
|
|
6766
6776
|
var getOption = function getOption(option) {
|
|
6767
6777
|
return typeof option === 'string' ? option : option.option;
|
|
6768
6778
|
};
|
|
@@ -6798,12 +6808,12 @@
|
|
|
6798
6808
|
readOnly: readOnly,
|
|
6799
6809
|
open: readOnly ? false : undefined
|
|
6800
6810
|
},
|
|
6811
|
+
"aria-label": ariaLabel || label,
|
|
6801
6812
|
autoFocus: autoFocus,
|
|
6802
6813
|
className: rootStyles,
|
|
6803
6814
|
defaultValue: defaultValue,
|
|
6804
6815
|
disabled: disabled,
|
|
6805
6816
|
error: error,
|
|
6806
|
-
focused: readOnly ? false : undefined,
|
|
6807
6817
|
fullWidth: fullWidth,
|
|
6808
6818
|
helperText: helperText,
|
|
6809
6819
|
id: id,
|
|
@@ -6813,7 +6823,7 @@
|
|
|
6813
6823
|
inputProps: {
|
|
6814
6824
|
'aria-label': ariaLabel,
|
|
6815
6825
|
'data-testid': dataTestId,
|
|
6816
|
-
className:
|
|
6826
|
+
className: inputStyles,
|
|
6817
6827
|
readOnly: readOnly
|
|
6818
6828
|
},
|
|
6819
6829
|
inputRef: inputRef,
|
|
@@ -6825,6 +6835,7 @@
|
|
|
6825
6835
|
onFocus: onFocus,
|
|
6826
6836
|
onKeyDown: onKeyDown,
|
|
6827
6837
|
required: required,
|
|
6838
|
+
role: "textbox",
|
|
6828
6839
|
select: true,
|
|
6829
6840
|
size: size,
|
|
6830
6841
|
value: value,
|
|
@@ -8058,7 +8069,7 @@
|
|
|
8058
8069
|
} : undefined,
|
|
8059
8070
|
ref: inlineEditRef,
|
|
8060
8071
|
role: ariaRole,
|
|
8061
|
-
tabIndex:
|
|
8072
|
+
tabIndex: tabIndex,
|
|
8062
8073
|
typography: typography
|
|
8063
8074
|
}, {
|
|
8064
8075
|
children: editing ? renderEditMode() : renderViewMode()
|
|
@@ -9798,7 +9809,6 @@
|
|
|
9798
9809
|
"data-testid": action['data-testid'],
|
|
9799
9810
|
disabled: action.disabled,
|
|
9800
9811
|
startIcon: startIcon,
|
|
9801
|
-
onClick: action.onClick,
|
|
9802
9812
|
type: "text"
|
|
9803
9813
|
}, {
|
|
9804
9814
|
children: action.label
|
|
@@ -9885,22 +9895,30 @@
|
|
|
9885
9895
|
}
|
|
9886
9896
|
};
|
|
9887
9897
|
var toggleMenu = function toggleMenu(event) {
|
|
9898
|
+
event.stopPropagation();
|
|
9888
9899
|
setAnchorEl(event.currentTarget);
|
|
9889
9900
|
setMenuOpen(!menuOpen);
|
|
9890
9901
|
};
|
|
9891
|
-
var onSelect = function onSelect(
|
|
9902
|
+
var onSelect = function onSelect(event, _menuId, itemKey) {
|
|
9903
|
+
event.stopPropagation();
|
|
9892
9904
|
selectionMap[itemKey].onClick(null);
|
|
9893
9905
|
};
|
|
9894
9906
|
var onLeave = function onLeave() {
|
|
9895
9907
|
setMenuOpen(false);
|
|
9896
9908
|
};
|
|
9909
|
+
var handleTableActionClick = function handleTableActionClick(event, action) {
|
|
9910
|
+
event.stopPropagation();
|
|
9911
|
+
action.onClick(event);
|
|
9912
|
+
};
|
|
9897
9913
|
var renderTableActions = function renderTableActions() {
|
|
9898
9914
|
return actions && actions.map(function (action, index) {
|
|
9899
9915
|
return index < 2 && jsxRuntime.jsx(DotTableAction, {
|
|
9900
9916
|
iconId: action.iconId,
|
|
9901
9917
|
label: action.label,
|
|
9902
9918
|
tooltip: action.tooltip || action.label,
|
|
9903
|
-
onClick:
|
|
9919
|
+
onClick: function (e) {
|
|
9920
|
+
return handleTableActionClick(e, action);
|
|
9921
|
+
}
|
|
9904
9922
|
}, "action-" + index);
|
|
9905
9923
|
});
|
|
9906
9924
|
};
|
|
@@ -9912,6 +9930,7 @@
|
|
|
9912
9930
|
children: [!showMenu && renderTableActions(), (showMenu || actions.length > 2) && jsxRuntime.jsx(DotIconButton, {
|
|
9913
9931
|
ariaLabel: "more options",
|
|
9914
9932
|
className: "dot-table-action-icon",
|
|
9933
|
+
"data-testid": "dot-table-action-icon",
|
|
9915
9934
|
iconId: "options",
|
|
9916
9935
|
iconSize: "small",
|
|
9917
9936
|
onClick: toggleMenu,
|
|
@@ -10418,7 +10437,7 @@
|
|
|
10418
10437
|
})(templateObject_2$2 || (templateObject_2$2 = __makeTemplateObject(["\n ", "\n"], ["\n ", "\n"])), function (_a) {
|
|
10419
10438
|
var theme = _a.theme,
|
|
10420
10439
|
draggableHandle = _a.draggableHandle;
|
|
10421
|
-
return styled.css(templateObject_1$3 || (templateObject_1$3 = __makeTemplateObject(["\n &.", " {\n padding: ", ";\n\n .", " {\n .dot-icon {\n color: ", ";\n }\n\n &.react-draggable-dragging {\n background-color: ", ";\n }\n\n &.with-default-cursor {\n cursor: default;\n }\n\n &.with-handle-grab-cursor ", " {\n cursor: grab;\n }\n }\n }\n "], ["\n &.", " {\n padding: ", ";\n\n .", " {\n .dot-icon {\n color: ", ";\n }\n\n &.react-draggable-dragging {\n background-color: ", ";\n }\n\n &.with-default-cursor {\n cursor: default;\n }\n\n &.with-handle-grab-cursor ", " {\n cursor: grab;\n }\n }\n }\n "])), rootClassName$3, theme.spacing(1, 0), listItemClassName, theme.palette.layer.n700, theme.palette.grey[50], draggableHandle);
|
|
10440
|
+
return styled.css(templateObject_1$3 || (templateObject_1$3 = __makeTemplateObject(["\n &.", " {\n padding: ", ";\n position: relative;\n\n .", " {\n .dot-icon {\n color: ", ";\n }\n\n &.react-draggable-dragging {\n background-color: ", ";\n }\n\n &.with-default-cursor {\n cursor: default;\n }\n\n &.with-handle-grab-cursor ", " {\n cursor: grab;\n }\n }\n }\n "], ["\n &.", " {\n padding: ", ";\n position: relative;\n\n .", " {\n .dot-icon {\n color: ", ";\n }\n\n &.react-draggable-dragging {\n background-color: ", ";\n }\n\n &.with-default-cursor {\n cursor: default;\n }\n\n &.with-handle-grab-cursor ", " {\n cursor: grab;\n }\n }\n }\n "])), rootClassName$3, theme.spacing(1, 0), listItemClassName, theme.palette.layer.n700, theme.palette.grey[50], draggableHandle);
|
|
10422
10441
|
});
|
|
10423
10442
|
var templateObject_1$3, templateObject_2$2;
|
|
10424
10443
|
|
|
@@ -10590,7 +10609,7 @@
|
|
|
10590
10609
|
componentId: "sc-1to4suu-1"
|
|
10591
10610
|
})(templateObject_3$1 || (templateObject_3$1 = __makeTemplateObject(["\n ", "\n"], ["\n ", "\n"])), function (_a) {
|
|
10592
10611
|
var theme = _a.theme;
|
|
10593
|
-
return styled.css(templateObject_2$1 || (templateObject_2$1 = __makeTemplateObject(["\n &.", " {\n ", ";\n }\n "], ["\n &.", " {\n ", ";\n }\n "])), rootClassName$1, pickerInputStyles(theme));
|
|
10612
|
+
return styled.css(templateObject_2$1 || (templateObject_2$1 = __makeTemplateObject(["\n &.", " {\n ", ";\n\n .Mui-disabled.MuiInputBase-root,\n &.read-only .MuiInputBase-root {\n ", ";\n }\n\n .MuiFormLabel-root {\n color: ", ";\n }\n }\n "], ["\n &.", " {\n ", ";\n\n .Mui-disabled.MuiInputBase-root,\n &.read-only .MuiInputBase-root {\n ", ";\n }\n\n .MuiFormLabel-root {\n color: ", ";\n }\n }\n "])), rootClassName$1, pickerInputStyles(theme), readOnlyStyles(theme), theme.palette.layer.n500);
|
|
10594
10613
|
});
|
|
10595
10614
|
var StyledPickersDay = styled__default["default"](xDatePickers.PickersDay).withConfig({
|
|
10596
10615
|
displayName: "DatePickerstyles__StyledPickersDay",
|
|
@@ -10913,7 +10932,7 @@
|
|
|
10913
10932
|
componentId: "sc-17aptuh-1"
|
|
10914
10933
|
})(templateObject_4 || (templateObject_4 = __makeTemplateObject(["\n ", "\n"], ["\n ", "\n"])), function (_a) {
|
|
10915
10934
|
var theme = _a.theme;
|
|
10916
|
-
return styled.css(templateObject_3 || (templateObject_3 = __makeTemplateObject(["\n &.", " {\n ", ";\n }\n "], ["\n &.", " {\n ", ";\n }\n "])), rootClassName, pickerInputStyles(theme));
|
|
10935
|
+
return styled.css(templateObject_3 || (templateObject_3 = __makeTemplateObject(["\n &.", " {\n ", ";\n\n .Mui-disabled.MuiInputBase-root,\n &.read-only .MuiInputBase-root {\n ", ";\n }\n\n .MuiFormLabel-root {\n color: ", ";\n }\n }\n "], ["\n &.", " {\n ", ";\n\n .Mui-disabled.MuiInputBase-root,\n &.read-only .MuiInputBase-root {\n ", ";\n }\n\n .MuiFormLabel-root {\n color: ", ";\n }\n }\n "])), rootClassName, pickerInputStyles(theme), readOnlyStyles(theme), theme.palette.layer.n500);
|
|
10917
10936
|
});
|
|
10918
10937
|
var templateObject_1, templateObject_2, templateObject_3, templateObject_4;
|
|
10919
10938
|
|
|
@@ -11246,7 +11265,6 @@
|
|
|
11246
11265
|
required: required,
|
|
11247
11266
|
helperText: helperText,
|
|
11248
11267
|
error: error,
|
|
11249
|
-
focused: isComponentReadOnly ? false : undefined,
|
|
11250
11268
|
InputProps: {
|
|
11251
11269
|
endAdornment: jsxRuntime.jsxs(jsxRuntime.Fragment, {
|
|
11252
11270
|
children: [error && jsxRuntime.jsx(DotIcon, {
|
|
@@ -44,6 +44,7 @@ export interface AutoCompleteProps<T extends AutoCompleteOption = AutoCompleteOp
|
|
|
44
44
|
inputRef?: Ref<HTMLInputElement>;
|
|
45
45
|
/** The value of the input field. */
|
|
46
46
|
inputValue?: string;
|
|
47
|
+
isOptionEqualToValue?: (option: T, value: T) => boolean;
|
|
47
48
|
/** Label displayed above the input field */
|
|
48
49
|
label?: string;
|
|
49
50
|
/** If true, the component will be in a loading state. */
|
|
@@ -85,4 +86,4 @@ export interface AutoCompleteProps<T extends AutoCompleteOption = AutoCompleteOp
|
|
|
85
86
|
/** If true, the label will be displayed in a warning state. */
|
|
86
87
|
warning?: boolean;
|
|
87
88
|
}
|
|
88
|
-
export declare const DotAutoComplete: <T extends AutoCompleteOption>({ ListboxComponent, actionItem, ariaLabel, autoFocus, className, "data-testid": dataTestId, defaultValue, dense, disabled, disablePortal, endAdornmentTooltip, error, filterOptions, filterSelectedOptions, freesolo, checkIfOptionDisabled, group, helperText, inputId, inputRef, inputValue, label, loading, maxHeight, multiple, onBlur, onChange, onClose, onInputChange, onOpen, open, options, persistentLabel, placeholder, readOnly, renderOption, renderTags, required, size, value, warning, }: AutoCompleteProps<T>) => JSX.Element;
|
|
89
|
+
export declare const DotAutoComplete: <T extends AutoCompleteOption>({ ListboxComponent, actionItem, ariaLabel, autoFocus, className, "data-testid": dataTestId, defaultValue, dense, disabled, disablePortal, endAdornmentTooltip, error, filterOptions, filterSelectedOptions, freesolo, checkIfOptionDisabled, group, helperText, inputId, inputRef, inputValue, isOptionEqualToValue, label, loading, maxHeight, multiple, onBlur, onChange, onClose, onInputChange, onOpen, open, options, persistentLabel, placeholder, readOnly, renderOption, renderTags, required, size, value, warning, }: AutoCompleteProps<T>) => JSX.Element;
|
|
@@ -2,7 +2,7 @@ import { ComponentMeta, Story } from '@storybook/react';
|
|
|
2
2
|
import { AutoCompleteProps } from './AutoComplete';
|
|
3
3
|
import { AutoCompleteOption } from './utils/interface';
|
|
4
4
|
import { AutoCompleteWithRenderOption } from './Autocomplete.stories.data';
|
|
5
|
-
declare const _default: ComponentMeta<(<T extends AutoCompleteOption>({ ListboxComponent, actionItem, ariaLabel, autoFocus, className, "data-testid": dataTestId, defaultValue, dense, disabled, disablePortal, endAdornmentTooltip, error, filterOptions, filterSelectedOptions, freesolo, checkIfOptionDisabled, group, helperText, inputId, inputRef, inputValue, label, loading, maxHeight, multiple, onBlur, onChange, onClose, onInputChange, onOpen, open, options, persistentLabel, placeholder, readOnly, renderOption, renderTags, required, size, value, warning, }: AutoCompleteProps<T>) => JSX.Element)>;
|
|
5
|
+
declare const _default: ComponentMeta<(<T extends AutoCompleteOption>({ ListboxComponent, actionItem, ariaLabel, autoFocus, className, "data-testid": dataTestId, defaultValue, dense, disabled, disablePortal, endAdornmentTooltip, error, filterOptions, filterSelectedOptions, freesolo, checkIfOptionDisabled, group, helperText, inputId, inputRef, inputValue, isOptionEqualToValue, label, loading, maxHeight, multiple, onBlur, onChange, onClose, onInputChange, onOpen, open, options, persistentLabel, placeholder, readOnly, renderOption, renderTags, required, size, value, warning, }: AutoCompleteProps<T>) => JSX.Element)>;
|
|
6
6
|
export default _default;
|
|
7
7
|
export declare const Default: any;
|
|
8
8
|
export declare const WithActionItem: any;
|
|
@@ -18,7 +18,7 @@ export interface DatePickerProps extends CommonProps {
|
|
|
18
18
|
disablePast?: boolean;
|
|
19
19
|
/** Disable the portal behavior. If true, children stay within parent DOM hierarchy. */
|
|
20
20
|
disablePortal?: boolean;
|
|
21
|
-
/** If `true`, the picker and text field are disabled. */
|
|
21
|
+
/** If `true`, the picker and text field are disabled. DOES NOT WORK WITH SCREEN READERS, we recommend using `readOnly` instead. */
|
|
22
22
|
disabled?: boolean;
|
|
23
23
|
/** If `true`, 'Clear' button will be displayed in the calendar popper. `True` by default. */
|
|
24
24
|
displayClearButton?: boolean;
|
|
@@ -6,7 +6,7 @@ export interface InputProps extends CommonProps {
|
|
|
6
6
|
autoFocus?: boolean;
|
|
7
7
|
/** default value of the input element */
|
|
8
8
|
defaultValue?: string;
|
|
9
|
-
/** If true, the input will be disabled. */
|
|
9
|
+
/** If true, the input will be disabled. DOES NOT WORK WITH SCREEN READERS, we recommend using `readOnly` instead. */
|
|
10
10
|
disabled?: boolean;
|
|
11
11
|
/** Icon placed after the children. */
|
|
12
12
|
endIcon?: ReactNode;
|
|
@@ -27,6 +27,8 @@ export interface InputProps extends CommonProps {
|
|
|
27
27
|
inputRef?: Ref<HTMLInputElement>;
|
|
28
28
|
/** The label content. */
|
|
29
29
|
label?: string;
|
|
30
|
+
max?: number | string;
|
|
31
|
+
min?: number | string;
|
|
30
32
|
/** The name of input element */
|
|
31
33
|
name: string;
|
|
32
34
|
/** A function that should be executed when the input loses focus */
|
|
@@ -7,6 +7,7 @@ export declare const warningClassName = "dot-warning";
|
|
|
7
7
|
export declare const successClassName = "dot-success";
|
|
8
8
|
export declare const adornmentIconClassName = "dot-adornment-icon";
|
|
9
9
|
export declare const fieldsetClassName = "MuiOutlinedInput-notchedOutline";
|
|
10
|
+
export declare const readOnlyClassName = "read-only";
|
|
10
11
|
export declare const StyledAdornment: import("styled-components").StyledComponent<import("@mui/material/OverridableComponent").OverridableComponent<import("@mui/material").InputAdornmentTypeMap<{}, "div">>, any, {}, never>;
|
|
11
12
|
export declare const StyledInputLabel: import("styled-components").StyledComponent<import("@mui/material/OverridableComponent").OverridableComponent<import("@mui/material").InputLabelTypeMap<{}, "label">>, any, {}, never>;
|
|
12
13
|
export declare const StyledTextFieldContainer: import("styled-components").StyledComponent<"div", any, {}, never>;
|
|
@@ -9,7 +9,7 @@ export interface InputTextProps extends InputProps {
|
|
|
9
9
|
**/
|
|
10
10
|
autoComplete?: string;
|
|
11
11
|
endAdornmentTooltip?: string;
|
|
12
|
-
/** If true, the input will use debounce functionality.
|
|
12
|
+
/** If true, the input will use debounce functionality. */
|
|
13
13
|
hasDebounce?: boolean;
|
|
14
14
|
/** max of rows for multiline line */
|
|
15
15
|
maxRows?: number;
|
|
@@ -31,4 +31,4 @@ export interface EndIconProps {
|
|
|
31
31
|
success?: boolean;
|
|
32
32
|
warning?: boolean;
|
|
33
33
|
}
|
|
34
|
-
export declare const DotInputText: ({ autoComplete, autoFocus, className, defaultValue, "data-testid": dataTestId, disabled, error, endAdornmentTooltip, fullWidth, hasDebounce, helperText, endIcon, endText, id, inputRef, label, maxRows, minRows, multiline, name, onBlur, onChange, onFocus, onKeyDown, onMouseUp, persistentLabel, placeholder, readOnly, required, shrink, startIcon, size, success, type, value, warning, }: InputTextProps) => JSX.Element;
|
|
34
|
+
export declare const DotInputText: ({ autoComplete, autoFocus, className, defaultValue, "data-testid": dataTestId, disabled, error, endAdornmentTooltip, fullWidth, hasDebounce, helperText, endIcon, endText, id, inputRef, label, max, maxRows, min, minRows, multiline, name, onBlur, onChange, onFocus, onKeyDown, onMouseUp, persistentLabel, placeholder, readOnly, required, shrink, startIcon, size, success, type, value, warning, }: InputTextProps) => JSX.Element;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { ComponentMeta, Story } from '@storybook/react';
|
|
2
2
|
import { InputTextProps } from './InputText';
|
|
3
|
-
declare const _default: ComponentMeta<({ autoComplete, autoFocus, className, defaultValue, "data-testid": dataTestId, disabled, error, endAdornmentTooltip, fullWidth, hasDebounce, helperText, endIcon, endText, id, inputRef, label, maxRows, minRows, multiline, name, onBlur, onChange, onFocus, onKeyDown, onMouseUp, persistentLabel, placeholder, readOnly, required, shrink, startIcon, size, success, type, value, warning, }: InputTextProps) => JSX.Element>;
|
|
3
|
+
declare const _default: ComponentMeta<({ autoComplete, autoFocus, className, defaultValue, "data-testid": dataTestId, disabled, error, endAdornmentTooltip, fullWidth, hasDebounce, helperText, endIcon, endText, id, inputRef, label, max, maxRows, min, minRows, multiline, name, onBlur, onChange, onFocus, onKeyDown, onMouseUp, persistentLabel, placeholder, readOnly, required, shrink, startIcon, size, success, type, value, warning, }: InputTextProps) => JSX.Element>;
|
|
4
4
|
export default _default;
|
|
5
5
|
export declare const Default: Story<InputTextProps>;
|
|
6
6
|
export declare const WithPersistentLabel: Story<InputTextProps>;
|
|
@@ -13,3 +13,5 @@ export declare const WithWarningTooltip: Story<InputTextProps>;
|
|
|
13
13
|
export declare const WithReadOnly: Story<InputTextProps>;
|
|
14
14
|
export declare const WithMultiline: Story<InputTextProps>;
|
|
15
15
|
export declare const WithEndText: Story<InputTextProps>;
|
|
16
|
+
export declare const WithMinMaxNumber: Story<InputTextProps>;
|
|
17
|
+
export declare const WithMinMaxDate: Story<InputTextProps>;
|
|
@@ -1,4 +1,5 @@
|
|
|
1
|
-
import { Theme } from '
|
|
2
|
-
export declare const formHelperTextRootStyles: (theme: Theme) => import("styled-components").FlattenSimpleInterpolation;
|
|
1
|
+
import { lightTheme as Theme } from '../../../lib/theme-provider/ThemeProvider';
|
|
2
|
+
export declare const formHelperTextRootStyles: (theme: typeof Theme) => import("styled-components").FlattenSimpleInterpolation;
|
|
3
3
|
export declare const adornmentIconStyles: () => import("styled-components").FlattenSimpleInterpolation;
|
|
4
|
-
export declare const pickerInputStyles: (theme: Theme) => import("styled-components").FlattenSimpleInterpolation;
|
|
4
|
+
export declare const pickerInputStyles: (theme: typeof Theme) => import("styled-components").FlattenSimpleInterpolation;
|
|
5
|
+
export declare const readOnlyStyles: (theme: typeof Theme) => import("styled-components").FlattenSimpleInterpolation;
|
|
@@ -13,7 +13,7 @@ export interface TimePickerProps extends CommonProps {
|
|
|
13
13
|
disableClickAwayListener?: boolean;
|
|
14
14
|
/** If `true`, the open picker button will not be rendered (renders only the field). */
|
|
15
15
|
disableOpenPicker?: boolean;
|
|
16
|
-
/** If `true`, the picker and text field are disabled. */
|
|
16
|
+
/** If `true`, the picker and text field are disabled. DOES NOT WORK WITH SCREEN READERS, we recommend using `readOnly` instead. */
|
|
17
17
|
disabled?: boolean;
|
|
18
18
|
/** If true, the label will be displayed in an error state. */
|
|
19
19
|
error?: boolean;
|
|
@@ -1,7 +1,19 @@
|
|
|
1
1
|
import { ReactNode } from 'react';
|
|
2
2
|
import { Theme } from '@mui/material';
|
|
3
3
|
import { TypographyOptions } from '@mui/material/styles/createTypography';
|
|
4
|
-
import { AvatarPaletteColorOptions } from '
|
|
4
|
+
import { AvatarPaletteColorOptions, IconPaletteColorOptions, LayerPaletteColorOptions } from './interfaces';
|
|
5
|
+
declare module '@mui/material/styles/createPalette' {
|
|
6
|
+
interface Palette {
|
|
7
|
+
layer: LayerPaletteColorOptions;
|
|
8
|
+
purple?: PaletteColorOptions;
|
|
9
|
+
}
|
|
10
|
+
interface PaletteOptions {
|
|
11
|
+
avatarColors: AvatarPaletteColorOptions;
|
|
12
|
+
icon: IconPaletteColorOptions;
|
|
13
|
+
layer: LayerPaletteColorOptions;
|
|
14
|
+
purple?: PaletteColorOptions;
|
|
15
|
+
}
|
|
16
|
+
}
|
|
5
17
|
export declare type ThemeOptions = 'light' | 'dark';
|
|
6
18
|
export declare const typographyOptions: TypographyOptions;
|
|
7
19
|
export declare const avatarColors: AvatarPaletteColorOptions;
|
|
@@ -17,12 +29,3 @@ declare module '@mui/material/LinearProgress' {
|
|
|
17
29
|
purple: true;
|
|
18
30
|
}
|
|
19
31
|
}
|
|
20
|
-
declare module '@mui/material/styles/createPalette' {
|
|
21
|
-
interface Palette {
|
|
22
|
-
layer: LayerPaletteColorOptions;
|
|
23
|
-
purple?: PaletteColorOptions;
|
|
24
|
-
}
|
|
25
|
-
interface PaletteOptions {
|
|
26
|
-
purple?: PaletteColorOptions;
|
|
27
|
-
}
|
|
28
|
-
}
|
|
@@ -0,0 +1,56 @@
|
|
|
1
|
+
export interface AvatarPaletteColorOption {
|
|
2
|
+
backgroundColor: string;
|
|
3
|
+
color: string;
|
|
4
|
+
}
|
|
5
|
+
export interface AvatarPaletteColorOptions {
|
|
6
|
+
blue: AvatarPaletteColorOption;
|
|
7
|
+
darkGrey: AvatarPaletteColorOption;
|
|
8
|
+
default: AvatarPaletteColorOption;
|
|
9
|
+
green: AvatarPaletteColorOption;
|
|
10
|
+
inherit: AvatarPaletteColorOption;
|
|
11
|
+
lightGrey: AvatarPaletteColorOption;
|
|
12
|
+
orange: AvatarPaletteColorOption;
|
|
13
|
+
purple: AvatarPaletteColorOption;
|
|
14
|
+
red: AvatarPaletteColorOption;
|
|
15
|
+
transparent: AvatarPaletteColorOption;
|
|
16
|
+
white: AvatarPaletteColorOption;
|
|
17
|
+
yellow: AvatarPaletteColorOption;
|
|
18
|
+
}
|
|
19
|
+
export interface BreakpointOptions {
|
|
20
|
+
values: {
|
|
21
|
+
lg: number;
|
|
22
|
+
md: number;
|
|
23
|
+
sm: number;
|
|
24
|
+
xl: number;
|
|
25
|
+
xs: number;
|
|
26
|
+
};
|
|
27
|
+
}
|
|
28
|
+
export interface AvatarPaletteColorOption {
|
|
29
|
+
backgroundColor: string;
|
|
30
|
+
color: string;
|
|
31
|
+
}
|
|
32
|
+
export interface LayerPaletteColorOptions {
|
|
33
|
+
n0: string;
|
|
34
|
+
n100: string;
|
|
35
|
+
n200: string;
|
|
36
|
+
n300: string;
|
|
37
|
+
n400: string;
|
|
38
|
+
n50: string;
|
|
39
|
+
n500: string;
|
|
40
|
+
n600: string;
|
|
41
|
+
n700: string;
|
|
42
|
+
n800: string;
|
|
43
|
+
n900: string;
|
|
44
|
+
}
|
|
45
|
+
export interface IconPaletteColorOptions {
|
|
46
|
+
checkOutline: string;
|
|
47
|
+
emphasized: string;
|
|
48
|
+
fileDotted: string;
|
|
49
|
+
improve: string;
|
|
50
|
+
improveHover: string;
|
|
51
|
+
maintain: string;
|
|
52
|
+
maintainHover: string;
|
|
53
|
+
rogueCommits: string;
|
|
54
|
+
unknown: string;
|
|
55
|
+
unknownHover: string;
|
|
56
|
+
}
|