@jetbrains/ring-ui-built 7.0.79 → 7.0.80

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 (57) hide show
  1. package/components/_helpers/theme.js +90 -94
  2. package/components/alert/alert.js +0 -13
  3. package/components/alert-service/alert-service.js +0 -12
  4. package/components/auth/auth-core.js +1 -13
  5. package/components/auth/auth.js +1 -13
  6. package/components/auth/down-notification.js +0 -12
  7. package/components/auth/iframe-flow.js +1 -0
  8. package/components/auth/storage.js +1 -13
  9. package/components/auth-dialog/auth-dialog.js +1 -0
  10. package/components/auth-dialog-service/auth-dialog-service.js +1 -0
  11. package/components/avatar/fallback-avatar.js +78 -79
  12. package/components/avatar-stack/avatar-stack.js +1 -0
  13. package/components/clipboard/clipboard.js +1 -13
  14. package/components/collapse/collapse-content.js +2 -2
  15. package/components/collapse/collapse-control.js +34 -50
  16. package/components/collapse/collapse.js +2 -2
  17. package/components/confirm/confirm.js +1 -0
  18. package/components/confirm-service/confirm-service.js +1 -0
  19. package/components/date-picker/date-picker.js +1 -0
  20. package/components/date-picker/months.js +86 -100
  21. package/components/dialog/dialog.js +1 -0
  22. package/components/dropdown-menu/dropdown-menu.js +154 -238
  23. package/components/editable-heading/editable-heading.js +11 -11
  24. package/components/error-bubble/error-bubble.js +1 -0
  25. package/components/global/theme.d.ts +1 -0
  26. package/components/global/theme.js +0 -17
  27. package/components/global/use-event-callback.js +3 -2
  28. package/components/header/header.js +17 -17
  29. package/components/header/profile.js +1 -0
  30. package/components/header/smart-profile.js +13 -13
  31. package/components/login-dialog/login-dialog.js +1 -0
  32. package/components/login-dialog/service.js +1 -0
  33. package/components/old-browsers-message/white-list.js +2 -2
  34. package/components/pager/pager.js +1 -0
  35. package/components/popup/popup.js +49 -43
  36. package/components/popup-menu/popup-menu.js +1 -0
  37. package/components/query-assist/query-assist.js +1 -0
  38. package/components/select/select-popup.js +1 -0
  39. package/components/select/select.js +1 -0
  40. package/components/slider/slider.js +289 -366
  41. package/components/storage/storage-local.js +1 -13
  42. package/components/storage/storage.js +1 -13
  43. package/components/style.css +1 -1
  44. package/components/tabs/collapsible-more.js +12 -12
  45. package/components/tabs/collapsible-tabs.js +191 -205
  46. package/components/tabs/dumb-tabs.js +1 -0
  47. package/components/tabs/smart-tabs.js +1 -0
  48. package/components/tabs/tabs.js +1 -0
  49. package/components/tags-input/tags-input.js +1 -0
  50. package/components/upload/upload.js +31 -8
  51. package/components/user-agreement/service.js +11 -11
  52. package/components/user-agreement/user-agreement.js +1 -0
  53. package/components/user-card/card.js +5 -5
  54. package/components/user-card/smart-user-card-tooltip.js +1 -1
  55. package/components/user-card/tooltip.js +1 -1
  56. package/components/user-card/user-card.js +8 -8
  57. package/package.json +2 -2
@@ -1,11 +1,7 @@
1
1
  import { c } from 'react-compiler-runtime';
2
- import { createContext, forwardRef, useEffect, useContext, useState } from 'react';
2
+ import { createContext, forwardRef, useEffect, useState } from 'react';
3
3
  import classNames from 'classnames';
4
- import { createPortal } from 'react-dom';
5
- import { PopupTargetContext, PopupTarget } from '../popup/popup.target.js';
6
- import { getPopupContainer } from '../popup/popup.js';
7
- import getUID from '../global/get-uid.js';
8
- import { jsx, jsxs, Fragment } from 'react/jsx-runtime';
4
+ import { jsx } from 'react/jsx-runtime';
9
5
 
