@fede.bebot/ui-library 0.1.1 → 0.1.2
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/dist/index.d.mts +7 -1
- package/dist/index.d.ts +7 -1
- package/dist/index.js +19 -2
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +17 -1
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
package/dist/index.d.mts
CHANGED
|
@@ -5,4 +5,10 @@ interface ButtonProps extends React.ButtonHTMLAttributes<HTMLButtonElement> {
|
|
|
5
5
|
}
|
|
6
6
|
declare const Button: ({ variant, children, ...props }: ButtonProps) => react_jsx_runtime.JSX.Element;
|
|
7
7
|
|
|
8
|
-
|
|
8
|
+
interface ButtonLinkProps extends React.AnchorHTMLAttributes<HTMLAnchorElement> {
|
|
9
|
+
variant?: "primary" | "secondary";
|
|
10
|
+
href: string;
|
|
11
|
+
}
|
|
12
|
+
declare const ButtonLink: ({ variant, href, children, ...props }: ButtonLinkProps) => react_jsx_runtime.JSX.Element;
|
|
13
|
+
|
|
14
|
+
export { Button, ButtonLink, type ButtonLinkProps, type ButtonProps };
|
package/dist/index.d.ts
CHANGED
|
@@ -5,4 +5,10 @@ interface ButtonProps extends React.ButtonHTMLAttributes<HTMLButtonElement> {
|
|
|
5
5
|
}
|
|
6
6
|
declare const Button: ({ variant, children, ...props }: ButtonProps) => react_jsx_runtime.JSX.Element;
|
|
7
7
|
|
|
8
|
-
|
|
8
|
+
interface ButtonLinkProps extends React.AnchorHTMLAttributes<HTMLAnchorElement> {
|
|
9
|
+
variant?: "primary" | "secondary";
|
|
10
|
+
href: string;
|
|
11
|
+
}
|
|
12
|
+
declare const ButtonLink: ({ variant, href, children, ...props }: ButtonLinkProps) => react_jsx_runtime.JSX.Element;
|
|
13
|
+
|
|
14
|
+
export { Button, ButtonLink, type ButtonLinkProps, type ButtonProps };
|
package/dist/index.js
CHANGED
|
@@ -49,7 +49,8 @@ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: tru
|
|
|
49
49
|
// src/index.ts
|
|
50
50
|
var index_exports = {};
|
|
51
51
|
__export(index_exports, {
|
|
52
|
-
Button: () => Button
|
|
52
|
+
Button: () => Button,
|
|
53
|
+
ButtonLink: () => ButtonLink
|
|
53
54
|
});
|
|
54
55
|
module.exports = __toCommonJS(index_exports);
|
|
55
56
|
|
|
@@ -65,8 +66,24 @@ var Button = (_a) => {
|
|
|
65
66
|
]);
|
|
66
67
|
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)("button", __spreadProps(__spreadValues({ "data-variant": variant }, props), { children }));
|
|
67
68
|
};
|
|
69
|
+
|
|
70
|
+
// src/components/buttonLink/ButtonLink.tsx
|
|
71
|
+
var import_jsx_runtime2 = require("react/jsx-runtime");
|
|
72
|
+
var ButtonLink = (_a) => {
|
|
73
|
+
var _b = _a, {
|
|
74
|
+
variant = "primary",
|
|
75
|
+
href,
|
|
76
|
+
children
|
|
77
|
+
} = _b, props = __objRest(_b, [
|
|
78
|
+
"variant",
|
|
79
|
+
"href",
|
|
80
|
+
"children"
|
|
81
|
+
]);
|
|
82
|
+
return /* @__PURE__ */ (0, import_jsx_runtime2.jsx)("a", __spreadProps(__spreadValues({ href, "data-variant": variant }, props), { children }));
|
|
83
|
+
};
|
|
68
84
|
// Annotate the CommonJS export names for ESM import in node:
|
|
69
85
|
0 && (module.exports = {
|
|
70
|
-
Button
|
|
86
|
+
Button,
|
|
87
|
+
ButtonLink
|
|
71
88
|
});
|
|
72
89
|
//# sourceMappingURL=index.js.map
|
package/dist/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../src/index.ts","../src/components/Button/Button.tsx"],"sourcesContent":["export { Button } from \"./components/Button/Button\";\r\nexport type { ButtonProps } from \"./components/Button/Button\";\r\n","export interface ButtonProps extends React.ButtonHTMLAttributes<HTMLButtonElement> {\r\n variant?: \"primary\" | \"secondary\";\r\n}\r\n\r\nexport const Button = ({\r\n variant = \"primary\",\r\n children,\r\n ...props\r\n}: ButtonProps) => {\r\n return (\r\n <button data-variant={variant} {...props}>\r\n {children}\r\n </button>\r\n );\r\n};\r\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;;;ACUI;AANG,IAAM,SAAS,CAAC,OAIJ;AAJI,eACrB;AAAA,cAAU;AAAA,IACV;AAAA,EANF,IAIuB,IAGlB,kBAHkB,IAGlB;AAAA,IAFH;AAAA,IACA;AAAA;AAGA,SACE,4CAAC,yCAAO,gBAAc,WAAa,QAAlC,EACE,WACH;AAEJ;","names":[]}
|
|
1
|
+
{"version":3,"sources":["../src/index.ts","../src/components/Button/Button.tsx","../src/components/buttonLink/ButtonLink.tsx"],"sourcesContent":["export { Button } from \"./components/Button/Button\";\r\nexport type { ButtonProps } from \"./components/Button/Button\";\r\n\r\nexport { ButtonLink } from \"./components/buttonLink/ButtonLink\";\r\nexport type { ButtonLinkProps } from \"./components/buttonLink/ButtonLink\";\r\n","export interface ButtonProps extends React.ButtonHTMLAttributes<HTMLButtonElement> {\r\n variant?: \"primary\" | \"secondary\";\r\n}\r\n\r\nexport const Button = ({\r\n variant = \"primary\",\r\n children,\r\n ...props\r\n}: ButtonProps) => {\r\n return (\r\n <button data-variant={variant} {...props}>\r\n {children}\r\n </button>\r\n );\r\n};\r\n","export interface ButtonLinkProps extends React.AnchorHTMLAttributes<HTMLAnchorElement> {\r\n variant?: \"primary\" | \"secondary\";\r\n href: string;\r\n}\r\n\r\nexport const ButtonLink = ({\r\n variant = \"primary\",\r\n href,\r\n children,\r\n ...props\r\n}: ButtonLinkProps) => {\r\n return (\r\n <a href={href} data-variant={variant} {...props}>\r\n {children}\r\n </a>\r\n );\r\n};\r\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;;;ACUI;AANG,IAAM,SAAS,CAAC,OAIJ;AAJI,eACrB;AAAA,cAAU;AAAA,IACV;AAAA,EANF,IAIuB,IAGlB,kBAHkB,IAGlB;AAAA,IAFH;AAAA,IACA;AAAA;AAGA,SACE,4CAAC,yCAAO,gBAAc,WAAa,QAAlC,EACE,WACH;AAEJ;;;ACFI,IAAAA,sBAAA;AAPG,IAAM,aAAa,CAAC,OAKJ;AALI,eACzB;AAAA,cAAU;AAAA,IACV;AAAA,IACA;AAAA,EARF,IAK2B,IAItB,kBAJsB,IAItB;AAAA,IAHH;AAAA,IACA;AAAA,IACA;AAAA;AAGA,SACE,6CAAC,oCAAE,MAAY,gBAAc,WAAa,QAAzC,EACE,WACH;AAEJ;","names":["import_jsx_runtime"]}
|
package/dist/index.mjs
CHANGED
|
@@ -42,7 +42,23 @@ var Button = (_a) => {
|
|
|
42
42
|
]);
|
|
43
43
|
return /* @__PURE__ */ jsx("button", __spreadProps(__spreadValues({ "data-variant": variant }, props), { children }));
|
|
44
44
|
};
|
|
45
|
+
|
|
46
|
+
// src/components/buttonLink/ButtonLink.tsx
|
|
47
|
+
import { jsx as jsx2 } from "react/jsx-runtime";
|
|
48
|
+
var ButtonLink = (_a) => {
|
|
49
|
+
var _b = _a, {
|
|
50
|
+
variant = "primary",
|
|
51
|
+
href,
|
|
52
|
+
children
|
|
53
|
+
} = _b, props = __objRest(_b, [
|
|
54
|
+
"variant",
|
|
55
|
+
"href",
|
|
56
|
+
"children"
|
|
57
|
+
]);
|
|
58
|
+
return /* @__PURE__ */ jsx2("a", __spreadProps(__spreadValues({ href, "data-variant": variant }, props), { children }));
|
|
59
|
+
};
|
|
45
60
|
export {
|
|
46
|
-
Button
|
|
61
|
+
Button,
|
|
62
|
+
ButtonLink
|
|
47
63
|
};
|
|
48
64
|
//# sourceMappingURL=index.mjs.map
|
package/dist/index.mjs.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../src/components/Button/Button.tsx"],"sourcesContent":["export interface ButtonProps extends React.ButtonHTMLAttributes<HTMLButtonElement> {\r\n variant?: \"primary\" | \"secondary\";\r\n}\r\n\r\nexport const Button = ({\r\n variant = \"primary\",\r\n children,\r\n ...props\r\n}: ButtonProps) => {\r\n return (\r\n <button data-variant={variant} {...props}>\r\n {children}\r\n </button>\r\n );\r\n};\r\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAUI;AANG,IAAM,SAAS,CAAC,OAIJ;AAJI,eACrB;AAAA,cAAU;AAAA,IACV;AAAA,EANF,IAIuB,IAGlB,kBAHkB,IAGlB;AAAA,IAFH;AAAA,IACA;AAAA;AAGA,SACE,oBAAC,yCAAO,gBAAc,WAAa,QAAlC,EACE,WACH;AAEJ;","names":[]}
|
|
1
|
+
{"version":3,"sources":["../src/components/Button/Button.tsx","../src/components/buttonLink/ButtonLink.tsx"],"sourcesContent":["export interface ButtonProps extends React.ButtonHTMLAttributes<HTMLButtonElement> {\r\n variant?: \"primary\" | \"secondary\";\r\n}\r\n\r\nexport const Button = ({\r\n variant = \"primary\",\r\n children,\r\n ...props\r\n}: ButtonProps) => {\r\n return (\r\n <button data-variant={variant} {...props}>\r\n {children}\r\n </button>\r\n );\r\n};\r\n","export interface ButtonLinkProps extends React.AnchorHTMLAttributes<HTMLAnchorElement> {\r\n variant?: \"primary\" | \"secondary\";\r\n href: string;\r\n}\r\n\r\nexport const ButtonLink = ({\r\n variant = \"primary\",\r\n href,\r\n children,\r\n ...props\r\n}: ButtonLinkProps) => {\r\n return (\r\n <a href={href} data-variant={variant} {...props}>\r\n {children}\r\n </a>\r\n );\r\n};\r\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAUI;AANG,IAAM,SAAS,CAAC,OAIJ;AAJI,eACrB;AAAA,cAAU;AAAA,IACV;AAAA,EANF,IAIuB,IAGlB,kBAHkB,IAGlB;AAAA,IAFH;AAAA,IACA;AAAA;AAGA,SACE,oBAAC,yCAAO,gBAAc,WAAa,QAAlC,EACE,WACH;AAEJ;;;ACFI,gBAAAA,YAAA;AAPG,IAAM,aAAa,CAAC,OAKJ;AALI,eACzB;AAAA,cAAU;AAAA,IACV;AAAA,IACA;AAAA,EARF,IAK2B,IAItB,kBAJsB,IAItB;AAAA,IAHH;AAAA,IACA;AAAA,IACA;AAAA;AAGA,SACE,gBAAAA,KAAC,oCAAE,MAAY,gBAAc,WAAa,QAAzC,EACE,WACH;AAEJ;","names":["jsx"]}
|