@atom-learning/components 2.49.0 → 2.50.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 -11
- package/dist/components/accordion/AccordionContent.js +1 -1
- package/dist/components/accordion/AccordionContent.js.map +1 -1
- package/dist/components/accordion/AccordionTrigger.js +1 -1
- package/dist/components/accordion/AccordionTrigger.js.map +1 -1
- package/dist/components/alert-dialog/AlertDialogContent.js +1 -1
- package/dist/components/alert-dialog/AlertDialogContent.js.map +1 -1
- package/dist/components/avatar/Avatar.js +1 -1
- package/dist/components/avatar/Avatar.js.map +1 -1
- package/dist/components/banner/Banner.d.ts +14 -0
- package/dist/components/banner/Banner.js +2 -0
- package/dist/components/banner/Banner.js.map +1 -0
- package/dist/components/banner/BannerContainer.d.ts +430 -0
- package/dist/components/banner/BannerContainer.js +2 -0
- package/dist/components/banner/BannerContainer.js.map +1 -0
- package/dist/components/banner/BannerContext.d.ts +6 -0
- package/dist/components/banner/BannerContext.js +2 -0
- package/dist/components/banner/BannerContext.js.map +1 -0
- package/dist/components/banner/banner-regular/BannerRegular.d.ts +18 -0
- package/dist/components/banner/banner-regular/BannerRegular.js +2 -0
- package/dist/components/banner/banner-regular/BannerRegular.js.map +1 -0
- package/dist/components/banner/banner-regular/BannerRegularActions.d.ts +3 -0
- package/dist/components/banner/banner-regular/BannerRegularActions.js +2 -0
- package/dist/components/banner/banner-regular/BannerRegularActions.js.map +1 -0
- package/dist/components/banner/banner-regular/BannerRegularButton.d.ts +3 -0
- package/dist/components/banner/banner-regular/BannerRegularButton.js +2 -0
- package/dist/components/banner/banner-regular/BannerRegularButton.js.map +1 -0
- package/dist/components/banner/banner-regular/BannerRegularContent.d.ts +430 -0
- package/dist/components/banner/banner-regular/BannerRegularContent.js +2 -0
- package/dist/components/banner/banner-regular/BannerRegularContent.js.map +1 -0
- package/dist/components/banner/banner-regular/BannerRegularDismiss.d.ts +3 -0
- package/dist/components/banner/banner-regular/BannerRegularDismiss.js +2 -0
- package/dist/components/banner/banner-regular/BannerRegularDismiss.js.map +1 -0
- package/dist/components/banner/banner-regular/BannerRegularHeading.d.ts +3 -0
- package/dist/components/banner/banner-regular/BannerRegularHeading.js +2 -0
- package/dist/components/banner/banner-regular/BannerRegularHeading.js.map +1 -0
- package/dist/components/banner/banner-regular/BannerRegularImage.d.ts +3 -0
- package/dist/components/banner/banner-regular/BannerRegularImage.js +2 -0
- package/dist/components/banner/banner-regular/BannerRegularImage.js.map +1 -0
- package/dist/components/banner/banner-regular/BannerRegularText.d.ts +3 -0
- package/dist/components/banner/banner-regular/BannerRegularText.js +2 -0
- package/dist/components/banner/banner-regular/BannerRegularText.js.map +1 -0
- package/dist/components/banner/banner-regular/index.d.ts +1 -0
- package/dist/components/banner/index.d.ts +1 -0
- package/dist/components/carousel/Carousel.js +1 -1
- package/dist/components/carousel/Carousel.js.map +1 -1
- package/dist/components/chip-toggle-group/ChipToggleGroupItem.js +1 -1
- package/dist/components/chip-toggle-group/ChipToggleGroupItem.js.map +1 -1
- package/dist/components/combobox/ComboboxInput.js +1 -1
- package/dist/components/combobox/ComboboxInput.js.map +1 -1
- package/dist/components/dialog/DialogContent.js +1 -1
- package/dist/components/dialog/DialogContent.js.map +1 -1
- package/dist/components/dropdown-menu/DropdownMenuContent.js +1 -1
- package/dist/components/dropdown-menu/DropdownMenuContent.js.map +1 -1
- package/dist/components/grid/Grid.js +1 -1
- package/dist/components/grid/Grid.js.map +1 -1
- package/dist/components/heading/Heading.js +1 -1
- package/dist/components/heading/Heading.js.map +1 -1
- package/dist/components/index.d.ts +1 -0
- package/dist/components/popover/PopoverContent.js +1 -1
- package/dist/components/popover/PopoverContent.js.map +1 -1
- package/dist/components/select/Select.js +1 -1
- package/dist/components/select/Select.js.map +1 -1
- package/dist/components/sidedrawer/SidedrawerContent.js +1 -1
- package/dist/components/sidedrawer/SidedrawerContent.js.map +1 -1
- package/dist/components/sidedrawer/SidedrawerOverlay.js +1 -1
- package/dist/components/sidedrawer/SidedrawerOverlay.js.map +1 -1
- package/dist/components/slider/Slider.js +1 -1
- package/dist/components/slider/Slider.js.map +1 -1
- package/dist/components/stack/Stack.js +1 -1
- package/dist/components/stack/Stack.js.map +1 -1
- package/dist/components/tabs/TabsTrigger.js +1 -1
- package/dist/components/tabs/TabsTrigger.js.map +1 -1
- package/dist/components/text/Text.js +1 -1
- package/dist/components/text/Text.js.map +1 -1
- package/dist/components/tile-interactive/TileInteractive.js +1 -1
- package/dist/components/tile-interactive/TileInteractive.js.map +1 -1
- package/dist/components/toggle-group/ToggleGroupItem.js +1 -1
- package/dist/components/toggle-group/ToggleGroupItem.js.map +1 -1
- package/dist/components/tooltip/TooltipContent.js +1 -1
- package/dist/components/tooltip/TooltipContent.js.map +1 -1
- package/dist/docgen.json +1 -1
- package/dist/index.cjs.js +1 -1
- package/dist/index.cjs.js.map +1 -1
- package/dist/index.js +1 -1
- package/package.json +1 -1
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{Ok as m}from"@atom-learning/icons";import*as n from"@radix-ui/react-toggle-group";import*as o from"react";import{Chip as t}from"../chip/Chip.js";import"../chip/ChipGroup.js";import{Icon as s}from"../icon/Icon.js";import{styled as r}from"../../stitches.js";import{focusVisibleStyleBlock as
|
|
1
|
+
import{Ok as m}from"@atom-learning/icons";import*as n from"@radix-ui/react-toggle-group";import*as o from"react";import{Chip as t}from"../chip/Chip.js";import"../chip/ChipGroup.js";import{Icon as s}from"../icon/Icon.js";import{styled as r}from"../../stitches.js";import"../../utilities/css-wrapper/CSSWrapper.js";import"color2k";import{focusVisibleStyleBlock as p}from"../../utilities/style/focus-visible-style-block.js";import"../../utilities/style/keyframe-animations.js";const e=r(s,{display:"none"}),c=r(t,{"&:not([disabled])":{cursor:"pointer","&:hover":{bg:"$tonal100",color:"$tonal600",borderColor:"currentColor"},"&:focus-visible":{...p()},'&[data-state="on"]':{"&:hover":{bg:"$white",color:"$primaryDark"}}},'&[data-state="off"]':{color:"$tonal400",bg:"$tonal50",borderColor:"$tonal200"},'&[data-state="on"]':{[`& ${e}`]:{display:"block"}}}),d=({size:l="md",children:a,...i})=>o.createElement(n.Item,{...i,asChild:!0},o.createElement(c,{asWorkaround:"button"},o.createElement(e,{is:m,size:l==="lg"?"md":"sm"}),o.createElement(t.Content,null,a)));export{d as ChipToggleGroupItem};
|
|
2
2
|
//# sourceMappingURL=ChipToggleGroupItem.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ChipToggleGroupItem.js","sources":["../../../src/components/chip-toggle-group/ChipToggleGroupItem.tsx"],"sourcesContent":["import { Ok } from '@atom-learning/icons'\nimport * as ToggleGroup from '@radix-ui/react-toggle-group'\nimport * as React from 'react'\n\nimport { Chip } from '~/components/chip'\nimport { Icon } from '~/components/icon'\nimport { styled } from '~/stitches'\nimport { focusVisibleStyleBlock } from '~/utilities'\n\nconst StyledChipToggleIcon = styled(Icon, {\n display: 'none'\n})\n\nconst StyledChipToggleGroupItem = styled(Chip, {\n '&:not([disabled])': {\n cursor: 'pointer',\n '&:hover': {\n bg: '$tonal100',\n color: '$tonal600',\n borderColor: 'currentColor'\n },\n '&:focus-visible': {\n ...focusVisibleStyleBlock()\n },\n '&[data-state=\"on\"]': {\n '&:hover': {\n bg: '$white',\n color: '$primaryDark'\n }\n }\n },\n '&[data-state=\"off\"]': {\n color: '$tonal400',\n bg: '$tonal50',\n borderColor: '$tonal200'\n },\n '&[data-state=\"on\"]': {\n [`& ${StyledChipToggleIcon}`]: {\n display: 'block'\n }\n }\n})\n\ntype TChipToggleGroupItem = React.ComponentProps<typeof ToggleGroup.Item> &\n React.ComponentProps<typeof StyledChipToggleGroupItem>\n\nexport const ChipToggleGroupItem: React.FC<TChipToggleGroupItem> = ({\n size = 'md',\n children,\n ...rest\n}) => {\n return (\n <ToggleGroup.Item {...rest} asChild>\n <StyledChipToggleGroupItem asWorkaround=\"button\">\n <StyledChipToggleIcon is={Ok} size={size === 'lg' ? 'md' : 'sm'} />\n <Chip.Content>{children}</Chip.Content>\n </StyledChipToggleGroupItem>\n </ToggleGroup.Item>\n )\n}\n"],"names":["StyledChipToggleIcon","styled","Icon","StyledChipToggleGroupItem","Chip","focusVisibleStyleBlock","ChipToggleGroupItem","size","children","rest","React","ToggleGroup","Ok"],"mappings":"
|
|
1
|
+
{"version":3,"file":"ChipToggleGroupItem.js","sources":["../../../src/components/chip-toggle-group/ChipToggleGroupItem.tsx"],"sourcesContent":["import { Ok } from '@atom-learning/icons'\nimport * as ToggleGroup from '@radix-ui/react-toggle-group'\nimport * as React from 'react'\n\nimport { Chip } from '~/components/chip'\nimport { Icon } from '~/components/icon'\nimport { styled } from '~/stitches'\nimport { focusVisibleStyleBlock } from '~/utilities'\n\nconst StyledChipToggleIcon = styled(Icon, {\n display: 'none'\n})\n\nconst StyledChipToggleGroupItem = styled(Chip, {\n '&:not([disabled])': {\n cursor: 'pointer',\n '&:hover': {\n bg: '$tonal100',\n color: '$tonal600',\n borderColor: 'currentColor'\n },\n '&:focus-visible': {\n ...focusVisibleStyleBlock()\n },\n '&[data-state=\"on\"]': {\n '&:hover': {\n bg: '$white',\n color: '$primaryDark'\n }\n }\n },\n '&[data-state=\"off\"]': {\n color: '$tonal400',\n bg: '$tonal50',\n borderColor: '$tonal200'\n },\n '&[data-state=\"on\"]': {\n [`& ${StyledChipToggleIcon}`]: {\n display: 'block'\n }\n }\n})\n\ntype TChipToggleGroupItem = React.ComponentProps<typeof ToggleGroup.Item> &\n React.ComponentProps<typeof StyledChipToggleGroupItem>\n\nexport const ChipToggleGroupItem: React.FC<TChipToggleGroupItem> = ({\n size = 'md',\n children,\n ...rest\n}) => {\n return (\n <ToggleGroup.Item {...rest} asChild>\n <StyledChipToggleGroupItem asWorkaround=\"button\">\n <StyledChipToggleIcon is={Ok} size={size === 'lg' ? 'md' : 'sm'} />\n <Chip.Content>{children}</Chip.Content>\n </StyledChipToggleGroupItem>\n </ToggleGroup.Item>\n )\n}\n"],"names":["StyledChipToggleIcon","styled","Icon","StyledChipToggleGroupItem","Chip","focusVisibleStyleBlock","ChipToggleGroupItem","size","children","rest","React","ToggleGroup","Ok"],"mappings":"0dASA,MAAMA,EAAuBC,EAAOC,EAAM,CACxC,QAAS,MACX,CAAC,EAEKC,EAA4BF,EAAOG,EAAM,CAC7C,oBAAqB,CACnB,OAAQ,UACR,UAAW,CACT,GAAI,YACJ,MAAO,YACP,YAAa,cACf,EACA,kBAAmB,CACjB,GAAGC,EAAAA,CACL,EACA,qBAAsB,CACpB,UAAW,CACT,GAAI,SACJ,MAAO,cACT,CACF,CACF,EACA,sBAAuB,CACrB,MAAO,YACP,GAAI,WACJ,YAAa,WACf,EACA,qBAAsB,CACpB,CAAC,KAAKL,KAAyB,CAC7B,QAAS,OACX,CACF,CACF,CAAC,EAKYM,EAAsD,CAAC,CAClE,KAAAC,EAAO,KACP,SAAAC,KACGC,CACL,IAEIC,EAAA,cAACC,EAAY,KAAZ,CAAkB,GAAGF,EAAM,QAAO,EAAA,EACjCC,EAAA,cAACP,EAAA,CAA0B,aAAa,QAAA,EACtCO,EAAA,cAACV,EAAA,CAAqB,GAAIY,EAAI,KAAML,IAAS,KAAO,KAAO,IAAM,CAAA,EACjEG,EAAA,cAACN,EAAK,QAAL,KAAcI,CAAS,CAC1B,CACF"}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{ComboboxInput as o}from"@reach/combobox";import{styled as r,theme as
|
|
1
|
+
import{ComboboxInput as o}from"@reach/combobox";import{styled as r,theme as t}from"../../stitches.js";import"../../utilities/css-wrapper/CSSWrapper.js";import{encodeBackgroundIcon as e}from"../../utilities/style/encode-background-icon.js";import"../../utilities/style/keyframe-animations.js";const a=r(o,{boxShadow:"none",fontSize:"$md",appearance:"none",backgroundImage:e(t.colors.tonal300.value,"chevron"),backgroundPosition:"right $space$3 top 50%, 0 0",backgroundRepeat:"no-repeat, repeat",backgroundSize:"20px auto, 100%",border:"1px solid $tonal300",borderRadius:"$0",boxSizing:"border-box",color:"$tonal600",cursor:"text",display:"block",fontFamily:"$body",height:"$4",pl:"$3",pr:"$6",transition:"all 100ms ease-out",width:"100%","&::placeholder":{color:"$tonal300",opacity:1},"&:focus-within":{borderColor:"$primary",outline:"none"},"&[disabled]":{backgroundColor:"$tonal100",color:"$tonal400",cursor:"not-allowed"},variants:{state:{error:{border:"1px solid $danger"}}}});export{a as ComboboxInput};
|
|
2
2
|
//# sourceMappingURL=ComboboxInput.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ComboboxInput.js","sources":["../../../src/components/combobox/ComboboxInput.tsx"],"sourcesContent":["import { ComboboxInput as BaseComboboxInput } from '@reach/combobox'\n\nimport { styled, theme } from '~/stitches'\nimport { encodeBackgroundIcon } from '~/utilities'\n\nexport const ComboboxInput = styled(BaseComboboxInput, {\n boxShadow: 'none', // prevent default iOS default styling\n fontSize: '$md', // prevent iOS zooming on focus\n appearance: 'none',\n backgroundImage: encodeBackgroundIcon(theme.colors.tonal300.value, 'chevron'),\n backgroundPosition: 'right $space$3 top 50%, 0 0',\n backgroundRepeat: 'no-repeat, repeat',\n backgroundSize: '20px auto, 100%',\n border: '1px solid $tonal300',\n borderRadius: '$0',\n boxSizing: 'border-box',\n color: '$tonal600',\n cursor: 'text',\n display: 'block',\n fontFamily: '$body',\n height: '$4',\n pl: '$3',\n pr: '$6',\n transition: 'all 100ms ease-out',\n width: '100%',\n '&::placeholder': {\n color: '$tonal300',\n opacity: 1\n },\n '&:focus-within': {\n borderColor: '$primary',\n outline: 'none'\n },\n '&[disabled]': {\n backgroundColor: '$tonal100',\n color: '$tonal400',\n cursor: 'not-allowed'\n },\n variants: {\n state: {\n error: {\n border: '1px solid $danger'\n }\n }\n }\n})\n"],"names":["ComboboxInput","styled","BaseComboboxInput","encodeBackgroundIcon","theme"],"mappings":"
|
|
1
|
+
{"version":3,"file":"ComboboxInput.js","sources":["../../../src/components/combobox/ComboboxInput.tsx"],"sourcesContent":["import { ComboboxInput as BaseComboboxInput } from '@reach/combobox'\n\nimport { styled, theme } from '~/stitches'\nimport { encodeBackgroundIcon } from '~/utilities'\n\nexport const ComboboxInput = styled(BaseComboboxInput, {\n boxShadow: 'none', // prevent default iOS default styling\n fontSize: '$md', // prevent iOS zooming on focus\n appearance: 'none',\n backgroundImage: encodeBackgroundIcon(theme.colors.tonal300.value, 'chevron'),\n backgroundPosition: 'right $space$3 top 50%, 0 0',\n backgroundRepeat: 'no-repeat, repeat',\n backgroundSize: '20px auto, 100%',\n border: '1px solid $tonal300',\n borderRadius: '$0',\n boxSizing: 'border-box',\n color: '$tonal600',\n cursor: 'text',\n display: 'block',\n fontFamily: '$body',\n height: '$4',\n pl: '$3',\n pr: '$6',\n transition: 'all 100ms ease-out',\n width: '100%',\n '&::placeholder': {\n color: '$tonal300',\n opacity: 1\n },\n '&:focus-within': {\n borderColor: '$primary',\n outline: 'none'\n },\n '&[disabled]': {\n backgroundColor: '$tonal100',\n color: '$tonal400',\n cursor: 'not-allowed'\n },\n variants: {\n state: {\n error: {\n border: '1px solid $danger'\n }\n }\n }\n})\n"],"names":["ComboboxInput","styled","BaseComboboxInput","encodeBackgroundIcon","theme"],"mappings":"0SAKaA,EAAgBC,EAAOC,EAAmB,CACrD,UAAW,OACX,SAAU,MACV,WAAY,OACZ,gBAAiBC,EAAqBC,EAAM,OAAO,SAAS,MAAO,SAAS,EAC5E,mBAAoB,8BACpB,iBAAkB,oBAClB,eAAgB,kBAChB,OAAQ,sBACR,aAAc,KACd,UAAW,aACX,MAAO,YACP,OAAQ,OACR,QAAS,QACT,WAAY,QACZ,OAAQ,KACR,GAAI,KACJ,GAAI,KACJ,WAAY,qBACZ,MAAO,OACP,iBAAkB,CAChB,MAAO,YACP,QAAS,CACX,EACA,iBAAkB,CAChB,YAAa,WACb,QAAS,MACX,EACA,cAAe,CACb,gBAAiB,YACjB,MAAO,YACP,OAAQ,aACV,EACA,SAAU,CACR,MAAO,CACL,MAAO,CACL,OAAQ,mBACV,CACF,CACF,CACF,CAAC"}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{Close as u}from"@atom-learning/icons";import{Overlay as x,Content as b,Portal as g,Close as w}from"@radix-ui/react-dialog";import*as o from"react";import{DIALOG_Z_INDEX as r}from"../../constants/zIndices.js";import{keyframes as n,styled as l}from"../../stitches.js";import{
|
|
1
|
+
import{Close as u}from"@atom-learning/icons";import{Overlay as x,Content as b,Portal as g,Close as w}from"@radix-ui/react-dialog";import*as o from"react";import{DIALOG_Z_INDEX as r}from"../../constants/zIndices.js";import{keyframes as n,styled as l}from"../../stitches.js";import"../../utilities/css-wrapper/CSSWrapper.js";import"color2k";import{fadeIn as v,fadeOut as $}from"../../utilities/style/keyframe-animations.js";import{ActionIcon as C}from"../action-icon/ActionIcon.js";import{Icon as z}from"../icon/Icon.js";import{DialogBackground as s}from"./DialogBackground.js";const e="translate3d(-50%, -50%, 0)",m="translate3d(-50%, 50vh, 0)",d="modal_overlay",D=n({"0%":{transform:m},"100%":{transform:e}}),I=n({"0%":{transform:e},"100%":{transform:m}}),y=l(x,{backgroundColor:"$alpha600",top:0,right:0,bottom:0,left:0,position:"fixed",overflowY:"auto",zIndex:r,"@allowMotion":{'&[data-state="open"]':{animation:`${v} 250ms ease-out`},'&[data-state="closed"]':{animation:`${$} 550ms ease-out`}}}),E=l(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:e,zIndex:r,"&:focus":{outline:"none"},"@allowMotion":{'&[data-state="open"]':{animation:`${D} 550ms cubic-bezier(0.22, 1, 0.36, 1)`},'&[data-state="closed"]':{animation:`${I} 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"}}}}),O=({size:p="sm",children:a,closeDialogText:f="Close dialog",showCloseButton:c=!0,...h})=>o.createElement(g,null,o.createElement(y,{id:d},o.Children.map(a,t=>(t==null?void 0:t.type)===s&&t),o.createElement(E,{size:p,"aria-label":"Dialog",onPointerDownOutside:t=>{const i=t.target;(i==null?void 0:i.id)!==d&&t.preventDefault()},...h},c&&o.createElement(C,{as:w,css:{position:"absolute",right:"$4",top:"$4"},label:f,hasTooltip:!1,size:"md",theme:"neutral"},o.createElement(z,{is:u})),o.Children.map(a,t=>(t==null?void 0:t.type)!==s&&t))));export{O as DialogContent};
|
|
2
2
|
//# sourceMappingURL=DialogContent.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"DialogContent.js","sources":["../../../src/components/dialog/DialogContent.tsx"],"sourcesContent":["import { Close as CloseIcon } from '@atom-learning/icons'\nimport { Close, Content, Overlay, Portal } from '@radix-ui/react-dialog'\nimport * as React from 'react'\n\nimport { DIALOG_Z_INDEX } from '~/constants/zIndices'\nimport { keyframes, styled } from '~/stitches'\nimport { fadeIn, fadeOut } from '~/utilities'\n\nimport { ActionIcon } from '../action-icon/ActionIcon'\nimport { Icon } from '../icon/Icon'\nimport { DialogBackground } from './DialogBackground'\n\nconst contentOnScreen = 'translate3d(-50%, -50%, 0)'\nconst contentOffScreen = 'translate3d(-50%, 50vh, 0)'\nconst modalOverlayId = 'modal_overlay'\n\nconst slideIn = keyframes({\n '0%': { transform: contentOffScreen },\n '100%': { transform: contentOnScreen }\n})\nconst slideOut = keyframes({\n '0%': { transform: contentOnScreen },\n '100%': { transform: contentOffScreen }\n})\n\nconst StyledDialogOverlay = styled(Overlay, {\n backgroundColor: '$alpha600',\n top: 0,\n right: 0,\n bottom: 0,\n left: 0,\n position: 'fixed',\n overflowY: 'auto',\n zIndex: DIALOG_Z_INDEX,\n '@allowMotion': {\n '&[data-state=\"open\"]': {\n animation: `${fadeIn} 250ms ease-out`\n },\n '&[data-state=\"closed\"]': {\n animation: `${fadeOut} 550ms ease-out`\n }\n }\n})\n\nconst StyledDialogContent = styled(Content, {\n bg: 'white',\n borderRadius: '$1',\n boxShadow: '$3',\n boxSizing: 'border-box',\n left: '50%',\n maxWidth: '90vw',\n maxHeight: '90vh',\n overflowY: 'auto',\n p: '$5',\n position: 'fixed',\n top: '50%',\n transform: contentOnScreen,\n zIndex: DIALOG_Z_INDEX,\n '&:focus': {\n outline: 'none'\n },\n '@allowMotion': {\n '&[data-state=\"open\"]': {\n animation: `${slideIn} 550ms cubic-bezier(0.22, 1, 0.36, 1)`\n },\n '&[data-state=\"closed\"]': {\n animation: `${slideOut} 550ms cubic-bezier(0.22, 1, 0.36, 1)`\n }\n },\n variants: {\n size: {\n xs: { width: '380px' },\n sm: { width: '480px' },\n md: { width: '600px' },\n lg: { width: '800px' },\n xl: { width: '1100px' }\n }\n }\n})\n\ntype DialogContentProps = React.ComponentProps<typeof StyledDialogContent> & {\n closeDialogText?: string\n showCloseButton?: boolean\n}\n\nexport const DialogContent: React.FC<DialogContentProps> = ({\n size = 'sm',\n children,\n closeDialogText = 'Close dialog',\n showCloseButton = true,\n ...remainingProps\n}) => (\n <Portal>\n <StyledDialogOverlay id={modalOverlayId}>\n {React.Children.map(\n children,\n (child?: React.ReactElement) =>\n child?.type === DialogBackground && child\n )}\n <StyledDialogContent\n size={size}\n aria-label=\"Dialog\"\n onPointerDownOutside={(event) => {\n const element = event.target as HTMLElement\n if (element?.id !== modalOverlayId) {\n event.preventDefault()\n }\n }}\n {...remainingProps}\n >\n {showCloseButton && (\n <ActionIcon\n as={Close}\n css={{ position: 'absolute', right: '$4', top: '$4' }}\n label={closeDialogText}\n hasTooltip={false}\n size=\"md\"\n theme=\"neutral\"\n >\n <Icon is={CloseIcon} />\n </ActionIcon>\n )}\n {React.Children.map(\n children,\n (child?: React.ReactElement) =>\n child?.type !== DialogBackground && child\n )}\n </StyledDialogContent>\n </StyledDialogOverlay>\n </Portal>\n)\n"],"names":["contentOnScreen","contentOffScreen","modalOverlayId","slideIn","keyframes","slideOut","StyledDialogOverlay","styled","Overlay","DIALOG_Z_INDEX","fadeIn","fadeOut","StyledDialogContent","Content","DialogContent","size","children","closeDialogText","showCloseButton","remainingProps","React","Portal","child","DialogBackground","event","element","ActionIcon","Close","Icon","CloseIcon"],"mappings":"
|
|
1
|
+
{"version":3,"file":"DialogContent.js","sources":["../../../src/components/dialog/DialogContent.tsx"],"sourcesContent":["import { Close as CloseIcon } from '@atom-learning/icons'\nimport { Close, Content, Overlay, Portal } from '@radix-ui/react-dialog'\nimport * as React from 'react'\n\nimport { DIALOG_Z_INDEX } from '~/constants/zIndices'\nimport { keyframes, styled } from '~/stitches'\nimport { fadeIn, fadeOut } from '~/utilities'\n\nimport { ActionIcon } from '../action-icon/ActionIcon'\nimport { Icon } from '../icon/Icon'\nimport { DialogBackground } from './DialogBackground'\n\nconst contentOnScreen = 'translate3d(-50%, -50%, 0)'\nconst contentOffScreen = 'translate3d(-50%, 50vh, 0)'\nconst modalOverlayId = 'modal_overlay'\n\nconst slideIn = keyframes({\n '0%': { transform: contentOffScreen },\n '100%': { transform: contentOnScreen }\n})\nconst slideOut = keyframes({\n '0%': { transform: contentOnScreen },\n '100%': { transform: contentOffScreen }\n})\n\nconst StyledDialogOverlay = styled(Overlay, {\n backgroundColor: '$alpha600',\n top: 0,\n right: 0,\n bottom: 0,\n left: 0,\n position: 'fixed',\n overflowY: 'auto',\n zIndex: DIALOG_Z_INDEX,\n '@allowMotion': {\n '&[data-state=\"open\"]': {\n animation: `${fadeIn} 250ms ease-out`\n },\n '&[data-state=\"closed\"]': {\n animation: `${fadeOut} 550ms ease-out`\n }\n }\n})\n\nconst StyledDialogContent = styled(Content, {\n bg: 'white',\n borderRadius: '$1',\n boxShadow: '$3',\n boxSizing: 'border-box',\n left: '50%',\n maxWidth: '90vw',\n maxHeight: '90vh',\n overflowY: 'auto',\n p: '$5',\n position: 'fixed',\n top: '50%',\n transform: contentOnScreen,\n zIndex: DIALOG_Z_INDEX,\n '&:focus': {\n outline: 'none'\n },\n '@allowMotion': {\n '&[data-state=\"open\"]': {\n animation: `${slideIn} 550ms cubic-bezier(0.22, 1, 0.36, 1)`\n },\n '&[data-state=\"closed\"]': {\n animation: `${slideOut} 550ms cubic-bezier(0.22, 1, 0.36, 1)`\n }\n },\n variants: {\n size: {\n xs: { width: '380px' },\n sm: { width: '480px' },\n md: { width: '600px' },\n lg: { width: '800px' },\n xl: { width: '1100px' }\n }\n }\n})\n\ntype DialogContentProps = React.ComponentProps<typeof StyledDialogContent> & {\n closeDialogText?: string\n showCloseButton?: boolean\n}\n\nexport const DialogContent: React.FC<DialogContentProps> = ({\n size = 'sm',\n children,\n closeDialogText = 'Close dialog',\n showCloseButton = true,\n ...remainingProps\n}) => (\n <Portal>\n <StyledDialogOverlay id={modalOverlayId}>\n {React.Children.map(\n children,\n (child?: React.ReactElement) =>\n child?.type === DialogBackground && child\n )}\n <StyledDialogContent\n size={size}\n aria-label=\"Dialog\"\n onPointerDownOutside={(event) => {\n const element = event.target as HTMLElement\n if (element?.id !== modalOverlayId) {\n event.preventDefault()\n }\n }}\n {...remainingProps}\n >\n {showCloseButton && (\n <ActionIcon\n as={Close}\n css={{ position: 'absolute', right: '$4', top: '$4' }}\n label={closeDialogText}\n hasTooltip={false}\n size=\"md\"\n theme=\"neutral\"\n >\n <Icon is={CloseIcon} />\n </ActionIcon>\n )}\n {React.Children.map(\n children,\n (child?: React.ReactElement) =>\n child?.type !== DialogBackground && child\n )}\n </StyledDialogContent>\n </StyledDialogOverlay>\n </Portal>\n)\n"],"names":["contentOnScreen","contentOffScreen","modalOverlayId","slideIn","keyframes","slideOut","StyledDialogOverlay","styled","Overlay","DIALOG_Z_INDEX","fadeIn","fadeOut","StyledDialogContent","Content","DialogContent","size","children","closeDialogText","showCloseButton","remainingProps","React","Portal","child","DialogBackground","event","element","ActionIcon","Close","Icon","CloseIcon"],"mappings":"gkBAYA,MAAMA,EAAkB,6BAClBC,EAAmB,6BACnBC,EAAiB,gBAEjBC,EAAUC,EAAU,CACxB,KAAM,CAAE,UAAWH,CAAiB,EACpC,OAAQ,CAAE,UAAWD,CAAgB,CACvC,CAAC,EACKK,EAAWD,EAAU,CACzB,KAAM,CAAE,UAAWJ,CAAgB,EACnC,OAAQ,CAAE,UAAWC,CAAiB,CACxC,CAAC,EAEKK,EAAsBC,EAAOC,EAAS,CAC1C,gBAAiB,YACjB,IAAK,EACL,MAAO,EACP,OAAQ,EACR,KAAM,EACN,SAAU,QACV,UAAW,OACX,OAAQC,EACR,eAAgB,CACd,uBAAwB,CACtB,UAAW,GAAGC,kBAChB,EACA,yBAA0B,CACxB,UAAW,GAAGC,kBAChB,CACF,CACF,CAAC,EAEKC,EAAsBL,EAAOM,EAAS,CAC1C,GAAI,QACJ,aAAc,KACd,UAAW,KACX,UAAW,aACX,KAAM,MACN,SAAU,OACV,UAAW,OACX,UAAW,OACX,EAAG,KACH,SAAU,QACV,IAAK,MACL,UAAWb,EACX,OAAQS,EACR,UAAW,CACT,QAAS,MACX,EACA,eAAgB,CACd,uBAAwB,CACtB,UAAW,GAAGN,wCAChB,EACA,yBAA0B,CACxB,UAAW,GAAGE,wCAChB,CACF,EACA,SAAU,CACR,KAAM,CACJ,GAAI,CAAE,MAAO,OAAQ,EACrB,GAAI,CAAE,MAAO,OAAQ,EACrB,GAAI,CAAE,MAAO,OAAQ,EACrB,GAAI,CAAE,MAAO,OAAQ,EACrB,GAAI,CAAE,MAAO,QAAS,CACxB,CACF,CACF,CAAC,EAOYS,EAA8C,CAAC,CAC1D,KAAAC,EAAO,KACP,SAAAC,EACA,gBAAAC,EAAkB,eAClB,gBAAAC,EAAkB,MACfC,CACL,IACEC,EAAA,cAACC,EAAA,KACCD,EAAA,cAACd,EAAA,CAAoB,GAAIJ,CACtBkB,EAAAA,EAAM,SAAS,IACdJ,EACCM,IACCA,GAAA,KAAAA,OAAAA,EAAO,QAASC,GAAoBD,CACxC,EACAF,EAAA,cAACR,EAAA,CACC,KAAMG,EACN,aAAW,SACX,qBAAuBS,GAAU,CAC/B,MAAMC,EAAUD,EAAM,QAClBC,GAAA,KAAAA,OAAAA,EAAS,MAAOvB,GAClBsB,EAAM,eAAe,CAEzB,EACC,GAAGL,GAEHD,GACCE,EAAA,cAACM,EAAA,CACC,GAAIC,EACJ,IAAK,CAAE,SAAU,WAAY,MAAO,KAAM,IAAK,IAAK,EACpD,MAAOV,EACP,WAAY,GACZ,KAAK,KACL,MAAM,SAAA,EAENG,EAAA,cAACQ,EAAA,CAAK,GAAIC,EAAW,CACvB,EAEDT,EAAM,SAAS,IACdJ,EACCM,IACCA,GAAA,KAAA,OAAAA,EAAO,QAASC,GAAoBD,CACxC,CACF,CACF,CACF"}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{Content as a}from"@radix-ui/react-dropdown-menu";import{DROPDOWN_Z_INDEX as i}from"../../constants/zIndices.js";import{styled as t}from"../../stitches.js";import{slideDownAndFade as o,slideLeftAndFade as n,slideUpAndFade as e,slideRightAndFade as d}from"../../utilities/style/keyframe-animations.js";const m=t(a,{bg:"white",borderRadius:"$0",boxShadow:"$0",py:"$2",zIndex:i,"@allowMotion":{animationDuration:"250ms",animationTimingFunction:"cubic-bezier(0.16, 1, 0.3, 1)",willChange:"transform, opacity",'&[data-state="open"]':{'&[data-side="top"]':{animationName:o},'&[data-side="right"]':{animationName:n},'&[data-side="bottom"]':{animationName:e},'&[data-side="left"]':{animationName:d}}}});export{m as DropdownMenuContent};
|
|
1
|
+
import{Content as a}from"@radix-ui/react-dropdown-menu";import{DROPDOWN_Z_INDEX as i}from"../../constants/zIndices.js";import{styled as t}from"../../stitches.js";import"../../utilities/css-wrapper/CSSWrapper.js";import"color2k";import{slideDownAndFade as o,slideLeftAndFade as n,slideUpAndFade as e,slideRightAndFade as d}from"../../utilities/style/keyframe-animations.js";const m=t(a,{bg:"white",borderRadius:"$0",boxShadow:"$0",py:"$2",zIndex:i,"@allowMotion":{animationDuration:"250ms",animationTimingFunction:"cubic-bezier(0.16, 1, 0.3, 1)",willChange:"transform, opacity",'&[data-state="open"]':{'&[data-side="top"]':{animationName:o},'&[data-side="right"]':{animationName:n},'&[data-side="bottom"]':{animationName:e},'&[data-side="left"]':{animationName:d}}}});export{m as DropdownMenuContent};
|
|
2
2
|
//# sourceMappingURL=DropdownMenuContent.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"DropdownMenuContent.js","sources":["../../../src/components/dropdown-menu/DropdownMenuContent.tsx"],"sourcesContent":["import { Content } from '@radix-ui/react-dropdown-menu'\n\nimport { DROPDOWN_Z_INDEX } from '~/constants/zIndices'\nimport { styled } from '~/stitches'\nimport {\n slideDownAndFade,\n slideLeftAndFade,\n slideRightAndFade,\n slideUpAndFade\n} from '~/utilities'\n\nexport const DropdownMenuContent = styled(Content, {\n bg: 'white',\n borderRadius: '$0',\n boxShadow: '$0',\n py: '$2',\n zIndex: DROPDOWN_Z_INDEX,\n '@allowMotion': {\n animationDuration: '250ms',\n animationTimingFunction: 'cubic-bezier(0.16, 1, 0.3, 1)',\n willChange: 'transform, opacity',\n '&[data-state=\"open\"]': {\n '&[data-side=\"top\"]': { animationName: slideDownAndFade },\n '&[data-side=\"right\"]': { animationName: slideLeftAndFade },\n '&[data-side=\"bottom\"]': { animationName: slideUpAndFade },\n '&[data-side=\"left\"]': { animationName: slideRightAndFade }\n }\n }\n})\n"],"names":["DropdownMenuContent","styled","Content","DROPDOWN_Z_INDEX","slideDownAndFade","slideLeftAndFade","slideUpAndFade","slideRightAndFade"],"mappings":"
|
|
1
|
+
{"version":3,"file":"DropdownMenuContent.js","sources":["../../../src/components/dropdown-menu/DropdownMenuContent.tsx"],"sourcesContent":["import { Content } from '@radix-ui/react-dropdown-menu'\n\nimport { DROPDOWN_Z_INDEX } from '~/constants/zIndices'\nimport { styled } from '~/stitches'\nimport {\n slideDownAndFade,\n slideLeftAndFade,\n slideRightAndFade,\n slideUpAndFade\n} from '~/utilities'\n\nexport const DropdownMenuContent = styled(Content, {\n bg: 'white',\n borderRadius: '$0',\n boxShadow: '$0',\n py: '$2',\n zIndex: DROPDOWN_Z_INDEX,\n '@allowMotion': {\n animationDuration: '250ms',\n animationTimingFunction: 'cubic-bezier(0.16, 1, 0.3, 1)',\n willChange: 'transform, opacity',\n '&[data-state=\"open\"]': {\n '&[data-side=\"top\"]': { animationName: slideDownAndFade },\n '&[data-side=\"right\"]': { animationName: slideLeftAndFade },\n '&[data-side=\"bottom\"]': { animationName: slideUpAndFade },\n '&[data-side=\"left\"]': { animationName: slideRightAndFade }\n }\n }\n})\n"],"names":["DropdownMenuContent","styled","Content","DROPDOWN_Z_INDEX","slideDownAndFade","slideLeftAndFade","slideUpAndFade","slideRightAndFade"],"mappings":"qXAWO,MAAMA,EAAsBC,EAAOC,EAAS,CACjD,GAAI,QACJ,aAAc,KACd,UAAW,KACX,GAAI,KACJ,OAAQC,EACR,eAAgB,CACd,kBAAmB,QACnB,wBAAyB,gCACzB,WAAY,qBACZ,uBAAwB,CACtB,qBAAsB,CAAE,cAAeC,CAAiB,EACxD,uBAAwB,CAAE,cAAeC,CAAiB,EAC1D,wBAAyB,CAAE,cAAeC,CAAe,EACzD,sBAAuB,CAAE,cAAeC,CAAkB,CAC5D,CACF,CACF,CAAC"}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import*as
|
|
1
|
+
import*as p from"react";import{styled as o}from"../../stitches.js";import{createThemeVariants as s}from"../../utilities/create-theme-variants/createThemeVariants.js";import"../../utilities/css-wrapper/CSSWrapper.js";import"color2k";import"../../utilities/style/keyframe-animations.js";const n=o("div",{display:"grid",variants:{gap:s("space",{gap:"$key"})}}),e=({css:a,gap:i=2,minItemSize:t,maxItemSize:m="1fr",...r})=>p.createElement(n,{css:{...t&&{gridTemplateColumns:`repeat(auto-fit, minmax(${t}, ${m}))`},...a},gap:i,...r});e.displayName="Grid";export{e as Grid};
|
|
2
2
|
//# sourceMappingURL=Grid.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Grid.js","sources":["../../../src/components/grid/Grid.tsx"],"sourcesContent":["import * as React from 'react'\n\nimport { CSS, styled } from '~/stitches'\nimport { createThemeVariants } from '~/utilities'\n\nconst GridContainer = styled('div', {\n display: 'grid',\n variants: {\n gap: createThemeVariants('space', { gap: '$key' })\n }\n})\n\ntype GridProps = React.ComponentProps<typeof GridContainer> & {\n minItemSize?: string\n maxItemSize?: string\n} & {\n css?: CSS\n as?: any\n} // (!) `css` and `as` are both props that come from `stitches`. It would be better to figure out and export the appropriate type for them in stitches!\n\nexport const Grid: React.FC<GridProps> = ({\n css,\n gap = 2,\n minItemSize,\n maxItemSize = '1fr',\n ...remainingProps\n}) => (\n <GridContainer\n css={{\n ...(minItemSize && {\n gridTemplateColumns: `repeat(auto-fit, minmax(${minItemSize}, ${maxItemSize}))`\n }),\n ...(css as any)\n }}\n gap={gap}\n {...remainingProps}\n />\n)\n\nGrid.displayName = 'Grid'\n"],"names":["GridContainer","styled","createThemeVariants","Grid","css","gap","minItemSize","maxItemSize","remainingProps","React"],"mappings":"
|
|
1
|
+
{"version":3,"file":"Grid.js","sources":["../../../src/components/grid/Grid.tsx"],"sourcesContent":["import * as React from 'react'\n\nimport { CSS, styled } from '~/stitches'\nimport { createThemeVariants } from '~/utilities'\n\nconst GridContainer = styled('div', {\n display: 'grid',\n variants: {\n gap: createThemeVariants('space', { gap: '$key' })\n }\n})\n\ntype GridProps = React.ComponentProps<typeof GridContainer> & {\n minItemSize?: string\n maxItemSize?: string\n} & {\n css?: CSS\n as?: any\n} // (!) `css` and `as` are both props that come from `stitches`. It would be better to figure out and export the appropriate type for them in stitches!\n\nexport const Grid: React.FC<GridProps> = ({\n css,\n gap = 2,\n minItemSize,\n maxItemSize = '1fr',\n ...remainingProps\n}) => (\n <GridContainer\n css={{\n ...(minItemSize && {\n gridTemplateColumns: `repeat(auto-fit, minmax(${minItemSize}, ${maxItemSize}))`\n }),\n ...(css as any)\n }}\n gap={gap}\n {...remainingProps}\n />\n)\n\nGrid.displayName = 'Grid'\n"],"names":["GridContainer","styled","createThemeVariants","Grid","css","gap","minItemSize","maxItemSize","remainingProps","React"],"mappings":"6RAKA,MAAMA,EAAgBC,EAAO,MAAO,CAClC,QAAS,OACT,SAAU,CACR,IAAKC,EAAoB,QAAS,CAAE,IAAK,MAAO,CAAC,CACnD,CACF,CAAC,EAUYC,EAA4B,CAAC,CACxC,IAAAC,EACA,IAAAC,EAAM,EACN,YAAAC,EACA,YAAAC,EAAc,SACXC,CACL,IACEC,EAAA,cAACT,EAAA,CACC,IAAK,CACH,GAAIM,GAAe,CACjB,oBAAqB,2BAA2BA,MAAgBC,KAClE,EACA,GAAIH,CACN,EACA,IAAKC,EACJ,GAAGG,CACN,CAAA,EAGFL,EAAK,YAAc"}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import*as i from"react";import{styled as
|
|
1
|
+
import*as i from"react";import{styled as r}from"../../stitches.js";import"../../utilities/css-wrapper/CSSWrapper.js";import{capsize as e}from"../../utilities/style/capsize.js";import"color2k";import"../../utilities/style/keyframe-animations.js";const t=r("h2",{fontFamily:"$display",fontWeight:700,m:0,variants:{size:{xs:{fontFamily:"$body",fontWeight:600,fontSize:"$md",lineHeight:1.5,...e(.3864)},sm:{fontSize:"$lg",lineHeight:1.14,...e(.2174,.2254)},md:{fontSize:"$xl",lineHeight:1.14,...e(.2174,.2254)},lg:{fontSize:"$2xl",lineHeight:1.08,...e(.1865,.1945)},xl:{fontSize:"$3xl",lineHeight:1.12,...e(.206,.214)},xxl:{fontSize:"$4xl",lineHeight:1.06,...e(.1793,.1873)}},noCapsize:{true:{"&::before, &::after":{display:"none !important"}}}}}),o=i.forwardRef(({size:n="md",...l},m)=>i.createElement(t,{ref:m,size:n,...l}));o.displayName="Heading";export{o as Heading,t as StyledHeading};
|
|
2
2
|
//# sourceMappingURL=Heading.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Heading.js","sources":["../../../src/components/heading/Heading.tsx"],"sourcesContent":["import * as React from 'react'\n\nimport { styled } from '~/stitches'\nimport type { Override } from '~/utilities'\nimport { capsize } from '~/utilities'\n\nexport const StyledHeading = styled('h2', {\n fontFamily: '$display',\n fontWeight: 700,\n m: 0,\n variants: {\n size: {\n xs: {\n fontFamily: '$body',\n fontWeight: 600,\n fontSize: '$md',\n lineHeight: 1.5,\n ...capsize(0.3864)\n },\n sm: {\n fontSize: '$lg',\n lineHeight: 1.14,\n ...capsize(0.2174, 0.2254)\n },\n md: {\n fontSize: '$xl',\n lineHeight: 1.14,\n ...capsize(0.2174, 0.2254)\n },\n lg: {\n fontSize: '$2xl',\n lineHeight: 1.08,\n ...capsize(0.1865, 0.1945)\n },\n xl: {\n fontSize: '$3xl',\n lineHeight: 1.12,\n ...capsize(0.206, 0.214)\n },\n xxl: {\n fontSize: '$4xl',\n lineHeight: 1.06,\n ...capsize(0.1793, 0.1873)\n }\n },\n noCapsize: {\n true: {\n '&::before, &::after': { display: 'none !important' }\n }\n }\n }\n})\n\nexport type HeadingProps = Override<\n React.ComponentPropsWithoutRef<typeof StyledHeading>,\n {\n as?:\n | 'h1'\n | 'h2'\n | 'h3'\n | 'h4'\n | 'h5'\n | 'h6'\n | React.ComponentType\n | React.ElementType\n }\n>\n\nexport const Heading: React.ForwardRefExoticComponent<HeadingProps> =\n React.forwardRef(({ size = 'md', ...remainingProps }, ref) => (\n <StyledHeading ref={ref} size={size} {...remainingProps} />\n ))\n\nHeading.displayName = 'Heading'\n"],"names":["StyledHeading","styled","capsize","Heading","React","size","remainingProps","ref"],"mappings":"
|
|
1
|
+
{"version":3,"file":"Heading.js","sources":["../../../src/components/heading/Heading.tsx"],"sourcesContent":["import * as React from 'react'\n\nimport { styled } from '~/stitches'\nimport type { Override } from '~/utilities'\nimport { capsize } from '~/utilities'\n\nexport const StyledHeading = styled('h2', {\n fontFamily: '$display',\n fontWeight: 700,\n m: 0,\n variants: {\n size: {\n xs: {\n fontFamily: '$body',\n fontWeight: 600,\n fontSize: '$md',\n lineHeight: 1.5,\n ...capsize(0.3864)\n },\n sm: {\n fontSize: '$lg',\n lineHeight: 1.14,\n ...capsize(0.2174, 0.2254)\n },\n md: {\n fontSize: '$xl',\n lineHeight: 1.14,\n ...capsize(0.2174, 0.2254)\n },\n lg: {\n fontSize: '$2xl',\n lineHeight: 1.08,\n ...capsize(0.1865, 0.1945)\n },\n xl: {\n fontSize: '$3xl',\n lineHeight: 1.12,\n ...capsize(0.206, 0.214)\n },\n xxl: {\n fontSize: '$4xl',\n lineHeight: 1.06,\n ...capsize(0.1793, 0.1873)\n }\n },\n noCapsize: {\n true: {\n '&::before, &::after': { display: 'none !important' }\n }\n }\n }\n})\n\nexport type HeadingProps = Override<\n React.ComponentPropsWithoutRef<typeof StyledHeading>,\n {\n as?:\n | 'h1'\n | 'h2'\n | 'h3'\n | 'h4'\n | 'h5'\n | 'h6'\n | React.ComponentType\n | React.ElementType\n }\n>\n\nexport const Heading: React.ForwardRefExoticComponent<HeadingProps> =\n React.forwardRef(({ size = 'md', ...remainingProps }, ref) => (\n <StyledHeading ref={ref} size={size} {...remainingProps} />\n ))\n\nHeading.displayName = 'Heading'\n"],"names":["StyledHeading","styled","capsize","Heading","React","size","remainingProps","ref"],"mappings":"qPAMa,MAAAA,EAAgBC,EAAO,KAAM,CACxC,WAAY,WACZ,WAAY,IACZ,EAAG,EACH,SAAU,CACR,KAAM,CACJ,GAAI,CACF,WAAY,QACZ,WAAY,IACZ,SAAU,MACV,WAAY,IACZ,GAAGC,EAAQ,KAAM,CACnB,EACA,GAAI,CACF,SAAU,MACV,WAAY,KACZ,GAAGA,EAAQ,MAAQ,KAAM,CAC3B,EACA,GAAI,CACF,SAAU,MACV,WAAY,KACZ,GAAGA,EAAQ,MAAQ,KAAM,CAC3B,EACA,GAAI,CACF,SAAU,OACV,WAAY,KACZ,GAAGA,EAAQ,MAAQ,KAAM,CAC3B,EACA,GAAI,CACF,SAAU,OACV,WAAY,KACZ,GAAGA,EAAQ,KAAO,IAAK,CACzB,EACA,IAAK,CACH,SAAU,OACV,WAAY,KACZ,GAAGA,EAAQ,MAAQ,KAAM,CAC3B,CACF,EACA,UAAW,CACT,KAAM,CACJ,sBAAuB,CAAE,QAAS,iBAAkB,CACtD,CACF,CACF,CACF,CAAC,EAiBYC,EACXC,EAAM,WAAW,CAAC,CAAE,KAAAC,EAAO,QAASC,CAAe,EAAGC,IACpDH,EAAA,cAACJ,GAAc,IAAKO,EAAK,KAAMF,EAAO,GAAGC,CAAAA,CAAgB,CAC1D,EAEHH,EAAQ,YAAc"}
|
|
@@ -71,6 +71,7 @@ export { ToggleGroup } from './toggle-group';
|
|
|
71
71
|
export { Tooltip } from './tooltip';
|
|
72
72
|
export { TopBar } from './top-bar';
|
|
73
73
|
export { Video } from './video';
|
|
74
|
+
export { BannerRegular } from './banner';
|
|
74
75
|
export { Tile, TileGroup } from './tile';
|
|
75
76
|
export { TileInteractive } from './tile-interactive';
|
|
76
77
|
export { TileToggleGroup } from './tile-toggle-group';
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{Close as r}from"@atom-learning/icons";import{Content as l,Arrow as p,Close as h}from"@radix-ui/react-popover";import*as e from"react";import{POPOVER_Z_INDEX as c}from"../../constants/zIndices.js";import{styled as t}from"../../stitches.js";import
|
|
1
|
+
import{Close as r}from"@atom-learning/icons";import{Content as l,Arrow as p,Close as h}from"@radix-ui/react-popover";import*as e from"react";import{POPOVER_Z_INDEX as c}from"../../constants/zIndices.js";import{styled as t}from"../../stitches.js";import"../../utilities/css-wrapper/CSSWrapper.js";import"color2k";import{slideDownAndFade as f,slideLeftAndFade as x,slideUpAndFade as $,slideRightAndFade as g}from"../../utilities/style/keyframe-animations.js";import{ActionIcon as w}from"../action-icon/ActionIcon.js";import{Icon as z}from"../icon/Icon.js";const b=t(l,{bg:"white",borderRadius:"$1",boxShadow:"$2",maxWidth:"90vw",p:"$sizes$2",pr:"$6",position:"relative",zIndex:c,"@allowMotion":{animationDuration:"75ms",animationTimingFunction:"cubic-bezier(0.16, 1, 0.3, 1)",willChange:"transform, opacity",'&[data-state="open"]':{'&[data-side="top"]':{animationName:f},'&[data-side="right"]':{animationName:x},'&[data-side="bottom"]':{animationName:$},'&[data-side="left"]':{animationName:g}}},variants:{size:{sm:{maxWidth:"200px"},md:{maxWidth:"400px"},lg:{maxWidth:"600px"}}}}),C=t(p,{fill:"white",zIndex:1,'[data-align="end"] &':{mr:"$sizes$2"},'[data-align="start"] &':{ml:"$sizes$2"}}),u=({children:i,side:o="top",sideOffset:a=8,closePopoverText:s="Close popover",showCloseButton:n=!0,size:m="md",...d})=>e.createElement(b,{size:m,side:o,sideOffset:a,...d},n&&e.createElement(w,{as:h,css:{position:"absolute",right:"$0",top:"$0"},label:s,size:"md",hasTooltip:!1,theme:"neutral"},e.createElement(z,{is:r})),i,e.createElement(C,{width:16,height:8}));export{u as PopoverContent};
|
|
2
2
|
//# sourceMappingURL=PopoverContent.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"PopoverContent.js","sources":["../../../src/components/popover/PopoverContent.tsx"],"sourcesContent":["import { Close as CloseIcon } from '@atom-learning/icons'\nimport { Arrow, Close, Content } from '@radix-ui/react-popover'\nimport * as React from 'react'\n\nimport { POPOVER_Z_INDEX } from '~/constants/zIndices'\nimport { styled } from '~/stitches'\nimport {\n slideDownAndFade,\n slideLeftAndFade,\n slideRightAndFade,\n slideUpAndFade\n} from '~/utilities'\n\nimport { ActionIcon } from '../action-icon/ActionIcon'\nimport { Icon } from '../icon/Icon'\n\nconst StyledContent = styled(Content, {\n bg: 'white',\n borderRadius: '$1',\n boxShadow: '$2',\n maxWidth: '90vw',\n p: '$sizes$2',\n pr: '$6',\n position: 'relative',\n zIndex: POPOVER_Z_INDEX,\n '@allowMotion': {\n animationDuration: '75ms',\n animationTimingFunction: 'cubic-bezier(0.16, 1, 0.3, 1)',\n willChange: 'transform, opacity',\n '&[data-state=\"open\"]': {\n '&[data-side=\"top\"]': { animationName: slideDownAndFade },\n '&[data-side=\"right\"]': { animationName: slideLeftAndFade },\n '&[data-side=\"bottom\"]': { animationName: slideUpAndFade },\n '&[data-side=\"left\"]': { animationName: slideRightAndFade }\n }\n },\n variants: {\n size: {\n sm: { maxWidth: '200px' },\n md: { maxWidth: '400px' },\n lg: { maxWidth: '600px' }\n }\n }\n})\n\nconst StyledArrow = styled(Arrow, {\n fill: 'white',\n zIndex: 1,\n '[data-align=\"end\"] &': { mr: '$sizes$2' },\n '[data-align=\"start\"] &': { ml: '$sizes$2' }\n})\n\ntype PopoverContentProps = React.ComponentProps<typeof StyledContent> &\n React.ComponentProps<typeof Content> & {\n closePopoverText?: string\n showCloseButton?: boolean\n }\n\nexport const PopoverContent: React.FC<PopoverContentProps> = ({\n children,\n side = 'top',\n sideOffset = 8,\n closePopoverText = 'Close popover',\n showCloseButton = true,\n size = 'md',\n ...remainingProps\n}) => (\n <StyledContent\n size={size}\n side={side}\n sideOffset={sideOffset}\n {...remainingProps}\n >\n {showCloseButton && (\n <ActionIcon\n as={Close}\n css={{ position: 'absolute', right: '$0', top: '$0' }}\n label={closePopoverText}\n size=\"md\"\n hasTooltip={false}\n theme=\"neutral\"\n >\n <Icon is={CloseIcon} />\n </ActionIcon>\n )}\n {children}\n <StyledArrow width={16} height={8} />\n </StyledContent>\n)\n"],"names":["StyledContent","styled","Content","POPOVER_Z_INDEX","slideDownAndFade","slideLeftAndFade","slideUpAndFade","slideRightAndFade","StyledArrow","Arrow","PopoverContent","children","side","sideOffset","closePopoverText","showCloseButton","size","remainingProps","React","ActionIcon","Close","Icon","CloseIcon"],"mappings":"
|
|
1
|
+
{"version":3,"file":"PopoverContent.js","sources":["../../../src/components/popover/PopoverContent.tsx"],"sourcesContent":["import { Close as CloseIcon } from '@atom-learning/icons'\nimport { Arrow, Close, Content } from '@radix-ui/react-popover'\nimport * as React from 'react'\n\nimport { POPOVER_Z_INDEX } from '~/constants/zIndices'\nimport { styled } from '~/stitches'\nimport {\n slideDownAndFade,\n slideLeftAndFade,\n slideRightAndFade,\n slideUpAndFade\n} from '~/utilities'\n\nimport { ActionIcon } from '../action-icon/ActionIcon'\nimport { Icon } from '../icon/Icon'\n\nconst StyledContent = styled(Content, {\n bg: 'white',\n borderRadius: '$1',\n boxShadow: '$2',\n maxWidth: '90vw',\n p: '$sizes$2',\n pr: '$6',\n position: 'relative',\n zIndex: POPOVER_Z_INDEX,\n '@allowMotion': {\n animationDuration: '75ms',\n animationTimingFunction: 'cubic-bezier(0.16, 1, 0.3, 1)',\n willChange: 'transform, opacity',\n '&[data-state=\"open\"]': {\n '&[data-side=\"top\"]': { animationName: slideDownAndFade },\n '&[data-side=\"right\"]': { animationName: slideLeftAndFade },\n '&[data-side=\"bottom\"]': { animationName: slideUpAndFade },\n '&[data-side=\"left\"]': { animationName: slideRightAndFade }\n }\n },\n variants: {\n size: {\n sm: { maxWidth: '200px' },\n md: { maxWidth: '400px' },\n lg: { maxWidth: '600px' }\n }\n }\n})\n\nconst StyledArrow = styled(Arrow, {\n fill: 'white',\n zIndex: 1,\n '[data-align=\"end\"] &': { mr: '$sizes$2' },\n '[data-align=\"start\"] &': { ml: '$sizes$2' }\n})\n\ntype PopoverContentProps = React.ComponentProps<typeof StyledContent> &\n React.ComponentProps<typeof Content> & {\n closePopoverText?: string\n showCloseButton?: boolean\n }\n\nexport const PopoverContent: React.FC<PopoverContentProps> = ({\n children,\n side = 'top',\n sideOffset = 8,\n closePopoverText = 'Close popover',\n showCloseButton = true,\n size = 'md',\n ...remainingProps\n}) => (\n <StyledContent\n size={size}\n side={side}\n sideOffset={sideOffset}\n {...remainingProps}\n >\n {showCloseButton && (\n <ActionIcon\n as={Close}\n css={{ position: 'absolute', right: '$0', top: '$0' }}\n label={closePopoverText}\n size=\"md\"\n hasTooltip={false}\n theme=\"neutral\"\n >\n <Icon is={CloseIcon} />\n </ActionIcon>\n )}\n {children}\n <StyledArrow width={16} height={8} />\n </StyledContent>\n)\n"],"names":["StyledContent","styled","Content","POPOVER_Z_INDEX","slideDownAndFade","slideLeftAndFade","slideUpAndFade","slideRightAndFade","StyledArrow","Arrow","PopoverContent","children","side","sideOffset","closePopoverText","showCloseButton","size","remainingProps","React","ActionIcon","Close","Icon","CloseIcon"],"mappings":"0iBAgBA,MAAMA,EAAgBC,EAAOC,EAAS,CACpC,GAAI,QACJ,aAAc,KACd,UAAW,KACX,SAAU,OACV,EAAG,WACH,GAAI,KACJ,SAAU,WACV,OAAQC,EACR,eAAgB,CACd,kBAAmB,OACnB,wBAAyB,gCACzB,WAAY,qBACZ,uBAAwB,CACtB,qBAAsB,CAAE,cAAeC,CAAiB,EACxD,uBAAwB,CAAE,cAAeC,CAAiB,EAC1D,wBAAyB,CAAE,cAAeC,CAAe,EACzD,sBAAuB,CAAE,cAAeC,CAAkB,CAC5D,CACF,EACA,SAAU,CACR,KAAM,CACJ,GAAI,CAAE,SAAU,OAAQ,EACxB,GAAI,CAAE,SAAU,OAAQ,EACxB,GAAI,CAAE,SAAU,OAAQ,CAC1B,CACF,CACF,CAAC,EAEKC,EAAcP,EAAOQ,EAAO,CAChC,KAAM,QACN,OAAQ,EACR,uBAAwB,CAAE,GAAI,UAAW,EACzC,yBAA0B,CAAE,GAAI,UAAW,CAC7C,CAAC,EAQYC,EAAgD,CAAC,CAC5D,SAAAC,EACA,KAAAC,EAAO,MACP,WAAAC,EAAa,EACb,iBAAAC,EAAmB,gBACnB,gBAAAC,EAAkB,GAClB,KAAAC,EAAO,QACJC,CACL,IACEC,EAAA,cAAClB,EAAA,CACC,KAAMgB,EACN,KAAMJ,EACN,WAAYC,EACX,GAAGI,CAAAA,EAEHF,GACCG,EAAA,cAACC,EAAA,CACC,GAAIC,EACJ,IAAK,CAAE,SAAU,WAAY,MAAO,KAAM,IAAK,IAAK,EACpD,MAAON,EACP,KAAK,KACL,WAAY,GACZ,MAAM,SAENI,EAAAA,EAAA,cAACG,EAAA,CAAK,GAAIC,EAAW,CACvB,EAEDX,EACDO,EAAA,cAACV,EAAA,CAAY,MAAO,GAAI,OAAQ,CAAA,CAAG,CACrC"}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import*as e from"react";import{styled as s,theme as c}from"../../stitches.js";import{encodeBackgroundIcon as p}from"../../utilities/style/encode-background-icon.js";const u=s("select",{appearance:"none",backgroundColor:"white",backgroundImage:p(c.colors.tonal300.value,"chevron"),backgroundRepeat:"no-repeat, repeat",border:"1px solid $tonal300",borderRadius:"$0",color:"$tonal600",display:"block",fontFamily:"$body",fontWeight:400,lineHeight:1.4,transition:"all 75ms ease-out",width:"100%","&:hover":{cursor:"pointer"},"&:focus":{borderColor:"$primary",outline:"none"},"&::-ms-expand":{display:"none"},"&[disabled], > option[disabled]":{backgroundColor:"$tonal100",color:"$tonal400",cursor:"not-allowed"},variants:{size:{sm:{backgroundPosition:"right $space$2 top 50%, 0 0",backgroundSize:"18px auto, 100%",fontSize:"$sm",height:"$3",pl:"$2",pr:"$5"},md:{backgroundPosition:"right $space$3 top 50%, 0 0",backgroundSize:"20px auto, 100%",fontSize:"$md",height:"$4",pl:"$3",pr:"$6"}},state:{error:{border:"1px solid $danger"}}}}),
|
|
1
|
+
import*as e from"react";import{styled as s,theme as c}from"../../stitches.js";import"../../utilities/css-wrapper/CSSWrapper.js";import{encodeBackgroundIcon as p}from"../../utilities/style/encode-background-icon.js";import"../../utilities/style/keyframe-animations.js";const u=s("select",{appearance:"none",backgroundColor:"white",backgroundImage:p(c.colors.tonal300.value,"chevron"),backgroundRepeat:"no-repeat, repeat",border:"1px solid $tonal300",borderRadius:"$0",color:"$tonal600",display:"block",fontFamily:"$body",fontWeight:400,lineHeight:1.4,transition:"all 75ms ease-out",width:"100%","&:hover":{cursor:"pointer"},"&:focus":{borderColor:"$primary",outline:"none"},"&::-ms-expand":{display:"none"},"&[disabled], > option[disabled]":{backgroundColor:"$tonal100",color:"$tonal400",cursor:"not-allowed"},variants:{size:{sm:{backgroundPosition:"right $space$2 top 50%, 0 0",backgroundSize:"18px auto, 100%",fontSize:"$sm",height:"$3",pl:"$2",pr:"$5"},md:{backgroundPosition:"right $space$3 top 50%, 0 0",backgroundSize:"20px auto, 100%",fontSize:"$md",height:"$4",pl:"$3",pr:"$6"}},state:{error:{border:"1px solid $danger"}}}}),a=e.forwardRef(({placeholder:r,children:n,size:i="md",...o},l)=>{const t={size:i,ref:l,...o};return[o.value,o.defaultValue].every(d=>d===void 0)&&(t.defaultValue=""),e.createElement(u,{...t},r&&e.createElement("option",{disabled:!0,hidden:!0,value:""},r),n)});a.displayName="Select";export{a as Select};
|
|
2
2
|
//# sourceMappingURL=Select.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Select.js","sources":["../../../src/components/select/Select.tsx"],"sourcesContent":["import * as React from 'react'\n\nimport { styled, theme } from '~/stitches'\nimport { encodeBackgroundIcon } from '~/utilities'\nimport { Override } from '~/utilities/types'\n\nconst StyledSelect = styled('select', {\n appearance: 'none',\n backgroundColor: 'white',\n backgroundImage: encodeBackgroundIcon(theme.colors.tonal300.value, 'chevron'),\n backgroundRepeat: 'no-repeat, repeat',\n border: '1px solid $tonal300',\n borderRadius: '$0',\n color: '$tonal600',\n display: 'block',\n fontFamily: '$body',\n fontWeight: 400,\n lineHeight: 1.4,\n transition: 'all 75ms ease-out',\n width: '100%',\n '&:hover': {\n cursor: 'pointer'\n },\n '&:focus': {\n borderColor: '$primary',\n outline: 'none'\n },\n '&::-ms-expand': {\n display: 'none'\n },\n '&[disabled], > option[disabled]': {\n backgroundColor: '$tonal100',\n color: '$tonal400',\n cursor: 'not-allowed'\n },\n variants: {\n size: {\n sm: {\n backgroundPosition: 'right $space$2 top 50%, 0 0',\n backgroundSize: '18px auto, 100%',\n fontSize: '$sm',\n height: '$3',\n pl: '$2',\n pr: '$5'\n },\n md: {\n backgroundPosition: 'right $space$3 top 50%, 0 0',\n backgroundSize: '20px auto, 100%',\n fontSize: '$md',\n height: '$4',\n pl: '$3',\n pr: '$6'\n }\n },\n state: {\n error: {\n border: '1px solid $danger'\n }\n }\n }\n})\n\nexport type SelectProps = Override<\n React.ComponentProps<typeof StyledSelect>,\n {\n as?: never\n placeholder?: string\n }\n // TODO: figure out why uncommenting this causes TS errors in\n // component declaration\n // & (\n // | { id: string; 'aria-label'?: string }\n // | { 'aria-label': string; id?: string }\n // )\n>\n\nexport const Select: React.FC<SelectProps> = React.forwardRef(\n ({ placeholder, children, size = 'md', ...remainingProps }, ref) => {\n const props = { size, ref, ...remainingProps }\n\n if (\n [remainingProps.value, remainingProps.defaultValue].every(\n (value) => value === undefined\n )\n ) {\n props.defaultValue = ''\n }\n\n return (\n <StyledSelect {...props}>\n {placeholder && (\n <option disabled hidden value=\"\">\n {placeholder}\n </option>\n )}\n {children}\n </StyledSelect>\n )\n }\n)\n\nSelect.displayName = 'Select'\n"],"names":["StyledSelect","styled","encodeBackgroundIcon","theme","Select","React","placeholder","children","size","remainingProps","ref","props","value"],"mappings":"
|
|
1
|
+
{"version":3,"file":"Select.js","sources":["../../../src/components/select/Select.tsx"],"sourcesContent":["import * as React from 'react'\n\nimport { styled, theme } from '~/stitches'\nimport { encodeBackgroundIcon } from '~/utilities'\nimport { Override } from '~/utilities/types'\n\nconst StyledSelect = styled('select', {\n appearance: 'none',\n backgroundColor: 'white',\n backgroundImage: encodeBackgroundIcon(theme.colors.tonal300.value, 'chevron'),\n backgroundRepeat: 'no-repeat, repeat',\n border: '1px solid $tonal300',\n borderRadius: '$0',\n color: '$tonal600',\n display: 'block',\n fontFamily: '$body',\n fontWeight: 400,\n lineHeight: 1.4,\n transition: 'all 75ms ease-out',\n width: '100%',\n '&:hover': {\n cursor: 'pointer'\n },\n '&:focus': {\n borderColor: '$primary',\n outline: 'none'\n },\n '&::-ms-expand': {\n display: 'none'\n },\n '&[disabled], > option[disabled]': {\n backgroundColor: '$tonal100',\n color: '$tonal400',\n cursor: 'not-allowed'\n },\n variants: {\n size: {\n sm: {\n backgroundPosition: 'right $space$2 top 50%, 0 0',\n backgroundSize: '18px auto, 100%',\n fontSize: '$sm',\n height: '$3',\n pl: '$2',\n pr: '$5'\n },\n md: {\n backgroundPosition: 'right $space$3 top 50%, 0 0',\n backgroundSize: '20px auto, 100%',\n fontSize: '$md',\n height: '$4',\n pl: '$3',\n pr: '$6'\n }\n },\n state: {\n error: {\n border: '1px solid $danger'\n }\n }\n }\n})\n\nexport type SelectProps = Override<\n React.ComponentProps<typeof StyledSelect>,\n {\n as?: never\n placeholder?: string\n }\n // TODO: figure out why uncommenting this causes TS errors in\n // component declaration\n // & (\n // | { id: string; 'aria-label'?: string }\n // | { 'aria-label': string; id?: string }\n // )\n>\n\nexport const Select: React.FC<SelectProps> = React.forwardRef(\n ({ placeholder, children, size = 'md', ...remainingProps }, ref) => {\n const props = { size, ref, ...remainingProps }\n\n if (\n [remainingProps.value, remainingProps.defaultValue].every(\n (value) => value === undefined\n )\n ) {\n props.defaultValue = ''\n }\n\n return (\n <StyledSelect {...props}>\n {placeholder && (\n <option disabled hidden value=\"\">\n {placeholder}\n </option>\n )}\n {children}\n </StyledSelect>\n )\n }\n)\n\nSelect.displayName = 'Select'\n"],"names":["StyledSelect","styled","encodeBackgroundIcon","theme","Select","React","placeholder","children","size","remainingProps","ref","props","value"],"mappings":"4QAMA,MAAMA,EAAeC,EAAO,SAAU,CACpC,WAAY,OACZ,gBAAiB,QACjB,gBAAiBC,EAAqBC,EAAM,OAAO,SAAS,MAAO,SAAS,EAC5E,iBAAkB,oBAClB,OAAQ,sBACR,aAAc,KACd,MAAO,YACP,QAAS,QACT,WAAY,QACZ,WAAY,IACZ,WAAY,IACZ,WAAY,oBACZ,MAAO,OACP,UAAW,CACT,OAAQ,SACV,EACA,UAAW,CACT,YAAa,WACb,QAAS,MACX,EACA,gBAAiB,CACf,QAAS,MACX,EACA,kCAAmC,CACjC,gBAAiB,YACjB,MAAO,YACP,OAAQ,aACV,EACA,SAAU,CACR,KAAM,CACJ,GAAI,CACF,mBAAoB,8BACpB,eAAgB,kBAChB,SAAU,MACV,OAAQ,KACR,GAAI,KACJ,GAAI,IACN,EACA,GAAI,CACF,mBAAoB,8BACpB,eAAgB,kBAChB,SAAU,MACV,OAAQ,KACR,GAAI,KACJ,GAAI,IACN,CACF,EACA,MAAO,CACL,MAAO,CACL,OAAQ,mBACV,CACF,CACF,CACF,CAAC,EAgBYC,EAAgCC,EAAM,WACjD,CAAC,CAAE,YAAAC,EAAa,SAAAC,EAAU,KAAAC,EAAO,QAASC,CAAe,EAAGC,IAAQ,CAClE,MAAMC,EAAQ,CAAE,KAAAH,EAAM,IAAAE,EAAK,GAAGD,CAAe,EAE7C,MACE,CAACA,EAAe,MAAOA,EAAe,YAAY,EAAE,MACjDG,GAAUA,IAAU,MACvB,IAEAD,EAAM,aAAe,IAIrBN,EAAA,cAACL,EAAA,CAAc,GAAGW,CACfL,EAAAA,GACCD,EAAA,cAAC,SAAA,CAAO,SAAQ,GAAC,OAAM,GAAC,MAAM,EAAA,EAC3BC,CACH,EAEDC,CACH,CAEJ,CACF,EAEAH,EAAO,YAAc"}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{Content as
|
|
1
|
+
import{Content as i,Portal as a}from"@radix-ui/react-dialog";import t from"react";import{MAX_Z_INDEX as r}from"../../constants/zIndices.js";import{styled as n}from"../../stitches.js";import"../../utilities/css-wrapper/CSSWrapper.js";import"color2k";import{slideInLeft as m,slideOutLeft as d}from"../../utilities/style/keyframe-animations.js";import{SidedrawerOverlay as l}from"./SidedrawerOverlay.js";const s=n(i,{bg:"white",boxShadow:"$2",display:"flex",flexDirection:"column",position:"fixed",top:0,left:0,height:"100%",maxWidth:"304px",width:"100%",zIndex:r,"@allowMotion":{'&[data-state="open"]':{animation:`${m} 250ms ease-out`},'&[data-state="closed"]':{animation:`${d} 250ms ease-out`}}}),p=({children:e,...o})=>t.createElement(a,null,t.createElement(l,{"data-testid":"sidedrawer_overlay"}),t.createElement(s,{role:"navigation",...o},e));export{p as SidedrawerContent};
|
|
2
2
|
//# sourceMappingURL=SidedrawerContent.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"SidedrawerContent.js","sources":["../../../src/components/sidedrawer/SidedrawerContent.tsx"],"sourcesContent":["import { Content, Portal } from '@radix-ui/react-dialog'\nimport React from 'react'\n\nimport { MAX_Z_INDEX } from '~/constants/zIndices'\nimport { styled } from '~/stitches'\nimport { slideInLeft, slideOutLeft } from '~/utilities'\n\nimport { SidedrawerOverlay } from './SidedrawerOverlay'\n\nconst StyledContent = styled(Content, {\n bg: 'white',\n boxShadow: '$2',\n display: 'flex',\n flexDirection: 'column',\n position: 'fixed',\n top: 0,\n left: 0,\n height: '100%',\n maxWidth: '304px',\n width: '100%',\n zIndex: MAX_Z_INDEX,\n '@allowMotion': {\n '&[data-state=\"open\"]': {\n animation: `${slideInLeft} 250ms ease-out`\n },\n '&[data-state=\"closed\"]': {\n animation: `${slideOutLeft} 250ms ease-out`\n }\n }\n})\n\nexport const SidedrawerContent: React.FC<\n React.ComponentProps<typeof StyledContent>\n> = ({ children, ...remainingProps }) => (\n <Portal>\n <SidedrawerOverlay data-testid=\"sidedrawer_overlay\" />\n <StyledContent role=\"navigation\" {...remainingProps}>\n {children}\n </StyledContent>\n </Portal>\n)\n"],"names":["StyledContent","styled","Content","MAX_Z_INDEX","slideInLeft","slideOutLeft","SidedrawerContent","children","remainingProps","React","Portal","SidedrawerOverlay"],"mappings":"
|
|
1
|
+
{"version":3,"file":"SidedrawerContent.js","sources":["../../../src/components/sidedrawer/SidedrawerContent.tsx"],"sourcesContent":["import { Content, Portal } from '@radix-ui/react-dialog'\nimport React from 'react'\n\nimport { MAX_Z_INDEX } from '~/constants/zIndices'\nimport { styled } from '~/stitches'\nimport { slideInLeft, slideOutLeft } from '~/utilities'\n\nimport { SidedrawerOverlay } from './SidedrawerOverlay'\n\nconst StyledContent = styled(Content, {\n bg: 'white',\n boxShadow: '$2',\n display: 'flex',\n flexDirection: 'column',\n position: 'fixed',\n top: 0,\n left: 0,\n height: '100%',\n maxWidth: '304px',\n width: '100%',\n zIndex: MAX_Z_INDEX,\n '@allowMotion': {\n '&[data-state=\"open\"]': {\n animation: `${slideInLeft} 250ms ease-out`\n },\n '&[data-state=\"closed\"]': {\n animation: `${slideOutLeft} 250ms ease-out`\n }\n }\n})\n\nexport const SidedrawerContent: React.FC<\n React.ComponentProps<typeof StyledContent>\n> = ({ children, ...remainingProps }) => (\n <Portal>\n <SidedrawerOverlay data-testid=\"sidedrawer_overlay\" />\n <StyledContent role=\"navigation\" {...remainingProps}>\n {children}\n </StyledContent>\n </Portal>\n)\n"],"names":["StyledContent","styled","Content","MAX_Z_INDEX","slideInLeft","slideOutLeft","SidedrawerContent","children","remainingProps","React","Portal","SidedrawerOverlay"],"mappings":"iZASA,MAAMA,EAAgBC,EAAOC,EAAS,CACpC,GAAI,QACJ,UAAW,KACX,QAAS,OACT,cAAe,SACf,SAAU,QACV,IAAK,EACL,KAAM,EACN,OAAQ,OACR,SAAU,QACV,MAAO,OACP,OAAQC,EACR,eAAgB,CACd,uBAAwB,CACtB,UAAW,GAAGC,kBAChB,EACA,yBAA0B,CACxB,UAAW,GAAGC,kBAChB,CACF,CACF,CAAC,EAEYC,EAET,CAAC,CAAE,SAAAC,KAAaC,CAAe,IACjCC,EAAA,cAACC,EAAA,KACCD,EAAA,cAACE,EAAA,CAAkB,cAAY,qBAAqB,EACpDF,EAAA,cAACT,EAAA,CAAc,KAAK,aAAc,GAAGQ,CAClCD,EAAAA,CACH,CACF"}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{Overlay as o}from"@radix-ui/react-dialog";import{MAX_Z_INDEX as t}from"../../constants/zIndices.js";import{styled as a}from"../../stitches.js";import{fadeIn as e,fadeOut as i}from"../../utilities/style/keyframe-animations.js";const r=a(o,{animationFillMode:"forwards",bg:"$alpha600",cursor:"pointer",height:"100vh",left:"0",position:"fixed",top:"0",width:"100vw",zIndex:t-1,"@allowMotion":{'&[data-state="open"]':{animation:`${e} 250ms ease-out`},'&[data-state="closed"]':{animation:`${i} 550ms ease-out`}}});export{r as SidedrawerOverlay};
|
|
1
|
+
import{Overlay as o}from"@radix-ui/react-dialog";import{MAX_Z_INDEX as t}from"../../constants/zIndices.js";import{styled as a}from"../../stitches.js";import"../../utilities/css-wrapper/CSSWrapper.js";import"color2k";import{fadeIn as e,fadeOut as i}from"../../utilities/style/keyframe-animations.js";const r=a(o,{animationFillMode:"forwards",bg:"$alpha600",cursor:"pointer",height:"100vh",left:"0",position:"fixed",top:"0",width:"100vw",zIndex:t-1,"@allowMotion":{'&[data-state="open"]':{animation:`${e} 250ms ease-out`},'&[data-state="closed"]':{animation:`${i} 550ms ease-out`}}});export{r as SidedrawerOverlay};
|
|
2
2
|
//# sourceMappingURL=SidedrawerOverlay.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"SidedrawerOverlay.js","sources":["../../../src/components/sidedrawer/SidedrawerOverlay.tsx"],"sourcesContent":["import { Overlay } from '@radix-ui/react-dialog'\n\nimport { MAX_Z_INDEX } from '~/constants/zIndices'\nimport { styled } from '~/stitches'\nimport { fadeIn, fadeOut } from '~/utilities'\n\nexport const SidedrawerOverlay = styled(Overlay, {\n animationFillMode: 'forwards',\n bg: '$alpha600',\n cursor: 'pointer',\n height: '100vh',\n left: '0',\n position: 'fixed',\n top: '0',\n width: '100vw',\n zIndex: MAX_Z_INDEX - 1,\n '@allowMotion': {\n '&[data-state=\"open\"]': {\n animation: `${fadeIn} 250ms ease-out`\n },\n '&[data-state=\"closed\"]': {\n animation: `${fadeOut} 550ms ease-out`\n }\n }\n})\n"],"names":["SidedrawerOverlay","styled","Overlay","MAX_Z_INDEX","fadeIn","fadeOut"],"mappings":"
|
|
1
|
+
{"version":3,"file":"SidedrawerOverlay.js","sources":["../../../src/components/sidedrawer/SidedrawerOverlay.tsx"],"sourcesContent":["import { Overlay } from '@radix-ui/react-dialog'\n\nimport { MAX_Z_INDEX } from '~/constants/zIndices'\nimport { styled } from '~/stitches'\nimport { fadeIn, fadeOut } from '~/utilities'\n\nexport const SidedrawerOverlay = styled(Overlay, {\n animationFillMode: 'forwards',\n bg: '$alpha600',\n cursor: 'pointer',\n height: '100vh',\n left: '0',\n position: 'fixed',\n top: '0',\n width: '100vw',\n zIndex: MAX_Z_INDEX - 1,\n '@allowMotion': {\n '&[data-state=\"open\"]': {\n animation: `${fadeIn} 250ms ease-out`\n },\n '&[data-state=\"closed\"]': {\n animation: `${fadeOut} 550ms ease-out`\n }\n }\n})\n"],"names":["SidedrawerOverlay","styled","Overlay","MAX_Z_INDEX","fadeIn","fadeOut"],"mappings":"2SAMO,MAAMA,EAAoBC,EAAOC,EAAS,CAC/C,kBAAmB,WACnB,GAAI,YACJ,OAAQ,UACR,OAAQ,QACR,KAAM,IACN,SAAU,QACV,IAAK,IACL,MAAO,QACP,OAAQC,EAAc,EACtB,eAAgB,CACd,uBAAwB,CACtB,UAAW,GAAGC,kBAChB,EACA,yBAA0B,CACxB,UAAW,GAAGC,kBAChB,CACF,CACF,CAAC"}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{Track as f,Root as h,Range as b,Thumb as g}from"@radix-ui/react-slider";import*as e from"react";import{styled as t}from"../../stitches.js";import{
|
|
1
|
+
import{Track as f,Root as h,Range as b,Thumb as g}from"@radix-ui/react-slider";import*as e from"react";import{styled as t}from"../../stitches.js";import{CSSWrapper as v}from"../../utilities/css-wrapper/CSSWrapper.js";import"color2k";import"../../utilities/style/keyframe-animations.js";import{SliderSteps as x}from"./SliderSteps.js";import{SliderValue as y}from"./SliderValue.js";const a=t(f,{borderRadius:"$round",flexGrow:1,position:"relative",'&[data-orientation="horizontal"]':{height:"$space$1"},'&[data-orientation="vertical"]':{width:"$space$1"}}),S=t(h,{alignItems:"center",display:"flex",position:"relative",touchAction:"none",userSelect:"none",cursor:"pointer",'&[data-orientation="horizontal"]':{height:"$1"},'&[data-orientation="vertical"]':{flexDirection:"column",width:"$1"},"&[data-disabled]":{cursor:"not-allowed",bg:"$tonal100"},variants:{theme:{light:{[`${a}`]:{bg:"#fff"}},tonal:{[`${a}`]:{bg:"$tonal200"}}}}}),w=t(b,{bg:"$primary",borderRadius:"$round",height:"100%",position:"absolute","&[data-disabled]":{bg:"$tonal200",cursor:"not-allowed"}}),R=t(g,{bg:"$primaryMid",borderRadius:"$round",display:"block",size:"$1","&:hover":{bg:"$primaryDark"},"&:focus":{outline:"2px solid $primaryMid",outlineOffset:"2px"},"&[data-disabled]":{bg:"$tonal200",cursor:"not-allowed"}}),o=e.forwardRef(({value:i,defaultValue:l,min:n=0,max:d=100,theme:s="tonal",css:m,children:u,...p},c)=>{const r=i||l;return e.createElement(v,{css:m},e.createElement(S,{theme:s,defaultValue:l,value:i,min:n,max:d,ref:c,...p},e.createElement(a,null,e.createElement(w,null)),(r==null?void 0:r.length)&&r.map((k,$)=>e.createElement(R,{key:`thumb${$}`}))),u)});o.Value=y,o.Steps=x,o.displayName="Slider";export{o as Slider};
|
|
2
2
|
//# sourceMappingURL=Slider.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Slider.js","sources":["../../../src/components/slider/Slider.tsx"],"sourcesContent":["import { Range, Root, Thumb, Track } from '@radix-ui/react-slider'\nimport * as React from 'react'\n\nimport { styled } from '~/stitches'\nimport { CSSWrapper } from '~/utilities'\n\nimport { SliderSteps } from './SliderSteps'\nimport { SliderValue } from './SliderValue'\n\nconst StyledTrack = styled(Track, {\n borderRadius: '$round',\n flexGrow: 1,\n position: 'relative',\n '&[data-orientation=\"horizontal\"]': { height: '$space$1' },\n '&[data-orientation=\"vertical\"]': { width: '$space$1' }\n})\n\nconst StyledSlider = styled(Root, {\n alignItems: 'center',\n display: 'flex',\n position: 'relative',\n touchAction: 'none',\n userSelect: 'none',\n cursor: 'pointer',\n '&[data-orientation=\"horizontal\"]': {\n height: '$1'\n },\n '&[data-orientation=\"vertical\"]': {\n flexDirection: 'column',\n width: '$1'\n },\n '&[data-disabled]': { cursor: 'not-allowed', bg: '$tonal100' },\n variants: {\n theme: {\n light: {\n [`${StyledTrack}`]: { bg: '#fff' }\n },\n tonal: {\n [`${StyledTrack}`]: { bg: '$tonal200' }\n }\n }\n }\n})\n\nconst StyledRange = styled(Range, {\n bg: '$primary',\n borderRadius: '$round',\n height: '100%',\n position: 'absolute',\n '&[data-disabled]': { bg: '$tonal200', cursor: 'not-allowed' }\n})\n\nconst StyledThumb = styled(Thumb, {\n bg: '$primaryMid',\n borderRadius: '$round',\n display: 'block',\n size: '$1',\n '&:hover': {\n bg: '$primaryDark'\n },\n '&:focus': {\n outline: '2px solid $primaryMid',\n outlineOffset: '2px'\n },\n '&[data-disabled]': { bg: '$tonal200', cursor: 'not-allowed' }\n})\n\nexport type SliderProps = React.ComponentProps<typeof StyledSlider>\n\ntype SliderType = React.ForwardRefExoticComponent<SliderProps> & {\n Value: typeof SliderValue\n Steps: typeof SliderSteps\n}\n\nexport const Slider: SliderType = React.forwardRef(\n (\n {\n value,\n defaultValue,\n min = 0,\n max = 100,\n theme = 'tonal',\n css,\n children,\n ...remainingProps\n },\n ref\n ) => {\n const values = value || defaultValue\n return (\n <CSSWrapper css={css}>\n <StyledSlider\n theme={theme}\n defaultValue={defaultValue}\n value={value}\n min={min}\n max={max}\n ref={ref}\n {...remainingProps}\n >\n <StyledTrack>\n <StyledRange />\n </StyledTrack>\n {values?.length &&\n values.map((_, i) => <StyledThumb key={`thumb${i}`} />)}\n </StyledSlider>\n {children}\n </CSSWrapper>\n )\n }\n) as SliderType\n\nSlider.Value = SliderValue\nSlider.Steps = SliderSteps\n\nSlider.displayName = 'Slider'\n"],"names":["StyledTrack","styled","Track","StyledSlider","Root","StyledRange","Range","StyledThumb","Thumb","Slider","React","value","defaultValue","min","max","theme","css","children","remainingProps","ref","values","CSSWrapper","_","i","SliderValue","SliderSteps"],"mappings":"
|
|
1
|
+
{"version":3,"file":"Slider.js","sources":["../../../src/components/slider/Slider.tsx"],"sourcesContent":["import { Range, Root, Thumb, Track } from '@radix-ui/react-slider'\nimport * as React from 'react'\n\nimport { styled } from '~/stitches'\nimport { CSSWrapper } from '~/utilities'\n\nimport { SliderSteps } from './SliderSteps'\nimport { SliderValue } from './SliderValue'\n\nconst StyledTrack = styled(Track, {\n borderRadius: '$round',\n flexGrow: 1,\n position: 'relative',\n '&[data-orientation=\"horizontal\"]': { height: '$space$1' },\n '&[data-orientation=\"vertical\"]': { width: '$space$1' }\n})\n\nconst StyledSlider = styled(Root, {\n alignItems: 'center',\n display: 'flex',\n position: 'relative',\n touchAction: 'none',\n userSelect: 'none',\n cursor: 'pointer',\n '&[data-orientation=\"horizontal\"]': {\n height: '$1'\n },\n '&[data-orientation=\"vertical\"]': {\n flexDirection: 'column',\n width: '$1'\n },\n '&[data-disabled]': { cursor: 'not-allowed', bg: '$tonal100' },\n variants: {\n theme: {\n light: {\n [`${StyledTrack}`]: { bg: '#fff' }\n },\n tonal: {\n [`${StyledTrack}`]: { bg: '$tonal200' }\n }\n }\n }\n})\n\nconst StyledRange = styled(Range, {\n bg: '$primary',\n borderRadius: '$round',\n height: '100%',\n position: 'absolute',\n '&[data-disabled]': { bg: '$tonal200', cursor: 'not-allowed' }\n})\n\nconst StyledThumb = styled(Thumb, {\n bg: '$primaryMid',\n borderRadius: '$round',\n display: 'block',\n size: '$1',\n '&:hover': {\n bg: '$primaryDark'\n },\n '&:focus': {\n outline: '2px solid $primaryMid',\n outlineOffset: '2px'\n },\n '&[data-disabled]': { bg: '$tonal200', cursor: 'not-allowed' }\n})\n\nexport type SliderProps = React.ComponentProps<typeof StyledSlider>\n\ntype SliderType = React.ForwardRefExoticComponent<SliderProps> & {\n Value: typeof SliderValue\n Steps: typeof SliderSteps\n}\n\nexport const Slider: SliderType = React.forwardRef(\n (\n {\n value,\n defaultValue,\n min = 0,\n max = 100,\n theme = 'tonal',\n css,\n children,\n ...remainingProps\n },\n ref\n ) => {\n const values = value || defaultValue\n return (\n <CSSWrapper css={css}>\n <StyledSlider\n theme={theme}\n defaultValue={defaultValue}\n value={value}\n min={min}\n max={max}\n ref={ref}\n {...remainingProps}\n >\n <StyledTrack>\n <StyledRange />\n </StyledTrack>\n {values?.length &&\n values.map((_, i) => <StyledThumb key={`thumb${i}`} />)}\n </StyledSlider>\n {children}\n </CSSWrapper>\n )\n }\n) as SliderType\n\nSlider.Value = SliderValue\nSlider.Steps = SliderSteps\n\nSlider.displayName = 'Slider'\n"],"names":["StyledTrack","styled","Track","StyledSlider","Root","StyledRange","Range","StyledThumb","Thumb","Slider","React","value","defaultValue","min","max","theme","css","children","remainingProps","ref","values","CSSWrapper","_","i","SliderValue","SliderSteps"],"mappings":"4XASA,MAAMA,EAAcC,EAAOC,EAAO,CAChC,aAAc,SACd,SAAU,EACV,SAAU,WACV,mCAAoC,CAAE,OAAQ,UAAW,EACzD,iCAAkC,CAAE,MAAO,UAAW,CACxD,CAAC,EAEKC,EAAeF,EAAOG,EAAM,CAChC,WAAY,SACZ,QAAS,OACT,SAAU,WACV,YAAa,OACb,WAAY,OACZ,OAAQ,UACR,mCAAoC,CAClC,OAAQ,IACV,EACA,iCAAkC,CAChC,cAAe,SACf,MAAO,IACT,EACA,mBAAoB,CAAE,OAAQ,cAAe,GAAI,WAAY,EAC7D,SAAU,CACR,MAAO,CACL,MAAO,CACL,CAAC,GAAGJ,KAAgB,CAAE,GAAI,MAAO,CACnC,EACA,MAAO,CACL,CAAC,GAAGA,KAAgB,CAAE,GAAI,WAAY,CACxC,CACF,CACF,CACF,CAAC,EAEKK,EAAcJ,EAAOK,EAAO,CAChC,GAAI,WACJ,aAAc,SACd,OAAQ,OACR,SAAU,WACV,mBAAoB,CAAE,GAAI,YAAa,OAAQ,aAAc,CAC/D,CAAC,EAEKC,EAAcN,EAAOO,EAAO,CAChC,GAAI,cACJ,aAAc,SACd,QAAS,QACT,KAAM,KACN,UAAW,CACT,GAAI,cACN,EACA,UAAW,CACT,QAAS,wBACT,cAAe,KACjB,EACA,mBAAoB,CAAE,GAAI,YAAa,OAAQ,aAAc,CAC/D,CAAC,EASYC,EAAqBC,EAAM,WACtC,CACE,CACE,MAAAC,EACA,aAAAC,EACA,IAAAC,EAAM,EACN,IAAAC,EAAM,IACN,MAAAC,EAAQ,QACR,IAAAC,EACA,SAAAC,KACGC,CACL,EACAC,IACG,CACH,MAAMC,EAAST,GAASC,EACxB,OACEF,EAAA,cAACW,EAAA,CAAW,IAAKL,CACfN,EAAAA,EAAA,cAACP,EAAA,CACC,MAAOY,EACP,aAAcH,EACd,MAAOD,EACP,IAAKE,EACL,IAAKC,EACL,IAAKK,EACJ,GAAGD,CAEJR,EAAAA,EAAA,cAACV,EAAA,KACCU,EAAA,cAACL,EAAA,IAAY,CACf,GACCe,GAAA,KAAA,OAAAA,EAAQ,SACPA,EAAO,IAAI,CAACE,EAAGC,IAAMb,EAAA,cAACH,EAAA,CAAY,IAAK,QAAQgB,GAAK,CAAA,CAAE,CAC1D,EACCN,CACH,CAEJ,CACF,EAEAR,EAAO,MAAQe,EACff,EAAO,MAAQgB,EAEfhB,EAAO,YAAc"}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import*as e from"react";import{styled as
|
|
1
|
+
import*as e from"react";import{styled as f}from"../../stitches.js";import{createThemeVariants as m}from"../../utilities/create-theme-variants/createThemeVariants.js";import{CSSWrapper as c}from"../../utilities/css-wrapper/CSSWrapper.js";import"color2k";import"../../utilities/style/keyframe-animations.js";const w=f("div",{display:"flex","& > *":{m:0},variants:{direction:{row:{flexDirection:"row"},"row-reverse":{flexDirection:"row-reverse"},column:{flexDirection:"column"}},wrap:{wrap:{flexWrap:"wrap"},"no-wrap":{flexWrap:"no-wrap"},"wrap-reverse":{flexWrap:"wrap-reverse"}},justify:{start:{justifyContent:"flex-start"},center:{justifyContent:"center"},end:{justifyContent:"flex-end"},false:{}},align:{start:{alignItems:"flex-start"},center:{alignItems:"center"},end:{alignItems:"flex-end"},false:{}},gap:{...m("space",{mt:"-$key",ml:"-$key","& > *":{mt:"$key",ml:"$key"}}),false:{}}}}),a=e.forwardRef(({css:n,gap:i=2,direction:r="row",wrap:o="wrap",justify:s="start",align:t,...l},p)=>e.createElement(c,{css:n},e.createElement(w,{ref:p,direction:r,gap:i,wrap:o,justify:s,align:typeof t>"u"&&r!=="column"?"center":t,...l})));a.displayName="Stack";export{a as Stack};
|
|
2
2
|
//# sourceMappingURL=Stack.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Stack.js","sources":["../../../src/components/stack/Stack.tsx"],"sourcesContent":["import * as React from 'react'\n\nimport { CSS, styled } from '~/stitches'\nimport { createThemeVariants } from '~/utilities'\nimport { CSSWrapper } from '~/utilities/css-wrapper'\n\nconst StyledStack = styled('div', {\n display: 'flex',\n '& > *': {\n m: 0\n },\n variants: {\n direction: {\n row: {\n flexDirection: 'row'\n },\n 'row-reverse': {\n flexDirection: 'row-reverse'\n },\n column: {\n flexDirection: 'column'\n }\n },\n wrap: {\n wrap: {\n flexWrap: 'wrap'\n },\n 'no-wrap': {\n flexWrap: 'no-wrap'\n },\n 'wrap-reverse': {\n flexWrap: 'wrap-reverse'\n }\n },\n justify: {\n start: { justifyContent: 'flex-start' },\n center: { justifyContent: 'center' },\n end: { justifyContent: 'flex-end' },\n false: {}\n },\n align: {\n start: { alignItems: 'flex-start' },\n center: { alignItems: 'center' },\n end: { alignItems: 'flex-end' },\n false: {}\n },\n gap: {\n ...createThemeVariants('space', {\n mt: '-$key',\n ml: '-$key',\n '& > *': {\n mt: '$key',\n ml: '$key'\n }\n }),\n false: {}\n }\n }\n})\n\ntype StackPropsType = React.ComponentProps<typeof StyledStack> & {\n css?: CSS\n as?: any\n} // (!) `css` and `as` are both props that come from `stitches`. It would be better to figure out and export the appropriate type for them in stitches!\n\nexport const Stack: React.ForwardRefExoticComponent<StackPropsType> =\n React.forwardRef(\n (\n {\n css,\n gap = 2,\n direction = 'row',\n wrap = 'wrap',\n justify = 'start',\n align,\n ...remainingProps\n },\n ref\n ) => {\n return (\n <CSSWrapper css={css}>\n <StyledStack\n ref={ref}\n direction={direction}\n gap={gap}\n wrap={wrap}\n justify={justify}\n align={\n typeof align === 'undefined' && direction !== 'column'\n ? 'center'\n : align\n }\n {...remainingProps}\n />\n </CSSWrapper>\n )\n }\n )\n\nStack.displayName = 'Stack'\n"],"names":["StyledStack","styled","createThemeVariants","Stack","React","css","gap","direction","wrap","justify","align","remainingProps","ref","CSSWrapper"],"mappings":"
|
|
1
|
+
{"version":3,"file":"Stack.js","sources":["../../../src/components/stack/Stack.tsx"],"sourcesContent":["import * as React from 'react'\n\nimport { CSS, styled } from '~/stitches'\nimport { createThemeVariants } from '~/utilities'\nimport { CSSWrapper } from '~/utilities/css-wrapper'\n\nconst StyledStack = styled('div', {\n display: 'flex',\n '& > *': {\n m: 0\n },\n variants: {\n direction: {\n row: {\n flexDirection: 'row'\n },\n 'row-reverse': {\n flexDirection: 'row-reverse'\n },\n column: {\n flexDirection: 'column'\n }\n },\n wrap: {\n wrap: {\n flexWrap: 'wrap'\n },\n 'no-wrap': {\n flexWrap: 'no-wrap'\n },\n 'wrap-reverse': {\n flexWrap: 'wrap-reverse'\n }\n },\n justify: {\n start: { justifyContent: 'flex-start' },\n center: { justifyContent: 'center' },\n end: { justifyContent: 'flex-end' },\n false: {}\n },\n align: {\n start: { alignItems: 'flex-start' },\n center: { alignItems: 'center' },\n end: { alignItems: 'flex-end' },\n false: {}\n },\n gap: {\n ...createThemeVariants('space', {\n mt: '-$key',\n ml: '-$key',\n '& > *': {\n mt: '$key',\n ml: '$key'\n }\n }),\n false: {}\n }\n }\n})\n\ntype StackPropsType = React.ComponentProps<typeof StyledStack> & {\n css?: CSS\n as?: any\n} // (!) `css` and `as` are both props that come from `stitches`. It would be better to figure out and export the appropriate type for them in stitches!\n\nexport const Stack: React.ForwardRefExoticComponent<StackPropsType> =\n React.forwardRef(\n (\n {\n css,\n gap = 2,\n direction = 'row',\n wrap = 'wrap',\n justify = 'start',\n align,\n ...remainingProps\n },\n ref\n ) => {\n return (\n <CSSWrapper css={css}>\n <StyledStack\n ref={ref}\n direction={direction}\n gap={gap}\n wrap={wrap}\n justify={justify}\n align={\n typeof align === 'undefined' && direction !== 'column'\n ? 'center'\n : align\n }\n {...remainingProps}\n />\n </CSSWrapper>\n )\n }\n )\n\nStack.displayName = 'Stack'\n"],"names":["StyledStack","styled","createThemeVariants","Stack","React","css","gap","direction","wrap","justify","align","remainingProps","ref","CSSWrapper"],"mappings":"kTAMA,MAAMA,EAAcC,EAAO,MAAO,CAChC,QAAS,OACT,QAAS,CACP,EAAG,CACL,EACA,SAAU,CACR,UAAW,CACT,IAAK,CACH,cAAe,KACjB,EACA,cAAe,CACb,cAAe,aACjB,EACA,OAAQ,CACN,cAAe,QACjB,CACF,EACA,KAAM,CACJ,KAAM,CACJ,SAAU,MACZ,EACA,UAAW,CACT,SAAU,SACZ,EACA,eAAgB,CACd,SAAU,cACZ,CACF,EACA,QAAS,CACP,MAAO,CAAE,eAAgB,YAAa,EACtC,OAAQ,CAAE,eAAgB,QAAS,EACnC,IAAK,CAAE,eAAgB,UAAW,EAClC,MAAO,CACT,CAAA,EACA,MAAO,CACL,MAAO,CAAE,WAAY,YAAa,EAClC,OAAQ,CAAE,WAAY,QAAS,EAC/B,IAAK,CAAE,WAAY,UAAW,EAC9B,MAAO,CACT,CAAA,EACA,IAAK,CACH,GAAGC,EAAoB,QAAS,CAC9B,GAAI,QACJ,GAAI,QACJ,QAAS,CACP,GAAI,OACJ,GAAI,MACN,CACF,CAAC,EACD,MAAO,EACT,CACF,CACF,CAAC,EAOYC,EACXC,EAAM,WACJ,CACE,CACE,IAAAC,EACA,IAAAC,EAAM,EACN,UAAAC,EAAY,MACZ,KAAAC,EAAO,OACP,QAAAC,EAAU,QACV,MAAAC,KACGC,CACL,EACAC,IAGER,EAAA,cAACS,EAAA,CAAW,IAAKR,GACfD,EAAA,cAACJ,EAAA,CACC,IAAKY,EACL,UAAWL,EACX,IAAKD,EACL,KAAME,EACN,QAASC,EACT,MACE,OAAOC,EAAU,KAAeH,IAAc,SAC1C,SACAG,EAEL,GAAGC,EACN,CACF,CAGN,EAEFR,EAAM,YAAc"}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{Trigger as c}from"@radix-ui/react-tabs";import*as e from"react";import{styled as t}from"../../stitches.js";import
|
|
1
|
+
import{Trigger as c}from"@radix-ui/react-tabs";import*as e from"react";import{styled as t}from"../../stitches.js";import"../../utilities/css-wrapper/CSSWrapper.js";import"color2k";import{focusVisibleStyleBlock as n}from"../../utilities/style/focus-visible-style-block.js";import"../../utilities/style/keyframe-animations.js";import{Text as l}from"../text/Text.js";const o=t("div",{position:"absolute",inset:0,height:"calc(100% + 2px)",opacity:0,bg:"$interactive1"}),s=t(c,{background:"none",border:"none",cursor:"pointer",flexShrink:0,p:"$4",userSelect:"none",borderBottom:"2px solid transparent",position:"relative",'&[data-state="active"]':{color:"$interactive1",fontWeight:600,letterSpacing:"-0.005em",borderColor:"currentColor"},"&[data-disabled]":{opacity:.3,cursor:"not-allowed"},"&:not([data-disabled])":{"&:hover, &:focus-visible":{color:"$interactive2",[`& ${o}`]:{opacity:.07}},"&:active":{color:"$interactive3"},"&:focus-visible":{...n()}}}),r=({children:i,...a})=>e.createElement(s,{...a},e.createElement(l,{size:"sm",as:"span"},i),e.createElement(o,null));r.displayName="TabsTrigger";export{r as TabsTrigger};
|
|
2
2
|
//# sourceMappingURL=TabsTrigger.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"TabsTrigger.js","sources":["../../../src/components/tabs/TabsTrigger.tsx"],"sourcesContent":["import { Trigger } from '@radix-ui/react-tabs'\nimport * as React from 'react'\n\nimport { styled } from '~/stitches'\nimport { focusVisibleStyleBlock } from '~/utilities'\n\nimport { Text } from '../text'\n\nconst StyledTabsTriggerHoverBackground = styled('div', {\n position: 'absolute',\n inset: 0,\n height: 'calc(100% + 2px)',\n opacity: 0,\n bg: '$interactive1'\n})\n\nconst StyledTabsTrigger = styled(Trigger, {\n background: 'none',\n border: 'none',\n cursor: 'pointer',\n flexShrink: 0,\n p: '$4',\n userSelect: 'none',\n borderBottom: '2px solid transparent',\n position: 'relative',\n '&[data-state=\"active\"]': {\n color: '$interactive1',\n fontWeight: 600,\n letterSpacing: '-0.005em',\n borderColor: 'currentColor'\n },\n '&[data-disabled]': {\n opacity: 0.3,\n cursor: 'not-allowed'\n },\n '&:not([data-disabled])': {\n '&:hover, &:focus-visible': {\n color: '$interactive2',\n [`& ${StyledTabsTriggerHoverBackground}`]: {\n opacity: 0.07\n }\n },\n '&:active': {\n color: '$interactive3'\n },\n '&:focus-visible': {\n ...focusVisibleStyleBlock()\n }\n }\n})\n\ninterface TabsTriggerProps\n extends React.ComponentProps<typeof StyledTabsTrigger> {\n value: string\n}\n\nexport const TabsTrigger: React.FC<TabsTriggerProps> = ({\n children,\n ...rest\n}) => (\n <StyledTabsTrigger {...rest}>\n <Text size=\"sm\" as=\"span\">\n {children}\n </Text>\n <StyledTabsTriggerHoverBackground />\n </StyledTabsTrigger>\n)\n\nTabsTrigger.displayName = 'TabsTrigger'\n"],"names":["StyledTabsTriggerHoverBackground","styled","StyledTabsTrigger","Trigger","focusVisibleStyleBlock","TabsTrigger","children","rest","React","Text"],"mappings":"
|
|
1
|
+
{"version":3,"file":"TabsTrigger.js","sources":["../../../src/components/tabs/TabsTrigger.tsx"],"sourcesContent":["import { Trigger } from '@radix-ui/react-tabs'\nimport * as React from 'react'\n\nimport { styled } from '~/stitches'\nimport { focusVisibleStyleBlock } from '~/utilities'\n\nimport { Text } from '../text'\n\nconst StyledTabsTriggerHoverBackground = styled('div', {\n position: 'absolute',\n inset: 0,\n height: 'calc(100% + 2px)',\n opacity: 0,\n bg: '$interactive1'\n})\n\nconst StyledTabsTrigger = styled(Trigger, {\n background: 'none',\n border: 'none',\n cursor: 'pointer',\n flexShrink: 0,\n p: '$4',\n userSelect: 'none',\n borderBottom: '2px solid transparent',\n position: 'relative',\n '&[data-state=\"active\"]': {\n color: '$interactive1',\n fontWeight: 600,\n letterSpacing: '-0.005em',\n borderColor: 'currentColor'\n },\n '&[data-disabled]': {\n opacity: 0.3,\n cursor: 'not-allowed'\n },\n '&:not([data-disabled])': {\n '&:hover, &:focus-visible': {\n color: '$interactive2',\n [`& ${StyledTabsTriggerHoverBackground}`]: {\n opacity: 0.07\n }\n },\n '&:active': {\n color: '$interactive3'\n },\n '&:focus-visible': {\n ...focusVisibleStyleBlock()\n }\n }\n})\n\ninterface TabsTriggerProps\n extends React.ComponentProps<typeof StyledTabsTrigger> {\n value: string\n}\n\nexport const TabsTrigger: React.FC<TabsTriggerProps> = ({\n children,\n ...rest\n}) => (\n <StyledTabsTrigger {...rest}>\n <Text size=\"sm\" as=\"span\">\n {children}\n </Text>\n <StyledTabsTriggerHoverBackground />\n </StyledTabsTrigger>\n)\n\nTabsTrigger.displayName = 'TabsTrigger'\n"],"names":["StyledTabsTriggerHoverBackground","styled","StyledTabsTrigger","Trigger","focusVisibleStyleBlock","TabsTrigger","children","rest","React","Text"],"mappings":"4WAQA,MAAMA,EAAmCC,EAAO,MAAO,CACrD,SAAU,WACV,MAAO,EACP,OAAQ,mBACR,QAAS,EACT,GAAI,eACN,CAAC,EAEKC,EAAoBD,EAAOE,EAAS,CACxC,WAAY,OACZ,OAAQ,OACR,OAAQ,UACR,WAAY,EACZ,EAAG,KACH,WAAY,OACZ,aAAc,wBACd,SAAU,WACV,yBAA0B,CACxB,MAAO,gBACP,WAAY,IACZ,cAAe,WACf,YAAa,cACf,EACA,mBAAoB,CAClB,QAAS,GACT,OAAQ,aACV,EACA,yBAA0B,CACxB,2BAA4B,CAC1B,MAAO,gBACP,CAAC,KAAKH,KAAqC,CACzC,QAAS,GACX,CACF,EACA,WAAY,CACV,MAAO,eACT,EACA,kBAAmB,CACjB,GAAGI,GACL,CACF,CACF,CAAC,EAOYC,EAA0C,CAAC,CACtD,SAAAC,KACGC,CACL,IACEC,EAAA,cAACN,EAAA,CAAmB,GAAGK,GACrBC,EAAA,cAACC,EAAA,CAAK,KAAK,KAAK,GAAG,MAAA,EAChBH,CACH,EACAE,EAAA,cAACR,EAAA,IAAiC,CACpC,EAGFK,EAAY,YAAc"}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import*as
|
|
1
|
+
import*as n from"react";import{styled as m}from"../../stitches.js";import"../../utilities/css-wrapper/CSSWrapper.js";import{capsize as e}from"../../utilities/style/capsize.js";import"color2k";import"../../utilities/style/keyframe-animations.js";const t={size:{xs:{fontSize:"$xs",lineHeight:1.6,...e(.4364)},sm:{fontSize:"$sm",lineHeight:1.53,...e(.4056)},md:{fontSize:"$md",lineHeight:1.5,...e(.3864)},lg:{fontSize:"$lg",lineHeight:1.52,...e(.3983)},xl:{fontSize:"$xl",lineHeight:1.42,...e(.3506)}},noCapsize:{true:{"&::before, &::after":{display:"none !important"}}}},f=({size:i,noCapsize:o})=>({...t.size[i],...t.noCapsize[`${o}`]}),r=m("p",{fontFamily:"$body",fontWeight:400,margin:0,"& > &":{"&:before, &:after":{display:"none"}},variants:t}),a=n.forwardRef(({size:i="md",...o},s)=>n.createElement(r,{size:i,...o,ref:s}));a.displayName="Text";export{r as StyledText,a as Text,f as getTextVariant,t as textVariants};
|
|
2
2
|
//# sourceMappingURL=Text.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Text.js","sources":["../../../src/components/text/Text.tsx"],"sourcesContent":["import * as React from 'react'\n\nimport { CSS, styled } from '~/stitches'\nimport type { Override } from '~/utilities'\nimport { capsize } from '~/utilities'\n\nexport const textVariants = {\n size: {\n xs: { fontSize: '$xs', lineHeight: 1.6, ...capsize(0.4364) },\n sm: { fontSize: '$sm', lineHeight: 1.53, ...capsize(0.4056) },\n md: { fontSize: '$md', lineHeight: 1.5, ...capsize(0.3864) },\n lg: { fontSize: '$lg', lineHeight: 1.52, ...capsize(0.3983) },\n xl: { fontSize: '$xl', lineHeight: 1.42, ...capsize(0.3506) }\n },\n noCapsize: {\n true: {\n '&::before, &::after': { display: 'none !important' }\n }\n }\n}\n\nexport const getTextVariant: (options: {\n size: keyof typeof textVariants.size\n noCapsize?: boolean\n}) => CSS = ({ size, noCapsize }) => ({\n ...textVariants.size[size],\n ...textVariants.noCapsize[`${noCapsize}`]\n})\n\nexport const StyledText = styled('p', {\n fontFamily: '$body',\n fontWeight: 400,\n margin: 0,\n /** Allow nesting `<Text />` inside `<Text />` without forcing a new line and spacing. */\n '& > &': {\n '&:before, &:after': { display: 'none' }\n },\n variants: textVariants\n})\n\ntype TextProps = Override<\n React.ComponentProps<typeof StyledText>,\n {\n as?:\n | 'blockquote'\n | 'caption'\n | 'dd'\n | 'dt'\n | 'figcaption'\n | 'li'\n | 'p'\n | 'span'\n | 'legend'\n | React.ComponentType\n | React.ElementType\n }\n>\n\nexport const Text: React.ForwardRefExoticComponent<TextProps> =\n React.forwardRef(({ size = 'md', ...remainingProps }, ref) => (\n <StyledText size={size} {...remainingProps} ref={ref} />\n ))\n\nText.displayName = 'Text'\n"],"names":["textVariants","capsize","getTextVariant","size","noCapsize","StyledText","styled","Text","React","remainingProps","ref"],"mappings":"
|
|
1
|
+
{"version":3,"file":"Text.js","sources":["../../../src/components/text/Text.tsx"],"sourcesContent":["import * as React from 'react'\n\nimport { CSS, styled } from '~/stitches'\nimport type { Override } from '~/utilities'\nimport { capsize } from '~/utilities'\n\nexport const textVariants = {\n size: {\n xs: { fontSize: '$xs', lineHeight: 1.6, ...capsize(0.4364) },\n sm: { fontSize: '$sm', lineHeight: 1.53, ...capsize(0.4056) },\n md: { fontSize: '$md', lineHeight: 1.5, ...capsize(0.3864) },\n lg: { fontSize: '$lg', lineHeight: 1.52, ...capsize(0.3983) },\n xl: { fontSize: '$xl', lineHeight: 1.42, ...capsize(0.3506) }\n },\n noCapsize: {\n true: {\n '&::before, &::after': { display: 'none !important' }\n }\n }\n}\n\nexport const getTextVariant: (options: {\n size: keyof typeof textVariants.size\n noCapsize?: boolean\n}) => CSS = ({ size, noCapsize }) => ({\n ...textVariants.size[size],\n ...textVariants.noCapsize[`${noCapsize}`]\n})\n\nexport const StyledText = styled('p', {\n fontFamily: '$body',\n fontWeight: 400,\n margin: 0,\n /** Allow nesting `<Text />` inside `<Text />` without forcing a new line and spacing. */\n '& > &': {\n '&:before, &:after': { display: 'none' }\n },\n variants: textVariants\n})\n\ntype TextProps = Override<\n React.ComponentProps<typeof StyledText>,\n {\n as?:\n | 'blockquote'\n | 'caption'\n | 'dd'\n | 'dt'\n | 'figcaption'\n | 'li'\n | 'p'\n | 'span'\n | 'legend'\n | React.ComponentType\n | React.ElementType\n }\n>\n\nexport const Text: React.ForwardRefExoticComponent<TextProps> =\n React.forwardRef(({ size = 'md', ...remainingProps }, ref) => (\n <StyledText size={size} {...remainingProps} ref={ref} />\n ))\n\nText.displayName = 'Text'\n"],"names":["textVariants","capsize","getTextVariant","size","noCapsize","StyledText","styled","Text","React","remainingProps","ref"],"mappings":"qPAMO,MAAMA,EAAe,CAC1B,KAAM,CACJ,GAAI,CAAE,SAAU,MAAO,WAAY,IAAK,GAAGC,EAAQ,KAAM,CAAE,EAC3D,GAAI,CAAE,SAAU,MAAO,WAAY,KAAM,GAAGA,EAAQ,KAAM,CAAE,EAC5D,GAAI,CAAE,SAAU,MAAO,WAAY,IAAK,GAAGA,EAAQ,KAAM,CAAE,EAC3D,GAAI,CAAE,SAAU,MAAO,WAAY,KAAM,GAAGA,EAAQ,KAAM,CAAE,EAC5D,GAAI,CAAE,SAAU,MAAO,WAAY,KAAM,GAAGA,EAAQ,KAAM,CAAE,CAC9D,EACA,UAAW,CACT,KAAM,CACJ,sBAAuB,CAAE,QAAS,iBAAkB,CACtD,CACF,CACF,EAEaC,EAGD,CAAC,CAAE,KAAAC,EAAM,UAAAC,CAAU,KAAO,CACpC,GAAGJ,EAAa,KAAKG,GACrB,GAAGH,EAAa,UAAU,GAAGI,IAC/B,GAEaC,EAAaC,EAAO,IAAK,CACpC,WAAY,QACZ,WAAY,IACZ,OAAQ,EAER,QAAS,CACP,oBAAqB,CAAE,QAAS,MAAO,CACzC,EACA,SAAUN,CACZ,CAAC,EAoBYO,EACXC,EAAM,WAAW,CAAC,CAAE,KAAAL,EAAO,QAASM,CAAe,EAAGC,IACpDF,EAAA,cAACH,EAAW,CAAA,KAAMF,EAAO,GAAGM,EAAgB,IAAKC,CAAAA,CAAK,CACvD,EAEHH,EAAK,YAAc"}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import o from"react";import{Tile as n}from"../tile/index.js";import{styled as l}from"../../stitches.js";import{focusVisibleStyleBlock as c}from"../../utilities/style/focus-visible-style-block.js";const
|
|
1
|
+
import o from"react";import{Tile as n}from"../tile/index.js";import{styled as l}from"../../stitches.js";import"../../utilities/css-wrapper/CSSWrapper.js";import"color2k";import{focusVisibleStyleBlock as c}from"../../utilities/style/focus-visible-style-block.js";import"../../utilities/style/keyframe-animations.js";const m=l(n,{"&[data-disabled]":{opacity:.3,cursor:"not-allowed"},"&:not([data-disabled])":{cursor:"pointer",transform:"translateY(0)",transition:"transform 250ms ease","&::after":{content:"",position:"absolute",inset:0,boxShadow:"$2",opacity:0,transition:"opacity 250ms ease-out",borderRadius:"inherit"},"&:hover":{transform:"translateY(-$space$0)","&::after":{opacity:1}},"&:active":{bg:"$base2"},"&:focus-visible":{...c()}}}),e=o.forwardRef(({onClick:r,href:t,type:a="button",...i},s)=>o.createElement(m,{...i,...t?{asWorkaround:"a",href:t,onClick:void 0}:{asWorkaround:"button",type:a,onClick:r},ref:s}));e.displayName="TileInteractive";export{e as TileInteractive};
|
|
2
2
|
//# sourceMappingURL=TileInteractive.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"TileInteractive.js","sources":["../../../src/components/tile-interactive/TileInteractive.tsx"],"sourcesContent":["import React from 'react'\n\nimport { Tile } from '~/components/tile'\nimport { styled } from '~/stitches'\nimport { NavigatorActions } from '~/types'\nimport { focusVisibleStyleBlock } from '~/utilities'\n\nconst StyledTileInteractive = styled(Tile, {\n '&[data-disabled]': {\n opacity: 0.3,\n cursor: 'not-allowed'\n },\n '&:not([data-disabled])': {\n cursor: 'pointer',\n transform: 'translateY(0)',\n transition: 'transform 250ms ease',\n '&::after': {\n content: '',\n position: 'absolute',\n inset: 0,\n boxShadow: '$2',\n opacity: 0,\n transition: 'opacity 250ms ease-out',\n borderRadius: 'inherit'\n },\n '&:hover': {\n transform: 'translateY(-$space$0)',\n '&::after': {\n opacity: 1\n }\n },\n '&:active': {\n bg: '$base2'\n },\n '&:focus-visible': {\n ...focusVisibleStyleBlock()\n }\n }\n})\n\ntype TTileInteractiveProps = React.ComponentProps<\n typeof StyledTileInteractive\n> & { type?: string } & NavigatorActions\n\nexport const TileInteractive = React.forwardRef<\n HTMLButtonElement,\n TTileInteractiveProps\n>(({ onClick, href, type = 'button', ...rest }, ref) => {\n const isLink = !!href\n const elementSpecificProps = isLink\n ? {\n asWorkaround: 'a' as React.ElementType,\n href,\n onClick: undefined\n }\n : { asWorkaround: 'button' as React.ElementType, type, onClick }\n\n return <StyledTileInteractive {...rest} {...elementSpecificProps} ref={ref} />\n})\n\nTileInteractive.displayName = 'TileInteractive'\n"],"names":["StyledTileInteractive","styled","Tile","focusVisibleStyleBlock","TileInteractive","React","onClick","href","type","rest","ref"],"mappings":"
|
|
1
|
+
{"version":3,"file":"TileInteractive.js","sources":["../../../src/components/tile-interactive/TileInteractive.tsx"],"sourcesContent":["import React from 'react'\n\nimport { Tile } from '~/components/tile'\nimport { styled } from '~/stitches'\nimport { NavigatorActions } from '~/types'\nimport { focusVisibleStyleBlock } from '~/utilities'\n\nconst StyledTileInteractive = styled(Tile, {\n '&[data-disabled]': {\n opacity: 0.3,\n cursor: 'not-allowed'\n },\n '&:not([data-disabled])': {\n cursor: 'pointer',\n transform: 'translateY(0)',\n transition: 'transform 250ms ease',\n '&::after': {\n content: '',\n position: 'absolute',\n inset: 0,\n boxShadow: '$2',\n opacity: 0,\n transition: 'opacity 250ms ease-out',\n borderRadius: 'inherit'\n },\n '&:hover': {\n transform: 'translateY(-$space$0)',\n '&::after': {\n opacity: 1\n }\n },\n '&:active': {\n bg: '$base2'\n },\n '&:focus-visible': {\n ...focusVisibleStyleBlock()\n }\n }\n})\n\ntype TTileInteractiveProps = React.ComponentProps<\n typeof StyledTileInteractive\n> & { type?: string } & NavigatorActions\n\nexport const TileInteractive = React.forwardRef<\n HTMLButtonElement,\n TTileInteractiveProps\n>(({ onClick, href, type = 'button', ...rest }, ref) => {\n const isLink = !!href\n const elementSpecificProps = isLink\n ? {\n asWorkaround: 'a' as React.ElementType,\n href,\n onClick: undefined\n }\n : { asWorkaround: 'button' as React.ElementType, type, onClick }\n\n return <StyledTileInteractive {...rest} {...elementSpecificProps} ref={ref} />\n})\n\nTileInteractive.displayName = 'TileInteractive'\n"],"names":["StyledTileInteractive","styled","Tile","focusVisibleStyleBlock","TileInteractive","React","onClick","href","type","rest","ref"],"mappings":"2TAOA,MAAMA,EAAwBC,EAAOC,EAAM,CACzC,mBAAoB,CAClB,QAAS,GACT,OAAQ,aACV,EACA,yBAA0B,CACxB,OAAQ,UACR,UAAW,gBACX,WAAY,uBACZ,WAAY,CACV,QAAS,GACT,SAAU,WACV,MAAO,EACP,UAAW,KACX,QAAS,EACT,WAAY,yBACZ,aAAc,SAChB,EACA,UAAW,CACT,UAAW,wBACX,WAAY,CACV,QAAS,CACX,CACF,EACA,WAAY,CACV,GAAI,QACN,EACA,kBAAmB,CACjB,GAAGC,EACL,CAAA,CACF,CACF,CAAC,EAMYC,EAAkBC,EAAM,WAGnC,CAAC,CAAE,QAAAC,EAAS,KAAAC,EAAM,KAAAC,EAAO,YAAaC,CAAK,EAAGC,IAUvCL,EAAA,cAACL,EAAA,CAAuB,GAAGS,EAAO,GATxBF,EAEb,CACE,aAAc,IACd,KAAAA,EACA,QAAS,MACX,EACA,CAAE,aAAc,SAA+B,KAAAC,EAAM,QAAAF,CAAQ,EAEC,IAAKI,CAAK,CAAA,CAC7E,EAEDN,EAAgB,YAAc"}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import*as t from"@radix-ui/react-toggle-group";import{styled as e}from"../../stitches.js";import{focusVisibleStyleBlock as o}from"../../utilities/style/focus-visible-style-block.js";const r=e(t.Item,{bg:"white",color:"$tonal400",border:"1px solid $tonal200",cursor:"pointer","&::before":{background:"$tonal200"},"&:not([disabled])":{'&:hover, &:focus-visible, &[data-state="on"]':{"&::before":{background:"none"}},"&:hover":{borderColor:"currentColor !important",color:"$primaryMid"},"&:focus-visible":{...o(),'&[data-state="off"]':{borderColor:"$tonal200 !important"},'&[data-state="on"]':{boxShadow:`inset currentColor 0px 0px 0px 1px, ${o().boxShadow}`}}},"&[disabled]":{opacity:.3,cursor:"not-allowed"},'&[data-state="on"]':{color:"$primary",borderColor:"currentColor !important",boxShadow:"inset currentColor 0px 0px 0px 1px"}}),a=r;export{r as StyledItem,a as ToggleGroupItem};
|
|
1
|
+
import*as t from"@radix-ui/react-toggle-group";import{styled as e}from"../../stitches.js";import"../../utilities/css-wrapper/CSSWrapper.js";import"color2k";import{focusVisibleStyleBlock as o}from"../../utilities/style/focus-visible-style-block.js";import"../../utilities/style/keyframe-animations.js";const r=e(t.Item,{bg:"white",color:"$tonal400",border:"1px solid $tonal200",cursor:"pointer","&::before":{background:"$tonal200"},"&:not([disabled])":{'&:hover, &:focus-visible, &[data-state="on"]':{"&::before":{background:"none"}},"&:hover":{borderColor:"currentColor !important",color:"$primaryMid"},"&:focus-visible":{...o(),'&[data-state="off"]':{borderColor:"$tonal200 !important"},'&[data-state="on"]':{boxShadow:`inset currentColor 0px 0px 0px 1px, ${o().boxShadow}`}}},"&[disabled]":{opacity:.3,cursor:"not-allowed"},'&[data-state="on"]':{color:"$primary",borderColor:"currentColor !important",boxShadow:"inset currentColor 0px 0px 0px 1px"}}),a=r;export{r as StyledItem,a as ToggleGroupItem};
|
|
2
2
|
//# sourceMappingURL=ToggleGroupItem.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ToggleGroupItem.js","sources":["../../../src/components/toggle-group/ToggleGroupItem.tsx"],"sourcesContent":["import * as ToggleGroup from '@radix-ui/react-toggle-group'\n\nimport { styled } from '~/stitches'\nimport { focusVisibleStyleBlock } from '~/utilities'\n\nexport const StyledItem = styled(ToggleGroup.Item, {\n bg: 'white',\n color: '$tonal400',\n border: '1px solid $tonal200',\n cursor: 'pointer',\n '&::before': {\n background: '$tonal200'\n },\n '&:not([disabled])': {\n '&:hover, &:focus-visible, &[data-state=\"on\"]': {\n '&::before': {\n background: 'none'\n }\n },\n '&:hover': {\n borderColor: 'currentColor !important',\n color: '$primaryMid'\n },\n '&:focus-visible': {\n ...focusVisibleStyleBlock(),\n '&[data-state=\"off\"]': {\n borderColor: '$tonal200 !important'\n },\n '&[data-state=\"on\"]': {\n boxShadow: `inset currentColor 0px 0px 0px 1px, ${\n focusVisibleStyleBlock().boxShadow\n }`\n }\n }\n },\n '&[disabled]': {\n opacity: 0.3,\n cursor: 'not-allowed'\n },\n '&[data-state=\"on\"]': {\n color: '$primary',\n borderColor: 'currentColor !important',\n boxShadow: 'inset currentColor 0px 0px 0px 1px'\n }\n})\n\nexport const ToggleGroupItem = StyledItem\n"],"names":["StyledItem","styled","ToggleGroup","focusVisibleStyleBlock","ToggleGroupItem"],"mappings":"
|
|
1
|
+
{"version":3,"file":"ToggleGroupItem.js","sources":["../../../src/components/toggle-group/ToggleGroupItem.tsx"],"sourcesContent":["import * as ToggleGroup from '@radix-ui/react-toggle-group'\n\nimport { styled } from '~/stitches'\nimport { focusVisibleStyleBlock } from '~/utilities'\n\nexport const StyledItem = styled(ToggleGroup.Item, {\n bg: 'white',\n color: '$tonal400',\n border: '1px solid $tonal200',\n cursor: 'pointer',\n '&::before': {\n background: '$tonal200'\n },\n '&:not([disabled])': {\n '&:hover, &:focus-visible, &[data-state=\"on\"]': {\n '&::before': {\n background: 'none'\n }\n },\n '&:hover': {\n borderColor: 'currentColor !important',\n color: '$primaryMid'\n },\n '&:focus-visible': {\n ...focusVisibleStyleBlock(),\n '&[data-state=\"off\"]': {\n borderColor: '$tonal200 !important'\n },\n '&[data-state=\"on\"]': {\n boxShadow: `inset currentColor 0px 0px 0px 1px, ${\n focusVisibleStyleBlock().boxShadow\n }`\n }\n }\n },\n '&[disabled]': {\n opacity: 0.3,\n cursor: 'not-allowed'\n },\n '&[data-state=\"on\"]': {\n color: '$primary',\n borderColor: 'currentColor !important',\n boxShadow: 'inset currentColor 0px 0px 0px 1px'\n }\n})\n\nexport const ToggleGroupItem = StyledItem\n"],"names":["StyledItem","styled","ToggleGroup","focusVisibleStyleBlock","ToggleGroupItem"],"mappings":"6SAKO,MAAMA,EAAaC,EAAOC,EAAY,KAAM,CACjD,GAAI,QACJ,MAAO,YACP,OAAQ,sBACR,OAAQ,UACR,YAAa,CACX,WAAY,WACd,EACA,oBAAqB,CACnB,+CAAgD,CAC9C,YAAa,CACX,WAAY,MACd,CACF,EACA,UAAW,CACT,YAAa,0BACb,MAAO,aACT,EACA,kBAAmB,CACjB,GAAGC,EAAAA,EACH,sBAAuB,CACrB,YAAa,sBACf,EACA,qBAAsB,CACpB,UAAW,uCACTA,IAAyB,WAE7B,CACF,CACF,EACA,cAAe,CACb,QAAS,GACT,OAAQ,aACV,EACA,qBAAsB,CACpB,MAAO,WACP,YAAa,0BACb,UAAW,oCACb,CACF,CAAC,EAEYC,EAAkBJ"}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{Content as m,Arrow as
|
|
1
|
+
import{Content as m,Arrow as r}from"@radix-ui/react-tooltip";import*as t from"react";import{TOOLTIP_Z_INDEX as l}from"../../constants/zIndices.js";import{styled as a}from"../../stitches.js";import"../../utilities/css-wrapper/CSSWrapper.js";import"color2k";import{slideDownAndFade as s,slideLeftAndFade as p,slideUpAndFade as f,slideRightAndFade as c}from"../../utilities/style/keyframe-animations.js";const h=a(m,{backgroundColor:"$tonal500",borderRadius:"$0",boxShadow:"$0",color:"white",fontFamily:"$body",fontSize:"$sm",lineHeight:1.5,whiteSpace:"normal",px:"$3",py:"$2",zIndex:l,"@allowMotion":{animationDuration:"75ms",animationTimingFunction:"cubic-bezier(0.16, 1, 0.3, 1)",willChange:"transform, opacity",'&[data-state="delayed-open"]':{'&[data-side="top"]':{animationName:s},'&[data-side="right"]':{animationName:p},'&[data-side="bottom"]':{animationName:f},'&[data-side="left"]':{animationName:c}}},variants:{size:{sm:{maxWidth:"100px"},md:{maxWidth:"250px"},lg:{maxWidth:"400px"}}}}),x=a(r,{fill:"$tonal500",'[data-align="end"] &':{mr:"$2"},'[data-align="start"] &':{ml:"$2"}}),$=({children:i,side:e="top",sideOffset:o=4,size:n="md",...d})=>t.createElement(h,{side:e,sideOffset:o,size:n,...d},i,t.createElement(x,null));export{$ as TooltipContent};
|
|
2
2
|
//# sourceMappingURL=TooltipContent.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"TooltipContent.js","sources":["../../../src/components/tooltip/TooltipContent.tsx"],"sourcesContent":["import { Arrow, Content } from '@radix-ui/react-tooltip'\nimport * as React from 'react'\n\nimport { TOOLTIP_Z_INDEX } from '~/constants/zIndices'\nimport { styled } from '~/stitches'\nimport {\n slideDownAndFade,\n slideLeftAndFade,\n slideRightAndFade,\n slideUpAndFade\n} from '~/utilities'\n\nconst StyledContent = styled(Content, {\n backgroundColor: '$tonal500',\n borderRadius: '$0',\n boxShadow: '$0',\n color: 'white',\n fontFamily: '$body',\n fontSize: '$sm',\n lineHeight: 1.5,\n whiteSpace: 'normal',\n px: '$3',\n py: '$2',\n zIndex: TOOLTIP_Z_INDEX,\n '@allowMotion': {\n animationDuration: '75ms',\n animationTimingFunction: 'cubic-bezier(0.16, 1, 0.3, 1)',\n willChange: 'transform, opacity',\n '&[data-state=\"delayed-open\"]': {\n '&[data-side=\"top\"]': { animationName: slideDownAndFade },\n '&[data-side=\"right\"]': { animationName: slideLeftAndFade },\n '&[data-side=\"bottom\"]': { animationName: slideUpAndFade },\n '&[data-side=\"left\"]': { animationName: slideRightAndFade }\n }\n },\n variants: {\n size: {\n sm: { maxWidth: '100px' },\n md: { maxWidth: '250px' },\n lg: { maxWidth: '400px' }\n }\n }\n})\n\nconst StyledArrow = styled(Arrow, {\n fill: '$tonal500',\n '[data-align=\"end\"] &': { mr: '$2' },\n '[data-align=\"start\"] &': { ml: '$2' }\n})\n\ntype TooltipContentProps = React.ComponentProps<typeof StyledContent> &\n React.ComponentProps<typeof Content>\n\nexport const TooltipContent: React.FC<TooltipContentProps> = ({\n children,\n side = 'top',\n sideOffset = 4,\n size = 'md',\n ...remainingProps\n}) => (\n <StyledContent\n side={side}\n sideOffset={sideOffset}\n size={size}\n {...remainingProps}\n >\n {children}\n <StyledArrow />\n </StyledContent>\n)\n"],"names":["StyledContent","styled","Content","TOOLTIP_Z_INDEX","slideDownAndFade","slideLeftAndFade","slideUpAndFade","slideRightAndFade","StyledArrow","Arrow","TooltipContent","children","side","sideOffset","size","remainingProps","React"],"mappings":"
|
|
1
|
+
{"version":3,"file":"TooltipContent.js","sources":["../../../src/components/tooltip/TooltipContent.tsx"],"sourcesContent":["import { Arrow, Content } from '@radix-ui/react-tooltip'\nimport * as React from 'react'\n\nimport { TOOLTIP_Z_INDEX } from '~/constants/zIndices'\nimport { styled } from '~/stitches'\nimport {\n slideDownAndFade,\n slideLeftAndFade,\n slideRightAndFade,\n slideUpAndFade\n} from '~/utilities'\n\nconst StyledContent = styled(Content, {\n backgroundColor: '$tonal500',\n borderRadius: '$0',\n boxShadow: '$0',\n color: 'white',\n fontFamily: '$body',\n fontSize: '$sm',\n lineHeight: 1.5,\n whiteSpace: 'normal',\n px: '$3',\n py: '$2',\n zIndex: TOOLTIP_Z_INDEX,\n '@allowMotion': {\n animationDuration: '75ms',\n animationTimingFunction: 'cubic-bezier(0.16, 1, 0.3, 1)',\n willChange: 'transform, opacity',\n '&[data-state=\"delayed-open\"]': {\n '&[data-side=\"top\"]': { animationName: slideDownAndFade },\n '&[data-side=\"right\"]': { animationName: slideLeftAndFade },\n '&[data-side=\"bottom\"]': { animationName: slideUpAndFade },\n '&[data-side=\"left\"]': { animationName: slideRightAndFade }\n }\n },\n variants: {\n size: {\n sm: { maxWidth: '100px' },\n md: { maxWidth: '250px' },\n lg: { maxWidth: '400px' }\n }\n }\n})\n\nconst StyledArrow = styled(Arrow, {\n fill: '$tonal500',\n '[data-align=\"end\"] &': { mr: '$2' },\n '[data-align=\"start\"] &': { ml: '$2' }\n})\n\ntype TooltipContentProps = React.ComponentProps<typeof StyledContent> &\n React.ComponentProps<typeof Content>\n\nexport const TooltipContent: React.FC<TooltipContentProps> = ({\n children,\n side = 'top',\n sideOffset = 4,\n size = 'md',\n ...remainingProps\n}) => (\n <StyledContent\n side={side}\n sideOffset={sideOffset}\n size={size}\n {...remainingProps}\n >\n {children}\n <StyledArrow />\n </StyledContent>\n)\n"],"names":["StyledContent","styled","Content","TOOLTIP_Z_INDEX","slideDownAndFade","slideLeftAndFade","slideUpAndFade","slideRightAndFade","StyledArrow","Arrow","TooltipContent","children","side","sideOffset","size","remainingProps","React"],"mappings":"iZAYA,MAAMA,EAAgBC,EAAOC,EAAS,CACpC,gBAAiB,YACjB,aAAc,KACd,UAAW,KACX,MAAO,QACP,WAAY,QACZ,SAAU,MACV,WAAY,IACZ,WAAY,SACZ,GAAI,KACJ,GAAI,KACJ,OAAQC,EACR,eAAgB,CACd,kBAAmB,OACnB,wBAAyB,gCACzB,WAAY,qBACZ,+BAAgC,CAC9B,qBAAsB,CAAE,cAAeC,CAAiB,EACxD,uBAAwB,CAAE,cAAeC,CAAiB,EAC1D,wBAAyB,CAAE,cAAeC,CAAe,EACzD,sBAAuB,CAAE,cAAeC,CAAkB,CAC5D,CACF,EACA,SAAU,CACR,KAAM,CACJ,GAAI,CAAE,SAAU,OAAQ,EACxB,GAAI,CAAE,SAAU,OAAQ,EACxB,GAAI,CAAE,SAAU,OAAQ,CAC1B,CACF,CACF,CAAC,EAEKC,EAAcP,EAAOQ,EAAO,CAChC,KAAM,YACN,uBAAwB,CAAE,GAAI,IAAK,EACnC,yBAA0B,CAAE,GAAI,IAAK,CACvC,CAAC,EAKYC,EAAgD,CAAC,CAC5D,SAAAC,EACA,KAAAC,EAAO,MACP,WAAAC,EAAa,EACb,KAAAC,EAAO,QACJC,CACL,IACEC,EAAA,cAAChB,EAAA,CACC,KAAMY,EACN,WAAYC,EACZ,KAAMC,EACL,GAAGC,CAEHJ,EAAAA,EACDK,EAAA,cAACR,EAAA,IAAY,CACf"}
|