@elastic/eui 85.0.0 → 85.1.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 (137) hide show
  1. package/dist/eui_charts_theme.js +13 -16
  2. package/dist/eui_charts_theme.js.map +1 -1
  3. package/dist/eui_theme_dark.css +47 -90
  4. package/dist/eui_theme_dark.min.css +1 -1
  5. package/dist/eui_theme_light.css +47 -90
  6. package/dist/eui_theme_light.min.css +1 -1
  7. package/es/components/collapsible_nav_beta/collapsible_nav_beta.js +26 -0
  8. package/es/components/collapsible_nav_beta/collapsible_nav_beta.styles.js +16 -0
  9. package/es/components/collapsible_nav_beta/collapsible_nav_item/collapsible_nav_accordion.js +202 -0
  10. package/es/components/collapsible_nav_beta/collapsible_nav_item/collapsible_nav_accordion.styles.js +33 -0
  11. package/es/components/collapsible_nav_beta/collapsible_nav_item/collapsible_nav_item.js +296 -0
  12. package/es/components/collapsible_nav_beta/collapsible_nav_item/collapsible_nav_item.styles.js +58 -0
  13. package/es/components/collapsible_nav_beta/collapsible_nav_item/collapsible_nav_link.js +93 -0
  14. package/es/components/collapsible_nav_beta/collapsible_nav_item/collapsible_nav_link.styles.js +28 -0
  15. package/es/components/collapsible_nav_beta/collapsible_nav_item/index.js +9 -0
  16. package/es/components/collapsible_nav_beta/index.js +15 -0
  17. package/es/components/color_picker/saturation.js +2 -1
  18. package/es/components/combo_box/combo_box_input/combo_box_input.js +7 -1
  19. package/es/components/combo_box/combo_box_input/combo_box_pill.js +16 -4
  20. package/es/components/combo_box/combo_box_options_list/combo_box_option.js +4 -0
  21. package/es/components/combo_box/combo_box_options_list/combo_box_options_list.js +21 -3
  22. package/es/components/error_boundary/error_boundary.js +1 -1
  23. package/es/components/filter_group/filter_group.styles.js +2 -2
  24. package/es/components/filter_group/filter_select_item.js +31 -15
  25. package/es/components/filter_group/filter_select_item.styles.js +19 -0
  26. package/es/components/form/range/range_highlight.js +1 -0
  27. package/es/components/highlight/highlight.js +4 -4
  28. package/es/components/index.js +1 -0
  29. package/es/components/inline_edit/inline_edit_form.js +2 -1
  30. package/es/components/markdown_editor/markdown_editor.js +2 -2
  31. package/es/themes/amsterdam/global_styling/variables/_states.js +13 -16
  32. package/eui.d.ts +362 -129
  33. package/i18ntokens.json +50 -50
  34. package/lib/components/collapsible_nav_beta/collapsible_nav_beta.js +30 -0
  35. package/lib/components/collapsible_nav_beta/collapsible_nav_beta.styles.js +23 -0
  36. package/lib/components/collapsible_nav_beta/collapsible_nav_item/collapsible_nav_accordion.js +211 -0
  37. package/lib/components/collapsible_nav_beta/collapsible_nav_item/collapsible_nav_accordion.styles.js +40 -0
  38. package/lib/components/collapsible_nav_beta/collapsible_nav_item/collapsible_nav_item.js +304 -0
  39. package/lib/components/collapsible_nav_beta/collapsible_nav_item/collapsible_nav_item.styles.js +63 -0
  40. package/lib/components/collapsible_nav_beta/collapsible_nav_item/collapsible_nav_link.js +100 -0
  41. package/lib/components/collapsible_nav_beta/collapsible_nav_item/collapsible_nav_link.styles.js +35 -0
  42. package/lib/components/collapsible_nav_beta/collapsible_nav_item/index.js +12 -0
  43. package/lib/components/collapsible_nav_beta/index.js +19 -0
  44. package/lib/components/color_picker/saturation.js +2 -1
  45. package/lib/components/combo_box/combo_box_input/combo_box_input.js +7 -1
  46. package/lib/components/combo_box/combo_box_input/combo_box_pill.js +16 -4
  47. package/lib/components/combo_box/combo_box_options_list/combo_box_option.js +4 -0
  48. package/lib/components/combo_box/combo_box_options_list/combo_box_options_list.js +21 -3
  49. package/lib/components/error_boundary/error_boundary.js +1 -1
  50. package/lib/components/filter_group/filter_group.styles.js +1 -1
  51. package/lib/components/filter_group/filter_select_item.js +33 -17
  52. package/lib/components/filter_group/filter_select_item.styles.js +26 -0
  53. package/lib/components/form/range/range_highlight.js +1 -0
  54. package/lib/components/highlight/highlight.js +4 -4
  55. package/lib/components/index.js +11 -0
  56. package/lib/components/inline_edit/inline_edit_form.js +2 -1
  57. package/lib/components/markdown_editor/markdown_editor.js +2 -2
  58. package/lib/themes/amsterdam/global_styling/variables/_states.js +13 -16
  59. package/optimize/es/components/collapsible_nav_beta/collapsible_nav_beta.js +26 -0
  60. package/optimize/es/components/collapsible_nav_beta/collapsible_nav_beta.styles.js +16 -0
  61. package/optimize/es/components/collapsible_nav_beta/collapsible_nav_item/collapsible_nav_accordion.js +113 -0
  62. package/optimize/es/components/collapsible_nav_beta/collapsible_nav_item/collapsible_nav_accordion.styles.js +33 -0
  63. package/optimize/es/components/collapsible_nav_beta/collapsible_nav_item/collapsible_nav_item.js +117 -0
  64. package/optimize/es/components/collapsible_nav_beta/collapsible_nav_item/collapsible_nav_item.styles.js +55 -0
  65. package/optimize/es/components/collapsible_nav_beta/collapsible_nav_item/collapsible_nav_link.js +59 -0
  66. package/optimize/es/components/collapsible_nav_beta/collapsible_nav_item/collapsible_nav_link.styles.js +28 -0
  67. package/optimize/es/components/collapsible_nav_beta/collapsible_nav_item/index.js +9 -0
  68. package/optimize/es/components/collapsible_nav_beta/index.js +15 -0
  69. package/optimize/es/components/color_picker/saturation.js +2 -1
  70. package/optimize/es/components/combo_box/combo_box_input/combo_box_input.js +3 -1
  71. package/optimize/es/components/combo_box/combo_box_input/combo_box_pill.js +12 -4
  72. package/optimize/es/components/combo_box/combo_box_options_list/combo_box_options_list.js +9 -3
  73. package/optimize/es/components/error_boundary/error_boundary.js +1 -1
  74. package/optimize/es/components/filter_group/filter_group.styles.js +2 -2
  75. package/optimize/es/components/filter_group/filter_select_item.js +30 -14
  76. package/optimize/es/components/filter_group/filter_select_item.styles.js +19 -0
  77. package/optimize/es/components/form/range/range_highlight.js +1 -0
  78. package/optimize/es/components/highlight/highlight.js +4 -4
  79. package/optimize/es/components/index.js +1 -0
  80. package/optimize/es/components/inline_edit/inline_edit_form.js +2 -1
  81. package/optimize/es/components/markdown_editor/markdown_editor.js +2 -2
  82. package/optimize/es/themes/amsterdam/global_styling/variables/_states.js +13 -16
  83. package/optimize/lib/components/collapsible_nav_beta/collapsible_nav_beta.js +33 -0
  84. package/optimize/lib/components/collapsible_nav_beta/collapsible_nav_beta.styles.js +23 -0
  85. package/optimize/lib/components/collapsible_nav_beta/collapsible_nav_item/collapsible_nav_accordion.js +123 -0
  86. package/optimize/lib/components/collapsible_nav_beta/collapsible_nav_item/collapsible_nav_accordion.styles.js +40 -0
  87. package/optimize/lib/components/collapsible_nav_beta/collapsible_nav_item/collapsible_nav_item.js +124 -0
  88. package/optimize/lib/components/collapsible_nav_beta/collapsible_nav_item/collapsible_nav_item.styles.js +61 -0
  89. package/optimize/lib/components/collapsible_nav_beta/collapsible_nav_item/collapsible_nav_link.js +66 -0
  90. package/optimize/lib/components/collapsible_nav_beta/collapsible_nav_item/collapsible_nav_link.styles.js +35 -0
  91. package/optimize/lib/components/collapsible_nav_beta/collapsible_nav_item/index.js +12 -0
  92. package/optimize/lib/components/collapsible_nav_beta/index.js +19 -0
  93. package/optimize/lib/components/color_picker/saturation.js +2 -1
  94. package/optimize/lib/components/combo_box/combo_box_input/combo_box_input.js +3 -1
  95. package/optimize/lib/components/combo_box/combo_box_input/combo_box_pill.js +12 -4
  96. package/optimize/lib/components/combo_box/combo_box_options_list/combo_box_options_list.js +9 -3
  97. package/optimize/lib/components/error_boundary/error_boundary.js +1 -1
  98. package/optimize/lib/components/filter_group/filter_group.styles.js +1 -1
  99. package/optimize/lib/components/filter_group/filter_select_item.js +32 -16
  100. package/optimize/lib/components/filter_group/filter_select_item.styles.js +26 -0
  101. package/optimize/lib/components/form/range/range_highlight.js +1 -0
  102. package/optimize/lib/components/highlight/highlight.js +4 -4
  103. package/optimize/lib/components/index.js +11 -0
  104. package/optimize/lib/components/inline_edit/inline_edit_form.js +2 -1
  105. package/optimize/lib/components/markdown_editor/markdown_editor.js +2 -2
  106. package/optimize/lib/themes/amsterdam/global_styling/variables/_states.js +13 -16
  107. package/package.json +1 -1
  108. package/src/components/combo_box/combo_box_input/_combo_box_pill.scss +24 -3
  109. package/src/components/combo_box/combo_box_options_list/_combo_box_option.scss +34 -14
  110. package/src/components/index.scss +0 -1
  111. package/test-env/components/collapsible_nav_beta/collapsible_nav_beta.js +33 -0
  112. package/test-env/components/collapsible_nav_beta/collapsible_nav_beta.styles.js +23 -0
  113. package/test-env/components/collapsible_nav_beta/collapsible_nav_item/collapsible_nav_accordion.js +208 -0
  114. package/test-env/components/collapsible_nav_beta/collapsible_nav_item/collapsible_nav_accordion.styles.js +40 -0
  115. package/test-env/components/collapsible_nav_beta/collapsible_nav_item/collapsible_nav_item.js +303 -0
  116. package/test-env/components/collapsible_nav_beta/collapsible_nav_item/collapsible_nav_item.styles.js +61 -0
  117. package/test-env/components/collapsible_nav_beta/collapsible_nav_item/collapsible_nav_link.js +96 -0
  118. package/test-env/components/collapsible_nav_beta/collapsible_nav_item/collapsible_nav_link.styles.js +35 -0
  119. package/test-env/components/collapsible_nav_beta/collapsible_nav_item/index.js +12 -0
  120. package/test-env/components/collapsible_nav_beta/index.js +19 -0
  121. package/test-env/components/color_picker/saturation.js +2 -1
  122. package/test-env/components/combo_box/combo_box_input/combo_box_input.js +7 -1
  123. package/test-env/components/combo_box/combo_box_input/combo_box_pill.js +16 -4
  124. package/test-env/components/combo_box/combo_box_options_list/combo_box_option.js +4 -0
  125. package/test-env/components/combo_box/combo_box_options_list/combo_box_options_list.js +21 -3
  126. package/test-env/components/error_boundary/error_boundary.js +1 -1
  127. package/test-env/components/filter_group/filter_group.styles.js +1 -1
  128. package/test-env/components/filter_group/filter_select_item.js +33 -17
  129. package/test-env/components/filter_group/filter_select_item.styles.js +26 -0
  130. package/test-env/components/form/range/range_highlight.js +1 -0
  131. package/test-env/components/highlight/highlight.js +4 -4
  132. package/test-env/components/index.js +11 -0
  133. package/test-env/components/inline_edit/inline_edit_form.js +2 -1
  134. package/test-env/components/markdown_editor/markdown_editor.js +2 -2
  135. package/test-env/themes/amsterdam/global_styling/variables/_states.js +13 -16
  136. package/src/components/filter_group/_filter_select_item.scss +0 -43
  137. package/src/components/filter_group/_index.scss +0 -1
