@qualtrics/ui-react 2.27.0 → 2.29.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (96) hide show
  1. package/CHANGELOG.md +23 -0
  2. package/dist/__shared/cjs/{index-88aa3bce.js → index-c2d2f188.js} +707 -451
  3. package/dist/__shared/cjs/{index-e6893573.js → index-c9e48360.js} +3 -3
  4. package/dist/components/Accordion/Accordion2.js +3 -3
  5. package/dist/components/Button/Button.js +3 -3
  6. package/dist/components/ButtonGroup/ButtonGroup2.js +3 -3
  7. package/dist/components/Checkbox/Checkbox.js +54 -10
  8. package/dist/components/Checkbox/Checkbox2.js +3 -3
  9. package/dist/components/Checkbox/VisualCheckbox2.js +3 -3
  10. package/dist/components/ColorPicker/ColorPicker2.js +3 -3
  11. package/dist/components/Combobox/Combobox2.js +3 -3
  12. package/dist/components/ConfigPane/ConfigPane2.js +3 -3
  13. package/dist/components/Divider/Divider2.js +3 -3
  14. package/dist/components/Dropdown/Dropdown.js +59 -7
  15. package/dist/components/Dropdown/Dropdown2.js +3 -3
  16. package/dist/components/FilePicker/FilePicker2.js +3 -3
  17. package/dist/components/FormField/Caption.js +3 -3
  18. package/dist/components/FormField/FormField2.js +3 -3
  19. package/dist/components/FullScreenTakeover/FullScreenTakeover2.js +3 -3
  20. package/dist/components/IconButton/IconButton2.js +3 -3
  21. package/dist/components/InlineInput/InlineInput2.js +3 -3
  22. package/dist/components/Input/Input2.js +3 -3
  23. package/dist/components/InputGroup/InputGroup2.js +3 -3
  24. package/dist/components/Label/Label2.js +3 -3
  25. package/dist/components/Link/Link2.js +3 -3
  26. package/dist/components/LoadingSpinner/LoadingSpinner2.js +3 -3
  27. package/dist/components/LogicEditor/ConditionSet.js +3 -4
  28. package/dist/components/LogicEditor/Controls.js +66 -48
  29. package/dist/components/LogicEditor/LogicEditor.js +34 -8
  30. package/dist/components/LogicEditor/LogicEditor2.js +3 -3
  31. package/dist/components/LogicEditor/utils.js +4 -1
  32. package/dist/components/Modal/Modal2.js +3 -3
  33. package/dist/components/NewMenu/NewMenu.js +3 -3
  34. package/dist/components/NumberStepper/NumberStepper2.js +3 -3
  35. package/dist/components/PageLayout/PageLayout.js +3 -3
  36. package/dist/components/Pagination/Pagination2.js +3 -3
  37. package/dist/components/Popover/Popover2.js +3 -3
  38. package/dist/components/QuickSearch/QuickSearch2.js +3 -3
  39. package/dist/components/Radio/Radio.js +25 -5
  40. package/dist/components/Radio/Radio2.js +3 -3
  41. package/dist/components/Radio/RadioGroup.js +16 -3
  42. package/dist/components/SearchInput/SearchInput2.js +3 -3
  43. package/dist/components/SidebarNav/SidebarNav2.js +3 -3
  44. package/dist/components/Slider/Slider2.js +3 -3
  45. package/dist/components/Switch/Switch2.js +3 -3
  46. package/dist/components/Table/Table2.js +3 -3
  47. package/dist/components/Tabs/Tabs2.js +3 -3
  48. package/dist/components/Tooltip/Tooltip2.js +3 -3
  49. package/dist/components/deprecated_ColorPicker/ColorPicker2.js +3 -3
  50. package/dist/components/deprecated_NumberStepper/NumberStepper2.js +3 -3
  51. package/dist/components/deprecated_Tabs/Tabs2.js +3 -3
  52. package/dist/components/deprecated_Toolbar/Toolbar2.js +3 -3
  53. package/dist/hooks/useOverlay/useOverlay2.js +3 -3
  54. package/dist/hooks/useScreenReaderAnnouncement/useScreenReaderAnnouncement2.js +3 -3
  55. package/dist/icons/Icon.js +3 -3
  56. package/dist/icons/index.js +1 -1
  57. package/dist/index.d.ts +12 -2
  58. package/dist/index.es.js +1 -1
  59. package/dist/index.js +3 -3
  60. package/dist/next/AdvancedTable/AdvancedTable.js +54 -78
  61. package/dist/next/AdvancedTable/AdvancedTable2.js +3 -3
  62. package/dist/next/CollapsibleSearchInput/CollapsibleSearchInput2.js +3 -3
  63. package/dist/next/Combobox/Combobox2.js +3 -3
  64. package/dist/next/Drawer/Drawer2.js +3 -3
  65. package/dist/next/FilterAnchor/FilterAnchor2.js +3 -3
  66. package/dist/next/Form/FormFields/FormFieldWrapper.js +36 -0
  67. package/dist/next/Form/FormFields/InputField.js +8 -0
  68. package/dist/next/Form/index.js +2 -0
  69. package/dist/next/Form/useForm.js +298 -0
  70. package/dist/next/Form/useFormField.js +25 -0
  71. package/dist/next/Form/utils/createFormInstance.js +32 -0
  72. package/dist/next/Form/utils/useFormContext.js +9 -0
  73. package/dist/next/Input/Input.js +47 -7
  74. package/dist/next/Input/Input2.js +3 -3
  75. package/dist/next/Menu/Menu2.js +3 -3
  76. package/dist/next/Menu/MenuPane.js +2 -2
  77. package/dist/next/Pagination/Pagination.css.js +9 -0
  78. package/dist/next/Pagination/Pagination.css.ts.vanilla.js +8 -0
  79. package/dist/next/Pagination/Pagination.js +166 -0
  80. package/dist/next/Pagination/RowDisplayCount.js +46 -0
  81. package/dist/next/Pagination/index.js +2 -0
  82. package/dist/next/PhoneNumberInput/PhoneNumberInput2.js +3 -3
  83. package/dist/next/Select/Select2.js +3 -3
  84. package/dist/next/SplitButton/SplitButton2.js +3 -3
  85. package/dist/next/TimePicker/TimeDropdown.js +9 -3
  86. package/dist/next/TimePicker/TimePicker.js +1 -1
  87. package/dist/next/TimePicker/TimePicker2.js +3 -3
  88. package/dist/next/ToggleButton/ToggleButton.js +2 -2
  89. package/dist/next/ToggleButton/styles.js +3 -3
  90. package/dist/next/index.d.ts +170 -4
  91. package/dist/next/index.es.js +29 -23
  92. package/dist/next/index.js +1968 -1474
  93. package/dist/utils/Flyout/Flyout2.js +3 -3
  94. package/icons/package.json +1 -1
  95. package/next/package.json +2 -2
  96. package/package.json +3 -3
@@ -1,8 +1,8 @@
1
1
  import styleInject from './../../__node_modules/style-inject/dist/style-inject.es.js';
2
2
 
