baseui 10.12.1 → 11.0.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.
Files changed (307) hide show
  1. package/README.md +3 -3
  2. package/accordion/accordion.js +60 -13
  3. package/accordion/accordion.js.flow +49 -12
  4. package/accordion/index.d.ts +0 -3
  5. package/accordion/panel.js +7 -6
  6. package/accordion/panel.js.flow +20 -20
  7. package/accordion/stateless-accordion.js +2 -4
  8. package/accordion/stateless-accordion.js.flow +0 -2
  9. package/accordion/types.js.flow +0 -5
  10. package/button/constants.js +1 -2
  11. package/button/constants.js.flow +0 -1
  12. package/button/index.d.ts +0 -1
  13. package/button/styled-components.js +2 -29
  14. package/button/styled-components.js.flow +2 -30
  15. package/checkbox/checkbox.js +6 -30
  16. package/checkbox/checkbox.js.flow +7 -38
  17. package/checkbox/constants.js +2 -1
  18. package/checkbox/constants.js.flow +2 -1
  19. package/checkbox/index.d.ts +4 -6
  20. package/checkbox/index.js +0 -6
  21. package/checkbox/index.js.flow +0 -1
  22. package/checkbox/styled-components.js +52 -149
  23. package/checkbox/styled-components.js.flow +59 -165
  24. package/checkbox/types.js.flow +0 -5
  25. package/data-table/column-categorical.js +1 -1
  26. package/data-table/column-categorical.js.flow +1 -1
  27. package/data-table/column-datetime.js +1 -1
  28. package/data-table/column-datetime.js.flow +3 -1
  29. package/data-table/column.js +6 -2
  30. package/data-table/column.js.flow +9 -7
  31. package/data-table/data-table.js +10 -2
  32. package/data-table/data-table.js.flow +4 -1
  33. package/data-table/header-cell.js +3 -0
  34. package/data-table/header-cell.js.flow +1 -1
  35. package/data-table/index.d.ts +7 -8
  36. package/data-table/stateful-data-table.js +2 -1
  37. package/data-table/stateful-data-table.js.flow +1 -0
  38. package/data-table/types.js.flow +8 -0
  39. package/datepicker/calendar.js +28 -15
  40. package/datepicker/calendar.js.flow +31 -14
  41. package/datepicker/constants.js +12 -2
  42. package/datepicker/constants.js.flow +10 -0
  43. package/datepicker/datepicker.js +117 -86
  44. package/datepicker/datepicker.js.flow +123 -66
  45. package/datepicker/day.js +85 -34
  46. package/datepicker/day.js.flow +118 -54
  47. package/datepicker/locale.js.flow +0 -1
  48. package/datepicker/month.js +3 -1
  49. package/datepicker/month.js.flow +2 -0
  50. package/datepicker/stateful-calendar.js +6 -1
  51. package/datepicker/stateful-calendar.js.flow +8 -1
  52. package/datepicker/stateful-container.js +23 -2
  53. package/datepicker/stateful-container.js.flow +17 -3
  54. package/datepicker/stateful-datepicker.js +6 -1
  55. package/datepicker/stateful-datepicker.js.flow +7 -1
  56. package/datepicker/styled-components.js +23 -1
  57. package/datepicker/styled-components.js.flow +12 -2
  58. package/datepicker/types.js.flow +46 -43
  59. package/datepicker/utils/date-helpers.js +30 -0
  60. package/datepicker/utils/date-helpers.js.flow +12 -0
  61. package/datepicker/week.js +3 -1
  62. package/datepicker/week.js.flow +2 -0
  63. package/es/accordion/accordion.js +52 -12
  64. package/es/accordion/panel.js +7 -5
  65. package/es/accordion/stateless-accordion.js +2 -4
  66. package/es/button/constants.js +1 -2
  67. package/es/button/styled-components.js +2 -29
  68. package/es/checkbox/checkbox.js +7 -32
  69. package/es/checkbox/constants.js +2 -1
  70. package/es/checkbox/index.js +1 -1
  71. package/es/checkbox/styled-components.js +51 -146
  72. package/es/data-table/column-categorical.js +1 -1
  73. package/es/data-table/column-datetime.js +1 -1
  74. package/es/data-table/column.js +6 -2
  75. package/es/data-table/data-table.js +6 -2
  76. package/es/data-table/header-cell.js +3 -0
  77. package/es/data-table/stateful-data-table.js +2 -1
  78. package/es/datepicker/calendar.js +28 -15
  79. package/es/datepicker/constants.js +8 -0
  80. package/es/datepicker/datepicker.js +106 -79
  81. package/es/datepicker/day.js +77 -34
  82. package/es/datepicker/month.js +3 -1
  83. package/es/datepicker/stateful-calendar.js +6 -1
  84. package/es/datepicker/stateful-container.js +22 -2
  85. package/es/datepicker/stateful-datepicker.js +6 -1
  86. package/es/datepicker/styled-components.js +8 -2
  87. package/es/datepicker/types.js +1 -1
  88. package/es/datepicker/utils/date-helpers.js +16 -0
  89. package/es/datepicker/week.js +3 -1
  90. package/es/file-uploader/file-uploader.js +4 -4
  91. package/es/form-control/styled-components.js +0 -1
  92. package/es/header-navigation/styled-components.js +3 -3
  93. package/es/helpers/overrides.js +1 -2
  94. package/es/input/styled-components.js +4 -4
  95. package/es/layer/layer.js +4 -4
  96. package/es/list/list-item.js +5 -1
  97. package/es/list/menu-adapter.js +4 -0
  98. package/es/locale/index.js +0 -7
  99. package/es/menu/stateful-container.js +0 -1
  100. package/es/menu/styled-components.js +1 -1
  101. package/es/modal/index.js +1 -1
  102. package/es/modal/modal.js +19 -65
  103. package/es/modal/styled-components.js +12 -48
  104. package/es/phone-input/default-props.js +1 -1
  105. package/es/phone-input/index.js +0 -4
  106. package/es/phone-input/phone-input-lite.js +55 -31
  107. package/es/radio/radio.js +1 -7
  108. package/es/radio/radiogroup.js +3 -28
  109. package/es/radio/styled-components.js +4 -5
  110. package/es/rating/styled-components.js +3 -3
  111. package/es/select/index.js +1 -2
  112. package/es/select/select-component.js +20 -20
  113. package/es/select/styled-components.js +21 -17
  114. package/es/snackbar/snackbar-context.js +1 -1
  115. package/es/snackbar/styled-components.js +2 -2
  116. package/es/spinner/index.js +3 -9
  117. package/es/spinner/styled-components.js +2 -32
  118. package/es/table/filter.js +3 -3
  119. package/es/tag/styled-components.js +1 -1
  120. package/es/themes/dark-theme/color-component-tokens.js +0 -38
  121. package/es/themes/dark-theme/color-tokens.js +0 -2
  122. package/es/themes/dark-theme/create-dark-theme.js +0 -2
  123. package/es/themes/dark-theme/dark-theme.js +0 -2
  124. package/es/themes/light-theme/color-component-tokens.js +0 -38
  125. package/es/themes/light-theme/color-tokens.js +0 -2
  126. package/es/themes/light-theme/create-light-theme.js +0 -2
  127. package/es/themes/light-theme/light-theme.js +0 -2
  128. package/es/timepicker/timepicker.js +1 -8
  129. package/es/typography/index.js +1 -31
  130. package/esm/accordion/accordion.js +60 -13
  131. package/esm/accordion/panel.js +7 -6
  132. package/esm/accordion/stateless-accordion.js +2 -4
  133. package/esm/button/constants.js +1 -2
  134. package/esm/button/styled-components.js +2 -29
  135. package/esm/checkbox/checkbox.js +7 -30
  136. package/esm/checkbox/constants.js +2 -1
  137. package/esm/checkbox/index.js +1 -1
  138. package/esm/checkbox/styled-components.js +52 -147
  139. package/esm/data-table/column-categorical.js +1 -1
  140. package/esm/data-table/column-datetime.js +1 -1
  141. package/esm/data-table/column.js +6 -2
  142. package/esm/data-table/data-table.js +10 -2
  143. package/esm/data-table/header-cell.js +3 -0
  144. package/esm/data-table/stateful-data-table.js +2 -1
  145. package/esm/datepicker/calendar.js +28 -15
  146. package/esm/datepicker/constants.js +8 -0
  147. package/esm/datepicker/datepicker.js +116 -86
  148. package/esm/datepicker/day.js +84 -34
  149. package/esm/datepicker/month.js +3 -1
  150. package/esm/datepicker/stateful-calendar.js +6 -1
  151. package/esm/datepicker/stateful-container.js +23 -2
  152. package/esm/datepicker/stateful-datepicker.js +6 -1
  153. package/esm/datepicker/styled-components.js +24 -2
  154. package/esm/datepicker/types.js +1 -1
  155. package/esm/datepicker/utils/date-helpers.js +30 -0
  156. package/esm/datepicker/week.js +3 -1
  157. package/esm/file-uploader/file-uploader.js +4 -4
  158. package/esm/form-control/styled-components.js +0 -1
  159. package/esm/header-navigation/styled-components.js +3 -3
  160. package/esm/helpers/overrides.js +1 -2
  161. package/esm/input/styled-components.js +4 -4
  162. package/esm/layer/layer.js +4 -4
  163. package/esm/list/list-item.js +5 -1
  164. package/esm/list/menu-adapter.js +4 -0
  165. package/esm/locale/index.js +0 -7
  166. package/esm/menu/stateful-container.js +0 -1
  167. package/esm/menu/styled-components.js +1 -1
  168. package/esm/modal/index.js +1 -1
  169. package/esm/modal/modal.js +28 -71
  170. package/esm/modal/styled-components.js +6 -38
  171. package/esm/phone-input/default-props.js +1 -1
  172. package/esm/phone-input/index.js +0 -4
  173. package/esm/phone-input/phone-input-lite.js +60 -37
  174. package/esm/radio/radio.js +1 -7
  175. package/esm/radio/radiogroup.js +3 -28
  176. package/esm/radio/styled-components.js +4 -5
  177. package/esm/rating/styled-components.js +3 -3
  178. package/esm/select/index.js +1 -2
  179. package/esm/select/select-component.js +20 -20
  180. package/esm/select/styled-components.js +21 -14
  181. package/esm/snackbar/snackbar-context.js +1 -1
  182. package/esm/snackbar/styled-components.js +2 -2
  183. package/esm/spinner/index.js +3 -9
  184. package/esm/spinner/styled-components.js +2 -40
  185. package/esm/table/filter.js +3 -3
  186. package/esm/tag/styled-components.js +1 -1
  187. package/esm/themes/dark-theme/color-component-tokens.js +0 -38
  188. package/esm/themes/dark-theme/color-tokens.js +0 -2
  189. package/esm/themes/dark-theme/create-dark-theme.js +1 -2
  190. package/esm/themes/dark-theme/dark-theme.js +1 -2
  191. package/esm/themes/light-theme/color-component-tokens.js +0 -38
  192. package/esm/themes/light-theme/color-tokens.js +0 -2
  193. package/esm/themes/light-theme/create-light-theme.js +1 -2
  194. package/esm/themes/light-theme/light-theme.js +1 -2
  195. package/esm/timepicker/timepicker.js +1 -8
  196. package/esm/typography/index.js +1 -35
  197. package/file-uploader/file-uploader.js +3 -3
  198. package/file-uploader/file-uploader.js.flow +4 -4
  199. package/form-control/index.d.ts +9 -0
  200. package/form-control/styled-components.js +0 -1
  201. package/form-control/styled-components.js.flow +0 -1
  202. package/header-navigation/styled-components.js +3 -3
  203. package/header-navigation/styled-components.js.flow +3 -3
  204. package/helpers/overrides.js +1 -2
  205. package/helpers/overrides.js.flow +1 -1
  206. package/input/index.d.ts +5 -9
  207. package/input/styled-components.js +4 -4
  208. package/input/styled-components.js.flow +4 -4
  209. package/layer/layer.js +4 -4
  210. package/layer/layer.js.flow +4 -3
  211. package/list/list-item.js +5 -1
  212. package/list/list-item.js.flow +4 -0
  213. package/list/menu-adapter.js +4 -0
  214. package/list/menu-adapter.js.flow +4 -0
  215. package/list/types.js.flow +4 -0
  216. package/locale/index.js +0 -7
  217. package/locale/index.js.flow +0 -7
  218. package/locale.ts +0 -1
  219. package/menu/index.d.ts +1 -3
  220. package/menu/stateful-container.js +0 -1
  221. package/menu/stateful-container.js.flow +0 -1
  222. package/menu/styled-components.js +1 -1
  223. package/menu/styled-components.js.flow +1 -1
  224. package/modal/index.d.ts +4 -6
  225. package/modal/index.js +0 -6
  226. package/modal/index.js.flow +0 -1
  227. package/modal/modal.js +27 -70
  228. package/modal/modal.js.flow +17 -83
  229. package/modal/styled-components.js +7 -40
  230. package/modal/styled-components.js.flow +12 -44
  231. package/modal/types.js.flow +1 -10
  232. package/package.json +3 -2
  233. package/phone-input/default-props.js +1 -1
  234. package/phone-input/default-props.js.flow +1 -1
  235. package/phone-input/index.d.ts +0 -1
  236. package/phone-input/index.js +0 -36
  237. package/phone-input/index.js.flow +0 -4
  238. package/phone-input/phone-input-lite.js +63 -38
  239. package/phone-input/phone-input-lite.js.flow +66 -44
  240. package/radio/index.d.ts +4 -9
  241. package/radio/radio.js +1 -7
  242. package/radio/radio.js.flow +1 -8
  243. package/radio/radiogroup.js +3 -28
  244. package/radio/radiogroup.js.flow +2 -26
  245. package/radio/styled-components.js +4 -5
  246. package/radio/styled-components.js.flow +3 -4
  247. package/radio/types.js.flow +4 -15
  248. package/rating/styled-components.js +3 -3
  249. package/rating/styled-components.js.flow +3 -3
  250. package/select/index.d.ts +0 -2
  251. package/select/index.js +0 -6
  252. package/select/index.js.flow +0 -2
  253. package/select/select-component.js +23 -24
  254. package/select/select-component.js.flow +25 -14
  255. package/select/styled-components.js +23 -17
  256. package/select/styled-components.js.flow +17 -12
  257. package/snackbar/snackbar-context.js +1 -1
  258. package/snackbar/snackbar-context.js.flow +1 -1
  259. package/snackbar/styled-components.js +1 -1
  260. package/snackbar/styled-components.js.flow +11 -11
  261. package/spinner/index.d.ts +5 -18
  262. package/spinner/index.js +2 -68
  263. package/spinner/index.js.flow +2 -27
  264. package/spinner/styled-components.js +9 -45
  265. package/spinner/styled-components.js.flow +2 -34
  266. package/spinner/types.js.flow +1 -19
  267. package/styles/types.js.flow +0 -2
  268. package/table/filter.js +3 -3
  269. package/table/filter.js.flow +3 -3
  270. package/tag/styled-components.js +1 -1
  271. package/tag/styled-components.js.flow +1 -1
  272. package/tag/types.js.flow +1 -1
  273. package/theme.ts +0 -81
  274. package/themes/dark-theme/color-component-tokens.js +0 -38
  275. package/themes/dark-theme/color-component-tokens.js.flow +0 -42
  276. package/themes/dark-theme/color-tokens.js +0 -2
  277. package/themes/dark-theme/color-tokens.js.flow +0 -2
  278. package/themes/dark-theme/create-dark-theme.js +1 -3
  279. package/themes/dark-theme/create-dark-theme.js.flow +0 -2
  280. package/themes/dark-theme/dark-theme.js +1 -3
  281. package/themes/dark-theme/dark-theme.js.flow +0 -2
  282. package/themes/light-theme/color-component-tokens.js +0 -38
  283. package/themes/light-theme/color-component-tokens.js.flow +0 -43
  284. package/themes/light-theme/color-tokens.js +0 -2
  285. package/themes/light-theme/color-tokens.js.flow +0 -2
  286. package/themes/light-theme/create-light-theme.js +1 -3
  287. package/themes/light-theme/create-light-theme.js.flow +0 -2
  288. package/themes/light-theme/light-theme.js +1 -3
  289. package/themes/light-theme/light-theme.js.flow +0 -2
  290. package/themes/types.js.flow +0 -68
  291. package/timepicker/timepicker.js +1 -8
  292. package/timepicker/timepicker.js.flow +4 -10
  293. package/typography/index.d.ts +0 -23
  294. package/typography/index.js +2 -57
  295. package/typography/index.js.flow +0 -31
  296. package/es/spinner/spinner.js +0 -68
  297. package/es/themes/dark-theme/color-deprecated-semantic-tokens.js +0 -35
  298. package/es/themes/light-theme/color-deprecated-semantic-tokens.js +0 -35
  299. package/esm/spinner/spinner.js +0 -125
  300. package/esm/themes/dark-theme/color-deprecated-semantic-tokens.js +0 -38
  301. package/esm/themes/light-theme/color-deprecated-semantic-tokens.js +0 -38
  302. package/spinner/spinner.js +0 -136
  303. package/spinner/spinner.js.flow +0 -75
  304. package/themes/dark-theme/color-deprecated-semantic-tokens.js +0 -50
  305. package/themes/dark-theme/color-deprecated-semantic-tokens.js.flow +0 -42
  306. package/themes/light-theme/color-deprecated-semantic-tokens.js +0 -50
  307. package/themes/light-theme/color-deprecated-semantic-tokens.js.flow +0 -42
