@plesk/ui-library 3.36.1 → 3.37.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 (279) hide show
  1. package/README.md +50 -50
  2. package/cjs/components/Action/Action.js +3 -3
  3. package/cjs/components/Alert/Alert.js +5 -5
  4. package/cjs/components/AutoClosable/AutoClosable.js +3 -3
  5. package/cjs/components/AuxiliaryActions/AuxiliaryActions.js +3 -3
  6. package/cjs/components/Badge/Badge.js +3 -3
  7. package/cjs/components/Breadcrumbs/Breadcrumbs.js +4 -4
  8. package/cjs/components/Button/Button.js +4 -4
  9. package/cjs/components/ButtonGroup/ButtonGroup.js +3 -3
  10. package/cjs/components/Card/Card.js +52 -52
  11. package/cjs/components/Card/CardButton.js +2 -2
  12. package/cjs/components/Card/PreviewPanel.js +3 -3
  13. package/cjs/components/Card/images/no-image.svg +6 -6
  14. package/cjs/components/CardList/CardList.js +55 -55
  15. package/cjs/components/Carousel/Carousel.js +186 -81
  16. package/cjs/components/Checkbox/Checkbox.js +3 -3
  17. package/cjs/components/CodeEditor/CodeEditor.js +3 -3
  18. package/cjs/components/Columns/Column.js +3 -3
  19. package/cjs/components/Columns/Columns.js +3 -3
  20. package/cjs/components/ComboBox/ComboBox.js +4 -4
  21. package/cjs/components/ComboBox/ComboBoxOption.js +5 -4
  22. package/cjs/components/ConsoleOutput/ConsoleOutput.js +3 -3
  23. package/cjs/components/ContentLoader/ContentLoader.js +3 -3
  24. package/cjs/components/Cuttable/Cuttable.js +3 -3
  25. package/cjs/components/Dialog/Dialog.js +3 -3
  26. package/cjs/components/Drawer/Drawer.js +4 -4
  27. package/cjs/components/Dropdown/Dropdown.js +5 -5
  28. package/cjs/components/ExtendedStatusMessage/ExtendedStatusMessage.js +4 -4
  29. package/cjs/components/ExtendedStatusMessage/ExtendedStatusMessageActions.js +3 -3
  30. package/cjs/components/ExtendedStatusMessage/ExtendedStatusMessageDescription.js +3 -3
  31. package/cjs/components/ExtendedStatusMessage/ExtendedStatusMessageSeparator.js +3 -3
  32. package/cjs/components/ExtendedStatusMessage/ExtendedStatusMessageTitle.js +3 -3
  33. package/cjs/components/Figure/Figure.js +3 -3
  34. package/cjs/components/Form/Form.js +4 -4
  35. package/cjs/components/Form/utils.js +22 -22
  36. package/cjs/components/FormField/FormField.js +24 -24
  37. package/cjs/components/FormFieldCheckbox/FormFieldCheckbox.js +4 -4
  38. package/cjs/components/FormFieldPassword/FormFieldPassword.js +3 -3
  39. package/cjs/components/FormFieldRadioButtons/FormFieldRadioButtons.js +3 -3
  40. package/cjs/components/FormFieldSelect/FormFieldSelect.js +4 -4
  41. package/cjs/components/FormFieldText/FormFieldText.js +5 -5
  42. package/cjs/components/Grid/Grid.js +3 -3
  43. package/cjs/components/GridCol/GridCol.js +3 -3
  44. package/cjs/components/Heading/Heading.js +3 -3
  45. package/cjs/components/Hint/Hint.js +3 -3
  46. package/cjs/components/Icon/Icon.js +6 -6
  47. package/cjs/components/Icon/images/symbols.svg +1846 -1846
  48. package/cjs/components/InPlaceEdit/InPlaceEdit.js +5 -5
  49. package/cjs/components/Input/Input.js +3 -3
  50. package/cjs/components/InputFile/InputFile.js +3 -3
  51. package/cjs/components/InputNumber/InputNumber.js +3 -3
  52. package/cjs/components/Item/Item.js +4 -4
  53. package/cjs/components/ItemLink/ItemLink.js +4 -4
  54. package/cjs/components/ItemList/ItemList.js +6 -6
  55. package/cjs/components/Label/Label.js +3 -3
  56. package/cjs/components/Layer/Layer.js +2 -2
  57. package/cjs/components/Layout/Layout.js +2 -2
  58. package/cjs/components/Link/Link.js +3 -3
  59. package/cjs/components/List/List.js +4 -7
  60. package/cjs/components/List/ListAction.js +4 -4
  61. package/cjs/components/List/ListActions.js +3 -3
  62. package/cjs/components/List/ListActionsDivider.js +4 -4
  63. package/cjs/components/List/ListEmptyView.js +4 -4
  64. package/cjs/components/List/ListOperation.js +4 -4
  65. package/cjs/components/LocaleProvider/LocaleProvider.js +3 -3
  66. package/cjs/components/Markdown/Markdown.js +3 -3
  67. package/cjs/components/Media/Media.js +5 -5
  68. package/cjs/components/Media/MediaSection.js +3 -3
  69. package/cjs/components/Menu/Menu.js +9 -9
  70. package/cjs/components/Menu/MenuBaseItem.js +3 -3
  71. package/cjs/components/Menu/MenuDivider.js +3 -3
  72. package/cjs/components/Menu/MenuHeader.js +3 -3
  73. package/cjs/components/Menu/MenuItem.js +3 -3
  74. package/cjs/components/Menu/MenuSelectableItem.js +3 -3
  75. package/cjs/components/Overlay/Overlay.js +2 -2
  76. package/cjs/components/PageHeader/PageHeader.js +3 -3
  77. package/cjs/components/Pagination/Pagination.js +3 -3
  78. package/cjs/components/Panel/Panel.js +64 -101
  79. package/cjs/components/Paragraph/Paragraph.js +3 -3
  80. package/cjs/components/Plaintext/Plaintext.js +3 -3
  81. package/cjs/components/Popover/Popover.js +4 -4
  82. package/cjs/components/Popper/Popper.js +2 -2
  83. package/cjs/components/Progress/Progress.js +3 -3
  84. package/cjs/components/ProgressDialog/ProgressDialog.js +3 -3
  85. package/cjs/components/ProgressDialogStep/ProgressDialogStep.js +3 -3
  86. package/cjs/components/ProgressStep/ProgressStep.js +3 -3
  87. package/cjs/components/Radio/Radio.js +3 -3
  88. package/cjs/components/Rating/Rating.js +3 -3
  89. package/cjs/components/Rating/images/rating.svg +6 -6
  90. package/cjs/components/Section/Section.js +4 -4
  91. package/cjs/components/Section/SectionItem.js +3 -3
  92. package/cjs/components/SegmentedControl/SegmentedControl.js +4 -4
  93. package/cjs/components/Select/MultiValue.js +1 -1
  94. package/cjs/components/Select/Select.js +3 -3
  95. package/cjs/components/Select/SelectControl.js +1 -1
  96. package/cjs/components/Select/SelectOption.js +5 -4
  97. package/cjs/components/Select/SelectOptionGroup.js +3 -3
  98. package/cjs/components/Skeleton/Skeleton.js +4 -4
  99. package/cjs/components/Skeleton/SkeletonTabs.js +3 -3
  100. package/cjs/components/Skeleton/SkeletonText.js +3 -3
  101. package/cjs/components/Spinner/Spinner.js +2 -2
  102. package/cjs/components/SplitButton/SplitButton.js +5 -5
  103. package/cjs/components/Spot/Spot.js +3 -3
  104. package/cjs/components/Status/Status.js +3 -3
  105. package/cjs/components/StatusMessage/StatusMessage.js +4 -4
  106. package/cjs/components/Subnav/Subnav.js +5 -5
  107. package/cjs/components/Switch/Switch.js +4 -4
  108. package/cjs/components/SwitchesPanel/SwitchesPanel.js +3 -3
  109. package/cjs/components/SwitchesPanelItem/SwitchesPanelItem.js +4 -4
  110. package/cjs/components/Tabs/SearchBar.js +3 -3
  111. package/cjs/components/Tabs/Tab.js +7 -7
  112. package/cjs/components/Tabs/Tabs.js +6 -6
  113. package/cjs/components/Text/Text.js +3 -3
  114. package/cjs/components/TextArea/TextArea.js +3 -3
  115. package/cjs/components/Toaster/Toaster.js +37 -37
  116. package/cjs/components/Toolbar/Toolbar.js +6 -6
  117. package/cjs/components/Toolbar/ToolbarExpander.js +5 -5
  118. package/cjs/components/Toolbar/ToolbarGroup.js +4 -4
  119. package/cjs/components/Toolbar/ToolbarMenu.js +0 -1
  120. package/cjs/components/Tooltip/Tooltip.js +4 -4
  121. package/cjs/components/Tour/Tour.js +5 -5
  122. package/cjs/components/Translate/Translate.js +3 -3
  123. package/cjs/index.js +1 -1
  124. package/dist/images/no-image.svg +6 -6
  125. package/dist/images/rating.svg +6 -6
  126. package/dist/images/symbols.svg +1846 -1846
  127. package/dist/plesk-ui-library-rtl.css +1 -1
  128. package/dist/plesk-ui-library-rtl.css.map +1 -1
  129. package/dist/plesk-ui-library.css +1 -1
  130. package/dist/plesk-ui-library.css.map +1 -1
  131. package/dist/plesk-ui-library.js +11997 -11914
  132. package/dist/plesk-ui-library.js.map +1 -1
  133. package/dist/plesk-ui-library.min.js +18 -18
  134. package/dist/plesk-ui-library.min.js.map +1 -1
  135. package/esm/components/Action/Action.js +3 -3
  136. package/esm/components/Alert/Alert.js +5 -5
  137. package/esm/components/AutoClosable/AutoClosable.js +3 -3
  138. package/esm/components/AuxiliaryActions/AuxiliaryActions.js +3 -3
  139. package/esm/components/Badge/Badge.js +3 -3
  140. package/esm/components/Breadcrumbs/Breadcrumbs.js +4 -4
  141. package/esm/components/Button/Button.js +4 -4
  142. package/esm/components/ButtonGroup/ButtonGroup.js +3 -3
  143. package/esm/components/Card/Card.js +52 -52
  144. package/esm/components/Card/CardButton.js +2 -2
  145. package/esm/components/Card/PreviewPanel.js +3 -3
  146. package/esm/components/Card/images/no-image.svg +6 -6
  147. package/esm/components/CardList/CardList.js +55 -55
  148. package/esm/components/Carousel/Carousel.js +187 -82
  149. package/esm/components/Checkbox/Checkbox.js +3 -3
  150. package/esm/components/CodeEditor/CodeEditor.js +3 -3
  151. package/esm/components/Columns/Column.js +3 -3
  152. package/esm/components/Columns/Columns.js +3 -3
  153. package/esm/components/ComboBox/ComboBox.js +4 -4
  154. package/esm/components/ComboBox/ComboBoxOption.js +5 -4
  155. package/esm/components/ConsoleOutput/ConsoleOutput.js +3 -3
  156. package/esm/components/ContentLoader/ContentLoader.js +3 -3
  157. package/esm/components/Cuttable/Cuttable.js +3 -3
  158. package/esm/components/Dialog/Dialog.js +3 -3
  159. package/esm/components/Drawer/Drawer.js +4 -4
  160. package/esm/components/Dropdown/Dropdown.js +5 -5
  161. package/esm/components/ExtendedStatusMessage/ExtendedStatusMessage.js +4 -4
  162. package/esm/components/ExtendedStatusMessage/ExtendedStatusMessageActions.js +3 -3
  163. package/esm/components/ExtendedStatusMessage/ExtendedStatusMessageDescription.js +3 -3
  164. package/esm/components/ExtendedStatusMessage/ExtendedStatusMessageSeparator.js +3 -3
  165. package/esm/components/ExtendedStatusMessage/ExtendedStatusMessageTitle.js +3 -3
  166. package/esm/components/Figure/Figure.js +3 -3
  167. package/esm/components/Form/Form.js +4 -4
  168. package/esm/components/Form/utils.js +22 -22
  169. package/esm/components/FormField/FormField.js +24 -24
  170. package/esm/components/FormFieldCheckbox/FormFieldCheckbox.js +4 -4
  171. package/esm/components/FormFieldPassword/FormFieldPassword.js +3 -3
  172. package/esm/components/FormFieldRadioButtons/FormFieldRadioButtons.js +3 -3
  173. package/esm/components/FormFieldSelect/FormFieldSelect.js +4 -4
  174. package/esm/components/FormFieldText/FormFieldText.js +5 -5
  175. package/esm/components/Grid/Grid.js +3 -3
  176. package/esm/components/GridCol/GridCol.js +3 -3
  177. package/esm/components/Heading/Heading.js +3 -3
  178. package/esm/components/Hint/Hint.js +3 -3
  179. package/esm/components/Icon/Icon.js +6 -6
  180. package/esm/components/Icon/images/symbols.svg +1846 -1846
  181. package/esm/components/InPlaceEdit/InPlaceEdit.js +5 -5
  182. package/esm/components/Input/Input.js +3 -3
  183. package/esm/components/InputFile/InputFile.js +3 -3
  184. package/esm/components/InputNumber/InputNumber.js +3 -3
  185. package/esm/components/Item/Item.js +4 -4
  186. package/esm/components/ItemLink/ItemLink.js +4 -4
  187. package/esm/components/ItemList/ItemList.js +6 -6
  188. package/esm/components/Label/Label.js +3 -3
  189. package/esm/components/Layer/Layer.js +2 -2
  190. package/esm/components/Layout/Layout.js +2 -2
  191. package/esm/components/Link/Link.js +3 -3
  192. package/esm/components/List/List.js +4 -7
  193. package/esm/components/List/ListAction.js +4 -4
  194. package/esm/components/List/ListActions.js +3 -3
  195. package/esm/components/List/ListActionsDivider.js +4 -4
  196. package/esm/components/List/ListEmptyView.js +4 -4
  197. package/esm/components/List/ListOperation.js +4 -4
  198. package/esm/components/LocaleProvider/LocaleProvider.js +3 -3
  199. package/esm/components/Markdown/Markdown.js +3 -3
  200. package/esm/components/Media/Media.js +5 -5
  201. package/esm/components/Media/MediaSection.js +3 -3
  202. package/esm/components/Menu/Menu.js +9 -9
  203. package/esm/components/Menu/MenuBaseItem.js +3 -3
  204. package/esm/components/Menu/MenuDivider.js +3 -3
  205. package/esm/components/Menu/MenuHeader.js +3 -3
  206. package/esm/components/Menu/MenuItem.js +3 -3
  207. package/esm/components/Menu/MenuSelectableItem.js +3 -3
  208. package/esm/components/Overlay/Overlay.js +2 -2
  209. package/esm/components/PageHeader/PageHeader.js +3 -3
  210. package/esm/components/Pagination/Pagination.js +3 -3
  211. package/esm/components/Panel/Panel.js +65 -102
  212. package/esm/components/Paragraph/Paragraph.js +3 -3
  213. package/esm/components/Plaintext/Plaintext.js +3 -3
  214. package/esm/components/Popover/Popover.js +4 -4
  215. package/esm/components/Popper/Popper.js +2 -2
  216. package/esm/components/Progress/Progress.js +3 -3
  217. package/esm/components/ProgressDialog/ProgressDialog.js +3 -3
  218. package/esm/components/ProgressDialogStep/ProgressDialogStep.js +3 -3
  219. package/esm/components/ProgressStep/ProgressStep.js +3 -3
  220. package/esm/components/Radio/Radio.js +3 -3
  221. package/esm/components/Rating/Rating.js +3 -3
  222. package/esm/components/Rating/images/rating.svg +6 -6
  223. package/esm/components/Section/Section.js +4 -4
  224. package/esm/components/Section/SectionItem.js +3 -3
  225. package/esm/components/SegmentedControl/SegmentedControl.js +4 -4
  226. package/esm/components/Select/MultiValue.js +1 -1
  227. package/esm/components/Select/Select.js +3 -3
  228. package/esm/components/Select/SelectControl.js +1 -1
  229. package/esm/components/Select/SelectOption.js +5 -4
  230. package/esm/components/Select/SelectOptionGroup.js +3 -3
  231. package/esm/components/Skeleton/Skeleton.js +4 -4
  232. package/esm/components/Skeleton/SkeletonTabs.js +3 -3
  233. package/esm/components/Skeleton/SkeletonText.js +3 -3
  234. package/esm/components/Spinner/Spinner.js +2 -2
  235. package/esm/components/SplitButton/SplitButton.js +5 -5
  236. package/esm/components/Spot/Spot.js +3 -3
  237. package/esm/components/Status/Status.js +3 -3
  238. package/esm/components/StatusMessage/StatusMessage.js +4 -4
  239. package/esm/components/Subnav/Subnav.js +5 -5
  240. package/esm/components/Switch/Switch.js +4 -4
  241. package/esm/components/SwitchesPanel/SwitchesPanel.js +3 -3
  242. package/esm/components/SwitchesPanelItem/SwitchesPanelItem.js +4 -4
  243. package/esm/components/Tabs/SearchBar.js +3 -3
  244. package/esm/components/Tabs/Tab.js +7 -7
  245. package/esm/components/Tabs/Tabs.js +6 -6
  246. package/esm/components/Text/Text.js +3 -3
  247. package/esm/components/TextArea/TextArea.js +3 -3
  248. package/esm/components/Toaster/Toaster.js +37 -37
  249. package/esm/components/Toolbar/Toolbar.js +6 -6
  250. package/esm/components/Toolbar/ToolbarExpander.js +5 -5
  251. package/esm/components/Toolbar/ToolbarGroup.js +4 -4
  252. package/esm/components/Toolbar/ToolbarMenu.js +0 -1
  253. package/esm/components/Tooltip/Tooltip.js +4 -4
  254. package/esm/components/Tour/Tour.js +5 -5
  255. package/esm/components/Translate/Translate.js +3 -3
  256. package/esm/index.js +1 -1
  257. package/index.js +5 -5
  258. package/package.json +150 -150
  259. package/scripts/postinstall.js +9 -9
  260. package/styleguide/browserconfig.xml +9 -9
  261. package/styleguide/build/bundle.c3d05006.js +2 -0
  262. package/styleguide/images/no-image.svg +6 -6
  263. package/styleguide/images/rating.svg +6 -6
  264. package/styleguide/images/symbols.svg +1846 -1846
  265. package/styleguide/index.html +2 -2
  266. package/styleguide/placeholders/placeholder_400x200.svg +5 -5
  267. package/styleguide/placeholders/placeholder_400x400.svg +5 -5
  268. package/styleguide/placeholders/placeholder_600x400.svg +5 -5
  269. package/styleguide/safari-pinned-tab.svg +28 -28
  270. package/styleguide/site.webmanifest +19 -19
  271. package/types/src/components/Carousel/Carousel.d.ts +43 -8
  272. package/types/src/components/List/List.d.ts +0 -1
  273. package/types/src/components/Panel/Panel.d.ts +4 -21
  274. package/types/src/components/Panel/index.d.ts +1 -0
  275. package/types/src/components/Radio/Radio.d.ts +4 -6
  276. package/types/src/components/Section/Section.d.ts +1 -1
  277. package/types/src/components/index.d.ts +1 -0
  278. package/styleguide/build/bundle.ed34a3c0.js +0 -2
  279. /package/styleguide/build/{bundle.ed34a3c0.js.LICENSE.txt → bundle.c3d05006.js.LICENSE.txt} +0 -0
