@ni/spright-components 5.1.0 → 5.1.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.
|
@@ -28195,7 +28195,7 @@ so this becomes the fallback color for the slot */ ''}
|
|
|
28195
28195
|
tree shape like this (without back pointers) makes easy.
|
|
28196
28196
|
|
|
28197
28197
|
**Do not** directly mutate the properties of a `Node` object. See
|
|
28198
|
-
[the guide](/docs/guide/#doc) for more information.
|
|
28198
|
+
[the guide](https://prosemirror.net/docs/guide/#doc) for more information.
|
|
28199
28199
|
*/
|
|
28200
28200
|
let Node$2 = class Node {
|
|
28201
28201
|
/**
|
|
@@ -28230,7 +28230,7 @@ so this becomes the fallback color for the slot */ ''}
|
|
|
28230
28230
|
get children() { return this.content.content; }
|
|
28231
28231
|
/**
|
|
28232
28232
|
The size of this node, as defined by the integer-based [indexing
|
|
28233
|
-
scheme](/docs/guide/#doc.indexing). For text nodes, this is the
|
|
28233
|
+
scheme](https://prosemirror.net/docs/guide/#doc.indexing). For text nodes, this is the
|
|
28234
28234
|
amount of characters. For other leaf nodes, it is one. For
|
|
28235
28235
|
non-leaf nodes, it is the size of the content plus two (the
|
|
28236
28236
|
start and end token).
|
|
@@ -30687,18 +30687,14 @@ so this becomes the fallback color for the slot */ ''}
|
|
|
30687
30687
|
maps](https://prosemirror.net/docs/ref/#transform.StepMap). It has special provisions for losslessly
|
|
30688
30688
|
handling mapping positions through a series of steps in which some
|
|
30689
30689
|
steps are inverted versions of earlier steps. (This comes up when
|
|
30690
|
-
‘[rebasing](/docs/guide/#transform.rebasing)’ steps for
|
|
30690
|
+
‘[rebasing](https://prosemirror.net/docs/guide/#transform.rebasing)’ steps for
|
|
30691
30691
|
collaboration or history management.)
|
|
30692
30692
|
*/
|
|
30693
30693
|
class Mapping {
|
|
30694
30694
|
/**
|
|
30695
30695
|
Create a new mapping with the given position maps.
|
|
30696
30696
|
*/
|
|
30697
|
-
constructor(
|
|
30698
|
-
/**
|
|
30699
|
-
The step maps in this mapping.
|
|
30700
|
-
*/
|
|
30701
|
-
maps = [],
|
|
30697
|
+
constructor(maps,
|
|
30702
30698
|
/**
|
|
30703
30699
|
@internal
|
|
30704
30700
|
*/
|
|
@@ -30711,23 +30707,22 @@ so this becomes the fallback color for the slot */ ''}
|
|
|
30711
30707
|
/**
|
|
30712
30708
|
The end position in the `maps` array.
|
|
30713
30709
|
*/
|
|
30714
|
-
to = maps.length) {
|
|
30715
|
-
this.maps = maps;
|
|
30710
|
+
to = maps ? maps.length : 0) {
|
|
30716
30711
|
this.mirror = mirror;
|
|
30717
30712
|
this.from = from;
|
|
30718
30713
|
this.to = to;
|
|
30714
|
+
this._maps = maps || [];
|
|
30715
|
+
this.ownData = !(maps || mirror);
|
|
30719
30716
|
}
|
|
30720
30717
|
/**
|
|
30721
|
-
|
|
30718
|
+
The step maps in this mapping.
|
|
30722
30719
|
*/
|
|
30723
|
-
|
|
30724
|
-
return new Mapping(this.maps, this.mirror, from, to);
|
|
30725
|
-
}
|
|
30720
|
+
get maps() { return this._maps; }
|
|
30726
30721
|
/**
|
|
30727
|
-
|
|
30722
|
+
Create a mapping that maps only through a part of this one.
|
|
30728
30723
|
*/
|
|
30729
|
-
|
|
30730
|
-
return new Mapping(this.
|
|
30724
|
+
slice(from = 0, to = this.maps.length) {
|
|
30725
|
+
return new Mapping(this._maps, this.mirror, from, to);
|
|
30731
30726
|
}
|
|
30732
30727
|
/**
|
|
30733
30728
|
Add a step map to the end of this mapping. If `mirrors` is
|
|
@@ -30735,18 +30730,23 @@ so this becomes the fallback color for the slot */ ''}
|
|
|
30735
30730
|
image of this one.
|
|
30736
30731
|
*/
|
|
30737
30732
|
appendMap(map, mirrors) {
|
|
30738
|
-
|
|
30733
|
+
if (!this.ownData) {
|
|
30734
|
+
this._maps = this._maps.slice();
|
|
30735
|
+
this.mirror = this.mirror && this.mirror.slice();
|
|
30736
|
+
this.ownData = true;
|
|
30737
|
+
}
|
|
30738
|
+
this.to = this._maps.push(map);
|
|
30739
30739
|
if (mirrors != null)
|
|
30740
|
-
this.setMirror(this.
|
|
30740
|
+
this.setMirror(this._maps.length - 1, mirrors);
|
|
30741
30741
|
}
|
|
30742
30742
|
/**
|
|
30743
30743
|
Add all the step maps in a given mapping to this one (preserving
|
|
30744
30744
|
mirroring information).
|
|
30745
30745
|
*/
|
|
30746
30746
|
appendMapping(mapping) {
|
|
30747
|
-
for (let i = 0, startSize = this.
|
|
30747
|
+
for (let i = 0, startSize = this._maps.length; i < mapping._maps.length; i++) {
|
|
30748
30748
|
let mirr = mapping.getMirror(i);
|
|
30749
|
-
this.appendMap(mapping.
|
|
30749
|
+
this.appendMap(mapping._maps[i], mirr != null && mirr < i ? startSize + mirr : undefined);
|
|
30750
30750
|
}
|
|
30751
30751
|
}
|
|
30752
30752
|
/**
|
|
@@ -30772,9 +30772,9 @@ so this becomes the fallback color for the slot */ ''}
|
|
|
30772
30772
|
Append the inverse of the given mapping to this one.
|
|
30773
30773
|
*/
|
|
30774
30774
|
appendMappingInverted(mapping) {
|
|
30775
|
-
for (let i = mapping.maps.length - 1, totalSize = this.
|
|
30775
|
+
for (let i = mapping.maps.length - 1, totalSize = this._maps.length + mapping._maps.length; i >= 0; i--) {
|
|
30776
30776
|
let mirr = mapping.getMirror(i);
|
|
30777
|
-
this.appendMap(mapping.
|
|
30777
|
+
this.appendMap(mapping._maps[i].invert(), mirr != null && mirr > i ? totalSize - mirr - 1 : undefined);
|
|
30778
30778
|
}
|
|
30779
30779
|
}
|
|
30780
30780
|
/**
|
|
@@ -30792,7 +30792,7 @@ so this becomes the fallback color for the slot */ ''}
|
|
|
30792
30792
|
if (this.mirror)
|
|
30793
30793
|
return this._map(pos, assoc, true);
|
|
30794
30794
|
for (let i = this.from; i < this.to; i++)
|
|
30795
|
-
pos = this.
|
|
30795
|
+
pos = this._maps[i].map(pos, assoc);
|
|
30796
30796
|
return pos;
|
|
30797
30797
|
}
|
|
30798
30798
|
/**
|
|
@@ -30806,12 +30806,12 @@ so this becomes the fallback color for the slot */ ''}
|
|
|
30806
30806
|
_map(pos, assoc, simple) {
|
|
30807
30807
|
let delInfo = 0;
|
|
30808
30808
|
for (let i = this.from; i < this.to; i++) {
|
|
30809
|
-
let map = this.
|
|
30809
|
+
let map = this._maps[i], result = map.mapResult(pos, assoc);
|
|
30810
30810
|
if (result.recover != null) {
|
|
30811
30811
|
let corr = this.getMirror(i);
|
|
30812
30812
|
if (corr != null && corr > i && corr < this.to) {
|
|
30813
30813
|
i = corr;
|
|
30814
|
-
pos = this.
|
|
30814
|
+
pos = this._maps[corr].recover(result.recover);
|
|
30815
30815
|
continue;
|
|
30816
30816
|
}
|
|
30817
30817
|
}
|
|
@@ -32613,7 +32613,7 @@ so this becomes the fallback color for the slot */ ''}
|
|
|
32613
32613
|
greater than one, any number of nodes above that. By default, the
|
|
32614
32614
|
parts split off will inherit the node type of the original node.
|
|
32615
32615
|
This can be changed by passing an array of types and attributes to
|
|
32616
|
-
use after the split.
|
|
32616
|
+
use after the split (with the outermost nodes coming first).
|
|
32617
32617
|
*/
|
|
32618
32618
|
split(pos, depth = 1, typesAfter) {
|
|
32619
32619
|
split(this, pos, depth, typesAfter);
|
|
@@ -33846,11 +33846,13 @@ so this becomes the fallback color for the slot */ ''}
|
|
|
33846
33846
|
function scrollRectIntoView(view, rect, startDOM) {
|
|
33847
33847
|
let scrollThreshold = view.someProp("scrollThreshold") || 0, scrollMargin = view.someProp("scrollMargin") || 5;
|
|
33848
33848
|
let doc = view.dom.ownerDocument;
|
|
33849
|
-
for (let parent = startDOM || view.dom;;
|
|
33849
|
+
for (let parent = startDOM || view.dom;;) {
|
|
33850
33850
|
if (!parent)
|
|
33851
33851
|
break;
|
|
33852
|
-
if (parent.nodeType != 1)
|
|
33852
|
+
if (parent.nodeType != 1) {
|
|
33853
|
+
parent = parentNode(parent);
|
|
33853
33854
|
continue;
|
|
33855
|
+
}
|
|
33854
33856
|
let elt = parent;
|
|
33855
33857
|
let atTop = elt == doc.body;
|
|
33856
33858
|
let bounding = atTop ? windowRect(doc) : clientRect(elt);
|
|
@@ -33879,8 +33881,10 @@ so this becomes the fallback color for the slot */ ''}
|
|
|
33879
33881
|
rect = { left: rect.left - dX, top: rect.top - dY, right: rect.right - dX, bottom: rect.bottom - dY };
|
|
33880
33882
|
}
|
|
33881
33883
|
}
|
|
33882
|
-
|
|
33884
|
+
let pos = atTop ? "fixed" : getComputedStyle(parent).position;
|
|
33885
|
+
if (/^(fixed|sticky)$/.test(pos))
|
|
33883
33886
|
break;
|
|
33887
|
+
parent = pos == "absolute" ? parent.offsetParent : parentNode(parent);
|
|
33884
33888
|
}
|
|
33885
33889
|
}
|
|
33886
33890
|
// Store the scroll position of the editor's parent nodes, along with
|
|
@@ -39291,6 +39295,17 @@ so this becomes the fallback color for the slot */ ''}
|
|
|
39291
39295
|
return doPaste(this, text, null, true, event || new ClipboardEvent("paste"));
|
|
39292
39296
|
}
|
|
39293
39297
|
/**
|
|
39298
|
+
Serialize the given slice as it would be if it was copied from
|
|
39299
|
+
this editor. Returns a DOM element that contains a
|
|
39300
|
+
representation of the slice as its children, a textual
|
|
39301
|
+
representation, and the transformed slice (which can be
|
|
39302
|
+
different from the given input due to hooks like
|
|
39303
|
+
[`transformCopied`](https://prosemirror.net/docs/ref/#view.EditorProps.transformCopied)).
|
|
39304
|
+
*/
|
|
39305
|
+
serializeForClipboard(slice) {
|
|
39306
|
+
return serializeForClipboard(this, slice);
|
|
39307
|
+
}
|
|
39308
|
+
/**
|
|
39294
39309
|
Removes the editor from the DOM and destroys all [node
|
|
39295
39310
|
views](https://prosemirror.net/docs/ref/#view.NodeView).
|
|
39296
39311
|
*/
|
|
@@ -39738,7 +39753,7 @@ so this becomes the fallback color for the slot */ ''}
|
|
|
39738
39753
|
return false;
|
|
39739
39754
|
};
|
|
39740
39755
|
/**
|
|
39741
|
-
A more limited form of [`joinBackward`](
|
|
39756
|
+
A more limited form of [`joinBackward`](https://prosemirror.net/docs/ref/#commands.joinBackward)
|
|
39742
39757
|
that only tries to join the current textblock to the one before
|
|
39743
39758
|
it, if the cursor is at the start of a textblock.
|
|
39744
39759
|
*/
|
|
@@ -39750,7 +39765,7 @@ so this becomes the fallback color for the slot */ ''}
|
|
|
39750
39765
|
return $cut ? joinTextblocksAround(state, $cut, dispatch) : false;
|
|
39751
39766
|
};
|
|
39752
39767
|
/**
|
|
39753
|
-
A more limited form of [`joinForward`](
|
|
39768
|
+
A more limited form of [`joinForward`](https://prosemirror.net/docs/ref/#commands.joinForward)
|
|
39754
39769
|
that only tries to join the current textblock to the one after
|
|
39755
39770
|
it, if the cursor is at the end of a textblock.
|
|
39756
39771
|
*/
|
|
@@ -40405,9 +40420,9 @@ so this becomes the fallback color for the slot */ ''}
|
|
|
40405
40420
|
if (target == null)
|
|
40406
40421
|
return false;
|
|
40407
40422
|
tr.lift(range, target);
|
|
40408
|
-
let after = tr.mapping.map(end, -1) - 1;
|
|
40409
|
-
if (canJoin(tr.doc, after))
|
|
40410
|
-
tr.join(after);
|
|
40423
|
+
let $after = tr.doc.resolve(tr.mapping.map(end, -1) - 1);
|
|
40424
|
+
if (canJoin(tr.doc, $after.pos) && $after.nodeBefore.type == $after.nodeAfter.type)
|
|
40425
|
+
tr.join($after.pos);
|
|
40411
40426
|
dispatch(tr.scrollIntoView());
|
|
40412
40427
|
return true;
|
|
40413
40428
|
}
|
|
@@ -44086,13 +44101,14 @@ so this becomes the fallback color for the slot */ ''}
|
|
|
44086
44101
|
},
|
|
44087
44102
|
});
|
|
44088
44103
|
|
|
44104
|
+
const focusEventsPluginKey = new PluginKey('focusEvents');
|
|
44089
44105
|
const FocusEvents = Extension.create({
|
|
44090
44106
|
name: 'focusEvents',
|
|
44091
44107
|
addProseMirrorPlugins() {
|
|
44092
44108
|
const { editor } = this;
|
|
44093
44109
|
return [
|
|
44094
44110
|
new Plugin({
|
|
44095
|
-
key:
|
|
44111
|
+
key: focusEventsPluginKey,
|
|
44096
44112
|
props: {
|
|
44097
44113
|
handleDOMEvents: {
|
|
44098
44114
|
focus: (view, event) => {
|
|
@@ -53326,6 +53342,16 @@ img.ProseMirror-separator {
|
|
|
53326
53342
|
return output;
|
|
53327
53343
|
}
|
|
53328
53344
|
|
|
53345
|
+
/**
|
|
53346
|
+
* Creates a string based on an array of numeric code points.
|
|
53347
|
+
* @see `punycode.ucs2.decode`
|
|
53348
|
+
* @memberOf punycode.ucs2
|
|
53349
|
+
* @name encode
|
|
53350
|
+
* @param {Array} codePoints The array of numeric code points.
|
|
53351
|
+
* @returns {String} The new Unicode string (UCS-2).
|
|
53352
|
+
*/
|
|
53353
|
+
const ucs2encode = codePoints => String.fromCodePoint(...codePoints);
|
|
53354
|
+
|
|
53329
53355
|
/**
|
|
53330
53356
|
* Converts a basic code point into a digit/integer.
|
|
53331
53357
|
* @see `digitToBasic()`
|
|
@@ -53611,6 +53637,25 @@ img.ProseMirror-separator {
|
|
|
53611
53637
|
|
|
53612
53638
|
/** Define the public API */
|
|
53613
53639
|
const punycode = {
|
|
53640
|
+
/**
|
|
53641
|
+
* A string representing the current Punycode.js version number.
|
|
53642
|
+
* @memberOf punycode
|
|
53643
|
+
* @type String
|
|
53644
|
+
*/
|
|
53645
|
+
'version': '2.3.1',
|
|
53646
|
+
/**
|
|
53647
|
+
* An object of methods to convert from JavaScript's internal character
|
|
53648
|
+
* representation (UCS-2) to Unicode code points, and back.
|
|
53649
|
+
* @see <https://mathiasbynens.be/notes/javascript-encoding>
|
|
53650
|
+
* @memberOf punycode
|
|
53651
|
+
* @type Object
|
|
53652
|
+
*/
|
|
53653
|
+
'ucs2': {
|
|
53654
|
+
'decode': ucs2decode,
|
|
53655
|
+
'encode': ucs2encode
|
|
53656
|
+
},
|
|
53657
|
+
'decode': decode,
|
|
53658
|
+
'encode': encode,
|
|
53614
53659
|
'toASCII': toASCII,
|
|
53615
53660
|
'toUnicode': toUnicode
|
|
53616
53661
|
};
|
|
@@ -54507,6 +54552,7 @@ img.ProseMirror-separator {
|
|
|
54507
54552
|
toDOM(node) { return ["a", node.attrs]; }
|
|
54508
54553
|
},
|
|
54509
54554
|
code: {
|
|
54555
|
+
code: true,
|
|
54510
54556
|
parseDOM: [{ tag: "code" }],
|
|
54511
54557
|
toDOM() { return ["code"]; }
|
|
54512
54558
|
}
|
|
@@ -59444,7 +59490,7 @@ img.ProseMirror-separator {
|
|
|
59444
59490
|
},
|
|
59445
59491
|
},
|
|
59446
59492
|
type: {
|
|
59447
|
-
default:
|
|
59493
|
+
default: null,
|
|
59448
59494
|
parseHTML: element => element.getAttribute('type'),
|
|
59449
59495
|
},
|
|
59450
59496
|
};
|
|
@@ -67791,7 +67837,7 @@ focus outline in that case.
|
|
|
67791
67837
|
function memo(getDeps, fn, opts) {
|
|
67792
67838
|
let deps = opts.initialDeps ?? [];
|
|
67793
67839
|
let result;
|
|
67794
|
-
|
|
67840
|
+
function memoizedFunction() {
|
|
67795
67841
|
var _a, _b, _c, _d;
|
|
67796
67842
|
let depTime;
|
|
67797
67843
|
if (opts.key && ((_a = opts.debug) == null ? void 0 : _a.call(opts))) depTime = Date.now();
|
|
@@ -67829,7 +67875,11 @@ focus outline in that case.
|
|
|
67829
67875
|
}
|
|
67830
67876
|
(_d = opts == null ? void 0 : opts.onChange) == null ? void 0 : _d.call(opts, result);
|
|
67831
67877
|
return result;
|
|
67878
|
+
}
|
|
67879
|
+
memoizedFunction.updateDeps = (newDeps) => {
|
|
67880
|
+
deps = newDeps;
|
|
67832
67881
|
};
|
|
67882
|
+
return memoizedFunction;
|
|
67833
67883
|
}
|
|
67834
67884
|
function notUndefined(value, msg) {
|
|
67835
67885
|
if (value === void 0) {
|
|
@@ -68038,7 +68088,7 @@ focus outline in that case.
|
|
|
68038
68088
|
isScrollingResetDelay: 150,
|
|
68039
68089
|
enabled: true,
|
|
68040
68090
|
isRtl: false,
|
|
68041
|
-
useScrollendEvent:
|
|
68091
|
+
useScrollendEvent: false,
|
|
68042
68092
|
useAnimationFrameWithResizeObserver: false,
|
|
68043
68093
|
...opts2
|
|
68044
68094
|
};
|
|
@@ -68256,6 +68306,7 @@ focus outline in that case.
|
|
|
68256
68306
|
startIndex = range.startIndex;
|
|
68257
68307
|
endIndex = range.endIndex;
|
|
68258
68308
|
}
|
|
68309
|
+
this.maybeNotify.updateDeps([this.isScrolling, startIndex, endIndex]);
|
|
68259
68310
|
return [
|
|
68260
68311
|
this.options.rangeExtractor,
|
|
68261
68312
|
this.options.overscan,
|
|
@@ -68478,10 +68529,19 @@ focus outline in that case.
|
|
|
68478
68529
|
let end;
|
|
68479
68530
|
if (measurements.length === 0) {
|
|
68480
68531
|
end = this.options.paddingStart;
|
|
68532
|
+
} else if (this.options.lanes === 1) {
|
|
68533
|
+
end = ((_a = measurements[measurements.length - 1]) == null ? void 0 : _a.end) ?? 0;
|
|
68481
68534
|
} else {
|
|
68482
|
-
|
|
68483
|
-
|
|
68484
|
-
)
|
|
68535
|
+
const endByLane = Array(this.options.lanes).fill(null);
|
|
68536
|
+
let endIndex = measurements.length - 1;
|
|
68537
|
+
while (endIndex >= 0 && endByLane.some((val) => val === null)) {
|
|
68538
|
+
const item = measurements[endIndex];
|
|
68539
|
+
if (endByLane[item.lane] === null) {
|
|
68540
|
+
endByLane[item.lane] = item.end;
|
|
68541
|
+
}
|
|
68542
|
+
endIndex--;
|
|
68543
|
+
}
|
|
68544
|
+
end = Math.max(...endByLane.filter((val) => val !== null));
|
|
68485
68545
|
}
|
|
68486
68546
|
return Math.max(
|
|
68487
68547
|
end - this.options.scrollMargin + this.options.paddingEnd,
|
|
@@ -68527,6 +68587,12 @@ focus outline in that case.
|
|
|
68527
68587
|
}) {
|
|
68528
68588
|
const lastIndex = measurements.length - 1;
|
|
68529
68589
|
const getOffset = (index) => measurements[index].start;
|
|
68590
|
+
if (measurements.length <= lanes) {
|
|
68591
|
+
return {
|
|
68592
|
+
startIndex: 0,
|
|
68593
|
+
endIndex: lastIndex
|
|
68594
|
+
};
|
|
68595
|
+
}
|
|
68530
68596
|
let startIndex = findNearestBinarySearch(
|
|
68531
68597
|
0,
|
|
68532
68598
|
lastIndex,
|
|
@@ -68534,10 +68600,23 @@ focus outline in that case.
|
|
|
68534
68600
|
scrollOffset
|
|
68535
68601
|
);
|
|
68536
68602
|
let endIndex = startIndex;
|
|
68537
|
-
|
|
68538
|
-
endIndex
|
|
68539
|
-
|
|
68540
|
-
|
|
68603
|
+
if (lanes === 1) {
|
|
68604
|
+
while (endIndex < lastIndex && measurements[endIndex].end < scrollOffset + outerSize) {
|
|
68605
|
+
endIndex++;
|
|
68606
|
+
}
|
|
68607
|
+
} else if (lanes > 1) {
|
|
68608
|
+
const endPerLane = Array(lanes).fill(0);
|
|
68609
|
+
while (endIndex < lastIndex && endPerLane.some((pos) => pos < scrollOffset + outerSize)) {
|
|
68610
|
+
const item = measurements[endIndex];
|
|
68611
|
+
endPerLane[item.lane] = item.end;
|
|
68612
|
+
endIndex++;
|
|
68613
|
+
}
|
|
68614
|
+
const startPerLane = Array(lanes).fill(scrollOffset + outerSize);
|
|
68615
|
+
while (startIndex >= 0 && startPerLane.some((pos) => pos >= scrollOffset)) {
|
|
68616
|
+
const item = measurements[startIndex];
|
|
68617
|
+
startPerLane[item.lane] = item.start;
|
|
68618
|
+
startIndex--;
|
|
68619
|
+
}
|
|
68541
68620
|
startIndex = Math.max(0, startIndex - startIndex % lanes);
|
|
68542
68621
|
endIndex = Math.min(lastIndex, endIndex + (lanes - 1 - endIndex % lanes));
|
|
68543
68622
|
}
|
|
@@ -68561,7 +68640,6 @@ focus outline in that case.
|
|
|
68561
68640
|
this.headerContainerMarginRight = 0;
|
|
68562
68641
|
this.rowContainerYOffset = 0;
|
|
68563
68642
|
this._pageSize = 0;
|
|
68564
|
-
this.isScrollingTimer = 0;
|
|
68565
68643
|
this.table = table;
|
|
68566
68644
|
this.tanStackTable = tanStackTable;
|
|
68567
68645
|
this.viewportResizeObserver = new ResizeObserver(entries => {
|
|
@@ -68624,6 +68702,7 @@ focus outline in that case.
|
|
|
68624
68702
|
enableSmoothScroll: true,
|
|
68625
68703
|
overscan: 3,
|
|
68626
68704
|
isScrollingResetDelay: 250,
|
|
68705
|
+
useScrollendEvent: false,
|
|
68627
68706
|
scrollToFn: elementScroll,
|
|
68628
68707
|
observeElementOffset,
|
|
68629
68708
|
observeElementRect,
|
|
@@ -68635,15 +68714,6 @@ focus outline in that case.
|
|
|
68635
68714
|
this.visibleItems = virtualizer.getVirtualItems();
|
|
68636
68715
|
this.scrollHeight = virtualizer.getTotalSize();
|
|
68637
68716
|
this.isScrolling = virtualizer.isScrolling;
|
|
68638
|
-
// There are multiple browser bugs that can result in us getting stuck thinking that we're scrolling.
|
|
68639
|
-
// As a workaround, we assume scrolling stopped if we haven't received an update in 300ms.
|
|
68640
|
-
// Tech debt item to remove this workaround: https://github.com/ni/nimble/issues/2382
|
|
68641
|
-
window.clearTimeout(this.isScrollingTimer);
|
|
68642
|
-
if (this.isScrolling) {
|
|
68643
|
-
this.isScrollingTimer = window.setTimeout(() => {
|
|
68644
|
-
this.isScrolling = false;
|
|
68645
|
-
}, 300);
|
|
68646
|
-
}
|
|
68647
68717
|
// We're using a separate div ('table-scroll') to represent the full height of all rows, and
|
|
68648
68718
|
// the row container's height is only big enough to hold the virtualized rows. So we don't
|
|
68649
68719
|
// use the TanStackVirtual-provided 'start' offset (which is in terms of the full height)
|