@digital-ai/dot-components 2.8.1 → 2.8.2

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 CHANGED
@@ -1,5 +1,27 @@
1
1
  # Changelog
2
2
 
3
+ ## [2.8.2](https://www.npmjs.com/package/@digital-ai/dot-components) (05/26/2023)
4
+
5
+ [Full Changelog](https://digital-ai.github.io/dot-components/?path=/story/introduction--page/digital-ai/dot-components/compare/1.21.11...2.8.2)
6
+
7
+ **Fixed bugs:**
8
+
9
+ - S-91947: DotStepper step onClick validation [\#1503](https://github.com/digital-ai/dot-components/pull/1503) ([ryangamble](https://github.com/ryangamble))
10
+ - S-92200: Dynamic form autocomplete needs to handle free-form input [\#1490](https://github.com/digital-ai/dot-components/pull/1490) ([jmcnally](https://github.com/jmcnally))
11
+
12
+ **Misc:**
13
+
14
+ - S-91987: update drawer to have correct aria attributes [\#1506](https://github.com/digital-ai/dot-components/pull/1506) ([CWSites](https://github.com/CWSites))
15
+ - S-91988: components missing focus visibility indicator [\#1504](https://github.com/digital-ai/dot-components/pull/1504) ([CWSites](https://github.com/CWSites))
16
+
17
+ ## [1.21.11](https://www.npmjs.com/package/@digital-ai/dot-components) (05/25/2023)
18
+
19
+ [Full Changelog](https://digital-ai.github.io/dot-components/?path=/story/introduction--page/digital-ai/dot-components/compare/2.8.1...1.21.11)
20
+
21
+ **Features:**
22
+
23
+ - S-92577 `DotAutoComplete`: expose `inputValue` prop [\#1502](https://github.com/digital-ai/dot-components/pull/1502) ([angel-git](https://github.com/angel-git))
24
+
3
25
  ## [2.8.1](https://www.npmjs.com/package/@digital-ai/dot-components) (05/17/2023)
4
26
 
5
27
  [Full Changelog](https://digital-ai.github.io/dot-components/?path=/story/introduction--page/digital-ai/dot-components/compare/2.8.0...2.8.1)
@@ -54,6 +76,10 @@
54
76
 
55
77
  - D-24626: Add startEditable attribute to InlineEdit [\#1466](https://github.com/digital-ai/dot-components/pull/1466) ([jmcnally](https://github.com/jmcnally))
56
78
 
79
+ **Fixed bugs:**
80
+
81
+ - D-24807: `Demo app` - fix error when starting demo application [\#1451](https://github.com/digital-ai/dot-components/pull/1451) ([dmiletic85](https://github.com/dmiletic85))
82
+
57
83
  **Misc:**
58
84
 
59
85
  - Updates to deprecated github action `set-output` [\#1465](https://github.com/digital-ai/dot-components/pull/1465) ([CWSites](https://github.com/CWSites))
@@ -83,7 +109,6 @@
83
109
  **Fixed bugs:**
84
110
 
85
111
  - `DotTimePicker`, `DotDatePicker`: fix issues with controlled and uncontrolled states [\#1454](https://github.com/digital-ai/dot-components/pull/1454) ([dmiletic85](https://github.com/dmiletic85))
86
- - D-24807: `Demo app` - fix error when starting demo application [\#1451](https://github.com/digital-ai/dot-components/pull/1451) ([dmiletic85](https://github.com/dmiletic85))
87
112
 
88
113
  **Misc:**
89
114
 
@@ -118,7 +143,6 @@
118
143
  **Features:**
119
144
 
120
145
  - S-90954: `TimePicker` component [\#1432](https://github.com/digital-ai/dot-components/pull/1432) ([dmiletic85](https://github.com/dmiletic85))
121
- - \[Freestyle Week\] Utilize `dot-icons` package [\#1393](https://github.com/digital-ai/dot-components/pull/1393) ([CWSites](https://github.com/CWSites))
122
146
  - S-87859: Stepper component [\#1392](https://github.com/digital-ai/dot-components/pull/1392) ([nikolinadapic](https://github.com/nikolinadapic))
123
147
 
124
148
  ## [2.5.5](https://www.npmjs.com/package/@digital-ai/dot-components) (03/31/2023)
@@ -196,13 +220,16 @@
196
220
  **Fixed bugs:**
197
221
 
198
222
  - D-24235: Empty table pagination [\#1402](https://github.com/digital-ai/dot-components/pull/1402) ([ryangamble](https://github.com/ryangamble))
199
- - D-24216: A few minor app-switcher display changes [\#1400](https://github.com/digital-ai/dot-components/pull/1400) ([jmcnally](https://github.com/jmcnally))
200
223
  - Issue \#1271: Updates to `AutoComplete` sizing with `dense` and `size` props [\#1395](https://github.com/digital-ai/dot-components/pull/1395) ([CWSites](https://github.com/CWSites))
201
224
 
202
225
  ## [1.21.9](https://www.npmjs.com/package/@digital-ai/dot-components) (03/03/2023)
203
226
 
204
227
  [Full Changelog](https://digital-ai.github.io/dot-components/?path=/story/introduction--page/digital-ai/dot-components/compare/2.4.0...1.21.9)
205
228
 
229
+ **Fixed bugs:**
230
+
231
+ - D-24216: A few minor app-switcher display changes [\#1400](https://github.com/digital-ai/dot-components/pull/1400) ([jmcnally](https://github.com/jmcnally))
232
+
206
233
  **Misc:**
207
234
 
208
235
  - Setup v1 to use dot-icons library [\#1399](https://github.com/digital-ai/dot-components/pull/1399) ([CWSites](https://github.com/CWSites))
@@ -212,6 +239,10 @@
212
239
 
213
240
  [Full Changelog](https://digital-ai.github.io/dot-components/?path=/story/introduction--page/digital-ai/dot-components/compare/2.3.2...2.4.0)
214
241
 
242
+ **Features:**
243
+
244
+ - \[Freestyle Week\] Utilize `dot-icons` package [\#1393](https://github.com/digital-ai/dot-components/pull/1393) ([CWSites](https://github.com/CWSites))
245
+
215
246
  **Fixed bugs:**
216
247
 
217
248
  - \#1390: Addressing some SQ review items-Issue\#1390 [\#1391](https://github.com/digital-ai/dot-components/pull/1391) ([jmcnally](https://github.com/jmcnally))
@@ -445,10 +476,6 @@
445
476
 
446
477
  - D-22241: `DotFileListItem`: fix focus states and expose `onKeyPress` [\#1254](https://github.com/digital-ai/dot-components/pull/1254) ([dmiletic85](https://github.com/dmiletic85))
447
478
 
448
- **Misc:**
449
-
450
- - S-86694: Extract agility theme [\#1242](https://github.com/digital-ai/dot-components/pull/1242) ([CWSites](https://github.com/CWSites))
451
-
452
479
  ## [2.0.0-rc.1](https://www.npmjs.com/package/@digital-ai/dot-components) (08/31/2022)
453
480
 
454
481
  [Full Changelog](https://digital-ai.github.io/dot-components/?path=/story/introduction--page/digital-ai/dot-components/compare/1.21.1...2.0.0-rc.1)
@@ -462,6 +489,7 @@
462
489
 
463
490
  - Release Candidate Workflow [\#1251](https://github.com/digital-ai/dot-components/pull/1251) ([CWSites](https://github.com/CWSites))
464
491
  - S-85001: add support for react 18 [\#1244](https://github.com/digital-ai/dot-components/pull/1244) ([CWSites](https://github.com/CWSites))
492
+ - S-86694: Extract agility theme [\#1242](https://github.com/digital-ai/dot-components/pull/1242) ([CWSites](https://github.com/CWSites))
465
493
 
466
494
  ## [1.21.1](https://www.npmjs.com/package/@digital-ai/dot-components) (08/31/2022)
467
495
 
@@ -758,6 +786,7 @@
758
786
  - S-81949: attempting branch name instead of sha [\#1028](https://github.com/digital-ai/dot-components/pull/1028) ([CWSites](https://github.com/CWSites))
759
787
  - S-81949: simplfying wait step, extend interval to 30s [\#1027](https://github.com/digital-ai/dot-components/pull/1027) ([CWSites](https://github.com/CWSites))
760
788
  - S-81949: add release candidate workflow [\#1026](https://github.com/digital-ai/dot-components/pull/1026) ([CWSites](https://github.com/CWSites))
789
+ - S-81949: make NPM wait for other jobs to finish pre-rc [\#1019](https://github.com/digital-ai/dot-components/pull/1019) ([CWSites](https://github.com/CWSites))
761
790
 
762
791
  ## [1.9.1](https://www.npmjs.com/package/@digital-ai/dot-components) (02/17/2022)
763
792
 
@@ -918,7 +947,6 @@
918
947
 
919
948
  **Fixed bugs:**
920
949
 
921
- - D-19330: `AppToolbar` shouldn't have grey dividers [\#891](https://github.com/digital-ai/dot-components/pull/891) ([dmiletic85](https://github.com/dmiletic85))
922
950
  - D-19321: `Breadcrumbs` - Circular dependency on `useBreadcrumbsObserver` [\#882](https://github.com/digital-ai/dot-components/pull/882) ([dmiletic85](https://github.com/dmiletic85))
923
951
  - S-79458: `Sidebar` & `List` updates [\#872](https://github.com/digital-ai/dot-components/pull/872) ([CWSites](https://github.com/CWSites))
924
952
 
@@ -953,7 +981,9 @@
953
981
 
954
982
  **Fixed bugs:**
955
983
 
984
+ - D-19330: `AppToolbar` shouldn't have grey dividers [\#891](https://github.com/digital-ai/dot-components/pull/891) ([dmiletic85](https://github.com/dmiletic85))
956
985
  - D-19294: Fix broken expand/collapse for uncontrolled accordion [\#866](https://github.com/digital-ai/dot-components/pull/866) ([selsemore](https://github.com/selsemore))
986
+ - D-19250: Fix alignment of DotAccordion collapsed/expanded icons [\#859](https://github.com/digital-ai/dot-components/pull/859) ([selsemore](https://github.com/selsemore))
957
987
 
958
988
  **Misc:**
959
989
 
@@ -968,10 +998,6 @@
968
998
 
969
999
  - S-80740: Expose DotAccordion 'expanded' and 'onChange' props [\#860](https://github.com/digital-ai/dot-components/pull/860) ([selsemore](https://github.com/selsemore))
970
1000
 
971
- **Fixed bugs:**
972
-
973
- - D-19250: Fix alignment of DotAccordion collapsed/expanded icons [\#859](https://github.com/digital-ai/dot-components/pull/859) ([selsemore](https://github.com/selsemore))
974
-
975
1001
  **Misc:**
976
1002
 
977
1003
  - S-76843: Use digital.ai bot PAT for merging master \> develop [\#862](https://github.com/digital-ai/dot-components/pull/862) ([CWSites](https://github.com/CWSites))
@@ -1014,6 +1040,7 @@
1014
1040
  **Features:**
1015
1041
 
1016
1042
  - 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))
1043
+ - S-80268: `DotDynamicForm` improvements [\#821](https://github.com/digital-ai/dot-components/pull/821) ([dmiletic85](https://github.com/dmiletic85))
1017
1044
 
1018
1045
  **Fixed bugs:**
1019
1046
 
@@ -1027,7 +1054,6 @@
1027
1054
  **Features:**
1028
1055
 
1029
1056
  - S-80369: Create `ProgressButton` component [\#822](https://github.com/digital-ai/dot-components/pull/822) ([dmiletic85](https://github.com/dmiletic85))
1030
- - S-80268: `DotDynamicForm` improvements [\#821](https://github.com/digital-ai/dot-components/pull/821) ([dmiletic85](https://github.com/dmiletic85))
1031
1057
  - 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))
1032
1058
  - S-80264: Agility wrapper sandbox documentation [\#810](https://github.com/digital-ai/dot-components/pull/810) ([CWSites](https://github.com/CWSites))
1033
1059
  - S-79569: `DotTable` - ability to add classes to rows & cells [\#799](https://github.com/digital-ai/dot-components/pull/799) ([monapatel91](https://github.com/monapatel91))
@@ -1063,7 +1089,6 @@
1063
1089
  - 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))
1064
1090
  - 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))
1065
1091
  - S-80048: product wrapper demo [\#782](https://github.com/digital-ai/dot-components/pull/782) ([CWSites](https://github.com/CWSites))
1066
- - Patch release [\#780](https://github.com/digital-ai/dot-components/pull/780) ([TheKeithStewart](https://github.com/TheKeithStewart))
1067
1092
 
1068
1093
  ## [1.3.2](https://www.npmjs.com/package/@digital-ai/dot-components) (11/05/2021)
1069
1094
 
@@ -1076,6 +1101,7 @@
1076
1101
 
1077
1102
  **Misc:**
1078
1103
 
1104
+ - Patch release [\#780](https://github.com/digital-ai/dot-components/pull/780) ([TheKeithStewart](https://github.com/TheKeithStewart))
1079
1105
  - S-79985: temporarily remove react-jsonschema-form from library [\#776](https://github.com/digital-ai/dot-components/pull/776) ([TheKeithStewart](https://github.com/TheKeithStewart))
1080
1106
  - Add submitButtonProps prop to DotJsonSchemaForm component [\#775](https://github.com/digital-ai/dot-components/pull/775) ([selsemore](https://github.com/selsemore))
1081
1107
  - S-76893: Webpack 4 - update peer dependencies [\#768](https://github.com/digital-ai/dot-components/pull/768) ([CWSites](https://github.com/CWSites))
package/index.esm.js CHANGED
@@ -2415,7 +2415,7 @@ const DotDrawerFooter = ({
2415
2415
  const DotDrawer = ({
2416
2416
  anchor: _anchor = 'right',
2417
2417
  ariaLabel,
2418
- ariaRole: _ariaRole = 'presentation',
2418
+ ariaRole: _ariaRole = 'dialog',
2419
2419
  className,
2420
2420
  children,
2421
2421
  'data-testid': dataTestId,
@@ -2441,6 +2441,7 @@ const DotDrawer = ({
2441
2441
  }
2442
2442
  };
2443
2443
  const rootClasses = useStylesWithRootClass(rootClassName$U, className);
2444
+ const backdropEnabled = _variant === 'temporary' && !(ModalProps === null || ModalProps === void 0 ? void 0 : ModalProps.hideBackdrop);
2444
2445
  const headerExists = !!drawerHeaderProps;
2445
2446
  const bodyTestId = drawerBodyProps ? drawerBodyProps[`data-testid`] : 'drawer-body';
2446
2447
  return jsxs(StyledDrawer, Object.assign({
@@ -2450,6 +2451,7 @@ const DotDrawer = ({
2450
2451
  }),
2451
2452
  anchor: _anchor,
2452
2453
  "aria-label": ariaLabel,
2454
+ "aria-modal": backdropEnabled ? 'true' : 'false',
2453
2455
  classes: {
2454
2456
  root: rootClasses,
2455
2457
  paper: 'dot-drawer-paper'
@@ -6236,6 +6238,7 @@ const DotProgressButton = ({
6236
6238
  isSubmit: _isSubmit = false,
6237
6239
  onClick,
6238
6240
  size: _size = 'medium',
6241
+ startIcon,
6239
6242
  tooltip,
6240
6243
  type: _type = 'primary'
6241
6244
  }) => {
@@ -6253,6 +6256,7 @@ const DotProgressButton = ({
6253
6256
  isSubmit: _isSubmit,
6254
6257
  onClick: onClick,
6255
6258
  size: _size,
6259
+ startIcon: startIcon,
6256
6260
  tooltip: tooltip,
6257
6261
  type: _type
6258
6262
  }, {
@@ -6418,7 +6422,7 @@ const StyledSwitch = styled(Switch).withConfig({
6418
6422
  componentId: "eign2a-0"
6419
6423
  })(["", ""], ({
6420
6424
  theme
6421
- }) => css(["{&.dot-switch{span.Mui-disabled{color:", ";}.MuiSwitch-switchBase:not(.Mui-checked):not(.Mui-disabled){color:", ";}}"], theme.palette.grey[200], theme.palette.background.default));
6425
+ }) => css(["{&.dot-switch{span.Mui-disabled{color:", ";}.MuiSwitch-switchBase:not(.Mui-checked):not(.Mui-disabled){color:", ";&.Mui-focusVisible .MuiTouchRipple-root{color:", ";}}}"], theme.palette.grey[200], theme.palette.background.default, theme.palette.grey[200]));
6422
6426
 
6423
6427
  const DotSwitch = ({
6424
6428
  ariaLabel,
@@ -6578,14 +6582,29 @@ const buildAutocompleteControl = ({
6578
6582
  index
6579
6583
  }) => {
6580
6584
  const props = controlProps;
6585
+ const isFreeSolo = props.freesolo === undefined || props.freesolo;
6581
6586
  const value = getControlValue(controlName, formData) || [];
6582
6587
  const errorMessage = formData[controlName].errorMessage;
6583
6588
  const handleChangeFn = handleChange;
6589
+ const handleFreeSoloChange = event => {
6590
+ var _a;
6591
+ if (event.key !== 'Enter') return;
6592
+ const typedValue = (_a = event === null || event === void 0 ? void 0 : event.target) === null || _a === void 0 ? void 0 : _a.value;
6593
+ const currentValue = value;
6594
+ if (typedValue) {
6595
+ checkIfDuplicateItem(typedValue, currentValue);
6596
+ currentValue.push({
6597
+ title: typedValue
6598
+ });
6599
+ handleChangeFn(controlName);
6600
+ }
6601
+ };
6584
6602
  return jsx(DotAutoComplete, Object.assign({}, props, {
6585
6603
  disabled: disabled,
6586
6604
  error: !!errorMessage,
6587
6605
  helperText: errorMessage || props.helperText,
6588
6606
  onChange: handleChangeFn(controlName),
6607
+ onInputChange: isFreeSolo ? event => handleFreeSoloChange(event) : null,
6589
6608
  value: value
6590
6609
  }), index);
6591
6610
  };
@@ -6798,12 +6817,11 @@ const DotDynamicForm = ({
6798
6817
  const updateFormState = ({
6799
6818
  controlName,
6800
6819
  newValue,
6801
- formConfig,
6802
6820
  validate: _validate = true
6803
6821
  }) => {
6804
6822
  let fieldValidation = {};
6805
6823
  if (_validate && _liveValidation) {
6806
- fieldValidation = getControlValidation(controlName, newValue, formConfig);
6824
+ fieldValidation = getControlValidation(controlName, newValue, config);
6807
6825
  }
6808
6826
  setFormState(prevFormState => Object.assign(Object.assign({}, prevFormState), {
6809
6827
  data: Object.assign(Object.assign({}, prevFormState.data), {
@@ -6838,7 +6856,6 @@ const DotDynamicForm = ({
6838
6856
  const handleAutocompleteChange = controlName => (_event, value) => {
6839
6857
  updateFormState({
6840
6858
  controlName,
6841
- formConfig: config,
6842
6859
  newValue: value
6843
6860
  });
6844
6861
  };
@@ -6846,7 +6863,6 @@ const DotDynamicForm = ({
6846
6863
  const newValue = e.target.checked;
6847
6864
  updateFormState({
6848
6865
  controlName,
6849
- formConfig: config,
6850
6866
  newValue,
6851
6867
  validate: false
6852
6868
  });
@@ -6854,7 +6870,6 @@ const DotDynamicForm = ({
6854
6870
  const handleCheckboxGroupChange = controlName => (e, value) => {
6855
6871
  updateFormState({
6856
6872
  controlName,
6857
- formConfig: config,
6858
6873
  newValue: value
6859
6874
  });
6860
6875
  };
@@ -6873,7 +6888,6 @@ const DotDynamicForm = ({
6873
6888
  const newValue = e.target.value;
6874
6889
  updateFormState({
6875
6890
  controlName,
6876
- formConfig: config,
6877
6891
  newValue
6878
6892
  });
6879
6893
  };
@@ -7753,7 +7767,7 @@ const StyledStepper = styled.div.withConfig({
7753
7767
  componentId: "sc-1qka0yq-0"
7754
7768
  })(["", ""], ({
7755
7769
  theme
7756
- }) => css(["&.", "{display:flex;align-items:flex-start;padding:0;width:100%;&.left{flex-direction:row;.", "{border-left:1px solid ", ";}}&.right{flex-direction:row-reverse;.", "{border-right:1px solid ", ";}}.", "{padding:", ";&.MuiStepper-horizontal{padding:0;display:flex;flex-direction:column;}.MuiStep-root{width:315px;.dot-icon{display:flex;background:", ";border-radius:50%;color:", ";height:28px;width:28px;}.dot-typography{color:", ";}.MuiStepContent-root{border-left-color:", ";margin-bottom:", ";}&.MuiStep-horizontal{padding:", ";.dot-avatar i:before{color:", ";}.dot-avatar,.dot-icon{background:", ";}.dot-typography{color:", ";}.horizontal-step-description{color:", ";}&:hover{cursor:pointer;}&.completed{.dot-avatar i:before{color:", ";}.dot-avatar,.dot-icon{background:", ";}}&.active{background:", ";}&.error{.dot-avatar i:before{color:", ";}.dot-avatar,.dot-icon{background:", ";}}&.in-progress{.dot-avatar i:before{color:", ";}}}&.MuiStep-vertical{&.completed{.dot-typography,.dot-icon{color:", ";}}&.active{.dot-icon{background:", ";color:", ";}.step-label.dot-typography{color:", ";}.dot-typography{color:", ";}}&.error{.dot-typography{color:", ";}.dot-icon{background:", ";border:1px solid ", ";color:", ";}}}&.disabled{.dot-icon{color:", ";}.dot-typography{color:", ";}}&:last-of-type .MuiStepContent-root{border-left-color:transparent;}}}.", "{width:100%;height:calc(100vh - 78px);overflow-y:auto;&.center-content{display:flex;flex-direction:column;justify-content:center;align-items:center;text-align:center;}.step-content-container{padding:", ";}}}"], rootClassName$i, contentClassName, theme.palette.layer.n200, contentClassName, theme.palette.layer.n200, stepListClassName, theme.spacing(3), theme.palette.primary['50'], theme.palette.primary['50'], theme.palette.layer.n300, theme.palette.layer.n300, theme.spacing(1), theme.spacing(1), theme.palette.layer.n300, theme.palette.layer.n100, theme.palette.layer.n500, theme.palette.layer.n400, theme.palette.secondary['500'], theme.palette.secondary['50'], theme.palette.layer['n50'], theme.palette.error['500'], theme.palette.error['50'], theme.palette.primary['400'], theme.palette.layer.n700, theme.palette.primary['400'], theme.palette.layer.n0, theme.palette.primary['500'], theme.palette.layer.n700, theme.palette.error.main, theme.palette.layer.n0, theme.palette.error.main, theme.palette.error.main, theme.palette.primary['50'], theme.palette.layer.n300, contentClassName, theme.spacing(3, 3, 2, 3)));
7770
+ }) => css(["&.", "{display:flex;align-items:flex-start;padding:0;width:100%;&.left{flex-direction:row;.", "{border-left:1px solid ", ";}}&.right{flex-direction:row-reverse;.", "{border-right:1px solid ", ";}}.", "{padding:", ";&.MuiStepper-horizontal{padding:0;display:flex;flex-direction:column;}.MuiStep-root{width:315px;.dot-icon{display:flex;background:", ";border-radius:50%;color:", ";height:28px;width:28px;}.dot-typography{color:", ";}.MuiStepContent-root{border-left-color:", ";}&.MuiStep-horizontal{padding:", ";.dot-avatar i:before{color:", ";}.dot-avatar,.dot-icon{background:", ";}.dot-typography{color:", ";}.horizontal-step-description{color:", ";}&:hover{cursor:pointer;}&.completed{.dot-avatar i:before{color:", ";}.dot-avatar,.dot-icon{background:", ";}}&.active{background:", ";}&.error{.dot-avatar i:before{color:", ";}.dot-avatar,.dot-icon{background:", ";}}&.in-progress{.dot-avatar i:before{color:", ";}}}&.MuiStep-vertical{&.completed{.dot-typography,.dot-icon{color:", ";}}&.active{.dot-icon{background:", ";color:", ";}.step-label.dot-typography{color:", ";}.dot-typography{color:", ";}}&.error{.dot-typography{color:", ";}.dot-icon{background:", ";border:1px solid ", ";color:", ";}}}&.disabled{.dot-icon{color:", ";}.dot-typography{color:", ";}}&:last-of-type .MuiStepContent-root{border-left-color:transparent;}}}.", "{width:100%;height:calc(100vh - 78px);overflow-y:auto;&.center-content{display:flex;flex-direction:column;justify-content:center;align-items:center;text-align:center;}.step-content-container{padding:", ";}}}"], rootClassName$i, contentClassName, theme.palette.layer.n200, contentClassName, theme.palette.layer.n200, stepListClassName, theme.spacing(3), theme.palette.primary['50'], theme.palette.primary['50'], theme.palette.layer.n300, theme.palette.layer.n300, theme.spacing(1), theme.palette.layer.n300, theme.palette.layer.n100, theme.palette.layer.n500, theme.palette.layer.n400, theme.palette.secondary['500'], theme.palette.secondary['50'], theme.palette.layer['n50'], theme.palette.error['500'], theme.palette.error['50'], theme.palette.primary['400'], theme.palette.layer.n700, theme.palette.primary['400'], theme.palette.layer.n0, theme.palette.primary['500'], theme.palette.layer.n700, theme.palette.error.main, theme.palette.layer.n0, theme.palette.error.main, theme.palette.error.main, theme.palette.primary['50'], theme.palette.layer.n300, contentClassName, theme.spacing(3, 3, 2, 3)));
7757
7771
  const StepContentWrapper = styled.div.withConfig({
7758
7772
  displayName: "Stepperstyles__StepContentWrapper",
7759
7773
  componentId: "sc-1qka0yq-1"
@@ -7801,6 +7815,7 @@ const DotStepper = ({
7801
7815
  onCancel,
7802
7816
  onSubmit,
7803
7817
  orientation: _orientation = 'vertical',
7818
+ disableUncompletedStepNav: _disableUncompletedStepNav = false,
7804
7819
  steps,
7805
7820
  stepsPosition: _stepsPosition = 'left',
7806
7821
  submitButtonText: _submitButtonText = 'Complete'
@@ -7876,6 +7891,12 @@ const DotStepper = ({
7876
7891
  };
7877
7892
  const navigateToStep = id => {
7878
7893
  if (id !== currentStep) {
7894
+ if (_disableUncompletedStepNav) {
7895
+ const previousStep = steps.find(step => step.id === id - 1);
7896
+ if (previousStep && !previousStep.completed) {
7897
+ return;
7898
+ }
7899
+ }
7879
7900
  const stepSelected = steps.find(step => step.id === id);
7880
7901
  stepSelected.onClick && stepSelected.onClick();
7881
7902
  setActiveStep(id);
@@ -8430,7 +8451,7 @@ const StyledTableHeaderCell = styled(TableCell).withConfig({
8430
8451
  componentId: "nko9j-0"
8431
8452
  })(["", ""], ({
8432
8453
  theme
8433
- }) => css(["&.", "{&.MuiTableCell-alignCenter > span.MuiTableSortLabel-root{padding-left:26px;}.dot-cell-typography{font-family:", ";}}"], rootClassName$b, theme.typography.h4.fontFamily));
8454
+ }) => css(["&.", "{&.MuiTableCell-alignCenter > span.MuiTableSortLabel-root{padding-left:26px;}> span.MuiTableSortLabel-root.Mui-focusVisible{.dot-cell-typography{color:", ";text-decoration:underline;}}.dot-cell-typography{font-family:", ";}}"], rootClassName$b, theme.palette.primary.main, theme.typography.h4.fontFamily));
8434
8455
 
8435
8456
  /**
8436
8457
  * A wrapper component around the TableCell component from @material-ui. This component should only
package/index.umd.js CHANGED
@@ -2714,7 +2714,7 @@
2714
2714
  anchor = _b === void 0 ? 'right' : _b,
2715
2715
  ariaLabel = _a.ariaLabel,
2716
2716
  _c = _a.ariaRole,
2717
- ariaRole = _c === void 0 ? 'presentation' : _c,
2717
+ ariaRole = _c === void 0 ? 'dialog' : _c,
2718
2718
  className = _a.className,
2719
2719
  children = _a.children,
2720
2720
  dataTestId = _a["data-testid"],
@@ -2741,6 +2741,7 @@
2741
2741
  }
2742
2742
  };
2743
2743
  var rootClasses = useStylesWithRootClass(rootClassName$U, className);
2744
+ var backdropEnabled = variant === 'temporary' && !(ModalProps === null || ModalProps === void 0 ? void 0 : ModalProps.hideBackdrop);
2744
2745
  var headerExists = !!drawerHeaderProps;
2745
2746
  var bodyTestId = drawerBodyProps ? drawerBodyProps["data-testid"] : 'drawer-body';
2746
2747
  return jsxRuntime.jsxs(StyledDrawer, __assign({
@@ -2750,6 +2751,7 @@
2750
2751
  }),
2751
2752
  anchor: anchor,
2752
2753
  "aria-label": ariaLabel,
2754
+ "aria-modal": backdropEnabled ? 'true' : 'false',
2753
2755
  classes: {
2754
2756
  root: rootClasses,
2755
2757
  paper: 'dot-drawer-paper'
@@ -6792,6 +6794,7 @@
6792
6794
  onClick = _a.onClick,
6793
6795
  _g = _a.size,
6794
6796
  size = _g === void 0 ? 'medium' : _g,
6797
+ startIcon = _a.startIcon,
6795
6798
  tooltip = _a.tooltip,
6796
6799
  _h = _a.type,
6797
6800
  type = _h === void 0 ? 'primary' : _h;
@@ -6809,6 +6812,7 @@
6809
6812
  isSubmit: isSubmit,
6810
6813
  onClick: onClick,
6811
6814
  size: size,
6815
+ startIcon: startIcon,
6812
6816
  tooltip: tooltip,
6813
6817
  type: type
6814
6818
  }, {
@@ -6981,7 +6985,7 @@
6981
6985
  componentId: "eign2a-0"
6982
6986
  })(templateObject_2$p || (templateObject_2$p = __makeTemplateObject(["\n ", "\n"], ["\n ", "\n"])), function (_a) {
6983
6987
  var theme = _a.theme;
6984
- return styled.css(templateObject_1$q || (templateObject_1$q = __makeTemplateObject(["{\n &.dot-switch {\n span.Mui-disabled {\n color: ", ";\n }\n\n .MuiSwitch-switchBase\n :not(.Mui-checked)\n :not(.Mui-disabled) {\n color: ", ";\n }\n }\n "], ["{\n &.dot-switch {\n span.Mui-disabled {\n color: ", ";\n }\n\n .MuiSwitch-switchBase\n :not(.Mui-checked)\n :not(.Mui-disabled) {\n color: ", ";\n }\n }\n "])), theme.palette.grey[200], theme.palette.background.default);
6988
+ return styled.css(templateObject_1$q || (templateObject_1$q = __makeTemplateObject(["{\n &.dot-switch {\n span.Mui-disabled {\n color: ", ";\n }\n\n .MuiSwitch-switchBase\n :not(.Mui-checked)\n :not(.Mui-disabled) {\n color: ", ";\n\n /* adjusted for a11y */\n &.Mui-focusVisible .MuiTouchRipple-root {\n color: ", ";\n }\n }\n }\n "], ["{\n &.dot-switch {\n span.Mui-disabled {\n color: ", ";\n }\n\n .MuiSwitch-switchBase\n :not(.Mui-checked)\n :not(.Mui-disabled) {\n color: ", ";\n\n /* adjusted for a11y */\n &.Mui-focusVisible .MuiTouchRipple-root {\n color: ", ";\n }\n }\n }\n "])), theme.palette.grey[200], theme.palette.background.default, theme.palette.grey[200]);
6985
6989
  });
6986
6990
  var templateObject_1$q, templateObject_2$p;
6987
6991
 
@@ -7137,14 +7141,31 @@
7137
7141
  handleChange = _a.handleChange,
7138
7142
  index = _a.index;
7139
7143
  var props = controlProps;
7144
+ var isFreeSolo = props.freesolo === undefined || props.freesolo;
7140
7145
  var value = getControlValue(controlName, formData) || [];
7141
7146
  var errorMessage = formData[controlName].errorMessage;
7142
7147
  var handleChangeFn = handleChange;
7148
+ var handleFreeSoloChange = function handleFreeSoloChange(event) {
7149
+ var _a;
7150
+ if (event.key !== 'Enter') return;
7151
+ var typedValue = (_a = event === null || event === void 0 ? void 0 : event.target) === null || _a === void 0 ? void 0 : _a.value;
7152
+ var currentValue = value;
7153
+ if (typedValue) {
7154
+ checkIfDuplicateItem(typedValue, currentValue);
7155
+ currentValue.push({
7156
+ title: typedValue
7157
+ });
7158
+ handleChangeFn(controlName);
7159
+ }
7160
+ };
7143
7161
  return jsxRuntime.jsx(DotAutoComplete, __assign({}, props, {
7144
7162
  disabled: disabled,
7145
7163
  error: !!errorMessage,
7146
7164
  helperText: errorMessage || props.helperText,
7147
7165
  onChange: handleChangeFn(controlName),
7166
+ onInputChange: isFreeSolo ? function (event) {
7167
+ return handleFreeSoloChange(event);
7168
+ } : null,
7148
7169
  value: value
7149
7170
  }), index);
7150
7171
  };
@@ -7348,12 +7369,11 @@
7348
7369
  var updateFormState = function updateFormState(_a) {
7349
7370
  var controlName = _a.controlName,
7350
7371
  newValue = _a.newValue,
7351
- formConfig = _a.formConfig,
7352
7372
  _b = _a.validate,
7353
7373
  validate = _b === void 0 ? true : _b;
7354
7374
  var fieldValidation = {};
7355
7375
  if (validate && liveValidation) {
7356
- fieldValidation = getControlValidation(controlName, newValue, formConfig);
7376
+ fieldValidation = getControlValidation(controlName, newValue, config);
7357
7377
  }
7358
7378
  setFormState(function (prevFormState) {
7359
7379
  var _a;
@@ -7392,7 +7412,6 @@
7392
7412
  return function (_event, value) {
7393
7413
  updateFormState({
7394
7414
  controlName: controlName,
7395
- formConfig: config,
7396
7415
  newValue: value
7397
7416
  });
7398
7417
  };
@@ -7402,7 +7421,6 @@
7402
7421
  var newValue = e.target.checked;
7403
7422
  updateFormState({
7404
7423
  controlName: controlName,
7405
- formConfig: config,
7406
7424
  newValue: newValue,
7407
7425
  validate: false
7408
7426
  });
@@ -7412,7 +7430,6 @@
7412
7430
  return function (e, value) {
7413
7431
  updateFormState({
7414
7432
  controlName: controlName,
7415
- formConfig: config,
7416
7433
  newValue: value
7417
7434
  });
7418
7435
  };
@@ -7433,7 +7450,6 @@
7433
7450
  var newValue = e.target.value;
7434
7451
  updateFormState({
7435
7452
  controlName: controlName,
7436
- formConfig: config,
7437
7453
  newValue: newValue
7438
7454
  });
7439
7455
  };
@@ -8429,7 +8445,7 @@
8429
8445
  componentId: "sc-1qka0yq-0"
8430
8446
  })(templateObject_2$h || (templateObject_2$h = __makeTemplateObject(["\n ", "\n"], ["\n ", "\n"])), function (_a) {
8431
8447
  var theme = _a.theme;
8432
- return styled.css(templateObject_1$i || (templateObject_1$i = __makeTemplateObject(["\n &.", " {\n display: flex;\n align-items: flex-start;\n padding: 0;\n width: 100%;\n\n &.left {\n flex-direction: row;\n .", " {\n border-left: 1px solid ", ";\n }\n }\n\n &.right {\n flex-direction: row-reverse;\n .", " {\n border-right: 1px solid ", ";\n }\n }\n\n .", " {\n padding: ", ";\n\n &.MuiStepper-horizontal {\n padding: 0;\n display: flex;\n flex-direction: column;\n }\n\n .MuiStep-root {\n width: 315px;\n\n .dot-icon {\n display: flex;\n background: ", ";\n border-radius: 50%;\n color: ", ";\n height: 28px;\n width: 28px;\n }\n\n .dot-typography {\n color: ", ";\n }\n\n .MuiStepContent-root {\n border-left-color: ", ";\n margin-bottom: ", ";\n }\n\n &.MuiStep-horizontal {\n padding: ", ";\n\n .dot-avatar i:before {\n color: ", ";\n }\n .dot-avatar,\n .dot-icon {\n background: ", ";\n }\n .dot-typography {\n color: ", ";\n }\n .horizontal-step-description {\n color: ", ";\n }\n\n &:hover {\n cursor: pointer;\n }\n\n &.completed {\n .dot-avatar i:before {\n color: ", ";\n }\n .dot-avatar,\n .dot-icon {\n background: ", ";\n }\n }\n\n &.active {\n background: ", ";\n }\n\n &.error {\n .dot-avatar i:before {\n color: ", ";\n }\n .dot-avatar,\n .dot-icon {\n background: ", ";\n }\n }\n\n &.in-progress {\n .dot-avatar i:before {\n color: ", ";\n }\n }\n }\n\n &.MuiStep-vertical {\n &.completed {\n .dot-typography,\n .dot-icon {\n color: ", ";\n }\n }\n\n &.active {\n .dot-icon {\n background: ", ";\n color: ", ";\n }\n .step-label.dot-typography {\n color: ", ";\n }\n .dot-typography {\n color: ", ";\n }\n }\n\n &.error {\n .dot-typography {\n color: ", ";\n }\n\n .dot-icon {\n background: ", ";\n border: 1px solid ", ";\n color: ", ";\n }\n }\n }\n\n &.disabled {\n .dot-icon {\n color: ", ";\n }\n .dot-typography {\n color: ", ";\n }\n }\n\n &:last-of-type .MuiStepContent-root {\n border-left-color: transparent;\n }\n }\n }\n\n .", " {\n width: 100%;\n height: calc(100vh - 78px);\n overflow-y: auto;\n\n &.center-content {\n display: flex;\n flex-direction: column;\n justify-content: center;\n align-items: center;\n text-align: center;\n }\n\n .step-content-container {\n padding: ", ";\n }\n }\n }\n "], ["\n &.", " {\n display: flex;\n align-items: flex-start;\n padding: 0;\n width: 100%;\n\n &.left {\n flex-direction: row;\n .", " {\n border-left: 1px solid ", ";\n }\n }\n\n &.right {\n flex-direction: row-reverse;\n .", " {\n border-right: 1px solid ", ";\n }\n }\n\n .", " {\n padding: ", ";\n\n &.MuiStepper-horizontal {\n padding: 0;\n display: flex;\n flex-direction: column;\n }\n\n .MuiStep-root {\n width: 315px;\n\n .dot-icon {\n display: flex;\n background: ", ";\n border-radius: 50%;\n color: ", ";\n height: 28px;\n width: 28px;\n }\n\n .dot-typography {\n color: ", ";\n }\n\n .MuiStepContent-root {\n border-left-color: ", ";\n margin-bottom: ", ";\n }\n\n &.MuiStep-horizontal {\n padding: ", ";\n\n .dot-avatar i:before {\n color: ", ";\n }\n .dot-avatar,\n .dot-icon {\n background: ", ";\n }\n .dot-typography {\n color: ", ";\n }\n .horizontal-step-description {\n color: ", ";\n }\n\n &:hover {\n cursor: pointer;\n }\n\n &.completed {\n .dot-avatar i:before {\n color: ", ";\n }\n .dot-avatar,\n .dot-icon {\n background: ", ";\n }\n }\n\n &.active {\n background: ", ";\n }\n\n &.error {\n .dot-avatar i:before {\n color: ", ";\n }\n .dot-avatar,\n .dot-icon {\n background: ", ";\n }\n }\n\n &.in-progress {\n .dot-avatar i:before {\n color: ", ";\n }\n }\n }\n\n &.MuiStep-vertical {\n &.completed {\n .dot-typography,\n .dot-icon {\n color: ", ";\n }\n }\n\n &.active {\n .dot-icon {\n background: ", ";\n color: ", ";\n }\n .step-label.dot-typography {\n color: ", ";\n }\n .dot-typography {\n color: ", ";\n }\n }\n\n &.error {\n .dot-typography {\n color: ", ";\n }\n\n .dot-icon {\n background: ", ";\n border: 1px solid ", ";\n color: ", ";\n }\n }\n }\n\n &.disabled {\n .dot-icon {\n color: ", ";\n }\n .dot-typography {\n color: ", ";\n }\n }\n\n &:last-of-type .MuiStepContent-root {\n border-left-color: transparent;\n }\n }\n }\n\n .", " {\n width: 100%;\n height: calc(100vh - 78px);\n overflow-y: auto;\n\n &.center-content {\n display: flex;\n flex-direction: column;\n justify-content: center;\n align-items: center;\n text-align: center;\n }\n\n .step-content-container {\n padding: ", ";\n }\n }\n }\n "])), rootClassName$i, contentClassName, theme.palette.layer.n200, contentClassName, theme.palette.layer.n200, stepListClassName, theme.spacing(3), theme.palette.primary['50'], theme.palette.primary['50'], theme.palette.layer.n300, theme.palette.layer.n300, theme.spacing(1), theme.spacing(1), theme.palette.layer.n300, theme.palette.layer.n100, theme.palette.layer.n500, theme.palette.layer.n400, theme.palette.secondary['500'], theme.palette.secondary['50'], theme.palette.layer['n50'], theme.palette.error['500'], theme.palette.error['50'], theme.palette.primary['400'], theme.palette.layer.n700, theme.palette.primary['400'], theme.palette.layer.n0, theme.palette.primary['500'], theme.palette.layer.n700, theme.palette.error.main, theme.palette.layer.n0, theme.palette.error.main, theme.palette.error.main, theme.palette.primary['50'], theme.palette.layer.n300, contentClassName, theme.spacing(3, 3, 2, 3));
8448
+ return styled.css(templateObject_1$i || (templateObject_1$i = __makeTemplateObject(["\n &.", " {\n display: flex;\n align-items: flex-start;\n padding: 0;\n width: 100%;\n\n &.left {\n flex-direction: row;\n .", " {\n border-left: 1px solid ", ";\n }\n }\n\n &.right {\n flex-direction: row-reverse;\n .", " {\n border-right: 1px solid ", ";\n }\n }\n\n .", " {\n padding: ", ";\n\n &.MuiStepper-horizontal {\n padding: 0;\n display: flex;\n flex-direction: column;\n }\n\n .MuiStep-root {\n width: 315px;\n\n .dot-icon {\n display: flex;\n background: ", ";\n border-radius: 50%;\n color: ", ";\n height: 28px;\n width: 28px;\n }\n\n .dot-typography {\n color: ", ";\n }\n\n .MuiStepContent-root {\n border-left-color: ", ";\n }\n\n &.MuiStep-horizontal {\n padding: ", ";\n\n .dot-avatar i:before {\n color: ", ";\n }\n .dot-avatar,\n .dot-icon {\n background: ", ";\n }\n .dot-typography {\n color: ", ";\n }\n .horizontal-step-description {\n color: ", ";\n }\n\n &:hover {\n cursor: pointer;\n }\n\n &.completed {\n .dot-avatar i:before {\n color: ", ";\n }\n .dot-avatar,\n .dot-icon {\n background: ", ";\n }\n }\n\n &.active {\n background: ", ";\n }\n\n &.error {\n .dot-avatar i:before {\n color: ", ";\n }\n .dot-avatar,\n .dot-icon {\n background: ", ";\n }\n }\n\n &.in-progress {\n .dot-avatar i:before {\n color: ", ";\n }\n }\n }\n\n &.MuiStep-vertical {\n &.completed {\n .dot-typography,\n .dot-icon {\n color: ", ";\n }\n }\n\n &.active {\n .dot-icon {\n background: ", ";\n color: ", ";\n }\n .step-label.dot-typography {\n color: ", ";\n }\n .dot-typography {\n color: ", ";\n }\n }\n\n &.error {\n .dot-typography {\n color: ", ";\n }\n\n .dot-icon {\n background: ", ";\n border: 1px solid ", ";\n color: ", ";\n }\n }\n }\n\n &.disabled {\n .dot-icon {\n color: ", ";\n }\n .dot-typography {\n color: ", ";\n }\n }\n\n &:last-of-type .MuiStepContent-root {\n border-left-color: transparent;\n }\n }\n }\n\n .", " {\n width: 100%;\n height: calc(100vh - 78px);\n overflow-y: auto;\n\n &.center-content {\n display: flex;\n flex-direction: column;\n justify-content: center;\n align-items: center;\n text-align: center;\n }\n\n .step-content-container {\n padding: ", ";\n }\n }\n }\n "], ["\n &.", " {\n display: flex;\n align-items: flex-start;\n padding: 0;\n width: 100%;\n\n &.left {\n flex-direction: row;\n .", " {\n border-left: 1px solid ", ";\n }\n }\n\n &.right {\n flex-direction: row-reverse;\n .", " {\n border-right: 1px solid ", ";\n }\n }\n\n .", " {\n padding: ", ";\n\n &.MuiStepper-horizontal {\n padding: 0;\n display: flex;\n flex-direction: column;\n }\n\n .MuiStep-root {\n width: 315px;\n\n .dot-icon {\n display: flex;\n background: ", ";\n border-radius: 50%;\n color: ", ";\n height: 28px;\n width: 28px;\n }\n\n .dot-typography {\n color: ", ";\n }\n\n .MuiStepContent-root {\n border-left-color: ", ";\n }\n\n &.MuiStep-horizontal {\n padding: ", ";\n\n .dot-avatar i:before {\n color: ", ";\n }\n .dot-avatar,\n .dot-icon {\n background: ", ";\n }\n .dot-typography {\n color: ", ";\n }\n .horizontal-step-description {\n color: ", ";\n }\n\n &:hover {\n cursor: pointer;\n }\n\n &.completed {\n .dot-avatar i:before {\n color: ", ";\n }\n .dot-avatar,\n .dot-icon {\n background: ", ";\n }\n }\n\n &.active {\n background: ", ";\n }\n\n &.error {\n .dot-avatar i:before {\n color: ", ";\n }\n .dot-avatar,\n .dot-icon {\n background: ", ";\n }\n }\n\n &.in-progress {\n .dot-avatar i:before {\n color: ", ";\n }\n }\n }\n\n &.MuiStep-vertical {\n &.completed {\n .dot-typography,\n .dot-icon {\n color: ", ";\n }\n }\n\n &.active {\n .dot-icon {\n background: ", ";\n color: ", ";\n }\n .step-label.dot-typography {\n color: ", ";\n }\n .dot-typography {\n color: ", ";\n }\n }\n\n &.error {\n .dot-typography {\n color: ", ";\n }\n\n .dot-icon {\n background: ", ";\n border: 1px solid ", ";\n color: ", ";\n }\n }\n }\n\n &.disabled {\n .dot-icon {\n color: ", ";\n }\n .dot-typography {\n color: ", ";\n }\n }\n\n &:last-of-type .MuiStepContent-root {\n border-left-color: transparent;\n }\n }\n }\n\n .", " {\n width: 100%;\n height: calc(100vh - 78px);\n overflow-y: auto;\n\n &.center-content {\n display: flex;\n flex-direction: column;\n justify-content: center;\n align-items: center;\n text-align: center;\n }\n\n .step-content-container {\n padding: ", ";\n }\n }\n }\n "])), rootClassName$i, contentClassName, theme.palette.layer.n200, contentClassName, theme.palette.layer.n200, stepListClassName, theme.spacing(3), theme.palette.primary['50'], theme.palette.primary['50'], theme.palette.layer.n300, theme.palette.layer.n300, theme.spacing(1), theme.palette.layer.n300, theme.palette.layer.n100, theme.palette.layer.n500, theme.palette.layer.n400, theme.palette.secondary['500'], theme.palette.secondary['50'], theme.palette.layer['n50'], theme.palette.error['500'], theme.palette.error['50'], theme.palette.primary['400'], theme.palette.layer.n700, theme.palette.primary['400'], theme.palette.layer.n0, theme.palette.primary['500'], theme.palette.layer.n700, theme.palette.error.main, theme.palette.layer.n0, theme.palette.error.main, theme.palette.error.main, theme.palette.primary['50'], theme.palette.layer.n300, contentClassName, theme.spacing(3, 3, 2, 3));
8433
8449
  });
8434
8450
  var StepContentWrapper = styled__default["default"].div.withConfig({
8435
8451
  displayName: "Stepperstyles__StepContentWrapper",
@@ -8485,17 +8501,19 @@
8485
8501
  onSubmit = _a.onSubmit,
8486
8502
  _e = _a.orientation,
8487
8503
  orientation = _e === void 0 ? 'vertical' : _e,
8504
+ _f = _a.disableUncompletedStepNav,
8505
+ disableUncompletedStepNav = _f === void 0 ? false : _f,
8488
8506
  steps = _a.steps,
8489
- _f = _a.stepsPosition,
8490
- stepsPosition = _f === void 0 ? 'left' : _f,
8491
- _g = _a.submitButtonText,
8492
- submitButtonText = _g === void 0 ? 'Complete' : _g;
8493
- var _h = React.useState(activeStep),
8494
- currentStep = _h[0],
8495
- setActiveStep = _h[1];
8496
- var _j = React.useState(false),
8497
- isStickyBottom = _j[0],
8498
- setIsStickyBottom = _j[1];
8507
+ _g = _a.stepsPosition,
8508
+ stepsPosition = _g === void 0 ? 'left' : _g,
8509
+ _h = _a.submitButtonText,
8510
+ submitButtonText = _h === void 0 ? 'Complete' : _h;
8511
+ var _j = React.useState(activeStep),
8512
+ currentStep = _j[0],
8513
+ setActiveStep = _j[1];
8514
+ var _k = React.useState(false),
8515
+ isStickyBottom = _k[0],
8516
+ setIsStickyBottom = _k[1];
8499
8517
  var actionsRef = React.useRef(null);
8500
8518
  var stepperContentRef = React.useRef(null);
8501
8519
  var isHorizontal = orientation === 'horizontal';
@@ -8572,6 +8590,14 @@
8572
8590
  };
8573
8591
  var navigateToStep = function navigateToStep(id) {
8574
8592
  if (id !== currentStep) {
8593
+ if (disableUncompletedStepNav) {
8594
+ var previousStep = steps.find(function (step) {
8595
+ return step.id === id - 1;
8596
+ });
8597
+ if (previousStep && !previousStep.completed) {
8598
+ return;
8599
+ }
8600
+ }
8575
8601
  var stepSelected = steps.find(function (step) {
8576
8602
  return step.id === id;
8577
8603
  });
@@ -9157,7 +9183,7 @@
9157
9183
  componentId: "nko9j-0"
9158
9184
  })(templateObject_2$a || (templateObject_2$a = __makeTemplateObject(["\n ", "\n"], ["\n ", "\n"])), function (_a) {
9159
9185
  var theme = _a.theme;
9160
- return styled.css(templateObject_1$b || (templateObject_1$b = __makeTemplateObject(["\n &.", " {\n &.MuiTableCell-alignCenter > span.MuiTableSortLabel-root {\n padding-left: 26px;\n }\n\n .dot-cell-typography {\n font-family: ", ";\n }\n }\n "], ["\n &.", " {\n &.MuiTableCell-alignCenter > span.MuiTableSortLabel-root {\n padding-left: 26px;\n }\n\n .dot-cell-typography {\n font-family: ", ";\n }\n }\n "])), rootClassName$b, theme.typography.h4.fontFamily);
9186
+ return styled.css(templateObject_1$b || (templateObject_1$b = __makeTemplateObject(["\n &.", " {\n &.MuiTableCell-alignCenter > span.MuiTableSortLabel-root {\n padding-left: 26px;\n }\n\n > span.MuiTableSortLabel-root.Mui-focusVisible {\n .dot-cell-typography {\n color: ", ";\n text-decoration: underline;\n }\n }\n\n .dot-cell-typography {\n font-family: ", ";\n }\n }\n "], ["\n &.", " {\n &.MuiTableCell-alignCenter > span.MuiTableSortLabel-root {\n padding-left: 26px;\n }\n\n > span.MuiTableSortLabel-root.Mui-focusVisible {\n .dot-cell-typography {\n color: ", ";\n text-decoration: underline;\n }\n }\n\n .dot-cell-typography {\n font-family: ", ";\n }\n }\n "])), rootClassName$b, theme.palette.primary.main, theme.typography.h4.fontFamily);
9161
9187
  });
9162
9188
  var templateObject_1$b, templateObject_2$a;
9163
9189
 
@@ -61,7 +61,7 @@ export interface DynamicFormValidation {
61
61
  minLength?: Length;
62
62
  }
63
63
  export interface DynamicFormStateItem {
64
- errorMessage: string;
64
+ errorMessage: string | null;
65
65
  hidden?: ControlCondition;
66
66
  isTouched: boolean;
67
67
  isValid: boolean;
@@ -76,7 +76,6 @@ export interface DynamicFormStateData {
76
76
  }
77
77
  export interface FormStateUpdateArgs {
78
78
  controlName: string;
79
- formConfig: DynamicFormConfig;
80
79
  newValue: unknown;
81
80
  validate?: boolean;
82
81
  }
@@ -0,0 +1,22 @@
1
+ import { DynamicFormState } from './models';
2
+ export declare const sampleFormTestData: {
3
+ customUserType: string;
4
+ firstName: string;
5
+ isAccountActive: boolean;
6
+ lastName: string;
7
+ gender: string;
8
+ hasVehicle: string;
9
+ interests: {
10
+ title: string;
11
+ }[];
12
+ password: string;
13
+ receive: {
14
+ label: string;
15
+ value: string;
16
+ }[];
17
+ terms: boolean;
18
+ userType: string;
19
+ username: string;
20
+ vehicleModel: string;
21
+ };
22
+ export declare const getSampleFormState: () => DynamicFormState;
@@ -5,4 +5,4 @@ export interface ProgressButtonProps extends ButtonProps {
5
5
  /** Is spinner displayed */
6
6
  isLoading?: boolean;
7
7
  }
8
- export declare const DotProgressButton: ({ ariaLabel, children, className, "data-testid": dataTestId, disabled, disableRipple, fullWidth, isLoading, isSubmit, onClick, size, tooltip, type, }: ProgressButtonProps) => JSX.Element;
8
+ export declare const DotProgressButton: ({ ariaLabel, children, className, "data-testid": dataTestId, disabled, disableRipple, fullWidth, isLoading, isSubmit, onClick, size, startIcon, tooltip, type, }: ProgressButtonProps) => JSX.Element;
@@ -1,5 +1,5 @@
1
1
  import { ComponentMeta, Story } from '@storybook/react';
2
2
  import { ProgressButtonProps } from './ProgressButton';
3
- declare const _default: ComponentMeta<({ ariaLabel, children, className, "data-testid": dataTestId, disabled, disableRipple, fullWidth, isLoading, isSubmit, onClick, size, tooltip, type, }: ProgressButtonProps) => JSX.Element>;
3
+ declare const _default: ComponentMeta<({ ariaLabel, children, className, "data-testid": dataTestId, disabled, disableRipple, fullWidth, isLoading, isSubmit, onClick, size, startIcon, tooltip, type, }: ProgressButtonProps) => JSX.Element>;
4
4
  export default _default;
5
5
  export declare const Default: Story<ProgressButtonProps>;
@@ -34,6 +34,8 @@ export interface StepProps extends CommonProps {
34
34
  export interface StepperProps extends CommonProps {
35
35
  /** determines the `id` of the step which is active */
36
36
  activeStep?: number;
37
+ /** if set to `true`, clicking on a step is only allowed if the previous step is completed **/
38
+ disableUncompletedStepNav: boolean;
37
39
  /** final content displayed after the last step is completed */
38
40
  finalContent?: ReactNode;
39
41
  /** initial content displayed before any step is active, ie when `activeStep` is 0 */
@@ -57,4 +59,4 @@ export interface StepperProps extends CommonProps {
57
59
  /** if passed, will overwrite the default "submit" button text */
58
60
  submitButtonText?: string;
59
61
  }
60
- export declare const DotStepper: ({ activeStep, ariaLabel, className, "data-testid": dataTestId, finalContent, initialContent, nextButtonText, nextStepDisabled, onBack, onCancel, onSubmit, orientation, steps, stepsPosition, submitButtonText, }: StepperProps) => JSX.Element;
62
+ export declare const DotStepper: ({ activeStep, ariaLabel, className, "data-testid": dataTestId, finalContent, initialContent, nextButtonText, nextStepDisabled, onBack, onCancel, onSubmit, orientation, disableUncompletedStepNav, steps, stepsPosition, submitButtonText, }: StepperProps) => JSX.Element;
@@ -1,6 +1,6 @@
1
1
  import { ComponentMeta, Story } from '@storybook/react';
2
2
  import { StepperProps } from './Stepper';
3
- declare const _default: ComponentMeta<({ activeStep, ariaLabel, className, "data-testid": dataTestId, finalContent, initialContent, nextButtonText, nextStepDisabled, onBack, onCancel, onSubmit, orientation, steps, stepsPosition, submitButtonText, }: StepperProps) => JSX.Element>;
3
+ declare const _default: ComponentMeta<({ activeStep, ariaLabel, className, "data-testid": dataTestId, finalContent, initialContent, nextButtonText, nextStepDisabled, onBack, onCancel, onSubmit, orientation, disableUncompletedStepNav, steps, stepsPosition, submitButtonText, }: StepperProps) => JSX.Element>;
4
4
  export default _default;
5
5
  export declare const Default: Story<StepperProps>;
6
6
  export declare const WithStepDescription: Story<StepperProps>;
@@ -23,6 +23,12 @@ export declare const demoSteps: ({
23
23
  halfWidthContent?: undefined;
24
24
  inProgress?: undefined;
25
25
  })[];
26
+ export declare const demoStepsUncompleted: {
27
+ content: string;
28
+ completed: boolean;
29
+ id: number;
30
+ label: string;
31
+ }[];
26
32
  export declare const withErrorStep: ({
27
33
  content: string;
28
34
  completed: boolean;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@digital-ai/dot-components",
3
- "version": "2.8.1",
3
+ "version": "2.8.2",
4
4
  "private": false,
5
5
  "license": "SEE LICENSE IN <LICENSE.md>",
6
6
  "contributors": [
@@ -1,2 +0,0 @@
1
- import { DynamicFormState } from './models';
2
- export declare const getSampleFormState: () => DynamicFormState;