@jsenv/dom 0.17.33 → 0.17.35
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/dist/jsenv_dom.js +382 -478
- package/package.json +1 -1
package/dist/jsenv_dom.js
CHANGED
|
@@ -4896,9 +4896,18 @@ const findFocusable = (element, { exclude } = {}) => {
|
|
|
4896
4896
|
return focusableDescendant;
|
|
4897
4897
|
};
|
|
4898
4898
|
|
|
4899
|
-
//
|
|
4900
|
-
//
|
|
4901
|
-
//
|
|
4899
|
+
// `hidden` and `clip` both cut the content off and are two different things
|
|
4900
|
+
// here, which is what `includeHidden` is about:
|
|
4901
|
+
// - `hidden` IS a scroll container. Nothing scrolls it by hand, but keyboard
|
|
4902
|
+
// arrows and scrollTop/scrollLeft do, so whoever cares where an element can
|
|
4903
|
+
// be brought into view has to count it.
|
|
4904
|
+
// - `clip` is not one. It clips and stops there: it has no scroll box at all,
|
|
4905
|
+
// and scrollTop/scrollLeft on it read back 0 whatever they are set to. That
|
|
4906
|
+
// is the whole reason a layout reaches for it (see navi's
|
|
4907
|
+
// docs/MOBILE_LAYOUT_PITFALLS.md), so it is never included, whatever the
|
|
4908
|
+
// caller asks for.
|
|
4909
|
+
// `visible` is the other non-scrolling value, and the only one on which the
|
|
4910
|
+
// content still reaches the ancestors.
|
|
4902
4911
|
const isScrollable = (element, { includeHidden } = {}) => {
|
|
4903
4912
|
if (canHaveVerticalScroll(element, { includeHidden })) {
|
|
4904
4913
|
return true;
|
|
@@ -4940,7 +4949,10 @@ const canHaveVerticalScroll = (element, { includeHidden }) => {
|
|
|
4940
4949
|
}
|
|
4941
4950
|
return false;
|
|
4942
4951
|
}
|
|
4943
|
-
if (verticalOverflow === "
|
|
4952
|
+
if (verticalOverflow === "clip") {
|
|
4953
|
+
return false;
|
|
4954
|
+
}
|
|
4955
|
+
if (verticalOverflow === "hidden") {
|
|
4944
4956
|
return includeHidden;
|
|
4945
4957
|
}
|
|
4946
4958
|
const overflow = getStyle(element, "overflow");
|
|
@@ -4951,7 +4963,10 @@ const canHaveVerticalScroll = (element, { includeHidden }) => {
|
|
|
4951
4963
|
}
|
|
4952
4964
|
return false;
|
|
4953
4965
|
}
|
|
4954
|
-
if (overflow === "
|
|
4966
|
+
if (overflow === "clip") {
|
|
4967
|
+
return false;
|
|
4968
|
+
}
|
|
4969
|
+
if (overflow === "hidden") {
|
|
4955
4970
|
return includeHidden;
|
|
4956
4971
|
}
|
|
4957
4972
|
return true; // "auto", "scroll"
|
|
@@ -4965,7 +4980,10 @@ const canHaveHorizontalScroll = (element, { includeHidden }) => {
|
|
|
4965
4980
|
}
|
|
4966
4981
|
return false;
|
|
4967
4982
|
}
|
|
4968
|
-
if (horizontalOverflow === "
|
|
4983
|
+
if (horizontalOverflow === "clip") {
|
|
4984
|
+
return false;
|
|
4985
|
+
}
|
|
4986
|
+
if (horizontalOverflow === "hidden") {
|
|
4969
4987
|
return includeHidden;
|
|
4970
4988
|
}
|
|
4971
4989
|
const overflow = getStyle(element, "overflow");
|
|
@@ -4976,7 +4994,10 @@ const canHaveHorizontalScroll = (element, { includeHidden }) => {
|
|
|
4976
4994
|
}
|
|
4977
4995
|
return false;
|
|
4978
4996
|
}
|
|
4979
|
-
if (overflow === "
|
|
4997
|
+
if (overflow === "clip") {
|
|
4998
|
+
return false;
|
|
4999
|
+
}
|
|
5000
|
+
if (overflow === "hidden") {
|
|
4980
5001
|
return includeHidden;
|
|
4981
5002
|
}
|
|
4982
5003
|
return true; // "auto", "scroll"
|
|
@@ -8405,26 +8426,16 @@ installImportMetaCssBuild(import.meta);/**
|
|
|
8405
8426
|
* donc juste x/y ca seras surement mieux
|
|
8406
8427
|
*
|
|
8407
8428
|
*/
|
|
8408
|
-
const css$5 = /* css
|
|
8409
|
-
|
|
8410
|
-
|
|
8411
|
-
|
|
8412
|
-
|
|
8413
|
-
|
|
8414
|
-
|
|
8415
|
-
|
|
8416
|
-
|
|
8417
|
-
|
|
8418
|
-
gesture holds draws a ring around an object the user already has under the
|
|
8419
|
-
pointer — a frame blinking for the length of the gesture, saying something
|
|
8420
|
-
the finger knows. The ring stays whole where it earns its place: at the
|
|
8421
|
-
keyboard, outside any gesture.
|
|
8422
|
-
focus({ focusVisible: false }) would say the intent better but does not
|
|
8423
|
-
hold — Chrome's heuristic does not always obey the option (see
|
|
8424
|
-
isMatchingFocusVisible). */
|
|
8425
|
-
[data-drag-focus]:focus-visible {
|
|
8426
|
-
outline: none;
|
|
8427
|
-
}
|
|
8429
|
+
const css$5 = /* css */`.navi_drag_gesture_backdrop {
|
|
8430
|
+
touch-action: none;
|
|
8431
|
+
user-select: none;
|
|
8432
|
+
position: fixed;
|
|
8433
|
+
inset: 0;
|
|
8434
|
+
}
|
|
8435
|
+
|
|
8436
|
+
[data-drag-focus]:focus-visible {
|
|
8437
|
+
outline: none;
|
|
8438
|
+
}
|
|
8428
8439
|
`;
|
|
8429
8440
|
import.meta.css = [css$5, "@jsenv/dom/src/interaction/drag/drag_gesture.js"];
|
|
8430
8441
|
|
|
@@ -9451,45 +9462,30 @@ installImportMetaCssBuild(import.meta);/**
|
|
|
9451
9462
|
lets the page scroll and still makes the refusal effective — provided the
|
|
9452
9463
|
listener that will refuse is already known too, which is markDragSource's
|
|
9453
9464
|
half of the same rule. */
|
|
9454
|
-
const css$4 = /* css */`
|
|
9455
|
-
|
|
9456
|
-
|
|
9457
|
-
|
|
9458
|
-
|
|
9459
|
-
|
|
9460
|
-
|
|
9461
|
-
|
|
9462
|
-
|
|
9463
|
-
|
|
9464
|
-
|
|
9465
|
-
|
|
9466
|
-
|
|
9467
|
-
|
|
9468
|
-
|
|
9469
|
-
|
|
9470
|
-
|
|
9471
|
-
|
|
9472
|
-
|
|
9473
|
-
|
|
9474
|
-
|
|
9475
|
-
|
|
9476
|
-
|
|
9477
|
-
|
|
9478
|
-
}
|
|
9479
|
-
[data-drag-on-contact] [data-drag-source],
|
|
9480
|
-
[data-drag-source][data-drag-on-contact] {
|
|
9481
|
-
/* Nothing scrolls here, so there is no pan to leave to anyone — the finger
|
|
9482
|
-
may travel from the first pixel. Zoom is kept: it belongs to the reader,
|
|
9483
|
-
not to the gesture, and two fingers are never a drag. */
|
|
9484
|
-
touch-action: pinch-zoom;
|
|
9485
|
-
}
|
|
9486
|
-
[data-drag-ignore],
|
|
9487
|
-
[data-own-target],
|
|
9488
|
-
[data-drag-source] [popover],
|
|
9489
|
-
[data-drag-source] dialog {
|
|
9490
|
-
-webkit-touch-callout: default;
|
|
9491
|
-
touch-action: auto;
|
|
9492
|
-
}
|
|
9465
|
+
const css$4 = /* css */`[data-drag-handle], [data-drag-source] {
|
|
9466
|
+
-webkit-touch-callout: none;
|
|
9467
|
+
}
|
|
9468
|
+
|
|
9469
|
+
[data-drag-handle] {
|
|
9470
|
+
touch-action: none;
|
|
9471
|
+
}
|
|
9472
|
+
|
|
9473
|
+
[data-drag-source] {
|
|
9474
|
+
touch-action: pan-y pinch-zoom;
|
|
9475
|
+
}
|
|
9476
|
+
|
|
9477
|
+
[data-drag-source="x"] {
|
|
9478
|
+
touch-action: pan-x pinch-zoom;
|
|
9479
|
+
}
|
|
9480
|
+
|
|
9481
|
+
[data-drag-on-contact] [data-drag-source], [data-drag-source][data-drag-on-contact] {
|
|
9482
|
+
touch-action: pinch-zoom;
|
|
9483
|
+
}
|
|
9484
|
+
|
|
9485
|
+
[data-drag-ignore], [data-own-target], [data-drag-source] [popover], [data-drag-source] dialog {
|
|
9486
|
+
-webkit-touch-callout: default;
|
|
9487
|
+
touch-action: auto;
|
|
9488
|
+
}
|
|
9493
9489
|
`;
|
|
9494
9490
|
import.meta.css = [css$4, "@jsenv/dom/src/interaction/drag/drag_after_intent.js"];
|
|
9495
9491
|
|
|
@@ -10202,20 +10198,19 @@ const getDragCoordinates = (
|
|
|
10202
10198
|
return [leftRelativeToScrollContainer, topRelativeToScrollContainer];
|
|
10203
10199
|
};
|
|
10204
10200
|
|
|
10205
|
-
installImportMetaCssBuild(import.meta);const css$3 = /* css
|
|
10206
|
-
|
|
10207
|
-
|
|
10208
|
-
|
|
10209
|
-
|
|
10210
|
-
|
|
10211
|
-
|
|
10212
|
-
|
|
10213
|
-
|
|
10214
|
-
}
|
|
10201
|
+
installImportMetaCssBuild(import.meta);const css$3 = /* css */`.navi_constraint_feedback_line {
|
|
10202
|
+
z-index: 9998;
|
|
10203
|
+
visibility: hidden;
|
|
10204
|
+
transform-origin: 0;
|
|
10205
|
+
pointer-events: none;
|
|
10206
|
+
border-top: 2px dotted #3b82f6b3;
|
|
10207
|
+
transition: opacity .15s;
|
|
10208
|
+
position: fixed;
|
|
10209
|
+
}
|
|
10215
10210
|
|
|
10216
|
-
|
|
10217
|
-
|
|
10218
|
-
|
|
10211
|
+
.navi_constraint_feedback_line[data-visible] {
|
|
10212
|
+
visibility: visible;
|
|
10213
|
+
}
|
|
10219
10214
|
`;
|
|
10220
10215
|
const setupConstraintFeedbackLine = () => {
|
|
10221
10216
|
import.meta.css = [css$3, "@jsenv/dom/src/interaction/drag/constraint_feedback_line.js"];
|
|
@@ -10298,191 +10293,172 @@ let currentDebugMarkers = [];
|
|
|
10298
10293
|
let currentConstraintMarkers = [];
|
|
10299
10294
|
let currentReferenceElementMarker = null;
|
|
10300
10295
|
let currentElementMarker = null;
|
|
10301
|
-
const css$2 = /* css
|
|
10302
|
-
|
|
10303
|
-
|
|
10304
|
-
|
|
10305
|
-
|
|
10306
|
-
|
|
10307
|
-
|
|
10308
|
-
|
|
10309
|
-
|
|
10310
|
-
|
|
10311
|
-
|
|
10312
|
-
}
|
|
10313
|
-
|
|
10314
|
-
.navi_debug_marker {
|
|
10315
|
-
position: absolute;
|
|
10316
|
-
pointer-events: none;
|
|
10317
|
-
}
|
|
10318
|
-
|
|
10319
|
-
/* Markers based on side rather than orientation */
|
|
10320
|
-
.navi_debug_marker[data-left],
|
|
10321
|
-
.navi_debug_marker[data-right] {
|
|
10322
|
-
width: var(--marker-size);
|
|
10323
|
-
height: 100vh;
|
|
10324
|
-
}
|
|
10325
|
-
|
|
10326
|
-
.navi_debug_marker[data-top],
|
|
10327
|
-
.navi_debug_marker[data-bottom] {
|
|
10328
|
-
width: 100vw;
|
|
10329
|
-
height: var(--marker-size);
|
|
10330
|
-
}
|
|
10331
|
-
|
|
10332
|
-
/* Gradient directions based on side, using CSS custom properties for color */
|
|
10333
|
-
.navi_debug_marker[data-left] {
|
|
10334
|
-
background: linear-gradient(
|
|
10335
|
-
to right,
|
|
10336
|
-
rgba(from var(--marker-color) r g b / 0.9) 0%,
|
|
10337
|
-
rgba(from var(--marker-color) r g b / 0.7) 30%,
|
|
10338
|
-
rgba(from var(--marker-color) r g b / 0.3) 70%,
|
|
10339
|
-
rgba(from var(--marker-color) r g b / 0) 100%
|
|
10340
|
-
);
|
|
10341
|
-
}
|
|
10296
|
+
const css$2 = /* css */`.navi_debug_markers_container {
|
|
10297
|
+
z-index: 999998;
|
|
10298
|
+
pointer-events: none;
|
|
10299
|
+
--marker-size: ${MARKER_SIZE}px;
|
|
10300
|
+
width: 100vw;
|
|
10301
|
+
height: 100vh;
|
|
10302
|
+
position: fixed;
|
|
10303
|
+
top: 0;
|
|
10304
|
+
left: 0;
|
|
10305
|
+
overflow: hidden;
|
|
10306
|
+
}
|
|
10342
10307
|
|
|
10343
|
-
|
|
10344
|
-
|
|
10345
|
-
|
|
10346
|
-
|
|
10347
|
-
rgba(from var(--marker-color) r g b / 0.7) 30%,
|
|
10348
|
-
rgba(from var(--marker-color) r g b / 0.3) 70%,
|
|
10349
|
-
rgba(from var(--marker-color) r g b / 0) 100%
|
|
10350
|
-
);
|
|
10351
|
-
}
|
|
10308
|
+
.navi_debug_marker {
|
|
10309
|
+
pointer-events: none;
|
|
10310
|
+
position: absolute;
|
|
10311
|
+
}
|
|
10352
10312
|
|
|
10353
|
-
|
|
10354
|
-
|
|
10355
|
-
|
|
10356
|
-
|
|
10357
|
-
rgba(from var(--marker-color) r g b / 0.7) 30%,
|
|
10358
|
-
rgba(from var(--marker-color) r g b / 0.3) 70%,
|
|
10359
|
-
rgba(from var(--marker-color) r g b / 0) 100%
|
|
10360
|
-
);
|
|
10361
|
-
}
|
|
10313
|
+
.navi_debug_marker[data-left], .navi_debug_marker[data-right] {
|
|
10314
|
+
width: var(--marker-size);
|
|
10315
|
+
height: 100vh;
|
|
10316
|
+
}
|
|
10362
10317
|
|
|
10363
|
-
|
|
10364
|
-
|
|
10365
|
-
|
|
10366
|
-
|
|
10367
|
-
rgba(from var(--marker-color) r g b / 0.7) 30%,
|
|
10368
|
-
rgba(from var(--marker-color) r g b / 0.3) 70%,
|
|
10369
|
-
rgba(from var(--marker-color) r g b / 0) 100%
|
|
10370
|
-
);
|
|
10371
|
-
}
|
|
10318
|
+
.navi_debug_marker[data-top], .navi_debug_marker[data-bottom] {
|
|
10319
|
+
width: 100vw;
|
|
10320
|
+
height: var(--marker-size);
|
|
10321
|
+
}
|
|
10372
10322
|
|
|
10373
|
-
|
|
10374
|
-
|
|
10375
|
-
|
|
10376
|
-
|
|
10377
|
-
|
|
10378
|
-
|
|
10379
|
-
|
|
10380
|
-
|
|
10381
|
-
|
|
10382
|
-
|
|
10383
|
-
|
|
10384
|
-
|
|
10385
|
-
|
|
10386
|
-
|
|
10387
|
-
|
|
10388
|
-
|
|
10389
|
-
|
|
10390
|
-
|
|
10391
|
-
|
|
10392
|
-
|
|
10393
|
-
|
|
10394
|
-
|
|
10395
|
-
|
|
10396
|
-
|
|
10397
|
-
|
|
10398
|
-
|
|
10399
|
-
|
|
10400
|
-
|
|
10401
|
-
|
|
10402
|
-
|
|
10403
|
-
|
|
10404
|
-
|
|
10405
|
-
|
|
10406
|
-
|
|
10407
|
-
|
|
10408
|
-
|
|
10409
|
-
|
|
10410
|
-
|
|
10411
|
-
|
|
10412
|
-
|
|
10413
|
-
|
|
10414
|
-
|
|
10415
|
-
|
|
10416
|
-
|
|
10417
|
-
|
|
10418
|
-
|
|
10419
|
-
|
|
10420
|
-
|
|
10421
|
-
|
|
10422
|
-
|
|
10423
|
-
|
|
10424
|
-
|
|
10425
|
-
|
|
10426
|
-
|
|
10427
|
-
|
|
10428
|
-
|
|
10429
|
-
|
|
10430
|
-
|
|
10431
|
-
|
|
10432
|
-
|
|
10433
|
-
|
|
10434
|
-
|
|
10435
|
-
|
|
10436
|
-
|
|
10437
|
-
|
|
10438
|
-
|
|
10439
|
-
|
|
10440
|
-
|
|
10441
|
-
|
|
10442
|
-
|
|
10443
|
-
|
|
10444
|
-
|
|
10445
|
-
|
|
10446
|
-
|
|
10447
|
-
|
|
10448
|
-
|
|
10449
|
-
|
|
10450
|
-
|
|
10451
|
-
|
|
10452
|
-
|
|
10453
|
-
|
|
10454
|
-
|
|
10455
|
-
|
|
10456
|
-
|
|
10457
|
-
|
|
10458
|
-
|
|
10459
|
-
|
|
10460
|
-
|
|
10461
|
-
|
|
10462
|
-
|
|
10463
|
-
|
|
10464
|
-
|
|
10465
|
-
|
|
10466
|
-
|
|
10467
|
-
|
|
10468
|
-
|
|
10469
|
-
|
|
10470
|
-
|
|
10471
|
-
|
|
10472
|
-
|
|
10473
|
-
|
|
10474
|
-
|
|
10475
|
-
|
|
10476
|
-
|
|
10477
|
-
|
|
10478
|
-
|
|
10479
|
-
|
|
10480
|
-
|
|
10481
|
-
|
|
10482
|
-
|
|
10483
|
-
|
|
10484
|
-
|
|
10485
|
-
|
|
10323
|
+
.navi_debug_marker[data-left] {
|
|
10324
|
+
background: linear-gradient(to right,
|
|
10325
|
+
rgba(from var(--marker-color) r g b / .9) 0%,
|
|
10326
|
+
rgba(from var(--marker-color) r g b / .7) 30%,
|
|
10327
|
+
rgba(from var(--marker-color) r g b / .3) 70%,
|
|
10328
|
+
rgba(from var(--marker-color) r g b / 0) 100%);
|
|
10329
|
+
}
|
|
10330
|
+
|
|
10331
|
+
.navi_debug_marker[data-right] {
|
|
10332
|
+
background: linear-gradient(to left,
|
|
10333
|
+
rgba(from var(--marker-color) r g b / .9) 0%,
|
|
10334
|
+
rgba(from var(--marker-color) r g b / .7) 30%,
|
|
10335
|
+
rgba(from var(--marker-color) r g b / .3) 70%,
|
|
10336
|
+
rgba(from var(--marker-color) r g b / 0) 100%);
|
|
10337
|
+
}
|
|
10338
|
+
|
|
10339
|
+
.navi_debug_marker[data-top] {
|
|
10340
|
+
background: linear-gradient(to bottom,
|
|
10341
|
+
rgba(from var(--marker-color) r g b / .9) 0%,
|
|
10342
|
+
rgba(from var(--marker-color) r g b / .7) 30%,
|
|
10343
|
+
rgba(from var(--marker-color) r g b / .3) 70%,
|
|
10344
|
+
rgba(from var(--marker-color) r g b / 0) 100%);
|
|
10345
|
+
}
|
|
10346
|
+
|
|
10347
|
+
.navi_debug_marker[data-bottom] {
|
|
10348
|
+
background: linear-gradient(to top,
|
|
10349
|
+
rgba(from var(--marker-color) r g b / .9) 0%,
|
|
10350
|
+
rgba(from var(--marker-color) r g b / .7) 30%,
|
|
10351
|
+
rgba(from var(--marker-color) r g b / .3) 70%,
|
|
10352
|
+
rgba(from var(--marker-color) r g b / 0) 100%);
|
|
10353
|
+
}
|
|
10354
|
+
|
|
10355
|
+
.navi_debug_marker_label {
|
|
10356
|
+
color: rgb(from var(--marker-color) r g b / 1);
|
|
10357
|
+
white-space: nowrap;
|
|
10358
|
+
border: 1px solid;
|
|
10359
|
+
border-color: rgb(from var(--marker-color) r g b / 1);
|
|
10360
|
+
pointer-events: none;
|
|
10361
|
+
background: #ffffffe6;
|
|
10362
|
+
border-radius: 3px;
|
|
10363
|
+
padding: 2px 6px;
|
|
10364
|
+
font-size: 12px;
|
|
10365
|
+
font-weight: bold;
|
|
10366
|
+
position: absolute;
|
|
10367
|
+
}
|
|
10368
|
+
|
|
10369
|
+
.navi_debug_marker[data-left] .navi_debug_marker_label {
|
|
10370
|
+
transform-origin: 0;
|
|
10371
|
+
top: 20px;
|
|
10372
|
+
left: 10px;
|
|
10373
|
+
transform: rotate(90deg);
|
|
10374
|
+
}
|
|
10375
|
+
|
|
10376
|
+
.navi_debug_marker[data-right] .navi_debug_marker_label {
|
|
10377
|
+
transform-origin: 100%;
|
|
10378
|
+
top: 20px;
|
|
10379
|
+
left: auto;
|
|
10380
|
+
right: 10px;
|
|
10381
|
+
transform: rotate(-90deg);
|
|
10382
|
+
}
|
|
10383
|
+
|
|
10384
|
+
.navi_debug_marker[data-top] .navi_debug_marker_label {
|
|
10385
|
+
top: 0;
|
|
10386
|
+
left: 20px;
|
|
10387
|
+
}
|
|
10388
|
+
|
|
10389
|
+
.navi_debug_marker[data-bottom] .navi_debug_marker_label {
|
|
10390
|
+
top: auto;
|
|
10391
|
+
bottom: 0;
|
|
10392
|
+
left: 20px;
|
|
10393
|
+
}
|
|
10394
|
+
|
|
10395
|
+
.navi_obstacle_marker {
|
|
10396
|
+
z-index: 9999;
|
|
10397
|
+
opacity: .6;
|
|
10398
|
+
pointer-events: none;
|
|
10399
|
+
background-color: orange;
|
|
10400
|
+
position: absolute;
|
|
10401
|
+
}
|
|
10402
|
+
|
|
10403
|
+
.navi_obstacle_marker_label {
|
|
10404
|
+
color: #fff;
|
|
10405
|
+
text-shadow: 1px 1px 1px #000c;
|
|
10406
|
+
pointer-events: none;
|
|
10407
|
+
font-size: 12px;
|
|
10408
|
+
font-weight: bold;
|
|
10409
|
+
position: absolute;
|
|
10410
|
+
top: 50%;
|
|
10411
|
+
left: 50%;
|
|
10412
|
+
transform: translate(-50%, -50%);
|
|
10413
|
+
}
|
|
10414
|
+
|
|
10415
|
+
.navi_element_marker {
|
|
10416
|
+
z-index: 9997;
|
|
10417
|
+
background-color: var(--element-color-alpha, #ff00964d);
|
|
10418
|
+
border: 2px solid var(--element-color, #ff0096);
|
|
10419
|
+
opacity: .9;
|
|
10420
|
+
pointer-events: none;
|
|
10421
|
+
position: absolute;
|
|
10422
|
+
}
|
|
10423
|
+
|
|
10424
|
+
.navi_element_marker_label {
|
|
10425
|
+
color: var(--element-color, #ff0096);
|
|
10426
|
+
white-space: nowrap;
|
|
10427
|
+
border: 1px solid var(--element-color, #ff0096);
|
|
10428
|
+
pointer-events: none;
|
|
10429
|
+
background: #ffffffe6;
|
|
10430
|
+
border-radius: 3px;
|
|
10431
|
+
padding: 2px 6px;
|
|
10432
|
+
font-size: 11px;
|
|
10433
|
+
font-weight: bold;
|
|
10434
|
+
position: absolute;
|
|
10435
|
+
top: -25px;
|
|
10436
|
+
right: 0;
|
|
10437
|
+
}
|
|
10438
|
+
|
|
10439
|
+
.navi_reference_element_marker {
|
|
10440
|
+
z-index: 9998;
|
|
10441
|
+
opacity: .8;
|
|
10442
|
+
pointer-events: none;
|
|
10443
|
+
background-color: #0096ff4d;
|
|
10444
|
+
border: 2px dashed #0096ffb3;
|
|
10445
|
+
position: absolute;
|
|
10446
|
+
}
|
|
10447
|
+
|
|
10448
|
+
.navi_reference_element_marker_label {
|
|
10449
|
+
color: #0096ff;
|
|
10450
|
+
white-space: nowrap;
|
|
10451
|
+
pointer-events: none;
|
|
10452
|
+
background: #ffffffe6;
|
|
10453
|
+
border: 1px solid #0096ffb3;
|
|
10454
|
+
border-radius: 3px;
|
|
10455
|
+
padding: 2px 6px;
|
|
10456
|
+
font-size: 11px;
|
|
10457
|
+
font-weight: bold;
|
|
10458
|
+
position: absolute;
|
|
10459
|
+
top: -25px;
|
|
10460
|
+
left: 0;
|
|
10461
|
+
}
|
|
10486
10462
|
`;
|
|
10487
10463
|
const setupDragDebugMarkers = (dragGesture, {
|
|
10488
10464
|
referenceElement
|
|
@@ -11818,222 +11794,151 @@ const dragStyleController = createStyleController("drag_to_move");
|
|
|
11818
11794
|
const TOSS_DURATION_MS = 320;
|
|
11819
11795
|
// Far enough to be off any screen, in the direction the hand was going.
|
|
11820
11796
|
const TOSS_DISTANCE = 900;
|
|
11821
|
-
const css$1 = /* css
|
|
11822
|
-
|
|
11823
|
-
|
|
11824
|
-
|
|
11825
|
-
|
|
11826
|
-
|
|
11827
|
-
|
|
11828
|
-
|
|
11829
|
-
|
|
11830
|
-
|
|
11831
|
-
|
|
11832
|
-
|
|
11833
|
-
|
|
11834
|
-
|
|
11835
|
-
|
|
11836
|
-
|
|
11837
|
-
|
|
11838
|
-
|
|
11839
|
-
|
|
11840
|
-
|
|
11841
|
-
|
|
11842
|
-
|
|
11843
|
-
|
|
11844
|
-
|
|
11845
|
-
|
|
11846
|
-
|
|
11847
|
-
|
|
11848
|
-
|
|
11849
|
-
|
|
11850
|
-
|
|
11851
|
-
|
|
11852
|
-
|
|
11853
|
-
|
|
11854
|
-
|
|
11855
|
-
|
|
11856
|
-
|
|
11857
|
-
|
|
11858
|
-
|
|
11859
|
-
|
|
11860
|
-
|
|
11861
|
-
|
|
11862
|
-
|
|
11863
|
-
|
|
11864
|
-
|
|
11865
|
-
|
|
11866
|
-
|
|
11867
|
-
|
|
11868
|
-
|
|
11869
|
-
|
|
11870
|
-
|
|
11871
|
-
|
|
11872
|
-
|
|
11873
|
-
|
|
11874
|
-
|
|
11875
|
-
|
|
11876
|
-
|
|
11877
|
-
|
|
11878
|
-
|
|
11879
|
-
|
|
11880
|
-
|
|
11881
|
-
|
|
11882
|
-
|
|
11883
|
-
|
|
11884
|
-
|
|
11885
|
-
|
|
11886
|
-
rotate: -90deg;
|
|
11887
|
-
}
|
|
11888
|
-
.navi_drop_hint_cap[data-side="end"] {
|
|
11889
|
-
right: calc(-1 * var(--drop-hint-arrow-size, 11px));
|
|
11890
|
-
rotate: 90deg;
|
|
11891
|
-
}
|
|
11892
|
-
|
|
11893
|
-
/* WHERE IT LANDS, when landing is ON a thing rather than between two: the
|
|
11894
|
-
place itself is lit up, because there is no gap to draw a line in. Fixed
|
|
11895
|
-
and in the top layer for the same reasons as the line above. */
|
|
11896
|
-
.navi_drop_surface {
|
|
11897
|
-
position: fixed;
|
|
11898
|
-
inset: auto;
|
|
11899
|
-
top: var(--drop-target-top);
|
|
11900
|
-
left: var(--drop-target-left);
|
|
11901
|
-
display: none;
|
|
11902
|
-
box-sizing: border-box;
|
|
11903
|
-
width: var(--drop-target-width);
|
|
11904
|
-
height: var(--drop-target-height);
|
|
11905
|
-
margin: 0;
|
|
11906
|
-
padding: 0;
|
|
11907
|
-
color: inherit;
|
|
11908
|
-
background: var(--drop-surface-background-color, rgba(68, 118, 255, 0.16));
|
|
11909
|
-
border: var(--drop-surface-border-width, 2px) solid
|
|
11797
|
+
const css$1 = /* css */`.navi_drop_hint {
|
|
11798
|
+
inset: auto;
|
|
11799
|
+
top: var(--drop-hint-y);
|
|
11800
|
+
left: calc(var(--drop-target-left) + var(--drop-hint-margin-x, 0px));
|
|
11801
|
+
box-sizing: border-box;
|
|
11802
|
+
width: calc(var(--drop-target-width) - 2 * var(--drop-hint-margin-x, 0px));
|
|
11803
|
+
height: var(--drop-hint-size, 3px);
|
|
11804
|
+
color: inherit;
|
|
11805
|
+
background: var(--drop-hint-background-color, #4476ff);
|
|
11806
|
+
border-radius: var(--drop-hint-border-radius, 2px);
|
|
11807
|
+
pointer-events: none;
|
|
11808
|
+
border: none;
|
|
11809
|
+
margin: 0;
|
|
11810
|
+
padding: 0;
|
|
11811
|
+
display: none;
|
|
11812
|
+
position: fixed;
|
|
11813
|
+
overflow: visible;
|
|
11814
|
+
transform: translateY(-50%);
|
|
11815
|
+
}
|
|
11816
|
+
|
|
11817
|
+
.navi_drop_hint[data-drop-edge]:popover-open {
|
|
11818
|
+
display: block;
|
|
11819
|
+
}
|
|
11820
|
+
|
|
11821
|
+
.navi_drop_hint[data-drop-edge="top"] {
|
|
11822
|
+
--drop-hint-y: calc(var(--drop-target-top) - var(--drop-hint-margin-y, 0px));
|
|
11823
|
+
}
|
|
11824
|
+
|
|
11825
|
+
.navi_drop_hint[data-drop-edge="bottom"] {
|
|
11826
|
+
--drop-hint-y: calc(var(--drop-target-bottom) + var(--drop-hint-margin-y, 0px));
|
|
11827
|
+
}
|
|
11828
|
+
|
|
11829
|
+
.navi_drop_hint_cap {
|
|
11830
|
+
color: var(--drop-hint-background-color, #4476ff);
|
|
11831
|
+
display: flex;
|
|
11832
|
+
position: absolute;
|
|
11833
|
+
top: 50%;
|
|
11834
|
+
translate: 0 -50%;
|
|
11835
|
+
}
|
|
11836
|
+
|
|
11837
|
+
.navi_drop_hint_cap svg {
|
|
11838
|
+
width: var(--drop-hint-arrow-size, 11px);
|
|
11839
|
+
height: var(--drop-hint-arrow-size, 11px);
|
|
11840
|
+
}
|
|
11841
|
+
|
|
11842
|
+
.navi_drop_hint_cap[data-side="start"] {
|
|
11843
|
+
left: calc(-1 * var(--drop-hint-arrow-size, 11px));
|
|
11844
|
+
rotate: -90deg;
|
|
11845
|
+
}
|
|
11846
|
+
|
|
11847
|
+
.navi_drop_hint_cap[data-side="end"] {
|
|
11848
|
+
right: calc(-1 * var(--drop-hint-arrow-size, 11px));
|
|
11849
|
+
rotate: 90deg;
|
|
11850
|
+
}
|
|
11851
|
+
|
|
11852
|
+
.navi_drop_surface {
|
|
11853
|
+
inset: auto;
|
|
11854
|
+
top: var(--drop-target-top);
|
|
11855
|
+
left: var(--drop-target-left);
|
|
11856
|
+
box-sizing: border-box;
|
|
11857
|
+
width: var(--drop-target-width);
|
|
11858
|
+
height: var(--drop-target-height);
|
|
11859
|
+
color: inherit;
|
|
11860
|
+
background: var(--drop-surface-background-color, #4476ff29);
|
|
11861
|
+
border: var(--drop-surface-border-width, 2px) solid
|
|
11910
11862
|
var(--drop-surface-border-color, #4476ff);
|
|
11911
|
-
|
|
11912
|
-
|
|
11913
|
-
|
|
11914
|
-
|
|
11915
|
-
|
|
11916
|
-
|
|
11917
|
-
|
|
11918
|
-
|
|
11919
|
-
|
|
11920
|
-
|
|
11921
|
-
|
|
11922
|
-
|
|
11923
|
-
|
|
11924
|
-
|
|
11925
|
-
|
|
11926
|
-
|
|
11927
|
-
|
|
11928
|
-
|
|
11929
|
-
|
|
11930
|
-
|
|
11931
|
-
|
|
11932
|
-
|
|
11933
|
-
|
|
11934
|
-
|
|
11935
|
-
|
|
11936
|
-
|
|
11937
|
-
|
|
11938
|
-
|
|
11939
|
-
|
|
11940
|
-
|
|
11941
|
-
|
|
11942
|
-
|
|
11943
|
-
|
|
11944
|
-
|
|
11945
|
-
|
|
11946
|
-
|
|
11947
|
-
|
|
11948
|
-
|
|
11949
|
-
|
|
11950
|
-
|
|
11951
|
-
|
|
11952
|
-
|
|
11953
|
-
|
|
11954
|
-
|
|
11955
|
-
|
|
11956
|
-
|
|
11957
|
-
|
|
11958
|
-
|
|
11959
|
-
|
|
11960
|
-
|
|
11961
|
-
|
|
11962
|
-
|
|
11963
|
-
|
|
11964
|
-
|
|
11965
|
-
|
|
11966
|
-
|
|
11967
|
-
|
|
11968
|
-
|
|
11969
|
-
|
|
11970
|
-
background: transparent;
|
|
11971
|
-
border: none;
|
|
11972
|
-
/* Carries the chain down to the copy, for an item whose own radius is an
|
|
11973
|
-
"inherit" from the list around it. */
|
|
11974
|
-
border-radius: inherit;
|
|
11975
|
-
opacity: 0.95;
|
|
11976
|
-
pointer-events: none;
|
|
11977
|
-
/* Nothing in a copy being carried by a pointer is text to select: the
|
|
11978
|
-
selection belongs to the original, which is still in the page. This is the
|
|
11979
|
-
one place the rule is unconditional — an element that can be dragged is
|
|
11980
|
-
usually selectable too (a link is both), and forcing it there would take
|
|
11981
|
-
away a selection made from outside the element. */
|
|
11982
|
-
user-select: none;
|
|
11983
|
-
overflow: visible;
|
|
11984
|
-
}
|
|
11985
|
-
|
|
11986
|
-
/* On its way home and still the object: the hand can reach for it there, so
|
|
11987
|
-
there it takes the pointer — which it must not do at any other moment of the
|
|
11988
|
-
gesture, or it would hide what it is being dropped on. */
|
|
11989
|
-
[navi-drag-clone-wrapper][data-catchable] {
|
|
11990
|
-
pointer-events: auto;
|
|
11991
|
-
}
|
|
11992
|
-
|
|
11993
|
-
/* …and a FINGER reaching for it does not land on it: the pictures of the
|
|
11994
|
-
transition cover the page, so as far as the browser is concerned the touch
|
|
11995
|
-
began on the document root. What a touch may do is decided there and at that
|
|
11996
|
-
moment, so the root says it for as long as the copy can be caught — the pan
|
|
11997
|
-
is ours (nothing should scroll while something is landing), zoom stays the
|
|
11998
|
-
reader's. Half of a pair: without the non-passive listener put down at the
|
|
11999
|
-
same moment (see letCopyBeCaught) every touchmove arrives already
|
|
12000
|
-
non-cancelable and refusing it does nothing. */
|
|
12001
|
-
[data-drag-catchable] {
|
|
12002
|
-
touch-action: pinch-zoom;
|
|
12003
|
-
}
|
|
12004
|
-
|
|
12005
|
-
/* Ce qui a été lancé: il continue dans la direction du geste jusqu'à sortir de
|
|
12006
|
-
l'écran, et revient par le même chemin si la réponse refuse. */
|
|
12007
|
-
[navi-drag-clone-wrapper][data-tossed] {
|
|
12008
|
-
transition:
|
|
12009
|
-
translate ${TOSS_DURATION_MS}ms ease-out,
|
|
11863
|
+
border-radius: var(--drop-surface-border-radius, 6px);
|
|
11864
|
+
pointer-events: none;
|
|
11865
|
+
margin: 0;
|
|
11866
|
+
padding: 0;
|
|
11867
|
+
display: none;
|
|
11868
|
+
position: fixed;
|
|
11869
|
+
overflow: visible;
|
|
11870
|
+
}
|
|
11871
|
+
|
|
11872
|
+
.navi_drop_surface[data-drop-over]:popover-open {
|
|
11873
|
+
display: block;
|
|
11874
|
+
}
|
|
11875
|
+
|
|
11876
|
+
[data-drag-handle] {
|
|
11877
|
+
cursor: grab;
|
|
11878
|
+
}
|
|
11879
|
+
|
|
11880
|
+
[data-drag-source] {
|
|
11881
|
+
cursor: default;
|
|
11882
|
+
}
|
|
11883
|
+
|
|
11884
|
+
[data-drag-ignore], [data-own-target], [data-drag-source] [popover], [data-drag-source] dialog {
|
|
11885
|
+
cursor: auto;
|
|
11886
|
+
}
|
|
11887
|
+
|
|
11888
|
+
[navi-drag-clone-source] {
|
|
11889
|
+
visibility: hidden;
|
|
11890
|
+
}
|
|
11891
|
+
|
|
11892
|
+
[navi-drag-clone-wrapper] {
|
|
11893
|
+
inset: auto;
|
|
11894
|
+
top: var(--clone-top);
|
|
11895
|
+
left: var(--clone-left);
|
|
11896
|
+
box-sizing: border-box;
|
|
11897
|
+
width: var(--clone-width);
|
|
11898
|
+
height: var(--clone-height);
|
|
11899
|
+
color: inherit;
|
|
11900
|
+
border-radius: inherit;
|
|
11901
|
+
opacity: .95;
|
|
11902
|
+
pointer-events: none;
|
|
11903
|
+
user-select: none;
|
|
11904
|
+
background: none;
|
|
11905
|
+
border: none;
|
|
11906
|
+
margin: 0;
|
|
11907
|
+
padding: 0;
|
|
11908
|
+
position: fixed;
|
|
11909
|
+
overflow: visible;
|
|
11910
|
+
}
|
|
11911
|
+
|
|
11912
|
+
[navi-drag-clone-wrapper][data-catchable] {
|
|
11913
|
+
pointer-events: auto;
|
|
11914
|
+
}
|
|
11915
|
+
|
|
11916
|
+
[data-drag-catchable] {
|
|
11917
|
+
touch-action: pinch-zoom;
|
|
11918
|
+
}
|
|
11919
|
+
|
|
11920
|
+
[navi-drag-clone-wrapper][data-tossed] {
|
|
11921
|
+
transition: translate ${TOSS_DURATION_MS}ms ease-out,
|
|
12010
11922
|
opacity ${TOSS_DURATION_MS}ms ease-out;
|
|
12011
|
-
|
|
12012
|
-
|
|
12013
|
-
|
|
12014
|
-
|
|
11923
|
+
}
|
|
11924
|
+
|
|
11925
|
+
[navi-drag-clone-wrapper][data-tossed="away"] {
|
|
11926
|
+
opacity: 0;
|
|
11927
|
+
}
|
|
11928
|
+
|
|
11929
|
+
[navi-drag-clone] {
|
|
11930
|
+
box-shadow: var(--drag-clone-shadow, 0 12px 28px #00000038);
|
|
11931
|
+
transform: scale(var(--drag-clone-scale, 1.03));
|
|
11932
|
+
transform-origin: var(--drag-origin);
|
|
11933
|
+
transition: transform .15s cubic-bezier(.34, 1.56, .64, 1), box-shadow .15s;
|
|
11934
|
+
}
|
|
12015
11935
|
|
|
11936
|
+
@starting-style {
|
|
12016
11937
|
[navi-drag-clone] {
|
|
12017
|
-
|
|
12018
|
-
|
|
12019
|
-
var read on the copy, which IS the dragged element: what being carried
|
|
12020
|
-
looks like belongs to whoever owns the thing — a row lifted off a list
|
|
12021
|
-
wants this shadow, a sheet of paper leaving a board wants none, and its
|
|
12022
|
-
shade is a theme's business either way. */
|
|
12023
|
-
box-shadow: var(--drag-clone-shadow, 0 12px 28px rgba(0, 0, 0, 0.22));
|
|
12024
|
-
transform: scale(var(--drag-clone-scale, 1.03));
|
|
12025
|
-
transform-origin: var(--drag-origin);
|
|
12026
|
-
transition:
|
|
12027
|
-
transform 0.15s cubic-bezier(0.34, 1.56, 0.64, 1),
|
|
12028
|
-
box-shadow 0.15s ease;
|
|
12029
|
-
}
|
|
12030
|
-
|
|
12031
|
-
@starting-style {
|
|
12032
|
-
[navi-drag-clone] {
|
|
12033
|
-
box-shadow: none;
|
|
12034
|
-
transform: scale(1);
|
|
12035
|
-
}
|
|
11938
|
+
box-shadow: none;
|
|
11939
|
+
transform: scale(1);
|
|
12036
11940
|
}
|
|
11941
|
+
}
|
|
12037
11942
|
`;
|
|
12038
11943
|
// At module scope, not inside startDragTo: the cursor rules above say who
|
|
12039
11944
|
// can start a drag, and they have to be true BEFORE anyone drags anything.
|
|
@@ -14519,13 +14424,12 @@ installImportMetaCssBuild(import.meta);/**
|
|
|
14519
14424
|
*
|
|
14520
14425
|
* The element should have a CSS "top" value specified (e.g., top: 10px).
|
|
14521
14426
|
*/
|
|
14522
|
-
const css = /* css */`
|
|
14523
|
-
|
|
14524
|
-
|
|
14525
|
-
|
|
14526
|
-
|
|
14527
|
-
|
|
14528
|
-
}
|
|
14427
|
+
const css = /* css */`[data-position-sticky-placeholder] {
|
|
14428
|
+
opacity: 0 !important;
|
|
14429
|
+
width: auto !important;
|
|
14430
|
+
height: auto !important;
|
|
14431
|
+
position: static !important;
|
|
14432
|
+
}
|
|
14529
14433
|
`;
|
|
14530
14434
|
const initPositionSticky = element => {
|
|
14531
14435
|
import.meta.css = [css, "@jsenv/dom/src/position/position_sticky.js"];
|