@jetbrains/ring-ui-built 7.0.72 → 7.0.73
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.
- package/components/_helpers/anchor.js +55 -13
- package/components/_helpers/avatar-info.js +44 -11
- package/components/_helpers/caption.js +2 -2
- package/components/_helpers/card.js +21 -21
- package/components/_helpers/icon-svg.js +75 -17
- package/components/_helpers/input.js +13 -13
- package/components/_helpers/query-assist-suggestions.js +5 -5
- package/components/_helpers/select-filter.js +5 -5
- package/components/_helpers/services-link.js +5 -5
- package/components/_helpers/sidebar.js +6 -6
- package/components/_helpers/tab-link.js +69 -17
- package/components/_helpers/theme.js +231 -54
- package/components/_helpers/title.js +5 -5
- package/components/alert/alert.d.ts +1 -1
- package/components/alert/alert.js +12 -10
- package/components/alert/container.js +4 -4
- package/components/alert-service/alert-service.d.ts +1 -1
- package/components/alert-service/alert-service.js +5 -4
- package/components/auth/auth-core.js +8 -8
- package/components/auth/auth.js +3 -2
- package/components/auth/down-notification.js +61 -17
- package/components/auth/iframe-flow.js +7 -6
- package/components/auth/storage.js +3 -2
- package/components/auth/token-validator.js +1 -1
- package/components/auth/window-flow.js +2 -2
- package/components/auth-dialog/auth-dialog.d.ts +1 -1
- package/components/auth-dialog/auth-dialog.js +15 -14
- package/components/auth-dialog-service/auth-dialog-service.js +4 -6
- package/components/avatar/avatar-info.d.ts +1 -1
- package/components/avatar/avatar-info.js +3 -2
- package/components/avatar/avatar.d.ts +1 -1
- package/components/avatar/avatar.js +16 -15
- package/components/avatar/fallback-avatar.d.ts +1 -1
- package/components/avatar/fallback-avatar.js +183 -59
- package/components/avatar-stack/avatar-stack.d.ts +1 -1
- package/components/avatar-stack/avatar-stack.js +115 -29
- package/components/banner/banner.d.ts +1 -1
- package/components/banner/banner.js +11 -10
- package/components/breadcrumbs/breadcrumbs.d.ts +1 -1
- package/components/breadcrumbs/breadcrumbs.js +3 -2
- package/components/button/button.d.ts +1 -1
- package/components/button/button.js +11 -10
- package/components/button-group/button-group.d.ts +1 -1
- package/components/button-group/button-group.js +6 -8
- package/components/button-group/caption.d.ts +1 -1
- package/components/button-group/caption.js +1 -1
- package/components/button-set/button-set.d.ts +1 -1
- package/components/button-set/button-set.js +2 -5
- package/components/button-toolbar/button-toolbar.d.ts +1 -1
- package/components/button-toolbar/button-toolbar.js +2 -5
- package/components/checkbox/checkbox.d.ts +1 -1
- package/components/checkbox/checkbox.js +12 -17
- package/components/clipboard/clipboard.js +2 -1
- package/components/code/code.d.ts +1 -1
- package/components/code/code.js +5 -5
- package/components/collapse/collapse-content.js +161 -77
- package/components/collapse/collapse-control.js +69 -22
- package/components/collapse/collapse.js +83 -31
- package/components/confirm/confirm.d.ts +1 -1
- package/components/confirm/confirm.js +11 -13
- package/components/confirm-service/confirm-service.js +4 -3
- package/components/content-layout/content-layout.d.ts +1 -1
- package/components/content-layout/content-layout.js +4 -7
- package/components/content-layout/sidebar.d.ts +1 -1
- package/components/content-layout/sidebar.js +1 -1
- package/components/contenteditable/contenteditable.d.ts +2 -2
- package/components/contenteditable/contenteditable.js +50 -14
- package/components/control-help/control-help.d.ts +1 -1
- package/components/control-help/control-help.js +45 -9
- package/components/control-label/control-label.js +62 -13
- package/components/data-list/data-list.d.ts +1 -1
- package/components/data-list/data-list.js +10 -9
- package/components/data-list/data-list.mock.d.ts +1 -1
- package/components/data-list/data-list.mock.js +79 -78
- package/components/data-list/item.d.ts +2 -2
- package/components/data-list/item.js +18 -17
- package/components/data-list/title.d.ts +1 -1
- package/components/data-list/title.js +2 -1
- package/components/date-picker/consts.js +1 -1
- package/components/date-picker/date-input.d.ts +1 -1
- package/components/date-picker/date-input.js +4 -3
- package/components/date-picker/date-picker.d.ts +1 -1
- package/components/date-picker/date-picker.js +97 -31
- package/components/date-picker/date-popup.d.ts +1 -1
- package/components/date-picker/date-popup.js +11 -10
- package/components/date-picker/day.d.ts +1 -1
- package/components/date-picker/day.js +4 -3
- package/components/date-picker/month-names.d.ts +1 -1
- package/components/date-picker/month-names.js +98 -22
- package/components/date-picker/month-slider.d.ts +1 -1
- package/components/date-picker/month-slider.js +4 -4
- package/components/date-picker/month.d.ts +1 -1
- package/components/date-picker/month.js +79 -18
- package/components/date-picker/months.d.ts +1 -1
- package/components/date-picker/months.js +163 -53
- package/components/date-picker/weekdays.d.ts +1 -1
- package/components/date-picker/weekdays.js +56 -16
- package/components/date-picker/years.d.ts +1 -1
- package/components/date-picker/years.js +5 -5
- package/components/dialog/dialog.d.ts +1 -1
- package/components/dialog/dialog.js +21 -23
- package/components/dropdown/anchor.d.ts +1 -1
- package/components/dropdown/anchor.js +2 -1
- package/components/dropdown/dropdown.d.ts +1 -1
- package/components/dropdown/dropdown.js +7 -8
- package/components/dropdown-menu/dropdown-menu.js +299 -83
- package/components/editable-heading/editable-heading.d.ts +2 -2
- package/components/editable-heading/editable-heading.js +523 -174
- package/components/error-bubble/error-bubble.d.ts +1 -1
- package/components/error-bubble/error-bubble.js +7 -9
- package/components/error-message/error-message.d.ts +1 -1
- package/components/error-message/error-message.js +8 -10
- package/components/footer/footer.js +205 -61
- package/components/global/create-stateful-context.d.ts +1 -1
- package/components/global/create-stateful-context.js +73 -18
- package/components/global/focus-sensor-hoc.js +2 -2
- package/components/global/get-uid.js +1 -1
- package/components/global/react-dom-renderer.d.ts +1 -1
- package/components/global/react-dom-renderer.js +2 -2
- package/components/global/rerender-hoc.js +23 -6
- package/components/global/theme.js +3 -2
- package/components/global/use-event-callback.js +37 -13
- package/components/grid/col.d.ts +1 -1
- package/components/grid/col.js +3 -3
- package/components/grid/grid.d.ts +1 -1
- package/components/grid/grid.js +3 -6
- package/components/grid/row.d.ts +1 -1
- package/components/grid/row.js +3 -3
- package/components/group/group.d.ts +1 -1
- package/components/group/group.js +3 -6
- package/components/header/header-icon.d.ts +1 -1
- package/components/header/header-icon.js +3 -2
- package/components/header/header.d.ts +1 -1
- package/components/header/header.js +7 -12
- package/components/header/links.d.ts +1 -1
- package/components/header/links.js +45 -10
- package/components/header/logo.d.ts +1 -1
- package/components/header/logo.js +4 -3
- package/components/header/profile.js +17 -16
- package/components/header/services-link.d.ts +1 -1
- package/components/header/services-link.js +1 -1
- package/components/header/services.d.ts +1 -1
- package/components/header/services.js +35 -16
- package/components/header/smart-profile.d.ts +1 -1
- package/components/header/smart-profile.js +6 -5
- package/components/header/smart-services.d.ts +1 -1
- package/components/header/smart-services.js +3 -2
- package/components/header/tray.d.ts +1 -1
- package/components/header/tray.js +3 -3
- package/components/heading/heading.js +188 -44
- package/components/i18n/i18n-context.js +51 -13
- package/components/icon/icon-svg.d.ts +1 -1
- package/components/icon/icon-svg.js +2 -1
- package/components/icon/icon.d.ts +1 -1
- package/components/icon/icon.js +6 -5
- package/components/icon/index.js +2 -1
- package/components/input/input.d.ts +1 -1
- package/components/input/input.js +2 -1
- package/components/island/adaptive-island-hoc.js +4 -4
- package/components/island/content.d.ts +1 -1
- package/components/island/content.js +36 -17
- package/components/island/header.d.ts +1 -1
- package/components/island/header.js +32 -14
- package/components/island/island.d.ts +1 -1
- package/components/island/island.js +3 -5
- package/components/link/clickable-link.d.ts +1 -1
- package/components/link/clickable-link.js +2 -2
- package/components/link/link.js +4 -4
- package/components/list/list-custom.d.ts +1 -1
- package/components/list/list-custom.js +2 -2
- package/components/list/list-hint.d.ts +1 -1
- package/components/list/list-hint.js +3 -7
- package/components/list/list-item.d.ts +1 -1
- package/components/list/list-item.js +23 -26
- package/components/list/list-separator.d.ts +1 -1
- package/components/list/list-separator.js +3 -3
- package/components/list/list-title.d.ts +1 -1
- package/components/list/list-title.js +7 -7
- package/components/list/list-users-groups-source.js +6 -5
- package/components/list/list.d.ts +6 -6
- package/components/list/list.js +33 -31
- package/components/loader/loader.d.ts +1 -1
- package/components/loader/loader.js +8 -14
- package/components/loader-inline/loader-inline.d.ts +1 -1
- package/components/loader-inline/loader-inline.js +4 -7
- package/components/loader-screen/loader-screen.d.ts +1 -1
- package/components/loader-screen/loader-screen.js +3 -6
- package/components/login-dialog/login-dialog.d.ts +1 -1
- package/components/login-dialog/login-dialog.js +10 -9
- package/components/login-dialog/service.js +4 -3
- package/components/markdown/markdown.d.ts +1 -1
- package/components/markdown/markdown.js +3 -6
- package/components/message/message.d.ts +1 -1
- package/components/message/message.js +13 -15
- package/components/old-browsers-message/white-list.js +2 -2
- package/components/pager/pager.d.ts +5 -5
- package/components/pager/pager.js +28 -27
- package/components/panel/panel.d.ts +1 -1
- package/components/panel/panel.js +3 -6
- package/components/popup/popup.d.ts +2 -2
- package/components/popup/popup.js +14 -11
- package/components/popup/popup.target.js +68 -16
- package/components/popup-menu/popup-menu.d.ts +1 -1
- package/components/popup-menu/popup-menu.js +7 -9
- package/components/progress-bar/progress-bar.d.ts +1 -1
- package/components/progress-bar/progress-bar.js +4 -7
- package/components/query-assist/query-assist-suggestions.d.ts +1 -1
- package/components/query-assist/query-assist-suggestions.js +5 -4
- package/components/query-assist/query-assist.d.ts +2 -2
- package/components/query-assist/query-assist.js +37 -34
- package/components/radio/radio-item.d.ts +1 -1
- package/components/radio/radio-item.js +40 -20
- package/components/radio/radio.d.ts +1 -1
- package/components/radio/radio.js +3 -5
- package/components/scrollable-section/scrollable-section.d.ts +1 -1
- package/components/scrollable-section/scrollable-section.js +100 -38
- package/components/select/select-filter.d.ts +1 -1
- package/components/select/select-filter.js +5 -4
- package/components/select/select-popup.d.ts +7 -7
- package/components/select/select-popup.js +26 -25
- package/components/select/select.d.ts +3 -3
- package/components/select/select.js +52 -52
- package/components/shortcuts/shortcuts-hoc.js +3 -3
- package/components/slider/slider.js +591 -196
- package/components/storage/storage-local.js +2 -1
- package/components/storage/storage.js +2 -1
- package/components/style.css +1 -1
- package/components/tab-trap/tab-trap.js +247 -102
- package/components/table/cell.d.ts +1 -1
- package/components/table/cell.js +2 -2
- package/components/table/disable-hover-hoc.js +3 -3
- package/components/table/header-cell.d.ts +1 -1
- package/components/table/header-cell.js +7 -6
- package/components/table/header.d.ts +2 -2
- package/components/table/header.js +14 -13
- package/components/table/multitable.d.ts +1 -1
- package/components/table/multitable.js +3 -3
- package/components/table/row-with-focus-sensor.d.ts +1 -1
- package/components/table/row-with-focus-sensor.js +3 -2
- package/components/table/row.d.ts +1 -1
- package/components/table/row.js +51 -24
- package/components/table/selection-shortcuts-hoc.js +2 -2
- package/components/table/simple-table.d.ts +1 -1
- package/components/table/simple-table.js +4 -3
- package/components/table/smart-table.d.ts +1 -1
- package/components/table/smart-table.js +4 -3
- package/components/table/table.d.ts +2 -2
- package/components/table/table.js +21 -23
- package/components/tabs/collapsible-more.d.ts +3 -3
- package/components/tabs/collapsible-more.js +253 -83
- package/components/tabs/collapsible-tab.d.ts +1 -1
- package/components/tabs/collapsible-tab.js +4 -3
- package/components/tabs/collapsible-tabs.d.ts +2 -2
- package/components/tabs/collapsible-tabs.js +450 -188
- package/components/tabs/dumb-tabs.d.ts +2 -2
- package/components/tabs/dumb-tabs.js +10 -9
- package/components/tabs/smart-tabs.d.ts +1 -1
- package/components/tabs/smart-tabs.js +6 -5
- package/components/tabs/tab-link.d.ts +1 -1
- package/components/tabs/tab-link.js +2 -1
- package/components/tabs/tab.d.ts +1 -1
- package/components/tabs/tab.js +2 -2
- package/components/tabs/tabs.js +5 -4
- package/components/tag/tag.d.ts +5 -5
- package/components/tag/tag.js +14 -13
- package/components/tags-input/tags-input.d.ts +1 -1
- package/components/tags-input/tags-input.js +10 -9
- package/components/tags-list/tags-list.d.ts +2 -2
- package/components/tags-list/tags-list.js +4 -3
- package/components/text/text.d.ts +1 -1
- package/components/text/text.js +2 -2
- package/components/toggle/toggle.d.ts +1 -1
- package/components/toggle/toggle.js +12 -11
- package/components/tooltip/tooltip.d.ts +1 -1
- package/components/tooltip/tooltip.js +7 -6
- package/components/upload/upload.js +10 -9
- package/components/user-agreement/service.js +11 -10
- package/components/user-agreement/user-agreement.d.ts +1 -1
- package/components/user-agreement/user-agreement.js +19 -18
- package/components/user-card/card.d.ts +1 -1
- package/components/user-card/card.js +3 -2
- package/components/user-card/smart-user-card-tooltip.d.ts +2 -2
- package/components/user-card/smart-user-card-tooltip.js +7 -6
- package/components/user-card/tooltip.d.ts +2 -2
- package/components/user-card/tooltip.js +7 -6
- package/components/user-card/user-card.js +4 -3
- package/package.json +3 -9
|
@@ -1,10 +1,11 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { useRef, useState,
|
|
1
|
+
import { c } from 'react-compiler-runtime';
|
|
2
|
+
import { useRef, useState, useEffect, Fragment } from 'react';
|
|
3
3
|
import classNames from 'classnames';
|
|
4
4
|
import { isArray } from '../global/typescript-utils.js';
|
|
5
5
|
import Shortcuts from '../shortcuts/shortcuts.js';
|
|
6
6
|
import getUID from '../global/get-uid.js';
|
|
7
|
-
import { toRange, HUNDRED,
|
|
7
|
+
import { toRange, HUNDRED, calculateMarks, toPercent, validateValue, calculateValue, adjustValues } from './slider.utils.js';
|
|
8
|
+
import { jsx, jsxs } from 'react/jsx-runtime';
|
|
8
9
|
import '../shortcuts/core.js';
|
|
9
10
|
import 'combokeys';
|
|
10
11
|
import '../global/sniffer.js';
|
|
@@ -12,239 +13,633 @@ import 'sniffr';
|
|
|
12
13
|
|
|
13
14
|
var styles = {"slider":"ring-slider-slider","disabled":"ring-slider-disabled","marked":"ring-slider-marked","rail":"ring-slider-rail","rounded":"ring-slider-rounded","track":"ring-slider-track","thumb":"ring-slider-thumb ring-global-resetButton","dragged":"ring-slider-dragged","tick":"ring-slider-tick","active":"ring-slider-active","markValue":"ring-slider-markValue","tag":"ring-slider-tag"};
|
|
14
15
|
|
|
15
|
-
const Slider =
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
16
|
+
const Slider = t0 => {
|
|
17
|
+
const $ = c(154);
|
|
18
|
+
if ($[0] !== "7c00c25355ca34476232faa4b0d729160f0b7ed5ed726089246ce3288d3c8d5e") {
|
|
19
|
+
for (let $i = 0; $i < 154; $i += 1) {
|
|
20
|
+
$[$i] = Symbol.for("react.memo_cache_sentinel");
|
|
21
|
+
}
|
|
22
|
+
$[0] = "7c00c25355ca34476232faa4b0d729160f0b7ed5ed726089246ce3288d3c8d5e";
|
|
23
|
+
}
|
|
24
|
+
const {
|
|
25
|
+
defaultValue,
|
|
26
|
+
value,
|
|
27
|
+
min: t1,
|
|
28
|
+
max: t2,
|
|
29
|
+
step: t3,
|
|
30
|
+
disabled,
|
|
31
|
+
marks,
|
|
32
|
+
showTicks,
|
|
33
|
+
showTag,
|
|
34
|
+
className,
|
|
35
|
+
renderTag,
|
|
36
|
+
onChange
|
|
37
|
+
} = t0;
|
|
38
|
+
const min = t1 === undefined ? 0 : t1;
|
|
39
|
+
const max = t2 === undefined ? HUNDRED : t2;
|
|
40
|
+
const step = t3 === undefined ? 1 : t3;
|
|
29
41
|
const ref = useRef(null);
|
|
30
42
|
const previouslyDragged = useRef(false);
|
|
31
43
|
const [values, setValues] = useState(defaultValue !== null && defaultValue !== void 0 ? defaultValue : min);
|
|
32
|
-
const
|
|
44
|
+
const t4 = value !== null && value !== void 0 ? value : values;
|
|
45
|
+
let t5;
|
|
46
|
+
if ($[1] !== max || $[2] !== min || $[3] !== t4) {
|
|
47
|
+
t5 = toRange(t4, min, max);
|
|
48
|
+
$[1] = max;
|
|
49
|
+
$[2] = min;
|
|
50
|
+
$[3] = t4;
|
|
51
|
+
$[4] = t5;
|
|
52
|
+
} else {
|
|
53
|
+
t5 = $[4];
|
|
54
|
+
}
|
|
55
|
+
const validValues = t5;
|
|
33
56
|
const validStep = step < 0 ? 0 : step;
|
|
34
|
-
const
|
|
57
|
+
const t6 = defaultValue !== null && defaultValue !== void 0 ? defaultValue : value;
|
|
58
|
+
let t7;
|
|
59
|
+
if ($[5] !== t6) {
|
|
60
|
+
t7 = isArray(t6);
|
|
61
|
+
$[5] = t6;
|
|
62
|
+
$[6] = t7;
|
|
63
|
+
} else {
|
|
64
|
+
t7 = $[6];
|
|
65
|
+
}
|
|
66
|
+
const isRange = t7;
|
|
35
67
|
const [isDragging, setIsDragging] = useState(false);
|
|
36
68
|
const [draggedIndex, setDraggedIndex] = useState(-1);
|
|
37
|
-
|
|
38
|
-
|
|
69
|
+
let t8;
|
|
70
|
+
if ($[7] === Symbol.for("react.memo_cache_sentinel")) {
|
|
71
|
+
t8 = getUID("ring-slider-");
|
|
72
|
+
$[7] = t8;
|
|
73
|
+
} else {
|
|
74
|
+
t8 = $[7];
|
|
75
|
+
}
|
|
76
|
+
const [shortcutsScope] = useState(t8);
|
|
77
|
+
let t9;
|
|
78
|
+
bb0: {
|
|
39
79
|
if (isArray(marks)) {
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
80
|
+
let t10;
|
|
81
|
+
if ($[8] !== marks || $[9] !== max || $[10] !== min) {
|
|
82
|
+
let t11;
|
|
83
|
+
if ($[12] !== max || $[13] !== min) {
|
|
84
|
+
t11 = mark => ({
|
|
85
|
+
...mark,
|
|
86
|
+
value: validateValue(mark.value, min, max)
|
|
87
|
+
});
|
|
88
|
+
$[12] = max;
|
|
89
|
+
$[13] = min;
|
|
90
|
+
$[14] = t11;
|
|
91
|
+
} else {
|
|
92
|
+
t11 = $[14];
|
|
93
|
+
}
|
|
94
|
+
t10 = marks.map(t11);
|
|
95
|
+
$[8] = marks;
|
|
96
|
+
$[9] = max;
|
|
97
|
+
$[10] = min;
|
|
98
|
+
$[11] = t10;
|
|
99
|
+
} else {
|
|
100
|
+
t10 = $[11];
|
|
101
|
+
}
|
|
102
|
+
t9 = t10;
|
|
103
|
+
break bb0;
|
|
44
104
|
}
|
|
45
105
|
if (marks) {
|
|
46
|
-
|
|
106
|
+
let t10;
|
|
107
|
+
if ($[15] !== max || $[16] !== min || $[17] !== validStep) {
|
|
108
|
+
t10 = calculateMarks(min, max, validStep);
|
|
109
|
+
$[15] = max;
|
|
110
|
+
$[16] = min;
|
|
111
|
+
$[17] = validStep;
|
|
112
|
+
$[18] = t10;
|
|
113
|
+
} else {
|
|
114
|
+
t10 = $[18];
|
|
115
|
+
}
|
|
116
|
+
t9 = t10;
|
|
117
|
+
break bb0;
|
|
118
|
+
}
|
|
119
|
+
let t10;
|
|
120
|
+
if ($[19] === Symbol.for("react.memo_cache_sentinel")) {
|
|
121
|
+
t10 = [];
|
|
122
|
+
$[19] = t10;
|
|
123
|
+
} else {
|
|
124
|
+
t10 = $[19];
|
|
47
125
|
}
|
|
48
|
-
|
|
49
|
-
}
|
|
50
|
-
const
|
|
126
|
+
t9 = t10;
|
|
127
|
+
}
|
|
128
|
+
const markValues = t9;
|
|
129
|
+
let t10;
|
|
130
|
+
bb1: {
|
|
51
131
|
if (showTicks) {
|
|
52
|
-
|
|
132
|
+
let t11;
|
|
133
|
+
if ($[20] !== markValues || $[21] !== max || $[22] !== min || $[23] !== validStep) {
|
|
134
|
+
t11 = markValues.length ? markValues : calculateMarks(min, max, validStep);
|
|
135
|
+
$[20] = markValues;
|
|
136
|
+
$[21] = max;
|
|
137
|
+
$[22] = min;
|
|
138
|
+
$[23] = validStep;
|
|
139
|
+
$[24] = t11;
|
|
140
|
+
} else {
|
|
141
|
+
t11 = $[24];
|
|
142
|
+
}
|
|
143
|
+
t10 = t11;
|
|
144
|
+
break bb1;
|
|
145
|
+
}
|
|
146
|
+
let t11;
|
|
147
|
+
if ($[25] === Symbol.for("react.memo_cache_sentinel")) {
|
|
148
|
+
t11 = [];
|
|
149
|
+
$[25] = t11;
|
|
150
|
+
} else {
|
|
151
|
+
t11 = $[25];
|
|
53
152
|
}
|
|
54
|
-
|
|
55
|
-
}
|
|
56
|
-
const
|
|
57
|
-
const
|
|
58
|
-
const
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
153
|
+
t10 = t11;
|
|
154
|
+
}
|
|
155
|
+
const tickMarks = t10;
|
|
156
|
+
const trackStart = toPercent(isRange ? Math.min(...validValues) : min, min, max);
|
|
157
|
+
const trackLength = toPercent(Math.max(...validValues), min, max) - trackStart;
|
|
158
|
+
let t11;
|
|
159
|
+
if ($[26] !== isRange || $[27] !== onChange) {
|
|
160
|
+
t11 = nextValues => {
|
|
161
|
+
setValues(nextValues);
|
|
162
|
+
onChange?.(isRange ? nextValues : nextValues[0]);
|
|
163
|
+
};
|
|
164
|
+
$[26] = isRange;
|
|
165
|
+
$[27] = onChange;
|
|
166
|
+
$[28] = t11;
|
|
167
|
+
} else {
|
|
168
|
+
t11 = $[28];
|
|
169
|
+
}
|
|
170
|
+
const handleValueChange = t11;
|
|
171
|
+
let t12;
|
|
172
|
+
if ($[29] !== handleValueChange || $[30] !== validValues) {
|
|
173
|
+
t12 = (nextValue, index) => {
|
|
174
|
+
const nextValues_0 = [...validValues];
|
|
175
|
+
nextValues_0[index] = nextValue;
|
|
176
|
+
if (nextValues_0[0] > nextValues_0[1]) {
|
|
177
|
+
const previousValue = nextValues_0[index];
|
|
178
|
+
nextValues_0.reverse();
|
|
179
|
+
const thumb = ref.current?.querySelector(`[role="slider"][data-index="${nextValues_0.indexOf(previousValue)}"]`);
|
|
70
180
|
thumb?.focus();
|
|
71
181
|
}
|
|
72
|
-
handleValueChange(
|
|
182
|
+
handleValueChange(nextValues_0);
|
|
73
183
|
};
|
|
74
|
-
|
|
75
|
-
|
|
184
|
+
$[29] = handleValueChange;
|
|
185
|
+
$[30] = validValues;
|
|
186
|
+
$[31] = t12;
|
|
187
|
+
} else {
|
|
188
|
+
t12 = $[31];
|
|
189
|
+
}
|
|
190
|
+
const setValueAndSwap = t12;
|
|
191
|
+
const getIndex = _temp;
|
|
192
|
+
let map;
|
|
193
|
+
if ($[32] !== disabled || $[33] !== max || $[34] !== min || $[35] !== setValueAndSwap || $[36] !== validStep || $[37] !== validValues) {
|
|
194
|
+
map = {};
|
|
76
195
|
if (!disabled) {
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
}
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
}
|
|
146
|
-
if (isDragging && !previouslyDragged.current) {
|
|
147
|
-
window.addEventListener('mousemove', handleMouseMove);
|
|
148
|
-
window.addEventListener('mouseup', handleMouseUp);
|
|
149
|
-
} else if (!isDragging && previouslyDragged.current) {
|
|
150
|
-
window.removeEventListener('mousemove', handleMouseMove);
|
|
151
|
-
window.removeEventListener('mouseup', handleMouseUp);
|
|
196
|
+
let t13;
|
|
197
|
+
if ($[39] !== min || $[40] !== setValueAndSwap || $[41] !== validStep || $[42] !== validValues) {
|
|
198
|
+
t13 = t14 => {
|
|
199
|
+
const {
|
|
200
|
+
target: target_0
|
|
201
|
+
} = t14;
|
|
202
|
+
const index_0 = getIndex(target_0);
|
|
203
|
+
setValueAndSwap(Math.max(min, validValues[index_0] - validStep), index_0);
|
|
204
|
+
};
|
|
205
|
+
$[39] = min;
|
|
206
|
+
$[40] = setValueAndSwap;
|
|
207
|
+
$[41] = validStep;
|
|
208
|
+
$[42] = validValues;
|
|
209
|
+
$[43] = t13;
|
|
210
|
+
} else {
|
|
211
|
+
t13 = $[43];
|
|
212
|
+
}
|
|
213
|
+
map.left = map.down = t13;
|
|
214
|
+
let t14;
|
|
215
|
+
if ($[44] !== max || $[45] !== setValueAndSwap || $[46] !== validStep || $[47] !== validValues) {
|
|
216
|
+
t14 = t15 => {
|
|
217
|
+
const {
|
|
218
|
+
target: target_1
|
|
219
|
+
} = t15;
|
|
220
|
+
const index_1 = getIndex(target_1);
|
|
221
|
+
setValueAndSwap(Math.min(max, validValues[index_1] + validStep), index_1);
|
|
222
|
+
};
|
|
223
|
+
$[44] = max;
|
|
224
|
+
$[45] = setValueAndSwap;
|
|
225
|
+
$[46] = validStep;
|
|
226
|
+
$[47] = validValues;
|
|
227
|
+
$[48] = t14;
|
|
228
|
+
} else {
|
|
229
|
+
t14 = $[48];
|
|
230
|
+
}
|
|
231
|
+
map.right = map.up = t14;
|
|
232
|
+
let t15;
|
|
233
|
+
if ($[49] !== min || $[50] !== setValueAndSwap) {
|
|
234
|
+
t15 = t16 => {
|
|
235
|
+
const {
|
|
236
|
+
target: target_2
|
|
237
|
+
} = t16;
|
|
238
|
+
const index_2 = getIndex(target_2);
|
|
239
|
+
setValueAndSwap(min, index_2);
|
|
240
|
+
};
|
|
241
|
+
$[49] = min;
|
|
242
|
+
$[50] = setValueAndSwap;
|
|
243
|
+
$[51] = t15;
|
|
244
|
+
} else {
|
|
245
|
+
t15 = $[51];
|
|
246
|
+
}
|
|
247
|
+
map.home = t15;
|
|
248
|
+
let t16;
|
|
249
|
+
if ($[52] !== max || $[53] !== setValueAndSwap) {
|
|
250
|
+
t16 = t17 => {
|
|
251
|
+
const {
|
|
252
|
+
target: target_3
|
|
253
|
+
} = t17;
|
|
254
|
+
const index_3 = getIndex(target_3);
|
|
255
|
+
setValueAndSwap(max, index_3);
|
|
256
|
+
};
|
|
257
|
+
$[52] = max;
|
|
258
|
+
$[53] = setValueAndSwap;
|
|
259
|
+
$[54] = t16;
|
|
260
|
+
} else {
|
|
261
|
+
t16 = $[54];
|
|
262
|
+
}
|
|
263
|
+
map.end = t16;
|
|
152
264
|
}
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
265
|
+
$[32] = disabled;
|
|
266
|
+
$[33] = max;
|
|
267
|
+
$[34] = min;
|
|
268
|
+
$[35] = setValueAndSwap;
|
|
269
|
+
$[36] = validStep;
|
|
270
|
+
$[37] = validValues;
|
|
271
|
+
$[38] = map;
|
|
272
|
+
} else {
|
|
273
|
+
map = $[38];
|
|
274
|
+
}
|
|
275
|
+
const shortcutsMap = map;
|
|
276
|
+
let t13;
|
|
277
|
+
if ($[55] !== disabled || $[56] !== isRange || $[57] !== max || $[58] !== min || $[59] !== validStep || $[60] !== validValues[0] || $[61] !== validValues[1]) {
|
|
278
|
+
t13 = e => {
|
|
279
|
+
e.stopPropagation();
|
|
280
|
+
if (disabled) {
|
|
281
|
+
return;
|
|
282
|
+
}
|
|
283
|
+
const index_4 = e.currentTarget.getAttribute("data-index");
|
|
284
|
+
const nextValue_0 = calculateValue(ref, e.pageX, min, max, validStep);
|
|
285
|
+
if (nextValue_0 !== null && !isNaN(nextValue_0) && !index_4) {
|
|
286
|
+
const rangeIndex = Number(Math.abs(validValues[0] - nextValue_0) > Math.abs(validValues[1] - nextValue_0));
|
|
287
|
+
setDraggedIndex(isRange ? rangeIndex : 0);
|
|
288
|
+
} else {
|
|
289
|
+
setDraggedIndex(Number(index_4));
|
|
290
|
+
}
|
|
291
|
+
setIsDragging(true);
|
|
292
|
+
previouslyDragged.current = false;
|
|
293
|
+
};
|
|
294
|
+
$[55] = disabled;
|
|
295
|
+
$[56] = isRange;
|
|
296
|
+
$[57] = max;
|
|
297
|
+
$[58] = min;
|
|
298
|
+
$[59] = validStep;
|
|
299
|
+
$[60] = validValues[0];
|
|
300
|
+
$[61] = validValues[1];
|
|
301
|
+
$[62] = t13;
|
|
302
|
+
} else {
|
|
303
|
+
t13 = $[62];
|
|
304
|
+
}
|
|
305
|
+
const handleMouseDown = t13;
|
|
306
|
+
let t14;
|
|
307
|
+
if ($[63] !== draggedIndex || $[64] !== handleValueChange || $[65] !== max || $[66] !== min || $[67] !== validStep || $[68] !== validValues) {
|
|
308
|
+
t14 = t15 => {
|
|
309
|
+
const {
|
|
310
|
+
pageX
|
|
311
|
+
} = t15;
|
|
312
|
+
const nextValues_1 = adjustValues(validValues, ref, draggedIndex, pageX, max, min, validStep);
|
|
313
|
+
if (nextValues_1[0] > nextValues_1[1]) {
|
|
314
|
+
nextValues_1.reverse();
|
|
315
|
+
}
|
|
316
|
+
handleValueChange(nextValues_1);
|
|
317
|
+
setDraggedIndex(-1);
|
|
318
|
+
setIsDragging(false);
|
|
319
|
+
previouslyDragged.current = true;
|
|
320
|
+
};
|
|
321
|
+
$[63] = draggedIndex;
|
|
322
|
+
$[64] = handleValueChange;
|
|
323
|
+
$[65] = max;
|
|
324
|
+
$[66] = min;
|
|
325
|
+
$[67] = validStep;
|
|
326
|
+
$[68] = validValues;
|
|
327
|
+
$[69] = t14;
|
|
328
|
+
} else {
|
|
329
|
+
t14 = $[69];
|
|
330
|
+
}
|
|
331
|
+
const handleMouseUp = t14;
|
|
332
|
+
let t15;
|
|
333
|
+
if ($[70] !== draggedIndex || $[71] !== handleValueChange || $[72] !== max || $[73] !== min || $[74] !== validStep || $[75] !== validValues) {
|
|
334
|
+
t15 = t16 => {
|
|
335
|
+
const {
|
|
336
|
+
pageX: pageX_0
|
|
337
|
+
} = t16;
|
|
338
|
+
const nextValues_2 = adjustValues(validValues, ref, draggedIndex, pageX_0, max, min, validStep);
|
|
339
|
+
if (nextValues_2[0] > nextValues_2[1]) {
|
|
340
|
+
nextValues_2.reverse();
|
|
341
|
+
setDraggedIndex(_temp2);
|
|
342
|
+
}
|
|
343
|
+
handleValueChange(nextValues_2);
|
|
344
|
+
};
|
|
345
|
+
$[70] = draggedIndex;
|
|
346
|
+
$[71] = handleValueChange;
|
|
347
|
+
$[72] = max;
|
|
348
|
+
$[73] = min;
|
|
349
|
+
$[74] = validStep;
|
|
350
|
+
$[75] = validValues;
|
|
351
|
+
$[76] = t15;
|
|
352
|
+
} else {
|
|
353
|
+
t15 = $[76];
|
|
354
|
+
}
|
|
355
|
+
const handleMouseMove = t15;
|
|
356
|
+
let t16;
|
|
357
|
+
let t17;
|
|
358
|
+
if ($[77] !== disabled || $[78] !== handleMouseMove || $[79] !== handleMouseUp || $[80] !== isDragging) {
|
|
359
|
+
t16 = () => {
|
|
360
|
+
if (disabled) {
|
|
361
|
+
return;
|
|
362
|
+
}
|
|
363
|
+
if (isDragging && !previouslyDragged.current) {
|
|
364
|
+
window.addEventListener("mousemove", handleMouseMove);
|
|
365
|
+
window.addEventListener("mouseup", handleMouseUp);
|
|
366
|
+
} else {
|
|
367
|
+
if (!isDragging && previouslyDragged.current) {
|
|
368
|
+
window.removeEventListener("mousemove", handleMouseMove);
|
|
369
|
+
window.removeEventListener("mouseup", handleMouseUp);
|
|
370
|
+
}
|
|
371
|
+
}
|
|
372
|
+
return () => {
|
|
373
|
+
window.removeEventListener("mousemove", handleMouseMove);
|
|
374
|
+
window.removeEventListener("mouseup", handleMouseUp);
|
|
375
|
+
};
|
|
156
376
|
};
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
377
|
+
t17 = [isDragging, handleMouseMove, handleMouseUp, disabled];
|
|
378
|
+
$[77] = disabled;
|
|
379
|
+
$[78] = handleMouseMove;
|
|
380
|
+
$[79] = handleMouseUp;
|
|
381
|
+
$[80] = isDragging;
|
|
382
|
+
$[81] = t16;
|
|
383
|
+
$[82] = t17;
|
|
384
|
+
} else {
|
|
385
|
+
t16 = $[81];
|
|
386
|
+
t17 = $[82];
|
|
387
|
+
}
|
|
388
|
+
useEffect(t16, t17);
|
|
389
|
+
const t18 = !!marks || showTag;
|
|
390
|
+
let t19;
|
|
391
|
+
if ($[83] !== className || $[84] !== disabled || $[85] !== t18) {
|
|
392
|
+
t19 = classNames(styles.slider, className, {
|
|
163
393
|
[styles.disabled]: disabled,
|
|
164
|
-
[styles.marked]:
|
|
165
|
-
})
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
394
|
+
[styles.marked]: t18
|
|
395
|
+
});
|
|
396
|
+
$[83] = className;
|
|
397
|
+
$[84] = disabled;
|
|
398
|
+
$[85] = t18;
|
|
399
|
+
$[86] = t19;
|
|
400
|
+
} else {
|
|
401
|
+
t19 = $[86];
|
|
402
|
+
}
|
|
403
|
+
let t20;
|
|
404
|
+
if ($[87] !== shortcutsMap || $[88] !== shortcutsScope) {
|
|
405
|
+
t20 = /*#__PURE__*/jsx(Shortcuts, {
|
|
169
406
|
map: shortcutsMap,
|
|
170
407
|
scope: shortcutsScope
|
|
171
|
-
})
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
408
|
+
});
|
|
409
|
+
$[87] = shortcutsMap;
|
|
410
|
+
$[88] = shortcutsScope;
|
|
411
|
+
$[89] = t20;
|
|
412
|
+
} else {
|
|
413
|
+
t20 = $[89];
|
|
414
|
+
}
|
|
415
|
+
const t21 = !showTicks;
|
|
416
|
+
let t22;
|
|
417
|
+
if ($[90] !== disabled || $[91] !== t21) {
|
|
418
|
+
t22 = classNames(styles.rail, {
|
|
419
|
+
[styles.rounded]: t21,
|
|
420
|
+
[styles.disabled]: disabled
|
|
421
|
+
});
|
|
422
|
+
$[90] = disabled;
|
|
423
|
+
$[91] = t21;
|
|
424
|
+
$[92] = t22;
|
|
425
|
+
} else {
|
|
426
|
+
t22 = $[92];
|
|
427
|
+
}
|
|
428
|
+
let t23;
|
|
429
|
+
if ($[93] !== t22) {
|
|
430
|
+
t23 = /*#__PURE__*/jsx("div", {
|
|
431
|
+
className: t22
|
|
432
|
+
});
|
|
433
|
+
$[93] = t22;
|
|
434
|
+
$[94] = t23;
|
|
435
|
+
} else {
|
|
436
|
+
t23 = $[94];
|
|
437
|
+
}
|
|
438
|
+
const t24 = `${trackStart}%`;
|
|
439
|
+
const t25 = `${trackLength}%`;
|
|
440
|
+
let t26;
|
|
441
|
+
if ($[95] !== t24 || $[96] !== t25) {
|
|
442
|
+
t26 = {
|
|
443
|
+
left: t24,
|
|
444
|
+
width: t25
|
|
445
|
+
};
|
|
446
|
+
$[95] = t24;
|
|
447
|
+
$[96] = t25;
|
|
448
|
+
$[97] = t26;
|
|
449
|
+
} else {
|
|
450
|
+
t26 = $[97];
|
|
451
|
+
}
|
|
452
|
+
const t27 = !showTicks;
|
|
453
|
+
let t28;
|
|
454
|
+
if ($[98] !== disabled || $[99] !== t27) {
|
|
455
|
+
t28 = classNames(styles.track, {
|
|
456
|
+
[styles.rounded]: t27,
|
|
457
|
+
[styles.disabled]: disabled
|
|
458
|
+
});
|
|
459
|
+
$[98] = disabled;
|
|
460
|
+
$[99] = t27;
|
|
461
|
+
$[100] = t28;
|
|
462
|
+
} else {
|
|
463
|
+
t28 = $[100];
|
|
464
|
+
}
|
|
465
|
+
let t29;
|
|
466
|
+
if ($[101] !== t26 || $[102] !== t28) {
|
|
467
|
+
t29 = /*#__PURE__*/jsx("div", {
|
|
468
|
+
style: t26,
|
|
469
|
+
className: t28
|
|
470
|
+
});
|
|
471
|
+
$[101] = t26;
|
|
472
|
+
$[102] = t28;
|
|
473
|
+
$[103] = t29;
|
|
474
|
+
} else {
|
|
475
|
+
t29 = $[103];
|
|
476
|
+
}
|
|
477
|
+
let t30;
|
|
478
|
+
if ($[104] !== disabled || $[105] !== draggedIndex || $[106] !== handleMouseDown || $[107] !== isDragging || $[108] !== max || $[109] !== min || $[110] !== renderTag || $[111] !== showTag || $[112] !== validValues) {
|
|
479
|
+
let t31;
|
|
480
|
+
if ($[114] !== disabled || $[115] !== draggedIndex || $[116] !== handleMouseDown || $[117] !== isDragging || $[118] !== max || $[119] !== min || $[120] !== renderTag || $[121] !== showTag) {
|
|
481
|
+
t31 = (numValue, index_5) => {
|
|
482
|
+
const percent = toPercent(numValue, min, max);
|
|
483
|
+
return /*#__PURE__*/jsxs(Fragment, {
|
|
484
|
+
children: [/*#__PURE__*/jsx("div", {
|
|
191
485
|
tabIndex: 0,
|
|
192
|
-
"aria-label":
|
|
193
|
-
role:
|
|
486
|
+
"aria-label": "Pick value",
|
|
487
|
+
role: "slider",
|
|
194
488
|
"aria-valuemin": min,
|
|
195
489
|
"aria-valuemax": max,
|
|
196
490
|
"aria-valuenow": numValue,
|
|
197
|
-
"data-index":
|
|
491
|
+
"data-index": index_5,
|
|
198
492
|
style: {
|
|
199
493
|
left: `${percent}%`
|
|
200
494
|
},
|
|
201
495
|
className: classNames(styles.thumb, {
|
|
202
496
|
[styles.disabled]: disabled,
|
|
203
|
-
[styles.dragged]: isDragging && draggedIndex ===
|
|
497
|
+
[styles.dragged]: isDragging && draggedIndex === index_5
|
|
204
498
|
}),
|
|
205
499
|
onMouseDown: handleMouseDown
|
|
206
|
-
}), showTag && jsx("div", {
|
|
500
|
+
}), showTag && /*#__PURE__*/jsx("div", {
|
|
207
501
|
style: {
|
|
208
502
|
left: `${percent}%`
|
|
209
503
|
},
|
|
210
504
|
className: classNames(styles.tag, {
|
|
211
505
|
[styles.disabled]: disabled
|
|
212
506
|
}),
|
|
213
|
-
role:
|
|
507
|
+
role: "tooltip",
|
|
214
508
|
children: renderTag ? renderTag(numValue) : numValue
|
|
215
509
|
})]
|
|
216
|
-
},
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
|
|
510
|
+
}, index_5);
|
|
511
|
+
};
|
|
512
|
+
$[114] = disabled;
|
|
513
|
+
$[115] = draggedIndex;
|
|
514
|
+
$[116] = handleMouseDown;
|
|
515
|
+
$[117] = isDragging;
|
|
516
|
+
$[118] = max;
|
|
517
|
+
$[119] = min;
|
|
518
|
+
$[120] = renderTag;
|
|
519
|
+
$[121] = showTag;
|
|
520
|
+
$[122] = t31;
|
|
521
|
+
} else {
|
|
522
|
+
t31 = $[122];
|
|
523
|
+
}
|
|
524
|
+
t30 = validValues.map(t31);
|
|
525
|
+
$[104] = disabled;
|
|
526
|
+
$[105] = draggedIndex;
|
|
527
|
+
$[106] = handleMouseDown;
|
|
528
|
+
$[107] = isDragging;
|
|
529
|
+
$[108] = max;
|
|
530
|
+
$[109] = min;
|
|
531
|
+
$[110] = renderTag;
|
|
532
|
+
$[111] = showTag;
|
|
533
|
+
$[112] = validValues;
|
|
534
|
+
$[113] = t30;
|
|
535
|
+
} else {
|
|
536
|
+
t30 = $[113];
|
|
537
|
+
}
|
|
538
|
+
let t31;
|
|
539
|
+
if ($[123] !== disabled || $[124] !== markValues || $[125] !== max || $[126] !== min) {
|
|
540
|
+
let t32;
|
|
541
|
+
if ($[128] !== disabled || $[129] !== max || $[130] !== min) {
|
|
542
|
+
t32 = (t33, index_6) => {
|
|
543
|
+
const {
|
|
544
|
+
value: markValue,
|
|
545
|
+
label
|
|
546
|
+
} = t33;
|
|
547
|
+
const percent_0 = toPercent(markValue, min, max);
|
|
548
|
+
return /*#__PURE__*/jsx("div", {
|
|
549
|
+
style: {
|
|
550
|
+
left: `${percent_0}%`
|
|
551
|
+
},
|
|
552
|
+
className: classNames(styles.markValue, {
|
|
553
|
+
[styles.disabled]: disabled
|
|
554
|
+
}),
|
|
555
|
+
children: label !== null && label !== void 0 ? label : markValue
|
|
556
|
+
}, index_6);
|
|
557
|
+
};
|
|
558
|
+
$[128] = disabled;
|
|
559
|
+
$[129] = max;
|
|
560
|
+
$[130] = min;
|
|
561
|
+
$[131] = t32;
|
|
562
|
+
} else {
|
|
563
|
+
t32 = $[131];
|
|
564
|
+
}
|
|
565
|
+
t31 = markValues.map(t32);
|
|
566
|
+
$[123] = disabled;
|
|
567
|
+
$[124] = markValues;
|
|
568
|
+
$[125] = max;
|
|
569
|
+
$[126] = min;
|
|
570
|
+
$[127] = t31;
|
|
571
|
+
} else {
|
|
572
|
+
t31 = $[127];
|
|
573
|
+
}
|
|
574
|
+
let t32;
|
|
575
|
+
if ($[132] !== disabled || $[133] !== isRange || $[134] !== max || $[135] !== min || $[136] !== tickMarks || $[137] !== validValues) {
|
|
576
|
+
let t33;
|
|
577
|
+
if ($[139] !== disabled || $[140] !== isRange || $[141] !== max || $[142] !== min || $[143] !== validValues) {
|
|
578
|
+
t33 = (t34, index_7) => {
|
|
579
|
+
const {
|
|
580
|
+
value: tickValue
|
|
581
|
+
} = t34;
|
|
582
|
+
const percent_1 = toPercent(tickValue, min, max);
|
|
583
|
+
const isActive = isRange ? tickValue >= validValues[0] && tickValue <= validValues[validValues.length - 1] : tickValue <= validValues[0];
|
|
584
|
+
return /*#__PURE__*/jsx("div", {
|
|
585
|
+
className: classNames(styles.tick, {
|
|
586
|
+
[styles.active]: isActive,
|
|
587
|
+
[styles.disabled]: disabled
|
|
588
|
+
}),
|
|
589
|
+
style: {
|
|
590
|
+
left: `${percent_1}%`
|
|
591
|
+
}
|
|
592
|
+
}, index_7);
|
|
593
|
+
};
|
|
594
|
+
$[139] = disabled;
|
|
595
|
+
$[140] = isRange;
|
|
596
|
+
$[141] = max;
|
|
597
|
+
$[142] = min;
|
|
598
|
+
$[143] = validValues;
|
|
599
|
+
$[144] = t33;
|
|
600
|
+
} else {
|
|
601
|
+
t33 = $[144];
|
|
602
|
+
}
|
|
603
|
+
t32 = tickMarks.map(t33);
|
|
604
|
+
$[132] = disabled;
|
|
605
|
+
$[133] = isRange;
|
|
606
|
+
$[134] = max;
|
|
607
|
+
$[135] = min;
|
|
608
|
+
$[136] = tickMarks;
|
|
609
|
+
$[137] = validValues;
|
|
610
|
+
$[138] = t32;
|
|
611
|
+
} else {
|
|
612
|
+
t32 = $[138];
|
|
613
|
+
}
|
|
614
|
+
let t33;
|
|
615
|
+
if ($[145] !== handleMouseDown || $[146] !== t19 || $[147] !== t20 || $[148] !== t23 || $[149] !== t29 || $[150] !== t30 || $[151] !== t31 || $[152] !== t32) {
|
|
616
|
+
t33 = /*#__PURE__*/jsxs("div", {
|
|
617
|
+
ref: ref,
|
|
618
|
+
role: "presentation",
|
|
619
|
+
className: t19,
|
|
620
|
+
tabIndex: -1,
|
|
621
|
+
onMouseDown: handleMouseDown,
|
|
622
|
+
children: [t20, t23, t29, t30, t31, t32]
|
|
623
|
+
});
|
|
624
|
+
$[145] = handleMouseDown;
|
|
625
|
+
$[146] = t19;
|
|
626
|
+
$[147] = t20;
|
|
627
|
+
$[148] = t23;
|
|
628
|
+
$[149] = t29;
|
|
629
|
+
$[150] = t30;
|
|
630
|
+
$[151] = t31;
|
|
631
|
+
$[152] = t32;
|
|
632
|
+
$[153] = t33;
|
|
633
|
+
} else {
|
|
634
|
+
t33 = $[153];
|
|
635
|
+
}
|
|
636
|
+
return t33;
|
|
248
637
|
};
|
|
638
|
+
function _temp(target) {
|
|
639
|
+
return Number(target?.getAttribute("data-index"));
|
|
640
|
+
}
|
|
641
|
+
function _temp2(prevState) {
|
|
642
|
+
return prevState === 0 ? 1 : 0;
|
|
643
|
+
}
|
|
249
644
|
|
|
250
645
|
export { Slider };
|