3
- var css_248z = "._fM8QO{max-width:100%;position:relative;display:inline-block}._N-qxQ{display:inline-flex;justify-content:space-between;align-items:center;background-color:#fafafa;border:1px solid #898989;border-radius:4px;height:36px;color:#515559;outline:none;cursor:pointer}._N-qxQ:hover:not([aria-disabled=true]){cursor:pointer;background-color:#f5f5f5}._N-qxQ:focus{box-shadow:0 0 0 2px #fff,0 0 0 4px #0a3f88;background-color:#fafafa}._N-qxQ:disabled,._N-qxQ[aria-disabled=true]{color:#74777a;border-color:#e5e5e5;cursor:not-allowed}._N-qxQ._-igSg{border-color:#b00}._N-qxQ._-igSg:focus{box-shadow:0 0 0 2px #fff,0 0 0 4px #900000}._N-qxQ._9nEB8{min-width:120px;padding:0 4px 0 12px}._N-qxQ._T1TLN{margin-top:4px}._N-qxQ._jhpX3:not([aria-disabled=true]):not(:disabled){color:#32363a}._N-qxQ ._KjfXa{min-height:10px}._N-qxQ ._KjfXa._NKDzo{line-height:20px;font-size:14px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}._N-qxQ ._KjfXa._9QYK4{display:inline-flex;align-items:center}._N-qxQ ._nqb2W{height:24px;width:24px;border-radius:4px;fill:#515559;flex-shrink:0;cursor:pointer}._N-qxQ ._nqb2W._tjJop{border-color:#e5e5e5;fill:#9d9fa1;opacity:.4;cursor:not-allowed}._N-qxQ ._nqb2W._-2eFs{transform:rotate(-180deg)}._9fFio[aria-disabled=true]{cursor:not-allowed;color:rgba(81,85,89,.65);fill:#9d9fa1}._055xr{position:-webkit-sticky;position:sticky;top:0;z-index:20;padding:4px 8px 8px!important;border-bottom:1px solid #e8e8e8;border-radius:4px 4px 0 0;background-color:#fff!important}._JS-Ja{min-height:40px;padding:10px 12px;display:flex;flex-direction:row;align-items:center;background-color:#fff;font-size:14px;color:#32363a;word-break:break-word}._jXhBu{fill:#515559}._JsOS9{margin:2px 12px 2px 0}._JsOS9._3njSz>svg{border-color:#0b6ed0}._ih0M-{width:100%}";
4
- var styles = {"container":"_fM8QO","button":"_N-qxQ","invalid":"_-igSg","hasText":"_9nEB8","labelled":"_T1TLN","selected":"_jhpX3","buttonLabel":"_KjfXa","isString":"_NKDzo","isNode":"_9QYK4","icon":"_nqb2W","disabled":"_tjJop","open":"_-2eFs","option":"_9fFio","search":"_055xr","emptyOption":"_JS-Ja","searchIcon":"_jXhBu","checkbox":"_JsOS9","highlighted":"_3njSz","searchInput":"_ih0M-"};
5
- var stylesheet="._fM8QO{max-width:100%;position:relative;display:inline-block}._N-qxQ{display:inline-flex;justify-content:space-between;align-items:center;background-color:#fafafa;border:1px solid #898989;border-radius:4px;height:36px;color:#515559;outline:none;cursor:pointer}._N-qxQ:hover:not([aria-disabled=true]){cursor:pointer;background-color:#f5f5f5}._N-qxQ:focus{box-shadow:0 0 0 2px #fff,0 0 0 4px #0a3f88;background-color:#fafafa}._N-qxQ:disabled,._N-qxQ[aria-disabled=true]{color:#74777a;border-color:#e5e5e5;cursor:not-allowed}._N-qxQ._-igSg{border-color:#b00}._N-qxQ._-igSg:focus{box-shadow:0 0 0 2px #fff,0 0 0 4px #900000}._N-qxQ._9nEB8{min-width:120px;padding:0 4px 0 12px}._N-qxQ._T1TLN{margin-top:4px}._N-qxQ._jhpX3:not([aria-disabled=true]):not(:disabled){color:#32363a}._N-qxQ ._KjfXa{min-height:10px}._N-qxQ ._KjfXa._NKDzo{line-height:20px;font-size:14px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}._N-qxQ ._KjfXa._9QYK4{display:inline-flex;align-items:center}._N-qxQ ._nqb2W{height:24px;width:24px;border-radius:4px;fill:#515559;flex-shrink:0;cursor:pointer}._N-qxQ ._nqb2W._tjJop{border-color:#e5e5e5;fill:#9d9fa1;opacity:.4;cursor:not-allowed}._N-qxQ ._nqb2W._-2eFs{transform:rotate(-180deg)}._9fFio[aria-disabled=true]{cursor:not-allowed;color:rgba(81,85,89,.65);fill:#9d9fa1}._055xr{position:-webkit-sticky;position:sticky;top:0;z-index:20;padding:4px 8px 8px!important;border-bottom:1px solid #e8e8e8;border-radius:4px 4px 0 0;background-color:#fff!important}._JS-Ja{min-height:40px;padding:10px 12px;display:flex;flex-direction:row;align-items:center;background-color:#fff;font-size:14px;color:#32363a;word-break:break-word}._jXhBu{fill:#515559}._JsOS9{margin:2px 12px 2px 0}._JsOS9._3njSz>svg{border-color:#0b6ed0}._ih0M-{width:100%}";
3
+ var css_248z = "._Oxn01{max-width:100%;position:relative;display:inline-block}._sW8cL{display:inline-flex;justify-content:space-between;align-items:center;background-color:#fafafa;border:1px solid #898989;border-radius:4px;height:36px;color:#515559;outline:none;cursor:pointer}._sW8cL:hover:not([aria-disabled=true]){cursor:pointer;background-color:#f5f5f5}._sW8cL:focus{box-shadow:0 0 0 2px #fff,0 0 0 4px #0a3f88;background-color:#fafafa}._sW8cL:disabled,._sW8cL[aria-disabled=true]{color:#74777a;border-color:#e5e5e5;cursor:not-allowed}._sW8cL._k-xci{border-color:#b00}._sW8cL._k-xci:focus{box-shadow:0 0 0 2px #fff,0 0 0 4px #900000}._sW8cL._CK9Dx{min-width:120px;padding:0 4px 0 12px}._sW8cL._e8B3i{margin-top:4px}._sW8cL._WbAYv:not([aria-disabled=true]):not(:disabled){color:#32363a}._sW8cL ._huqqe{min-height:10px}._sW8cL ._huqqe._r8WtV{line-height:20px;font-size:14px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}._sW8cL ._huqqe._Jj0yL{display:inline-flex;align-items:center}._sW8cL ._GkQLi{height:24px;width:24px;border-radius:4px;fill:#515559;flex-shrink:0;cursor:pointer}._sW8cL ._GkQLi._lS1N-{border-color:#e5e5e5;fill:#9d9fa1;opacity:.4;cursor:not-allowed}._sW8cL ._GkQLi._335Er{transform:rotate(-180deg)}._hXCHa[aria-disabled=true]{cursor:not-allowed;color:rgba(81,85,89,.65);fill:#9d9fa1}._PQ2Nd{position:-webkit-sticky;position:sticky;top:0;z-index:20;padding:4px 8px 8px!important;border-bottom:1px solid #e8e8e8;border-radius:4px 4px 0 0;background-color:#fff!important}._oGmBj{min-height:40px;padding:10px 12px;display:flex;flex-direction:row;align-items:center;background-color:#fff;font-size:14px;color:#32363a;word-break:break-word}._Z5gJA{fill:#515559}._ccV0M{margin:2px 12px 2px 0}._ccV0M._hMFu4>svg{border-color:#0b6ed0}._8m3Au{width:100%}";
4
+ var styles = {"container":"_Oxn01","button":"_sW8cL","invalid":"_k-xci","hasText":"_CK9Dx","labelled":"_e8B3i","selected":"_WbAYv","buttonLabel":"_huqqe","isString":"_r8WtV","isNode":"_Jj0yL","icon":"_GkQLi","disabled":"_lS1N-","open":"_335Er","option":"_hXCHa","search":"_PQ2Nd","emptyOption":"_oGmBj","searchIcon":"_Z5gJA","checkbox":"_ccV0M","highlighted":"_hMFu4","searchInput":"_8m3Au"};
5
+ var stylesheet="._Oxn01{max-width:100%;position:relative;display:inline-block}._sW8cL{display:inline-flex;justify-content:space-between;align-items:center;background-color:#fafafa;border:1px solid #898989;border-radius:4px;height:36px;color:#515559;outline:none;cursor:pointer}._sW8cL:hover:not([aria-disabled=true]){cursor:pointer;background-color:#f5f5f5}._sW8cL:focus{box-shadow:0 0 0 2px #fff,0 0 0 4px #0a3f88;background-color:#fafafa}._sW8cL:disabled,._sW8cL[aria-disabled=true]{color:#74777a;border-color:#e5e5e5;cursor:not-allowed}._sW8cL._k-xci{border-color:#b00}._sW8cL._k-xci:focus{box-shadow:0 0 0 2px #fff,0 0 0 4px #900000}._sW8cL._CK9Dx{min-width:120px;padding:0 4px 0 12px}._sW8cL._e8B3i{margin-top:4px}._sW8cL._WbAYv:not([aria-disabled=true]):not(:disabled){color:#32363a}._sW8cL ._huqqe{min-height:10px}._sW8cL ._huqqe._r8WtV{line-height:20px;font-size:14px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}._sW8cL ._huqqe._Jj0yL{display:inline-flex;align-items:center}._sW8cL ._GkQLi{height:24px;width:24px;border-radius:4px;fill:#515559;flex-shrink:0;cursor:pointer}._sW8cL ._GkQLi._lS1N-{border-color:#e5e5e5;fill:#9d9fa1;opacity:.4;cursor:not-allowed}._sW8cL ._GkQLi._335Er{transform:rotate(-180deg)}._hXCHa[aria-disabled=true]{cursor:not-allowed;color:rgba(81,85,89,.65);fill:#9d9fa1}._PQ2Nd{position:-webkit-sticky;position:sticky;top:0;z-index:20;padding:4px 8px 8px!important;border-bottom:1px solid #e8e8e8;border-radius:4px 4px 0 0;background-color:#fff!important}._oGmBj{min-height:40px;padding:10px 12px;display:flex;flex-direction:row;align-items:center;background-color:#fff;font-size:14px;color:#32363a;word-break:break-word}._Z5gJA{fill:#515559}._ccV0M{margin:2px 12px 2px 0}._ccV0M._hMFu4>svg{border-color:#0b6ed0}._8m3Au{width:100%}";
6
6
  if(typeof process !== 'object' || !process.hasOwnProperty('env') || process.env.NODE_ENV !== 'test'){styleInject(css_248z);}
7
7
 
8
8
  export { styles as default, stylesheet };
@@ -1,8 +1,8 @@
1
1
  import styleInject from './../../__node_modules/style-inject/dist/style-inject.es.js';
2
2
 
3
- var css_248z = "._fxQlW{position:relative}._fxQlW[focus-within] button{outline:none;box-shadow:0 0 0 2px #fff,0 0 0 4px #0a3f88}._fxQlW:focus-within button{outline:none;box-shadow:0 0 0 2px #fff,0 0 0 4px #0a3f88}._QV-Yb{opacity:0;position:absolute;height:36px;width:100%;left:0;z-index:-1}._-CaTN{margin-left:16px;font-size:14px;color:#32363a}._-CaTN ._IPl-m{margin-right:16px}";
4
- var filePickerStyles = {"container":"_fxQlW","fileInput":"_QV-Yb","fileDetails":"_-CaTN","fileName":"_IPl-m"};
5
- var stylesheet="._fxQlW{position:relative}._fxQlW[focus-within] button{outline:none;box-shadow:0 0 0 2px #fff,0 0 0 4px #0a3f88}._fxQlW:focus-within button{outline:none;box-shadow:0 0 0 2px #fff,0 0 0 4px #0a3f88}._QV-Yb{opacity:0;position:absolute;height:36px;width:100%;left:0;z-index:-1}._-CaTN{margin-left:16px;font-size:14px;color:#32363a}._-CaTN ._IPl-m{margin-right:16px}";
3
+ var css_248z = "._31WCV{position:relative}._31WCV[focus-within] button{outline:none;box-shadow:0 0 0 2px #fff,0 0 0 4px #0a3f88}._31WCV:focus-within button{outline:none;box-shadow:0 0 0 2px #fff,0 0 0 4px #0a3f88}._Svpzm{opacity:0;position:absolute;height:36px;width:100%;left:0;z-index:-1}._lSQNR{margin-left:16px;font-size:14px;color:#32363a}._lSQNR ._l00E2{margin-right:16px}";
4
+ var filePickerStyles = {"container":"_31WCV","fileInput":"_Svpzm","fileDetails":"_lSQNR","fileName":"_l00E2"};
5
+ var stylesheet="._31WCV{position:relative}._31WCV[focus-within] button{outline:none;box-shadow:0 0 0 2px #fff,0 0 0 4px #0a3f88}._31WCV:focus-within button{outline:none;box-shadow:0 0 0 2px #fff,0 0 0 4px #0a3f88}._Svpzm{opacity:0;position:absolute;height:36px;width:100%;left:0;z-index:-1}._lSQNR{margin-left:16px;font-size:14px;color:#32363a}._lSQNR ._l00E2{margin-right:16px}";
6
6
  if(typeof process !== 'object' || !process.hasOwnProperty('env') || process.env.NODE_ENV !== 'test'){styleInject(css_248z);}
7
7
 
8
8
  export { filePickerStyles as default, stylesheet };
@@ -1,8 +1,8 @@
1
1
  import styleInject from './../../__node_modules/style-inject/dist/style-inject.es.js';
2
2
 
3
- var css_248z = "._aAJui{display:flex;align-items:center;font-size:12px;line-height:16px;min-height:16px}._XBmAe{color:#6a6d70;fill:#6a6d70}._E5Nbu{color:#b00;fill:#b00}._gR0ko,._yov2M{margin-left:-2px;margin-right:3px}";
4
- var styles = {"caption":"_aAJui","helperText":"_XBmAe","errorText":"_E5Nbu","errorIcon":"_yov2M","readOnlyIcon":"_gR0ko"};
5
- var stylesheet="._aAJui{display:flex;align-items:center;font-size:12px;line-height:16px;min-height:16px}._XBmAe{color:#6a6d70;fill:#6a6d70}._E5Nbu{color:#b00;fill:#b00}._gR0ko,._yov2M{margin-left:-2px;margin-right:3px}";
3
+ var css_248z = "._-Sn-x{display:flex;align-items:center;font-size:12px;line-height:16px;min-height:16px}._WR73Z{color:#6a6d70;fill:#6a6d70}._DhQj-{color:#b00;fill:#b00}._-Y6V3,._cXCSd{margin-left:-2px;margin-right:3px}";
4
+ var styles = {"caption":"_-Sn-x","helperText":"_WR73Z","errorText":"_DhQj-","errorIcon":"_-Y6V3","readOnlyIcon":"_cXCSd"};
5
+ var stylesheet="._-Sn-x{display:flex;align-items:center;font-size:12px;line-height:16px;min-height:16px}._WR73Z{color:#6a6d70;fill:#6a6d70}._DhQj-{color:#b00;fill:#b00}._-Y6V3,._cXCSd{margin-left:-2px;margin-right:3px}";
6
6
  if(typeof process !== 'object' || !process.hasOwnProperty('env') || process.env.NODE_ENV !== 'test'){styleInject(css_248z);}
