@up-packages/ui 0.1.1-qa.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/LICENSE +22 -0
- package/README.md +360 -0
- package/dist/components/UpAccordion/UpAccordion.vue.d.ts +26 -0
- package/dist/components/UpAccordion/index.d.ts +2 -0
- package/dist/components/UpBadge/UpBadge.vue.d.ts +41 -0
- package/dist/components/UpBadge/index.d.ts +2 -0
- package/dist/components/UpButton/UpButton.vue.d.ts +30 -0
- package/dist/components/UpButton/index.d.ts +2 -0
- package/dist/components/UpCalendar/UpCalendar.vue.d.ts +35 -0
- package/dist/components/UpCalendar/index.d.ts +2 -0
- package/dist/components/UpCard/UpCard.vue.d.ts +20 -0
- package/dist/components/UpCard/UpCardIndicator.vue.d.ts +17 -0
- package/dist/components/UpCard/UpCardInfo.vue.d.ts +16 -0
- package/dist/components/UpCard/UpCardInteractive.vue.d.ts +23 -0
- package/dist/components/UpCard/UpCardItem.vue.d.ts +15 -0
- package/dist/components/UpCard/UpCardList.vue.d.ts +12 -0
- package/dist/components/UpCard/UpCardNode.vue.d.ts +21 -0
- package/dist/components/UpCard/UpCardProduct.vue.d.ts +16 -0
- package/dist/components/UpCard/index.d.ts +9 -0
- package/dist/components/UpCard/types.d.ts +33 -0
- package/dist/components/UpCell/UpCell.vue.d.ts +17 -0
- package/dist/components/UpCell/index.d.ts +6 -0
- package/dist/components/UpCell/types.d.ts +24 -0
- package/dist/components/UpCheckbox/UpCheckbox.vue.d.ts +11 -0
- package/dist/components/UpCheckbox/index.d.ts +6 -0
- package/dist/components/UpCheckbox/types.d.ts +31 -0
- package/dist/components/UpDataTable/UpDataTable.vue.d.ts +70 -0
- package/dist/components/UpDataTable/index.d.ts +2 -0
- package/dist/components/UpDatePicker/UpDatePicker.vue.d.ts +59 -0
- package/dist/components/UpDatePicker/index.d.ts +2 -0
- package/dist/components/UpDivider/UpDivider.vue.d.ts +5 -0
- package/dist/components/UpDivider/index.d.ts +2 -0
- package/dist/components/UpDivider/types.d.ts +7 -0
- package/dist/components/UpEnvironmentBadge/UpEnvironmentBadge.vue.d.ts +2 -0
- package/dist/components/UpEnvironmentBadge/index.d.ts +1 -0
- package/dist/components/UpFloatMenu/UpFloatMenu.vue.d.ts +16 -0
- package/dist/components/UpFloatMenu/index.d.ts +2 -0
- package/dist/components/UpFloatMenu/types.d.ts +41 -0
- package/dist/components/UpNotification/UpNotification.vue.d.ts +11 -0
- package/dist/components/UpNotification/index.d.ts +2 -0
- package/dist/components/UpPagination/UpPagination.vue.d.ts +26 -0
- package/dist/components/UpPagination/index.d.ts +2 -0
- package/dist/components/UpPagination/types.d.ts +20 -0
- package/dist/components/UpProduct/UpProduct.vue.d.ts +3 -0
- package/dist/components/UpProduct/index.d.ts +2 -0
- package/dist/components/UpProduct/types.d.ts +7 -0
- package/dist/components/UpRadio/UpRadio.vue.d.ts +52 -0
- package/dist/components/UpRadio/index.d.ts +2 -0
- package/dist/components/UpSelect/UpSelect.vue.d.ts +97 -0
- package/dist/components/UpSelect/index.d.ts +2 -0
- package/dist/components/UpSelect/types.d.ts +38 -0
- package/dist/components/UpSideBar/UpSideBar.vue.d.ts +23 -0
- package/dist/components/UpSideBar/index.d.ts +2 -0
- package/dist/components/UpSideBar/types.d.ts +11 -0
- package/dist/components/UpStepper/UpStepper.vue.d.ts +11 -0
- package/dist/components/UpStepper/index.d.ts +2 -0
- package/dist/components/UpStepper/types.d.ts +9 -0
- package/dist/components/UpSwitch/UpSwitch.vue.d.ts +15 -0
- package/dist/components/UpSwitch/index.d.ts +2 -0
- package/dist/components/UpTab/UpTab.vue.d.ts +13 -0
- package/dist/components/UpTab/index.d.ts +2 -0
- package/dist/components/UpTab/types.d.ts +11 -0
- package/dist/components/UpTextField/UpTextField.vue.d.ts +73 -0
- package/dist/components/UpTextField/index.d.ts +2 -0
- package/dist/components/UpTitleBar/UpTitleBar.vue.d.ts +13 -0
- package/dist/components/UpTitleBar/index.d.ts +2 -0
- package/dist/components/UpTitleBar/types.d.ts +9 -0
- package/dist/components/UpToast/UpToast.vue.d.ts +44 -0
- package/dist/components/UpToast/index.d.ts +2 -0
- package/dist/components/UpTooltip/UpTooltip.vue.d.ts +19 -0
- package/dist/components/UpTooltip/index.d.ts +2 -0
- package/dist/components/UpTooltip/types.d.ts +6 -0
- package/dist/components/UpWindow/UpWindow.vue.d.ts +22 -0
- package/dist/components/UpWindow/index.d.ts +2 -0
- package/dist/components/UpWindow/types.d.ts +16 -0
- package/dist/components/index.d.ts +50 -0
- package/dist/composables/index.d.ts +6 -0
- package/dist/composables/useToast.d.ts +40 -0
- package/dist/config/environments.d.ts +26 -0
- package/dist/directives/index.d.ts +21 -0
- package/dist/directives/textFormat.d.ts +15 -0
- package/dist/index.d.ts +10 -0
- package/dist/install.d.ts +35 -0
- package/dist/plugins/vuetify.d.ts +142 -0
- package/dist/uplexis-ui.css +5 -0
- package/dist/uplexis-ui.js +15474 -0
- package/dist/uplexis-ui.js.map +1 -0
- package/dist/uplexis-ui.umd.cjs +5 -0
- package/dist/uplexis-ui.umd.cjs.map +1 -0
- package/dist/utils/formatters.d.ts +49 -0
- package/dist/utils/helpers.d.ts +19 -0
- package/dist/utils/index.d.ts +6 -0
- package/package.json +82 -0
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Formatadores de dados
|
|
3
|
+
* Compatível com @aplicativo/uplexis-ui v1.7.7
|
|
4
|
+
*/
|
|
5
|
+
/**
|
|
6
|
+
* Formata CPF
|
|
7
|
+
* @param text - CPF sem formatação (11 dígitos)
|
|
8
|
+
* @returns CPF formatado (123.456.789-00)
|
|
9
|
+
* @example
|
|
10
|
+
* formatCPF('12345678900') // '123.456.789-00'
|
|
11
|
+
*/
|
|
12
|
+
export declare function formatCPF(text: string): string;
|
|
13
|
+
/**
|
|
14
|
+
* Formata CNPJ
|
|
15
|
+
* @param text - CNPJ sem formatação (14 dígitos)
|
|
16
|
+
* @returns CNPJ formatado (12.345.678/0001-90)
|
|
17
|
+
* @example
|
|
18
|
+
* formatCNPJ('12345678000190') // '12.345.678/0001-90'
|
|
19
|
+
*/
|
|
20
|
+
export declare function formatCNPJ(text: string): string;
|
|
21
|
+
/**
|
|
22
|
+
* Formata moeda (Real Brasileiro)
|
|
23
|
+
* @param text - Valor numérico ou string
|
|
24
|
+
* @param el - Elemento HTML (opcional, para aplicar cor vermelha em valores negativos)
|
|
25
|
+
* @returns Valor formatado (R$ 1.234,56)
|
|
26
|
+
* @example
|
|
27
|
+
* formatCurrency('1234.56') // 'R$ 1.234,56'
|
|
28
|
+
* formatCurrency('-1234.56') // 'R$ -1.234,56' (com cor vermelha se el fornecido)
|
|
29
|
+
*/
|
|
30
|
+
export declare function formatCurrency(text: string | number, el?: HTMLElement): string;
|
|
31
|
+
/**
|
|
32
|
+
* Formata data
|
|
33
|
+
* @param text - Data sem formatação (DDMMYYYY ou DDMMYY)
|
|
34
|
+
* @returns Data formatada (DD/MM/YYYY)
|
|
35
|
+
* @example
|
|
36
|
+
* formatDate('01012024') // '01/01/2024'
|
|
37
|
+
* formatDate('010124') // '01/01/2024'
|
|
38
|
+
*/
|
|
39
|
+
export declare function formatDate(text: string): string;
|
|
40
|
+
/**
|
|
41
|
+
* Objeto formatters para compatibilidade com biblioteca antiga
|
|
42
|
+
*/
|
|
43
|
+
export declare const formatters: {
|
|
44
|
+
cpf: typeof formatCPF;
|
|
45
|
+
cnpj: typeof formatCNPJ;
|
|
46
|
+
currency: typeof formatCurrency;
|
|
47
|
+
date: typeof formatDate;
|
|
48
|
+
};
|
|
49
|
+
export default formatters;
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Funções auxiliares (helpers)
|
|
3
|
+
* Compatível com @aplicativo/uplexis-ui v1.7.7
|
|
4
|
+
*/
|
|
5
|
+
/**
|
|
6
|
+
* Trunca texto adicionando reticências
|
|
7
|
+
* @param text - Texto a ser truncado
|
|
8
|
+
* @param from - Posição inicial (geralmente 0)
|
|
9
|
+
* @param limit - Limite de caracteres
|
|
10
|
+
* @returns Texto truncado com "..." no final
|
|
11
|
+
* @example
|
|
12
|
+
* truncateText('Texto muito longo', 0, 10) // 'Texto muit...'
|
|
13
|
+
* truncateText('Curto', 0, 10) // 'Curto'
|
|
14
|
+
*/
|
|
15
|
+
export declare function truncateText(text: string, from: number, limit: number): string;
|
|
16
|
+
declare const _default: {
|
|
17
|
+
truncateText: typeof truncateText;
|
|
18
|
+
};
|
|
19
|
+
export default _default;
|
package/package.json
ADDED
|
@@ -0,0 +1,82 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "@up-packages/ui",
|
|
3
|
+
"version": "0.1.1-qa.0",
|
|
4
|
+
"type": "module",
|
|
5
|
+
"private": false,
|
|
6
|
+
"description": "Biblioteca de componentes Vue 3 + Vuetify para Uplexis",
|
|
7
|
+
"author": "Uplexis",
|
|
8
|
+
"license": "MIT",
|
|
9
|
+
"keywords": [
|
|
10
|
+
"vue",
|
|
11
|
+
"vuetify",
|
|
12
|
+
"components",
|
|
13
|
+
"ui-library",
|
|
14
|
+
"uplexis"
|
|
15
|
+
],
|
|
16
|
+
"files": [
|
|
17
|
+
"dist"
|
|
18
|
+
],
|
|
19
|
+
"exports": {
|
|
20
|
+
".": {
|
|
21
|
+
"types": "./dist/index.d.ts",
|
|
22
|
+
"import": "./dist/uplexis-ui.js",
|
|
23
|
+
"default": "./dist/uplexis-ui.js"
|
|
24
|
+
},
|
|
25
|
+
"./styles.css": "./dist/style.css"
|
|
26
|
+
},
|
|
27
|
+
"main": "dist/uplexis-ui.js",
|
|
28
|
+
"module": "dist/uplexis-ui.js",
|
|
29
|
+
"types": "dist/index.d.ts",
|
|
30
|
+
"scripts": {
|
|
31
|
+
"dev": "vite",
|
|
32
|
+
"build": "vite build && vue-tsc --project tsconfig.build.json",
|
|
33
|
+
"preview": "vite preview",
|
|
34
|
+
"storybook": "storybook dev -p 6006",
|
|
35
|
+
"build:storybook": "storybook build",
|
|
36
|
+
"test": "vitest",
|
|
37
|
+
"test:ui": "vitest --ui",
|
|
38
|
+
"lint": "eslint . --ext .vue,.js,.jsx,.cjs,.mjs,.ts,.tsx,.cts,.mts --fix --ignore-path .gitignore",
|
|
39
|
+
"type-check": "vue-tsc --noEmit",
|
|
40
|
+
"build:qa": "vite build --mode qa && vue-tsc --project tsconfig.build.json",
|
|
41
|
+
"build:staging": "vite build --mode staging && vue-tsc --project tsconfig.build.json",
|
|
42
|
+
"build:production": "vite build --mode production && vue-tsc --project tsconfig.build.json",
|
|
43
|
+
"publish:qa": "npm run build:qa && npm version prerelease --preid=qa && npm publish --tag qa --access public",
|
|
44
|
+
"publish:staging": "npm run build:staging && npm version prerelease --preid=rc && npm publish --tag next --access public",
|
|
45
|
+
"publish:production": "npm run build:production && npm version patch && npm publish --tag latest --access public",
|
|
46
|
+
"version:patch": "npm version patch",
|
|
47
|
+
"version:minor": "npm version minor",
|
|
48
|
+
"version:major": "npm version major"
|
|
49
|
+
},
|
|
50
|
+
"peerDependencies": {
|
|
51
|
+
"vue": "^3.4.0",
|
|
52
|
+
"vuetify": "^3.6.0"
|
|
53
|
+
},
|
|
54
|
+
"devDependencies": {
|
|
55
|
+
"@mdi/font": "^7.4.47",
|
|
56
|
+
"@storybook/addon-essentials": "^8.4.0",
|
|
57
|
+
"@storybook/addon-interactions": "^8.4.0",
|
|
58
|
+
"@storybook/addon-links": "^8.4.0",
|
|
59
|
+
"@storybook/blocks": "^8.4.0",
|
|
60
|
+
"@storybook/test": "^8.4.0",
|
|
61
|
+
"@storybook/vue3": "^8.4.0",
|
|
62
|
+
"@storybook/vue3-vite": "^8.4.0",
|
|
63
|
+
"@types/node": "^20.11.0",
|
|
64
|
+
"@vitejs/plugin-vue": "^5.0.0",
|
|
65
|
+
"@vitest/ui": "^4.0.8",
|
|
66
|
+
"@vue/test-utils": "^2.4.0",
|
|
67
|
+
"jsdom": "^27.1.0",
|
|
68
|
+
"sass": "^1.77.0",
|
|
69
|
+
"storybook": "^8.4.0",
|
|
70
|
+
"typescript": "^5.6.0",
|
|
71
|
+
"vite": "^6.4.1",
|
|
72
|
+
"vite-plugin-vuetify": "^2.0.0",
|
|
73
|
+
"vitest": "^4.0.8",
|
|
74
|
+
"vue": "^3.4.0",
|
|
75
|
+
"vue-tsc": "^2.0.0",
|
|
76
|
+
"vuetify": "^3.6.0"
|
|
77
|
+
},
|
|
78
|
+
"dependencies": {
|
|
79
|
+
"@iconify/vue": "^5.0.0",
|
|
80
|
+
"v-mask": "^2.3.0"
|
|
81
|
+
}
|
|
82
|
+
}
|