react-window 2.0.2-alpha.0 → 2.0.2-alpha.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/react-window.cjs +1 -1
- package/dist/react-window.cjs.map +1 -1
- package/dist/react-window.d.ts +2270 -9
- package/dist/react-window.js +430 -428
- package/dist/react-window.js.map +1 -1
- package/docs/assets/{AriaRolesRoute-BQ4l2o71.js → AriaRolesRoute-DUJio_Uq.js} +2 -2
- package/docs/assets/{AriaRolesRoute-BQ4l2o71.js.map → AriaRolesRoute-DUJio_Uq.js.map} +1 -1
- package/docs/assets/{AriaRolesRoute-ahe1aw6k.js → AriaRolesRoute-Dsxt70zK.js} +2 -2
- package/docs/assets/{AriaRolesRoute-ahe1aw6k.js.map → AriaRolesRoute-Dsxt70zK.js.map} +1 -1
- package/docs/assets/{AriaRolesRoute-BXnUEUK2.js → AriaRolesRoute-rvLAMJGg.js} +2 -2
- package/docs/assets/{AriaRolesRoute-BXnUEUK2.js.map → AriaRolesRoute-rvLAMJGg.js.map} +1 -1
- package/docs/assets/CellComponent.example-CFiu8zNV.js +2 -0
- package/docs/assets/{CellComponent.example-dKVH8ZYc.js.map → CellComponent.example-CFiu8zNV.js.map} +1 -1
- package/docs/assets/{ComponentProps-BA6jJCAT.js → ComponentProps-BFVtvKZW.js} +2 -2
- package/docs/assets/{ComponentProps-BA6jJCAT.js.map → ComponentProps-BFVtvKZW.js.map} +1 -1
- package/docs/assets/ContinueLink-DMnSPbdx.js +2 -0
- package/docs/assets/{ContinueLink-DN1_wnU9.js.map → ContinueLink-DMnSPbdx.js.map} +1 -1
- package/docs/assets/FixedHeightList-C81qGuc2.js +2 -0
- package/docs/assets/FixedHeightList-C81qGuc2.js.map +1 -0
- package/docs/assets/{FixedRowHeightsRoute-iwoWadtD.js → FixedRowHeightsRoute-BgFMqZ9J.js} +2 -2
- package/docs/assets/FixedRowHeightsRoute-BgFMqZ9J.js.map +1 -0
- package/docs/assets/{FormattedCode-CDzGfhdX.js → FormattedCode-B5NYyy8K.js} +2 -2
- package/docs/assets/{FormattedCode-CDzGfhdX.js.map → FormattedCode-B5NYyy8K.js.map} +1 -1
- package/docs/assets/{GettingStartedRoute-6onVm0dP.js → GettingStartedRoute-OLG6nuHW.js} +2 -2
- package/docs/assets/{GettingStartedRoute-6onVm0dP.js.map → GettingStartedRoute-OLG6nuHW.js.map} +1 -1
- package/docs/assets/Grid-BXEwl59J.js +2 -0
- package/docs/assets/Grid-BXEwl59J.js.map +1 -0
- package/docs/assets/{Header-DyQVANF3.js → Header-B_onM2vR.js} +2 -2
- package/docs/assets/{Header-DyQVANF3.js.map → Header-B_onM2vR.js.map} +1 -1
- package/docs/assets/{HorizontalListsRoute-BQxNRT_F.js → HorizontalListsRoute-YTu4ru_X.js} +2 -2
- package/docs/assets/{HorizontalListsRoute-BQxNRT_F.js.map → HorizontalListsRoute-YTu4ru_X.js.map} +1 -1
- package/docs/assets/{ImperativeApiRoute-ZdLgDzyA.js → ImperativeApiRoute-BxC-VyUh.js} +2 -2
- package/docs/assets/{ImperativeApiRoute-ZdLgDzyA.js.map → ImperativeApiRoute-BxC-VyUh.js.map} +1 -1
- package/docs/assets/{ImperativeApiRoute-DN4crA5x.js → ImperativeApiRoute-D8HOQfr3.js} +2 -2
- package/docs/assets/{ImperativeApiRoute-DN4crA5x.js.map → ImperativeApiRoute-D8HOQfr3.js.map} +1 -1
- package/docs/assets/List-CwFMf7n1.js +2 -0
- package/docs/assets/List-CwFMf7n1.js.map +1 -0
- package/docs/assets/{LoadingSpinner-DXcA8wXA.js → LoadingSpinner-BMzTPwZo.js} +2 -2
- package/docs/assets/{LoadingSpinner-DXcA8wXA.js.map → LoadingSpinner-BMzTPwZo.js.map} +1 -1
- package/docs/assets/{PageNotFound-I9Ugq07H.js → PageNotFound-kFYcmtEM.js} +2 -2
- package/docs/assets/{PageNotFound-I9Ugq07H.js.map → PageNotFound-kFYcmtEM.js.map} +1 -1
- package/docs/assets/{PlatformRequirementsRoute-Mn45V_j9.js → PlatformRequirementsRoute-D2r4s58b.js} +2 -2
- package/docs/assets/{PlatformRequirementsRoute-Mn45V_j9.js.map → PlatformRequirementsRoute-D2r4s58b.js.map} +1 -1
- package/docs/assets/PropsRoute-B_3n6IE5.js +2 -0
- package/docs/assets/{PropsRoute-BzcsHp2c.js.map → PropsRoute-B_3n6IE5.js.map} +1 -1
- package/docs/assets/PropsRoute-CUL_CRSw.js +2 -0
- package/docs/assets/{PropsRoute-CHeNkGKQ.js.map → PropsRoute-CUL_CRSw.js.map} +1 -1
- package/docs/assets/{RTLGridsRoute-RdjRBOG7.js → RTLGridsRoute-BXZTN5aZ.js} +2 -2
- package/docs/assets/{RTLGridsRoute-RdjRBOG7.js.map → RTLGridsRoute-BXZTN5aZ.js.map} +1 -1
- package/docs/assets/{RenderingGridRoute-bkYAfFEg.js → RenderingGridRoute-DjDJX4pV.js} +2 -2
- package/docs/assets/{RenderingGridRoute-bkYAfFEg.js.map → RenderingGridRoute-DjDJX4pV.js.map} +1 -1
- package/docs/assets/ScratchpadRoute-BvmbZ6RR.js +2 -0
- package/docs/assets/{ScratchpadRoute-B8OO7yyx.js.map → ScratchpadRoute-BvmbZ6RR.js.map} +1 -1
- package/docs/assets/{Select-Dtoy3zH8.js → Select-INFvG4Rz.js} +2 -2
- package/docs/assets/{Select-Dtoy3zH8.js.map → Select-INFvG4Rz.js.map} +1 -1
- package/docs/assets/StickyRowsRoute-D9QBSEk_.js +2 -0
- package/docs/assets/StickyRowsRoute-D9QBSEk_.js.map +1 -0
- package/docs/assets/{SupportRoute-Cy6JXaox.js → SupportRoute-DyO6dv_w.js} +2 -2
- package/docs/assets/{SupportRoute-Cy6JXaox.js.map → SupportRoute-DyO6dv_w.js.map} +1 -1
- package/docs/assets/{TabularDataRoute-EbsuxYEq.js → TabularDataRoute-CH8QvWD7.js} +2 -2
- package/docs/assets/{TabularDataRoute-EbsuxYEq.js.map → TabularDataRoute-CH8QvWD7.js.map} +1 -1
- package/docs/assets/{VariableRowHeightsRoute-Bmh2fNYt.js → VariableRowHeightsRoute--1XN3vDI.js} +2 -2
- package/docs/assets/{VariableRowHeightsRoute-Bmh2fNYt.js.map → VariableRowHeightsRoute--1XN3vDI.js.map} +1 -1
- package/docs/assets/{arePropsEqual-Bhv0L31F.js → arePropsEqual-Czc4-HWX.js} +2 -2
- package/docs/assets/{arePropsEqual-Bhv0L31F.js.map → arePropsEqual-Czc4-HWX.js.map} +1 -1
- package/docs/assets/{index-Dfhz9Ad4.js → index-C6NWGx8D.js} +3 -3
- package/docs/assets/index-C6NWGx8D.js.map +1 -0
- package/docs/assets/index-CTUnf-2d.css +1 -0
- package/docs/assets/{useCitiesByState-_PN38xmv.js → useCitiesByState-rFcDxGxC.js} +2 -2
- package/docs/assets/{useCitiesByState-_PN38xmv.js.map → useCitiesByState-rFcDxGxC.js.map} +1 -1
- package/docs/assets/{useContacts-CDDyJV-g.js → useContacts-Bu0Z6ao9.js} +2 -2
- package/docs/assets/{useContacts-CDDyJV-g.js.map → useContacts-Bu0Z6ao9.js.map} +1 -1
- package/docs/generated/code-snippets/FixedHeightList.json +2 -2
- package/docs/generated/code-snippets/FixedHeightRowComponent.json +2 -2
- package/docs/generated/code-snippets/ListWithStickyRows.json +4 -0
- package/docs/generated/js-docs/Grid.json +631 -0
- package/docs/generated/js-docs/List.json +631 -0
- package/docs/index.html +2 -2
- package/docs/stats.html +1 -1
- package/package.json +2 -1
- package/docs/assets/CellComponent.example-dKVH8ZYc.js +0 -2
- package/docs/assets/ContinueLink-DN1_wnU9.js +0 -2
- package/docs/assets/FixedHeightList-HNBwl6P8.js +0 -2
- package/docs/assets/FixedHeightList-HNBwl6P8.js.map +0 -1
- package/docs/assets/FixedRowHeightsRoute-iwoWadtD.js.map +0 -1
- package/docs/assets/Grid-BnGy9pmI.js +0 -2
- package/docs/assets/Grid-BnGy9pmI.js.map +0 -1
- package/docs/assets/List-CsalXuo6.js +0 -2
- package/docs/assets/List-CsalXuo6.js.map +0 -1
- package/docs/assets/PropsRoute-BzcsHp2c.js +0 -2
- package/docs/assets/PropsRoute-CHeNkGKQ.js +0 -2
- package/docs/assets/ScratchpadRoute-B8OO7yyx.js +0 -2
- package/docs/assets/index-DEYagqsv.css +0 -1
- package/docs/assets/index-Dfhz9Ad4.js.map +0 -1
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "react-window",
|
|
3
|
-
"version": "2.0.2-alpha.
|
|
3
|
+
"version": "2.0.2-alpha.1",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"author": "Brian Vaughn <brian.david.vaughn@gmail.com> (https://github.com/bvaughn/)",
|
|
6
6
|
"contributors": [
|
|
@@ -67,6 +67,7 @@
|
|
|
67
67
|
"@types/react-dom": "^19.1.6",
|
|
68
68
|
"@vitejs/plugin-react-swc": "^3.10.2",
|
|
69
69
|
"clsx": "^2.1.1",
|
|
70
|
+
"csstype": "^3.1.3",
|
|
70
71
|
"eslint": "^9.30.1",
|
|
71
72
|
"eslint-plugin-react-hooks": "^5.2.0",
|
|
72
73
|
"eslint-plugin-react-refresh": "^0.4.20",
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
import{j as s}from"./index-Dfhz9Ad4.js";import{i as t}from"./useContacts-CDDyJV-g.js";function n({contacts:n,columnIndex:e,rowIndex:o,style:r}){const c=n[o][t(e)];return s.jsx("div",{className:"truncate",style:r,children:c})}export{n as C};
|
|
2
|
-
//# sourceMappingURL=CellComponent.example-dKVH8ZYc.js.map
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
const s={javaScript:'<div style="min-height: 1rem; padding-left: 2ch; text-indent: -2ch;"><span class="tok-keyword">import</span><span class=""> </span><span class="tok-punctuation">{</span><span class=""> </span><span class="tok-variableName tok-definition">List</span><span class=""> </span><span class="tok-punctuation">}</span><span class=""> </span><span class="tok-keyword">from</span><span class=""> </span><span class="tok-string">"react-window"</span><span class="tok-punctuation">;</span><span class=""></span></div>\n<div style="min-height: 1rem; padding-left: 2ch; text-indent: -2ch;"><span class=""></span></div>\n<div style="min-height: 1rem; padding-left: 2ch; text-indent: -2ch;"><span class=""></span><span class="tok-keyword">function</span><span class=""> </span><span class="tok-variableName tok-definition">Example</span><span class="tok-punctuation">(</span><span class="tok-punctuation">{</span><span class=""> </span><span class="tok-propertyName">names</span><span class=""> </span><span class="tok-punctuation">}</span><span class="tok-punctuation">)</span><span class=""> </span><span class="tok-punctuation">{</span><span class=""></span></div>\n<div style="min-height: 1rem; padding-left: 4ch; text-indent: -2ch;"><span class=""></span><span class="tok-keyword">return</span><span class=""> </span><span class="tok-punctuation">(</span><span class=""></span></div>\n<div style="min-height: 1rem; padding-left: 6ch; text-indent: -2ch;"><span class=""></span><span class="tok-punctuation"><</span><span class="tok-typeName">List</span><span class=""></span></div>\n<div style="min-height: 1rem; padding-left: 8ch; text-indent: -2ch;"><span class=""></span><span class="tok-propertyName">rowComponent</span><span class="tok-operator">=</span><span class="tok-punctuation">{</span><span class="tok-variableName">RowComponent</span><span class="tok-punctuation">}</span><span class=""></span></div>\n<div style="min-height: 1rem; padding-left: 8ch; text-indent: -2ch;"><span class=""></span><span class="tok-propertyName">rowCount</span><span class="tok-operator">=</span><span class="tok-punctuation">{</span><span class="tok-variableName">names</span><span class="tok-operator">.</span><span class="tok-propertyName">length</span><span class="tok-punctuation">}</span><span class=""></span></div>\n<div style="min-height: 1rem; padding-left: 8ch; text-indent: -2ch;"><span class=""></span><span class="tok-propertyName">rowHeight</span><span class="tok-operator">=</span><span class="tok-punctuation">{</span><span class="tok-number">25</span><span class="tok-punctuation">}</span><span class=""></span></div>\n<div style="min-height: 1rem; padding-left: 8ch; text-indent: -2ch;"><span class=""></span><span class="tok-propertyName">rowProps</span><span class="tok-operator">=</span><span class="tok-punctuation">{</span><span class="tok-punctuation">{</span><span class=""> </span><span class="tok-propertyName tok-definition">names</span><span class=""> </span><span class="tok-punctuation">}</span><span class="tok-punctuation">}</span><span class=""></span></div>\n<div style="min-height: 1rem; padding-left: 6ch; text-indent: -2ch;"><span class=""></span><span class="tok-punctuation">/></span><span class=""></span></div>\n<div style="min-height: 1rem; padding-left: 4ch; text-indent: -2ch;"><span class=""></span><span class="tok-punctuation">)</span><span class="tok-punctuation">;</span><span class=""></span></div>\n<div style="min-height: 1rem; padding-left: 2ch; text-indent: -2ch;"><span class=""></span><span class="tok-punctuation">}</span></div>',typeScript:'<div style="min-height: 1rem; padding-left: 2ch; text-indent: -2ch;"><span class="tok-keyword">import</span><span class=""> </span><span class="tok-punctuation">{</span><span class=""> </span><span class="tok-variableName tok-definition">List</span><span class=""> </span><span class="tok-punctuation">}</span><span class=""> </span><span class="tok-keyword">from</span><span class=""> </span><span class="tok-string">"react-window"</span><span class="tok-punctuation">;</span><span class=""></span></div>\n<div style="min-height: 1rem; padding-left: 2ch; text-indent: -2ch;"><span class=""></span></div>\n<div style="min-height: 1rem; padding-left: 2ch; text-indent: -2ch;"><span class=""></span><span class="tok-keyword">function</span><span class=""> </span><span class="tok-variableName tok-definition">Example</span><span class="tok-punctuation">(</span><span class="tok-punctuation">{</span><span class=""> </span><span class="tok-propertyName">names</span><span class=""> </span><span class="tok-punctuation">}</span><span class="tok-punctuation">:</span><span class=""> </span><span class="tok-punctuation">{</span><span class=""> </span><span class="tok-propertyName tok-definition">names</span><span class="tok-punctuation">:</span><span class=""> </span><span class="tok-typeName">string</span><span class="tok-punctuation">[</span><span class="tok-punctuation">]</span><span class=""> </span><span class="tok-punctuation">}</span><span class="tok-punctuation">)</span><span class=""> </span><span class="tok-punctuation">{</span><span class=""></span></div>\n<div style="min-height: 1rem; padding-left: 4ch; text-indent: -2ch;"><span class=""></span><span class="tok-keyword">return</span><span class=""> </span><span class="tok-punctuation">(</span><span class=""></span></div>\n<div style="min-height: 1rem; padding-left: 6ch; text-indent: -2ch;"><span class=""></span><span class="tok-punctuation"><</span><span class="tok-typeName">List</span><span class=""></span></div>\n<div style="min-height: 1rem; padding-left: 8ch; text-indent: -2ch;"><span class=""></span><span class="tok-propertyName">rowComponent</span><span class="tok-operator">=</span><span class="tok-punctuation">{</span><span class="tok-variableName">RowComponent</span><span class="tok-punctuation">}</span><span class=""></span></div>\n<div style="min-height: 1rem; padding-left: 8ch; text-indent: -2ch;"><span class=""></span><span class="tok-propertyName">rowCount</span><span class="tok-operator">=</span><span class="tok-punctuation">{</span><span class="tok-variableName">names</span><span class="tok-operator">.</span><span class="tok-propertyName">length</span><span class="tok-punctuation">}</span><span class=""></span></div>\n<div style="min-height: 1rem; padding-left: 8ch; text-indent: -2ch;"><span class=""></span><span class="tok-propertyName">rowHeight</span><span class="tok-operator">=</span><span class="tok-punctuation">{</span><span class="tok-number">25</span><span class="tok-punctuation">}</span><span class=""></span></div>\n<div style="min-height: 1rem; padding-left: 8ch; text-indent: -2ch;"><span class=""></span><span class="tok-propertyName">rowProps</span><span class="tok-operator">=</span><span class="tok-punctuation">{</span><span class="tok-punctuation">{</span><span class=""> </span><span class="tok-propertyName tok-definition">names</span><span class=""> </span><span class="tok-punctuation">}</span><span class="tok-punctuation">}</span><span class=""></span></div>\n<div style="min-height: 1rem; padding-left: 6ch; text-indent: -2ch;"><span class=""></span><span class="tok-punctuation">/></span><span class=""></span></div>\n<div style="min-height: 1rem; padding-left: 4ch; text-indent: -2ch;"><span class=""></span><span class="tok-punctuation">)</span><span class="tok-punctuation">;</span><span class=""></span></div>\n<div style="min-height: 1rem; padding-left: 2ch; text-indent: -2ch;"><span class=""></span><span class="tok-punctuation">}</span></div>'};export{s as c};
|
|
2
|
-
//# sourceMappingURL=FixedHeightList-HNBwl6P8.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"FixedHeightList-HNBwl6P8.js","sources":[],"sourcesContent":[],"names":[],"mappings":""}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"FixedRowHeightsRoute-iwoWadtD.js","sources":["../../src/routes/list/examples/FixedHeightRowComponent.example.tsx","../../src/routes/list/examples/FixedHeightList.example.tsx","../../src/routes/list/FixedRowHeightsRoute.tsx"],"sourcesContent":["import { type RowComponentProps } from \"react-window\";\n\nfunction RowComponent({\n index,\n names,\n style\n}: RowComponentProps<{\n names: string[];\n}>) {\n return (\n <div className=\"flex items-center justify-between\" style={style}>\n {names[index]}\n <div className=\"text-slate-500 text-xs\">{`${index + 1} of ${names.length}`}</div>\n </div>\n );\n}\n\n// <end>\n\nexport { RowComponent };\n","import { RowComponent } from \"./FixedHeightRowComponent.example\";\n\n// <begin>\n\nimport { List } from \"react-window\";\n\nfunction Example({ names }: { names: string[] }) {\n return (\n <List\n rowComponent={RowComponent}\n rowCount={names.length}\n rowHeight={25}\n rowProps={{ names }}\n />\n );\n}\n\n// <end>\n\nexport { Example };\n","import json from \"../../../public/data/names.json\";\nimport FixedHeightListMarkdown from \"../../../public/generated/code-snippets/FixedHeightList.json\";\nimport FixedHeightRowComponentMarkdown from \"../../../public/generated/code-snippets/FixedHeightRowComponent.json\";\nimport { Block } from \"../../components/Block\";\nimport { Box } from \"../../components/Box\";\nimport { Callout } from \"../../components/Callout\";\nimport { FormattedCode } from \"../../components/code/FormattedCode\";\nimport { ContinueLink } from \"../../components/ContinueLink\";\nimport { ExternalLink } from \"../../components/ExternalLink\";\nimport { Header } from \"../../components/Header\";\nimport { Example } from \"./examples/FixedHeightList.example\";\n\nexport default function FixedRowHeightsRoute() {\n return (\n <Box direction=\"column\" gap={4}>\n <Header section=\"Lists\" title=\"Fixed row heights\" />\n <div>\n The simplest type of list to render is one with fixed row heights.\n </div>\n <Block className=\"h-50\" data-focus-within=\"bold\">\n <Example names={json} />\n </Block>\n <div>\n To render this type of list, you need to specify how many rows it\n contains (<code>rowCount</code>), which component should render rows (\n <code>rowComponent</code>), and the height of each row (\n <code>rowHeight</code>):\n </div>\n <FormattedCode markdown={FixedHeightListMarkdown} />\n <div>\n The <code>rowProps</code> object can also be used to share between\n components. Values passed in <code>rowProps</code> will also be passed\n as props to the row component:\n </div>\n <FormattedCode markdown={FixedHeightRowComponentMarkdown} />\n <Callout intent=\"warning\">\n <Box direction=\"column\" gap={4}>\n <div>\n Lists require vertical space to render rows. Typically the{\" \"}\n <ExternalLink href=\"https://developer.mozilla.org/en-US/docs/Web/API/ResizeObserver\">\n ResizeObserver\n </ExternalLink>{\" \"}\n API is used to determine how much space there is available within\n the parent DOM element.\n </div>\n <div>\n If an explicit height is specified (in pixels) using the{\" \"}\n <code>style</code> prop, <code>ResizeObserver</code> will not be\n used.\n </div>\n </Box>\n </Callout>\n <ContinueLink\n to=\"/list/variable-row-height\"\n title=\"variable row heights\"\n />\n </Box>\n );\n}\n"],"names":["RowComponent","index","names","style","jsxs","className","children","jsx","length","Example","List","rowComponent","rowCount","rowHeight","rowProps","FixedRowHeightsRoute","Box","direction","gap","Header","section","title","Block","json","FormattedCode","markdown","FixedHeightListMarkdown","FixedHeightRowComponentMarkdown","Callout","intent","ExternalLink","href","ContinueLink","to"],"mappings":"g6kBAEA,SAASA,GAAaC,MACpBA,EAAAC,MACAA,EAAAC,MACAA,IAIA,SACEC,KAAC,MAAA,CAAIC,UAAU,oCAAoCF,QAChDG,SAAA,CAAAJ,EAAMD,GACPM,EAAAA,IAAC,MAAA,CAAIF,UAAU,yBAA0BC,SAAA,GAAGL,EAAQ,QAAQC,EAAMM,aAGxE,CCTA,SAASC,GAAQP,MAAEA,IACjB,OACEK,EAAAA,IAACG,EAAA,CACCC,aAAcX,EACdY,SAAUV,EAAMM,OAChBK,UAAW,GACXC,SAAU,CAAEZ,UAGlB,CCHA,SAAwBa,IACtB,OACEX,EAAAA,KAACY,EAAA,CAAIC,UAAU,SAASC,IAAK,EAC3BZ,SAAA,CAAAC,EAAAA,IAACY,EAAA,CAAOC,QAAQ,QAAQC,MAAM,wBAC9Bd,IAAC,OAAID,SAAA,yEAGLC,IAACe,EAAA,CAAMjB,UAAU,OAAO,oBAAkB,OACxCC,SAAAC,EAAAA,IAACE,EAAA,CAAQP,MAAOqB,aAEjB,MAAA,CAAIjB,SAAA,CAAA,iFAEOC,IAAC,QAAKD,SAAA,aAAe,4CAC/BC,IAAC,QAAKD,SAAA,iBAAmB,oCACzBC,IAAC,QAAKD,SAAA,cAAgB,UAExBC,IAACiB,EAAA,CAAcC,SAAUC,WACxB,MAAA,CAAIpB,SAAA,CAAA,SACCC,IAAC,QAAKD,SAAA,aAAe,4EACIC,IAAC,QAAKD,SAAA,aAAe,2DAGpDC,IAACiB,EAAA,CAAcC,SAAUE,IACzBpB,EAAAA,IAACqB,GAAQC,OAAO,UACdvB,gBAACU,EAAA,CAAIC,UAAU,SAASC,IAAK,EAC3BZ,SAAA,CAAAF,OAAC,MAAA,CAAIE,SAAA,CAAA,6DACwD,IAC3DC,EAAAA,IAACuB,EAAA,CAAaC,KAAK,kEAAkEzB,SAAA,mBAErE,IAAI,sGAIrB,MAAA,CAAIA,SAAA,CAAA,2DACsD,MACzDC,IAAC,QAAKD,SAAA,UAAY,YAAOC,IAAC,QAAKD,SAAA,mBAAqB,6BAK1DC,EAAAA,IAACyB,EAAA,CACCC,GAAG,4BACHZ,MAAM,2BAId"}
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
import{r as e,j as o}from"./index-Dfhz9Ad4.js";import{u as t,a as n,b as l}from"./arePropsEqual-Bhv0L31F.js";function r({cellComponent:r,cellProps:i,className:s,columnCount:a,columnWidth:c,defaultHeight:d=0,defaultWidth:u=0,dir:f,gridRef:m,onCellsRendered:x,onResize:h,overscanCount:p=3,rowCount:g,rowHeight:v,style:w,...I}){const S=t(i),C=e.useMemo(()=>e.memo(r,n),[r]),[z,T]=e.useState(null),b=function(o,t){const[n,l]=e.useState("rtl"===t);return e.useLayoutEffect(()=>{o&&(t||l(function(e){let o=e;for(;o;){if(o.dir)return"rtl"===o.dir;o=o.parentElement}return!1}(o)))},[t,o]),n}(z,f),{getCellBounds:y,getEstimatedSize:E,startIndex:O,scrollToIndex:R,stopIndex:j}=l({containerElement:z,defaultContainerSize:u,direction:"horizontal",isRtl:b,itemCount:a,itemProps:S,itemSize:c,onResize:h,overscanCount:p}),{getCellBounds:H,getEstimatedSize:P,startIndex:A,scrollToIndex:L,stopIndex:W}=l({containerElement:z,defaultContainerSize:d,direction:"vertical",itemCount:g,itemProps:S,itemSize:v,onResize:h,overscanCount:p});e.useImperativeHandle(m,()=>({get element(){return z},scrollToCell({behavior:e="auto",columnAlign:o="auto",columnIndex:t,rowAlign:n="auto",rowIndex:l}){const r=R({align:o,containerScrollOffset:z?.scrollLeft??0,index:t}),i=L({align:n,containerScrollOffset:z?.scrollTop??0,index:l});"function"==typeof z?.scrollTo&&z.scrollTo({behavior:e,left:r,top:i})},scrollToColumn({align:e="auto",behavior:o="auto",index:t}){const n=R({align:e,containerScrollOffset:z?.scrollLeft??0,index:t});"function"==typeof z?.scrollTo&&z.scrollTo({behavior:o,left:n})},scrollToRow({align:e="auto",behavior:o="auto",index:t}){const n=L({align:e,containerScrollOffset:z?.scrollTop??0,index:t});"function"==typeof z?.scrollTo&&z.scrollTo({behavior:o,top:n})}}),[z,R,L]),e.useEffect(()=>{O>=0&&j>=0&&A>=0&&W>=0&&x&&x({columnStartIndex:O,columnStopIndex:j,rowStartIndex:A,rowStopIndex:W})},[x,O,j,A,W]);const B=e.useMemo(()=>{const t=[];if(a>0&&g>0)for(let n=A;n<=W;n++){const l=H(n),r=[];for(let o=O;o<=j;o++){const t=y(o);r.push(e.createElement(C,{...S,ariaAttributes:{"aria-colindex":o+1,role:"gridcell"},columnIndex:o,key:o,rowIndex:n,style:{position:"absolute",left:b?void 0:0,right:b?0:void 0,transform:`translate(${b?-t.scrollOffset:t.scrollOffset}px, ${l.scrollOffset}px)`,height:g>1?l.size:"100%",width:t.size}}))}t.push(o.jsx("div",{role:"row","aria-rowindex":n+1,children:r},n))}return t},[C,S,a,O,j,y,H,b,g,A,W]);return o.jsxs("div",{"aria-colcount":a,"aria-rowcount":g,role:"grid",...I,className:s,dir:f,ref:T,style:{position:"relative",width:"100%",height:"100%",maxHeight:"100%",maxWidth:"100%",flexGrow:1,overflow:"auto",...w},children:[B,o.jsx("div",{"aria-hidden":!0,style:{height:P(),width:E(),zIndex:-1}})]})}export{r as G};
|
|
2
|
-
//# sourceMappingURL=Grid-BnGy9pmI.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"Grid-BnGy9pmI.js","sources":["../../lib/components/grid/Grid.tsx","../../lib/core/useIsRtl.ts","../../lib/utils/isRtl.ts"],"sourcesContent":["import {\n memo,\n useEffect,\n useImperativeHandle,\n useMemo,\n useState,\n type ReactNode\n} from \"react\";\nimport { useIsRtl } from \"../../core/useIsRtl\";\nimport { useVirtualizer } from \"../../core/useVirtualizer\";\nimport { useMemoizedObject } from \"../../hooks/useMemoizedObject\";\nimport type { Align } from \"../../types\";\nimport { arePropsEqual } from \"../../utils/arePropsEqual\";\nimport type { GridProps } from \"./types\";\n\nexport function Grid<CellProps extends object>({\n cellComponent: CellComponentProp,\n cellProps: cellPropsUnstable,\n className,\n columnCount,\n columnWidth,\n defaultHeight = 0,\n defaultWidth = 0,\n dir,\n gridRef,\n onCellsRendered,\n onResize,\n overscanCount = 3,\n rowCount,\n rowHeight,\n style,\n ...rest\n}: GridProps<CellProps>) {\n const cellProps = useMemoizedObject(cellPropsUnstable);\n const CellComponent = useMemo(\n () => memo(CellComponentProp, arePropsEqual),\n [CellComponentProp]\n );\n\n const [element, setElement] = useState<HTMLDivElement | null>(null);\n\n const isRtl = useIsRtl(element, dir);\n\n const {\n getCellBounds: getColumnBounds,\n getEstimatedSize: getEstimatedWidth,\n startIndex: columnStartIndex,\n scrollToIndex: scrollToColumnIndex,\n stopIndex: columnStopIndex\n } = useVirtualizer({\n containerElement: element,\n defaultContainerSize: defaultWidth,\n direction: \"horizontal\",\n isRtl,\n itemCount: columnCount,\n itemProps: cellProps,\n itemSize: columnWidth,\n onResize,\n overscanCount\n });\n\n const {\n getCellBounds: getRowBounds,\n getEstimatedSize: getEstimatedHeight,\n startIndex: rowStartIndex,\n scrollToIndex: scrollToRowIndex,\n stopIndex: rowStopIndex\n } = useVirtualizer({\n containerElement: element,\n defaultContainerSize: defaultHeight,\n direction: \"vertical\",\n itemCount: rowCount,\n itemProps: cellProps,\n itemSize: rowHeight,\n onResize,\n overscanCount\n });\n\n useImperativeHandle(\n gridRef,\n () => ({\n get element() {\n return element;\n },\n\n scrollToCell({\n behavior = \"auto\",\n columnAlign = \"auto\",\n columnIndex,\n rowAlign = \"auto\",\n rowIndex\n }: {\n behavior?: ScrollBehavior;\n columnAlign?: Align;\n columnIndex: number;\n rowAlign?: Align;\n rowIndex: number;\n }) {\n const left = scrollToColumnIndex({\n align: columnAlign,\n containerScrollOffset: element?.scrollLeft ?? 0,\n index: columnIndex\n });\n const top = scrollToRowIndex({\n align: rowAlign,\n containerScrollOffset: element?.scrollTop ?? 0,\n index: rowIndex\n });\n\n if (typeof element?.scrollTo === \"function\") {\n element.scrollTo({\n behavior,\n left,\n top\n });\n }\n },\n\n scrollToColumn({\n align = \"auto\",\n behavior = \"auto\",\n index\n }: {\n align?: Align;\n behavior?: ScrollBehavior;\n index: number;\n }) {\n const left = scrollToColumnIndex({\n align,\n containerScrollOffset: element?.scrollLeft ?? 0,\n index\n });\n\n if (typeof element?.scrollTo === \"function\") {\n element.scrollTo({\n behavior,\n left\n });\n }\n },\n\n scrollToRow({\n align = \"auto\",\n behavior = \"auto\",\n index\n }: {\n align?: Align;\n behavior?: ScrollBehavior;\n index: number;\n }) {\n const top = scrollToRowIndex({\n align,\n containerScrollOffset: element?.scrollTop ?? 0,\n index\n });\n\n if (typeof element?.scrollTo === \"function\") {\n element.scrollTo({\n behavior,\n top\n });\n }\n }\n }),\n [element, scrollToColumnIndex, scrollToRowIndex]\n );\n\n useEffect(() => {\n if (\n columnStartIndex >= 0 &&\n columnStopIndex >= 0 &&\n rowStartIndex >= 0 &&\n rowStopIndex >= 0 &&\n onCellsRendered\n ) {\n onCellsRendered({\n columnStartIndex,\n columnStopIndex,\n rowStartIndex,\n rowStopIndex\n });\n }\n }, [\n onCellsRendered,\n columnStartIndex,\n columnStopIndex,\n rowStartIndex,\n rowStopIndex\n ]);\n\n const cells = useMemo(() => {\n const children: ReactNode[] = [];\n if (columnCount > 0 && rowCount > 0) {\n for (let rowIndex = rowStartIndex; rowIndex <= rowStopIndex; rowIndex++) {\n const rowBounds = getRowBounds(rowIndex);\n\n const columns: ReactNode[] = [];\n\n for (\n let columnIndex = columnStartIndex;\n columnIndex <= columnStopIndex;\n columnIndex++\n ) {\n const columnBounds = getColumnBounds(columnIndex);\n\n columns.push(\n <CellComponent\n {...(cellProps as CellProps)}\n ariaAttributes={{\n \"aria-colindex\": columnIndex + 1,\n role: \"gridcell\"\n }}\n columnIndex={columnIndex}\n key={columnIndex}\n rowIndex={rowIndex}\n style={{\n position: \"absolute\",\n left: isRtl ? undefined : 0,\n right: isRtl ? 0 : undefined,\n transform: `translate(${isRtl ? -columnBounds.scrollOffset : columnBounds.scrollOffset}px, ${rowBounds.scrollOffset}px)`,\n height: rowCount > 1 ? rowBounds.size : \"100%\",\n width: columnBounds.size\n }}\n />\n );\n }\n\n children.push(\n <div key={rowIndex} role=\"row\" aria-rowindex={rowIndex + 1}>\n {columns}\n </div>\n );\n }\n }\n return children;\n }, [\n CellComponent,\n cellProps,\n columnCount,\n columnStartIndex,\n columnStopIndex,\n getColumnBounds,\n getRowBounds,\n isRtl,\n rowCount,\n rowStartIndex,\n rowStopIndex\n ]);\n\n return (\n <div\n aria-colcount={columnCount}\n aria-rowcount={rowCount}\n role=\"grid\"\n {...rest}\n className={className}\n dir={dir}\n ref={setElement}\n style={{\n position: \"relative\",\n width: \"100%\",\n height: \"100%\",\n maxHeight: \"100%\",\n maxWidth: \"100%\",\n flexGrow: 1,\n overflow: \"auto\",\n ...style\n }}\n >\n {cells}\n\n <div\n aria-hidden\n style={{\n height: getEstimatedHeight(),\n width: getEstimatedWidth(),\n zIndex: -1\n }}\n ></div>\n </div>\n );\n}\n","import { useLayoutEffect, useState, type HTMLAttributes } from \"react\";\nimport { isRtl } from \"../utils/isRtl\";\n\nexport function useIsRtl(\n element: HTMLElement | null,\n dir: HTMLAttributes<HTMLElement>[\"dir\"]\n) {\n const [value, setValue] = useState(dir === \"rtl\");\n\n useLayoutEffect(() => {\n if (element) {\n if (!dir) {\n setValue(isRtl(element));\n }\n }\n }, [dir, element]);\n\n return value;\n}\n","export function isRtl(element: HTMLElement) {\n let currentElement: HTMLElement | null = element;\n while (currentElement) {\n if (currentElement.dir) {\n return currentElement.dir === \"rtl\";\n }\n\n currentElement = currentElement.parentElement;\n }\n\n return false;\n}\n"],"names":["Grid","cellComponent","CellComponentProp","cellProps","cellPropsUnstable","className","columnCount","columnWidth","defaultHeight","defaultWidth","dir","gridRef","onCellsRendered","onResize","overscanCount","rowCount","rowHeight","style","rest","useMemoizedObject","CellComponent","useMemo","memo","arePropsEqual","element","setElement","useState","isRtl","value","setValue","useLayoutEffect","currentElement","parentElement","useIsRtl","getCellBounds","getColumnBounds","getEstimatedSize","getEstimatedWidth","startIndex","columnStartIndex","scrollToIndex","scrollToColumnIndex","stopIndex","columnStopIndex","useVirtualizer","containerElement","defaultContainerSize","direction","itemCount","itemProps","itemSize","getRowBounds","getEstimatedHeight","rowStartIndex","scrollToRowIndex","rowStopIndex","useImperativeHandle","scrollToCell","behavior","columnAlign","columnIndex","rowAlign","rowIndex","left","align","containerScrollOffset","scrollLeft","index","top","scrollTop","scrollTo","scrollToColumn","scrollToRow","useEffect","cells","children","rowBounds","columns","columnBounds","push","createElement","ariaAttributes","role","key","position","right","transform","scrollOffset","height","size","width","jsx","jsxs","ref","maxHeight","maxWidth","flexGrow","overflow","zIndex"],"mappings":"6GAeO,SAASA,GACdC,cAAeC,EACfC,UAAWC,EAAAC,UACXA,EAAAC,YACAA,EAAAC,YACAA,EAAAC,cACAA,EAAgB,EAAAC,aAChBA,EAAe,EAAAC,IACfA,EAAAC,QACAA,EAAAC,gBACAA,EAAAC,SACAA,EAAAC,cACAA,EAAgB,EAAAC,SAChBA,EAAAC,UACAA,EAAAC,MACAA,KACGC,IAEH,MAAMf,EAAYgB,EAAkBf,GAC9BgB,EAAgBC,EAAAA,QACpB,IAAMC,EAAAA,KAAKpB,EAAmBqB,GAC9B,CAACrB,KAGIsB,EAASC,GAAcC,EAAAA,SAAgC,MAExDC,ECtCD,SACLH,EACAd,GAEA,MAAOkB,EAAOC,GAAYH,EAAAA,SAAiB,QAARhB,GAUnC,OARAoB,EAAAA,gBAAgB,KACVN,IACGd,GACHmB,ECZD,SAAeL,GACpB,IAAIO,EAAqCP,EACzC,KAAOO,GAAgB,CACrB,GAAIA,EAAerB,IACjB,MAA8B,QAAvBqB,EAAerB,IAGxBqB,EAAiBA,EAAeC,aAClC,CAEA,OAAO,CACT,CDCiBL,CAAMH,MAGlB,CAACd,EAAKc,IAEFI,CACT,CDuBgBK,CAAST,EAASd,IAG9BwB,cAAeC,EACfC,iBAAkBC,EAClBC,WAAYC,EACZC,cAAeC,EACfC,UAAWC,GACTC,EAAe,CACjBC,iBAAkBrB,EAClBsB,qBAAsBrC,EACtBsC,UAAW,aACXpB,MAAAA,EACAqB,UAAW1C,EACX2C,UAAW9C,EACX+C,SAAU3C,EACVM,WACAC,mBAIAoB,cAAeiB,EACff,iBAAkBgB,EAClBd,WAAYe,EACZb,cAAec,EACfZ,UAAWa,GACTX,EAAe,CACjBC,iBAAkBrB,EAClBsB,qBAAsBtC,EACtBuC,UAAW,WACXC,UAAWjC,EACXkC,UAAW9C,EACX+C,SAAUlC,EACVH,WACAC,kBAGF0C,EAAAA,oBACE7C,EACA,KAAA,CACE,WAAIa,GACF,OAAOA,CACT,EAEA,YAAAiC,EAAaC,SACXA,EAAW,OAAAC,YACXA,EAAc,OAAAC,YACdA,EAAAC,SACAA,EAAW,OAAAC,SACXA,IAQA,MAAMC,EAAOtB,EAAoB,CAC/BuB,MAAOL,EACPM,sBAAuBzC,GAAS0C,YAAc,EAC9CC,MAAOP,IAEHQ,EAAMd,EAAiB,CAC3BU,MAAOH,EACPI,sBAAuBzC,GAAS6C,WAAa,EAC7CF,MAAOL,IAGwB,mBAAtBtC,GAAS8C,UAClB9C,EAAQ8C,SAAS,CACfZ,WACAK,OACAK,OAGN,EAEA,cAAAG,EAAeP,MACbA,EAAQ,OAAAN,SACRA,EAAW,OAAAS,MACXA,IAMA,MAAMJ,EAAOtB,EAAoB,CAC/BuB,QACAC,sBAAuBzC,GAAS0C,YAAc,EAC9CC,UAG+B,mBAAtB3C,GAAS8C,UAClB9C,EAAQ8C,SAAS,CACfZ,WACAK,QAGN,EAEA,WAAAS,EAAYR,MACVA,EAAQ,OAAAN,SACRA,EAAW,OAAAS,MACXA,IAMA,MAAMC,EAAMd,EAAiB,CAC3BU,QACAC,sBAAuBzC,GAAS6C,WAAa,EAC7CF,UAG+B,mBAAtB3C,GAAS8C,UAClB9C,EAAQ8C,SAAS,CACfZ,WACAU,OAGN,IAEF,CAAC5C,EAASiB,EAAqBa,IAGjCmB,EAAAA,UAAU,KAENlC,GAAoB,GACpBI,GAAmB,GACnBU,GAAiB,GACjBE,GAAgB,GAChB3C,GAEAA,EAAgB,CACd2B,mBACAI,kBACAU,gBACAE,kBAGH,CACD3C,EACA2B,EACAI,EACAU,EACAE,IAGF,MAAMmB,EAAQrD,EAAAA,QAAQ,KACpB,MAAMsD,EAAwB,GAC9B,GAAIrE,EAAc,GAAKS,EAAW,EAChC,IAAA,IAAS+C,EAAWT,EAAeS,GAAYP,EAAcO,IAAY,CACvE,MAAMc,EAAYzB,EAAaW,GAEzBe,EAAuB,GAE7B,IAAA,IACMjB,EAAcrB,EAClBqB,GAAejB,EACfiB,IACA,CACA,MAAMkB,EAAe3C,EAAgByB,GAErCiB,EAAQE,KACNC,EAAAA,cAAC5D,EAAA,IACMjB,EACL8E,eAAgB,CACd,gBAAiBrB,EAAc,EAC/BsB,KAAM,YAERtB,cACAuB,IAAKvB,EACLE,WACA7C,MAAO,CACLmE,SAAU,WACVrB,KAAMpC,OAAQ,EAAY,EAC1B0D,MAAO1D,EAAQ,OAAI,EACnB2D,UAAW,aAAa3D,GAASmD,EAAaS,aAAeT,EAAaS,mBAAmBX,EAAUW,kBACvGC,OAAQzE,EAAW,EAAI6D,EAAUa,KAAO,OACxCC,MAAOZ,EAAaW,QAI5B,CAEAd,EAASI,KACPY,EAAAA,IAAC,OAAmBT,KAAK,MAAM,gBAAepB,EAAW,EACtDa,YADOb,GAId,CAEF,OAAOa,GACN,CACDvD,EACAjB,EACAG,EACAiC,EACAI,EACAR,EACAgB,EACAxB,EACAZ,EACAsC,EACAE,IAGF,OACEqC,EAAAA,KAAC,MAAA,CACC,gBAAetF,EACf,gBAAeS,EACfmE,KAAK,UACDhE,EACJb,YACAK,MACAmF,IAAKpE,EACLR,MAAO,CACLmE,SAAU,WACVM,MAAO,OACPF,OAAQ,OACRM,UAAW,OACXC,SAAU,OACVC,SAAU,EACVC,SAAU,UACPhF,GAGJ0D,SAAA,CAAAD,EAEDiB,EAAAA,IAAC,MAAA,CACC,eAAW,EACX1E,MAAO,CACLuE,OAAQpC,IACRsC,MAAOrD,IACP6D,QAAQ,OAKlB"}
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
import{r as e,j as t}from"./index-Dfhz9Ad4.js";import{u as o,a as s,b as i}from"./arePropsEqual-Bhv0L31F.js";function r({className:r,defaultHeight:n=0,listRef:a,onResize:l,onRowsRendered:u,overscanCount:c=3,rowComponent:d,rowCount:m,rowHeight:f,rowProps:p,style:x,...h}){const g=o(p),v=e.useMemo(()=>e.memo(d,s),[d]),[w,z]=e.useState(null),{getCellBounds:C,getEstimatedSize:I,scrollToIndex:y,startIndex:R,stopIndex:b}=i({containerElement:w,defaultContainerSize:n,direction:"vertical",itemCount:m,itemProps:g,itemSize:f,onResize:l,overscanCount:c});e.useImperativeHandle(a,()=>({get element(){return w},scrollToRow({align:e="auto",behavior:t="auto",index:o}){const s=y({align:e,containerScrollOffset:w?.scrollTop??0,index:o});"function"==typeof w?.scrollTo&&w.scrollTo({behavior:t,top:s})}}),[w,y]),e.useEffect(()=>{R>=0&&b>=0&&u&&u({startIndex:R,stopIndex:b})},[u,R,b]);const j=e.useMemo(()=>{const t=[];if(m>0)for(let o=R;o<=b;o++){const s=C(o);t.push(e.createElement(v,{...g,ariaAttributes:{"aria-posinset":o+1,"aria-setsize":m,role:"listitem"},key:o,index:o,style:{position:"absolute",left:0,transform:`translateY(${s.scrollOffset}px)`,height:s.size,width:"100%"}}))}return t},[v,C,m,g,R,b]);return t.jsxs("div",{role:"list",...h,className:r,ref:z,style:{position:"relative",maxHeight:"100%",flexGrow:1,overflowY:"auto",...x},children:[j,t.jsx("div",{"aria-hidden":!0,style:{height:I(),width:"100%",zIndex:-1}})]})}export{r as L};
|
|
2
|
-
//# sourceMappingURL=List-CsalXuo6.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"List-CsalXuo6.js","sources":["../../lib/components/list/List.tsx"],"sourcesContent":["import {\n memo,\n useEffect,\n useImperativeHandle,\n useMemo,\n useState,\n type ReactNode\n} from \"react\";\nimport { useVirtualizer } from \"../../core/useVirtualizer\";\nimport { useMemoizedObject } from \"../../hooks/useMemoizedObject\";\nimport type { Align } from \"../../types\";\nimport { arePropsEqual } from \"../../utils/arePropsEqual\";\nimport type { ListProps } from \"./types\";\n\nexport function List<RowProps extends object>({\n className,\n defaultHeight = 0,\n listRef,\n onResize,\n onRowsRendered,\n overscanCount = 3,\n rowComponent: RowComponentProp,\n rowCount,\n rowHeight,\n rowProps: rowPropsUnstable,\n style,\n ...rest\n}: ListProps<RowProps>) {\n const rowProps = useMemoizedObject(rowPropsUnstable);\n const RowComponent = useMemo(\n () => memo(RowComponentProp, arePropsEqual),\n [RowComponentProp]\n );\n\n const [element, setElement] = useState<HTMLDivElement | null>(null);\n\n const {\n getCellBounds,\n getEstimatedSize,\n scrollToIndex,\n startIndex,\n stopIndex\n } = useVirtualizer({\n containerElement: element,\n defaultContainerSize: defaultHeight,\n direction: \"vertical\",\n itemCount: rowCount,\n itemProps: rowProps,\n itemSize: rowHeight,\n onResize,\n overscanCount\n });\n\n useImperativeHandle(\n listRef,\n () => ({\n get element() {\n return element;\n },\n\n scrollToRow({\n align = \"auto\",\n behavior = \"auto\",\n index\n }: {\n align?: Align;\n behavior?: ScrollBehavior;\n index: number;\n }) {\n const top = scrollToIndex({\n align,\n containerScrollOffset: element?.scrollTop ?? 0,\n index\n });\n\n if (typeof element?.scrollTo === \"function\") {\n element.scrollTo({\n behavior,\n top\n });\n }\n }\n }),\n [element, scrollToIndex]\n );\n\n useEffect(() => {\n if (startIndex >= 0 && stopIndex >= 0 && onRowsRendered) {\n onRowsRendered({\n startIndex,\n stopIndex\n });\n }\n }, [onRowsRendered, startIndex, stopIndex]);\n\n const rows = useMemo(() => {\n const children: ReactNode[] = [];\n if (rowCount > 0) {\n for (let index = startIndex; index <= stopIndex; index++) {\n const bounds = getCellBounds(index);\n\n children.push(\n <RowComponent\n {...(rowProps as RowProps)}\n ariaAttributes={{\n \"aria-posinset\": index + 1,\n \"aria-setsize\": rowCount,\n role: \"listitem\"\n }}\n key={index}\n index={index}\n style={{\n position: \"absolute\",\n left: 0,\n transform: `translateY(${bounds.scrollOffset}px)`,\n height: bounds.size,\n width: \"100%\"\n }}\n />\n );\n }\n }\n return children;\n }, [RowComponent, getCellBounds, rowCount, rowProps, startIndex, stopIndex]);\n\n return (\n <div\n role=\"list\"\n {...rest}\n className={className}\n ref={setElement}\n style={{\n position: \"relative\",\n maxHeight: \"100%\",\n flexGrow: 1,\n overflowY: \"auto\",\n ...style\n }}\n >\n {rows}\n\n <div\n aria-hidden\n style={{\n height: getEstimatedSize(),\n width: \"100%\",\n zIndex: -1\n }}\n ></div>\n </div>\n );\n}\n"],"names":["List","className","defaultHeight","listRef","onResize","onRowsRendered","overscanCount","rowComponent","RowComponentProp","rowCount","rowHeight","rowProps","rowPropsUnstable","style","rest","useMemoizedObject","RowComponent","useMemo","memo","arePropsEqual","element","setElement","useState","getCellBounds","getEstimatedSize","scrollToIndex","startIndex","stopIndex","useVirtualizer","containerElement","defaultContainerSize","direction","itemCount","itemProps","itemSize","useImperativeHandle","scrollToRow","align","behavior","index","top","containerScrollOffset","scrollTop","scrollTo","useEffect","rows","children","bounds","push","createElement","ariaAttributes","role","key","position","left","transform","scrollOffset","height","size","width","jsxs","ref","maxHeight","flexGrow","overflowY","jsx","zIndex"],"mappings":"6GAcO,SAASA,GAA8BC,UAC5CA,EAAAC,cACAA,EAAgB,EAAAC,QAChBA,EAAAC,SACAA,EAAAC,eACAA,EAAAC,cACAA,EAAgB,EAChBC,aAAcC,EAAAC,SACdA,EAAAC,UACAA,EACAC,SAAUC,EAAAC,MACVA,KACGC,IAEH,MAAMH,EAAWI,EAAkBH,GAC7BI,EAAeC,EAAAA,QACnB,IAAMC,EAAAA,KAAKV,EAAkBW,GAC7B,CAACX,KAGIY,EAASC,GAAcC,EAAAA,SAAgC,OAExDC,cACJA,EAAAC,iBACAA,EAAAC,cACAA,EAAAC,WACAA,EAAAC,UACAA,GACEC,EAAe,CACjBC,iBAAkBT,EAClBU,qBAAsB5B,EACtB6B,UAAW,WACXC,UAAWvB,EACXwB,UAAWtB,EACXuB,SAAUxB,EACVN,WACAE,kBAGF6B,EAAAA,oBACEhC,EACA,KAAA,CACE,WAAIiB,GACF,OAAOA,CACT,EAEA,WAAAgB,EAAYC,MACVA,EAAQ,OAAAC,SACRA,EAAW,OAAAC,MACXA,IAMA,MAAMC,EAAMf,EAAc,CACxBY,QACAI,sBAAuBrB,GAASsB,WAAa,EAC7CH,UAG+B,mBAAtBnB,GAASuB,UAClBvB,EAAQuB,SAAS,CACfL,WACAE,OAGN,IAEF,CAACpB,EAASK,IAGZmB,EAAAA,UAAU,KACJlB,GAAc,GAAKC,GAAa,GAAKtB,GACvCA,EAAe,CACbqB,aACAC,eAGH,CAACtB,EAAgBqB,EAAYC,IAEhC,MAAMkB,EAAO5B,EAAAA,QAAQ,KACnB,MAAM6B,EAAwB,GAC9B,GAAIrC,EAAW,EACb,IAAA,IAAS8B,EAAQb,EAAYa,GAASZ,EAAWY,IAAS,CACxD,MAAMQ,EAASxB,EAAcgB,GAE7BO,EAASE,KACPC,EAAAA,cAACjC,EAAA,IACML,EACLuC,eAAgB,CACd,gBAAiBX,EAAQ,EACzB,eAAgB9B,EAChB0C,KAAM,YAERC,IAAKb,EACLA,QACA1B,MAAO,CACLwC,SAAU,WACVC,KAAM,EACNC,UAAW,cAAcR,EAAOS,kBAChCC,OAAQV,EAAOW,KACfC,MAAO,UAIf,CAEF,OAAOb,GACN,CAAC9B,EAAcO,EAAed,EAAUE,EAAUe,EAAYC,IAEjE,OACEiC,EAAAA,KAAC,MAAA,CACCT,KAAK,UACDrC,EACJb,YACA4D,IAAKxC,EACLR,MAAO,CACLwC,SAAU,WACVS,UAAW,OACXC,SAAU,EACVC,UAAW,UACRnD,GAGJiC,SAAA,CAAAD,EAEDoB,EAAAA,IAAC,MAAA,CACC,eAAW,EACXpD,MAAO,CACL4C,OAAQjC,IACRmC,MAAO,OACPO,QAAQ,OAKlB"}
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
import{j as e,B as n}from"./index-Dfhz9Ad4.js";import{C as t}from"./ContinueLink-DN1_wnU9.js";import{C as r}from"./ComponentProps-BA6jJCAT.js";import"./Header-DyQVANF3.js";const i={tags:{},filePath:"lib/components/grid/Grid.tsx",description:"",displayName:"Grid",methods:[],props:{className:{defaultValue:null,description:"CSS class name.",name:"className",parent:{fileName:"react-window/node_modules/.pnpm/@types+react@19.1.8/node_modules/@types/react/index.d.ts",name:"HTMLAttributes"},declarations:[{fileName:"react-window/node_modules/.pnpm/@types+react@19.1.8/node_modules/@types/react/index.d.ts",name:"HTMLAttributes"},{fileName:"react-window/lib/components/grid/types.ts",name:"TypeLiteral"}],required:!1,type:{name:"enum",raw:"string | undefined",value:[{value:"undefined"},{value:"string"}]}},dir:{defaultValue:null,description:"Corresponds to the HTML dir attribute:\nhttps://developer.mozilla.org/en-US/docs/Web/HTML/Reference/Global_attributes/dir",name:"dir",parent:{fileName:"react-window/node_modules/.pnpm/@types+react@19.1.8/node_modules/@types/react/index.d.ts",name:"HTMLAttributes"},declarations:[{fileName:"react-window/node_modules/.pnpm/@types+react@19.1.8/node_modules/@types/react/index.d.ts",name:"HTMLAttributes"},{fileName:"react-window/lib/components/grid/types.ts",name:"TypeLiteral"}],required:!1,type:{name:"enum",raw:"string | undefined",value:[{value:"undefined"},{value:"string"}]}},style:{defaultValue:null,description:"Optional CSS properties.\nThe grid of cells will fill the height and width defined by this style.",name:"style",parent:{fileName:"react-window/node_modules/.pnpm/@types+react@19.1.8/node_modules/@types/react/index.d.ts",name:"HTMLAttributes"},declarations:[{fileName:"react-window/node_modules/.pnpm/@types+react@19.1.8/node_modules/@types/react/index.d.ts",name:"HTMLAttributes"},{fileName:"react-window/lib/components/grid/types.ts",name:"TypeLiteral"}],required:!1,type:{name:"enum",raw:"CSSProperties | undefined",value:[{value:"undefined"},{value:"CSSProperties",description:"",fullComment:"",tags:{}}]}},cellComponent:{defaultValue:null,description:"React component responsible for rendering a cell.\n\nThis component will receive an `index` and `style` prop by default.\nAdditionally it will receive prop values passed to `cellProps`.\n\n⚠️ The prop types for this component are exported as `CellComponentProps`",name:"cellComponent",declarations:[{fileName:"react-window/lib/components/grid/types.ts",name:"TypeLiteral"}],required:!0,type:{name:'(props: { ariaAttributes: { "aria-colindex": number; role: "gridcell"; }; columnIndex: number; rowIndex: number; style: CSSProperties; } & CellProps) => ReactNode'}},cellProps:{defaultValue:null,description:"Additional props to be passed to the cell-rendering component.\nGrid will automatically re-render cells when values in this object change.\n\n⚠️ This object must not contain either an `index` or `style` prop.",name:"cellProps",declarations:[{fileName:"react-window/lib/components/grid/types.ts",name:"TypeLiteral"}],required:!0,type:{name:"ExcludeForbiddenKeys<CellProps>"}},columnCount:{defaultValue:null,description:"Number of columns to be rendered in the grid.",name:"columnCount",declarations:[{fileName:"react-window/lib/components/grid/types.ts",name:"TypeLiteral"}],required:!0,type:{name:"number"}},columnWidth:{defaultValue:null,description:"Column width; the following formats are supported:\n- number of pixels (number)\n- percentage of the grid's current width (string)\n- function that returns the row width (in pixels) given an index and `cellProps`",name:"columnWidth",declarations:[{fileName:"react-window/lib/components/grid/types.ts",name:"TypeLiteral"}],required:!0,type:{name:"enum",raw:"string | number | ((index: number, cellProps: CellProps) => number)",value:[{value:"string"},{value:"number"},{value:"(index: number, cellProps: CellProps) => number",description:"",fullComment:"",tags:{}}]}},defaultHeight:{defaultValue:{value:"0"},description:"Default height of grid for initial render.\nThis value is important for server rendering.",name:"defaultHeight",declarations:[{fileName:"react-window/lib/components/grid/types.ts",name:"TypeLiteral"}],required:!1,type:{name:"enum",raw:"number | undefined",value:[{value:"undefined"},{value:"number"}]}},defaultWidth:{defaultValue:{value:"0"},description:"Default width of grid for initial render.\nThis value is important for server rendering.",name:"defaultWidth",declarations:[{fileName:"react-window/lib/components/grid/types.ts",name:"TypeLiteral"}],required:!1,type:{name:"enum",raw:"number | undefined",value:[{value:"undefined"},{value:"number"}]}},gridRef:{defaultValue:null,description:"Ref used to interact with this component's imperative API.\n\nThis API has imperative methods for scrolling and a getter for the outermost DOM element.\n\n⚠️ The `useGridRef` and `useGridCallbackRef` hooks are exported for convenience use in TypeScript projects.",name:"gridRef",declarations:[{fileName:"react-window/lib/components/grid/types.ts",name:"TypeLiteral"}],required:!1,type:{name:"enum",raw:"Ref<GridImperativeAPI> | undefined",value:[{value:"undefined"},{value:"null"},{value:"(instance: GridImperativeAPI | null) => void | (() => VoidOrUndefinedOnly)",description:"",fullComment:"",tags:{}},{value:"RefObject<GridImperativeAPI | null>",description:"Created by {@link createRef}, or {@link useRef} when passed `null`.",fullComment:"Created by {@link createRef}, or {@link useRef} when passed `null`.\n@template T The type of the ref's value.\n@example ```tsx\nconst ref = createRef<HTMLDivElement>();\n\nref.current = document.createElement('div'); // Error\n```",tags:{template:"T The type of the ref's value.",example:"```tsx\nconst ref = createRef<HTMLDivElement>();\n\nref.current = document.createElement('div'); // Error\n```"}}]}},onCellsRendered:{defaultValue:null,description:"Callback notified when the range of rendered cells changes.",name:"onCellsRendered",declarations:[{fileName:"react-window/lib/components/grid/types.ts",name:"TypeLiteral"}],required:!1,type:{name:"enum",raw:"((args: { columnStartIndex: number; columnStopIndex: number; rowStartIndex: number; rowStopIndex: number; }) => void) | undefined",value:[{value:"undefined"},{value:"(args: { columnStartIndex: number; columnStopIndex: number; rowStartIndex: number; rowStopIndex: number; }) => void",description:"",fullComment:"",tags:{}}]}},onResize:{defaultValue:null,description:"Callback notified when the Grid's outermost HTMLElement resizes.\nThis may be used to (re)scroll a cell into view.",name:"onResize",declarations:[{fileName:"react-window/lib/components/grid/types.ts",name:"TypeLiteral"}],required:!1,type:{name:"enum",raw:"((size: { height: number; width: number; }, prevSize: { height: number; width: number; }) => void) | undefined",value:[{value:"undefined"},{value:"(size: { height: number; width: number; }, prevSize: { height: number; width: number; }) => void",description:"",fullComment:"",tags:{}}]}},overscanCount:{defaultValue:{value:"3"},description:"How many additional rows/columns to render outside of the visible area.\nThis can reduce visual flickering near the edges of a grid when scrolling.",name:"overscanCount",declarations:[{fileName:"react-window/lib/components/grid/types.ts",name:"TypeLiteral"}],required:!1,type:{name:"enum",raw:"number | undefined",value:[{value:"undefined"},{value:"number"}]}},rowCount:{defaultValue:null,description:"Number of rows to be rendered in the grid.",name:"rowCount",declarations:[{fileName:"react-window/lib/components/grid/types.ts",name:"TypeLiteral"}],required:!0,type:{name:"number"}},rowHeight:{defaultValue:null,description:"Row height; the following formats are supported:\n- number of pixels (number)\n- percentage of the grid's current height (string)\n- function that returns the row height (in pixels) given an index and `cellProps`",name:"rowHeight",declarations:[{fileName:"react-window/lib/components/grid/types.ts",name:"TypeLiteral"}],required:!0,type:{name:"enum",raw:"string | number | ((index: number, cellProps: CellProps) => number)",value:[{value:"string"},{value:"number"},{value:"(index: number, cellProps: CellProps) => number",description:"",fullComment:"",tags:{}}]}}}};function a(){return e.jsxs(n,{direction:"column",gap:4,children:[e.jsx(r,{section:"Grids",json:i}),e.jsx(t,{to:"/grid/imperative-api",title:"imperative api"})]})}export{a as default};
|
|
2
|
-
//# sourceMappingURL=PropsRoute-BzcsHp2c.js.map
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
import{j as e,B as n}from"./index-Dfhz9Ad4.js";import{C as t}from"./ContinueLink-DN1_wnU9.js";import{C as i}from"./ComponentProps-BA6jJCAT.js";import"./Header-DyQVANF3.js";const r={tags:{},filePath:"lib/components/list/List.tsx",description:"",displayName:"List",methods:[],props:{className:{defaultValue:null,description:"CSS class name.",name:"className",parent:{fileName:"react-window/node_modules/.pnpm/@types+react@19.1.8/node_modules/@types/react/index.d.ts",name:"HTMLAttributes"},declarations:[{fileName:"react-window/node_modules/.pnpm/@types+react@19.1.8/node_modules/@types/react/index.d.ts",name:"HTMLAttributes"},{fileName:"react-window/lib/components/list/types.ts",name:"TypeLiteral"}],required:!1,type:{name:"enum",raw:"string | undefined",value:[{value:"undefined"},{value:"string"}]}},style:{defaultValue:null,description:"Optional CSS properties.\nThe list of rows will fill the height defined by this style.",name:"style",parent:{fileName:"react-window/node_modules/.pnpm/@types+react@19.1.8/node_modules/@types/react/index.d.ts",name:"HTMLAttributes"},declarations:[{fileName:"react-window/node_modules/.pnpm/@types+react@19.1.8/node_modules/@types/react/index.d.ts",name:"HTMLAttributes"},{fileName:"react-window/lib/components/list/types.ts",name:"TypeLiteral"}],required:!1,type:{name:"enum",raw:"CSSProperties | undefined",value:[{value:"undefined"},{value:"CSSProperties",description:"",fullComment:"",tags:{}}]}},defaultHeight:{defaultValue:{value:"0"},description:"Default height of list for initial render.\nThis value is important for server rendering.",name:"defaultHeight",declarations:[{fileName:"react-window/lib/components/list/types.ts",name:"TypeLiteral"}],required:!1,type:{name:"enum",raw:"number | undefined",value:[{value:"undefined"},{value:"number"}]}},listRef:{defaultValue:null,description:"Ref used to interact with this component's imperative API.\n\nThis API has imperative methods for scrolling and a getter for the outermost DOM element.\n\n⚠️ The `useListRef` and `useListCallbackRef` hooks are exported for convenience use in TypeScript projects.",name:"listRef",declarations:[{fileName:"react-window/lib/components/list/types.ts",name:"TypeLiteral"}],required:!1,type:{name:"enum",raw:"Ref<ListImperativeAPI> | undefined",value:[{value:"undefined"},{value:"null"},{value:"(instance: ListImperativeAPI | null) => void | (() => VoidOrUndefinedOnly)",description:"",fullComment:"",tags:{}},{value:"RefObject<ListImperativeAPI | null>",description:"Created by {@link createRef}, or {@link useRef} when passed `null`.",fullComment:"Created by {@link createRef}, or {@link useRef} when passed `null`.\n@template T The type of the ref's value.\n@example ```tsx\nconst ref = createRef<HTMLDivElement>();\n\nref.current = document.createElement('div'); // Error\n```",tags:{template:"T The type of the ref's value.",example:"```tsx\nconst ref = createRef<HTMLDivElement>();\n\nref.current = document.createElement('div'); // Error\n```"}}]}},onResize:{defaultValue:null,description:"Callback notified when the List's outermost HTMLElement resizes.\nThis may be used to (re)scroll a row into view.",name:"onResize",declarations:[{fileName:"react-window/lib/components/list/types.ts",name:"TypeLiteral"}],required:!1,type:{name:"enum",raw:"((size: { height: number; width: number; }, prevSize: { height: number; width: number; }) => void) | undefined",value:[{value:"undefined"},{value:"(size: { height: number; width: number; }, prevSize: { height: number; width: number; }) => void",description:"",fullComment:"",tags:{}}]}},onRowsRendered:{defaultValue:null,description:"Callback notified when the range of visible rows changes.",name:"onRowsRendered",declarations:[{fileName:"react-window/lib/components/list/types.ts",name:"TypeLiteral"}],required:!1,type:{name:"enum",raw:"((args: { startIndex: number; stopIndex: number; }) => void) | undefined",value:[{value:"undefined"},{value:"(args: { startIndex: number; stopIndex: number; }) => void",description:"",fullComment:"",tags:{}}]}},overscanCount:{defaultValue:{value:"3"},description:"How many additional rows to render outside of the visible area.\nThis can reduce visual flickering near the edges of a list when scrolling.",name:"overscanCount",declarations:[{fileName:"react-window/lib/components/list/types.ts",name:"TypeLiteral"}],required:!1,type:{name:"enum",raw:"number | undefined",value:[{value:"undefined"},{value:"number"}]}},rowComponent:{defaultValue:null,description:"React component responsible for rendering a row.\n\nThis component will receive an `index` and `style` prop by default.\nAdditionally it will receive prop values passed to `rowProps`.\n\n⚠️ The prop types for this component are exported as `RowComponentProps`",name:"rowComponent",declarations:[{fileName:"react-window/lib/components/list/types.ts",name:"TypeLiteral"}],required:!0,type:{name:'(props: { ariaAttributes: { "aria-posinset": number; "aria-setsize": number; role: "listitem"; }; index: number; style: CSSProperties; } & RowProps) => ReactNode'}},rowCount:{defaultValue:null,description:"Number of items to be rendered in the list.",name:"rowCount",declarations:[{fileName:"react-window/lib/components/list/types.ts",name:"TypeLiteral"}],required:!0,type:{name:"number"}},rowHeight:{defaultValue:null,description:"Row height; the following formats are supported:\n- number of pixels (number)\n- percentage of the grid's current height (string)\n- function that returns the row height (in pixels) given an index and `cellProps`",name:"rowHeight",declarations:[{fileName:"react-window/lib/components/list/types.ts",name:"TypeLiteral"}],required:!0,type:{name:"enum",raw:"string | number | ((index: number, cellProps: RowProps) => number)",value:[{value:"string"},{value:"number"},{value:"(index: number, cellProps: RowProps) => number",description:"",fullComment:"",tags:{}}]}},rowProps:{defaultValue:null,description:"Additional props to be passed to the row-rendering component.\nList will automatically re-render rows when values in this object change.\n\n⚠️ This object must not contain either an `index` or `style` prop.",name:"rowProps",declarations:[{fileName:"react-window/lib/components/list/types.ts",name:"TypeLiteral"}],required:!0,type:{name:"ExcludeForbiddenKeys<RowProps>"}}}};function a(){return e.jsxs(n,{direction:"column",gap:4,children:[e.jsx(i,{section:"Lists",json:r}),e.jsx(t,{to:"/list/imperative-api",title:"imperative api"})]})}export{a as default};
|
|
2
|
-
//# sourceMappingURL=PropsRoute-CHeNkGKQ.js.map
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
import{r as e,j as t,B as n,c as l}from"./index-Dfhz9Ad4.js";import{G as o}from"./Grid-BnGy9pmI.js";import{B as s}from"./arePropsEqual-Bhv0L31F.js";import{S as a}from"./Select-Dtoy3zH8.js";const r=e.useState,c=t=>e.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",height:"24px",viewBox:"0 -960 960 960",width:"24px",fill:"#e3e3e3",...t},e.createElement("path",{d:"m424-424-86-86q-11-11-28-11t-28 11q-11 11-11 28t11 28l114 114q12 12 28 12t28-12l226-226q11-11 11-28t-11-28q-11-11-28-11t-28 11L424-424ZM200-120q-33 0-56.5-23.5T120-200v-560q0-33 23.5-56.5T200-840h560q33 0 56.5 23.5T840-760v560q0 33-23.5 56.5T760-120H200Z"})),i=t=>e.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",height:"24px",viewBox:"0 -960 960 960",width:"24px",fill:"#e3e3e3",...t},e.createElement("path",{d:"M320-440h320q17 0 28.5-11.5T680-480q0-17-11.5-28.5T640-520H320q-17 0-28.5 11.5T280-480q0 17 11.5 28.5T320-440ZM200-120q-33 0-56.5-23.5T120-200v-560q0-33 23.5-56.5T200-840h560q33 0 56.5 23.5T840-760v560q0 33-23.5 56.5T760-120H200Z"})),d=t=>e.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",height:"24px",viewBox:"0 -960 960 960",width:"24px",fill:"#e3e3e3",...t},e.createElement("path",{d:"M200-120q-33 0-56.5-23.5T120-200v-560q0-33 23.5-56.5T200-840h560q33 0 56.5 23.5T840-760v560q0 33-23.5 56.5T760-120H200Z"}));function u({checked:e,children:n,className:l,indeterminate:o,onChange:s,...a}){let r,u;return o?(r=i,u="fill-white"):e?(r=c,u="fill-blue-600"):(r=d,u="fill-slate-600"),t.jsxs("label",{className:`cursor-pointer rounded-lg flex flex-row items-center outline-none group ${l}`,"data-focus-within":!0,...a,children:[t.jsx("input",{checked:e,className:"w-0 h-0",onChange:e=>{s(e.currentTarget.checked)},type:"checkbox"}),t.jsx(r,{className:u}),n&&t.jsxs(t.Fragment,{children:[" ",n]})]})}function m({children:e,className:n,onChange:l,value:o,...s}){return t.jsx("input",{className:`rounded-md bg-black/30 border border-2 border-transparent py-1 px-2 outline-none focus:border-emerald-300 ${n}`,"data-focus":!0,onChange:e=>{l(e.currentTarget.value)},value:o,...s,children:e})}const h=["auto","center","end","smart","start"].map(e=>({label:`align: ${e}`,value:e}));function x(){const[l,c]=e.useState(!1),[i,d]=e.useState(),[x,p]=e.useState(),[w,v]=r(null),[f,q]=e.useState(h[0]);return t.jsxs(n,{direction:"column",gap:4,children:[t.jsxs(n,{align:"center",direction:"row",gap:4,onKeyDown:e=>{if("Enter"===e.key)void 0!==i&&void 0!==x?w?.scrollToCell({columnAlign:f.value,columnIndex:i,rowAlign:f.value,rowIndex:x}):void 0!==i?w?.scrollToColumn({align:f.value,index:i}):void 0!==x&&w?.scrollToRow({align:f.value,index:x})},children:[t.jsx(a,{className:"flex-1",onChange:q,options:h,placeholder:"Align",value:f}),t.jsx(u,{checked:l,onChange:c}),t.jsx(m,{autoFocus:!0,className:"grow",min:0,max:99,onChange:e=>{const t=parseInt(e);d(isNaN(t)?void 0:t)},placeholder:"Column",step:1,type:"number",value:void 0===i?"":""+i}),t.jsx(m,{autoFocus:!0,className:"grow",min:0,max:99,onChange:e=>{const t=parseInt(e);p(isNaN(t)?void 0:t)},placeholder:"Row",step:1,type:"number",value:void 0===x?"":""+x})]}),t.jsx(s,{className:"w-full h-100","data-focus-within":"bold",children:t.jsx(o,{cellComponent:g,cellProps:{focusedColumnIndex:i,focusedRowIndex:x},columnCount:100,columnWidth:75,dir:l?"rtl":void 0,gridRef:v,rowCount:100,rowHeight:35},l?"rtl":"ltr")})]})}function g({columnIndex:e,focusedColumnIndex:n,focusedRowIndex:o,rowIndex:s,style:a}){return t.jsxs("div",{className:l("flex items-center justify-center text-xs",{"bg-slate-900":e%2==s%2,"bg-slate-800":e===n||s===o}),style:a,children:["row ",s,", col ",e]})}export{x as default};
|
|
2
|
-
//# sourceMappingURL=ScratchpadRoute-B8OO7yyx.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
/*! tailwindcss v4.1.11 | MIT License | https://tailwindcss.com */@layer properties{@supports (((-webkit-hyphens:none)) and (not (margin-trim:inline))) or ((-moz-orient:inline) and (not (color:rgb(from red r g b)))){*,:before,:after,::backdrop{--tw-rotate-x:initial;--tw-rotate-y:initial;--tw-rotate-z:initial;--tw-skew-x:initial;--tw-skew-y:initial;--tw-border-style:solid;--tw-leading:initial;--tw-font-weight:initial;--tw-shadow:0 0 #0000;--tw-shadow-color:initial;--tw-shadow-alpha:100%;--tw-inset-shadow:0 0 #0000;--tw-inset-shadow-color:initial;--tw-inset-shadow-alpha:100%;--tw-ring-color:initial;--tw-ring-shadow:0 0 #0000;--tw-inset-ring-color:initial;--tw-inset-ring-shadow:0 0 #0000;--tw-ring-inset:initial;--tw-ring-offset-width:0px;--tw-ring-offset-color:#fff;--tw-ring-offset-shadow:0 0 #0000;--tw-blur:initial;--tw-brightness:initial;--tw-contrast:initial;--tw-grayscale:initial;--tw-hue-rotate:initial;--tw-invert:initial;--tw-opacity:initial;--tw-saturate:initial;--tw-sepia:initial;--tw-drop-shadow:initial;--tw-drop-shadow-color:initial;--tw-drop-shadow-alpha:100%;--tw-drop-shadow-size:initial;--tw-duration:initial;--tw-ease:initial;--tw-text-shadow-color:initial;--tw-text-shadow-alpha:100%}}}@layer theme{:root,:host{--font-sans:ui-sans-serif,system-ui,sans-serif,"Apple Color Emoji","Segoe UI Emoji","Segoe UI Symbol","Noto Color Emoji";--font-mono:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,"Liberation Mono","Courier New",monospace;--color-red-300:rgb(255, 163, 164);--color-red-400:rgb(255, 101, 104);--color-red-500:rgb(251, 44, 54);--color-red-800:rgb(159, 7, 18);--color-red-950:rgb(70, 8, 9);--color-orange-400:rgb(255, 139, 31);--color-amber-400:rgb(250, 188, 0);--color-amber-500:rgb(246, 158, 0);--color-amber-800:rgb(149, 61, 0);--color-amber-950:rgb(70, 25, 1);--color-green-400:rgb(5, 223, 114);--color-emerald-200:rgb(164, 244, 207);--color-emerald-300:rgb(94, 233, 181);--color-emerald-400:rgb(0, 210, 148);--color-emerald-500:rgb(0, 185, 129);--color-emerald-800:rgb(0, 95, 70);--color-emerald-950:rgb(0, 44, 34);--color-teal-300:rgb(70, 236, 213);--color-teal-400:rgb(0, 211, 189);--color-teal-600:rgb(0, 148, 136);--color-sky-300:rgb(120, 212, 255);--color-sky-400:rgb(0, 187, 253);--color-sky-500:rgb(0, 165, 234);--color-sky-800:rgb(0, 89, 134);--color-sky-950:rgb(5, 47, 74);--color-blue-600:rgb(21, 93, 252);--color-pink-400:rgb(251, 100, 182);--color-pink-500:rgb(246, 51, 154);--color-slate-300:rgb(202, 213, 226);--color-slate-400:rgb(144, 161, 185);--color-slate-500:rgb(98, 116, 142);--color-slate-600:rgb(69, 85, 108);--color-slate-800:rgb(29, 41, 61);--color-slate-900:rgb(15, 23, 43);--color-gray-400:rgb(153, 161, 175);--color-black:#000;--color-white:#fff;--spacing:.25rem;--text-xs:.75rem;--text-xs--line-height:calc(1/.75);--text-sm:.875rem;--text-sm--line-height:calc(1.25/.875);--text-lg:1.125rem;--text-lg--line-height:calc(1.75/1.125);--text-xl:1.25rem;--text-xl--line-height:calc(1.75/1.25);--text-3xl:1.875rem;--text-3xl--line-height: 1.2 ;--text-7xl:4.5rem;--text-7xl--line-height:1;--text-8xl:6rem;--text-8xl--line-height:1;--font-weight-bold:700;--radius-sm:.25rem;--radius-md:.375rem;--radius-lg:.5rem;--radius-3xl:1.5rem;--drop-shadow-xs:0 1px 1px #0000000d;--drop-shadow-sm:0 1px 2px #00000026;--ease-in:cubic-bezier(.4,0,1,1);--animate-spin:spin 1s linear infinite;--default-transition-duration:.15s;--default-transition-timing-function:cubic-bezier(.4,0,.2,1);--default-font-family:var(--font-sans);--default-mono-font-family:var(--font-mono)}@supports (color: color(display-p3 0 0 0%)){:root,:host{--color-red-300:color(display-p3 .95692 .65189 .64512);--color-red-400:color(display-p3 .93353 .43168 .42349);--color-orange-400:color(display-p3 .95019 .56181 .21102);--color-amber-400:color(display-p3 .95919 .73852 .11827);--color-amber-500:color(display-p3 .93994 .62058 .05854);--color-amber-800:color(display-p3 .54753 .25606 .07283);--color-emerald-400:color(display-p3 .3347 .8196 .59158);--color-emerald-500:color(display-p3 .26711 .72685 .5084);--color-emerald-800:color(display-p3 .1354 .3714 .27756);--color-emerald-950:color(display-p3 .05491 .17043 .13484);--color-teal-400:color(display-p3 .32279 .82206 .74439);--color-teal-600:color(display-p3 .20711 .57958 .53668);--color-sky-300:color(display-p3 .54636 .82256 .99058);--color-sky-400:color(display-p3 .30598 .72501 .98017);--color-sky-500:color(display-p3 .21911 .63903 .93148);--color-sky-800:color(display-p3 .12072 .34308 .52441)}}}@layer base{*,:after,:before,::backdrop{box-sizing:border-box;border:0 solid;margin:0;padding:0}::file-selector-button{box-sizing:border-box;border:0 solid;margin:0;padding:0}html,:host{-webkit-text-size-adjust:100%;tab-size:4;line-height:1.5;font-family:var(--default-font-family,ui-sans-serif,system-ui,sans-serif,"Apple Color Emoji","Segoe UI Emoji","Segoe UI Symbol","Noto Color Emoji");font-feature-settings:var(--default-font-feature-settings,normal);font-variation-settings:var(--default-font-variation-settings,normal);-webkit-tap-highlight-color:transparent}hr{height:0;color:inherit;border-top-width:1px}abbr:where([title]){-webkit-text-decoration:underline dotted;text-decoration:underline dotted}h1,h2,h3,h4,h5,h6{font-size:inherit;font-weight:inherit}a{color:inherit;-webkit-text-decoration:inherit;text-decoration:inherit}b,strong{font-weight:bolder}code,kbd,samp,pre{font-family:var(--default-mono-font-family,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,"Liberation Mono","Courier New",monospace);font-feature-settings:var(--default-mono-font-feature-settings,normal);font-variation-settings:var(--default-mono-font-variation-settings,normal);font-size:1em}small{font-size:80%}sub,sup{vertical-align:baseline;font-size:75%;line-height:0;position:relative}sub{bottom:-.25em}sup{top:-.5em}table{text-indent:0;border-color:inherit;border-collapse:collapse}:-moz-focusring{outline:auto}progress{vertical-align:baseline}summary{display:list-item}ol,ul,menu{list-style:none}img,svg,video,canvas,audio,iframe,embed,object{vertical-align:middle;display:block}img,video{max-width:100%;height:auto}button,input,select,optgroup,textarea{font:inherit;font-feature-settings:inherit;font-variation-settings:inherit;letter-spacing:inherit;color:inherit;opacity:1;background-color:#0000;border-radius:0}::file-selector-button{font:inherit;font-feature-settings:inherit;font-variation-settings:inherit;letter-spacing:inherit;color:inherit;opacity:1;background-color:#0000;border-radius:0}:where(select:is([multiple],[size])) optgroup{font-weight:bolder}:where(select:is([multiple],[size])) optgroup option{padding-inline-start:20px}::file-selector-button{margin-inline-end:4px}::placeholder{opacity:1}@supports (not ((-webkit-appearance:-apple-pay-button))) or (contain-intrinsic-size:1px){::placeholder{color:currentColor}@supports (color:color-mix(in lab,red,red)){::placeholder{color:color-mix(in oklab,currentcolor 50%,transparent)}}}textarea{resize:vertical}::-webkit-search-decoration{-webkit-appearance:none}::-webkit-date-and-time-value{min-height:1lh;text-align:inherit}::-webkit-datetime-edit{display:inline-flex}::-webkit-datetime-edit-fields-wrapper{padding:0}::-webkit-datetime-edit{padding-block:0}::-webkit-datetime-edit-year-field{padding-block:0}::-webkit-datetime-edit-month-field{padding-block:0}::-webkit-datetime-edit-day-field{padding-block:0}::-webkit-datetime-edit-hour-field{padding-block:0}::-webkit-datetime-edit-minute-field{padding-block:0}::-webkit-datetime-edit-second-field{padding-block:0}::-webkit-datetime-edit-millisecond-field{padding-block:0}::-webkit-datetime-edit-meridiem-field{padding-block:0}:-moz-ui-invalid{box-shadow:none}button,input:where([type=button],[type=reset],[type=submit]){appearance:button}::file-selector-button{appearance:button}::-webkit-inner-spin-button{height:auto}::-webkit-outer-spin-button{height:auto}[hidden]:where(:not([hidden=until-found])){display:none!important}}@layer components;@layer utilities{.pointer-events-none{pointer-events:none}.\!visible{visibility:visible!important}.visible{visibility:visible}.absolute{position:absolute}.fixed{position:fixed}.relative{position:relative}.inset-y-0{inset-block:calc(var(--spacing)*0)}.top-0{top:calc(var(--spacing)*0)}.top-2{top:calc(var(--spacing)*2)}.right-0{right:calc(var(--spacing)*0)}.right-2{right:calc(var(--spacing)*2)}.left-0{left:calc(var(--spacing)*0)}.z-10{z-index:10}.z-400{z-index:400}.container{width:100%}@media (min-width:40rem){.container{max-width:40rem}}@media (min-width:48rem){.container{max-width:48rem}}@media (min-width:64rem){.container{max-width:64rem}}@media (min-width:80rem){.container{max-width:80rem}}@media (min-width:96rem){.container{max-width:96rem}}.mx-2{margin-inline:calc(var(--spacing)*2)}.mx-auto{margin-inline:auto}.mt-1{margin-top:calc(var(--spacing)*1)}.mt-2{margin-top:calc(var(--spacing)*2)}.ml-4{margin-left:calc(var(--spacing)*4)}.block{display:block}.contents{display:contents}.flex{display:flex}.grid{display:grid}.hidden{display:none}.inline-block{display:inline-block}.table{display:table}.size-4{width:calc(var(--spacing)*4);height:calc(var(--spacing)*4)}.h-0{height:calc(var(--spacing)*0)}.h-2{height:calc(var(--spacing)*2)}.h-4{height:calc(var(--spacing)*4)}.h-6{height:calc(var(--spacing)*6)}.h-7{height:calc(var(--spacing)*7)}.h-8{height:calc(var(--spacing)*8)}.h-9{height:calc(var(--spacing)*9)}.h-12{height:calc(var(--spacing)*12)}.h-20{height:calc(var(--spacing)*20)}.h-50{height:calc(var(--spacing)*50)}.h-55{height:calc(var(--spacing)*55)}.h-100{height:calc(var(--spacing)*100)}.h-full{height:100%}.max-h-50{max-height:calc(var(--spacing)*50)}.w-0{width:calc(var(--spacing)*0)}.w-2{width:calc(var(--spacing)*2)}.w-4{width:calc(var(--spacing)*4)}.w-6{width:calc(var(--spacing)*6)}.w-8{width:calc(var(--spacing)*8)}.w-10{width:calc(var(--spacing)*10)}.w-fit{width:fit-content}.w-full{width:100%}.max-w-350{max-width:calc(var(--spacing)*350)}.flex-1{flex:1}.shrink{flex-shrink:1}.shrink-0{flex-shrink:0}.shrink-1{flex-shrink:1}.grow{flex-grow:1}.grow-0{flex-grow:0}.grow-1{flex-grow:1}.transform{transform:var(--tw-rotate-x,)var(--tw-rotate-y,)var(--tw-rotate-z,)var(--tw-skew-x,)var(--tw-skew-y,)}.animate-spin{animation:var(--animate-spin)}.cursor-default{cursor:default}.cursor-pointer{cursor:pointer}.resize{resize:both}.list-disc{list-style-type:disc}.flex-col{flex-direction:column}.flex-row{flex-direction:row}.flex-wrap{flex-wrap:wrap}.items-center{align-items:center}.items-end{align-items:flex-end}.items-start{align-items:flex-start}.items-stretch{align-items:stretch}.justify-around{justify-content:space-around}.justify-between{justify-content:space-between}.justify-center{justify-content:center}.justify-end{justify-content:flex-end}.justify-start{justify-content:flex-start}.justify-stretch{justify-content:stretch}.gap-1{gap:calc(var(--spacing)*1)}.gap-2{gap:calc(var(--spacing)*2)}.gap-3{gap:calc(var(--spacing)*3)}.gap-4{gap:calc(var(--spacing)*4)}.gap-10{gap:calc(var(--spacing)*10)}.truncate{text-overflow:ellipsis;white-space:nowrap;overflow:hidden}.overflow-auto{overflow:auto}.overflow-hidden{overflow:hidden}.overflow-y-auto{overflow-y:auto}.rounded{border-radius:.25rem}.rounded-full{border-radius:3.40282e38px}.rounded-lg{border-radius:var(--radius-lg)}.rounded-md{border-radius:var(--radius-md)}.rounded-sm{border-radius:var(--radius-sm)}.rounded-t-3xl{border-top-left-radius:var(--radius-3xl);border-top-right-radius:var(--radius-3xl)}.border{border-style:var(--tw-border-style);border-width:1px}.border-2{border-style:var(--tw-border-style);border-width:2px}.border-r{border-right-style:var(--tw-border-style);border-right-width:1px}.border-none\!{--tw-border-style:none!important;border-style:none!important}.border-amber-400{border-color:var(--color-amber-400)}.border-emerald-400{border-color:var(--color-emerald-400)}.border-red-400{border-color:var(--color-red-400)}.border-sky-400{border-color:var(--color-sky-400)}.border-transparent{border-color:#0000}.border-white\/40{border-color:#fff6}@supports (color:color-mix(in lab,red,red)){.border-white\/40{border-color:color-mix(in oklab,var(--color-white)40%,transparent)}}.border-r-slate-800{border-right-color:var(--color-slate-800)}.bg-amber-400{background-color:var(--color-amber-400)}.bg-black{background-color:var(--color-black)}.bg-black\/10{background-color:#0000001a}@supports (color:color-mix(in lab,red,red)){.bg-black\/10{background-color:color-mix(in oklab,var(--color-black)10%,transparent)}}.bg-black\/30{background-color:#0000004d}@supports (color:color-mix(in lab,red,red)){.bg-black\/30{background-color:color-mix(in oklab,var(--color-black)30%,transparent)}}.bg-black\/40{background-color:#0006}@supports (color:color-mix(in lab,red,red)){.bg-black\/40{background-color:color-mix(in oklab,var(--color-black)40%,transparent)}}.bg-black\/50{background-color:#00000080}@supports (color:color-mix(in lab,red,red)){.bg-black\/50{background-color:color-mix(in oklab,var(--color-black)50%,transparent)}}.bg-black\/90{background-color:#000000e6}@supports (color:color-mix(in lab,red,red)){.bg-black\/90{background-color:color-mix(in oklab,var(--color-black)90%,transparent)}}.bg-emerald-400{background-color:var(--color-emerald-400)}.bg-green-400{background-color:var(--color-green-400)}.bg-orange-400{background-color:var(--color-orange-400)}.bg-red-400{background-color:var(--color-red-400)}.bg-sky-400{background-color:var(--color-sky-400)}.bg-sky-950\/50{background-color:#052f4a80}@supports (color:color-mix(in lab,red,red)){.bg-sky-950\/50{background-color:color-mix(in oklab,var(--color-sky-950)50%,transparent)}}.bg-slate-800{background-color:var(--color-slate-800)}.bg-slate-900{background-color:var(--color-slate-900)}.bg-teal-600{background-color:var(--color-teal-600)}.bg-white\/10{background-color:#ffffff1a}@supports (color:color-mix(in lab,red,red)){.bg-white\/10{background-color:color-mix(in oklab,var(--color-white)10%,transparent)}}.\[mask-image\:linear-gradient\(to_bottom\,transparent\,black_1\.5rem\)\]{-webkit-mask-image:linear-gradient(#0000,#000 1.5rem);mask-image:linear-gradient(#0000,#000 1.5rem)}.fill-blue-600{fill:var(--color-blue-600)}.fill-current{fill:currentColor}.fill-slate-600{fill:var(--color-slate-600)}.fill-white{fill:var(--color-white)}.fill-white\/60{fill:#fff9}@supports (color:color-mix(in lab,red,red)){.fill-white\/60{fill:color-mix(in oklab,var(--color-white)60%,transparent)}}.p-0\!{padding:calc(var(--spacing)*0)!important}.p-1{padding:calc(var(--spacing)*1)}.p-2{padding:calc(var(--spacing)*2)}.p-3{padding:calc(var(--spacing)*3)}.p-4{padding:calc(var(--spacing)*4)}.px-2{padding-inline:calc(var(--spacing)*2)}.px-3{padding-inline:calc(var(--spacing)*3)}.px-4{padding-inline:calc(var(--spacing)*4)}.py-1{padding-block:calc(var(--spacing)*1)}.py-2{padding-block:calc(var(--spacing)*2)}.py-4{padding-block:calc(var(--spacing)*4)}.pr-2{padding-right:calc(var(--spacing)*2)}.pl-4{padding-left:calc(var(--spacing)*4)}.pl-8{padding-left:calc(var(--spacing)*8)}.text-center{text-align:center}.text-left{text-align:left}.indent-\[-1rem\]{text-indent:-1rem}.text-3xl{font-size:var(--text-3xl);line-height:var(--tw-leading,var(--text-3xl--line-height))}.text-7xl{font-size:var(--text-7xl);line-height:var(--tw-leading,var(--text-7xl--line-height))}.text-8xl{font-size:var(--text-8xl);line-height:var(--tw-leading,var(--text-8xl--line-height))}.text-lg{font-size:var(--text-lg);line-height:var(--tw-leading,var(--text-lg--line-height))}.text-sm{font-size:var(--text-sm);line-height:var(--tw-leading,var(--text-sm--line-height))}.text-xl{font-size:var(--text-xl);line-height:var(--tw-leading,var(--text-xl--line-height))}.text-xs{font-size:var(--text-xs);line-height:var(--tw-leading,var(--text-xs--line-height))}.leading-\[2\.5\]{--tw-leading:2.5;line-height:2.5}.leading-none{--tw-leading:1;line-height:1}.font-bold{--tw-font-weight:var(--font-weight-bold);font-weight:var(--font-weight-bold)}.whitespace-pre-wrap{white-space:pre-wrap}.text-amber-800{color:var(--color-amber-800)}.text-black{color:var(--color-black)}.text-emerald-200{color:var(--color-emerald-200)}.text-emerald-300{color:var(--color-emerald-300)}.text-emerald-800{color:var(--color-emerald-800)}.text-gray-400{color:var(--color-gray-400)}.text-red-300{color:var(--color-red-300)}.text-red-800{color:var(--color-red-800)}.text-sky-300{color:var(--color-sky-300)}.text-sky-800{color:var(--color-sky-800)}.text-slate-300{color:var(--color-slate-300)}.text-slate-400{color:var(--color-slate-400)}.text-slate-500{color:var(--color-slate-500)}.text-white{color:var(--color-white)}.text-white\!{color:var(--color-white)!important}.text-white\/50{color:#ffffff80}@supports (color:color-mix(in lab,red,red)){.text-white\/50{color:color-mix(in oklab,var(--color-white)50%,transparent)}}.text-white\/90{color:#ffffffe6}@supports (color:color-mix(in lab,red,red)){.text-white\/90{color:color-mix(in oklab,var(--color-white)90%,transparent)}}.uppercase{text-transform:uppercase}.opacity-0{opacity:0}.opacity-50{opacity:.5}.opacity-100{opacity:1}.shadow-lg{--tw-shadow:0 10px 15px -3px var(--tw-shadow-color,#0000001a),0 4px 6px -4px var(--tw-shadow-color,#0000001a);box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.drop-shadow-sm{--tw-drop-shadow-size:drop-shadow(0 1px 2px var(--tw-drop-shadow-color,#00000026));--tw-drop-shadow:drop-shadow(var(--drop-shadow-sm));filter:var(--tw-blur,)var(--tw-brightness,)var(--tw-contrast,)var(--tw-grayscale,)var(--tw-hue-rotate,)var(--tw-invert,)var(--tw-saturate,)var(--tw-sepia,)var(--tw-drop-shadow,)}.drop-shadow-xs{--tw-drop-shadow-size:drop-shadow(0 1px 1px var(--tw-drop-shadow-color,#0000000d));--tw-drop-shadow:drop-shadow(var(--drop-shadow-xs));filter:var(--tw-blur,)var(--tw-brightness,)var(--tw-contrast,)var(--tw-grayscale,)var(--tw-hue-rotate,)var(--tw-invert,)var(--tw-saturate,)var(--tw-sepia,)var(--tw-drop-shadow,)}.drop-shadow-black\/20{--tw-drop-shadow-color:#0003}@supports (color:color-mix(in lab,red,red)){.drop-shadow-black\/20{--tw-drop-shadow-color:color-mix(in oklab,color-mix(in oklab,var(--color-black)20%,transparent)var(--tw-drop-shadow-alpha),transparent)}}.drop-shadow-black\/20{--tw-drop-shadow:var(--tw-drop-shadow-size)}.filter{filter:var(--tw-blur,)var(--tw-brightness,)var(--tw-contrast,)var(--tw-grayscale,)var(--tw-hue-rotate,)var(--tw-invert,)var(--tw-saturate,)var(--tw-sepia,)var(--tw-drop-shadow,)}.transition{transition-property:color,background-color,border-color,outline-color,text-decoration-color,fill,stroke,--tw-gradient-from,--tw-gradient-via,--tw-gradient-to,opacity,box-shadow,transform,translate,scale,rotate,filter,-webkit-backdrop-filter,backdrop-filter,display,visibility,content-visibility,overlay,pointer-events;transition-timing-function:var(--tw-ease,var(--default-transition-timing-function));transition-duration:var(--tw-duration,var(--default-transition-duration))}.duration-100{--tw-duration:.1s;transition-duration:.1s}.ease-in{--tw-ease:var(--ease-in);transition-timing-function:var(--ease-in)}.outline-none{--tw-outline-style:none;outline-style:none}.select-none{-webkit-user-select:none;user-select:none}.text-shadow-black\/20{--tw-text-shadow-color:#0003}@supports (color:color-mix(in lab,red,red)){.text-shadow-black\/20{--tw-text-shadow-color:color-mix(in oklab,color-mix(in oklab,var(--color-black)20%,transparent)var(--tw-text-shadow-alpha),transparent)}}.text-shadow-sm{text-shadow:0px 1px 0px var(--tw-text-shadow-color,#00000013),0px 1px 1px var(--tw-text-shadow-color,#00000013),0px 2px 2px var(--tw-text-shadow-color,#00000013)}.text-shadow-white\/50{--tw-text-shadow-color:#ffffff80}@supports (color:color-mix(in lab,red,red)){.text-shadow-white\/50{--tw-text-shadow-color:color-mix(in oklab,color-mix(in oklab,var(--color-white)50%,transparent)var(--tw-text-shadow-alpha),transparent)}}.text-shadow-xs{text-shadow:0px 1px 1px var(--tw-text-shadow-color,#0003)}.group-data-hover\:fill-white\/50:is(:where(.group)[data-hover] *){fill:#ffffff80}@supports (color:color-mix(in lab,red,red)){.group-data-hover\:fill-white\/50:is(:where(.group)[data-hover] *){fill:color-mix(in oklab,var(--color-white)50%,transparent)}}.group-data-open\:rotate-90:is(:where(.group)[data-open] *){rotate:90deg}.focus-within\:bg-white\/10:focus-within{background-color:#ffffff1a}@supports (color:color-mix(in lab,red,red)){.focus-within\:bg-white\/10:focus-within{background-color:color-mix(in oklab,var(--color-white)10%,transparent)}}@media (hover:hover){.hover\:bg-amber-500:hover{background-color:var(--color-amber-500)}.hover\:bg-emerald-500:hover{background-color:var(--color-emerald-500)}.hover\:bg-red-500:hover{background-color:var(--color-red-500)}.hover\:bg-sky-500:hover{background-color:var(--color-sky-500)}.hover\:bg-sky-950:hover{background-color:var(--color-sky-950)}.hover\:text-amber-950:hover{color:var(--color-amber-950)}.hover\:text-emerald-950:hover{color:var(--color-emerald-950)}.hover\:text-red-950:hover{color:var(--color-red-950)}.hover\:text-sky-300:hover{color:var(--color-sky-300)}.hover\:text-sky-950:hover{color:var(--color-sky-950)}.hover\:text-white:hover{color:var(--color-white)}}.focus\:border-emerald-300:focus{border-color:var(--color-emerald-300)}.focus\:border-teal-300:focus{border-color:var(--color-teal-300)}.focus\:bg-white\/10:focus{background-color:#ffffff1a}@supports (color:color-mix(in lab,red,red)){.focus\:bg-white\/10:focus{background-color:color-mix(in oklab,var(--color-white)10%,transparent)}}.focus\:text-black:focus{color:var(--color-black)}.data-active\:bg-black[data-active]{background-color:var(--color-black)}.data-active\:text-teal-300[data-active]{color:var(--color-teal-300)}.data-focus\:bg-black[data-focus]{background-color:var(--color-black)}.data-focus\:bg-white\/10[data-focus]{background-color:#ffffff1a}@supports (color:color-mix(in lab,red,red)){.data-focus\:bg-white\/10[data-focus]{background-color:color-mix(in oklab,var(--color-white)10%,transparent)}}.data-focus\:text-teal-300[data-focus]{color:var(--color-teal-300)}.data-selected\:font-bold[data-selected]{--tw-font-weight:var(--font-weight-bold);font-weight:var(--font-weight-bold)}.data-selected\:text-teal-300[data-selected]{color:var(--color-teal-300)}@media (min-width:48rem){.md\:relative{position:relative}.md\:block{display:block}.md\:flex{display:flex}.md\:hidden{display:none}.md\:w-50{width:calc(var(--spacing)*50)}.md\:w-80{width:calc(var(--spacing)*80)}.md\:bg-black\/80{background-color:#000c}@supports (color:color-mix(in lab,red,red)){.md\:bg-black\/80{background-color:color-mix(in oklab,var(--color-black)80%,transparent)}}.md\:text-sm{font-size:var(--text-sm);line-height:var(--tw-leading,var(--text-sm--line-height))}}.\[\&_code\]\:text-sky-300 code{color:var(--color-sky-300)}.\[\&_svg\]\:text-amber-400 svg{color:var(--color-amber-400)}.\[\&_svg\]\:text-emerald-400 svg{color:var(--color-emerald-400)}.\[\&_svg\]\:text-red-400 svg{color:var(--color-red-400)}.\[\&_svg\]\:text-sky-400 svg{color:var(--color-sky-400)}.\[\&_svg\]\:text-white\/60 svg{color:#fff9}@supports (color:color-mix(in lab,red,red)){.\[\&_svg\]\:text-white\/60 svg{color:color-mix(in oklab,var(--color-white)60%,transparent)}}}:root{font-family:system-ui,Avenir,Helvetica,Arial,sans-serif;font-size:12px;font-weight:400;line-height:1.5}@media only screen and (max-width:600px){:root{font-size:16px}}:root{color-scheme:dark;font-synthesis:none;text-rendering:optimizeLegibility;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}@keyframes background-gradient-animation{0%{background-position:0%}50%{background-position:100%}to{background-position:0%}}#root{background:linear-gradient(-45deg,var(--color-pink-500),var(--color-sky-500),var(--color-emerald-400));background-size:400% 400%;width:100dvw;height:100dvh;animation:20s infinite background-gradient-animation;overflow:auto}*{scrollbar-width:thin;scrollbar-color:var(--color-slate-600)transparent;outline:none;transition:color .25s,background-color .25s,border-color .25s,opacity .25s,outline-color .25s}main [data-link],main a{cursor:pointer;color:var(--color-teal-400)}:is(main [data-link],main a):hover{color:var(--color-teal-300)}[data-focus]{border:2px solid #0000}[data-focus]:focus{border:2px solid var(--color-teal-300)}[data-focus-within]{border:2px solid #0000}[data-focus-within]:focus-within{border:2px solid var(--color-teal-300)}[data-focus-within][data-focus-within=bold]{border-color:var(--color-teal-600)}[data-focus-within][data-focus-within=bold]:focus-within{border:2px solid var(--color-teal-300)}code{color:var(--color-slate-300)}@property --tw-rotate-x{syntax:"*";inherits:false}@property --tw-rotate-y{syntax:"*";inherits:false}@property --tw-rotate-z{syntax:"*";inherits:false}@property --tw-skew-x{syntax:"*";inherits:false}@property --tw-skew-y{syntax:"*";inherits:false}@property --tw-border-style{syntax:"*";inherits:false;initial-value:solid}@property --tw-leading{syntax:"*";inherits:false}@property --tw-font-weight{syntax:"*";inherits:false}@property --tw-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-shadow-color{syntax:"*";inherits:false}@property --tw-shadow-alpha{syntax:"<percentage>";inherits:false;initial-value:100%}@property --tw-inset-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-inset-shadow-color{syntax:"*";inherits:false}@property --tw-inset-shadow-alpha{syntax:"<percentage>";inherits:false;initial-value:100%}@property --tw-ring-color{syntax:"*";inherits:false}@property --tw-ring-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-inset-ring-color{syntax:"*";inherits:false}@property --tw-inset-ring-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-ring-inset{syntax:"*";inherits:false}@property --tw-ring-offset-width{syntax:"<length>";inherits:false;initial-value:0}@property --tw-ring-offset-color{syntax:"*";inherits:false;initial-value:#fff}@property --tw-ring-offset-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-blur{syntax:"*";inherits:false}@property --tw-brightness{syntax:"*";inherits:false}@property --tw-contrast{syntax:"*";inherits:false}@property --tw-grayscale{syntax:"*";inherits:false}@property --tw-hue-rotate{syntax:"*";inherits:false}@property --tw-invert{syntax:"*";inherits:false}@property --tw-opacity{syntax:"*";inherits:false}@property --tw-saturate{syntax:"*";inherits:false}@property --tw-sepia{syntax:"*";inherits:false}@property --tw-drop-shadow{syntax:"*";inherits:false}@property --tw-drop-shadow-color{syntax:"*";inherits:false}@property --tw-drop-shadow-alpha{syntax:"<percentage>";inherits:false;initial-value:100%}@property --tw-drop-shadow-size{syntax:"*";inherits:false}@property --tw-duration{syntax:"*";inherits:false}@property --tw-ease{syntax:"*";inherits:false}@property --tw-text-shadow-color{syntax:"*";inherits:false}@property --tw-text-shadow-alpha{syntax:"<percentage>";inherits:false;initial-value:100%}@keyframes spin{to{transform:rotate(360deg)}}
|