@pequity/squirrel 8.6.0 → 10.0.0
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/README.md +1 -1
- package/dist/cjs/chunks/p-btn.js +14 -7
- package/dist/cjs/chunks/p-icon.js +1 -2058
- package/dist/cjs/number.js +3 -2
- package/dist/es/chunks/p-btn.js +14 -7
- package/dist/es/chunks/p-icon.js +1 -2058
- package/dist/es/number.js +3 -2
- package/dist/squirrel/components/p-btn/p-btn.vue.d.ts +51 -21
- package/package.json +21 -20
- package/squirrel/components/p-action-bar/p-action-bar.spec.ts +2 -2
- package/squirrel/components/p-btn/p-btn.spec.js +60 -10
- package/squirrel/components/p-btn/p-btn.stories.js +79 -16
- package/squirrel/components/p-btn/p-btn.vue +15 -7
- package/squirrel/utils/number.spec.js +13 -3
- package/squirrel/utils/number.ts +5 -2
package/README.md
CHANGED
|
@@ -10,7 +10,7 @@ The library is built using [Vue 3](https://vuejs.org/) and [Tailwind CSS](https:
|
|
|
10
10
|
Install the package and its dependencies using `pnpm`:
|
|
11
11
|
|
|
12
12
|
```bash
|
|
13
|
-
pnpm i vue vue-router @pequity/squirrel @tanstack/vue-virtual @vuepic/vue-datepicker floating-vue lodash-es vue-currency-input vue-toastification@2.0.0-rc.5
|
|
13
|
+
pnpm i vue vue-router @pequity/squirrel @tanstack/vue-virtual @vuepic/vue-datepicker floating-vue iconify-icon lodash-es vue-currency-input vue-toastification@2.0.0-rc.5
|
|
14
14
|
```
|
|
15
15
|
|
|
16
16
|
Install Tailwind CSS:
|
package/dist/cjs/chunks/p-btn.js
CHANGED
|
@@ -9,7 +9,7 @@ const index = require("./index.js");
|
|
|
9
9
|
const _hoisted_1 = { class: "slot-wrapper empty:hidden" };
|
|
10
10
|
const btnClasses = {
|
|
11
11
|
slots: {
|
|
12
|
-
button: "relative inline-
|
|
12
|
+
button: "relative inline-flex whitespace-nowrap rounded font-medium outline-none disabled:pointer-events-none disabled:cursor-default disabled:opacity-50 aria-disabled:pointer-events-none aria-disabled:cursor-default aria-disabled:opacity-50",
|
|
13
13
|
content: "flex items-center justify-center has-[.slot-wrapper:empty]:gap-0",
|
|
14
14
|
loader: "absolute bottom-0 left-0 right-0 top-0 flex items-center justify-center font-medium",
|
|
15
15
|
icon: "shrink-0"
|
|
@@ -42,24 +42,31 @@ const btnClasses = {
|
|
|
42
42
|
loader: "text-p-red-50"
|
|
43
43
|
},
|
|
44
44
|
success: { button: "bg-p-green-40 text-white hover:bg-p-green-50", loader: "text-white" },
|
|
45
|
+
black: { button: "bg-night text-white hover:bg-p-gray-80", loader: "text-white" },
|
|
46
|
+
"black-outline-gradient": {
|
|
47
|
+
button: "bg-gradient-to-r from-[#17c0e8] via-[#8e8bda] to-[#f65ece] hover:bg-gradient-to-l p-px group",
|
|
48
|
+
content: "bg-night rounded-[calc(theme(borderRadius.DEFAULT)-1px)] text-white group-hover:bg-p-gray-80 transition-colors duration-300",
|
|
49
|
+
icon: "-mx-px",
|
|
50
|
+
loader: "text-white"
|
|
51
|
+
},
|
|
45
52
|
"primary-link": { button: "bg-transparent text-primary underline hover:text-accent", loader: "text-p-blue-60" },
|
|
46
53
|
"secondary-ghost": { button: "text-on-surface hover:bg-p-gray-20", loader: "text-p-purple-60" },
|
|
47
54
|
"secondary-ghost-dark": { button: "text-white hover:bg-p-purple-50", loader: "text-p-blue-15" }
|
|
48
55
|
},
|
|
49
56
|
size: {
|
|
50
57
|
sm: {
|
|
51
|
-
button: "
|
|
52
|
-
content: "gap-1",
|
|
58
|
+
button: "text-sm leading-5 h-8",
|
|
59
|
+
content: "px-3 has-[.slot-wrapper:empty]:px-1.5 py-1.5 gap-1",
|
|
53
60
|
icon: "text-base p-0.5"
|
|
54
61
|
},
|
|
55
62
|
md: {
|
|
56
|
-
button: "
|
|
57
|
-
content: "gap-2",
|
|
63
|
+
button: "text-base h-10",
|
|
64
|
+
content: "px-6 has-[.slot-wrapper:empty]:px-2.5 has-[.slot-wrapper:empty]:py-2.5 py-2 gap-2",
|
|
58
65
|
icon: "text-xl"
|
|
59
66
|
},
|
|
60
67
|
lg: {
|
|
61
|
-
button: "
|
|
62
|
-
content: "gap-2.5",
|
|
68
|
+
button: "text-lg leading-6 h-12",
|
|
69
|
+
content: "px-6 has-[.slot-wrapper:empty]:px-3 py-3 gap-2.5",
|
|
63
70
|
icon: "text-2xl"
|
|
64
71
|
}
|
|
65
72
|
}
|