New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

react-virtuoso

Package Overview
Dependencies
Maintainers
1
Versions
291
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

react-virtuoso - npm Package Compare versions

Comparing version 2.4.1 to 2.5.0

dist/Table.d.ts

2

dist/alignToBottomSystem.d.ts

@@ -141,2 +141,3 @@ import * as u from '@virtuoso.dev/urx';

topListHeight: u.StatefulStream<number>;
fixedHeaderHeight: u.StatefulStream<number>;
increaseViewportBy: u.StatefulStream<import("./sizeRangeSystem").ViewportIncrease>;

@@ -427,2 +428,3 @@ visibleRange: u.StatefulStream<import("./sizeRangeSystem").NumberTuple>;

topListHeight: u.StatefulStream<number>;
fixedHeaderHeight: u.StatefulStream<number>;
increaseViewportBy: u.StatefulStream<import("./sizeRangeSystem").ViewportIncrease>;

@@ -429,0 +431,0 @@ visibleRange: u.StatefulStream<import("./sizeRangeSystem").NumberTuple>;

@@ -59,2 +59,3 @@ import { RefHandle } from '@virtuoso.dev/react-urx';

topListHeight: u.StatefulStream<number>;
fixedHeaderHeight: u.StatefulStream<number>;
increaseViewportBy: u.StatefulStream<import("./sizeRangeSystem").ViewportIncrease>;

@@ -209,2 +210,3 @@ visibleRange: u.StatefulStream<import("./sizeRangeSystem").NumberTuple>;

topListHeight: u.StatefulStream<number>;
fixedHeaderHeight: u.StatefulStream<number>;
increaseViewportBy: u.StatefulStream<import("./sizeRangeSystem").ViewportIncrease>;

@@ -211,0 +213,0 @@ visibleRange: u.StatefulStream<import("./sizeRangeSystem").NumberTuple>;

@@ -51,2 +51,3 @@ import * as u from '@virtuoso.dev/urx';

topListHeight: u.StatefulStream<number>;
fixedHeaderHeight: u.StatefulStream<number>;
increaseViewportBy: u.StatefulStream<import("./sizeRangeSystem").ViewportIncrease>;

@@ -201,2 +202,3 @@ visibleRange: u.StatefulStream<import("./sizeRangeSystem").NumberTuple>;

topListHeight: u.StatefulStream<number>;
fixedHeaderHeight: u.StatefulStream<number>;
increaseViewportBy: u.StatefulStream<import("./sizeRangeSystem").ViewportIncrease>;

@@ -203,0 +205,0 @@ visibleRange: u.StatefulStream<import("./sizeRangeSystem").NumberTuple>;

2

dist/index.js

@@ -1,2 +0,2 @@

