@jetbrains/ring-ui-built 7.0.65 → 7.0.70

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 (231) hide show
  1. package/components/_helpers/anchor.js +12 -17
  2. package/components/_helpers/avatar-info.js +4 -5
  3. package/components/_helpers/button.classes.js +20 -21
  4. package/components/_helpers/caption.js +3 -3
  5. package/components/_helpers/card.js +26 -32
  6. package/components/_helpers/dialog-body-scroll-preventer.js +1 -2
  7. package/components/_helpers/icon-svg.js +9 -12
  8. package/components/_helpers/input.js +78 -86
  9. package/components/_helpers/loader-core.js +260 -0
  10. package/components/_helpers/query-assist-suggestions.js +0 -1
  11. package/components/_helpers/select-filter.js +19 -26
  12. package/components/_helpers/services-link.js +9 -12
  13. package/components/_helpers/sidebar.js +36 -44
  14. package/components/_helpers/tab-link.js +9 -11
  15. package/components/_helpers/theme.js +20 -24
  16. package/components/_helpers/title.js +12 -17
  17. package/components/alert/alert.js +41 -49
  18. package/components/alert/container.js +9 -12
  19. package/components/alert-service/alert-service.js +23 -32
  20. package/components/analytics/analytics-custom-plugin.js +12 -17
  21. package/components/analytics/analytics.js +1 -3
  22. package/components/auth/auth-core.js +128 -170
  23. package/components/auth/auth.js +3 -10
  24. package/components/auth/background-flow.js +5 -8
  25. package/components/auth/down-notification.js +9 -17
  26. package/components/auth/iframe-flow.js +13 -19
  27. package/components/auth/request-builder.js +4 -9
  28. package/components/auth/response-parser.js +9 -12
  29. package/components/auth/storage.js +12 -18
  30. package/components/auth/token-validator.js +19 -30
  31. package/components/auth/window-flow.js +22 -27
  32. package/components/auth-dialog/auth-dialog.js +40 -48
  33. package/components/auth-dialog-service/auth-dialog-service.js +10 -13
  34. package/components/avatar/avatar.figma.js +6 -6
  35. package/components/avatar/avatar.js +58 -59
  36. package/components/avatar/fallback-avatar.js +8 -11
  37. package/components/avatar-stack/avatar-stack.figma.js +10 -11
  38. package/components/avatar-stack/avatar-stack.js +25 -31
  39. package/components/banner/banner.js +0 -6
  40. package/components/breadcrumbs/breadcrumbs.figma.js +8 -6
  41. package/components/breadcrumbs/breadcrumbs.js +4 -5
  42. package/components/button/button.figma.js +15 -10
  43. package/components/button/button.js +59 -64
  44. package/components/button-group/button-group.js +11 -15
  45. package/components/button-group/caption.js +0 -1
  46. package/components/button-set/button-set.js +9 -12
  47. package/components/button-toolbar/button-toolbar.js +8 -11
  48. package/components/caret/caret.js +20 -28
  49. package/components/checkbox/checkbox-group.figma.js +8 -10
  50. package/components/checkbox/checkbox.figma.js +5 -5
  51. package/components/checkbox/checkbox.js +27 -35
  52. package/components/clipboard/clipboard-fallback.js +3 -3
  53. package/components/clipboard/clipboard.js +3 -16
  54. package/components/code/code.js +8 -14
  55. package/components/collapse/collapse-content.js +10 -15
  56. package/components/collapse/collapse-control.js +5 -7
  57. package/components/collapse/collapse.js +9 -11
  58. package/components/collapse/utils.js +1 -1
  59. package/components/confirm/confirm.js +17 -26
  60. package/components/confirm-service/confirm-service.js +30 -31
  61. package/components/content-layout/content-layout.js +21 -28
  62. package/components/content-layout/sidebar.js +0 -2
  63. package/components/contenteditable/contenteditable.js +23 -28
  64. package/components/control-help/control-help.js +8 -10
  65. package/components/control-label/control-label.js +12 -17
  66. package/components/data-list/data-list.js +57 -65
  67. package/components/data-list/data-list.mock.js +0 -4
  68. package/components/data-list/item.js +65 -72
  69. package/components/data-list/selection.js +11 -19
  70. package/components/data-list/title.js +0 -4
  71. package/components/date-picker/consts.js +3 -4
  72. package/components/date-picker/date-input.js +25 -33
  73. package/components/date-picker/date-picker.js +179 -193
  74. package/components/date-picker/date-popup.js +135 -127
  75. package/components/date-picker/day.d.ts +1 -1
  76. package/components/date-picker/day.js +24 -30
  77. package/components/date-picker/month-names.js +7 -12
  78. package/components/date-picker/month-slider.js +16 -22
  79. package/components/date-picker/month.js +3 -5
  80. package/components/date-picker/months.js +6 -6
  81. package/components/date-picker/weekdays.js +0 -1
  82. package/components/date-picker/years.js +20 -26
  83. package/components/dialog/dialog-body-scroll-preventer.js +0 -1
  84. package/components/dialog/dialog.js +73 -83
  85. package/components/dropdown/anchor.js +0 -4
  86. package/components/dropdown/dropdown.js +98 -114
  87. package/components/dropdown-menu/dropdown-menu.js +80 -79
  88. package/components/editable-heading/editable-heading.js +48 -54
  89. package/components/error-bubble/error-bubble.figma.js +4 -4
  90. package/components/error-bubble/error-bubble.js +9 -13
  91. package/components/error-message/error-message.js +1 -6
  92. package/components/footer/footer.js +11 -15
  93. package/components/global/compose-refs.js +1 -4
  94. package/components/global/compose.js +1 -4
  95. package/components/global/configuration.js +3 -3
  96. package/components/global/controls-height.js +0 -1
  97. package/components/global/create-stateful-context.js +10 -14
  98. package/components/global/data-tests.js +2 -10
  99. package/components/global/dom.js +6 -19
  100. package/components/global/focus-sensor-hoc.js +74 -87
  101. package/components/global/fuzzy-highlight.js +3 -8
  102. package/components/global/get-uid.js +1 -1
  103. package/components/global/inject-styles.js +5 -6
  104. package/components/global/listeners.js +2 -11
  105. package/components/global/memoize.js +0 -2
  106. package/components/global/normalize-indent.js +2 -6
  107. package/components/global/promise-with-timeout.js +4 -5
  108. package/components/global/react-dom-renderer.js +4 -9
  109. package/components/global/rerender-hoc.js +8 -11
  110. package/components/global/schedule-raf.js +1 -2
  111. package/components/global/theme.js +0 -5
  112. package/components/global/trivial-template-tag.js +1 -6
  113. package/components/global/url.js +2 -6
  114. package/components/global/use-event-callback.js +2 -3
  115. package/components/grid/col.js +7 -18
  116. package/components/grid/grid.js +9 -14
  117. package/components/grid/row.js +7 -11
  118. package/components/group/group.js +9 -12
  119. package/components/header/header-icon.js +8 -13
  120. package/components/header/header.js +16 -27
  121. package/components/header/links.js +7 -10
  122. package/components/header/logo.js +12 -16
  123. package/components/header/profile.js +73 -83
  124. package/components/header/services-link.js +0 -2
  125. package/components/header/services.js +32 -43
  126. package/components/header/smart-profile.js +44 -59
  127. package/components/header/smart-services.js +33 -45
  128. package/components/header/tray.js +8 -10
  129. package/components/heading/heading.js +27 -27
  130. package/components/http/http.js +120 -125
  131. package/components/http/http.mock.js +6 -10
  132. package/components/hub-source/hub-source-user.js +6 -13
  133. package/components/hub-source/hub-source-users-groups.js +8 -12
  134. package/components/hub-source/hub-source.js +8 -10
  135. package/components/i18n/i18n-context.js +4 -7
  136. package/components/i18n/i18n.js +5 -5
  137. package/components/icon/icon-svg.js +0 -4
  138. package/components/icon/icon.js +28 -32
  139. package/components/icon/index.js +0 -4
  140. package/components/input/input.figma.js +8 -8
  141. package/components/input/input.js +0 -4
  142. package/components/island/adaptive-island-hoc.js +19 -23
  143. package/components/island/content.js +70 -75
  144. package/components/island/header.js +21 -21
  145. package/components/island/island.js +11 -14
  146. package/components/link/clickable-link.js +30 -37
  147. package/components/link/link.js +27 -29
  148. package/components/list/list-custom.js +6 -11
  149. package/components/list/list-item.js +49 -56
  150. package/components/list/list-separator.js +0 -1
  151. package/components/list/list-title.js +0 -1
  152. package/components/list/list-users-groups-source.js +14 -22
  153. package/components/list/list.classes.js +8 -9
  154. package/components/list/list.js +387 -404
  155. package/components/loader/loader-core.js +2 -265
  156. package/components/loader/loader.d.ts +8 -0
  157. package/components/loader/loader.js +43 -29
  158. package/components/loader-inline/loader-inline.js +9 -12
  159. package/components/loader-screen/loader-screen.js +10 -14
  160. package/components/login-dialog/login-dialog.js +46 -54
  161. package/components/login-dialog/service.js +13 -15
  162. package/components/message/message.js +65 -79
  163. package/components/old-browsers-message/old-browsers-message-stop.js +0 -3
  164. package/components/old-browsers-message/old-browsers-message.js +1 -4
  165. package/components/old-browsers-message/white-list.js +5 -7
  166. package/components/pager/pager.js +73 -88
  167. package/components/panel/panel.js +9 -12
  168. package/components/permissions/permissions-cache.js +6 -8
  169. package/components/permissions/permissions.js +19 -21
  170. package/components/popup/popup.js +136 -145
  171. package/components/popup/popup.target.js +8 -10
  172. package/components/popup/position-css.js +19 -27
  173. package/components/popup/position.js +22 -28
  174. package/components/popup-menu/popup-menu.js +27 -37
  175. package/components/progress-bar/progress-bar.js +26 -32
  176. package/components/query-assist/query-assist-suggestions.js +0 -6
  177. package/components/query-assist/query-assist.js +432 -468
  178. package/components/radio/radio-item.js +30 -40
  179. package/components/radio/radio.js +6 -10
  180. package/components/scrollable-section/scrollable-section.js +7 -10
  181. package/components/select/select-filter.js +0 -6
  182. package/components/select/select-popup.js +155 -174
  183. package/components/select/select.js +464 -479
  184. package/components/shortcuts/core.js +40 -45
  185. package/components/shortcuts/shortcut-title.js +0 -1
  186. package/components/shortcuts/shortcuts-hoc.js +9 -15
  187. package/components/shortcuts/shortcuts.js +3 -5
  188. package/components/slider/slider.js +53 -66
  189. package/components/slider/slider.utils.js +1 -4
  190. package/components/storage/storage-local.js +2 -8
  191. package/components/storage/storage.js +0 -5
  192. package/components/style.css +1 -1
  193. package/components/tab-trap/tab-trap.js +21 -30
  194. package/components/table/cell.js +3 -4
  195. package/components/table/disable-hover-hoc.js +24 -28
  196. package/components/table/header-cell.js +30 -38
  197. package/components/table/header.js +20 -28
  198. package/components/table/multitable.js +81 -101
  199. package/components/table/row-with-focus-sensor.js +17 -28
  200. package/components/table/row.js +89 -99
  201. package/components/table/selection-adapter.js +0 -2
  202. package/components/table/selection-shortcuts-hoc.js +159 -161
  203. package/components/table/selection.js +23 -31
  204. package/components/table/simple-table.js +16 -22
  205. package/components/table/smart-table.js +19 -26
  206. package/components/table/table.js +137 -146
  207. package/components/tabs/collapsible-more.js +34 -47
  208. package/components/tabs/collapsible-tab.js +28 -33
  209. package/components/tabs/collapsible-tabs.js +18 -26
  210. package/components/tabs/custom-item.js +3 -6
  211. package/components/tabs/dumb-tabs.js +48 -64
  212. package/components/tabs/smart-tabs.js +14 -23
  213. package/components/tabs/tab-link.js +0 -2
  214. package/components/tabs/tab.js +0 -1
  215. package/components/tabs/tabs.js +0 -7
  216. package/components/tag/tag.js +30 -35
  217. package/components/tags-input/tags-input.js +192 -218
  218. package/components/tags-list/tags-list.js +26 -31
  219. package/components/text/text.js +16 -19
  220. package/components/toggle/toggle.js +19 -23
  221. package/components/tooltip/tooltip.js +110 -121
  222. package/components/upload/upload.js +19 -28
  223. package/components/user-agreement/service.js +247 -252
  224. package/components/user-agreement/toolbox.eula.js +160 -1
  225. package/components/user-agreement/user-agreement.js +23 -32
  226. package/components/user-card/card.js +0 -5
  227. package/components/user-card/smart-user-card-tooltip.js +41 -50
  228. package/components/user-card/tooltip.js +32 -38
  229. package/components/user-card/user-card.js +0 -5
  230. package/package.json +9 -3
  231. package/components/_helpers/_rollupPluginBabelHelpers.js +0 -72
