@elastic/eui 64.0.1 → 65.0.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 (354) hide show
  1. package/dist/eui_charts_theme.js +330 -330
  2. package/dist/eui_charts_theme.js.map +1 -1
  3. package/dist/eui_theme_dark.css +160 -1248
  4. package/dist/eui_theme_dark.json +0 -32
  5. package/dist/eui_theme_dark.json.d.ts +0 -32
  6. package/dist/eui_theme_dark.min.css +1 -1
  7. package/dist/eui_theme_light.css +132 -1220
  8. package/dist/eui_theme_light.json +0 -32
  9. package/dist/eui_theme_light.json.d.ts +0 -32
  10. package/dist/eui_theme_light.min.css +1 -1
  11. package/es/components/accessibility/screen_reader_only/screen_reader_only.styles.js +2 -1
  12. package/es/components/accessibility/skip_link/skip_link.js +4 -54
  13. package/es/components/accordion/accordion.js +2 -1
  14. package/es/components/accordion/accordion.styles.js +17 -27
  15. package/es/components/badge/beta_badge/beta_badge.js +16 -3
  16. package/es/components/basic_table/basic_table.js +1 -1
  17. package/es/components/basic_table/collapsed_item_actions.js +1 -1
  18. package/es/components/basic_table/in_memory_table.js +1 -1
  19. package/es/components/beacon/beacon.styles.js +2 -2
  20. package/es/components/button/button.js +112 -215
  21. package/es/components/button/button_display/_button_display.js +90 -40
  22. package/es/components/button/button_display/_button_display.styles.js +7 -16
  23. package/es/components/button/button_display/_button_display_content.js +6 -3
  24. package/es/components/button/button_display/_button_display_content.styles.js +7 -17
  25. package/es/components/button/button_empty/button_empty.js +63 -53
  26. package/es/components/button/button_empty/index.js +1 -1
  27. package/es/components/button/button_group/button_group.js +4 -12
  28. package/es/components/button/button_group/button_group_button.js +14 -4
  29. package/es/components/button/button_icon/button_icon.js +61 -42
  30. package/es/components/call_out/call_out.styles.js +2 -1
  31. package/es/components/card/card.js +173 -89
  32. package/es/components/card/card.styles.js +136 -0
  33. package/es/components/card/card_select/card_select.js +133 -0
  34. package/es/components/card/card_select/card_select.styles.js +25 -0
  35. package/es/components/card/card_select/index.js +8 -0
  36. package/es/components/card/checkable_card/checkable_card.js +14 -9
  37. package/es/components/card/checkable_card/checkable_card.styles.js +22 -0
  38. package/es/components/comment_list/comment_event.styles.js +1 -1
  39. package/es/components/datagrid/body/data_grid_body.js +7 -6
  40. package/es/components/datagrid/body/data_grid_cell.js +13 -12
  41. package/es/components/datagrid/body/header/data_grid_header_cell.js +7 -6
  42. package/es/components/datagrid/body/header/data_grid_header_row.js +7 -6
  43. package/es/components/datagrid/data_grid.js +7 -6
  44. package/es/components/datagrid/utils/in_memory.js +7 -6
  45. package/es/components/date_picker/auto_refresh/auto_refresh.js +3 -2
  46. package/es/components/date_picker/super_date_picker/super_date_picker.js +17 -1
  47. package/es/components/date_picker/super_date_picker/super_update_button.js +11 -1
  48. package/es/components/expression/expression.styles.js +13 -31
  49. package/es/components/facet/facet_button.js +5 -4
  50. package/es/components/header/header_links/header_link.js +5 -3
  51. package/es/components/image/image_button.styles.js +1 -1
  52. package/es/components/image/image_wrapper.styles.js +3 -3
  53. package/es/components/link/link.styles.js +2 -2
  54. package/es/components/list_group/list_group.js +2 -1
  55. package/es/components/list_group/list_group_item.js +2 -1
  56. package/es/components/list_group/pinnable_list_group/pinnable_list_group.js +3 -2
  57. package/es/components/loading/loading_chart.styles.js +16 -26
  58. package/es/components/loading/loading_content.styles.js +2 -2
  59. package/es/components/loading/loading_logo.styles.js +4 -4
  60. package/es/components/loading/loading_spinner.styles.js +6 -6
  61. package/es/components/markdown_editor/markdown_editor_toolbar.js +2 -0
  62. package/es/components/modal/confirm_modal.js +1 -1
  63. package/es/components/notification/notification_event.js +5 -3
  64. package/es/components/notification/notification_event_read_button.js +2 -1
  65. package/es/components/page/page_template.js +2 -2
  66. package/es/components/page_template/inner/page_inner.styles.js +2 -2
  67. package/es/components/page_template/outer/page_outer.styles.js +3 -1
  68. package/es/components/pagination/pagination_button.js +5 -3
  69. package/es/components/panel/panel.js +1 -1
  70. package/es/components/panel/{panel.style.js → panel.styles.js} +2 -2
  71. package/es/components/progress/progress.styles.js +2 -2
  72. package/es/components/title/title.styles.js +2 -2
  73. package/es/components/toast/toast.styles.js +4 -4
  74. package/es/components/tool_tip/icon_tip.js +11 -1
  75. package/es/components/tool_tip/tool_tip.js +18 -6
  76. package/es/global_styling/functions/logicals.js +2 -72
  77. package/es/global_styling/functions/typography.js +2 -1
  78. package/es/global_styling/mixins/_color.js +1 -1
  79. package/es/global_styling/mixins/_helpers.js +7 -1
  80. package/es/global_styling/reset/global_styles.js +2 -1
  81. package/es/themes/amsterdam/global_styling/mixins/button.js +165 -16
  82. package/eui.d.ts +1062 -936
  83. package/i18ntokens.json +15 -15
  84. package/lib/components/accessibility/screen_reader_only/screen_reader_only.styles.js +3 -1
  85. package/lib/components/accessibility/skip_link/skip_link.js +4 -54
  86. package/lib/components/accordion/accordion.js +3 -1
  87. package/lib/components/accordion/accordion.styles.js +17 -26
  88. package/lib/components/badge/beta_badge/beta_badge.js +16 -3
  89. package/lib/components/basic_table/basic_table.js +1 -1
  90. package/lib/components/basic_table/collapsed_item_actions.js +1 -1
  91. package/lib/components/basic_table/in_memory_table.js +1 -1
  92. package/lib/components/beacon/beacon.styles.js +1 -1
  93. package/lib/components/button/button.js +124 -229
  94. package/lib/components/button/button_display/_button_display.js +94 -33
  95. package/lib/components/button/button_display/_button_display.styles.js +7 -16
  96. package/lib/components/button/button_display/_button_display_content.js +7 -3
  97. package/lib/components/button/button_display/_button_display_content.styles.js +7 -17
  98. package/lib/components/button/button_empty/button_empty.js +64 -54
  99. package/lib/components/button/button_empty/index.js +0 -6
  100. package/lib/components/button/button_group/button_group.js +4 -12
  101. package/lib/components/button/button_group/button_group_button.js +15 -4
  102. package/lib/components/button/button_icon/button_icon.js +61 -43
  103. package/lib/components/call_out/call_out.styles.js +2 -1
  104. package/lib/components/card/card.js +174 -88
  105. package/lib/components/card/card.styles.js +146 -0
  106. package/lib/components/card/card_select/card_select.js +144 -0
  107. package/lib/components/card/card_select/card_select.styles.js +27 -0
  108. package/lib/components/card/card_select/index.js +19 -0
  109. package/lib/components/card/checkable_card/checkable_card.js +16 -9
  110. package/lib/components/card/checkable_card/checkable_card.styles.js +33 -0
  111. package/lib/components/comment_list/comment_event.styles.js +1 -1
  112. package/lib/components/datagrid/body/data_grid_body.js +7 -6
  113. package/lib/components/datagrid/body/data_grid_cell.js +13 -12
  114. package/lib/components/datagrid/body/header/data_grid_header_cell.js +7 -6
  115. package/lib/components/datagrid/body/header/data_grid_header_row.js +7 -6
  116. package/lib/components/datagrid/data_grid.js +7 -6
  117. package/lib/components/datagrid/utils/in_memory.js +7 -6
  118. package/lib/components/date_picker/auto_refresh/auto_refresh.js +3 -2
  119. package/lib/components/date_picker/super_date_picker/super_date_picker.js +17 -1
  120. package/lib/components/date_picker/super_date_picker/super_update_button.js +11 -1
  121. package/lib/components/expression/expression.styles.js +12 -30
  122. package/lib/components/facet/facet_button.js +4 -3
  123. package/lib/components/header/header_links/header_link.js +5 -3
  124. package/lib/components/image/image_button.styles.js +1 -1
  125. package/lib/components/image/image_wrapper.styles.js +2 -2
  126. package/lib/components/link/link.styles.js +1 -1
  127. package/lib/components/list_group/list_group.js +2 -1
  128. package/lib/components/list_group/list_group_item.js +2 -1
  129. package/lib/components/list_group/pinnable_list_group/pinnable_list_group.js +3 -2
  130. package/lib/components/loading/loading_chart.styles.js +16 -25
  131. package/lib/components/loading/loading_content.styles.js +1 -1
  132. package/lib/components/loading/loading_logo.styles.js +4 -4
  133. package/lib/components/loading/loading_spinner.styles.js +5 -5
  134. package/lib/components/markdown_editor/markdown_editor_toolbar.js +2 -0
  135. package/lib/components/modal/confirm_modal.js +1 -1
  136. package/lib/components/notification/notification_event.js +5 -3
  137. package/lib/components/notification/notification_event_read_button.js +2 -1
  138. package/lib/components/page/page_template.js +1 -1
  139. package/lib/components/page_template/inner/page_inner.styles.js +2 -2
  140. package/lib/components/page_template/outer/page_outer.styles.js +4 -1
  141. package/lib/components/panel/panel.js +1 -1
  142. package/{optimize/lib/components/panel/panel.style.js → lib/components/panel/panel.styles.js} +1 -1
  143. package/lib/components/progress/progress.styles.js +2 -2
  144. package/lib/components/title/title.styles.js +1 -1
  145. package/lib/components/toast/toast.styles.js +4 -4
  146. package/lib/components/tool_tip/icon_tip.js +11 -1
  147. package/lib/components/tool_tip/tool_tip.js +18 -6
  148. package/lib/global_styling/functions/logicals.js +3 -72
  149. package/lib/global_styling/functions/typography.js +3 -1
  150. package/lib/global_styling/mixins/_color.js +1 -1
  151. package/lib/global_styling/mixins/_helpers.js +9 -2
  152. package/lib/global_styling/reset/global_styles.js +3 -1
  153. package/lib/themes/amsterdam/global_styling/mixins/button.js +178 -24
  154. package/optimize/es/components/accessibility/screen_reader_only/screen_reader_only.styles.js +2 -1
  155. package/optimize/es/components/accordion/accordion.js +2 -1
  156. package/optimize/es/components/accordion/accordion.styles.js +17 -27
  157. package/optimize/es/components/badge/beta_badge/beta_badge.js +6 -3
  158. package/optimize/es/components/beacon/beacon.styles.js +2 -2
  159. package/optimize/es/components/button/button.js +88 -100
  160. package/optimize/es/components/button/button_display/_button_display.js +67 -32
  161. package/optimize/es/components/button/button_display/_button_display.styles.js +7 -16
  162. package/optimize/es/components/button/button_display/_button_display_content.js +5 -2
  163. package/optimize/es/components/button/button_display/_button_display_content.styles.js +7 -17
  164. package/optimize/es/components/button/button_empty/button_empty.js +55 -47
  165. package/optimize/es/components/button/button_empty/index.js +1 -1
  166. package/optimize/es/components/button/button_group/button_group.js +2 -10
  167. package/optimize/es/components/button/button_group/button_group_button.js +13 -3
  168. package/optimize/es/components/button/button_icon/button_icon.js +54 -41
  169. package/optimize/es/components/call_out/call_out.styles.js +2 -1
  170. package/optimize/es/components/card/card.js +97 -31
  171. package/optimize/es/components/card/card.styles.js +136 -0
  172. package/optimize/es/components/card/{card_select.js → card_select/card_select.js} +16 -14
  173. package/optimize/es/components/card/card_select/card_select.styles.js +25 -0
  174. package/optimize/es/components/card/card_select/index.js +8 -0
  175. package/optimize/es/components/card/checkable_card/checkable_card.js +14 -9
  176. package/optimize/es/components/card/checkable_card/checkable_card.styles.js +22 -0
  177. package/optimize/es/components/comment_list/comment_event.styles.js +1 -1
  178. package/optimize/es/components/expression/expression.styles.js +13 -31
  179. package/optimize/es/components/facet/facet_button.js +5 -3
  180. package/optimize/es/components/image/image_button.styles.js +1 -1
  181. package/optimize/es/components/image/image_wrapper.styles.js +3 -3
  182. package/optimize/es/components/link/link.styles.js +2 -2
  183. package/optimize/es/components/loading/loading_chart.styles.js +16 -26
  184. package/optimize/es/components/loading/loading_content.styles.js +2 -2
  185. package/optimize/es/components/loading/loading_logo.styles.js +4 -4
  186. package/optimize/es/components/loading/loading_spinner.styles.js +6 -6
  187. package/optimize/es/components/markdown_editor/markdown_editor_toolbar.js +2 -0
  188. package/optimize/es/components/page/page_template.js +2 -2
  189. package/optimize/es/components/page_template/inner/page_inner.styles.js +2 -2
  190. package/optimize/es/components/page_template/outer/page_outer.styles.js +3 -1
  191. package/optimize/es/components/panel/panel.js +1 -1
  192. package/optimize/es/components/panel/{panel.style.js → panel.styles.js} +2 -2
  193. package/optimize/es/components/progress/progress.styles.js +2 -2
  194. package/optimize/es/components/title/title.styles.js +2 -2
  195. package/optimize/es/components/toast/toast.styles.js +4 -4
  196. package/optimize/es/components/tool_tip/tool_tip.js +7 -5
  197. package/optimize/es/global_styling/functions/logicals.js +2 -72
  198. package/optimize/es/global_styling/functions/typography.js +2 -1
  199. package/optimize/es/global_styling/mixins/_color.js +1 -1
  200. package/optimize/es/global_styling/mixins/_helpers.js +7 -1
  201. package/optimize/es/global_styling/reset/global_styles.js +2 -1
  202. package/optimize/es/themes/amsterdam/global_styling/mixins/button.js +155 -16
  203. package/optimize/lib/components/accessibility/screen_reader_only/screen_reader_only.styles.js +3 -1
  204. package/optimize/lib/components/accordion/accordion.js +3 -1
  205. package/optimize/lib/components/accordion/accordion.styles.js +17 -26
  206. package/optimize/lib/components/badge/beta_badge/beta_badge.js +6 -3
  207. package/optimize/lib/components/beacon/beacon.styles.js +1 -1
  208. package/optimize/lib/components/button/button.js +92 -103
  209. package/optimize/lib/components/button/button_display/_button_display.js +71 -25
  210. package/optimize/lib/components/button/button_display/_button_display.styles.js +7 -16
  211. package/optimize/lib/components/button/button_display/_button_display_content.js +6 -2
  212. package/optimize/lib/components/button/button_display/_button_display_content.styles.js +7 -17
  213. package/optimize/lib/components/button/button_empty/button_empty.js +59 -50
  214. package/optimize/lib/components/button/button_empty/index.js +0 -6
  215. package/optimize/lib/components/button/button_group/button_group.js +2 -10
  216. package/optimize/lib/components/button/button_group/button_group_button.js +15 -3
  217. package/optimize/lib/components/button/button_icon/button_icon.js +54 -41
  218. package/optimize/lib/components/call_out/call_out.styles.js +2 -1
  219. package/optimize/lib/components/card/card.js +97 -30
  220. package/optimize/lib/components/card/card.styles.js +146 -0
  221. package/optimize/lib/components/card/{card_select.js → card_select/card_select.js} +16 -14
  222. package/optimize/lib/components/card/card_select/card_select.styles.js +27 -0
  223. package/optimize/lib/components/card/card_select/index.js +19 -0
  224. package/optimize/lib/components/card/checkable_card/checkable_card.js +16 -9
  225. package/optimize/lib/components/card/checkable_card/checkable_card.styles.js +33 -0
  226. package/optimize/lib/components/comment_list/comment_event.styles.js +1 -1
  227. package/optimize/lib/components/expression/expression.styles.js +12 -30
  228. package/optimize/lib/components/facet/facet_button.js +4 -2
  229. package/optimize/lib/components/image/image_button.styles.js +1 -1
  230. package/optimize/lib/components/image/image_wrapper.styles.js +2 -2
  231. package/optimize/lib/components/link/link.styles.js +1 -1
  232. package/optimize/lib/components/loading/loading_chart.styles.js +16 -25
  233. package/optimize/lib/components/loading/loading_content.styles.js +1 -1
  234. package/optimize/lib/components/loading/loading_logo.styles.js +4 -4
  235. package/optimize/lib/components/loading/loading_spinner.styles.js +5 -5
  236. package/optimize/lib/components/markdown_editor/markdown_editor_toolbar.js +2 -0
  237. package/optimize/lib/components/page/page_template.js +1 -1
  238. package/optimize/lib/components/page_template/inner/page_inner.styles.js +2 -2
  239. package/optimize/lib/components/page_template/outer/page_outer.styles.js +4 -1
  240. package/optimize/lib/components/panel/panel.js +1 -1
  241. package/{test-env/components/panel/panel.style.js → optimize/lib/components/panel/panel.styles.js} +1 -1
  242. package/optimize/lib/components/progress/progress.styles.js +2 -2
  243. package/optimize/lib/components/title/title.styles.js +1 -1
  244. package/optimize/lib/components/toast/toast.styles.js +4 -4
  245. package/optimize/lib/components/tool_tip/tool_tip.js +7 -5
  246. package/optimize/lib/global_styling/functions/logicals.js +10 -73
  247. package/optimize/lib/global_styling/functions/typography.js +3 -1
  248. package/optimize/lib/global_styling/mixins/_color.js +1 -1
  249. package/optimize/lib/global_styling/mixins/_helpers.js +9 -2
  250. package/optimize/lib/global_styling/reset/global_styles.js +3 -1
  251. package/optimize/lib/themes/amsterdam/global_styling/mixins/button.js +170 -17
  252. package/package.json +2 -2
  253. package/src/components/badge/beta_badge/_beta_badge.scss +5 -1
  254. package/src/components/button/_index.scss +0 -1
  255. package/src/components/button/button_empty/_button_empty.scss +4 -48
  256. package/src/components/button/button_group/_button_group.scss +0 -1
  257. package/src/components/button/button_group/_button_group_button.scss +55 -83
  258. package/src/components/button/button_icon/_button_icon.scss +3 -103
  259. package/src/components/control_bar/_control_bar.scss +2 -6
  260. package/src/components/flyout/_flyout.scss +4 -1
  261. package/src/components/index.scss +0 -1
  262. package/src/global_styling/mixins/_button.scss +55 -11
  263. package/src/global_styling/mixins/_index.scss +0 -1
  264. package/src/themes/amsterdam/global_styling/mixins/_index.scss +0 -2
  265. package/src/themes/amsterdam/overrides/_header.scss +0 -2
  266. package/src/themes/amsterdam/overrides/_index.scss +0 -4
  267. package/test-env/components/accessibility/screen_reader_only/screen_reader_only.styles.js +3 -1
  268. package/test-env/components/accessibility/skip_link/skip_link.js +4 -54
  269. package/test-env/components/accordion/accordion.js +3 -1
  270. package/test-env/components/accordion/accordion.styles.js +17 -26
  271. package/test-env/components/badge/beta_badge/beta_badge.js +16 -3
  272. package/test-env/components/basic_table/basic_table.js +1 -1
  273. package/test-env/components/basic_table/collapsed_item_actions.js +1 -1
  274. package/test-env/components/basic_table/in_memory_table.js +1 -1
  275. package/test-env/components/beacon/beacon.styles.js +1 -1
  276. package/test-env/components/button/button.js +111 -225
  277. package/test-env/components/button/button_display/_button_display.js +93 -32
  278. package/test-env/components/button/button_display/_button_display.styles.js +7 -16
  279. package/test-env/components/button/button_display/_button_display_content.js +7 -3
  280. package/test-env/components/button/button_display/_button_display_content.styles.js +7 -17
  281. package/test-env/components/button/button_empty/button_empty.js +64 -53
  282. package/test-env/components/button/button_empty/index.js +0 -6
  283. package/test-env/components/button/button_group/button_group.js +4 -12
  284. package/test-env/components/button/button_group/button_group_button.js +16 -4
  285. package/test-env/components/button/button_icon/button_icon.js +61 -42
  286. package/test-env/components/call_out/call_out.styles.js +2 -1
  287. package/test-env/components/card/card.js +172 -88
  288. package/test-env/components/card/card.styles.js +146 -0
  289. package/test-env/components/card/card_select/card_select.js +141 -0
  290. package/test-env/components/card/card_select/card_select.styles.js +27 -0
  291. package/test-env/components/card/card_select/index.js +19 -0
  292. package/test-env/components/card/checkable_card/checkable_card.js +16 -9
  293. package/test-env/components/card/checkable_card/checkable_card.styles.js +33 -0
  294. package/test-env/components/comment_list/comment_event.styles.js +1 -1
  295. package/test-env/components/datagrid/body/data_grid_body.js +7 -6
  296. package/test-env/components/datagrid/body/data_grid_cell.js +13 -12
  297. package/test-env/components/datagrid/body/header/data_grid_header_cell.js +7 -6
  298. package/test-env/components/datagrid/body/header/data_grid_header_row.js +7 -6
  299. package/test-env/components/datagrid/data_grid.js +7 -6
  300. package/test-env/components/datagrid/utils/in_memory.js +7 -6
  301. package/test-env/components/date_picker/auto_refresh/auto_refresh.js +3 -2
  302. package/test-env/components/date_picker/super_date_picker/super_date_picker.js +17 -1
  303. package/test-env/components/date_picker/super_date_picker/super_update_button.js +11 -1
  304. package/test-env/components/expression/expression.styles.js +12 -30
  305. package/test-env/components/facet/facet_button.js +4 -3
  306. package/test-env/components/header/header_links/header_link.js +5 -3
  307. package/test-env/components/image/image_button.styles.js +1 -1
  308. package/test-env/components/image/image_wrapper.styles.js +2 -2
  309. package/test-env/components/link/link.styles.js +1 -1
  310. package/test-env/components/list_group/list_group.js +2 -1
  311. package/test-env/components/list_group/list_group_item.js +2 -1
  312. package/test-env/components/list_group/pinnable_list_group/pinnable_list_group.js +3 -2
  313. package/test-env/components/loading/loading_chart.styles.js +16 -25
  314. package/test-env/components/loading/loading_content.styles.js +1 -1
  315. package/test-env/components/loading/loading_logo.styles.js +4 -4
  316. package/test-env/components/loading/loading_spinner.styles.js +5 -5
  317. package/test-env/components/markdown_editor/markdown_editor_toolbar.js +2 -0
  318. package/test-env/components/modal/confirm_modal.js +1 -1
  319. package/test-env/components/notification/notification_event.js +5 -3
  320. package/test-env/components/notification/notification_event_read_button.js +2 -1
  321. package/test-env/components/page/page_template.js +1 -1
  322. package/test-env/components/page_template/inner/page_inner.styles.js +2 -2
  323. package/test-env/components/page_template/outer/page_outer.styles.js +4 -1
  324. package/test-env/components/panel/panel.js +1 -1
  325. package/{lib/components/panel/panel.style.js → test-env/components/panel/panel.styles.js} +1 -1
  326. package/test-env/components/progress/progress.styles.js +2 -2
  327. package/test-env/components/title/title.styles.js +1 -1
  328. package/test-env/components/toast/toast.styles.js +4 -4
  329. package/test-env/components/tool_tip/icon_tip.js +11 -1
  330. package/test-env/components/tool_tip/tool_tip.js +18 -6
  331. package/test-env/global_styling/functions/logicals.js +10 -73
  332. package/test-env/global_styling/functions/typography.js +3 -1
  333. package/test-env/global_styling/mixins/_color.js +1 -1
  334. package/test-env/global_styling/mixins/_helpers.js +9 -2
  335. package/test-env/global_styling/reset/global_styles.js +3 -1
  336. package/test-env/themes/amsterdam/global_styling/mixins/button.js +170 -17
  337. package/es/components/card/card_select.js +0 -176
  338. package/lib/components/card/card_select.js +0 -187
  339. package/src/components/button/_button.scss +0 -143
  340. package/src/components/button/button_icon/_variables.scss +0 -11
  341. package/src/components/card/_card.scss +0 -239
  342. package/src/components/card/_card_select.scss +0 -21
  343. package/src/components/card/_index.scss +0 -5
  344. package/src/components/card/_mixins.scss +0 -11
  345. package/src/components/card/_variables.scss +0 -25
  346. package/src/components/card/checkable_card/_checkable_card.scss +0 -29
  347. package/src/components/card/checkable_card/_index.scss +0 -1
  348. package/src/global_styling/mixins/_beta_badge.scss +0 -30
  349. package/src/themes/amsterdam/global_styling/mixins/_button.scss +0 -60
  350. package/src/themes/amsterdam/overrides/_button.scss +0 -119
  351. package/src/themes/amsterdam/overrides/_button_empty.scss +0 -20
  352. package/src/themes/amsterdam/overrides/_button_group.scss +0 -91
  353. package/src/themes/amsterdam/overrides/_card.scss +0 -6
  354. package/test-env/components/card/card_select.js +0 -184
