@dargmuesli/nuxt-vio 16.1.0-beta.1 → 17.0.0-beta.1

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.
@@ -0,0 +1,90 @@
1
+ /* stylelint-disable plugin/no-unsupported-browser-features */
2
+ @layer components {
3
+ .form-input {
4
+ appearance: none;
5
+ background-color: #fff;
6
+ border-color: oklch(55.1% 0.027 264.364deg);
7
+ border-width: 1px;
8
+ border-radius: 0;
9
+ padding: 0.75rem 0.5rem;
10
+ font-size: 1rem;
11
+ line-height: 1.5rem;
12
+
13
+ --tw-shadow: 0 0 #0000;
14
+
15
+ &:focus {
16
+ outline: 2px solid transparent;
17
+ outline-offset: 2px;
18
+
19
+ --tw-ring-inset: var(--tw-empty,/*!*/ /*!*/);
20
+ --tw-ring-offset-width: 0px;
21
+ --tw-ring-offset-color: #fff;
22
+ --tw-ring-color: oklch(54.6% 0.245 262.881deg);
23
+ --tw-ring-offset-shadow: var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);
24
+ --tw-ring-shadow: var(--tw-ring-inset) 0 0 0 calc(1px + var(--tw-ring-offset-width)) var(--tw-ring-color);
25
+
26
+ box-shadow: var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow);
27
+ border-color: oklch(54.6% 0.245 262.881deg);
28
+ }
29
+
30
+ &::placeholder {
31
+ color: oklch(55.1% 0.027 264.364deg);
32
+ opacity: 1;
33
+ }
34
+
35
+ &::-webkit-datetime-edit-fields-wrapper {
36
+ padding: 0;
37
+ }
38
+
39
+ &::-webkit-date-and-time-value {
40
+ min-height: 1.5em;
41
+ text-align: inherit;
42
+ }
43
+
44
+ &::-webkit-datetime-edit {
45
+ display: inline-flex;
46
+ padding-top: 0;
47
+ padding-bottom: 0;
48
+ }
49
+
50
+ &::-webkit-datetime-edit-year-field {
51
+ padding-top: 0;
52
+ padding-bottom: 0;
53
+ }
54
+
55
+ &::-webkit-datetime-edit-month-field {
56
+ padding-top: 0;
57
+ padding-bottom: 0;
58
+ }
59
+
60
+ &::-webkit-datetime-edit-day-field {
61
+ padding-top: 0;
62
+ padding-bottom: 0;
63
+ }
64
+
65
+ &::-webkit-datetime-edit-hour-field {
66
+ padding-top: 0;
67
+ padding-bottom: 0;
68
+ }
69
+
70
+ &::-webkit-datetime-edit-minute-field {
71
+ padding-top: 0;
72
+ padding-bottom: 0;
73
+ }
74
+
75
+ &::-webkit-datetime-edit-second-field {
76
+ padding-top: 0;
77
+ padding-bottom: 0;
78
+ }
79
+
80
+ &::-webkit-datetime-edit-millisecond-field {
81
+ padding-top: 0;
82
+ padding-bottom: 0;
83
+ }
84
+
85
+ &::-webkit-datetime-edit-meridiem-field {
86
+ padding-top: 0;
87
+ padding-bottom: 0;
88
+ }
89
+ }
90
+ }
@@ -1,25 +1,212 @@
1
+ /* stylelint-disable at-rule-no-deprecated */
1
2
  /* stylelint-disable at-rule-no-unknown */
2
- @tailwind base;
3
- @tailwind components;
4
- @tailwind utilities;
5
- /* stylelint-enable at-rule-no-unknown */
3
+ /* stylelint-disable custom-property-pattern */
4
+ /* stylelint-disable import-notation */
5
+ /* stylelint-disable plugin/no-unsupported-browser-features */
6
+
7
+ @import 'tailwindcss';
8
+ @import './forms.css';
9
+
10
+ @plugin "@tailwindcss/forms" {
11
+ strategy: 'base';
12
+ }
13
+
14
+ @plugin "@tailwindcss/typography";
15
+
16
+ @theme {
17
+ --animate-shake: shake 0.6s ease-in-out 0s 1 normal forwards running;
18
+
19
+ @keyframes shake {
20
+ 0%,
21
+ 100% {
22
+ transform: translateX(0);
23
+ }
24
+
25
+ 15% {
26
+ transform: translateX(0.375rem);
27
+ }
28
+
29
+ 30% {
30
+ transform: translateX(-0.375rem);
31
+ }
32
+
33
+ 45% {
34
+ transform: translateX(0.375rem);
35
+ }
36
+
37
+ 60% {
38
+ transform: translateX(-0.375rem);
39
+ }
40
+
41
+ 75% {
42
+ transform: translateX(0.375rem);
43
+ }
44
+
45
+ 90% {
46
+ transform: translateX(-0.375rem);
47
+ }
48
+ }
49
+
50
+ --color-background-bright: rgb(255 255 255);
51
+ --color-background-brighten: rgb(229 231 235);
52
+ --color-background-dark: rgb(31 41 55);
53
+ --color-background-darken: rgb(55 65 81);
54
+ --color-link-bright: rgb(96 165 250);
55
+ --color-link-dark: rgb(37 99 235);
56
+ --color-text-bright: rgb(249 250 251);
57
+ --color-text-dark: rgb(17 24 39);
58
+ --color-vio-primary-bg: rgb(243 244 246);
59
+ --color-vio-primary-text: rgb(17 24 39);
60
+
61
+ /* --text-3xl--line-height: calc(2.5 / 1.875);
62
+ --text-4xl--line-height: calc(3 / 2.25);
63
+ --text-5xl--line-height: calc(4 / 3);
64
+ --text-6xl--line-height: calc(4.75 / 3.75);
65
+ --text-7xl--line-height: calc(4.75 / 4);
66
+ --text-8xl--line-height: calc(7.5 / 6);
67
+ --text-9xl--line-height: calc(10 / 8); */
68
+ }
6
69
 