package/i18ntokens.json CHANGED
@@ -707,14 +707,14 @@
707
707
  "highlighting": "string",
708
708
  "loc": {
709
709
  "start": {
710
- "line": 60,
710
+ "line": 62,
711
711
  "column": 49,
712
- "index": 1558
712
+ "index": 1604
713
713
  },
714
714
  "end": {
715
- "line": 66,
715
+ "line": 68,
716
716
  "column": 5,
717
- "index": 1972
717
+ "index": 2018
718
718
  }
719
719
  },
720
720
  "filepath": "src/components/color_picker/saturation.tsx"
@@ -725,14 +725,14 @@
725
725
  "highlighting": "string",
726
726
  "loc": {
727
727
  "start": {
728
- "line": 60,
728
+ "line": 62,
729
729
  "column": 49,
730
- "index": 1558
730
+ "index": 1604
731
731
  },
732
732
  "end": {
733
- "line": 66,
733
+ "line": 68,
734
734
  "column": 5,
735
- "index": 1972
735
+ "index": 2018
736
736
  }
737
737
  },
738
738
  "filepath": "src/components/color_picker/saturation.tsx"
@@ -743,14 +743,14 @@
743
743
  "highlighting": "string",
744
744
  "loc": {
745
745
  "start": {
746
- "line": 69,
746
+ "line": 83,
747
747
  "column": 8,
748
- "index": 1847
748
+ "index": 2072
749
749
  },
750
750
  "end": {
751
- "line": 73,
751
+ "line": 87,
752
752
  "column": 9,
753
- "index": 2014
753
+ "index": 2239
754
754
  }
755
755
  },
