maz-ui 3.9.0 → 3.10.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/components/MazAvatar.mjs +22 -185
- package/components/MazAvatar.umd.js +2 -2
- package/components/MazBackdrop.mjs +1 -1
- package/components/MazBackdrop.umd.js +1 -1
- package/components/MazBadge.mjs +3 -3
- package/components/MazBadge.umd.js +2 -2
- package/components/MazBottomSheet.mjs +60 -33
- package/components/MazBottomSheet.umd.js +2 -2
- package/components/MazBtn.mjs +25 -20
- package/components/MazBtn.umd.js +2 -2
- package/components/MazCard.mjs +255 -231
- package/components/MazCard.umd.js +2 -2
- package/components/MazCarousel.mjs +93 -38
- package/components/MazCarousel.umd.js +2 -2
- package/components/MazChart.mjs +43 -25
- package/components/MazChart.umd.js +1 -2
- package/components/MazCheckbox.mjs +3 -3
- package/components/MazCheckbox.umd.js +2 -2
- package/components/MazDialog.mjs +61 -34
- package/components/MazDialog.umd.js +2 -2
- package/components/MazDialogPromise.mjs +75 -58
- package/components/MazDialogPromise.umd.js +2 -2
- package/components/MazDrawer.mjs +57 -30
- package/components/MazDrawer.umd.js +2 -2
- package/components/MazDropzone.mjs +4 -4
- package/components/MazDropzone.umd.js +2 -2
- package/components/MazGallery.mjs +16 -181
- package/components/MazGallery.umd.js +2 -2
- package/components/MazIcon.mjs +7 -2
- package/components/MazIcon.umd.js +2 -2
- package/components/MazInput.mjs +46 -40
- package/components/MazInput.umd.js +2 -2
- package/components/MazInputNumber.mjs +175 -125
- package/components/MazInputNumber.umd.js +2 -2
- package/components/MazInputPrice.mjs +97 -91
- package/components/MazInputPrice.umd.js +2 -2
- package/components/MazInputTags.mjs +135 -107
- package/components/MazInputTags.umd.js +2 -2
- package/components/MazLazyImg.mjs +9 -9
- package/components/MazLazyImg.umd.js +2 -2
- package/components/MazPhoneNumberInput.mjs +165 -90
- package/components/MazPhoneNumberInput.umd.js +2 -2
- package/components/MazPicker.mjs +349 -261
- package/components/MazPicker.umd.js +2 -2
- package/components/MazRadioButtons.mjs +3 -3
- package/components/MazRadioButtons.umd.js +2 -2
- package/components/MazSelect.mjs +155 -80
- package/components/MazSelect.umd.js +2 -2
- package/components/MazSlider.mjs +6 -6
- package/components/MazSlider.umd.js +2 -2
- package/components/MazSpinner.mjs +4 -4
- package/components/MazSpinner.umd.js +2 -2
- package/components/MazStepper.mjs +16 -11
- package/components/MazStepper.umd.js +2 -2
- package/components/MazSwitch.mjs +6 -6
- package/components/MazSwitch.umd.js +2 -2
- package/components/MazTabsBar.mjs +29 -24
- package/components/MazTabsBar.umd.js +2 -2
- package/components/MazTabsContent.mjs +7 -2
- package/components/MazTabsContent.umd.js +2 -2
- package/components/MazTabsContentItem.mjs +5 -5
- package/components/MazTabsContentItem.umd.js +2 -2
- package/components/MazTextarea.mjs +26 -17
- package/components/MazTextarea.umd.js +2 -2
- package/components/MazTransitionExpand.mjs +3 -3
- package/components/MazTransitionExpand.umd.js +2 -2
- package/components/assets/check-ac2fdfbb.mjs +31 -0
- package/components/assets/eye-ac35bb54.mjs +44 -0
- package/components/assets/eye-off-4a5fd13d.mjs +31 -0
- package/components/assets/no-photography-7a1e4d68.mjs +36 -0
- package/components/assets/pencil-c1aa23f9.mjs +31 -0
- package/modules/assets/no-photography-7a1e4d68.mjs +36 -0
- package/modules/{maz-ui.mjs → index.mjs} +130 -191
- package/modules/index.umd.js +2 -0
- package/nuxt/index.ts +130 -0
- package/nuxt/runtime/composables/use-toast.ts +8 -0
- package/nuxt/runtime/plugins/toaster.ts +26 -0
- package/package.json +91 -62
- package/tailwindcss/{tailwind.config.js → tailwind.config.ts} +13 -9
- package/tailwindcss/tailwind.css +4 -0
- package/tailwindcss/utils/colors.ts +20 -0
- package/tailwindcss/variables/{breakpoints.js → breakpoints.ts} +1 -1
- package/tailwindcss/variables/colors.ts +44 -0
- package/tailwindcss/variables/{utilities.js → utilities.ts} +1 -1
- package/tailwindcss/variables/{z-indexes.js → z-indexes.ts} +1 -1
- package/components/MazAvatar.d.ts +0 -161
- package/components/MazBackdrop.d.ts +0 -92
- package/components/MazBadge.d.ts +0 -78
- package/components/MazBottomSheet.d.ts +0 -41
- package/components/MazBtn.d.ts +0 -183
- package/components/MazCard.d.ts +0 -199
- package/components/MazCarousel.d.ts +0 -29
- package/components/MazChart.d.ts +0 -22
- package/components/MazCheckbox.d.ts +0 -59
- package/components/MazDialog.d.ts +0 -96
- package/components/MazDialogPromise/use-maz-dialog-promise.d.ts +0 -30
- package/components/MazDialogPromise.d.ts +0 -77
- package/components/MazDrawer.d.ts +0 -74
- package/components/MazDropzone.d.ts +0 -129
- package/components/MazGallery.d.ts +0 -126
- package/components/MazIcon.d.ts +0 -65
- package/components/MazInput.d.ts +0 -277
- package/components/MazInputNumber.d.ts +0 -66
- package/components/MazInputPrice.d.ts +0 -74
- package/components/MazInputTags.d.ts +0 -95
- package/components/MazLazyImg.d.ts +0 -82
- package/components/MazPhoneNumberInput/constantes/locales.d.ts +0 -12
- package/components/MazPhoneNumberInput/types.d.ts +0 -21
- package/components/MazPhoneNumberInput/utils/countries-name-list-by-iso-code.d.ts +0 -2
- package/components/MazPhoneNumberInput/utils/index.d.ts +0 -12
- package/components/MazPhoneNumberInput.d.ts +0 -254
- package/components/MazPicker/MazPickerCalendar.vue.d.ts +0 -136
- package/components/MazPicker/MazPickerCalendarMonth/MazPickerCalendarDays.vue.d.ts +0 -21
- package/components/MazPicker/MazPickerCalendarMonth/MazPickerCalendarGrid.vue.d.ts +0 -113
- package/components/MazPicker/MazPickerCalendarMonth/MazPickerCalendarMonth.vue.d.ts +0 -123
- package/components/MazPicker/MazPickerCalendarSwitcher.vue.d.ts +0 -37
- package/components/MazPicker/MazPickerContainer.vue.d.ts +0 -211
- package/components/MazPicker/MazPickerFooter.vue.d.ts +0 -17
- package/components/MazPicker/MazPickerHeader.vue.d.ts +0 -83
- package/components/MazPicker/MazPickerMonthSwitcher.vue.d.ts +0 -42
- package/components/MazPicker/MazPickerShortcuts.vue.d.ts +0 -61
- package/components/MazPicker/MazPickerTime.vue.d.ts +0 -128
- package/components/MazPicker/MazPickerYearSwitcher.vue.d.ts +0 -34
- package/components/MazPicker/types.d.ts +0 -15
- package/components/MazPicker/utils.d.ts +0 -54
- package/components/MazPicker.d.ts +0 -312
- package/components/MazRadioButtons.d.ts +0 -82
- package/components/MazSelect.d.ts +0 -191
- package/components/MazSlider/utils.d.ts +0 -15
- package/components/MazSlider.d.ts +0 -95
- package/components/MazSpinner.d.ts +0 -29
- package/components/MazStepper.d.ts +0 -119
- package/components/MazSwitch.d.ts +0 -55
- package/components/MazTabsBar.d.ts +0 -48
- package/components/MazTabsContent.d.ts +0 -26
- package/components/MazTabsContentItem.d.ts +0 -24
- package/components/MazTextarea/textarea-autogrow.d.ts +0 -9
- package/components/MazTextarea.d.ts +0 -124
- package/components/MazTransitionExpand.d.ts +0 -14
- package/components/assets/no-photography-584c6185.mjs +0 -4
- package/components/index.d.ts +0 -33
- package/components/index.mjs +0 -35
- package/components/types.d.ts +0 -17
- package/css/aos.css +0 -1
- package/css/main.css +0 -1
- package/maz-ui.d.ts +0 -318
- package/modules/assets/no-photography-584c6185.mjs +0 -4
- package/modules/maz-ui.umd.js +0 -2
- package/tailwindcss/utils/colors.js +0 -26
- package/tailwindcss/variables/colors.js +0 -44
package/nuxt/index.ts
ADDED
|
@@ -0,0 +1,130 @@
|
|
|
1
|
+
import { defineNuxtModule, addPlugin, createResolver, addImports, addComponent } from '@nuxt/kit'
|
|
2
|
+
import { defu } from 'defu'
|
|
3
|
+
import { componentList } from '../components/component-list'
|
|
4
|
+
import { dirname } from 'node:path'
|
|
5
|
+
import { fileURLToPath } from 'node:url'
|
|
6
|
+
|
|
7
|
+
export interface MazUiNuxtOptions {
|
|
8
|
+
/**
|
|
9
|
+
* Install the toaster plugin and enable auto import of toaster composable
|
|
10
|
+
*/
|
|
11
|
+
injectToaster?: boolean
|
|
12
|
+
/**
|
|
13
|
+
* Enable auto import of useCurrency composable
|
|
14
|
+
*/
|
|
15
|
+
injectUseCurrency?: boolean
|
|
16
|
+
/**
|
|
17
|
+
* Enable auto import of useTheme composable
|
|
18
|
+
*/
|
|
19
|
+
injectUseTheme?: boolean
|
|
20
|
+
/**
|
|
21
|
+
* install global of v-fullscreen-img directive
|
|
22
|
+
*/
|
|
23
|
+
installFullscreenImgDirective?: boolean
|
|
24
|
+
/**
|
|
25
|
+
* Enable auto import of all components
|
|
26
|
+
* @default true
|
|
27
|
+
*/
|
|
28
|
+
injectComponents?: boolean
|
|
29
|
+
/**
|
|
30
|
+
* Enable Nuxt Devtools integration
|
|
31
|
+
* @default true
|
|
32
|
+
*/
|
|
33
|
+
devtools?: boolean
|
|
34
|
+
}
|
|
35
|
+
|
|
36
|
+
declare module '@nuxt/schema' {
|
|
37
|
+
interface PublicRuntimeConfig {
|
|
38
|
+
mazUi?: MazUiNuxtOptions
|
|
39
|
+
}
|
|
40
|
+
interface NuxtConfig {
|
|
41
|
+
mazUi?: MazUiNuxtOptions
|
|
42
|
+
}
|
|
43
|
+
interface NuxtOptions {
|
|
44
|
+
mazUi?: MazUiNuxtOptions
|
|
45
|
+
}
|
|
46
|
+
}
|
|
47
|
+
|
|
48
|
+
const _dirname = dirname(fileURLToPath(import.meta.url))
|
|
49
|
+
|
|
50
|
+
export default defineNuxtModule<MazUiNuxtOptions>({
|
|
51
|
+
meta: {
|
|
52
|
+
name: 'maz-ui/nuxt',
|
|
53
|
+
configKey: 'mazUi',
|
|
54
|
+
compatibility: {
|
|
55
|
+
nuxt: '^3.0.0',
|
|
56
|
+
},
|
|
57
|
+
},
|
|
58
|
+
defaults: {
|
|
59
|
+
devtools: true,
|
|
60
|
+
injectComponents: true,
|
|
61
|
+
},
|
|
62
|
+
setup(options, nuxt) {
|
|
63
|
+
const resolver = createResolver(import.meta.url)
|
|
64
|
+
|
|
65
|
+
const moduleOptions = defu(nuxt.options.runtimeConfig.public.mazUi, options)
|
|
66
|
+
|
|
67
|
+
nuxt.options.runtimeConfig.public.mazUi = moduleOptions
|
|
68
|
+
|
|
69
|
+
if (moduleOptions.injectComponents) {
|
|
70
|
+
for (const componentName of componentList) {
|
|
71
|
+
addComponent({
|
|
72
|
+
name: componentName,
|
|
73
|
+
filePath:
|
|
74
|
+
process.env.NODE_ENV === 'prodution'
|
|
75
|
+
? `maz-ui/components/${componentName}`
|
|
76
|
+
: `maz-ui/components/${componentName}.vue`,
|
|
77
|
+
})
|
|
78
|
+
}
|
|
79
|
+
}
|
|
80
|
+
|
|
81
|
+
if (moduleOptions.injectToaster) {
|
|
82
|
+
addPlugin(resolver.resolve(_dirname, './runtime/plugins/toaster'))
|
|
83
|
+
|
|
84
|
+
addImports({
|
|
85
|
+
from: resolver.resolve(_dirname, './runtime/composables/use-toast'),
|
|
86
|
+
name: 'useToast',
|
|
87
|
+
as: 'useToast',
|
|
88
|
+
})
|
|
89
|
+
}
|
|
90
|
+
|
|
91
|
+
if (moduleOptions.injectUseCurrency) {
|
|
92
|
+
addImports({
|
|
93
|
+
from: 'maz-ui',
|
|
94
|
+
name: 'useCurrency',
|
|
95
|
+
as: 'useCurrency',
|
|
96
|
+
})
|
|
97
|
+
}
|
|
98
|
+
|
|
99
|
+
if (moduleOptions.injectUseTheme) {
|
|
100
|
+
addImports({
|
|
101
|
+
from: 'maz-ui',
|
|
102
|
+
name: 'useTheme',
|
|
103
|
+
as: 'useTheme',
|
|
104
|
+
})
|
|
105
|
+
}
|
|
106
|
+
|
|
107
|
+
if (moduleOptions.installFullscreenImgDirective) {
|
|
108
|
+
addPlugin(resolver.resolve(_dirname, './runtime/plugins/v-fullscreen-img'))
|
|
109
|
+
}
|
|
110
|
+
|
|
111
|
+
if (options.devtools) {
|
|
112
|
+
// @ts-expect-error - private API
|
|
113
|
+
nuxt.hook('devtools:customTabs', (iframeTabs) => {
|
|
114
|
+
iframeTabs.push({
|
|
115
|
+
// unique identifier
|
|
116
|
+
name: 'maz-ui',
|
|
117
|
+
// title to display in the tab
|
|
118
|
+
title: 'maz-ui',
|
|
119
|
+
// any icon from Iconify, or a URL to an image
|
|
120
|
+
icon: 'https://louismazel.github.io/maz-ui-3/img/icons/android-chrome-512x512.png',
|
|
121
|
+
// iframe view
|
|
122
|
+
view: {
|
|
123
|
+
type: 'iframe',
|
|
124
|
+
src: 'https://louismazel.github.io/maz-ui-3',
|
|
125
|
+
},
|
|
126
|
+
})
|
|
127
|
+
})
|
|
128
|
+
}
|
|
129
|
+
},
|
|
130
|
+
})
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
import { ToasterHandler } from './../../../modules'
|
|
2
|
+
import { defineNuxtPlugin } from 'nuxt/app'
|
|
3
|
+
|
|
4
|
+
export default defineNuxtPlugin(({ vueApp }) => {
|
|
5
|
+
const instance = new ToasterHandler(vueApp, {
|
|
6
|
+
position: 'top',
|
|
7
|
+
timeout: 10_000,
|
|
8
|
+
persistent: false,
|
|
9
|
+
})
|
|
10
|
+
|
|
11
|
+
/* eslint-disable @typescript-eslint/no-empty-function */
|
|
12
|
+
const toasterServer = {
|
|
13
|
+
show: () => {},
|
|
14
|
+
success: () => {},
|
|
15
|
+
error: () => {},
|
|
16
|
+
warning: () => {},
|
|
17
|
+
info: () => {},
|
|
18
|
+
} as unknown as ToasterHandler
|
|
19
|
+
/* eslint-enable @typescript-eslint/no-empty-function */
|
|
20
|
+
|
|
21
|
+
return {
|
|
22
|
+
provide: {
|
|
23
|
+
toast: (process.client ? instance : toasterServer) as ToasterHandler,
|
|
24
|
+
},
|
|
25
|
+
}
|
|
26
|
+
})
|
package/package.json
CHANGED
|
@@ -1,19 +1,27 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "maz-ui",
|
|
3
|
-
"version": "3.
|
|
3
|
+
"version": "3.10.0",
|
|
4
4
|
"description": "A standalone components library for Vue.Js 3 & Nuxt.Js 3",
|
|
5
5
|
"author": "Louis Mazel <me@loicmazuel.com>",
|
|
6
|
-
"main": "modules/
|
|
7
|
-
"module": "modules/
|
|
8
|
-
"types": "
|
|
6
|
+
"main": "./modules/index.mjs",
|
|
7
|
+
"module": "./modules/index.mjs",
|
|
8
|
+
"types": "./modules/index.d.ts",
|
|
9
|
+
"exports": {
|
|
10
|
+
".": {
|
|
11
|
+
"default": "./modules/index.mjs",
|
|
12
|
+
"types": "./modules/index.d.ts"
|
|
13
|
+
},
|
|
14
|
+
"./*": "./*",
|
|
15
|
+
"./components": "./components/index.mjs",
|
|
16
|
+
"./components/*": "./components/*",
|
|
17
|
+
"./nuxt": "./nuxt/index.ts"
|
|
18
|
+
},
|
|
9
19
|
"files": [
|
|
10
20
|
"components",
|
|
11
21
|
"modules",
|
|
12
22
|
"css",
|
|
13
|
-
"
|
|
14
|
-
"
|
|
15
|
-
"tailwindcss/utils",
|
|
16
|
-
"tailwindcss/variables"
|
|
23
|
+
"tailwindcss",
|
|
24
|
+
"nuxt"
|
|
17
25
|
],
|
|
18
26
|
"lint-staged": {
|
|
19
27
|
"*": "prettier -w -u",
|
|
@@ -21,10 +29,13 @@
|
|
|
21
29
|
"*.{vue,css,scss,postcss,pcss}": "stylelint --fix"
|
|
22
30
|
},
|
|
23
31
|
"peerDependencies": {
|
|
32
|
+
"@nuxt/kit": "^3.4.0",
|
|
24
33
|
"chart.js": "^4.0.0",
|
|
25
34
|
"dayjs": "^1.1.0",
|
|
35
|
+
"defu": "^6.0.0",
|
|
26
36
|
"dropzone": "^5.9.3",
|
|
27
37
|
"libphonenumber-js": "^1.9.44",
|
|
38
|
+
"nuxt": "^3.4.0",
|
|
28
39
|
"vue": "^3.0.0",
|
|
29
40
|
"vue-router": "^4.0.0"
|
|
30
41
|
},
|
|
@@ -43,82 +54,96 @@
|
|
|
43
54
|
},
|
|
44
55
|
"dayjs": {
|
|
45
56
|
"optional": true
|
|
57
|
+
},
|
|
58
|
+
"nuxt": {
|
|
59
|
+
"optional": true
|
|
60
|
+
},
|
|
61
|
+
"@nuxt/kit": {
|
|
62
|
+
"optional": true
|
|
63
|
+
},
|
|
64
|
+
"defu": {
|
|
65
|
+
"optional": true
|
|
46
66
|
}
|
|
47
67
|
},
|
|
48
68
|
"devDependencies": {
|
|
49
|
-
"@babel/core": "^7.
|
|
50
|
-
"@babel/preset-env": "^7.
|
|
51
|
-
"@babel/preset-typescript": "^7.
|
|
52
|
-
"@
|
|
69
|
+
"@babel/core": "^7.22.11",
|
|
70
|
+
"@babel/preset-env": "^7.22.14",
|
|
71
|
+
"@babel/preset-typescript": "^7.22.11",
|
|
72
|
+
"@nuxt/kit": "^3.7.0",
|
|
73
|
+
"@nuxt/schema": "^3.7.0",
|
|
74
|
+
"@rollup/plugin-typescript": "^11.1.3",
|
|
53
75
|
"@types/dropzone": "^5.7.4",
|
|
54
|
-
"@types/google.maps": "^3.
|
|
55
|
-
"@types/node": "^
|
|
76
|
+
"@types/google.maps": "^3.54.0",
|
|
77
|
+
"@types/node": "^20.5.8",
|
|
56
78
|
"@types/rollup-plugin-peer-deps-external": "^2.2.1",
|
|
57
|
-
"@typescript-eslint/eslint-plugin": "^5.
|
|
58
|
-
"@typescript-eslint/parser": "^5.
|
|
59
|
-
"@vitejs/plugin-vue": "^4.
|
|
60
|
-
"@vitest/coverage-
|
|
61
|
-
"@vue/compiler-sfc": "^3.
|
|
62
|
-
"@vue/eslint-config-prettier": "^
|
|
63
|
-
"@vue/eslint-config-typescript": "^11.0.
|
|
64
|
-
"@vue/test-utils": "^2.
|
|
65
|
-
"@vue/tsconfig": "^0.
|
|
66
|
-
"autoprefixer": "^10.4.
|
|
67
|
-
"c8": "^
|
|
79
|
+
"@typescript-eslint/eslint-plugin": "^6.5.0",
|
|
80
|
+
"@typescript-eslint/parser": "^6.5.0",
|
|
81
|
+
"@vitejs/plugin-vue": "^4.3.4",
|
|
82
|
+
"@vitest/coverage-v8": "^0.34.3",
|
|
83
|
+
"@vue/compiler-sfc": "^3.3.4",
|
|
84
|
+
"@vue/eslint-config-prettier": "^8.0.0",
|
|
85
|
+
"@vue/eslint-config-typescript": "^11.0.3",
|
|
86
|
+
"@vue/test-utils": "^2.4.1",
|
|
87
|
+
"@vue/tsconfig": "^0.4.0",
|
|
88
|
+
"autoprefixer": "^10.4.15",
|
|
89
|
+
"c8": "^8.0.1",
|
|
68
90
|
"chalk": "^4.1.2",
|
|
69
|
-
"chart.js": "^4.
|
|
91
|
+
"chart.js": "^4.4.0",
|
|
70
92
|
"cross-env": "^7.0.3",
|
|
71
|
-
"dayjs": "^1.11.
|
|
93
|
+
"dayjs": "^1.11.9",
|
|
94
|
+
"defu": "^6.1.2",
|
|
72
95
|
"dropzone": "^5.9.3",
|
|
73
|
-
"eslint": "^8.
|
|
74
|
-
"eslint-plugin-prettier": "^
|
|
75
|
-
"eslint-plugin-sonarjs": "^0.
|
|
76
|
-
"eslint-plugin-unicorn": "^
|
|
77
|
-
"eslint-plugin-vue": "^9.
|
|
96
|
+
"eslint": "^8.48.0",
|
|
97
|
+
"eslint-plugin-prettier": "^5.0.0",
|
|
98
|
+
"eslint-plugin-sonarjs": "^0.21.0",
|
|
99
|
+
"eslint-plugin-unicorn": "^48.0.1",
|
|
100
|
+
"eslint-plugin-vue": "^9.17.0",
|
|
78
101
|
"fs": "0.0.2",
|
|
79
|
-
"jsdom": "^
|
|
102
|
+
"jsdom": "^22.1.0",
|
|
80
103
|
"json-templater": "^1.2.0",
|
|
81
|
-
"libphonenumber-js": "^1.10.
|
|
82
|
-
"lint-staged": "^
|
|
104
|
+
"libphonenumber-js": "^1.10.43",
|
|
105
|
+
"lint-staged": "^14.0.1",
|
|
83
106
|
"minimist": "^1.2.8",
|
|
107
|
+
"nuxt": "^3.7.0",
|
|
84
108
|
"onchange": "^7.1.0",
|
|
85
109
|
"path": "^0.12.7",
|
|
86
|
-
"postcss": "^8.4.
|
|
110
|
+
"postcss": "^8.4.29",
|
|
87
111
|
"postcss-html": "^1.5.0",
|
|
88
112
|
"postcss-import": "^15.1.0",
|
|
89
113
|
"postcss-nested": "^6.0.0",
|
|
90
114
|
"postcss-simple-vars": "^7.0.1",
|
|
91
115
|
"postcss-url": "^10.1.3",
|
|
92
|
-
"prettier": "^
|
|
93
|
-
"prettier-plugin-tailwindcss": "^0.
|
|
94
|
-
"replace-in-file": "^
|
|
95
|
-
"rimraf": "^5.0.
|
|
96
|
-
"rollup": "^3.
|
|
97
|
-
"rollup-plugin-dts": "^
|
|
116
|
+
"prettier": "^3.0.3",
|
|
117
|
+
"prettier-plugin-tailwindcss": "^0.5.4",
|
|
118
|
+
"replace-in-file": "^7.0.1",
|
|
119
|
+
"rimraf": "^5.0.1",
|
|
120
|
+
"rollup": "^3.28.1",
|
|
121
|
+
"rollup-plugin-dts": "^6.0.1",
|
|
98
122
|
"rollup-plugin-peer-deps-external": "^2.2.4",
|
|
99
|
-
"sass": "^1.
|
|
100
|
-
"semver": "^7.5.
|
|
101
|
-
"
|
|
102
|
-
"stylelint
|
|
103
|
-
"stylelint-config-
|
|
104
|
-
"stylelint-config-standard
|
|
123
|
+
"sass": "^1.66.1",
|
|
124
|
+
"semver": "^7.5.4",
|
|
125
|
+
"sirv": "^2.0.3",
|
|
126
|
+
"stylelint": "^15.10.3",
|
|
127
|
+
"stylelint-config-recommended-vue": "^1.5.0",
|
|
128
|
+
"stylelint-config-standard": "^34.0.0",
|
|
129
|
+
"stylelint-config-standard-scss": "^10.0.0",
|
|
105
130
|
"stylelint-config-tailwindcss": "^0.0.7",
|
|
106
131
|
"tailwind-css-variables": "^3.0.1",
|
|
107
|
-
"tailwindcss": "^3.3.
|
|
108
|
-
"terser": "^5.
|
|
132
|
+
"tailwindcss": "^3.3.3",
|
|
133
|
+
"terser": "^5.19.3",
|
|
109
134
|
"ts-node": "^10.9.1",
|
|
110
|
-
"typescript": "^5.
|
|
111
|
-
"vite": "^4.
|
|
112
|
-
"vite-plugin-css-injected-by-js": "^3.
|
|
113
|
-
"vite-plugin-static-copy": "^0.
|
|
135
|
+
"typescript": "^5.2.2",
|
|
136
|
+
"vite": "^4.4.9",
|
|
137
|
+
"vite-plugin-css-injected-by-js": "^3.3.0",
|
|
138
|
+
"vite-plugin-static-copy": "^0.17.0",
|
|
114
139
|
"vite-svg-loader": "^4.0.0",
|
|
115
|
-
"vitest": "^0.
|
|
116
|
-
"vitest-canvas-mock": "^0.
|
|
117
|
-
"vue": "^3.
|
|
140
|
+
"vitest": "^0.34.3",
|
|
141
|
+
"vitest-canvas-mock": "^0.3.3",
|
|
142
|
+
"vue": "^3.3.4",
|
|
118
143
|
"vue-chartjs": "^5.2.0",
|
|
119
|
-
"vue-loader": "^17.
|
|
120
|
-
"vue-router": "^4.
|
|
121
|
-
"vue-tsc": "^1.
|
|
144
|
+
"vue-loader": "^17.2.2",
|
|
145
|
+
"vue-router": "^4.2.4",
|
|
146
|
+
"vue-tsc": "^1.8.8",
|
|
122
147
|
"vuedraggable": "^2.24.3"
|
|
123
148
|
},
|
|
124
149
|
"engines": {
|
|
@@ -136,7 +161,11 @@
|
|
|
136
161
|
"vue-component",
|
|
137
162
|
"framework",
|
|
138
163
|
"library",
|
|
139
|
-
"ui"
|
|
164
|
+
"ui",
|
|
165
|
+
"nuxt",
|
|
166
|
+
"nuxt3",
|
|
167
|
+
"module",
|
|
168
|
+
"nuxt-module"
|
|
140
169
|
],
|
|
141
170
|
"repository": {
|
|
142
171
|
"type": "git",
|
|
@@ -144,7 +173,7 @@
|
|
|
144
173
|
},
|
|
145
174
|
"license": "MIT",
|
|
146
175
|
"scripts": {
|
|
147
|
-
"lint": "
|
|
176
|
+
"lint": "pnpm lint:js && pnpm lint:style",
|
|
148
177
|
"lint:nofix": "cross-env NODE_ENV=production eslint --ext .ts,.js,.vue .",
|
|
149
178
|
"lint:js": "cross-env NODE_ENV=production eslint --fix --ext .ts,.js,.vue .",
|
|
150
179
|
"lint:style": "stylelint --fix \"./**/*.{vue,css,scss,postcss,pcss}\"",
|
|
@@ -1,24 +1,28 @@
|
|
|
1
1
|
// @ts-check
|
|
2
2
|
|
|
3
3
|
// Tailwind CSS configuration (https://tailwindcss.com/docs/configuration)
|
|
4
|
-
|
|
4
|
+
import plugin from 'tailwindcss/plugin'
|
|
5
|
+
import type { Config } from 'tailwindcss'
|
|
5
6
|
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
7
|
+
import { utilities } from './variables/utilities'
|
|
8
|
+
import { screens } from './variables/breakpoints'
|
|
9
|
+
import { zIndex } from './variables/z-indexes'
|
|
10
|
+
import { getColors } from './utils/colors'
|
|
10
11
|
|
|
11
|
-
|
|
12
|
+
import tailwindCSSVariable from 'tailwind-css-variables'
|
|
13
|
+
|
|
14
|
+
export default <Config>{
|
|
12
15
|
darkMode: 'class',
|
|
16
|
+
content: [],
|
|
13
17
|
theme: {
|
|
14
18
|
extend: {
|
|
15
|
-
backgroundColor: ['even', 'odd'],
|
|
19
|
+
// backgroundColor: ['even', 'odd'],
|
|
16
20
|
fontFamily: {
|
|
17
21
|
base: 'var(--maz-font-family)',
|
|
18
22
|
},
|
|
19
23
|
zIndex,
|
|
20
24
|
screens,
|
|
21
|
-
colors:
|
|
25
|
+
colors: getColors(),
|
|
22
26
|
borderWidth: {
|
|
23
27
|
0: '0',
|
|
24
28
|
1: '1px',
|
|
@@ -34,7 +38,7 @@ module.exports = {
|
|
|
34
38
|
},
|
|
35
39
|
},
|
|
36
40
|
plugins: [
|
|
37
|
-
|
|
41
|
+
tailwindCSSVariable({
|
|
38
42
|
colors: false,
|
|
39
43
|
screens: 'screen',
|
|
40
44
|
fontFamily: false,
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
/* eslint-disable unicorn/prefer-module */
|
|
2
|
+
import { baseColors, variations, variatingColors } from '../variables/colors'
|
|
3
|
+
|
|
4
|
+
export function getColors() {
|
|
5
|
+
const colors = {
|
|
6
|
+
...baseColors,
|
|
7
|
+
}
|
|
8
|
+
|
|
9
|
+
for (const color of Object.keys(variatingColors)) {
|
|
10
|
+
colors[color] = variations.reduce((colorVariations, variation) => {
|
|
11
|
+
colorVariations[variation] =
|
|
12
|
+
variation === 'DEFAULT'
|
|
13
|
+
? `var(--maz-color-${color})`
|
|
14
|
+
: `var(--maz-color-${color}-${variation})`
|
|
15
|
+
return colorVariations
|
|
16
|
+
}, {})
|
|
17
|
+
}
|
|
18
|
+
|
|
19
|
+
return colors
|
|
20
|
+
}
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
/* eslint-disable unicorn/prefer-module */
|
|
2
|
+
export const baseColors = {
|
|
3
|
+
transparent: 'transparent',
|
|
4
|
+
black: 'var(--maz-color-black)',
|
|
5
|
+
'black-contrast': 'var(--maz-color-black-contrast)',
|
|
6
|
+
white: 'var(--maz-color-white)',
|
|
7
|
+
'white-contrast': 'var(--maz-color-white-contrast)',
|
|
8
|
+
current: 'currentColor',
|
|
9
|
+
normal: 'var(--maz-color-text)',
|
|
10
|
+
color: 'var(--maz-color-bg)',
|
|
11
|
+
'color-light': 'var(--maz-color-bg-light)',
|
|
12
|
+
'color-lighter': 'var(--maz-color-bg-lighter)',
|
|
13
|
+
'bg-dark': 'var(--maz-bg-color-dark)',
|
|
14
|
+
'bg-light': 'var(--maz-bg-color-light)',
|
|
15
|
+
light: 'var(--maz-color-text-light)',
|
|
16
|
+
dark: 'var(--maz-color-text-dark)',
|
|
17
|
+
muted: 'var(--maz-color-muted)',
|
|
18
|
+
overlay: 'var(--maz-bg-overlay)',
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
export const variations = [
|
|
22
|
+
'DEFAULT',
|
|
23
|
+
50,
|
|
24
|
+
100,
|
|
25
|
+
200,
|
|
26
|
+
300,
|
|
27
|
+
400,
|
|
28
|
+
600,
|
|
29
|
+
700,
|
|
30
|
+
800,
|
|
31
|
+
900,
|
|
32
|
+
'contrast',
|
|
33
|
+
'alpha',
|
|
34
|
+
'alpha-20',
|
|
35
|
+
]
|
|
36
|
+
|
|
37
|
+
export const variatingColors = {
|
|
38
|
+
primary: true,
|
|
39
|
+
secondary: true,
|
|
40
|
+
info: true,
|
|
41
|
+
success: true,
|
|
42
|
+
warning: true,
|
|
43
|
+
danger: true,
|
|
44
|
+
}
|