7
7
 
8
8
  export { styles as default, stylesheet };
@@ -1,8 +1,8 @@
1
1
  import styleInject from './../../__node_modules/style-inject/dist/style-inject.es.js';
2
2
 
3
- var css_248z = "._CLX9U{display:flex;flex-direction:column;align-items:flex-start}._8ueK6{margin-top:6px;max-width:100%}._8ueK6 *+*{margin-top:4px}";
4
- var styles = {"formField":"_CLX9U","captionContainer":"_8ueK6"};
5
- var stylesheet="._CLX9U{display:flex;flex-direction:column;align-items:flex-start}._8ueK6{margin-top:6px;max-width:100%}._8ueK6 *+*{margin-top:4px}";
3
+ var css_248z = "._KRYqF{display:flex;flex-direction:column;align-items:flex-start}._wJPIR{margin-top:6px;max-width:100%}._wJPIR *+*{margin-top:4px}";
4
+ var styles = {"formField":"_KRYqF","captionContainer":"_wJPIR"};
5
+ var stylesheet="._KRYqF{display:flex;flex-direction:column;align-items:flex-start}._wJPIR{margin-top:6px;max-width:100%}._wJPIR *+*{margin-top:4px}";
6
6
  if(typeof process !== 'object' || !process.hasOwnProperty('env') || process.env.NODE_ENV !== 'test'){styleInject(css_248z);}
7
7
 
8
8
  export { styles as default, stylesheet };
@@ -1,8 +1,8 @@
1
1
  import styleInject from './../../__node_modules/style-inject/dist/style-inject.es.js';
2
2
 
3
- var css_248z = "._HCeVg{position:fixed;left:0;top:0;width:100vw;height:100vh;background-color:#fff;overflow:auto}@keyframes _LrJfq{0%{transform:scale3d(.7,.7,.7);opacity:0}}._CiXSs{animation:_LrJfq both;animation-duration:.2s}@keyframes _W54-1{to{transform:scale3d(.7,.7,.7);opacity:0}}._K7y5p{animation:_W54-1 both;animation-duration:.2s}";
4
- var styles = {"dialog":"_HCeVg","transitionIn":"_CiXSs","showAnimation":"_LrJfq","transitionOut":"_K7y5p","hideAnimation":"_W54-1"};
5
- var stylesheet="._HCeVg{position:fixed;left:0;top:0;width:100vw;height:100vh;background-color:#fff;overflow:auto}@keyframes _LrJfq{0%{transform:scale3d(.7,.7,.7);opacity:0}}._CiXSs{animation:_LrJfq both;animation-duration:.2s}@keyframes _W54-1{to{transform:scale3d(.7,.7,.7);opacity:0}}._K7y5p{animation:_W54-1 both;animation-duration:.2s}";
3
+ var css_248z = "._qR-wV{position:fixed;left:0;top:0;width:100vw;height:100vh;background-color:#fff;overflow:auto}@keyframes _Z3uSf{0%{transform:scale3d(.7,.7,.7);opacity:0}}._DNI8a{animation:_Z3uSf both;animation-duration:.2s}@keyframes _k-BcY{to{transform:scale3d(.7,.7,.7);opacity:0}}._JABEp{animation:_k-BcY both;animation-duration:.2s}";
4
+ var styles = {"dialog":"_qR-wV","transitionIn":"_DNI8a","showAnimation":"_Z3uSf","transitionOut":"_JABEp","hideAnimation":"_k-BcY"};
5
+ var stylesheet="._qR-wV{position:fixed;left:0;top:0;width:100vw;height:100vh;background-color:#fff;overflow:auto}@keyframes _Z3uSf{0%{transform:scale3d(.7,.7,.7);opacity:0}}._DNI8a{animation:_Z3uSf both;animation-duration:.2s}@keyframes _k-BcY{to{transform:scale3d(.7,.7,.7);opacity:0}}._JABEp{animation:_k-BcY both;animation-duration:.2s}";
6
6
  if(typeof process !== 'object' || !process.hasOwnProperty('env') || process.env.NODE_ENV !== 'test'){styleInject(css_248z);}
7
7
 
8
8
  export { styles as default, stylesheet };
@@ -1,8 +1,8 @@
1
1
  import styleInject from './../../__node_modules/style-inject/dist/style-inject.es.js';
2
2
 
3
- var css_248z = "._Dd2JG{border-radius:4px;border:none;height:36px;width:36px;display:inline-flex;flex-shrink:0;align-items:center;justify-content:center;padding:0;cursor:pointer;fill:#515559;background-color:transparent;transition:background .2s,color .2s}._Dd2JG:focus{outline:none}._Dd2JG:hover:not(._-9rHh){background-color:rgba(50,54,58,.08)}._Dd2JG:active:not(._-9rHh){background-color:rgba(50,54,58,.11);stroke-width:2}._Dd2JG._-9rHh{cursor:not-allowed;fill:rgba(81,85,89,.6)}._Dd2JG.focus-visible,._Dd2JG:focus-visible{outline:none;box-shadow:0 0 0 2px #fff,0 0 0 4px #0a3f88}";
4
- var iconButtonStyles = {"button":"_Dd2JG","disabled":"_-9rHh"};
5
- var stylesheet="._Dd2JG{border-radius:4px;border:none;height:36px;width:36px;display:inline-flex;flex-shrink:0;align-items:center;justify-content:center;padding:0;cursor:pointer;fill:#515559;background-color:transparent;transition:background .2s,color .2s}._Dd2JG:focus{outline:none}._Dd2JG:hover:not(._-9rHh){background-color:rgba(50,54,58,.08)}._Dd2JG:active:not(._-9rHh){background-color:rgba(50,54,58,.11);stroke-width:2}._Dd2JG._-9rHh{cursor:not-allowed;fill:rgba(81,85,89,.6)}._Dd2JG.focus-visible,._Dd2JG:focus-visible{outline:none;box-shadow:0 0 0 2px #fff,0 0 0 4px #0a3f88}";
3
+ var css_248z = "._5J-4M{border-radius:4px;border:none;height:36px;width:36px;display:inline-flex;flex-shrink:0;align-items:center;justify-content:center;padding:0;cursor:pointer;fill:#515559;background-color:transparent;transition:background .2s,color .2s}._5J-4M:focus{outline:none}._5J-4M:hover:not(._tViLp){background-color:rgba(50,54,58,.08)}._5J-4M:active:not(._tViLp){background-color:rgba(50,54,58,.11);stroke-width:2}._5J-4M._tViLp{cursor:not-allowed;fill:rgba(81,85,89,.6)}._5J-4M.focus-visible,._5J-4M:focus-visible{outline:none;box-shadow:0 0 0 2px #fff,0 0 0 4px #0a3f88}";
4
+ var iconButtonStyles = {"button":"_5J-4M","disabled":"_tViLp"};
5
+ var stylesheet="._5J-4M{border-radius:4px;border:none;height:36px;width:36px;display:inline-flex;flex-shrink:0;align-items:center;justify-content:center;padding:0;cursor:pointer;fill:#515559;background-color:transparent;transition:background .2s,color .2s}._5J-4M:focus{outline:none}._5J-4M:hover:not(._tViLp){background-color:rgba(50,54,58,.08)}._5J-4M:active:not(._tViLp){background-color:rgba(50,54,58,.11);stroke-width:2}._5J-4M._tViLp{cursor:not-allowed;fill:rgba(81,85,89,.6)}._5J-4M.focus-visible,._5J-4M:focus-visible{outline:none;box-shadow:0 0 0 2px #fff,0 0 0 4px #0a3f88}";
6
6
  if(typeof process !== 'object' || !process.hasOwnProperty('env') || process.env.NODE_ENV !== 'test'){styleInject(css_248z);}
7
7
 
8
8
  export { iconButtonStyles as default, stylesheet };
@@ -1,8 +1,8 @@
1
1
  import styleInject from './../../__node_modules/style-inject/dist/style-inject.es.js';
2
2
 
3
- var css_248z = "._mFf-l{display:inline-block}._o3h-H{color:#085caf;cursor:pointer;font-size:14px;box-sizing:border-box;padding:4px;margin:-5px;outline:0;border:1px solid transparent;border-radius:4px;background-clip:padding-box;display:block}._o3h-H::-moz-selection{background-color:rgba(11,110,208,.11)}._o3h-H::selection{background-color:rgba(11,110,208,.11)}._o3h-H:focus,._o3h-H:hover{background-color:#f5f5f5}._o3h-H:focus{border:2px solid #0a3f88;padding:3px}._o3h-H:focus._Yflz-{background-color:#fafafa;cursor:text;box-shadow:inset 0 1px 1px rgba(0,0,0,.075),0 1px 8px hsla(0,0%,66.7%,.5)}";
4
- var styles = {"container":"_mFf-l","inlineInput":"_o3h-H","isEditing":"_Yflz-"};
5
- var stylesheet="._mFf-l{display:inline-block}._o3h-H{color:#085caf;cursor:pointer;font-size:14px;box-sizing:border-box;padding:4px;margin:-5px;outline:0;border:1px solid transparent;border-radius:4px;background-clip:padding-box;display:block}._o3h-H::-moz-selection{background-color:rgba(11,110,208,.11)}._o3h-H::selection{background-color:rgba(11,110,208,.11)}._o3h-H:focus,._o3h-H:hover{background-color:#f5f5f5}._o3h-H:focus{border:2px solid #0a3f88;padding:3px}._o3h-H:focus._Yflz-{background-color:#fafafa;cursor:text;box-shadow:inset 0 1px 1px rgba(0,0,0,.075),0 1px 8px hsla(0,0%,66.7%,.5)}";
3
+ var css_248z = "._5CDb2{display:inline-block}._p94xX{color:#085caf;cursor:pointer;font-size:14px;box-sizing:border-box;padding:4px;margin:-5px;outline:0;border:1px solid transparent;border-radius:4px;background-clip:padding-box;display:block}._p94xX::-moz-selection{background-color:rgba(11,110,208,.11)}._p94xX::selection{background-color:rgba(11,110,208,.11)}._p94xX:focus,._p94xX:hover{background-color:#f5f5f5}._p94xX:focus{border:2px solid #0a3f88;padding:3px}._p94xX:focus._GVv4L{background-color:#fafafa;cursor:text;box-shadow:inset 0 1px 1px rgba(0,0,0,.075),0 1px 8px hsla(0,0%,66.7%,.5)}";
4
+ var styles = {"container":"_5CDb2","inlineInput":"_p94xX","isEditing":"_GVv4L"};
5
+ var stylesheet="._5CDb2{display:inline-block}._p94xX{color:#085caf;cursor:pointer;font-size:14px;box-sizing:border-box;padding:4px;margin:-5px;outline:0;border:1px solid transparent;border-radius:4px;background-clip:padding-box;display:block}._p94xX::-moz-selection{background-color:rgba(11,110,208,.11)}._p94xX::selection{background-color:rgba(11,110,208,.11)}._p94xX:focus,._p94xX:hover{background-color:#f5f5f5}._p94xX:focus{border:2px solid #0a3f88;padding:3px}._p94xX:focus._GVv4L{background-color:#fafafa;cursor:text;box-shadow:inset 0 1px 1px rgba(0,0,0,.075),0 1px 8px hsla(0,0%,66.7%,.5)}";
6
6
  if(typeof process !== 'object' || !process.hasOwnProperty('env') || process.env.NODE_ENV !== 'test'){styleInject(css_248z);}
7
7
 
8
8
  export { styles as default, stylesheet };
@@ -1,8 +1,8 @@
1
1
  import styleInject from './../../__node_modules/style-inject/dist/style-inject.es.js';
2
2
 
3
- var css_248z = "._IyL7i{display:inline-block;height:36px;min-height:36px;padding:8px 12px;line-height:20px;font-size:14px;color:#32363a;caret-color:#32363a;background-color:#fafafa;border:1px solid #898989;border-radius:4px;outline:none}._IyL7i::-moz-placeholder{color:#515559;opacity:1}._IyL7i::placeholder{color:#515559;opacity:1}._IyL7i:hover{cursor:pointer;background-color:#f5f5f5}._IyL7i:focus{box-shadow:0 0 0 2px #fff,0 0 0 4px #0a3f88;background-color:#fafafa;cursor:text;outline:none;border-color:transparent}._IyL7i._ANKCo{border-color:#b00}._IyL7i._ANKCo:focus{box-shadow:0 0 0 2px #fff,0 0 0 4px #900000;border-color:transparent}._IyL7i:disabled{background-color:#fafafa;border-color:#e5e5e5;color:#9d9fa1;-webkit-text-fill-color:#9d9fa1;cursor:not-allowed}._IyL7i:disabled::-moz-placeholder{color:#aaabad;-webkit-text-fill-color:#aaabad}._IyL7i:disabled::placeholder{color:#aaabad;-webkit-text-fill-color:#aaabad}._IyL7i._MUt7T{height:auto}._IyL7i._MUt7T::-webkit-resizer{background-image:url(data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iOCIgaGVpZ2h0PSI4IiBmaWxsPSJub25lIiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciPjxwYXRoIGQ9Ik03IDF2M2EzIDMgMCAwMS0zIDNIMSIgc3Ryb2tlPSIjOTI5MjkyIiBzdHJva2Utd2lkdGg9IjIiIHN0cm9rZS1saW5lY2FwPSJyb3VuZCIgc3Ryb2tlLWxpbmVqb2luPSJyb3VuZCIvPjwvc3ZnPg==);background-size:8px 8px;background-repeat:no-repeat;background-position:50%}._IyL7i._z8rDW{display:block;width:100%}._IyL7i._0W1pc{padding:4px 8px}input._IyL7i._0W1pc{height:26px;min-height:26px}[type=number]._IyL7i{-moz-appearance:textfield}[type=number]._IyL7i::-webkit-inner-spin-button,[type=number]._IyL7i::-webkit-outer-spin-button{-webkit-appearance:none;margin:0}._VKXmU{line-height:20px;color:#6a6d70;display:flex;flex-direction:column;align-items:flex-start}._VKXmU:hover{cursor:pointer}._VKXmU._AN7Q2{color:#0b6ed0}._ebJY1{margin-top:4px}";
4
- var styles = {"input":"_IyL7i","invalid":"_ANKCo","multiline":"_MUt7T","full":"_z8rDW","small":"_0W1pc","label":"_VKXmU","focused":"_AN7Q2","wrappedInput":"_ebJY1"};
5
- var stylesheet="._IyL7i{display:inline-block;height:36px;min-height:36px;padding:8px 12px;line-height:20px;font-size:14px;color:#32363a;caret-color:#32363a;background-color:#fafafa;border:1px solid #898989;border-radius:4px;outline:none}._IyL7i::-moz-placeholder{color:#515559;opacity:1}._IyL7i::placeholder{color:#515559;opacity:1}._IyL7i:hover{cursor:pointer;background-color:#f5f5f5}._IyL7i:focus{box-shadow:0 0 0 2px #fff,0 0 0 4px #0a3f88;background-color:#fafafa;cursor:text;outline:none;border-color:transparent}._IyL7i._ANKCo{border-color:#b00}._IyL7i._ANKCo:focus{box-shadow:0 0 0 2px #fff,0 0 0 4px #900000;border-color:transparent}._IyL7i:disabled{background-color:#fafafa;border-color:#e5e5e5;color:#9d9fa1;-webkit-text-fill-color:#9d9fa1;cursor:not-allowed}._IyL7i:disabled::-moz-placeholder{color:#aaabad;-webkit-text-fill-color:#aaabad}._IyL7i:disabled::placeholder{color:#aaabad;-webkit-text-fill-color:#aaabad}._IyL7i._MUt7T{height:auto}._IyL7i._MUt7T::-webkit-resizer{background-image:url(data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iOCIgaGVpZ2h0PSI4IiBmaWxsPSJub25lIiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciPjxwYXRoIGQ9Ik03IDF2M2EzIDMgMCAwMS0zIDNIMSIgc3Ryb2tlPSIjOTI5MjkyIiBzdHJva2Utd2lkdGg9IjIiIHN0cm9rZS1saW5lY2FwPSJyb3VuZCIgc3Ryb2tlLWxpbmVqb2luPSJyb3VuZCIvPjwvc3ZnPg==);background-size:8px 8px;background-repeat:no-repeat;background-position:50%}._IyL7i._z8rDW{display:block;width:100%}._IyL7i._0W1pc{padding:4px 8px}input._IyL7i._0W1pc{height:26px;min-height:26px}[type=number]._IyL7i{-moz-appearance:textfield}[type=number]._IyL7i::-webkit-inner-spin-button,[type=number]._IyL7i::-webkit-outer-spin-button{-webkit-appearance:none;margin:0}._VKXmU{line-height:20px;color:#6a6d70;display:flex;flex-direction:column;align-items:flex-start}._VKXmU:hover{cursor:pointer}._VKXmU._AN7Q2{color:#0b6ed0}._ebJY1{margin-top:4px}";
3
+ var css_248z = "._15ziu{display:inline-block;height:36px;min-height:36px;padding:8px 12px;line-height:20px;font-size:14px;color:#32363a;caret-color:#32363a;background-color:#fafafa;border:1px solid #898989;border-radius:4px;outline:none}._15ziu::-moz-placeholder{color:#515559;opacity:1}._15ziu::placeholder{color:#515559;opacity:1}._15ziu:hover{cursor:pointer;background-color:#f5f5f5}._15ziu:focus{box-shadow:0 0 0 2px #fff,0 0 0 4px #0a3f88;background-color:#fafafa;cursor:text;outline:none;border-color:transparent}._15ziu._-Ow1J{border-color:#b00}._15ziu._-Ow1J:focus{box-shadow:0 0 0 2px #fff,0 0 0 4px #900000;border-color:transparent}._15ziu:disabled{background-color:#fafafa;border-color:#e5e5e5;color:#9d9fa1;-webkit-text-fill-color:#9d9fa1;cursor:not-allowed}._15ziu:disabled::-moz-placeholder{color:#aaabad;-webkit-text-fill-color:#aaabad}._15ziu:disabled::placeholder{color:#aaabad;-webkit-text-fill-color:#aaabad}._15ziu._93BjW{height:auto}._15ziu._93BjW::-webkit-resizer{background-image:url(data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iOCIgaGVpZ2h0PSI4IiBmaWxsPSJub25lIiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciPjxwYXRoIGQ9Ik03IDF2M2EzIDMgMCAwMS0zIDNIMSIgc3Ryb2tlPSIjOTI5MjkyIiBzdHJva2Utd2lkdGg9IjIiIHN0cm9rZS1saW5lY2FwPSJyb3VuZCIgc3Ryb2tlLWxpbmVqb2luPSJyb3VuZCIvPjwvc3ZnPg==);background-size:8px 8px;background-repeat:no-repeat;background-position:50%}._15ziu._BO7z8{display:block;width:100%}._15ziu._eZQ9V{padding:4px 8px}input._15ziu._eZQ9V{height:26px;min-height:26px}[type=number]._15ziu{-moz-appearance:textfield}[type=number]._15ziu::-webkit-inner-spin-button,[type=number]._15ziu::-webkit-outer-spin-button{-webkit-appearance:none;margin:0}._qijvA{line-height:20px;color:#6a6d70;display:flex;flex-direction:column;align-items:flex-start}._qijvA:hover{cursor:pointer}._qijvA._uTV6P{color:#0b6ed0}._8jFuc{margin-top:4px}";
4
+ var styles = {"input":"_15ziu","invalid":"_-Ow1J","multiline":"_93BjW","full":"_BO7z8","small":"_eZQ9V","label":"_qijvA","focused":"_uTV6P","wrappedInput":"_8jFuc"};
5
+ var stylesheet="._15ziu{display:inline-block;height:36px;min-height:36px;padding:8px 12px;line-height:20px;font-size:14px;color:#32363a;caret-color:#32363a;background-color:#fafafa;border:1px solid #898989;border-radius:4px;outline:none}._15ziu::-moz-placeholder{color:#515559;opacity:1}._15ziu::placeholder{color:#515559;opacity:1}._15ziu:hover{cursor:pointer;background-color:#f5f5f5}._15ziu:focus{box-shadow:0 0 0 2px #fff,0 0 0 4px #0a3f88;background-color:#fafafa;cursor:text;outline:none;border-color:transparent}._15ziu._-Ow1J{border-color:#b00}._15ziu._-Ow1J:focus{box-shadow:0 0 0 2px #fff,0 0 0 4px #900000;border-color:transparent}._15ziu:disabled{background-color:#fafafa;border-color:#e5e5e5;color:#9d9fa1;-webkit-text-fill-color:#9d9fa1;cursor:not-allowed}._15ziu:disabled::-moz-placeholder{color:#aaabad;-webkit-text-fill-color:#aaabad}._15ziu:disabled::placeholder{color:#aaabad;-webkit-text-fill-color:#aaabad}._15ziu._93BjW{height:auto}._15ziu._93BjW::-webkit-resizer{background-image:url(data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iOCIgaGVpZ2h0PSI4IiBmaWxsPSJub25lIiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciPjxwYXRoIGQ9Ik03IDF2M2EzIDMgMCAwMS0zIDNIMSIgc3Ryb2tlPSIjOTI5MjkyIiBzdHJva2Utd2lkdGg9IjIiIHN0cm9rZS1saW5lY2FwPSJyb3VuZCIgc3Ryb2tlLWxpbmVqb2luPSJyb3VuZCIvPjwvc3ZnPg==);background-size:8px 8px;background-repeat:no-repeat;background-position:50%}._15ziu._BO7z8{display:block;width:100%}._15ziu._eZQ9V{padding:4px 8px}input._15ziu._eZQ9V{height:26px;min-height:26px}[type=number]._15ziu{-moz-appearance:textfield}[type=number]._15ziu::-webkit-inner-spin-button,[type=number]._15ziu::-webkit-outer-spin-button{-webkit-appearance:none;margin:0}._qijvA{line-height:20px;color:#6a6d70;display:flex;flex-direction:column;align-items:flex-start}._qijvA:hover{cursor:pointer}._qijvA._uTV6P{color:#0b6ed0}._8jFuc{margin-top:4px}";
6
6
  if(typeof process !== 'object' || !process.hasOwnProperty('env') || process.env.NODE_ENV !== 'test'){styleInject(css_248z);}
