@yamada-ui/close-button 1.0.40-dev-20240915031944 → 1.0.40-dev-20240917033401
Sign up to get free protection for your applications and to get access to all the features.
- package/dist/{chunk-LF7HRRGI.mjs → chunk-JA6RODZU.mjs} +1 -1
- package/dist/chunk-JA6RODZU.mjs.map +1 -0
- package/dist/close-button.d.mts +4 -3
- package/dist/close-button.d.ts +4 -3
- package/dist/close-button.js.map +1 -1
- package/dist/close-button.mjs +1 -1
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +1 -1
- package/package.json +5 -5
- package/dist/chunk-LF7HRRGI.mjs.map +0 -1
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"sources":["../src/close-button.tsx"],"sourcesContent":["import type { HTMLUIProps, ThemeProps, CSSUIObject } from \"@yamada-ui/core\"\nimport {\n ui,\n forwardRef,\n useComponentStyle,\n omitThemeProps,\n} from \"@yamada-ui/core\"\nimport { CloseIcon } from \"@yamada-ui/icon\"\nimport { Ripple, useRipple } from \"@yamada-ui/ripple\"\nimport { cx } from \"@yamada-ui/utils\"\n\ninterface CloseButtonOptions {\n /**\n * If `true`, the button is disabled.\n *\n * @default false\n */\n isDisabled?: boolean\n /**\n * If `true`, disable ripple effects when pressing a element.\n *\n * @default false\n */\n disableRipple?: boolean\n /**\n * If true, the button is full rounded.\n *\n * @default false\n */\n isRounded?: boolean\n}\n\nexport interface CloseButtonProps\n extends HTMLUIProps<\"button\">,\n ThemeProps<\"CloseButton\">,\n CloseButtonOptions {}\n\n/**\n * `CloseButton` is a component used primarily to trigger the close functionality of a component.\n *\n * @see Docs https://yamada-ui.com/components/other/close-button\n */\n\nexport const CloseButton = forwardRef<CloseButtonProps, \"button\">(\n (props, ref) => {\n const [styles, mergedProps] = useComponentStyle(\"CloseButton\", props)\n const {\n className,\n children,\n isDisabled,\n isRounded,\n __css,\n disableRipple,\n ...rest\n } = omitThemeProps(mergedProps)\n const { onPointerDown, ...rippleProps } = useRipple({\n ...rest,\n isDisabled: disableRipple || isDisabled,\n })\n\n const css: CSSUIObject = {\n position: \"relative\",\n overflow: \"hidden\",\n outline: 0,\n display: \"flex\",\n justifyContent: \"center\",\n alignItems: \"center\",\n flexShrink: 0,\n ...styles,\n ...__css,\n ...(isRounded ? { borderRadius: \"fallback(full, 9999px)\" } : {}),\n }\n\n return (\n <ui.button\n ref={ref}\n type=\"button\"\n aria-label=\"Close\"\n className={cx(\"ui-close-button\", className)}\n disabled={isDisabled}\n __css={css}\n {...rest}\n onPointerDown={onPointerDown}\n >\n {children || <CloseIcon width=\"1em\" height=\"1em\" />}\n\n <Ripple isDisabled={disableRipple || isDisabled} {...rippleProps} />\n </ui.button>\n )\n },\n)\n"],"mappings":";;;AACA;AAAA,EACE;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,OACK;AACP,SAAS,iBAAiB;AAC1B,SAAS,QAAQ,iBAAiB;AAClC,SAAS,UAAU;AAiEb,SAUe,KAVf;AA/BC,IAAM,cAAc;AAAA,EACzB,CAAC,OAAO,QAAQ;AACd,UAAM,CAAC,QAAQ,WAAW,IAAI,kBAAkB,eAAe,KAAK;AACpE,UAAM;AAAA,MACJ;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA,GAAG;AAAA,IACL,IAAI,eAAe,WAAW;AAC9B,UAAM,EAAE,eAAe,GAAG,YAAY,IAAI,UAAU;AAAA,MAClD,GAAG;AAAA,MACH,YAAY,iBAAiB;AAAA,IAC/B,CAAC;AAED,UAAM,MAAmB;AAAA,MACvB,UAAU;AAAA,MACV,UAAU;AAAA,MACV,SAAS;AAAA,MACT,SAAS;AAAA,MACT,gBAAgB;AAAA,MAChB,YAAY;AAAA,MACZ,YAAY;AAAA,MACZ,GAAG;AAAA,MACH,GAAG;AAAA,MACH,GAAI,YAAY,EAAE,cAAc,yBAAyB,IAAI,CAAC;AAAA,IAChE;AAEA,WACE;AAAA,MAAC,GAAG;AAAA,MAAH;AAAA,QACC;AAAA,QACA,MAAK;AAAA,QACL,cAAW;AAAA,QACX,WAAW,GAAG,mBAAmB,SAAS;AAAA,QAC1C,UAAU;AAAA,QACV,OAAO;AAAA,QACN,GAAG;AAAA,QACJ;AAAA,QAEC;AAAA,sBAAY,oBAAC,aAAU,OAAM,OAAM,QAAO,OAAM;AAAA,UAEjD,oBAAC,UAAO,YAAY,iBAAiB,YAAa,GAAG,aAAa;AAAA;AAAA;AAAA,IACpE;AAAA,EAEJ;AACF;","names":[]}
|
package/dist/close-button.d.mts
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
import * as _yamada_ui_core from '@yamada-ui/core';
|
2
2
|
import { HTMLUIProps, ThemeProps } from '@yamada-ui/core';
|
3
3
|
|
4
|
-
|
4
|
+
interface CloseButtonOptions {
|
5
5
|
/**
|
6
6
|
* If `true`, the button is disabled.
|
7
7
|
*
|
@@ -20,8 +20,9 @@ type CloseButtonOptions = {
|
|
20
20
|
* @default false
|
21
21
|
*/
|
22
22
|
isRounded?: boolean;
|
23
|
-
}
|
24
|
-
|
23
|
+
}
|
24
|
+
interface CloseButtonProps extends HTMLUIProps<"button">, ThemeProps<"CloseButton">, CloseButtonOptions {
|
25
|
+
}
|
25
26
|
/**
|
26
27
|
* `CloseButton` is a component used primarily to trigger the close functionality of a component.
|
27
28
|
*
|
package/dist/close-button.d.ts
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
import * as _yamada_ui_core from '@yamada-ui/core';
|
2
2
|
import { HTMLUIProps, ThemeProps } from '@yamada-ui/core';
|
3
3
|
|
4
|
-
|
4
|
+
interface CloseButtonOptions {
|
5
5
|
/**
|
6
6
|
* If `true`, the button is disabled.
|
7
7
|
*
|
@@ -20,8 +20,9 @@ type CloseButtonOptions = {
|
|
20
20
|
* @default false
|
21
21
|
*/
|
22
22
|
isRounded?: boolean;
|
23
|
-
}
|
24
|
-
|
23
|
+
}
|
24
|
+
interface CloseButtonProps extends HTMLUIProps<"button">, ThemeProps<"CloseButton">, CloseButtonOptions {
|
25
|
+
}
|
25
26
|
/**
|
26
27
|
* `CloseButton` is a component used primarily to trigger the close functionality of a component.
|
27
28
|
*
|
package/dist/close-button.js.map
CHANGED
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"sources":["../src/close-button.tsx"],"sourcesContent":["import type { HTMLUIProps, ThemeProps, CSSUIObject } from \"@yamada-ui/core\"\nimport {\n ui,\n forwardRef,\n useComponentStyle,\n omitThemeProps,\n} from \"@yamada-ui/core\"\nimport { CloseIcon } from \"@yamada-ui/icon\"\nimport { Ripple, useRipple } from \"@yamada-ui/ripple\"\nimport { cx } from \"@yamada-ui/utils\"\n\
|
1
|
+
{"version":3,"sources":["../src/close-button.tsx"],"sourcesContent":["import type { HTMLUIProps, ThemeProps, CSSUIObject } from \"@yamada-ui/core\"\nimport {\n ui,\n forwardRef,\n useComponentStyle,\n omitThemeProps,\n} from \"@yamada-ui/core\"\nimport { CloseIcon } from \"@yamada-ui/icon\"\nimport { Ripple, useRipple } from \"@yamada-ui/ripple\"\nimport { cx } from \"@yamada-ui/utils\"\n\ninterface CloseButtonOptions {\n /**\n * If `true`, the button is disabled.\n *\n * @default false\n */\n isDisabled?: boolean\n /**\n * If `true`, disable ripple effects when pressing a element.\n *\n * @default false\n */\n disableRipple?: boolean\n /**\n * If true, the button is full rounded.\n *\n * @default false\n */\n isRounded?: boolean\n}\n\nexport interface CloseButtonProps\n extends HTMLUIProps<\"button\">,\n ThemeProps<\"CloseButton\">,\n CloseButtonOptions {}\n\n/**\n * `CloseButton` is a component used primarily to trigger the close functionality of a component.\n *\n * @see Docs https://yamada-ui.com/components/other/close-button\n */\n\nexport const CloseButton = forwardRef<CloseButtonProps, \"button\">(\n (props, ref) => {\n const [styles, mergedProps] = useComponentStyle(\"CloseButton\", props)\n const {\n className,\n children,\n isDisabled,\n isRounded,\n __css,\n disableRipple,\n ...rest\n } = omitThemeProps(mergedProps)\n const { onPointerDown, ...rippleProps } = useRipple({\n ...rest,\n isDisabled: disableRipple || isDisabled,\n })\n\n const css: CSSUIObject = {\n position: \"relative\",\n overflow: \"hidden\",\n outline: 0,\n display: \"flex\",\n justifyContent: \"center\",\n alignItems: \"center\",\n flexShrink: 0,\n ...styles,\n ...__css,\n ...(isRounded ? { borderRadius: \"fallback(full, 9999px)\" } : {}),\n }\n\n return (\n <ui.button\n ref={ref}\n type=\"button\"\n aria-label=\"Close\"\n className={cx(\"ui-close-button\", className)}\n disabled={isDisabled}\n __css={css}\n {...rest}\n onPointerDown={onPointerDown}\n >\n {children || <CloseIcon width=\"1em\" height=\"1em\" />}\n\n <Ripple isDisabled={disableRipple || isDisabled} {...rippleProps} />\n </ui.button>\n )\n },\n)\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AACA,kBAKO;AACP,kBAA0B;AAC1B,oBAAkC;AAClC,mBAAmB;AAiEb;AA/BC,IAAM,kBAAc;AAAA,EACzB,CAAC,OAAO,QAAQ;AACd,UAAM,CAAC,QAAQ,WAAW,QAAI,+BAAkB,eAAe,KAAK;AACpE,UAAM;AAAA,MACJ;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA,GAAG;AAAA,IACL,QAAI,4BAAe,WAAW;AAC9B,UAAM,EAAE,eAAe,GAAG,YAAY,QAAI,yBAAU;AAAA,MAClD,GAAG;AAAA,MACH,YAAY,iBAAiB;AAAA,IAC/B,CAAC;AAED,UAAM,MAAmB;AAAA,MACvB,UAAU;AAAA,MACV,UAAU;AAAA,MACV,SAAS;AAAA,MACT,SAAS;AAAA,MACT,gBAAgB;AAAA,MAChB,YAAY;AAAA,MACZ,YAAY;AAAA,MACZ,GAAG;AAAA,MACH,GAAG;AAAA,MACH,GAAI,YAAY,EAAE,cAAc,yBAAyB,IAAI,CAAC;AAAA,IAChE;AAEA,WACE;AAAA,MAAC,eAAG;AAAA,MAAH;AAAA,QACC;AAAA,QACA,MAAK;AAAA,QACL,cAAW;AAAA,QACX,eAAW,iBAAG,mBAAmB,SAAS;AAAA,QAC1C,UAAU;AAAA,QACV,OAAO;AAAA,QACN,GAAG;AAAA,QACJ;AAAA,QAEC;AAAA,sBAAY,4CAAC,yBAAU,OAAM,OAAM,QAAO,OAAM;AAAA,UAEjD,4CAAC,wBAAO,YAAY,iBAAiB,YAAa,GAAG,aAAa;AAAA;AAAA;AAAA,IACpE;AAAA,EAEJ;AACF;","names":[]}
|
package/dist/close-button.mjs
CHANGED
package/dist/index.js.map
CHANGED
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"sources":["../src/index.ts","../src/close-button.tsx"],"sourcesContent":["export { CloseButton } from \"./close-button\"\nexport type { CloseButtonProps } from \"./close-button\"\n","import type { HTMLUIProps, ThemeProps, CSSUIObject } from \"@yamada-ui/core\"\nimport {\n ui,\n forwardRef,\n useComponentStyle,\n omitThemeProps,\n} from \"@yamada-ui/core\"\nimport { CloseIcon } from \"@yamada-ui/icon\"\nimport { Ripple, useRipple } from \"@yamada-ui/ripple\"\nimport { cx } from \"@yamada-ui/utils\"\n\
|
1
|
+
{"version":3,"sources":["../src/index.ts","../src/close-button.tsx"],"sourcesContent":["export { CloseButton } from \"./close-button\"\nexport type { CloseButtonProps } from \"./close-button\"\n","import type { HTMLUIProps, ThemeProps, CSSUIObject } from \"@yamada-ui/core\"\nimport {\n ui,\n forwardRef,\n useComponentStyle,\n omitThemeProps,\n} from \"@yamada-ui/core\"\nimport { CloseIcon } from \"@yamada-ui/icon\"\nimport { Ripple, useRipple } from \"@yamada-ui/ripple\"\nimport { cx } from \"@yamada-ui/utils\"\n\ninterface CloseButtonOptions {\n /**\n * If `true`, the button is disabled.\n *\n * @default false\n */\n isDisabled?: boolean\n /**\n * If `true`, disable ripple effects when pressing a element.\n *\n * @default false\n */\n disableRipple?: boolean\n /**\n * If true, the button is full rounded.\n *\n * @default false\n */\n isRounded?: boolean\n}\n\nexport interface CloseButtonProps\n extends HTMLUIProps<\"button\">,\n ThemeProps<\"CloseButton\">,\n CloseButtonOptions {}\n\n/**\n * `CloseButton` is a component used primarily to trigger the close functionality of a component.\n *\n * @see Docs https://yamada-ui.com/components/other/close-button\n */\n\nexport const CloseButton = forwardRef<CloseButtonProps, \"button\">(\n (props, ref) => {\n const [styles, mergedProps] = useComponentStyle(\"CloseButton\", props)\n const {\n className,\n children,\n isDisabled,\n isRounded,\n __css,\n disableRipple,\n ...rest\n } = omitThemeProps(mergedProps)\n const { onPointerDown, ...rippleProps } = useRipple({\n ...rest,\n isDisabled: disableRipple || isDisabled,\n })\n\n const css: CSSUIObject = {\n position: \"relative\",\n overflow: \"hidden\",\n outline: 0,\n display: \"flex\",\n justifyContent: \"center\",\n alignItems: \"center\",\n flexShrink: 0,\n ...styles,\n ...__css,\n ...(isRounded ? { borderRadius: \"fallback(full, 9999px)\" } : {}),\n }\n\n return (\n <ui.button\n ref={ref}\n type=\"button\"\n aria-label=\"Close\"\n className={cx(\"ui-close-button\", className)}\n disabled={isDisabled}\n __css={css}\n {...rest}\n onPointerDown={onPointerDown}\n >\n {children || <CloseIcon width=\"1em\" height=\"1em\" />}\n\n <Ripple isDisabled={disableRipple || isDisabled} {...rippleProps} />\n </ui.button>\n )\n },\n)\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;;;ACCA,kBAKO;AACP,kBAA0B;AAC1B,oBAAkC;AAClC,mBAAmB;AAiEb;AA/BC,IAAM,kBAAc;AAAA,EACzB,CAAC,OAAO,QAAQ;AACd,UAAM,CAAC,QAAQ,WAAW,QAAI,+BAAkB,eAAe,KAAK;AACpE,UAAM;AAAA,MACJ;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA,GAAG;AAAA,IACL,QAAI,4BAAe,WAAW;AAC9B,UAAM,EAAE,eAAe,GAAG,YAAY,QAAI,yBAAU;AAAA,MAClD,GAAG;AAAA,MACH,YAAY,iBAAiB;AAAA,IAC/B,CAAC;AAED,UAAM,MAAmB;AAAA,MACvB,UAAU;AAAA,MACV,UAAU;AAAA,MACV,SAAS;AAAA,MACT,SAAS;AAAA,MACT,gBAAgB;AAAA,MAChB,YAAY;AAAA,MACZ,YAAY;AAAA,MACZ,GAAG;AAAA,MACH,GAAG;AAAA,MACH,GAAI,YAAY,EAAE,cAAc,yBAAyB,IAAI,CAAC;AAAA,IAChE;AAEA,WACE;AAAA,MAAC,eAAG;AAAA,MAAH;AAAA,QACC;AAAA,QACA,MAAK;AAAA,QACL,cAAW;AAAA,QACX,eAAW,iBAAG,mBAAmB,SAAS;AAAA,QAC1C,UAAU;AAAA,QACV,OAAO;AAAA,QACN,GAAG;AAAA,QACJ;AAAA,QAEC;AAAA,sBAAY,4CAAC,yBAAU,OAAM,OAAM,QAAO,OAAM;AAAA,UAEjD,4CAAC,wBAAO,YAAY,iBAAiB,YAAa,GAAG,aAAa;AAAA;AAAA;AAAA,IACpE;AAAA,EAEJ;AACF;","names":[]}
|
package/dist/index.mjs
CHANGED
package/package.json
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
{
|
2
2
|
"name": "@yamada-ui/close-button",
|
3
|
-
"version": "1.0.40-dev-
|
3
|
+
"version": "1.0.40-dev-20240917033401",
|
4
4
|
"description": "Yamada UI close button component",
|
5
5
|
"keywords": [
|
6
6
|
"yamada",
|
@@ -36,10 +36,10 @@
|
|
36
36
|
"url": "https://github.com/yamada-ui/yamada-ui/issues"
|
37
37
|
},
|
38
38
|
"dependencies": {
|
39
|
-
"@yamada-ui/core": "1.14.1-dev-
|
40
|
-
"@yamada-ui/icon": "1.1.6-dev-
|
41
|
-
"@yamada-ui/ripple": "1.0.38-dev-
|
42
|
-
"@yamada-ui/utils": "1.5.
|
39
|
+
"@yamada-ui/core": "1.14.1-dev-20240917033401",
|
40
|
+
"@yamada-ui/icon": "1.1.6-dev-20240917033401",
|
41
|
+
"@yamada-ui/ripple": "1.0.38-dev-20240917033401",
|
42
|
+
"@yamada-ui/utils": "1.5.1-dev-20240917033401"
|
43
43
|
},
|
44
44
|
"devDependencies": {
|
45
45
|
"clean-package": "2.2.0",
|
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"sources":["../src/close-button.tsx"],"sourcesContent":["import type { HTMLUIProps, ThemeProps, CSSUIObject } from \"@yamada-ui/core\"\nimport {\n ui,\n forwardRef,\n useComponentStyle,\n omitThemeProps,\n} from \"@yamada-ui/core\"\nimport { CloseIcon } from \"@yamada-ui/icon\"\nimport { Ripple, useRipple } from \"@yamada-ui/ripple\"\nimport { cx } from \"@yamada-ui/utils\"\n\ntype CloseButtonOptions = {\n /**\n * If `true`, the button is disabled.\n *\n * @default false\n */\n isDisabled?: boolean\n /**\n * If `true`, disable ripple effects when pressing a element.\n *\n * @default false\n */\n disableRipple?: boolean\n /**\n * If true, the button is full rounded.\n *\n * @default false\n */\n isRounded?: boolean\n}\n\nexport type CloseButtonProps = HTMLUIProps<\"button\"> &\n ThemeProps<\"CloseButton\"> &\n CloseButtonOptions\n\n/**\n * `CloseButton` is a component used primarily to trigger the close functionality of a component.\n *\n * @see Docs https://yamada-ui.com/components/other/close-button\n */\n\nexport const CloseButton = forwardRef<CloseButtonProps, \"button\">(\n (props, ref) => {\n const [styles, mergedProps] = useComponentStyle(\"CloseButton\", props)\n const {\n className,\n children,\n isDisabled,\n isRounded,\n __css,\n disableRipple,\n ...rest\n } = omitThemeProps(mergedProps)\n const { onPointerDown, ...rippleProps } = useRipple({\n ...rest,\n isDisabled: disableRipple || isDisabled,\n })\n\n const css: CSSUIObject = {\n position: \"relative\",\n overflow: \"hidden\",\n outline: 0,\n display: \"flex\",\n justifyContent: \"center\",\n alignItems: \"center\",\n flexShrink: 0,\n ...styles,\n ...__css,\n ...(isRounded ? { borderRadius: \"fallback(full, 9999px)\" } : {}),\n }\n\n return (\n <ui.button\n ref={ref}\n type=\"button\"\n aria-label=\"Close\"\n className={cx(\"ui-close-button\", className)}\n disabled={isDisabled}\n __css={css}\n {...rest}\n onPointerDown={onPointerDown}\n >\n {children || <CloseIcon width=\"1em\" height=\"1em\" />}\n\n <Ripple isDisabled={disableRipple || isDisabled} {...rippleProps} />\n </ui.button>\n )\n },\n)\n"],"mappings":";;;AACA;AAAA,EACE;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,OACK;AACP,SAAS,iBAAiB;AAC1B,SAAS,QAAQ,iBAAiB;AAClC,SAAS,UAAU;AAgEb,SAUe,KAVf;AA/BC,IAAM,cAAc;AAAA,EACzB,CAAC,OAAO,QAAQ;AACd,UAAM,CAAC,QAAQ,WAAW,IAAI,kBAAkB,eAAe,KAAK;AACpE,UAAM;AAAA,MACJ;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA,GAAG;AAAA,IACL,IAAI,eAAe,WAAW;AAC9B,UAAM,EAAE,eAAe,GAAG,YAAY,IAAI,UAAU;AAAA,MAClD,GAAG;AAAA,MACH,YAAY,iBAAiB;AAAA,IAC/B,CAAC;AAED,UAAM,MAAmB;AAAA,MACvB,UAAU;AAAA,MACV,UAAU;AAAA,MACV,SAAS;AAAA,MACT,SAAS;AAAA,MACT,gBAAgB;AAAA,MAChB,YAAY;AAAA,MACZ,YAAY;AAAA,MACZ,GAAG;AAAA,MACH,GAAG;AAAA,MACH,GAAI,YAAY,EAAE,cAAc,yBAAyB,IAAI,CAAC;AAAA,IAChE;AAEA,WACE;AAAA,MAAC,GAAG;AAAA,MAAH;AAAA,QACC;AAAA,QACA,MAAK;AAAA,QACL,cAAW;AAAA,QACX,WAAW,GAAG,mBAAmB,SAAS;AAAA,QAC1C,UAAU;AAAA,QACV,OAAO;AAAA,QACN,GAAG;AAAA,QACJ;AAAA,QAEC;AAAA,sBAAY,oBAAC,aAAU,OAAM,OAAM,QAAO,OAAM;AAAA,UAEjD,oBAAC,UAAO,YAAY,iBAAiB,YAAa,GAAG,aAAa;AAAA;AAAA;AAAA,IACpE;AAAA,EAEJ;AACF;","names":[]}
|