Open source website builder and Webflow alternative. Webstudio is an advanced visual builder that connects to any headless CMS, supports all CSS properties, and can be hosted anywhere, including with us.
TypeScript accessibilityalternativecloudflarecloudflare-workersdesignfreefrontendopen-sourceradix-uireactremixweb-developmentwebflowwebsite-builderwebsite-developmentwebsiteswebstudio
Move styles to Card and don't use `zoom` since it's messing up Popover positioning
Andrey Okonetchnikove14ef59d77a9
diff --git a/app/auth/login.tsx b/app/auth/login.tsxindex f03e922a89..54d378412a 100644--- a/app/auth/login.tsx+++ b/app/auth/login.tsx@@ -42,7 +42,7 @@ export const Login = ({ errorMessage }: { errorMessage: string }) => {align="center"justify="center">- <Card css={{ width: 200, padding: "$5", zoom: 1.4 }} variant="active">+ <Card><Flex direction="column" gap="2" align="center"><Heading>Login</Heading>{errorMessage.length ? (diff --git a/app/dashboard/components/card.tsx b/app/dashboard/components/card.tsxindex aaa7eac872..71730f8060 100644--- a/app/dashboard/components/card.tsx+++ b/app/dashboard/components/card.tsx@@ -32,7 +32,7 @@ export const SelectProjectCard = ({navigate(`${config.designerPath}/${selectedProject}`);};return (- <Card css={{ width: "$10", padding: "$5", zoom: 1.4 }} variant="active">+ <Card><Flex direction="column" gap="2"><Heading>Select a project</Heading><Selectdiff --git a/app/shared/design-system/components/card.tsx b/app/shared/design-system/components/card.tsxindex 756bc5aca8..f971138949 100644--- a/app/shared/design-system/components/card.tsx+++ b/app/shared/design-system/components/card.tsx@@ -1,96 +1,98 @@-import { styled } from '../stitches.config';+import { styled } from "../stitches.config";-export const Card = styled('div', {- appearance: 'none',- border: 'none',- boxSizing: 'border-box',- font: 'inherit',- lineHeight: '1',- outline: 'none',- padding: 0,- textAlign: 'inherit',- verticalAlign: 'middle',- WebkitTapHighlightColor: 'rgba(0, 0, 0, 0)',+export const Card = styled("div", {+ appearance: "none",+ border: "none",+ boxSizing: "border-box",+ font: "inherit",+ lineHeight: "1",+ outline: "none",+ width: "$10",+ padding: "$5",+ textAlign: "inherit",+ verticalAlign: "middle",+ WebkitTapHighlightColor: "rgba(0, 0, 0, 0)",- backgroundColor: '$panel',- display: 'block',- textDecoration: 'none',- color: 'inherit',+ backgroundColor: "$panel",+ display: "block",+ textDecoration: "none",+ color: "inherit",flexShrink: 0,- borderRadius: '$3',- position: 'relative',+ borderRadius: "$3",+ position: "relative",- '&::before': {- boxSizing: 'border-box',+ "&::before": {+ boxSizing: "border-box",content: '""',- position: 'absolute',+ position: "absolute",top: 0,right: 0,bottom: 0,left: 0,- boxShadow: 'inset 0 0 0 1px rgba(0,0,0,.1)',- borderRadius: '$3',- pointerEvents: 'none',+ boxShadow: "inset 0 0 0 1px rgba(0,0,0,.1)",+ borderRadius: "$3",+ pointerEvents: "none",},variants: {variant: {interactive: {- '@hover': {- '&:hover': {- '&::before': {- boxShadow: 'inset 0 0 0 1px rgba(0,0,0,.2)',+ "@hover": {+ "&:hover": {+ "&::before": {+ boxShadow: "inset 0 0 0 1px rgba(0,0,0,.2)",},},},- '&:focus': {- '&::before': {- boxShadow: 'inset 0 0 0 1px $colors$blue8, 0 0 0 1px $colors$blue8',+ "&:focus": {+ "&::before": {+ boxShadow: "inset 0 0 0 1px $colors$blue8, 0 0 0 1px $colors$blue8",},},},ghost: {- backgroundColor: 'transparent',- transition: 'transform 200ms cubic-bezier(0.22, 1, 0.36, 1), background-color 25ms linear',- willChange: 'transform',- '&::before': {+ backgroundColor: "transparent",+ transition:+ "transform 200ms cubic-bezier(0.22, 1, 0.36, 1), background-color 25ms linear",+ willChange: "transform",+ "&::before": {boxShadow:- '0px 10px 38px -10px rgba(22, 23, 24, 0.35), 0px 10px 20px -15px rgba(22, 23, 24, 0.2)',- opacity: '0',- transition: 'all 200ms cubic-bezier(0.22, 1, 0.36, 1)',+ "0px 10px 38px -10px rgba(22, 23, 24, 0.35), 0px 10px 20px -15px rgba(22, 23, 24, 0.2)",+ opacity: "0",+ transition: "all 200ms cubic-bezier(0.22, 1, 0.36, 1)",},- '@hover': {- '&:hover': {- backgroundColor: '$panel',- transform: 'translateY(-2px)',- '&::before': {- opacity: '1',+ "@hover": {+ "&:hover": {+ backgroundColor: "$panel",+ transform: "translateY(-2px)",+ "&::before": {+ opacity: "1",},},},- '&:active': {- transform: 'translateY(0)',- transition: 'none',- '&::before': {+ "&:active": {+ transform: "translateY(0)",+ transition: "none",+ "&::before": {boxShadow:- '0px 5px 16px -5px rgba(22, 23, 24, 0.35), 0px 5px 10px -7px rgba(22, 23, 24, 0.2)',- opacity: '1',+ "0px 5px 16px -5px rgba(22, 23, 24, 0.35), 0px 5px 10px -7px rgba(22, 23, 24, 0.2)",+ opacity: "1",},},- '&:focus': {- boxShadow: 'inset 0 0 0 1px $colors$blue8, 0 0 0 1px $colors$blue8',+ "&:focus": {+ boxShadow: "inset 0 0 0 1px $colors$blue8, 0 0 0 1px $colors$blue8",},},active: {- transform: 'translateY(0)',- transition: 'none',- '&::before': {+ transform: "translateY(0)",+ transition: "none",+ "&::before": {boxShadow:- '0px 5px 16px -5px rgba(22, 23, 24, 0.35), 0px 5px 10px -7px rgba(22, 23, 24, 0.2)',- opacity: '1',+ "0px 5px 16px -5px rgba(22, 23, 24, 0.35), 0px 5px 10px -7px rgba(22, 23, 24, 0.2)",+ opacity: "1",},- '&:focus': {- boxShadow: 'inset 0 0 0 1px $colors$blue8, 0 0 0 1px $colors$blue8',+ "&:focus": {+ boxShadow: "inset 0 0 0 1px $colors$blue8, 0 0 0 1px $colors$blue8",},},},