@@ -1,4 +1,3 @@
1
- import { a as _objectWithoutProperties, b as _objectSpread2 } from '../_helpers/_rollupPluginBabelHelpers.js';
2
1
  import { jsx } from 'react/jsx-runtime';
3
2
  import { forwardRef, useMemo, cloneElement } from 'react';
4
3
  import List, { ActiveItemContext } from '../list/list.js';
@@ -7,9 +6,6 @@ import PopupMenu from '../popup-menu/popup-menu.js';
7
6
  import getUID from '../global/get-uid.js';
8
7
  import { A as Anchor } from '../_helpers/anchor.js';
9
8
  import { isArray } from '../global/typescript-utils.js';
10
- import 'core-js/modules/es.symbol.description.js';
11
- import 'core-js/modules/es.string.trim.js';
12
- import 'core-js/modules/web.dom-collections.iterator.js';
13
9
  import 'classnames';
14
10
  import 'react-virtualized/dist/es/List';
15
11
  import 'react-virtualized/dist/es/AutoSizer';
@@ -21,7 +17,6 @@ import '../global/data-tests.js';
21
17
  import '../global/schedule-raf.js';
22
18
  import '../global/memoize.js';
23
19
  import '../global/dom.js';
24
- import 'core-js/modules/es.regexp.exec.js';
25
20
  import '../shortcuts/shortcuts.js';