@@ -32,7 +32,7 @@ LICENSE file in the root directory of this source tree.
32
32
  */
33
33
  import * as React from 'react';
34
34
  import { getOverride, getOverrideProps } from '../helpers/overrides.js';
35
- import { Checkmark as StyledCheckmark, Input as StyledInput, Label as StyledLabel, Root as StyledRoot, Toggle as StyledToggle, ToggleInner as StyledToggleInner, ToggleTrack as StyledToggleTrack } from './styled-components.js';
35
+ import { Checkmark as StyledCheckmark, Input as StyledInput, Label as StyledLabel, Root as StyledRoot, Toggle as StyledToggle, ToggleTrack as StyledToggleTrack } from './styled-components.js';
36
36
  import { STYLE_TYPE } from './constants.js';
37
37
  import { isFocusVisible } from '../utils/focusVisible.js';
38
38
 
@@ -124,10 +124,6 @@ var StatelessCheckbox = /*#__PURE__*/function (_React$Component) {
124
124
  }
125
125
  });
126
126
 
127
- _defineProperty(_assertThisInitialized(_this), "isToggle", function () {
128
- return _this.props.checkmarkType === STYLE_TYPE.toggle || _this.props.checkmarkType === STYLE_TYPE.toggle_round;
129
- });
130
-
131
127
  return _this;
