@atom-learning/components 1.14.1 → 1.16.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 +3 -3
- package/dist/components/alert-dialog/AlertDialogContent.js +1 -1
- package/dist/components/dialog/DialogContent.js +1 -1
- package/dist/components/grid/Grid.d.ts +1 -1
- package/dist/components/grid/Grid.js +1 -1
- package/dist/components/table/TableBody.d.ts +7 -1
- package/dist/components/table/TableBody.js +1 -1
- package/dist/components/table/TableCell.js +1 -1
- package/dist/components/table/TableHeader.d.ts +1 -1
- package/dist/components/table/TableHeader.js +1 -1
- package/dist/constants/dialog.d.ts +1 -0
- package/dist/constants/dialog.js +1 -0
- package/dist/docgen.json +1 -1
- package/dist/docs/Table.mdx +10 -2
- package/dist/index.cjs.js +1 -1
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
|
|
1
|
+
# [1.16.0](https://github.com/Atom-Learning/components/compare/v1.15.0...v1.16.0) (2022-06-20)
|
|
2
2
|
|
|
3
3
|
|
|
4
|
-
###
|
|
4
|
+
### Features
|
|
5
5
|
|
|
6
|
-
* the
|
|
6
|
+
* made the minItemSize prop optional and allow gridTemplateColumns property to be overridden ([d3bd25b](https://github.com/Atom-Learning/components/commit/d3bd25b1e8c14ee5866fde649c35dc0b92013d68))
|
|
7
7
|
|
|
8
8
|
# [1.4.0](https://github.com/Atom-Learning/components/compare/v1.3.0...v1.4.0) (2022-04-11)
|
|
9
9
|
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{Overlay as
|
|
1
|
+
import{Overlay as l,Content as d,Portal as m}from"@radix-ui/react-alert-dialog";import{createElement as t}from"react";import{DIALOG_Z_INDEX as e}from"../../constants/dialog.js";import{keyframes as n,styled as a}from"../../stitches.js";import{fadeIn as c,fadeOut as f}from"../../utilities/style/keyframe-animations.js";const o="translate3d(-50%, -50%, 0)",i="translate3d(-50%, 50vh, 0)",p=n({"0%":{transform:i},"100%":{transform:o}}),u=n({"0%":{transform:o},"100%":{transform:i}}),x=a(l,{backgroundColor:"$alpha600",inset:0,position:"fixed",zIndex:e,"@allowMotion":{'&[data-state="open"]':{animation:`${c} 250ms ease-out`},'&[data-state="closed"]':{animation:`${f} 550ms ease-out`}}}),b=a(d,{bg:"white",borderRadius:"$1",boxShadow:"$3",boxSizing:"border-box",left:"50%",maxWidth:"90vw",p:"$5",position:"fixed",top:"50%",transform:o,"&:focus":{outline:"none"},zIndex:e,"@allowMotion":{'&[data-state="open"]':{animation:`${p} 550ms cubic-bezier(0.22, 1, 0.36, 1)`},'&[data-state="closed"]':{animation:`${u} 550ms cubic-bezier(0.22, 1, 0.36, 1)`}},variants:{size:{sm:{width:"380px"},md:{width:"480px"},lg:{width:"600px"}}}}),h=({size:r="sm",...s})=>t(m,null,t(x,null),t(b,{size:r,...s}));export{h as AlertDialogContent};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{Close as u}from"@atom-learning/icons";import{Overlay as x,Content as b,Portal as h,Close as g}from"@radix-ui/react-dialog";import{createElement as o}from"react";import{keyframes as
|
|
1
|
+
import{Close as u}from"@atom-learning/icons";import{Overlay as x,Content as b,Portal as h,Close as g}from"@radix-ui/react-dialog";import{createElement as o}from"react";import{DIALOG_Z_INDEX as n}from"../../constants/dialog.js";import{keyframes as i,styled as r}from"../../stitches.js";import{ActionIcon as w}from"../action-icon/ActionIcon.js";import{Icon as v}from"../icon/Icon.js";import{fadeIn as $,fadeOut as I}from"../../utilities/style/keyframe-animations.js";const t="translate3d(-50%, -50%, 0)",s="translate3d(-50%, 50vh, 0)",l="modal_overlay",O=i({"0%":{transform:s},"100%":{transform:t}}),y=i({"0%":{transform:t},"100%":{transform:s}}),C=r(x,{backgroundColor:"$alpha600",inset:0,position:"fixed",overflowY:"auto",zIndex:n,"@allowMotion":{'&[data-state="open"]':{animation:`${$} 250ms ease-out`},'&[data-state="closed"]':{animation:`${I} 550ms ease-out`}}}),D=r(b,{bg:"white",borderRadius:"$1",boxShadow:"$3",boxSizing:"border-box",left:"50%",maxWidth:"90vw",maxHeight:"90vh",overflowY:"auto",p:"$5",position:"fixed",top:"50%",transform:t,zIndex:n,"&:focus":{outline:"none"},"@allowMotion":{'&[data-state="open"]':{animation:`${O} 550ms cubic-bezier(0.22, 1, 0.36, 1)`},'&[data-state="closed"]':{animation:`${y} 550ms cubic-bezier(0.22, 1, 0.36, 1)`}},variants:{size:{xs:{width:"380px"},sm:{width:"480px"},md:{width:"600px"},lg:{width:"800px"},xl:{width:"1100px"}}}}),z=({size:m="sm",children:d,closeDialogText:c="Close dialog",showCloseButton:f=!0,...p})=>o(h,null,o(C,{id:l},o(D,{size:m,"aria-label":"Dialog",onPointerDownOutside:e=>{const a=e.target;(a==null?void 0:a.id)!==l&&e.preventDefault()},...p},f&&o(w,{as:g,css:{position:"absolute",right:"$4",top:"$4"},label:c,size:"lg",theme:"neutral"},o(v,{is:u})),d)));export{z as DialogContent};
|
|
@@ -267,7 +267,7 @@ declare const GridContainer: import("@stitches/react/types/styled-component").St
|
|
|
267
267
|
};
|
|
268
268
|
}>>;
|
|
269
269
|
declare type GridProps = React.ComponentProps<typeof GridContainer> & {
|
|
270
|
-
minItemSize
|
|
270
|
+
minItemSize?: string;
|
|
271
271
|
maxItemSize?: string;
|
|
272
272
|
};
|
|
273
273
|
export declare const Grid: React.FC<GridProps>;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{createElement as
|
|
1
|
+
import{createElement as i}from"react";import{theme as o,styled as d}from"../../stitches.js";const c=Object.keys(o.space).reduce((e,a)=>({...e,[a]:{gap:`$space$${a}`}}),{}),m=d("div",{display:"grid",variants:{gap:c}}),t=({css:e,gap:a=2,minItemSize:r,maxItemSize:p="1fr",...s})=>i(m,{css:{...r&&{gridTemplateColumns:`repeat(auto-fit, minmax(${r}, ${p}))`},...e},gap:a,...s});t.displayName="Grid";export{t as Grid};
|
|
@@ -1,4 +1,7 @@
|
|
|
1
|
-
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
declare const StyledTableBody: import("@stitches/react/types/styled-component").StyledComponent<"tbody", {
|
|
3
|
+
striped?: boolean | "true" | "false" | undefined;
|
|
4
|
+
}, {
|
|
2
5
|
sm: string;
|
|
3
6
|
md: string;
|
|
4
7
|
lg: string;
|
|
@@ -263,3 +266,6 @@ export declare const TableBody: import("@stitches/react/types/styled-component")
|
|
|
263
266
|
};
|
|
264
267
|
};
|
|
265
268
|
}>>;
|
|
269
|
+
declare type TableBodyProps = React.ComponentProps<typeof StyledTableBody>;
|
|
270
|
+
export declare const TableBody: React.FC<TableBodyProps>;
|
|
271
|
+
export {};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{styled as d}from"../../stitches.js";const
|
|
1
|
+
import{styled as d}from"../../stitches.js";import{createElement as l}from"react";import{TableRow as r}from"./TableRow.js";const a=d("tbody",{variants:{striped:{true:{[`${r}`]:{"&:nth-child(odd)":{bg:"white"},"&:nth-child(even)":{bg:"$tonal50"}}},false:{bg:"white"}}}}),e=({striped:t=!0,...o})=>l(a,{striped:t,...o});e.displayName="TableBody";export{e as TableBody};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{styled as
|
|
1
|
+
import{styled as o}from"../../stitches.js";const l=o("td",{borderBottom:"1px solid $tonal100",boxSizing:"border-box",color:"$tonal400",fontFamily:"$body",lineHeight:1.5,p:"$2 $3",textAlign:"left",verticalAlign:"middle","&:first-child":{fontWeight:"bold"}});l.displayName="TableCell";export{l as TableCell};
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
declare const StyledTableHeader: import("@stitches/react/types/styled-component").StyledComponent<"thead", {
|
|
3
|
-
theme?: "primary" | "primaryDark" | undefined;
|
|
3
|
+
theme?: "primary" | "primaryDark" | "light" | undefined;
|
|
4
4
|
}, {
|
|
5
5
|
sm: string;
|
|
6
6
|
md: string;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import
|
|
1
|
+
import l from"react";import{styled as m}from"../../stitches.js";import{TableHeaderCell as r}from"./TableHeaderCell.js";const o=m("thead",{variants:{theme:{primary:{[`${r}`]:{bg:"$primary"}},primaryDark:{[`${r}`]:{bg:"$primaryDark"}},light:{[`${r}`]:{bg:"$tonal50",color:"$tonal600"}}}}}),a=({theme:e="primaryDark",...t})=>l.createElement(o,{theme:e,...t});a.displayName="TableHeader";export{a as TableHeader};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const DIALOG_Z_INDEX = 2147483646;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
const o=2147483646;export{o as DIALOG_Z_INDEX};
|