7
7
 
8
8
  export { styles as default, stylesheet };
@@ -1,8 +1,8 @@
1
1
  import styleInject from './../../__node_modules/style-inject/dist/style-inject.es.js';
2
2
 
3
- var css_248z = "._ttqXk{border:1px solid #898989;border-radius:4px;height:36px;min-height:36px;color:#6a6d70;fill:#6a6d70;background-color:#fafafa;font-size:14px;display:inline-flex;justify-content:center;align-items:center;line-height:1;padding:0 13px}._ttqXk._HENan{height:26px;min-height:26px;padding:5px 8px}._qMGFQ{display:flex;align-items:stretch}._qMGFQ._eS8lL{width:100%}._qMGFQ ._0UoD2{margin:0;position:relative;flex-shrink:0;z-index:10}._qMGFQ ._0UoD2:first-child{margin:0 -1px 0 0;border-top-left-radius:4px;border-bottom-left-radius:4px;border-top-right-radius:0;border-bottom-right-radius:0}._qMGFQ ._0UoD2:not(:last-child):not(:first-child){margin:0 -1px 0 0;border-radius:0}._qMGFQ ._0UoD2:last-child{border-top-left-radius:0;border-bottom-left-radius:0}._qMGFQ ._0UoD2:last-child,._qMGFQ ._0UoD2:only-child{margin:0;border-top-right-radius:4px;border-bottom-right-radius:4px}._qMGFQ ._0UoD2:only-child{border-top-left-radius:4px;border-bottom-left-radius:4px}._qMGFQ ._0UoD2._91v8C{flex-shrink:1;min-width:40px;z-index:0}._qMGFQ ._0UoD2._91v8C._eS8lL{flex-grow:1}._qMGFQ ._0UoD2:focus{z-index:20}";
4
- var styles = {"addon":"_ttqXk","small":"_HENan","inputGroup":"_qMGFQ","full":"_eS8lL","inputGroupElement":"_0UoD2","input":"_91v8C"};
5
- var stylesheet="._ttqXk{border:1px solid #898989;border-radius:4px;height:36px;min-height:36px;color:#6a6d70;fill:#6a6d70;background-color:#fafafa;font-size:14px;display:inline-flex;justify-content:center;align-items:center;line-height:1;padding:0 13px}._ttqXk._HENan{height:26px;min-height:26px;padding:5px 8px}._qMGFQ{display:flex;align-items:stretch}._qMGFQ._eS8lL{width:100%}._qMGFQ ._0UoD2{margin:0;position:relative;flex-shrink:0;z-index:10}._qMGFQ ._0UoD2:first-child{margin:0 -1px 0 0;border-top-left-radius:4px;border-bottom-left-radius:4px;border-top-right-radius:0;border-bottom-right-radius:0}._qMGFQ ._0UoD2:not(:last-child):not(:first-child){margin:0 -1px 0 0;border-radius:0}._qMGFQ ._0UoD2:last-child{border-top-left-radius:0;border-bottom-left-radius:0}._qMGFQ ._0UoD2:last-child,._qMGFQ ._0UoD2:only-child{margin:0;border-top-right-radius:4px;border-bottom-right-radius:4px}._qMGFQ ._0UoD2:only-child{border-top-left-radius:4px;border-bottom-left-radius:4px}._qMGFQ ._0UoD2._91v8C{flex-shrink:1;min-width:40px;z-index:0}._qMGFQ ._0UoD2._91v8C._eS8lL{flex-grow:1}._qMGFQ ._0UoD2:focus{z-index:20}";
3
+ var css_248z = "._txHMa{border:1px solid #898989;border-radius:4px;height:36px;min-height:36px;color:#6a6d70;fill:#6a6d70;background-color:#fafafa;font-size:14px;display:inline-flex;justify-content:center;align-items:center;line-height:1;padding:0 13px}._txHMa._TSejv{height:26px;min-height:26px;padding:5px 8px}._UiP7s{display:flex;align-items:stretch}._UiP7s._wLB4u{width:100%}._UiP7s ._iDD5d{margin:0;position:relative;flex-shrink:0;z-index:10}._UiP7s ._iDD5d:first-child{margin:0 -1px 0 0;border-top-left-radius:4px;border-bottom-left-radius:4px;border-top-right-radius:0;border-bottom-right-radius:0}._UiP7s ._iDD5d:not(:last-child):not(:first-child){margin:0 -1px 0 0;border-radius:0}._UiP7s ._iDD5d:last-child{border-top-left-radius:0;border-bottom-left-radius:0}._UiP7s ._iDD5d:last-child,._UiP7s ._iDD5d:only-child{margin:0;border-top-right-radius:4px;border-bottom-right-radius:4px}._UiP7s ._iDD5d:only-child{border-top-left-radius:4px;border-bottom-left-radius:4px}._UiP7s ._iDD5d._kUrVQ{flex-shrink:1;min-width:40px;z-index:0}._UiP7s ._iDD5d._kUrVQ._wLB4u{flex-grow:1}._UiP7s ._iDD5d:focus{z-index:20}";
4
+ var styles = {"addon":"_txHMa","small":"_TSejv","inputGroup":"_UiP7s","full":"_wLB4u","inputGroupElement":"_iDD5d","input":"_kUrVQ"};
5
+ var stylesheet="._txHMa{border:1px solid #898989;border-radius:4px;height:36px;min-height:36px;color:#6a6d70;fill:#6a6d70;background-color:#fafafa;font-size:14px;display:inline-flex;justify-content:center;align-items:center;line-height:1;padding:0 13px}._txHMa._TSejv{height:26px;min-height:26px;padding:5px 8px}._UiP7s{display:flex;align-items:stretch}._UiP7s._wLB4u{width:100%}._UiP7s ._iDD5d{margin:0;position:relative;flex-shrink:0;z-index:10}._UiP7s ._iDD5d:first-child{margin:0 -1px 0 0;border-top-left-radius:4px;border-bottom-left-radius:4px;border-top-right-radius:0;border-bottom-right-radius:0}._UiP7s ._iDD5d:not(:last-child):not(:first-child){margin:0 -1px 0 0;border-radius:0}._UiP7s ._iDD5d:last-child{border-top-left-radius:0;border-bottom-left-radius:0}._UiP7s ._iDD5d:last-child,._UiP7s ._iDD5d:only-child{margin:0;border-top-right-radius:4px;border-bottom-right-radius:4px}._UiP7s ._iDD5d:only-child{border-top-left-radius:4px;border-bottom-left-radius:4px}._UiP7s ._iDD5d._kUrVQ{flex-shrink:1;min-width:40px;z-index:0}._UiP7s ._iDD5d._kUrVQ._wLB4u{flex-grow:1}._UiP7s ._iDD5d:focus{z-index:20}";
6
6
  if(typeof process !== 'object' || !process.hasOwnProperty('env') || process.env.NODE_ENV !== 'test'){styleInject(css_248z);}
7
7
 
8
8
  export { styles as default, stylesheet };
@@ -1,8 +1,8 @@
1
1
  import styleInject from './../../__node_modules/style-inject/dist/style-inject.es.js';
2
2
 
3
- var css_248z = "._H9rpG{font-size:14px}._jSjie{color:#6a6d70;line-height:20px;display:inline-flex;flex-direction:column;align-items:flex-start}._hEpDs{color:#0b6ed0}";
4
- var styles = {"label":"_H9rpG","control":"_jSjie","focused":"_hEpDs"};
5
- var stylesheet="._H9rpG{font-size:14px}._jSjie{color:#6a6d70;line-height:20px;display:inline-flex;flex-direction:column;align-items:flex-start}._hEpDs{color:#0b6ed0}";
3
+ var css_248z = "._kwZoc{font-size:14px}._ePrV0{color:#6a6d70;line-height:20px;display:inline-flex;flex-direction:column;align-items:flex-start}._2NAta{color:#0b6ed0}";
4
+ var styles = {"label":"_kwZoc","control":"_ePrV0","focused":"_2NAta"};
5
+ var stylesheet="._kwZoc{font-size:14px}._ePrV0{color:#6a6d70;line-height:20px;display:inline-flex;flex-direction:column;align-items:flex-start}._2NAta{color:#0b6ed0}";
6
6
  if(typeof process !== 'object' || !process.hasOwnProperty('env') || process.env.NODE_ENV !== 'test'){styleInject(css_248z);}
7
7
 
8
8
  export { styles as default, stylesheet };
@@ -1,8 +1,8 @@
1
1
  import styleInject from './../../__node_modules/style-inject/dist/style-inject.es.js';
2
2
 
3
- var css_248z = "._i96UG{color:#0b6ed0;cursor:pointer;text-decoration:underline;text-decoration-thickness:1px;-webkit-text-decoration-skip:ink;text-decoration-skip-ink:auto;text-underline-offset:3px;border-radius:1px}._i96UG:active:focus,._i96UG:focus{outline:none}._i96UG:visited{color:#0854a1}._i96UG:hover{color:#085caf}._i96UG:active{color:#0854a1}._i96UG.focus-visible,._i96UG:focus-visible{box-shadow:0 0 0 2px #fff,0 0 0 4px #0a3f88}";
4
- var styles = {"link":"_i96UG"};
5
- var stylesheet="._i96UG{color:#0b6ed0;cursor:pointer;text-decoration:underline;text-decoration-thickness:1px;-webkit-text-decoration-skip:ink;text-decoration-skip-ink:auto;text-underline-offset:3px;border-radius:1px}._i96UG:active:focus,._i96UG:focus{outline:none}._i96UG:visited{color:#0854a1}._i96UG:hover{color:#085caf}._i96UG:active{color:#0854a1}._i96UG.focus-visible,._i96UG:focus-visible{box-shadow:0 0 0 2px #fff,0 0 0 4px #0a3f88}";
3
+ var css_248z = "._DXsA1{color:#0b6ed0;cursor:pointer;text-decoration:underline;text-decoration-thickness:1px;-webkit-text-decoration-skip:ink;text-decoration-skip-ink:auto;text-underline-offset:3px;border-radius:1px}._DXsA1:active:focus,._DXsA1:focus{outline:none}._DXsA1:visited{color:#0854a1}._DXsA1:hover{color:#085caf}._DXsA1:active{color:#0854a1}._DXsA1.focus-visible,._DXsA1:focus-visible{box-shadow:0 0 0 2px #fff,0 0 0 4px #0a3f88}";
4
+ var styles = {"link":"_DXsA1"};
5
+ var stylesheet="._DXsA1{color:#0b6ed0;cursor:pointer;text-decoration:underline;text-decoration-thickness:1px;-webkit-text-decoration-skip:ink;text-decoration-skip-ink:auto;text-underline-offset:3px;border-radius:1px}._DXsA1:active:focus,._DXsA1:focus{outline:none}._DXsA1:visited{color:#0854a1}._DXsA1:hover{color:#085caf}._DXsA1:active{color:#0854a1}._DXsA1.focus-visible,._DXsA1:focus-visible{box-shadow:0 0 0 2px #fff,0 0 0 4px #0a3f88}";
6
6
  if(typeof process !== 'object' || !process.hasOwnProperty('env') || process.env.NODE_ENV !== 'test'){styleInject(css_248z);}
