@tamagui/slider 2.7.7 → 3.0.0-beta.637.1

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 (96) hide show
  1. package/dist/cjs/Slider.cjs +455 -512
  2. package/dist/cjs/Slider.native.cjs +469 -0
  3. package/dist/cjs/Slider.native.js +424 -498
  4. package/dist/cjs/Slider.native.js.map +1 -1
  5. package/dist/cjs/SliderImpl.cjs +111 -128
  6. package/dist/cjs/SliderImpl.native.cjs +154 -0
  7. package/dist/cjs/SliderImpl.native.js +127 -143
  8. package/dist/cjs/SliderImpl.native.js.map +1 -1
  9. package/dist/cjs/constants.cjs +59 -45
  10. package/dist/cjs/constants.native.cjs +79 -0
  11. package/dist/cjs/constants.native.js +59 -44
  12. package/dist/cjs/constants.native.js.map +1 -1
  13. package/dist/cjs/helpers.cjs +59 -60
  14. package/dist/cjs/helpers.native.cjs +99 -0
  15. package/dist/cjs/helpers.native.js +66 -68
  16. package/dist/cjs/helpers.native.js.map +1 -1
  17. package/dist/cjs/index.cjs +16 -17
  18. package/dist/cjs/index.native.cjs +33 -0
  19. package/dist/cjs/index.native.js +16 -16
  20. package/dist/cjs/index.native.js.map +1 -1
  21. package/dist/cjs/types.cjs +10 -11
  22. package/dist/cjs/types.native.cjs +19 -0
  23. package/dist/cjs/types.native.js +10 -10
  24. package/dist/cjs/types.native.js.map +1 -1
  25. package/dist/esm/Slider.mjs +427 -474
  26. package/dist/esm/Slider.mjs.map +1 -1
  27. package/dist/esm/Slider.native.js +396 -463
  28. package/dist/esm/Slider.native.js.map +1 -1
  29. package/dist/esm/SliderImpl.mjs +92 -102
  30. package/dist/esm/SliderImpl.mjs.map +1 -1
  31. package/dist/esm/SliderImpl.native.js +109 -119
  32. package/dist/esm/SliderImpl.native.js.map +1 -1
  33. package/dist/esm/constants.mjs +38 -21
  34. package/dist/esm/constants.mjs.map +1 -1
  35. package/dist/esm/constants.native.js +38 -21
  36. package/dist/esm/constants.native.js.map +1 -1
  37. package/dist/esm/helpers.mjs +37 -36
  38. package/dist/esm/helpers.mjs.map +1 -1
  39. package/dist/esm/helpers.native.js +44 -45
  40. package/dist/esm/helpers.native.js.map +1 -1
  41. package/dist/esm/index.js +4 -3
  42. package/dist/esm/index.mjs +4 -3
  43. package/dist/esm/index.native.js +4 -3
  44. package/dist/esm/types.mjs +0 -2
  45. package/dist/esm/types.native.js +0 -2
  46. package/dist/jsx/Slider.mjs +427 -474
  47. package/dist/jsx/Slider.mjs.map +1 -1
  48. package/dist/jsx/Slider.native.cjs +469 -0
  49. package/dist/jsx/Slider.native.js +424 -498
  50. package/dist/jsx/Slider.native.js.map +1 -1
  51. package/dist/jsx/SliderImpl.mjs +92 -102
  52. package/dist/jsx/SliderImpl.mjs.map +1 -1
  53. package/dist/jsx/SliderImpl.native.cjs +154 -0
  54. package/dist/jsx/SliderImpl.native.js +127 -143
  55. package/dist/jsx/SliderImpl.native.js.map +1 -1
  56. package/dist/jsx/constants.mjs +38 -21
  57. package/dist/jsx/constants.mjs.map +1 -1
  58. package/dist/jsx/constants.native.cjs +79 -0
  59. package/dist/jsx/constants.native.js +59 -44
  60. package/dist/jsx/constants.native.js.map +1 -1
  61. package/dist/jsx/helpers.mjs +37 -36
  62. package/dist/jsx/helpers.mjs.map +1 -1
  63. package/dist/jsx/helpers.native.cjs +99 -0
  64. package/dist/jsx/helpers.native.js +66 -68
  65. package/dist/jsx/helpers.native.js.map +1 -1
  66. package/dist/jsx/index.js +4 -3
  67. package/dist/jsx/index.mjs +4 -3
  68. package/dist/jsx/index.native.cjs +33 -0
  69. package/dist/jsx/index.native.js +16 -16
  70. package/dist/jsx/index.native.js.map +1 -1
  71. package/dist/jsx/types.mjs +0 -2
  72. package/dist/jsx/types.native.cjs +19 -0
  73. package/dist/jsx/types.native.js +10 -10
  74. package/dist/jsx/types.native.js.map +1 -1
  75. package/package.json +15 -14
  76. package/src/Slider.tsx +126 -171
  77. package/src/SliderImpl.tsx +3 -2
  78. package/src/constants.tsx +16 -6
  79. package/src/types.ts +6 -4
  80. package/types/Slider.d.ts +218 -200
  81. package/types/Slider.d.ts.map +1 -1
  82. package/types/SliderImpl.d.ts +16 -5
  83. package/types/SliderImpl.d.ts.map +1 -1
  84. package/types/constants.d.ts +10 -10
  85. package/types/constants.d.ts.map +1 -1
  86. package/types/helpers.d.ts.map +1 -1
  87. package/types/types.d.ts +6 -4
  88. package/types/types.d.ts.map +1 -1
  89. package/dist/esm/index.js.map +0 -1
  90. package/dist/esm/index.mjs.map +0 -1
  91. package/dist/esm/index.native.js.map +0 -1
  92. package/dist/esm/types.mjs.map +0 -1
  93. package/dist/esm/types.native.js.map +0 -1
  94. package/dist/jsx/index.js.map +0 -1
  95. package/dist/jsx/index.mjs.map +0 -1
  96. package/dist/jsx/types.mjs.map +0 -1
@@ -1,5 +1,6 @@
1
1
  "use strict";
2
2
 
3
+
3
4
  var __create = Object.create;
4
5
  var __defProp = Object.defineProperty;