7
- /* doiuse-disable css-cascade-layers */
8
70
  @layer base {
9
- /* doiuse-enable css-cascade-layers */
10
-
11
- :root {
12
- /* stylelint-disable plugin/no-unsupported-browser-features */
13
- --color-background-bright: 255 255 255;
14
- --color-background-brighten: 229 231 235;
15
- --color-background-dark: 31 41 55;
16
- --color-background-darken: 55 65 81;
17
- --color-link-bright: 96 165 250;
18
- --color-link-dark: 37 99 235;
19
- --color-text-bright: 249 250 251;
20
- --color-text-dark: 17 24 39;
21
- --color-vio-primary-bg: 243 244 246;
22
- --color-vio-primary-text: 17 24 39;
23
- /* stylelint-enable plugin/no-unsupported-browser-features */
71
+ ::placeholder {
72
+ @apply italic;
73
+ }
74
+
75
+ :disabled {
76
+ /* pointer-events-none */
77
+ @apply cursor-not-allowed opacity-50;
78
+ }
79
+
80
+ a,
81
+ button {
82
+ @apply focus:ring-3 focus:ring-blue-500/50 focus:outline-none;
83
+ }
84
+
85
+ a[target='_blank']:not([is-external-icon-disabled])::after {
86
+ /* inline-table centers the element vertically in the tiptap text area, instead of inline-block */
87
+ @apply ml-[5px] inline-table h-3 w-3 bg-current;
88
+
89
+ content: '';
90
+ mask: url('data:image/svg+xml;base64,PHN2ZyBhcmlhLWhpZGRlbj0idHJ1ZSIgZm9jdXNhYmxlPSJmYWxzZSIgZGF0YS1wcmVmaXg9ImZhcyIgZGF0YS1pY29uPSJhcnJvdy11cC1yaWdodC1mcm9tLXNxdWFyZSIgY2xhc3M9InN2Zy1pbmxpbmUtLWZhIGZhLWFycm93LXVwLXJpZ2h0LWZyb20tc3F1YXJlIiByb2xlPSJpbWciIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgdmlld0JveD0iMCAwIDUxMiA1MTIiPjxwYXRoIGZpbGw9ImN1cnJlbnRDb2xvciIgZD0iTTM4NCAzMjBjLTE3LjY3IDAtMzIgMTQuMzMtMzIgMzJ2OTZINjRWMTYwaDk2YzE3LjY3IDAgMzItMTQuMzIgMzItMzJzLTE0LjMzLTMyLTMyLTMyTDY0IDk2Yy0zNS4zNSAwLTY0IDI4LjY1LTY0IDY0VjQ0OGMwIDM1LjM0IDI4LjY1IDY0IDY0IDY0aDI4OGMzNS4zNSAwIDY0LTI4LjY2IDY0LTY0di05NkM0MTYgMzM0LjMgNDAxLjcgMzIwIDM4NCAzMjB6TTUwMi42IDkuMzY3QzQ5Ni44IDMuNTc4IDQ4OC44IDAgNDgwIDBoLTE2MGMtMTcuNjcgMC0zMS4xIDE0LjMyLTMxLjEgMzEuMWMwIDE3LjY3IDE0LjMyIDMxLjEgMzEuOTkgMzEuMWg4Mi43NUwxNzguNyAyOTAuN2MtMTIuNSAxMi41LTEyLjUgMzIuNzYgMCA0NS4yNkMxOTEuMiAzNDguNSAyMTEuNSAzNDguNSAyMjQgMzM2bDIyNC0yMjYuOFYxOTJjMCAxNy42NyAxNC4zMyAzMS4xIDMxLjEgMzEuMVM1MTIgMjA5LjcgNTEyIDE5MlYzMS4xQzUxMiAyMy4xNiA1MDguNCAxNS4xNiA1MDIuNiA5LjM2N3oiPjwvcGF0aD48L3N2Zz4K')
91
+ no-repeat 50% 50%;
92
+ mask-size: cover;
93
+ }
94
+
95
+ address {
96
+ @apply m-4;
97
+ }
98
+
99
+ button:not(:disabled),
100
+ [role='button']:not(:disabled) {
101
+ cursor: pointer;
102
+ }
103
+
104
+ h1 {
105
+ /* mb-4 */
106
+ @apply heading text-center text-4xl;
107
+ }
108
+
109
+ h2 {
110
+ @apply heading text-3xl;
111
+ }
112
+
113
+ h3 {
114
+ @apply heading text-2xl;
115
+ }
116
+
117
+ h4 {
118
+ @apply heading text-xl;
119
+ }
120
+
121
+ h5 {
122
+ @apply heading text-lg;
123
+ }
124
+
125
+ h6 {
126
+ @apply heading;
127
+ }
128
+
129
+ img::before {
130
+ @apply flex h-full items-center justify-center;
131
+ }
132
+
133
+ table {
134
+ @apply w-full;
135
+ }
136
+
137
+ td {
138
+ @apply px-4 py-6 whitespace-nowrap;
139
+ }
140
+
141
+ th {
142
+ @apply px-3 py-6 text-left text-xs font-medium tracking-wider uppercase;
143
+ }
144
+ }
145
+
146
+ @layer components {
147
+ .form-input {
148
+ appearance: none;
149
+ background-color: rgb(249 250 251 / var(--tw-bg-opacity, 1));
150
+ border-color: rgb(209 213 219 / var(--tw-border-opacity, 1));
151
+ border-radius: 0.25rem;
152
+ border-width: 1px;
153
+ box-shadow: 0 1px 2px 0 rgb(0 0 0 / 5%);
154
+ color: rgb(24 24 27 / var(--tw-text-opacity, 1));
155
+ line-height: 1.25;
156
+ padding: 0.5rem 1rem;
157
+ width: 100%;
158
+ }
159
+
160
+ .form-input:focus {
161
+ background-color: rgb(255 255 255 / var(--tw-bg-opacity, 1));
162
+ }
163
+
164
+ .form-input::placeholder {
165
+ opacity: 0.5;
166
+ }
167
+
168
+ .form-input-error .form-input {
169
+ border-color: rgb(239 68 68 / var(--tw-border-opacity, 1));
170
+ }
171
+
172
+ .form-input-success .form-input {
173
+ border-color: rgb(22 163 74 / var(--tw-border-opacity, 1));
174
+ }
175
+
176
+ .form-input-warning .form-input {
177
+ border-color: rgb(202 138 4 / var(--tw-border-opacity, 1));
178
+ }
179
+
180
+ .form-textarea::placeholder {
181
+ opacity: 0.5;
182
+ }
183
+ }
184
+
185
+ @utility disabled {
186
+ /* pointer-events-none */
187
+ @apply cursor-not-allowed opacity-50;
188
+ }
189
+
190
+ @utility heading {
191
+ @apply font-bold;
192
+ } /* set overflow truncate/ellipsis in the surrounding container, or larger fonts will be cut off due to their line-heights */
193
+
194
+ .dark {
195
+ @apply scheme-dark;
196
+ }
197
+
198
+ .prose {
199
+ a {
200
+ /* color-link */
201
+ @apply no-underline;
202
+ }
203
+
204
+ h1,
205
+ h2,
206
+ h3,
207
+ h4,
208
+ h5,
209
+ h6 {
210
+ @apply leading-snug;
24
211
  }
25
212
  }
@@ -56,7 +56,7 @@ const route = useRoute()
56
56
  // computations
57
57
  const classes = computed(() => {
58
58
  return [
59
- 'rounded',
59
+ 'rounded-sm',
60
60
  ...(props.isColored ? ['text-link-dark dark:text-link-bright'] : []),
61
61
  ...(props.isUnderlined ? ['underline'] : []),
62
62
  ].join(' ')
@@ -7,10 +7,10 @@
7
7
  [
8
8
  ...(isPrimary
9
9
  ? [
10
- 'border-transparent bg-gray-800 text-text-bright hover:brightness-90 dark:bg-vio-primary-bg dark:text-vio-primary-text',
10
+ 'text-text-bright dark:bg-vio-primary-bg dark:text-vio-primary-text border-transparent bg-gray-800 hover:brightness-90',
11
11
  ]
12
12
  : [
13
- 'border-gray-300 text-text-dark hover:bg-black/5 dark:border-gray-600 dark:text-text-bright dark:hover:bg-black/30',
13
+ 'text-text-dark dark:text-text-bright border-gray-300 hover:bg-black/5 dark:border-gray-600 dark:hover:bg-black/30',
14
14
  ]),
15
15
  ].join(' ')
16
16
  "
@@ -2,7 +2,7 @@
2
2
  <div>
3
3
  <input
4
4
  :id="`input-${formKey}`"
5
- class="rounded"
5
+ class="rounded-sm"
6
6
  type="checkbox"
7
7
  :checked="value"
8
8
  @change="emit('change', ($event.target as HTMLInputElement).checked)"
@@ -20,7 +20,7 @@
20
20
  >
21
21
  <span>{{ title }}</span>
22
22
  <span
23
- class="text-xs font-medium text-gray-500 dark:text-gray-400 md:text-right"
23
+ class="text-xs font-medium text-gray-500 md:text-right dark:text-gray-400"
24
24
  >
25
25
  <span v-if="isRequired">
26
26
  {{ t('required') }}
@@ -1,5 +1,5 @@
1
1
  <template>
2
- <span class="absolute right-0 top-1/2 -translate-y-1/2 px-3">
2
+ <span class="absolute top-1/2 right-0 -translate-y-1/2 px-3">
3
3
  <div class="rounded-full bg-gray-50">
4
4
  <slot />
5
5
  </div>
@@ -16,7 +16,7 @@
16
16
  >
17
17
  <span>{{ t('separator') }}</span>
18
18
  <VioLink
19
- class="whitespace-nowrap text-2xl"
19
+ class="text-2xl whitespace-nowrap"
20
20
  :data-testid="`breadcrumb-prefix-${prefix.to}`"
21
21
  :is-colored="false"
22
22
  :to="prefix.to"
@@ -28,7 +28,7 @@
28
28
  <span>{{ t('separator') }}</span>
29
29
  <VioLink :is-colored="false" :to="route.path">
30
30
  <span
31
- class="whitespace-nowrap text-2xl font-bold"
31
+ class="text-2xl font-bold whitespace-nowrap"
32
32
  data-testid="breadcrumb"
33
33
  >
34
34
  <slot />
@@ -42,7 +42,7 @@
42
42
  >
43
43
  <span>{{ t('separator') }}</span>
44
44
  <VioLink
45
- class="whitespace-nowrap text-2xl"
45
+ class="text-2xl whitespace-nowrap"
46
46
  :data-testid="`breadcrumb-suffix-${suffix.to}`"
47
47
  :is-colored="false"
48
48
  :to="suffix.to"
@@ -2,7 +2,7 @@
2
2
  <div
3
3
  class="flex flex-1 basis-1/2 flex-col items-start gap-2 p-4 md:flex-none md:basis-auto"
4
4
  >
5
- <span class="whitespace-nowrap text-lg font-medium leading-7">
5
+ <span class="text-lg leading-7 font-medium whitespace-nowrap">
6
6
  {{ heading }}
7
7
  </span>
8
8
  <slot />
@@ -1,6 +1,6 @@
1
1
  <template>
2
2
  <tbody
3
- class="divide-y divide-background-brighten dark:divide-background-darken"
3
+ class="divide-background-brighten dark:divide-background-darken divide-y"
4
4
  >
5
5
  <slot />
6
6
  </tbody>
@@ -1,6 +1,6 @@
1
1
  <template>
2
2
  <thead
3
- class="sticky top-0 z-10 bg-background-brighten dark:bg-background-darken"
3
+ class="bg-background-brighten dark:bg-background-darken sticky top-0 z-10"
4
4
  >
5
5
  <slot />
6
6
  </thead>
package/nuxt.config.ts CHANGED
@@ -1,6 +1,4 @@
1
- import { dirname, join } from 'node:path'
2
- import { fileURLToPath } from 'node:url'
3
-
1
+ import tailwindcss from '@tailwindcss/vite'
4
2
  import { defu } from 'defu'
5
3
 
6
4
  import {
@@ -12,9 +10,6 @@ import {
12
10
  } from './utils/constants'
13
11
  import { VIO_NUXT_BASE_CONFIG } from './utils/nuxt'
14
12
 
15
- const currentDir = dirname(fileURLToPath(import.meta.url))
16
-
17
- // https://v3.nuxtjs.org/api/configuration/nuxt.config
18
13
  export default defineNuxtConfig(
19
14
  defu(
20
15
  {
@@ -30,6 +25,7 @@ export default defineNuxtConfig(
30
25
  },
31
26
  },
32
27
  compatibilityDate: '2024-04-03',
28
+ css: ['./assets/css/tailwind.css'],
33
29
  ...(process.env.NUXT_PUBLIC_SITE_URL
34
30
  ? {}
35
31
  : {
@@ -54,7 +50,6 @@ export default defineNuxtConfig(
54
50
  '@nuxtjs/html-validator',
55
51
  '@nuxtjs/i18n',
56
52
  '@nuxtjs/seo',
57
- '@nuxtjs/tailwindcss',
58
53
  '@pinia/nuxt',
59
54
  'nuxt-gtag',
60
55
  (_options, nuxt) => {
@@ -125,6 +120,9 @@ export default defineNuxtConfig(
125
120
  // },
126
121
  },
127
122
  },
123
+ vite: {
124
+ plugins: [tailwindcss()],
125
+ },
128
126
 
129
127
  // modules
130
128
  colorMode: {
@@ -256,9 +254,6 @@ export default defineNuxtConfig(
256
254
  sitemap: {
257
255
  credits: false,
258
256
  },
259
- tailwindcss: {
260
- cssPath: join(currentDir, './assets/css/tailwind.css'),
261
- },
262
257
 
263
258
  // environments
264
259
  $development: {
package/package.json CHANGED
@@ -1,19 +1,18 @@
1
1
  {
2
2
  "dependencies": {
3
- "@dargmuesli/nuxt-cookie-control": "8.4.20",
4
- "@eslint/compat": "1.2.5",
3
+ "@dargmuesli/nuxt-cookie-control": "8.5.2",
4
+ "@eslint/compat": "1.2.6",
5
5
  "@heroicons/vue": "2.2.0",
6
6
  "@http-util/status-i18n": "0.8.1",
7
7
  "@intlify/eslint-plugin-vue-i18n": "4.0.0-next.1",
8
- "@nuxt/devtools": "1.7.0",
9
- "@nuxt/eslint": "0.7.5",
8
+ "@nuxt/devtools": "2.1.0",
9
+ "@nuxt/eslint": "1.0.1",
10
10
  "@nuxt/image": "1.9.0",
11
11
  "@nuxtjs/color-mode": "3.5.2",
12
12
  "@nuxtjs/html-validator": "1.8.2",
13
13
  "@nuxtjs/i18n": "9.1.1",
14
- "@nuxtjs/seo": "2.0.2",
15
- "@nuxtjs/tailwindcss": "6.12.2",
16
- "@pinia/nuxt": "0.9.0",
14
+ "@nuxtjs/seo": "2.1.1",
15
+ "@pinia/nuxt": "0.10.1",
17
16
  "@tailwindcss/forms": "0.5.10",
18
17
  "@tailwindcss/typography": "0.5.16",
19
18
  "@types/lodash-es": "4.17.12",
@@ -23,40 +22,41 @@
23
22
  "@vuelidate/validators": "2.0.4",
24
23
  "clipboardy": "4.0.0",
25
24
  "dayjs": "2.0.0-alpha.4",
26
- "eslint": "9.18.0",
25
+ "eslint": "9.20.1",
27
26
  "eslint-config-prettier": "10.0.1",
28
27
  "eslint-plugin-compat": "6.0.2",
29
- "eslint-plugin-prettier": "5.2.1",
28
+ "eslint-plugin-prettier": "5.2.3",
30
29
  "eslint-plugin-yml": "1.16.0",
31
- "globals": "15.14.0",
30
+ "globals": "15.15.0",
32
31
  "jiti": "2.4.2",
33
- "jose": "5.9.6",
32
+ "jose": "5.10.0",
34
33
  "nuxt-gtag": "3.0.2",
35
34
  "nuxt-security": "2.1.5",
36
- "sweetalert2": "11.15.10",
35
+ "sweetalert2": "11.17.2",
37
36
  "vue-tsc": "2.2.0"
38
37
  },
39
38
  "devDependencies": {
40
- "@unhead/vue": "1.11.16",
39
+ "@tailwindcss/vite": "4.0.6",
40
+ "@unhead/vue": "1.11.19",
41
41
  "@urql/devtools": "2.0.3",
42
- "@urql/exchange-graphcache": "7.2.1",
42
+ "@urql/exchange-graphcache": "7.2.2",
43
43
  "consola": "3.4.0",
44
44
  "cookie-es": "1.2.2",
45
45
  "defu": "6.1.4",
46
- "h3": "1.13.1",
46
+ "h3": "1.15.0",
47
47
  "lodash-es": "4.17.21",
48
- "nuxt": "3.15.1",
49
- "pinia": "2.3.0",
50
- "prettier": "3.4.2",
51
- "prettier-plugin-tailwindcss": "0.6.9",
48
+ "nuxt": "3.15.4",
49
+ "pinia": "3.0.1",
50
+ "prettier": "3.5.1",
51
+ "prettier-plugin-tailwindcss": "0.6.11",
52
52
  "serve": "14.2.4",
53
53
  "sharp": "0.33.5",
54
- "stylelint": "16.13.1",
55
- "stylelint-config-recommended-vue": "1.5.0",
54
+ "stylelint": "16.14.1",
55
+ "stylelint-config-recommended-vue": "1.6.0",
56
56
  "stylelint-config-standard": "37.0.0",
57
- "stylelint-no-unsupported-browser-features": "8.0.2",
58
- "tailwindcss": "3.4.17",
59
- "unhead": "1.11.16",
57
+ "stylelint-no-unsupported-browser-features": "8.0.4",
58
+ "tailwindcss": "4.0.6",
59
+ "unhead": "1.11.19",
60
60
  "vue": "3.5.13",
61
61
  "vue-router": "4.5.0"
62
62
  },
@@ -80,13 +80,12 @@
80
80
  "error.vue",
81
81
  "i18n.config.ts",
82
82
  "nuxt.config.ts",
83
- "package.json",
84
- "tailwind.config.ts"
83
+ "package.json"
85
84
  ],
86
85
  "main": "nuxt.config.ts",
87
86
  "name": "@dargmuesli/nuxt-vio",
88
87
  "peerDependencies": {
89
- "nuxt": "3.15.1",
88
+ "nuxt": "3.15.4",
90
89
  "vue": "3.5.13",
91
90
  "vue-router": "4.5.0"
92
91
  },
@@ -101,8 +100,7 @@
101
100
  "build": "pnpm run build:node",
102
101
  "build:node": "nuxt build .playground",
103
102
  "build:static": "nuxt generate .playground",
104
- "build:static:test": "cross-env NUXT_PUBLIC_VIO_IS_TESTING=true SITE_URL=https://localhost:3002 pnpm run build:static",
105
- "build:test": "pnpm run build:static:test",
103
+ "build:static:test": "SITE_URL=https://localhost:3002 pnpm run build:static",
106
104
  "dev": "pnpm run start:dev",
107
105
  "generate": "pnpm run build:static",
108
106
  "lint:fix": "pnpm run lint:js --fix && pnpm run lint:ts --fix && pnpm run lint:style --fix",
@@ -113,13 +111,11 @@
113
111
  "lint": "pnpm run lint:js && pnpm run lint:ts && pnpm run lint:style",
114
112
  "prepare": "nuxt prepare && nuxt prepare .playground && ./.config/certificates/mkcert.sh",
115
113
  "preview": "nuxt preview .playground",
114
+ "start": "pnpm run start:node",
116
115
  "start:dev": "nuxt dev .playground",
117
116
  "start:node": "node .playground/.output/server/index.mjs",
118
- "start:node:test": "PORT=3001 pnpm run start:node",
119
- "start:static": "serve .playground/.output/public --ssl-cert ./.config/certificates/ssl.crt --ssl-key ./.config/certificates/ssl.key",
120
- "start:static:test": "PORT=3002 pnpm run start:static",
121
- "start:test": "pnpm run start:static:test"
117
+ "start:static": "serve .playground/.output/public --ssl-cert ./.config/certificates/ssl.crt --ssl-key ./.config/certificates/ssl.key"
122
118
  },
123
119
  "type": "module",
124
- "version": "16.1.0-beta.1"
120
+ "version": "17.0.0-beta.1"
125
121
  }
@@ -1,253 +0,0 @@
1
- import type { ModuleOptions } from '@nuxtjs/tailwindcss'
2
- import formsPlugin from '@tailwindcss/forms'
3
- import typographyPlugin from '@tailwindcss/typography'
4
- import type { PluginAPI } from 'tailwindcss/types/config'
5
-
6
- const heading = (theme: PluginAPI['theme']): Record<string, string> => ({
7
- fontWeight: theme('fontWeight.bold'),
8
- // marginBottom: theme('margin.1'),
9
- // marginTop: theme('margin.4'),
10
- // set overflow truncate/ellipsis in the surrounding container, or larger fonts will be cut off due to their line-heights
11
- })
12
-
13
- const prose = (theme: PluginAPI['theme']) => ({
14
- css: {
15
- a: {
16
- color: theme('colors.link'),
17
- textDecoration: 'none',
18
- },
19
- h1: {
20
- lineHeight: theme('lineHeight.snug'),
21
- },
22
- h2: {
23
- lineHeight: theme('lineHeight.snug'),
24
- },
25
- h3: {
26
- lineHeight: theme('lineHeight.snug'),
27
- },
28
- h4: {
29
- lineHeight: theme('lineHeight.snug'),
30
- },
31
- h5: {
32
- lineHeight: theme('lineHeight.snug'),
33
- },
34
- h6: {
35
- lineHeight: theme('lineHeight.snug'),
36
- },
37
- },
38
- })
39
-
40
- export default {
41
- darkMode: 'class',
42
- plugins: [
43
- formsPlugin,
44
- typographyPlugin,
45
- ({ addBase, addComponents, addUtilities, theme }: PluginAPI) => {
46
- addBase({
47
- ':disabled': {
48
- cursor: theme('cursor.not-allowed'),
49
- opacity: theme('opacity.50'),
50
- },
51
- 'a[target="_blank"]:not([is-external-icon-disabled]):after': {
52
- backgroundColor: 'currentColor',
53
- content: '""',
54
- display: 'inline-table', // inline-table centers the element vertically in the tiptap text area, instead of inline-block
55
- mask: 'url(data:image/svg+xml;base64,PHN2ZyBhcmlhLWhpZGRlbj0idHJ1ZSIgZm9jdXNhYmxlPSJmYWxzZSIgZGF0YS1wcmVmaXg9ImZhcyIgZGF0YS1pY29uPSJhcnJvdy11cC1yaWdodC1mcm9tLXNxdWFyZSIgY2xhc3M9InN2Zy1pbmxpbmUtLWZhIGZhLWFycm93LXVwLXJpZ2h0LWZyb20tc3F1YXJlIiByb2xlPSJpbWciIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgdmlld0JveD0iMCAwIDUxMiA1MTIiPjxwYXRoIGZpbGw9ImN1cnJlbnRDb2xvciIgZD0iTTM4NCAzMjBjLTE3LjY3IDAtMzIgMTQuMzMtMzIgMzJ2OTZINjRWMTYwaDk2YzE3LjY3IDAgMzItMTQuMzIgMzItMzJzLTE0LjMzLTMyLTMyLTMyTDY0IDk2Yy0zNS4zNSAwLTY0IDI4LjY1LTY0IDY0VjQ0OGMwIDM1LjM0IDI4LjY1IDY0IDY0IDY0aDI4OGMzNS4zNSAwIDY0LTI4LjY2IDY0LTY0di05NkM0MTYgMzM0LjMgNDAxLjcgMzIwIDM4NCAzMjB6TTUwMi42IDkuMzY3QzQ5Ni44IDMuNTc4IDQ4OC44IDAgNDgwIDBoLTE2MGMtMTcuNjcgMC0zMS4xIDE0LjMyLTMxLjEgMzEuMWMwIDE3LjY3IDE0LjMyIDMxLjEgMzEuOTkgMzEuMWg4Mi43NUwxNzguNyAyOTAuN2MtMTIuNSAxMi41LTEyLjUgMzIuNzYgMCA0NS4yNkMxOTEuMiAzNDguNSAyMTEuNSAzNDguNSAyMjQgMzM2bDIyNC0yMjYuOFYxOTJjMCAxNy42NyAxNC4zMyAzMS4xIDMxLjEgMzEuMVM1MTIgMjA5LjcgNTEyIDE5MlYzMS4xQzUxMiAyMy4xNiA1MDguNCAxNS4xNiA1MDIuNiA5LjM2N3oiPjwvcGF0aD48L3N2Zz4K) no-repeat 50% 50%',
56
- maskSize: 'cover',
57
- height: theme('fontSize.xs'),
58
- marginLeft: '5px',
59
- width: theme('fontSize.xs'),
60
- },
61
- 'a:focus': {
62
- // @apply outline-none ring
63
- outline: '2px solid transparent',
64
- outlineOffset: '2px',
65
- boxShadow:
66
- 'var(--tw-ring-inset) 0 0 0 calc(3px + var(--tw-ring-offset-width)) var(--tw-ring-color)',
67
- },
68
- address: {
69
- margin: theme('margin.4'),
70
- },
71
- 'button:focus': {
72
- // @apply outline-none ring
73
- outline: '2px solid transparent',
74
- outlineOffset: '2px',
75
- boxShadow:
76
- 'var(--tw-ring-inset) 0 0 0 calc(3px + var(--tw-ring-offset-width)) var(--tw-ring-color)',
77
- },
78
- h1: {
79
- ...heading(theme),
80
- fontSize: theme('fontSize.4xl'),
81
- // marginBottom: theme('margin.4'),
82
- textAlign: 'center',
83
- },
84
- h2: {
85
- ...heading(theme),
86
- fontSize: theme('fontSize.3xl'),
87
- },
88
- h3: {
89
- ...heading(theme),
90
- fontSize: theme('fontSize.2xl'),
91
- },
92
- h4: {
93
- ...heading(theme),
94
- fontSize: theme('fontSize.xl'),
95
- },
96
- h5: {
97
- ...heading(theme),
98
- fontSize: theme('fontSize.lg'),
99
- },
100
- h6: {
101
- ...heading(theme),
102
- },
103
- img: {
104
- '&::before': {
105
- alignItems: 'center',
106
- display: 'flex',
107
- height: '100%',
108
- justifyContent: 'center',
109
- },
110
- },
111
- table: {
112
- width: '100%',
113
- },
114
- td: {
115
- padding: theme('padding.4') + ' ' + theme('padding.6'),
116
- whiteSpace: 'nowrap',
117
- },
118
- th: {
119
- padding: theme('padding.3') + ' ' + theme('padding.6'),
120
- textAlign: 'left',
121
- fontSize: theme('fontSize.xs'),
122
- fontWeight: theme('fontWeight.medium'),
123
- textTransform: 'uppercase',
124
- letterSpacing: theme('letterSpacing.wider'),
125
- },
126
- })
127
- addComponents({
128
- '::placeholder': {
129
- fontStyle: 'italic',
130
- '.form-input&,.form-textarea&': {
131
- opacity: '0.5',
132
- },
133
- },
134
- '.form-input': {
135
- appearance: 'none',
136
- backgroundColor: theme('colors.gray.50'),
137
- borderColor: theme('colors.gray.300'),
138
- borderRadius: theme('borderRadius.DEFAULT'),
139
- borderWidth: theme('borderWidth.DEFAULT'),
140
- boxShadow: theme('boxShadow.sm'),
141
- color: theme('colors.text.dark'),
142
- lineHeight: theme('lineHeight.tight'),
143
- padding: theme('padding.2') + ' ' + theme('padding.4'),
144
- width: theme('width.full'),
145
- '&:focus': {
146
- backgroundColor: theme('colors.white'),
147
- },
148
- },
149
- '.form-input-error': {
150
- '.form-input': {
151
- borderColor: theme('colors.red.500'),
152
- },
153
- },
154
- '.form-input-success': {
155
- '.form-input': {
156
- borderColor: theme('colors.green.600'),
157
- },
158
- },
159
- '.form-input-warning': {
160
- '.form-input': {
161
- borderColor: theme('colors.yellow.600'),
162
- },
163
- },
164
- '.fullscreen': {
165
- bottom: '0',
166
- height: theme('height.full'),
167
- left: '0',
168
- position: 'absolute',
169
- right: '0',
170
- top: '0',
171
- width: theme('width.full'),
172
- },
173
- '.object-position-custom': {
174
- objectPosition: '50% 30%',
175
- },
176
- })
177
- addUtilities({
178
- '.disabled': {
179
- cursor: theme('cursor.not-allowed'),
180
- opacity: theme('opacity.50'),
181
- },
182
- })
183
- },
184
- ],
185
- theme: {
186
- extend: {
187
- animation: {
188
- shake: 'shake 0.6s ease-in-out 0s 1 normal forwards running',
189
- },
190
- colors: {
191
- background: {
192
- bright: 'rgb(var(--color-background-bright))',
193
- brighten: 'rgb(var(--color-background-brighten))',
194
- dark: 'rgb(var(--color-background-dark))',
195
- darken: 'rgb(var(--color-background-darken))',
196
- },
197
- link: {
198
- bright: 'rgb(var(--color-link-bright))',
199
- dark: 'rgb(var(--color-link-dark))',
200
- },
201
- text: {
202
- bright: 'rgb(var(--color-text-bright))',
203
- dark: 'rgb(var(--color-text-dark))',
204
- },
205
- vio: {
206
- primary: {
207
- bg: 'rgb(var(--color-vio-primary-bg))',
208
- text: 'rgb(var(--color-vio-primary-text))',
209
- },
210
- },
211
- },
212
- keyframes: {
213
- shake: {
214
- '0%': {
215
- transform: 'translateX(0)',
216
- },
217
- '15%': {
218
- transform: 'translateX(0.375rem)',
219
- },
220
- '30%': {
221
- transform: 'translateX(-0.375rem)',
222
- },
223
- '45%': {
224
- transform: 'translateX(0.375rem)',
225
- },
226
- '60%': {
227
- transform: 'translateX(-0.375rem)',
228
- },
229
- '75%': {
230
- transform: 'translateX(0.375rem)',
231
- },
232
- '90%': {
233
- transform: 'translateX(-0.375rem)',
234
- },
235
- '100%': {
236
- transform: 'translateX(0)',
237
- },
238
- },
239
- },
240
- screens: {
241
- 12: { raw: '(min-aspect-ratio: 2/1)' },
242
- },
243
- typography: (theme: PluginAPI['theme']) => ({
244
- DEFAULT: prose(theme),
245
- sm: prose(theme),
246
- base: prose(theme),
247
- lg: prose(theme),
248
- xl: prose(theme),
249
- '2xl': prose(theme),
250
- }),
251
- },
252
- },
253
- } as ModuleOptions['config']