132
128
  }
133
129
 
@@ -140,32 +136,19 @@ var StatelessCheckbox = /*#__PURE__*/function (_React$Component) {
140
136
 
141
137
  if (autoFocus && inputRef.current) {
142
138
  inputRef.current.focus();
143
- } // TODO(v11)
144
-
145
-
146
- if (process.env.NODE_ENV !== "production") {
147
- if (this.props.checkmarkType === STYLE_TYPE.toggle) {
148
- console.warn("baseui:Checkbox The STYLE_TYPE.toggle value on the 'checkmarkType' prop does not conform to the current base design specification. " + 'Please update your code to STYLE_TYPE.toggle_round. This will be updated automatically in a future major version.');
149
- }
150
-
151
- if (this.props.isError) {
152
- console.warn('baseui:Checkbox Property "isError" will be removed in the next major version. Use "error" property instead.');
153
- }
154
139
  }
155
140
  }
156
141
  }, {
157
142
  key: "render",
158
143
  value: function render() {
159
- var checkmarkType = this.props.checkmarkType;
160
144
  var _this$props2 = this.props,
161
145
  _this$props2$override = _this$props2.overrides,
162
146
  overrides = _this$props2$override === void 0 ? {} : _this$props2$override,
163
147
  onChange = _this$props2.onChange,
164
148
  _this$props2$labelPla = _this$props2.labelPlacement,
165
- labelPlacement = _this$props2$labelPla === void 0 ? this.isToggle() ? 'left' : 'right' : _this$props2$labelPla,
149
+ labelPlacement = _this$props2$labelPla === void 0 ? this.props.checkmarkType === STYLE_TYPE.toggle ? 'left' : 'right' : _this$props2$labelPla,
166
150
  inputRef = _this$props2.inputRef,
167
151
  isIndeterminate = _this$props2.isIndeterminate,
168
- isError = _this$props2.isError,
169
152
  error = _this$props2.error,
170
153
  disabled = _this$props2.disabled,
171
154
  value = _this$props2.value,
@@ -180,14 +163,12 @@ var StatelessCheckbox = /*#__PURE__*/function (_React$Component) {
180
163
  LabelOverride = overrides.Label,
181
164
  InputOverride = overrides.Input,
182
165
  ToggleOverride = overrides.Toggle,
183
- ToggleInnerOverride = overrides.ToggleInner,
184
166
  ToggleTrackOverride = overrides.ToggleTrack;
185
167
  var Root = getOverride(RootOverride) || StyledRoot;
186
168
  var Checkmark = getOverride(CheckmarkOverride) || StyledCheckmark;
187
169
  var Label = getOverride(LabelOverride) || StyledLabel;
188
170
  var Input = getOverride(InputOverride) || StyledInput;
189
171
  var Toggle = getOverride(ToggleOverride) || StyledToggle;
190
- var ToggleInner = getOverride(ToggleInnerOverride) || StyledToggleInner;
191
172
  var ToggleTrack = getOverride(ToggleTrackOverride) || StyledToggleTrack;
192
173
  var inputEvents = {
193
174
  onChange: onChange,
@@ -205,17 +186,14 @@ var StatelessCheckbox = /*#__PURE__*/function (_React$Component) {
205
186
  $isFocusVisible: this.state.isFocusVisible,
206
187
  $isHovered: this.state.isHovered,
207
188
  $isActive: this.state.isActive,
208
- $isError: isError,
209
189
  $error: error,
210
190
  $checked: checked,
211
191
  $isIndeterminate: isIndeterminate,
212
192
  $required: required,
213
193
  $disabled: disabled,
214
- $value: value,
215
- $checkmarkType: checkmarkType
216
- }; // TODO(v11) - add check for children (#2172)
217
-
218
- var labelComp = /*#__PURE__*/React.createElement(Label, _extends({
194
+ $value: value
195
+ };
196
+ var labelComp = children && /*#__PURE__*/React.createElement(Label, _extends({
219
197
  $labelPlacement: labelPlacement
220
198
  }, sharedProps, getOverrideProps(LabelOverride)), this.props.containsInteractiveElement ?
221
199
  /*#__PURE__*/
@@ -230,7 +208,7 @@ var StatelessCheckbox = /*#__PURE__*/function (_React$Component) {
230
208
  "data-baseweb": "checkbox",
231
209
  title: title || null,
232
210
  $labelPlacement: labelPlacement
233
- }, sharedProps, mouseEvents, getOverrideProps(RootOverride)), (labelPlacement === 'top' || labelPlacement === 'left') && labelComp, this.isToggle() ? /*#__PURE__*/React.createElement(ToggleTrack, _extends({}, sharedProps, getOverrideProps(ToggleTrackOverride)), /*#__PURE__*/React.createElement(Toggle, _extends({}, sharedProps, getOverrideProps(ToggleOverride)), /*#__PURE__*/React.createElement(ToggleInner, _extends({}, sharedProps, getOverrideProps(ToggleInnerOverride))))) : /*#__PURE__*/React.createElement(Checkmark, _extends({}, sharedProps, getOverrideProps(CheckmarkOverride))), /*#__PURE__*/React.createElement(Input, _extends({
211
+ }, sharedProps, mouseEvents, getOverrideProps(RootOverride)), (labelPlacement === 'top' || labelPlacement === 'left') && labelComp, this.props.checkmarkType === STYLE_TYPE.toggle ? /*#__PURE__*/React.createElement(ToggleTrack, _extends({}, sharedProps, getOverrideProps(ToggleTrackOverride)), /*#__PURE__*/React.createElement(Toggle, _extends({}, sharedProps, getOverrideProps(ToggleOverride)))) : /*#__PURE__*/React.createElement(Checkmark, _extends({}, sharedProps, getOverrideProps(CheckmarkOverride))), /*#__PURE__*/React.createElement(Input, _extends({
234
212
  value: value,
235
213
  name: name,
236
214
  checked: checked,
@@ -239,7 +217,7 @@ var StatelessCheckbox = /*#__PURE__*/function (_React$Component) {
239
217
  "aria-checked": isIndeterminate ? 'mixed' : checked,
240
218
  "aria-describedby": this.props['aria-describedby'],
241
219
  "aria-errormessage": this.props['aria-errormessage'],
242
- "aria-invalid": error || isError || null,
220
+ "aria-invalid": error || null,
243
221
  "aria-required": required || null,
244
222
  disabled: disabled,
245
223
  type: type,
@@ -262,7 +240,6 @@ _defineProperty(StatelessCheckbox, "defaultProps", {
262
240
  autoFocus: false,
263
241
  isIndeterminate: false,
264
242
  inputRef: /*#__PURE__*/React.createRef(),
265
- isError: false,
266
243
  error: false,
267
244
  type: 'checkbox',
268
245
  checkmarkType: STYLE_TYPE.default,
@@ -12,7 +12,8 @@ export var STATE_TYPE = {
12
12
  export var STYLE_TYPE = Object.freeze({
13
13
  default: 'default',
14
14
  toggle: 'toggle',
15
- toggle_round: 'toggle_round'
15
+ // maintaining key with aliased value to assist in transition to v11 but will be removed soon after release
16
+ toggle_round: 'toggle'
16
17
  });
17
18
  export var LABEL_PLACEMENT = Object.freeze({
18
19
  top: 'top',
@@ -8,5 +8,5 @@ export { default as StatefulCheckbox } from './stateful-checkbox.js';
8
8
  export { default as StatefulContainer } from './stateful-checkbox-container.js';
9
9
  export { default as Checkbox } from './checkbox.js'; // Styled elements
10
10
 
11
- export { Root as StyledRoot, Checkmark as StyledCheckmark, Label as StyledLabel, Input as StyledInput, Toggle as StyledToggle, ToggleInner as StyledToggleInner, ToggleTrack as StyledToggleTrack } from './styled-components.js';
11
+ export { Root as StyledRoot, Checkmark as StyledCheckmark, Label as StyledLabel, Input as StyledInput, Toggle as StyledToggle, ToggleTrack as StyledToggleTrack } from './styled-components.js';
12
12
  export { STATE_TYPE, STYLE_TYPE, LABEL_PLACEMENT } from './constants.js'; // Flow
@@ -10,13 +10,11 @@ Copyright (c) Uber Technologies, Inc.
10
10
  This source code is licensed under the MIT license found in the
11
11
  LICENSE file in the root directory of this source tree.
12
12
  */
13
- import { styled, expandBorderStyles } from '../styles/index.js';
14
- import { STYLE_TYPE } from './constants.js';
13
+ import { styled } from '../styles/index.js';
15
14
 
16
15
  function getBorderColor(props) {
17
16
  var $disabled = props.$disabled,
18
17
  $checked = props.$checked,
19
- $isError = props.$isError,
20
18
  $error = props.$error,
21
19
  $isIndeterminate = props.$isIndeterminate,
22
20
  $theme = props.$theme,
@@ -27,8 +25,8 @@ function getBorderColor(props) {
27
25
  return colors.tickFillDisabled;
28
26
  } else if ($checked || $isIndeterminate) {
29
27
  return 'transparent';
30
- } else if ($error || $isError) {
31
- return colors.borderError;
28
+ } else if ($error) {
29
+ return colors.borderNegative;
32
30
  } else if ($isFocusVisible) {
33
31
  return colors.borderSelected;
34
32
  } else {
@@ -76,26 +74,19 @@ function getBackgroundColor(props) {
76
74
  var $disabled = props.$disabled,
77
75
  $checked = props.$checked,
78
76
  $isIndeterminate = props.$isIndeterminate,
79
- $isError = props.$isError,
80
77
  $error = props.$error,
81
78
  $isHovered = props.$isHovered,
82
79
  $isActive = props.$isActive,
83
- $theme = props.$theme,
84
- $checkmarkType = props.$checkmarkType;
85
- var isToggle = $checkmarkType === STYLE_TYPE.toggle;
80
+ $theme = props.$theme;
86
81
  var colors = $theme.colors;
87
82
 
88
83
  if ($disabled) {
89
- if (isToggle) {
90
- return colors.toggleFillDisabled;
91
- }
92
-
93
84
  if ($checked || $isIndeterminate) {
94
85
  return colors.tickFillDisabled;
95
86
  } else {
96
87
  return colors.tickFill;
97
88
  }
98
- } else if (($error || $isError) && ($isIndeterminate || $checked)) {
89
+ } else if ($error && ($isIndeterminate || $checked)) {
99
90
  if ($isActive) {
100
91
  return colors.tickFillErrorSelectedHoverActive;
101
92
  } else if ($isHovered) {
@@ -103,7 +94,7 @@ function getBackgroundColor(props) {
103
94
  } else {
104
95
  return colors.tickFillErrorSelected;
105
96
  }
106
- } else if ($error || $isError) {
97
+ } else if ($error) {
107
98
  if ($isActive) {
108
99
  return colors.tickFillErrorHoverActive;
109
100
  } else if ($isHovered) {
@@ -121,11 +112,11 @@ function getBackgroundColor(props) {
121
112
  }
122
113
  } else {
123
114
  if ($isActive) {
124
- return isToggle ? colors.sliderTrackFillActive : colors.tickFillActive;
115
+ return colors.tickFillActive;
125
116
  } else if ($isHovered) {
126
- return isToggle ? colors.sliderTrackFillHover : colors.tickFillHover;
117
+ return colors.tickFillHover;
127
118
  } else {
128
- return isToggle ? colors.toggleTrackFill : colors.tickFill;
119
+ return colors.tickFill;
129
120
  }
130
121
  }
131
122
  }
@@ -152,14 +143,13 @@ Root.displayName = "Root";
152
143
  export var Checkmark = styled('span', function (props) {
153
144
  var $checked = props.$checked,
154
145
  $disabled = props.$disabled,
155
- $isError = props.$isError,
156
146
  $error = props.$error,
157
147
  $isIndeterminate = props.$isIndeterminate,
158
148
  $theme = props.$theme,
159
149
  $isFocusVisible = props.$isFocusVisible;
160
150
  var sizing = $theme.sizing,
161
151
  animation = $theme.animation;
162
- var tickColor = $disabled ? $theme.colors.tickMarkFillDisabled : $isError || $error ? $theme.colors.tickMarkFillError : $theme.colors.tickMarkFill;
152
+ var tickColor = $disabled ? $theme.colors.tickMarkFillDisabled : $error ? $theme.colors.tickMarkFillError : $theme.colors.tickMarkFill;
163
153
  var indeterminate = encodeURIComponent("\n <svg width=\"14\" height=\"4\" viewBox=\"0 0 14 4\" fill=\"none\" xmlns=\"http://www.w3.org/2000/svg\">\n <path d=\"M14 0.5H0V3.5H14V0.5Z\" fill=\"".concat(tickColor, "\"/>\n </svg>\n "));
164
154
  var check = encodeURIComponent("\n <svg width=\"17\" height=\"13\" viewBox=\"0 0 17 13\" fill=\"none\" xmlns=\"http://www.w3.org/2000/svg\">\n <path d=\"M6.50002 12.6L0.400024 6.60002L2.60002 4.40002L6.50002 8.40002L13.9 0.900024L16.1 3.10002L6.50002 12.6Z\" fill=\"".concat(tickColor, "\"/>\n </svg>\n "));
165
155
  var borderRadius = $theme.borders.inputBorderRadius;
@@ -206,11 +196,9 @@ export var Checkmark = styled('span', function (props) {
206
196
  });
207
197
  Checkmark.displayName = "Checkmark";
208
198
  export var Label = styled('div', function (props) {
209
- var $theme = props.$theme,
210
- $checkmarkType = props.$checkmarkType;
199
+ var $theme = props.$theme;
211
200
  var typography = $theme.typography;
212
201
  return _objectSpread(_objectSpread(_objectSpread({
213
- flex: $checkmarkType === STYLE_TYPE.toggle ? 'auto' : null,
214
202
  verticalAlign: 'middle'
215
203
  }, getLabelPadding(props)), {}, {
216
204
  color: getLabelColor(props)
@@ -231,137 +219,54 @@ export var Input = styled('input', {
231
219
  });
232
220
  Input.displayName = "Input";
233
221
  export var Toggle = styled('div', function (props) {
234
- if (props.$checkmarkType === STYLE_TYPE.toggle) {
235
- var borderRadius = props.$theme.borders.useRoundedCorners ? props.$theme.borders.radius200 : null;
236
- return _objectSpread(_objectSpread({}, expandBorderStyles(props.$theme.borders.border300)), {}, {
237
- alignItems: 'center',
238
- backgroundColor: props.$theme.colors.mono100,
239
- borderTopLeftRadius: borderRadius,
240
- borderTopRightRadius: borderRadius,
241
- borderBottomRightRadius: borderRadius,
242
- borderBottomLeftRadius: borderRadius,
243
- boxShadow: props.$isFocusVisible ? "0 0 0 3px ".concat(props.$theme.colors.accent) : props.$theme.lighting.shadow400,
244
- outline: 'none',
245
- display: 'flex',
246
- justifyContent: 'center',
247
- height: props.$theme.sizing.scale800,
248
- width: props.$theme.sizing.scale800
249
- });
250
- }
251
-
252
- if (props.$checkmarkType === STYLE_TYPE.toggle_round) {
253
- var backgroundColor = props.$theme.colors.toggleFill;
254
-
255
- if (props.$disabled) {
256
- backgroundColor = props.$theme.colors.toggleFillDisabled;
257
- } else if (props.$checked && (props.$error || props.$isError)) {
258
- backgroundColor = props.$theme.colors.borderError;
259
- } else if (props.$checked) {
260
- backgroundColor = props.$theme.colors.toggleFillChecked;
261
- }
262
-
263
- return {
264
- backgroundColor: backgroundColor,
265
- borderTopLeftRadius: '50%',
266
- borderTopRightRadius: '50%',
267
- borderBottomRightRadius: '50%',
268
- borderBottomLeftRadius: '50%',
269
- boxShadow: props.$isFocusVisible ? "0 0 0 3px ".concat(props.$theme.colors.accent) : props.$isHovered && !props.$disabled ? props.$theme.lighting.shadow500 : props.$theme.lighting.shadow400,
270
- outline: 'none',
271
- height: props.$theme.sizing.scale700,
272
- width: props.$theme.sizing.scale700,
273
- transform: props.$checked ? "translateX(".concat(props.$theme.direction === 'rtl' ? '-100%' : '100%', ")") : null,
274
- transition: "transform ".concat(props.$theme.animation.timing200)
275
- };
222
+ var backgroundColor = props.$theme.colors.toggleFill;
223
+
224
+ if (props.$disabled) {
225
+ backgroundColor = props.$theme.colors.toggleFillDisabled;
226
+ } else if (props.$checked && props.$error) {
227
+ backgroundColor = props.$theme.colors.tickFillErrorSelected;
228
+ } else if (props.$checked) {
229
+ backgroundColor = props.$theme.colors.toggleFillChecked;
276
230
  }
277
231
 
278
- return {};
232
+ return {
233
+ backgroundColor: backgroundColor,
234
+ borderTopLeftRadius: '50%',
235
+ borderTopRightRadius: '50%',
236
+ borderBottomRightRadius: '50%',
237
+ borderBottomLeftRadius: '50%',
238
+ boxShadow: props.$isFocusVisible ? "0 0 0 3px ".concat(props.$theme.colors.accent) : props.$isHovered && !props.$disabled ? props.$theme.lighting.shadow500 : props.$theme.lighting.shadow400,
239
+ outline: 'none',
240
+ height: props.$theme.sizing.scale700,
241
+ width: props.$theme.sizing.scale700,
242
+ transform: props.$checked ? "translateX(".concat(props.$theme.direction === 'rtl' ? '-100%' : '100%', ")") : null,
243
+ transition: "transform ".concat(props.$theme.animation.timing200)
244
+ };
279
245
  });
280
246
  Toggle.displayName = "Toggle";
281
- export var ToggleInner = styled('div', function (props) {
282
- if (props.$checkmarkType === STYLE_TYPE.toggle) {
283
- // eslint-disable-next-line no-inner-declarations
284
- var backgroundColor = function backgroundColor() {
285
- if (props.$disabled) {
286
- return props.$theme.colors.sliderHandleInnerFillDisabled;
287
- }
288
-
289
- if (props.$isActive && props.$checked) {
290
- return props.$theme.colors.sliderHandleInnerFillSelectedActive;
291
- }
292
-
293
- if (props.$isHovered && props.$checked) {
294
- return props.$theme.colors.sliderHandleInnerFillSelectedHover;
295
- }
296
-
297
- return props.$theme.colors.toggleTrackFill;
298
- };
299
-
300
- return {
301
- height: props.$theme.sizing.scale300,
302
- width: props.$theme.sizing.scale0,
303
- borderTopLeftRadius: props.$theme.borders.radius100,
304
- borderTopRightRadius: props.$theme.borders.radius100,
305
- borderBottomRightRadius: props.$theme.borders.radius100,
306
- borderBottomLeftRadius: props.$theme.borders.radius100,
307
- backgroundColor: backgroundColor()
308
- };
309
- }
310
-
311
- if (props.$checkmarkType === STYLE_TYPE.toggle_round) {
312
- return {};
313
- }
314
-
315
- return {};
316
- });
317
- ToggleInner.displayName = "ToggleInner";
318
247
  export var ToggleTrack = styled('div', function (props) {
319
- if (props.$checkmarkType === STYLE_TYPE.toggle) {
320
- var borderRadius = props.$theme.borders.useRoundedCorners ? props.$theme.borders.radius200 : null;
321
- return {
322
- alignItems: 'center',
323
- backgroundColor: getBackgroundColor(props),
324
- borderTopLeftRadius: borderRadius,
325
- borderTopRightRadius: borderRadius,
326
- borderBottomRightRadius: borderRadius,
327
- borderBottomLeftRadius: borderRadius,
328
- display: 'flex',
329
- height: props.$theme.sizing.scale600,
330
- justifyContent: props.$checked ? 'flex-end' : 'flex-start',
331
- marginTop: props.$theme.sizing.scale100,
332
- marginBottom: props.$theme.sizing.scale100,
333
- marginLeft: props.$theme.sizing.scale100,
334
- marginRight: props.$theme.sizing.scale100,
335
- width: props.$theme.sizing.scale1000
336
- };
337
- }
338
-
339
- if (props.$checkmarkType === STYLE_TYPE.toggle_round) {
340
- var backgroundColor = props.$theme.colors.toggleTrackFill;
341
-
342
- if (props.$disabled) {
343
- backgroundColor = props.$theme.colors.toggleTrackFillDisabled;
344
- } else if ((props.$error || props.$isError) && props.$checked) {
345
- backgroundColor = props.$theme.colors.tickFillError;
346
- }
248
+ var backgroundColor = props.$theme.colors.toggleTrackFill;
347
249
 
348
- return {
349
- alignItems: 'center',
350
- backgroundColor: backgroundColor,
351
- borderTopLeftRadius: '7px',
352
- borderTopRightRadius: '7px',
353
- borderBottomRightRadius: '7px',
354
- borderBottomLeftRadius: '7px',
355
- display: 'flex',
356
- height: props.$theme.sizing.scale550,
357
- marginTop: props.$theme.sizing.scale200,
358
- marginBottom: props.$theme.sizing.scale100,
359
- marginLeft: props.$theme.sizing.scale200,
360
- marginRight: props.$theme.sizing.scale100,
361
- width: props.$theme.sizing.scale1000
362
- };
250
+ if (props.$disabled) {
251
+ backgroundColor = props.$theme.colors.toggleTrackFillDisabled;
252
+ } else if (props.$error && props.$checked) {
253
+ backgroundColor = props.$theme.colors.tickFillError;
363
254
  }
364
255
 
365
- return {};
256
+ return {
257
+ alignItems: 'center',
258
+ backgroundColor: backgroundColor,
259
+ borderTopLeftRadius: '7px',
260
+ borderTopRightRadius: '7px',
261
+ borderBottomRightRadius: '7px',
262
+ borderBottomLeftRadius: '7px',
263
+ display: 'flex',
264
+ height: props.$theme.sizing.scale550,
265
+ marginTop: props.$theme.sizing.scale200,
266
+ marginBottom: props.$theme.sizing.scale100,
267
+ marginLeft: props.$theme.sizing.scale200,
268
+ marginRight: props.$theme.sizing.scale100,
269
+ width: props.$theme.sizing.scale1000
270
+ };
366
271
  });
367
272
  ToggleTrack.displayName = "ToggleTrack";
@@ -57,7 +57,7 @@ function FilterQuickControls(props) {
57
57
  var locale = React.useContext(LocaleContext);
58
58
  return /*#__PURE__*/React.createElement(ButtonGroup, {
59
59
  size: SIZE.mini,
60
- kind: KIND.minimal
60
+ kind: KIND.tertiary
61
61
  }, /*#__PURE__*/React.createElement(Button, {
62
62
  type: "button",
63
63
  onClick: props.onSelectAll
@@ -425,7 +425,7 @@ function DatetimeFilter(props) {
425
425
  if (Array.isArray(date)) {
426
426
  if (!date.length) return;
427
427
  var nextDates = date.map(function (d, i) {
428
- return applyDateToTime(rangeDates[i], d);
428
+ return d ? applyDateToTime(rangeDates[i], d) : null;
429
429
  });
430
430
  setRangeDates(nextDates);
431
431
  }
@@ -75,7 +75,11 @@ function Column(options) {
75
75
  display: 'flex',
76
76
  height: '100%'
77
77
  })
78
- }, Boolean(props.onSelect) && /*#__PURE__*/React.createElement(Checkbox, {
78
+ }, Boolean(props.onSelect) && /*#__PURE__*/React.createElement("span", {
79
+ className: css({
80
+ paddingRight: theme.sizing.scale300
81
+ })
82
+ }, /*#__PURE__*/React.createElement(Checkbox, {
79
83
  onChange: props.onSelect,
80
84
  checked: props.isSelected,
81
85
  overrides: {
@@ -86,7 +90,7 @@ function Column(options) {
86
90
  }
87
91
  }
88
92
  }
89
- }), /*#__PURE__*/React.createElement(ProvidedCell, props)));
93
+ })), /*#__PURE__*/React.createElement(ProvidedCell, props)));
90
94
  }),
91
95
  renderFilter: options.renderFilter || function () {
92
96
  return null;
@@ -466,7 +466,7 @@ var InnerTableElement = /*#__PURE__*/React.forwardRef(function (props, ref) {
466
466
  });
467
467
  },
468
468
  size: BUTTON_SIZES.compact,
469
- kind: BUTTON_KINDS.minimal,
469
+ kind: BUTTON_KINDS.tertiary,
470
470
  shape: BUTTON_SHAPES.round,
471
471
  overrides: {
472
472
  BaseButton: {
@@ -536,7 +536,8 @@ export function DataTable(_ref2) {
536
536
  sortIndex = _ref2.sortIndex,
537
537
  sortDirection = _ref2.sortDirection,
538
538
  _ref2$textQuery = _ref2.textQuery,
539
- textQuery = _ref2$textQuery === void 0 ? '' : _ref2$textQuery;
539
+ textQuery = _ref2$textQuery === void 0 ? '' : _ref2$textQuery,
540
+ controlRef = _ref2.controlRef;
540
541
 
541
542
  var _useStyletron13 = useStyletron(),
542
543
  _useStyletron14 = _slicedToArray(_useStyletron13, 2),
@@ -735,6 +736,13 @@ export function DataTable(_ref2) {
735
736
 
736
737
  return result;
737
738
  }, [sortedIndices, filteredIndices, onIncludedRowsChange, allRows]);
739
+ React.useImperativeHandle(controlRef, function () {
740
+ return {
741
+ getRows: function getRows() {
742
+ return rows;
743
+ }
744
+ };
745
+ }, [rows]);
738
746
 
739
747
  var _React$useState19 = React.useState(0),
740
748
  _React$useState20 = _slicedToArray(_React$useState19, 2),
@@ -95,6 +95,9 @@ var HeaderCell = /*#__PURE__*/React.forwardRef(function (props, ref) {
95
95
  onFocus: handleFocus,
96
96
  onBlur: handleBlur
97
97
  }, props.isSelectable && /*#__PURE__*/React.createElement("span", {
98
+ className: css({
99
+ paddingRight: theme.sizing.scale300
100
+ }),
98
101
  ref: checkboxRef
99
102
  }, /*#__PURE__*/React.createElement(Checkbox, {
100
103
  onChange: function onChange(e) {
@@ -327,7 +327,8 @@ export function StatefulDataTable(props) {
327
327
  selectedRowIds: selectedRowIds,
328
328
  sortDirection: sortDirection,
329
329
  sortIndex: sortIndex,
330
- textQuery: textQuery
330
+ textQuery: textQuery,
331
+ controlRef: props.controlRef
331
332
  })));
332
333
  });
333
334
  }
@@ -315,25 +315,36 @@ var Calendar = /*#__PURE__*/function (_React$Component) {
315
315
  _defineProperty(_assertThisInitialized(_this), "handleDateChange", function (data) {
316
316
  var _this$props$onChange = _this.props.onChange,
317
317
  onChange = _this$props$onChange === void 0 ? function (params) {} : _this$props$onChange;
318
- var updatedDate = data.date; // We'll need to update the date in time values of internal state
318
+ var updatedDate = data.date; // Apply the currently selected time values (saved in state) to the updated date
319
319
 
320
- var newTimeState = _toConsumableArray(_this.state.time); // Apply the currently selected time values (saved in state) to the updated date
320
+ if (Array.isArray(data.date)) {
321
+ // We'll need to update the date in time values of internal state
322
+ var newTimeState = _toConsumableArray(_this.state.time);
321
323
 
324
+ var start = data.date[0] ? _this.dateHelpers.applyDateToTime(newTimeState[0], data.date[0]) : null;
325
+ var end = data.date[1] ? _this.dateHelpers.applyDateToTime(newTimeState[1], data.date[1]) : null;
326
+ newTimeState[0] = start;
322
327
 
323
- if (Array.isArray(data.date)) {
324
- updatedDate = data.date.map(function (date, index) {
325
- newTimeState[index] = _this.dateHelpers.applyDateToTime(newTimeState[index], date);
326
- return newTimeState[index];
328
+ if (end) {
329
+ updatedDate = [start, end];
330
+ newTimeState[1] = end;
331
+ } else {
332
+ updatedDate = [start];
333
+ } // Update the date in time values of internal state
334
+
335
+
336
+ _this.setState({
337
+ time: newTimeState
327
338
  });
328
339
  } else if (!Array.isArray(_this.props.value) && data.date) {
329
- newTimeState[0] = _this.dateHelpers.applyDateToTime(newTimeState[0], data.date);
330
- updatedDate = newTimeState[0];
331
- } // Update the date in time values of internal state
340
+ var _newTimeState = _this.dateHelpers.applyDateToTime(_this.state.time[0], data.date);
332
341
 
342
+ updatedDate = _newTimeState; // Update the date in time values of internal state
333
343
 
334
- _this.setState({
335
- time: newTimeState
336
- });
344
+ _this.setState({
345
+ time: [_newTimeState]
346
+ });
347
+ }
337
348
 
338
349
  onChange({
339
350
  date: updatedDate
@@ -356,7 +367,7 @@ var Calendar = /*#__PURE__*/function (_React$Component) {
356
367
 
357
368
  if (Array.isArray(_this.props.value)) {
358
369
  var dates = _this.props.value.map(function (date, i) {
359
- if (index === i) {
370
+ if (date && index === i) {
360
371
  return _this.dateHelpers.applyTimeToDate(date, time);
361
372
  }
362
373
 
@@ -364,7 +375,7 @@ var Calendar = /*#__PURE__*/function (_React$Component) {
364
375
  });
365
376
 
366
377
  onChange({
367
- date: dates
378
+ date: [dates[0], dates[1]]
368
379
  });
369
380
  } else {
370
381
  var date = _this.dateHelpers.applyTimeToDate(_this.props.value, time);
@@ -434,7 +445,9 @@ var Calendar = /*#__PURE__*/function (_React$Component) {
434
445
  overrides: overrides,
435
446
  value: _this.props.value,
436
447
  peekNextMonth: _this.props.peekNextMonth,
437
- fixedHeight: _this.props.fixedHeight
448
+ fixedHeight: _this.props.fixedHeight,
449
+ hasLockedBehavior: !!_this.props.hasLockedBehavior,
450
+ selectedInput: _this.props.selectedInput
438
451
  })));
439
452
  monthList.push( /*#__PURE__*/React.createElement("div", {
440
453
  key: "month-component-".concat(i)
@@ -25,4 +25,12 @@ export var DEFAULT_MONTHS = [0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11];
25
25
  export var DENSITY = {
26
26
  high: 'high',
27
27
  default: 'default'
28
+ };
29
+ export var INPUT_ROLE = {
30
+ startDate: 'startDate',
31
+ endDate: 'endDate'
32
+ };
33
+ export var RANGED_CALENDAR_BEHAVIOR = {
34
+ default: 'default',
35
+ locked: 'locked'
28
36
  };