7
7
 
8
8
  export { styles as default, stylesheet };
@@ -1,8 +1,8 @@
1
1
  import styleInject from './../../__node_modules/style-inject/dist/style-inject.es.js';
2
2
 
3
- var css_248z = "._uCwW0{position:relative;display:inline-block}._uCwW0._D5C98{min-height:20px;min-width:20px}._uCwW0._ZX1aT{min-height:25px;min-width:25px}._uCwW0._K4slw{min-height:40px;min-width:40px}._uCwW0._0cPQt{min-height:64px;min-width:64px}._uCwW0 ._xS4hH{display:inline-block;background-color:transparent;position:absolute;z-index:10;width:0;height:0;left:50%;bottom:50%;pointer-events:none}._uCwW0 ._xS4hH._lDVf5{visibility:hidden}._uCwW0 ._xS4hH div{position:absolute;transform:rotate(20deg)}._uCwW0 ._xS4hH div div:nth-child(-n+9){background-color:#fff;transform-origin:0 0;animation:_xS4hH .9s linear infinite}._uCwW0 ._xS4hH div div:nth-child(-n+9):after{content:\" \";display:block;position:absolute;top:5px;left:-1px;width:2px;height:10px;border-radius:20%;background:#000}._uCwW0 ._xS4hH div div:first-child{transform:rotate(20deg);animation-delay:-.8s}._uCwW0 ._xS4hH div div:nth-child(2){transform:rotate(60deg);animation-delay:-.7s}._uCwW0 ._xS4hH div div:nth-child(3){transform:rotate(100deg);animation-delay:-.6s}._uCwW0 ._xS4hH div div:nth-child(4){transform:rotate(140deg);animation-delay:-.5s}._uCwW0 ._xS4hH div div:nth-child(5){transform:rotate(180deg);animation-delay:-.4s}._uCwW0 ._xS4hH div div:nth-child(6){transform:rotate(220deg);animation-delay:-.3s}._uCwW0 ._xS4hH div div:nth-child(7){transform:rotate(260deg);animation-delay:-.2s}._uCwW0 ._xS4hH div div:nth-child(8){transform:rotate(300deg);animation-delay:-.1s}._uCwW0 ._xS4hH div div:nth-child(9){transform:rotate(340deg);animation-delay:0s}._uCwW0 ._0cPQt div div:nth-child(-n+9):after{top:10px;left:-2px;width:4px;height:18px}._uCwW0 ._D5C98 div div:nth-child(-n+9):after{top:2px;left:-1px;width:1.5px;height:6px}._uCwW0 ._ZX1aT div div:nth-child(-n+9):after{top:4px;left:-1px;width:2px;height:7px}._uCwW0 ._Ja4ov div div:nth-child(-n+9):after{background:#fff}._uCwW0 ._EPrUM{width:100%;height:100%}._uCwW0 ._EPrUM._PFJ3-{pointer-events:none}._uCwW0 ._EPrUM._lDVf5{opacity:0}._uCwW0 ._EPrUM._WrFk6{opacity:.5}@keyframes _xS4hH{0%{opacity:1}to{opacity:0}}";
4
- var styles = {"spinnerContainer":"_uCwW0","xs":"_D5C98","small":"_ZX1aT","medium":"_K4slw","large":"_0cPQt","spinnerComponent":"_xS4hH","hide":"_lDVf5","inverted":"_Ja4ov","spinnerContent":"_EPrUM","disablePointerEvents":"_PFJ3-","fade":"_WrFk6"};
5
- var stylesheet="._uCwW0{position:relative;display:inline-block}._uCwW0._D5C98{min-height:20px;min-width:20px}._uCwW0._ZX1aT{min-height:25px;min-width:25px}._uCwW0._K4slw{min-height:40px;min-width:40px}._uCwW0._0cPQt{min-height:64px;min-width:64px}._uCwW0 ._xS4hH{display:inline-block;background-color:transparent;position:absolute;z-index:10;width:0;height:0;left:50%;bottom:50%;pointer-events:none}._uCwW0 ._xS4hH._lDVf5{visibility:hidden}._uCwW0 ._xS4hH div{position:absolute;transform:rotate(20deg)}._uCwW0 ._xS4hH div div:nth-child(-n+9){background-color:#fff;transform-origin:0 0;animation:_xS4hH .9s linear infinite}._uCwW0 ._xS4hH div div:nth-child(-n+9):after{content:\" \";display:block;position:absolute;top:5px;left:-1px;width:2px;height:10px;border-radius:20%;background:#000}._uCwW0 ._xS4hH div div:first-child{transform:rotate(20deg);animation-delay:-.8s}._uCwW0 ._xS4hH div div:nth-child(2){transform:rotate(60deg);animation-delay:-.7s}._uCwW0 ._xS4hH div div:nth-child(3){transform:rotate(100deg);animation-delay:-.6s}._uCwW0 ._xS4hH div div:nth-child(4){transform:rotate(140deg);animation-delay:-.5s}._uCwW0 ._xS4hH div div:nth-child(5){transform:rotate(180deg);animation-delay:-.4s}._uCwW0 ._xS4hH div div:nth-child(6){transform:rotate(220deg);animation-delay:-.3s}._uCwW0 ._xS4hH div div:nth-child(7){transform:rotate(260deg);animation-delay:-.2s}._uCwW0 ._xS4hH div div:nth-child(8){transform:rotate(300deg);animation-delay:-.1s}._uCwW0 ._xS4hH div div:nth-child(9){transform:rotate(340deg);animation-delay:0s}._uCwW0 ._0cPQt div div:nth-child(-n+9):after{top:10px;left:-2px;width:4px;height:18px}._uCwW0 ._D5C98 div div:nth-child(-n+9):after{top:2px;left:-1px;width:1.5px;height:6px}._uCwW0 ._ZX1aT div div:nth-child(-n+9):after{top:4px;left:-1px;width:2px;height:7px}._uCwW0 ._Ja4ov div div:nth-child(-n+9):after{background:#fff}._uCwW0 ._EPrUM{width:100%;height:100%}._uCwW0 ._EPrUM._PFJ3-{pointer-events:none}._uCwW0 ._EPrUM._lDVf5{opacity:0}._uCwW0 ._EPrUM._WrFk6{opacity:.5}@keyframes _xS4hH{0%{opacity:1}to{opacity:0}}";
3
+ var css_248z = "._gNwVH{position:relative;display:inline-block}._gNwVH._WhE9c{min-height:20px;min-width:20px}._gNwVH._QF74b{min-height:25px;min-width:25px}._gNwVH._-hiLC{min-height:40px;min-width:40px}._gNwVH._Jf-QY{min-height:64px;min-width:64px}._gNwVH ._HYLqQ{display:inline-block;background-color:transparent;position:absolute;z-index:10;width:0;height:0;left:50%;bottom:50%;pointer-events:none}._gNwVH ._HYLqQ._WAngi{visibility:hidden}._gNwVH ._HYLqQ div{position:absolute;transform:rotate(20deg)}._gNwVH ._HYLqQ div div:nth-child(-n+9){background-color:#fff;transform-origin:0 0;animation:_HYLqQ .9s linear infinite}._gNwVH ._HYLqQ div div:nth-child(-n+9):after{content:\" \";display:block;position:absolute;top:5px;left:-1px;width:2px;height:10px;border-radius:20%;background:#000}._gNwVH ._HYLqQ div div:first-child{transform:rotate(20deg);animation-delay:-.8s}._gNwVH ._HYLqQ div div:nth-child(2){transform:rotate(60deg);animation-delay:-.7s}._gNwVH ._HYLqQ div div:nth-child(3){transform:rotate(100deg);animation-delay:-.6s}._gNwVH ._HYLqQ div div:nth-child(4){transform:rotate(140deg);animation-delay:-.5s}._gNwVH ._HYLqQ div div:nth-child(5){transform:rotate(180deg);animation-delay:-.4s}._gNwVH ._HYLqQ div div:nth-child(6){transform:rotate(220deg);animation-delay:-.3s}._gNwVH ._HYLqQ div div:nth-child(7){transform:rotate(260deg);animation-delay:-.2s}._gNwVH ._HYLqQ div div:nth-child(8){transform:rotate(300deg);animation-delay:-.1s}._gNwVH ._HYLqQ div div:nth-child(9){transform:rotate(340deg);animation-delay:0s}._gNwVH ._Jf-QY div div:nth-child(-n+9):after{top:10px;left:-2px;width:4px;height:18px}._gNwVH ._WhE9c div div:nth-child(-n+9):after{top:2px;left:-1px;width:1.5px;height:6px}._gNwVH ._QF74b div div:nth-child(-n+9):after{top:4px;left:-1px;width:2px;height:7px}._gNwVH ._vkRO6 div div:nth-child(-n+9):after{background:#fff}._gNwVH ._n-J4s{width:100%;height:100%}._gNwVH ._n-J4s._7dUL1{pointer-events:none}._gNwVH ._n-J4s._WAngi{opacity:0}._gNwVH ._n-J4s._QGTe2{opacity:.5}@keyframes _HYLqQ{0%{opacity:1}to{opacity:0}}";
4
+ var styles = {"spinnerContainer":"_gNwVH","xs":"_WhE9c","small":"_QF74b","medium":"_-hiLC","large":"_Jf-QY","spinnerComponent":"_HYLqQ","hide":"_WAngi","inverted":"_vkRO6","spinnerContent":"_n-J4s","disablePointerEvents":"_7dUL1","fade":"_QGTe2"};
5
+ var stylesheet="._gNwVH{position:relative;display:inline-block}._gNwVH._WhE9c{min-height:20px;min-width:20px}._gNwVH._QF74b{min-height:25px;min-width:25px}._gNwVH._-hiLC{min-height:40px;min-width:40px}._gNwVH._Jf-QY{min-height:64px;min-width:64px}._gNwVH ._HYLqQ{display:inline-block;background-color:transparent;position:absolute;z-index:10;width:0;height:0;left:50%;bottom:50%;pointer-events:none}._gNwVH ._HYLqQ._WAngi{visibility:hidden}._gNwVH ._HYLqQ div{position:absolute;transform:rotate(20deg)}._gNwVH ._HYLqQ div div:nth-child(-n+9){background-color:#fff;transform-origin:0 0;animation:_HYLqQ .9s linear infinite}._gNwVH ._HYLqQ div div:nth-child(-n+9):after{content:\" \";display:block;position:absolute;top:5px;left:-1px;width:2px;height:10px;border-radius:20%;background:#000}._gNwVH ._HYLqQ div div:first-child{transform:rotate(20deg);animation-delay:-.8s}._gNwVH ._HYLqQ div div:nth-child(2){transform:rotate(60deg);animation-delay:-.7s}._gNwVH ._HYLqQ div div:nth-child(3){transform:rotate(100deg);animation-delay:-.6s}._gNwVH ._HYLqQ div div:nth-child(4){transform:rotate(140deg);animation-delay:-.5s}._gNwVH ._HYLqQ div div:nth-child(5){transform:rotate(180deg);animation-delay:-.4s}._gNwVH ._HYLqQ div div:nth-child(6){transform:rotate(220deg);animation-delay:-.3s}._gNwVH ._HYLqQ div div:nth-child(7){transform:rotate(260deg);animation-delay:-.2s}._gNwVH ._HYLqQ div div:nth-child(8){transform:rotate(300deg);animation-delay:-.1s}._gNwVH ._HYLqQ div div:nth-child(9){transform:rotate(340deg);animation-delay:0s}._gNwVH ._Jf-QY div div:nth-child(-n+9):after{top:10px;left:-2px;width:4px;height:18px}._gNwVH ._WhE9c div div:nth-child(-n+9):after{top:2px;left:-1px;width:1.5px;height:6px}._gNwVH ._QF74b div div:nth-child(-n+9):after{top:4px;left:-1px;width:2px;height:7px}._gNwVH ._vkRO6 div div:nth-child(-n+9):after{background:#fff}._gNwVH ._n-J4s{width:100%;height:100%}._gNwVH ._n-J4s._7dUL1{pointer-events:none}._gNwVH ._n-J4s._WAngi{opacity:0}._gNwVH ._n-J4s._QGTe2{opacity:.5}@keyframes _HYLqQ{0%{opacity:1}to{opacity:0}}";
6
6
  if(typeof process !== 'object' || !process.hasOwnProperty('env') || process.env.NODE_ENV !== 'test'){styleInject(css_248z);}