10
6
  var defaultStyles = {"light":"ring-variables-light"};
11
7
 
@@ -24,11 +20,11 @@ const GLOBAL_DARK_CLASS_NAME = 'ring-ui-theme-dark';
24
20
  const darkMatcher = window.matchMedia('(prefers-color-scheme: dark)');
25
21
  function useTheme() {
26
22
  const $ = c(3);
27
- if ($[0] !== "420c141f405e041fcedabc175502fba7d82b5112935d96597788965382528620") {
23
+ if ($[0] !== "eabfde84870498e54e35112b5ff33c796334250351dda2073f3913df7a796682") {
28
24
  for (let $i = 0; $i < 3; $i += 1) {
29
25
  $[$i] = Symbol.for("react.memo_cache_sentinel");
30
26
  }
31
- $[0] = "420c141f405e041fcedabc175502fba7d82b5112935d96597788965382528620";
27
+ $[0] = "eabfde84870498e54e35112b5ff33c796334250351dda2073f3913df7a796682";
32
28
  }
33
29
  const [dark, setDark] = useState(darkMatcher.matches);
34
30
  let t0;
@@ -51,11 +47,11 @@ function useTheme() {
51
47
  }
52
48
  function useThemeClasses(theme) {
53
49
  const $ = c(5);
54
- if ($[0] !== "420c141f405e041fcedabc175502fba7d82b5112935d96597788965382528620") {
50
+ if ($[0] !== "eabfde84870498e54e35112b5ff33c796334250351dda2073f3913df7a796682") {
55
51
  for (let $i = 0; $i < 5; $i += 1) {
56
52
  $[$i] = Symbol.for("react.memo_cache_sentinel");
57
53
  }
58
- $[0] = "420c141f405e041fcedabc175502fba7d82b5112935d96597788965382528620";
54
+ $[0] = "eabfde84870498e54e35112b5ff33c796334250351dda2073f3913df7a796682";
59
55
  }
60
56
  const systemTheme = useTheme();
61
57
  const resolvedTheme = theme === Theme.AUTO ? systemTheme : theme;
@@ -80,11 +76,11 @@ function useThemeClasses(theme) {
80
76
  }
81
77
  function WithThemeClasses(t0) {
82
78
  const $ = c(4);
83
- if ($[0] !== "420c141f405e041fcedabc175502fba7d82b5112935d96597788965382528620") {
79
+ if ($[0] !== "eabfde84870498e54e35112b5ff33c796334250351dda2073f3913df7a796682") {
84
80
  for (let $i = 0; $i < 4; $i += 1) {
85
81
  $[$i] = Symbol.for("react.memo_cache_sentinel");
86
82
  }
87
- $[0] = "420c141f405e041fcedabc175502fba7d82b5112935d96597788965382528620";
83
+ $[0] = "eabfde84870498e54e35112b5ff33c796334250351dda2073f3913df7a796682";
88
84
  }
89
85
  const {
90
86
  theme,
@@ -115,11 +111,11 @@ function applyTheme(theme, container) {
115
111
  }
116
112
  const DefaultWrapper = /*#__PURE__*/forwardRef(function Wrapper(props, ref) {
117
113
  const $ = c(4);
118
- if ($[0] !== "420c141f405e041fcedabc175502fba7d82b5112935d96597788965382528620") {
114
+ if ($[0] !== "eabfde84870498e54e35112b5ff33c796334250351dda2073f3913df7a796682") {
119
115
  for (let $i = 0; $i < 4; $i += 1) {
120
116
  $[$i] = Symbol.for("react.memo_cache_sentinel");
121
117
  }
122
- $[0] = "420c141f405e041fcedabc175502fba7d82b5112935d96597788965382528620";
118
+ $[0] = "eabfde84870498e54e35112b5ff33c796334250351dda2073f3913df7a796682";
123
119
  }
124
120
  let t0;
125
121
  if ($[1] !== props || $[2] !== ref) {
@@ -135,13 +131,13 @@ const DefaultWrapper = /*#__PURE__*/forwardRef(function Wrapper(props, ref) {
135
131
  }
136
132
  return t0;
137
133
  });
138
- const ThemeProvider = /*#__PURE__*/forwardRef(function ThemeProvider(t0, ref) {
139
- const $ = c(34);
140
- if ($[0] !== "420c141f405e041fcedabc175502fba7d82b5112935d96597788965382528620") {
141
- for (let $i = 0; $i < 34; $i += 1) {
134
+ function ThemeProviderInner(t0) {
135
+ const $ = c(30);
136
+ if ($[0] !== "eabfde84870498e54e35112b5ff33c796334250351dda2073f3913df7a796682") {
137
+ for (let $i = 0; $i < 30; $i += 1) {
142
138
  $[$i] = Symbol.for("react.memo_cache_sentinel");
143
139
  }
144
- $[0] = "420c141f405e041fcedabc175502fba7d82b5112935d96597788965382528620";
140
+ $[0] = "eabfde84870498e54e35112b5ff33c796334250351dda2073f3913df7a796682";
145
141
  }
146
142
  let children;
147
143
  let className;
@@ -150,6 +146,7 @@ const ThemeProvider = /*#__PURE__*/forwardRef(function ThemeProvider(t0, ref) {
150
146
  let t1;
151
147
  let t2;
152
148
  let target;
149
+ let wrapperRef;
153
150
  if ($[1] !== t0) {
154
151
  ({
155
152
  theme: t1,
@@ -158,6 +155,7 @@ const ThemeProvider = /*#__PURE__*/forwardRef(function ThemeProvider(t0, ref) {
158
155
  children,
159
156
  WrapperComponent: t2,
160
157
  target,
158
+ wrapperRef,
161
159
  ...restProps
162
160
  } = t0);
163
161
  $[1] = t0;
@@ -168,6 +166,7 @@ const ThemeProvider = /*#__PURE__*/forwardRef(function ThemeProvider(t0, ref) {
168
166
  $[6] = t1;
169
167
  $[7] = t2;
170
168
  $[8] = target;
169
+ $[9] = wrapperRef;
171
170
  } else {
172
171
  children = $[2];
173
172
  className = $[3];
@@ -176,109 +175,106 @@ const ThemeProvider = /*#__PURE__*/forwardRef(function ThemeProvider(t0, ref) {
176
175
  t1 = $[6];
177
176
  t2 = $[7];
178
177
  target = $[8];
178
+ wrapperRef = $[9];
179
179
  }
180
180
  const theme = t1 === undefined ? Theme.AUTO : t1;
181
181
  const WrapperComponent = t2 === undefined ? DefaultWrapper : t2;
182
182
  const systemTheme = useTheme();
183
183
  const resolvedTheme = theme === Theme.AUTO ? systemTheme : theme;
184
184
  let t3;
185
- if ($[9] === Symbol.for("react.memo_cache_sentinel")) {
186
- t3 = getUID("popups-with-theme-");
187
- $[9] = t3;
188
- } else {
189
- t3 = $[9];
190
- }
191
- const id = t3;
192
- let t4;
193
- if ($[10] !== resolvedTheme) {
194
- t4 = {
195
- theme: resolvedTheme
185
+ if ($[10] !== passToPopups || $[11] !== resolvedTheme) {
186
+ t3 = {
187
+ theme: resolvedTheme,
188
+ passToPopups
196
189
  };
197
- $[10] = resolvedTheme;
198
- $[11] = t4;
190
+ $[10] = passToPopups;
191
+ $[11] = resolvedTheme;
192
+ $[12] = t3;
199
193
  } else {
200
- t4 = $[11];
194
+ t3 = $[12];
201
195
  }
202
- const themeValue = t4;
196
+ const themeValue = t3;
197
+ let t4;
203
198
  let t5;
204
- let t6;
205
- if ($[12] !== resolvedTheme || $[13] !== target) {
206
- t5 = () => {
199
+ if ($[13] !== resolvedTheme || $[14] !== target) {
200
+ t4 = () => {
207
201
  if (target) {
208
202
  applyTheme(resolvedTheme, target);
209
203
  }
210
204
  };
211
- t6 = [resolvedTheme, target];
212
- $[12] = resolvedTheme;
213
- $[13] = target;
214
- $[14] = t5;
215
- $[15] = t6;
205
+ t5 = [resolvedTheme, target];
206
+ $[13] = resolvedTheme;
207
+ $[14] = target;
208
+ $[15] = t4;
209
+ $[16] = t5;
216
210
  } else {
217
- t5 = $[14];
218
- t6 = $[15];
211
+ t4 = $[15];
212
+ t5 = $[16];
219
213
  }
220
- useEffect(t5, t6);
214
+ useEffect(t4, t5);
221
215
  const themeClasses = useThemeClasses(theme);
222
- const parentTarget = useContext(PopupTargetContext);
223
- let t7;
224
- if ($[16] !== className || $[17] !== target || $[18] !== themeClasses) {
225
- t7 = target ? undefined : classNames(className, themeClasses);
226
- $[16] = className;
227
- $[17] = target;
228
- $[18] = themeClasses;
229
- $[19] = t7;
216
+ let t6;
217
+ if ($[17] !== className || $[18] !== target || $[19] !== themeClasses) {
218
+ t6 = target ? undefined : classNames(className, themeClasses);
219
+ $[17] = className;
220
+ $[18] = target;
221
+ $[19] = themeClasses;
222
+ $[20] = t6;
230
223
  } else {
231
- t7 = $[19];
224
+ t6 = $[20];
232
225
  }
233
- let t8;
234
- if ($[20] !== children || $[21] !== parentTarget || $[22] !== passToPopups || $[23] !== themeClasses) {
235
- t8 = passToPopups ? /*#__PURE__*/jsx(PopupTarget, {
236
- id: id,
237
- children: popupTarget => /*#__PURE__*/jsxs(Fragment, {
238
- children: [children, /*#__PURE__*/createPortal(/*#__PURE__*/jsx("div", {
239
- className: themeClasses,
240
- children: popupTarget
241
- }), parentTarget && getPopupContainer(parentTarget) || document.body)]
242
- })
243
- }) : children;
244
- $[20] = children;
245
- $[21] = parentTarget;
246
- $[22] = passToPopups;
247
- $[23] = themeClasses;
248
- $[24] = t8;
226
+ let t7;
227
+ if ($[21] !== WrapperComponent || $[22] !== children || $[23] !== restProps || $[24] !== t6 || $[25] !== wrapperRef) {
228
+ t7 = /*#__PURE__*/jsx(WrapperComponent, {
229
+ ref: wrapperRef,
230
+ className: t6,
231
+ ...restProps,
232
+ children: children
233
+ });
234
+ $[21] = WrapperComponent;
235
+ $[22] = children;
236
+ $[23] = restProps;
237
+ $[24] = t6;
238
+ $[25] = wrapperRef;
239
+ $[26] = t7;
249
240
  } else {
250
- t8 = $[24];
241
+ t7 = $[26];
251
242
  }
252
- let t9;
253
- if ($[25] !== WrapperComponent || $[26] !== ref || $[27] !== restProps || $[28] !== t7 || $[29] !== t8) {
254
- t9 = /*#__PURE__*/jsx(WrapperComponent, {
255
- ref: ref,
256
- className: t7,
257
- ...restProps,
258
- children: t8
243
+ let t8;
244
+ if ($[27] !== t7 || $[28] !== themeValue) {
245
+ t8 = /*#__PURE__*/jsx(ThemeContext.Provider, {
246
+ value: themeValue,
247
+ children: t7
259
248
  });
260
- $[25] = WrapperComponent;
261
- $[26] = ref;
262
- $[27] = restProps;
263
- $[28] = t7;
249
+ $[27] = t7;
250
+ $[28] = themeValue;
264
251
  $[29] = t8;
265
- $[30] = t9;
266
252
  } else {
267
- t9 = $[30];
253
+ t8 = $[29];
268
254
  }
269
- let t10;
270
- if ($[31] !== t9 || $[32] !== themeValue) {
271
- t10 = /*#__PURE__*/jsx(ThemeContext.Provider, {
272
- value: themeValue,
273
- children: t9
255
+ return t8;
256
+ }
257
+ const ThemeProvider = /*#__PURE__*/forwardRef(function ThemeProvider(props, ref) {
258
+ const $ = c(4);
259
+ if ($[0] !== "eabfde84870498e54e35112b5ff33c796334250351dda2073f3913df7a796682") {
260
+ for (let $i = 0; $i < 4; $i += 1) {
261
+ $[$i] = Symbol.for("react.memo_cache_sentinel");
262
+ }
263
+ $[0] = "eabfde84870498e54e35112b5ff33c796334250351dda2073f3913df7a796682";
264
+ }
265
+ let t0;
266
+ if ($[1] !== props || $[2] !== ref) {
267
+ t0 = /*#__PURE__*/jsx(ThemeProviderInner, {
268
+ ...props,
269
+ wrapperRef: ref
274
270
  });
275
- $[31] = t9;
276
- $[32] = themeValue;
277
- $[33] = t10;
271
+ $[1] = props;
272
+ $[2] = ref;
273
+ $[3] = t0;
278
274
  } else {
279
- t10 = $[33];
275
+ t0 = $[3];
280
276
  }
281
- return t10;
277
+ return t0;
282
278
  });
283
279
  var Theme$1 = Theme;
284
280
 
@@ -24,19 +24,6 @@ import '../global/controls-height.js';
24
24
  import '../global/configuration.js';
25
25
  import '../_helpers/button.classes.js';
26
26
  import 'react-dom';
27
- import '../popup/popup.target.js';
28
- import '../popup/popup.js';
29
- import '../global/get-uid.js';
30
- import '../global/schedule-raf.js';
31
- import '../shortcuts/shortcuts.js';
32
- import '../shortcuts/core.js';
33
- import 'combokeys';
34
- import '../global/sniffer.js';
35
- import 'sniffr';
36
- import '../tab-trap/tab-trap.js';
37
- import '../popup/position.js';
38
- import '../popup/popup.consts.js';
39
- import '../popup/position-css.js';
40
27
 
41
28
  var styles = {"alert":"ring-alert-alert","alertInline":"ring-alert-alertInline","error":"ring-alert-error","icon":"ring-alert-icon","caption":"ring-alert-caption","withCloseButton":"ring-alert-withCloseButton","badge":"ring-alert-badge","loader":"ring-alert-loader","close":"ring-alert-close","animationOpen":"ring-alert-animationOpen","show":"ring-alert-show","animationClosing":"ring-alert-animationClosing","animationShaking":"ring-alert-animationShaking","shaking":"ring-alert-shaking"};
42
29
 
@@ -27,18 +27,6 @@ import '../global/configuration.js';
27
27
  import '../_helpers/button.classes.js';
28
28
  import '../_helpers/theme.js';
29
29
  import 'react-dom';
30
- import '../popup/popup.target.js';
31
- import '../popup/popup.js';
32
- import '../global/schedule-raf.js';
33
- import '../shortcuts/shortcuts.js';
34
- import '../shortcuts/core.js';
35
- import 'combokeys';
36
- import '../global/sniffer.js';
37
- import 'sniffr';
38
- import '../tab-trap/tab-trap.js';
39
- import '../popup/position.js';
40
- import '../popup/popup.consts.js';
41
- import '../popup/position-css.js';
42
30
 
43
31
  const DEFAULT_ALERT_TIMEOUT = 10000; // 10 seconds
44
32
  /**
@@ -37,20 +37,8 @@ import '../global/controls-height.js';
37
37
  import '../global/configuration.js';
38
38
  import '../_helpers/button.classes.js';
39
39
  import '../_helpers/theme.js';
40
- import 'react-dom';
41
- import '../popup/popup.target.js';
42
- import '../popup/popup.js';
43
- import '../global/schedule-raf.js';
44
- import '../shortcuts/shortcuts.js';
45
- import '../shortcuts/core.js';
46
- import 'combokeys';
47
- import '../global/sniffer.js';
48
- import 'sniffr';
49
- import '../tab-trap/tab-trap.js';
50
- import '../popup/position.js';
51
- import '../popup/popup.consts.js';
52
- import '../popup/position-css.js';
53
40
  import '../alert/container.js';
41
+ import 'react-dom';
54
42
  import 'simply-uuid';
55
43
 
56
44
  /* eslint-disable no-magic-numbers */
@@ -32,20 +32,8 @@ import '../global/controls-height.js';
32
32
  import '../global/configuration.js';
33
33
  import '../_helpers/button.classes.js';
34
34
  import '../_helpers/theme.js';
35
- import 'react-dom';
36
- import '../popup/popup.target.js';
37
- import '../popup/popup.js';
38
- import '../global/schedule-raf.js';
39
- import '../shortcuts/shortcuts.js';
40
- import '../shortcuts/core.js';
41
- import 'combokeys';
42
- import '../global/sniffer.js';
43
- import 'sniffr';
44
- import '../tab-trap/tab-trap.js';
45
- import '../popup/position.js';
46
- import '../popup/popup.consts.js';
47
- import '../popup/position-css.js';
48
35
  import '../alert/container.js';
36
+ import 'react-dom';
49
37
  import '../link/link.js';
50
38
  import '../_helpers/link.js';
51
39
  import '../group/group.js';
@@ -30,18 +30,6 @@ import '../global/controls-height.js';
30
30
  import '../global/configuration.js';
31
31
  import '../_helpers/button.classes.js';
32
32
  import '../_helpers/theme.js';
33
- import '../popup/popup.target.js';
34
- import '../popup/popup.js';
35
- import '../global/schedule-raf.js';
36
- import '../shortcuts/shortcuts.js';
37
- import '../shortcuts/core.js';
38
- import 'combokeys';
39
- import '../global/sniffer.js';
40
- import 'sniffr';
41
- import '../tab-trap/tab-trap.js';
42
- import '../popup/position.js';
43
- import '../popup/popup.consts.js';
44
- import '../popup/position-css.js';
45
33
  import '../_helpers/link.js';
46
34
 
47
35
  var styles = {"title":"ring-down-notification-title","error":"ring-down-notification-error"};
@@ -44,6 +44,7 @@ import '../popup/popup.js';
44
44
  import '../popup/position.js';
45
45
  import '../popup/popup.consts.js';
46
46
  import '../popup/position-css.js';
47
+ import '../_helpers/theme.js';
47
48
  import '../_helpers/dialog-body-scroll-preventer.js';
48
49
  import 'scrollbar-width';
49
50
  import '../loader-screen/loader-screen.js';
@@ -27,20 +27,8 @@ import '../global/controls-height.js';
27
27
  import '../global/configuration.js';
28
28
  import '../_helpers/button.classes.js';
29
29
  import '../_helpers/theme.js';
30
- import 'react-dom';
31
- import '../popup/popup.target.js';
32
- import '../popup/popup.js';
33
- import '../global/schedule-raf.js';
34
- import '../shortcuts/shortcuts.js';
35
- import '../shortcuts/core.js';
36
- import 'combokeys';
37
- import '../global/sniffer.js';
38
- import 'sniffr';
39
- import '../tab-trap/tab-trap.js';
40
- import '../popup/position.js';
41
- import '../popup/popup.consts.js';
42
- import '../popup/position-css.js';
43
30
  import '../alert/container.js';
31
+ import 'react-dom';
44
32
 
45
33
  /**
46
34
  * @typedef {Object} StoredToken
@@ -30,6 +30,7 @@ import '../global/configuration.js';
30
30
  import '../popup/position.js';
31
31
  import '../popup/popup.consts.js';
32
32
  import '../popup/position-css.js';
33
+ import '../_helpers/theme.js';
33
34
  import '../_helpers/dialog-body-scroll-preventer.js';
34
35
  import 'scrollbar-width';
35
36
  import '@jetbrains/icons/chevron-down';
@@ -41,6 +41,7 @@ import '../popup/popup.js';
41
41
  import '../popup/position.js';
42
42
  import '../popup/popup.consts.js';
43
43
  import '../popup/position-css.js';
44
+ import '../_helpers/theme.js';
44
45
  import '../_helpers/dialog-body-scroll-preventer.js';
45
46
  import 'scrollbar-width';
46
47
  import '../heading/heading.js';