@mage-ui/components 1.0.83 → 1.0.84
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.
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{ButtonIcon as e}from"../../buttons/button-icon/ButtonIcon.mjs";import{cx as t}from"@mage-ui/styled-system/css";import{removableItem as n,removableItemButtonIcon as r,removableItemButtonIconIcon as i,removableItemButtonIconIconRaw as a,removableItemButtonIconIconRawRoot as o,removableItemButtonIconRoot as s,removableItemContent as c,removableItemRoot as l,removableItemSection as u}from"@mage-ui/styled-system/recipes";import{jsx as d,jsxs as f}from"react/jsx-runtime";const p=({startSlot:p,children:m,onRemove:h,removeButtonLabel:g=`Remove`,classNames:_})=>f(`div`,{className:t(_?.container??n(),_?.root??l()),children:[p&&d(`div`,{className:_?.section??u(),children:p}),d(`div`,{className:_?.content??c(),children:m}),d(e,{label:g,onClick:h,path:`/icons/sprite-mage.svg`,name:`mage-
|
|
1
|
+
import{ButtonIcon as e}from"../../buttons/button-icon/ButtonIcon.mjs";import{cx as t}from"@mage-ui/styled-system/css";import{removableItem as n,removableItemButtonIcon as r,removableItemButtonIconIcon as i,removableItemButtonIconIconRaw as a,removableItemButtonIconIconRawRoot as o,removableItemButtonIconRoot as s,removableItemContent as c,removableItemRoot as l,removableItemSection as u}from"@mage-ui/styled-system/recipes";import{jsx as d,jsxs as f}from"react/jsx-runtime";const p=({startSlot:p,children:m,onRemove:h,removeButtonLabel:g=`Remove`,classNames:_})=>f(`div`,{className:t(_?.container??n(),_?.root??l()),children:[p&&d(`div`,{className:_?.section??u(),children:p}),d(`div`,{className:_?.content??c(),children:m}),d(e,{label:g,onClick:h,path:`/icons/sprite-mage.svg`,name:`mage-removable-item-button-x`,classNames:{buttonIcon:_?.buttonIcon?.buttonIcon??r(),root:_?.buttonIcon?.root??s(),icon:_?.buttonIcon?.icon??i(),iconRaw:{iconRaw:_?.buttonIcon?.iconRaw?.iconRaw??a(),root:_?.buttonIcon?.iconRaw?.root??o()}}})]});export{p as RemovableItem};
|
|
2
2
|
//# sourceMappingURL=RemovableItem.mjs.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"RemovableItem.mjs","names":[],"sources":["../../../../src/components/data-display/removable-item/RemovableItem.tsx"],"sourcesContent":["import type { ReactNode } from 'react';\n\nimport { cx } from '@mage-ui/styled-system/css';\nimport {\n removableItem,\n removableItemButtonIcon,\n removableItemButtonIconIcon,\n removableItemButtonIconIconRaw,\n removableItemButtonIconIconRawRoot,\n removableItemButtonIconRoot,\n removableItemContent,\n removableItemRoot,\n removableItemSection,\n} from '@mage-ui/styled-system/recipes';\nimport { ButtonIcon, type ButtonIconProps } from '@/components/buttons';\n\nexport type RemovableItemProps = {\n startSlot?: ReactNode;\n children: ReactNode;\n onRemove: () => void;\n removeButtonLabel?: string;\n classNames?: {\n container?: string;\n root?: string;\n section?: string;\n content?: string;\n buttonIcon?: ButtonIconProps['classNames'];\n };\n};\n\nexport const RemovableItem = ({\n startSlot,\n children,\n onRemove,\n removeButtonLabel = 'Remove',\n classNames,\n}: RemovableItemProps) => {\n return (\n <div\n className={cx(\n classNames?.container ?? removableItem(),\n classNames?.root ?? removableItemRoot(),\n )}\n >\n {startSlot && (\n <div className={classNames?.section ?? removableItemSection()}>\n {startSlot}\n </div>\n )}\n\n <div className={classNames?.content ?? removableItemContent()}>\n {children}\n </div>\n\n <ButtonIcon\n label={removeButtonLabel}\n onClick={onRemove}\n path='/icons/sprite-mage.svg'\n name='mage-
|
|
1
|
+
{"version":3,"file":"RemovableItem.mjs","names":[],"sources":["../../../../src/components/data-display/removable-item/RemovableItem.tsx"],"sourcesContent":["import type { ReactNode } from 'react';\n\nimport { cx } from '@mage-ui/styled-system/css';\nimport {\n removableItem,\n removableItemButtonIcon,\n removableItemButtonIconIcon,\n removableItemButtonIconIconRaw,\n removableItemButtonIconIconRawRoot,\n removableItemButtonIconRoot,\n removableItemContent,\n removableItemRoot,\n removableItemSection,\n} from '@mage-ui/styled-system/recipes';\nimport { ButtonIcon, type ButtonIconProps } from '@/components/buttons';\n\nexport type RemovableItemProps = {\n startSlot?: ReactNode;\n children: ReactNode;\n onRemove: () => void;\n removeButtonLabel?: string;\n classNames?: {\n container?: string;\n root?: string;\n section?: string;\n content?: string;\n buttonIcon?: ButtonIconProps['classNames'];\n };\n};\n\nexport const RemovableItem = ({\n startSlot,\n children,\n onRemove,\n removeButtonLabel = 'Remove',\n classNames,\n}: RemovableItemProps) => {\n return (\n <div\n className={cx(\n classNames?.container ?? removableItem(),\n classNames?.root ?? removableItemRoot(),\n )}\n >\n {startSlot && (\n <div className={classNames?.section ?? removableItemSection()}>\n {startSlot}\n </div>\n )}\n\n <div className={classNames?.content ?? removableItemContent()}>\n {children}\n </div>\n\n <ButtonIcon\n label={removeButtonLabel}\n onClick={onRemove}\n path='/icons/sprite-mage.svg'\n name='mage-removable-item-button-x'\n classNames={{\n buttonIcon:\n classNames?.buttonIcon?.buttonIcon ?? removableItemButtonIcon(),\n root: classNames?.buttonIcon?.root ?? removableItemButtonIconRoot(),\n icon: classNames?.buttonIcon?.icon ?? removableItemButtonIconIcon(),\n iconRaw: {\n iconRaw:\n classNames?.buttonIcon?.iconRaw?.iconRaw ??\n removableItemButtonIconIconRaw(),\n root:\n classNames?.buttonIcon?.iconRaw?.root ??\n removableItemButtonIconIconRawRoot(),\n },\n }}\n />\n </div>\n );\n};\n"],"mappings":"6dA8BA,MAAa,GAAiB,CAC5B,YACA,WACA,WACA,oBAAoB,SACpB,gBAGE,EAAC,MAAA,CACC,UAAW,EACT,GAAY,WAAa,GAAe,CACxC,GAAY,MAAQ,GAAmB,CACxC,WAEA,GACC,EAAC,MAAA,CAAI,UAAW,GAAY,SAAW,GAAsB,UAC1D,GACG,CAGR,EAAC,MAAA,CAAI,UAAW,GAAY,SAAW,GAAsB,CAC1D,YACG,CAEN,EAAC,EAAA,CACC,MAAO,EACP,QAAS,EACT,KAAK,yBACL,KAAK,+BACL,WAAY,CACV,WACE,GAAY,YAAY,YAAc,GAAyB,CACjE,KAAM,GAAY,YAAY,MAAQ,GAA6B,CACnE,KAAM,GAAY,YAAY,MAAQ,GAA6B,CACnE,QAAS,CACP,QACE,GAAY,YAAY,SAAS,SACjC,GAAgC,CAClC,KACE,GAAY,YAAY,SAAS,MACjC,GAAoC,CACvC,CACF,EACD,GACE"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@mage-ui/components",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.84",
|
|
4
4
|
"private": false,
|
|
5
5
|
"description": "",
|
|
6
6
|
"keywords": [],
|
|
@@ -25,7 +25,7 @@
|
|
|
25
25
|
"rimraf": "^6.1.3",
|
|
26
26
|
"tsdown": "^0.20.3",
|
|
27
27
|
"typescript": "^5.9.3",
|
|
28
|
-
"@mage-ui/preset": "1.0.
|
|
28
|
+
"@mage-ui/preset": "1.0.84",
|
|
29
29
|
"@mage-ui/styled-system": "1.0.8"
|
|
30
30
|
},
|
|
31
31
|
"peerDependencies": {
|