5
6
  var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
@@ -7,51 +8,43 @@ var __getOwnPropNames = Object.getOwnPropertyNames;
7
8
  var __getProtoOf = Object.getPrototypeOf;
8
9
  var __hasOwnProp = Object.prototype.hasOwnProperty;
9
10
  var __export = (target, all) => {
10
- for (var name in all) __defProp(target, name, {
11
- get: all[name],
12
- enumerable: true
13
- });
11
+ for (var name in all) __defProp(target, name, {
12
+ get: all[name],
13
+ enumerable: true
14
+ });
14
15
  };
15
16
  var __copyProps = (to, from, except, desc) => {
16
- if (from && typeof from === "object" || typeof from === "function") {
17
- for (let key of __getOwnPropNames(from)) if (!__hasOwnProp.call(to, key) && key !== except) __defProp(to, key, {
18
- get: () => from[key],
19
- enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable
20
- });
21
- }
22
- return to;
17
+ if (from && typeof from === "object" || typeof from === "function") {
18
+ for (let key of __getOwnPropNames(from)) if (!__hasOwnProp.call(to, key) && key !== except) __defProp(to, key, {
19
+ get: () => from[key],
20
+ enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable
21
+ });
22
+ }
23
+ return to;
23
24
  };
24
- var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
25
- // If the importer is in node compatibility mode or this is not an ESM
26
- // file that has been converted to a CommonJS file using a Babel-
27
- // compatible transform (i.e. "__esModule" has not been set), then set
28
- // "default" to the CommonJS "module.exports" for node compatibility.
29
- isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", {
30
- value: mod,
31
- enumerable: true
25
+ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", {
26
+ value: mod,
27
+ enumerable: true
32
28
  }) : target, mod));
33
- var __toCommonJS = mod => __copyProps(__defProp({}, "__esModule", {
34
- value: true
35
- }), mod);
29
+ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
36
30
  var Slider_exports = {};
37
31
  __export(Slider_exports, {
38
- Range: () => Range,
39
- Slider: () => Slider,
40
- SliderActive: () => SliderActive,
41
- SliderActiveFrame: () => SliderActiveFrame,
42
- SliderThumb: () => SliderThumb,
43
- SliderThumbFrame: () => SliderThumbFrame,
44
- SliderTrack: () => SliderTrack,
45
- SliderTrackFrame: () => SliderTrackFrame,
46
- Thumb: () => Thumb,
47
- Track: () => Track
32
+ Range: () => Range,
33
+ Slider: () => Slider,
34
+ SliderActive: () => SliderActive,
35
+ SliderActiveFrame: () => SliderActiveFrame,
36
+ SliderThumb: () => SliderThumb,
37
+ SliderThumbFrame: () => SliderThumbFrame,
38
+ SliderTrack: () => SliderTrack,
39
+ SliderTrackFrame: () => SliderTrackFrame,
40
+ Thumb: () => Thumb,
41
+ Track: () => Track
48
42
  });
49
43
  module.exports = __toCommonJS(Slider_exports);
50
44
  var import_jsx_runtime = require("react/jsx-runtime");
51
45
  var import_compose_refs = require("@tamagui/compose-refs");
52
46
  var import_constants = require("@tamagui/constants");
53
47
  var import_core = require("@tamagui/core");
54
- var import_get_token = require("@tamagui/get-token");
55
48
  var import_helpers = require("@tamagui/helpers");
56
49
  var import_stacks = require("@tamagui/stacks");
57
50
  var import_use_controllable_state = require("@tamagui/use-controllable-state");
@@ -60,486 +53,419 @@ var React = __toESM(require("react"), 1);
60
53
  var import_constants2 = require("./constants.native.js");
61
54
  var import_helpers2 = require("./helpers.native.js");
62
55
  var import_SliderImpl = require("./SliderImpl.native.js");