7
7
 
8
8
  export { styles as default, stylesheet };
@@ -89,14 +89,13 @@ const ConditionSet = function ConditionSet(_ref) {
89
89
  }
90
90
  return getSubDataTestId(rootDataTestId, "".concat(prefix, "-").concat(indices.join('-')));
91
91
  }, [fixedSet, rootDataTestId]);
92
- function renderControls(itemType, itemPosition, itemLevel, numberOfSetItems, itemId) {
92
+ function renderControls(itemType, itemPosition, itemLevel, itemId) {
93
93
  return /*#__PURE__*/React__default.createElement(Controls, {
94
94
  handleNewLogicItem: handleNewLogicItem,
95
95
  itemType: itemType,
96
96
  parent: itemPosition.parent,
97
97
  itemIndex: itemPosition.index,
98
98
  itemLevel: itemLevel,
99
- numberOfSetItems: numberOfSetItems,
100
99
  itemId: itemId,
101
100
  "data-testid": getDataTestId('condition-actions', itemPosition)
102
101
  });
@@ -130,7 +129,7 @@ const ConditionSet = function ConditionSet(_ref) {
130
129
  position: conditionPosition,
131
130
  condition: item,
132
131
  firstFocusableElementRef: fixedSet && firstFocusableElementRef && i === 0 ? firstFocusableElementRef : undefined,
133
- conditionControls: !readOnly ? renderControls(LOGIC_TYPE_CONDITION, conditionPosition, level + 1, value.conditions.length, item.id) : undefined
132
+ conditionControls: !readOnly ? renderControls(LOGIC_TYPE_CONDITION, conditionPosition, level + 1, item.id) : undefined
134
133
  }));
135
134
  }
136
135
  if (item.logicType === LOGIC_TYPE_SET) {
@@ -172,7 +171,7 @@ const ConditionSet = function ConditionSet(_ref) {
172
171
  }), /*#__PURE__*/React__default.createElement(DropdownOption, {
173
172
  value: SET_VALUE_ALL,
174
173
  label: String(translations.all)
175
- }))), !readOnly && renderControls(LOGIC_TYPE_SET, position, level, value.conditions.length, value.id)), /*#__PURE__*/React__default.createElement("div", {
174
+ }))), !readOnly && renderControls(LOGIC_TYPE_SET, position, level, value.id)), /*#__PURE__*/React__default.createElement("div", {
176
175
  role: "group",
177
176
  ref: conditionRef
178
177
  }, renderSetChildren()));
@@ -22,7 +22,6 @@ const Controls = function Controls(_ref) {
22
22
  itemIndex,
23
23
  itemLevel,
24
24
  itemId,
25
- numberOfSetItems,
26
25
  'data-testid': dataTestId
27
26
  } = _ref;
28
27
  const {
@@ -32,63 +31,82 @@ const Controls = function Controls(_ref) {
32
31
  defaultSetValue,
33
32
  maxNestedSets,
34
33
  maxConditions,
35
- controlsRef
34
+ controlsRef,
35
+ numberOfItems,
36
+ setNumberOfItems
36
37
  } = useLogicEditorContext();
38
+ const canAddNewCondition = useMemo(() => !maxConditions || numberOfItems < maxConditions, [maxConditions, numberOfItems]);
37
39
  const canAddNewSet = useMemo(() => {
40
+ // Need to have space for two conditions to add a new set, since
41
+ // adding a set automatically adds a condition below.
42
+ if (maxConditions && numberOfItems >= maxConditions - 1) {
43
+ return false;
44
+ }
38
45
  // If "insert condition set below" is clicked on a logic item's control, it's added at the same level.
39
46
  // If "insert condition set below" is clicked on a logic set's control, it's added a level deeper.
40
47
  const levelOfNewSet = itemType === LOGIC_TYPE_CONDITION ? itemLevel : itemLevel + 1;
41
48
  return !fixedSet && levelOfNewSet <= maxNestedSets;
42
- }, [fixedSet, itemLevel, maxNestedSets, itemType]);
49
+ }, [fixedSet, itemLevel, maxNestedSets, itemType, maxConditions, numberOfItems]);
43
50
  const indexOfNewItem = useMemo(() => itemType === LOGIC_TYPE_SET ? 0 : itemIndex + 1, [itemType, itemIndex]);
