@micromag/core 0.4.110 → 0.4.113
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/es/contexts.js +1 -1
- package/es/hooks.js +52 -34
- package/package.json +2 -2
package/es/contexts.js
CHANGED
|
@@ -196,7 +196,7 @@ function ComponentsProvider(t0) {
|
|
|
196
196
|
const messages = defineMessages({
|
|
197
197
|
functionality_title: {
|
|
198
198
|
id: "consent.functionality_title",
|
|
199
|
-
defaultMessage: "
|
|
199
|
+
defaultMessage: "Functional"
|
|
200
200
|
},
|
|
201
201
|
functionality_description: {
|
|
202
202
|
id: "consent.functionality_description",
|
package/es/hooks.js
CHANGED
|
@@ -259,7 +259,7 @@ const defaultDragOptions = {
|
|
|
259
259
|
filterTaps: true
|
|
260
260
|
};
|
|
261
261
|
function useDragProgress(t0) {
|
|
262
|
-
const $ = c(
|
|
262
|
+
const $ = c(40);
|
|
263
263
|
const {
|
|
264
264
|
progress: wantedProgress,
|
|
265
265
|
onTap: t1,
|
|
@@ -396,37 +396,55 @@ function useDragProgress(t0) {
|
|
|
396
396
|
t15 = $[16];
|
|
397
397
|
}
|
|
398
398
|
const onDrag = t15;
|
|
399
|
-
|
|
400
|
-
|
|
399
|
+
let t16;
|
|
400
|
+
if ($[17] !== onPointerDown) {
|
|
401
|
+
t16 = onPointerDown !== null ? {
|
|
402
|
+
onPointerDown
|
|
403
|
+
} : null;
|
|
404
|
+
$[17] = onPointerDown;
|
|
405
|
+
$[18] = t16;
|
|
406
|
+
} else {
|
|
407
|
+
t16 = $[18];
|
|
408
|
+
}
|
|
409
|
+
let t17;
|
|
410
|
+
if ($[19] !== onScroll) {
|
|
411
|
+
t17 = onScroll !== null ? {
|
|
412
|
+
onScroll
|
|
413
|
+
} : null;
|
|
414
|
+
$[19] = onScroll;
|
|
415
|
+
$[20] = t17;
|
|
416
|
+
} else {
|
|
417
|
+
t17 = $[20];
|
|
418
|
+
}
|
|
401
419
|
let t18;
|
|
402
|
-
if ($[
|
|
420
|
+
if ($[21] !== onDrag || $[22] !== t16 || $[23] !== t17) {
|
|
403
421
|
t18 = {
|
|
404
422
|
onDrag,
|
|
405
|
-
|
|
406
|
-
|
|
423
|
+
...t16,
|
|
424
|
+
...t17
|
|
407
425
|
};
|
|
408
|
-
$[
|
|
409
|
-
$[
|
|
410
|
-
$[
|
|
411
|
-
$[
|
|
426
|
+
$[21] = onDrag;
|
|
427
|
+
$[22] = t16;
|
|
428
|
+
$[23] = t17;
|
|
429
|
+
$[24] = t18;
|
|
412
430
|
} else {
|
|
413
|
-
t18 = $[
|
|
431
|
+
t18 = $[24];
|
|
414
432
|
}
|
|
415
433
|
let t19;
|
|
416
|
-
if ($[
|
|
434
|
+
if ($[25] !== dragOptions) {
|
|
417
435
|
t19 = {
|
|
418
436
|
drag: dragOptions
|
|
419
437
|
};
|
|
420
|
-
$[
|
|
421
|
-
$[
|
|
438
|
+
$[25] = dragOptions;
|
|
439
|
+
$[26] = t19;
|
|
422
440
|
} else {
|
|
423
|
-
t19 = $[
|
|
441
|
+
t19 = $[26];
|
|
424
442
|
}
|
|
425
443
|
const bind = useGesture(t18, t19);
|
|
426
444
|
const [lastWantedProgress, setLastWantedProgress] = useState(wantedProgress);
|
|
427
445
|
let t20;
|
|
428
446
|
let t21;
|
|
429
|
-
if ($[
|
|
447
|
+
if ($[27] !== api || $[28] !== disabled || $[29] !== onResolve || $[30] !== springParams || $[31] !== wantedProgress) {
|
|
430
448
|
t20 = () => {
|
|
431
449
|
if (!draggingRef.current && wantedProgress !== progressRef.current) {
|
|
432
450
|
setDirection(wantedProgress < progressRef.current ? -1 : 1);
|
|
@@ -448,22 +466,22 @@ function useDragProgress(t0) {
|
|
|
448
466
|
}
|
|
449
467
|
};
|
|
450
468
|
t21 = [api, wantedProgress, disabled, onResolve, springParams, onTransitionStart, onTransitionComplete];
|
|
451
|
-
$[
|
|
452
|
-
$[
|
|
453
|
-
$[
|
|
454
|
-
$[
|
|
455
|
-
$[
|
|
456
|
-
$[
|
|
457
|
-
$[
|
|
469
|
+
$[27] = api;
|
|
470
|
+
$[28] = disabled;
|
|
471
|
+
$[29] = onResolve;
|
|
472
|
+
$[30] = springParams;
|
|
473
|
+
$[31] = wantedProgress;
|
|
474
|
+
$[32] = t20;
|
|
475
|
+
$[33] = t21;
|
|
458
476
|
} else {
|
|
459
|
-
t20 = $[
|
|
460
|
-
t21 = $[
|
|
477
|
+
t20 = $[32];
|
|
478
|
+
t21 = $[33];
|
|
461
479
|
}
|
|
462
480
|
useEffect(t20, t21);
|
|
463
481
|
const transitioning = progress.isAnimating || dragging || !transitioned;
|
|
464
482
|
const t22 = wantedProgress !== lastWantedProgress ? wantedProgress < lastWantedProgress ? -1 : 1 : direction;
|
|
465
483
|
let t23;
|
|
466
|
-
if ($[
|
|
484
|
+
if ($[34] !== bind || $[35] !== dragging || $[36] !== progress || $[37] !== t22 || $[38] !== transitioning) {
|
|
467
485
|
t23 = {
|
|
468
486
|
transitioning,
|
|
469
487
|
bind,
|
|
@@ -471,14 +489,14 @@ function useDragProgress(t0) {
|
|
|
471
489
|
progress,
|
|
472
490
|
direction: t22
|
|
473
491
|
};
|
|
474
|
-
$[
|
|
475
|
-
$[
|
|
476
|
-
$[
|
|
477
|
-
$[
|
|
478
|
-
$[
|
|
479
|
-
$[
|
|
480
|
-
} else {
|
|
481
|
-
t23 = $[
|
|
492
|
+
$[34] = bind;
|
|
493
|
+
$[35] = dragging;
|
|
494
|
+
$[36] = progress;
|
|
495
|
+
$[37] = t22;
|
|
496
|
+
$[38] = transitioning;
|
|
497
|
+
$[39] = t23;
|
|
498
|
+
} else {
|
|
499
|
+
t23 = $[39];
|
|
482
500
|
}
|
|
483
501
|
return t23;
|
|
484
502
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@micromag/core",
|
|
3
|
-
"version": "0.4.
|
|
3
|
+
"version": "0.4.113",
|
|
4
4
|
"private": false,
|
|
5
5
|
"description": "",
|
|
6
6
|
"keywords": [
|
|
@@ -161,5 +161,5 @@
|
|
|
161
161
|
"access": "public",
|
|
162
162
|
"registry": "https://registry.npmjs.org/"
|
|
163
163
|
},
|
|
164
|
-
"gitHead": "
|
|
164
|
+
"gitHead": "c5d9e3ac8153791975e6686c1a6e7b75fea76c22"
|
|
165
165
|
}
|