26
21
  import '../shortcuts/core.js';
27
22
  import 'combokeys';
@@ -31,7 +26,6 @@ import '../global/create-stateful-context.js';
31
26
  import '../list/list-item.js';
32
27
  import '../avatar/avatar.js';
33
28
  import '../global/url.js';
34
- import 'core-js/modules/es.string.replace.js';
35
29
  import '../_helpers/avatar-info.js';
36
30
  import '../avatar/avatar-size.js';
37
31
  import '../avatar/fallback-avatar.js';
@@ -64,112 +58,119 @@ import '../popup/popup.js';
64
58
  import 'react-dom';
65
59
  import '../tab-trap/tab-trap.js';
66
60
  import '../popup/position.js';
67
- import 'core-js/modules/es.array.sort.js';
68
61
  import '../popup/popup.consts.js';
69
62
  import '../popup/popup.target.js';
70
63
  import '../popup/position-css.js';
71
64
 
72
- const _excluded = ["anchor", "pinned", "active", "activeListItemId", "listId"],
73
- _excluded2 = ["id", "anchor", "ariaLabel", "data", "onSelect", "menuProps", "children"],
74
- _excluded3 = ["pinned", "active"];
75
65
  const defaultAriaLabel = 'Dropdown menu';
76
- function DropdownAnchorWrapper(_ref) {
77
- let {
78
- anchor,
79
- pinned,
80
- active,
81
- activeListItemId,
82
- listId
83
- } = _ref,
84
- restProps = _objectWithoutProperties(_ref, _excluded);
85
- const anchorAriaProps = useMemo(() => _objectSpread2(_objectSpread2(_objectSpread2({}, listId ? {
86
- 'aria-haspopup': true
87
- } : {}), activeListItemId ? {
88
- 'aria-activedescendant': activeListItemId,
89
- 'aria-owns': listId
90
- } : {}), active ? {
91
- 'aria-expanded': true
92
- } : {}), [active, activeListItemId, listId]);
93
- const anchorProps = useMemo(() => _objectSpread2(_objectSpread2({
66
+ function DropdownAnchorWrapper({
67
+ anchor,
68
+ pinned,
69
+ active,
70
+ activeListItemId,
71
+ listId,
72
+ ...restProps
73
+ }) {
74
+ const anchorAriaProps = useMemo(() => ({
75
+ ...(listId ? {
76
+ 'aria-haspopup': true
77
+ } : {}),
78
+ ...(activeListItemId ? {
79
+ 'aria-activedescendant': activeListItemId,
80
+ 'aria-owns': listId
81
+ } : {}),
82
+ ...(active ? {
83
+ 'aria-expanded': true
84
+ } : {})
85
+ }), [active, activeListItemId, listId]);
86
+ const anchorProps = useMemo(() => ({
94
87
  active,
95
- pinned
96
- }, restProps), anchorAriaProps), [pinned, active, restProps, anchorAriaProps]);
97
- const anchorComponentProps = useMemo(() => _objectSpread2(_objectSpread2({}, anchorProps), {}, {
98
- pinned: "".concat(anchorProps.pinned)
88
+ pinned,
89
+ ...restProps,
90
+ ...anchorAriaProps
91
+ }), [pinned, active, restProps, anchorAriaProps]);
92
+ const anchorComponentProps = useMemo(() => ({
93
+ ...anchorProps,
94
+ pinned: `${anchorProps.pinned}`
99
95
  }), [anchorProps]);
100
96
  if (typeof anchor === 'string') {
101
- return jsx(Anchor, _objectSpread2(_objectSpread2({}, anchorComponentProps), {}, {
97
+ return jsx(Anchor, {
98
+ ...anchorComponentProps,
102
99
  children: anchor
103
- }));
100
+ });
104
101
  }
105
102
  if (typeof anchor === 'function') {
106
- return anchor(_objectSpread2({
103
+ return anchor({
107
104
  active,
108
- pinned
109
- }, restProps), anchorAriaProps);
105
+ pinned,
106
+ ...restProps
107
+ }, anchorAriaProps);
110
108
  }
111
109
  if (!isArray(anchor)) {
112
110
  return /*#__PURE__*/cloneElement(anchor, typeof anchor.type === 'string' ? anchorAriaProps : anchorComponentProps);
113
111
  }
114
- return jsx("div", _objectSpread2(_objectSpread2({}, anchorAriaProps), {}, {
112
+ return jsx("div", {
113
+ ...anchorAriaProps,
115
114
  children: anchor
116
- }));
115
+ });
117
116
  }
118
- function renderDropdownMenuChildren(_ref2) {
119
- let {
120
- children,
121
- popupMenuProps
122
- } = _ref2;
117
+ function renderDropdownMenuChildren({
118
+ children,
119
+ popupMenuProps
120
+ }) {
123
121
  if (!children) {
124
- return jsx(PopupMenu, _objectSpread2({}, popupMenuProps));
122
+ return jsx(PopupMenu, {
123
+ ...popupMenuProps
124
+ });
125
125
  }
126
- return popupProps => children(_objectSpread2(_objectSpread2({}, popupProps), popupMenuProps));
126
+ return popupProps => children({
127
+ ...popupProps,
128
+ ...popupMenuProps
129
+ });
127
130
  }
128
- const DropdownMenu = /*#__PURE__*/forwardRef(function DropdownMenu(_ref3, forwardedRef) {
129
- let {
130
- id,
131
- anchor,
132
- ariaLabel,
133
- data,
134
- onSelect,
135
- menuProps,
136
- children
137
- } = _ref3,
138
- restDropdownProps = _objectWithoutProperties(_ref3, _excluded2);
131
+ const DropdownMenu = /*#__PURE__*/forwardRef(function DropdownMenu({
132
+ id,
133
+ anchor,
134
+ ariaLabel,
135
+ data,
136
+ onSelect,
137
+ menuProps,
138
+ children,
139
+ ...restDropdownProps
140
+ }, forwardedRef) {
139
141
  const listId = useMemo(() => id || getUID('dropdown-menu-list'), [id]);
140
- const popupMenuProps = useMemo(() => _objectSpread2({
142
+ const popupMenuProps = useMemo(() => ({
141
143
  ref: forwardedRef,
142
144
  id: listId,
143
145
  ariaLabel: ariaLabel || defaultAriaLabel,
144
146
  closeOnSelect: true,
145
147
  activateFirstItem: true,
146
148
  data,
147
- onSelect
148
- }, menuProps), [ariaLabel, data, forwardedRef, listId, menuProps, onSelect]);
149
+ onSelect,
150
+ ...menuProps
151
+ }), [ariaLabel, data, forwardedRef, listId, menuProps, onSelect]);
149
152
  return jsx(ActiveItemContext.Provider, {
150
- children: jsx(Dropdown, _objectSpread2(_objectSpread2({
151
- anchor: _ref4 => {
152
- let {
153
- pinned,
154
- active
155
- } = _ref4,
156
- restAnchorProps = _objectWithoutProperties(_ref4, _excluded3);
157
- return jsx(ActiveItemContext.ValueContext.Consumer, {
158
- children: activeItemId => jsx(DropdownAnchorWrapper, _objectSpread2({
159
- anchor: anchor,
160
- pinned: pinned,
161
- active: active,
162
- activeListItemId: activeItemId,
163
- listId: listId
164
- }, restAnchorProps))
165
- });
166
- }
167
- }, restDropdownProps), {}, {
153
+ children: jsx(Dropdown, {
154
+ anchor: ({
155
+ pinned,
156
+ active,
157
+ ...restAnchorProps
158
+ }) => jsx(ActiveItemContext.ValueContext.Consumer, {
159
+ children: activeItemId => jsx(DropdownAnchorWrapper, {
160
+ anchor: anchor,
161
+ pinned: pinned,
162
+ active: active,
163
+ activeListItemId: activeItemId,
164
+ listId: listId,
165
+ ...restAnchorProps
166
+ })
167
+ }),
168
+ ...restDropdownProps,
168
169
  children: renderDropdownMenuChildren({
169
170
  children,
170
171
  popupMenuProps
171
172
  })
172
- }))
173
+ })
173
174
  });
174
175
  });
175
176
  var DropdownMenu$1 = Object.assign(DropdownMenu, {
@@ -1,6 +1,3 @@
1
- import { a as _objectWithoutProperties, b as _objectSpread2 } from '../_helpers/_rollupPluginBabelHelpers.js';
2
- import 'core-js/modules/es.string.trim.js';
3
- import 'core-js/modules/web.dom-collections.iterator.js';
4
1
  import { jsxs, Fragment, jsx } from 'react/jsx-runtime';
5
2
  import * as React from 'react';
6
3
  import { useCallback, useEffect } from 'react';
@@ -17,8 +14,6 @@ import '@jetbrains/icons/chevron-12px-down';
17
14
  import '../icon/icon.js';
18
15
  import '../icon/icon.constants.js';
19
16
  import '../_helpers/icon-svg.js';
20
- import 'core-js/modules/es.regexp.exec.js';
21
- import 'core-js/modules/es.string.replace.js';
22
17
  import '../global/memoize.js';
23
18
  import '../link/clickable-link.js';
24
19
  import '../global/controls-height.js';
@@ -38,41 +33,40 @@ import 'sniffr';
38
33
 
39
34
  var styles = {"editableHeading":"ring-editable-heading-editableHeading","fullSize":"ring-editable-heading-fullSize","isEditing":"ring-editable-heading-isEditing","headingWrapperButton":"ring-editable-heading-headingWrapperButton","disabled":"ring-editable-heading-disabled","selectionMode":"ring-editable-heading-selectionMode","heading":"ring-editable-heading-heading","multiline":"ring-editable-heading-multiline","input":"ring-editable-heading-input","error":"ring-editable-heading-error","textarea":"ring-editable-heading-textarea","textareaNotOverflow":"ring-editable-heading-textareaNotOverflow","textareaFade":"ring-editable-heading-textareaFade","textareaWrapper":"ring-editable-heading-textareaWrapper","button":"ring-editable-heading-button","errorText":"ring-editable-heading-errorText","level1":"ring-editable-heading-level1","level2":"ring-editable-heading-level2","level3":"ring-editable-heading-level3","sizeS":"ring-editable-heading-sizeS","sizeM":"ring-editable-heading-sizeM","sizeL":"ring-editable-heading-sizeL","sizeFULL":"ring-editable-heading-sizeFULL"};
40
35
 
41
- const _excluded = ["level", "className", "headingClassName", "inputClassName", "children", "isEditing", "isSavingPossible", "isSaving", "embedded", "size", "onEdit", "onSave", "onCancel", "autoFocus", "data-test", "error", "disabled", "multiline", "renderMenu", "onFocus", "onBlur", "onChange", "onScroll", "maxInputRows", "translations"];
42
36
  function noop() {}
43
37
  // eslint-disable-next-line complexity
44
38
  const EditableHeading = props => {
45
39
  const {
46
- level = Levels.H1,
47
- className,
48
- headingClassName,
49
- inputClassName,
50
- children,
51
- isEditing = false,
52
- isSavingPossible = false,
53
- isSaving = false,
54
- embedded = false,
55
- size = Size.L,
56
- onEdit = noop,
57
- onSave = noop,
58
- onCancel = noop,
59
- autoFocus = true,
60
- 'data-test': dataTest,
61
- error,
62
- disabled,
63
- multiline = false,
64
- renderMenu = () => null,
65
- onFocus,
66
- onBlur,
67
- onChange,
68
- onScroll,
69
- maxInputRows,
70
- translations = {
71
- save: 'Save',
72
- cancel: 'Cancel'
73
- }
74
- } = props,
75
- restProps = _objectWithoutProperties(props, _excluded);
40
+ level = Levels.H1,
41
+ className,
42
+ headingClassName,
43
+ inputClassName,
44
+ children,
45
+ isEditing = false,
46
+ isSavingPossible = false,
47
+ isSaving = false,
48
+ embedded = false,
49
+ size = Size.L,
50
+ onEdit = noop,
51
+ onSave = noop,
52
+ onCancel = noop,
53
+ autoFocus = true,
54
+ 'data-test': dataTest,
55
+ error,
56
+ disabled,
57
+ multiline = false,
58
+ renderMenu = () => null,
59
+ onFocus,
60
+ onBlur,
61
+ onChange,
62
+ onScroll,
63
+ maxInputRows,
64
+ translations = {
65
+ save: 'Save',
66
+ cancel: 'Cancel'
67
+ },
68
+ ...restProps
69
+ } = props;
76
70
  const [shortcutsScope] = React.useState(getUID('ring-editable-heading-'));
77
71
  const [isInFocus, setIsInFocus] = React.useState(false);
78
72
  const [isMouseDown, setIsMouseDown] = React.useState(false);
@@ -102,10 +96,10 @@ const EditableHeading = props => {
102
96
  [styles.multiline]: multiline,
103
97
  [styles.selectionMode]: isInSelectionMode
104
98
  });
105
- const headingClasses = classNames(styles.heading, headingClassName, styles["size".concat(size)]);
99
+ const headingClasses = classNames(styles.heading, headingClassName, styles[`size${size}`]);
106
100
  const inputClasses = classNames('ring-js-shortcuts', styles.input, styles.textarea, {
107
101
  [styles.textareaNotOverflow]: !isOverflow
108
- }, inputStyles["size".concat(size)], styles["level".concat(level)], inputClassName);
102
+ }, inputStyles[`size${size}`], styles[`level${level}`], inputClassName);
109
103
  const stretch = useCallback(el => {
110
104
  if (!el || !el.style) {
111
105
  return;
@@ -115,7 +109,7 @@ const EditableHeading = props => {
115
109
  paddingTop,
116
110
  paddingBottom
117
111
  } = window.getComputedStyle(el);
118
- el.style.height = "".concat(el.scrollHeight - parseFloat(paddingTop) - parseFloat(paddingBottom), "px");
112
+ el.style.height = `${el.scrollHeight - parseFloat(paddingTop) - parseFloat(paddingBottom)}px`;
119
113
  }, []);
120
114
  const checkValue = useCallback(el => {
121
115
  if (multiline && el && el.scrollHeight >= el.clientHeight) {
@@ -149,20 +143,20 @@ const EditableHeading = props => {
149
143
  setIsInFocus(true);
150
144
  checkValue(e.target);
151
145
  checkOverflow(e.target);
152
- onFocus === null || onFocus === void 0 || onFocus(e);
146
+ onFocus?.(e);
153
147
  }, [onFocus, checkOverflow, checkValue]);
154
148
  const onInputChange = React.useCallback(e => {
155
149
  checkValue(e.target);
156
150
  checkOverflow(e.target);
157
- onChange === null || onChange === void 0 || onChange(e);
151
+ onChange?.(e);
158
152
  }, [onChange, checkOverflow, checkValue]);
159
153
  const onInputScroll = React.useCallback(e => {
160
154
  checkOverflow(e.target);
161
- onScroll === null || onScroll === void 0 || onScroll(e);
155
+ onScroll?.(e);
162
156
  }, [onScroll, checkOverflow]);
163
157
  const onInputBlur = React.useCallback(e => {
164
158
  setIsInFocus(false);
165
- onBlur === null || onBlur === void 0 || onBlur(e);
159
+ onBlur?.(e);
166
160
  }, [onBlur]);
167
161
  useEffect(() => {
168
162
  window.addEventListener('mousemove', onMouseMove);
@@ -180,34 +174,34 @@ const EditableHeading = props => {
180
174
  map: shortcutsMap,
181
175
  scope: shortcutsScope,
182
176
  disabled: isShortcutsDisabled
183
- }), !multiline ? jsx("input", _objectSpread2(_objectSpread2({
177
+ }), !multiline ? jsx("input", {
184
178
  className: inputClasses,
185
179
  value: children,
186
180
  autoFocus: autoFocus,
187
181
  "data-test": dataTest,
188
182
  disabled: isSaving,
189
- onChange: onChange
190
- }, restProps), {}, {
183
+ onChange: onChange,
184
+ ...restProps,
191
185
  onFocus: onInputFocus,
192
186
  onBlur: onInputBlur
193
- })) : jsxs("div", {
194
- className: classNames(styles.textareaWrapper, inputStyles["size".concat(size)]),
195
- children: [jsx("textarea", _objectSpread2(_objectSpread2({
187
+ }) : jsxs("div", {
188
+ className: classNames(styles.textareaWrapper, inputStyles[`size${size}`]),
189
+ children: [jsx("textarea", {
196
190
  ref: textAreaRef,
197
191
  className: inputClasses,
198
192
  value: children,
199
193
  autoFocus: autoFocus,
200
194
  "data-test": dataTest,
201
195
  disabled: isSaving,
202
- onChange: onInputChange
203
- }, restProps), {}, {
196
+ onChange: onInputChange,
197
+ ...restProps,
204
198
  onFocus: onInputFocus,
205
199
  onBlur: onInputBlur,
206
200
  onScroll: onInputScroll,
207
201
  style: {
208
- maxHeight: maxInputRows ? "".concat(maxInputRows, "lh") : ''
202
+ maxHeight: maxInputRows ? `${maxInputRows}lh` : ''
209
203
  }
210
- })), !isScrolledToBottom && jsx("div", {
204
+ }), !isScrolledToBottom && jsx("div", {
211
205
  className: styles.textareaFade
212
206
  })]
213
207
  })]
@@ -237,7 +231,7 @@ const EditableHeading = props => {
237
231
  })]
238
232
  })]
239
233
  }), isEditing && error && jsx("div", {
240
- className: classNames(styles.errorText, inputStyles["size".concat(size)]),
234
+ className: classNames(styles.errorText, inputStyles[`size${size}`]),
241
235
  children: error
242
236
  })]
243
237
  });
@@ -1,14 +1,14 @@
1
- import { c as _taggedTemplateLiteral } from '../_helpers/_rollupPluginBabelHelpers.js';
2
1
  import figma from '@figma/code-connect';
3
2
 
4
- var _templateObject;
5
3
  const instance = figma.selectedInstance;
6
4
  const error = instance.findLayers(() => true)[0].textContent;
7
5
  const imports = ["import ErrorBubble from '@jetbrains/ring-ui/components/error-bubble/error-bubble'"];
8
- const props = ["error={`".concat(error, "`")];
6
+ const props = [`error={\`${error}\``];
9
7
  var errorBubble_figma = {
10
8
  id: 'error-bubble',
11
- example: figma.code(_templateObject || (_templateObject = _taggedTemplateLiteral(["", "\n\n<ErrorBubble ", "/>"])), imports.join('\n'), props.map(prop => "".concat(prop, " ")).join(''))
9
+ example: figma.code`${imports.join('\n')}
10
+
11
+ <ErrorBubble ${props.map(prop => `${prop} `).join('')}/>`
12
12
  };
13
13
 
14
14
  export { errorBubble_figma as default };
@@ -1,12 +1,8 @@
1
- import { a as _objectWithoutProperties, b as _objectSpread2 } from '../_helpers/_rollupPluginBabelHelpers.js';
2
1
  import { jsxs, jsx } from 'react/jsx-runtime';
3
2
  import { PureComponent, Children, cloneElement } from 'react';
4
3
  import classNames from 'classnames';
5
4
  import Popup from '../popup/popup.js';
6
5
  import { Directions } from '../popup/popup.consts.js';
7
- import 'core-js/modules/es.regexp.exec.js';
8
- import 'core-js/modules/es.string.replace.js';
9
- import 'core-js/modules/web.dom-collections.iterator.js';
10
6
  import 'react-dom';
11
7
  import '../global/get-uid.js';
12
8
  import '../global/schedule-raf.js';
@@ -20,29 +16,29 @@ import '../global/data-tests.js';
20
16
  import '../tab-trap/tab-trap.js';
21
17
  import '../global/configuration.js';
22
18
  import '../popup/position.js';
23
- import 'core-js/modules/es.array.sort.js';
24
19
  import '../popup/popup.target.js';
25
20
  import '../popup/position-css.js';
26
21
 
27
22
  var styles = {"errorBubblePopup":"ring-error-bubble-errorBubblePopup","errorBubbleWrapper":"ring-error-bubble-errorBubbleWrapper","errorBubble":"ring-error-bubble-errorBubble"};
28
23
 
29
- const _excluded = ["children", "className"];
30
24
  /**
31
25
  * @name Error Bubble
32
26
  */
33
27
  class ErrorBubble extends PureComponent {
34
28
  render() {
35
- const _this$props = this.props,
36
- {
37
- children,
38
- className
39
- } = _this$props,
40
- restProps = _objectWithoutProperties(_this$props, _excluded);
29
+ const {
30
+ children,
31
+ className,
32
+ ...restProps
33
+ } = this.props;
41
34
  const errorBubbleClasses = classNames(styles.errorBubble, className);
42
35
  return jsxs("div", {
43
36
  className: styles.errorBubbleWrapper,
44
37
  "data-test": 'ring-error-bubble-wrapper',
45
- children: [children && Children.map(children, child => /*#__PURE__*/cloneElement(child, _objectSpread2(_objectSpread2({}, child.props), restProps))), restProps.error && jsx(Popup, {
38
+ children: [children && Children.map(children, child => /*#__PURE__*/cloneElement(child, {
39
+ ...child.props,
40
+ ...restProps
41
+ })), restProps.error && jsx(Popup, {
46
42
  trapFocus: false,
47
43
  className: styles.errorBubblePopup,
48
44
  hidden: false,
@@ -1,17 +1,12 @@
1
- import 'core-js/modules/es.symbol.description.js';
2
1
  import { jsxs, jsx } from 'react/jsx-runtime';
3
2
  import { Component } from 'react';
4
3
  import classNames from 'classnames';
5
4
  import Icon from '../icon/icon.js';
6
5
  import { Size } from '../icon/icon.constants.js';
7
6
  import joinDataTestAttributes from '../global/data-tests.js';
8
- import '../_helpers/_rollupPluginBabelHelpers.js';
9
7
  import 'util-deprecate';
10
8
  import '../_helpers/icon-svg.js';
11
- import 'core-js/modules/es.regexp.exec.js';
12
- import 'core-js/modules/es.string.replace.js';
13
9
  import '../global/memoize.js';
14
- import 'core-js/modules/web.dom-collections.iterator.js';
15
10
 
16
11
  var styles = {"errorMessage":"ring-error-message-errorMessage","title":"ring-error-message-title","description":"ring-error-message-description","content":"ring-error-message-content","icon":"ring-error-message-icon"};
17
12
 
@@ -43,7 +38,7 @@ class ErrorMessage extends Component {
43
38
  children: [jsxs("div", {
44
39
  className: styles.title,
45
40
  "data-test": 'ring-error-message-title',
46
- children: [code && "".concat(code, ":"), " ", message]
41
+ children: [code && `${code}:`, " ", message]
47
42
  }), description && jsx("div", {
48
43
  className: styles.description,
49
44
  children: description
@@ -2,19 +2,16 @@ import { jsx } from 'react/jsx-runtime';
2
2
  import { memo, isValidElement } from 'react';
3
3
  import classNames from 'classnames';
4
4
  import Link from '../link/link.js';
5
- import '../_helpers/_rollupPluginBabelHelpers.js';
6
5
  import '../global/data-tests.js';
7
- import 'core-js/modules/web.dom-collections.iterator.js';
8
6
  import '../link/clickable-link.js';
9
7
  import '../_helpers/link.js';
10
8
 
11
9
  var styles = {"footer":"ring-footer-footer ring-global-font","footerFloating":"ring-footer-footerFloating ring-footer-footer ring-global-font","column":"ring-footer-column","columnItem":"ring-footer-columnItem","columnLeft":"ring-footer-columnLeft ring-footer-column","columnCenter":"ring-footer-columnCenter ring-footer-column","line":"ring-footer-line","columnRight":"ring-footer-columnRight ring-footer-column","lineCenter":"ring-footer-lineCenter"};
12
10
 
13
- const FooterColumn = /*#__PURE__*/memo(function FooterColumn(_ref) {
14
- let {
15
- position,
16
- children
17
- } = _ref;
11
+ const FooterColumn = /*#__PURE__*/memo(function FooterColumn({
12
+ position,
13
+ children
14
+ }) {
18
15
  const classes = classNames({
19
16
  [styles.columnLeft]: position === 'left',
20
17
  [styles.columnCenter]: position === 'center',
@@ -71,14 +68,13 @@ const FooterLine = /*#__PURE__*/memo(function FooterLine(props) {
71
68
  children: items.map(renderItem)
72
69
  });
73
70
  });
74
- const Footer = /*#__PURE__*/memo(function Footer(_ref2) {
75
- let {
76
- floating,
77
- className,
78
- left,
79
- center,
80
- right
81
- } = _ref2;
71
+ const Footer = /*#__PURE__*/memo(function Footer({
72
+ floating,
73
+ className,
74
+ left,
75
+ center,
76
+ right
77
+ }) {
82
78
  function content(elements, position) {
83
79
  if (!elements) {
84
80
  return false;
@@ -1,9 +1,6 @@
1
1
  import memoizeOne from 'memoize-one';
2
2
 
3
- function composeRefs() {
4
- for (var _len = arguments.length, refs = new Array(_len), _key = 0; _key < _len; _key++) {
5
- refs[_key] = arguments[_key];
6
- }
3
+ function composeRefs(...refs) {
7
4
  return value => refs.forEach(ref => {
8
5
  if (typeof ref === 'function') {
9
6
  ref(value);
@@ -1,7 +1,4 @@
1
- function compose() {
2
- for (var _len = arguments.length, funcs = new Array(_len), _key = 0; _key < _len; _key++) {
3
- funcs[_key] = arguments[_key];
4
- }
1
+ function compose(...funcs) {
5
2
  return funcs.reduce((acc, func) => arg => acc(func(arg)), arg => arg);
6
3
  }
7
4
 
@@ -1,5 +1,3 @@
1
- import { b as _objectSpread2 } from '../_helpers/_rollupPluginBabelHelpers.js';
2
-
3
1
  var ControlsHeight;
4
2
  (function (ControlsHeight) {
5
3
  ControlsHeight["S"] = "S";
@@ -19,7 +17,9 @@ function configure(config) {
19
17
  }
20
18
  }
21
19
  function getConfiguration() {
22
- return _objectSpread2({}, globalConfiguration);
20
+ return {
21
+ ...globalConfiguration
22
+ };
23
23
  }
24
24
 
25
25
  export { ControlsHeight, configure, getConfiguration };
@@ -1,7 +1,6 @@
1
1
  import { createContext } from 'react';
2
2
  import deprecate from 'util-deprecate';
3
3
  import { ControlsHeight, getConfiguration, configure } from './configuration.js';
4
- import '../_helpers/_rollupPluginBabelHelpers.js';
5
4
 
6
5
  // This can be used if React Context is not applicable, for example for alertService or Auth dialog
7
6
  const configureGlobalControlsHeight = deprecate(value => {
@@ -1,15 +1,12 @@
1
- import 'core-js/modules/web.dom-collections.iterator.js';
2
1
  import { jsx } from 'react/jsx-runtime';
3
2
  import { memo, createContext, useState, useContext, useEffect } from 'react';
4
3
 
5
- function createStatefulContext(initialValue) {
6
- let name = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : '';
4
+ function createStatefulContext(initialValue, name = '') {
7
5
  const ValueContext = /*#__PURE__*/createContext(initialValue);
8
6
  const UpdateContext = /*#__PURE__*/createContext(() => {});
9
- function Provider(_ref) {
10
- let {
11
- children
12
- } = _ref;
7
+ function Provider({
8
+ children
9
+ }) {
13
10
  const [value, update] = useState(initialValue);
14
11
  return jsx(ValueContext.Provider, {
15
12
  value: value,
@@ -19,7 +16,7 @@ function createStatefulContext(initialValue) {
19
16
  })
20
17
  });
21
18
  }
22
- Provider.displayName = "".concat(name, "Provider");
19
+ Provider.displayName = `${name}Provider`;
23
20
  function useUpdate(value, skipUpdate) {
24
21
  const update = useContext(UpdateContext);
25
22
  useEffect(() => {
@@ -28,15 +25,14 @@ function createStatefulContext(initialValue) {
28
25
  }
29
26
  }, [update, value, skipUpdate]);
30
27
  }
31
- function Updater(_ref2) {
32
- let {
33
- value,
34
- skipUpdate
35
- } = _ref2;
28
+ function Updater({
29
+ value,
30
+ skipUpdate
31
+ }) {
36
32
  useUpdate(value, skipUpdate);
37
33
  return null;
38
34
  }
39
- Updater.displayName = "".concat(name, "Updater");
35
+ Updater.displayName = `${name}Updater`;
40
36
  return {
41
37
  ValueContext,
42
38
  UpdateContext,