63
- var SliderHorizontal = /* @__PURE__ */React.forwardRef(function (props, forwardedRef) {
64
- var {
65
- min,
66
- max,
67
- dir,
68
- onSlideStart,
69
- onSlideMove,
70
- onStepKeyDown,
71
- onSlideEnd,
72
- ...sliderProps
73
- } = props;
74
- var direction = (0, import_use_direction.useDirection)(dir);
75
- var isDirectionLTR = direction === "ltr";
76
- var sliderRef = React.useRef(null);
77
- var [state, setState_] = React.useState(function () {
78
- return {
79
- size: 0,
80
- offset: 0
81
- };
82
- });
83
- var setState = (0, import_core.useCreateShallowSetState)(setState_);
84
- function getValueFromPointer(pointerPosition) {
85
- var input = [0, state.size];
86
- var output = isDirectionLTR ? [min, max] : [max, min];
87
- return (0, import_helpers2.linearScale)(input, output)(pointerPosition);
88
- }
89
- var measure = function () {
90
- var _sliderRef_current;
91
- (_sliderRef_current = sliderRef.current) === null || _sliderRef_current === void 0 || _sliderRef_current.measure(function (_x, _y, width, _height, pageX, _pageY) {
92
- setState({
93
- size: width,
94
- offset: pageX
95
- });
96
- });
97
- };
98
- return /* @__PURE__ */(0, import_jsx_runtime.jsx)(import_constants2.SliderOrientationProvider, {
99
- scope: props.__scopeSlider,
100
- startEdge: isDirectionLTR ? "left" : "right",
101
- endEdge: isDirectionLTR ? "right" : "left",
102
- direction: isDirectionLTR ? 1 : -1,
103
- sizeProp: "width",
104
- size: state.size,
105
- children: /* @__PURE__ */(0, import_jsx_runtime.jsx)(import_SliderImpl.SliderImpl, {
106
- ref: (0, import_compose_refs.composeRefs)(forwardedRef, sliderRef),
107
- dir: direction,
108
- ...sliderProps,
109
- orientation: "horizontal",
110
- onLayout: measure,
111
- onSlideStart: function (event, target) {
112
- var value = getValueFromPointer(event.nativeEvent.locationX);
113
- if (value) onSlideStart === null || onSlideStart === void 0 || onSlideStart(value, target, event);
114
- },
115
- onSlideMove: function (event) {
116
- var value = getValueFromPointer(event.nativeEvent.pageX - state.offset);
117
- if (value) onSlideMove === null || onSlideMove === void 0 || onSlideMove(value, event);
118
- },
119
- onSlideEnd: function (event) {
120
- var value = getValueFromPointer(event.nativeEvent.pageX - state.offset);
121
- if (value) onSlideEnd === null || onSlideEnd === void 0 || onSlideEnd(event, value);
122
- },
123
- onStepKeyDown: function (event) {
124
- var isBackKey = import_constants2.BACK_KEYS[direction].includes(event.key);
125
- onStepKeyDown === null || onStepKeyDown === void 0 || onStepKeyDown({
126
- event,
127
- direction: isBackKey ? -1 : 1
128
- });
129
- }
130
- })
131
- });
56
+ var SliderHorizontal = (0, import_core.createRefComponent)(function(props, forwardedRef) {
57
+ var { min, max, dir, onSlideStart, onSlideMove, onStepKeyDown, onSlideEnd, ...sliderProps } = props;
58
+ var direction = (0, import_use_direction.useDirection)(dir);
59
+ var isDirectionLTR = direction === "ltr";
60
+ var sliderRef = React.useRef(null);
61
+ var [state, setState_] = React.useState(function() {
62
+ return {
63
+ size: 0,
64
+ offset: 0
65
+ };
66
+ });
67
+ var setState = (0, import_core.useCreateShallowSetState)(setState_);
68
+ function getValueFromPointer(pointerPosition) {
69
+ var input = [0, state.size];
70
+ var output = isDirectionLTR ? [min, max] : [max, min];
71
+ return (0, import_helpers2.linearScale)(input, output)(pointerPosition);
72
+ }
73
+ var measure = function() {
74
+ var _sliderRef_current;
75
+ (_sliderRef_current = sliderRef.current) === null || _sliderRef_current === void 0 || _sliderRef_current.measure(function(_x, _y, width, _height, pageX, _pageY) {
76
+ setState({
77
+ size: width,
78
+ offset: pageX
79
+ });
80
+ });
81
+ };
82
+ return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_constants2.SliderOrientationProvider, {
83
+ scope: props.__scopeSlider,
84
+ startEdge: isDirectionLTR ? "left" : "right",
85
+ endEdge: isDirectionLTR ? "right" : "left",
86
+ direction: isDirectionLTR ? 1 : -1,
87
+ sizeProp: "width",
88
+ size: state.size,
89
+ children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_SliderImpl.SliderImpl, {
90
+ ref: (0, import_compose_refs.composeRefs)(forwardedRef, sliderRef),
91
+ dir: direction,
92
+ ...sliderProps,
93
+ orientation: "horizontal",
94
+ onLayout: measure,
95
+ onSlideStart: function(event, target) {
96
+ var value = getValueFromPointer(event.nativeEvent.locationX);
97
+ if (value) onSlideStart === null || onSlideStart === void 0 || onSlideStart(value, target, event);
98
+ },
99
+ onSlideMove: function(event) {
100
+ var value = getValueFromPointer(event.nativeEvent.pageX - state.offset);
101
+ if (value) onSlideMove === null || onSlideMove === void 0 || onSlideMove(value, event);
102
+ },
103
+ onSlideEnd: function(event) {
104
+ var value = getValueFromPointer(event.nativeEvent.pageX - state.offset);
105
+ if (value) onSlideEnd === null || onSlideEnd === void 0 || onSlideEnd(event, value);
106
+ },
107
+ onStepKeyDown: function(event) {
108
+ var isBackKey = import_constants2.BACK_KEYS[direction].includes(event.key);
109
+ onStepKeyDown === null || onStepKeyDown === void 0 || onStepKeyDown({
110
+ event,
111
+ direction: isBackKey ? -1 : 1
112
+ });
113
+ }
114
+ })
115
+ });
132
116
  });
