@citizenplane/pimp 18.19.2 → 18.19.3
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.
|
@@ -9,15 +9,19 @@ export interface Props {
|
|
|
9
9
|
tag?: 'a' | 'button' | 'label';
|
|
10
10
|
type?: 'button' | 'submit' | 'reset';
|
|
11
11
|
}
|
|
12
|
-
declare var
|
|
12
|
+
declare var __VLS_15: {}, __VLS_17: {}, __VLS_19: {};
|
|
13
13
|
type __VLS_Slots = {} & {
|
|
14
|
-
'leading-icon'?: (props: typeof
|
|
14
|
+
'leading-icon'?: (props: typeof __VLS_15) => any;
|
|
15
15
|
} & {
|
|
16
|
-
default?: (props: typeof
|
|
16
|
+
default?: (props: typeof __VLS_17) => any;
|
|
17
17
|
} & {
|
|
18
|
-
'trailing-icon'?: (props: typeof
|
|
18
|
+
'trailing-icon'?: (props: typeof __VLS_19) => any;
|
|
19
19
|
};
|
|
20
|
-
declare const __VLS_base: import('vue').DefineComponent<Props, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {
|
|
20
|
+
declare const __VLS_base: import('vue').DefineComponent<Props, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {
|
|
21
|
+
click: (event: MouseEvent) => any;
|
|
22
|
+
}, string, import('vue').PublicProps, Readonly<Props> & Readonly<{
|
|
23
|
+
onClick?: ((event: MouseEvent) => any) | undefined;
|
|
24
|
+
}>, {
|
|
21
25
|
size: "2xs" | "xs" | "sm" | "md" | "lg";
|
|
22
26
|
tag: "a" | "button" | "label";
|
|
23
27
|
type: "button" | "submit" | "reset";
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"CpButton.vue.d.ts","sourceRoot":"","sources":["../../src/components/CpButton.vue"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"CpButton.vue.d.ts","sourceRoot":"","sources":["../../src/components/CpButton.vue"],"names":[],"mappings":"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AS,eAAe,CAAC,OAAO,UAAU,EAAE,WAAW,CAAC,CAAC;wBACtD,OAAO,YAAY;AAAxC,wBAAyC;AAWzC,KAAK,eAAe,CAAC,CAAC,EAAE,CAAC,IAAI,CAAC,GAAG;IAChC,QAAO;QACN,MAAM,EAAE,CAAC,CAAC;KACV,CAAA;CACD,CAAC"}
|
package/dist/pimp.es.js
CHANGED
|
@@ -25109,32 +25109,36 @@ var DA = (e, t) => ({
|
|
|
25109
25109
|
tag: { default: "button" },
|
|
25110
25110
|
type: { default: "button" }
|
|
25111
25111
|
},
|
|
25112
|
-
|
|
25113
|
-
|
|
25114
|
-
|
|
25115
|
-
|
|
25112
|
+
emits: ["click"],
|
|
25113
|
+
setup(e, { emit: t }) {
|
|
25114
|
+
let n = e, r = t, i = fe(), o = a(() => $E(n.appearance)), d = a(() => $E(n.color)), f = a(() => !!i.default), p = a(() => !!i["leading-icon"]), h = a(() => !!i["trailing-icon"]), g = a(() => n.disabled || n.isLoading), _ = a(() => n.tag === "a" ? n.href : void 0), v = (e) => {
|
|
25115
|
+
g.value || r("click", e);
|
|
25116
|
+
}, y = a(() => [
|
|
25117
|
+
`cpButton--is${o.value}`,
|
|
25118
|
+
`cpButton--${n.size}`,
|
|
25116
25119
|
{
|
|
25117
|
-
[`cpButton--is${
|
|
25118
|
-
"cpButton--isDisabled":
|
|
25119
|
-
"cpButton--isIcon": !
|
|
25120
|
-
"cpButton--isLoading":
|
|
25121
|
-
"cpButton--isSquare":
|
|
25120
|
+
[`cpButton--is${d.value}`]: !!d.value,
|
|
25121
|
+
"cpButton--isDisabled": g.value,
|
|
25122
|
+
"cpButton--isIcon": !f.value,
|
|
25123
|
+
"cpButton--isLoading": n.isLoading,
|
|
25124
|
+
"cpButton--isSquare": n.isSquare
|
|
25122
25125
|
}
|
|
25123
25126
|
]);
|
|
25124
25127
|
return (t, n) => (M(), s(oe(e.tag), {
|
|
25125
|
-
"aria-disabled":
|
|
25126
|
-
class: T(["cpButton",
|
|
25127
|
-
disabled:
|
|
25128
|
-
href:
|
|
25128
|
+
"aria-disabled": g.value,
|
|
25129
|
+
class: T(["cpButton", y.value]),
|
|
25130
|
+
disabled: g.value,
|
|
25131
|
+
href: _.value,
|
|
25129
25132
|
role: "button",
|
|
25130
25133
|
tabindex: "0",
|
|
25131
|
-
type: e.type
|
|
25134
|
+
type: e.type,
|
|
25135
|
+
onClick: v
|
|
25132
25136
|
}, {
|
|
25133
25137
|
default: V(() => [u("span", UA, [
|
|
25134
25138
|
e.isLoading ? (M(), l("span", WA, [m(HA, { color: "neutral" })])) : c("", !0),
|
|
25135
|
-
|
|
25136
|
-
|
|
25137
|
-
|
|
25139
|
+
p.value ? (M(), l("span", GA, [F(t.$slots, "leading-icon")])) : c("", !0),
|
|
25140
|
+
f.value ? (M(), l("span", KA, [F(t.$slots, "default")])) : c("", !0),
|
|
25141
|
+
h.value ? (M(), l("span", qA, [F(t.$slots, "trailing-icon")])) : c("", !0)
|
|
25138
25142
|
])]),
|
|
25139
25143
|
_: 3
|
|
25140
25144
|
}, 8, [
|