756
756
  "filepath": "src/components/combo_box/combo_box_input/combo_box_pill.tsx"
@@ -761,14 +761,14 @@
761
761
  "highlighting": "string",
762
762
  "loc": {
763
763
  "start": {
764
- "line": 330,
764
+ "line": 341,
765
765
  "column": 12,
766
- "index": 9821
766
+ "index": 10114
767
767
  },
768
768
  "end": {
769
- "line": 333,
769
+ "line": 344,
770
770
  "column": 14,
771
- "index": 9944
771
+ "index": 10237
772
772
  }
773
773
  },
774
774
  "filepath": "src/components/combo_box/combo_box_options_list/combo_box_options_list.tsx"
@@ -779,14 +779,14 @@
779
779
  "highlighting": "string",
780
780
  "loc": {
781
781
  "start": {
782
- "line": 343,
782
+ "line": 354,
783
783
  "column": 16,
784
- "index": 10383
784
+ "index": 10676
785
785
  },
786
786
  "end": {
787
- "line": 347,
787
+ "line": 358,
788
788
  "column": 18,
789
- "index": 10614
789
+ "index": 10907
790
790
  }
791
791
  },
792
792
  "filepath": "src/components/combo_box/combo_box_options_list/combo_box_options_list.tsx"
@@ -797,14 +797,14 @@
797
797
  "highlighting": "string",
798
798
  "loc": {
799
799
  "start": {
800
- "line": 362,
800
+ "line": 373,
801
801
  "column": 16,
802
- "index": 11043
802
+ "index": 11336
803
803
  },
804
804
  "end": {
805
- "line": 368,
805
+ "line": 379,
806
806
  "column": 18,
807
- "index": 11316
807
+ "index": 11609
808
808
  }
809
809
  },
810
810
  "filepath": "src/components/combo_box/combo_box_options_list/combo_box_options_list.tsx"
@@ -815,14 +815,14 @@
815
815
  "highlighting": "string",
816
816
  "loc": {
817
817
  "start": {
818
- "line": 397,
818
+ "line": 408,
819
819
  "column": 20,
820
- "index": 12307
820
+ "index": 12600
821
821
  },
822
822
  "end": {
823
- "line": 403,
823
+ "line": 414,
824
824
  "column": 22,
825
- "index": 12605
825
+ "index": 12898
826
826
  }
827
827
  },
828
828
  "filepath": "src/components/combo_box/combo_box_options_list/combo_box_options_list.tsx"
@@ -833,14 +833,14 @@
833
833
  "highlighting": "string",
834
834
  "loc": {
835
835
  "start": {
836
- "line": 414,
836
+ "line": 425,
837
837
  "column": 12,
838
- "index": 12809
838
+ "index": 13102
839
839
  },
840
840
  "end": {
841
- "line": 418,
841
+ "line": 429,
842
842
  "column": 14,
843
- "index": 13030
843
+ "index": 13323
844
844
  }
845
845
  },
846
846
  "filepath": "src/components/combo_box/combo_box_options_list/combo_box_options_list.tsx"
@@ -851,14 +851,14 @@
851
851
  "highlighting": "string",
852
852
  "loc": {
853
853
  "start": {
854
- "line": 425,
854
+ "line": 436,
855
855
  "column": 10,
856
- "index": 13149
856
+ "index": 13442
857
857
  },
858
858
  "end": {
859
- "line": 428,
859
+ "line": 439,
860
860
  "column": 12,
861
- "index": 13289
861
+ "index": 13582
862
862
  }
863
863
  },
864
864
  "filepath": "src/components/combo_box/combo_box_options_list/combo_box_options_list.tsx"
@@ -869,14 +869,14 @@
869
869
  "highlighting": "string",
870
870
  "loc": {
871
871
  "start": {
872
- "line": 434,
872
+ "line": 445,
873
873
  "column": 10,
874
- "index": 13402
874
+ "index": 13695
875
875
  },
876
876
  "end": {
877
- "line": 437,
877
+ "line": 448,
878
878
  "column": 12,
879
- "index": 13545
879
+ "index": 13838
880
880
  }
881
881
  },
882
882
  "filepath": "src/components/combo_box/combo_box_options_list/combo_box_options_list.tsx"
@@ -889,12 +889,12 @@
889
889
  "start": {
890
890
  "line": 972,
891
891
  "column": 10,
892
- "index": 27919
892
+ "index": 27948
893
893
  },
894
894
  "end": {
895
895
  "line": 975,
896
896
  "column": 11,
897
- "index": 28044
897
+ "index": 28073
898
898
  }
899
899
  },
900
900
  "filepath": "src/components/combo_box/combo_box.tsx"
@@ -4559,14 +4559,14 @@
4559
4559
  "highlighting": "string",
4560
4560
  "loc": {
4561
4561
  "start": {
4562
- "line": 109,
4562
+ "line": 110,
4563
4563
  "column": 12,
4564
- "index": 3045
4564
+ "index": 3054
4565
4565
  },
4566
4566
  "end": {
4567
- "line": 109,
4567
+ "line": 110,
4568
4568
  "column": 70,
4569
- "index": 3103
4569
+ "index": 3112
4570
4570
  }
4571
4571
  },
4572
4572
  "filepath": "src/components/error_boundary/error_boundary.tsx"
@@ -5045,14 +5045,14 @@
5045
5045
  "highlighting": "string",
5046
5046
  "loc": {
5047
5047
  "start": {
5048
- "line": 348,
5048
+ "line": 349,
5049
5049
  "column": 10,
5050
- "index": 11418
5050
+ "index": 11463
5051
5051
  },
5052
5052
  "end": {
5053
- "line": 351,
5053
+ "line": 352,
5054
5054
  "column": 12,
5055
- "index": 11559
5055
+ "index": 11604
5056
5056
  }
5057
5057
  },
5058
5058
  "filepath": "src/components/inline_edit/inline_edit_form.tsx"