"use strict";var e=require("@virtuoso.dev/react-urx"),t=require("@virtuoso.dev/urx"),n=require("react");function r(){return(r=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e}).apply(this,arguments)}function o(e,t){if(null==e)return{};var n,r,o={},i=Object.keys(e);for(r=0;r<i.length;r++)t.indexOf(n=i[r])>=0||(o[n]=e[n]);return o}function i(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function a(e,t){var n;if("undefined"==typeof Symbol||null==e[Symbol.iterator]){if(Array.isArray(e)||(n=function(e,t){if(e){if("string"==typeof e)return i(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?i(e,t):void 0}}(e))||t&&e&&"number"==typeof e.length){n&&(e=n);var r=0;return function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}return(n=e[Symbol.iterator]()).next.bind(n)}function l(e,t){return!(!e||e[0]!==t[0]||e[1]!==t[1])}function s(e,t){return!(!e||e.startIndex!==t.startIndex||e.endIndex!==t.endIndex)}var u,c,m=t.system(function(){var e=t.stream(),n=t.stream(),r=t.statefulStream(0),o=t.stream(),i=t.statefulStream(0),a=t.stream(),l=t.stream(),s=t.statefulStream(0),u=t.statefulStream(0),c=t.stream(),m=t.stream(),f=t.statefulStream(!1);return t.connect(t.pipe(e,t.map(function(e){return e[0]})),n),t.connect(t.pipe(e,t.map(function(e){return e[1]})),l),t.connect(n,i),{scrollContainerState:e,scrollTop:n,viewportHeight:a,headerHeight:s,footerHeight:u,scrollHeight:l,smoothScrollTargetReached:o,scrollTo:c,scrollBy:m,statefulScrollTop:i,deviation:r,scrollingInProgress:f}},[],{singleton:!0});(c=exports.LogLevel||(exports.LogLevel={}))[c.DEBUG=0]="DEBUG",c[c.INFO=1]="INFO",c[c.WARN=2]="WARN",c[c.ERROR=3]="ERROR";var f=((u={})[exports.LogLevel.DEBUG]="debug",u[exports.LogLevel.INFO]="log",u[exports.LogLevel.WARN]="warn",u[exports.LogLevel.ERROR]="error",u),p=t.system(function(){var e=t.statefulStream(exports.LogLevel.ERROR);return{log:t.statefulStream(function(n,r,o){var i;void 0===o&&(o=exports.LogLevel.INFO),o>=(null!=(i=("undefined"==typeof globalThis?window:globalThis).VIRTUOSO_LOG_LEVEL)?i:t.getValue(e))&&console[f[o]]("%creact-virtuoso: %c%s %o","color: #0253b3; font-weight: bold","color: initial",n,r)}),logLevel:e}},[],{singleton:!0}),d=t.system(function(e){var n=e[0].log,r=t.statefulStream(!1),o=t.streamFromEmitter(t.pipe(r,t.filter(function(e){return e}),t.distinctUntilChanged()));return t.subscribe(r,function(e){e&&t.getValue(n)("props updated",{},exports.LogLevel.DEBUG)}),{propsReady:r,didMount:o}},t.tup(p),{singleton:!0}),h="up",g={atBottom:!1,notAtBottomBecause:"NOT_SHOWING_LAST_ITEM",state:{offsetBottom:0,scrollTop:0,viewportHeight:0,scrollHeight:0}},v=t.system(function(e){var n=e[0],r=n.scrollContainerState,o=n.scrollTop,i=n.viewportHeight,a=n.headerHeight,l=n.footerHeight,s=n.scrollBy,u=t.statefulStream(!1),c=t.statefulStream(!0),m=t.stream(),f=t.stream(),p=t.statefulStream(4),d=t.streamFromEmitter(t.pipe(t.merge(t.pipe(t.duc(o),t.skip(1),t.mapTo(!0)),t.pipe(t.duc(o),t.skip(1),t.mapTo(!1),t.debounceTime(100))),t.distinctUntilChanged())),v=t.statefulStreamFromEmitter(t.pipe(t.merge(t.pipe(s,t.mapTo(!0)),t.pipe(s,t.mapTo(!1),t.debounceTime(200))),t.distinctUntilChanged()),!1);t.connect(t.pipe(t.duc(o),t.map(function(e){return 0===e}),t.distinctUntilChanged()),c),t.connect(c,f);var S=t.streamFromEmitter(t.pipe(t.combineLatest(r,t.duc(i),t.duc(a),t.duc(l),t.duc(p)),t.scan(function(e,t){var n,r,o=t[0],i=o[0],a=o[1],l=t[1],s={viewportHeight:l,scrollTop:i,scrollHeight:a};return i+l-a>-t[4]?(i>e.state.scrollTop?(n="SCROLLED_DOWN",r=e.state.scrollTop-i):(n="SIZE_DECREASED",r=e.state.scrollTop-i||e.scrollTopDelta),{atBottom:!0,state:s,atBottomBecause:n,scrollTopDelta:r}):{atBottom:!1,notAtBottomBecause:s.scrollHeight>e.state.scrollHeight?"SIZE_INCREASED":l<e.state.viewportHeight?"VIEWPORT_HEIGHT_DECREASING":i<e.state.scrollTop?"SCROLLING_UPWARDS":"NOT_FULLY_SCROLLED_TO_LAST_ITEM_BOTTOM",state:s}},g),t.distinctUntilChanged(function(e,t){return e&&e.atBottom===t.atBottom}))),I=t.statefulStreamFromEmitter(t.pipe(r,t.scan(function(e,t){var n=t[0],r=t[1];return e.scrollHeight!==r?e.scrollTop!==n?{scrollHeight:r,scrollTop:n,jump:e.scrollTop-n,changed:!0}:{scrollHeight:r,scrollTop:n,jump:0,changed:!0}:{scrollTop:n,scrollHeight:r,jump:0,changed:!1}},{scrollHeight:0,jump:0,scrollTop:0,changed:!1}),t.filter(function(e){return e.changed}),t.map(function(e){return e.jump})),0);t.connect(t.pipe(S,t.map(function(e){return e.atBottom})),u),t.subscribe(u,function(e){setTimeout(function(){return t.publish(m,e)})});var C=t.statefulStream("down");t.subscribe(u,function(e){setTimeout(function(){t.publish(m,e)})}),t.connect(t.pipe(r,t.map(function(e){return e[0]}),t.distinctUntilChanged(),t.scan(function(e,n){return t.getValue(v)?{direction:e.direction,prevScrollTop:n}:{direction:n<e.prevScrollTop?h:"down",prevScrollTop:n}},{direction:"down",prevScrollTop:0}),t.map(function(e){return e.direction})),C),t.connect(t.pipe(r,t.throttleTime(50),t.mapTo("none")),C),t.connect(u,m);var x=t.statefulStream(0);return t.connect(t.pipe(d,t.filter(function(e){return!e}),t.mapTo(0)),x),t.connect(t.pipe(o,t.throttleTime(100),t.withLatestFrom(d),t.filter(function(e){return!!e[1]}),t.scan(function(e,t){return[e[1],t[0]]},[0,0]),t.map(function(e){return e[1]-e[0]})),x),{isScrolling:d,isAtTop:c,isAtBottom:u,atBottomState:S,atTopStateChange:f,atBottomStateChange:m,scrollDirection:C,atBottomThreshold:p,scrollVelocity:x,lastJumpDueToItemResize:I}},t.tup(m)),S=t.system(function(e){var n=e[0].scrollVelocity,r=t.statefulStream(!1),o=t.stream(),i=t.statefulStream(!1);return t.connect(t.pipe(n,t.withLatestFrom(i,r,o),t.filter(function(e){return!!e[1]}),t.map(function(e){var t=e[0],n=e[1],r=e[2],o=e[3],i=n.enter;if(r){if((0,n.exit)(t,o))return!1}else if(i(t,o))return!0;return r}),t.distinctUntilChanged()),r),t.subscribe(t.pipe(t.combineLatest(r,n,o),t.withLatestFrom(i)),function(e){var t=e[0],n=e[1];return t[0]&&n&&n.change&&n.change(t[1],t[2])}),{isSeeking:r,scrollSeekConfiguration:i,scrollVelocity:n,scrollSeekRangeChanged:o}},t.tup(v),{singleton:!0}),I={lvl:0};function C(e,t,n,r,o){return void 0===r&&(r=I),void 0===o&&(o=I),{k:e,v:t,lvl:n,l:r,r:o}}function x(e){return e===I}function w(){return I}function T(e,t){if(x(e))return I;var n=e.k,r=e.l,o=e.r;if(t===n){if(x(r))return o;if(x(o))return r;var i=R(r);return B(k(e,{k:i[0],v:i[1],l:H(r)}))}return B(k(e,t<n?{l:T(r,t)}:{r:T(o,t)}))}function b(e,t,n){if(void 0===n&&(n="k"),x(e))return[-Infinity,void 0];if(e[n]===t)return[e.k,e.v];if(e[n]<t){var r=b(e.r,t,n);return-Infinity===r[0]?[e.k,e.v]:r}return b(e.l,t,n)}function y(e,t,n){return x(e)?C(t,n,1):t===e.k?k(e,{k:t,v:n}):function(e){return M(U(e))}(k(e,t<e.k?{l:y(e.l,t,n)}:{r:y(e.r,t,n)}))}function L(e,t,n){if(x(e))return[];var r=e.k,o=e.v,i=e.r,a=[];return r>t&&(a=a.concat(L(e.l,t,n))),r>=t&&r<=n&&a.push({k:r,v:o}),r<=n&&(a=a.concat(L(i,t,n))),a}function E(e){return x(e)?[]:[].concat(E(e.l),[{k:e.k,v:e.v}],E(e.r))}function R(e){return x(e.r)?[e.k,e.v]:R(e.r)}function H(e){return x(e.r)?e.l:B(k(e,{r:H(e.r)}))}function k(e,t){return C(void 0!==t.k?t.k:e.k,void 0!==t.v?t.v:e.v,void 0!==t.lvl?t.lvl:e.lvl,void 0!==t.l?t.l:e.l,void 0!==t.r?t.r:e.r)}function z(e){return x(e)||e.lvl>e.r.lvl}function B(e){var t=e.l,n=e.r,r=e.lvl;if(n.lvl>=r-1&&t.lvl>=r-1)return e;if(r>n.lvl+1){if(z(t))return U(k(e,{lvl:r-1}));if(x(t)||x(t.r))throw new Error("Unexpected empty nodes");return k(t.r,{l:k(t,{r:t.r.l}),r:k(e,{l:t.r.r,lvl:r-1}),lvl:r})}if(z(e))return M(k(e,{lvl:r-1}));if(x(n)||x(n.l))throw new Error("Unexpected empty nodes");var o=n.l,i=z(o)?n.lvl-1:n.lvl;return k(o,{l:k(e,{r:o.l,lvl:r-1}),r:M(k(n,{l:o.r,lvl:i})),lvl:o.lvl+1})}function F(e,t,n){return x(e)?[]:O(L(e,b(e,t)[0],n),function(e){return{index:e.k,value:e.v}})}function O(e,t){var n=e.length;if(0===n)return[];for(var r=t(e[0]),o=r.index,i=r.value,a=[],l=1;l<n;l++){var s=t(e[l]),u=s.index,c=s.value;a.push({start:o,end:u-1,value:i}),o=u,i=c}return a.push({start:o,end:Infinity,value:i}),a}function M(e){var t=e.r,n=e.lvl;return x(t)||x(t.r)||t.lvl!==n||t.r.lvl!==n?e:k(t,{l:k(e,{r:t.l}),lvl:n+1})}function U(e){var t=e.l;return x(t)||t.lvl!==e.lvl?e:k(t,{r:k(e,{l:t.r})})}function P(e,t,n,r){void 0===r&&(r=0);for(var o=e.length-1;r<=o;){var i=Math.floor((r+o)/2),a=n(e[i],t);if(0===a)return i;if(-1===a){if(o-r<2)return i-1;o=i-1}else{if(o===r)return i;r=i+1}}throw new Error("Failed binary finding record in array - "+e.join(",")+", searched for "+t)}function V(e,t,n){return e[P(e,t,n)]}function A(e,t){return Math.round(e.getBoundingClientRect()[t])}function N(e){var t=e.size,n=e.startIndex,r=e.endIndex;return function(e){return e.start===n&&(e.end===r||Infinity===e.end)&&e.value===t}}function D(e,t){var n=e.index;return t===n?0:t<n?-1:1}function G(e,t){var n=e.offset;return t===n?0:t<n?-1:1}function W(e){return{index:e.index,value:e}}function _(e,t){var n=t[0],r=t[1];n.length>0&&(0,t[2])("received item sizes",n,exports.LogLevel.DEBUG);var o=e.sizeTree,i=e.offsetTree,l=o,s=0;if(r.length>0&&x(o)&&2===n.length){var u=n[0].size,c=n[1].size;l=r.reduce(function(e,t){return y(y(e,t,u),t+1,c)},l)}else{var m=function(e,t){for(var n,r=x(e)?0:Infinity,o=a(t);!(n=o()).done;){var i=n.value,l=i.size,s=i.startIndex,u=i.endIndex;if(r=Math.min(r,s),x(e))e=y(e,0,l);else{var c=F(e,s-1,u+1);if(!c.some(N(i))){for(var m,f=!1,p=!1,d=a(c);!(m=d()).done;){var h=m.value,g=h.start,v=h.end,S=h.value;f?(u>=g||l===S)&&(e=T(e,g)):(p=S!==l,f=!0),v>u&&u>=g&&S!==l&&(e=y(e,u+1,S))}p&&(e=y(e,s,l))}}}return[e,r]}(l,n);l=m[0],s=m[1]}if(l===o)return e;var f=0,p=0,d=0,h=0;if(0!==s){h=P(i,s-1,D),d=i[h].offset;var g=b(l,s-1);f=g[0],p=g[1],i.length&&i[h].size===b(l,s)[1]&&(h-=1),i=i.slice(0,h+1)}else i=[];for(var v,S=a(F(l,s,Infinity));!(v=S()).done;){var I=v.value,C=I.start,L=I.value,E=(C-f)*p+d;i.push({offset:E,size:L,index:C}),f=C,d=E,p=L}return{sizeTree:l,offsetTree:i,groupOffsetTree:r.reduce(function(e,t){return y(e,t,j(t,i))},w()),lastIndex:f,lastOffset:d,lastSize:p,groupIndices:r}}function j(e,t){if(0===t.length)return 0;var n=V(t,e,D);return n.size*(e-n.index)+n.offset}function K(e,t){if(!Y(t))return e;for(var n=0;t.groupIndices[n]<=e+n;)n++;return e+n}function Y(e){return!x(e.groupOffsetTree)}var q={offsetHeight:"height",offsetWidth:"width"},Z=t.system(function(e){var n=e[0].log,o=t.stream(),i=t.stream(),a=t.stream(),l=t.statefulStream(0),s=t.statefulStream([]),u=t.statefulStream(void 0),c=t.statefulStream(void 0),m=t.statefulStream(function(e,t){return A(e,q[t])}),f=t.statefulStream(void 0),p={offsetTree:[],sizeTree:w(),groupOffsetTree:w(),lastIndex:0,lastOffset:0,lastSize:0,groupIndices:[]},d=t.statefulStreamFromEmitter(t.pipe(o,t.withLatestFrom(s,n),t.scan(_,p),t.distinctUntilChanged()),p);t.connect(t.pipe(s,t.filter(function(e){return e.length>0}),t.withLatestFrom(d),t.map(function(e){var t=e[0],n=e[1],o=t.reduce(function(e,t,r){return y(e,t,j(t,n.offsetTree)||r)},w());return r({},n,{groupIndices:t,groupOffsetTree:o})})),d),t.connect(t.pipe(i,t.withLatestFrom(d),t.filter(function(e){return e[0]<e[1].lastIndex}),t.map(function(e){var t=e[1];return[{startIndex:e[0],endIndex:t.lastIndex,size:t.lastSize}]})),o),t.connect(u,c);var h=t.statefulStreamFromEmitter(t.pipe(u,t.map(function(e){return void 0===e})),!0);t.connect(t.pipe(c,t.filter(function(e){return void 0!==e&&x(t.getValue(d).sizeTree)}),t.map(function(e){return[{startIndex:0,endIndex:0,size:e}]})),o);var g=t.streamFromEmitter(t.pipe(o,t.withLatestFrom(d),t.scan(function(e,t){var n=t[1];return{changed:n!==e.sizes,sizes:n}},{changed:!1,sizes:p}),t.map(function(e){return e.changed})));t.connect(t.pipe(l,t.scan(function(e,t){return{diff:e.prev-t,prev:t}},{diff:0,prev:0}),t.map(function(e){return e.diff}),t.filter(function(e){return e>0})),a),t.subscribe(t.pipe(l,t.withLatestFrom(n)),function(e){e[0]<0&&(0,e[1])("`firstItemIndex` prop should not be set to less than zero. If you don't know the total count, just use a very high value",{firstItemIndex:l},exports.LogLevel.ERROR)});var v=t.streamFromEmitter(a);return t.connect(t.pipe(a,t.withLatestFrom(d),t.map(function(e){var t=e[0],n=e[1];if(n.groupIndices.length>0)throw new Error("Virtuoso: prepending items does not work with groups");return E(n.sizeTree).reduce(function(e,n){var r=n.k,o=n.v;return{ranges:[].concat(e.ranges,[{startIndex:e.prevIndex,endIndex:r+t-1,size:e.prevSize}]),prevIndex:r+t,prevSize:o}},{ranges:[],prevIndex:0,prevSize:n.lastSize}).ranges})),o),{data:f,totalCount:i,sizeRanges:o,groupIndices:s,defaultItemSize:c,fixedItemSize:u,unshiftWith:a,beforeUnshiftWith:v,firstItemIndex:l,sizes:d,listRefresh:g,trackItemSizes:h,itemSize:m}},t.tup(p),{singleton:!0}),J="undefined"!=typeof document&&"scrollBehavior"in document.documentElement.style;function $(e){var t="number"==typeof e?{index:e}:e;return t.align||(t.align="start"),t.behavior&&J||(t.behavior="auto"),t.offset||(t.offset=0),t}var Q=t.system(function(e){var n=e[0],r=n.sizes,o=n.totalCount,i=n.listRefresh,a=e[1],l=a.scrollingInProgress,s=a.viewportHeight,u=a.scrollTo,c=a.smoothScrollTargetReached,m=a.headerHeight,f=a.footerHeight,p=e[2].log,d=t.stream(),h=t.statefulStream(0),g=null,v=null,S=null;function I(){g&&(g(),g=null),S&&(S(),S=null),v&&(clearTimeout(v),v=null),t.publish(l,!1)}return t.connect(t.pipe(d,t.withLatestFrom(r,s,o,h,m,f,p),t.map(function(e){var n=e[0],r=e[1],o=e[2],a=e[3],s=e[4],u=e[5],m=e[6],f=e[7],p=$(n),h=p.align,C=p.behavior,x=p.offset,w=a-1,T=p.index;"LAST"===T&&(T=w),T=K(T,r);var y=j(T=Math.max(0,T,Math.min(w,T)),r.offsetTree)+u;"end"===h?(y=Math.round(y-o+b(r.sizeTree,T)[1]),T===w&&(y+=m)):"center"===h?y=Math.round(y-o/2+b(r.sizeTree,T)[1]/2):y-=s,x&&(y+=x);var L=function(e){I(),e?(f("retrying to scroll to",{location:n},exports.LogLevel.DEBUG),t.publish(d,n)):f("list did not change, scroll successful",{},exports.LogLevel.DEBUG)};if(I(),"smooth"===C){var E=!1;S=t.subscribe(i,function(e){E=E||e}),g=t.handleNext(c,function(){L(E)})}else g=t.handleNext(t.pipe(i,function(e){var t=setTimeout(function(){e(!1)},50);return function(n){n&&(e(!0),clearTimeout(t))}}),L);return v=setTimeout(function(){I()},1200),t.publish(l,!0),f("scrolling from index to",{index:T,top:y,behavior:C},exports.LogLevel.DEBUG),{top:y,behavior:C}})),u),{scrollToIndex:d,topListHeight:h}},t.tup(Z,m,p),{singleton:!0});function X(e,t,n){return"number"==typeof e?n===h&&"top"===t||"down"===n&&"bottom"===t?e:0:n===h?"top"===t?e.main:e.reverse:"bottom"===t?e.main:e.reverse}function ee(e,t){return"number"==typeof e?e:e[t]||0}var te=t.system(function(e){var n=e[0],r=n.scrollTop,o=n.viewportHeight,i=n.deviation,a=n.headerHeight,s=t.stream(),u=t.statefulStream(0),c=t.statefulStream(0),m=t.statefulStream(0);return{listBoundary:s,overscan:m,topListHeight:u,increaseViewportBy:c,visibleRange:t.statefulStreamFromEmitter(t.pipe(t.combineLatest(t.duc(r),t.duc(o),t.duc(a),t.duc(s,l),t.duc(m),t.duc(u),t.duc(i),t.duc(c)),t.map(function(e){var t=e[0],n=e[1],r=e[2],o=e[3],i=o[0],a=o[1],l=e[4],s=e[5],u=e[6],c=e[7],m=t-u,f=Math.max(r-m,0),p="none",d=ee(c,"top"),g=ee(c,"bottom");return i-=u,a+=r,(i+=r)>t+s-d&&(p=h),(a-=u)<t-f+n+g&&(p="down"),"none"!==p?[Math.max(m-r-X(l,"top",p)-d,0),m-f+n+X(l,"bottom",p)+g]:null}),t.filter(function(e){return null!=e}),t.distinctUntilChanged(l)),[0,0])}},t.tup(m),{singleton:!0}),ne=t.system(function(e){var n=e[0],o=n.scrollTo,i=n.scrollContainerState,a=t.stream(),l=t.stream(),s=t.stream(),u=t.statefulStream(!1);return t.connect(t.pipe(t.combineLatest(a,l),t.map(function(e){var t=e[0],n=t[1];return[Math.max(0,t[0]-e[1].offsetTop),n]})),i),t.connect(t.pipe(o,t.withLatestFrom(l),t.map(function(e){var t=e[0];return r({},t,{top:t.top+e[1].offsetTop})})),s),{useWindowScroll:u,windowScrollContainerState:a,windowViewportRect:l,windowScrollTo:s}},t.tup(m)),re={items:[],offsetBottom:0,offsetTop:0,top:0,bottom:0,itemHeight:0,itemWidth:0},oe={items:[{index:0}],offsetBottom:0,offsetTop:0,top:0,bottom:0,itemHeight:0,itemWidth:0},ie=Math.ceil,ae=Math.floor,le=Math.min,se=Math.max;function ue(e){return ie(e)-e<.03?ie(e):ae(e)}function ce(e,t){return Array.from({length:t-e+1}).map(function(t,n){return{index:n+e}})}var me=t.system(function(e){var n=e[0],o=n.overscan,i=n.visibleRange,a=n.listBoundary,u=e[1],c=u.scrollTop,m=u.viewportHeight,f=u.scrollBy,p=u.scrollTo,d=u.smoothScrollTargetReached,h=u.scrollContainerState,g=e[2],v=e[3],S=e[4],I=S.propsReady,C=S.didMount,x=e[5],w=x.windowViewportRect,T=x.windowScrollTo,b=x.useWindowScroll,y=x.windowScrollContainerState,L=t.statefulStream(0),E=t.statefulStream(0),R=t.statefulStream(re),H=t.statefulStream({height:0,width:0}),k=t.statefulStream({height:0,width:0}),z=t.stream(),B=t.stream(),F=t.statefulStream(0);t.connect(t.pipe(C,t.withLatestFrom(E),t.filter(function(e){return 0!==e[1]}),t.map(function(e){return{items:ce(0,e[1]-1),top:0,bottom:0,offsetBottom:0,offsetTop:0,itemHeight:0,itemWidth:0}})),R),t.connect(t.pipe(t.combineLatest(t.duc(L),i,t.duc(k,function(e,t){return e&&e.width===t.width&&e.height===t.height})),t.withLatestFrom(H),t.map(function(e){var t=e[0],n=t[0],r=t[1],o=r[0],i=r[1],a=t[2],l=e[1],s=a.height,u=a.width,c=l.width;if(0===n||0===c)return re;if(0===u)return oe;var m=ue(c/u),f=m*ae(o/s),p=m*ie(i/s)-1;p=le(n-1,p);var d=ce(f=le(p,se(0,f)),p),h=fe(l,a,d),g=h.top,v=h.bottom;return{items:d,offsetTop:g,offsetBottom:ie(n/m)*s-v,top:g,bottom:v,itemHeight:s,itemWidth:u}})),R),t.connect(t.pipe(H,t.map(function(e){return e.height})),m),t.connect(t.pipe(t.combineLatest(H,k,R),t.map(function(e){var t=fe(e[0],e[1],e[2].items);return[t.top,t.bottom]}),t.distinctUntilChanged(l)),a);var O=t.streamFromEmitter(t.pipe(t.duc(R),t.filter(function(e){return e.items.length>0}),t.withLatestFrom(L),t.filter(function(e){var t=e[0].items;return t[t.length-1].index===e[1]-1}),t.map(function(e){return e[1]-1}),t.distinctUntilChanged())),M=t.streamFromEmitter(t.pipe(t.duc(R),t.filter(function(e){var t=e.items;return t.length>0&&0===t[0].index}),t.mapTo(0),t.distinctUntilChanged())),U=t.streamFromEmitter(t.pipe(t.duc(R),t.filter(function(e){return e.items.length>0}),t.map(function(e){var t=e.items;return{startIndex:t[0].index,endIndex:t[t.length-1].index}}),t.distinctUntilChanged(s)));t.connect(U,v.scrollSeekRangeChanged),t.connect(t.pipe(z,t.withLatestFrom(H,k,L),t.map(function(e){var t=e[1],n=e[2],r=e[3],o=$(e[0]),i=o.align,a=o.behavior,l=o.offset,s=o.index;"LAST"===s&&(s=r-1);var u=pe(t,n,s=Math.max(0,s,Math.min(r-1,s)));return"end"===i?u=Math.round(u-t.height+n.height):"center"===i&&(u=Math.round(u-t.height/2+n.height/2)),l&&(u+=l),{top:u,behavior:a}})),p);var P=t.statefulStreamFromEmitter(t.pipe(R,t.map(function(e){return e.offsetBottom+e.bottom})),0);return t.connect(t.pipe(w,t.map(function(e){return{width:e.visibleWidth,height:e.visibleHeight}})),H),r({totalCount:L,viewportDimensions:H,itemDimensions:k,scrollTop:c,scrollHeight:B,overscan:o,scrollBy:f,scrollTo:p,scrollToIndex:z,smoothScrollTargetReached:d,windowViewportRect:w,windowScrollTo:T,useWindowScroll:b,windowScrollContainerState:y,deviation:F,scrollContainerState:h,initialItemCount:E},v,{gridState:R,totalListHeight:P},g,{startReached:M,endReached:O,rangeChanged:U,propsReady:I})},t.tup(te,m,v,S,d,ne));function fe(e,t,n){var r=t.height;return void 0===r||0===n.length?{top:0,bottom:0}:{top:pe(e,t,n[0].index),bottom:pe(e,t,n[n.length-1].index)+r}}function pe(e,t,n){var r=ue(e.width/t.width);return ae(n/r)*t.height}function de(e,t){void 0===t&&(t=!0);var r=n.useRef(null),o=function(e){};if("undefined"!=typeof ResizeObserver){var i=new ResizeObserver(function(t){var n=t[0].target;null!==n.offsetParent&&e(n)});o=function(e){e&&t?(i.observe(e),r.current=e):(r.current&&i.unobserve(r.current),r.current=null)}}return{ref:r,callbackRef:o}}function he(e,t){return void 0===t&&(t=!0),de(e,t).callbackRef}function ge(e){var t=n.useRef(null),r=n.useCallback(function(n){if(null!==n){var r=n.getBoundingClientRect(),o=window.innerHeight-Math.max(0,r.top),i=r.top+window.pageYOffset;t.current={offsetTop:i,visibleHeight:o,visibleWidth:r.width},e(t.current)}},[e]),o=de(r),i=o.callbackRef,a=o.ref,l=n.useCallback(function(){r(a.current)},[r,a]);return n.useEffect(function(){return window.addEventListener("scroll",l),window.addEventListener("resize",l),function(){window.removeEventListener("scroll",l),window.removeEventListener("resize",l)}},[l]),i}var ve="undefined"!=typeof document?n.useLayoutEffect:n.useEffect;function Se(e,r,o,i){void 0===i&&(i=t.noop);var a=n.useRef(null),l=n.useRef(null),s=n.useRef(null),u=n.useCallback(function(t){var n=t.target,o=n===window||n===document?window.pageYOffset||document.documentElement.scrollTop:n.scrollTop,i=n===window?document.documentElement.scrollHeight:n.scrollHeight;e([Math.max(o,0),i]),null!==l.current&&(o===l.current||o<=0||o===n.scrollHeight-A(n,"height"))&&(l.current=null,r(!0),s.current&&(clearTimeout(s.current),s.current=null))},[e,r]);return n.useEffect(function(){var e=a.current;return i(a.current),u({target:e}),e.addEventListener("scroll",u,{passive:!0}),function(){i(null),e.removeEventListener("scroll",u)}},[a,u,o,i]),{scrollerRef:a,scrollByCallback:function(e){null===l.current&&a.current.scrollBy(e)},scrollToCallback:function(t){var n=a.current;if(n&&(!("offsetHeight"in n)||0!==n.offsetHeight)){var o,i,u,c="smooth"===t.behavior;if(n===window?(i=Math.max(A(document.documentElement,"height"),document.documentElement.scrollHeight),o=window.innerHeight,u=document.documentElement.scrollTop):(i=n.scrollHeight,o=A(n,"height"),u=n.scrollTop),t.top=Math.max(Math.min(i-o,t.top),0),Math.abs(o-i)<1.01||t.top===u)return e([u,i]),void(c&&r(!0));c?(l.current=t.top,s.current&&clearTimeout(s.current),s.current=setTimeout(function(){s.current=null,l.current=null,r(!0)},1e3)):l.current=null,n.scrollTo(t)}}}}var Ie=t.system(function(e){var n=e[0],r=n.sizes,o=n.listRefresh,i=n.defaultItemSize,a=e[1].scrollTop,l=e[2].scrollToIndex,s=e[3].didMount,u=t.statefulStream(!0),c=t.statefulStream(0);return t.connect(t.pipe(s,t.withLatestFrom(c),t.filter(function(e){return 0!==e[1]}),t.mapTo(!1)),u),t.subscribe(t.pipe(t.combineLatest(o,s),t.withLatestFrom(u,r,i),t.filter(function(e){var t=e[1],n=e[3];return e[0][1]&&(!x(e[2].sizeTree)||void 0!==n)&&!t}),t.withLatestFrom(c)),function(e){var n=e[1];setTimeout(function(){t.handleNext(a,function(){t.publish(u,!0)}),t.publish(l,n)})}),{scrolledToInitialItem:u,initialTopMostItemIndex:c}},t.tup(Z,m,Q,d),{singleton:!0});function Ce(e){return!!e&&("smooth"===e?"smooth":"auto")}var xe=t.system(function(e){var n=e[0],r=n.totalCount,o=n.listRefresh,i=e[1],a=i.isAtBottom,l=i.atBottomState,s=e[2].scrollToIndex,u=e[3].scrolledToInitialItem,c=e[4],m=c.propsReady,f=c.didMount,p=e[5].log,d=e[6].scrollingInProgress,h=t.statefulStream(!1),g=null;function v(e){t.publish(s,{index:"LAST",align:"end",behavior:e})}return t.subscribe(t.pipe(t.combineLatest(t.pipe(t.duc(r),t.skip(1)),f),t.withLatestFrom(t.duc(h),a,u,d),t.map(function(e){var t=e[0],n=t[0],r=t[1]&&e[3],o="auto";return r&&(o=function(e,t){return"function"==typeof e?Ce(e(t)):t&&Ce(e)}(e[1],e[2]||e[4]),r=r&&!!o),{totalCount:n,shouldFollow:r,followOutputBehavior:o}}),t.filter(function(e){return e.shouldFollow})),function(e){var n=e.totalCount,r=e.followOutputBehavior;g&&(g(),g=null),g=t.handleNext(o,function(){t.getValue(p)("following output to ",{totalCount:n},exports.LogLevel.DEBUG),v(r),g=null})}),t.subscribe(t.pipe(t.combineLatest(t.duc(h),r,m),t.filter(function(e){return e[0]&&e[2]}),t.scan(function(e,t){var n=t[1];return{refreshed:e.value===n,value:n}},{refreshed:!1,value:0}),t.filter(function(e){return e.refreshed}),t.withLatestFrom(h,r)),function(e){var n=e[1],r=t.handleNext(l,function(e){!n||e.atBottom||"SIZE_INCREASED"!==e.notAtBottomBecause||g||(t.getValue(p)("scrolling to bottom due to increased size",{},exports.LogLevel.DEBUG),v("auto"))});setTimeout(r,100)}),t.subscribe(t.combineLatest(t.duc(h),l),function(e){var t=e[1];e[0]&&!t.atBottom&&"VIEWPORT_HEIGHT_DECREASING"===t.notAtBottomBecause&&v("auto")}),{followOutput:h}},t.tup(Z,v,Q,Ie,d,p,m));function we(e){return e.reduce(function(e,t){return e.groupIndices.push(e.totalCount),e.totalCount+=t+1,e},{totalCount:0,groupIndices:[]})}var Te=t.system(function(e){var n=e[0],r=n.totalCount,o=n.groupIndices,i=n.sizes,a=e[1],l=a.scrollTop,s=a.headerHeight,u=t.stream(),c=t.stream(),m=t.streamFromEmitter(t.pipe(u,t.map(we)));return t.connect(t.pipe(m,t.map(t.prop("totalCount"))),r),t.connect(t.pipe(m,t.map(t.prop("groupIndices"))),o),t.connect(t.pipe(t.combineLatest(l,i,s),t.filter(function(e){return Y(e[1])}),t.map(function(e){return b(e[1].groupOffsetTree,Math.max(e[0]-e[2],0),"v")[0]}),t.distinctUntilChanged(),t.map(function(e){return[e]})),c),{groupCounts:u,topItemsIndexes:c}},t.tup(Z,m)),be={items:[],topItems:[],offsetTop:0,offsetBottom:0,top:0,bottom:0,topListHeight:0,totalCount:0};function ye(e,t,n){if(0===e.length)return[];if(!Y(t))return e.map(function(e){return r({},e,{index:e.index+n,originalIndex:e.index})});for(var o,i=[],l=F(t.groupOffsetTree,e[0].index,e[e.length-1].index),s=void 0,u=0,c=a(e);!(o=c()).done;){var m=o.value;(!s||s.end<m.index)&&(s=l.shift(),u=t.groupIndices.indexOf(s.start)),i.push(r({},m.index===s.start?{type:"group",index:u}:{index:m.index-(u+1)+n,groupIndex:u},{size:m.size,offset:m.offset,originalIndex:m.index,data:m.data}))}return i}function Le(e,t,n,r,o){var i=0,a=0;if(e.length>0){i=e[0].offset;var l=e[e.length-1];a=l.offset+l.size}var s=i,u=r.lastOffset+(n-r.lastIndex)*r.lastSize-a;return{items:ye(e,r,o),topItems:ye(t,r,o),topListHeight:t.reduce(function(e,t){return t.size+e},0),offsetTop:i,offsetBottom:u,top:s,bottom:a,totalCount:n}}var Ee,Re,He,ke=t.system(function(e){var n=e[0],o=n.sizes,i=n.totalCount,u=n.data,c=n.firstItemIndex,m=e[1],f=e[2],p=f.visibleRange,d=f.listBoundary,h=f.topListHeight,g=e[3],v=g.scrolledToInitialItem,S=g.initialTopMostItemIndex,I=e[4].topListHeight,C=e[5],w=e[6].didMount,T=t.statefulStream([]),y=t.stream();t.connect(m.topItemsIndexes,T);var L=t.statefulStreamFromEmitter(t.pipe(t.combineLatest(w,t.duc(p),t.duc(i),t.duc(o),t.duc(S),v,t.duc(T),t.duc(c),u),t.filter(function(e){return e[0]}),t.map(function(e){var n=e[1],r=n[0],o=n[1],i=e[2],l=e[4],s=e[5],u=e[6],c=e[7],m=e[8],f=e[3],p=f.sizeTree,d=f.offsetTree;if(0===i||0===r&&0===o)return be;if(x(p))return Le(function(e,t,n){if(Y(t)){var r=K(e,t);return[{index:b(t.groupOffsetTree,r)[0],size:0,offset:0},{index:r,size:0,offset:0,data:n&&n[0]}]}return[{index:e,size:0,offset:0,data:n&&n[0]}]}(l,f,m),[],i,f,c);var h=[];if(u.length>0)for(var g,v=u[0],S=u[u.length-1],I=0,C=a(F(p,v,S));!(g=C()).done;)for(var w=g.value,T=w.value,y=Math.max(w.start,v),L=Math.min(w.end,S),E=y;E<=L;E++)h.push({index:E,size:T,offset:I,data:m&&m[E]}),I+=T;if(!s)return Le([],h,i,f,c);var R=u.length>0?u[u.length-1]+1:0,H=function(e,t,n,r){return void 0===r&&(r=0),r>0&&(t=Math.max(t,V(e,r,D).offset)),O((i=n,l=P(o=e,t,a=G),s=P(o,i,a,l),o.slice(l,s+1)),W);var o,i,a,l,s}(d,r,o,R);if(0===H.length)return null;var k=i-1;return Le(t.tap([],function(e){for(var t,n=a(H);!(t=n()).done;){var i=t.value,l=i.value,s=l.offset,u=i.start,c=l.size;l.offset<r&&(s+=((u+=Math.floor((r-l.offset)/c))-i.start)*c),u<R&&(s+=(R-u)*c,u=R);for(var f=Math.min(i.end,k),p=u;p<=f&&!(s>=o);p++)e.push({index:p,size:c,offset:s,data:m&&m[p]}),s+=c}}),h,i,f,c)}),t.filter(function(e){return null!==e}),t.distinctUntilChanged()),be);return t.connect(t.pipe(u,t.filter(function(e){return void 0!==e}),t.map(function(e){return e.length})),i),t.connect(t.pipe(L,t.map(t.prop("topListHeight"))),I),t.connect(I,h),t.connect(t.pipe(L,t.map(function(e){return[e.top,e.bottom]})),d),t.connect(t.pipe(L,t.map(function(e){return e.items})),y),r({listState:L,topItemsIndexes:T,endReached:t.streamFromEmitter(t.pipe(L,t.filter(function(e){return e.items.length>0}),t.withLatestFrom(i,u),t.filter(function(e){var t=e[0].items;return t[t.length-1].originalIndex===e[1]-1}),t.map(function(e){return[e[1]-1,e[2]]}),t.distinctUntilChanged(l),t.map(function(e){return e[0]}))),startReached:t.streamFromEmitter(t.pipe(L,t.throttleTime(200),t.filter(function(e){var t=e.items;return t.length>0&&t[0].originalIndex===e.topItems.length}),t.map(function(e){return e.items[0].index}),t.distinctUntilChanged())),rangeChanged:t.streamFromEmitter(t.pipe(L,t.filter(function(e){return e.items.length>0}),t.map(function(e){var t=e.items;return{startIndex:t[0].index,endIndex:t[t.length-1].index}}),t.distinctUntilChanged(s))),itemsRendered:y},C)},t.tup(Z,Te,te,Ie,Q,v,d),{singleton:!0}),ze=t.system(function(e){var n=e[0],r=n.sizes,o=n.firstItemIndex,i=n.data,l=e[1].listState,s=e[2].didMount,u=t.statefulStream(0);return t.connect(t.pipe(s,t.withLatestFrom(u),t.filter(function(e){return 0!==e[1]}),t.withLatestFrom(r,o,i),t.map(function(e){var t=e[0][1],n=e[1],r=e[2],o=e[3],i=void 0===o?[]:o,l=0;if(n.groupIndices.length>0)for(var s,u=a(n.groupIndices);!((s=u()).done||s.value-l>=t);)l++;var c=t+l;return Le(Array.from({length:c}).map(function(e,t){return{index:t,size:0,offset:0,data:i[t]}}),[],c,n,r)})),l),{initialItemCount:u}},t.tup(Z,ke,d),{singleton:!0}),Be=t.system(function(e){var n=e[0].topItemsIndexes,r=t.statefulStream(0);return t.connect(t.pipe(r,t.filter(function(e){return e>0}),t.map(function(e){return Array.from({length:e}).map(function(e,t){return t})})),n),{topItemCount:r}},t.tup(ke)),Fe=t.system(function(e){var n=e[0],r=n.footerHeight,o=n.headerHeight,i=e[1].listState,a=t.stream(),l=t.statefulStreamFromEmitter(t.pipe(t.combineLatest(r,o,i),t.map(function(e){var t=e[2];return e[0]+e[1]+t.offsetBottom+t.bottom})),0);return t.connect(t.duc(l),a),{totalListHeight:l,totalListHeightChanged:a}},t.tup(m,ke),{singleton:!0}),Oe=t.system(function(e){var n=e[0],r=n.scrollBy,o=n.scrollTop,i=n.deviation,a=n.scrollingInProgress,l=e[1],s=l.isScrolling,u=l.isAtBottom,c=l.atBottomState,m=l.scrollDirection,f=e[3],p=f.beforeUnshiftWith,d=f.sizes,g=e[4].log,v=t.streamFromEmitter(t.pipe(e[2].listState,t.withLatestFrom(l.lastJumpDueToItemResize),t.scan(function(e,t){var n=e[1],r=t[0],o=r.items,i=r.totalCount,a=t[1],l=0;if(e[2]===i){if(n.length>0&&o.length>0){var s=1===o.length;if(0!==o[0].originalIndex||0!==n[0].originalIndex)for(var u=function(e){var t=o[e],r=n.find(function(e){return e.originalIndex===t.originalIndex});return r?t.offset!==r.offset||s?(l=t.offset-r.offset+t.size-r.size,"break"):void 0:"continue"},c=o.length-1;c>=0;c--){var m=u(c);if("continue"!==m&&"break"===m)break}}0!==l&&(l+=a)}return[l,o,i]},[0,[],0]),t.filter(function(e){return 0!==e[0]}),t.withLatestFrom(o,m,a,g,u,c),t.filter(function(e){return!e[3]&&0!==e[1]&&e[2]===h}),t.map(function(e){var t=e[0][0];return(0,e[4])("Upward scrolling compensation",{amount:t},exports.LogLevel.DEBUG),t})));return t.connect(t.pipe(v,t.withLatestFrom(i),t.map(function(e){return e[1]-e[0]})),i),t.subscribe(t.pipe(t.combineLatest(t.statefulStreamFromEmitter(s,!1),i),t.filter(function(e){return!e[0]&&0!==e[1]}),t.map(function(e){return e[1]}),t.throttleTime(1)),function(e){e>0?(t.publish(r,{top:-e,behavior:"auto"}),t.publish(i,0)):(t.publish(i,0),t.publish(r,{top:-e,behavior:"auto"}))}),t.connect(t.pipe(p,t.withLatestFrom(d),t.map(function(e){return e[0]*e[1].lastSize})),v),{deviation:i}},t.tup(m,v,ke,Z,p)),Me=t.system(function(e){var n=e[0].totalListHeight,r=e[1].didMount,o=e[2].scrollTo,i=t.statefulStream(0);return t.subscribe(t.pipe(r,t.withLatestFrom(i),t.filter(function(e){return 0!==e[1]}),t.map(function(e){return{top:e[1]}})),function(e){t.handleNext(t.pipe(n,t.filter(function(e){return 0!==e})),function(){setTimeout(function(){t.publish(o,e)})})}),{initialScrollTop:i}},t.tup(Fe,d,m),{singleton:!0}),Ue=t.system(function(e){var n=e[0].viewportHeight,r=e[1].totalListHeight,o=t.statefulStream(!1);return{alignToBottom:o,paddingTopAddition:t.statefulStreamFromEmitter(t.pipe(t.combineLatest(o,n,r),t.filter(function(e){return e[0]}),t.map(function(e){return Math.max(0,e[1]-e[2])}),t.distinctUntilChanged()),0)}},t.tup(m,Fe),{singleton:!0}),Pe=t.system(function(e){var n=e[0],r=n.sizes,o=n.totalCount,i=e[1],a=i.scrollTop,l=i.viewportHeight,s=i.headerHeight,u=i.scrollingInProgress,c=e[2].scrollToIndex,m=t.stream();return t.connect(t.pipe(m,t.withLatestFrom(r,l,o,s,a),t.map(function(e){var n=e[0],r=n.index,o=n.behavior,i=void 0===o?"auto":o,a=n.done,l=e[1],s=e[2],c=e[4],m=e[5],f=e[3]-1,p=null;r=K(r,l);var d=j(r=Math.max(0,r,Math.min(f,r)),l.offsetTree)+c;return d<m?p={index:r,behavior:i,align:"start"}:d+b(l.sizeTree,r)[1]>m+s&&(p={index:r,behavior:i,align:"end"}),p?a&&t.handleNext(t.pipe(u,t.skip(1),t.filter(function(e){return!1===e})),a):a&&a(),p}),t.filter(function(e){return null!==e})),c),{scrollIntoView:m}},t.tup(Z,m,Q,ke,p),{singleton:!0}),Ve=t.system(function(e){return r({},e[0],e[1],e[2],e[3],e[4],e[5],e[6],e[7],e[8])},t.tup(te,ze,d,S,Fe,Me,Ue,ne,Pe)),Ae=t.system(function(e){var n=e[0],i=n.totalCount,a=n.sizeRanges,l=n.fixedItemSize,s=n.defaultItemSize,u=n.trackItemSizes,c=n.itemSize,m=n.data,f=n.firstItemIndex,p=n.groupIndices,d=e[1],h=d.initialTopMostItemIndex,g=d.scrolledToInitialItem,v=e[2],S=e[3],I=e[4],C=I.listState,x=I.topItemsIndexes,w=o(I,["listState","topItemsIndexes"]),T=e[5].scrollToIndex,b=e[7].topItemCount,y=e[8].groupCounts,L=e[9],E=e[10];return t.connect(w.rangeChanged,L.scrollSeekRangeChanged),t.connect(t.pipe(L.windowViewportRect,t.map(t.prop("visibleHeight"))),v.viewportHeight),r({totalCount:i,data:m,firstItemIndex:f,sizeRanges:a,initialTopMostItemIndex:h,scrolledToInitialItem:g,topItemsIndexes:x,topItemCount:b,groupCounts:y,fixedItemHeight:l,defaultItemHeight:s},S,{listState:C,scrollToIndex:T,trackItemSizes:u,itemSize:c,groupIndices:p},w,L,v,E)},t.tup(Z,Ie,m,xe,ke,Q,Oe,Be,Te,Ve,p)),Ne=(Ee=function(){if("undefined"==typeof document)return"sticky";var e=document.createElement("div");return e.style.position="-webkit-sticky","-webkit-sticky"===e.style.position?"-webkit-sticky":"sticky"},He=!1,function(){return He||(He=!0,Re=Ee()),Re});function De(e){return e}var Ge=t.system(function(){var e=t.statefulStream(function(e){return"Item "+e}),n=t.statefulStream(function(e){return"Group "+e}),r=t.statefulStream({}),o=t.statefulStream(De),i=t.statefulStream("div"),a=t.statefulStream(t.noop),l=function(e,n){return void 0===n&&(n=null),t.statefulStreamFromEmitter(t.pipe(r,t.map(function(t){return t[e]}),t.distinctUntilChanged()),n)};return{itemContent:e,groupContent:n,components:r,computeItemKey:o,headerFooterTag:i,scrollerRef:a,FooterComponent:l("Footer"),HeaderComponent:l("Header"),TopItemListComponent:l("TopItemList"),ListComponent:l("List","div"),ItemComponent:l("Item","div"),GroupComponent:l("Group","div"),ScrollerComponent:l("Scroller","div"),EmptyPlaceholder:l("EmptyPlaceholder"),ScrollSeekPlaceholder:l("ScrollSeekPlaceholder")}});function We(e,n){var r=t.stream();return t.subscribe(r,function(){return console.warn("react-virtuoso: You are using a deprecated property. "+n,"color: red;","color: inherit;","color: blue;")}),t.connect(r,e),r}var _e=t.system(function(e){var n=e[0],i=e[1],a={item:We(i.itemContent,"Rename the %citem%c prop to %citemContent."),group:We(i.groupContent,"Rename the %cgroup%c prop to %cgroupContent."),topItems:We(n.topItemCount,"Rename the %ctopItems%c prop to %ctopItemCount."),itemHeight:We(n.fixedItemHeight,"Rename the %citemHeight%c prop to %cfixedItemHeight."),scrollingStateChange:We(n.isScrolling,"Rename the %cscrollingStateChange%c prop to %cisScrolling."),adjustForPrependedItems:t.stream(),maxHeightCacheSize:t.stream(),footer:t.stream(),header:t.stream(),HeaderContainer:t.stream(),FooterContainer:t.stream(),ItemContainer:t.stream(),ScrollContainer:t.stream(),GroupContainer:t.stream(),ListContainer:t.stream(),emptyComponent:t.stream(),scrollSeek:t.stream()};function l(e,n,o){t.connect(t.pipe(e,t.withLatestFrom(i.components),t.map(function(e){var t,i=e[0],a=e[1];return console.warn("react-virtuoso: "+o+" property is deprecated. Pass components."+n+" instead."),r({},a,((t={})[n]=i,t))})),i.components)}return t.subscribe(a.adjustForPrependedItems,function(){console.warn("react-virtuoso: adjustForPrependedItems is no longer supported. Use the firstItemIndex property instead - https://virtuoso.dev/prepend-items.","color: red;","color: inherit;","color: blue;")}),t.subscribe(a.maxHeightCacheSize,function(){console.warn("react-virtuoso: maxHeightCacheSize is no longer necessary. Setting it has no effect - remove it from your code.")}),t.subscribe(a.HeaderContainer,function(){console.warn("react-virtuoso: HeaderContainer is deprecated. Use headerFooterTag if you want to change the wrapper of the header component and pass components.Header to change its contents.")}),t.subscribe(a.FooterContainer,function(){console.warn("react-virtuoso: FooterContainer is deprecated. Use headerFooterTag if you want to change the wrapper of the footer component and pass components.Footer to change its contents.")}),t.subscribe(a.scrollSeek,function(e){var a=e.placeholder,l=o(e,["placeholder"]);console.warn("react-virtuoso: scrollSeek property is deprecated. Pass scrollSeekConfiguration and specify the placeholder in components.ScrollSeekPlaceholder instead."),t.publish(i.components,r({},t.getValue(i.components),{ScrollSeekPlaceholder:a})),t.publish(n.scrollSeekConfiguration,l)}),l(a.footer,"Footer","footer"),l(a.header,"Header","header"),l(a.ItemContainer,"Item","ItemContainer"),l(a.ListContainer,"List","ListContainer"),l(a.ScrollContainer,"Scroller","ScrollContainer"),l(a.emptyComponent,"EmptyPlaceholder","emptyComponent"),l(a.GroupContainer,"Group","GroupContainer"),r({},n,i,a)},t.tup(Ae,Ge)),je=function(e){return n.createElement("div",{style:{height:e.height}})},Ke={position:Ne(),zIndex:1,overflowAnchor:"none"},Ye=n.memo(function(e){var o=e.showTopList,i=void 0!==o&&o,a=st("listState"),l=st("deviation"),s=lt("sizeRanges"),u=st("useWindowScroll"),c=lt("windowScrollContainerState"),m=lt("scrollContainerState"),f=u?c:m,p=st("itemContent"),d=st("groupContent"),h=st("trackItemSizes"),g=st("itemSize"),v=st("log"),S=function(e,t,n,r,o){return he(function(n){var i=function(e,t,n,r){var o=e.length;if(0===o)return null;for(var i=[],a=0;a<o;a++){var l=e.item(a);if(l&&void 0!==l.dataset.index){var s=parseInt(l.dataset.index),u=parseFloat(l.dataset.knownSize),c=t(l,"offsetHeight");if(0===c&&r("Zero-sized element, this should not happen",{child:l},exports.LogLevel.ERROR),c!==u){var m=i[i.length-1];0===i.length||m.size!==c||m.endIndex!==s-1?i.push({startIndex:s,endIndex:s,size:c}):i[i.length-1].endIndex++}}}return i}(n.children,t,0,o),a=n.parentElement.parentElement,l="window"===n.parentElement.dataset.viewportType?window.pageYOffset||document.documentElement.scrollTop:a.scrollTop;r([Math.max(l,0),a.scrollHeight]),null!==i&&e(i)},n)}(s,g,h,i?t.noop:f,v),I=st("EmptyPlaceholder"),C=st("ScrollSeekPlaceholder")||je,x=st("ListComponent"),w=st("ItemComponent"),T=st("GroupComponent"),b=st("computeItemKey"),y=st("isSeeking"),L=st("groupIndices").length>0,E=st("paddingTopAddition"),R=st("scrolledToInitialItem"),H=st("firstItemIndex"),k=i?{}:{boxSizing:"border-box",paddingTop:a.offsetTop+E,paddingBottom:a.offsetBottom,marginTop:l};return!i&&0===a.items.length&&I&&R?n.createElement(I):n.createElement(x,{ref:S,style:k,"data-test-id":i?"virtuoso-top-item-list":"virtuoso-item-list"},(i?a.topItems:a.items).map(function(e){var t=e.originalIndex,o=b(t+H,e.data);return y?n.createElement(C,r({key:o,index:e.index,height:e.size,type:e.type||"item"},"group"===e.type?{}:{groupIndex:e.groupIndex})):"group"===e.type?n.createElement(T,{key:o,"data-index":t,"data-known-size":e.size,"data-item-index":e.index,style:Ke},d(e.index)):n.createElement(w,{key:o,"data-index":t,"data-known-size":e.size,"data-item-index":e.index,"data-item-group-index":e.groupIndex,style:{overflowAnchor:"none"}},L?p(e.index,e.groupIndex,e.data):p(e.index,e.data))}))}),qe={height:"100%",outline:"none",overflowY:"auto",position:"relative",WebkitOverflowScrolling:"touch"},Ze={width:"100%",height:"100%",position:"absolute",top:0},Je={width:"100%",position:Ne(),top:0},$e=n.memo(function(){var e=st("HeaderComponent"),t=lt("headerHeight"),r=st("headerFooterTag"),o=he(function(e){return t(A(e,"height"))});return e?n.createElement(r,{ref:o},n.createElement(e)):null}),Qe=n.memo(function(){var e=st("FooterComponent"),t=lt("footerHeight"),r=st("headerFooterTag"),o=he(function(e){return t(A(e,"height"))});return e?n.createElement(r,{ref:o},n.createElement(e)):null});function Xe(e){var t=e.usePublisher,i=e.useEmitter,a=e.useEmitterValue;return n.memo(function(e){var l=e.style,s=e.children,u=o(e,["style","children"]),c=t("scrollContainerState"),m=a("ScrollerComponent"),f=Se(c,t("smoothScrollTargetReached"),m,a("scrollerRef")),p=f.scrollerRef,d=f.scrollByCallback;return i("scrollTo",f.scrollToCallback),i("scrollBy",d),n.createElement(m,r({ref:p,style:r({},qe,l),"data-test-id":"virtuoso-scroller",tabIndex:0},u),s)})}function et(e){var i=e.usePublisher,a=e.useEmitter,l=e.useEmitterValue;return n.memo(function(e){var s=e.style,u=e.children,c=o(e,["style","children"]),m=i("windowScrollContainerState"),f=l("ScrollerComponent"),p=i("smoothScrollTargetReached"),d=l("totalListHeight"),h=l("deviation"),g=Se(m,p,f,t.noop),v=g.scrollerRef,S=g.scrollByCallback,I=g.scrollToCallback;return ve(function(){return v.current=window,function(){v.current=null}},[v]),a("windowScrollTo",I),a("scrollBy",S),n.createElement(f,r({style:r({position:"relative"},s,0!==d?{height:d+h}:{})},c),u)})}var tt=function(e){var r=e.children,o=lt("viewportHeight"),i=he(t.compose(o,function(e){return A(e,"height")}));return n.createElement("div",{style:Ze,ref:i,"data-viewport-type":"element"},r)},nt=function(e){var t=e.children,r=ge(lt("windowViewportRect"));return n.createElement("div",{ref:r,style:Ze,"data-viewport-type":"window"},t)},rt=function(e){var t=e.children,o=st("TopItemListComponent"),i=st("headerHeight"),a=r({},Je,{marginTop:i+"px"});return n.createElement(o||"div",{style:a},t)},ot=n.memo(function(e){var t=st("useWindowScroll"),o=st("topItemsIndexes").length>0,i=t?nt:tt;return n.createElement(t?mt:ct,r({},e),n.createElement(i,null,n.createElement($e,null),n.createElement(Ye,null),n.createElement(Qe,null)),o&&n.createElement(rt,null,n.createElement(Ye,{showTopList:!0})))}),it=e.systemToComponent(_e,{required:{},optional:{followOutput:"followOutput",firstItemIndex:"firstItemIndex",itemContent:"itemContent",groupContent:"groupContent",overscan:"overscan",increaseViewportBy:"increaseViewportBy",totalCount:"totalCount",topItemCount:"topItemCount",initialTopMostItemIndex:"initialTopMostItemIndex",components:"components",groupCounts:"groupCounts",atBottomThreshold:"atBottomThreshold",computeItemKey:"computeItemKey",defaultItemHeight:"defaultItemHeight",fixedItemHeight:"fixedItemHeight",itemSize:"itemSize",scrollSeekConfiguration:"scrollSeekConfiguration",headerFooterTag:"headerFooterTag",data:"data",initialItemCount:"initialItemCount",initialScrollTop:"initialScrollTop",alignToBottom:"alignToBottom",useWindowScroll:"useWindowScroll",scrollerRef:"scrollerRef",logLevel:"logLevel",item:"item",group:"group",topItems:"topItems",itemHeight:"itemHeight",scrollingStateChange:"scrollingStateChange",maxHeightCacheSize:"maxHeightCacheSize",footer:"footer",header:"header",ItemContainer:"ItemContainer",ScrollContainer:"ScrollContainer",ListContainer:"ListContainer",GroupContainer:"GroupContainer",emptyComponent:"emptyComponent",HeaderContainer:"HeaderContainer",FooterContainer:"FooterContainer",scrollSeek:"scrollSeek"},methods:{scrollToIndex:"scrollToIndex",scrollIntoView:"scrollIntoView",scrollTo:"scrollTo",scrollBy:"scrollBy",adjustForPrependedItems:"adjustForPrependedItems"},events:{isScrolling:"isScrolling",endReached:"endReached",startReached:"startReached",rangeChanged:"rangeChanged",atBottomStateChange:"atBottomStateChange",atTopStateChange:"atTopStateChange",totalListHeightChanged:"totalListHeightChanged",itemsRendered:"itemsRendered",groupIndices:"groupIndices"}},ot),at=it.Component,lt=it.usePublisher,st=it.useEmitterValue,ut=it.useEmitter,ct=Xe({usePublisher:lt,useEmitterValue:st,useEmitter:ut}),mt=et({usePublisher:lt,useEmitterValue:st,useEmitter:ut}),ft=t.system(function(){var e=t.statefulStream(function(e){return"Item "+e}),n=t.statefulStream({}),r=t.statefulStream("virtuoso-grid-item"),o=t.statefulStream("virtuoso-grid-list"),i=t.statefulStream(De),a=t.statefulStream(t.noop),l=function(e,r){return void 0===r&&(r=null),t.statefulStreamFromEmitter(t.pipe(n,t.map(function(t){return t[e]}),t.distinctUntilChanged()),r)};return{itemContent:e,components:n,computeItemKey:i,itemClassName:r,listClassName:o,scrollerRef:a,ListComponent:l("List","div"),ItemComponent:l("Item","div"),ScrollerComponent:l("Scroller","div"),ScrollSeekPlaceholder:l("ScrollSeekPlaceholder","div")}}),pt=t.system(function(e){var n=e[0],i=e[1],a={item:We(i.itemContent,"Rename the %citem%c prop to %citemContent."),ItemContainer:t.stream(),ScrollContainer:t.stream(),ListContainer:t.stream(),emptyComponent:t.stream(),scrollSeek:t.stream()};function l(e,n,o){t.connect(t.pipe(e,t.withLatestFrom(i.components),t.map(function(e){var t,i=e[0],a=e[1];return console.warn("react-virtuoso: "+o+" property is deprecated. Pass components."+n+" instead."),r({},a,((t={})[n]=i,t))})),i.components)}return t.subscribe(a.scrollSeek,function(e){var a=e.placeholder,l=o(e,["placeholder"]);console.warn("react-virtuoso: scrollSeek property is deprecated. Pass scrollSeekConfiguration and specify the placeholder in components.ScrollSeekPlaceholder instead."),t.publish(i.components,r({},t.getValue(i.components),{ScrollSeekPlaceholder:a})),t.publish(n.scrollSeekConfiguration,l)}),l(a.ItemContainer,"Item","ItemContainer"),l(a.ListContainer,"List","ListContainer"),l(a.ScrollContainer,"Scroller","ScrollContainer"),r({},n,i,a)},t.tup(me,ft)),dt=n.memo(function(){var e=xt("gridState"),t=xt("listClassName"),r=xt("itemClassName"),o=xt("itemContent"),i=xt("computeItemKey"),a=xt("isSeeking"),l=Ct("scrollHeight"),s=xt("ItemComponent"),u=xt("ListComponent"),c=xt("ScrollSeekPlaceholder"),m=Ct("itemDimensions"),f=he(function(e){l(e.parentElement.parentElement.scrollHeight);var t=e.firstChild;t&&m(t.getBoundingClientRect())});return n.createElement(u,{ref:f,className:t,style:{paddingTop:e.offsetTop,paddingBottom:e.offsetBottom}},e.items.map(function(t){var l=i(t.index);return a?n.createElement(c,{key:l,index:t.index,height:e.itemHeight,width:e.itemWidth}):n.createElement(s,{className:r,"data-index":t.index,key:l},o(t.index))}))}),ht=function(e){var t=e.children,r=Ct("viewportDimensions"),o=he(function(e){r(e.getBoundingClientRect())});return n.createElement("div",{style:Ze,ref:o},t)},gt=function(e){var t=e.children,r=ge(Ct("windowViewportRect"));return n.createElement("div",{ref:r,style:Ze},t)},vt=n.memo(function(e){var t=r({},e),o=xt("useWindowScroll"),i=o?gt:ht;return n.createElement(o?bt:Tt,r({},t),n.createElement(i,null,n.createElement(dt,null)))}),St=e.systemToComponent(pt,{optional:{totalCount:"totalCount",overscan:"overscan",itemContent:"itemContent",components:"components",computeItemKey:"computeItemKey",initialItemCount:"initialItemCount",scrollSeekConfiguration:"scrollSeekConfiguration",listClassName:"listClassName",itemClassName:"itemClassName",useWindowScroll:"useWindowScroll",scrollerRef:"scrollerRef",item:"item",ItemContainer:"ItemContainer",ScrollContainer:"ScrollContainer",ListContainer:"ListContainer",scrollSeek:"scrollSeek"},methods:{scrollTo:"scrollTo",scrollBy:"scrollBy",scrollToIndex:"scrollToIndex"},events:{isScrolling:"isScrolling",endReached:"endReached",startReached:"startReached",rangeChanged:"rangeChanged",atBottomStateChange:"atBottomStateChange",atTopStateChange:"atTopStateChange"}},vt),It=St.Component,Ct=St.usePublisher,xt=St.useEmitterValue,wt=St.useEmitter,Tt=Xe({usePublisher:Ct,useEmitterValue:xt,useEmitter:wt}),bt=et({usePublisher:Ct,useEmitterValue:xt,useEmitter:wt}),yt=at,Lt=It;exports.GroupedVirtuoso=at,exports.Virtuoso=yt,exports.VirtuosoGrid=Lt;
"use strict";var e=require("@virtuoso.dev/react-urx"),t=require("@virtuoso.dev/urx"),n=require("react");function r(){return(r=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e}).apply(this,arguments)}function o(e,t){if(null==e)return{};var n,r,o={},i=Object.keys(e);for(r=0;r<i.length;r++)t.indexOf(n=i[r])>=0||(o[n]=e[n]);return o}function i(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function a(e,t){var n;if("undefined"==typeof Symbol||null==e[Symbol.iterator]){if(Array.isArray(e)||(n=function(e,t){if(e){if("string"==typeof e)return i(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?i(e,t):void 0}}(e))||t&&e&&"number"==typeof e.length){n&&(e=n);var r=0;return function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}return(n=e[Symbol.iterator]()).next.bind(n)}function l(e,t){return!(!e||e[0]!==t[0]||e[1]!==t[1])}function s(e,t){return!(!e||e.startIndex!==t.startIndex||e.endIndex!==t.endIndex)}var u,c,m=t.system(function(){var e=t.stream(),n=t.stream(),r=t.statefulStream(0),o=t.stream(),i=t.statefulStream(0),a=t.stream(),l=t.stream(),s=t.statefulStream(0),u=t.statefulStream(0),c=t.stream(),m=t.stream(),d=t.statefulStream(!1);return t.connect(t.pipe(e,t.map(function(e){return e[0]})),n),t.connect(t.pipe(e,t.map(function(e){return e[1]})),l),t.connect(n,i),{scrollContainerState:e,scrollTop:n,viewportHeight:a,headerHeight:s,footerHeight:u,scrollHeight:l,smoothScrollTargetReached:o,scrollTo:c,scrollBy:m,statefulScrollTop:i,deviation:r,scrollingInProgress:d}},[],{singleton:!0});(c=exports.LogLevel||(exports.LogLevel={}))[c.DEBUG=0]="DEBUG",c[c.INFO=1]="INFO",c[c.WARN=2]="WARN",c[c.ERROR=3]="ERROR";var d=((u={})[exports.LogLevel.DEBUG]="debug",u[exports.LogLevel.INFO]="log",u[exports.LogLevel.WARN]="warn",u[exports.LogLevel.ERROR]="error",u),f=t.system(function(){var e=t.statefulStream(exports.LogLevel.ERROR);return{log:t.statefulStream(function(n,r,o){var i;void 0===o&&(o=exports.LogLevel.INFO),o>=(null!=(i=("undefined"==typeof globalThis?window:globalThis).VIRTUOSO_LOG_LEVEL)?i:t.getValue(e))&&console[d[o]]("%creact-virtuoso: %c%s %o","color: #0253b3; font-weight: bold","color: initial",n,r)}),logLevel:e}},[],{singleton:!0}),p=t.system(function(e){var n=e[0].log,r=t.statefulStream(!1),o=t.streamFromEmitter(t.pipe(r,t.filter(function(e){return e}),t.distinctUntilChanged()));return t.subscribe(r,function(e){e&&t.getValue(n)("props updated",{},exports.LogLevel.DEBUG)}),{propsReady:r,didMount:o}},t.tup(f),{singleton:!0}),h="up",g={atBottom:!1,notAtBottomBecause:"NOT_SHOWING_LAST_ITEM",state:{offsetBottom:0,scrollTop:0,viewportHeight:0,scrollHeight:0}},v=t.system(function(e){var n=e[0],r=n.scrollContainerState,o=n.scrollTop,i=n.viewportHeight,a=n.headerHeight,l=n.footerHeight,s=n.scrollBy,u=t.statefulStream(!1),c=t.statefulStream(!0),m=t.stream(),d=t.stream(),f=t.statefulStream(4),p=t.streamFromEmitter(t.pipe(t.merge(t.pipe(t.duc(o),t.skip(1),t.mapTo(!0)),t.pipe(t.duc(o),t.skip(1),t.mapTo(!1),t.debounceTime(100))),t.distinctUntilChanged())),v=t.statefulStreamFromEmitter(t.pipe(t.merge(t.pipe(s,t.mapTo(!0)),t.pipe(s,t.mapTo(!1),t.debounceTime(200))),t.distinctUntilChanged()),!1);t.connect(t.pipe(t.duc(o),t.map(function(e){return 0===e}),t.distinctUntilChanged()),c),t.connect(c,d);var S=t.streamFromEmitter(t.pipe(t.combineLatest(r,t.duc(i),t.duc(a),t.duc(l),t.duc(f)),t.scan(function(e,t){var n,r,o=t[0],i=o[0],a=o[1],l=t[1],s={viewportHeight:l,scrollTop:i,scrollHeight:a};return i+l-a>-t[4]?(i>e.state.scrollTop?(n="SCROLLED_DOWN",r=e.state.scrollTop-i):(n="SIZE_DECREASED",r=e.state.scrollTop-i||e.scrollTopDelta),{atBottom:!0,state:s,atBottomBecause:n,scrollTopDelta:r}):{atBottom:!1,notAtBottomBecause:s.scrollHeight>e.state.scrollHeight?"SIZE_INCREASED":l<e.state.viewportHeight?"VIEWPORT_HEIGHT_DECREASING":i<e.state.scrollTop?"SCROLLING_UPWARDS":"NOT_FULLY_SCROLLED_TO_LAST_ITEM_BOTTOM",state:s}},g),t.distinctUntilChanged(function(e,t){return e&&e.atBottom===t.atBottom}))),I=t.statefulStreamFromEmitter(t.pipe(r,t.scan(function(e,t){var n=t[0],r=t[1];return e.scrollHeight!==r?e.scrollTop!==n?{scrollHeight:r,scrollTop:n,jump:e.scrollTop-n,changed:!0}:{scrollHeight:r,scrollTop:n,jump:0,changed:!0}:{scrollTop:n,scrollHeight:r,jump:0,changed:!1}},{scrollHeight:0,jump:0,scrollTop:0,changed:!1}),t.filter(function(e){return e.changed}),t.map(function(e){return e.jump})),0);t.connect(t.pipe(S,t.map(function(e){return e.atBottom})),u),t.subscribe(u,function(e){setTimeout(function(){return t.publish(m,e)})});var C=t.statefulStream("down");t.subscribe(u,function(e){setTimeout(function(){t.publish(m,e)})}),t.connect(t.pipe(r,t.map(function(e){return e[0]}),t.distinctUntilChanged(),t.scan(function(e,n){return t.getValue(v)?{direction:e.direction,prevScrollTop:n}:{direction:n<e.prevScrollTop?h:"down",prevScrollTop:n}},{direction:"down",prevScrollTop:0}),t.map(function(e){return e.direction})),C),t.connect(t.pipe(r,t.throttleTime(50),t.mapTo("none")),C),t.connect(u,m);var x=t.statefulStream(0);return t.connect(t.pipe(p,t.filter(function(e){return!e}),t.mapTo(0)),x),t.connect(t.pipe(o,t.throttleTime(100),t.withLatestFrom(p),t.filter(function(e){return!!e[1]}),t.scan(function(e,t){return[e[1],t[0]]},[0,0]),t.map(function(e){return e[1]-e[0]})),x),{isScrolling:p,isAtTop:c,isAtBottom:u,atBottomState:S,atTopStateChange:d,atBottomStateChange:m,scrollDirection:C,atBottomThreshold:f,scrollVelocity:x,lastJumpDueToItemResize:I}},t.tup(m)),S=t.system(function(e){var n=e[0].scrollVelocity,r=t.statefulStream(!1),o=t.stream(),i=t.statefulStream(!1);return t.connect(t.pipe(n,t.withLatestFrom(i,r,o),t.filter(function(e){return!!e[1]}),t.map(function(e){var t=e[0],n=e[1],r=e[2],o=e[3],i=n.enter;if(r){if((0,n.exit)(t,o))return!1}else if(i(t,o))return!0;return r}),t.distinctUntilChanged()),r),t.subscribe(t.pipe(t.combineLatest(r,n,o),t.withLatestFrom(i)),function(e){var t=e[0],n=e[1];return t[0]&&n&&n.change&&n.change(t[1],t[2])}),{isSeeking:r,scrollSeekConfiguration:i,scrollVelocity:n,scrollSeekRangeChanged:o}},t.tup(v),{singleton:!0}),I={lvl:0};function C(e,t,n,r,o){return void 0===r&&(r=I),void 0===o&&(o=I),{k:e,v:t,lvl:n,l:r,r:o}}function x(e){return e===I}function T(){return I}function w(e,t){if(x(e))return I;var n=e.k,r=e.l,o=e.r;if(t===n){if(x(r))return o;if(x(o))return r;var i=H(r);return B(k(e,{k:i[0],v:i[1],l:R(r)}))}return B(k(e,t<n?{l:w(r,t)}:{r:w(o,t)}))}function y(e,t,n){if(void 0===n&&(n="k"),x(e))return[-Infinity,void 0];if(e[n]===t)return[e.k,e.v];if(e[n]<t){var r=y(e.r,t,n);return-Infinity===r[0]?[e.k,e.v]:r}return y(e.l,t,n)}function b(e,t,n){return x(e)?C(t,n,1):t===e.k?k(e,{k:t,v:n}):function(e){return M(P(e))}(k(e,t<e.k?{l:b(e.l,t,n)}:{r:b(e.r,t,n)}))}function E(e,t,n){if(x(e))return[];var r=e.k,o=e.v,i=e.r,a=[];return r>t&&(a=a.concat(E(e.l,t,n))),r>=t&&r<=n&&a.push({k:r,v:o}),r<=n&&(a=a.concat(E(i,t,n))),a}function L(e){return x(e)?[]:[].concat(L(e.l),[{k:e.k,v:e.v}],L(e.r))}function H(e){return x(e.r)?[e.k,e.v]:H(e.r)}function R(e){return x(e.r)?e.l:B(k(e,{r:R(e.r)}))}function k(e,t){return C(void 0!==t.k?t.k:e.k,void 0!==t.v?t.v:e.v,void 0!==t.lvl?t.lvl:e.lvl,void 0!==t.l?t.l:e.l,void 0!==t.r?t.r:e.r)}function z(e){return x(e)||e.lvl>e.r.lvl}function B(e){var t=e.l,n=e.r,r=e.lvl;if(n.lvl>=r-1&&t.lvl>=r-1)return e;if(r>n.lvl+1){if(z(t))return P(k(e,{lvl:r-1}));if(x(t)||x(t.r))throw new Error("Unexpected empty nodes");return k(t.r,{l:k(t,{r:t.r.l}),r:k(e,{l:t.r.r,lvl:r-1}),lvl:r})}if(z(e))return M(k(e,{lvl:r-1}));if(x(n)||x(n.l))throw new Error("Unexpected empty nodes");var o=n.l,i=z(o)?n.lvl-1:n.lvl;return k(o,{l:k(e,{r:o.l,lvl:r-1}),r:M(k(n,{l:o.r,lvl:i})),lvl:o.lvl+1})}function F(e,t,n){return x(e)?[]:O(E(e,y(e,t)[0],n),function(e){return{index:e.k,value:e.v}})}function O(e,t){var n=e.length;if(0===n)return[];for(var r=t(e[0]),o=r.index,i=r.value,a=[],l=1;l<n;l++){var s=t(e[l]),u=s.index,c=s.value;a.push({start:o,end:u-1,value:i}),o=u,i=c}return a.push({start:o,end:Infinity,value:i}),a}function M(e){var t=e.r,n=e.lvl;return x(t)||x(t.r)||t.lvl!==n||t.r.lvl!==n?e:k(t,{l:k(e,{r:t.l}),lvl:n+1})}function P(e){var t=e.l;return x(t)||t.lvl!==e.lvl?e:k(t,{r:k(e,{l:t.r})})}function V(e,t,n,r){void 0===r&&(r=0);for(var o=e.length-1;r<=o;){var i=Math.floor((r+o)/2),a=n(e[i],t);if(0===a)return i;if(-1===a){if(o-r<2)return i-1;o=i-1}else{if(o===r)return i;r=i+1}}throw new Error("Failed binary finding record in array - "+e.join(",")+", searched for "+t)}function U(e,t,n){return e[V(e,t,n)]}function A(e,t){return Math.round(e.getBoundingClientRect()[t])}function W(e){var t=e.size,n=e.startIndex,r=e.endIndex;return function(e){return e.start===n&&(e.end===r||Infinity===e.end)&&e.value===t}}function N(e,t){var n=e.index;return t===n?0:t<n?-1:1}function D(e,t){var n=e.offset;return t===n?0:t<n?-1:1}function G(e){return{index:e.index,value:e}}function _(e,t){var n=t[0],r=t[1];n.length>0&&(0,t[2])("received item sizes",n,exports.LogLevel.DEBUG);var o=e.sizeTree,i=e.offsetTree,l=o,s=0;if(r.length>0&&x(o)&&2===n.length){var u=n[0].size,c=n[1].size;l=r.reduce(function(e,t){return b(b(e,t,u),t+1,c)},l)}else{var m=function(e,t){for(var n,r=x(e)?0:Infinity,o=a(t);!(n=o()).done;){var i=n.value,l=i.size,s=i.startIndex,u=i.endIndex;if(r=Math.min(r,s),x(e))e=b(e,0,l);else{var c=F(e,s-1,u+1);if(!c.some(W(i))){for(var m,d=!1,f=!1,p=a(c);!(m=p()).done;){var h=m.value,g=h.start,v=h.end,S=h.value;d?(u>=g||l===S)&&(e=w(e,g)):(f=S!==l,d=!0),v>u&&u>=g&&S!==l&&(e=b(e,u+1,S))}f&&(e=b(e,s,l))}}}return[e,r]}(l,n);l=m[0],s=m[1]}if(l===o)return e;var d=0,f=0,p=0,h=0;if(0!==s){h=V(i,s-1,N),p=i[h].offset;var g=y(l,s-1);d=g[0],f=g[1],i.length&&i[h].size===y(l,s)[1]&&(h-=1),i=i.slice(0,h+1)}else i=[];for(var v,S=a(F(l,s,Infinity));!(v=S()).done;){var I=v.value,C=I.start,E=I.value,L=(C-d)*f+p;i.push({offset:L,size:E,index:C}),d=C,p=L,f=E}return{sizeTree:l,offsetTree:i,groupOffsetTree:r.reduce(function(e,t){return b(e,t,j(t,i))},T()),lastIndex:d,lastOffset:p,lastSize:f,groupIndices:r}}function j(e,t){if(0===t.length)return 0;var n=U(t,e,N);return n.size*(e-n.index)+n.offset}function K(e,t){if(!Y(t))return e;for(var n=0;t.groupIndices[n]<=e+n;)n++;return e+n}function Y(e){return!x(e.groupOffsetTree)}var q={offsetHeight:"height",offsetWidth:"width"},Z=t.system(function(e){var n=e[0].log,o=t.stream(),i=t.stream(),a=t.stream(),l=t.statefulStream(0),s=t.statefulStream([]),u=t.statefulStream(void 0),c=t.statefulStream(void 0),m=t.statefulStream(function(e,t){return A(e,q[t])}),d=t.statefulStream(void 0),f={offsetTree:[],sizeTree:T(),groupOffsetTree:T(),lastIndex:0,lastOffset:0,lastSize:0,groupIndices:[]},p=t.statefulStreamFromEmitter(t.pipe(o,t.withLatestFrom(s,n),t.scan(_,f),t.distinctUntilChanged()),f);t.connect(t.pipe(s,t.filter(function(e){return e.length>0}),t.withLatestFrom(p),t.map(function(e){var t=e[0],n=e[1],o=t.reduce(function(e,t,r){return b(e,t,j(t,n.offsetTree)||r)},T());return r({},n,{groupIndices:t,groupOffsetTree:o})})),p),t.connect(t.pipe(i,t.withLatestFrom(p),t.filter(function(e){return e[0]<e[1].lastIndex}),t.map(function(e){var t=e[1];return[{startIndex:e[0],endIndex:t.lastIndex,size:t.lastSize}]})),o),t.connect(u,c);var h=t.statefulStreamFromEmitter(t.pipe(u,t.map(function(e){return void 0===e})),!0);t.connect(t.pipe(c,t.filter(function(e){return void 0!==e&&x(t.getValue(p).sizeTree)}),t.map(function(e){return[{startIndex:0,endIndex:0,size:e}]})),o);var g=t.streamFromEmitter(t.pipe(o,t.withLatestFrom(p),t.scan(function(e,t){var n=t[1];return{changed:n!==e.sizes,sizes:n}},{changed:!1,sizes:f}),t.map(function(e){return e.changed})));t.connect(t.pipe(l,t.scan(function(e,t){return{diff:e.prev-t,prev:t}},{diff:0,prev:0}),t.map(function(e){return e.diff}),t.filter(function(e){return e>0})),a),t.subscribe(t.pipe(l,t.withLatestFrom(n)),function(e){e[0]<0&&(0,e[1])("`firstItemIndex` prop should not be set to less than zero. If you don't know the total count, just use a very high value",{firstItemIndex:l},exports.LogLevel.ERROR)});var v=t.streamFromEmitter(a);return t.connect(t.pipe(a,t.withLatestFrom(p),t.map(function(e){var t=e[0],n=e[1];if(n.groupIndices.length>0)throw new Error("Virtuoso: prepending items does not work with groups");return L(n.sizeTree).reduce(function(e,n){var r=n.k,o=n.v;return{ranges:[].concat(e.ranges,[{startIndex:e.prevIndex,endIndex:r+t-1,size:e.prevSize}]),prevIndex:r+t,prevSize:o}},{ranges:[],prevIndex:0,prevSize:n.lastSize}).ranges})),o),{data:d,totalCount:i,sizeRanges:o,groupIndices:s,defaultItemSize:c,fixedItemSize:u,unshiftWith:a,beforeUnshiftWith:v,firstItemIndex:l,sizes:p,listRefresh:g,trackItemSizes:h,itemSize:m}},t.tup(f),{singleton:!0}),J="undefined"!=typeof document&&"scrollBehavior"in document.documentElement.style;function $(e){var t="number"==typeof e?{index:e}:e;return t.align||(t.align="start"),t.behavior&&J||(t.behavior="auto"),t.offset||(t.offset=0),t}var Q=t.system(function(e){var n=e[0],r=n.sizes,o=n.totalCount,i=n.listRefresh,a=e[1],l=a.scrollingInProgress,s=a.viewportHeight,u=a.scrollTo,c=a.smoothScrollTargetReached,m=a.headerHeight,d=a.footerHeight,f=e[2].log,p=t.stream(),h=t.statefulStream(0),g=null,v=null,S=null;function I(){g&&(g(),g=null),S&&(S(),S=null),v&&(clearTimeout(v),v=null),t.publish(l,!1)}return t.connect(t.pipe(p,t.withLatestFrom(r,s,o,h,m,d,f),t.map(function(e){var n=e[0],r=e[1],o=e[2],a=e[3],s=e[4],u=e[5],m=e[6],d=e[7],f=$(n),h=f.align,C=f.behavior,x=f.offset,T=a-1,w=f.index;"LAST"===w&&(w=T),w=K(w,r);var b=j(w=Math.max(0,w,Math.min(T,w)),r.offsetTree)+u;"end"===h?(b=Math.round(b-o+y(r.sizeTree,w)[1]),w===T&&(b+=m)):"center"===h?b=Math.round(b-o/2+y(r.sizeTree,w)[1]/2):b-=s,x&&(b+=x);var E=function(e){I(),e?(d("retrying to scroll to",{location:n},exports.LogLevel.DEBUG),t.publish(p,n)):d("list did not change, scroll successful",{},exports.LogLevel.DEBUG)};if(I(),"smooth"===C){var L=!1;S=t.subscribe(i,function(e){L=L||e}),g=t.handleNext(c,function(){E(L)})}else g=t.handleNext(t.pipe(i,function(e){var t=setTimeout(function(){e(!1)},50);return function(n){n&&(e(!0),clearTimeout(t))}}),E);return v=setTimeout(function(){I()},1200),t.publish(l,!0),d("scrolling from index to",{index:w,top:b,behavior:C},exports.LogLevel.DEBUG),{top:b,behavior:C}})),u),{scrollToIndex:p,topListHeight:h}},t.tup(Z,m,f),{singleton:!0});function X(e,t,n){return"number"==typeof e?n===h&&"top"===t||"down"===n&&"bottom"===t?e:0:n===h?"top"===t?e.main:e.reverse:"bottom"===t?e.main:e.reverse}function ee(e,t){return"number"==typeof e?e:e[t]||0}var te=t.system(function(e){var n=e[0],r=n.scrollTop,o=n.viewportHeight,i=n.deviation,a=n.headerHeight,s=t.stream(),u=t.statefulStream(0),c=t.statefulStream(0),m=t.statefulStream(0),d=t.statefulStream(0);return{listBoundary:s,overscan:d,topListHeight:u,fixedHeaderHeight:c,increaseViewportBy:m,visibleRange:t.statefulStreamFromEmitter(t.pipe(t.combineLatest(t.duc(r),t.duc(o),t.duc(a),t.duc(s,l),t.duc(d),t.duc(u),t.duc(c),t.duc(i),t.duc(m)),t.map(function(e){var t=e[0],n=e[1],r=e[2],o=e[3],i=o[0],a=o[1],l=e[4],s=e[6],u=e[7],c=e[8],m=t-u,d=e[5]+s,f=Math.max(r-m,0),p="none",g=ee(c,"top"),v=ee(c,"bottom");return i-=u,a+=r,(i+=r)>t+d-g&&(p=h),(a-=u)<t-f+n+v&&(p="down"),"none"!==p?[Math.max(m-r-X(l,"top",p)-g,0),m-f-s+n+X(l,"bottom",p)+v]:null}),t.filter(function(e){return null!=e}),t.distinctUntilChanged(l)),[0,0])}},t.tup(m),{singleton:!0}),ne=t.system(function(e){var n=e[0],o=n.scrollTo,i=n.scrollContainerState,a=t.stream(),l=t.stream(),s=t.stream(),u=t.statefulStream(!1);return t.connect(t.pipe(t.combineLatest(a,l),t.map(function(e){var t=e[0],n=t[1];return[Math.max(0,t[0]-e[1].offsetTop),n]})),i),t.connect(t.pipe(o,t.withLatestFrom(l),t.map(function(e){var t=e[0];return r({},t,{top:t.top+e[1].offsetTop})})),s),{useWindowScroll:u,windowScrollContainerState:a,windowViewportRect:l,windowScrollTo:s}},t.tup(m)),re={items:[],offsetBottom:0,offsetTop:0,top:0,bottom:0,itemHeight:0,itemWidth:0},oe={items:[{index:0}],offsetBottom:0,offsetTop:0,top:0,bottom:0,itemHeight:0,itemWidth:0},ie=Math.ceil,ae=Math.floor,le=Math.min,se=Math.max;function ue(e){return ie(e)-e<.03?ie(e):ae(e)}function ce(e,t){return Array.from({length:t-e+1}).map(function(t,n){return{index:n+e}})}var me=t.system(function(e){var n=e[0],o=n.overscan,i=n.visibleRange,a=n.listBoundary,u=e[1],c=u.scrollTop,m=u.viewportHeight,d=u.scrollBy,f=u.scrollTo,p=u.smoothScrollTargetReached,h=u.scrollContainerState,g=e[2],v=e[3],S=e[4],I=S.propsReady,C=S.didMount,x=e[5],T=x.windowViewportRect,w=x.windowScrollTo,y=x.useWindowScroll,b=x.windowScrollContainerState,E=t.statefulStream(0),L=t.statefulStream(0),H=t.statefulStream(re),R=t.statefulStream({height:0,width:0}),k=t.statefulStream({height:0,width:0}),z=t.stream(),B=t.stream(),F=t.statefulStream(0);t.connect(t.pipe(C,t.withLatestFrom(L),t.filter(function(e){return 0!==e[1]}),t.map(function(e){return{items:ce(0,e[1]-1),top:0,bottom:0,offsetBottom:0,offsetTop:0,itemHeight:0,itemWidth:0}})),H),t.connect(t.pipe(t.combineLatest(t.duc(E),i,t.duc(k,function(e,t){return e&&e.width===t.width&&e.height===t.height})),t.withLatestFrom(R),t.map(function(e){var t=e[0],n=t[0],r=t[1],o=r[0],i=r[1],a=t[2],l=e[1],s=a.height,u=a.width,c=l.width;if(0===n||0===c)return re;if(0===u)return oe;var m=ue(c/u),d=m*ae(o/s),f=m*ie(i/s)-1;f=le(n-1,f);var p=ce(d=le(f,se(0,d)),f),h=de(l,a,p),g=h.top,v=h.bottom;return{items:p,offsetTop:g,offsetBottom:ie(n/m)*s-v,top:g,bottom:v,itemHeight:s,itemWidth:u}})),H),t.connect(t.pipe(R,t.map(function(e){return e.height})),m),t.connect(t.pipe(t.combineLatest(R,k,H),t.map(function(e){var t=de(e[0],e[1],e[2].items);return[t.top,t.bottom]}),t.distinctUntilChanged(l)),a);var O=t.streamFromEmitter(t.pipe(t.duc(H),t.filter(function(e){return e.items.length>0}),t.withLatestFrom(E),t.filter(function(e){var t=e[0].items;return t[t.length-1].index===e[1]-1}),t.map(function(e){return e[1]-1}),t.distinctUntilChanged())),M=t.streamFromEmitter(t.pipe(t.duc(H),t.filter(function(e){var t=e.items;return t.length>0&&0===t[0].index}),t.mapTo(0),t.distinctUntilChanged())),P=t.streamFromEmitter(t.pipe(t.duc(H),t.filter(function(e){return e.items.length>0}),t.map(function(e){var t=e.items;return{startIndex:t[0].index,endIndex:t[t.length-1].index}}),t.distinctUntilChanged(s)));t.connect(P,v.scrollSeekRangeChanged),t.connect(t.pipe(z,t.withLatestFrom(R,k,E),t.map(function(e){var t=e[1],n=e[2],r=e[3],o=$(e[0]),i=o.align,a=o.behavior,l=o.offset,s=o.index;"LAST"===s&&(s=r-1);var u=fe(t,n,s=Math.max(0,s,Math.min(r-1,s)));return"end"===i?u=Math.round(u-t.height+n.height):"center"===i&&(u=Math.round(u-t.height/2+n.height/2)),l&&(u+=l),{top:u,behavior:a}})),f);var V=t.statefulStreamFromEmitter(t.pipe(H,t.map(function(e){return e.offsetBottom+e.bottom})),0);return t.connect(t.pipe(T,t.map(function(e){return{width:e.visibleWidth,height:e.visibleHeight}})),R),r({totalCount:E,viewportDimensions:R,itemDimensions:k,scrollTop:c,scrollHeight:B,overscan:o,scrollBy:d,scrollTo:f,scrollToIndex:z,smoothScrollTargetReached:p,windowViewportRect:T,windowScrollTo:w,useWindowScroll:y,windowScrollContainerState:b,deviation:F,scrollContainerState:h,initialItemCount:L},v,{gridState:H,totalListHeight:V},g,{startReached:M,endReached:O,rangeChanged:P,propsReady:I})},t.tup(te,m,v,S,p,ne));function de(e,t,n){var r=t.height;return void 0===r||0===n.length?{top:0,bottom:0}:{top:fe(e,t,n[0].index),bottom:fe(e,t,n[n.length-1].index)+r}}function fe(e,t,n){var r=ue(e.width/t.width);return ae(n/r)*t.height}function pe(e,t){void 0===t&&(t=!0);var r=n.useRef(null),o=function(e){};if("undefined"!=typeof ResizeObserver){var i=new ResizeObserver(function(t){var n=t[0].target;null!==n.offsetParent&&e(n)});o=function(e){e&&t?(i.observe(e),r.current=e):(r.current&&i.unobserve(r.current),r.current=null)}}return{ref:r,callbackRef:o}}function he(e,t){return void 0===t&&(t=!0),pe(e,t).callbackRef}function ge(e){var t=n.useRef(null),r=n.useCallback(function(n){if(null!==n){var r=n.getBoundingClientRect(),o=window.innerHeight-Math.max(0,r.top),i=r.top+window.pageYOffset;t.current={offsetTop:i,visibleHeight:o,visibleWidth:r.width},e(t.current)}},[e]),o=pe(r),i=o.callbackRef,a=o.ref,l=n.useCallback(function(){r(a.current)},[r,a]);return n.useEffect(function(){return window.addEventListener("scroll",l),window.addEventListener("resize",l),function(){window.removeEventListener("scroll",l),window.removeEventListener("resize",l)}},[l]),i}var ve="undefined"!=typeof document?n.useLayoutEffect:n.useEffect;function Se(e,t,n,r,o){return he(function(n){for(var i=function(e,t,n,r){var o=e.length;if(0===o)return null;for(var i=[],a=0;a<o;a++){var l=e.item(a);if(l&&void 0!==l.dataset.index){var s=parseInt(l.dataset.index),u=parseFloat(l.dataset.knownSize),c=t(l,"offsetHeight");if(0===c&&r("Zero-sized element, this should not happen",{child:l},exports.LogLevel.ERROR),c!==u){var m=i[i.length-1];0===i.length||m.size!==c||m.endIndex!==s-1?i.push({startIndex:s,endIndex:s,size:c}):i[i.length-1].endIndex++}}}return i}(n.children,t,0,o),a=n.parentElement;!a.dataset.virtuosoScroller;)a=a.parentElement;var l="window"===a.firstElementChild.dataset.viewportType?window.pageYOffset||document.documentElement.scrollTop:a.scrollTop;r([Math.max(l,0),a.scrollHeight]),null!==i&&e(i)},n)}function Ie(e,r,o,i){void 0===i&&(i=t.noop);var a=n.useRef(null),l=n.useRef(null),s=n.useRef(null),u=n.useCallback(function(t){var n=t.target,o=n===window||n===document?window.pageYOffset||document.documentElement.scrollTop:n.scrollTop,i=n===window?document.documentElement.scrollHeight:n.scrollHeight;e([Math.max(o,0),i]),null!==l.current&&(o===l.current||o<=0||o===n.scrollHeight-A(n,"height"))&&(l.current=null,r(!0),s.current&&(clearTimeout(s.current),s.current=null))},[e,r]);return n.useEffect(function(){var e=a.current;return i(a.current),u({target:e}),e.addEventListener("scroll",u,{passive:!0}),function(){i(null),e.removeEventListener("scroll",u)}},[a,u,o,i]),{scrollerRef:a,scrollByCallback:function(e){null===l.current&&a.current.scrollBy(e)},scrollToCallback:function(t){var n=a.current;if(n&&(!("offsetHeight"in n)||0!==n.offsetHeight)){var o,i,u,c="smooth"===t.behavior;if(n===window?(i=Math.max(A(document.documentElement,"height"),document.documentElement.scrollHeight),o=window.innerHeight,u=document.documentElement.scrollTop):(i=n.scrollHeight,o=A(n,"height"),u=n.scrollTop),t.top=Math.max(Math.min(i-o,t.top),0),Math.abs(o-i)<1.01||t.top===u)return e([u,i]),void(c&&r(!0));c?(l.current=t.top,s.current&&clearTimeout(s.current),s.current=setTimeout(function(){s.current=null,l.current=null,r(!0)},1e3)):l.current=null,n.scrollTo(t)}}}}var Ce=t.system(function(e){var n=e[0],r=n.sizes,o=n.listRefresh,i=n.defaultItemSize,a=e[1].scrollTop,l=e[2].scrollToIndex,s=e[3].didMount,u=t.statefulStream(!0),c=t.statefulStream(0);return t.connect(t.pipe(s,t.withLatestFrom(c),t.filter(function(e){return 0!==e[1]}),t.mapTo(!1)),u),t.subscribe(t.pipe(t.combineLatest(o,s),t.withLatestFrom(u,r,i),t.filter(function(e){var t=e[1],n=e[3];return e[0][1]&&(!x(e[2].sizeTree)||void 0!==n)&&!t}),t.withLatestFrom(c)),function(e){var n=e[1];setTimeout(function(){t.handleNext(a,function(){t.publish(u,!0)}),t.publish(l,n)})}),{scrolledToInitialItem:u,initialTopMostItemIndex:c}},t.tup(Z,m,Q,p),{singleton:!0});function xe(e){return!!e&&("smooth"===e?"smooth":"auto")}var Te=t.system(function(e){var n=e[0],r=n.totalCount,o=n.listRefresh,i=e[1],a=i.isAtBottom,l=i.atBottomState,s=e[2].scrollToIndex,u=e[3].scrolledToInitialItem,c=e[4],m=c.propsReady,d=c.didMount,f=e[5].log,p=e[6].scrollingInProgress,h=t.statefulStream(!1),g=null;function v(e){t.publish(s,{index:"LAST",align:"end",behavior:e})}return t.subscribe(t.pipe(t.combineLatest(t.pipe(t.duc(r),t.skip(1)),d),t.withLatestFrom(t.duc(h),a,u,p),t.map(function(e){var t=e[0],n=t[0],r=t[1]&&e[3],o="auto";return r&&(o=function(e,t){return"function"==typeof e?xe(e(t)):t&&xe(e)}(e[1],e[2]||e[4]),r=r&&!!o),{totalCount:n,shouldFollow:r,followOutputBehavior:o}}),t.filter(function(e){return e.shouldFollow})),function(e){var n=e.totalCount,r=e.followOutputBehavior;g&&(g(),g=null),g=t.handleNext(o,function(){t.getValue(f)("following output to ",{totalCount:n},exports.LogLevel.DEBUG),v(r),g=null})}),t.subscribe(t.pipe(t.combineLatest(t.duc(h),r,m),t.filter(function(e){return e[0]&&e[2]}),t.scan(function(e,t){var n=t[1];return{refreshed:e.value===n,value:n}},{refreshed:!1,value:0}),t.filter(function(e){return e.refreshed}),t.withLatestFrom(h,r)),function(e){var n=e[1],r=t.handleNext(l,function(e){!n||e.atBottom||"SIZE_INCREASED"!==e.notAtBottomBecause||g||(t.getValue(f)("scrolling to bottom due to increased size",{},exports.LogLevel.DEBUG),v("auto"))});setTimeout(r,100)}),t.subscribe(t.combineLatest(t.duc(h),l),function(e){var t=e[1];e[0]&&!t.atBottom&&"VIEWPORT_HEIGHT_DECREASING"===t.notAtBottomBecause&&v("auto")}),{followOutput:h}},t.tup(Z,v,Q,Ce,p,f,m));function we(e){return e.reduce(function(e,t){return e.groupIndices.push(e.totalCount),e.totalCount+=t+1,e},{totalCount:0,groupIndices:[]})}var ye=t.system(function(e){var n=e[0],r=n.totalCount,o=n.groupIndices,i=n.sizes,a=e[1],l=a.scrollTop,s=a.headerHeight,u=t.stream(),c=t.stream(),m=t.streamFromEmitter(t.pipe(u,t.map(we)));return t.connect(t.pipe(m,t.map(t.prop("totalCount"))),r),t.connect(t.pipe(m,t.map(t.prop("groupIndices"))),o),t.connect(t.pipe(t.combineLatest(l,i,s),t.filter(function(e){return Y(e[1])}),t.map(function(e){return y(e[1].groupOffsetTree,Math.max(e[0]-e[2],0),"v")[0]}),t.distinctUntilChanged(),t.map(function(e){return[e]})),c),{groupCounts:u,topItemsIndexes:c}},t.tup(Z,m)),be={items:[],topItems:[],offsetTop:0,offsetBottom:0,top:0,bottom:0,topListHeight:0,totalCount:0};function Ee(e,t,n){if(0===e.length)return[];if(!Y(t))return e.map(function(e){return r({},e,{index:e.index+n,originalIndex:e.index})});for(var o,i=[],l=F(t.groupOffsetTree,e[0].index,e[e.length-1].index),s=void 0,u=0,c=a(e);!(o=c()).done;){var m=o.value;(!s||s.end<m.index)&&(s=l.shift(),u=t.groupIndices.indexOf(s.start)),i.push(r({},m.index===s.start?{type:"group",index:u}:{index:m.index-(u+1)+n,groupIndex:u},{size:m.size,offset:m.offset,originalIndex:m.index,data:m.data}))}return i}function Le(e,t,n,r,o){var i=0,a=0;if(e.length>0){i=e[0].offset;var l=e[e.length-1];a=l.offset+l.size}var s=i,u=r.lastOffset+(n-r.lastIndex)*r.lastSize-a;return{items:Ee(e,r,o),topItems:Ee(t,r,o),topListHeight:t.reduce(function(e,t){return t.size+e},0),offsetTop:i,offsetBottom:u,top:s,bottom:a,totalCount:n}}var He,Re,ke,ze=t.system(function(e){var n=e[0],o=n.sizes,i=n.totalCount,u=n.data,c=n.firstItemIndex,m=e[1],d=e[2],f=d.visibleRange,p=d.listBoundary,h=d.topListHeight,g=e[3],v=g.scrolledToInitialItem,S=g.initialTopMostItemIndex,I=e[4].topListHeight,C=e[5],T=e[6].didMount,w=t.statefulStream([]),b=t.stream();t.connect(m.topItemsIndexes,w);var E=t.statefulStreamFromEmitter(t.pipe(t.combineLatest(T,t.duc(f),t.duc(i),t.duc(o),t.duc(S),v,t.duc(w),t.duc(c),u),t.filter(function(e){return e[0]}),t.map(function(e){var n=e[1],r=n[0],o=n[1],i=e[2],l=e[4],s=e[5],u=e[6],c=e[7],m=e[8],d=e[3],f=d.sizeTree,p=d.offsetTree;if(0===i||0===r&&0===o)return be;if(x(f))return Le(function(e,t,n){if(Y(t)){var r=K(e,t);return[{index:y(t.groupOffsetTree,r)[0],size:0,offset:0},{index:r,size:0,offset:0,data:n&&n[0]}]}return[{index:e,size:0,offset:0,data:n&&n[0]}]}(l,d,m),[],i,d,c);var h=[];if(u.length>0)for(var g,v=u[0],S=u[u.length-1],I=0,C=a(F(f,v,S));!(g=C()).done;)for(var T=g.value,w=T.value,b=Math.max(T.start,v),E=Math.min(T.end,S),L=b;L<=E;L++)h.push({index:L,size:w,offset:I,data:m&&m[L]}),I+=w;if(!s)return Le([],h,i,d,c);var H=u.length>0?u[u.length-1]+1:0,R=function(e,t,n,r){return void 0===r&&(r=0),r>0&&(t=Math.max(t,U(e,r,N).offset)),O((i=n,l=V(o=e,t,a=D),s=V(o,i,a,l),o.slice(l,s+1)),G);var o,i,a,l,s}(p,r,o,H);if(0===R.length)return null;var k=i-1;return Le(t.tap([],function(e){for(var t,n=a(R);!(t=n()).done;){var i=t.value,l=i.value,s=l.offset,u=i.start,c=l.size;l.offset<r&&(s+=((u+=Math.floor((r-l.offset)/c))-i.start)*c),u<H&&(s+=(H-u)*c,u=H);for(var d=Math.min(i.end,k),f=u;f<=d&&!(s>=o);f++)e.push({index:f,size:c,offset:s,data:m&&m[f]}),s+=c}}),h,i,d,c)}),t.filter(function(e){return null!==e}),t.distinctUntilChanged()),be);return t.connect(t.pipe(u,t.filter(function(e){return void 0!==e}),t.map(function(e){return e.length})),i),t.connect(t.pipe(E,t.map(t.prop("topListHeight"))),I),t.connect(I,h),t.connect(t.pipe(E,t.map(function(e){return[e.top,e.bottom]})),p),t.connect(t.pipe(E,t.map(function(e){return e.items})),b),r({listState:E,topItemsIndexes:w,endReached:t.streamFromEmitter(t.pipe(E,t.filter(function(e){return e.items.length>0}),t.withLatestFrom(i,u),t.filter(function(e){var t=e[0].items;return t[t.length-1].originalIndex===e[1]-1}),t.map(function(e){return[e[1]-1,e[2]]}),t.distinctUntilChanged(l),t.map(function(e){return e[0]}))),startReached:t.streamFromEmitter(t.pipe(E,t.throttleTime(200),t.filter(function(e){var t=e.items;return t.length>0&&t[0].originalIndex===e.topItems.length}),t.map(function(e){return e.items[0].index}),t.distinctUntilChanged())),rangeChanged:t.streamFromEmitter(t.pipe(E,t.filter(function(e){return e.items.length>0}),t.map(function(e){var t=e.items;return{startIndex:t[0].index,endIndex:t[t.length-1].index}}),t.distinctUntilChanged(s))),itemsRendered:b},C)},t.tup(Z,ye,te,Ce,Q,v,p),{singleton:!0}),Be=t.system(function(e){var n=e[0],r=n.sizes,o=n.firstItemIndex,i=n.data,l=e[1].listState,s=e[2].didMount,u=t.statefulStream(0);return t.connect(t.pipe(s,t.withLatestFrom(u),t.filter(function(e){return 0!==e[1]}),t.withLatestFrom(r,o,i),t.map(function(e){var t=e[0][1],n=e[1],r=e[2],o=e[3],i=void 0===o?[]:o,l=0;if(n.groupIndices.length>0)for(var s,u=a(n.groupIndices);!((s=u()).done||s.value-l>=t);)l++;var c=t+l;return Le(Array.from({length:c}).map(function(e,t){return{index:t,size:0,offset:0,data:i[t]}}),[],c,n,r)})),l),{initialItemCount:u}},t.tup(Z,ze,p),{singleton:!0}),Fe=t.system(function(e){var n=e[0].topItemsIndexes,r=t.statefulStream(0);return t.connect(t.pipe(r,t.filter(function(e){return e>0}),t.map(function(e){return Array.from({length:e}).map(function(e,t){return t})})),n),{topItemCount:r}},t.tup(ze)),Oe=t.system(function(e){var n=e[0],r=n.footerHeight,o=n.headerHeight,i=e[1].listState,a=t.stream(),l=t.statefulStreamFromEmitter(t.pipe(t.combineLatest(r,o,i),t.map(function(e){var t=e[2];return e[0]+e[1]+t.offsetBottom+t.bottom})),0);return t.connect(t.duc(l),a),{totalListHeight:l,totalListHeightChanged:a}},t.tup(m,ze),{singleton:!0}),Me=t.system(function(e){var n=e[0],r=n.scrollBy,o=n.scrollTop,i=n.deviation,a=n.scrollingInProgress,l=e[1],s=l.isScrolling,u=l.isAtBottom,c=l.atBottomState,m=l.scrollDirection,d=e[3],f=d.beforeUnshiftWith,p=d.sizes,g=e[4].log,v=t.streamFromEmitter(t.pipe(e[2].listState,t.withLatestFrom(l.lastJumpDueToItemResize),t.scan(function(e,t){var n=e[1],r=t[0],o=r.items,i=r.totalCount,a=t[1],l=0;if(e[2]===i){if(n.length>0&&o.length>0){var s=1===o.length;if(0!==o[0].originalIndex||0!==n[0].originalIndex)for(var u=function(e){var t=o[e],r=n.find(function(e){return e.originalIndex===t.originalIndex});return r?t.offset!==r.offset||s?(l=t.offset-r.offset+t.size-r.size,"break"):void 0:"continue"},c=o.length-1;c>=0;c--){var m=u(c);if("continue"!==m&&"break"===m)break}}0!==l&&(l+=a)}return[l,o,i]},[0,[],0]),t.filter(function(e){return 0!==e[0]}),t.withLatestFrom(o,m,a,g,u,c),t.filter(function(e){return!e[3]&&0!==e[1]&&e[2]===h}),t.map(function(e){var t=e[0][0];return(0,e[4])("Upward scrolling compensation",{amount:t},exports.LogLevel.DEBUG),t})));return t.connect(t.pipe(v,t.withLatestFrom(i),t.map(function(e){return e[1]-e[0]})),i),t.subscribe(t.pipe(t.combineLatest(t.statefulStreamFromEmitter(s,!1),i),t.filter(function(e){return!e[0]&&0!==e[1]}),t.map(function(e){return e[1]}),t.throttleTime(1)),function(e){e>0?(t.publish(r,{top:-e,behavior:"auto"}),t.publish(i,0)):(t.publish(i,0),t.publish(r,{top:-e,behavior:"auto"}))}),t.connect(t.pipe(f,t.withLatestFrom(p),t.map(function(e){return e[0]*e[1].lastSize})),v),{deviation:i}},t.tup(m,v,ze,Z,f)),Pe=t.system(function(e){var n=e[0].totalListHeight,r=e[1].didMount,o=e[2].scrollTo,i=t.statefulStream(0);return t.subscribe(t.pipe(r,t.withLatestFrom(i),t.filter(function(e){return 0!==e[1]}),t.map(function(e){return{top:e[1]}})),function(e){t.handleNext(t.pipe(n,t.filter(function(e){return 0!==e})),function(){setTimeout(function(){t.publish(o,e)})})}),{initialScrollTop:i}},t.tup(Oe,p,m),{singleton:!0}),Ve=t.system(function(e){var n=e[0].viewportHeight,r=e[1].totalListHeight,o=t.statefulStream(!1);return{alignToBottom:o,paddingTopAddition:t.statefulStreamFromEmitter(t.pipe(t.combineLatest(o,n,r),t.filter(function(e){return e[0]}),t.map(function(e){return Math.max(0,e[1]-e[2])}),t.distinctUntilChanged()),0)}},t.tup(m,Oe),{singleton:!0}),Ue=t.system(function(e){var n=e[0],r=n.sizes,o=n.totalCount,i=e[1],a=i.scrollTop,l=i.viewportHeight,s=i.headerHeight,u=i.scrollingInProgress,c=e[2].scrollToIndex,m=t.stream();return t.connect(t.pipe(m,t.withLatestFrom(r,l,o,s,a),t.map(function(e){var n=e[0],r=n.index,o=n.behavior,i=void 0===o?"auto":o,a=n.done,l=e[1],s=e[2],c=e[4],m=e[5],d=e[3]-1,f=null;r=K(r,l);var p=j(r=Math.max(0,r,Math.min(d,r)),l.offsetTree)+c;return p<m?f={index:r,behavior:i,align:"start"}:p+y(l.sizeTree,r)[1]>m+s&&(f={index:r,behavior:i,align:"end"}),f?a&&t.handleNext(t.pipe(u,t.skip(1),t.filter(function(e){return!1===e})),a):a&&a(),f}),t.filter(function(e){return null!==e})),c),{scrollIntoView:m}},t.tup(Z,m,Q,ze,f),{singleton:!0}),Ae=t.system(function(e){return r({},e[0],e[1],e[2],e[3],e[4],e[5],e[6],e[7],e[8])},t.tup(te,Be,p,S,Oe,Pe,Ve,ne,Ue)),We=t.system(function(e){var n=e[0],i=n.totalCount,a=n.sizeRanges,l=n.fixedItemSize,s=n.defaultItemSize,u=n.trackItemSizes,c=n.itemSize,m=n.data,d=n.firstItemIndex,f=n.groupIndices,p=e[1],h=p.initialTopMostItemIndex,g=p.scrolledToInitialItem,v=e[2],S=e[3],I=e[4],C=I.listState,x=I.topItemsIndexes,T=o(I,["listState","topItemsIndexes"]),w=e[5].scrollToIndex,y=e[7].topItemCount,b=e[8].groupCounts,E=e[9],L=e[10];return t.connect(T.rangeChanged,E.scrollSeekRangeChanged),t.connect(t.pipe(E.windowViewportRect,t.map(t.prop("visibleHeight"))),v.viewportHeight),r({totalCount:i,data:m,firstItemIndex:d,sizeRanges:a,initialTopMostItemIndex:h,scrolledToInitialItem:g,topItemsIndexes:x,topItemCount:y,groupCounts:b,fixedItemHeight:l,defaultItemHeight:s},S,{listState:C,scrollToIndex:w,trackItemSizes:u,itemSize:c,groupIndices:f},T,E,v,L)},t.tup(Z,Ce,m,Te,ze,Q,Me,Fe,ye,Ae,f)),Ne=(He=function(){if("undefined"==typeof document)return"sticky";var e=document.createElement("div");return e.style.position="-webkit-sticky","-webkit-sticky"===e.style.position?"-webkit-sticky":"sticky"},ke=!1,function(){return ke||(ke=!0,Re=He()),Re});function De(e){return e}var Ge=t.system(function(){var e=t.statefulStream(function(e){return"Item "+e}),n=t.statefulStream(function(e){return"Group "+e}),r=t.statefulStream({}),o=t.statefulStream(De),i=t.statefulStream("div"),a=t.statefulStream(t.noop),l=function(e,n){return void 0===n&&(n=null),t.statefulStreamFromEmitter(t.pipe(r,t.map(function(t){return t[e]}),t.distinctUntilChanged()),n)};return{itemContent:e,groupContent:n,components:r,computeItemKey:o,headerFooterTag:i,scrollerRef:a,FooterComponent:l("Footer"),HeaderComponent:l("Header"),TopItemListComponent:l("TopItemList"),ListComponent:l("List","div"),ItemComponent:l("Item","div"),GroupComponent:l("Group","div"),ScrollerComponent:l("Scroller","div"),EmptyPlaceholder:l("EmptyPlaceholder"),ScrollSeekPlaceholder:l("ScrollSeekPlaceholder")}});function _e(e,n){var r=t.stream();return t.subscribe(r,function(){return console.warn("react-virtuoso: You are using a deprecated property. "+n,"color: red;","color: inherit;","color: blue;")}),t.connect(r,e),r}var je=t.system(function(e){var n=e[0],i=e[1],a={item:_e(i.itemContent,"Rename the %citem%c prop to %citemContent."),group:_e(i.groupContent,"Rename the %cgroup%c prop to %cgroupContent."),topItems:_e(n.topItemCount,"Rename the %ctopItems%c prop to %ctopItemCount."),itemHeight:_e(n.fixedItemHeight,"Rename the %citemHeight%c prop to %cfixedItemHeight."),scrollingStateChange:_e(n.isScrolling,"Rename the %cscrollingStateChange%c prop to %cisScrolling."),adjustForPrependedItems:t.stream(),maxHeightCacheSize:t.stream(),footer:t.stream(),header:t.stream(),HeaderContainer:t.stream(),FooterContainer:t.stream(),ItemContainer:t.stream(),ScrollContainer:t.stream(),GroupContainer:t.stream(),ListContainer:t.stream(),emptyComponent:t.stream(),scrollSeek:t.stream()};function l(e,n,o){t.connect(t.pipe(e,t.withLatestFrom(i.components),t.map(function(e){var t,i=e[0],a=e[1];return console.warn("react-virtuoso: "+o+" property is deprecated. Pass components."+n+" instead."),r({},a,((t={})[n]=i,t))})),i.components)}return t.subscribe(a.adjustForPrependedItems,function(){console.warn("react-virtuoso: adjustForPrependedItems is no longer supported. Use the firstItemIndex property instead - https://virtuoso.dev/prepend-items.","color: red;","color: inherit;","color: blue;")}),t.subscribe(a.maxHeightCacheSize,function(){console.warn("react-virtuoso: maxHeightCacheSize is no longer necessary. Setting it has no effect - remove it from your code.")}),t.subscribe(a.HeaderContainer,function(){console.warn("react-virtuoso: HeaderContainer is deprecated. Use headerFooterTag if you want to change the wrapper of the header component and pass components.Header to change its contents.")}),t.subscribe(a.FooterContainer,function(){console.warn("react-virtuoso: FooterContainer is deprecated. Use headerFooterTag if you want to change the wrapper of the footer component and pass components.Footer to change its contents.")}),t.subscribe(a.scrollSeek,function(e){var a=e.placeholder,l=o(e,["placeholder"]);console.warn("react-virtuoso: scrollSeek property is deprecated. Pass scrollSeekConfiguration and specify the placeholder in components.ScrollSeekPlaceholder instead."),t.publish(i.components,r({},t.getValue(i.components),{ScrollSeekPlaceholder:a})),t.publish(n.scrollSeekConfiguration,l)}),l(a.footer,"Footer","footer"),l(a.header,"Header","header"),l(a.ItemContainer,"Item","ItemContainer"),l(a.ListContainer,"List","ListContainer"),l(a.ScrollContainer,"Scroller","ScrollContainer"),l(a.emptyComponent,"EmptyPlaceholder","emptyComponent"),l(a.GroupContainer,"Group","GroupContainer"),r({},n,i,a)},t.tup(We,Ge)),Ke=function(e){return n.createElement("div",{style:{height:e.height}})},Ye={position:Ne(),zIndex:1,overflowAnchor:"none"},qe=n.memo(function(e){var o=e.showTopList,i=void 0!==o&&o,a=ut("listState"),l=ut("deviation"),s=st("sizeRanges"),u=ut("useWindowScroll"),c=st("windowScrollContainerState"),m=st("scrollContainerState"),d=u?c:m,f=ut("itemContent"),p=ut("groupContent"),h=ut("trackItemSizes"),g=ut("itemSize"),v=ut("log"),S=Se(s,g,h,i?t.noop:d,v),I=ut("EmptyPlaceholder"),C=ut("ScrollSeekPlaceholder")||Ke,x=ut("ListComponent"),T=ut("ItemComponent"),w=ut("GroupComponent"),y=ut("computeItemKey"),b=ut("isSeeking"),E=ut("groupIndices").length>0,L=ut("paddingTopAddition"),H=ut("scrolledToInitialItem"),R=ut("firstItemIndex"),k=i?{}:{boxSizing:"border-box",paddingTop:a.offsetTop+L,paddingBottom:a.offsetBottom,marginTop:l};return!i&&0===a.items.length&&I&&H?n.createElement(I):n.createElement(x,{ref:S,style:k,"data-test-id":i?"virtuoso-top-item-list":"virtuoso-item-list"},(i?a.topItems:a.items).map(function(e){var t=e.originalIndex,o=y(t+R,e.data);return b?n.createElement(C,r({key:o,index:e.index,height:e.size,type:e.type||"item"},"group"===e.type?{}:{groupIndex:e.groupIndex})):"group"===e.type?n.createElement(w,{key:o,"data-index":t,"data-known-size":e.size,"data-item-index":e.index,style:Ye},p(e.index)):n.createElement(T,{key:o,"data-index":t,"data-known-size":e.size,"data-item-index":e.index,"data-item-group-index":e.groupIndex,style:{overflowAnchor:"none"}},E?f(e.index,e.groupIndex,e.data):f(e.index,e.data))}))}),Ze={height:"100%",outline:"none",overflowY:"auto",position:"relative",WebkitOverflowScrolling:"touch"},Je={width:"100%",height:"100%",position:"absolute",top:0},$e={width:"100%",position:Ne(),top:0},Qe=n.memo(function(){var e=ut("HeaderComponent"),t=st("headerHeight"),r=ut("headerFooterTag"),o=he(function(e){return t(A(e,"height"))});return e?n.createElement(r,{ref:o},n.createElement(e)):null}),Xe=n.memo(function(){var e=ut("FooterComponent"),t=st("footerHeight"),r=ut("headerFooterTag"),o=he(function(e){return t(A(e,"height"))});return e?n.createElement(r,{ref:o},n.createElement(e)):null});function et(e){var t=e.usePublisher,i=e.useEmitter,a=e.useEmitterValue;return n.memo(function(e){var l=e.style,s=e.children,u=o(e,["style","children"]),c=t("scrollContainerState"),m=a("ScrollerComponent"),d=Ie(c,t("smoothScrollTargetReached"),m,a("scrollerRef")),f=d.scrollerRef,p=d.scrollByCallback;return i("scrollTo",d.scrollToCallback),i("scrollBy",p),n.createElement(m,r({ref:f,style:r({},Ze,l),"data-test-id":"virtuoso-scroller","data-virtuoso-scroller":"true",tabIndex:0},u),s)})}function tt(e){var i=e.usePublisher,a=e.useEmitter,l=e.useEmitterValue;return n.memo(function(e){var s=e.style,u=e.children,c=o(e,["style","children"]),m=i("windowScrollContainerState"),d=l("ScrollerComponent"),f=i("smoothScrollTargetReached"),p=l("totalListHeight"),h=l("deviation"),g=Ie(m,f,d,t.noop),v=g.scrollerRef,S=g.scrollByCallback,I=g.scrollToCallback;return ve(function(){return v.current=window,function(){v.current=null}},[v]),a("windowScrollTo",I),a("scrollBy",S),n.createElement(d,r({style:r({position:"relative"},s,0!==p?{height:p+h}:{}),"data-virtuoso-scroller":"true"},c),u)})}var nt=function(e){var r=e.children,o=st("viewportHeight"),i=he(t.compose(o,function(e){return A(e,"height")}));return n.createElement("div",{style:Je,ref:i,"data-viewport-type":"element"},r)},rt=function(e){var t=e.children,r=ge(st("windowViewportRect"));return n.createElement("div",{ref:r,style:Je,"data-viewport-type":"window"},t)},ot=function(e){var t=e.children,o=ut("TopItemListComponent"),i=ut("headerHeight"),a=r({},$e,{marginTop:i+"px"});return n.createElement(o||"div",{style:a},t)},it=n.memo(function(e){var t=ut("useWindowScroll"),o=ut("topItemsIndexes").length>0,i=t?rt:nt;return n.createElement(t?dt:mt,r({},e),n.createElement(i,null,n.createElement(Qe,null),n.createElement(qe,null),n.createElement(Xe,null)),o&&n.createElement(ot,null,n.createElement(qe,{showTopList:!0})))}),at=e.systemToComponent(je,{required:{},optional:{followOutput:"followOutput",firstItemIndex:"firstItemIndex",itemContent:"itemContent",groupContent:"groupContent",overscan:"overscan",increaseViewportBy:"increaseViewportBy",totalCount:"totalCount",topItemCount:"topItemCount",initialTopMostItemIndex:"initialTopMostItemIndex",components:"components",groupCounts:"groupCounts",atBottomThreshold:"atBottomThreshold",computeItemKey:"computeItemKey",defaultItemHeight:"defaultItemHeight",fixedItemHeight:"fixedItemHeight",itemSize:"itemSize",scrollSeekConfiguration:"scrollSeekConfiguration",headerFooterTag:"headerFooterTag",data:"data",initialItemCount:"initialItemCount",initialScrollTop:"initialScrollTop",alignToBottom:"alignToBottom",useWindowScroll:"useWindowScroll",scrollerRef:"scrollerRef",logLevel:"logLevel",item:"item",group:"group",topItems:"topItems",itemHeight:"itemHeight",scrollingStateChange:"scrollingStateChange",maxHeightCacheSize:"maxHeightCacheSize",footer:"footer",header:"header",ItemContainer:"ItemContainer",ScrollContainer:"ScrollContainer",ListContainer:"ListContainer",GroupContainer:"GroupContainer",emptyComponent:"emptyComponent",HeaderContainer:"HeaderContainer",FooterContainer:"FooterContainer",scrollSeek:"scrollSeek"},methods:{scrollToIndex:"scrollToIndex",scrollIntoView:"scrollIntoView",scrollTo:"scrollTo",scrollBy:"scrollBy",adjustForPrependedItems:"adjustForPrependedItems"},events:{isScrolling:"isScrolling",endReached:"endReached",startReached:"startReached",rangeChanged:"rangeChanged",atBottomStateChange:"atBottomStateChange",atTopStateChange:"atTopStateChange",totalListHeightChanged:"totalListHeightChanged",itemsRendered:"itemsRendered",groupIndices:"groupIndices"}},it),lt=at.Component,st=at.usePublisher,ut=at.useEmitterValue,ct=at.useEmitter,mt=et({usePublisher:st,useEmitterValue:ut,useEmitter:ct}),dt=tt({usePublisher:st,useEmitterValue:ut,useEmitter:ct}),ft=t.system(function(){var e=t.statefulStream(function(e){return"Item "+e}),n=t.statefulStream({}),r=t.statefulStream("virtuoso-grid-item"),o=t.statefulStream("virtuoso-grid-list"),i=t.statefulStream(De),a=t.statefulStream(t.noop),l=function(e,r){return void 0===r&&(r=null),t.statefulStreamFromEmitter(t.pipe(n,t.map(function(t){return t[e]}),t.distinctUntilChanged()),r)};return{itemContent:e,components:n,computeItemKey:i,itemClassName:r,listClassName:o,scrollerRef:a,ListComponent:l("List","div"),ItemComponent:l("Item","div"),ScrollerComponent:l("Scroller","div"),ScrollSeekPlaceholder:l("ScrollSeekPlaceholder","div")}}),pt=t.system(function(e){var n=e[0],i=e[1],a={item:_e(i.itemContent,"Rename the %citem%c prop to %citemContent."),ItemContainer:t.stream(),ScrollContainer:t.stream(),ListContainer:t.stream(),emptyComponent:t.stream(),scrollSeek:t.stream()};function l(e,n,o){t.connect(t.pipe(e,t.withLatestFrom(i.components),t.map(function(e){var t,i=e[0],a=e[1];return console.warn("react-virtuoso: "+o+" property is deprecated. Pass components."+n+" instead."),r({},a,((t={})[n]=i,t))})),i.components)}return t.subscribe(a.scrollSeek,function(e){var a=e.placeholder,l=o(e,["placeholder"]);console.warn("react-virtuoso: scrollSeek property is deprecated. Pass scrollSeekConfiguration and specify the placeholder in components.ScrollSeekPlaceholder instead."),t.publish(i.components,r({},t.getValue(i.components),{ScrollSeekPlaceholder:a})),t.publish(n.scrollSeekConfiguration,l)}),l(a.ItemContainer,"Item","ItemContainer"),l(a.ListContainer,"List","ListContainer"),l(a.ScrollContainer,"Scroller","ScrollContainer"),r({},n,i,a)},t.tup(me,ft)),ht=n.memo(function(){var e=Tt("gridState"),t=Tt("listClassName"),r=Tt("itemClassName"),o=Tt("itemContent"),i=Tt("computeItemKey"),a=Tt("isSeeking"),l=xt("scrollHeight"),s=Tt("ItemComponent"),u=Tt("ListComponent"),c=Tt("ScrollSeekPlaceholder"),m=xt("itemDimensions"),d=he(function(e){l(e.parentElement.parentElement.scrollHeight);var t=e.firstChild;t&&m(t.getBoundingClientRect())});return n.createElement(u,{ref:d,className:t,style:{paddingTop:e.offsetTop,paddingBottom:e.offsetBottom}},e.items.map(function(t){var l=i(t.index);return a?n.createElement(c,{key:l,index:t.index,height:e.itemHeight,width:e.itemWidth}):n.createElement(s,{className:r,"data-index":t.index,key:l},o(t.index))}))}),gt=function(e){var t=e.children,r=xt("viewportDimensions"),o=he(function(e){r(e.getBoundingClientRect())});return n.createElement("div",{style:Je,ref:o},t)},vt=function(e){var t=e.children,r=ge(xt("windowViewportRect"));return n.createElement("div",{ref:r,style:Je},t)},St=n.memo(function(e){var t=r({},e),o=Tt("useWindowScroll"),i=o?vt:gt;return n.createElement(o?bt:yt,r({},t),n.createElement(i,null,n.createElement(ht,null)))}),It=e.systemToComponent(pt,{optional:{totalCount:"totalCount",overscan:"overscan",itemContent:"itemContent",components:"components",computeItemKey:"computeItemKey",initialItemCount:"initialItemCount",scrollSeekConfiguration:"scrollSeekConfiguration",listClassName:"listClassName",itemClassName:"itemClassName",useWindowScroll:"useWindowScroll",scrollerRef:"scrollerRef",item:"item",ItemContainer:"ItemContainer",ScrollContainer:"ScrollContainer",ListContainer:"ListContainer",scrollSeek:"scrollSeek"},methods:{scrollTo:"scrollTo",scrollBy:"scrollBy",scrollToIndex:"scrollToIndex"},events:{isScrolling:"isScrolling",endReached:"endReached",startReached:"startReached",rangeChanged:"rangeChanged",atBottomStateChange:"atBottomStateChange",atTopStateChange:"atTopStateChange"}},St),Ct=It.Component,xt=It.usePublisher,Tt=It.useEmitterValue,wt=It.useEmitter,yt=et({usePublisher:xt,useEmitterValue:Tt,useEmitter:wt}),bt=tt({usePublisher:xt,useEmitterValue:Tt,useEmitter:wt}),Et=t.system(function(){var e=t.statefulStream(function(e){return n.createElement("td",null,"Item $",e)}),r=t.statefulStream(null),o=t.statefulStream({}),i=t.statefulStream(De),a=t.statefulStream(t.noop),l=function(e,n){return void 0===n&&(n=null),t.statefulStreamFromEmitter(t.pipe(o,t.map(function(t){return t[e]}),t.distinctUntilChanged()),n)};return{itemContent:e,fixedHeaderContent:r,components:o,computeItemKey:i,scrollerRef:a,TableComponent:l("Table","table"),TableHeadComponent:l("TableHead","thead"),TableBodyComponent:l("TableBody","tbody"),TableRowComponent:l("TableRow","tr"),ScrollerComponent:l("Scroller","div"),EmptyPlaceholder:l("EmptyPlaceholder"),ScrollSeekPlaceholder:l("ScrollSeekPlaceholder")}}),Lt=t.system(function(e){return r({},e[0],e[1])},t.tup(We,Et)),Ht=function(e){return n.createElement("tr",null,n.createElement("td",{style:{height:e.height}}))},Rt=function(e){return n.createElement("tr",null,n.createElement("td",{style:{height:e.height,padding:0,border:0}}))},kt=n.memo(function(){var e=Vt("listState"),t=Vt("deviation"),r=Pt("sizeRanges"),o=Vt("useWindowScroll"),i=Pt("windowScrollContainerState"),a=Pt("scrollContainerState"),l=o?i:a,s=Vt("itemContent"),u=Vt("trackItemSizes"),c=Se(r,Vt("itemSize"),u,l,Vt("log")),m=Vt("EmptyPlaceholder"),d=Vt("ScrollSeekPlaceholder")||Ht,f=Vt("TableBodyComponent"),p=Vt("TableRowComponent"),h=Vt("computeItemKey"),g=Vt("isSeeking"),v=Vt("paddingTopAddition"),S=Vt("scrolledToInitialItem"),I=Vt("firstItemIndex");if(0===e.items.length&&m&&S)return n.createElement(m);var C=e.offsetTop+v+t,x=e.offsetBottom,T=C>0?n.createElement(Rt,{height:C,key:"padding-top"}):null,w=x>0?n.createElement(Rt,{height:x,key:"padding-bottom"}):null,y=e.items.map(function(e){var t=e.originalIndex,r=h(t+I,e.data);return g?n.createElement(d,{key:r,index:e.index,height:e.size,type:e.type||"item"}):n.createElement(p,{key:r,"data-index":t,"data-known-size":e.size,"data-item-index":e.index,style:{overflowAnchor:"none"}},s(e.index,e.data))});return n.createElement(f,{ref:c,"data-test-id":"virtuoso-item-list"},[T].concat(y,[w]))}),zt=function(e){var r=e.children,o=Pt("viewportHeight"),i=he(t.compose(o,function(e){return A(e,"height")}));return n.createElement("div",{style:Je,ref:i,"data-viewport-type":"element"},r)},Bt=function(e){var t=e.children,r=ge(Pt("windowViewportRect"));return n.createElement("div",{ref:r,style:Je,"data-viewport-type":"window"},t)},Ft=n.memo(function(e){var o=Vt("useWindowScroll"),i=Pt("fixedHeaderHeight"),a=Vt("fixedHeaderContent"),l=he(t.compose(i,function(e){return A(e,"height")})),s=o?Wt:At,u=o?Bt:zt,c=Vt("TableComponent"),m=Vt("TableHeadComponent"),d=a?n.createElement(m,{style:{zIndex:1,position:"sticky",top:0},ref:l},a()):null;return n.createElement(s,r({},e),n.createElement(u,null,n.createElement(c,{style:{borderSpacing:0}},[d,n.createElement(kt,null)])))}),Ot=e.systemToComponent(Lt,{required:{},optional:{followOutput:"followOutput",firstItemIndex:"firstItemIndex",itemContent:"itemContent",fixedHeaderContent:"fixedHeaderContent",overscan:"overscan",increaseViewportBy:"increaseViewportBy",totalCount:"totalCount",topItemCount:"topItemCount",initialTopMostItemIndex:"initialTopMostItemIndex",components:"components",groupCounts:"groupCounts",atBottomThreshold:"atBottomThreshold",computeItemKey:"computeItemKey",defaultItemHeight:"defaultItemHeight",fixedItemHeight:"fixedItemHeight",itemSize:"itemSize",scrollSeekConfiguration:"scrollSeekConfiguration",data:"data",initialItemCount:"initialItemCount",initialScrollTop:"initialScrollTop",alignToBottom:"alignToBottom",useWindowScroll:"useWindowScroll",scrollerRef:"scrollerRef",logLevel:"logLevel"},methods:{scrollToIndex:"scrollToIndex",scrollIntoView:"scrollIntoView",scrollTo:"scrollTo",scrollBy:"scrollBy"},events:{isScrolling:"isScrolling",endReached:"endReached",startReached:"startReached",rangeChanged:"rangeChanged",atBottomStateChange:"atBottomStateChange",atTopStateChange:"atTopStateChange",totalListHeightChanged:"totalListHeightChanged",itemsRendered:"itemsRendered",groupIndices:"groupIndices"}},Ft),Mt=Ot.Component,Pt=Ot.usePublisher,Vt=Ot.useEmitterValue,Ut=Ot.useEmitter,At=et({usePublisher:Pt,useEmitterValue:Vt,useEmitter:Ut}),Wt=tt({usePublisher:Pt,useEmitterValue:Vt,useEmitter:Ut}),Nt=lt,Dt=Mt,Gt=Ct;exports.GroupedVirtuoso=lt,exports.TableVirtuoso=Dt,exports.Virtuoso=Nt,exports.VirtuosoGrid=Gt;
//# sourceMappingURL=index.js.map

@@ -1,2 +0,2 @@

import{systemToComponent as e}from"@virtuoso.dev/react-urx";import{system as t,stream as n,statefulStream as o,connect as r,pipe as i,map as l,getValue as a,streamFromEmitter as u,filter as s,distinctUntilChanged as c,subscribe as d,tup as f,merge as m,duc as h,skip as p,mapTo as v,debounceTime as g,statefulStreamFromEmitter as I,combineLatest as C,scan as S,publish as x,throttleTime as T,withLatestFrom as w,handleNext as y,noop as H,prop as R,tap as b,compose as z}from"@virtuoso.dev/urx";import{useRef as k,useCallback as B,useEffect as E,useLayoutEffect as L,memo as O,createElement as M}from"react";function P(){return(P=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var o in n)Object.prototype.hasOwnProperty.call(n,o)&&(e[o]=n[o])}return e}).apply(this,arguments)}function A(e,t){if(null==e)return{};var n,o,r={},i=Object.keys(e);for(o=0;o<i.length;o++)t.indexOf(n=i[o])>=0||(r[n]=e[n]);return r}function D(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,o=new Array(t);n<t;n++)o[n]=e[n];return o}function F(e,t){var n;if("undefined"==typeof Symbol||null==e[Symbol.iterator]){if(Array.isArray(e)||(n=function(e,t){if(e){if("string"==typeof e)return D(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?D(e,t):void 0}}(e))||t&&e&&"number"==typeof e.length){n&&(e=n);var o=0;return function(){return o>=e.length?{done:!0}:{done:!1,value:e[o++]}}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}return(n=e[Symbol.iterator]()).next.bind(n)}function W(e,t){return!(!e||e[0]!==t[0]||e[1]!==t[1])}function G(e,t){return!(!e||e.startIndex!==t.startIndex||e.endIndex!==t.endIndex)}var V,N,U=t(function(){var e=n(),t=n(),a=o(0),u=n(),s=o(0),c=n(),d=n(),f=o(0),m=o(0),h=n(),p=n(),v=o(!1);return r(i(e,l(function(e){return e[0]})),t),r(i(e,l(function(e){return e[1]})),d),r(t,s),{scrollContainerState:e,scrollTop:t,viewportHeight:c,headerHeight:f,footerHeight:m,scrollHeight:d,smoothScrollTargetReached:u,scrollTo:h,scrollBy:p,statefulScrollTop:s,deviation:a,scrollingInProgress:v}},[],{singleton:!0});!function(e){e[e.DEBUG=0]="DEBUG",e[e.INFO=1]="INFO",e[e.WARN=2]="WARN",e[e.ERROR=3]="ERROR"}(N||(N={}));var _=((V={})[N.DEBUG]="debug",V[N.INFO]="log",V[N.WARN]="warn",V[N.ERROR]="error",V),j=t(function(){var e=o(N.ERROR);return{log:o(function(t,n,o){var r;void 0===o&&(o=N.INFO),o>=(null!=(r=("undefined"==typeof globalThis?window:globalThis).VIRTUOSO_LOG_LEVEL)?r:a(e))&&console[_[o]]("%creact-virtuoso: %c%s %o","color: #0253b3; font-weight: bold","color: initial",t,n)}),logLevel:e}},[],{singleton:!0}),K=t(function(e){var t=e[0].log,n=o(!1),r=u(i(n,s(function(e){return e}),c()));return d(n,function(e){e&&a(t)("props updated",{},N.DEBUG)}),{propsReady:n,didMount:r}},f(j),{singleton:!0}),Y="up",Z={atBottom:!1,notAtBottomBecause:"NOT_SHOWING_LAST_ITEM",state:{offsetBottom:0,scrollTop:0,viewportHeight:0,scrollHeight:0}},J=t(function(e){var t=e[0],f=t.scrollContainerState,y=t.scrollTop,H=t.viewportHeight,R=t.headerHeight,b=t.footerHeight,z=t.scrollBy,k=o(!1),B=o(!0),E=n(),L=n(),O=o(4),M=u(i(m(i(h(y),p(1),v(!0)),i(h(y),p(1),v(!1),g(100))),c())),P=I(i(m(i(z,v(!0)),i(z,v(!1),g(200))),c()),!1);r(i(h(y),l(function(e){return 0===e}),c()),B),r(B,L);var A=u(i(C(f,h(H),h(R),h(b),h(O)),S(function(e,t){var n,o,r=t[0],i=r[0],l=r[1],a=t[1],u={viewportHeight:a,scrollTop:i,scrollHeight:l};return i+a-l>-t[4]?(i>e.state.scrollTop?(n="SCROLLED_DOWN",o=e.state.scrollTop-i):(n="SIZE_DECREASED",o=e.state.scrollTop-i||e.scrollTopDelta),{atBottom:!0,state:u,atBottomBecause:n,scrollTopDelta:o}):{atBottom:!1,notAtBottomBecause:u.scrollHeight>e.state.scrollHeight?"SIZE_INCREASED":a<e.state.viewportHeight?"VIEWPORT_HEIGHT_DECREASING":i<e.state.scrollTop?"SCROLLING_UPWARDS":"NOT_FULLY_SCROLLED_TO_LAST_ITEM_BOTTOM",state:u}},Z),c(function(e,t){return e&&e.atBottom===t.atBottom}))),D=I(i(f,S(function(e,t){var n=t[0],o=t[1];return e.scrollHeight!==o?e.scrollTop!==n?{scrollHeight:o,scrollTop:n,jump:e.scrollTop-n,changed:!0}:{scrollHeight:o,scrollTop:n,jump:0,changed:!0}:{scrollTop:n,scrollHeight:o,jump:0,changed:!1}},{scrollHeight:0,jump:0,scrollTop:0,changed:!1}),s(function(e){return e.changed}),l(function(e){return e.jump})),0);r(i(A,l(function(e){return e.atBottom})),k),d(k,function(e){setTimeout(function(){return x(E,e)})});var F=o("down");d(k,function(e){setTimeout(function(){x(E,e)})}),r(i(f,l(function(e){return e[0]}),c(),S(function(e,t){return a(P)?{direction:e.direction,prevScrollTop:t}:{direction:t<e.prevScrollTop?Y:"down",prevScrollTop:t}},{direction:"down",prevScrollTop:0}),l(function(e){return e.direction})),F),r(i(f,T(50),v("none")),F),r(k,E);var W=o(0);return r(i(M,s(function(e){return!e}),v(0)),W),r(i(y,T(100),w(M),s(function(e){return!!e[1]}),S(function(e,t){return[e[1],t[0]]},[0,0]),l(function(e){return e[1]-e[0]})),W),{isScrolling:M,isAtTop:B,isAtBottom:k,atBottomState:A,atTopStateChange:L,atBottomStateChange:E,scrollDirection:F,atBottomThreshold:O,scrollVelocity:W,lastJumpDueToItemResize:D}},f(U)),q=t(function(e){var t=e[0].scrollVelocity,a=o(!1),u=n(),f=o(!1);return r(i(t,w(f,a,u),s(function(e){return!!e[1]}),l(function(e){var t=e[0],n=e[1],o=e[2],r=e[3],i=n.enter;if(o){if((0,n.exit)(t,r))return!1}else if(i(t,r))return!0;return o}),c()),a),d(i(C(a,t,u),w(f)),function(e){var t=e[0],n=e[1];return t[0]&&n&&n.change&&n.change(t[1],t[2])}),{isSeeking:a,scrollSeekConfiguration:f,scrollVelocity:t,scrollSeekRangeChanged:u}},f(J),{singleton:!0}),$={lvl:0};function Q(e,t,n,o,r){return void 0===o&&(o=$),void 0===r&&(r=$),{k:e,v:t,lvl:n,l:o,r:r}}function X(e){return e===$}function ee(){return $}function te(e,t){if(X(e))return $;var n=e.k,o=e.l,r=e.r;if(t===n){if(X(o))return r;if(X(r))return o;var i=le(o);return ce(ue(e,{k:i[0],v:i[1],l:ae(o)}))}return ce(ue(e,t<n?{l:te(o,t)}:{r:te(r,t)}))}function ne(e,t,n){if(void 0===n&&(n="k"),X(e))return[-Infinity,void 0];if(e[n]===t)return[e.k,e.v];if(e[n]<t){var o=ne(e.r,t,n);return-Infinity===o[0]?[e.k,e.v]:o}return ne(e.l,t,n)}function oe(e,t,n){return X(e)?Q(t,n,1):t===e.k?ue(e,{k:t,v:n}):function(e){return me(he(e))}(ue(e,t<e.k?{l:oe(e.l,t,n)}:{r:oe(e.r,t,n)}))}function re(e,t,n){if(X(e))return[];var o=e.k,r=e.v,i=e.r,l=[];return o>t&&(l=l.concat(re(e.l,t,n))),o>=t&&o<=n&&l.push({k:o,v:r}),o<=n&&(l=l.concat(re(i,t,n))),l}function ie(e){return X(e)?[]:[].concat(ie(e.l),[{k:e.k,v:e.v}],ie(e.r))}function le(e){return X(e.r)?[e.k,e.v]:le(e.r)}function ae(e){return X(e.r)?e.l:ce(ue(e,{r:ae(e.r)}))}function ue(e,t){return Q(void 0!==t.k?t.k:e.k,void 0!==t.v?t.v:e.v,void 0!==t.lvl?t.lvl:e.lvl,void 0!==t.l?t.l:e.l,void 0!==t.r?t.r:e.r)}function se(e){return X(e)||e.lvl>e.r.lvl}function ce(e){var t=e.l,n=e.r,o=e.lvl;if(n.lvl>=o-1&&t.lvl>=o-1)return e;if(o>n.lvl+1){if(se(t))return he(ue(e,{lvl:o-1}));if(X(t)||X(t.r))throw new Error("Unexpected empty nodes");return ue(t.r,{l:ue(t,{r:t.r.l}),r:ue(e,{l:t.r.r,lvl:o-1}),lvl:o})}if(se(e))return me(ue(e,{lvl:o-1}));if(X(n)||X(n.l))throw new Error("Unexpected empty nodes");var r=n.l,i=se(r)?n.lvl-1:n.lvl;return ue(r,{l:ue(e,{r:r.l,lvl:o-1}),r:me(ue(n,{l:r.r,lvl:i})),lvl:r.lvl+1})}function de(e,t,n){return X(e)?[]:fe(re(e,ne(e,t)[0],n),function(e){return{index:e.k,value:e.v}})}function fe(e,t){var n=e.length;if(0===n)return[];for(var o=t(e[0]),r=o.index,i=o.value,l=[],a=1;a<n;a++){var u=t(e[a]),s=u.index,c=u.value;l.push({start:r,end:s-1,value:i}),r=s,i=c}return l.push({start:r,end:Infinity,value:i}),l}function me(e){var t=e.r,n=e.lvl;return X(t)||X(t.r)||t.lvl!==n||t.r.lvl!==n?e:ue(t,{l:ue(e,{r:t.l}),lvl:n+1})}function he(e){var t=e.l;return X(t)||t.lvl!==e.lvl?e:ue(t,{r:ue(e,{l:t.r})})}function pe(e,t,n,o){void 0===o&&(o=0);for(var r=e.length-1;o<=r;){var i=Math.floor((o+r)/2),l=n(e[i],t);if(0===l)return i;if(-1===l){if(r-o<2)return i-1;r=i-1}else{if(r===o)return i;o=i+1}}throw new Error("Failed binary finding record in array - "+e.join(",")+", searched for "+t)}function ve(e,t,n){return e[pe(e,t,n)]}function ge(e,t){return Math.round(e.getBoundingClientRect()[t])}function Ie(e){var t=e.size,n=e.startIndex,o=e.endIndex;return function(e){return e.start===n&&(e.end===o||Infinity===e.end)&&e.value===t}}function Ce(e,t){var n=e.index;return t===n?0:t<n?-1:1}function Se(e,t){var n=e.offset;return t===n?0:t<n?-1:1}function xe(e){return{index:e.index,value:e}}function Te(e,t){var n=t[0],o=t[1];n.length>0&&(0,t[2])("received item sizes",n,N.DEBUG);var r=e.sizeTree,i=e.offsetTree,l=r,a=0;if(o.length>0&&X(r)&&2===n.length){var u=n[0].size,s=n[1].size;l=o.reduce(function(e,t){return oe(oe(e,t,u),t+1,s)},l)}else{var c=function(e,t){for(var n,o=X(e)?0:Infinity,r=F(t);!(n=r()).done;){var i=n.value,l=i.size,a=i.startIndex,u=i.endIndex;if(o=Math.min(o,a),X(e))e=oe(e,0,l);else{var s=de(e,a-1,u+1);if(!s.some(Ie(i))){for(var c,d=!1,f=!1,m=F(s);!(c=m()).done;){var h=c.value,p=h.start,v=h.end,g=h.value;d?(u>=p||l===g)&&(e=te(e,p)):(f=g!==l,d=!0),v>u&&u>=p&&g!==l&&(e=oe(e,u+1,g))}f&&(e=oe(e,a,l))}}}return[e,o]}(l,n);l=c[0],a=c[1]}if(l===r)return e;var d=0,f=0,m=0,h=0;if(0!==a){h=pe(i,a-1,Ce),m=i[h].offset;var p=ne(l,a-1);d=p[0],f=p[1],i.length&&i[h].size===ne(l,a)[1]&&(h-=1),i=i.slice(0,h+1)}else i=[];for(var v,g=F(de(l,a,Infinity));!(v=g()).done;){var I=v.value,C=I.start,S=I.value,x=(C-d)*f+m;i.push({offset:x,size:S,index:C}),d=C,m=x,f=S}return{sizeTree:l,offsetTree:i,groupOffsetTree:o.reduce(function(e,t){return oe(e,t,we(t,i))},ee()),lastIndex:d,lastOffset:m,lastSize:f,groupIndices:o}}function we(e,t){if(0===t.length)return 0;var n=ve(t,e,Ce);return n.size*(e-n.index)+n.offset}function ye(e,t){if(!He(t))return e;for(var n=0;t.groupIndices[n]<=e+n;)n++;return e+n}function He(e){return!X(e.groupOffsetTree)}var Re={offsetHeight:"height",offsetWidth:"width"},be=t(function(e){var t=e[0].log,f=n(),m=n(),h=n(),p=o(0),v=o([]),g=o(void 0),C=o(void 0),x=o(function(e,t){return ge(e,Re[t])}),T=o(void 0),y={offsetTree:[],sizeTree:ee(),groupOffsetTree:ee(),lastIndex:0,lastOffset:0,lastSize:0,groupIndices:[]},H=I(i(f,w(v,t),S(Te,y),c()),y);r(i(v,s(function(e){return e.length>0}),w(H),l(function(e){var t=e[0],n=e[1],o=t.reduce(function(e,t,o){return oe(e,t,we(t,n.offsetTree)||o)},ee());return P({},n,{groupIndices:t,groupOffsetTree:o})})),H),r(i(m,w(H),s(function(e){return e[0]<e[1].lastIndex}),l(function(e){var t=e[1];return[{startIndex:e[0],endIndex:t.lastIndex,size:t.lastSize}]})),f),r(g,C);var R=I(i(g,l(function(e){return void 0===e})),!0);r(i(C,s(function(e){return void 0!==e&&X(a(H).sizeTree)}),l(function(e){return[{startIndex:0,endIndex:0,size:e}]})),f);var b=u(i(f,w(H),S(function(e,t){var n=t[1];return{changed:n!==e.sizes,sizes:n}},{changed:!1,sizes:y}),l(function(e){return e.changed})));r(i(p,S(function(e,t){return{diff:e.prev-t,prev:t}},{diff:0,prev:0}),l(function(e){return e.diff}),s(function(e){return e>0})),h),d(i(p,w(t)),function(e){e[0]<0&&(0,e[1])("`firstItemIndex` prop should not be set to less than zero. If you don't know the total count, just use a very high value",{firstItemIndex:p},N.ERROR)});var z=u(h);return r(i(h,w(H),l(function(e){var t=e[0],n=e[1];if(n.groupIndices.length>0)throw new Error("Virtuoso: prepending items does not work with groups");return ie(n.sizeTree).reduce(function(e,n){var o=n.k,r=n.v;return{ranges:[].concat(e.ranges,[{startIndex:e.prevIndex,endIndex:o+t-1,size:e.prevSize}]),prevIndex:o+t,prevSize:r}},{ranges:[],prevIndex:0,prevSize:n.lastSize}).ranges})),f),{data:T,totalCount:m,sizeRanges:f,groupIndices:v,defaultItemSize:C,fixedItemSize:g,unshiftWith:h,beforeUnshiftWith:z,firstItemIndex:p,sizes:H,listRefresh:b,trackItemSizes:R,itemSize:x}},f(j),{singleton:!0}),ze="undefined"!=typeof document&&"scrollBehavior"in document.documentElement.style;function ke(e){var t="number"==typeof e?{index:e}:e;return t.align||(t.align="start"),t.behavior&&ze||(t.behavior="auto"),t.offset||(t.offset=0),t}var Be=t(function(e){var t=e[0],a=t.sizes,u=t.totalCount,s=t.listRefresh,c=e[1],f=c.scrollingInProgress,m=c.viewportHeight,h=c.scrollTo,p=c.smoothScrollTargetReached,v=c.headerHeight,g=c.footerHeight,I=e[2].log,C=n(),S=o(0),T=null,H=null,R=null;function b(){T&&(T(),T=null),R&&(R(),R=null),H&&(clearTimeout(H),H=null),x(f,!1)}return r(i(C,w(a,m,u,S,v,g,I),l(function(e){var t=e[0],n=e[1],o=e[2],r=e[3],l=e[4],a=e[5],u=e[6],c=e[7],m=ke(t),h=m.align,v=m.behavior,g=m.offset,I=r-1,S=m.index;"LAST"===S&&(S=I),S=ye(S,n);var w=we(S=Math.max(0,S,Math.min(I,S)),n.offsetTree)+a;"end"===h?(w=Math.round(w-o+ne(n.sizeTree,S)[1]),S===I&&(w+=u)):"center"===h?w=Math.round(w-o/2+ne(n.sizeTree,S)[1]/2):w-=l,g&&(w+=g);var z=function(e){b(),e?(c("retrying to scroll to",{location:t},N.DEBUG),x(C,t)):c("list did not change, scroll successful",{},N.DEBUG)};if(b(),"smooth"===v){var k=!1;R=d(s,function(e){k=k||e}),T=y(p,function(){z(k)})}else T=y(i(s,function(e){var t=setTimeout(function(){e(!1)},50);return function(n){n&&(e(!0),clearTimeout(t))}}),z);return H=setTimeout(function(){b()},1200),x(f,!0),c("scrolling from index to",{index:S,top:w,behavior:v},N.DEBUG),{top:w,behavior:v}})),h),{scrollToIndex:C,topListHeight:S}},f(be,U,j),{singleton:!0});function Ee(e,t,n){return"number"==typeof e?n===Y&&"top"===t||"down"===n&&"bottom"===t?e:0:n===Y?"top"===t?e.main:e.reverse:"bottom"===t?e.main:e.reverse}function Le(e,t){return"number"==typeof e?e:e[t]||0}var Oe=t(function(e){var t=e[0],r=t.scrollTop,a=t.viewportHeight,u=t.deviation,d=t.headerHeight,f=n(),m=o(0),p=o(0),v=o(0);return{listBoundary:f,overscan:v,topListHeight:m,increaseViewportBy:p,visibleRange:I(i(C(h(r),h(a),h(d),h(f,W),h(v),h(m),h(u),h(p)),l(function(e){var t=e[0],n=e[1],o=e[2],r=e[3],i=r[0],l=r[1],a=e[4],u=e[5],s=e[6],c=e[7],d=t-s,f=Math.max(o-d,0),m="none",h=Le(c,"top"),p=Le(c,"bottom");return i-=s,l+=o,(i+=o)>t+u-h&&(m=Y),(l-=s)<t-f+n+p&&(m="down"),"none"!==m?[Math.max(d-o-Ee(a,"top",m)-h,0),d-f+n+Ee(a,"bottom",m)+p]:null}),s(function(e){return null!=e}),c(W)),[0,0])}},f(U),{singleton:!0}),Me=t(function(e){var t=e[0],a=t.scrollTo,u=t.scrollContainerState,s=n(),c=n(),d=n(),f=o(!1);return r(i(C(s,c),l(function(e){var t=e[0],n=t[1];return[Math.max(0,t[0]-e[1].offsetTop),n]})),u),r(i(a,w(c),l(function(e){var t=e[0];return P({},t,{top:t.top+e[1].offsetTop})})),d),{useWindowScroll:f,windowScrollContainerState:s,windowViewportRect:c,windowScrollTo:d}},f(U)),Pe={items:[],offsetBottom:0,offsetTop:0,top:0,bottom:0,itemHeight:0,itemWidth:0},Ae={items:[{index:0}],offsetBottom:0,offsetTop:0,top:0,bottom:0,itemHeight:0,itemWidth:0},De=Math.ceil,Fe=Math.floor,We=Math.min,Ge=Math.max;function Ve(e){return De(e)-e<.03?De(e):Fe(e)}function Ne(e,t){return Array.from({length:t-e+1}).map(function(t,n){return{index:n+e}})}var Ue=t(function(e){var t=e[0],a=t.overscan,d=t.visibleRange,f=t.listBoundary,m=e[1],p=m.scrollTop,g=m.viewportHeight,S=m.scrollBy,x=m.scrollTo,T=m.smoothScrollTargetReached,y=m.scrollContainerState,H=e[2],R=e[3],b=e[4],z=b.propsReady,k=b.didMount,B=e[5],E=B.windowViewportRect,L=B.windowScrollTo,O=B.useWindowScroll,M=B.windowScrollContainerState,A=o(0),D=o(0),F=o(Pe),V=o({height:0,width:0}),N=o({height:0,width:0}),U=n(),_=n(),j=o(0);r(i(k,w(D),s(function(e){return 0!==e[1]}),l(function(e){return{items:Ne(0,e[1]-1),top:0,bottom:0,offsetBottom:0,offsetTop:0,itemHeight:0,itemWidth:0}})),F),r(i(C(h(A),d,h(N,function(e,t){return e&&e.width===t.width&&e.height===t.height})),w(V),l(function(e){var t=e[0],n=t[0],o=t[1],r=o[0],i=o[1],l=t[2],a=e[1],u=l.height,s=l.width,c=a.width;if(0===n||0===c)return Pe;if(0===s)return Ae;var d=Ve(c/s),f=d*Fe(r/u),m=d*De(i/u)-1;m=We(n-1,m);var h=Ne(f=We(m,Ge(0,f)),m),p=_e(a,l,h),v=p.top,g=p.bottom;return{items:h,offsetTop:v,offsetBottom:De(n/d)*u-g,top:v,bottom:g,itemHeight:u,itemWidth:s}})),F),r(i(V,l(function(e){return e.height})),g),r(i(C(V,N,F),l(function(e){var t=_e(e[0],e[1],e[2].items);return[t.top,t.bottom]}),c(W)),f);var K=u(i(h(F),s(function(e){return e.items.length>0}),w(A),s(function(e){var t=e[0].items;return t[t.length-1].index===e[1]-1}),l(function(e){return e[1]-1}),c())),Y=u(i(h(F),s(function(e){var t=e.items;return t.length>0&&0===t[0].index}),v(0),c())),Z=u(i(h(F),s(function(e){return e.items.length>0}),l(function(e){var t=e.items;return{startIndex:t[0].index,endIndex:t[t.length-1].index}}),c(G)));r(Z,R.scrollSeekRangeChanged),r(i(U,w(V,N,A),l(function(e){var t=e[1],n=e[2],o=e[3],r=ke(e[0]),i=r.align,l=r.behavior,a=r.offset,u=r.index;"LAST"===u&&(u=o-1);var s=je(t,n,u=Math.max(0,u,Math.min(o-1,u)));return"end"===i?s=Math.round(s-t.height+n.height):"center"===i&&(s=Math.round(s-t.height/2+n.height/2)),a&&(s+=a),{top:s,behavior:l}})),x);var J=I(i(F,l(function(e){return e.offsetBottom+e.bottom})),0);return r(i(E,l(function(e){return{width:e.visibleWidth,height:e.visibleHeight}})),V),P({totalCount:A,viewportDimensions:V,itemDimensions:N,scrollTop:p,scrollHeight:_,overscan:a,scrollBy:S,scrollTo:x,scrollToIndex:U,smoothScrollTargetReached:T,windowViewportRect:E,windowScrollTo:L,useWindowScroll:O,windowScrollContainerState:M,deviation:j,scrollContainerState:y,initialItemCount:D},R,{gridState:F,totalListHeight:J},H,{startReached:Y,endReached:K,rangeChanged:Z,propsReady:z})},f(Oe,U,J,q,K,Me));function _e(e,t,n){var o=t.height;return void 0===o||0===n.length?{top:0,bottom:0}:{top:je(e,t,n[0].index),bottom:je(e,t,n[n.length-1].index)+o}}function je(e,t,n){var o=Ve(e.width/t.width);return Fe(n/o)*t.height}function Ke(e,t){void 0===t&&(t=!0);var n=k(null),o=function(e){};if("undefined"!=typeof ResizeObserver){var r=new ResizeObserver(function(t){var n=t[0].target;null!==n.offsetParent&&e(n)});o=function(e){e&&t?(r.observe(e),n.current=e):(n.current&&r.unobserve(n.current),n.current=null)}}return{ref:n,callbackRef:o}}function Ye(e,t){return void 0===t&&(t=!0),Ke(e,t).callbackRef}function Ze(e){var t=k(null),n=B(function(n){if(null!==n){var o=n.getBoundingClientRect(),r=window.innerHeight-Math.max(0,o.top),i=o.top+window.pageYOffset;t.current={offsetTop:i,visibleHeight:r,visibleWidth:o.width},e(t.current)}},[e]),o=Ke(n),r=o.callbackRef,i=o.ref,l=B(function(){n(i.current)},[n,i]);return E(function(){return window.addEventListener("scroll",l),window.addEventListener("resize",l),function(){window.removeEventListener("scroll",l),window.removeEventListener("resize",l)}},[l]),r}var Je="undefined"!=typeof document?L:E;function qe(e,t,n,o){void 0===o&&(o=H);var r=k(null),i=k(null),l=k(null),a=B(function(n){var o=n.target,r=o===window||o===document?window.pageYOffset||document.documentElement.scrollTop:o.scrollTop,a=o===window?document.documentElement.scrollHeight:o.scrollHeight;e([Math.max(r,0),a]),null!==i.current&&(r===i.current||r<=0||r===o.scrollHeight-ge(o,"height"))&&(i.current=null,t(!0),l.current&&(clearTimeout(l.current),l.current=null))},[e,t]);return E(function(){var e=r.current;return o(r.current),a({target:e}),e.addEventListener("scroll",a,{passive:!0}),function(){o(null),e.removeEventListener("scroll",a)}},[r,a,n,o]),{scrollerRef:r,scrollByCallback:function(e){null===i.current&&r.current.scrollBy(e)},scrollToCallback:function(n){var o=r.current;if(o&&(!("offsetHeight"in o)||0!==o.offsetHeight)){var a,u,s,c="smooth"===n.behavior;if(o===window?(u=Math.max(ge(document.documentElement,"height"),document.documentElement.scrollHeight),a=window.innerHeight,s=document.documentElement.scrollTop):(u=o.scrollHeight,a=ge(o,"height"),s=o.scrollTop),n.top=Math.max(Math.min(u-a,n.top),0),Math.abs(a-u)<1.01||n.top===s)return e([s,u]),void(c&&t(!0));c?(i.current=n.top,l.current&&clearTimeout(l.current),l.current=setTimeout(function(){l.current=null,i.current=null,t(!0)},1e3)):i.current=null,o.scrollTo(n)}}}}var $e=t(function(e){var t=e[0],n=t.sizes,l=t.listRefresh,a=t.defaultItemSize,u=e[1].scrollTop,c=e[2].scrollToIndex,f=e[3].didMount,m=o(!0),h=o(0);return r(i(f,w(h),s(function(e){return 0!==e[1]}),v(!1)),m),d(i(C(l,f),w(m,n,a),s(function(e){var t=e[1],n=e[3];return e[0][1]&&(!X(e[2].sizeTree)||void 0!==n)&&!t}),w(h)),function(e){var t=e[1];setTimeout(function(){y(u,function(){x(m,!0)}),x(c,t)})}),{scrolledToInitialItem:m,initialTopMostItemIndex:h}},f(be,U,Be,K),{singleton:!0});function Qe(e){return!!e&&("smooth"===e?"smooth":"auto")}var Xe=t(function(e){var t=e[0],n=t.totalCount,r=t.listRefresh,u=e[1],c=u.isAtBottom,f=u.atBottomState,m=e[2].scrollToIndex,v=e[3].scrolledToInitialItem,g=e[4],I=g.propsReady,T=g.didMount,H=e[5].log,R=e[6].scrollingInProgress,b=o(!1),z=null;function k(e){x(m,{index:"LAST",align:"end",behavior:e})}return d(i(C(i(h(n),p(1)),T),w(h(b),c,v,R),l(function(e){var t=e[0],n=t[0],o=t[1]&&e[3],r="auto";return o&&(r=function(e,t){return"function"==typeof e?Qe(e(t)):t&&Qe(e)}(e[1],e[2]||e[4]),o=o&&!!r),{totalCount:n,shouldFollow:o,followOutputBehavior:r}}),s(function(e){return e.shouldFollow})),function(e){var t=e.totalCount,n=e.followOutputBehavior;z&&(z(),z=null),z=y(r,function(){a(H)("following output to ",{totalCount:t},N.DEBUG),k(n),z=null})}),d(i(C(h(b),n,I),s(function(e){return e[0]&&e[2]}),S(function(e,t){var n=t[1];return{refreshed:e.value===n,value:n}},{refreshed:!1,value:0}),s(function(e){return e.refreshed}),w(b,n)),function(e){var t=e[1],n=y(f,function(e){!t||e.atBottom||"SIZE_INCREASED"!==e.notAtBottomBecause||z||(a(H)("scrolling to bottom due to increased size",{},N.DEBUG),k("auto"))});setTimeout(n,100)}),d(C(h(b),f),function(e){var t=e[1];e[0]&&!t.atBottom&&"VIEWPORT_HEIGHT_DECREASING"===t.notAtBottomBecause&&k("auto")}),{followOutput:b}},f(be,J,Be,$e,K,j,U));function et(e){return e.reduce(function(e,t){return e.groupIndices.push(e.totalCount),e.totalCount+=t+1,e},{totalCount:0,groupIndices:[]})}var tt=t(function(e){var t=e[0],o=t.totalCount,a=t.groupIndices,d=t.sizes,f=e[1],m=f.scrollTop,h=f.headerHeight,p=n(),v=n(),g=u(i(p,l(et)));return r(i(g,l(R("totalCount"))),o),r(i(g,l(R("groupIndices"))),a),r(i(C(m,d,h),s(function(e){return He(e[1])}),l(function(e){return ne(e[1].groupOffsetTree,Math.max(e[0]-e[2],0),"v")[0]}),c(),l(function(e){return[e]})),v),{groupCounts:p,topItemsIndexes:v}},f(be,U)),nt={items:[],topItems:[],offsetTop:0,offsetBottom:0,top:0,bottom:0,topListHeight:0,totalCount:0};function ot(e,t,n){if(0===e.length)return[];if(!He(t))return e.map(function(e){return P({},e,{index:e.index+n,originalIndex:e.index})});for(var o,r=[],i=de(t.groupOffsetTree,e[0].index,e[e.length-1].index),l=void 0,a=0,u=F(e);!(o=u()).done;){var s=o.value;(!l||l.end<s.index)&&(l=i.shift(),a=t.groupIndices.indexOf(l.start)),r.push(P({},s.index===l.start?{type:"group",index:a}:{index:s.index-(a+1)+n,groupIndex:a},{size:s.size,offset:s.offset,originalIndex:s.index,data:s.data}))}return r}function rt(e,t,n,o,r){var i=0,l=0;if(e.length>0){i=e[0].offset;var a=e[e.length-1];l=a.offset+a.size}var u=i,s=o.lastOffset+(n-o.lastIndex)*o.lastSize-l;return{items:ot(e,o,r),topItems:ot(t,o,r),topListHeight:t.reduce(function(e,t){return t.size+e},0),offsetTop:i,offsetBottom:s,top:u,bottom:l,totalCount:n}}var it,lt,at,ut=t(function(e){var t=e[0],a=t.sizes,d=t.totalCount,f=t.data,m=t.firstItemIndex,p=e[1],v=e[2],g=v.visibleRange,S=v.listBoundary,x=v.topListHeight,y=e[3],H=y.scrolledToInitialItem,z=y.initialTopMostItemIndex,k=e[4].topListHeight,B=e[5],E=e[6].didMount,L=o([]),O=n();r(p.topItemsIndexes,L);var M=I(i(C(E,h(g),h(d),h(a),h(z),H,h(L),h(m),f),s(function(e){return e[0]}),l(function(e){var t=e[1],n=t[0],o=t[1],r=e[2],i=e[4],l=e[5],a=e[6],u=e[7],s=e[8],c=e[3],d=c.sizeTree,f=c.offsetTree;if(0===r||0===n&&0===o)return nt;if(X(d))return rt(function(e,t,n){if(He(t)){var o=ye(e,t);return[{index:ne(t.groupOffsetTree,o)[0],size:0,offset:0},{index:o,size:0,offset:0,data:n&&n[0]}]}return[{index:e,size:0,offset:0,data:n&&n[0]}]}(i,c,s),[],r,c,u);var m=[];if(a.length>0)for(var h,p=a[0],v=a[a.length-1],g=0,I=F(de(d,p,v));!(h=I()).done;)for(var C=h.value,S=C.value,x=Math.max(C.start,p),T=Math.min(C.end,v),w=x;w<=T;w++)m.push({index:w,size:S,offset:g,data:s&&s[w]}),g+=S;if(!l)return rt([],m,r,c,u);var y=a.length>0?a[a.length-1]+1:0,H=function(e,t,n,o){return void 0===o&&(o=0),o>0&&(t=Math.max(t,ve(e,o,Ce).offset)),fe((i=n,a=pe(r=e,t,l=Se),u=pe(r,i,l,a),r.slice(a,u+1)),xe);var r,i,l,a,u}(f,n,o,y);if(0===H.length)return null;var R=r-1;return rt(b([],function(e){for(var t,r=F(H);!(t=r()).done;){var i=t.value,l=i.value,a=l.offset,u=i.start,c=l.size;l.offset<n&&(a+=((u+=Math.floor((n-l.offset)/c))-i.start)*c),u<y&&(a+=(y-u)*c,u=y);for(var d=Math.min(i.end,R),f=u;f<=d&&!(a>=o);f++)e.push({index:f,size:c,offset:a,data:s&&s[f]}),a+=c}}),m,r,c,u)}),s(function(e){return null!==e}),c()),nt);return r(i(f,s(function(e){return void 0!==e}),l(function(e){return e.length})),d),r(i(M,l(R("topListHeight"))),k),r(k,x),r(i(M,l(function(e){return[e.top,e.bottom]})),S),r(i(M,l(function(e){return e.items})),O),P({listState:M,topItemsIndexes:L,endReached:u(i(M,s(function(e){return e.items.length>0}),w(d,f),s(function(e){var t=e[0].items;return t[t.length-1].originalIndex===e[1]-1}),l(function(e){return[e[1]-1,e[2]]}),c(W),l(function(e){return e[0]}))),startReached:u(i(M,T(200),s(function(e){var t=e.items;return t.length>0&&t[0].originalIndex===e.topItems.length}),l(function(e){return e.items[0].index}),c())),rangeChanged:u(i(M,s(function(e){return e.items.length>0}),l(function(e){var t=e.items;return{startIndex:t[0].index,endIndex:t[t.length-1].index}}),c(G))),itemsRendered:O},B)},f(be,tt,Oe,$e,Be,J,K),{singleton:!0}),st=t(function(e){var t=e[0],n=t.sizes,a=t.firstItemIndex,u=t.data,c=e[1].listState,d=e[2].didMount,f=o(0);return r(i(d,w(f),s(function(e){return 0!==e[1]}),w(n,a,u),l(function(e){var t=e[0][1],n=e[1],o=e[2],r=e[3],i=void 0===r?[]:r,l=0;if(n.groupIndices.length>0)for(var a,u=F(n.groupIndices);!((a=u()).done||a.value-l>=t);)l++;var s=t+l;return rt(Array.from({length:s}).map(function(e,t){return{index:t,size:0,offset:0,data:i[t]}}),[],s,n,o)})),c),{initialItemCount:f}},f(be,ut,K),{singleton:!0}),ct=t(function(e){var t=e[0].topItemsIndexes,n=o(0);return r(i(n,s(function(e){return e>0}),l(function(e){return Array.from({length:e}).map(function(e,t){return t})})),t),{topItemCount:n}},f(ut)),dt=t(function(e){var t=e[0],o=t.footerHeight,a=t.headerHeight,u=e[1].listState,s=n(),c=I(i(C(o,a,u),l(function(e){var t=e[2];return e[0]+e[1]+t.offsetBottom+t.bottom})),0);return r(h(c),s),{totalListHeight:c,totalListHeightChanged:s}},f(U,ut),{singleton:!0}),ft=t(function(e){var t=e[0],n=t.scrollBy,o=t.scrollTop,a=t.deviation,c=t.scrollingInProgress,f=e[1],m=f.isScrolling,h=f.isAtBottom,p=f.atBottomState,v=f.scrollDirection,g=e[3],y=g.beforeUnshiftWith,H=g.sizes,R=e[4].log,b=u(i(e[2].listState,w(f.lastJumpDueToItemResize),S(function(e,t){var n=e[1],o=t[0],r=o.items,i=o.totalCount,l=t[1],a=0;if(e[2]===i){if(n.length>0&&r.length>0){var u=1===r.length;if(0!==r[0].originalIndex||0!==n[0].originalIndex)for(var s=function(e){var t=r[e],o=n.find(function(e){return e.originalIndex===t.originalIndex});return o?t.offset!==o.offset||u?(a=t.offset-o.offset+t.size-o.size,"break"):void 0:"continue"},c=r.length-1;c>=0;c--){var d=s(c);if("continue"!==d&&"break"===d)break}}0!==a&&(a+=l)}return[a,r,i]},[0,[],0]),s(function(e){return 0!==e[0]}),w(o,v,c,R,h,p),s(function(e){return!e[3]&&0!==e[1]&&e[2]===Y}),l(function(e){var t=e[0][0];return(0,e[4])("Upward scrolling compensation",{amount:t},N.DEBUG),t})));return r(i(b,w(a),l(function(e){return e[1]-e[0]})),a),d(i(C(I(m,!1),a),s(function(e){return!e[0]&&0!==e[1]}),l(function(e){return e[1]}),T(1)),function(e){e>0?(x(n,{top:-e,behavior:"auto"}),x(a,0)):(x(a,0),x(n,{top:-e,behavior:"auto"}))}),r(i(y,w(H),l(function(e){return e[0]*e[1].lastSize})),b),{deviation:a}},f(U,J,ut,be,j)),mt=t(function(e){var t=e[0].totalListHeight,n=e[1].didMount,r=e[2].scrollTo,a=o(0);return d(i(n,w(a),s(function(e){return 0!==e[1]}),l(function(e){return{top:e[1]}})),function(e){y(i(t,s(function(e){return 0!==e})),function(){setTimeout(function(){x(r,e)})})}),{initialScrollTop:a}},f(dt,K,U),{singleton:!0}),ht=t(function(e){var t=e[0].viewportHeight,n=e[1].totalListHeight,r=o(!1);return{alignToBottom:r,paddingTopAddition:I(i(C(r,t,n),s(function(e){return e[0]}),l(function(e){return Math.max(0,e[1]-e[2])}),c()),0)}},f(U,dt),{singleton:!0}),pt=t(function(e){var t=e[0],o=t.sizes,a=t.totalCount,u=e[1],c=u.scrollTop,d=u.viewportHeight,f=u.headerHeight,m=u.scrollingInProgress,h=e[2].scrollToIndex,v=n();return r(i(v,w(o,d,a,f,c),l(function(e){var t=e[0],n=t.index,o=t.behavior,r=void 0===o?"auto":o,l=t.done,a=e[1],u=e[2],c=e[4],d=e[5],f=e[3]-1,h=null;n=ye(n,a);var v=we(n=Math.max(0,n,Math.min(f,n)),a.offsetTree)+c;return v<d?h={index:n,behavior:r,align:"start"}:v+ne(a.sizeTree,n)[1]>d+u&&(h={index:n,behavior:r,align:"end"}),h?l&&y(i(m,p(1),s(function(e){return!1===e})),l):l&&l(),h}),s(function(e){return null!==e})),h),{scrollIntoView:v}},f(be,U,Be,ut,j),{singleton:!0}),vt=t(function(e){return P({},e[0],e[1],e[2],e[3],e[4],e[5],e[6],e[7],e[8])},f(Oe,st,K,q,dt,mt,ht,Me,pt)),gt=t(function(e){var t=e[0],n=t.totalCount,o=t.sizeRanges,a=t.fixedItemSize,u=t.defaultItemSize,s=t.trackItemSizes,c=t.itemSize,d=t.data,f=t.firstItemIndex,m=t.groupIndices,h=e[1],p=h.initialTopMostItemIndex,v=h.scrolledToInitialItem,g=e[2],I=e[3],C=e[4],S=C.listState,x=C.topItemsIndexes,T=A(C,["listState","topItemsIndexes"]),w=e[5].scrollToIndex,y=e[7].topItemCount,H=e[8].groupCounts,b=e[9],z=e[10];return r(T.rangeChanged,b.scrollSeekRangeChanged),r(i(b.windowViewportRect,l(R("visibleHeight"))),g.viewportHeight),P({totalCount:n,data:d,firstItemIndex:f,sizeRanges:o,initialTopMostItemIndex:p,scrolledToInitialItem:v,topItemsIndexes:x,topItemCount:y,groupCounts:H,fixedItemHeight:a,defaultItemHeight:u},I,{listState:S,scrollToIndex:w,trackItemSizes:s,itemSize:c,groupIndices:m},T,b,g,z)},f(be,$e,U,Xe,ut,Be,ft,ct,tt,vt,j)),It=(it=function(){if("undefined"==typeof document)return"sticky";var e=document.createElement("div");return e.style.position="-webkit-sticky","-webkit-sticky"===e.style.position?"-webkit-sticky":"sticky"},at=!1,function(){return at||(at=!0,lt=it()),lt});function Ct(e){return e}var St=t(function(){var e=o(function(e){return"Item "+e}),t=o(function(e){return"Group "+e}),n=o({}),r=o(Ct),a=o("div"),u=o(H),s=function(e,t){return void 0===t&&(t=null),I(i(n,l(function(t){return t[e]}),c()),t)};return{itemContent:e,groupContent:t,components:n,computeItemKey:r,headerFooterTag:a,scrollerRef:u,FooterComponent:s("Footer"),HeaderComponent:s("Header"),TopItemListComponent:s("TopItemList"),ListComponent:s("List","div"),ItemComponent:s("Item","div"),GroupComponent:s("Group","div"),ScrollerComponent:s("Scroller","div"),EmptyPlaceholder:s("EmptyPlaceholder"),ScrollSeekPlaceholder:s("ScrollSeekPlaceholder")}});function xt(e,t){var o=n();return d(o,function(){return console.warn("react-virtuoso: You are using a deprecated property. "+t,"color: red;","color: inherit;","color: blue;")}),r(o,e),o}var Tt=t(function(e){var t=e[0],o=e[1],u={item:xt(o.itemContent,"Rename the %citem%c prop to %citemContent."),group:xt(o.groupContent,"Rename the %cgroup%c prop to %cgroupContent."),topItems:xt(t.topItemCount,"Rename the %ctopItems%c prop to %ctopItemCount."),itemHeight:xt(t.fixedItemHeight,"Rename the %citemHeight%c prop to %cfixedItemHeight."),scrollingStateChange:xt(t.isScrolling,"Rename the %cscrollingStateChange%c prop to %cisScrolling."),adjustForPrependedItems:n(),maxHeightCacheSize:n(),footer:n(),header:n(),HeaderContainer:n(),FooterContainer:n(),ItemContainer:n(),ScrollContainer:n(),GroupContainer:n(),ListContainer:n(),emptyComponent:n(),scrollSeek:n()};function s(e,t,n){r(i(e,w(o.components),l(function(e){var o,r=e[0],i=e[1];return console.warn("react-virtuoso: "+n+" property is deprecated. Pass components."+t+" instead."),P({},i,((o={})[t]=r,o))})),o.components)}return d(u.adjustForPrependedItems,function(){console.warn("react-virtuoso: adjustForPrependedItems is no longer supported. Use the firstItemIndex property instead - https://virtuoso.dev/prepend-items.","color: red;","color: inherit;","color: blue;")}),d(u.maxHeightCacheSize,function(){console.warn("react-virtuoso: maxHeightCacheSize is no longer necessary. Setting it has no effect - remove it from your code.")}),d(u.HeaderContainer,function(){console.warn("react-virtuoso: HeaderContainer is deprecated. Use headerFooterTag if you want to change the wrapper of the header component and pass components.Header to change its contents.")}),d(u.FooterContainer,function(){console.warn("react-virtuoso: FooterContainer is deprecated. Use headerFooterTag if you want to change the wrapper of the footer component and pass components.Footer to change its contents.")}),d(u.scrollSeek,function(e){var n=e.placeholder,r=A(e,["placeholder"]);console.warn("react-virtuoso: scrollSeek property is deprecated. Pass scrollSeekConfiguration and specify the placeholder in components.ScrollSeekPlaceholder instead."),x(o.components,P({},a(o.components),{ScrollSeekPlaceholder:n})),x(t.scrollSeekConfiguration,r)}),s(u.footer,"Footer","footer"),s(u.header,"Header","header"),s(u.ItemContainer,"Item","ItemContainer"),s(u.ListContainer,"List","ListContainer"),s(u.ScrollContainer,"Scroller","ScrollContainer"),s(u.emptyComponent,"EmptyPlaceholder","emptyComponent"),s(u.GroupContainer,"Group","GroupContainer"),P({},t,o,u)},f(gt,St)),wt=function(e){return M("div",{style:{height:e.height}})},yt={position:It(),zIndex:1,overflowAnchor:"none"},Ht=O(function(e){var t=e.showTopList,n=void 0!==t&&t,o=Wt("listState"),r=Wt("deviation"),i=Ft("sizeRanges"),l=Wt("useWindowScroll"),a=Ft("windowScrollContainerState"),u=Ft("scrollContainerState"),s=l?a:u,c=Wt("itemContent"),d=Wt("groupContent"),f=Wt("trackItemSizes"),m=Wt("itemSize"),h=Wt("log"),p=function(e,t,n,o,r){return Ye(function(n){var i=function(e,t,n,o){var r=e.length;if(0===r)return null;for(var i=[],l=0;l<r;l++){var a=e.item(l);if(a&&void 0!==a.dataset.index){var u=parseInt(a.dataset.index),s=parseFloat(a.dataset.knownSize),c=t(a,"offsetHeight");if(0===c&&o("Zero-sized element, this should not happen",{child:a},N.ERROR),c!==s){var d=i[i.length-1];0===i.length||d.size!==c||d.endIndex!==u-1?i.push({startIndex:u,endIndex:u,size:c}):i[i.length-1].endIndex++}}}return i}(n.children,t,0,r),l=n.parentElement.parentElement,a="window"===n.parentElement.dataset.viewportType?window.pageYOffset||document.documentElement.scrollTop:l.scrollTop;o([Math.max(a,0),l.scrollHeight]),null!==i&&e(i)},n)}(i,m,f,n?H:s,h),v=Wt("EmptyPlaceholder"),g=Wt("ScrollSeekPlaceholder")||wt,I=Wt("ListComponent"),C=Wt("ItemComponent"),S=Wt("GroupComponent"),x=Wt("computeItemKey"),T=Wt("isSeeking"),w=Wt("groupIndices").length>0,y=Wt("paddingTopAddition"),R=Wt("scrolledToInitialItem"),b=Wt("firstItemIndex"),z=n?{}:{boxSizing:"border-box",paddingTop:o.offsetTop+y,paddingBottom:o.offsetBottom,marginTop:r};return!n&&0===o.items.length&&v&&R?M(v):M(I,{ref:p,style:z,"data-test-id":n?"virtuoso-top-item-list":"virtuoso-item-list"},(n?o.topItems:o.items).map(function(e){var t=e.originalIndex,n=x(t+b,e.data);return T?M(g,P({key:n,index:e.index,height:e.size,type:e.type||"item"},"group"===e.type?{}:{groupIndex:e.groupIndex})):"group"===e.type?M(S,{key:n,"data-index":t,"data-known-size":e.size,"data-item-index":e.index,style:yt},d(e.index)):M(C,{key:n,"data-index":t,"data-known-size":e.size,"data-item-index":e.index,"data-item-group-index":e.groupIndex,style:{overflowAnchor:"none"}},w?c(e.index,e.groupIndex,e.data):c(e.index,e.data))}))}),Rt={height:"100%",outline:"none",overflowY:"auto",position:"relative",WebkitOverflowScrolling:"touch"},bt={width:"100%",height:"100%",position:"absolute",top:0},zt={width:"100%",position:It(),top:0},kt=O(function(){var e=Wt("HeaderComponent"),t=Ft("headerHeight"),n=Wt("headerFooterTag"),o=Ye(function(e){return t(ge(e,"height"))});return e?M(n,{ref:o},M(e)):null}),Bt=O(function(){var e=Wt("FooterComponent"),t=Ft("footerHeight"),n=Wt("headerFooterTag"),o=Ye(function(e){return t(ge(e,"height"))});return e?M(n,{ref:o},M(e)):null});function Et(e){var t=e.usePublisher,n=e.useEmitter,o=e.useEmitterValue;return O(function(e){var r=e.style,i=e.children,l=A(e,["style","children"]),a=t("scrollContainerState"),u=o("ScrollerComponent"),s=qe(a,t("smoothScrollTargetReached"),u,o("scrollerRef")),c=s.scrollerRef,d=s.scrollByCallback;return n("scrollTo",s.scrollToCallback),n("scrollBy",d),M(u,P({ref:c,style:P({},Rt,r),"data-test-id":"virtuoso-scroller",tabIndex:0},l),i)})}function Lt(e){var t=e.usePublisher,n=e.useEmitter,o=e.useEmitterValue;return O(function(e){var r=e.style,i=e.children,l=A(e,["style","children"]),a=t("windowScrollContainerState"),u=o("ScrollerComponent"),s=t("smoothScrollTargetReached"),c=o("totalListHeight"),d=o("deviation"),f=qe(a,s,u,H),m=f.scrollerRef,h=f.scrollByCallback,p=f.scrollToCallback;return Je(function(){return m.current=window,function(){m.current=null}},[m]),n("windowScrollTo",p),n("scrollBy",h),M(u,P({style:P({position:"relative"},r,0!==c?{height:c+d}:{})},l),i)})}var Ot=function(e){var t=e.children,n=Ft("viewportHeight"),o=Ye(z(n,function(e){return ge(e,"height")}));return M("div",{style:bt,ref:o,"data-viewport-type":"element"},t)},Mt=function(e){var t=e.children,n=Ze(Ft("windowViewportRect"));return M("div",{ref:n,style:bt,"data-viewport-type":"window"},t)},Pt=function(e){var t=e.children,n=Wt("TopItemListComponent"),o=Wt("headerHeight"),r=P({},zt,{marginTop:o+"px"});return M(n||"div",{style:r},t)},At=e(Tt,{required:{},optional:{followOutput:"followOutput",firstItemIndex:"firstItemIndex",itemContent:"itemContent",groupContent:"groupContent",overscan:"overscan",increaseViewportBy:"increaseViewportBy",totalCount:"totalCount",topItemCount:"topItemCount",initialTopMostItemIndex:"initialTopMostItemIndex",components:"components",groupCounts:"groupCounts",atBottomThreshold:"atBottomThreshold",computeItemKey:"computeItemKey",defaultItemHeight:"defaultItemHeight",fixedItemHeight:"fixedItemHeight",itemSize:"itemSize",scrollSeekConfiguration:"scrollSeekConfiguration",headerFooterTag:"headerFooterTag",data:"data",initialItemCount:"initialItemCount",initialScrollTop:"initialScrollTop",alignToBottom:"alignToBottom",useWindowScroll:"useWindowScroll",scrollerRef:"scrollerRef",logLevel:"logLevel",item:"item",group:"group",topItems:"topItems",itemHeight:"itemHeight",scrollingStateChange:"scrollingStateChange",maxHeightCacheSize:"maxHeightCacheSize",footer:"footer",header:"header",ItemContainer:"ItemContainer",ScrollContainer:"ScrollContainer",ListContainer:"ListContainer",GroupContainer:"GroupContainer",emptyComponent:"emptyComponent",HeaderContainer:"HeaderContainer",FooterContainer:"FooterContainer",scrollSeek:"scrollSeek"},methods:{scrollToIndex:"scrollToIndex",scrollIntoView:"scrollIntoView",scrollTo:"scrollTo",scrollBy:"scrollBy",adjustForPrependedItems:"adjustForPrependedItems"},events:{isScrolling:"isScrolling",endReached:"endReached",startReached:"startReached",rangeChanged:"rangeChanged",atBottomStateChange:"atBottomStateChange",atTopStateChange:"atTopStateChange",totalListHeightChanged:"totalListHeightChanged",itemsRendered:"itemsRendered",groupIndices:"groupIndices"}},O(function(e){var t=Wt("useWindowScroll"),n=Wt("topItemsIndexes").length>0,o=t?Mt:Ot;return M(t?Nt:Vt,P({},e),M(o,null,M(kt,null),M(Ht,null),M(Bt,null)),n&&M(Pt,null,M(Ht,{showTopList:!0})))})),Dt=At.Component,Ft=At.usePublisher,Wt=At.useEmitterValue,Gt=At.useEmitter,Vt=Et({usePublisher:Ft,useEmitterValue:Wt,useEmitter:Gt}),Nt=Lt({usePublisher:Ft,useEmitterValue:Wt,useEmitter:Gt}),Ut=t(function(){var e=o(function(e){return"Item "+e}),t=o({}),n=o("virtuoso-grid-item"),r=o("virtuoso-grid-list"),a=o(Ct),u=o(H),s=function(e,n){return void 0===n&&(n=null),I(i(t,l(function(t){return t[e]}),c()),n)};return{itemContent:e,components:t,computeItemKey:a,itemClassName:n,listClassName:r,scrollerRef:u,ListComponent:s("List","div"),ItemComponent:s("Item","div"),ScrollerComponent:s("Scroller","div"),ScrollSeekPlaceholder:s("ScrollSeekPlaceholder","div")}}),_t=t(function(e){var t=e[0],o=e[1],u={item:xt(o.itemContent,"Rename the %citem%c prop to %citemContent."),ItemContainer:n(),ScrollContainer:n(),ListContainer:n(),emptyComponent:n(),scrollSeek:n()};function s(e,t,n){r(i(e,w(o.components),l(function(e){var o,r=e[0],i=e[1];return console.warn("react-virtuoso: "+n+" property is deprecated. Pass components."+t+" instead."),P({},i,((o={})[t]=r,o))})),o.components)}return d(u.scrollSeek,function(e){var n=e.placeholder,r=A(e,["placeholder"]);console.warn("react-virtuoso: scrollSeek property is deprecated. Pass scrollSeekConfiguration and specify the placeholder in components.ScrollSeekPlaceholder instead."),x(o.components,P({},a(o.components),{ScrollSeekPlaceholder:n})),x(t.scrollSeekConfiguration,r)}),s(u.ItemContainer,"Item","ItemContainer"),s(u.ListContainer,"List","ListContainer"),s(u.ScrollContainer,"Scroller","ScrollContainer"),P({},t,o,u)},f(Ue,Ut)),jt=O(function(){var e=$t("gridState"),t=$t("listClassName"),n=$t("itemClassName"),o=$t("itemContent"),r=$t("computeItemKey"),i=$t("isSeeking"),l=qt("scrollHeight"),a=$t("ItemComponent"),u=$t("ListComponent"),s=$t("ScrollSeekPlaceholder"),c=qt("itemDimensions"),d=Ye(function(e){l(e.parentElement.parentElement.scrollHeight);var t=e.firstChild;t&&c(t.getBoundingClientRect())});return M(u,{ref:d,className:t,style:{paddingTop:e.offsetTop,paddingBottom:e.offsetBottom}},e.items.map(function(t){var l=r(t.index);return i?M(s,{key:l,index:t.index,height:e.itemHeight,width:e.itemWidth}):M(a,{className:n,"data-index":t.index,key:l},o(t.index))}))}),Kt=function(e){var t=e.children,n=qt("viewportDimensions"),o=Ye(function(e){n(e.getBoundingClientRect())});return M("div",{style:bt,ref:o},t)},Yt=function(e){var t=e.children,n=Ze(qt("windowViewportRect"));return M("div",{ref:n,style:bt},t)},Zt=e(_t,{optional:{totalCount:"totalCount",overscan:"overscan",itemContent:"itemContent",components:"components",computeItemKey:"computeItemKey",initialItemCount:"initialItemCount",scrollSeekConfiguration:"scrollSeekConfiguration",listClassName:"listClassName",itemClassName:"itemClassName",useWindowScroll:"useWindowScroll",scrollerRef:"scrollerRef",item:"item",ItemContainer:"ItemContainer",ScrollContainer:"ScrollContainer",ListContainer:"ListContainer",scrollSeek:"scrollSeek"},methods:{scrollTo:"scrollTo",scrollBy:"scrollBy",scrollToIndex:"scrollToIndex"},events:{isScrolling:"isScrolling",endReached:"endReached",startReached:"startReached",rangeChanged:"rangeChanged",atBottomStateChange:"atBottomStateChange",atTopStateChange:"atTopStateChange"}},O(function(e){var t=P({},e),n=$t("useWindowScroll"),o=n?Yt:Kt;return M(n?en:Xt,P({},t),M(o,null,M(jt,null)))})),Jt=Zt.Component,qt=Zt.usePublisher,$t=Zt.useEmitterValue,Qt=Zt.useEmitter,Xt=Et({usePublisher:qt,useEmitterValue:$t,useEmitter:Qt}),en=Lt({usePublisher:qt,useEmitterValue:$t,useEmitter:Qt}),tn=Dt,nn=Dt,on=Jt;export{nn as GroupedVirtuoso,N as LogLevel,tn as Virtuoso,on as VirtuosoGrid};
import{systemToComponent as e}from"@virtuoso.dev/react-urx";import{system as t,stream as n,statefulStream as o,connect as r,pipe as i,map as l,getValue as a,streamFromEmitter as u,filter as s,distinctUntilChanged as c,subscribe as d,tup as f,merge as m,duc as h,skip as p,mapTo as g,debounceTime as v,statefulStreamFromEmitter as I,combineLatest as C,scan as S,publish as T,throttleTime as x,withLatestFrom as w,handleNext as y,noop as H,prop as b,tap as R,compose as z}from"@virtuoso.dev/urx";import{useRef as k,useCallback as B,useEffect as E,useLayoutEffect as L,memo as O,createElement as M}from"react";function P(){return(P=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var o in n)Object.prototype.hasOwnProperty.call(n,o)&&(e[o]=n[o])}return e}).apply(this,arguments)}function A(e,t){if(null==e)return{};var n,o,r={},i=Object.keys(e);for(o=0;o<i.length;o++)t.indexOf(n=i[o])>=0||(r[n]=e[n]);return r}function V(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,o=new Array(t);n<t;n++)o[n]=e[n];return o}function W(e,t){var n;if("undefined"==typeof Symbol||null==e[Symbol.iterator]){if(Array.isArray(e)||(n=function(e,t){if(e){if("string"==typeof e)return V(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?V(e,t):void 0}}(e))||t&&e&&"number"==typeof e.length){n&&(e=n);var o=0;return function(){return o>=e.length?{done:!0}:{done:!1,value:e[o++]}}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}return(n=e[Symbol.iterator]()).next.bind(n)}function D(e,t){return!(!e||e[0]!==t[0]||e[1]!==t[1])}function F(e,t){return!(!e||e.startIndex!==t.startIndex||e.endIndex!==t.endIndex)}var G,N,U=t(function(){var e=n(),t=n(),a=o(0),u=n(),s=o(0),c=n(),d=n(),f=o(0),m=o(0),h=n(),p=n(),g=o(!1);return r(i(e,l(function(e){return e[0]})),t),r(i(e,l(function(e){return e[1]})),d),r(t,s),{scrollContainerState:e,scrollTop:t,viewportHeight:c,headerHeight:f,footerHeight:m,scrollHeight:d,smoothScrollTargetReached:u,scrollTo:h,scrollBy:p,statefulScrollTop:s,deviation:a,scrollingInProgress:g}},[],{singleton:!0});!function(e){e[e.DEBUG=0]="DEBUG",e[e.INFO=1]="INFO",e[e.WARN=2]="WARN",e[e.ERROR=3]="ERROR"}(N||(N={}));var _=((G={})[N.DEBUG]="debug",G[N.INFO]="log",G[N.WARN]="warn",G[N.ERROR]="error",G),j=t(function(){var e=o(N.ERROR);return{log:o(function(t,n,o){var r;void 0===o&&(o=N.INFO),o>=(null!=(r=("undefined"==typeof globalThis?window:globalThis).VIRTUOSO_LOG_LEVEL)?r:a(e))&&console[_[o]]("%creact-virtuoso: %c%s %o","color: #0253b3; font-weight: bold","color: initial",t,n)}),logLevel:e}},[],{singleton:!0}),K=t(function(e){var t=e[0].log,n=o(!1),r=u(i(n,s(function(e){return e}),c()));return d(n,function(e){e&&a(t)("props updated",{},N.DEBUG)}),{propsReady:n,didMount:r}},f(j),{singleton:!0}),Y="up",Z={atBottom:!1,notAtBottomBecause:"NOT_SHOWING_LAST_ITEM",state:{offsetBottom:0,scrollTop:0,viewportHeight:0,scrollHeight:0}},q=t(function(e){var t=e[0],f=t.scrollContainerState,y=t.scrollTop,H=t.viewportHeight,b=t.headerHeight,R=t.footerHeight,z=t.scrollBy,k=o(!1),B=o(!0),E=n(),L=n(),O=o(4),M=u(i(m(i(h(y),p(1),g(!0)),i(h(y),p(1),g(!1),v(100))),c())),P=I(i(m(i(z,g(!0)),i(z,g(!1),v(200))),c()),!1);r(i(h(y),l(function(e){return 0===e}),c()),B),r(B,L);var A=u(i(C(f,h(H),h(b),h(R),h(O)),S(function(e,t){var n,o,r=t[0],i=r[0],l=r[1],a=t[1],u={viewportHeight:a,scrollTop:i,scrollHeight:l};return i+a-l>-t[4]?(i>e.state.scrollTop?(n="SCROLLED_DOWN",o=e.state.scrollTop-i):(n="SIZE_DECREASED",o=e.state.scrollTop-i||e.scrollTopDelta),{atBottom:!0,state:u,atBottomBecause:n,scrollTopDelta:o}):{atBottom:!1,notAtBottomBecause:u.scrollHeight>e.state.scrollHeight?"SIZE_INCREASED":a<e.state.viewportHeight?"VIEWPORT_HEIGHT_DECREASING":i<e.state.scrollTop?"SCROLLING_UPWARDS":"NOT_FULLY_SCROLLED_TO_LAST_ITEM_BOTTOM",state:u}},Z),c(function(e,t){return e&&e.atBottom===t.atBottom}))),V=I(i(f,S(function(e,t){var n=t[0],o=t[1];return e.scrollHeight!==o?e.scrollTop!==n?{scrollHeight:o,scrollTop:n,jump:e.scrollTop-n,changed:!0}:{scrollHeight:o,scrollTop:n,jump:0,changed:!0}:{scrollTop:n,scrollHeight:o,jump:0,changed:!1}},{scrollHeight:0,jump:0,scrollTop:0,changed:!1}),s(function(e){return e.changed}),l(function(e){return e.jump})),0);r(i(A,l(function(e){return e.atBottom})),k),d(k,function(e){setTimeout(function(){return T(E,e)})});var W=o("down");d(k,function(e){setTimeout(function(){T(E,e)})}),r(i(f,l(function(e){return e[0]}),c(),S(function(e,t){return a(P)?{direction:e.direction,prevScrollTop:t}:{direction:t<e.prevScrollTop?Y:"down",prevScrollTop:t}},{direction:"down",prevScrollTop:0}),l(function(e){return e.direction})),W),r(i(f,x(50),g("none")),W),r(k,E);var D=o(0);return r(i(M,s(function(e){return!e}),g(0)),D),r(i(y,x(100),w(M),s(function(e){return!!e[1]}),S(function(e,t){return[e[1],t[0]]},[0,0]),l(function(e){return e[1]-e[0]})),D),{isScrolling:M,isAtTop:B,isAtBottom:k,atBottomState:A,atTopStateChange:L,atBottomStateChange:E,scrollDirection:W,atBottomThreshold:O,scrollVelocity:D,lastJumpDueToItemResize:V}},f(U)),J=t(function(e){var t=e[0].scrollVelocity,a=o(!1),u=n(),f=o(!1);return r(i(t,w(f,a,u),s(function(e){return!!e[1]}),l(function(e){var t=e[0],n=e[1],o=e[2],r=e[3],i=n.enter;if(o){if((0,n.exit)(t,r))return!1}else if(i(t,r))return!0;return o}),c()),a),d(i(C(a,t,u),w(f)),function(e){var t=e[0],n=e[1];return t[0]&&n&&n.change&&n.change(t[1],t[2])}),{isSeeking:a,scrollSeekConfiguration:f,scrollVelocity:t,scrollSeekRangeChanged:u}},f(q),{singleton:!0}),$={lvl:0};function Q(e,t,n,o,r){return void 0===o&&(o=$),void 0===r&&(r=$),{k:e,v:t,lvl:n,l:o,r:r}}function X(e){return e===$}function ee(){return $}function te(e,t){if(X(e))return $;var n=e.k,o=e.l,r=e.r;if(t===n){if(X(o))return r;if(X(r))return o;var i=le(o);return ce(ue(e,{k:i[0],v:i[1],l:ae(o)}))}return ce(ue(e,t<n?{l:te(o,t)}:{r:te(r,t)}))}function ne(e,t,n){if(void 0===n&&(n="k"),X(e))return[-Infinity,void 0];if(e[n]===t)return[e.k,e.v];if(e[n]<t){var o=ne(e.r,t,n);return-Infinity===o[0]?[e.k,e.v]:o}return ne(e.l,t,n)}function oe(e,t,n){return X(e)?Q(t,n,1):t===e.k?ue(e,{k:t,v:n}):function(e){return me(he(e))}(ue(e,t<e.k?{l:oe(e.l,t,n)}:{r:oe(e.r,t,n)}))}function re(e,t,n){if(X(e))return[];var o=e.k,r=e.v,i=e.r,l=[];return o>t&&(l=l.concat(re(e.l,t,n))),o>=t&&o<=n&&l.push({k:o,v:r}),o<=n&&(l=l.concat(re(i,t,n))),l}function ie(e){return X(e)?[]:[].concat(ie(e.l),[{k:e.k,v:e.v}],ie(e.r))}function le(e){return X(e.r)?[e.k,e.v]:le(e.r)}function ae(e){return X(e.r)?e.l:ce(ue(e,{r:ae(e.r)}))}function ue(e,t){return Q(void 0!==t.k?t.k:e.k,void 0!==t.v?t.v:e.v,void 0!==t.lvl?t.lvl:e.lvl,void 0!==t.l?t.l:e.l,void 0!==t.r?t.r:e.r)}function se(e){return X(e)||e.lvl>e.r.lvl}function ce(e){var t=e.l,n=e.r,o=e.lvl;if(n.lvl>=o-1&&t.lvl>=o-1)return e;if(o>n.lvl+1){if(se(t))return he(ue(e,{lvl:o-1}));if(X(t)||X(t.r))throw new Error("Unexpected empty nodes");return ue(t.r,{l:ue(t,{r:t.r.l}),r:ue(e,{l:t.r.r,lvl:o-1}),lvl:o})}if(se(e))return me(ue(e,{lvl:o-1}));if(X(n)||X(n.l))throw new Error("Unexpected empty nodes");var r=n.l,i=se(r)?n.lvl-1:n.lvl;return ue(r,{l:ue(e,{r:r.l,lvl:o-1}),r:me(ue(n,{l:r.r,lvl:i})),lvl:r.lvl+1})}function de(e,t,n){return X(e)?[]:fe(re(e,ne(e,t)[0],n),function(e){return{index:e.k,value:e.v}})}function fe(e,t){var n=e.length;if(0===n)return[];for(var o=t(e[0]),r=o.index,i=o.value,l=[],a=1;a<n;a++){var u=t(e[a]),s=u.index,c=u.value;l.push({start:r,end:s-1,value:i}),r=s,i=c}return l.push({start:r,end:Infinity,value:i}),l}function me(e){var t=e.r,n=e.lvl;return X(t)||X(t.r)||t.lvl!==n||t.r.lvl!==n?e:ue(t,{l:ue(e,{r:t.l}),lvl:n+1})}function he(e){var t=e.l;return X(t)||t.lvl!==e.lvl?e:ue(t,{r:ue(e,{l:t.r})})}function pe(e,t,n,o){void 0===o&&(o=0);for(var r=e.length-1;o<=r;){var i=Math.floor((o+r)/2),l=n(e[i],t);if(0===l)return i;if(-1===l){if(r-o<2)return i-1;r=i-1}else{if(r===o)return i;o=i+1}}throw new Error("Failed binary finding record in array - "+e.join(",")+", searched for "+t)}function ge(e,t,n){return e[pe(e,t,n)]}function ve(e,t){return Math.round(e.getBoundingClientRect()[t])}function Ie(e){var t=e.size,n=e.startIndex,o=e.endIndex;return function(e){return e.start===n&&(e.end===o||Infinity===e.end)&&e.value===t}}function Ce(e,t){var n=e.index;return t===n?0:t<n?-1:1}function Se(e,t){var n=e.offset;return t===n?0:t<n?-1:1}function Te(e){return{index:e.index,value:e}}function xe(e,t){var n=t[0],o=t[1];n.length>0&&(0,t[2])("received item sizes",n,N.DEBUG);var r=e.sizeTree,i=e.offsetTree,l=r,a=0;if(o.length>0&&X(r)&&2===n.length){var u=n[0].size,s=n[1].size;l=o.reduce(function(e,t){return oe(oe(e,t,u),t+1,s)},l)}else{var c=function(e,t){for(var n,o=X(e)?0:Infinity,r=W(t);!(n=r()).done;){var i=n.value,l=i.size,a=i.startIndex,u=i.endIndex;if(o=Math.min(o,a),X(e))e=oe(e,0,l);else{var s=de(e,a-1,u+1);if(!s.some(Ie(i))){for(var c,d=!1,f=!1,m=W(s);!(c=m()).done;){var h=c.value,p=h.start,g=h.end,v=h.value;d?(u>=p||l===v)&&(e=te(e,p)):(f=v!==l,d=!0),g>u&&u>=p&&v!==l&&(e=oe(e,u+1,v))}f&&(e=oe(e,a,l))}}}return[e,o]}(l,n);l=c[0],a=c[1]}if(l===r)return e;var d=0,f=0,m=0,h=0;if(0!==a){h=pe(i,a-1,Ce),m=i[h].offset;var p=ne(l,a-1);d=p[0],f=p[1],i.length&&i[h].size===ne(l,a)[1]&&(h-=1),i=i.slice(0,h+1)}else i=[];for(var g,v=W(de(l,a,Infinity));!(g=v()).done;){var I=g.value,C=I.start,S=I.value,T=(C-d)*f+m;i.push({offset:T,size:S,index:C}),d=C,m=T,f=S}return{sizeTree:l,offsetTree:i,groupOffsetTree:o.reduce(function(e,t){return oe(e,t,we(t,i))},ee()),lastIndex:d,lastOffset:m,lastSize:f,groupIndices:o}}function we(e,t){if(0===t.length)return 0;var n=ge(t,e,Ce);return n.size*(e-n.index)+n.offset}function ye(e,t){if(!He(t))return e;for(var n=0;t.groupIndices[n]<=e+n;)n++;return e+n}function He(e){return!X(e.groupOffsetTree)}var be={offsetHeight:"height",offsetWidth:"width"},Re=t(function(e){var t=e[0].log,f=n(),m=n(),h=n(),p=o(0),g=o([]),v=o(void 0),C=o(void 0),T=o(function(e,t){return ve(e,be[t])}),x=o(void 0),y={offsetTree:[],sizeTree:ee(),groupOffsetTree:ee(),lastIndex:0,lastOffset:0,lastSize:0,groupIndices:[]},H=I(i(f,w(g,t),S(xe,y),c()),y);r(i(g,s(function(e){return e.length>0}),w(H),l(function(e){var t=e[0],n=e[1],o=t.reduce(function(e,t,o){return oe(e,t,we(t,n.offsetTree)||o)},ee());return P({},n,{groupIndices:t,groupOffsetTree:o})})),H),r(i(m,w(H),s(function(e){return e[0]<e[1].lastIndex}),l(function(e){var t=e[1];return[{startIndex:e[0],endIndex:t.lastIndex,size:t.lastSize}]})),f),r(v,C);var b=I(i(v,l(function(e){return void 0===e})),!0);r(i(C,s(function(e){return void 0!==e&&X(a(H).sizeTree)}),l(function(e){return[{startIndex:0,endIndex:0,size:e}]})),f);var R=u(i(f,w(H),S(function(e,t){var n=t[1];return{changed:n!==e.sizes,sizes:n}},{changed:!1,sizes:y}),l(function(e){return e.changed})));r(i(p,S(function(e,t){return{diff:e.prev-t,prev:t}},{diff:0,prev:0}),l(function(e){return e.diff}),s(function(e){return e>0})),h),d(i(p,w(t)),function(e){e[0]<0&&(0,e[1])("`firstItemIndex` prop should not be set to less than zero. If you don't know the total count, just use a very high value",{firstItemIndex:p},N.ERROR)});var z=u(h);return r(i(h,w(H),l(function(e){var t=e[0],n=e[1];if(n.groupIndices.length>0)throw new Error("Virtuoso: prepending items does not work with groups");return ie(n.sizeTree).reduce(function(e,n){var o=n.k,r=n.v;return{ranges:[].concat(e.ranges,[{startIndex:e.prevIndex,endIndex:o+t-1,size:e.prevSize}]),prevIndex:o+t,prevSize:r}},{ranges:[],prevIndex:0,prevSize:n.lastSize}).ranges})),f),{data:x,totalCount:m,sizeRanges:f,groupIndices:g,defaultItemSize:C,fixedItemSize:v,unshiftWith:h,beforeUnshiftWith:z,firstItemIndex:p,sizes:H,listRefresh:R,trackItemSizes:b,itemSize:T}},f(j),{singleton:!0}),ze="undefined"!=typeof document&&"scrollBehavior"in document.documentElement.style;function ke(e){var t="number"==typeof e?{index:e}:e;return t.align||(t.align="start"),t.behavior&&ze||(t.behavior="auto"),t.offset||(t.offset=0),t}var Be=t(function(e){var t=e[0],a=t.sizes,u=t.totalCount,s=t.listRefresh,c=e[1],f=c.scrollingInProgress,m=c.viewportHeight,h=c.scrollTo,p=c.smoothScrollTargetReached,g=c.headerHeight,v=c.footerHeight,I=e[2].log,C=n(),S=o(0),x=null,H=null,b=null;function R(){x&&(x(),x=null),b&&(b(),b=null),H&&(clearTimeout(H),H=null),T(f,!1)}return r(i(C,w(a,m,u,S,g,v,I),l(function(e){var t=e[0],n=e[1],o=e[2],r=e[3],l=e[4],a=e[5],u=e[6],c=e[7],m=ke(t),h=m.align,g=m.behavior,v=m.offset,I=r-1,S=m.index;"LAST"===S&&(S=I),S=ye(S,n);var w=we(S=Math.max(0,S,Math.min(I,S)),n.offsetTree)+a;"end"===h?(w=Math.round(w-o+ne(n.sizeTree,S)[1]),S===I&&(w+=u)):"center"===h?w=Math.round(w-o/2+ne(n.sizeTree,S)[1]/2):w-=l,v&&(w+=v);var z=function(e){R(),e?(c("retrying to scroll to",{location:t},N.DEBUG),T(C,t)):c("list did not change, scroll successful",{},N.DEBUG)};if(R(),"smooth"===g){var k=!1;b=d(s,function(e){k=k||e}),x=y(p,function(){z(k)})}else x=y(i(s,function(e){var t=setTimeout(function(){e(!1)},50);return function(n){n&&(e(!0),clearTimeout(t))}}),z);return H=setTimeout(function(){R()},1200),T(f,!0),c("scrolling from index to",{index:S,top:w,behavior:g},N.DEBUG),{top:w,behavior:g}})),h),{scrollToIndex:C,topListHeight:S}},f(Re,U,j),{singleton:!0});function Ee(e,t,n){return"number"==typeof e?n===Y&&"top"===t||"down"===n&&"bottom"===t?e:0:n===Y?"top"===t?e.main:e.reverse:"bottom"===t?e.main:e.reverse}function Le(e,t){return"number"==typeof e?e:e[t]||0}var Oe=t(function(e){var t=e[0],r=t.scrollTop,a=t.viewportHeight,u=t.deviation,d=t.headerHeight,f=n(),m=o(0),p=o(0),g=o(0),v=o(0);return{listBoundary:f,overscan:v,topListHeight:m,fixedHeaderHeight:p,increaseViewportBy:g,visibleRange:I(i(C(h(r),h(a),h(d),h(f,D),h(v),h(m),h(p),h(u),h(g)),l(function(e){var t=e[0],n=e[1],o=e[2],r=e[3],i=r[0],l=r[1],a=e[4],u=e[6],s=e[7],c=e[8],d=t-s,f=e[5]+u,m=Math.max(o-d,0),h="none",p=Le(c,"top"),g=Le(c,"bottom");return i-=s,l+=o,(i+=o)>t+f-p&&(h=Y),(l-=s)<t-m+n+g&&(h="down"),"none"!==h?[Math.max(d-o-Ee(a,"top",h)-p,0),d-m-u+n+Ee(a,"bottom",h)+g]:null}),s(function(e){return null!=e}),c(D)),[0,0])}},f(U),{singleton:!0}),Me=t(function(e){var t=e[0],a=t.scrollTo,u=t.scrollContainerState,s=n(),c=n(),d=n(),f=o(!1);return r(i(C(s,c),l(function(e){var t=e[0],n=t[1];return[Math.max(0,t[0]-e[1].offsetTop),n]})),u),r(i(a,w(c),l(function(e){var t=e[0];return P({},t,{top:t.top+e[1].offsetTop})})),d),{useWindowScroll:f,windowScrollContainerState:s,windowViewportRect:c,windowScrollTo:d}},f(U)),Pe={items:[],offsetBottom:0,offsetTop:0,top:0,bottom:0,itemHeight:0,itemWidth:0},Ae={items:[{index:0}],offsetBottom:0,offsetTop:0,top:0,bottom:0,itemHeight:0,itemWidth:0},Ve=Math.ceil,We=Math.floor,De=Math.min,Fe=Math.max;function Ge(e){return Ve(e)-e<.03?Ve(e):We(e)}function Ne(e,t){return Array.from({length:t-e+1}).map(function(t,n){return{index:n+e}})}var Ue=t(function(e){var t=e[0],a=t.overscan,d=t.visibleRange,f=t.listBoundary,m=e[1],p=m.scrollTop,v=m.viewportHeight,S=m.scrollBy,T=m.scrollTo,x=m.smoothScrollTargetReached,y=m.scrollContainerState,H=e[2],b=e[3],R=e[4],z=R.propsReady,k=R.didMount,B=e[5],E=B.windowViewportRect,L=B.windowScrollTo,O=B.useWindowScroll,M=B.windowScrollContainerState,A=o(0),V=o(0),W=o(Pe),G=o({height:0,width:0}),N=o({height:0,width:0}),U=n(),_=n(),j=o(0);r(i(k,w(V),s(function(e){return 0!==e[1]}),l(function(e){return{items:Ne(0,e[1]-1),top:0,bottom:0,offsetBottom:0,offsetTop:0,itemHeight:0,itemWidth:0}})),W),r(i(C(h(A),d,h(N,function(e,t){return e&&e.width===t.width&&e.height===t.height})),w(G),l(function(e){var t=e[0],n=t[0],o=t[1],r=o[0],i=o[1],l=t[2],a=e[1],u=l.height,s=l.width,c=a.width;if(0===n||0===c)return Pe;if(0===s)return Ae;var d=Ge(c/s),f=d*We(r/u),m=d*Ve(i/u)-1;m=De(n-1,m);var h=Ne(f=De(m,Fe(0,f)),m),p=_e(a,l,h),g=p.top,v=p.bottom;return{items:h,offsetTop:g,offsetBottom:Ve(n/d)*u-v,top:g,bottom:v,itemHeight:u,itemWidth:s}})),W),r(i(G,l(function(e){return e.height})),v),r(i(C(G,N,W),l(function(e){var t=_e(e[0],e[1],e[2].items);return[t.top,t.bottom]}),c(D)),f);var K=u(i(h(W),s(function(e){return e.items.length>0}),w(A),s(function(e){var t=e[0].items;return t[t.length-1].index===e[1]-1}),l(function(e){return e[1]-1}),c())),Y=u(i(h(W),s(function(e){var t=e.items;return t.length>0&&0===t[0].index}),g(0),c())),Z=u(i(h(W),s(function(e){return e.items.length>0}),l(function(e){var t=e.items;return{startIndex:t[0].index,endIndex:t[t.length-1].index}}),c(F)));r(Z,b.scrollSeekRangeChanged),r(i(U,w(G,N,A),l(function(e){var t=e[1],n=e[2],o=e[3],r=ke(e[0]),i=r.align,l=r.behavior,a=r.offset,u=r.index;"LAST"===u&&(u=o-1);var s=je(t,n,u=Math.max(0,u,Math.min(o-1,u)));return"end"===i?s=Math.round(s-t.height+n.height):"center"===i&&(s=Math.round(s-t.height/2+n.height/2)),a&&(s+=a),{top:s,behavior:l}})),T);var q=I(i(W,l(function(e){return e.offsetBottom+e.bottom})),0);return r(i(E,l(function(e){return{width:e.visibleWidth,height:e.visibleHeight}})),G),P({totalCount:A,viewportDimensions:G,itemDimensions:N,scrollTop:p,scrollHeight:_,overscan:a,scrollBy:S,scrollTo:T,scrollToIndex:U,smoothScrollTargetReached:x,windowViewportRect:E,windowScrollTo:L,useWindowScroll:O,windowScrollContainerState:M,deviation:j,scrollContainerState:y,initialItemCount:V},b,{gridState:W,totalListHeight:q},H,{startReached:Y,endReached:K,rangeChanged:Z,propsReady:z})},f(Oe,U,q,J,K,Me));function _e(e,t,n){var o=t.height;return void 0===o||0===n.length?{top:0,bottom:0}:{top:je(e,t,n[0].index),bottom:je(e,t,n[n.length-1].index)+o}}function je(e,t,n){var o=Ge(e.width/t.width);return We(n/o)*t.height}function Ke(e,t){void 0===t&&(t=!0);var n=k(null),o=function(e){};if("undefined"!=typeof ResizeObserver){var r=new ResizeObserver(function(t){var n=t[0].target;null!==n.offsetParent&&e(n)});o=function(e){e&&t?(r.observe(e),n.current=e):(n.current&&r.unobserve(n.current),n.current=null)}}return{ref:n,callbackRef:o}}function Ye(e,t){return void 0===t&&(t=!0),Ke(e,t).callbackRef}function Ze(e){var t=k(null),n=B(function(n){if(null!==n){var o=n.getBoundingClientRect(),r=window.innerHeight-Math.max(0,o.top),i=o.top+window.pageYOffset;t.current={offsetTop:i,visibleHeight:r,visibleWidth:o.width},e(t.current)}},[e]),o=Ke(n),r=o.callbackRef,i=o.ref,l=B(function(){n(i.current)},[n,i]);return E(function(){return window.addEventListener("scroll",l),window.addEventListener("resize",l),function(){window.removeEventListener("scroll",l),window.removeEventListener("resize",l)}},[l]),r}var qe="undefined"!=typeof document?L:E;function Je(e,t,n,o,r){return Ye(function(n){for(var i=function(e,t,n,o){var r=e.length;if(0===r)return null;for(var i=[],l=0;l<r;l++){var a=e.item(l);if(a&&void 0!==a.dataset.index){var u=parseInt(a.dataset.index),s=parseFloat(a.dataset.knownSize),c=t(a,"offsetHeight");if(0===c&&o("Zero-sized element, this should not happen",{child:a},N.ERROR),c!==s){var d=i[i.length-1];0===i.length||d.size!==c||d.endIndex!==u-1?i.push({startIndex:u,endIndex:u,size:c}):i[i.length-1].endIndex++}}}return i}(n.children,t,0,r),l=n.parentElement;!l.dataset.virtuosoScroller;)l=l.parentElement;var a="window"===l.firstElementChild.dataset.viewportType?window.pageYOffset||document.documentElement.scrollTop:l.scrollTop;o([Math.max(a,0),l.scrollHeight]),null!==i&&e(i)},n)}function $e(e,t,n,o){void 0===o&&(o=H);var r=k(null),i=k(null),l=k(null),a=B(function(n){var o=n.target,r=o===window||o===document?window.pageYOffset||document.documentElement.scrollTop:o.scrollTop,a=o===window?document.documentElement.scrollHeight:o.scrollHeight;e([Math.max(r,0),a]),null!==i.current&&(r===i.current||r<=0||r===o.scrollHeight-ve(o,"height"))&&(i.current=null,t(!0),l.current&&(clearTimeout(l.current),l.current=null))},[e,t]);return E(function(){var e=r.current;return o(r.current),a({target:e}),e.addEventListener("scroll",a,{passive:!0}),function(){o(null),e.removeEventListener("scroll",a)}},[r,a,n,o]),{scrollerRef:r,scrollByCallback:function(e){null===i.current&&r.current.scrollBy(e)},scrollToCallback:function(n){var o=r.current;if(o&&(!("offsetHeight"in o)||0!==o.offsetHeight)){var a,u,s,c="smooth"===n.behavior;if(o===window?(u=Math.max(ve(document.documentElement,"height"),document.documentElement.scrollHeight),a=window.innerHeight,s=document.documentElement.scrollTop):(u=o.scrollHeight,a=ve(o,"height"),s=o.scrollTop),n.top=Math.max(Math.min(u-a,n.top),0),Math.abs(a-u)<1.01||n.top===s)return e([s,u]),void(c&&t(!0));c?(i.current=n.top,l.current&&clearTimeout(l.current),l.current=setTimeout(function(){l.current=null,i.current=null,t(!0)},1e3)):i.current=null,o.scrollTo(n)}}}}var Qe=t(function(e){var t=e[0],n=t.sizes,l=t.listRefresh,a=t.defaultItemSize,u=e[1].scrollTop,c=e[2].scrollToIndex,f=e[3].didMount,m=o(!0),h=o(0);return r(i(f,w(h),s(function(e){return 0!==e[1]}),g(!1)),m),d(i(C(l,f),w(m,n,a),s(function(e){var t=e[1],n=e[3];return e[0][1]&&(!X(e[2].sizeTree)||void 0!==n)&&!t}),w(h)),function(e){var t=e[1];setTimeout(function(){y(u,function(){T(m,!0)}),T(c,t)})}),{scrolledToInitialItem:m,initialTopMostItemIndex:h}},f(Re,U,Be,K),{singleton:!0});function Xe(e){return!!e&&("smooth"===e?"smooth":"auto")}var et=t(function(e){var t=e[0],n=t.totalCount,r=t.listRefresh,u=e[1],c=u.isAtBottom,f=u.atBottomState,m=e[2].scrollToIndex,g=e[3].scrolledToInitialItem,v=e[4],I=v.propsReady,x=v.didMount,H=e[5].log,b=e[6].scrollingInProgress,R=o(!1),z=null;function k(e){T(m,{index:"LAST",align:"end",behavior:e})}return d(i(C(i(h(n),p(1)),x),w(h(R),c,g,b),l(function(e){var t=e[0],n=t[0],o=t[1]&&e[3],r="auto";return o&&(r=function(e,t){return"function"==typeof e?Xe(e(t)):t&&Xe(e)}(e[1],e[2]||e[4]),o=o&&!!r),{totalCount:n,shouldFollow:o,followOutputBehavior:r}}),s(function(e){return e.shouldFollow})),function(e){var t=e.totalCount,n=e.followOutputBehavior;z&&(z(),z=null),z=y(r,function(){a(H)("following output to ",{totalCount:t},N.DEBUG),k(n),z=null})}),d(i(C(h(R),n,I),s(function(e){return e[0]&&e[2]}),S(function(e,t){var n=t[1];return{refreshed:e.value===n,value:n}},{refreshed:!1,value:0}),s(function(e){return e.refreshed}),w(R,n)),function(e){var t=e[1],n=y(f,function(e){!t||e.atBottom||"SIZE_INCREASED"!==e.notAtBottomBecause||z||(a(H)("scrolling to bottom due to increased size",{},N.DEBUG),k("auto"))});setTimeout(n,100)}),d(C(h(R),f),function(e){var t=e[1];e[0]&&!t.atBottom&&"VIEWPORT_HEIGHT_DECREASING"===t.notAtBottomBecause&&k("auto")}),{followOutput:R}},f(Re,q,Be,Qe,K,j,U));function tt(e){return e.reduce(function(e,t){return e.groupIndices.push(e.totalCount),e.totalCount+=t+1,e},{totalCount:0,groupIndices:[]})}var nt=t(function(e){var t=e[0],o=t.totalCount,a=t.groupIndices,d=t.sizes,f=e[1],m=f.scrollTop,h=f.headerHeight,p=n(),g=n(),v=u(i(p,l(tt)));return r(i(v,l(b("totalCount"))),o),r(i(v,l(b("groupIndices"))),a),r(i(C(m,d,h),s(function(e){return He(e[1])}),l(function(e){return ne(e[1].groupOffsetTree,Math.max(e[0]-e[2],0),"v")[0]}),c(),l(function(e){return[e]})),g),{groupCounts:p,topItemsIndexes:g}},f(Re,U)),ot={items:[],topItems:[],offsetTop:0,offsetBottom:0,top:0,bottom:0,topListHeight:0,totalCount:0};function rt(e,t,n){if(0===e.length)return[];if(!He(t))return e.map(function(e){return P({},e,{index:e.index+n,originalIndex:e.index})});for(var o,r=[],i=de(t.groupOffsetTree,e[0].index,e[e.length-1].index),l=void 0,a=0,u=W(e);!(o=u()).done;){var s=o.value;(!l||l.end<s.index)&&(l=i.shift(),a=t.groupIndices.indexOf(l.start)),r.push(P({},s.index===l.start?{type:"group",index:a}:{index:s.index-(a+1)+n,groupIndex:a},{size:s.size,offset:s.offset,originalIndex:s.index,data:s.data}))}return r}function it(e,t,n,o,r){var i=0,l=0;if(e.length>0){i=e[0].offset;var a=e[e.length-1];l=a.offset+a.size}var u=i,s=o.lastOffset+(n-o.lastIndex)*o.lastSize-l;return{items:rt(e,o,r),topItems:rt(t,o,r),topListHeight:t.reduce(function(e,t){return t.size+e},0),offsetTop:i,offsetBottom:s,top:u,bottom:l,totalCount:n}}var lt,at,ut,st=t(function(e){var t=e[0],a=t.sizes,d=t.totalCount,f=t.data,m=t.firstItemIndex,p=e[1],g=e[2],v=g.visibleRange,S=g.listBoundary,T=g.topListHeight,y=e[3],H=y.scrolledToInitialItem,z=y.initialTopMostItemIndex,k=e[4].topListHeight,B=e[5],E=e[6].didMount,L=o([]),O=n();r(p.topItemsIndexes,L);var M=I(i(C(E,h(v),h(d),h(a),h(z),H,h(L),h(m),f),s(function(e){return e[0]}),l(function(e){var t=e[1],n=t[0],o=t[1],r=e[2],i=e[4],l=e[5],a=e[6],u=e[7],s=e[8],c=e[3],d=c.sizeTree,f=c.offsetTree;if(0===r||0===n&&0===o)return ot;if(X(d))return it(function(e,t,n){if(He(t)){var o=ye(e,t);return[{index:ne(t.groupOffsetTree,o)[0],size:0,offset:0},{index:o,size:0,offset:0,data:n&&n[0]}]}return[{index:e,size:0,offset:0,data:n&&n[0]}]}(i,c,s),[],r,c,u);var m=[];if(a.length>0)for(var h,p=a[0],g=a[a.length-1],v=0,I=W(de(d,p,g));!(h=I()).done;)for(var C=h.value,S=C.value,T=Math.max(C.start,p),x=Math.min(C.end,g),w=T;w<=x;w++)m.push({index:w,size:S,offset:v,data:s&&s[w]}),v+=S;if(!l)return it([],m,r,c,u);var y=a.length>0?a[a.length-1]+1:0,H=function(e,t,n,o){return void 0===o&&(o=0),o>0&&(t=Math.max(t,ge(e,o,Ce).offset)),fe((i=n,a=pe(r=e,t,l=Se),u=pe(r,i,l,a),r.slice(a,u+1)),Te);var r,i,l,a,u}(f,n,o,y);if(0===H.length)return null;var b=r-1;return it(R([],function(e){for(var t,r=W(H);!(t=r()).done;){var i=t.value,l=i.value,a=l.offset,u=i.start,c=l.size;l.offset<n&&(a+=((u+=Math.floor((n-l.offset)/c))-i.start)*c),u<y&&(a+=(y-u)*c,u=y);for(var d=Math.min(i.end,b),f=u;f<=d&&!(a>=o);f++)e.push({index:f,size:c,offset:a,data:s&&s[f]}),a+=c}}),m,r,c,u)}),s(function(e){return null!==e}),c()),ot);return r(i(f,s(function(e){return void 0!==e}),l(function(e){return e.length})),d),r(i(M,l(b("topListHeight"))),k),r(k,T),r(i(M,l(function(e){return[e.top,e.bottom]})),S),r(i(M,l(function(e){return e.items})),O),P({listState:M,topItemsIndexes:L,endReached:u(i(M,s(function(e){return e.items.length>0}),w(d,f),s(function(e){var t=e[0].items;return t[t.length-1].originalIndex===e[1]-1}),l(function(e){return[e[1]-1,e[2]]}),c(D),l(function(e){return e[0]}))),startReached:u(i(M,x(200),s(function(e){var t=e.items;return t.length>0&&t[0].originalIndex===e.topItems.length}),l(function(e){return e.items[0].index}),c())),rangeChanged:u(i(M,s(function(e){return e.items.length>0}),l(function(e){var t=e.items;return{startIndex:t[0].index,endIndex:t[t.length-1].index}}),c(F))),itemsRendered:O},B)},f(Re,nt,Oe,Qe,Be,q,K),{singleton:!0}),ct=t(function(e){var t=e[0],n=t.sizes,a=t.firstItemIndex,u=t.data,c=e[1].listState,d=e[2].didMount,f=o(0);return r(i(d,w(f),s(function(e){return 0!==e[1]}),w(n,a,u),l(function(e){var t=e[0][1],n=e[1],o=e[2],r=e[3],i=void 0===r?[]:r,l=0;if(n.groupIndices.length>0)for(var a,u=W(n.groupIndices);!((a=u()).done||a.value-l>=t);)l++;var s=t+l;return it(Array.from({length:s}).map(function(e,t){return{index:t,size:0,offset:0,data:i[t]}}),[],s,n,o)})),c),{initialItemCount:f}},f(Re,st,K),{singleton:!0}),dt=t(function(e){var t=e[0].topItemsIndexes,n=o(0);return r(i(n,s(function(e){return e>0}),l(function(e){return Array.from({length:e}).map(function(e,t){return t})})),t),{topItemCount:n}},f(st)),ft=t(function(e){var t=e[0],o=t.footerHeight,a=t.headerHeight,u=e[1].listState,s=n(),c=I(i(C(o,a,u),l(function(e){var t=e[2];return e[0]+e[1]+t.offsetBottom+t.bottom})),0);return r(h(c),s),{totalListHeight:c,totalListHeightChanged:s}},f(U,st),{singleton:!0}),mt=t(function(e){var t=e[0],n=t.scrollBy,o=t.scrollTop,a=t.deviation,c=t.scrollingInProgress,f=e[1],m=f.isScrolling,h=f.isAtBottom,p=f.atBottomState,g=f.scrollDirection,v=e[3],y=v.beforeUnshiftWith,H=v.sizes,b=e[4].log,R=u(i(e[2].listState,w(f.lastJumpDueToItemResize),S(function(e,t){var n=e[1],o=t[0],r=o.items,i=o.totalCount,l=t[1],a=0;if(e[2]===i){if(n.length>0&&r.length>0){var u=1===r.length;if(0!==r[0].originalIndex||0!==n[0].originalIndex)for(var s=function(e){var t=r[e],o=n.find(function(e){return e.originalIndex===t.originalIndex});return o?t.offset!==o.offset||u?(a=t.offset-o.offset+t.size-o.size,"break"):void 0:"continue"},c=r.length-1;c>=0;c--){var d=s(c);if("continue"!==d&&"break"===d)break}}0!==a&&(a+=l)}return[a,r,i]},[0,[],0]),s(function(e){return 0!==e[0]}),w(o,g,c,b,h,p),s(function(e){return!e[3]&&0!==e[1]&&e[2]===Y}),l(function(e){var t=e[0][0];return(0,e[4])("Upward scrolling compensation",{amount:t},N.DEBUG),t})));return r(i(R,w(a),l(function(e){return e[1]-e[0]})),a),d(i(C(I(m,!1),a),s(function(e){return!e[0]&&0!==e[1]}),l(function(e){return e[1]}),x(1)),function(e){e>0?(T(n,{top:-e,behavior:"auto"}),T(a,0)):(T(a,0),T(n,{top:-e,behavior:"auto"}))}),r(i(y,w(H),l(function(e){return e[0]*e[1].lastSize})),R),{deviation:a}},f(U,q,st,Re,j)),ht=t(function(e){var t=e[0].totalListHeight,n=e[1].didMount,r=e[2].scrollTo,a=o(0);return d(i(n,w(a),s(function(e){return 0!==e[1]}),l(function(e){return{top:e[1]}})),function(e){y(i(t,s(function(e){return 0!==e})),function(){setTimeout(function(){T(r,e)})})}),{initialScrollTop:a}},f(ft,K,U),{singleton:!0}),pt=t(function(e){var t=e[0].viewportHeight,n=e[1].totalListHeight,r=o(!1);return{alignToBottom:r,paddingTopAddition:I(i(C(r,t,n),s(function(e){return e[0]}),l(function(e){return Math.max(0,e[1]-e[2])}),c()),0)}},f(U,ft),{singleton:!0}),gt=t(function(e){var t=e[0],o=t.sizes,a=t.totalCount,u=e[1],c=u.scrollTop,d=u.viewportHeight,f=u.headerHeight,m=u.scrollingInProgress,h=e[2].scrollToIndex,g=n();return r(i(g,w(o,d,a,f,c),l(function(e){var t=e[0],n=t.index,o=t.behavior,r=void 0===o?"auto":o,l=t.done,a=e[1],u=e[2],c=e[4],d=e[5],f=e[3]-1,h=null;n=ye(n,a);var g=we(n=Math.max(0,n,Math.min(f,n)),a.offsetTree)+c;return g<d?h={index:n,behavior:r,align:"start"}:g+ne(a.sizeTree,n)[1]>d+u&&(h={index:n,behavior:r,align:"end"}),h?l&&y(i(m,p(1),s(function(e){return!1===e})),l):l&&l(),h}),s(function(e){return null!==e})),h),{scrollIntoView:g}},f(Re,U,Be,st,j),{singleton:!0}),vt=t(function(e){return P({},e[0],e[1],e[2],e[3],e[4],e[5],e[6],e[7],e[8])},f(Oe,ct,K,J,ft,ht,pt,Me,gt)),It=t(function(e){var t=e[0],n=t.totalCount,o=t.sizeRanges,a=t.fixedItemSize,u=t.defaultItemSize,s=t.trackItemSizes,c=t.itemSize,d=t.data,f=t.firstItemIndex,m=t.groupIndices,h=e[1],p=h.initialTopMostItemIndex,g=h.scrolledToInitialItem,v=e[2],I=e[3],C=e[4],S=C.listState,T=C.topItemsIndexes,x=A(C,["listState","topItemsIndexes"]),w=e[5].scrollToIndex,y=e[7].topItemCount,H=e[8].groupCounts,R=e[9],z=e[10];return r(x.rangeChanged,R.scrollSeekRangeChanged),r(i(R.windowViewportRect,l(b("visibleHeight"))),v.viewportHeight),P({totalCount:n,data:d,firstItemIndex:f,sizeRanges:o,initialTopMostItemIndex:p,scrolledToInitialItem:g,topItemsIndexes:T,topItemCount:y,groupCounts:H,fixedItemHeight:a,defaultItemHeight:u},I,{listState:S,scrollToIndex:w,trackItemSizes:s,itemSize:c,groupIndices:m},x,R,v,z)},f(Re,Qe,U,et,st,Be,mt,dt,nt,vt,j)),Ct=(lt=function(){if("undefined"==typeof document)return"sticky";var e=document.createElement("div");return e.style.position="-webkit-sticky","-webkit-sticky"===e.style.position?"-webkit-sticky":"sticky"},ut=!1,function(){return ut||(ut=!0,at=lt()),at});function St(e){return e}var Tt=t(function(){var e=o(function(e){return"Item "+e}),t=o(function(e){return"Group "+e}),n=o({}),r=o(St),a=o("div"),u=o(H),s=function(e,t){return void 0===t&&(t=null),I(i(n,l(function(t){return t[e]}),c()),t)};return{itemContent:e,groupContent:t,components:n,computeItemKey:r,headerFooterTag:a,scrollerRef:u,FooterComponent:s("Footer"),HeaderComponent:s("Header"),TopItemListComponent:s("TopItemList"),ListComponent:s("List","div"),ItemComponent:s("Item","div"),GroupComponent:s("Group","div"),ScrollerComponent:s("Scroller","div"),EmptyPlaceholder:s("EmptyPlaceholder"),ScrollSeekPlaceholder:s("ScrollSeekPlaceholder")}});function xt(e,t){var o=n();return d(o,function(){return console.warn("react-virtuoso: You are using a deprecated property. "+t,"color: red;","color: inherit;","color: blue;")}),r(o,e),o}var wt=t(function(e){var t=e[0],o=e[1],u={item:xt(o.itemContent,"Rename the %citem%c prop to %citemContent."),group:xt(o.groupContent,"Rename the %cgroup%c prop to %cgroupContent."),topItems:xt(t.topItemCount,"Rename the %ctopItems%c prop to %ctopItemCount."),itemHeight:xt(t.fixedItemHeight,"Rename the %citemHeight%c prop to %cfixedItemHeight."),scrollingStateChange:xt(t.isScrolling,"Rename the %cscrollingStateChange%c prop to %cisScrolling."),adjustForPrependedItems:n(),maxHeightCacheSize:n(),footer:n(),header:n(),HeaderContainer:n(),FooterContainer:n(),ItemContainer:n(),ScrollContainer:n(),GroupContainer:n(),ListContainer:n(),emptyComponent:n(),scrollSeek:n()};function s(e,t,n){r(i(e,w(o.components),l(function(e){var o,r=e[0],i=e[1];return console.warn("react-virtuoso: "+n+" property is deprecated. Pass components."+t+" instead."),P({},i,((o={})[t]=r,o))})),o.components)}return d(u.adjustForPrependedItems,function(){console.warn("react-virtuoso: adjustForPrependedItems is no longer supported. Use the firstItemIndex property instead - https://virtuoso.dev/prepend-items.","color: red;","color: inherit;","color: blue;")}),d(u.maxHeightCacheSize,function(){console.warn("react-virtuoso: maxHeightCacheSize is no longer necessary. Setting it has no effect - remove it from your code.")}),d(u.HeaderContainer,function(){console.warn("react-virtuoso: HeaderContainer is deprecated. Use headerFooterTag if you want to change the wrapper of the header component and pass components.Header to change its contents.")}),d(u.FooterContainer,function(){console.warn("react-virtuoso: FooterContainer is deprecated. Use headerFooterTag if you want to change the wrapper of the footer component and pass components.Footer to change its contents.")}),d(u.scrollSeek,function(e){var n=e.placeholder,r=A(e,["placeholder"]);console.warn("react-virtuoso: scrollSeek property is deprecated. Pass scrollSeekConfiguration and specify the placeholder in components.ScrollSeekPlaceholder instead."),T(o.components,P({},a(o.components),{ScrollSeekPlaceholder:n})),T(t.scrollSeekConfiguration,r)}),s(u.footer,"Footer","footer"),s(u.header,"Header","header"),s(u.ItemContainer,"Item","ItemContainer"),s(u.ListContainer,"List","ListContainer"),s(u.ScrollContainer,"Scroller","ScrollContainer"),s(u.emptyComponent,"EmptyPlaceholder","emptyComponent"),s(u.GroupContainer,"Group","GroupContainer"),P({},t,o,u)},f(It,Tt)),yt=function(e){return M("div",{style:{height:e.height}})},Ht={position:Ct(),zIndex:1,overflowAnchor:"none"},bt=O(function(e){var t=e.showTopList,n=void 0!==t&&t,o=Ft("listState"),r=Ft("deviation"),i=Dt("sizeRanges"),l=Ft("useWindowScroll"),a=Dt("windowScrollContainerState"),u=Dt("scrollContainerState"),s=l?a:u,c=Ft("itemContent"),d=Ft("groupContent"),f=Ft("trackItemSizes"),m=Ft("itemSize"),h=Ft("log"),p=Je(i,m,f,n?H:s,h),g=Ft("EmptyPlaceholder"),v=Ft("ScrollSeekPlaceholder")||yt,I=Ft("ListComponent"),C=Ft("ItemComponent"),S=Ft("GroupComponent"),T=Ft("computeItemKey"),x=Ft("isSeeking"),w=Ft("groupIndices").length>0,y=Ft("paddingTopAddition"),b=Ft("scrolledToInitialItem"),R=Ft("firstItemIndex"),z=n?{}:{boxSizing:"border-box",paddingTop:o.offsetTop+y,paddingBottom:o.offsetBottom,marginTop:r};return!n&&0===o.items.length&&g&&b?M(g):M(I,{ref:p,style:z,"data-test-id":n?"virtuoso-top-item-list":"virtuoso-item-list"},(n?o.topItems:o.items).map(function(e){var t=e.originalIndex,n=T(t+R,e.data);return x?M(v,P({key:n,index:e.index,height:e.size,type:e.type||"item"},"group"===e.type?{}:{groupIndex:e.groupIndex})):"group"===e.type?M(S,{key:n,"data-index":t,"data-known-size":e.size,"data-item-index":e.index,style:Ht},d(e.index)):M(C,{key:n,"data-index":t,"data-known-size":e.size,"data-item-index":e.index,"data-item-group-index":e.groupIndex,style:{overflowAnchor:"none"}},w?c(e.index,e.groupIndex,e.data):c(e.index,e.data))}))}),Rt={height:"100%",outline:"none",overflowY:"auto",position:"relative",WebkitOverflowScrolling:"touch"},zt={width:"100%",height:"100%",position:"absolute",top:0},kt={width:"100%",position:Ct(),top:0},Bt=O(function(){var e=Ft("HeaderComponent"),t=Dt("headerHeight"),n=Ft("headerFooterTag"),o=Ye(function(e){return t(ve(e,"height"))});return e?M(n,{ref:o},M(e)):null}),Et=O(function(){var e=Ft("FooterComponent"),t=Dt("footerHeight"),n=Ft("headerFooterTag"),o=Ye(function(e){return t(ve(e,"height"))});return e?M(n,{ref:o},M(e)):null});function Lt(e){var t=e.usePublisher,n=e.useEmitter,o=e.useEmitterValue;return O(function(e){var r=e.style,i=e.children,l=A(e,["style","children"]),a=t("scrollContainerState"),u=o("ScrollerComponent"),s=$e(a,t("smoothScrollTargetReached"),u,o("scrollerRef")),c=s.scrollerRef,d=s.scrollByCallback;return n("scrollTo",s.scrollToCallback),n("scrollBy",d),M(u,P({ref:c,style:P({},Rt,r),"data-test-id":"virtuoso-scroller","data-virtuoso-scroller":"true",tabIndex:0},l),i)})}function Ot(e){var t=e.usePublisher,n=e.useEmitter,o=e.useEmitterValue;return O(function(e){var r=e.style,i=e.children,l=A(e,["style","children"]),a=t("windowScrollContainerState"),u=o("ScrollerComponent"),s=t("smoothScrollTargetReached"),c=o("totalListHeight"),d=o("deviation"),f=$e(a,s,u,H),m=f.scrollerRef,h=f.scrollByCallback,p=f.scrollToCallback;return qe(function(){return m.current=window,function(){m.current=null}},[m]),n("windowScrollTo",p),n("scrollBy",h),M(u,P({style:P({position:"relative"},r,0!==c?{height:c+d}:{}),"data-virtuoso-scroller":"true"},l),i)})}var Mt=function(e){var t=e.children,n=Dt("viewportHeight"),o=Ye(z(n,function(e){return ve(e,"height")}));return M("div",{style:zt,ref:o,"data-viewport-type":"element"},t)},Pt=function(e){var t=e.children,n=Ze(Dt("windowViewportRect"));return M("div",{ref:n,style:zt,"data-viewport-type":"window"},t)},At=function(e){var t=e.children,n=Ft("TopItemListComponent"),o=Ft("headerHeight"),r=P({},kt,{marginTop:o+"px"});return M(n||"div",{style:r},t)},Vt=e(wt,{required:{},optional:{followOutput:"followOutput",firstItemIndex:"firstItemIndex",itemContent:"itemContent",groupContent:"groupContent",overscan:"overscan",increaseViewportBy:"increaseViewportBy",totalCount:"totalCount",topItemCount:"topItemCount",initialTopMostItemIndex:"initialTopMostItemIndex",components:"components",groupCounts:"groupCounts",atBottomThreshold:"atBottomThreshold",computeItemKey:"computeItemKey",defaultItemHeight:"defaultItemHeight",fixedItemHeight:"fixedItemHeight",itemSize:"itemSize",scrollSeekConfiguration:"scrollSeekConfiguration",headerFooterTag:"headerFooterTag",data:"data",initialItemCount:"initialItemCount",initialScrollTop:"initialScrollTop",alignToBottom:"alignToBottom",useWindowScroll:"useWindowScroll",scrollerRef:"scrollerRef",logLevel:"logLevel",item:"item",group:"group",topItems:"topItems",itemHeight:"itemHeight",scrollingStateChange:"scrollingStateChange",maxHeightCacheSize:"maxHeightCacheSize",footer:"footer",header:"header",ItemContainer:"ItemContainer",ScrollContainer:"ScrollContainer",ListContainer:"ListContainer",GroupContainer:"GroupContainer",emptyComponent:"emptyComponent",HeaderContainer:"HeaderContainer",FooterContainer:"FooterContainer",scrollSeek:"scrollSeek"},methods:{scrollToIndex:"scrollToIndex",scrollIntoView:"scrollIntoView",scrollTo:"scrollTo",scrollBy:"scrollBy",adjustForPrependedItems:"adjustForPrependedItems"},events:{isScrolling:"isScrolling",endReached:"endReached",startReached:"startReached",rangeChanged:"rangeChanged",atBottomStateChange:"atBottomStateChange",atTopStateChange:"atTopStateChange",totalListHeightChanged:"totalListHeightChanged",itemsRendered:"itemsRendered",groupIndices:"groupIndices"}},O(function(e){var t=Ft("useWindowScroll"),n=Ft("topItemsIndexes").length>0,o=t?Pt:Mt;return M(t?Ut:Nt,P({},e),M(o,null,M(Bt,null),M(bt,null),M(Et,null)),n&&M(At,null,M(bt,{showTopList:!0})))})),Wt=Vt.Component,Dt=Vt.usePublisher,Ft=Vt.useEmitterValue,Gt=Vt.useEmitter,Nt=Lt({usePublisher:Dt,useEmitterValue:Ft,useEmitter:Gt}),Ut=Ot({usePublisher:Dt,useEmitterValue:Ft,useEmitter:Gt}),_t=t(function(){var e=o(function(e){return"Item "+e}),t=o({}),n=o("virtuoso-grid-item"),r=o("virtuoso-grid-list"),a=o(St),u=o(H),s=function(e,n){return void 0===n&&(n=null),I(i(t,l(function(t){return t[e]}),c()),n)};return{itemContent:e,components:t,computeItemKey:a,itemClassName:n,listClassName:r,scrollerRef:u,ListComponent:s("List","div"),ItemComponent:s("Item","div"),ScrollerComponent:s("Scroller","div"),ScrollSeekPlaceholder:s("ScrollSeekPlaceholder","div")}}),jt=t(function(e){var t=e[0],o=e[1],u={item:xt(o.itemContent,"Rename the %citem%c prop to %citemContent."),ItemContainer:n(),ScrollContainer:n(),ListContainer:n(),emptyComponent:n(),scrollSeek:n()};function s(e,t,n){r(i(e,w(o.components),l(function(e){var o,r=e[0],i=e[1];return console.warn("react-virtuoso: "+n+" property is deprecated. Pass components."+t+" instead."),P({},i,((o={})[t]=r,o))})),o.components)}return d(u.scrollSeek,function(e){var n=e.placeholder,r=A(e,["placeholder"]);console.warn("react-virtuoso: scrollSeek property is deprecated. Pass scrollSeekConfiguration and specify the placeholder in components.ScrollSeekPlaceholder instead."),T(o.components,P({},a(o.components),{ScrollSeekPlaceholder:n})),T(t.scrollSeekConfiguration,r)}),s(u.ItemContainer,"Item","ItemContainer"),s(u.ListContainer,"List","ListContainer"),s(u.ScrollContainer,"Scroller","ScrollContainer"),P({},t,o,u)},f(Ue,_t)),Kt=O(function(){var e=Qt("gridState"),t=Qt("listClassName"),n=Qt("itemClassName"),o=Qt("itemContent"),r=Qt("computeItemKey"),i=Qt("isSeeking"),l=$t("scrollHeight"),a=Qt("ItemComponent"),u=Qt("ListComponent"),s=Qt("ScrollSeekPlaceholder"),c=$t("itemDimensions"),d=Ye(function(e){l(e.parentElement.parentElement.scrollHeight);var t=e.firstChild;t&&c(t.getBoundingClientRect())});return M(u,{ref:d,className:t,style:{paddingTop:e.offsetTop,paddingBottom:e.offsetBottom}},e.items.map(function(t){var l=r(t.index);return i?M(s,{key:l,index:t.index,height:e.itemHeight,width:e.itemWidth}):M(a,{className:n,"data-index":t.index,key:l},o(t.index))}))}),Yt=function(e){var t=e.children,n=$t("viewportDimensions"),o=Ye(function(e){n(e.getBoundingClientRect())});return M("div",{style:zt,ref:o},t)},Zt=function(e){var t=e.children,n=Ze($t("windowViewportRect"));return M("div",{ref:n,style:zt},t)},qt=e(jt,{optional:{totalCount:"totalCount",overscan:"overscan",itemContent:"itemContent",components:"components",computeItemKey:"computeItemKey",initialItemCount:"initialItemCount",scrollSeekConfiguration:"scrollSeekConfiguration",listClassName:"listClassName",itemClassName:"itemClassName",useWindowScroll:"useWindowScroll",scrollerRef:"scrollerRef",item:"item",ItemContainer:"ItemContainer",ScrollContainer:"ScrollContainer",ListContainer:"ListContainer",scrollSeek:"scrollSeek"},methods:{scrollTo:"scrollTo",scrollBy:"scrollBy",scrollToIndex:"scrollToIndex"},events:{isScrolling:"isScrolling",endReached:"endReached",startReached:"startReached",rangeChanged:"rangeChanged",atBottomStateChange:"atBottomStateChange",atTopStateChange:"atTopStateChange"}},O(function(e){var t=P({},e),n=Qt("useWindowScroll"),o=n?Zt:Yt;return M(n?tn:en,P({},t),M(o,null,M(Kt,null)))})),Jt=qt.Component,$t=qt.usePublisher,Qt=qt.useEmitterValue,Xt=qt.useEmitter,en=Lt({usePublisher:$t,useEmitterValue:Qt,useEmitter:Xt}),tn=Ot({usePublisher:$t,useEmitterValue:Qt,useEmitter:Xt}),nn=t(function(){var e=o(function(e){return M("td",null,"Item $",e)}),t=o(null),n=o({}),r=o(St),a=o(H),u=function(e,t){return void 0===t&&(t=null),I(i(n,l(function(t){return t[e]}),c()),t)};return{itemContent:e,fixedHeaderContent:t,components:n,computeItemKey:r,scrollerRef:a,TableComponent:u("Table","table"),TableHeadComponent:u("TableHead","thead"),TableBodyComponent:u("TableBody","tbody"),TableRowComponent:u("TableRow","tr"),ScrollerComponent:u("Scroller","div"),EmptyPlaceholder:u("EmptyPlaceholder"),ScrollSeekPlaceholder:u("ScrollSeekPlaceholder")}}),on=t(function(e){return P({},e[0],e[1])},f(It,nn)),rn=function(e){return M("tr",null,M("td",{style:{height:e.height}}))},ln=function(e){return M("tr",null,M("td",{style:{height:e.height,padding:0,border:0}}))},an=O(function(){var e=mn("listState"),t=mn("deviation"),n=fn("sizeRanges"),o=mn("useWindowScroll"),r=fn("windowScrollContainerState"),i=fn("scrollContainerState"),l=o?r:i,a=mn("itemContent"),u=mn("trackItemSizes"),s=Je(n,mn("itemSize"),u,l,mn("log")),c=mn("EmptyPlaceholder"),d=mn("ScrollSeekPlaceholder")||rn,f=mn("TableBodyComponent"),m=mn("TableRowComponent"),h=mn("computeItemKey"),p=mn("isSeeking"),g=mn("paddingTopAddition"),v=mn("scrolledToInitialItem"),I=mn("firstItemIndex");if(0===e.items.length&&c&&v)return M(c);var C=e.offsetTop+g+t,S=e.offsetBottom,T=C>0?M(ln,{height:C,key:"padding-top"}):null,x=S>0?M(ln,{height:S,key:"padding-bottom"}):null,w=e.items.map(function(e){var t=e.originalIndex,n=h(t+I,e.data);return p?M(d,{key:n,index:e.index,height:e.size,type:e.type||"item"}):M(m,{key:n,"data-index":t,"data-known-size":e.size,"data-item-index":e.index,style:{overflowAnchor:"none"}},a(e.index,e.data))});return M(f,{ref:s,"data-test-id":"virtuoso-item-list"},[T].concat(w,[x]))}),un=function(e){var t=e.children,n=fn("viewportHeight"),o=Ye(z(n,function(e){return ve(e,"height")}));return M("div",{style:zt,ref:o,"data-viewport-type":"element"},t)},sn=function(e){var t=e.children,n=Ze(fn("windowViewportRect"));return M("div",{ref:n,style:zt,"data-viewport-type":"window"},t)},cn=e(on,{required:{},optional:{followOutput:"followOutput",firstItemIndex:"firstItemIndex",itemContent:"itemContent",fixedHeaderContent:"fixedHeaderContent",overscan:"overscan",increaseViewportBy:"increaseViewportBy",totalCount:"totalCount",topItemCount:"topItemCount",initialTopMostItemIndex:"initialTopMostItemIndex",components:"components",groupCounts:"groupCounts",atBottomThreshold:"atBottomThreshold",computeItemKey:"computeItemKey",defaultItemHeight:"defaultItemHeight",fixedItemHeight:"fixedItemHeight",itemSize:"itemSize",scrollSeekConfiguration:"scrollSeekConfiguration",data:"data",initialItemCount:"initialItemCount",initialScrollTop:"initialScrollTop",alignToBottom:"alignToBottom",useWindowScroll:"useWindowScroll",scrollerRef:"scrollerRef",logLevel:"logLevel"},methods:{scrollToIndex:"scrollToIndex",scrollIntoView:"scrollIntoView",scrollTo:"scrollTo",scrollBy:"scrollBy"},events:{isScrolling:"isScrolling",endReached:"endReached",startReached:"startReached",rangeChanged:"rangeChanged",atBottomStateChange:"atBottomStateChange",atTopStateChange:"atTopStateChange",totalListHeightChanged:"totalListHeightChanged",itemsRendered:"itemsRendered",groupIndices:"groupIndices"}},O(function(e){var t=mn("useWindowScroll"),n=fn("fixedHeaderHeight"),o=mn("fixedHeaderContent"),r=Ye(z(n,function(e){return ve(e,"height")})),i=t?gn:pn,l=t?sn:un,a=mn("TableComponent"),u=mn("TableHeadComponent"),s=o?M(u,{style:{zIndex:1,position:"sticky",top:0},ref:r},o()):null;return M(i,P({},e),M(l,null,M(a,{style:{borderSpacing:0}},[s,M(an,null)])))})),dn=cn.Component,fn=cn.usePublisher,mn=cn.useEmitterValue,hn=cn.useEmitter,pn=Lt({usePublisher:fn,useEmitterValue:mn,useEmitter:hn}),gn=Ot({usePublisher:fn,useEmitterValue:mn,useEmitter:hn}),vn=Wt,In=Wt,Cn=dn,Sn=Jt;export{In as GroupedVirtuoso,N as LogLevel,Cn as TableVirtuoso,vn as Virtuoso,Sn as VirtuosoGrid};
//# sourceMappingURL=index.m.js.map

@@ -135,2 +135,3 @@ import * as u from '@virtuoso.dev/urx';

topListHeight: u.StatefulStream<number>;
fixedHeaderHeight: u.StatefulStream<number>;
increaseViewportBy: u.StatefulStream<import("./sizeRangeSystem").ViewportIncrease>;

@@ -421,2 +422,3 @@ visibleRange: u.StatefulStream<import("./sizeRangeSystem").NumberTuple>;

topListHeight: u.StatefulStream<number>;
fixedHeaderHeight: u.StatefulStream<number>;
increaseViewportBy: u.StatefulStream<import("./sizeRangeSystem").ViewportIncrease>;

@@ -423,0 +425,0 @@ visibleRange: u.StatefulStream<import("./sizeRangeSystem").NumberTuple>;

@@ -128,2 +128,3 @@ import * as u from '@virtuoso.dev/urx';

topListHeight: u.StatefulStream<number>;
fixedHeaderHeight: u.StatefulStream<number>;
increaseViewportBy: u.StatefulStream<import("./sizeRangeSystem").ViewportIncrease>;

@@ -414,2 +415,3 @@ visibleRange: u.StatefulStream<import("./sizeRangeSystem").NumberTuple>;

topListHeight: u.StatefulStream<number>;
fixedHeaderHeight: u.StatefulStream<number>;
increaseViewportBy: u.StatefulStream<import("./sizeRangeSystem").ViewportIncrease>;

@@ -416,0 +418,0 @@ visibleRange: u.StatefulStream<import("./sizeRangeSystem").NumberTuple>;

@@ -9,2 +9,3 @@ import { ComponentPropsWithRef, ComponentType, Key, ReactNode } from 'react';

}
export declare type FixedHeaderContent = (() => React.ReactChildren | React.ReactNode) | null;
export interface GroupItemContent<D> {

@@ -28,2 +29,3 @@ (index: number, groupIndex: number, data: D): ReactNode;

export declare type TopItemListProps = Pick<ComponentPropsWithRef<'div'>, 'style' | 'children'>;
export declare type TableProps = Pick<ComponentPropsWithRef<'table'>, 'style'>;
/**

@@ -44,2 +46,3 @@ * Passed to the Components.List custom component

'data-test-id'?: string;
'data-virtuoso-scroller'?: boolean;
};

@@ -108,2 +111,38 @@ /**

}
/**
* Customize the TableVirtuoso rendering by passing a set of custom components.
*/
export interface TableComponents {
/**
* Set to customize the wrapping `table` element.
*
*/
Table?: ComponentType<TableProps>;
/**
* Set to render a fixed header at the top of the table (`thead`). use [[fixedHeaderHeight]] to set the contents
*
*/
TableHead?: ComponentType;
/**
* Set to customize the item wrapping element. Default is `tr`.
*/
TableRow?: ComponentType<ItemProps>;
/**
* Set to customize the outermost scrollable element. This should not be necessary in general,
* as the component passes its HTML attribute props to it.
*/
Scroller?: ComponentType<ScrollerProps>;
/**
* Set to customize the items wrapper. Default is `tbody`.
*/
TableBody?: ComponentType<ListProps>;
/**
* Set to render a custom UI when the list is empty.
*/
EmptyPlaceholder?: ComponentType;
/**
* Set to render an item placeholder when the user scrolls fast. See the `scrollSeek` property for more details.
*/
ScrollSeekPlaceholder?: ComponentType<ScrollSeekPlaceholderProps>;
}
export interface ComputeItemKey<D> {

@@ -168,2 +207,3 @@ (index: number, item: D): Key;

export declare type ListRootProps = Omit<React.HTMLProps<'div'>, 'ref' | 'data'>;
export declare type TableRootProps = Omit<React.HTMLProps<'table'>, 'ref' | 'data'>;
export declare type GridRootProps = Omit<React.HTMLProps<'div'>, 'ref' | 'data'>;

@@ -170,0 +210,0 @@ export interface GridItem {

@@ -133,2 +133,3 @@ import * as u from '@virtuoso.dev/urx';

topListHeight: u.StatefulStream<number>;
fixedHeaderHeight: u.StatefulStream<number>;
increaseViewportBy: u.StatefulStream<import("./sizeRangeSystem").ViewportIncrease>;

@@ -419,2 +420,3 @@ visibleRange: u.StatefulStream<import("./sizeRangeSystem").NumberTuple>;

topListHeight: u.StatefulStream<number>;
fixedHeaderHeight: u.StatefulStream<number>;
increaseViewportBy: u.StatefulStream<import("./sizeRangeSystem").ViewportIncrease>;

@@ -421,0 +423,0 @@ visibleRange: u.StatefulStream<import("./sizeRangeSystem").NumberTuple>;

@@ -222,2 +222,3 @@ import * as u from '@virtuoso.dev/urx';

topListHeight: u.StatefulStream<number>;
fixedHeaderHeight: u.StatefulStream<number>;
increaseViewportBy: u.StatefulStream<import("./sizeRangeSystem").ViewportIncrease>;

@@ -508,2 +509,3 @@ visibleRange: u.StatefulStream<import("./sizeRangeSystem").NumberTuple>;

topListHeight: u.StatefulStream<number>;
fixedHeaderHeight: u.StatefulStream<number>;
increaseViewportBy: u.StatefulStream<import("./sizeRangeSystem").ViewportIncrease>;

@@ -510,0 +512,0 @@ visibleRange: u.StatefulStream<import("./sizeRangeSystem").NumberTuple>;

@@ -47,4 +47,5 @@ import * as u from '@virtuoso.dev/urx';

topListHeight: u.StatefulStream<number>;
fixedHeaderHeight: u.StatefulStream<number>;
increaseViewportBy: u.StatefulStream<ViewportIncrease>;
visibleRange: u.StatefulStream<NumberTuple>;
}>;

@@ -114,2 +114,3 @@ export declare const topItemCountSystem: import("@virtuoso.dev/urx").SystemSpec<[import("@virtuoso.dev/urx").SystemSpec<[import("@virtuoso.dev/urx").SystemSpec<[import("@virtuoso.dev/urx").SystemSpec<never[], () => {

topListHeight: import("@virtuoso.dev/urx").StatefulStream<number>;
fixedHeaderHeight: import("@virtuoso.dev/urx").StatefulStream<number>;
increaseViewportBy: import("@virtuoso.dev/urx").StatefulStream<import("./sizeRangeSystem").ViewportIncrease>;

@@ -400,2 +401,3 @@ visibleRange: import("@virtuoso.dev/urx").StatefulStream<import("./sizeRangeSystem").NumberTuple>;

topListHeight: import("@virtuoso.dev/urx").StatefulStream<number>;
fixedHeaderHeight: import("@virtuoso.dev/urx").StatefulStream<number>;
increaseViewportBy: import("@virtuoso.dev/urx").StatefulStream<import("./sizeRangeSystem").ViewportIncrease>;

@@ -402,0 +404,0 @@ visibleRange: import("@virtuoso.dev/urx").StatefulStream<import("./sizeRangeSystem").NumberTuple>;

@@ -128,2 +128,3 @@ import * as u from '@virtuoso.dev/urx';

topListHeight: u.StatefulStream<number>;
fixedHeaderHeight: u.StatefulStream<number>;
increaseViewportBy: u.StatefulStream<import("./sizeRangeSystem").ViewportIncrease>;

@@ -414,2 +415,3 @@ visibleRange: u.StatefulStream<import("./sizeRangeSystem").NumberTuple>;

topListHeight: u.StatefulStream<number>;
fixedHeaderHeight: u.StatefulStream<number>;
increaseViewportBy: u.StatefulStream<import("./sizeRangeSystem").ViewportIncrease>;

@@ -416,0 +418,0 @@ visibleRange: u.StatefulStream<import("./sizeRangeSystem").NumberTuple>;

@@ -169,2 +169,3 @@ import * as u from '@virtuoso.dev/urx';

topListHeight: u.StatefulStream<number>;
fixedHeaderHeight: u.StatefulStream<number>;
increaseViewportBy: u.StatefulStream<import("./sizeRangeSystem").ViewportIncrease>;

@@ -455,2 +456,3 @@ visibleRange: u.StatefulStream<import("./sizeRangeSystem").NumberTuple>;

topListHeight: u.StatefulStream<number>;
fixedHeaderHeight: u.StatefulStream<number>;
increaseViewportBy: u.StatefulStream<import("./sizeRangeSystem").ViewportIncrease>;

@@ -457,0 +459,0 @@ visibleRange: u.StatefulStream<import("./sizeRangeSystem").NumberTuple>;

@@ -5,3 +5,3 @@ {

"sideEffects": false,
"version": "2.4.1",
"version": "2.5.0",
"homepage": "https://virtuoso.dev/",

@@ -81,3 +81,2 @@ "license": "MIT",

"jest": "^26.6.3",
"jest-playwright-preset": "^1.7.0",
"jsdom": "^16.4.0",

@@ -84,0 +83,0 @@ "lodash": "^4.17.21",

@@ -5,3 +5,3 @@ <img src="https://user-images.githubusercontent.com/13347/101237112-ec4c6000-36de-11eb-936d-4b6b7ec94976.png" width="229" />

**React Virtuoso** is the most powerful React virtual list component, full stop. Here's why:
**React Virtuoso** is the most powerful React virtual list/table component, full stop. Here's why:

@@ -12,2 +12,3 @@ - Variable sized items out of the box; no manual measurements or hard-coding item heights is necessary;

- [Responsive grid layout](//virtuoso.dev/grid-responsive-columns/);
- [Table Support](//virtuoso.dev/hello-table/);
- [Automatic handling of content resize](//virtuoso.dev/auto-resizing/);

@@ -62,2 +63,7 @@ - [Custom Header, Footer, and empty list components](//virtuoso.dev/customize-structure/);

## [Table](//virtuoso.dev/hello-table/)
The `TableVirtuoso` component works just like `Virtuoso`, but with HTML tables.
It supports window scrolling, sticky headers, sticky columns, and works with React Table and MUI Table.
## Works With Your UI Library of Choice

@@ -64,0 +70,0 @@

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is too big to display

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc