@atom-learning/components 2.31.2-beta.0 → 2.32.0
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/CHANGELOG.md +13 -0
- package/dist/components/data-table/DataTableGlobalFilter.js +1 -1
- package/dist/components/data-table/DataTableTable.js +1 -1
- package/dist/components/search-input/SearchInput.d.ts +2 -0
- package/dist/components/search-input/SearchInput.js +1 -1
- package/dist/components/table/Table.d.ts +1 -5
- package/dist/components/table/Table.js +1 -1
- package/dist/components/table/TableBody.d.ts +1 -3
- package/dist/components/table/TableBody.js +1 -1
- package/dist/components/table/TableHeader.d.ts +1 -3
- package/dist/components/table/TableHeader.js +1 -1
- package/dist/docgen.json +1 -1
- package/dist/index.cjs.js +1 -1
- package/package.json +1 -1
- package/dist/components/table/TableStickyColumnsContainer.d.ts +0 -9
- package/dist/components/table/TableStickyColumnsContainer.js +0 -1
- package/dist/components/table/useStickyColumnsCss.d.ts +0 -7
- package/dist/components/table/useStickyColumnsCss.js +0 -1
package/package.json
CHANGED
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
import { CSS } from '../../stitches';
|
|
3
|
-
interface ITableStickyColumnsContainerProps {
|
|
4
|
-
children: React.ReactNode;
|
|
5
|
-
numOfStickyColumns?: number;
|
|
6
|
-
css?: CSS;
|
|
7
|
-
}
|
|
8
|
-
export declare const TableStickyColumnsContainer: React.FC<ITableStickyColumnsContainerProps>;
|
|
9
|
-
export {};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import o from"react";import{Box as a}from"../box/Box.js";const s=({children:t,numOfStickyColumns:r=0,css:e,...l})=>{const[c,n]=o.useState(!1);return o.createElement(a,{onScroll:p=>{n(p.currentTarget.scrollLeft>0)},role:"scrollbar",css:{overflow:"auto",maxWidth:"100%",...c&&{[`& th,td:nth-of-type(${r})`]:{boxShadow:"$colors$alpha200 -2px -3px 9px 1px",clipPath:"inset(0px -10px 0px 0px)"}},...e},...l},t)};export{s as TableStickyColumnsContainer};
|
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
import * as React from 'react';
|
|
2
|
-
import { CSS } from '../../stitches';
|
|
3
|
-
interface IUseStickyColumnsCss {
|
|
4
|
-
columnsCss: CSS;
|
|
5
|
-
}
|
|
6
|
-
export declare const useStickyColumnsCss: (numOfStickyColumns: number, cellElement: 'th' | 'td', wrapperRef?: React.RefObject<HTMLTableSectionElement> | undefined) => IUseStickyColumnsCss;
|
|
7
|
-
export {};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import*as r from"react";const y=(s,t,e)=>{const[c,a]=r.useState([]),[f,v]=r.useState({});return r.useEffect(()=>{let l=0;v(c.reduce((n,u,o)=>{var i,d;const m={...n,[`& ${t}:nth-of-type(${o+1})`]:{position:"sticky",left:l,zIndex:"2"}};return l+=(((d=(i=e==null?void 0:e.current)==null?void 0:i.querySelectorAll(t))==null?void 0:d.item(o).clientWidth)||0)+.3,m},{}))},[c,e,t]),r.useLayoutEffect(()=>{const l=()=>{var n;const u=[];(n=e==null?void 0:e.current)==null||n.querySelectorAll(t).forEach(o=>u.push(o)),a(u.slice(0,s))};l(),window.addEventListener("resize",l)},[e,s,t]),{columnsCss:f}};export{y as useStickyColumnsCss};
|