@yamada-ui/react
Version:
React UI components of the Yamada, by the Yamada, for the Yamada built with React and Emotion
1 lines • 6.19 kB
Source Map (JSON)
{"version":3,"file":"resizable.style.cjs","names":["defineComponentSlotStyle"],"sources":["../../../../src/components/resizable/resizable.style.ts"],"sourcesContent":["import { defineComponentSlotStyle } from \"../../core\"\n\nexport const resizableStyle = defineComponentSlotStyle({\n base: {\n icon: {\n alignItems: \"center\",\n display: \"flex\",\n justifyContent: \"center\",\n left: \"50%\",\n position: \"absolute\",\n top: \"50%\",\n translateX: \"-50%\",\n translateY: \"-50%\",\n },\n item: {\n boxSize: \"full\",\n },\n root: {\n boxSize: \"full\",\n },\n trigger: {\n position: \"relative\",\n transitionDuration: \"moderate\",\n transitionProperty: \"common\",\n _after: {\n transitionDuration: \"moderate\",\n transitionProperty: \"common\",\n },\n },\n },\n\n variants: {\n border: {\n icon: {\n bg: \"colorScheme.muted\",\n color: \"colorScheme.fg\",\n py: \"1\",\n rounded: \"l1\",\n },\n trigger: {\n bg: \"colorScheme.muted\",\n focusVisibleRing: \"none\",\n _after: {\n position: \"absolute\",\n },\n _hover: {\n bg: \"colorScheme.emphasized\",\n },\n _focusVisible: {\n bg: \"colorScheme.emphasized\",\n },\n },\n },\n plain: {\n trigger: {\n focusVisibleRing: \"none\",\n _after: {\n position: \"absolute\",\n },\n },\n },\n spacer: {\n icon: {\n color: \"colorScheme.fg\",\n transitionDuration: \"moderate\",\n transitionProperty: \"common\",\n _active: {\n color: \"transparent\",\n },\n },\n trigger: {\n focusVisibleRing: \"none\",\n p: \"1\",\n _after: {\n bg: \"transparent\",\n display: \"block\",\n rounded: \"full\",\n },\n _hover: {\n _after: {\n bg: \"colorScheme.bg\",\n },\n _icon: {\n color: \"transparent\",\n },\n },\n _focusVisible: {\n _after: {\n bg: \"colorScheme.bg\",\n },\n _icon: {\n color: \"transparent\",\n },\n },\n },\n },\n },\n\n props: {\n /**\n * The orientation of the resizable.\n *\n * @default 'horizontal'\n */\n orientation: {\n horizontal: {\n icon: {\n transform: \"translate(-50%, -50%) rotate(0deg)\",\n },\n },\n vertical: {\n icon: {\n transform: \"translate(-50%, -50%) rotate(90deg)\",\n },\n },\n },\n },\n\n compounds: [\n {\n css: {\n trigger: {\n h: \"px\",\n _after: {\n h: \"2\",\n left: \"0\",\n right: \"0\",\n transform: \"translateY(-50%)\",\n },\n },\n },\n variant: \"border\",\n orientation: \"vertical\",\n },\n {\n css: {\n trigger: {\n w: \"px\",\n _after: {\n bottom: \"0\",\n top: \"0\",\n transform: \"translateX(-50%)\",\n w: \"2\",\n },\n },\n },\n variant: \"border\",\n orientation: \"horizontal\",\n },\n {\n css: {\n trigger: {\n _after: { h: \"2\", w: \"full\" },\n },\n },\n variant: \"spacer\",\n orientation: \"vertical\",\n },\n {\n css: {\n trigger: {\n _after: { h: \"full\", w: \"2\" },\n },\n },\n variant: \"spacer\",\n orientation: \"horizontal\",\n },\n {\n css: {\n trigger: {\n _after: {\n h: \"2\",\n left: \"0\",\n right: \"0\",\n transform: \"translateY(-50%)\",\n },\n },\n },\n variant: \"plain\",\n orientation: \"vertical\",\n },\n {\n css: {\n trigger: {\n _after: {\n bottom: \"0\",\n top: \"0\",\n transform: \"translateX(-50%)\",\n w: \"2\",\n },\n },\n },\n variant: \"plain\",\n orientation: \"horizontal\",\n },\n ],\n\n defaultProps: {\n variant: \"border\",\n orientation: \"horizontal\",\n },\n})\n\nexport type ResizableStyle = typeof resizableStyle\n"],"mappings":";;;AAEA,MAAa,iBAAiBA,wCAAyB;CACrD,MAAM;EACJ,MAAM;GACJ,YAAY;GACZ,SAAS;GACT,gBAAgB;GAChB,MAAM;GACN,UAAU;GACV,KAAK;GACL,YAAY;GACZ,YAAY;GACb;EACD,MAAM,EACJ,SAAS,QACV;EACD,MAAM,EACJ,SAAS,QACV;EACD,SAAS;GACP,UAAU;GACV,oBAAoB;GACpB,oBAAoB;GACpB,QAAQ;IACN,oBAAoB;IACpB,oBAAoB;IACrB;GACF;EACF;CAED,UAAU;EACR,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d;EACD;GACE,KAAK,EACH,SAAS,EACP,QAAQ;IACN,GAAG;IACH,MAAM;IACN,OAAO;IACP,WAAW;IACZ,EACF,EACF;GACD,SAAS;GACT,aAAa;GACd;EACD;GACE,KAAK,EACH,SAAS,EACP,QAAQ;IACN,QAAQ;IACR,KAAK;IACL,WAAW;IACX,GAAG;IACJ,EACF,EACF;GACD,SAAS;GACT,aAAa;GACd;EACF;CAED,cAAc;EACZ,SAAS;EACT,aAAa;EACd;CACF,CAAC"}