@elastic/eui 93.3.0 → 93.4.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 (286) hide show
  1. package/dist/eui_charts_theme.d.ts +9 -0
  2. package/dist/eui_charts_theme.js +56 -14
  3. package/dist/eui_charts_theme.js.map +1 -1
  4. package/es/components/breadcrumbs/_breadcrumb_content.js +362 -0
  5. package/es/components/breadcrumbs/_breadcrumb_content.styles.js +48 -0
  6. package/es/components/breadcrumbs/breadcrumb.js +10 -327
  7. package/es/components/breadcrumbs/breadcrumb.styles.js +5 -27
  8. package/es/components/breadcrumbs/breadcrumbs.js +4 -4
  9. package/es/components/breadcrumbs/types.js +1 -0
  10. package/es/components/button/button_group/button_group.js +16 -2
  11. package/es/components/button/button_group/button_group.styles.js +1 -1
  12. package/es/components/button/button_group/button_group_button.js +59 -5
  13. package/es/components/button/button_group/button_group_button.styles.js +39 -3
  14. package/es/components/datagrid/body/cell/data_grid_cell.js +97 -58
  15. package/es/components/datagrid/body/cell/data_grid_cell_actions.js +24 -18
  16. package/es/components/datagrid/body/cell/data_grid_cell_popover.js +64 -56
  17. package/es/components/datagrid/body/cell/data_grid_cell_wrapper.js +32 -31
  18. package/es/components/datagrid/body/cell/index.js +1 -1
  19. package/es/components/datagrid/body/data_grid_body.js +13 -0
  20. package/es/components/datagrid/body/data_grid_body_custom.js +52 -36
  21. package/es/components/datagrid/body/data_grid_body_virtualized.js +84 -56
  22. package/es/components/datagrid/body/data_grid_row_manager.js +6 -4
  23. package/es/components/datagrid/body/footer/use_data_grid_footer.js +1 -2
  24. package/es/components/datagrid/body/header/data_grid_control_header_cell.js +5 -4
  25. package/es/components/datagrid/body/header/data_grid_header_cell.js +73 -53
  26. package/es/components/datagrid/body/header/data_grid_header_row.js +15 -551
  27. package/es/components/datagrid/body/header/use_data_grid_header.js +7 -6
  28. package/es/components/datagrid/controls/column_selector.js +126 -123
  29. package/es/components/datagrid/controls/column_sorting.js +605 -103
  30. package/es/components/datagrid/controls/column_sorting_draggable.js +24 -22
  31. package/es/components/datagrid/controls/display_selector.js +109 -107
  32. package/es/components/datagrid/data_grid.a11y.js +13 -12
  33. package/es/components/datagrid/data_grid.js +45 -22
  34. package/es/components/datagrid/utils/col_widths.js +12 -8
  35. package/es/components/datagrid/utils/focus.js +10 -8
  36. package/es/components/datagrid/utils/grid_height_width.js +31 -30
  37. package/es/components/datagrid/utils/ref.js +1 -1
  38. package/es/components/datagrid/utils/row_heights.js +2 -2
  39. package/es/components/datagrid/utils/sorting.js +29 -27
  40. package/es/components/date_picker/super_date_picker/super_date_picker.js +9 -0
  41. package/es/components/date_picker/super_date_picker/super_update_button.js +57 -29
  42. package/es/components/flex/flex_grid.js +22 -8
  43. package/es/components/flex/flex_grid.styles.js +13 -6
  44. package/es/components/flex/flex_group.js +10 -11
  45. package/es/components/flex/flex_item.js +9 -11
  46. package/es/components/flex/flex_item.styles.js +107 -122
  47. package/es/components/flyout/flyout.js +16 -18
  48. package/es/components/header/header_breadcrumbs/header_breadcrumbs.js +3 -5
  49. package/es/components/modal/confirm_modal.js +2 -1
  50. package/es/components/modal/modal.js +12 -3
  51. package/es/components/observer/resize_observer/resize_observer.js +15 -24
  52. package/es/components/spacer/spacer.js +2 -3
  53. package/es/components/toast/global_toast_list.js +70 -73
  54. package/es/components/toast/toast.js +27 -42
  55. package/es/components/toast/toast.styles.js +2 -17
  56. package/es/services/color/eui_palettes.js +21 -13
  57. package/es/services/color/index.js +1 -1
  58. package/es/services/hooks/index.js +1 -0
  59. package/es/services/hooks/useDeepEqual.js +23 -0
  60. package/es/services/index.js +1 -1
  61. package/eui.d.ts +2442 -2337
  62. package/i18ntokens.json +259 -259
  63. package/lib/components/breadcrumbs/_breadcrumb_content.js +372 -0
  64. package/lib/components/breadcrumbs/_breadcrumb_content.styles.js +55 -0
  65. package/lib/components/breadcrumbs/breadcrumb.js +11 -331
  66. package/lib/components/breadcrumbs/breadcrumb.styles.js +5 -29
  67. package/lib/components/breadcrumbs/breadcrumbs.js +3 -3
  68. package/lib/components/breadcrumbs/types.js +5 -0
  69. package/lib/components/button/button_group/button_group.js +16 -2
  70. package/lib/components/button/button_group/button_group.styles.js +1 -1
  71. package/lib/components/button/button_group/button_group_button.js +59 -5
  72. package/lib/components/button/button_group/button_group_button.styles.js +45 -11
  73. package/lib/components/datagrid/body/cell/data_grid_cell.js +95 -57
  74. package/lib/components/datagrid/body/cell/data_grid_cell_actions.js +24 -18
  75. package/lib/components/datagrid/body/cell/data_grid_cell_popover.js +63 -55
  76. package/lib/components/datagrid/body/cell/data_grid_cell_wrapper.js +32 -31
  77. package/lib/components/datagrid/body/cell/index.js +2 -2
  78. package/lib/components/datagrid/body/data_grid_body.js +13 -0
  79. package/lib/components/datagrid/body/data_grid_body_custom.js +51 -35
  80. package/lib/components/datagrid/body/data_grid_body_virtualized.js +83 -55
  81. package/lib/components/datagrid/body/data_grid_row_manager.js +5 -3
  82. package/lib/components/datagrid/body/footer/use_data_grid_footer.js +1 -2
  83. package/lib/components/datagrid/body/header/data_grid_control_header_cell.js +8 -4
  84. package/lib/components/datagrid/body/header/data_grid_header_cell.js +72 -52
  85. package/lib/components/datagrid/body/header/data_grid_header_row.js +14 -550
  86. package/lib/components/datagrid/body/header/use_data_grid_header.js +7 -6
  87. package/lib/components/datagrid/controls/column_selector.js +126 -123
  88. package/lib/components/datagrid/controls/column_sorting.js +615 -110
  89. package/lib/components/datagrid/controls/column_sorting_draggable.js +27 -22
  90. package/lib/components/datagrid/controls/display_selector.js +109 -107
  91. package/lib/components/datagrid/data_grid.a11y.js +13 -12
  92. package/lib/components/datagrid/data_grid.js +43 -20
  93. package/lib/components/datagrid/utils/col_widths.js +12 -8
  94. package/lib/components/datagrid/utils/focus.js +10 -8
  95. package/lib/components/datagrid/utils/grid_height_width.js +29 -28
  96. package/lib/components/datagrid/utils/ref.js +1 -1
  97. package/lib/components/datagrid/utils/row_heights.js +1 -1
  98. package/lib/components/datagrid/utils/sorting.js +31 -29
  99. package/lib/components/date_picker/super_date_picker/super_date_picker.js +9 -0
  100. package/lib/components/date_picker/super_date_picker/super_update_button.js +57 -29
  101. package/lib/components/flex/flex_grid.js +23 -7
  102. package/lib/components/flex/flex_grid.styles.js +13 -6
  103. package/lib/components/flex/flex_group.js +10 -10
  104. package/lib/components/flex/flex_item.js +13 -13
  105. package/lib/components/flex/flex_item.styles.js +107 -122
  106. package/lib/components/flyout/flyout.js +16 -18
  107. package/lib/components/header/header_breadcrumbs/header_breadcrumbs.js +3 -5
  108. package/lib/components/modal/confirm_modal.js +2 -1
  109. package/lib/components/modal/modal.js +12 -3
  110. package/lib/components/observer/resize_observer/resize_observer.js +15 -24
  111. package/lib/components/spacer/spacer.js +1 -2
  112. package/lib/components/toast/global_toast_list.js +68 -71
  113. package/lib/components/toast/toast.js +25 -40
  114. package/lib/components/toast/toast.styles.js +11 -25
  115. package/lib/services/color/eui_palettes.js +24 -14
  116. package/lib/services/color/index.js +14 -0
  117. package/lib/services/hooks/index.js +11 -0
  118. package/lib/services/hooks/useDeepEqual.js +30 -0
  119. package/lib/services/index.js +15 -1
  120. package/optimize/es/components/breadcrumbs/_breadcrumb_content.js +153 -0
  121. package/optimize/es/components/breadcrumbs/_breadcrumb_content.styles.js +48 -0
  122. package/optimize/es/components/breadcrumbs/breadcrumb.js +10 -110
  123. package/optimize/es/components/breadcrumbs/breadcrumb.styles.js +5 -27
  124. package/optimize/es/components/breadcrumbs/breadcrumbs.js +4 -4
  125. package/optimize/es/components/breadcrumbs/types.js +1 -0
  126. package/optimize/es/components/button/button_group/button_group.js +2 -2
  127. package/optimize/es/components/button/button_group/button_group.styles.js +1 -1
  128. package/optimize/es/components/button/button_group/button_group_button.js +36 -4
  129. package/optimize/es/components/button/button_group/button_group_button.styles.js +39 -3
  130. package/optimize/es/components/datagrid/body/cell/data_grid_cell.js +80 -55
  131. package/optimize/es/components/datagrid/body/cell/data_grid_cell_actions.js +24 -18
  132. package/optimize/es/components/datagrid/body/cell/data_grid_cell_popover.js +64 -56
  133. package/optimize/es/components/datagrid/body/cell/data_grid_cell_wrapper.js +32 -31
  134. package/optimize/es/components/datagrid/body/cell/index.js +1 -1
  135. package/optimize/es/components/datagrid/body/data_grid_body_custom.js +39 -36
  136. package/optimize/es/components/datagrid/body/data_grid_body_virtualized.js +69 -49
  137. package/optimize/es/components/datagrid/body/data_grid_row_manager.js +6 -4
  138. package/optimize/es/components/datagrid/body/footer/use_data_grid_footer.js +1 -2
  139. package/optimize/es/components/datagrid/body/header/data_grid_control_header_cell.js +4 -3
  140. package/optimize/es/components/datagrid/body/header/data_grid_header_cell.js +65 -49
  141. package/optimize/es/components/datagrid/body/header/data_grid_header_row.js +15 -13
  142. package/optimize/es/components/datagrid/body/header/use_data_grid_header.js +7 -6
  143. package/optimize/es/components/datagrid/controls/column_selector.js +126 -123
  144. package/optimize/es/components/datagrid/controls/column_sorting.js +121 -103
  145. package/optimize/es/components/datagrid/controls/column_sorting_draggable.js +24 -22
  146. package/optimize/es/components/datagrid/controls/display_selector.js +109 -107
  147. package/optimize/es/components/datagrid/data_grid.a11y.js +13 -12
  148. package/optimize/es/components/datagrid/data_grid.js +45 -22
  149. package/optimize/es/components/datagrid/utils/col_widths.js +9 -5
  150. package/optimize/es/components/datagrid/utils/focus.js +10 -8
  151. package/optimize/es/components/datagrid/utils/grid_height_width.js +31 -30
  152. package/optimize/es/components/datagrid/utils/ref.js +1 -1
  153. package/optimize/es/components/datagrid/utils/row_heights.js +2 -2
  154. package/optimize/es/components/datagrid/utils/sorting.js +29 -27
  155. package/optimize/es/components/date_picker/super_date_picker/super_update_button.js +49 -29
  156. package/optimize/es/components/flex/flex_grid.js +19 -8
  157. package/optimize/es/components/flex/flex_grid.styles.js +13 -6
  158. package/optimize/es/components/flex/flex_group.js +9 -10
  159. package/optimize/es/components/flex/flex_item.js +9 -11
  160. package/optimize/es/components/flex/flex_item.styles.js +107 -122
  161. package/optimize/es/components/flyout/flyout.js +16 -18
  162. package/optimize/es/components/header/header_breadcrumbs/header_breadcrumbs.js +3 -5
  163. package/optimize/es/components/modal/confirm_modal.js +2 -1
  164. package/optimize/es/components/modal/modal.js +6 -2
  165. package/optimize/es/components/observer/resize_observer/resize_observer.js +15 -24
  166. package/optimize/es/components/spacer/spacer.js +2 -3
  167. package/optimize/es/components/toast/global_toast_list.js +70 -73
  168. package/optimize/es/components/toast/toast.js +27 -42
  169. package/optimize/es/components/toast/toast.styles.js +2 -17
  170. package/optimize/es/services/color/eui_palettes.js +21 -13
  171. package/optimize/es/services/color/index.js +1 -1
  172. package/optimize/es/services/hooks/index.js +1 -0
  173. package/optimize/es/services/hooks/useDeepEqual.js +23 -0
  174. package/optimize/es/services/index.js +1 -1
  175. package/optimize/lib/components/breadcrumbs/_breadcrumb_content.js +163 -0
  176. package/optimize/lib/components/breadcrumbs/_breadcrumb_content.styles.js +55 -0
  177. package/optimize/lib/components/breadcrumbs/breadcrumb.js +10 -113
  178. package/optimize/lib/components/breadcrumbs/breadcrumb.styles.js +5 -29
  179. package/optimize/lib/components/breadcrumbs/breadcrumbs.js +3 -3
  180. package/optimize/lib/components/breadcrumbs/types.js +5 -0
  181. package/optimize/lib/components/button/button_group/button_group.js +2 -2
  182. package/optimize/lib/components/button/button_group/button_group.styles.js +1 -1
  183. package/optimize/lib/components/button/button_group/button_group_button.js +37 -5
  184. package/optimize/lib/components/button/button_group/button_group_button.styles.js +45 -11
  185. package/optimize/lib/components/datagrid/body/cell/data_grid_cell.js +78 -54
  186. package/optimize/lib/components/datagrid/body/cell/data_grid_cell_actions.js +24 -18
  187. package/optimize/lib/components/datagrid/body/cell/data_grid_cell_popover.js +63 -55
  188. package/optimize/lib/components/datagrid/body/cell/data_grid_cell_wrapper.js +32 -31
  189. package/optimize/lib/components/datagrid/body/cell/index.js +2 -2
  190. package/optimize/lib/components/datagrid/body/data_grid_body_custom.js +38 -35
  191. package/optimize/lib/components/datagrid/body/data_grid_body_virtualized.js +70 -50
  192. package/optimize/lib/components/datagrid/body/data_grid_row_manager.js +5 -3
  193. package/optimize/lib/components/datagrid/body/footer/use_data_grid_footer.js +1 -2
  194. package/optimize/lib/components/datagrid/body/header/data_grid_control_header_cell.js +8 -4
  195. package/optimize/lib/components/datagrid/body/header/data_grid_header_cell.js +65 -49
  196. package/optimize/lib/components/datagrid/body/header/data_grid_header_row.js +14 -12
  197. package/optimize/lib/components/datagrid/body/header/use_data_grid_header.js +7 -6
  198. package/optimize/lib/components/datagrid/controls/column_selector.js +126 -123
  199. package/optimize/lib/components/datagrid/controls/column_sorting.js +125 -107
  200. package/optimize/lib/components/datagrid/controls/column_sorting_draggable.js +27 -22
  201. package/optimize/lib/components/datagrid/controls/display_selector.js +109 -107
  202. package/optimize/lib/components/datagrid/data_grid.a11y.js +13 -12
  203. package/optimize/lib/components/datagrid/data_grid.js +43 -20
  204. package/optimize/lib/components/datagrid/utils/col_widths.js +9 -5
  205. package/optimize/lib/components/datagrid/utils/focus.js +10 -8
  206. package/optimize/lib/components/datagrid/utils/grid_height_width.js +29 -28
  207. package/optimize/lib/components/datagrid/utils/ref.js +1 -1
  208. package/optimize/lib/components/datagrid/utils/row_heights.js +1 -1
  209. package/optimize/lib/components/datagrid/utils/sorting.js +31 -29
  210. package/optimize/lib/components/date_picker/super_date_picker/super_update_button.js +49 -29
  211. package/optimize/lib/components/flex/flex_grid.js +21 -7
  212. package/optimize/lib/components/flex/flex_grid.styles.js +13 -6
  213. package/optimize/lib/components/flex/flex_group.js +9 -9
  214. package/optimize/lib/components/flex/flex_item.js +13 -13
  215. package/optimize/lib/components/flex/flex_item.styles.js +107 -122
  216. package/optimize/lib/components/flyout/flyout.js +16 -18
  217. package/optimize/lib/components/header/header_breadcrumbs/header_breadcrumbs.js +3 -5
  218. package/optimize/lib/components/modal/confirm_modal.js +2 -1
  219. package/optimize/lib/components/modal/modal.js +6 -2
  220. package/optimize/lib/components/observer/resize_observer/resize_observer.js +15 -24
  221. package/optimize/lib/components/spacer/spacer.js +1 -2
  222. package/optimize/lib/components/toast/global_toast_list.js +68 -71
  223. package/optimize/lib/components/toast/toast.js +25 -40
  224. package/optimize/lib/components/toast/toast.styles.js +11 -25
  225. package/optimize/lib/services/color/eui_palettes.js +24 -14
  226. package/optimize/lib/services/color/index.js +14 -0
  227. package/optimize/lib/services/hooks/index.js +11 -0
  228. package/optimize/lib/services/hooks/useDeepEqual.js +30 -0
  229. package/optimize/lib/services/index.js +15 -1
  230. package/package.json +2 -2
  231. package/test-env/components/breadcrumbs/_breadcrumb_content.js +363 -0
  232. package/test-env/components/breadcrumbs/_breadcrumb_content.styles.js +55 -0
  233. package/test-env/components/breadcrumbs/breadcrumb.js +11 -326
  234. package/test-env/components/breadcrumbs/breadcrumb.styles.js +5 -29
  235. package/test-env/components/breadcrumbs/breadcrumbs.js +3 -3
  236. package/test-env/components/breadcrumbs/types.js +5 -0
  237. package/test-env/components/button/button_group/button_group.js +16 -2
  238. package/test-env/components/button/button_group/button_group.styles.js +1 -1
  239. package/test-env/components/button/button_group/button_group_button.js +56 -5
  240. package/test-env/components/button/button_group/button_group_button.styles.js +45 -11
  241. package/test-env/components/datagrid/body/cell/data_grid_cell.js +95 -57
  242. package/test-env/components/datagrid/body/cell/data_grid_cell_actions.js +24 -18
  243. package/test-env/components/datagrid/body/cell/data_grid_cell_popover.js +63 -55
  244. package/test-env/components/datagrid/body/cell/data_grid_cell_wrapper.js +32 -31
  245. package/test-env/components/datagrid/body/cell/index.js +2 -2
  246. package/test-env/components/datagrid/body/data_grid_body.js +13 -0
  247. package/test-env/components/datagrid/body/data_grid_body_custom.js +51 -35
  248. package/test-env/components/datagrid/body/data_grid_body_virtualized.js +83 -55
  249. package/test-env/components/datagrid/body/data_grid_row_manager.js +5 -3
  250. package/test-env/components/datagrid/body/footer/use_data_grid_footer.js +1 -2
  251. package/test-env/components/datagrid/body/header/data_grid_control_header_cell.js +8 -4
  252. package/test-env/components/datagrid/body/header/data_grid_header_cell.js +72 -52
  253. package/test-env/components/datagrid/body/header/data_grid_header_row.js +14 -550
  254. package/test-env/components/datagrid/body/header/use_data_grid_header.js +7 -6
  255. package/test-env/components/datagrid/controls/column_selector.js +126 -123
  256. package/test-env/components/datagrid/controls/column_sorting.js +607 -106
  257. package/test-env/components/datagrid/controls/column_sorting_draggable.js +27 -22
  258. package/test-env/components/datagrid/controls/display_selector.js +109 -107
  259. package/test-env/components/datagrid/data_grid.a11y.js +13 -12
  260. package/test-env/components/datagrid/data_grid.js +43 -20
  261. package/test-env/components/datagrid/utils/col_widths.js +9 -5
  262. package/test-env/components/datagrid/utils/focus.js +10 -8
  263. package/test-env/components/datagrid/utils/grid_height_width.js +29 -28
  264. package/test-env/components/datagrid/utils/ref.js +1 -1
  265. package/test-env/components/datagrid/utils/row_heights.js +1 -1
  266. package/test-env/components/datagrid/utils/sorting.js +31 -29
  267. package/test-env/components/date_picker/super_date_picker/super_date_picker.js +9 -0
  268. package/test-env/components/date_picker/super_date_picker/super_update_button.js +57 -29
  269. package/test-env/components/flex/flex_grid.js +21 -7
  270. package/test-env/components/flex/flex_grid.styles.js +13 -6
  271. package/test-env/components/flex/flex_group.js +10 -10
  272. package/test-env/components/flex/flex_item.js +13 -13
  273. package/test-env/components/flex/flex_item.styles.js +107 -122
  274. package/test-env/components/header/header_breadcrumbs/header_breadcrumbs.js +3 -5
  275. package/test-env/components/modal/confirm_modal.js +2 -1
  276. package/test-env/components/modal/modal.js +12 -3
  277. package/test-env/components/spacer/spacer.js +1 -2
  278. package/test-env/components/toast/global_toast_list.js +68 -71
  279. package/test-env/components/toast/toast.js +25 -40
  280. package/test-env/components/toast/toast.styles.js +11 -25
  281. package/test-env/services/color/eui_palettes.js +24 -14
  282. package/test-env/services/color/index.js +14 -0
  283. package/test-env/services/hooks/index.js +11 -0
  284. package/test-env/services/hooks/useDeepEqual.js +30 -0
  285. package/test-env/services/index.js +15 -1
  286. package/src/themes/charts/theme.scss +0 -5
@@ -8,127 +8,112 @@ function _EMOTION_STRINGIFIED_CSS_ERROR__() { return "You have tried to stringif
8
8
  */
9
9
 
10
10
  import { css } from '@emotion/react';
11
- var _ref = process.env.NODE_ENV === "production" ? {
12
- name: "n7polf-10",
13
- styles: "flex-grow:10;label:10;"
14
- } : {
15
- name: "n7polf-10",
16
- styles: "flex-grow:10;label:10;",
17
- toString: _EMOTION_STRINGIFIED_CSS_ERROR__
18
- };
19
- var _ref2 = process.env.NODE_ENV === "production" ? {
20
- name: "1tyr8p6-9",
21
- styles: "flex-grow:9;label:9;"
22
- } : {
23
- name: "1tyr8p6-9",
24
- styles: "flex-grow:9;label:9;",
25
- toString: _EMOTION_STRINGIFIED_CSS_ERROR__
26
- };
27
- var _ref3 = process.env.NODE_ENV === "production" ? {
28
- name: "fjdgzc-8",
29
- styles: "flex-grow:8;label:8;"
30
- } : {
31
- name: "fjdgzc-8",
32
- styles: "flex-grow:8;label:8;",
33
- toString: _EMOTION_STRINGIFIED_CSS_ERROR__
34
- };
35
- var _ref4 = process.env.NODE_ENV === "production" ? {
36
- name: "fvh3nz-7",
37
- styles: "flex-grow:7;label:7;"
38
- } : {
39
- name: "fvh3nz-7",
40
- styles: "flex-grow:7;label:7;",
41
- toString: _EMOTION_STRINGIFIED_CSS_ERROR__
42
- };
43
- var _ref5 = process.env.NODE_ENV === "production" ? {
44
- name: "1in9iiy-6",
45
- styles: "flex-grow:6;label:6;"
46
- } : {
47
- name: "1in9iiy-6",
48
- styles: "flex-grow:6;label:6;",
49
- toString: _EMOTION_STRINGIFIED_CSS_ERROR__
50
- };
51
- var _ref6 = process.env.NODE_ENV === "production" ? {
52
- name: "1cx5fxs-5",
53
- styles: "flex-grow:5;label:5;"
54
- } : {
55
- name: "1cx5fxs-5",
56
- styles: "flex-grow:5;label:5;",
57
- toString: _EMOTION_STRINGIFIED_CSS_ERROR__
58
- };
59
- var _ref7 = process.env.NODE_ENV === "production" ? {
60
- name: "k4pnsg-4",
61
- styles: "flex-grow:4;label:4;"
62
- } : {
63
- name: "k4pnsg-4",
64
- styles: "flex-grow:4;label:4;",
65
- toString: _EMOTION_STRINGIFIED_CSS_ERROR__
66
- };
67
- var _ref8 = process.env.NODE_ENV === "production" ? {
68
- name: "1sl79ay-3",
69
- styles: "flex-grow:3;label:3;"
70
- } : {
71
- name: "1sl79ay-3",
72
- styles: "flex-grow:3;label:3;",
73
- toString: _EMOTION_STRINGIFIED_CSS_ERROR__
74
- };
75
- var _ref9 = process.env.NODE_ENV === "production" ? {
76
- name: "1l86xxh-2",
77
- styles: "flex-grow:2;label:2;"
78
- } : {
79
- name: "1l86xxh-2",
80
- styles: "flex-grow:2;label:2;",
81
- toString: _EMOTION_STRINGIFIED_CSS_ERROR__
82
- };
83
- var _ref10 = process.env.NODE_ENV === "production" ? {
84
- name: "1v6uyoj-1",
85
- styles: "flex-grow:1;label:1;"
86
- } : {
87
- name: "1v6uyoj-1",
88
- styles: "flex-grow:1;label:1;",
89
- toString: _EMOTION_STRINGIFIED_CSS_ERROR__
90
- };
91
- var _ref11 = process.env.NODE_ENV === "production" ? {
92
- name: "tr4wer-grow",
93
- styles: "flex-basis:0%;label:grow;"
94
- } : {
95
- name: "tr4wer-grow",
96
- styles: "flex-basis:0%;label:grow;",
97
- toString: _EMOTION_STRINGIFIED_CSS_ERROR__
98
- };
99
- var _ref12 = process.env.NODE_ENV === "production" ? {
100
- name: "1pat7n0-growZero",
101
- styles: "flex-grow:0;flex-basis:auto;label:growZero;"
102
- } : {
103
- name: "1pat7n0-growZero",
104
- styles: "flex-grow:0;flex-basis:auto;label:growZero;",
105
- toString: _EMOTION_STRINGIFIED_CSS_ERROR__
106
- };
107
- var _ref13 = process.env.NODE_ENV === "production" ? {
108
- name: "19hf44n-euiFlexItem",
109
- styles: "display:flex;flex-direction:column;label:euiFlexItem;"
110
- } : {
111
- name: "19hf44n-euiFlexItem",
112
- styles: "display:flex;flex-direction:column;label:euiFlexItem;",
113
- toString: _EMOTION_STRINGIFIED_CSS_ERROR__
114
- };
115
- export var euiFlexItemStyles = function euiFlexItemStyles() {
116
- return {
117
- // 1. Allow EuiPanels to expand to fill the item.
118
- euiFlexItem: _ref13,
119
- growZero: _ref12,
120
- grow: _ref11,
121
- growSizes: {
122
- '1': _ref10,
123
- '2': _ref9,
124
- '3': _ref8,
125
- '4': _ref7,
126
- '5': _ref6,
127
- '6': _ref5,
128
- '7': _ref4,
129
- '8': _ref3,
130
- '9': _ref2,
131
- '10': _ref
11
+ export var euiFlexItemStyles = {
12
+ // 1. Allow EuiPanels to expand to fill the item.
13
+ euiFlexItem: process.env.NODE_ENV === "production" ? {
14
+ name: "19hf44n-euiFlexItem",
15
+ styles: "display:flex;flex-direction:column;label:euiFlexItem;"
16
+ } : {
17
+ name: "19hf44n-euiFlexItem",
18
+ styles: "display:flex;flex-direction:column;label:euiFlexItem;",
19
+ toString: _EMOTION_STRINGIFIED_CSS_ERROR__
20
+ },
21
+ growZero: process.env.NODE_ENV === "production" ? {
22
+ name: "1pat7n0-growZero",
23
+ styles: "flex-grow:0;flex-basis:auto;label:growZero;"
24
+ } : {
25
+ name: "1pat7n0-growZero",
26
+ styles: "flex-grow:0;flex-basis:auto;label:growZero;",
27
+ toString: _EMOTION_STRINGIFIED_CSS_ERROR__
28
+ },
29
+ grow: process.env.NODE_ENV === "production" ? {
30
+ name: "tr4wer-grow",
31
+ styles: "flex-basis:0%;label:grow;"
32
+ } : {
33
+ name: "tr4wer-grow",
34
+ styles: "flex-basis:0%;label:grow;",
35
+ toString: _EMOTION_STRINGIFIED_CSS_ERROR__
36
+ },
37
+ growSizes: {
38
+ '1': process.env.NODE_ENV === "production" ? {
39
+ name: "1v6uyoj-1",
40
+ styles: "flex-grow:1;label:1;"
41
+ } : {
42
+ name: "1v6uyoj-1",
43
+ styles: "flex-grow:1;label:1;",
44
+ toString: _EMOTION_STRINGIFIED_CSS_ERROR__
45
+ },
46
+ '2': process.env.NODE_ENV === "production" ? {
47
+ name: "1l86xxh-2",
48
+ styles: "flex-grow:2;label:2;"
49
+ } : {
50
+ name: "1l86xxh-2",
51
+ styles: "flex-grow:2;label:2;",
52
+ toString: _EMOTION_STRINGIFIED_CSS_ERROR__
53
+ },
54
+ '3': process.env.NODE_ENV === "production" ? {
55
+ name: "1sl79ay-3",
56
+ styles: "flex-grow:3;label:3;"
57
+ } : {
58
+ name: "1sl79ay-3",
59
+ styles: "flex-grow:3;label:3;",
60
+ toString: _EMOTION_STRINGIFIED_CSS_ERROR__
61
+ },
62
+ '4': process.env.NODE_ENV === "production" ? {
63
+ name: "k4pnsg-4",
64
+ styles: "flex-grow:4;label:4;"
65
+ } : {
66
+ name: "k4pnsg-4",
67
+ styles: "flex-grow:4;label:4;",
68
+ toString: _EMOTION_STRINGIFIED_CSS_ERROR__
69
+ },
70
+ '5': process.env.NODE_ENV === "production" ? {
71
+ name: "1cx5fxs-5",
72
+ styles: "flex-grow:5;label:5;"
73
+ } : {
74
+ name: "1cx5fxs-5",
75
+ styles: "flex-grow:5;label:5;",
76
+ toString: _EMOTION_STRINGIFIED_CSS_ERROR__
77
+ },
78
+ '6': process.env.NODE_ENV === "production" ? {
79
+ name: "1in9iiy-6",
80
+ styles: "flex-grow:6;label:6;"
81
+ } : {
82
+ name: "1in9iiy-6",
83
+ styles: "flex-grow:6;label:6;",
84
+ toString: _EMOTION_STRINGIFIED_CSS_ERROR__
85
+ },
86
+ '7': process.env.NODE_ENV === "production" ? {
87
+ name: "fvh3nz-7",
88
+ styles: "flex-grow:7;label:7;"
89
+ } : {
90
+ name: "fvh3nz-7",
91
+ styles: "flex-grow:7;label:7;",
92
+ toString: _EMOTION_STRINGIFIED_CSS_ERROR__
93
+ },
94
+ '8': process.env.NODE_ENV === "production" ? {
95
+ name: "fjdgzc-8",
96
+ styles: "flex-grow:8;label:8;"
97
+ } : {
98
+ name: "fjdgzc-8",
99
+ styles: "flex-grow:8;label:8;",
100
+ toString: _EMOTION_STRINGIFIED_CSS_ERROR__
101
+ },
102
+ '9': process.env.NODE_ENV === "production" ? {
103
+ name: "1tyr8p6-9",
104
+ styles: "flex-grow:9;label:9;"
105
+ } : {
106
+ name: "1tyr8p6-9",
107
+ styles: "flex-grow:9;label:9;",
108
+ toString: _EMOTION_STRINGIFIED_CSS_ERROR__
109
+ },
110
+ '10': process.env.NODE_ENV === "production" ? {
111
+ name: "n7polf-10",
112
+ styles: "flex-grow:10;label:10;"
113
+ } : {
114
+ name: "n7polf-10",
115
+ styles: "flex-grow:10;label:10;",
116
+ toString: _EMOTION_STRINGIFIED_CSS_ERROR__
132
117
  }
133
- };
118
+ }
134
119
  };
@@ -99,33 +99,31 @@ export var EuiFlyout = /*#__PURE__*/forwardRef(function (_ref, ref) {
99
99
  resizeRef = _useState2[0],
100
100
  setResizeRef = _useState2[1];
101
101
  var setRef = useCombinedRefs([setResizeRef, ref]);
102
- // TODO: Allow this hook to be conditional
103
- var dimensions = useResizeObserver(resizeRef);
102
+ var _useResizeObserver = useResizeObserver(isPushed ? resizeRef : null, 'width'),
103
+ width = _useResizeObserver.width;
104
104
  useEffect(function () {
105
- // This class doesn't actually do anything by EUI, but is nice to add for consumers (JIC)
106
- document.body.classList.add('euiBody--hasFlyout');
107
-
108
105
  /**
109
106
  * Accomodate for the `isPushed` state by adding padding to the body equal to the width of the element
110
107
  */
111
108
  if (isPushed) {
112
- if (side === 'right') {
113
- document.body.style.paddingInlineEnd = "".concat(dimensions.width, "px");
114
- } else if (side === 'left') {
115
- document.body.style.paddingInlineStart = "".concat(dimensions.width, "px");
116
- }
109
+ var paddingSide = side === 'left' ? 'paddingInlineStart' : 'paddingInlineEnd';
110
+ document.body.style[paddingSide] = "".concat(width, "px");
111
+ return function () {
112
+ document.body.style[paddingSide] = '';
113
+ };
117
114
  }
115
+ }, [isPushed, side, width]);
116
+
117
+ /**
118
+ * This class doesn't actually do anything by EUI, but is nice to add for consumers (JIC)
119
+ */
120
+ useEffect(function () {
121
+ document.body.classList.add('euiBody--hasFlyout');
118
122
  return function () {
123
+ // Remove the hasFlyout class when the flyout is unmounted
119
124
  document.body.classList.remove('euiBody--hasFlyout');
120
- if (isPushed) {
121
- if (side === 'right') {
122
- document.body.style.paddingInlineEnd = '';
123
- } else if (side === 'left') {
124
- document.body.style.paddingInlineStart = '';
125
- }
126
- }
127
125
  };
128
- }, [side, dimensions, isPushed]);
126
+ }, []);
129
127
 
130
128
  /**
131
129
  * ESC key closes flyout (always?)
@@ -13,24 +13,22 @@ function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) r
13
13
  import React from 'react';
14
14
  import PropTypes from "prop-types";
15
15
  import classNames from 'classnames';
16
+ import { useEuiMemoizedStyles } from '../../../services';
16
17
  import { EuiBreadcrumbs } from '../../breadcrumbs';
17
18
  import { euiHeaderBreadcrumbsStyles } from './header_breadcrumbs.styles';
18
- import { useEuiTheme } from '../../../services';
19
19
  import { jsx as ___EmotionJSX } from "@emotion/react";
20
20
  export var EuiHeaderBreadcrumbs = function EuiHeaderBreadcrumbs(_ref) {
21
21
  var className = _ref.className,
22
22
  breadcrumbs = _ref.breadcrumbs,
23
23
  rest = _objectWithoutProperties(_ref, _excluded);
24
24
  var classes = classNames('euiHeaderBreadcrumbs', className);
25
- var euiTheme = useEuiTheme();
26
- var styles = euiHeaderBreadcrumbsStyles(euiTheme);
27
- var cssHeaderBreadcrumbStyles = [styles.euiHeaderBreadcrumbs];
25
+ var styles = useEuiMemoizedStyles(euiHeaderBreadcrumbsStyles);
28
26
  return ___EmotionJSX(EuiBreadcrumbs, _extends({
29
27
  max: 4,
30
28
  truncate: true,
31
29
  breadcrumbs: breadcrumbs,
32
30
  className: classes,
33
- css: cssHeaderBreadcrumbStyles,
31
+ css: styles.euiHeaderBreadcrumbs,
34
32
  type: "application"
35
33
  }, rest));
36
34
  };
@@ -74,7 +74,8 @@ export var EuiConfirmModal = function EuiConfirmModal(_ref) {
74
74
  return ___EmotionJSX(EuiModal, _extends({
75
75
  className: classes,
76
76
  css: cssStyles,
77
- onClose: onCancel
77
+ onClose: onCancel,
78
+ role: "alertdialog"
78
79
  }, rest), modalTitle, message && ___EmotionJSX(EuiModalBody, null, ___EmotionJSX(EuiText, {
79
80
  "data-test-subj": "confirmModalBodyText"
80
81
  }, message)), ___EmotionJSX(EuiModalFooter, null, ___EmotionJSX(EuiButtonEmpty, {
@@ -1,5 +1,5 @@
1
1
  function _typeof(obj) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) { return typeof obj; } : function (obj) { return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }, _typeof(obj); }
2
- var _excluded = ["className", "children", "initialFocus", "onClose", "maxWidth", "style"];
2
+ var _excluded = ["className", "children", "initialFocus", "onClose", "maxWidth", "role", "style"];
3
3
  function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
4
4
  function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
5
5
  function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { _defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
@@ -33,6 +33,8 @@ export var EuiModal = function EuiModal(_ref) {
33
33
  onClose = _ref.onClose,
34
34
  _ref$maxWidth = _ref.maxWidth,
35
35
  maxWidth = _ref$maxWidth === void 0 ? true : _ref$maxWidth,
36
+ _ref$role = _ref.role,
37
+ role = _ref$role === void 0 ? 'dialog' : _ref$role,
36
38
  style = _ref.style,
37
39
  rest = _objectWithoutProperties(_ref, _excluded);
38
40
  var onKeyDown = function onKeyDown(event) {
@@ -62,7 +64,9 @@ export var EuiModal = function EuiModal(_ref) {
62
64
  className: classes,
63
65
  onKeyDown: onKeyDown,
64
66
  tabIndex: 0,
65
- style: newStyle
67
+ style: newStyle,
68
+ role: role,
69
+ "aria-modal": true
66
70
  }, rest), ___EmotionJSX(EuiI18n, {
67
71
  token: "euiModal.closeModal",
68
72
  default: "Closes this modal window"
@@ -96,5 +100,10 @@ EuiModal.propTypes = {
96
100
  * Specifies what element should initially have focus.
97
101
  * Can be a DOM node, or a selector string (which will be passed to document.querySelector() to find the DOM node), or a function that returns a DOM node.
98
102
  */
99
- initialFocus: PropTypes.oneOfType([PropTypes.any.isRequired, PropTypes.func.isRequired, PropTypes.string.isRequired])
103
+ initialFocus: PropTypes.oneOfType([PropTypes.any.isRequired, PropTypes.func.isRequired, PropTypes.string.isRequired]),
104
+ /**
105
+ * Identifies a modal dialog to screen readers. Modal dialogs that confirm destructive actions
106
+ * or need a user's attention should use "alertdialog".
107
+ */
108
+ role: PropTypes.oneOf(["dialog", "alertdialog"])
100
109
  };
@@ -44,14 +44,13 @@ export var EuiResizeObserver = /*#__PURE__*/function (_EuiObserver) {
44
44
  height: 0,
45
45
  width: 0
46
46
  });
47
- _defineProperty(_assertThisInitialized(_this), "onResize", function () {
48
- // `entry.contentRect` provides incomplete `height` and `width` data.
49
- // Use `getBoundingClientRect` to account for padding and border.
50
- // https://developer.mozilla.org/en-US/docs/Web/API/DOMRectReadOnly
51
- if (!_this.childNode) return;
52
- var _this$childNode$getBo = _this.childNode.getBoundingClientRect(),
53
- height = _this$childNode$getBo.height,
54
- width = _this$childNode$getBo.width;
47
+ _defineProperty(_assertThisInitialized(_this), "onResize", function (_ref) {
48
+ var _ref2 = _slicedToArray(_ref, 1),
49
+ entry = _ref2[0];
50
+ var _entry$borderBoxSize$ = entry.borderBoxSize[0],
51
+ width = _entry$borderBoxSize$.inlineSize,
52
+ height = _entry$borderBoxSize$.blockSize;
53
+
55
54
  // Check for actual resize event
56
55
  if (_this.state.height === height && _this.state.width === width) {
57
56
  return;
@@ -105,23 +104,15 @@ export var useResizeObserver = function useResizeObserver(container, dimension)
105
104
  }, [dimension]);
106
105
  useEffect(function () {
107
106
  if (container != null) {
108
- // ResizeObserver's first call to the observation callback is scheduled in the future
109
- // so find the container's initial dimensions now
110
- var boundingRect = container.getBoundingClientRect();
111
- setSize({
112
- width: boundingRect.width,
113
- height: boundingRect.height
114
- });
115
- var observer = makeResizeObserver(container, function () {
116
- // `entry.contentRect` provides incomplete `height` and `width` data.
117
- // Use `getBoundingClientRect` to account for padding and border.
118
- // https://developer.mozilla.org/en-US/docs/Web/API/DOMRectReadOnly
119
- var _container$getBoundin = container.getBoundingClientRect(),
120
- height = _container$getBoundin.height,
121
- width = _container$getBoundin.width;
107
+ var observer = makeResizeObserver(container, function (_ref3) {
108
+ var _ref4 = _slicedToArray(_ref3, 1),
109
+ entry = _ref4[0];
110
+ var _entry$borderBoxSize$2 = entry.borderBoxSize[0],
111
+ inlineSize = _entry$borderBoxSize$2.inlineSize,
112
+ blockSize = _entry$borderBoxSize$2.blockSize;
122
113
  setSize({
123
- width: width,
124
- height: height
114
+ width: inlineSize,
115
+ height: blockSize
125
116
  });
126
117
  });
127
118
  return function () {
@@ -17,7 +17,7 @@ function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) r
17
17
  import React from 'react';
18
18
  import PropTypes from "prop-types";
19
19
  import classNames from 'classnames';
20
- import { useEuiTheme } from '../../services';
20
+ import { useEuiMemoizedStyles } from '../../services';
21
21
  import { euiSpacerStyles } from './spacer.styles';
22
22
  import { jsx as ___EmotionJSX } from "@emotion/react";
23
23
  export var SIZES = ['xs', 's', 'm', 'l', 'xl', 'xxl'];
@@ -26,8 +26,7 @@ export var EuiSpacer = function EuiSpacer(_ref) {
26
26
  _ref$size = _ref.size,
27
27
  size = _ref$size === void 0 ? 'l' : _ref$size,
28
28
  rest = _objectWithoutProperties(_ref, _excluded);
29
- var euiTheme = useEuiTheme();
30
- var styles = euiSpacerStyles(euiTheme);
29
+ var styles = useEuiMemoizedStyles(euiSpacerStyles);
31
30
  var classes = classNames('euiSpacer', _defineProperty({}, "euiSpacer--".concat(size), size), className);
32
31
  var cssStyles = [styles.euiSpacer, styles[size]];
33
32
  return ___EmotionJSX("div", _extends({