44
- const menu = useMemo(() => /*#__PURE__*/React__default.createElement(Menu, {
45
- anchor: /*#__PURE__*/React__default.createElement(IconButton, {
46
- "aria-label": translations.conditionActions,
47
- className: styles.controls,
48
- "data-testid": dataTestId
49
- }, /*#__PURE__*/React__default.createElement(EllipsisHorizontalIcon, null)),
50
- ref: node => {
51
- if (node) {
52
- controlsRef.current[itemId] = node;
53
- } else {
54
- controlsRef.current[itemId] = null;
51
+ const menu = useMemo(() => {
52
+ const isRootMenu = itemLevel === 0 && !fixedSet;
53
+ const menuHasNoOptions = isRootMenu && !canAddNewCondition;
54
+ return /*#__PURE__*/React__default.createElement(Menu, {
55
+ anchor: /*#__PURE__*/React__default.createElement(IconButton, {
56
+ "aria-label": translations.conditionActions,
57
+ className: styles.controls,
58
+ "data-testid": dataTestId,
59
+ style: {
60
+ visibility: menuHasNoOptions ? 'hidden' : undefined
61
+ }
62
+ }, /*#__PURE__*/React__default.createElement(EllipsisHorizontalIcon, null)),
63
+ ref: node => {
64
+ if (node) {
65
+ controlsRef.current.set(itemId, node);
66
+ setNumberOfItems(controlsRef.current.size);
67
+ } else {
68
+ controlsRef.current.delete(itemId);
69
+ setNumberOfItems(controlsRef.current.size);
70
+ }
55
71
  }
56
- }
57
- }, !(fixedSet && maxConditions && numberOfSetItems >= maxConditions) && /*#__PURE__*/React__default.createElement(MenuItem, {
58
- value: "add-condition",
59
- onSelect: () => handleNewLogicItem(newCondition(), indexOfNewItem)
60
- }, /*#__PURE__*/React__default.createElement(AddItemIcon, {
61
- "aria-hidden": "true"
62
- }), /*#__PURE__*/React__default.createElement("span", {
63
- className: styles.controlMenuItem
64
- }, translations.insertConditionBelow)), canAddNewSet && /*#__PURE__*/React__default.createElement(MenuItem, {
65
- value: "add-set",
66
- onSelect: () => handleNewLogicItem(newConditionSet(defaultSetValue), indexOfNewItem)
67
- }, /*#__PURE__*/React__default.createElement(FilterIcon, {
68
- "aria-hidden": "true"
69
- }), /*#__PURE__*/React__default.createElement("span", {
70
- className: styles.controlMenuItem
71
- }, translations.insertSetBelow)), (fixedSet && numberOfSetItems > 1 || !fixedSet && itemLevel > 0) && /*#__PURE__*/React__default.createElement(MenuItem, {
72
- value: "delete",
73
- onSelect: e => {
74
- onDelete({
75
- parent,
76
- index: itemIndex
77
- });
78
- // We want to move focus to the previous control
79
- // item when this one is deleted, so we need to
80
- // prevent Menu's default focus behavior
81
- e.preventDefault();
82
- }
83
- }, /*#__PURE__*/React__default.createElement(RemoveItemIcon, {
84
- "aria-hidden": "true"
85
- }), /*#__PURE__*/React__default.createElement("span", {
86
- className: styles.controlMenuItem
87
- }, translations.delete))), [
72
+ }, canAddNewCondition && /*#__PURE__*/React__default.createElement(MenuItem, {
73
+ value: "add-condition",
74
+ onSelect: () => handleNewLogicItem(newCondition(), indexOfNewItem)
75
+ }, /*#__PURE__*/React__default.createElement(AddItemIcon, {
76
+ "aria-hidden": "true"
77
+ }), /*#__PURE__*/React__default.createElement("span", {
78
+ className: styles.controlMenuItem
79
+ }, translations.insertConditionBelow)), canAddNewSet && /*#__PURE__*/React__default.createElement(MenuItem, {
80
+ value: "add-set",
81
+ onSelect: () => handleNewLogicItem(newConditionSet(defaultSetValue), indexOfNewItem)
82
+ }, /*#__PURE__*/React__default.createElement(FilterIcon, {
83
+ "aria-hidden": "true"
84
+ }), /*#__PURE__*/React__default.createElement("span", {
85
+ className: styles.controlMenuItem
86
+ }, translations.insertSetBelow)), (fixedSet && numberOfItems > 1 || !fixedSet && itemLevel > 0) && /*#__PURE__*/React__default.createElement(MenuItem, {
87
+ value: "delete",
88
+ onSelect: e => {
89
+ onDelete({
90
+ parent,
91
+ index: itemIndex
92
+ });
93
+ // We want to move focus to the previous control
94
+ // item when this one is deleted, so we need to
95
+ // prevent Menu's default focus behavior
96
+ e.preventDefault();
97
+ }
98
+ }, /*#__PURE__*/React__default.createElement(RemoveItemIcon, {
99
+ "aria-hidden": "true"
100
+ }), /*#__PURE__*/React__default.createElement("span", {
101
+ className: styles.controlMenuItem
102
+ }, translations.delete)));
103
+ }, [
88
104
  // context
89
- translations, fixedSet, onDelete, defaultSetValue, maxConditions, controlsRef,
105
+ translations, fixedSet, onDelete, defaultSetValue, controlsRef, numberOfItems, setNumberOfItems,
90
106
  // props
91
- handleNewLogicItem, parent, itemIndex, itemLevel, itemId, numberOfSetItems, dataTestId, canAddNewSet, indexOfNewItem]);
107
+ handleNewLogicItem, parent, itemIndex, itemLevel, itemId, dataTestId,
108
+ // variables in scope
109
+ canAddNewSet, canAddNewCondition, indexOfNewItem]);
92
110
  return /*#__PURE__*/React__default.createElement("div", {
93
111
  className: classNames({
94
112
  [styles.conditionControlsContainer]: itemType === LOGIC_TYPE_CONDITION
@@ -1,5 +1,5 @@
1
1
  import _extends from '@babel/runtime-corejs3/helpers/extends';
2
- import React__default, { useMemo, useState, useCallback, useRef } from 'react';
2
+ import React__default, { useMemo, useState, useCallback, useRef, useEffect } from 'react';
3
3
  import classNames from 'classnames';
4
4
  import styles from './LogicEditor2.js';
5
5
  import ConditionSet from './ConditionSet.js';
@@ -48,14 +48,33 @@ const LogicEditor = /*#__PURE__*/React__default.forwardRef((_ref, ref) => {
48
48
  return newState;
49
49
  });
50
50
  }, [onChange]);
51
+ const controlsRef = useRef(new Map());
52
+ const [numberOfItems, setNumberOfItems] = useState(controlsRef.current.size);
53
+ const itemToFocusId = useRef(null);
54
+ useEffect(() => {
55
+ // Must be in a useEffect instead of event handlers to ensure `focus` is called
56
+ // _after_ the root condition control menu is possibly added back into view
57
+ if (itemToFocusId.current !== null) {
58
+ var _controlsRef$current$;
59
+ (_controlsRef$current$ = controlsRef.current.get(itemToFocusId.current)) === null || _controlsRef$current$ === void 0 || _controlsRef$current$.focus();
60
+ itemToFocusId.current = null;
61
+ }
62
+ }, [numberOfItems]);
51
63
  const handleNewLogicItem = useCallback((item, position) => {
64
+ var _position$parent;
65
+ const numberOfItemsBeingAdded = item.logicType === 'set' ? 2 : 1;
66
+ const willReachMaxCondiitons = numberOfItems + numberOfItemsBeingAdded === maxConditions;
67
+ const focusIsOnRootNode = position.index === 0 && ((_position$parent = position.parent) === null || _position$parent === void 0 ? void 0 : _position$parent.parent) === undefined;
68
+ if (focusIsOnRootNode && willReachMaxCondiitons) {
69
+ itemToFocusId.current = item.id;
70
+ }
52
71
  update(prevState => {
53
72
  const newState = shallowCopy(prevState);
54
73
  const parent = getParentSet(newState, position);
55
74
  parent.conditions.splice(position.index, 0, item);
56
75
  return newState;
57
76
  });
58
- }, [update]);
77
+ }, [update, numberOfItems, maxConditions]);
59
78
  const handleSetChange = (newSetValue, position) => {
60
79
  update(prevState => {
61
80
  const rootState = shallowCopy(prevState);
@@ -77,23 +96,28 @@ const LogicEditor = /*#__PURE__*/React__default.forwardRef((_ref, ref) => {
77
96
  return newState;
78
97
  });
79
98
  };
80
- const controlsRef = useRef({});
81
99
  const handleDelete = useCallback(position => {
100
+ let previousItemId;
82
101
  update(prevState => {
83
- let previousItemId = getPreviousItemId(prevState, position);
102
+ previousItemId = getPreviousItemId(prevState, position, fixedSet);
84
103
  const newState = shallowCopy(prevState);
85
104
  const parent = getParentSet(newState, position);
86
105
  parent.conditions.splice(position.index, 1);
87
106
 
88
107
  // If the last condition in a set was deleted, also delete the set.
89
108
  if (parent.conditions.length === 0) {
90
- previousItemId = getPreviousItemId(newState, position.parent);
109
+ previousItemId = getPreviousItemId(newState, position.parent, fixedSet);
91
110
  getParentSet(newState, position.parent).conditions.splice(position.parent.index, 1);
92
111
  }
93
- controlsRef.current[previousItemId].focus();
112
+ if (previousItemId === null) {
113
+ // May be null if first item in fixedSet editor is deleted.
114
+ // In this case focus the new first item in the editor.
115
+ previousItemId = newState.conditions[0].id;
116
+ }
94
117
  return newState;
95
118
  });
96
- }, [update, controlsRef]);
119
+ itemToFocusId.current = previousItemId;
120
+ }, [update, fixedSet]);
97
121
  return /*#__PURE__*/React__default.createElement("div", _extends({}, rest, {
98
122
  role: "group",
99
123
  className: classes,
@@ -113,7 +137,9 @@ const LogicEditor = /*#__PURE__*/React__default.forwardRef((_ref, ref) => {
113
137
  maxConditions,
114
138
  readOnly,
115
139
  rootDataTestId: dataTestId,
116
- controlsRef
140
+ controlsRef,
141
+ numberOfItems,
142
+ setNumberOfItems
117
143
  }
118
144
  }, /*#__PURE__*/React__default.createElement(ConditionSet, {
119
145
  value: state,
@@ -1,8 +1,8 @@
1
1
  import styleInject from './../../__node_modules/style-inject/dist/style-inject.es.js';
2
2
 
3
- var css_248z = "._Aaucd{width:100%}._3LaKB{display:flex;align-items:center}._PAXoH{display:flex;flex-wrap:wrap;grid-gap:4px}._PAXoH._VRcU- :nth-last-child(2){margin-right:42px}._ZTExg{position:relative;padding-left:32px;padding-top:16px}._fZg4T ._ZTExg{padding-top:0;padding-left:16px}._fZg4T ._ZTExg+._ZTExg{margin-top:16px}._Rcqye{position:absolute;left:16px;top:0;height:34px;width:16px;border-left:1px solid #c2c2c2;border-bottom:1px solid #c2c2c2;border-bottom-left-radius:4px}._fZg4T ._ZTExg:first-of-type ._Rcqye{top:16px;border-bottom:none;border-bottom-left-radius:0;border-top:1px solid #c2c2c2;border-top-left-radius:4px}._fZg4T ._Rcqye{top:-16px;left:0}._fZg4T ._ZTExg:not(:first-of-type):not(:last-of-type) ._Rcqye{border-bottom-left-radius:0}._5Xey3{margin-left:-46px}._9Usmq{margin:0 2px 0 4px}._9Usmq.focus-visible,._9Usmq:focus-visible{outline-width:2px}._F7n2m{margin-left:4px}";
4
- var styles = {"set":"_Aaucd","setWrapper":"_3LaKB","condition":"_PAXoH","readOnly":"_VRcU-","branch":"_ZTExg","fixedSet":"_fZg4T","connection":"_Rcqye","conditionControlsContainer":"_5Xey3","controls":"_9Usmq","controlMenuItem":"_F7n2m"};
5
- var stylesheet="._Aaucd{width:100%}._3LaKB{display:flex;align-items:center}._PAXoH{display:flex;flex-wrap:wrap;grid-gap:4px}._PAXoH._VRcU- :nth-last-child(2){margin-right:42px}._ZTExg{position:relative;padding-left:32px;padding-top:16px}._fZg4T ._ZTExg{padding-top:0;padding-left:16px}._fZg4T ._ZTExg+._ZTExg{margin-top:16px}._Rcqye{position:absolute;left:16px;top:0;height:34px;width:16px;border-left:1px solid #c2c2c2;border-bottom:1px solid #c2c2c2;border-bottom-left-radius:4px}._fZg4T ._ZTExg:first-of-type ._Rcqye{top:16px;border-bottom:none;border-bottom-left-radius:0;border-top:1px solid #c2c2c2;border-top-left-radius:4px}._fZg4T ._Rcqye{top:-16px;left:0}._fZg4T ._ZTExg:not(:first-of-type):not(:last-of-type) ._Rcqye{border-bottom-left-radius:0}._5Xey3{margin-left:-46px}._9Usmq{margin:0 2px 0 4px}._9Usmq.focus-visible,._9Usmq:focus-visible{outline-width:2px}._F7n2m{margin-left:4px}";
3
+ var css_248z = "._GiFHr{width:100%}._Z8l6G{display:flex;align-items:center}._q9zRP{display:flex;flex-wrap:wrap;grid-gap:4px}._q9zRP._W2-Wo :nth-last-child(2){margin-right:42px}._MO99L{position:relative;padding-left:32px;padding-top:16px}._XWoNh ._MO99L{padding-top:0;padding-left:16px}._XWoNh ._MO99L+._MO99L{margin-top:16px}._-Qs-r{position:absolute;left:16px;top:0;height:34px;width:16px;border-left:1px solid #c2c2c2;border-bottom:1px solid #c2c2c2;border-bottom-left-radius:4px}._XWoNh ._MO99L:first-of-type ._-Qs-r{top:16px;border-bottom:none;border-bottom-left-radius:0;border-top:1px solid #c2c2c2;border-top-left-radius:4px}._XWoNh ._-Qs-r{top:-16px;left:0}._XWoNh ._MO99L:not(:first-of-type):not(:last-of-type) ._-Qs-r{border-bottom-left-radius:0}._99O3B{margin-left:-46px}._l5Uio{margin:0 2px 0 4px}._l5Uio.focus-visible,._l5Uio:focus-visible{outline-width:2px}._FCkGC{margin-left:4px}";
4
+ var styles = {"set":"_GiFHr","setWrapper":"_Z8l6G","condition":"_q9zRP","readOnly":"_W2-Wo","branch":"_MO99L","fixedSet":"_XWoNh","connection":"_-Qs-r","conditionControlsContainer":"_99O3B","controls":"_l5Uio","controlMenuItem":"_FCkGC"};
5
+ var stylesheet="._GiFHr{width:100%}._Z8l6G{display:flex;align-items:center}._q9zRP{display:flex;flex-wrap:wrap;grid-gap:4px}._q9zRP._W2-Wo :nth-last-child(2){margin-right:42px}._MO99L{position:relative;padding-left:32px;padding-top:16px}._XWoNh ._MO99L{padding-top:0;padding-left:16px}._XWoNh ._MO99L+._MO99L{margin-top:16px}._-Qs-r{position:absolute;left:16px;top:0;height:34px;width:16px;border-left:1px solid #c2c2c2;border-bottom:1px solid #c2c2c2;border-bottom-left-radius:4px}._XWoNh ._MO99L:first-of-type ._-Qs-r{top:16px;border-bottom:none;border-bottom-left-radius:0;border-top:1px solid #c2c2c2;border-top-left-radius:4px}._XWoNh ._-Qs-r{top:-16px;left:0}._XWoNh ._MO99L:not(:first-of-type):not(:last-of-type) ._-Qs-r{border-bottom-left-radius:0}._99O3B{margin-left:-46px}._l5Uio{margin:0 2px 0 4px}._l5Uio.focus-visible,._l5Uio:focus-visible{outline-width:2px}._FCkGC{margin-left:4px}";
6
6
  if(typeof process !== 'object' || !process.hasOwnProperty('env') || process.env.NODE_ENV !== 'test'){styleInject(css_248z);}
7
7
 
8
8
  export { styles as default, stylesheet };
@@ -111,9 +111,12 @@ function walkToRoot(position) {
111
111
  }
112
112
  return root;
113
113
  }
114
- function getPreviousItemId(conditionRoot, position) {
114
+ function getPreviousItemId(conditionRoot, position, fixedSet) {
115
115
  const parentSet = getParentSet(conditionRoot, position);
116
116
  if (position.index === 0) {
117
+ if (fixedSet) {
118
+ return null;
119
+ }
117
120
  // The previous item is the parent
118
121
  return parentSet.id;
119
122
  }