@tanstack/react-table 8.0.0-alpha.24 → 8.0.0-alpha.27

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.
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sources":["../../src/index.tsx"],"sourcesContent":["import * as React from 'react'\nexport * from '@tanstack/table-core'\n\nimport {\n createTableInstance,\n PartialKeys,\n Options,\n TableInstance,\n PartialGenerics,\n CreateTableFactoryOptions,\n Table,\n init,\n AnyGenerics,\n} from '@tanstack/table-core'\n\nexport type Renderable<TProps> =\n | React.ReactNode\n | React.FunctionComponent<TProps>\n | React.Component<TProps>\n\nexport const render = <TProps extends {}>(\n Comp: Renderable<TProps>,\n props: TProps\n): React.ReactNode =>\n !Comp ? null : isReactComponent(Comp) ? <Comp {...props} /> : Comp\n\nexport type Render = typeof render\n\nfunction isReactComponent(component: unknown): component is React.FC {\n return (\n isClassComponent(component) ||\n typeof component === 'function' ||\n isExoticComponent(component)\n )\n}\n\nfunction isClassComponent(component: any) {\n return (\n typeof component === 'function' &&\n (() => {\n const proto = Object.getPrototypeOf(component)\n return proto.prototype && proto.prototype.isReactComponent\n })()\n )\n}\n\nfunction isExoticComponent(component: any) {\n return (\n typeof component === 'object' &&\n typeof component.$$typeof === 'symbol' &&\n ['react.memo', 'react.forward_ref'].includes(component.$$typeof.description)\n )\n}\n\nconst { createTable, createTableFactory } = init({ render })\n\nexport { createTable, createTableFactory }\n\nexport function useTable<TGenerics extends AnyGenerics>(\n table: Table<TGenerics>,\n options: PartialKeys<\n Omit<\n Options<TGenerics>,\n keyof CreateTableFactoryOptions<any, any, any, any>\n >,\n 'state' | 'onStateChange'\n >\n): TableInstance<TGenerics> {\n // Compose in the generic options to the user options\n const resolvedOptions: Options<TGenerics> = {\n ...(table.__options ?? {}),\n state: {}, // Dummy state\n onStateChange: () => {}, // noop\n render,\n ...options,\n }\n\n // Create a new table instance and store it in state\n const [instance] = React.useState(() =>\n createTableInstance<TGenerics>(resolvedOptions)\n )\n\n // By default, manage table state here using the instance's initial state\n const [state, setState] = React.useState(() => instance.initialState)\n\n // Compose the default state above with any user state. This will allow the user\n // to only control a subset of the state if desired.\n instance.setOptions(prev => ({\n ...prev,\n ...options,\n state: {\n ...state,\n ...options.state,\n },\n // Similarly, we'll maintain both our internal state and any user-provided\n // state.\n onStateChange: updater => {\n setState(updater)\n options.onStateChange?.(updater)\n },\n }))\n\n return instance\n}\n"],"names":["render","Comp","props","isReactComponent","React","component","isClassComponent","isExoticComponent","proto","Object","getPrototypeOf","prototype","$$typeof","includes","description","init","createTable","createTableFactory","useTable","table","options","resolvedOptions","__options","state","onStateChange","useState","createTableInstance","instance","initialState","setState","setOptions","prev","updater"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;IAoBaA,MAAM,GAAG,SAATA,MAAS,CACpBC,IADoB,EAEpBC,KAFoB;AAAA,SAIpB,CAACD,IAAD,GAAQ,IAAR,GAAeE,gBAAgB,CAACF,IAAD,CAAhB,gBAAyBG,+BAAC,IAAD,EAAUF,KAAV,CAAzB,GAA+CD,IAJ1C;AAAA;;AAQtB,SAASE,gBAAT,CAA0BE,SAA1B,EAAqE;AACnE,SACEC,gBAAgB,CAACD,SAAD,CAAhB,IACA,OAAOA,SAAP,KAAqB,UADrB,IAEAE,iBAAiB,CAACF,SAAD,CAHnB;AAKD;;AAED,SAASC,gBAAT,CAA0BD,SAA1B,EAA0C;AACxC,SACE,OAAOA,SAAP,KAAqB,UAArB,IACC,YAAM;AACL,QAAMG,KAAK,GAAGC,MAAM,CAACC,cAAP,CAAsBL,SAAtB,CAAd;AACA,WAAOG,KAAK,CAACG,SAAN,IAAmBH,KAAK,CAACG,SAAN,CAAgBR,gBAA1C;AACD,GAHD,EAFF;AAOD;;AAED,SAASI,iBAAT,CAA2BF,SAA3B,EAA2C;AACzC,SACE,OAAOA,SAAP,KAAqB,QAArB,IACA,OAAOA,SAAS,CAACO,QAAjB,KAA8B,QA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.tsx"],"sourcesContent":["import * as React from 'react'\nexport * from '@tanstack/table-core'\n\nimport {\n createTableInstance,\n PartialKeys,\n Options,\n TableInstance,\n CreateTableFactoryOptions,\n Table,\n init,\n AnyGenerics,\n} from '@tanstack/table-core'\n\nexport type Renderable<TProps> =\n | React.ReactNode\n | React.FunctionComponent<TProps>\n | React.Component<TProps>\n\nexport const render = <TProps extends {}>(\n Comp: Renderable<TProps>,\n props: TProps\n): React.ReactNode =>\n !Comp ? null : isReactComponent(Comp) ? <Comp {...props} /> : Comp\n\nexport type Render = typeof render\n\nfunction isReactComponent(component: unknown): component is React.FC {\n return (\n isClassComponent(component) ||\n typeof component === 'function' ||\n isExoticComponent(component)\n )\n}\n\nfunction isClassComponent(component: any) {\n return (\n typeof component === 'function' &&\n (() => {\n const proto = Object.getPrototypeOf(component)\n return proto.prototype && proto.prototype.isReactComponent\n })()\n )\n}\n\nfunction isExoticComponent(component: any) {\n return (\n typeof component === 'object' &&\n typeof component.$$typeof === 'symbol' &&\n ['react.memo', 'react.forward_ref'].includes(component.$$typeof.description)\n )\n}\n\nconst { createTable, createTableFactory } = init({ render })\n\nexport { createTable, createTableFactory }\n\nexport function useTable<TGenerics extends AnyGenerics>(\n table: Table<TGenerics>,\n options: PartialKeys<\n Omit<\n Options<TGenerics>,\n keyof CreateTableFactoryOptions<any, any, any, any>\n >,\n 'state' | 'onStateChange'\n >\n): TableInstance<TGenerics> {\n // Compose in the generic options to the user options\n const resolvedOptions: Options<TGenerics> = {\n ...(table.__options ?? {}),\n state: {}, // Dummy state\n onStateChange: () => {}, // noop\n render,\n ...options,\n }\n\n // Create a new table instance and store it in state\n const [instance] = React.useState(() =>\n createTableInstance<TGenerics>(resolvedOptions)\n )\n\n // By default, manage table state here using the instance's initial state\n const [state, setState] = React.useState(() => instance.initialState)\n\n // Compose the default state above with any user state. This will allow the user\n // to only control a subset of the state if desired.\n instance.setOptions(prev => ({\n ...prev,\n ...options,\n state: {\n ...state,\n ...options.state,\n },\n // Similarly, we'll maintain both our internal state and any user-provided\n // state.\n onStateChange: updater => {\n setState(updater)\n options.onStateChange?.(updater)\n },\n }))\n\n return instance\n}\n"],"names":["render","Comp","props","isReactComponent","React","component","isClassComponent","isExoticComponent","proto","Object","getPrototypeOf","prototype","$$typeof","includes","description","init","createTable","createTableFactory","useTable","table","options","resolvedOptions","__options","state","onStateChange","useState","createTableInstance","instance","initialState","setState","setOptions","prev","updater"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;IAmBaA,MAAM,GAAG,SAATA,MAAS,CACpBC,IADoB,EAEpBC,KAFoB;AAAA,SAIpB,CAACD,IAAD,GAAQ,IAAR,GAAeE,gBAAgB,CAACF,IAAD,CAAhB,gBAAyBG,+BAAC,IAAD,EAAUF,KAAV,CAAzB,GAA+CD,IAJ1C;AAAA;;AAQtB,SAASE,gBAAT,CAA0BE,SAA1B,EAAqE;AACnE,SACEC,gBAAgB,CAACD,SAAD,CAAhB,IACA,OAAOA,SAAP,KAAqB,UADrB,IAEAE,iBAAiB,CAACF,SAAD,CAHnB;AAKD;;AAED,SAASC,gBAAT,CAA0BD,SAA1B,EAA0C;AACxC,SACE,OAAOA,SAAP,KAAqB,UAArB,IACC,YAAM;AACL,QAAMG,KAAK,GAAGC,MAAM,CAACC,cAAP,CAAsBL,SAAtB,CAAd;AACA,WAAOG,KAAK,CAACG,SAAN,IAAmBH,KAAK,CAACG,SAAN,CAAgBR,gBAA1C;AACD,GAHD,EAFF;AAOD;;AAED,SAASI,iBAAT,CAA2BF,SAA3B,EAA2C;AACzC,SACE,OAAOA,SAAP,KAAqB,QAArB,IACA,OAAOA,SAAS,CAACO,QAAjB,KAA8B,QAD9B,IAEA,CAAC,YAAD,EAAe,mBAAf,EAAoCC,QAApC,CAA6CR,SAAS,CAACO,QAAV,CAAmBE,WAAhE,CAHF;AAKD;;YAE2CC,cAAI,CAAC;AAAEf,EAAAA,MAAM,EAANA;AAAF,CAAD,CAAhD;AAAA,IAAQgB,WAAR,SAAQA,WAAR;AAAA,IAAqBC,kBAArB,SAAqBA;AAId,SAASC,QAAT,CACLC,KADK,EAELC,OAFK,EASqB;AAAA;;AAC1B;AACA,MAAMC,eAAmC,gEACnCF,KAAK,CAACG,SAD6B,+BAChB,EADgB;AAEvCC,IAAAA,KAAK,EAAE,EAFgC;AAE5B;AACXC,IAAAA,aAAa,EAAE,yBAAM,EAHkB;AAGd;AACzBxB,IAAAA,MAAM,EAANA;AAJuC,KAKpCoB,OALoC,CAAzC,CAF0B;;;AAW1B,wBAAmBhB,gBAAK,CAACqB,QAAN,CAAe;AAAA,WAChCC,6BAAmB,CAAYL,eAAZ,CADa;AAAA,GAAf,CAAnB;AAAA,MAAOM,QAAP,sBAX0B;;;AAgB1B,yBAA0BvB,gBAAK,CAACqB,QAAN,CAAe;AAAA,WAAME,QAAQ,CAACC,YAAf;AAAA,GAAf,CAA1B;AAAA,MAAOL,KAAP;AAAA,MAAcM,QAAd,uBAhB0B;AAmB1B;;;AACAF,EAAAA,QAAQ,CAACG,UAAT,CAAoB,UAAAC,IAAI;AAAA,oDACnBA,IADmB,EAEnBX,OAFmB;AAGtBG,MAAAA,KAAK,2CACAA,KADA,EAEAH,OAAO,CAACG,KAFR,CAHiB;AAOtB;AACA;AACAC,MAAAA,aAAa,EAAE,uBAAAQ,OAAO,EAAI;AACxBH,QAAAA,QAAQ,CAACG,OAAD,CAAR;AACAZ,QAAAA,OAAO,CAACI,aAAR,oBAAAJ,OAAO,CAACI,aAAR,CAAwBQ,OAAxB;AACD;AAZqB;AAAA,GAAxB;AAeA,SAAOL,QAAP;AACD;;;;;;;;;;;;;"}
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sources":["../../src/index.tsx"],"sourcesContent":["import * as React from 'react'\nexport * from '@tanstack/table-core'\n\nimport {\n createTableInstance,\n PartialKeys,\n Options,\n TableInstance,\n PartialGenerics,\n CreateTableFactoryOptions,\n Table,\n init,\n AnyGenerics,\n} from '@tanstack/table-core'\n\nexport type Renderable<TProps> =\n | React.ReactNode\n | React.FunctionComponent<TProps>\n | React.Component<TProps>\n\nexport const render = <TProps extends {}>(\n Comp: Renderable<TProps>,\n props: TProps\n): React.ReactNode =>\n !Comp ? null : isReactComponent(Comp) ? <Comp {...props} /> : Comp\n\nexport type Render = typeof render\n\nfunction isReactComponent(component: unknown): component is React.FC {\n return (\n isClassComponent(component) ||\n typeof component === 'function' ||\n isExoticComponent(component)\n )\n}\n\nfunction isClassComponent(component: any) {\n return (\n typeof component === 'function' &&\n (() => {\n const proto = Object.getPrototypeOf(component)\n return proto.prototype && proto.prototype.isReactComponent\n })()\n )\n}\n\nfunction isExoticComponent(component: any) {\n return (\n typeof component === 'object' &&\n typeof component.$$typeof === 'symbol' &&\n ['react.memo', 'react.forward_ref'].includes(component.$$typeof.description)\n )\n}\n\nconst { createTable, createTableFactory } = init({ render })\n\nexport { createTable, createTableFactory }\n\nexport function useTable<TGenerics extends AnyGenerics>(\n table: Table<TGenerics>,\n options: PartialKeys<\n Omit<\n Options<TGenerics>,\n keyof CreateTableFactoryOptions<any, any, any, any>\n >,\n 'state' | 'onStateChange'\n >\n): TableInstance<TGenerics> {\n // Compose in the generic options to the user options\n const resolvedOptions: Options<TGenerics> = {\n ...(table.__options ?? {}),\n state: {}, // Dummy state\n onStateChange: () => {}, // noop\n render,\n ...options,\n }\n\n // Create a new table instance and store it in state\n const [instance] = React.useState(() =>\n createTableInstance<TGenerics>(resolvedOptions)\n )\n\n // By default, manage table state here using the instance's initial state\n const [state, setState] = React.useState(() => instance.initialState)\n\n // Compose the default state above with any user state. This will allow the user\n // to only control a subset of the state if desired.\n instance.setOptions(prev => ({\n ...prev,\n ...options,\n state: {\n ...state,\n ...options.state,\n },\n // Similarly, we'll maintain both our internal state and any user-provided\n // state.\n onStateChange: updater => {\n setState(updater)\n options.onStateChange?.(updater)\n },\n }))\n\n return instance\n}\n"],"names":["render","Comp","props","isReactComponent","component","isClassComponent","isExoticComponent","proto","Object","getPrototypeOf","prototype","$$typeof","includes","description","init","createTable","createTableFactory","useTable","table","options","resolvedOptions","__options","state","onStateChange","React","useState","createTableInstance","instance","initialState","setState","setOptions","prev","updater"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;IAoBaA,MAAM,GAAG,SAATA,MAAS,CACpBC,IADoB,EAEpBC,KAFoB;AAAA,SAIpB,CAACD,IAAD,GAAQ,IAAR,GAAeE,gBAAgB,CAACF,IAAD,CAAhB,gBAAyB,oBAAC,IAAD,EAAUC,KAAV,CAAzB,GAA+CD,IAJ1C;AAAA;;AAQtB,SAASE,gBAAT,CAA0BC,SAA1B,EAAqE;AACnE,SACEC,gBAAgB,CAACD,SAAD,CAAhB,IACA,OAAOA,SAAP,KAAqB,UADrB,IAEAE,iBAAiB,CAACF,SAAD,CAHnB;AAKD;;AAED,SAASC,gBAAT,CAA0BD,SAA1B,EAA0C;AACxC,SACE,OAAOA,SAAP,KAAqB,UAArB,IACC,YAAM;AACL,QAAMG,KAAK,GAAGC,MAAM,CAACC,cAAP,CAAsBL,SAAtB,CAAd;AACA,WAAOG,KAAK,CAACG,SAAN,IAAmBH,KAAK,CAACG,SAAN,CAAgBP,gBAA1C;AACD,GAHD,EAFF;AAOD;;AAED,SAASG,iBAAT,CAA2BF,SAA3B,EAA2C;AACzC,SACE,OAAOA,SAAP,KAAqB,QAArB,IACA,OAAOA,SAAS,CAACO,QAAjB,KAA8B,QAD9B,IAEA,CAAC,YAAD,EAAe,mBAAf,EAAoCC,QAApC,CAA6CR,SAAS,CAACO,QAAV,CAAmBE,WAAhE,CAHF;AAKD;;YAE2CC,IAAI,CAAC;AAAEd,EAAAA,MAAM,EAANA;AAAF,CAAD,CAAhD;AAAA,IAAQe,WAAR,SAAQA,WAAR;AAAA,IAAqBC,kBAArB,SAAqBA;AAId,SAASC,QAAT,CACLC,KADK,EAELC,OAFK,EASqB;AAAA;;AAC1B;AACA,MAAMC,eAAmC,oCACnCF,KAAK,CAACG,SAD6B,+BAChB,EADgB;AAEvCC,IAAAA,KAAK,EAAE,EAFgC;AAE5B;AACXC,IAAAA,aAAa,EAAE,yBAAM,EAHkB;AAGd;AACzBvB,IAAAA,MAAM,EAANA;AAJuC,KAKpCmB,OALoC,CAAzC,CAF0B;;;AAW1B,wBAAmBK,KAAK,CAACC,QAAN,CAAe;AAAA,WAChCC,mBAAmB,CAAYN,eAAZ,CADa;AAAA,GAAf,CAAnB;AAAA,MAAOO,QAAP,sBAX0B;;;AAgB1B,yBAA0BH,KAAK,CAACC,QAAN,CAAe;AAAA,WAAME,QAAQ,CAACC,YAAf;AAAA,GAAf,CAA1B;AAAA,MAAON,KAAP;AAAA,MAAcO,QAAd,uBAhB0B;AAmB1B;;;AACAF,EAAAA,QAAQ,CAACG,UAAT,CAAoB,UAAAC,IAAI;AAAA,wBACnBA,IADmB,EAEnBZ,OAFmB;AAGtBG,MAAAA,KAAK,eACAA,KADA,EAEAH,OAAO,CAACG,KAFR,CAHiB;AAOtB;AACA;AACAC,MAAAA,aAAa,EAAE,uBAAAS,OAAO,EAAI;AACxBH,QAAAA,QAAQ,CAACG,OAAD,CAAR;AACAb,QAAAA,OAAO,CAACI,aAAR,oBAAAJ,OAAO,CAACI,aAAR,CAAwBS,OAAxB;AACD;AAZqB;AAAA,GAAxB;AAeA,SAAOL,QAAP;AACD;;;;"}
1
+ {"version":3,"file":"index.js","sources":["../../src/index.tsx"],"sourcesContent":["import * as React from 'react'\nexport * from '@tanstack/table-core'\n\nimport {\n createTableInstance,\n PartialKeys,\n Options,\n TableInstance,\n CreateTableFactoryOptions,\n Table,\n init,\n AnyGenerics,\n} from '@tanstack/table-core'\n\nexport type Renderable<TProps> =\n | React.ReactNode\n | React.FunctionComponent<TProps>\n | React.Component<TProps>\n\nexport const render = <TProps extends {}>(\n Comp: Renderable<TProps>,\n props: TProps\n): React.ReactNode =>\n !Comp ? null : isReactComponent(Comp) ? <Comp {...props} /> : Comp\n\nexport type Render = typeof render\n\nfunction isReactComponent(component: unknown): component is React.FC {\n return (\n isClassComponent(component) ||\n typeof component === 'function' ||\n isExoticComponent(component)\n )\n}\n\nfunction isClassComponent(component: any) {\n return (\n typeof component === 'function' &&\n (() => {\n const proto = Object.getPrototypeOf(component)\n return proto.prototype && proto.prototype.isReactComponent\n })()\n )\n}\n\nfunction isExoticComponent(component: any) {\n return (\n typeof component === 'object' &&\n typeof component.$$typeof === 'symbol' &&\n ['react.memo', 'react.forward_ref'].includes(component.$$typeof.description)\n )\n}\n\nconst { createTable, createTableFactory } = init({ render })\n\nexport { createTable, createTableFactory }\n\nexport function useTable<TGenerics extends AnyGenerics>(\n table: Table<TGenerics>,\n options: PartialKeys<\n Omit<\n Options<TGenerics>,\n keyof CreateTableFactoryOptions<any, any, any, any>\n >,\n 'state' | 'onStateChange'\n >\n): TableInstance<TGenerics> {\n // Compose in the generic options to the user options\n const resolvedOptions: Options<TGenerics> = {\n ...(table.__options ?? {}),\n state: {}, // Dummy state\n onStateChange: () => {}, // noop\n render,\n ...options,\n }\n\n // Create a new table instance and store it in state\n const [instance] = React.useState(() =>\n createTableInstance<TGenerics>(resolvedOptions)\n )\n\n // By default, manage table state here using the instance's initial state\n const [state, setState] = React.useState(() => instance.initialState)\n\n // Compose the default state above with any user state. This will allow the user\n // to only control a subset of the state if desired.\n instance.setOptions(prev => ({\n ...prev,\n ...options,\n state: {\n ...state,\n ...options.state,\n },\n // Similarly, we'll maintain both our internal state and any user-provided\n // state.\n onStateChange: updater => {\n setState(updater)\n options.onStateChange?.(updater)\n },\n }))\n\n return instance\n}\n"],"names":["render","Comp","props","isReactComponent","component","isClassComponent","isExoticComponent","proto","Object","getPrototypeOf","prototype","$$typeof","includes","description","init","createTable","createTableFactory","useTable","table","options","resolvedOptions","__options","state","onStateChange","React","useState","createTableInstance","instance","initialState","setState","setOptions","prev","updater"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;IAmBaA,MAAM,GAAG,SAATA,MAAS,CACpBC,IADoB,EAEpBC,KAFoB;AA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AmB,CAAYN,eAAZ,CADa;AAAA,GAAf,CAAnB;AAAA,MAAOO,QAAP,sBAX0B;;;AAgB1B,yBAA0BH,KAAK,CAACC,QAAN,CAAe;AAAA,WAAME,QAAQ,CAACC,YAAf;AAAA,GAAf,CAA1B;AAAA,MAAON,KAAP;AAAA,MAAcO,QAAd,uBAhB0B;AAmB1B;;;AACAF,EAAAA,QAAQ,CAACG,UAAT,CAAoB,UAAAC,IAAI;AAAA,wBACnBA,IADmB,EAEnBZ,OAFmB;AAGtBG,MAAAA,KAAK,eACAA,KADA,EAEAH,OAAO,CAACG,KAFR,CAHiB;AAOtB;AACA;AACAC,MAAAA,aAAa,EAAE,uBAAAS,OAAO,EAAI;AACxBH,QAAAA,QAAQ,CAACG,OAAD,CAAR;AACAb,QAAAA,OAAO,CAACI,aAAR,oBAAAJ,OAAO,CAACI,aAAR,CAAwBS,OAAxB;AACD;AAZqB;AAAA,GAAxB;AAeA,SAAOL,QAAP;AACD;;;;"}
@@ -2669,7 +2669,7 @@ var drawChart = (function (exports) {
2669
2669
  </script>
2670
2670
  <script>
2671
2671
  /*<!--*/
2672
- const data = {"version":2,"tree":{"name":"root","children":[{"name":"index.production.js","children":[{"uid":"5980-107","name":"\u0000rollupPluginBabelHelpers.js"},{"name":"packages/react-table/src/index.tsx","uid":"5980-109"}]}],"isRoot":true},"nodeParts":{"5980-107":{"renderedLength":410,"gzipLength":231,"brotliLength":0,"mainUid":"5980-106"},"5980-109":{"renderedLength":2378,"gzipLength":855,"brotliLength":0,"mainUid":"5980-108"}},"nodeMetas":{"5980-106":{"id":"\u0000rollupPluginBabelHelpers.js","moduleParts":{"index.production.js":"5980-107"},"imported":[],"importedBy":[{"uid":"5980-108"}]},"5980-108":{"id":"/packages/react-table/src/index.tsx","moduleParts":{"index.production.js":"5980-109"},"imported":[{"uid":"5980-106"},{"uid":"5980-110"},{"uid":"5980-111"}],"importedBy":[],"isEntry":true},"5980-110":{"id":"react","moduleParts":{},"imported":[],"importedBy":[{"uid":"5980-108"}],"isExternal":true},"5980-111":{"id":"@tanstack/table-core","moduleParts":{},"imported":[],"importedBy":[{"uid":"5980-108"}],"isExternal":true}},"env":{"rollup":"2.66.0"},"options":{"gzip":true,"brotli":false,"sourcemap":false}};
2672
+ const data = {"version":2,"tree":{"name":"root","children":[{"name":"index.production.js","children":[{"uid":"4339-109","name":"\u0000rollupPluginBabelHelpers.js"},{"name":"packages/react-table/src/index.tsx","uid":"4339-111"}]}],"isRoot":true},"nodeParts":{"4339-109":{"renderedLength":410,"gzipLength":231,"brotliLength":0,"mainUid":"4339-108"},"4339-111":{"renderedLength":2378,"gzipLength":855,"brotliLength":0,"mainUid":"4339-110"}},"nodeMetas":{"4339-108":{"id":"\u0000rollupPluginBabelHelpers.js","moduleParts":{"index.production.js":"4339-109"},"imported":[],"importedBy":[{"uid":"4339-110"}]},"4339-110":{"id":"/packages/react-table/src/index.tsx","moduleParts":{"index.production.js":"4339-111"},"imported":[{"uid":"4339-108"},{"uid":"4339-112"},{"uid":"4339-113"}],"importedBy":[],"isEntry":true},"4339-112":{"id":"react","moduleParts":{},"imported":[],"importedBy":[{"uid":"4339-110"}],"isExternal":true},"4339-113":{"id":"@tanstack/table-core","moduleParts":{},"imported":[],"importedBy":[{"uid":"4339-110"}],"isExternal":true}},"env":{"rollup":"2.66.0"},"options":{"gzip":true,"brotli":false,"sourcemap":false}};
2673
2673
 
2674
2674
  const run = () => {
2675
2675
  const width = window.innerWidth;
@@ -7,12 +7,12 @@
7
7
  "name": "index.production.js",
8
8
  "children": [
9
9
  {
10
- "uid": "5980-113",
10
+ "uid": "4339-115",
11
11
  "name": "\u0000rollupPluginBabelHelpers.js"
12
12
  },
13
13
  {
14
14
  "name": "packages/react-table/src/index.tsx",
15
- "uid": "5980-115"
15
+ "uid": "4339-117"
16
16
  }
17
17
  ]
18
18
  }
@@ -20,69 +20,69 @@
20
20
  "isRoot": true
21
21
  },
22
22
  "nodeParts": {
23
- "5980-113": {
23
+ "4339-115": {
24
24
  "renderedLength": 410,
25
25
  "gzipLength": 231,
26
26
  "brotliLength": 0,
27
- "mainUid": "5980-112"
27
+ "mainUid": "4339-114"
28
28
  },
29
- "5980-115": {
29
+ "4339-117": {
30
30
  "renderedLength": 2378,
31
31
  "gzipLength": 855,
32
32
  "brotliLength": 0,
33
- "mainUid": "5980-114"
33
+ "mainUid": "4339-116"
34
34
  }
35
35
  },
36
36
  "nodeMetas": {
37
- "5980-112": {
37
+ "4339-114": {
38
38
  "id": "\u0000rollupPluginBabelHelpers.js",
39
39
  "moduleParts": {
40
- "index.production.js": "5980-113"
40
+ "index.production.js": "4339-115"
41
41
  },
42
42
  "imported": [],
43
43
  "importedBy": [
44
44
  {
45
- "uid": "5980-114"
45
+ "uid": "4339-116"
46
46
  }
47
47
  ]
48
48
  },
49
- "5980-114": {
49
+ "4339-116": {
50
50
  "id": "/packages/react-table/src/index.tsx",
51
51
  "moduleParts": {
52
- "index.production.js": "5980-115"
52
+ "index.production.js": "4339-117"
53
53
  },
54
54
  "imported": [
55
55
  {
56
- "uid": "5980-112"
56
+ "uid": "4339-114"
57
57
  },
58
58
  {
59
- "uid": "5980-116"
59
+ "uid": "4339-118"
60
60
  },
61
61
  {
62
- "uid": "5980-117"
62
+ "uid": "4339-119"
63
63
  }
64
64
  ],
65
65
  "importedBy": [],
66
66
  "isEntry": true
67
67
  },
68
- "5980-116": {
68
+ "4339-118": {
69
69
  "id": "react",
70
70
  "moduleParts": {},
71
71
  "imported": [],
72
72
  "importedBy": [
73
73
  {
74
- "uid": "5980-114"
74
+ "uid": "4339-116"
75
75
  }
76
76
  ],
77
77
  "isExternal": true
78
78
  },
79
- "5980-117": {
79
+ "4339-119": {
80
80
  "id": "@tanstack/table-core",
81
81
  "moduleParts": {},
82
82
  "imported": [],
83
83
  "importedBy": [
84
84
  {
85
- "uid": "5980-114"
85
+ "uid": "4339-116"
86
86
  }
87
87
  ],
88
88
  "isExternal": true
@@ -6,7 +6,7 @@ export declare const render: <TProps extends {}>(Comp: Renderable<TProps>, props
6
6
  export declare type Render = typeof render;
7
7
  declare const createTable: import("@tanstack/table-core").CreateTableFactory<import("@tanstack/table-core").Overwrite<Partial<import("@tanstack/table-core").DefaultGenerics>, {
8
8
  Render: <TProps extends {}>(Comp: Renderable<TProps>, props: TProps) => React.ReactNode;
9
- }>>, createTableFactory: <TGenerics extends Partial<import("@tanstack/table-core").DefaultGenerics>>(options?: CreateTableFactoryOptions<(<TProps extends {}>(Comp: Renderable<TProps>, props: TProps) => React.ReactNode), any, any, any> | undefined) => import("@tanstack/table-core").CreateTableFactory<import("@tanstack/table-core").Overwrite<TGenerics, {
9
+ }>>, createTableFactory: <TGenerics extends AnyGenerics>(options: CreateTableFactoryOptions<(<TProps extends {}>(Comp: Renderable<TProps>, props: TProps) => React.ReactNode), any, any, any>) => import("@tanstack/table-core").CreateTableFactory<import("@tanstack/table-core").Overwrite<TGenerics, {
10
10
  Render: <TProps extends {}>(Comp: Renderable<TProps>, props: TProps) => React.ReactNode;
11
11
  }>>;
12
12
  export { createTable, createTableFactory };
@@ -1 +1 @@
1
- {"version":3,"file":"index.development.js","sources":["../../src/index.tsx"],"sourcesContent":["import * as React from 'react'\nexport * from '@tanstack/table-core'\n\nimport {\n createTableInstance,\n PartialKeys,\n Options,\n TableInstance,\n PartialGenerics,\n CreateTableFactoryOptions,\n Table,\n init,\n AnyGenerics,\n} from '@tanstack/table-core'\n\nexport type Renderable<TProps> =\n | React.ReactNode\n | React.FunctionComponent<TProps>\n | React.Component<TProps>\n\nexport const render = <TProps extends {}>(\n Comp: Renderable<TProps>,\n props: TProps\n): React.ReactNode =>\n !Comp ? null : isReactComponent(Comp) ? <Comp {...props} /> : Comp\n\nexport type Render = typeof render\n\nfunction isReactComponent(component: unknown): component is React.FC {\n return (\n isClassComponent(component) ||\n typeof component === 'function' ||\n isExoticComponent(component)\n )\n}\n\nfunction isClassComponent(component: any) {\n return (\n typeof component === 'function' &&\n (() => {\n const proto = Object.getPrototypeOf(component)\n return proto.prototype && proto.prototype.isReactComponent\n })()\n )\n}\n\nfunction isExoticComponent(component: any) {\n return (\n typeof component === 'object' &&\n typeof component.$$typeof === 'symbol' &&\n ['react.memo', 'react.forward_ref'].includes(component.$$typeof.description)\n )\n}\n\nconst { createTable, createTableFactory } = init({ render })\n\nexport { createTable, createTableFactory }\n\nexport function useTable<TGenerics extends AnyGenerics>(\n table: Table<TGenerics>,\n options: PartialKeys<\n Omit<\n Options<TGenerics>,\n keyof CreateTableFactoryOptions<any, any, any, any>\n >,\n 'state' | 'onStateChange'\n >\n): TableInstance<TGenerics> {\n // Compose in the generic options to the user options\n const resolvedOptions: Options<TGenerics> = {\n ...(table.__options ?? {}),\n state: {}, // Dummy state\n onStateChange: () => {}, // noop\n render,\n ...options,\n }\n\n // Create a new table instance and store it in state\n const [instance] = React.useState(() =>\n createTableInstance<TGenerics>(resolvedOptions)\n )\n\n // By default, manage table state here using the instance's initial state\n const [state, setState] = React.useState(() => instance.initialState)\n\n // Compose the default state above with any user state. This will allow the user\n // to only control a subset of the state if desired.\n instance.setOptions(prev => ({\n ...prev,\n ...options,\n state: {\n ...state,\n ...options.state,\n },\n // Similarly, we'll maintain both our internal state and any user-provided\n // state.\n onStateChange: updater => {\n setState(updater)\n options.onStateChange?.(updater)\n },\n }))\n\n return instance\n}\n"],"names":["render","Comp","props","isReactComponent","React","component","isClassComponent","isExoticComponent","proto","Object","getPrototypeOf","prototype","$$typeof","includes","description","init","createTable","createTableFactory","useTable","table","options","resolvedOptions","__options","state","onStateChange","useState","createTableInstance","instance","initialState","setState","setOptions","prev","updater"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;MAoBaA,MAAM,GAAG,SAATA,MAAS,CACpBC,IADoB,EAEpBC,KAFoB;EAAA,SAIpB,CAACD,IAAD,GAAQ,IAAR,GAAeE,gBAAgB,CAACF,IAAD,CAAhB,gBAAyBG,+BAAC,IAAD,EAAUF,KAAV,CAAzB,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AAN,CAAe;EAAA,WAAME,QAAQ,CAACC,YAAf;EAAA,GAAf,CAA1B;EAAA,MAAOL,KAAP;EAAA,MAAcM,QAAd,uBAhB0B;EAmB1B;;;EACAF,EAAAA,QAAQ,CAACG,UAAT,CAAoB,UAAAC,IAAI;EAAA,wBACnBA,IADmB,EAEnBX,OAFmB;EAGtBG,MAAAA,KAAK,eACAA,KADA,EAEAH,OAAO,CAACG,KAFR,CAHiB;EAOtB;EACA;EACAC,MAAAA,aAAa,EAAE,uBAAAQ,OAAO,EAAI;EACxBH,QAAAA,QAAQ,CAACG,OAAD,CAAR;EACAZ,QAAAA,OAAO,CAACI,aAAR,oBAAAJ,OAAO,CAACI,aAAR,CAAwBQ,OAAxB;EACD;EAZqB;EAAA,GAAxB;EAeA,SAAOL,QAAP;EACD;;;;;;;;;;;;;;;;;;;"}
1
+ {"version":3,"file":"index.development.js","sources":["../../src/index.tsx"],"sourcesContent":["import * as React from 'react'\nexport * from '@tanstack/table-core'\n\nimport {\n createTableInstance,\n PartialKeys,\n Options,\n TableInstance,\n CreateTableFactoryOptions,\n Table,\n init,\n AnyGenerics,\n} from '@tanstack/table-core'\n\nexport type Renderable<TProps> =\n | React.ReactNode\n | React.FunctionComponent<TProps>\n | React.Component<TProps>\n\nexport const render = <TProps extends {}>(\n Comp: Renderable<TProps>,\n props: TProps\n): React.ReactNode =>\n !Comp ? null : isReactComponent(Comp) ? <Comp {...props} /> : Comp\n\nexport type Render = typeof render\n\nfunction isReactComponent(component: unknown): component is React.FC {\n return (\n isClassComponent(component) ||\n typeof component === 'function' ||\n isExoticComponent(component)\n )\n}\n\nfunction isClassComponent(component: any) {\n return (\n typeof component === 'function' &&\n (() => {\n const proto = Object.getPrototypeOf(component)\n return proto.prototype && proto.prototype.isReactComponent\n })()\n )\n}\n\nfunction isExoticComponent(component: any) {\n return (\n typeof component === 'object' &&\n typeof component.$$typeof === 'symbol' &&\n ['react.memo', 'react.forward_ref'].includes(component.$$typeof.description)\n )\n}\n\nconst { createTable, createTableFactory } = init({ render })\n\nexport { createTable, createTableFactory }\n\nexport function useTable<TGenerics extends AnyGenerics>(\n table: Table<TGenerics>,\n options: PartialKeys<\n Omit<\n Options<TGenerics>,\n keyof CreateTableFactoryOptions<any, any, any, any>\n >,\n 'state' | 'onStateChange'\n >\n): TableInstance<TGenerics> {\n // Compose in the generic options to the user options\n const resolvedOptions: Options<TGenerics> = {\n ...(table.__options ?? {}),\n state: {}, // Dummy state\n onStateChange: () => {}, // noop\n render,\n ...options,\n }\n\n // Create a new table instance and store it in state\n const [instance] = React.useState(() =>\n createTableInstance<TGenerics>(resolvedOptions)\n )\n\n // By default, manage table state here using the instance's initial state\n const [state, setState] = React.useState(() => instance.initialState)\n\n // Compose the default state above with any user state. This will allow the user\n // to only control a subset of the state if desired.\n instance.setOptions(prev => ({\n ...prev,\n ...options,\n state: {\n ...state,\n ...options.state,\n },\n // Similarly, we'll maintain both our internal state and any user-provided\n // state.\n onStateChange: updater => {\n setState(updater)\n options.onStateChange?.(updater)\n },\n }))\n\n return instance\n}\n"],"names":["render","Comp","props","isReactComponent","React","component","isClassComponent","isExoticComponent","proto","Object","getPrototypeOf","prototype","$$typeof","includes","description","init","createTable","createTableFactory","useTable","table","options","resolvedOptions","__options","state","onStateChange","useState","createTableInstance","instance","initialState","setState","setOptions","prev","updater"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;MAmBaA,MAAM,GAAG,SAATA,MAAS,CACpBC,IADoB,EAEpBC,KAFoB;EAAA,SAIpB,CAACD,IAAD,GAAQ,IAAR,GAAeE,gBAAgB,CAACF,IAAD,CAAhB,gBAAyBG,+BAAC,IAAD,EAAUF,KAAV,CAAzB,GAA+CD,IAJ1C;EAAA;;EAQtB,SAASE,gBAAT,CAA0BE,SAA1B,EAAqE;EACnE,SACEC,gBAAgB,CAACD,SAAD,CAAhB,IACA,OAAOA,SAAP,KAAqB,UADrB,IAEAE,iBAAiB,CA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oB,UAAAC,IAAI;EAAA,wBACnBA,IADmB,EAEnBX,OAFmB;EAGtBG,MAAAA,KAAK,eACAA,KADA,EAEAH,OAAO,CAACG,KAFR,CAHiB;EAOtB;EACA;EACAC,MAAAA,aAAa,EAAE,uBAAAQ,OAAO,EAAI;EACxBH,QAAAA,QAAQ,CAACG,OAAD,CAAR;EACAZ,QAAAA,OAAO,CAACI,aAAR,oBAAAJ,OAAO,CAACI,aAAR,CAAwBQ,OAAxB;EACD;EAZqB;EAAA,GAAxB;EAeA,SAAOL,QAAP;EACD;;;;;;;;;;;;;;;;;;;"}
@@ -1 +1 @@
1
- {"version":3,"file":"index.production.js","sources":["../../src/index.tsx"],"sourcesContent":["import * as React from 'react'\nexport * from '@tanstack/table-core'\n\nimport {\n createTableInstance,\n PartialKeys,\n Options,\n TableInstance,\n PartialGenerics,\n CreateTableFactoryOptions,\n Table,\n init,\n AnyGenerics,\n} from '@tanstack/table-core'\n\nexport type Renderable<TProps> =\n | React.ReactNode\n | React.FunctionComponent<TProps>\n | React.Component<TProps>\n\nexport const render = <TProps extends {}>(\n Comp: Renderable<TProps>,\n props: TProps\n): React.ReactNode =>\n !Comp ? null : isReactComponent(Comp) ? <Comp {...props} /> : Comp\n\nexport type Render = typeof render\n\nfunction isReactComponent(component: unknown): component is React.FC {\n return (\n isClassComponent(component) ||\n typeof component === 'function' ||\n isExoticComponent(component)\n )\n}\n\nfunction isClassComponent(component: any) {\n return (\n typeof component === 'function' &&\n (() => {\n const proto = Object.getPrototypeOf(component)\n return proto.prototype && proto.prototype.isReactComponent\n })()\n )\n}\n\nfunction isExoticComponent(component: any) {\n return (\n typeof component === 'object' &&\n typeof component.$$typeof === 'symbol' &&\n ['react.memo', 'react.forward_ref'].includes(component.$$typeof.description)\n )\n}\n\nconst { createTable, createTableFactory } = init({ render })\n\nexport { createTable, createTableFactory }\n\nexport function useTable<TGenerics extends AnyGenerics>(\n table: Table<TGenerics>,\n options: PartialKeys<\n Omit<\n Options<TGenerics>,\n keyof CreateTableFactoryOptions<any, any, any, any>\n >,\n 'state' | 'onStateChange'\n >\n): TableInstance<TGenerics> {\n // Compose in the generic options to the user options\n const resolvedOptions: Options<TGenerics> = {\n ...(table.__options ?? {}),\n state: {}, // Dummy state\n onStateChange: () => {}, // noop\n render,\n ...options,\n }\n\n // Create a new table instance and store it in state\n const [instance] = React.useState(() =>\n createTableInstance<TGenerics>(resolvedOptions)\n )\n\n // By default, manage table state here using the instance's initial state\n const [state, setState] = React.useState(() => instance.initialState)\n\n // Compose the default state above with any user state. This will allow the user\n // to only control a subset of the state if desired.\n instance.setOptions(prev => ({\n ...prev,\n ...options,\n state: {\n ...state,\n ...options.state,\n },\n // Similarly, we'll maintain both our internal state and any user-provided\n // state.\n onStateChange: updater => {\n setState(updater)\n options.onStateChange?.(updater)\n },\n }))\n\n return instance\n}\n"],"names":["render","Comp","props","component","proto","Object","getPrototypeOf","prototype","isReactComponent","isClassComponent","$$typeof","includes","description","isExoticComponent","React","init","createTable","createTableFactory","table","options","resolvedOptions","__options","state","onStateChange","instance","useState","createTableInstance","initialState","setState","setOptions","prev","updater"],"mappings":";;;;;;;;;;w1BAoBaA,EAAS,SACpBC,EACAC,UAECD,EAYH,SAA0BE,SAED,mBAAdA,KAECC,EAAQC,OAAOC,eAAeH,IACvBI,WAAaH,EAAMG,UAAUC,kBAF3C,IACOJ,EAVRK,CAFsBN,EAJQF,IAOT,mBAAdE,GAeX,SAA2BA,SAEF,iBAAdA,GACuB,iBAAvBA,EAAUO,UACjB,CAAC,aAAc,qBAAqBC,SAASR,EAAUO,SAASE,aAlBhEC,CAAkBV,GARoBW,gBAACb,EAASC,GAAYD,EAAtD,KAIV,IAA0BE,SA0BkBY,OAAK,CAAEf,OAAAA,IAA3CgB,IAAAA,YAAaC,IAAAA,gFAId,SACLC,EACAC,SASMC,gBACAF,EAAMG,aAAa,IACvBC,MAAO,GACPC,cAAe,aACfvB,OAAAA,GACGmB,GAIEK,EAAYV,EAAMW,UAAS,kBAChCC,sBAA+BN,WAIPN,EAAMW,UAAS,kBAAMD,EAASG,gBAAjDL,OAAOM,cAIdJ,EAASK,YAAW,SAAAC,eACfA,EACAX,GACHG,WACKA,EACAH,EAAQG,OAIbC,cAAe,SAAAQ,GACbH,EAASG,SACTZ,EAAQI,eAARJ,EAAQI,cAAgBQ,SAIrBP"}
1
+ {"version":3,"file":"index.production.js","sources":["../../src/index.tsx"],"sourcesContent":["import * as React from 'react'\nexport * from '@tanstack/table-core'\n\nimport {\n createTableInstance,\n PartialKeys,\n Options,\n TableInstance,\n CreateTableFactoryOptions,\n Table,\n init,\n AnyGenerics,\n} from '@tanstack/table-core'\n\nexport type Renderable<TProps> =\n | React.ReactNode\n | React.FunctionComponent<TProps>\n | React.Component<TProps>\n\nexport const render = <TProps extends {}>(\n Comp: Renderable<TProps>,\n props: TProps\n): React.ReactNode =>\n !Comp ? null : isReactComponent(Comp) ? <Comp {...props} /> : Comp\n\nexport type Render = typeof render\n\nfunction isReactComponent(component: unknown): component is React.FC {\n return (\n isClassComponent(component) ||\n typeof component === 'function' ||\n isExoticComponent(component)\n )\n}\n\nfunction isClassComponent(component: any) {\n return (\n typeof component === 'function' &&\n (() => {\n const proto = Object.getPrototypeOf(component)\n return proto.prototype && proto.prototype.isReactComponent\n })()\n )\n}\n\nfunction isExoticComponent(component: any) {\n return (\n typeof component === 'object' &&\n typeof component.$$typeof === 'symbol' &&\n ['react.memo', 'react.forward_ref'].includes(component.$$typeof.description)\n )\n}\n\nconst { createTable, createTableFactory } = init({ render })\n\nexport { createTable, createTableFactory }\n\nexport function useTable<TGenerics extends AnyGenerics>(\n table: Table<TGenerics>,\n options: PartialKeys<\n Omit<\n Options<TGenerics>,\n keyof CreateTableFactoryOptions<any, any, any, any>\n >,\n 'state' | 'onStateChange'\n >\n): TableInstance<TGenerics> {\n // Compose in the generic options to the user options\n const resolvedOptions: Options<TGenerics> = {\n ...(table.__options ?? {}),\n state: {}, // Dummy state\n onStateChange: () => {}, // noop\n render,\n ...options,\n }\n\n // Create a new table instance and store it in state\n const [instance] = React.useState(() =>\n createTableInstance<TGenerics>(resolvedOptions)\n )\n\n // By default, manage table state here using the instance's initial state\n const [state, setState] = React.useState(() => instance.initialState)\n\n // Compose the default state above with any user state. This will allow the user\n // to only control a subset of the state if desired.\n instance.setOptions(prev => ({\n ...prev,\n ...options,\n state: {\n ...state,\n ...options.state,\n },\n // Similarly, we'll maintain both our internal state and any user-provided\n // state.\n onStateChange: updater => {\n setState(updater)\n options.onStateChange?.(updater)\n },\n }))\n\n return instance\n}\n"],"names":["render","Comp","props","component","proto","Object","getPrototypeOf","prototype","isReactComponent","isClassComponent","$$typeof","includes","description","isExoticComponent","React","init","createTable","createTableFactory","table","options","resolvedOptions","__options","state","onStateChange","instance","useState","createTableInstance","initialState","setState","setOptions","prev","updater"],"mappings":";;;;;;;;;;w1BAmBaA,EAAS,SACpBC,EACAC,UAECD,EAYH,SAA0BE,SAED,mBAAdA,KAECC,EAAQC,OAAOC,eAAeH,IACvBI,WAAaH,EAAMG,UAAUC,kBAF3C,IACOJ,EAVRK,CAFsBN,EAJQF,IAOT,mBAAdE,GAeX,SAA2BA,SAEF,iBAAdA,GACuB,iBAAvBA,EAAUO,UACjB,CAAC,aAAc,qBAAqBC,SAASR,EAAUO,SAASE,aAlBhEC,CAAkBV,GARoBW,gBAACb,EAASC,GAAYD,EAAtD,KAIV,IAA0BE,SA0BkBY,OAAK,CAAEf,OAAAA,IAA3CgB,IAAAA,YAAaC,IAAAA,gFAId,SACLC,EACAC,SASMC,gBACAF,EAAMG,aAAa,IACvBC,MAAO,GACPC,cAAe,aACfvB,OAAAA,GACGmB,GAIEK,EAAYV,EAAMW,UAAS,kBAChCC,sBAA+BN,WAIPN,EAAMW,UAAS,kBAAMD,EAASG,gBAAjDL,OAAOM,cAIdJ,EAASK,YAAW,SAAAC,eACfA,EACAX,GACHG,WACKA,EACAH,EAAQG,OAIbC,cAAe,SAAAQ,GACbH,EAASG,SACTZ,EAAQI,eAARJ,EAAQI,cAAgBQ,SAIrBP"}
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@tanstack/react-table",
3
3
  "author": "Tanner Linsley",
4
- "version": "8.0.0-alpha.24",
4
+ "version": "8.0.0-alpha.27",
5
5
  "description": "Hooks for building lightweight, fast and extendable datagrids for React",
6
6
  "license": "MIT",
7
7
  "homepage": "https://github.com/tanstack/react-table#readme",
@@ -34,7 +34,7 @@
34
34
  "src"
35
35
  ],
36
36
  "dependencies": {
37
- "@tanstack/table-core": "8.0.0-alpha.24"
37
+ "@tanstack/table-core": "8.0.0-alpha.27"
38
38
  },
39
39
  "peerDependencies": {
40
40
  "react": ">=16",
package/src/index.tsx CHANGED
@@ -6,7 +6,6 @@ import {
6
6
  PartialKeys,
7
7
  Options,
8
8
  TableInstance,
9
- PartialGenerics,
10
9
  CreateTableFactoryOptions,
11
10
  Table,
12
11
  init,