@@ -15,6 +15,8 @@ var _react2 = require("@emotion/react");
15
15
 
16
16
  var _mixins = require("../mixins");
17
17
 
18
+ var _functions = require("../functions");
19
+
18
20
  var _color = require("../../services/color");
19
21
 
20
22
  var _theme = require("../../services/theme");
@@ -55,7 +57,7 @@ var EuiGlobalStyles = function EuiGlobalStyles(_ref) {
55
57
  * Final styles
56
58
  */
57
59
 
58
- var styles = /*#__PURE__*/(0, _react2.css)(_reset.resetStyles, " html{", scrollbarStyles, " ", fontReset, " text-size-adjust:100%;font-kerning:normal;height:100%;background-color:", colors.body, ";color:", colors.text, ";}code,pre,kbd,samp{font-family:", font.familyCode, ";}input,textarea,select{", fontReset, ";}button{font-family:", font.family, ";}em{font-style:italic;}strong{font-weight:", font.weight.bold, ";}*:focus{", (0, _mixins.euiFocusRing)(euiThemeContext), ";}::selection{background:", (0, _color.transparentize)(colors.primary, colorMode === 'LIGHT' ? 0.1 : 0.2), ";}a{color:", colors.primaryText, ";&,&:hover,&:focus{text-decoration:none;}}.euiBody-hasPortalContent{position:relative;};label:styles;");
60
+ var styles = /*#__PURE__*/(0, _react2.css)(_reset.resetStyles, " html{", scrollbarStyles, " ", fontReset, " text-size-adjust:100%;font-kerning:normal;", (0, _functions.logicalCSS)('height', '100%'), " background-color:", colors.body, ";color:", colors.text, ";}code,pre,kbd,samp{font-family:", font.familyCode, ";}input,textarea,select{", fontReset, ";}button{font-family:", font.family, ";}em{font-style:italic;}strong{font-weight:", font.weight.bold, ";}*:focus{", (0, _mixins.euiFocusRing)(euiThemeContext), ";}::selection{background:", (0, _color.transparentize)(colors.primary, colorMode === 'LIGHT' ? 0.1 : 0.2), ";}a{color:", colors.primaryText, ";&,&:hover,&:focus{text-decoration:none;}}.euiBody-hasPortalContent{position:relative;};label:styles;");
59
61
  return (0, _react2.jsx)(_react2.Global, {
60
62
  styles: styles
61
63
  });
@@ -1,12 +1,18 @@
1
1
  "use strict";
2
2
 
3
+ var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
4
+
3
5
  Object.defineProperty(exports, "__esModule", {
4
6
  value: true
5
7
  });
6
- exports.useEuiButtonColorCSS = exports.euiButtonColor = exports.BUTTON_COLORS = void 0;
8
+ exports.useEuiButtonRadiusCSS = exports.useEuiButtonFocusCSS = exports.useEuiButtonColorCSS = exports.euiButtonFillColor = exports.euiButtonEmptyColor = exports.euiButtonColor = exports.BUTTON_COLORS = void 0;
9
+
10
+ var _toConsumableArray2 = _interopRequireDefault(require("@babel/runtime/helpers/toConsumableArray"));
7
11
 
8
12
  var _react = require("@emotion/react");
9
13
 
14
+ var _global_styling = require("../../../../global_styling");
15
+
10
16
  var _services = require("../../../../services");
11
17
 
12
18
  /*
@@ -16,42 +22,189 @@ var _services = require("../../../../services");
16
22
  * in compliance with, at your election, the Elastic License 2.0 or the Server
17
23
  * Side Public License, v 1.
18
24
  */
19
- var BUTTON_COLORS = ['text', 'accent', 'primary', 'success', 'warning', 'danger', 'disabled'];
25
+ var BUTTON_COLORS = ['text', 'accent', 'primary', 'success', 'warning', 'danger'];
20
26
  exports.BUTTON_COLORS = BUTTON_COLORS;
21
27
 
22
- var euiButtonColor = function euiButtonColor(color, _ref) {
23
- var euiTheme = _ref.euiTheme,
24
- colorMode = _ref.colorMode;
28
+ /**
29
+ * Creates the `base` version of button styles with proper text contrast.
30
+ * @param euiThemeContext
31
+ * @param color One of the named button colors or 'disabled'
32
+ * @returns Style object `{ backgroundColor, color }`
33
+ */
34
+ var euiButtonColor = function euiButtonColor(euiThemeContext, color) {
35
+ var euiTheme = euiThemeContext.euiTheme,
36
+ colorMode = euiThemeContext.colorMode;
25
37
 
26
38
  function tintOrShade(color) {
27
39
  return colorMode === 'DARK' ? (0, _services.shade)(color, 0.7) : (0, _services.tint)(color, 0.8);
28
40
  }
29
41
 
42
+ var foreground;
43
+ var background;
44
+
30
45
  switch (color) {
31
46
  case 'disabled':
32
- return (0, _services.transparentize)(euiTheme.colors.lightShade, 0.15);
47
+ return {
48
+ color: euiTheme.colors.disabledText,
49
+ backgroundColor: (0, _services.transparentize)(euiTheme.colors.lightShade, 0.15)
50
+ };
33
51
 
34
52
  case 'text':
35
- return colorMode === 'DARK' ? (0, _services.shade)(euiTheme.colors.lightShade, 0.2) : (0, _services.tint)(euiTheme.colors.lightShade, 0.5);
53
+ foreground = euiTheme.colors[color];
54
+ background = colorMode === 'DARK' ? (0, _services.shade)(euiTheme.colors.lightShade, 0.2) : (0, _services.tint)(euiTheme.colors.lightShade, 0.5);
55
+ break;
36
56
 
37
57
  default:
38
- return tintOrShade(euiTheme.colors[color]);
58
+ foreground = euiTheme.colors["".concat(color, "Text")];
59
+ background = tintOrShade(euiTheme.colors[color]);
60
+ break;
39
61
  }
62
+
63
+ return {
64
+ color: (0, _services.makeHighContrastColor)(foreground)(background),
65
+ backgroundColor: background
66
+ };
40
67
  };
68
+ /**
69
+ * Creates the `fill` version of buttons styles with proper text contrast.
70
+ * @param euiThemeContext
71
+ * @param color One of the named button colors or 'disabled'
72
+ * @returns Style object `{ backgroundColor, color }`
73
+ */
74
+
41
75
 
42
76
  exports.euiButtonColor = euiButtonColor;
43
77
 
78
+ var euiButtonFillColor = function euiButtonFillColor(euiThemeContext, color) {
79
+ var euiTheme = euiThemeContext.euiTheme,
80
+ colorMode = euiThemeContext.colorMode;
81
+ var background;
82
+ var foreground;
83
+
84
+ switch (color) {
85
+ case 'disabled':
86
+ background = euiButtonColor(euiThemeContext, color).backgroundColor;
87
+ foreground = euiButtonColor(euiThemeContext, color).color;
88
+ break;
89
+
90
+ case 'text':
91
+ background = colorMode === 'DARK' ? euiTheme.colors.text : euiTheme.colors.darkShade;
92
+ foreground = _services.isColorDark.apply(void 0, (0, _toConsumableArray2.default)((0, _services.hexToRgb)(background))) ? euiTheme.colors.ghost : euiTheme.colors.ink;
93
+ break;
94
+
95
+ default:
96
+ background = euiTheme.colors[color];
97
+ foreground = _services.isColorDark.apply(void 0, (0, _toConsumableArray2.default)((0, _services.hexToRgb)(euiTheme.colors[color]))) ? euiTheme.colors.ghost : euiTheme.colors.ink;
98
+ break;
99
+ }
100
+
101
+ return {
102
+ color: foreground,
103
+ backgroundColor: background
104
+ };
105
+ };
106
+ /**
107
+ * Creates the `empty` version of button styles using the text-variant and adding interactive styles.
108
+ * @param euiThemeContext
109
+ * @param color One of the named button colors or 'disabled'
110
+ * @returns Style object `{ backgroundColor, color }` where `background` is typically used for interactive states
111
+ */
112
+
113
+
114
+ exports.euiButtonFillColor = euiButtonFillColor;
115
+
116
+ var euiButtonEmptyColor = function euiButtonEmptyColor(euiThemeContext, color) {
117
+ var foreground;
118
+ var background;
119
+
120
+ switch (color) {
121
+ case 'disabled':
122
+ foreground = euiButtonColor(euiThemeContext, color).color;
123
+ background = 'transparent';
124
+ break;
125
+
126
+ case 'text':
127
+ foreground = euiButtonColor(euiThemeContext, color).color;
128
+ background = (0, _global_styling.euiBackgroundColor)(euiThemeContext, 'subdued', {
129
+ method: 'transparent'
130
+ });
131
+ break;
132
+
133
+ default:
134
+ foreground = euiButtonColor(euiThemeContext, color).color;
135
+ background = (0, _global_styling.euiBackgroundColor)(euiThemeContext, color, {
136
+ method: 'transparent'
137
+ });
138
+ break;
139
+ }
140
+
141
+ return {
142
+ color: foreground,
143
+ backgroundColor: background
144
+ };
145
+ };
146
+ /**
147
+ * Given the button display type, returns the Emotion based color keys.
148
+ * @param options Button display type
149
+ * @returns An object of `_EuiButtonColor` keys including `disabled`
150
+ */
151
+
152
+
153
+ exports.euiButtonEmptyColor = euiButtonEmptyColor;
154
+
44
155
  var useEuiButtonColorCSS = function useEuiButtonColorCSS() {
45
- var euiTheme = (0, _services.useEuiTheme)();
156
+ var options = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
157
+ var euiThemeContext = (0, _services.useEuiTheme)();
158
+
159
+ function stylesByDisplay(color) {
160
+ return {
161
+ base: /*#__PURE__*/(0, _react.css)(euiButtonColor(euiThemeContext, color), ";;label:base;"),
162
+ fill: /*#__PURE__*/(0, _react.css)(euiButtonFillColor(euiThemeContext, color), "outline-color:", euiThemeContext.colorMode === 'DARK' && color === 'text' ? 'currentColor' : euiThemeContext.euiTheme.colors.fullShade, ";;label:fill;"),
163
+ empty: /*#__PURE__*/(0, _react.css)("color:", euiButtonEmptyColor(euiThemeContext, color).color, ";&:focus,&:active{background-color:", euiButtonEmptyColor(euiThemeContext, color).backgroundColor, ";};label:empty;")
164
+ };
165
+ }
166
+
46
167
  return {
47
- text: /*#__PURE__*/(0, _react.css)("background-color:", euiButtonColor('text', euiTheme), ";;label:text;"),
48
- accent: /*#__PURE__*/(0, _react.css)("background-color:", euiButtonColor('accent', euiTheme), ";;label:accent;"),
49
- primary: /*#__PURE__*/(0, _react.css)("background-color:", euiButtonColor('primary', euiTheme), ";;label:primary;"),
50
- success: /*#__PURE__*/(0, _react.css)("background-color:", euiButtonColor('success', euiTheme), ";;label:success;"),
51
- warning: /*#__PURE__*/(0, _react.css)("background-color:", euiButtonColor('warning', euiTheme), ";;label:warning;"),
52
- danger: /*#__PURE__*/(0, _react.css)("background-color:", euiButtonColor('danger', euiTheme), ";;label:danger;"),
53
- disabled: /*#__PURE__*/(0, _react.css)("background-color:", euiButtonColor('disabled', euiTheme), ";;label:disabled;")
168
+ text: /*#__PURE__*/(0, _react.css)(stylesByDisplay('text')[options.display || 'base'], ";label:text;"),
169
+ accent: /*#__PURE__*/(0, _react.css)(stylesByDisplay('accent')[options.display || 'base'], ";label:accent;"),
170
+ primary: /*#__PURE__*/(0, _react.css)(stylesByDisplay('primary')[options.display || 'base'], ";label:primary;"),
171
+ success: /*#__PURE__*/(0, _react.css)(stylesByDisplay('success')[options.display || 'base'], ";label:success;"),
172
+ warning: /*#__PURE__*/(0, _react.css)(stylesByDisplay('warning')[options.display || 'base'], ";label:warning;"),
173
+ danger: /*#__PURE__*/(0, _react.css)(stylesByDisplay('danger')[options.display || 'base'], ";label:danger;"),
174
+ disabled: /*#__PURE__*/(0, _react.css)(stylesByDisplay('disabled')[options.display || 'base'], ";label:disabled;")
54
175
  };
55
176
  };
177
+ /**
178
+ * Based on the button size, creates the style properties.
179
+ * @returns An object of button size keys with Emption styles for `border-radius`
180
+ */
181
+
182
+
183
+ exports.useEuiButtonColorCSS = useEuiButtonColorCSS;
184
+
185
+ var useEuiButtonRadiusCSS = function useEuiButtonRadiusCSS() {
186
+ var _useEuiTheme = (0, _services.useEuiTheme)(),
187
+ euiTheme = _useEuiTheme.euiTheme;
188
+
189
+ return {
190
+ xs: /*#__PURE__*/(0, _react.css)("border-radius:", euiTheme.border.radius.small, ";;label:xs;"),
191
+ s: /*#__PURE__*/(0, _react.css)("border-radius:", euiTheme.border.radius.small, ";;label:s;"),
192
+ m: /*#__PURE__*/(0, _react.css)("border-radius:", euiTheme.border.radius.medium, ";;label:m;")
193
+ };
194
+ };
195
+ /**
196
+ * Creates the translate animation when button is in focus.
197
+ * @returns string
198
+ */
199
+
200
+
201
+ exports.useEuiButtonRadiusCSS = useEuiButtonRadiusCSS;
202
+
203
+ var useEuiButtonFocusCSS = function useEuiButtonFocusCSS() {
204
+ var _useEuiTheme2 = (0, _services.useEuiTheme)(),
205
+ euiTheme = _useEuiTheme2.euiTheme;
206
+
207
+ return "\n ".concat(_global_styling.euiCanAnimate, " {\n transition: transform ").concat(euiTheme.animation.normal, " ease-in-out,\n background-color ").concat(euiTheme.animation.normal, " ease-in-out;\n\n &:hover:not(:disabled) {\n transform: translateY(-1px);\n }\n\n &:focus {\n animation: euiButtonActive ").concat(euiTheme.animation.normal, "\n ").concat(euiTheme.animation.bounce, ";\n }\n\n &:active:not(:disabled) {\n transform: translateY(1px);\n }\n }\n ");
208
+ };
56
209
 
57
- exports.useEuiButtonColorCSS = useEuiButtonColorCSS;
210
+ exports.useEuiButtonFocusCSS = useEuiButtonFocusCSS;
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@elastic/eui",
3
3
  "description": "Elastic UI Component Library",
4
- "version": "64.0.1",
4
+ "version": "65.0.0",
5
5
  "license": "SEE LICENSE IN LICENSE.txt",
6
6
  "main": "lib",
7
7
  "module": "es",
@@ -115,7 +115,7 @@
115
115
  "@cypress/code-coverage": "^3.9.12",
116
116
  "@cypress/react": "^5.10.3",
117
117
  "@cypress/webpack-dev-server": "^1.7.0",
118
- "@elastic/charts": "^47.2.0",
118
+ "@elastic/charts": "^47.2.1",
119
119
  "@elastic/datemath": "^5.0.3",
120
120
  "@elastic/eslint-config-kibana": "^0.15.0",
121
121
  "@emotion/babel-preset-css-prop": "^11.2.0",
@@ -13,6 +13,8 @@
13
13
  text-align: center;
14
14
  white-space: nowrap;
15
15
  cursor: default;
16
+ overflow: hidden;
17
+ text-overflow: ellipsis;
16
18
 
17
19
  &:focus {
18
20
  @include euiFocusRing;
@@ -70,9 +72,11 @@
70
72
  }
71
73
 
72
74
  .euiBetaBadge--hollow {
75
+ background-color: $euiColorEmptyShade;
76
+
73
77
  &.euiBetaBadge-isClickable {
74
78
  $backgroundColor: tint($euiColorLightShade, 30%);
75
- color: chooseLightOrDarkText($backgroundColor, $euiColorGhost, $euiColorInk);
79
+ color: chooseLightOrDarkText($euiColorEmptyShade, $euiColorGhost, $euiColorInk);
76
80
  }
77
81
  }
78
82
 
@@ -1,4 +1,3 @@
1
- @import 'button';
2
1
  @import 'button_content';
3
2
  @import 'button_empty/index';
4
3
  @import 'button_icon/index';
@@ -5,10 +5,8 @@
5
5
  */
6
6
  .euiButtonEmpty {
7
7
  @include euiButton;
8
+ border-radius: $euiBorderRadius;
8
9
 
9
- border-color: transparent;
10
- background-color: transparent;
11
- box-shadow: none;
12
10
  // sass-lint:disable-block no-important
13
11
  transform: none !important; /* 1 */
14
12
  animation: none !important; /* 1 */
@@ -26,22 +24,18 @@
26
24
 
27
25
  &.euiButtonEmpty--small {
28
26
  height: $euiButtonHeightSmall;
27
+ border-radius: $euiBorderRadius * .667;
29
28
  }
30
29
 
31
30
  &.euiButtonEmpty--xSmall {
32
31
  height: $euiButtonHeightXSmall;
33
- font-size: $euiFontSizeS;
32
+ border-radius: $euiBorderRadius * .667;
33
+ font-size: $euiFontSizeXS;
34
34
  }
35
35
 
36
36
  &:disabled {
37
37
  @include euiButtonContentDisabled;
38
38
 
39
- color: $euiButtonColorDisabledText;
40
-
41
- &:focus {
42
- background-color: transparent;
43
- }
44
-
45
39
  &:hover,
46
40
  &:focus {
47
41
  text-decoration: none;
@@ -66,41 +60,3 @@
66
60
  .euiButtonEmpty--flushRight {
67
61
  margin-left: $euiSizeS;
68
62
  }
69
-
70
- // Modifier naming and colors.
71
- $euiButtonEmptyTypes: (
72
- primary: $euiColorPrimaryText,
73
- danger: $euiColorDangerText,
74
- disabled: $euiButtonColorDisabledText,
75
- ghost: $euiColorGhost,
76
- text: $euiTextColor,
77
- success: $euiColorSuccessText,
78
- warning: $euiColorWarningText,
79
- );
80
-
81
- // Create button modifiers based upon the map.
82
- @each $name, $color in $euiButtonEmptyTypes {
83
- .euiButtonEmpty--#{$name} {
84
- @if ($name == 'ghost') {
85
- // Ghost is unique and ALWAYS sits against a dark background.
86
- color: $color;
87
- } @else if ($name == 'text') {
88
- // The default color is lighter than the normal text color, make the it the text color
89
- color: $euiTextColor;
90
- } @else {
91
- // Other colors need to check their contrast against the page background color.
92
- color: makeHighContrastColor($color, $euiColorEmptyShade);
93
- }
94
-
95
- &:focus {
96
- background-color: transparentize($color, .9);
97
- }
98
-
99
- &:hover {
100
- @if ($name == 'disabled') {
101
- cursor: not-allowed;
102
- }
103
- }
104
- }
105
- }
106
-
@@ -17,7 +17,6 @@
17
17
  }
18
18
 
19
19
  .euiButtonGroup__buttons {
20
- @include euiSlightShadow;
21
20
  border-radius: $euiBorderRadius + 1px; // Simply for the box-shadow
22
21
  max-width: 100%;
23
22
  display: flex;
@@ -1,3 +1,6 @@
1
+ // This file has lots of modifiers and is somewhat nesty by nature
2
+ // sass-lint:disable nesting-depth
3
+
1
4
  .euiButtonGroupButton {
2
5
  @include euiButtonBase;
3
6
  @include euiFont;
@@ -5,7 +8,6 @@
5
8
 
6
9
  // sass-lint:disable-block indentation
7
10
  transition: background-color $euiAnimSpeedNormal ease-in-out,
8
- border-color $euiAnimSpeedNormal ease-in-out,
9
11
  color $euiAnimSpeedNormal ease-in-out;
10
12
 
11
13
  // Allow button to shrink and truncate
@@ -21,81 +23,26 @@
21
23
  padding: 0 $euiSizeS;
22
24
  }
23
25
 
24
- .euiButton__text {
25
- text-overflow: ellipsis;
26
- overflow: hidden;
27
- }
28
-
29
26
  &.euiButtonGroupButton--small {
30
27
  height: $euiButtonHeightSmall;
31
28
  line-height: $euiButtonHeightSmall; // prevents descenders from getting cut off
32
29
  }
33
30
 
34
- &:not([class*='isDisabled']) {
31
+ &:not(:disabled) {
35
32
  &:hover,
36
33
  &:focus,
37
34
  &:focus-within {
38
- background-color: transparentize($euiColorPrimary, .9);
39
35
  text-decoration: underline;
40
36
  }
41
37
  }
42
38
 
43
- &.euiButtonGroupButton-isDisabled {
39
+ &:disabled {
44
40
  @include euiButtonContentDisabled;
45
- color: $euiButtonColorDisabledText;
46
41
 
47
42
  &.euiButtonGroupButton-isSelected {
48
- color: makeHighContrastColor($euiButtonColorDisabled, $euiButtonColorDisabled, 2);
43
+ color: makeDisabledContrastColor($euiButtonColorDisabled, $euiButtonColorDisabled);
49
44
  background-color: $euiButtonColorDisabled;
50
45
  border-color: $euiButtonColorDisabled;
51
-
52
- &:hover,
53
- &:focus,
54
- &:focus-within {
55
- background-color: $euiButtonColorDisabled;
56
- border-color: $euiButtonColorDisabled;
57
- }
58
- }
59
- }
60
-
61
- @each $name, $color in $euiButtonTypes {
62
- &.euiButtonGroupButton--#{$name}:not([class*='isDisabled']) {
63
- @if ($name == 'ghost') {
64
- // Ghost is unique and ALWAYS sits against a dark background.
65
- // Compressed styles don't support ghost color, it defaults to the text color
66
- color: $color;
67
- } @else if ($name == 'text') {
68
- // The default color is lighter than the normal text color, make the it the text color
69
- color: $euiTextColor;
70
- } @else {
71
- // Other colors need to check their contrast against the page background color.
72
- color: makeHighContrastColor($color, $euiPageBackgroundColor);
73
- }
74
-
75
- &.euiButtonGroupButton-isSelected {
76
- background-color: $color;
77
- border-color: $color;
78
-
79
- // The function makes that hexes safe for theming
80
- $fillTextColor: chooseLightOrDarkText($color, $euiColorGhost, $euiColorInk);
81
-
82
- color: $fillTextColor;
83
-
84
- &:hover,
85
- &:focus,
86
- &:focus-within {
87
- $darkHighlightBg: darken($color, 5%);
88
-
89
- background-color: $darkHighlightBg;
90
- border-color: $darkHighlightBg;
91
- }
92
- }
93
-
94
- &:hover,
95
- &:focus,
96
- &:focus-within {
97
- background-color: transparentize($color, .9);
98
- }
99
46
  }
100
47
  }
101
48
  }
@@ -111,37 +58,34 @@
111
58
  .euiButtonGroup--medium,
112
59
  .euiButtonGroup--small {
113
60
  .euiButtonGroupButton {
114
- border: $euiBorderThin;
61
+ border-radius: 0 !important; // sass-lint:disable-line no-important
62
+ font-weight: $euiButtonFontWeight;
115
63
 
116
- &:not(:first-child) {
117
- margin-left: -1px;
118
- }
64
+ &:focus,
65
+ &:focus-within {
66
+ outline-style: solid;
67
+ outline-color: lightOrDarkTheme($euiColorInk, $euiColorGhost);
68
+ outline-offset: -2px;
119
69
 
120
- &:first-child {
121
- border-radius: $euiBorderRadius 0 0 $euiBorderRadius;
70
+ &:focus-visible {
71
+ outline-style: auto; // For chrome only
72
+ }
122
73
  }
123
74
 
124
- &:last-child {
125
- border-radius: 0 $euiBorderRadius $euiBorderRadius 0;
75
+ &:focus:not(:focus-visible) {
76
+ outline: none;
126
77
  }
127
- }
128
78
 
129
- // Fix ghost/disabled look specifically
130
- .euiButtonGroupButton.euiButtonGroupButton-isDisabled.euiButtonGroupButton--ghost {
131
- &,
132
- &:hover,
133
- &:focus,
134
- &:focus-within {
135
- color: $euiButtonColorGhostDisabled;
79
+ &:not(:first-child):not(.euiButtonGroupButton-isSelected):not(:disabled) {
80
+ box-shadow: -1px 0 0 0 transparentize($euiShadowColor, .95);
136
81
  }
137
82
 
138
- .euiButtonGroup--isDisabled & {
139
- border-color: $euiButtonColorGhostDisabled;
83
+ &:first-child {
84
+ border-radius: $euiBorderRadius 0 0 $euiBorderRadius;
140
85
  }
141
86
 
142
- &.euiButtonGroupButton-isSelected {
143
- background-color: $euiButtonColorGhostDisabled;
144
- color: makeHighContrastColor($euiButtonColorGhostDisabled, $euiButtonColorGhostDisabled, 2);
87
+ &:last-child {
88
+ border-radius: 0 $euiBorderRadius $euiBorderRadius 0;
145
89
  }
146
90
  }
147
91
 
@@ -149,11 +93,18 @@
149
93
  z-index: 0;
150
94
  }
151
95
 
96
+ // Faux border for separation of selected buttons
152
97
  .euiButtonGroupButton-isSelected + .euiButtonGroupButton-isSelected {
153
98
  box-shadow: -1px 0 0 transparentize($euiColorEmptyShade, .9);
154
99
  }
155
100
  }
156
101
 
102
+ .euiButtonGroup--small .euiButtonGroup__buttons {
103
+ // Use a moderately smaller radius on small buttons
104
+ // so that they don't appear completely rounded
105
+ border-radius: $euiBorderRadius * (2 / 3);
106
+ }
107
+
157
108
  /**
158
109
  * Compressed (form style)
159
110
  */
@@ -163,7 +114,8 @@
163
114
  height: $euiFormControlCompressedHeight - 2px;
164
115
  line-height: $euiFormControlCompressedHeight - 2px; // prevents descenders from getting cut off
165
116
  font-size: $euiFontSizeS;
166
- border-radius: $euiBorderRadius;
117
+ // Add 1 to the border radius to account for the background-clip
118
+ border-radius: $euiFormControlCompressedBorderRadius + 1;
167
119
  // Offset the background color from the border by 2px
168
120
  // by clipping background to before the padding starts
169
121
  padding: 2px;
@@ -178,10 +130,30 @@
178
130
  font-weight: $euiFontWeightSemiBold;
179
131
  }
180
132
 
181
- &:not([class*='isDisabled']) {
133
+ &:not(:disabled) {
182
134
  &:focus,
183
135
  &:focus-within {
184
- outline: 2px solid $euiFocusRingColor;
136
+ outline: $euiFocusRingSize solid currentColor;
137
+ }
138
+ }
139
+
140
+ @each $name, $color in $euiButtonTypes {
141
+ &[class*='-fill-#{$name}'] {
142
+ // Complicated set of focus states depending on whether it's a button and can receive :focus,
143
+ // or an input and uses focus-within, and browser support for :focus-visible,
144
+ // and override nature of default theme
145
+ &:not(:disabled):focus,
146
+ &:not(:disabled):focus-within {
147
+ outline-color: $color;
148
+
149
+ &:focus-visible {
150
+ outline-style: auto; // For chrome only
151
+ }
152
+ }
153
+
154
+ &:not(:disabled):focus:not(:focus-visible) {
155
+ outline: none;
156
+ }
185
157
  }
186
158
  }
187
159
  }