133
- var SliderVertical = /* @__PURE__ */React.forwardRef(function (props, forwardedRef) {
134
- var {
135
- min,
136
- max,
137
- onSlideStart,
138
- onSlideMove,
139
- onStepKeyDown,
140
- onSlideEnd,
141
- ...sliderProps
142
- } = props;
143
- var [state, setState_] = React.useState(function () {
144
- return {
145
- size: 0,
146
- offset: 0
147
- };
148
- });
149
- var setState = (0, import_core.useCreateShallowSetState)(setState_);
150
- var sliderRef = React.useRef(null);
151
- var configuration = (0, import_core.useConfiguration)();
152
- var insets = import_constants.isIos && configuration.insets ? configuration.insets : {
153
- top: 0,
154
- bottom: 0
155
- };
156
- function getValueFromPointer(pointerPosition) {
157
- var input = [0, state.size];
158
- var output = [max, min];
159
- return (0, import_helpers2.linearScale)(input, output)(pointerPosition);
160
- }
161
- var measure = function () {
162
- var _sliderRef_current;
163
- (_sliderRef_current = sliderRef.current) === null || _sliderRef_current === void 0 || _sliderRef_current.measure(function (_x, _y, _width, height, _pageX, pageY) {
164
- setState({
165
- size: height,
166
- offset: pageY + (import_constants.isIos ? insets.top : 0)
167
- });
168
- });
169
- };
170
- return /* @__PURE__ */(0, import_jsx_runtime.jsx)(import_constants2.SliderOrientationProvider, {
171
- scope: props.__scopeSlider,
172
- startEdge: "bottom",
173
- endEdge: "top",
174
- sizeProp: "height",
175
- size: state.size,
176
- direction: 1,
177
- children: /* @__PURE__ */(0, import_jsx_runtime.jsx)(import_SliderImpl.SliderImpl, {
178
- ref: (0, import_compose_refs.composeRefs)(forwardedRef, sliderRef),
179
- ...sliderProps,
180
- orientation: "vertical",
181
- onLayout: measure,
182
- onSlideStart: function (event, target) {
183
- var value = getValueFromPointer(event.nativeEvent.locationY);
184
- if (value) onSlideStart === null || onSlideStart === void 0 || onSlideStart(value, target, event);
185
- },
186
- onSlideMove: function (event) {
187
- var value = getValueFromPointer(event.nativeEvent.pageY - state.offset);
188
- if (value) onSlideMove === null || onSlideMove === void 0 || onSlideMove(value, event);
189
- },
190
- onSlideEnd: function (event) {
191
- var value = getValueFromPointer(event.nativeEvent.pageY - state.offset);
192
- onSlideEnd === null || onSlideEnd === void 0 || onSlideEnd(event, value);
193
- },
194
- onStepKeyDown: function (event) {
195
- var isBackKey = import_constants2.BACK_KEYS.ltr.includes(event.key);
196
- onStepKeyDown === null || onStepKeyDown === void 0 || onStepKeyDown({
197
- event,
198
- direction: isBackKey ? -1 : 1
199
- });
200
- }
201
- })
202
- });
117
+ var SliderVertical = (0, import_core.createRefComponent)(function(props, forwardedRef) {
118
+ var { min, max, onSlideStart, onSlideMove, onStepKeyDown, onSlideEnd, ...sliderProps } = props;
119
+ var [state, setState_] = React.useState(function() {
120
+ return {
121
+ size: 0,
122
+ offset: 0
123
+ };
124
+ });
125
+ var setState = (0, import_core.useCreateShallowSetState)(setState_);
126
+ var sliderRef = React.useRef(null);
127
+ var configuration = (0, import_core.useConfiguration)();
128
+ var insets = import_constants.isIos && configuration.insets ? configuration.insets : {
129
+ top: 0,
130
+ bottom: 0
131
+ };
132
+ function getValueFromPointer(pointerPosition) {
133
+ var input = [0, state.size];
134
+ var output = [max, min];
135
+ return (0, import_helpers2.linearScale)(input, output)(pointerPosition);
136
+ }
137
+ var measure = function() {
138
+ var _sliderRef_current;
139
+ (_sliderRef_current = sliderRef.current) === null || _sliderRef_current === void 0 || _sliderRef_current.measure(function(_x, _y, _width, height, _pageX, pageY) {
140
+ setState({
141
+ size: height,
142
+ offset: pageY + (import_constants.isIos ? insets.top : 0)
143
+ });
144
+ });
145
+ };
146
+ return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_constants2.SliderOrientationProvider, {
147
+ scope: props.__scopeSlider,
148
+ startEdge: "bottom",
149
+ endEdge: "top",
150
+ sizeProp: "height",
151
+ size: state.size,
152
+ direction: 1,
153
+ children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_SliderImpl.SliderImpl, {
154
+ ref: (0, import_compose_refs.composeRefs)(forwardedRef, sliderRef),
155
+ ...sliderProps,
156
+ orientation: "vertical",
157
+ onLayout: measure,
158
+ onSlideStart: function(event, target) {
159
+ var value = getValueFromPointer(event.nativeEvent.locationY);
160
+ if (value) onSlideStart === null || onSlideStart === void 0 || onSlideStart(value, target, event);
161
+ },
162
+ onSlideMove: function(event) {
163
+ var value = getValueFromPointer(event.nativeEvent.pageY - state.offset);
164
+ if (value) onSlideMove === null || onSlideMove === void 0 || onSlideMove(value, event);
165
+ },
166
+ onSlideEnd: function(event) {
167
+ var value = getValueFromPointer(event.nativeEvent.pageY - state.offset);
168
+ onSlideEnd === null || onSlideEnd === void 0 || onSlideEnd(event, value);
169
+ },
170
+ onStepKeyDown: function(event) {
171
+ var isBackKey = import_constants2.BACK_KEYS.ltr.includes(event.key);
172
+ onStepKeyDown === null || onStepKeyDown === void 0 || onStepKeyDown({
173
+ event,
174
+ direction: isBackKey ? -1 : 1
175
+ });
176
+ }
177
+ })
178
+ });
203
179
  });
204
180
  var SliderTrackFrame = (0, import_core.styled)(import_SliderImpl.SliderFrame, {
205
- name: "Slider",
206
- variants: {
207
- unstyled: {
208
- false: {
209
- height: "100%",
210
- width: "100%",
211
- backgroundColor: "$background",
212
- position: "relative",
213
- borderRadius: 1e5,
214
- overflow: "hidden"
215
- }
216
- }
217
- },
218
- defaultVariants: {
219
- unstyled: process.env.TAMAGUI_HEADLESS === "1"
220
- }
181
+ displayName: "Slider",
182
+ height: "100%",
183
+ width: "100%",
184
+ position: "relative",
185
+ overflow: "hidden"
221
186
  });