@@ -1,117 +1,80 @@
1
- import _defineProperty from "@babel/runtime/helpers/defineProperty";
2
1
  // Copyright 1999-2023. Plesk International GmbH. All rights reserved.
3
2
 
4
- import { Component, createRef } from 'react';
3
+ import { useRef, useState } from 'react';
4
+ import { CSSTransition } from 'react-transition-group';
5
5
  import classNames from 'classnames';
6
6
  import { CLS_PREFIX } from '../../constants';
7
- import { CSSTransition } from 'react-transition-group';
8
7
  import { isLikeText } from '../Translate';
9
8
  import Heading from '../Heading';
10
9
  import Button from '../Button';
11
10
  import { isClickable } from '../utils';
12
11
  import { jsx as _jsx } from "react/jsx-runtime";
13
12
  import { jsxs as _jsxs } from "react/jsx-runtime";
14
- /**
15
- * `Panel` component is used for visually grouping some content.
16
- * @since 0.0.35
13
+ /**
14
+ * `Panel` component is used for visually grouping some content.
15
+ * @since 0.0.35
17
16
  */
18
- class Panel extends Component {
19
- constructor(props) {
20
- super(props);
21
- _defineProperty(this, "handleToggle", e => {
22
- if (isClickable(e)) {
23
- return;
24
- }
25
- this.setState(_ref => {
26
- let {
27
- collapsed
28
- } = _ref;
29
- return {
30
- collapsed: !collapsed
31
- };
32
- }, () => {
33
- if (this.props.onToggle) {
34
- this.props.onToggle(this.state.collapsed);
35
- }
36
- });
37
- });
38
- const _collapsed2 = this.props.collapsible && this.props.collapsed || false;
39
- // eslint-disable-next-line react/state-in-constructor
40
- this.state = {
41
- collapsed: _collapsed2,
42
- prevPropsCollapsed: _collapsed2
43
- };
44
- }
45
- static getDerivedStateFromProps(props, state) {
46
- if (props.collapsed !== state.prevPropsCollapsed) {
47
- return {
48
- collapsed: props.collapsed,
49
- prevPropsCollapsed: props.collapsed
50
- };
17
+ const Panel = _ref => {
18
+ let {
19
+ baseClassName = `${CLS_PREFIX}panel`,
20
+ className,
21
+ title,
22
+ collapsible = false,
23
+ collapsed: externalCollapsed,
24
+ onToggle,
25
+ children,
26
+ extra,
27
+ ...props
28
+ } = _ref;
29
+ const rootRef = useRef(null);
30
+ const isControlled = externalCollapsed !== undefined;
31
+ const [internalCollapsed, setInternalCollapsed] = useState(false);
32
+ const collapsed = isControlled ? externalCollapsed : internalCollapsed;
33
+ const handleToggle = e => {
34
+ if (!collapsible || isClickable(e)) return;
35
+ if (!isControlled) {
36
+ setInternalCollapsed(!collapsed);
51
37
  }
52
- return null;
53
- }
54
- render() {
55
- const {
56
- baseClassName,
57
- className,
58
- title,
59
- collapsible,
60
- collapsed: _collapsed,
61
- onToggle,
62
- children,
63
- extra,
64
- ...props
65
- } = this.props;
66
- const {
67
- collapsed
68
- } = this.state;
69
- const handleToggle = collapsible ? this.handleToggle : undefined;
70
- const rootRef = /*#__PURE__*/createRef();
71
- return /*#__PURE__*/_jsx(CSSTransition, {
72
- classNames: `${baseClassName}-`,
73
- in: !collapsed,
74
- timeout: 300,
75
- nodeRef: rootRef,
76
- children: /*#__PURE__*/_jsxs("div", {
77
- className: classNames(baseClassName, {
78
- [`${baseClassName}--collapsible`]: collapsible,
79
- [`${baseClassName}--collapsed`]: collapsed,
80
- [`${baseClassName}--expanded`]: !collapsed
81
- }, className),
82
- ...props,
83
- ref: rootRef,
84
- children: [title && /*#__PURE__*/_jsxs("div", {
85
- className: `${baseClassName}__header`,
86
- onClick: handleToggle,
87
- children: [isLikeText(title) ? /*#__PURE__*/_jsx(Heading, {
88
- component: "div",
89
- level: 4,
90
- className: `${baseClassName}__title`,
91
- children: title
92
- }) : title, (extra || collapsible) && /*#__PURE__*/_jsxs("div", {
93
- className: `${baseClassName}__extra`,
94
- children: [extra, collapsible && /*#__PURE__*/_jsx(Button, {
95
- ghost: true,
96
- className: `${baseClassName}__control-button`,
97
- icon: {
98
- name: 'chevron-up',
99
- flipVertical: collapsed
100
- },
101
- onClick: handleToggle
102
- })]
38
+ onToggle?.(!collapsed);
39
+ };
40
+ return /*#__PURE__*/_jsx(CSSTransition, {
41
+ classNames: `${baseClassName}-`,
42
+ in: !collapsed,
43
+ timeout: 300,
44
+ nodeRef: rootRef,
45
+ children: /*#__PURE__*/_jsxs("div", {
46
+ className: classNames(baseClassName, {
47
+ [`${baseClassName}--collapsible`]: collapsible,
48
+ [`${baseClassName}--collapsed`]: collapsed,
49
+ [`${baseClassName}--expanded`]: !collapsed
50
+ }, className),
51
+ ...props,
52
+ ref: rootRef,
53
+ children: [title && /*#__PURE__*/_jsxs("div", {
54
+ className: `${baseClassName}__header`,
55
+ onClick: handleToggle,
56
+ children: [isLikeText(title) ? /*#__PURE__*/_jsx(Heading, {
57
+ component: "div",
58
+ level: 4,
59
+ className: `${baseClassName}__title`,
60
+ children: title
61
+ }) : title, (extra || collapsible) && /*#__PURE__*/_jsxs("div", {
62
+ className: `${baseClassName}__extra`,
63
+ children: [extra, collapsible && /*#__PURE__*/_jsx(Button, {
64
+ ghost: true,
65
+ className: `${baseClassName}__control-button`,
66
+ icon: {
67
+ name: 'chevron-up',
68
+ flipVertical: collapsed
69
+ },
70
+ onClick: handleToggle
103
71
  })]
104
- }), /*#__PURE__*/_jsx("div", {
105
- className: `${baseClassName}__content`,
106
- children: children
107
72
  })]
108
- })
109
- });
110
- }
111
- }
112
- _defineProperty(Panel, "defaultProps", {
113
- collapsible: false,
114
- collapsed: false,
115
- baseClassName: `${CLS_PREFIX}panel`
116
- });
73
+ }), /*#__PURE__*/_jsx("div", {
74
+ className: `${baseClassName}__content`,
75
+ children: children
76
+ })]
77
+ })
78
+ });
79
+ };
117
80
  export default Panel;
@@ -3,9 +3,9 @@
3
3
  import classNames from 'classnames';
4
4
  import { CLS_PREFIX } from '../../constants';
5
5
  import { jsx as _jsx } from "react/jsx-runtime";
6
- /**
7
- * `Paragraph` is a block containing a single paragraph of [Text](#!/Text).
8
- * @since 1.1.0
6
+ /**
7
+ * `Paragraph` is a block containing a single paragraph of [Text](#!/Text).
8
+ * @since 1.1.0
9
9
  */
10
10
  const Paragraph = _ref => {
11
11
  let {
@@ -3,9 +3,9 @@
3
3
  import classNames from 'classnames';
4
4
  import { CLS_PREFIX } from '../../constants';
5
5
  import { jsx as _jsx } from "react/jsx-runtime";
6
- /**
7
- * `Plaintext` component is used to show regular text, without any formatting options and ignoring html tags.
8
- * @since 0.0.42
6
+ /**
7
+ * `Plaintext` component is used to show regular text, without any formatting options and ignoring html tags.
8
+ * @since 0.0.42
9
9
  */
10
10
  const Plaintext = _ref => {
11
11
  let {
@@ -34,10 +34,10 @@ const PLACEMENT_MAP = {
34
34
  const ARROW_HEIGHT = 26;
35
35
  const isControlled = props => props.visible !== null;
36
36
  const normalize = value => String(Number(value)) === String(value) ? `${value}px` : value;
37
- /**
38
- * `Popover` component is non-modal pop-up window used for providing additional information
39
- * for an interface element. It also may contain Form with few fields or any other small content.
40
- * @since 0.0.42
37
+ /**
38
+ * `Popover` component is non-modal pop-up window used for providing additional information
39
+ * for an interface element. It also may contain Form with few fields or any other small content.
40
+ * @since 0.0.42
41
41
  */
42
42
  class Popover extends Component {
43
43
  constructor() {
@@ -9,8 +9,8 @@ import { CLS_PREFIX } from '../../constants';
9
9
  import Layer from '../Layer';
10
10
  import { jsxs as _jsxs } from "react/jsx-runtime";
11
11
  import { jsx as _jsx } from "react/jsx-runtime";
12
- /**
13
- * `Popper` component.
12
+ /**
13
+ * `Popper` component.
14
14
  */
15
15
  class Popper extends Component {
16
16
  constructor() {
@@ -7,9 +7,9 @@ import { CLS_PREFIX } from '../../constants';
7
7
  import { safeInvoke } from '../utils';
8
8
  import { STATUS_NOT_STARTED, STATUS_RUNNING, STATUS_DONE, STATUS_ERROR, STATUS_WARNING } from '../ProgressStep';
9
9
  import { jsx as _jsx } from "react/jsx-runtime";
10
- /**
11
- * `Progress` is used for showing progress of performing long operations.
12
- * @since 1.10.0
10
+ /**
11
+ * `Progress` is used for showing progress of performing long operations.
12
+ * @since 1.10.0
13
13
  */
14
14
  class Progress extends Component {
15
15
  constructor() {
@@ -11,9 +11,9 @@ import { STATUS_DONE, STATUS_ERROR, STATUS_WARNING } from '../ProgressStep';
11
11
  import Progress from '../Progress';
12
12
  import { jsx as _jsx } from "react/jsx-runtime";
13
13
  import { jsxs as _jsxs } from "react/jsx-runtime";
14
- /**
15
- * `ProgressDialog` is a [Dialog](#!/Dialog) combined with of [Progress](#!/Progress) component.
16
- * @since 1.2.0
14
+ /**
15
+ * `ProgressDialog` is a [Dialog](#!/Dialog) combined with of [Progress](#!/Progress) component.
16
+ * @since 1.2.0
17
17
  */
18
18
  class ProgressDialog extends Component {
19
19
  constructor() {
@@ -3,9 +3,9 @@
3
3
  import React from 'react';
4
4
  import ProgressStep from '../ProgressStep';
5
5
 
6
- /**
7
- * @deprecated Component `ProgressDialogStep` is deprecated, use `ProgressStep` instead.
8
- * @since 1.2.0
6
+ /**
7
+ * @deprecated Component `ProgressDialogStep` is deprecated, use `ProgressStep` instead.
8
+ * @since 1.2.0
9
9
  */
10
10
  import { jsx as _jsx } from "react/jsx-runtime";
11
11
  const ProgressDialogStep = props => {
@@ -15,9 +15,9 @@ export const STATUS_DONE = 'done';
15
15
  export const STATUS_WARNING = 'warning';
16
16
  export const STATUS_ERROR = 'error';
17
17
  export const STATUS_CANCELED = 'canceled';
18
- /**
19
- * `ProgressStep` is a part of the [Progress](#!/Progress) component.
20
- * @since 1.10.0
18
+ /**
19
+ * `ProgressStep` is a part of the [Progress](#!/Progress) component.
20
+ * @since 1.10.0
21
21
  */
22
22
  const ProgressStep = _ref => {
23
23
  let {
@@ -6,9 +6,9 @@ import { jsx as _jsx } from "react/jsx-runtime";
6
6
  import { jsxs as _jsxs } from "react/jsx-runtime";
7
7
  let radioId = 0;
8
8
 
9
- /**
10
- * `Radio` component is used for making a choice among a set of mutually exclusive, related options.
11
- * @since 3.2.0
9
+ /**
10
+ * `Radio` component is used for making a choice among a set of mutually exclusive, related options.
11
+ * @since 3.2.0
12
12
  */
13
13
  const Radio = _ref => {
14
14
  let {
@@ -12,9 +12,9 @@ const width = value => {
12
12
  }
13
13
  return result;
14
14
  };
15
- /**
16
- * `Rating` component is used for showing and collecting feedback of users' opinion in 0-5 grade scale.
17
- * @since 0.0.42
15
+ /**
16
+ * `Rating` component is used for showing and collecting feedback of users' opinion in 0-5 grade scale.
17
+ * @since 0.0.42
18
18
  */
19
19
  const Rating = _ref => {
20
20
  let {
@@ -1,6 +1,6 @@
1
- <svg version="1.1" xmlns="http://www.w3.org/2000/svg" width="56" height="248" viewBox="0 0 51 248">
2
- <defs><symbol id="star"><path stroke-width="3" d="m25,1 6,17h18l-14,11 5,17-15-10-15,10 5-17-14-11h18z"></path></symbol></defs>
3
- <use x="0" y="0" fill="none" stroke="#ff9500" href="#star"></use>
4
- <use x="0" y="100" fill="#ff9500" stroke="#ff9500" href="#star"></use>
5
- <use x="0" y="200" fill="#848484" stroke="#848484" href="#star"></use>
6
- </svg>
1
+ <svg version="1.1" xmlns="http://www.w3.org/2000/svg" width="56" height="248" viewBox="0 0 51 248">
2
+ <defs><symbol id="star"><path stroke-width="3" d="m25,1 6,17h18l-14,11 5,17-15-10-15,10 5-17-14-11h18z"></path></symbol></defs>
3
+ <use x="0" y="0" fill="none" stroke="#ff9500" href="#star"></use>
4
+ <use x="0" y="100" fill="#ff9500" stroke="#ff9500" href="#star"></use>
5
+ <use x="0" y="200" fill="#848484" stroke="#848484" href="#star"></use>
6
+ </svg>
@@ -231,10 +231,10 @@ class Section extends Component {
231
231
  }
232
232
  }
233
233
 
234
- /**
235
- * `Section` component is used for dividing of complex content into groups for better readability
236
- * and comprehension of the presented information.
237
- * @since 0.0.54
234
+ /**
235
+ * `Section` component is used for dividing of complex content into groups for better readability
236
+ * and comprehension of the presented information.
237
+ * @since 0.0.54
238
238
  */
239
239
  _defineProperty(Section, "defaultProps", DEFAULT_PROPS);
240
240
  const SectionWrapper = props => {
@@ -8,9 +8,9 @@ import { jsx as _jsx } from "react/jsx-runtime";
8
8
  import { jsxs as _jsxs } from "react/jsx-runtime";
9
9
  export const SECTION_ITEM_BASE_CLASS_NAME = `${CLS_PREFIX}section-item`;
10
10
 
11
- /**
12
- * `SectionItem` component is used for showing parameters and its values in [Section](#!/Section).
13
- * @since 0.0.54
11
+ /**
12
+ * `SectionItem` component is used for showing parameters and its values in [Section](#!/Section).
13
+ * @since 0.0.54
14
14
  */
15
15
  const SectionItem = _ref => {
16
16
  let {
@@ -15,10 +15,10 @@ import { jsxs as _jsxs } from "react/jsx-runtime";
15
15
  const alphaSort = (a, b) => a > b ? 1 : -1;
16
16
  export const SEGMENTED_CONTROL_BASE_CLASS_NAME = `${CLS_PREFIX}segmented-control`;
17
17
 
18
- /**
19
- * `Segmented Control` is a group of several [Buttons](#!/Button)
20
- * each of which functions as a mutually exclusive option.
21
- * @since 0.0.68
18
+ /**
19
+ * `Segmented Control` is a group of several [Buttons](#!/Button)
20
+ * each of which functions as a mutually exclusive option.
21
+ * @since 0.0.68
22
22
  */
23
23
  class SegmentedControl extends Component {
24
24
  constructor() {
@@ -38,7 +38,7 @@ const MultiValue = _ref => {
38
38
  focusable: "false",
39
39
  "aria-hidden": "true",
40
40
  children: /*#__PURE__*/_jsx("path", {
41
- d: "M3.85 8.854a.498.498 0 1 1-.704-.704L5.296 6l-2.15-2.15a.498.498 0 0 1 .704-.704L6 5.296l2.15-2.15a.498.498 0 1 1\r .704.704L6.704 6l2.15 2.15a.498.498 0 0 1-.704.704L6 6.704l-2.15 2.15z"
41
+ d: "M3.85 8.854a.498.498 0 1 1-.704-.704L5.296 6l-2.15-2.15a.498.498 0 0 1 .704-.704L6 5.296l2.15-2.15a.498.498 0 1 1 .704.704L6.704 6l2.15 2.15a.498.498 0 0 1-.704.704L6 6.704l-2.15 2.15z"
42
42
  })
43
43
  })
44
44
  })]
@@ -86,9 +86,9 @@ const getNextValue = (value, prevValue) => {
86
86
  }
87
87
  return value;
88
88
  };
89
- /**
90
- * `Select` component is used for making a choice among a set of related options.
91
- * @since 2.3.0
89
+ /**
90
+ * `Select` component is used for making a choice among a set of related options.
91
+ * @since 2.3.0
92
92
  */
93
93
  const Select = _ref => {
94
94
  let {
@@ -220,7 +220,7 @@ const SelectControl = /*#__PURE__*/forwardRef(function SelectControl(_ref, ref)
220
220
  "aria-hidden": "true",
221
221
  focusable: "false",
222
222
  children: /*#__PURE__*/_jsx("path", {
223
- d: "M.85 7.854a.498.498 0 1 1-.704-.704L3.296 4 .146.85A.498.498 0 0 1 .85.146L4 3.296 7.15.146a.498.498 0 0 1\r .704.704L4.704 4l3.15 3.15a.498.498 0 0 1-.704.704L4 4.704.85 7.854z"
223
+ d: "M.85 7.854a.498.498 0 1 1-.704-.704L3.296 4 .146.85A.498.498 0 0 1 .85.146L4 3.296 7.15.146a.498.498 0 0 1 .704.704L4.704 4l3.15 3.15a.498.498 0 0 1-.704.704L4 4.704.85 7.854z"
224
224
  })
225
225
  })
226
226
  })
@@ -1,10 +1,11 @@
1
1
  import { jsx as _jsx } from "react/jsx-runtime";
2
2
  // Copyright 1999-2023. Plesk International GmbH. All rights reserved.
3
3
 
4
- /**
5
- * `SelectOption` is a part of [SelectOptionGroup](#!/SelectOptionGroup) component.
6
- * @since 2.3.0
7
- */ // eslint-disable-next-line @typescript-eslint/no-unused-vars
4
+ /**
5
+ * `SelectOption` is a part of [SelectOptionGroup](#!/SelectOptionGroup) component.
6
+ * @since 2.3.0
7
+ */
8
+ // eslint-disable-next-line @typescript-eslint/no-unused-vars
8
9
  const SelectOption = _props => {
9
10
  // styleguidist doesn't show Props & Methods if component renders nothing
10
11
  // eslint-disable-next-line no-constant-condition
@@ -1,9 +1,9 @@
1
1
  import { jsx as _jsx } from "react/jsx-runtime";
2
2
  // Copyright 1999-2023. Plesk International GmbH. All rights reserved.
3
3
 
4
- /**
5
- * `SelectOptionGroup` is a part of [Select](#!/Select) component. It can be used for splitting the list of all options into groups.
6
- * @since 2.3.0
4
+ /**
5
+ * `SelectOptionGroup` is a part of [Select](#!/Select) component. It can be used for splitting the list of all options into groups.
6
+ * @since 2.3.0
7
7
  */
8
8
  const SelectOptionGroup = _props => {
9
9
  // styleguidist doesn't show Props & Methods if component renders nothing
@@ -4,10 +4,10 @@ import classNames from 'classnames';
4
4
  import { normalizeSize } from '../utils';
5
5
  import { CLS_PREFIX } from '../../constants';
6
6
  import { jsx as _jsx } from "react/jsx-runtime";
7
- /**
8
- * `Skeleton` (or content-placeholder) is placeholder preview of content before the data gets loaded to reduce load-time frustration.
9
- * Skeleton is used for non-text components, images, media-objects, etc.
10
- * @since 3.28.0
7
+ /**
8
+ * `Skeleton` (or content-placeholder) is placeholder preview of content before the data gets loaded to reduce load-time frustration.
9
+ * Skeleton is used for non-text components, images, media-objects, etc.
10
+ * @since 3.28.0
11
11
  */
12
12
  const Skeleton = _ref => {
13
13
  let {
@@ -4,9 +4,9 @@ import classNames from 'classnames';
4
4
  import SkeletonText from './SkeletonText';
5
5
  import { CLS_PREFIX } from '../../constants';
6
6
  import { jsx as _jsx } from "react/jsx-runtime";
7
- /**
8
- * Skeleton for tabs component
9
- * @since `3.28.0
7
+ /**
8
+ * Skeleton for tabs component
9
+ * @since `3.28.0
10
10
  */
11
11
  const SkeletonTabs = _ref => {
12
12
  let {
@@ -4,9 +4,9 @@ import classNames from 'classnames';
4
4
  import Skeleton from './Skeleton';
5
5
  import { CLS_PREFIX } from '../../constants';
6
6
  import { jsx as _jsx } from "react/jsx-runtime";
7
- /**
8
- * Skeleton for text-containing components. Is can be used inside Paragraph, as title, or single text
9
- * @since 3.28.0
7
+ /**
8
+ * Skeleton for text-containing components. Is can be used inside Paragraph, as title, or single text
9
+ * @since 3.28.0
10
10
  */
11
11
  const SkeletonText = _ref => {
12
12
  let {
@@ -3,8 +3,8 @@
3
3
  import classNames from 'classnames';
4
4
  import { CLS_PREFIX } from '../../constants';
5
5
  import { jsx as _jsx } from "react/jsx-runtime";
6
- /**
7
- * `Spinner` component.
6
+ /**
7
+ * `Spinner` component.
8
8
  */
9
9
  const Spinner = _ref => {
10
10
  let {
@@ -31,11 +31,11 @@ const focusStrategy = {
31
31
  return container.children[1].querySelector('button');
32
32
  }
33
33
  };
34
- /**
35
- * `Split Button` is a combination of a standard [Button](#!/Button) with a [Dropdown](#!/Dropdown) menu.
36
- * It is used for grouping several related actions when one of the actions should be accessible immediately
37
- * because it is used more often than others.
38
- * @since 0.0.40
34
+ /**
35
+ * `Split Button` is a combination of a standard [Button](#!/Button) with a [Dropdown](#!/Dropdown) menu.
36
+ * It is used for grouping several related actions when one of the actions should be accessible immediately
37
+ * because it is used more often than others.
38
+ * @since 0.0.40
39
39
  */
40
40
  const SplitButton = _ref => {
41
41
  let {
@@ -9,9 +9,9 @@ import SpotPopup from './SpotPopup';
9
9
  import { jsx as _jsx } from "react/jsx-runtime";
10
10
  const isEqual = (a, b) => a.top === b.top && a.left === b.left && a.right === b.right && a.bottom === b.bottom && a.width === b.width && a.height === b.height;
11
11
 
12
- /**
13
- * The component can be used to attract the user's attention to a specific element on the page.
14
- * @since 3.0.1
12
+ /**
13
+ * The component can be used to attract the user's attention to a specific element on the page.
14
+ * @since 3.0.1
15
15
  */
16
16
  const Spot = _ref => {
17
17
  let {
@@ -20,9 +20,9 @@ const toIcon = (icon, intent) => {
20
20
  } : undefined);
21
21
  };
22
22
 
23
- /**
24
- * `Status` component is used for indicating state of an object or the system.
25
- * @since 0.0.68
23
+ /**
24
+ * `Status` component is used for indicating state of an object or the system.
25
+ * @since 0.0.68
26
26
  */
27
27
  const Status = _ref => {
28
28
  let {
@@ -7,10 +7,10 @@ import { CLS_PREFIX } from '../../constants';
7
7
  import { intentIconMap } from '../intentIconMap';
8
8
  import { jsx as _jsx } from "react/jsx-runtime";
9
9
  import { jsxs as _jsxs } from "react/jsx-runtime";
10
- /**
11
- * `StatusMessage` is used for notifying users about events happened (or going to happen) in the system.
12
- * For showing results of performed operations [Toaster](#!/Toaster) should be used.
13
- * @since 1.12.0
10
+ /**
11
+ * `StatusMessage` is used for notifying users about events happened (or going to happen) in the system.
12
+ * For showing results of performed operations [Toaster](#!/Toaster) should be used.
13
+ * @since 1.12.0
14
14
  */
15
15
  const StatusMessage = _ref => {
16
16
  let {
@@ -5,9 +5,9 @@ import { CLS_PREFIX } from '../../constants';
5
5
  import { safeInvoke, createFocusManager } from '../utils';
6
6
  import { cloneElement, Children, isValidElement, useRef, useMemo } from 'react';
7
7
  import { jsx as _jsx } from "react/jsx-runtime";
8
- /**
9
- * `Subnav` component is used when you need a second level navigation under [Tabs](#!/Tabs) on the screen.
10
- * @since 0.0.42
8
+ /**
9
+ * `Subnav` component is used when you need a second level navigation under [Tabs](#!/Tabs) on the screen.
10
+ * @since 0.0.42
11
11
  */
12
12
  const Subnav = _ref => {
13
13
  let {
@@ -85,8 +85,8 @@ const Subnav = _ref => {
85
85
  children: items
86
86
  });
87
87
  };
88
- /**
89
- * SubnavItem component.
88
+ /**
89
+ * SubnavItem component.
90
90
  */
91
91
  const SubnavItem = _ref2 => {
92
92
  let {
@@ -5,10 +5,10 @@ import { CLS_PREFIX } from '../../constants';
5
5
  import Tooltip from '../Tooltip';
6
6
  import { jsx as _jsx } from "react/jsx-runtime";
7
7
  import { jsxs as _jsxs } from "react/jsx-runtime";
8
- /**
9
- * `Switch` component is used for changing the state of an object or system preferences.
10
- * It provides immediate results that is why it should not be used in Form.
11
- * @since 0.0.42
8
+ /**
9
+ * `Switch` component is used for changing the state of an object or system preferences.
10
+ * It provides immediate results that is why it should not be used in Form.
11
+ * @since 0.0.42
12
12
  */
13
13
  const Switch = _ref => {
14
14
  let {
@@ -5,9 +5,9 @@ import classNames from 'classnames';
5
5
  import { CLS_PREFIX } from '../../constants';
6
6
  import Section from '../Section';
7
7
  import { jsx as _jsx } from "react/jsx-runtime";
8
- /**
9
- * `SwitchesPanel` component is used for grouping several [SwitchesPanelItems](#!/SwitchesPanelItem) into one set.
10
- * @since 0.3.0
8
+ /**
9
+ * `SwitchesPanel` component is used for grouping several [SwitchesPanelItems](#!/SwitchesPanelItem) into one set.
10
+ * @since 0.3.0
11
11
  */
12
12
  const SwitchesPanel = _ref => {
13
13
  let {
@@ -9,10 +9,10 @@ import Action from '../Action';
9
9
  import Popover from '../Popover';
10
10
  import { jsx as _jsx } from "react/jsx-runtime";
11
11
  import { jsxs as _jsxs } from "react/jsx-runtime";
12
- /**
13
- * `SwitchesPanelItem` component is used for combining [Switch](#!/Switch) component with text title and description.
14
- * Used in [SwitchesPanel](#!/SwitchesPanel).
15
- * @since 0.3.0
12
+ /**
13
+ * `SwitchesPanelItem` component is used for combining [Switch](#!/Switch) component with text title and description.
14
+ * Used in [SwitchesPanel](#!/SwitchesPanel).
15
+ * @since 0.3.0
16
16
  */
17
17
  class SwitchesPanelItem extends Component {
18
18
  constructor() {