@@ -0,0 +1,30 @@
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
6
+ exports.EuiCollapsibleNavBeta = void 0;
7
+ var _react = _interopRequireDefault(require("react"));
8
+ var _services = require("../../services");
9
+ var _collapsible_nav = require("../collapsible_nav/collapsible_nav");
10
+ var _collapsible_nav_beta = require("./collapsible_nav_beta.styles");
11
+ var _react2 = require("@emotion/react");
12
+ function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
13
+ 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); } /*
14
+ * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one
15
+ * or more contributor license agreements. Licensed under the Elastic License
16
+ * 2.0 and the Server Side Public License, v 1; you may not use this file except
17
+ * in compliance with, at your election, the Elastic License 2.0 or the Server
18
+ * Side Public License, v 1.
19
+ */ /**
20
+ * TODO: Actual component in a follow-up PR
21
+ */
22
+ var EuiCollapsibleNavBeta = function EuiCollapsibleNavBeta(props) {
23
+ var euiTheme = (0, _services.useEuiTheme)();
24
+ var styles = (0, _collapsible_nav_beta.euiCollapsibleNavBetaStyles)(euiTheme);
25
+ return (0, _react2.jsx)(_collapsible_nav.EuiCollapsibleNav, _extends({
26
+ css: styles.euiCollapsibleNavBeta,
27
+ size: 248
28
+ }, props));
29
+ };
30
+ exports.EuiCollapsibleNavBeta = EuiCollapsibleNavBeta;
@@ -0,0 +1,23 @@
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
6
+ exports.euiCollapsibleNavBetaStyles = void 0;
7
+ var _react = require("@emotion/react");
8
+ var _global_styling = require("../../global_styling");
9
+ /*
10
+ * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one
11
+ * or more contributor license agreements. Licensed under the Elastic License
12
+ * 2.0 and the Server Side Public License, v 1; you may not use this file except
13
+ * in compliance with, at your election, the Elastic License 2.0 or the Server
14
+ * Side Public License, v 1.
15
+ */
16
+
17
+ var euiCollapsibleNavBetaStyles = function euiCollapsibleNavBetaStyles(euiThemeContext) {
18
+ var euiTheme = euiThemeContext.euiTheme;
19
+ return {
20
+ euiCollapsibleNavBeta: /*#__PURE__*/(0, _react.css)((0, _global_styling.logicalCSS)('border-top', euiTheme.border.thin), " ", (0, _global_styling.logicalCSS)('border-right', euiTheme.border.thin), " .euiFlyoutFooter{background-color:", euiTheme.colors.emptyShade, ";", (0, _global_styling.logicalCSS)('border-top', euiTheme.border.thin), ";};label:euiCollapsibleNavBeta;")
21
+ };
22
+ };
23
+ exports.euiCollapsibleNavBetaStyles = euiCollapsibleNavBetaStyles;
@@ -0,0 +1,211 @@
1
+ "use strict";
2
+
3
+ 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); }
4
+ Object.defineProperty(exports, "__esModule", {
5
+ value: true
6
+ });
7
+ exports.EuiCollapsibleNavAccordion = void 0;
8
+ var _react = _interopRequireWildcard(require("react"));
9
+ var _propTypes = _interopRequireDefault(require("prop-types"));
10
+ var _classnames = _interopRequireDefault(require("classnames"));
11
+ var _services = require("../../../services");
12
+ var _accordion = require("../../accordion");
13
+ var _collapsible_nav_item = require("./collapsible_nav_item");
14
+ var _collapsible_nav_link = require("./collapsible_nav_link");
15
+ var _collapsible_nav_accordion = require("./collapsible_nav_accordion.styles");
16
+ var _react2 = require("@emotion/react");
17
+ var _excluded = ["id", "className", "items", "href", "isSubItem", "isSelected", "linkProps", "accordionProps", "buttonContent", "children"];
18
+ /*
19
+ * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one
20
+ * or more contributor license agreements. Licensed under the Elastic License
21
+ * 2.0 and the Server Side Public License, v 1; you may not use this file except
22
+ * in compliance with, at your election, the Elastic License 2.0 or the Server
23
+ * Side Public License, v 1.
24
+ */
25
+ function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
26
+ function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
27
+ function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || _typeof(obj) !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
28
+ 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; }
29
+ 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; }
30
+ function _defineProperty(obj, key, value) { key = _toPropertyKey(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
31
+ function _toPropertyKey(arg) { var key = _toPrimitive(arg, "string"); return _typeof(key) === "symbol" ? key : String(key); }
32
+ function _toPrimitive(input, hint) { if (_typeof(input) !== "object" || input === null) return input; var prim = input[Symbol.toPrimitive]; if (prim !== undefined) { var res = prim.call(input, hint || "default"); if (_typeof(res) !== "object") return res; throw new TypeError("@@toPrimitive must return a primitive value."); } return (hint === "string" ? String : Number)(input); }
33
+ 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); }
34
+ function _objectWithoutProperties(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }
35
+ function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }
36
+ /**
37
+ * Internal nav accordion component.
38
+ *
39
+ * Renders children as either a nav link or any number/nesting of more nav accordions.
40
+ * Triggering the open/closed state is handled only by the accordion `arrow` for
41
+ * UX consistency, as accordion/nav titles can be their own links to pages.
42
+ */
43
+ var EuiCollapsibleNavAccordion = function EuiCollapsibleNavAccordion(_ref) {
44
+ var _accordionProps$arrow;
45
+ var id = _ref.id,
46
+ className = _ref.className,
47
+ items = _ref.items,
48
+ href = _ref.href,
49
+ isSubItem = _ref.isSubItem,
50
+ isSelected = _ref.isSelected,
51
+ linkProps = _ref.linkProps,
52
+ accordionProps = _ref.accordionProps,
53
+ buttonContent = _ref.buttonContent,
54
+ _children = _ref.children,
55
+ rest = _objectWithoutProperties(_ref, _excluded);
56
+ var classes = (0, _classnames.default)('euiCollapsibleNavAccordion', className);
57
+ var groupID = (0, _services.useGeneratedHtmlId)({
58
+ conditionalId: id
59
+ });
60
+ var euiTheme = (0, _services.useEuiTheme)();
61
+ var styles = (0, _collapsible_nav_accordion.euiCollapsibleNavAccordionStyles)(euiTheme);
62
+ var cssStyles = [styles.euiCollapsibleNavAccordion, isSubItem ? styles.isSubItem : styles.isTopItem, isSelected && styles.isSelected, accordionProps === null || accordionProps === void 0 ? void 0 : accordionProps.css];
63
+
64
+ /**
65
+ * Title / accordion trigger
66
+ */
67
+ var isTitleInteractive = !!(href || linkProps !== null && linkProps !== void 0 && linkProps.onClick);
68
+
69
+ // Stop propagation on the title so that the accordion toggle doesn't occur on click
70
+ // (should only occur on accordion arrow click for UX consistency)
71
+ var stopPropagationClick = (0, _react.useCallback)(function (e) {
72
+ var _linkProps$onClick;
73
+ e.stopPropagation();
74
+ linkProps === null || linkProps === void 0 ? void 0 : (_linkProps$onClick = linkProps.onClick) === null || _linkProps$onClick === void 0 ? void 0 : _linkProps$onClick.call(linkProps, e);
75
+ }, [linkProps === null || linkProps === void 0 ? void 0 : linkProps.onClick] // eslint-disable-line react-hooks/exhaustive-deps
76
+ );
77
+
78
+ /**
79
+ * Child items
80
+ */
81
+ // If any of the sub items have an icon, default to an
82
+ // icon of `empty` so that all text lines up vertically
83
+ var itemsHaveIcons = (0, _react.useMemo)(function () {
84
+ return items.some(function (item) {
85
+ return !!item.icon;
86
+ });
87
+ }, [items]);
88
+ var icon = itemsHaveIcons ? 'empty' : undefined;
89
+ var childrenCssStyles = [styles.children.euiCollapsibleNavAccordion__children, isSubItem ? styles.children.isSubItem : styles.children.isTopItem];
90
+ var children = (0, _react2.jsx)("div", {
91
+ css: childrenCssStyles,
92
+ className: "euiCollapsibleNavAccordion__children"
93
+ }, items.map(function (item, index) {
94
+ return (
95
+ // This is an intentional circular dependency between the accordion & parent item display.
96
+ // EuiSideNavItem is purposely recursive to support any amount of nested sub items,
97
+ // and split up into separate files/components for better dev readability
98
+ (0, _react2.jsx)(_collapsible_nav_item.EuiCollapsibleNavSubItem, _extends({
99
+ key: index,
100
+ icon: icon
101
+ }, item))
102
+ );
103
+ }));
104
+ return (0, _react2.jsx)(_accordion.EuiAccordion, _extends({
105
+ id: groupID,
106
+ className: classes,
107
+ initialIsOpen: isSelected,
108
+ buttonElement: "div",
109
+ buttonContent: (0, _react2.jsx)(_collapsible_nav_link.EuiCollapsibleNavLink, _extends({
110
+ href: href
111
+ }, linkProps, {
112
+ isSelected: isSelected,
113
+ isSubItem: isSubItem,
114
+ onClick: stopPropagationClick,
115
+ isInteractive: isTitleInteractive
116
+ }), buttonContent),
117
+ arrowDisplay: "right"
118
+ }, rest, accordionProps, {
119
+ css: cssStyles,
120
+ arrowProps: _objectSpread(_objectSpread({
121
+ iconSize: 's'
122
+ }, accordionProps === null || accordionProps === void 0 ? void 0 : accordionProps.arrowProps), {}, {
123
+ css: [styles.euiCollapsibleNavAccordion__arrow, accordionProps === null || accordionProps === void 0 ? void 0 : (_accordionProps$arrow = accordionProps.arrowProps) === null || _accordionProps$arrow === void 0 ? void 0 : _accordionProps$arrow.css]
124
+ })
125
+ }), children);
126
+ };
127
+ exports.EuiCollapsibleNavAccordion = EuiCollapsibleNavAccordion;
128
+ EuiCollapsibleNavAccordion.propTypes = {
129
+ /**
130
+ * Determines whether the item should render as a top-level nav item
131
+ * or a nested nav subitem. Set internally by EUI
132
+ */
133
+ isSubItem: _propTypes.default.bool,
134
+ buttonContent: _propTypes.default.node.isRequired,
135
+ // On the main `EuiCollapsibleNavItem` component, this uses `EuiCollapsibleNavSubItemProps`
136
+ // to allow for section headings, but by the time `items` reaches this component, we
137
+ // know for sure it's an actual accordion item and not a section heading
138
+ items: _propTypes.default.arrayOf(_propTypes.default.shape({
139
+ /**
140
+ * ReactNode to render as this component's title
141
+ */
142
+ title: _propTypes.default.node.isRequired,
143
+ /**
144
+ * Allows customizing title's element.
145
+ * Consider using a heading element for better accessibility.
146
+ * Defaults to an unsemantic `span` or `div`, depending on context.
147
+ */
148
+ titleElement: _propTypes.default.oneOf(["h2", "h3", "h4", "h5", "h6", "span", "div"]),
149
+ icon: _propTypes.default.oneOfType([_propTypes.default.oneOf(["accessibility", "addDataApp", "advancedSettingsApp", "agentApp", "aggregate", "analyzeEvent", "annotation", "apmApp", "apmTrace", "appSearchApp", "apps", "arrowDown", "arrowLeft", "arrowRight", "arrowUp", "arrowStart", "arrowEnd", "article", "asterisk", "at", "auditbeatApp", "beaker", "bell", "bellSlash", "beta", "bolt", "boxesHorizontal", "boxesVertical", "branch", "branchUser", "broom", "brush", "bug", "bullseye", "calendar", "canvasApp", "casesApp", "check", "checkInCircleFilled", "cheer", "classificationJob", "clock", "cloudDrizzle", "cloudStormy", "cloudSunny", "cluster", "codeApp", "color", "compute", "console", "consoleApp", "container", "continuityAbove", "continuityAboveBelow", "continuityBelow", "continuityWithin", "controlsHorizontal", "controlsVertical", "copy", "copyClipboard", "createAdvancedJob", "createMultiMetricJob", "createPopulationJob", "createSingleMetricJob", "cross", "crossClusterReplicationApp", "crosshairs", "currency", "cut", "dashboardApp", "dataVisualizer", "database", "desktop", "devToolsApp", "discoverApp", "discuss", "document", "documentEdit", "documentation", "documents", "dot", "dotInCircle", "doubleArrowLeft", "doubleArrowRight", "download", "editorAlignCenter", "editorAlignLeft", "editorAlignRight", "editorBold", "editorChecklist", "editorCodeBlock", "editorComment", "editorDistributeHorizontal", "editorDistributeVertical", "editorHeading", "editorItalic", "editorItemAlignBottom", "editorItemAlignCenter", "editorItemAlignLeft", "editorItemAlignMiddle", "editorItemAlignRight", "editorItemAlignTop", "editorLink", "editorOrderedList", "editorPositionBottomLeft", "editorPositionBottomRight", "editorPositionTopLeft", "editorPositionTopRight", "editorRedo", "editorStrike", "editorTable", "editorUnderline", "editorUndo", "editorUnorderedList", "email", "empty", "emsApp", "eql", "eraser", "error", "exit", "expand", "expandMini", "exportAction", "eye", "eyeClosed", "faceHappy", "faceNeutral", "faceSad", "filebeatApp", "filter", "filterExclude", "filterIgnore", "filterInclude", "filterInCircle", "flag", "fleetApp", "fold", "folderCheck", "folderClosed", "folderExclamation", "folderOpen", "frameNext", "framePrevious", "fullScreen", "fullScreenExit", "function", "gear", "gisApp", "glasses", "globe", "grab", "grabHorizontal", "graphApp", "grid", "grokApp", "heart", "heartbeatApp", "heatmap", "help", "home", "iInCircle", "image", "importAction", "indexClose", "indexEdit", "indexFlush", "indexManagementApp", "indexMapping", "indexOpen", "indexPatternApp", "indexRollupApp", "indexRuntime", "indexSettings", "indexTemporary", "infinity", "inputOutput", "inspect", "invert", "ip", "key", "keyboard", "kqlField", "kqlFunction", "kqlOperand", "kqlSelector", "kqlValue", "kubernetesNode", "kubernetesPod", "launch", "layers", "lensApp", "lettering", "lineDashed", "lineDotted", "lineSolid", "link", "list", "listAdd", "lock", "lockOpen", "logoAWS", "logoAWSMono", "logoAerospike", "logoApache", "logoAppSearch", "logoAzure", "logoAzureMono", "logoBeats", "logoBusinessAnalytics", "logoCeph", "logoCloud", "logoCloudEnterprise", "logoCode", "logoCodesandbox", "logoCouchbase", "logoDocker", "logoDropwizard", "logoElastic", "logoElasticStack", "logoElasticsearch", "logoEnterpriseSearch", "logoEtcd", "logoGCP", "logoGCPMono", "logoGithub", "logoGmail", "logoGolang", "logoGoogleG", "logoHAproxy", "logoIBM", "logoIBMMono", "logoKafka", "logoKibana", "logoKubernetes", "logoLogging", "logoLogstash", "logoMaps", "logoMemcached", "logoMetrics", "logoMongodb", "logoMySQL", "logoNginx", "logoObservability", "logoOsquery", "logoPhp", "logoPostgres", "logoPrometheus", "logoRabbitmq", "logoRedis", "logoSecurity", "logoSiteSearch", "logoSketch", "logoSlack", "logoUptime", "logoVulnerabilityManagement", "logoWebhook", "logoWindows", "logoWorkplaceSearch", "logsApp", "logstashFilter", "logstashIf", "logstashInput", "logstashOutput", "logstashQueue", "machineLearningApp", "magnet", "magnifyWithExclamation", "magnifyWithMinus", "magnifyWithPlus", "managementApp", "mapMarker", "memory", "menu", "menuDown", "menuLeft", "menuRight", "menuUp", "merge", "metricbeatApp", "metricsApp", "minimize", "minus", "minusInCircle", "minusInCircleFilled", "mobile", "monitoringApp", "moon", "namespace", "nested", "node", "notebookApp", "number", "offline", "online", "outlierDetectionJob", "package", "packetbeatApp", "pageSelect", "pagesSelect", "paperClip", "partial", "pause", "payment", "pencil", "percent", "pin", "pinFilled", "pipelineApp", "pivot", "play", "playFilled", "plus", "plusInCircle", "plusInCircleFilled", "popout", "push", "questionInCircle", "quote", "recentlyViewedApp", "refresh", "regressionJob", "reporter", "reportingApp", "returnKey", "save", "savedObjectsApp", "scale", "search", "searchProfilerApp", "securityAnalyticsApp", "securityApp", "securitySignal", "securitySignalDetected", "securitySignalResolved", "sessionViewer", "shard", "share", "snowflake", "sortAscending", "sortDescending", "sortDown", "sortLeft", "sortRight", "sortUp", "sortable", "spaces", "spacesApp", "sparkles", "sqlApp", "starEmpty", "starEmptySpace", "starFilled", "starFilledSpace", "starMinusEmpty", "starMinusFilled", "starPlusEmpty", "starPlusFilled", "stats", "stop", "stopFilled", "stopSlash", "storage", "string", "submodule", "sun", "swatchInput", "symlink", "tableDensityCompact", "tableDensityExpanded", "tableDensityNormal", "tableOfContents", "tag", "tear", "temperature", "timeline", "timelineWithArrow", "timelionApp", "timeRefresh", "timeslider", "training", "trash", "unfold", "unlink", "upgradeAssistantApp", "uptimeApp", "user", "userAvatar", "users", "usersRolesApp", "vector", "videoPlayer", "visArea", "visAreaStacked", "visBarHorizontal", "visBarHorizontalStacked", "visBarVertical", "visBarVerticalStacked", "visGauge", "visGoal", "visLine", "visMapCoordinate", "visMapRegion", "visMetric", "visPie", "visTable", "visTagCloud", "visText", "visTimelion", "visVega", "visVisualBuilder", "visualizeApp", "vulnerabilityManagementApp", "warning", "alert", "watchesApp", "wordWrap", "wordWrapDisabled", "workplaceSearchApp", "wrench", "tokenAlias", "tokenAnnotation", "tokenArray", "tokenBinary", "tokenBoolean", "tokenClass", "tokenCompletionSuggester", "tokenConstant", "tokenDate", "tokenDenseVector", "tokenElement", "tokenEnum", "tokenEnumMember", "tokenEvent", "tokenException", "tokenField", "tokenFile", "tokenFlattened", "tokenFunction", "tokenGeo", "tokenHistogram", "tokenInterface", "tokenIP", "tokenJoin", "tokenKey", "tokenKeyword", "tokenMethod", "tokenMetricCounter", "tokenMetricGauge", "tokenModule", "tokenNamespace", "tokenNested", "tokenNull", "tokenNumber", "tokenObject", "tokenOperator", "tokenPackage", "tokenParameter", "tokenPercolator", "tokenProperty", "tokenRange", "tokenRankFeature", "tokenRankFeatures", "tokenRepo", "tokenSearchType", "tokenShape", "tokenString", "tokenStruct", "tokenSymbol", "tokenTag", "tokenText", "tokenTokenCount", "tokenVariable"]).isRequired, _propTypes.default.string.isRequired, _propTypes.default.elementType.isRequired]),
150
+ /**
151
+ * Optional props to pass to the title icon
152
+ */
153
+ iconProps: _propTypes.default.any,
154
+ className: _propTypes.default.string,
155
+ "aria-label": _propTypes.default.string,
156
+ "data-test-subj": _propTypes.default.string,
157
+ css: _propTypes.default.any,
158
+ /**
159
+ * The nav item link.
160
+ * If not included, and no `onClick` is specified, the nav item
161
+ * will render as an non-interactive `<span>`.
162
+ */
163
+ href: _propTypes.default.string,
164
+ /**
165
+ * When passed, an `EuiAccordion` with nested child item links will be rendered.
166
+ *
167
+ * Accepts any #EuiCollapsibleNavItem prop, and also accepts an
168
+ * #EuiCollapsibleNavSubItemGroupTitle
169
+ */
170
+ items: _propTypes.default.arrayOf(_propTypes.default.shape({
171
+ /**
172
+ * ReactNode to render as this component's title
173
+ */
174
+ title: _propTypes.default.node,
175
+ /**
176
+ * Allows customizing title's element.
177
+ * Consider using a heading element for better accessibility.
178
+ * Defaults to an unsemantic `span` or `div`, depending on context.
179
+ */
180
+ titleElement: _propTypes.default.oneOf(["h2", "h3", "h4", "h5", "h6", "span", "div"]),
181
+ /**
182
+ * Optional icon to render to the left of title content
183
+ */
184
+ icon: _propTypes.default.oneOfType([_propTypes.default.oneOf(["accessibility", "addDataApp", "advancedSettingsApp", "agentApp", "aggregate", "analyzeEvent", "annotation", "apmApp", "apmTrace", "appSearchApp", "apps", "arrowDown", "arrowLeft", "arrowRight", "arrowUp", "arrowStart", "arrowEnd", "article", "asterisk", "at", "auditbeatApp", "beaker", "bell", "bellSlash", "beta", "bolt", "boxesHorizontal", "boxesVertical", "branch", "branchUser", "broom", "brush", "bug", "bullseye", "calendar", "canvasApp", "casesApp", "check", "checkInCircleFilled", "cheer", "classificationJob", "clock", "cloudDrizzle", "cloudStormy", "cloudSunny", "cluster", "codeApp", "color", "compute", "console", "consoleApp", "container", "continuityAbove", "continuityAboveBelow", "continuityBelow", "continuityWithin", "controlsHorizontal", "controlsVertical", "copy", "copyClipboard", "createAdvancedJob", "createMultiMetricJob", "createPopulationJob", "createSingleMetricJob", "cross", "crossClusterReplicationApp", "crosshairs", "currency", "cut", "dashboardApp", "dataVisualizer", "database", "desktop", "devToolsApp", "discoverApp", "discuss", "document", "documentEdit", "documentation", "documents", "dot", "dotInCircle", "doubleArrowLeft", "doubleArrowRight", "download", "editorAlignCenter", "editorAlignLeft", "editorAlignRight", "editorBold", "editorChecklist", "editorCodeBlock", "editorComment", "editorDistributeHorizontal", "editorDistributeVertical", "editorHeading", "editorItalic", "editorItemAlignBottom", "editorItemAlignCenter", "editorItemAlignLeft", "editorItemAlignMiddle", "editorItemAlignRight", "editorItemAlignTop", "editorLink", "editorOrderedList", "editorPositionBottomLeft", "editorPositionBottomRight", "editorPositionTopLeft", "editorPositionTopRight", "editorRedo", "editorStrike", "editorTable", "editorUnderline", "editorUndo", "editorUnorderedList", "email", "empty", "emsApp", "eql", "eraser", "error", "exit", "expand", "expandMini", "exportAction", "eye", "eyeClosed", "faceHappy", "faceNeutral", "faceSad", "filebeatApp", "filter", "filterExclude", "filterIgnore", "filterInclude", "filterInCircle", "flag", "fleetApp", "fold", "folderCheck", "folderClosed", "folderExclamation", "folderOpen", "frameNext", "framePrevious", "fullScreen", "fullScreenExit", "function", "gear", "gisApp", "glasses", "globe", "grab", "grabHorizontal", "graphApp", "grid", "grokApp", "heart", "heartbeatApp", "heatmap", "help", "home", "iInCircle", "image", "importAction", "indexClose", "indexEdit", "indexFlush", "indexManagementApp", "indexMapping", "indexOpen", "indexPatternApp", "indexRollupApp", "indexRuntime", "indexSettings", "indexTemporary", "infinity", "inputOutput", "inspect", "invert", "ip", "key", "keyboard", "kqlField", "kqlFunction", "kqlOperand", "kqlSelector", "kqlValue", "kubernetesNode", "kubernetesPod", "launch", "layers", "lensApp", "lettering", "lineDashed", "lineDotted", "lineSolid", "link", "list", "listAdd", "lock", "lockOpen", "logoAWS", "logoAWSMono", "logoAerospike", "logoApache", "logoAppSearch", "logoAzure", "logoAzureMono", "logoBeats", "logoBusinessAnalytics", "logoCeph", "logoCloud", "logoCloudEnterprise", "logoCode", "logoCodesandbox", "logoCouchbase", "logoDocker", "logoDropwizard", "logoElastic", "logoElasticStack", "logoElasticsearch", "logoEnterpriseSearch", "logoEtcd", "logoGCP", "logoGCPMono", "logoGithub", "logoGmail", "logoGolang", "logoGoogleG", "logoHAproxy", "logoIBM", "logoIBMMono", "logoKafka", "logoKibana", "logoKubernetes", "logoLogging", "logoLogstash", "logoMaps", "logoMemcached", "logoMetrics", "logoMongodb", "logoMySQL", "logoNginx", "logoObservability", "logoOsquery", "logoPhp", "logoPostgres", "logoPrometheus", "logoRabbitmq", "logoRedis", "logoSecurity", "logoSiteSearch", "logoSketch", "logoSlack", "logoUptime", "logoVulnerabilityManagement", "logoWebhook", "logoWindows", "logoWorkplaceSearch", "logsApp", "logstashFilter", "logstashIf", "logstashInput", "logstashOutput", "logstashQueue", "machineLearningApp", "magnet", "magnifyWithExclamation", "magnifyWithMinus", "magnifyWithPlus", "managementApp", "mapMarker", "memory", "menu", "menuDown", "menuLeft", "menuRight", "menuUp", "merge", "metricbeatApp", "metricsApp", "minimize", "minus", "minusInCircle", "minusInCircleFilled", "mobile", "monitoringApp", "moon", "namespace", "nested", "node", "notebookApp", "number", "offline", "online", "outlierDetectionJob", "package", "packetbeatApp", "pageSelect", "pagesSelect", "paperClip", "partial", "pause", "payment", "pencil", "percent", "pin", "pinFilled", "pipelineApp", "pivot", "play", "playFilled", "plus", "plusInCircle", "plusInCircleFilled", "popout", "push", "questionInCircle", "quote", "recentlyViewedApp", "refresh", "regressionJob", "reporter", "reportingApp", "returnKey", "save", "savedObjectsApp", "scale", "search", "searchProfilerApp", "securityAnalyticsApp", "securityApp", "securitySignal", "securitySignalDetected", "securitySignalResolved", "sessionViewer", "shard", "share", "snowflake", "sortAscending", "sortDescending", "sortDown", "sortLeft", "sortRight", "sortUp", "sortable", "spaces", "spacesApp", "sparkles", "sqlApp", "starEmpty", "starEmptySpace", "starFilled", "starFilledSpace", "starMinusEmpty", "starMinusFilled", "starPlusEmpty", "starPlusFilled", "stats", "stop", "stopFilled", "stopSlash", "storage", "string", "submodule", "sun", "swatchInput", "symlink", "tableDensityCompact", "tableDensityExpanded", "tableDensityNormal", "tableOfContents", "tag", "tear", "temperature", "timeline", "timelineWithArrow", "timelionApp", "timeRefresh", "timeslider", "training", "trash", "unfold", "unlink", "upgradeAssistantApp", "uptimeApp", "user", "userAvatar", "users", "usersRolesApp", "vector", "videoPlayer", "visArea", "visAreaStacked", "visBarHorizontal", "visBarHorizontalStacked", "visBarVertical", "visBarVerticalStacked", "visGauge", "visGoal", "visLine", "visMapCoordinate", "visMapRegion", "visMetric", "visPie", "visTable", "visTagCloud", "visText", "visTimelion", "visVega", "visVisualBuilder", "visualizeApp", "vulnerabilityManagementApp", "warning", "alert", "watchesApp", "wordWrap", "wordWrapDisabled", "workplaceSearchApp", "wrench", "tokenAlias", "tokenAnnotation", "tokenArray", "tokenBinary", "tokenBoolean", "tokenClass", "tokenCompletionSuggester", "tokenConstant", "tokenDate", "tokenDenseVector", "tokenElement", "tokenEnum", "tokenEnumMember", "tokenEvent", "tokenException", "tokenField", "tokenFile", "tokenFlattened", "tokenFunction", "tokenGeo", "tokenHistogram", "tokenInterface", "tokenIP", "tokenJoin", "tokenKey", "tokenKeyword", "tokenMethod", "tokenMetricCounter", "tokenMetricGauge", "tokenModule", "tokenNamespace", "tokenNested", "tokenNull", "tokenNumber", "tokenObject", "tokenOperator", "tokenPackage", "tokenParameter", "tokenPercolator", "tokenProperty", "tokenRange", "tokenRankFeature", "tokenRankFeatures", "tokenRepo", "tokenSearchType", "tokenShape", "tokenString", "tokenStruct", "tokenSymbol", "tokenTag", "tokenText", "tokenTokenCount", "tokenVariable"]).isRequired, _propTypes.default.string.isRequired, _propTypes.default.elementType.isRequired]),
185
+ /**
186
+ * Optional props to pass to the title icon
187
+ */
188
+ iconProps: _propTypes.default.any,
189
+ /**
190
+ * Pass this flag to seperate links by group title headings.
191
+ * Strongly consider using the `titleElement` prop for accessibility.
192
+ */
193
+ isGroupTitle: _propTypes.default.bool
194
+ }).isRequired),
195
+ /**
196
+ * If `items` is specified, use this prop to pass any prop that `EuiAccordion`
197
+ * accepts, including props that control the toggled state of the accordion
198
+ * (e.g. `initialIsOpen`, `forceState`)
199
+ */
200
+ accordionProps: _propTypes.default.any,
201
+ /**
202
+ * If a `href` is specified, use this prop to pass any prop that `EuiLink` accepts
203
+ */
204
+ linkProps: _propTypes.default.any,
205
+ /**
206
+ * Highlights whether an item is currently selected, e.g.
207
+ * if the user is on the same page as the nav link
208
+ */
209
+ isSelected: _propTypes.default.bool
210
+ }).isRequired).isRequired
211
+ };
@@ -0,0 +1,40 @@
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
6
+ exports.euiCollapsibleNavAccordionStyles = void 0;
7
+ var _react = require("@emotion/react");
8
+ var _global_styling = require("../../../global_styling");
9
+ var _collapsible_nav_item = require("./collapsible_nav_item.styles");
10
+ /*
11
+ * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one
12
+ * or more contributor license agreements. Licensed under the Elastic License
13
+ * 2.0 and the Server Side Public License, v 1; you may not use this file except
14
+ * in compliance with, at your election, the Elastic License 2.0 or the Server
15
+ * Side Public License, v 1.
16
+ */
17
+
18
+ var euiCollapsibleNavAccordionStyles = function euiCollapsibleNavAccordionStyles(euiThemeContext) {
19
+ var euiTheme = euiThemeContext.euiTheme;
20
+ var sharedStyles = (0, _collapsible_nav_item.euiCollapsibleNavItemVariables)(euiThemeContext);
21
+ return {
22
+ // NOTE: Specific usage of `>`s selectors are important here, because accordions can be nested
23
+ // - just because a parent accordion is open or selected does not mean its child accordion is the same
24
+ euiCollapsibleNavAccordion: /*#__PURE__*/(0, _react.css)(".euiAccordion__button{overflow:hidden;&:hover,&:focus{cursor:default;text-decoration:none;}}.euiAccordion__triggerWrapper{border-radius:", sharedStyles.borderRadius, ";", _global_styling.euiCanAnimate, "{transition:background-color ", sharedStyles.animation, ";}}.euiAccordion__buttonContent{", (0, _global_styling.logicalCSS)('max-width', '100%'), " flex-basis:100%;display:flex;align-items:center;}.euiCollapsibleNavLink{", (0, _global_styling.logicalCSS)('width', '100%'), ";};label:euiCollapsibleNavAccordion;"),
25
+ isTopItem: /*#__PURE__*/(0, _react.css)("margin:", sharedStyles.padding, ";&>.euiAccordion__triggerWrapper{&:hover{background-color:", sharedStyles.backgroundHoverColor, ";}};label:isTopItem;"),
26
+ isSelected: /*#__PURE__*/(0, _react.css)("&>.euiAccordion__triggerWrapper{background-color:", sharedStyles.backgroundSelectedColor, ";&:hover{background-color:", sharedStyles.backgroundSelectedColor, ";}};label:isSelected;"),
27
+ isSubItem: /*#__PURE__*/(0, _react.css)("&.euiAccordion-isOpen{", (0, _global_styling.logicalCSS)('margin-bottom', euiTheme.size.m), ";};label:isSubItem;"),
28
+ // Arrow element
29
+ euiCollapsibleNavAccordion__arrow: /*#__PURE__*/(0, _react.css)((0, _global_styling.logicalCSS)('margin-right', euiTheme.size.xs), _global_styling.euiCanAnimate, "{transition:background-color ", sharedStyles.animation, ";}&:hover,&:focus-visible{background-color:", euiTheme.colors.lightShade, ";&>.euiIcon{color:", sharedStyles.color, ";}}transform:none!important;&>.euiIcon{color:", sharedStyles.rightIconColor, ";transform:rotate(-90deg);", _global_styling.euiCanAnimate, "{transition:transform ", sharedStyles.animation, ",color ", sharedStyles.animation, ";}}&.euiAccordion__iconButton-isOpen>.euiIcon{color:", sharedStyles.color, ";transform:rotate(90deg);};label:euiCollapsibleNavAccordion__arrow;"),
30
+ // Children wrapper
31
+ children: {
32
+ euiCollapsibleNavAccordion__children: /*#__PURE__*/(0, _react.css)(";label:euiCollapsibleNavAccordion__children;"),
33
+ isTopItem: /*#__PURE__*/(0, _react.css)((0, _global_styling.logicalCSS)('padding-top', euiTheme.size.xs), " ", (0, _global_styling.logicalCSS)('padding-left', euiTheme.size.xl), ";;label:isTopItem;"),
34
+ isSubItem: /*#__PURE__*/(0, _react.css)((0, _global_styling.logicalCSS)('border-left', euiTheme.border.thin), " ", (0, _global_styling.logicalCSS)('margin-left', euiTheme.size.s), " ", (0, _global_styling.logicalCSS)('padding-left', (0, _global_styling.mathWithUnits)([euiTheme.size.s, euiTheme.border.width.thin], function (x, y) {
35
+ return x - y;
36
+ })), ";;label:isSubItem;")
37
+ }
38
+ };
39
+ };
40
+ exports.euiCollapsibleNavAccordionStyles = euiCollapsibleNavAccordionStyles;