222
- var SliderTrack = /* @__PURE__ */React.forwardRef(function SliderTrack2(props, forwardedRef) {
223
- var {
224
- __scopeSlider,
225
- ...trackProps
226
- } = props;
227
- var context = (0, import_constants2.useSliderContext)(__scopeSlider);
228
- return /* @__PURE__ */(0, import_jsx_runtime.jsx)(SliderTrackFrame, {
229
- "data-disabled": context.disabled ? "" : void 0,
230
- "data-orientation": context.orientation,
231
- orientation: context.orientation,
232
- size: context.size,
233
- ...trackProps,
234
- ref: forwardedRef
235
- });
187
+ var SliderTrack = (0, import_core.createStyledHOC)(SliderTrackFrame, function SliderTrack2(props, forwardedRef) {
188
+ var { __scopeSlider, ...trackProps } = props;
189
+ var context = (0, import_constants2.useSliderContext)(__scopeSlider);
190
+ return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(SliderTrackFrame, {
191
+ "data-disabled": context.disabled ? "" : void 0,
192
+ "data-orientation": context.orientation,
193
+ orientation: context.orientation,
194
+ size: context.size,
195
+ ...trackProps,
196
+ ref: forwardedRef
197
+ });
236
198
  });
237
199
  var SliderActiveFrame = (0, import_core.styled)(import_SliderImpl.SliderFrame, {
238
- name: "SliderActive",
239
- position: "absolute",
240
- pointerEvents: "box-none",
241
- variants: {
242
- unstyled: {
243
- false: {
244
- backgroundColor: "$background",
245
- borderRadius: 1e5
246
- }
247
- }
248
- },
249
- defaultVariants: {
250
- unstyled: process.env.TAMAGUI_HEADLESS === "1"
251
- }
200
+ displayName: "SliderActive",
201
+ position: "absolute",
202
+ pointerEvents: "box-none"
252
203
  });
253
- var SliderActive = /* @__PURE__ */React.forwardRef(function SliderActive2(props, forwardedRef) {
254
- var {
255
- __scopeSlider,
256
- ...rangeProps
257
- } = props;
258
- var context = (0, import_constants2.useSliderContext)(__scopeSlider);
259
- var orientation = (0, import_constants2.useSliderOrientationContext)(__scopeSlider);
260
- var ref = React.useRef(null);
261
- var composedRefs = (0, import_compose_refs.useComposedRefs)(forwardedRef, ref);
262
- var valuesCount = context.values.length;
263
- var percentages = context.values.map(function (value) {
264
- return (0, import_helpers2.convertValueToPercentage)(value, context.min, context.max);
265
- });
266
- var offsetStart = valuesCount > 1 ? Math.min(...percentages) : 0;
267
- var offsetEnd = 100 - Math.max(...percentages);
268
- return /* @__PURE__ */(0, import_jsx_runtime.jsx)(SliderActiveFrame, {
269
- orientation: context.orientation,
270
- "data-orientation": context.orientation,
271
- "data-disabled": context.disabled ? "" : void 0,
272
- size: context.size,
273
- animateOnly: ["left", "top", "right", "bottom"],
274
- ...rangeProps,
275
- ref: composedRefs,
276
- [orientation.startEdge]: `${offsetStart}%`,
277
- [orientation.endEdge]: `${offsetEnd}%`,
278
- ...(orientation.sizeProp === "width" ? {
279
- height: "100%"
280
- } : {
281
- left: 0,
282
- right: 0
283
- })
284
- });
204
+ var SliderActive = (0, import_core.createStyledHOC)(SliderActiveFrame, function SliderActive2(props, forwardedRef) {
205
+ var { __scopeSlider, ...rangeProps } = props;
206
+ var context = (0, import_constants2.useSliderContext)(__scopeSlider);
207
+ var orientation = (0, import_constants2.useSliderOrientationContext)(__scopeSlider);
208
+ var ref = React.useRef(null);
209
+ var composedRefs = (0, import_compose_refs.useComposedRefs)(forwardedRef, ref);
210
+ var valuesCount = context.values.length;
211
+ var percentages = context.values.map(function(value) {
212
+ return (0, import_helpers2.convertValueToPercentage)(value, context.min, context.max);
213
+ });
214
+ var offsetStart = valuesCount > 1 ? Math.min(...percentages) : 0;
215
+ var offsetEnd = 100 - Math.max(...percentages);
216
+ return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(SliderActiveFrame, {
217
+ orientation: context.orientation,
218
+ "data-orientation": context.orientation,
219
+ "data-disabled": context.disabled ? "" : void 0,
220
+ size: context.size,
221
+ animateOnly: [
222
+ "left",
223
+ "top",
224
+ "right",
225
+ "bottom"
226
+ ],
227
+ ...rangeProps,
228
+ ref: composedRefs,
229
+ [orientation.startEdge]: `${offsetStart}%`,
230
+ [orientation.endEdge]: `${offsetEnd}%`,
231
+ ...orientation.sizeProp === "width" ? { height: "100%" } : {
232
+ left: 0,
233
+ right: 0
234
+ }
235
+ });
285
236
  });
286
- var getThumbSize = function (val) {
287
- var tokens = (0, import_core.getTokens)();
288
- var size = typeof val === "number" ? val : (0, import_get_token.getSize)(tokens.size[val], {
289
- shift: -1
290
- });
291
- return {
292
- width: size,
293
- height: size,
294
- minWidth: size,
295
- minHeight: size
296
- };
237
+ var getThumbSize = function(val) {
238
+ var tokens = (0, import_core.getTokens)();
239
+ var sizeToken = (0, import_core.resolveSizeToken)(val !== null && val !== void 0 ? val : true, "size");
240
+ var resolved = typeof sizeToken === "number" ? sizeToken : tokens.size[sizeToken];
241
+ var size = typeof val === "number" ? val : (0, import_core.getVariableValue)(resolved) * .86;
242
+ return {
243
+ width: size,
244
+ height: size,
245
+ minWidth: size,
246
+ minHeight: size
247
+ };
297
248
  };
298
- var SliderThumbFrame = (0, import_core.styled)(import_stacks.ThemeableStack, {
299
- name: "SliderThumb",
300
- variants: {
301
- size: {
302
- "...size": getThumbSize,
303
- ":number": getThumbSize
304
- },
305
- unstyled: {
306
- false: {
307
- position: "absolute",
308
- borderWidth: 2,
309
- borderColor: "$borderColor",
310
- backgroundColor: "$background",
311
- pressStyle: {
312
- backgroundColor: "$backgroundPress",
313
- borderColor: "$borderColorPress"
314
- },
315
- hoverStyle: {
316
- backgroundColor: "$backgroundHover",
317
- borderColor: "$borderColorHover"
318
- },
319
- focusVisibleStyle: {
320
- outlineStyle: "solid",
321
- outlineWidth: 2,
322
- outlineColor: "$outlineColor"
323
- }
324
- }
325
- }
326
- },
327
- defaultVariants: {
328
- unstyled: process.env.TAMAGUI_HEADLESS === "1"
329
- }
330
- });
331
- var SliderThumb = SliderThumbFrame.styleable(function SliderThumb2(props, forwardedRef) {
332
- var {
333
- __scopeSlider,
334
- index = 0,
335
- circular,
336
- size: sizeProp,
337
- ...thumbProps
338
- } = props;
339
- var context = (0, import_constants2.useSliderContext)(__scopeSlider);
340
- var orientation = (0, import_constants2.useSliderOrientationContext)(__scopeSlider);
341
- var [thumb, setThumb] = React.useState(null);
342
- var composedRefs = (0, import_compose_refs.useComposedRefs)(forwardedRef, setThumb);
343
- var value = context.values[index];
344
- var percent = value === void 0 ? 0 : (0, import_helpers2.convertValueToPercentage)(value, context.min, context.max);
345
- var label = (0, import_helpers2.getLabel)(index, context.values.length);
346
- var _ref;
347
- var sizeIn = (_ref = sizeProp !== null && sizeProp !== void 0 ? sizeProp : context.size) !== null && _ref !== void 0 ? _ref : "$true";
348
- var [size, setSize] = React.useState(function () {
349
- return (0, import_core.getVariableValue)(getThumbSize(sizeIn).width);
350
- });
351
- var thumbInBoundsOffset = size ? (0, import_helpers2.getThumbInBoundsOffset)(size, percent, orientation.direction) : 0;
352
- React.useEffect(function () {
353
- if (thumb) {
354
- context.thumbs.set(thumb, index);
355
- return function () {
356
- context.thumbs.delete(thumb);
357
- };
358
- }
359
- }, [thumb, context.thumbs, index]);
360
- var positionalStyles = context.orientation === "horizontal" ? {
361
- x: (thumbInBoundsOffset - size / 2) * orientation.direction,
362
- y: -size / 2,
363
- top: "50%",
364
- ...(size === 0 && {
365
- top: "auto",
366
- bottom: "auto"
367
- })
368
- } : {
369
- x: -size / 2,
370
- y: size / 2,
371
- left: "50%",
372
- ...(size === 0 && {
373
- left: "auto",
374
- right: "auto"
375
- })
376
- };
377
- return /* @__PURE__ */(0, import_jsx_runtime.jsx)(SliderThumbFrame, {
378
- ref: composedRefs,
379
- role: "slider",
380
- "aria-label": props["aria-label"] || label,
381
- "aria-valuemin": context.min,
382
- "aria-valuenow": value,
383
- "aria-valuemax": context.max,
384
- "aria-orientation": context.orientation,
385
- "data-orientation": context.orientation,
386
- "data-disabled": context.disabled ? "" : void 0,
387
- tabIndex: context.disabled ? void 0 : 0,
388
- animateOnly: ["transform", "left", "top", "right", "bottom"],
389
- ...positionalStyles,
390
- [orientation.startEdge]: `${percent}%`,
391
- size: sizeIn,
392
- circular,
393
- ...thumbProps,
394
- onLayout: function (e) {
395
- setSize(e.nativeEvent.layout[orientation.sizeProp]);
396
- },
397
- onFocus: (0, import_helpers.composeEventHandlers)(props.onFocus, function () {
398
- context.valueIndexToChangeRef.current = index;
399
- })
400
- });
401
- }, {
402
- staticConfig: {
403
- memo: true
404
- }
249
+ var SliderThumbFrame = (0, import_core.styled)(import_stacks.YStack, {
250
+ displayName: "SliderThumb",
251
+ position: "absolute",
252
+ variants: {
253
+ size: {
254
+ number: getThumbSize,
255
+ Size: getThumbSize
256
+ },
257
+ circular: { true: {
258
+ borderRadius: 1e5,
259
+ padding: 0
260
+ } },
261
+ elevate: { true: {
262
+ shadowColor: "shadow-color",
263
+ shadowRadius: 4,
264
+ shadowOffset: {
265
+ width: 0,
266
+ height: 2
267
+ }
268
+ } }
269
+ }
405
270
  });
406
- var SliderComponent = /* @__PURE__ */React.forwardRef(function (props, forwardedRef) {
407
- var {
408
- name,
409
- min = 0,
410
- max = 100,
411
- step = 1,
412
- orientation = "horizontal",
413
- disabled = false,
414
- minStepsBetweenThumbs = 0,
415
- defaultValue = [min],
416
- value,
417
- onValueChange = function () {},
418
- size: sizeProp,
419
- onSlideEnd,
420
- onSlideMove,
421
- onSlideStart,
422
- ...sliderProps
423
- } = props;
424
- var sliderRef = React.useRef(null);
425
- var composedRefs = (0, import_compose_refs.useComposedRefs)(sliderRef, forwardedRef);
426
- var thumbRefs = React.useRef(/* @__PURE__ */new Map());
427
- var valueIndexToChangeRef = React.useRef(0);
428
- var isHorizontal = orientation === "horizontal";
429
- var [values = [], setValues] = (0, import_use_controllable_state.useControllableState)({
430
- prop: value,
431
- defaultProp: defaultValue,
432
- transition: true,
433
- onChange: function (value2) {
434
- updateThumbFocus(valueIndexToChangeRef.current);
435
- onValueChange(value2);
436
- }
437
- });
438
- if (import_constants.isWeb) React.useEffect(function () {
439
- var node = sliderRef.current;
440
- if (!node) return;
441
- var preventDefault = function (e) {
442
- e.preventDefault();
443
- };
444
- node.addEventListener("touchstart", preventDefault);
445
- return function () {
446
- node.removeEventListener("touchstart", preventDefault);
447
- };
448
- }, []);
449
- function updateThumbFocus(focusIndex) {
450
- if (!import_constants.isWeb) return;
451
- var _iteratorNormalCompletion = true,
452
- _didIteratorError = false,
453
- _iteratorError = void 0;
454
- try {
455
- for (var _iterator = thumbRefs.current.entries()[Symbol.iterator](), _step; !(_iteratorNormalCompletion = (_step = _iterator.next()).done); _iteratorNormalCompletion = true) {
456
- var [node, index] = _step.value;
457
- if (index === focusIndex) {
458
- node.focus();
459
- return;
460
- }
461
- }
462
- } catch (err) {
463
- _didIteratorError = true;
464
- _iteratorError = err;
465
- } finally {
466
- try {
467
- if (!_iteratorNormalCompletion && _iterator.return != null) _iterator.return();
468
- } finally {
469
- if (_didIteratorError) throw _iteratorError;
470
- }
471
- }
472
- }
473
- function handleSlideMove(value2, event) {
474
- updateValues(value2, valueIndexToChangeRef.current);
475
- onSlideMove === null || onSlideMove === void 0 || onSlideMove(event, value2);
476
- }
477
- function updateValues(value2, atIndex) {
478
- var decimalCount = (0, import_helpers2.getDecimalCount)(step);
479
- var snapToStep = (0, import_helpers2.roundValue)(Math.round((value2 - min) / step) * step + min, decimalCount);
480
- var nextValue = (0, import_helpers.clamp)(snapToStep, [min, max]);
481
- setValues(function () {
482
- var prevValues = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : [];
483
- var nextValues = (0, import_helpers2.getNextSortedValues)(prevValues, nextValue, atIndex);
484
- if ((0, import_helpers2.hasMinStepsBetweenValues)(nextValues, minStepsBetweenThumbs * step)) {
485
- valueIndexToChangeRef.current = nextValues.indexOf(nextValue);
486
- return String(nextValues) === String(prevValues) ? prevValues : nextValues;
487
- }
488
- return prevValues;
489
- });
490
- }
491
- var SliderOriented = isHorizontal ? SliderHorizontal : SliderVertical;
492
- return /* @__PURE__ */(0, import_jsx_runtime.jsx)(import_constants2.SliderProvider, {
493
- scope: props.__scopeSlider,
494
- disabled,
495
- min,
496
- max,
497
- valueIndexToChangeRef,
498
- thumbs: thumbRefs.current,
499
- values,
500
- orientation,
501
- size: sizeProp,
502
- children: /* @__PURE__ */(0, import_jsx_runtime.jsx)(SliderOriented, {
503
- "aria-disabled": disabled,
504
- "data-disabled": disabled ? "" : void 0,
505
- ...sliderProps,
506
- ref: composedRefs,
507
- min,
508
- max,
509
- onSlideEnd,
510
- onSlideStart: disabled ? void 0 : function (value2, target, event) {
511
- if (target !== "thumb") updateValues(value2, (0, import_helpers2.getClosestValueIndex)(values, value2));
512
- onSlideStart === null || onSlideStart === void 0 || onSlideStart(event, value2, target);
513
- },
514
- onSlideMove: disabled ? void 0 : handleSlideMove,
515
- onHomeKeyDown: function () {
516
- return !disabled && updateValues(min, 0);
517
- },
518
- onEndKeyDown: function () {
519
- return !disabled && updateValues(max, values.length - 1);
520
- },
521
- onStepKeyDown: function (param) {
522
- var {
523
- event,
524
- direction: stepDirection
525
- } = param;
526
- if (!disabled) {
527
- var multiplier = import_constants2.PAGE_KEYS.includes(event.key) || event.shiftKey && import_constants2.ARROW_KEYS.includes(event.key) ? 10 : 1;
528
- var atIndex = valueIndexToChangeRef.current;
529
- var value2 = values[atIndex];
530
- updateValues(value2 + step * multiplier * stepDirection, atIndex);
531
- }
532
- }
533
- })
534
- });
271
+ var SliderThumb = (0, import_core.createStyledHOC)(SliderThumbFrame, function SliderThumb2(props, forwardedRef) {
272
+ var { __scopeSlider, index = 0, circular, size: sizeProp, ...thumbProps } = props;
273
+ var context = (0, import_constants2.useSliderContext)(__scopeSlider);
274
+ var orientation = (0, import_constants2.useSliderOrientationContext)(__scopeSlider);
275
+ var [thumb, setThumb] = React.useState(null);
276
+ var composedRefs = (0, import_compose_refs.useComposedRefs)(forwardedRef, setThumb);
277
+ var value = context.values[index];
278
+ var percent = value === void 0 ? 0 : (0, import_helpers2.convertValueToPercentage)(value, context.min, context.max);
279
+ var label = (0, import_helpers2.getLabel)(index, context.values.length);
280
+ var _ref;
281
+ var sizeIn = (_ref = sizeProp !== null && sizeProp !== void 0 ? sizeProp : context.size) !== null && _ref !== void 0 ? _ref : true;
282
+ var [size, setSize] = React.useState(function() {
283
+ return (0, import_core.getVariableValue)(getThumbSize(sizeIn).width);
284
+ });
285
+ var thumbInBoundsOffset = size ? (0, import_helpers2.getThumbInBoundsOffset)(size, percent, orientation.direction) : 0;
286
+ React.useEffect(function() {
287
+ if (thumb) {
288
+ context.thumbs.set(thumb, index);
289
+ return function() {
290
+ context.thumbs.delete(thumb);
291
+ };
292
+ }
293
+ }, [
294
+ thumb,
295
+ context.thumbs,
296
+ index
297
+ ]);
298
+ var positionalStyles = context.orientation === "horizontal" ? {
299
+ x: (thumbInBoundsOffset - size / 2) * orientation.direction,
300
+ y: -size / 2,
301
+ top: "50%",
302
+ ...size === 0 && {
303
+ top: "auto",
304
+ bottom: "auto"
305
+ }
306
+ } : {
307
+ x: -size / 2,
308
+ y: size / 2,
309
+ left: "50%",
310
+ ...size === 0 && {
311
+ left: "auto",
312
+ right: "auto"
313
+ }
314
+ };
315
+ return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(SliderThumbFrame, {
316
+ ref: composedRefs,
317
+ role: "slider",
318
+ "aria-label": props["aria-label"] || label,
319
+ "aria-valuemin": context.min,
320
+ "aria-valuenow": value,
321
+ "aria-valuemax": context.max,
322
+ "aria-orientation": context.orientation,
323
+ "data-orientation": context.orientation,
324
+ "data-disabled": context.disabled ? "" : void 0,
325
+ tabIndex: context.disabled ? void 0 : 0,
326
+ animateOnly: [
327
+ "transform",
328
+ "left",
329
+ "top",
330
+ "right",
331
+ "bottom"
332
+ ],
333
+ ...positionalStyles,
334
+ [orientation.startEdge]: `${percent}%`,
335
+ size: sizeIn,
336
+ circular,
337
+ ...thumbProps,
338
+ onLayout: function(e) {
339
+ setSize(e.nativeEvent.layout[orientation.sizeProp]);
340
+ },
341
+ onFocus: (0, import_helpers.composeEventHandlers)(props.onFocus, function() {
342
+ context.valueIndexToChangeRef.current = index;
343
+ })
344
+ });
345
+ }, { staticConfig: { memo: true } });
346
+ var SliderComponent = (0, import_core.createRefComponent)(function(props, forwardedRef) {
347
+ var { name, min = 0, max = 100, step = 1, orientation = "horizontal", disabled = false, minStepsBetweenThumbs = 0, defaultValue = [min], value, onValueChange = function() {}, size: sizeProp, onSlideEnd, onSlideMove, onSlideStart, ...sliderProps } = props;
348
+ var sliderRef = React.useRef(null);
349
+ var composedRefs = (0, import_compose_refs.useComposedRefs)(sliderRef, forwardedRef);
350
+ var thumbRefs = React.useRef(/* @__PURE__ */ new Map());
351
+ var valueIndexToChangeRef = React.useRef(0);
352
+ var isHorizontal = orientation === "horizontal";
353
+ var [values = [], setValues] = (0, import_use_controllable_state.useControllableState)({
354
+ prop: value,
355
+ defaultProp: defaultValue,
356
+ transition: true,
357
+ onChange: function(value2) {
358
+ updateThumbFocus(valueIndexToChangeRef.current);
359
+ onValueChange(value2);
360
+ }
361
+ });
362
+ if (import_constants.isWeb) React.useEffect(function() {
363
+ var node = sliderRef.current;
364
+ if (!node) return;
365
+ var preventDefault = function(e) {
366
+ e.preventDefault();
367
+ };
368
+ node.addEventListener("touchstart", preventDefault);
369
+ return function() {
370
+ node.removeEventListener("touchstart", preventDefault);
371
+ };
372
+ }, []);
373
+ function updateThumbFocus(focusIndex) {
374
+ if (!import_constants.isWeb) return;
375
+ var _iteratorNormalCompletion = true, _didIteratorError = false, _iteratorError = void 0;
376
+ try {
377
+ for (var _iterator = thumbRefs.current.entries()[Symbol.iterator](), _step; !(_iteratorNormalCompletion = (_step = _iterator.next()).done); _iteratorNormalCompletion = true) {
378
+ var [node, index] = _step.value;
379
+ if (index === focusIndex) {
380
+ node.focus();
381
+ return;
382
+ }
383
+ }
384
+ } catch (err) {
385
+ _didIteratorError = true;
386
+ _iteratorError = err;
387
+ } finally {
388
+ try {
389
+ if (!_iteratorNormalCompletion && _iterator.return != null) _iterator.return();
390
+ } finally {
391
+ if (_didIteratorError) throw _iteratorError;
392
+ }
393
+ }
394
+ }
395
+ function handleSlideMove(value2, event) {
396
+ updateValues(value2, valueIndexToChangeRef.current);
397
+ onSlideMove === null || onSlideMove === void 0 || onSlideMove(event, value2);
398
+ }
399
+ function updateValues(value2, atIndex) {
400
+ var decimalCount = (0, import_helpers2.getDecimalCount)(step);
401
+ var snapToStep = (0, import_helpers2.roundValue)(Math.round((value2 - min) / step) * step + min, decimalCount);
402
+ var nextValue = (0, import_helpers.clamp)(snapToStep, [min, max]);
403
+ setValues(function() {
404
+ var prevValues = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : [];
405
+ var nextValues = (0, import_helpers2.getNextSortedValues)(prevValues, nextValue, atIndex);
406
+ if ((0, import_helpers2.hasMinStepsBetweenValues)(nextValues, minStepsBetweenThumbs * step)) {
407
+ valueIndexToChangeRef.current = nextValues.indexOf(nextValue);
408
+ return String(nextValues) === String(prevValues) ? prevValues : nextValues;
409
+ }
410
+ return prevValues;
411
+ });
412
+ }
413
+ var SliderOriented = isHorizontal ? SliderHorizontal : SliderVertical;
414
+ return /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(import_constants2.SliderProvider, {
415
+ scope: props.__scopeSlider,
416
+ disabled,
417
+ min,
418
+ max,
419
+ valueIndexToChangeRef,
420
+ thumbs: thumbRefs.current,
421
+ values,
422
+ orientation,
423
+ size: sizeProp,
424
+ children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)(SliderOriented, {
425
+ "aria-disabled": disabled,
426
+ "data-disabled": disabled ? "" : void 0,
427
+ ...sliderProps,
428
+ ref: composedRefs,
429
+ min,
430
+ max,
431
+ onSlideEnd,
432
+ onSlideStart: disabled ? void 0 : function(value2, target, event) {
433
+ if (target !== "thumb") updateValues(value2, (0, import_helpers2.getClosestValueIndex)(values, value2));
434
+ onSlideStart === null || onSlideStart === void 0 || onSlideStart(event, value2, target);
435
+ },
436
+ onSlideMove: disabled ? void 0 : handleSlideMove,
437
+ onHomeKeyDown: function() {
438
+ return !disabled && updateValues(min, 0);
439
+ },
440
+ onEndKeyDown: function() {
441
+ return !disabled && updateValues(max, values.length - 1);
442
+ },
443
+ onStepKeyDown: function(param) {
444
+ var { event, direction: stepDirection } = param;
445
+ if (!disabled) {
446
+ var multiplier = import_constants2.PAGE_KEYS.includes(event.key) || event.shiftKey && import_constants2.ARROW_KEYS.includes(event.key) ? 10 : 1;
447
+ var atIndex = valueIndexToChangeRef.current;
448
+ var value2 = values[atIndex];
449
+ updateValues(value2 + step * multiplier * stepDirection, atIndex);
450
+ }
451
+ }
452
+ }), import_constants.isWeb && name && values.map(function(value2, index) {
453
+ return /* @__PURE__ */ (0, import_jsx_runtime.jsx)("input", {
454
+ type: "hidden",
455
+ name,
456
+ value: value2
457
+ }, index);
458
+ })]
459
+ });
535
460
  });
536
461
  var Slider = (0, import_helpers.withStaticProperties)(SliderComponent, {
537
- Track: SliderTrack,
538
- TrackActive: SliderActive,
539
- Thumb: SliderThumb
462
+ Track: SliderTrack,
463
+ TrackActive: SliderActive,
464
+ Thumb: SliderThumb
540
465
  });
541
466
  Slider.displayName = import_constants2.SLIDER_NAME;
542
467
  var Track = SliderTrack;
543
468
  var Range = SliderActive;
544
469
  var Thumb = SliderThumb;
470
+
545
471
  //# sourceMappingURL=Slider.native.js.map