@topjoao/top-design-system 0.1.0-beta.0 → 0.1.0-beta.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/README.md +86 -22
- package/dist/TopButton-9IIdtUbJ.js +81 -0
- package/dist/TopButton-9IIdtUbJ.js.map +1 -0
- package/dist/TopButton-CDKgguLF.cjs +2 -0
- package/dist/TopButton-CDKgguLF.cjs.map +1 -0
- package/dist/components/TopButton.vue.d.ts +2 -0
- package/dist/index.cjs +1 -1
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.ts +1 -4
- package/dist/index.js +5 -77
- package/dist/index.js.map +1 -1
- package/dist/nuxt.cjs +2 -0
- package/dist/nuxt.cjs.map +1 -0
- package/dist/nuxt.d.ts +2 -0
- package/dist/nuxt.js +20 -0
- package/dist/nuxt.js.map +1 -0
- package/dist/plugin.cjs +2 -0
- package/dist/plugin.cjs.map +1 -0
- package/dist/plugin.d.ts +8 -0
- package/dist/plugin.js +9 -0
- package/dist/plugin.js.map +1 -0
- package/dist/style.css +1 -1
- package/package.json +18 -1
package/README.md
CHANGED
|
@@ -1,38 +1,49 @@
|
|
|
1
1
|
# TopSolutions Design System
|
|
2
2
|
|
|
3
|
-
Biblioteca
|
|
3
|
+
Biblioteca de componentes Vue 3, estilos e tokens visuais compartilhados pela
|
|
4
4
|
TopSolutions.
|
|
5
5
|
|
|
6
|
-
##
|
|
6
|
+
## Instalação
|
|
7
7
|
|
|
8
8
|
```bash
|
|
9
|
-
npm install
|
|
10
|
-
npm run check
|
|
9
|
+
npm install @topjoao/top-design-system@beta
|
|
11
10
|
```
|
|
12
11
|
|
|
13
|
-
|
|
12
|
+
A aplicação consumidora deve possuir Vue 3, PrimeVue, PrimeIcons e
|
|
13
|
+
`@primeuix/themes` em versões compatíveis com as `peerDependencies` do pacote.
|
|
14
14
|
|
|
15
|
-
|
|
15
|
+
## Uso com Nuxt
|
|
16
16
|
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
17
|
+
Adicione o módulo uma única vez ao `nuxt.config.ts`:
|
|
18
|
+
|
|
19
|
+
```ts
|
|
20
|
+
export default defineNuxtConfig({
|
|
21
|
+
modules: [
|
|
22
|
+
// outros módulos...
|
|
23
|
+
'@topjoao/top-design-system/nuxt',
|
|
24
|
+
],
|
|
25
|
+
})
|
|
20
26
|
```
|
|
21
27
|
|
|
22
|
-
|
|
23
|
-
os
|
|
28
|
+
Depois de alterar a configuração, reinicie o servidor de desenvolvimento ou
|
|
29
|
+
regenere os arquivos do Nuxt:
|
|
24
30
|
|
|
25
|
-
```
|
|
26
|
-
|
|
27
|
-
import '@topjoao/top-design-system/style.css'
|
|
31
|
+
```bash
|
|
32
|
+
npm run postinstall
|
|
28
33
|
```
|
|
29
34
|
|
|
30
|
-
|
|
31
|
-
|
|
35
|
+
O módulo registra os componentes, gera suas tipagens e inclui o CSS da
|
|
36
|
+
biblioteca. Não é necessário importar o componente manualmente:
|
|
32
37
|
|
|
33
|
-
|
|
38
|
+
```vue
|
|
39
|
+
<template>
|
|
40
|
+
<TopButton label="Salvar" icon="pi pi-save" />
|
|
41
|
+
</template>
|
|
42
|
+
```
|
|
34
43
|
|
|
35
|
-
|
|
44
|
+
## Uso com Vue 3
|
|
45
|
+
|
|
46
|
+
### Importação por componente
|
|
36
47
|
|
|
37
48
|
```vue
|
|
38
49
|
<script setup lang="ts">
|
|
@@ -41,8 +52,33 @@ import '@topjoao/top-design-system/style.css'
|
|
|
41
52
|
</script>
|
|
42
53
|
|
|
43
54
|
<template>
|
|
44
|
-
<TopButton label="Salvar" icon="pi pi-save"
|
|
55
|
+
<TopButton label="Salvar" icon="pi pi-save" />
|
|
56
|
+
</template>
|
|
57
|
+
```
|
|
58
|
+
|
|
59
|
+
### Registro global
|
|
60
|
+
|
|
61
|
+
Na inicialização da aplicação:
|
|
62
|
+
|
|
63
|
+
```ts
|
|
64
|
+
import { createApp } from 'vue'
|
|
65
|
+
import { TopSolutionsDesignSystem } from '@topjoao/top-design-system/plugin'
|
|
66
|
+
import '@topjoao/top-design-system/style.css'
|
|
67
|
+
import App from './App.vue'
|
|
68
|
+
|
|
69
|
+
createApp(App).use(TopSolutionsDesignSystem).mount('#app')
|
|
70
|
+
```
|
|
71
|
+
|
|
72
|
+
Após o registro, os componentes podem ser utilizados sem importação manual. A
|
|
73
|
+
entrada `/plugin` também fornece as declarações globais usadas pela IDE.
|
|
45
74
|
|
|
75
|
+
## TopButton
|
|
76
|
+
|
|
77
|
+
Exemplo
|
|
78
|
+
|
|
79
|
+
```vue
|
|
80
|
+
<template>
|
|
81
|
+
<TopButton label="Salvar" icon="pi pi-save" @click="salvar" />
|
|
46
82
|
<TopButton label="Cancelar" secondary />
|
|
47
83
|
|
|
48
84
|
<TopButton label="Consultar" outlined>
|
|
@@ -53,11 +89,10 @@ import '@topjoao/top-design-system/style.css'
|
|
|
53
89
|
</template>
|
|
54
90
|
```
|
|
55
91
|
|
|
56
|
-
Props disponíveis:
|
|
57
|
-
|
|
58
92
|
| Prop | Tipo | Padrão |
|
|
59
93
|
|---|---|---|
|
|
60
94
|
| `tooltip` | `string` | `''` |
|
|
95
|
+
| `tooltipClass` | `string` | `'text-xs'` |
|
|
61
96
|
| `label` | `string` | `''` |
|
|
62
97
|
| `icon` | `string` | `''` |
|
|
63
98
|
| `loading` | `boolean` | `false` |
|
|
@@ -66,6 +101,35 @@ Props disponíveis:
|
|
|
66
101
|
| `secondary` | `boolean` | `false` |
|
|
67
102
|
| `disabled` | `boolean` | `false` |
|
|
68
103
|
| `unstyled` | `boolean` | `false` |
|
|
69
|
-
| `type` | `'button'
|
|
104
|
+
| `type` | `'button' \| 'submit' \| 'reset'` | `'button'` |
|
|
70
105
|
|
|
71
106
|
O componente emite `click` sem payload e oferece o slot nomeado `icon`.
|
|
107
|
+
|
|
108
|
+
## Desenvolvimento da biblioteca
|
|
109
|
+
|
|
110
|
+
```bash
|
|
111
|
+
npm install
|
|
112
|
+
npm run check
|
|
113
|
+
```
|
|
114
|
+
|
|
115
|
+
O comando `check` executa verificação de tipos, testes e build.
|
|
116
|
+
|
|
117
|
+
Para inspecionar o conteúdo que seria publicado:
|
|
118
|
+
|
|
119
|
+
```bash
|
|
120
|
+
npm pack --dry-run
|
|
121
|
+
```
|
|
122
|
+
|
|
123
|
+
Para gerar um pacote local instalável:
|
|
124
|
+
|
|
125
|
+
```bash
|
|
126
|
+
npm pack
|
|
127
|
+
```
|
|
128
|
+
|
|
129
|
+
Para publicar uma nova versão beta, primeiro altere a versão; versões já
|
|
130
|
+
publicadas no npm não podem ser sobrescritas.
|
|
131
|
+
|
|
132
|
+
```bash
|
|
133
|
+
npm version prerelease --preid=beta --no-git-tag-version
|
|
134
|
+
npm publish --access public --tag beta
|
|
135
|
+
```
|
|
@@ -0,0 +1,81 @@
|
|
|
1
|
+
import { computed as e, createBlock as t, createElementBlock as n, createSlots as r, defineComponent as i, normalizeClass as a, openBlock as o, renderSlot as s, unref as c, useSlots as l, withCtx as u, withDirectives as d } from "vue";
|
|
2
|
+
import f from "primevue/button";
|
|
3
|
+
import p from "primevue/tooltip";
|
|
4
|
+
import { twMerge as m } from "tailwind-merge";
|
|
5
|
+
//#region src/components/TopButton.vue?vue&type=script&setup=true&lang.ts
|
|
6
|
+
var h = { class: "h-fit w-fit rounded-[12px] bg-transparent" }, g = /* @__PURE__ */ i({
|
|
7
|
+
__name: "TopButton",
|
|
8
|
+
props: {
|
|
9
|
+
tooltip: { default: "" },
|
|
10
|
+
tooltipClass: { default: "text-xs" },
|
|
11
|
+
label: { default: "" },
|
|
12
|
+
icon: { default: "" },
|
|
13
|
+
loading: {
|
|
14
|
+
type: Boolean,
|
|
15
|
+
default: !1
|
|
16
|
+
},
|
|
17
|
+
class: { default: "" },
|
|
18
|
+
outlined: {
|
|
19
|
+
type: Boolean,
|
|
20
|
+
default: !1
|
|
21
|
+
},
|
|
22
|
+
secondary: {
|
|
23
|
+
type: Boolean,
|
|
24
|
+
default: !1
|
|
25
|
+
},
|
|
26
|
+
disabled: {
|
|
27
|
+
type: Boolean,
|
|
28
|
+
default: !1
|
|
29
|
+
},
|
|
30
|
+
unstyled: {
|
|
31
|
+
type: Boolean,
|
|
32
|
+
default: !1
|
|
33
|
+
},
|
|
34
|
+
type: { default: "button" }
|
|
35
|
+
},
|
|
36
|
+
emits: ["click"],
|
|
37
|
+
setup(i, { emit: g }) {
|
|
38
|
+
let _ = l(), v = e(() => !!_.icon), y = i, b = g, x = e(() => {
|
|
39
|
+
let e = y.unstyled ? "" : y.secondary ? "rounded-[10px] border px-2 py-2 font-bold" : y.outlined ? "shrink-0 rounded-[10px] border-primary-800 px-4 py-2 text-primary-800 hover:bg-primary-50" : "rounded-[10px] !border-primary-900 bg-primary-900 px-3 py-2 font-bold text-white hover:!border-primary-800 hover:bg-primary-800 ";
|
|
40
|
+
return m(e, y.class);
|
|
41
|
+
});
|
|
42
|
+
return (e, l) => (o(), n("span", h, [d((o(), t(c(f), {
|
|
43
|
+
type: i.type,
|
|
44
|
+
label: i.label,
|
|
45
|
+
disabled: i.disabled || i.loading,
|
|
46
|
+
icon: v.value ? void 0 : i.icon || void 0,
|
|
47
|
+
loading: i.loading,
|
|
48
|
+
outlined: i.outlined || i.secondary,
|
|
49
|
+
severity: i.secondary ? "secondary" : void 0,
|
|
50
|
+
class: a(x.value),
|
|
51
|
+
pt: { root: { class: x.value } },
|
|
52
|
+
onClick: l[0] ||= (e) => b("click")
|
|
53
|
+
}, r({ _: 2 }, [v.value ? {
|
|
54
|
+
name: "icon",
|
|
55
|
+
fn: u(() => [s(e.$slots, "icon")]),
|
|
56
|
+
key: "0"
|
|
57
|
+
} : void 0]), 1032, [
|
|
58
|
+
"type",
|
|
59
|
+
"label",
|
|
60
|
+
"disabled",
|
|
61
|
+
"icon",
|
|
62
|
+
"loading",
|
|
63
|
+
"outlined",
|
|
64
|
+
"severity",
|
|
65
|
+
"class",
|
|
66
|
+
"pt"
|
|
67
|
+
])), [[
|
|
68
|
+
c(p),
|
|
69
|
+
{
|
|
70
|
+
value: i.tooltip,
|
|
71
|
+
class: i.tooltipClass
|
|
72
|
+
},
|
|
73
|
+
void 0,
|
|
74
|
+
{ top: !0 }
|
|
75
|
+
]])]));
|
|
76
|
+
}
|
|
77
|
+
});
|
|
78
|
+
//#endregion
|
|
79
|
+
export { g as t };
|
|
80
|
+
|
|
81
|
+
//# sourceMappingURL=TopButton-9IIdtUbJ.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"TopButton-9IIdtUbJ.js","names":[],"sources":["../src/components/TopButton.vue","../src/components/TopButton.vue"],"sourcesContent":["<script setup lang=\"ts\">\nimport { computed, useSlots } from 'vue'\nimport Button from 'primevue/button'\nimport vTooltip from 'primevue/tooltip'\nimport { twMerge } from 'tailwind-merge'\n\nconst slots = useSlots()\nconst outrosIcones = computed(() => Boolean(slots.icon))\n\nconst props = withDefaults(\n defineProps<{\n tooltip?: string\n tooltipClass?: string\n label?: string\n icon?: string\n loading?: boolean\n class?: string\n outlined?: boolean\n secondary?: boolean\n disabled?: boolean\n unstyled?: boolean\n type?: 'button' | 'submit' | 'reset'\n }>(),\n {\n tooltip: '',\n tooltipClass: 'text-xs',\n label: '',\n icon: '',\n loading: false,\n class: '',\n outlined: false,\n secondary: false,\n disabled: false,\n unstyled: false,\n type: 'button',\n },\n)\n\nconst emit = defineEmits<{\n click: []\n}>()\n\nconst buttonClasses = computed(() => {\n const baseClasses = !props.unstyled\n ? props.secondary\n ? 'rounded-[10px] border px-2 py-2 font-bold'\n : props.outlined\n ? 'shrink-0 rounded-[10px] border-primary-800 px-4 py-2 text-primary-800 hover:bg-primary-50'\n : 'rounded-[10px] !border-primary-900 bg-primary-900 px-3 py-2 font-bold text-white hover:!border-primary-800 hover:bg-primary-800 '\n : ''\n\n return twMerge(baseClasses, props.class)\n})\n</script>\n\n<template>\n <span class=\"h-fit w-fit rounded-[12px] bg-transparent\">\n <Button\n v-tooltip.top=\"{\n value: tooltip,\n class: tooltipClass,\n }\"\n :type=\"type\"\n :label=\"label\"\n :disabled=\"disabled || loading\"\n :icon=\"outrosIcones ? undefined : icon || undefined\"\n :loading=\"loading\"\n :outlined=\"outlined || secondary\"\n :severity=\"secondary ? 'secondary' : undefined\"\n :class=\"buttonClasses\"\n :pt=\"{\n root: { class: buttonClasses },\n }\"\n @click=\"emit('click')\"\n >\n <template v-if=\"outrosIcones\" #icon>\n <slot name=\"icon\" />\n </template>\n </Button>\n </span>\n</template>\n","<script setup lang=\"ts\">\nimport { computed, useSlots } from 'vue'\nimport Button from 'primevue/button'\nimport vTooltip from 'primevue/tooltip'\nimport { twMerge } from 'tailwind-merge'\n\nconst slots = useSlots()\nconst outrosIcones = computed(() => Boolean(slots.icon))\n\nconst props = withDefaults(\n defineProps<{\n tooltip?: string\n tooltipClass?: string\n label?: string\n icon?: string\n loading?: boolean\n class?: string\n outlined?: boolean\n secondary?: boolean\n disabled?: boolean\n unstyled?: boolean\n type?: 'button' | 'submit' | 'reset'\n }>(),\n {\n tooltip: '',\n tooltipClass: 'text-xs',\n label: '',\n icon: '',\n loading: false,\n class: '',\n outlined: false,\n secondary: false,\n disabled: false,\n unstyled: false,\n type: 'button',\n },\n)\n\nconst emit = defineEmits<{\n click: []\n}>()\n\nconst buttonClasses = computed(() => {\n const baseClasses = !props.unstyled\n ? props.secondary\n ? 'rounded-[10px] border px-2 py-2 font-bold'\n : props.outlined\n ? 'shrink-0 rounded-[10px] border-primary-800 px-4 py-2 text-primary-800 hover:bg-primary-50'\n : 'rounded-[10px] !border-primary-900 bg-primary-900 px-3 py-2 font-bold text-white hover:!border-primary-800 hover:bg-primary-800 '\n : ''\n\n return twMerge(baseClasses, props.class)\n})\n</script>\n\n<template>\n <span class=\"h-fit w-fit rounded-[12px] bg-transparent\">\n <Button\n v-tooltip.top=\"{\n value: tooltip,\n class: tooltipClass,\n }\"\n :type=\"type\"\n :label=\"label\"\n :disabled=\"disabled || loading\"\n :icon=\"outrosIcones ? undefined : icon || undefined\"\n :loading=\"loading\"\n :outlined=\"outlined || secondary\"\n :severity=\"secondary ? 'secondary' : undefined\"\n :class=\"buttonClasses\"\n :pt=\"{\n root: { class: buttonClasses },\n }\"\n @click=\"emit('click')\"\n >\n <template v-if=\"outrosIcones\" #icon>\n <slot name=\"icon\" />\n </template>\n </Button>\n </span>\n</template>\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAMA,IAAM,IAAQ,EAAS,GACjB,IAAe,QAAe,EAAQ,EAAM,IAAK,GAEjD,IAAQ,GA6BR,IAAO,GAIP,IAAgB,QAAe;GACnC,IAAM,IAAe,EAAM,WAMvB,KALA,EAAM,YACJ,8CACA,EAAM,WACJ,8FACA;GAGR,OAAO,EAAQ,GAAa,EAAM,KAAK;EACzC,CAAC;oBAIC,EAAA,GAAA,EAuBO,QAvBP,GAuBO,CAtBL,GAAA,EAAA,GAAA,EAqBS,EAAA,CAAA,GAAA;GAhBN,MAAM,EAAA;GACN,OAAO,EAAA;GACP,UAAU,EAAA,YAAY,EAAA;GACtB,MAAM,EAAA,QAAe,KAAA,IAAY,EAAA,QAAQ,KAAA;GACzC,SAAS,EAAA;GACT,UAAU,EAAA,YAAY,EAAA;GACtB,UAAU,EAAA,YAAS,cAAiB,KAAA;GACpC,OAAK,EAAE,EAAA,KAAa;GACpB,IAAE,EAA2B,MAAA,EAAA,OAAA,EAAA,MAAa,EAAA;GAG1C,SAAK,AAAA,EAAA,QAAA,MAAE,EAAI,OAAA;EAEI,GAAA,EAAA,EAAA,GAAA,EAAA,GAAA,CAAA,EAAA,QAAA;GAAe,MAAA;GAC7B,IAAA,QAAoB,CAApB,EAAoB,EAAA,QAAA,MAAA,CAAA,CAAA;;;;;;;;;;;;;;;IAlBU,OAAA,EAAA;IAAwB,OAAA,EAAA;;;GAA9C,EAAA,KAAV,GAGE"}
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
var e=Object.create,t=Object.defineProperty,n=Object.getOwnPropertyDescriptor,r=Object.getOwnPropertyNames,i=Object.getPrototypeOf,a=Object.prototype.hasOwnProperty,o=(e,i,o,s)=>{if(i&&typeof i==`object`||typeof i==`function`)for(var c=r(i),l=0,u=c.length,d;l<u;l++)d=c[l],!a.call(e,d)&&d!==o&&t(e,d,{get:(e=>i[e]).bind(null,d),enumerable:!(s=n(i,d))||s.enumerable});return e},s=(n,r,s)=>(s=n==null?{}:e(i(n)),o(r||!n||!n.__esModule||!a.call(n,`default`)?t(s,`default`,{value:n,enumerable:!0}):s,n));let c=require("vue"),l=require("primevue/button");l=s(l,1);let u=require("primevue/tooltip");u=s(u,1);let d=require("tailwind-merge");var f={class:`h-fit w-fit rounded-[12px] bg-transparent`},p=(0,c.defineComponent)({__name:`TopButton`,props:{tooltip:{default:``},tooltipClass:{default:`text-xs`},label:{default:``},icon:{default:``},loading:{type:Boolean,default:!1},class:{default:``},outlined:{type:Boolean,default:!1},secondary:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},unstyled:{type:Boolean,default:!1},type:{default:`button`}},emits:[`click`],setup(e,{emit:t}){let n=(0,c.useSlots)(),r=(0,c.computed)(()=>!!n.icon),i=e,a=t,o=(0,c.computed)(()=>{let e=i.unstyled?``:i.secondary?`rounded-[10px] border px-2 py-2 font-bold`:i.outlined?`shrink-0 rounded-[10px] border-primary-800 px-4 py-2 text-primary-800 hover:bg-primary-50`:`rounded-[10px] !border-primary-900 bg-primary-900 px-3 py-2 font-bold text-white hover:!border-primary-800 hover:bg-primary-800 `;return(0,d.twMerge)(e,i.class)});return(t,n)=>((0,c.openBlock)(),(0,c.createElementBlock)(`span`,f,[(0,c.withDirectives)(((0,c.openBlock)(),(0,c.createBlock)((0,c.unref)(l.default),{type:e.type,label:e.label,disabled:e.disabled||e.loading,icon:r.value?void 0:e.icon||void 0,loading:e.loading,outlined:e.outlined||e.secondary,severity:e.secondary?`secondary`:void 0,class:(0,c.normalizeClass)(o.value),pt:{root:{class:o.value}},onClick:n[0]||=e=>a(`click`)},(0,c.createSlots)({_:2},[r.value?{name:`icon`,fn:(0,c.withCtx)(()=>[(0,c.renderSlot)(t.$slots,`icon`)]),key:`0`}:void 0]),1032,[`type`,`label`,`disabled`,`icon`,`loading`,`outlined`,`severity`,`class`,`pt`])),[[(0,c.unref)(u.default),{value:e.tooltip,class:e.tooltipClass},void 0,{top:!0}]])]))}});Object.defineProperty(exports,"t",{enumerable:!0,get:function(){return p}});
|
|
2
|
+
//# sourceMappingURL=TopButton-CDKgguLF.cjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"TopButton-CDKgguLF.cjs","names":[],"sources":["../src/components/TopButton.vue","../src/components/TopButton.vue"],"sourcesContent":["<script setup lang=\"ts\">\nimport { computed, useSlots } from 'vue'\nimport Button from 'primevue/button'\nimport vTooltip from 'primevue/tooltip'\nimport { twMerge } from 'tailwind-merge'\n\nconst slots = useSlots()\nconst outrosIcones = computed(() => Boolean(slots.icon))\n\nconst props = withDefaults(\n defineProps<{\n tooltip?: string\n tooltipClass?: string\n label?: string\n icon?: string\n loading?: boolean\n class?: string\n outlined?: boolean\n secondary?: boolean\n disabled?: boolean\n unstyled?: boolean\n type?: 'button' | 'submit' | 'reset'\n }>(),\n {\n tooltip: '',\n tooltipClass: 'text-xs',\n label: '',\n icon: '',\n loading: false,\n class: '',\n outlined: false,\n secondary: false,\n disabled: false,\n unstyled: false,\n type: 'button',\n },\n)\n\nconst emit = defineEmits<{\n click: []\n}>()\n\nconst buttonClasses = computed(() => {\n const baseClasses = !props.unstyled\n ? props.secondary\n ? 'rounded-[10px] border px-2 py-2 font-bold'\n : props.outlined\n ? 'shrink-0 rounded-[10px] border-primary-800 px-4 py-2 text-primary-800 hover:bg-primary-50'\n : 'rounded-[10px] !border-primary-900 bg-primary-900 px-3 py-2 font-bold text-white hover:!border-primary-800 hover:bg-primary-800 '\n : ''\n\n return twMerge(baseClasses, props.class)\n})\n</script>\n\n<template>\n <span class=\"h-fit w-fit rounded-[12px] bg-transparent\">\n <Button\n v-tooltip.top=\"{\n value: tooltip,\n class: tooltipClass,\n }\"\n :type=\"type\"\n :label=\"label\"\n :disabled=\"disabled || loading\"\n :icon=\"outrosIcones ? undefined : icon || undefined\"\n :loading=\"loading\"\n :outlined=\"outlined || secondary\"\n :severity=\"secondary ? 'secondary' : undefined\"\n :class=\"buttonClasses\"\n :pt=\"{\n root: { class: buttonClasses },\n }\"\n @click=\"emit('click')\"\n >\n <template v-if=\"outrosIcones\" #icon>\n <slot name=\"icon\" />\n </template>\n </Button>\n </span>\n</template>\n","<script setup lang=\"ts\">\nimport { computed, useSlots } from 'vue'\nimport Button from 'primevue/button'\nimport vTooltip from 'primevue/tooltip'\nimport { twMerge } from 'tailwind-merge'\n\nconst slots = useSlots()\nconst outrosIcones = computed(() => Boolean(slots.icon))\n\nconst props = withDefaults(\n defineProps<{\n tooltip?: string\n tooltipClass?: string\n label?: string\n icon?: string\n loading?: boolean\n class?: string\n outlined?: boolean\n secondary?: boolean\n disabled?: boolean\n unstyled?: boolean\n type?: 'button' | 'submit' | 'reset'\n }>(),\n {\n tooltip: '',\n tooltipClass: 'text-xs',\n label: '',\n icon: '',\n loading: false,\n class: '',\n outlined: false,\n secondary: false,\n disabled: false,\n unstyled: false,\n type: 'button',\n },\n)\n\nconst emit = defineEmits<{\n click: []\n}>()\n\nconst buttonClasses = computed(() => {\n const baseClasses = !props.unstyled\n ? props.secondary\n ? 'rounded-[10px] border px-2 py-2 font-bold'\n : props.outlined\n ? 'shrink-0 rounded-[10px] border-primary-800 px-4 py-2 text-primary-800 hover:bg-primary-50'\n : 'rounded-[10px] !border-primary-900 bg-primary-900 px-3 py-2 font-bold text-white hover:!border-primary-800 hover:bg-primary-800 '\n : ''\n\n return twMerge(baseClasses, props.class)\n})\n</script>\n\n<template>\n <span class=\"h-fit w-fit rounded-[12px] bg-transparent\">\n <Button\n v-tooltip.top=\"{\n value: tooltip,\n class: tooltipClass,\n }\"\n :type=\"type\"\n :label=\"label\"\n :disabled=\"disabled || loading\"\n :icon=\"outrosIcones ? undefined : icon || undefined\"\n :loading=\"loading\"\n :outlined=\"outlined || secondary\"\n :severity=\"secondary ? 'secondary' : undefined\"\n :class=\"buttonClasses\"\n :pt=\"{\n root: { class: buttonClasses },\n }\"\n @click=\"emit('click')\"\n >\n <template v-if=\"outrosIcones\" #icon>\n <slot name=\"icon\" />\n </template>\n </Button>\n </span>\n</template>\n"],"mappings":"+jCAMA,IAAM,GAAA,EAAQ,EAAA,SAAA,CAAS,EACjB,GAAA,EAAe,EAAA,SAAA,KAAe,EAAQ,EAAM,IAAK,EAEjD,EAAQ,EA6BR,EAAO,EAIP,GAAA,EAAgB,EAAA,SAAA,KAAe,CACnC,IAAM,EAAe,EAAM,SAMvB,GALA,EAAM,UACJ,4CACA,EAAM,SACJ,4FACA,mIAGR,OAAA,EAAO,EAAA,QAAA,CAAQ,EAAa,EAAM,KAAK,CACzC,CAAC,iBAIC,EAAA,EAAA,UAAA,CAAA,GAAA,EAAA,EAAA,mBAAA,CAuBO,OAvBP,EAuBO,EAAA,EAtBL,EAAA,eAAA,GAAA,EAAA,EAAA,UAAA,CAAA,GAAA,EAAA,EAAA,YAAA,EAAA,EAqBS,EAAA,MAAA,CAAA,EAAA,OAAA,EAAA,CAhBN,KAAM,EAAA,KACN,MAAO,EAAA,MACP,SAAU,EAAA,UAAY,EAAA,QACtB,KAAM,EAAA,MAAe,IAAA,GAAY,EAAA,MAAQ,IAAA,GACzC,QAAS,EAAA,QACT,SAAU,EAAA,UAAY,EAAA,UACtB,SAAU,EAAA,UAAS,YAAiB,IAAA,GACpC,OAAA,EAAK,EAAA,eAAA,CAAE,EAAA,KAAa,EACpB,GAAE,CAA2B,KAAA,CAAA,MAAA,EAAA,KAAa,CAAA,EAG1C,QAAK,AAAA,EAAA,KAAA,GAAE,EAAI,OAAA,CAEI,GAAA,EAAA,EAAA,YAAA,CAAA,CAAA,EAAA,CAAA,EAAA,CAAA,EAAA,MAAA,CAAe,KAAA,OAC7B,IAAA,EAAA,EAAA,QAAA,KAAoB,EAAA,EAApB,EAAA,WAAA,CAAoB,EAAA,OAAA,MAAA,CAAA,CAAA,qIAlBU,MAAA,EAAA,QAAwB,MAAA,EAAA,qBAA9C,CAAA,IAAV,EAGE"}
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
type __VLS_Props = {
|
|
2
2
|
tooltip?: string;
|
|
3
|
+
tooltipClass?: string;
|
|
3
4
|
label?: string;
|
|
4
5
|
icon?: string;
|
|
5
6
|
loading?: boolean;
|
|
@@ -21,6 +22,7 @@ declare const __VLS_base: import('vue').DefineComponent<__VLS_Props, {}, {}, {},
|
|
|
21
22
|
}>, {
|
|
22
23
|
icon: string;
|
|
23
24
|
tooltip: string;
|
|
25
|
+
tooltipClass: string;
|
|
24
26
|
label: string;
|
|
25
27
|
loading: boolean;
|
|
26
28
|
class: string;
|
package/dist/index.cjs
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
Object.defineProperty(exports,Symbol.toStringTag,{value:`Module`});
|
|
1
|
+
Object.defineProperty(exports,Symbol.toStringTag,{value:`Module`});const e=require("./TopButton-CDKgguLF.cjs");var t={primary:{50:`#EEF9FF`,100:`#DFF4FF`,200:`#C5E6F8`,300:`#8EC4DF`,400:`#66ACD1`,500:`#2488BC`,600:`#036DA3`,700:`#1B5783`,800:`#02466B`,900:`#052F4A`,950:`#0C192D`},secondary:{50:`#FAFAFA`,100:`#F4F4F5`,200:`#E9E9E9`,300:`#D8D8D8`,400:`#B8B8B8`,500:`#8E8E8E`,600:`#676767`,700:`#4B4B4B`,800:`#343434`,900:`#1C1917`,950:`#0C0A09`},success:{50:`#FAFFFA`,100:`#F4FBF6`,200:`#DFF6DE`,300:`#CBE3CA`,400:`#A3CCA1`,500:`#6BA968`,600:`#358F30`,700:`#2C7B27`,800:`#1E631A`,900:`#10430D`,950:`#062804`},warn:{50:`#FFF7ED`,100:`#FDF3D8`,200:`#FDE9B2`,300:`#FDD566`,400:`#FFB900`,500:`#FFA515`,600:`#FD9024`,700:`#DD781F`,800:`#BC4E00`,900:`#A42D02`,950:`#792202`},danger:{50:`#F8E6E4`,100:`#FFDDD9`,200:`#EEC1BC`,300:`#E3938C`,400:`#E3675C`,500:`#DC3F32`,600:`#CF150E`,700:`#B10404`,800:`#820907`,900:`#5D0803`,950:`#450501`}};exports.TopButton=e.t,exports.colors=t;
|
|
2
2
|
//# sourceMappingURL=index.cjs.map
|
package/dist/index.cjs.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.cjs","names":[],"sources":["../src/
|
|
1
|
+
{"version":3,"file":"index.cjs","names":[],"sources":["../src/tokens/colors.ts"],"sourcesContent":["export const colors = {\n primary: {\n 50: '#EEF9FF',\n 100: '#DFF4FF',\n 200: '#C5E6F8',\n 300: '#8EC4DF',\n 400: '#66ACD1',\n 500: '#2488BC',\n 600: '#036DA3',\n 700: '#1B5783',\n 800: '#02466B',\n 900: '#052F4A',\n 950: '#0C192D',\n },\n secondary: {\n 50: '#FAFAFA',\n 100: '#F4F4F5',\n 200: '#E9E9E9',\n 300: '#D8D8D8',\n 400: '#B8B8B8',\n 500: '#8E8E8E',\n 600: '#676767',\n 700: '#4B4B4B',\n 800: '#343434',\n 900: '#1C1917',\n 950: '#0C0A09',\n },\n success: {\n 50: '#FAFFFA',\n 100: '#F4FBF6',\n 200: '#DFF6DE',\n 300: '#CBE3CA',\n 400: '#A3CCA1',\n 500: '#6BA968',\n 600: '#358F30',\n 700: '#2C7B27',\n 800: '#1E631A',\n 900: '#10430D',\n 950: '#062804',\n },\n warn: {\n 50: '#FFF7ED',\n 100: '#FDF3D8',\n 200: '#FDE9B2',\n 300: '#FDD566',\n 400: '#FFB900',\n 500: '#FFA515',\n 600: '#FD9024',\n 700: '#DD781F',\n 800: '#BC4E00',\n 900: '#A42D02',\n 950: '#792202',\n },\n danger: {\n 50: '#F8E6E4',\n 100: '#FFDDD9',\n 200: '#EEC1BC',\n 300: '#E3938C',\n 400: '#E3675C',\n 500: '#DC3F32',\n 600: '#CF150E',\n 700: '#B10404',\n 800: '#820907',\n 900: '#5D0803',\n 950: '#450501',\n },\n} as const\n"],"mappings":"+GAAA,IAAa,EAAS,CACpB,QAAS,CACP,GAAI,UACJ,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,SACP,EACA,UAAW,CACT,GAAI,UACJ,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,SACP,EACA,QAAS,CACP,GAAI,UACJ,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,SACP,EACA,KAAM,CACJ,GAAI,UACJ,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,SACP,EACA,OAAQ,CACN,GAAI,UACJ,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,UACL,IAAK,SACP,CACF"}
|
package/dist/index.d.ts
CHANGED
|
@@ -1,5 +1,2 @@
|
|
|
1
|
-
|
|
2
|
-
import { default as TopButton } from './components/TopButton.vue';
|
|
3
|
-
export { TopButton };
|
|
1
|
+
export { default as TopButton } from './components/TopButton.vue';
|
|
4
2
|
export { colors } from './tokens/colors';
|
|
5
|
-
export declare const TopSolutionsDesignSystem: Plugin;
|
package/dist/index.js
CHANGED
|
@@ -1,76 +1,6 @@
|
|
|
1
|
-
import {
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
import { twMerge as m } from "tailwind-merge";
|
|
5
|
-
//#region src/components/TopButton.vue?vue&type=script&setup=true&lang.ts
|
|
6
|
-
var h = { class: "h-fit w-fit rounded-[12px] bg-transparent" }, g = /* @__PURE__ */ i({
|
|
7
|
-
__name: "TopButton",
|
|
8
|
-
props: {
|
|
9
|
-
tooltip: { default: "" },
|
|
10
|
-
label: { default: "" },
|
|
11
|
-
icon: { default: "" },
|
|
12
|
-
loading: {
|
|
13
|
-
type: Boolean,
|
|
14
|
-
default: !1
|
|
15
|
-
},
|
|
16
|
-
class: { default: "" },
|
|
17
|
-
outlined: {
|
|
18
|
-
type: Boolean,
|
|
19
|
-
default: !1
|
|
20
|
-
},
|
|
21
|
-
secondary: {
|
|
22
|
-
type: Boolean,
|
|
23
|
-
default: !1
|
|
24
|
-
},
|
|
25
|
-
disabled: {
|
|
26
|
-
type: Boolean,
|
|
27
|
-
default: !1
|
|
28
|
-
},
|
|
29
|
-
unstyled: {
|
|
30
|
-
type: Boolean,
|
|
31
|
-
default: !1
|
|
32
|
-
},
|
|
33
|
-
type: { default: "button" }
|
|
34
|
-
},
|
|
35
|
-
emits: ["click"],
|
|
36
|
-
setup(i, { emit: g }) {
|
|
37
|
-
let _ = l(), v = e(() => !!_.icon), y = i, b = g, x = e(() => {
|
|
38
|
-
let e = y.unstyled ? "" : y.secondary ? "rounded-[10px] border px-2 py-2 font-bold" : y.outlined ? "shrink-0 rounded-[10px] border-primary-800 px-4 py-2 text-primary-800 hover:bg-primary-50" : "rounded-[10px] !border-primary-900 bg-primary-900 px-3 py-2 font-bold text-white hover:!border-primary-800 hover:bg-primary-800 ";
|
|
39
|
-
return m(e, y.class);
|
|
40
|
-
});
|
|
41
|
-
return (e, l) => (o(), n("span", h, [d((o(), t(c(f), {
|
|
42
|
-
type: i.type,
|
|
43
|
-
label: i.label,
|
|
44
|
-
disabled: i.disabled || i.loading,
|
|
45
|
-
icon: v.value ? void 0 : i.icon || void 0,
|
|
46
|
-
loading: i.loading,
|
|
47
|
-
outlined: i.outlined || i.secondary,
|
|
48
|
-
severity: i.secondary ? "secondary" : void 0,
|
|
49
|
-
class: a(x.value),
|
|
50
|
-
pt: { root: { class: x.value } },
|
|
51
|
-
onClick: l[0] ||= (e) => b("click")
|
|
52
|
-
}, r({ _: 2 }, [v.value ? {
|
|
53
|
-
name: "icon",
|
|
54
|
-
fn: u(() => [s(e.$slots, "icon")]),
|
|
55
|
-
key: "0"
|
|
56
|
-
} : void 0]), 1032, [
|
|
57
|
-
"type",
|
|
58
|
-
"label",
|
|
59
|
-
"disabled",
|
|
60
|
-
"icon",
|
|
61
|
-
"loading",
|
|
62
|
-
"outlined",
|
|
63
|
-
"severity",
|
|
64
|
-
"class",
|
|
65
|
-
"pt"
|
|
66
|
-
])), [[
|
|
67
|
-
c(p),
|
|
68
|
-
i.tooltip,
|
|
69
|
-
void 0,
|
|
70
|
-
{ top: !0 }
|
|
71
|
-
]])]));
|
|
72
|
-
}
|
|
73
|
-
}), _ = {
|
|
1
|
+
import { t as e } from "./TopButton-9IIdtUbJ.js";
|
|
2
|
+
//#region src/tokens/colors.ts
|
|
3
|
+
var t = {
|
|
74
4
|
primary: {
|
|
75
5
|
50: "#EEF9FF",
|
|
76
6
|
100: "#DFF4FF",
|
|
@@ -136,10 +66,8 @@ var h = { class: "h-fit w-fit rounded-[12px] bg-transparent" }, g = /* @__PURE__
|
|
|
136
66
|
900: "#5D0803",
|
|
137
67
|
950: "#450501"
|
|
138
68
|
}
|
|
139
|
-
}
|
|
140
|
-
e.component("TopButton", g);
|
|
141
|
-
} };
|
|
69
|
+
};
|
|
142
70
|
//#endregion
|
|
143
|
-
export {
|
|
71
|
+
export { e as TopButton, t as colors };
|
|
144
72
|
|
|
145
73
|
//# sourceMappingURL=index.js.map
|
package/dist/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","names":[],"sources":["../src/
|
|
1
|
+
{"version":3,"file":"index.js","names":[],"sources":["../src/tokens/colors.ts"],"sourcesContent":["export const colors = {\n primary: {\n 50: '#EEF9FF',\n 100: '#DFF4FF',\n 200: '#C5E6F8',\n 300: '#8EC4DF',\n 400: '#66ACD1',\n 500: '#2488BC',\n 600: '#036DA3',\n 700: '#1B5783',\n 800: '#02466B',\n 900: '#052F4A',\n 950: '#0C192D',\n },\n secondary: {\n 50: '#FAFAFA',\n 100: '#F4F4F5',\n 200: '#E9E9E9',\n 300: '#D8D8D8',\n 400: '#B8B8B8',\n 500: '#8E8E8E',\n 600: '#676767',\n 700: '#4B4B4B',\n 800: '#343434',\n 900: '#1C1917',\n 950: '#0C0A09',\n },\n success: {\n 50: '#FAFFFA',\n 100: '#F4FBF6',\n 200: '#DFF6DE',\n 300: '#CBE3CA',\n 400: '#A3CCA1',\n 500: '#6BA968',\n 600: '#358F30',\n 700: '#2C7B27',\n 800: '#1E631A',\n 900: '#10430D',\n 950: '#062804',\n },\n warn: {\n 50: '#FFF7ED',\n 100: '#FDF3D8',\n 200: '#FDE9B2',\n 300: '#FDD566',\n 400: '#FFB900',\n 500: '#FFA515',\n 600: '#FD9024',\n 700: '#DD781F',\n 800: '#BC4E00',\n 900: '#A42D02',\n 950: '#792202',\n },\n danger: {\n 50: '#F8E6E4',\n 100: '#FFDDD9',\n 200: '#EEC1BC',\n 300: '#E3938C',\n 400: '#E3675C',\n 500: '#DC3F32',\n 600: '#CF150E',\n 700: '#B10404',\n 800: '#820907',\n 900: '#5D0803',\n 950: '#450501',\n },\n} as const\n"],"mappings":";;AAAA,IAAa,IAAS;CACpB,SAAS;EACP,IAAI;EACJ,KAAK;EACL,KAAK;EACL,KAAK;EACL,KAAK;EACL,KAAK;EACL,KAAK;EACL,KAAK;EACL,KAAK;EACL,KAAK;EACL,KAAK;CACP;CACA,WAAW;EACT,IAAI;EACJ,KAAK;EACL,KAAK;EACL,KAAK;EACL,KAAK;EACL,KAAK;EACL,KAAK;EACL,KAAK;EACL,KAAK;EACL,KAAK;EACL,KAAK;CACP;CACA,SAAS;EACP,IAAI;EACJ,KAAK;EACL,KAAK;EACL,KAAK;EACL,KAAK;EACL,KAAK;EACL,KAAK;EACL,KAAK;EACL,KAAK;EACL,KAAK;EACL,KAAK;CACP;CACA,MAAM;EACJ,IAAI;EACJ,KAAK;EACL,KAAK;EACL,KAAK;EACL,KAAK;EACL,KAAK;EACL,KAAK;EACL,KAAK;EACL,KAAK;EACL,KAAK;EACL,KAAK;CACP;CACA,QAAQ;EACN,IAAI;EACJ,KAAK;EACL,KAAK;EACL,KAAK;EACL,KAAK;EACL,KAAK;EACL,KAAK;EACL,KAAK;EACL,KAAK;EACL,KAAK;EACL,KAAK;CACP;AACF"}
|
package/dist/nuxt.cjs
ADDED
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
let e=require("@nuxt/kit");var t=`@topjoao/top-design-system`,n=`${t}/style.css`,r=(0,e.defineNuxtModule)({meta:{name:t,configKey:`topDesignSystem`,compatibility:{nuxt:`^3.0.0 || ^4.0.0`}},setup(r,i){i.options.css.some(e=>e===n)||i.options.css.push(n),(0,e.addComponent)({name:`TopButton`,export:`TopButton`,filePath:t})}});module.exports=r;
|
|
2
|
+
//# sourceMappingURL=nuxt.cjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"nuxt.cjs","names":[],"sources":["../src/nuxt.ts"],"sourcesContent":["import { addComponent, defineNuxtModule } from '@nuxt/kit'\n\nconst packageName = '@topjoao/top-design-system'\nconst stylePath = `${packageName}/style.css`\n\nexport default defineNuxtModule({\n meta: {\n name: packageName,\n configKey: 'topDesignSystem',\n compatibility: {\n nuxt: '^3.0.0 || ^4.0.0',\n },\n },\n setup(_options, nuxt) {\n if (!nuxt.options.css.some((style) => style === stylePath)) {\n nuxt.options.css.push(stylePath)\n }\n\n addComponent({\n name: 'TopButton',\n export: 'TopButton',\n filePath: packageName,\n })\n },\n})\n"],"mappings":"2BAEA,IAAM,EAAc,6BACd,EAAY,GAAG,EAAY,YAEjC,GAAA,EAAe,EAAA,iBAAA,CAAiB,CAC9B,KAAM,CACJ,KAAM,EACN,UAAW,kBACX,cAAe,CACb,KAAM,kBACR,CACF,EACA,MAAM,EAAU,EAAM,CACf,EAAK,QAAQ,IAAI,KAAM,GAAU,IAAU,CAAS,GACvD,EAAK,QAAQ,IAAI,KAAK,CAAS,GAGjC,EAAA,EAAA,aAAA,CAAa,CACX,KAAM,YACN,OAAQ,YACR,SAAU,CACZ,CAAC,CACH,CACF,CAAC"}
|
package/dist/nuxt.d.ts
ADDED
package/dist/nuxt.js
ADDED
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import { addComponent as e, defineNuxtModule as t } from "@nuxt/kit";
|
|
2
|
+
//#region src/nuxt.ts
|
|
3
|
+
var n = "@topjoao/top-design-system", r = `${n}/style.css`, i = t({
|
|
4
|
+
meta: {
|
|
5
|
+
name: n,
|
|
6
|
+
configKey: "topDesignSystem",
|
|
7
|
+
compatibility: { nuxt: "^3.0.0 || ^4.0.0" }
|
|
8
|
+
},
|
|
9
|
+
setup(t, i) {
|
|
10
|
+
i.options.css.some((e) => e === r) || i.options.css.push(r), e({
|
|
11
|
+
name: "TopButton",
|
|
12
|
+
export: "TopButton",
|
|
13
|
+
filePath: n
|
|
14
|
+
});
|
|
15
|
+
}
|
|
16
|
+
});
|
|
17
|
+
//#endregion
|
|
18
|
+
export { i as default };
|
|
19
|
+
|
|
20
|
+
//# sourceMappingURL=nuxt.js.map
|
package/dist/nuxt.js.map
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"nuxt.js","names":[],"sources":["../src/nuxt.ts"],"sourcesContent":["import { addComponent, defineNuxtModule } from '@nuxt/kit'\n\nconst packageName = '@topjoao/top-design-system'\nconst stylePath = `${packageName}/style.css`\n\nexport default defineNuxtModule({\n meta: {\n name: packageName,\n configKey: 'topDesignSystem',\n compatibility: {\n nuxt: '^3.0.0 || ^4.0.0',\n },\n },\n setup(_options, nuxt) {\n if (!nuxt.options.css.some((style) => style === stylePath)) {\n nuxt.options.css.push(stylePath)\n }\n\n addComponent({\n name: 'TopButton',\n export: 'TopButton',\n filePath: packageName,\n })\n },\n})\n"],"mappings":";;AAEA,IAAM,IAAc,8BACd,IAAY,GAAG,EAAY,aAEjC,IAAe,EAAiB;CAC9B,MAAM;EACJ,MAAM;EACN,WAAW;EACX,eAAe,EACb,MAAM,mBACR;CACF;CACA,MAAM,GAAU,GAAM;EAKpB,AAJK,EAAK,QAAQ,IAAI,MAAM,MAAU,MAAU,CAAS,KACvD,EAAK,QAAQ,IAAI,KAAK,CAAS,GAGjC,EAAa;GACX,MAAM;GACN,QAAQ;GACR,UAAU;EACZ,CAAC;CACH;AACF,CAAC"}
|
package/dist/plugin.cjs
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"plugin.cjs","names":[],"sources":["../src/plugin.ts"],"sourcesContent":["import type { App, Plugin } from 'vue'\nimport TopButton from './components/TopButton.vue'\n\ndeclare module 'vue' {\n export interface GlobalComponents {\n TopButton: typeof TopButton\n }\n}\n\nexport const TopSolutionsDesignSystem: Plugin = {\n install(app: App) {\n app.component('TopButton', TopButton)\n },\n}\n"],"mappings":"+GASA,IAAa,EAAmC,CAC9C,QAAQ,EAAU,CAChB,EAAI,UAAU,YAAa,EAAA,CAAS,CACtC,CACF"}
|
package/dist/plugin.d.ts
ADDED
package/dist/plugin.js
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"plugin.js","names":[],"sources":["../src/plugin.ts"],"sourcesContent":["import type { App, Plugin } from 'vue'\nimport TopButton from './components/TopButton.vue'\n\ndeclare module 'vue' {\n export interface GlobalComponents {\n TopButton: typeof TopButton\n }\n}\n\nexport const TopSolutionsDesignSystem: Plugin = {\n install(app: App) {\n app.component('TopButton', TopButton)\n },\n}\n"],"mappings":";;AASA,IAAa,IAAmC,EAC9C,QAAQ,GAAU;CAChB,EAAI,UAAU,aAAa,CAAS;AACtC,EACF"}
|
package/dist/style.css
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
.h-fit{height:fit-content}.w-fit{width:fit-content}.shrink-0{flex-shrink:0}.rounded-\[10px\]{border-radius:10px}.rounded-\[12px\]{border-radius:12px}.border{border-width:1px}.\!border-primary-900{border-color:var(--top-primary-900)!important}.border-primary-800{border-color:var(--top-primary-800)}.bg-primary-900{background-color:var(--top-primary-900)}.bg-transparent{background-color:#0000}.px-2{padding-left:.5rem;padding-right:.5rem}.px-3{padding-left:.75rem;padding-right:.75rem}.px-4{padding-left:1rem;padding-right:1rem}.py-2{padding-top:.5rem;padding-bottom:.5rem}.font-bold{font-weight:700}.text-primary-800{color:var(--top-primary-800)}.text-white{--tw-text-opacity:1;color:rgb(255 255 255/var(--tw-text-opacity,1))}:root{--top-primary-50:#eef9ff;--top-primary-100:#dff4ff;--top-primary-200:#c5e6f8;--top-primary-300:#8ec4df;--top-primary-400:#66acd1;--top-primary-500:#2488bc;--top-primary-600:#036da3;--top-primary-700:#1b5783;--top-primary-800:#02466b;--top-primary-900:#052f4a;--top-primary-950:#0c192d;--top-secondary-50:#fafafa;--top-secondary-100:#f4f4f5;--top-secondary-200:#e9e9e9;--top-secondary-300:#d8d8d8;--top-secondary-400:#b8b8b8;--top-secondary-500:#8e8e8e;--top-secondary-600:#676767;--top-secondary-700:#4b4b4b;--top-secondary-800:#343434;--top-secondary-900:#1c1917;--top-secondary-950:#0c0a09}.hover\:\!border-primary-800:hover{border-color:var(--top-primary-800)!important}.hover\:bg-primary-50:hover{background-color:var(--top-primary-50)}.hover\:bg-primary-800:hover{background-color:var(--top-primary-800)}
|
|
1
|
+
.h-fit{height:fit-content}.w-fit{width:fit-content}.shrink-0{flex-shrink:0}.rounded-\[10px\]{border-radius:10px}.rounded-\[12px\]{border-radius:12px}.border{border-width:1px}.\!border-primary-900{border-color:var(--top-primary-900)!important}.border-primary-800{border-color:var(--top-primary-800)}.bg-primary-900{background-color:var(--top-primary-900)}.bg-transparent{background-color:#0000}.px-2{padding-left:.5rem;padding-right:.5rem}.px-3{padding-left:.75rem;padding-right:.75rem}.px-4{padding-left:1rem;padding-right:1rem}.py-2{padding-top:.5rem;padding-bottom:.5rem}.text-xs{font-size:.75rem;line-height:1rem}.font-bold{font-weight:700}.text-primary-800{color:var(--top-primary-800)}.text-white{--tw-text-opacity:1;color:rgb(255 255 255/var(--tw-text-opacity,1))}:root{--top-primary-50:#eef9ff;--top-primary-100:#dff4ff;--top-primary-200:#c5e6f8;--top-primary-300:#8ec4df;--top-primary-400:#66acd1;--top-primary-500:#2488bc;--top-primary-600:#036da3;--top-primary-700:#1b5783;--top-primary-800:#02466b;--top-primary-900:#052f4a;--top-primary-950:#0c192d;--top-secondary-50:#fafafa;--top-secondary-100:#f4f4f5;--top-secondary-200:#e9e9e9;--top-secondary-300:#d8d8d8;--top-secondary-400:#b8b8b8;--top-secondary-500:#8e8e8e;--top-secondary-600:#676767;--top-secondary-700:#4b4b4b;--top-secondary-800:#343434;--top-secondary-900:#1c1917;--top-secondary-950:#0c0a09}.hover\:\!border-primary-800:hover{border-color:var(--top-primary-800)!important}.hover\:bg-primary-50:hover{background-color:var(--top-primary-50)}.hover\:bg-primary-800:hover{background-color:var(--top-primary-800)}
|
|
2
2
|
/*$vite$:1*/
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@topjoao/top-design-system",
|
|
3
|
-
"version": "0.1.0-beta.
|
|
3
|
+
"version": "0.1.0-beta.2",
|
|
4
4
|
"description": "Design system e biblioteca de componentes Vue da TopSolutions",
|
|
5
5
|
"private": false,
|
|
6
6
|
"type": "module",
|
|
@@ -25,6 +25,15 @@
|
|
|
25
25
|
"import": "./dist/index.js",
|
|
26
26
|
"require": "./dist/index.cjs"
|
|
27
27
|
},
|
|
28
|
+
"./plugin": {
|
|
29
|
+
"types": "./dist/plugin.d.ts",
|
|
30
|
+
"import": "./dist/plugin.js",
|
|
31
|
+
"require": "./dist/plugin.cjs"
|
|
32
|
+
},
|
|
33
|
+
"./nuxt": {
|
|
34
|
+
"types": "./dist/nuxt.d.ts",
|
|
35
|
+
"import": "./dist/nuxt.js"
|
|
36
|
+
},
|
|
28
37
|
"./style.css": "./dist/style.css"
|
|
29
38
|
},
|
|
30
39
|
"scripts": {
|
|
@@ -37,15 +46,23 @@
|
|
|
37
46
|
"prepack": "npm run check"
|
|
38
47
|
},
|
|
39
48
|
"peerDependencies": {
|
|
49
|
+
"@nuxt/kit": "^3.0.0 || ^4.0.0",
|
|
40
50
|
"@primeuix/themes": "^1.2.0",
|
|
41
51
|
"primeicons": "^7.0.0",
|
|
42
52
|
"primevue": "^4.4.0",
|
|
43
53
|
"vue": "^3.5.0"
|
|
44
54
|
},
|
|
55
|
+
"peerDependenciesMeta": {
|
|
56
|
+
"@nuxt/kit": {
|
|
57
|
+
"optional": true
|
|
58
|
+
}
|
|
59
|
+
},
|
|
45
60
|
"dependencies": {
|
|
46
61
|
"tailwind-merge": "^3.6.0"
|
|
47
62
|
},
|
|
48
63
|
"devDependencies": {
|
|
64
|
+
"@nuxt/kit": "^4.2.1",
|
|
65
|
+
"@nuxt/schema": "^4.2.1",
|
|
49
66
|
"@primeuix/themes": "^1.2.5",
|
|
50
67
|
"@types/node": "^24.13.3",
|
|
51
68
|
"@vitejs/plugin-vue": "^6.0.8",
|