@freezecold/button-ds 1.0.1 → 1.0.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.cjs.js +1 -1
- package/dist/{style.css → index.css} +0 -1
- package/dist/index.esm.js +1 -1
- package/package.json +6 -2
package/dist/index.cjs.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
Object.defineProperty(exports,Symbol.toStringTag,{value:`Module`}),require("react");let e=require("react/jsx-runtime");var t=({children:t,variant:n=`primary`,size:r=`md`,disabled:i=!1,fullWidth:a=!1,loading:o=!1,onClick:s,type:c=`button`,...l})=>{let u=[`btn`,`btn--${n}`,`btn--${r}`,a&&`btn--full-width`,o&&`btn--loading`].filter(Boolean).join(` `);return(0,e.jsxs)(`button`,{type:c,className:u,disabled:i||o,onClick:s,...l,children:[o&&(0,e.jsx)(`span`,{className:`btn__spinner`}),(0,e.jsx)(`span`,{children:t})]})};exports.Button=t;
|
|
1
|
+
Object.defineProperty(exports,Symbol.toStringTag,{value:`Module`}),require("react");require('./index.css');let e=require("react/jsx-runtime");var t=({children:t,variant:n=`primary`,size:r=`md`,disabled:i=!1,fullWidth:a=!1,loading:o=!1,onClick:s,type:c=`button`,...l})=>{let u=[`btn`,`btn--${n}`,`btn--${r}`,a&&`btn--full-width`,o&&`btn--loading`].filter(Boolean).join(` `);return(0,e.jsxs)(`button`,{type:c,className:u,disabled:i||o,onClick:s,...l,children:[o&&(0,e.jsx)(`span`,{className:`btn__spinner`}),(0,e.jsx)(`span`,{children:t})]})};exports.Button=t;
|
|
@@ -1,2 +1 @@
|
|
|
1
1
|
:root{--color-primary-50:#eff6ff;--color-primary-100:#dbeafe;--color-primary-500:#3b82f6;--color-primary-600:#2563eb;--color-primary-700:#1d4ed8;--color-gray-100:#f3f4f6;--color-gray-200:#e5e7eb;--color-gray-300:#d1d5db;--color-gray-700:#374151;--color-gray-900:#111827;--radius-md:.375rem;--shadow-md:0 4px 6px -1px #0000001a}.btn{border-radius:var(--radius-md);cursor:pointer;border:none;justify-content:center;align-items:center;gap:.5rem;font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,sans-serif;font-weight:500;transition:all .2s;display:inline-flex}.btn:disabled{opacity:.5;cursor:not-allowed}.btn--full-width{width:100%}.btn--sm{padding:.5rem .75rem;font-size:.875rem}.btn--md{padding:.75rem 1rem;font-size:1rem}.btn--lg{padding:1rem 1.5rem;font-size:1.125rem}.btn--primary{background-color:var(--color-primary-600);color:#fff}.btn--primary:hover:not(:disabled){background-color:var(--color-primary-700);box-shadow:var(--shadow-md)}.btn--secondary{background-color:var(--color-gray-200);color:var(--color-gray-900)}.btn--secondary:hover:not(:disabled){background-color:var(--color-gray-300)}.btn--outline{color:var(--color-primary-600);border:1px solid var(--color-primary-600);background-color:#0000}.btn--outline:hover:not(:disabled){background-color:var(--color-primary-50)}.btn--ghost{color:var(--color-gray-700);background-color:#0000}.btn--ghost:hover:not(:disabled){background-color:var(--color-gray-100)}.btn__spinner{border:2px solid #0000;border-top-color:currentColor;border-radius:50%;width:1em;height:1em;animation:.6s linear infinite spin}@keyframes spin{to{transform:rotate(360deg)}}
|
|
2
|
-
/*$vite$:1*/
|
package/dist/index.esm.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import "react";
|
|
2
2
|
import { jsx as e, jsxs as t } from "react/jsx-runtime";
|
|
3
|
-
|
|
3
|
+
import './index.css';// src/components/Button/Button.jsx
|
|
4
4
|
var n = ({ children: n, variant: r = "primary", size: i = "md", disabled: a = !1, fullWidth: o = !1, loading: s = !1, onClick: c, type: l = "button", ...u }) => {
|
|
5
5
|
let d = [
|
|
6
6
|
"btn",
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@freezecold/button-ds",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.2",
|
|
4
4
|
"description": "A reusable Button component design system",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "./dist/index.cjs.js",
|
|
@@ -48,6 +48,10 @@
|
|
|
48
48
|
"globals": "^17.13.0",
|
|
49
49
|
"react": "^19.3.1",
|
|
50
50
|
"react-dom": "^19.3.1",
|
|
51
|
-
"vite": "^8.3.6"
|
|
51
|
+
"vite": "^8.3.6",
|
|
52
|
+
"vite-plugin-lib-inject-css": "^2.2.2"
|
|
53
|
+
},
|
|
54
|
+
"dependencies": {
|
|
55
|
+
"@freezecold/button-ds": "^1.0.0"
|
|
52
56
|
}
|
|
53
57
|
}
|