unocss-preset-quasar 0.1.4 → 0.1.6
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/dist/core/dark.unocss.js +4 -1
- package/dist/core/flex.unocss.js +17 -6
- package/dist/core/index.js +10 -0
- package/dist/core/typography.unocss.js +0 -2
- package/dist/index.js +58 -20
- package/dist/styles/md2/components/QBanner.unocss.js +5 -0
- package/dist/styles/md2/components/QCheckbox.unocss.js +1 -1
- package/dist/styles/md2/components/QItem.unocss.js +2 -2
- package/dist/styles/md2/components/QScrollarea.unocss.js +2 -5
- package/dist/styles/md2/components/QTabs.unocss.js +14 -5
- package/dist/styles/md3/components/QBanner.unocss.js +7 -2
- package/dist/styles/md3/components/QBtn.unocss.js +12 -5
- package/dist/styles/md3/components/QBtnToggle.unocss.js +1 -0
- package/dist/styles/md3/components/QCard.unocss.js +7 -2
- package/dist/styles/md3/components/QCheckbox.unocss.js +7 -3
- package/dist/styles/md3/components/QChip.unocss.js +4 -3
- package/dist/styles/md3/components/QDate.unocss.js +8 -4
- package/dist/styles/md3/components/QDrawer.unocss.js +20 -7
- package/dist/styles/md3/components/QField.unocss.js +33 -32
- package/dist/styles/md3/components/QFooter.unocss.js +1 -1
- package/dist/styles/md3/components/QHeader.unocss.js +2 -1
- package/dist/styles/md3/components/QIcon.unocss.js +1 -1
- package/dist/styles/md3/components/QItem.unocss.js +15 -10
- package/dist/styles/md3/components/QLayout.unocss.js +1 -1
- package/dist/styles/md3/components/QPageSticky.unocss.js +4 -0
- package/dist/styles/md3/components/QScrollarea.unocss.js +2 -5
- package/dist/styles/md3/components/QStepper.unocss.js +30 -4
- package/dist/styles/md3/components/QTabs.unocss.js +16 -6
- package/dist/styles/md3/components/QToggle.unocss.js +1 -3
- package/dist/styles/md3/components/QToolbar.unocss.js +1 -1
- package/dist/styles/md3/index.js +17 -1
- package/dist/theme.js +1 -1
- package/dist/types/styles/md3/index.d.ts +5 -1
- package/dist/types/theme.d.ts +5 -0
- package/package.json +1 -1
- package/src/core/dark.unocss.ts +4 -1
- package/src/core/flex.unocss.ts +16 -6
- package/src/core/index.ts +10 -0
- package/src/core/typography.unocss.ts +0 -2
- package/src/index.ts +64 -20
- package/src/styles/md2/components/QBanner.unocss.ts +7 -0
- package/src/styles/md2/components/QCheckbox.unocss.ts +1 -1
- package/src/styles/md2/components/QItem.unocss.ts +2 -2
- package/src/styles/md2/components/QScrollarea.unocss.ts +2 -5
- package/src/styles/md2/components/QTabs.unocss.ts +14 -5
- package/src/styles/md3/components/QBanner.unocss.ts +9 -2
- package/src/styles/md3/components/QBtn.unocss.ts +12 -5
- package/src/styles/md3/components/QBtnToggle.unocss.ts +1 -0
- package/src/styles/md3/components/QCard.unocss.ts +9 -2
- package/src/styles/md3/components/QCheckbox.unocss.ts +9 -3
- package/src/styles/md3/components/QChip.unocss.ts +4 -3
- package/src/styles/md3/components/QDate.unocss.ts +8 -4
- package/src/styles/md3/components/QDrawer.unocss.ts +20 -7
- package/src/styles/md3/components/QField.unocss.ts +33 -32
- package/src/styles/md3/components/QFooter.unocss.ts +1 -1
- package/src/styles/md3/components/QHeader.unocss.ts +2 -1
- package/src/styles/md3/components/QIcon.unocss.ts +1 -1
- package/src/styles/md3/components/QItem.unocss.ts +15 -10
- package/src/styles/md3/components/QLayout.unocss.ts +1 -1
- package/src/styles/md3/components/QPageSticky.unocss.ts +4 -0
- package/src/styles/md3/components/QScrollarea.unocss.ts +2 -5
- package/src/styles/md3/components/QStepper.unocss.ts +32 -4
- package/src/styles/md3/components/QTabs.unocss.ts +16 -6
- package/src/styles/md3/components/QToggle.unocss.ts +1 -3
- package/src/styles/md3/components/QToolbar.unocss.ts +1 -1
- package/src/styles/md3/index.ts +25 -1
- package/src/theme.ts +6 -1
|
@@ -35,7 +35,7 @@ const shortcuts: UserShortcuts<QuasarTheme> = [
|
|
|
35
35
|
[&_::-ms-reveal]:(hidden)`
|
|
36
36
|
],
|
|
37
37
|
|
|
38
|
-
[/^q-field--with-bottom$/, ([, c], { theme }) =>
|
|
38
|
+
[/^q-field--with-bottom$/, ([, c], { theme }) => ``],
|
|
39
39
|
|
|
40
40
|
[
|
|
41
41
|
/^q-field__marginal$/,
|
|
@@ -71,14 +71,14 @@ const shortcuts: UserShortcuts<QuasarTheme> = [
|
|
|
71
71
|
/^q-field__bottom$/,
|
|
72
72
|
([, c], { theme }) =>
|
|
73
73
|
theme.quasar?.components?.['q-field__bottom'] ??
|
|
74
|
-
`text-[12px] min-h-[20px] leading-none text-black/54 mt
|
|
74
|
+
`text-[12px] min-h-[20px] leading-none bg-transparent text-black/54 mt-4px px-[12px] pb-[0] [backface-visibility:hidden]`
|
|
75
75
|
],
|
|
76
76
|
|
|
77
77
|
[
|
|
78
78
|
/^q-field__bottom--animated$/,
|
|
79
79
|
([, c], { theme }) =>
|
|
80
80
|
theme.quasar?.components?.['q-field__bottom--animated'] ??
|
|
81
|
-
`
|
|
81
|
+
`left-[0] right-[0] bottom-[0]`
|
|
82
82
|
],
|
|
83
83
|
|
|
84
84
|
[
|
|
@@ -222,19 +222,19 @@ const shortcuts: UserShortcuts<QuasarTheme> = [
|
|
|
222
222
|
/^q-field--filled$/,
|
|
223
223
|
([, c], { theme }) =>
|
|
224
224
|
theme.quasar?.components?.['q-field--filled'] ??
|
|
225
|
-
`bg-light-surface-container text-light-on-surface-variant
|
|
226
|
-
dark:bg-dark-surface-container dark:text-dark-on-surface-variant
|
|
225
|
+
`[&_.q-field\\_\\_control]:(bg-light-surface-container text-light-on-surface-variant
|
|
226
|
+
dark:bg-dark-surface-container dark:text-dark-on-surface-variant)
|
|
227
227
|
[&_.q-field\\_\\_control]:(px-[16px] py-[0] layer-components:bg-black/5 rounded-tl-[4px] rounded-br-[0] rounded-tr-[4px] rounded-bl-[0])
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
228
|
+
[&_.q-field\\_\\_control:before]:(layer-components:bg-black/5 [border-bottom:1px_solid_rgba(0,_0,_0,_0.42)] opacity-0 [transition:opacity_0.36s_cubic-bezier(0.4,_0,_0.2,_1),_background_0.36s_cubic-bezier(0.4,_0,_0.2,_1)])
|
|
229
|
+
[&_.q-field\\_\\_control:hover:before]:(opacity-100)
|
|
230
|
+
[&_.q-field\\_\\_control:after]:(h-[2px] top-auto origin-[center_bottom] [transform:scale3d(0,_1,_1)] bg-current [transition:transform_0.36s_cubic-bezier(0.4,_0,_0.2,_1)])
|
|
231
|
+
[&.q-field--rounded_.q-field\\_\\_control]:(rounded-tl-[28px] rounded-br-[0] rounded-tr-[28px] rounded-bl-[0])
|
|
232
|
+
[&.q-field--highlighted_.q-field\\_\\_control:before]:(opacity-100 layer-components:bg-black/12)
|
|
233
|
+
[&.q-field--highlighted_.q-field\\_\\_control:after]:([transform:scale3d(1,_1,_1)])
|
|
234
|
+
[&.q-field--dark_.q-field\\_\\_control]:(layer-components:bg-white/7)
|
|
235
|
+
[&.q-field--dark_.q-field\\_\\_control:before]:(layer-components:bg-white/7)
|
|
236
|
+
[&.q-field--dark.q-field--highlighted_.q-field\\_\\_control:before]:(layer-components:bg-white/1)
|
|
237
|
+
[&.q-field--readonly_.q-field\\_\\_control:before]:(opacity-100 bg-transparent [border-bottom-style:dashed])`
|
|
238
238
|
],
|
|
239
239
|
|
|
240
240
|
[
|
|
@@ -285,27 +285,28 @@ const shortcuts: UserShortcuts<QuasarTheme> = [
|
|
|
285
285
|
/^q-field--standout$/,
|
|
286
286
|
([, c], { theme }) =>
|
|
287
287
|
theme.quasar?.components?.['q-field--standout'] ??
|
|
288
|
-
`[&_.q-field\\_\\_control]:(px-[12px] py-[0] layer-components:bg-
|
|
288
|
+
`[&_.q-field\\_\\_control]:(px-[12px] py-[0] layer-components:bg-light-surface-container-high
|
|
289
|
+
rounded-[4px] [transition:box-shadow_0.36s_cubic-bezier(0.4,_0,_0.2,_1),_background-color_0.36s_cubic-bezier(0.4,_0,_0.2,_1)])
|
|
289
290
|
[&_.q-field\\_\\_control:before]:(layer-components:bg-black/7 opacity-0 [transition:opacity_0.36s_cubic-bezier(0.4,_0,_0.2,_1),_background_0.36s_cubic-bezier(0.4,_0,_0.2,_1)])
|
|
290
291
|
[&_.q-field\\_\\_control:hover:before]:(opacity-100)
|
|
291
292
|
[&.q-field--rounded_.q-field\\_\\_control]:(rounded-[28px])
|
|
292
|
-
[&.q-field--highlighted_.q-field\\_\\_control]:([box-shadow:0_1px_5px_rgba(0,_0,_0,_0.2),_0_2px_2px_rgba(0,_0,_0,_0.14),_0_3px_1px_-2px_rgba(0,_0,_0,_0.12)]
|
|
293
|
-
[&.q-field--highlighted_.q-field\\_\\_native]:(text-
|
|
294
|
-
[&.q-field--highlighted_.q-field\\_\\_prefix]:(text-
|
|
295
|
-
[&.q-field--highlighted_.q-field\\_\\_suffix]:(text-
|
|
296
|
-
[&.q-field--highlighted_.q-field\\_\\_prepend]:(text-
|
|
297
|
-
[&.q-field--highlighted_.q-field\\_\\_append]:(text-
|
|
298
|
-
[&.q-field--highlighted_.q-field\\_\\_input]:(text-
|
|
293
|
+
[&.q-field--highlighted_.q-field\\_\\_control]:([box-shadow:0_1px_5px_rgba(0,_0,_0,_0.2),_0_2px_2px_rgba(0,_0,_0,_0.14),_0_3px_1px_-2px_rgba(0,_0,_0,_0.12)])
|
|
294
|
+
[&.q-field--highlighted_.q-field\\_\\_native]:(text-light-primary)
|
|
295
|
+
[&.q-field--highlighted_.q-field\\_\\_prefix]:(text-light-primary)
|
|
296
|
+
[&.q-field--highlighted_.q-field\\_\\_suffix]:(text-light-primary)
|
|
297
|
+
[&.q-field--highlighted_.q-field\\_\\_prepend]:(text-light-primary)
|
|
298
|
+
[&.q-field--highlighted_.q-field\\_\\_append]:(text-light-primary)
|
|
299
|
+
[&.q-field--highlighted_.q-field\\_\\_input]:(text-light-on-surface)
|
|
299
300
|
[&.q-field--readonly_.q-field\\_\\_control:before]:(opacity-100 bg-transparent border-[1px] border-dashed border-black/24)
|
|
300
|
-
[&.q-field--dark_.q-field\\_\\_control]:(bg-
|
|
301
|
+
[&.q-field--dark_.q-field\\_\\_control]:(bg-dark-surface-container-high)
|
|
301
302
|
[&.q-field--dark_.q-field\\_\\_control:before]:(layer-components:bg-white/7)
|
|
302
|
-
[&.q-field--dark.q-field--highlighted_.q-field\\_\\_control]:(layer-components:bg-
|
|
303
|
-
[&.q-field--dark.q-field--highlighted_.q-field\\_\\_native]:(text-
|
|
304
|
-
[&.q-field--dark.q-field--highlighted_.q-field\\_\\_prefix]:(text-
|
|
305
|
-
[&.q-field--dark.q-field--highlighted_.q-field\\_\\_suffix]:(text-
|
|
306
|
-
[&.q-field--dark.q-field--highlighted_.q-field\\_\\_prepend]:(text-
|
|
307
|
-
[&.q-field--dark.q-field--highlighted_.q-field\\_\\_append]:(text-
|
|
308
|
-
[&.q-field--dark.q-field--highlighted_.q-field\\_\\_input]:(text-
|
|
303
|
+
[&.q-field--dark.q-field--highlighted_.q-field\\_\\_control]:(layer-components:bg-dark-surface-container-highest)
|
|
304
|
+
[&.q-field--dark.q-field--highlighted_.q-field\\_\\_native]:(text-dark-primary)
|
|
305
|
+
[&.q-field--dark.q-field--highlighted_.q-field\\_\\_prefix]:(text-dark-primary)
|
|
306
|
+
[&.q-field--dark.q-field--highlighted_.q-field\\_\\_suffix]:(text-dark-primary)
|
|
307
|
+
[&.q-field--dark.q-field--highlighted_.q-field\\_\\_prepend]:(text-dark-primary)
|
|
308
|
+
[&.q-field--dark.q-field--highlighted_.q-field\\_\\_append]:(text-dark-primary)
|
|
309
|
+
[&.q-field--dark.q-field--highlighted_.q-field\\_\\_input]:(!text-dark-on-surface)
|
|
309
310
|
[&.q-field--dark.q-field--readonly_.q-field\\_\\_control:before]:(border-white/24)`
|
|
310
311
|
],
|
|
311
312
|
|
|
@@ -333,7 +334,7 @@ const shortcuts: UserShortcuts<QuasarTheme> = [
|
|
|
333
334
|
`[&_.q-field--with-bottom]:(pb-[19px])
|
|
334
335
|
[&_.q-field\\_\\_shadow]:(top-[0])
|
|
335
336
|
[&_.q-field\\_\\_control]:(h-[40px])
|
|
336
|
-
[&_.q-field\\_\\_marginal]:(
|
|
337
|
+
[&_.q-field\\_\\_marginal]:()
|
|
337
338
|
[&_.q-field\\_\\_bottom]:(text-[11px])
|
|
338
339
|
[&_.q-field\\_\\_label]:(text-[14px] top-[10px])
|
|
339
340
|
[&_.q-field\\_\\_before]:()
|
|
@@ -15,7 +15,7 @@ const shortcuts: UserShortcuts<QuasarTheme> = [
|
|
|
15
15
|
/^q-footer$/,
|
|
16
16
|
([, c], { theme }) =>
|
|
17
17
|
theme.quasar?.components?.['q-footer'] ??
|
|
18
|
-
`[&_.q-layout\\_\\_shadow]:(-top-[10px]) [&_.q-layout\\_\\_shadow:after]:(top-[10px])
|
|
18
|
+
`[&_.q-layout\\_\\_shadow]:(-top-[10px]) [&_.q-layout\\_\\_shadow:after]:(top-[10px]) z-${theme.quasar.z['marginals']}`
|
|
19
19
|
]
|
|
20
20
|
]
|
|
21
21
|
|
|
@@ -15,7 +15,8 @@ const shortcuts: UserShortcuts<QuasarTheme> = [
|
|
|
15
15
|
/^q-header$/,
|
|
16
16
|
([, c], { theme }) =>
|
|
17
17
|
theme.quasar?.components?.['q-header'] ??
|
|
18
|
-
`z-2000 [&_.q-layout\\_\\_shadow]:(-bottom-10px) [&_.q-layout\\_\\_shadow:after]:(bottom-10px)
|
|
18
|
+
`z-2000 [&_.q-layout\\_\\_shadow]:(-bottom-10px) [&_.q-layout\\_\\_shadow:after]:(bottom-10px)
|
|
19
|
+
[&_.q-toolbar\\_\\_title]:(flex-grow-1000)`
|
|
19
20
|
// relative
|
|
20
21
|
]
|
|
21
22
|
]
|
|
@@ -13,7 +13,7 @@ const shortcuts: UserShortcuts<QuasarTheme> = [
|
|
|
13
13
|
[&>img]:(h-full w-full)
|
|
14
14
|
[&:before]:(w-full h-full flex! items-center justify-center)
|
|
15
15
|
[&:after]:(w-full h-full flex! items-center justify-center)
|
|
16
|
-
select-none cursor-inherit layer-components:
|
|
16
|
+
select-none cursor-inherit layer-components:text-light-on-surface layer-components:dark:text-dark-on-surface inline-flex items-center justify-center v-middle
|
|
17
17
|
`
|
|
18
18
|
],
|
|
19
19
|
// [
|
|
@@ -6,22 +6,22 @@ const shortcuts: UserShortcuts<QuasarTheme> = [
|
|
|
6
6
|
/^q-item$/,
|
|
7
7
|
([, c], { theme }) =>
|
|
8
8
|
theme.quasar?.components?.['q-item'] ??
|
|
9
|
-
`min-h-[
|
|
10
|
-
[&.q-router-link--active]:(text-primary)`
|
|
9
|
+
`min-h-[28px] px-[16px] py-[8px] [color:inherit] [transition:color_0.3s,_background-color_0.3s] [&_>_.q-item\\_\\_section--thumbnail:first-child]:(-ml-[16px]) [&_>_.q-focus-helper_+_.q-item\\_\\_section--thumbnail]:(-ml-[16px]) [&_>_.q-item\\_\\_section--thumbnail:last-of-type]:(-mr-[16px]) relative
|
|
10
|
+
[&.q-router-link--active]:(text-light-primary dark:text-dark-primary)`
|
|
11
11
|
],
|
|
12
12
|
|
|
13
13
|
[
|
|
14
14
|
/^q-item__section--side$/,
|
|
15
15
|
([, c], { theme }) =>
|
|
16
16
|
theme.quasar?.components?.['q-item__section--side'] ??
|
|
17
|
-
`!flex-initial text-[#757575] items-start pr-[16px] w-auto
|
|
17
|
+
`!flex-initial text-[#757575] items-start pr-[16px] w-auto max-w-full [&_>_.q-icon]:(text-[24px]) [&_>_.q-avatar]:(text-[40px])`
|
|
18
18
|
],
|
|
19
19
|
|
|
20
20
|
[
|
|
21
21
|
/^q-item__section--avatar$/,
|
|
22
22
|
([, c], { theme }) =>
|
|
23
23
|
theme.quasar?.components?.['q-item__section--avatar'] ??
|
|
24
|
-
`!flex-initial [color:inherit] min-w-[
|
|
24
|
+
`!flex-initial [color:inherit] min-w-[40px]`
|
|
25
25
|
],
|
|
26
26
|
|
|
27
27
|
[
|
|
@@ -80,8 +80,8 @@ const shortcuts: UserShortcuts<QuasarTheme> = [
|
|
|
80
80
|
([, c], { theme }) =>
|
|
81
81
|
theme.quasar?.components?.['q-item__section--main'] ??
|
|
82
82
|
`w-auto min-w-[0] max-w-full flex-[10000_1_0%]
|
|
83
|
-
[&:has(>:last-child:nth-child(2))]:(min-h-
|
|
84
|
-
[&:has(>:last-child:nth-child(3))]:(min-h-
|
|
83
|
+
[&:has(>:last-child:nth-child(2))]:(min-h-36px)
|
|
84
|
+
[&:has(>:last-child:nth-child(3))]:(min-h-44px)
|
|
85
85
|
[&_+_.q-item\\_\\_section--main]:(ml-[8px])
|
|
86
86
|
[&_~_.q-item\\_\\_section--side]:(items-end pr-0 pl-[16px])`
|
|
87
87
|
],
|
|
@@ -104,16 +104,18 @@ const shortcuts: UserShortcuts<QuasarTheme> = [
|
|
|
104
104
|
/^q-list--dense$/,
|
|
105
105
|
([, c], { theme }) =>
|
|
106
106
|
theme.quasar?.components?.['q-list--dense'] ??
|
|
107
|
-
`[&_>_.q-item]:(min-h-[
|
|
107
|
+
`[&_>_.q-item]:(min-h-[28px] px-[16px] py-[2px])`
|
|
108
108
|
],
|
|
109
109
|
|
|
110
|
-
[/^q-item--dense$/, ([, c], { theme }) => `min-h-[
|
|
110
|
+
[/^q-item--dense$/, ([, c], { theme }) => `min-h-[28px] px-[16px] py-[2px]`],
|
|
111
111
|
|
|
112
112
|
[
|
|
113
113
|
/^q-list--dark$/,
|
|
114
114
|
([, c], { theme }) =>
|
|
115
115
|
theme.quasar?.components?.['q-list--dark'] ??
|
|
116
|
-
`text-[#fff] border-[rgba(255,_255,_255,_0.28)]
|
|
116
|
+
`text-[#fff] border-[rgba(255,_255,_255,_0.28)]
|
|
117
|
+
[&_.q-item\\_\\_section--side:not(.q-item\\_\\_section--avatar)]:(text-[rgba(255,_255,_255,_0.7)])
|
|
118
|
+
[&_.q-item\\_\\_label--header]:(text-[rgba(255,_255,_255,_0.64)]) [&_.q-item\\_\\_label--overline]:(text-[rgba(255,_255,_255,_0.8)]) [&_.q-item\\_\\_label--caption]:(text-[rgba(255,_255,_255,_0.8)])`
|
|
117
119
|
],
|
|
118
120
|
|
|
119
121
|
[
|
|
@@ -123,7 +125,10 @@ const shortcuts: UserShortcuts<QuasarTheme> = [
|
|
|
123
125
|
`text-[#fff] border-[rgba(255,_255,_255,_0.28)] [&_.q-item\\_\\_section--side:not(.q-item\\_\\_section--avatar)]:(text-[rgba(255,_255,_255,_0.7)]) [&_.q-item\\_\\_label--header]:(text-[rgba(255,_255,_255,_0.64)]) [&_.q-item\\_\\_label--overline]:(text-[rgba(255,_255,_255,_0.8)]) [&_.q-item\\_\\_label--caption]:(text-[rgba(255,_255,_255,_0.8)])`
|
|
124
126
|
],
|
|
125
127
|
|
|
126
|
-
[
|
|
128
|
+
[
|
|
129
|
+
/^q-item--active$/,
|
|
130
|
+
([, c], { theme }) => `text-light-primary dark:text-dark-primary`
|
|
131
|
+
]
|
|
127
132
|
]
|
|
128
133
|
|
|
129
134
|
export { shortcuts }
|
|
@@ -88,7 +88,7 @@ const shortcuts: UserShortcuts<QuasarTheme> = [
|
|
|
88
88
|
/^q-layout__section--marginal$/,
|
|
89
89
|
([, c], { theme }) =>
|
|
90
90
|
theme.quasar?.components?.['q-layout__section--marginal'] ??
|
|
91
|
-
`text-[#fff] bg-light-surface dark:bg-dark-surface-container text-light-on-surface dark:text-dark-on-surface`
|
|
91
|
+
`text-[#fff] bg-light-surface-container-low dark:bg-dark-surface-container-low text-light-on-surface dark:text-dark-on-surface`
|
|
92
92
|
]
|
|
93
93
|
]
|
|
94
94
|
|
|
@@ -2,6 +2,10 @@ import type { Rule, UserShortcuts } from '@unocss/core'
|
|
|
2
2
|
import type { QuasarTheme } from '../../../theme.js'
|
|
3
3
|
|
|
4
4
|
const shortcuts: UserShortcuts<QuasarTheme> = [
|
|
5
|
+
[
|
|
6
|
+
/^q-page-sticky$/,
|
|
7
|
+
([, c], { theme }) => theme.quasar?.components?.['q-page-sticky'] ?? ``
|
|
8
|
+
],
|
|
5
9
|
[
|
|
6
10
|
/^q-page-sticky--shrink$/,
|
|
7
11
|
([, c], { theme }) =>
|
|
@@ -2,7 +2,7 @@ import type { Rule, UserShortcuts } from '@unocss/core'
|
|
|
2
2
|
import type { QuasarTheme } from '../../../theme.js'
|
|
3
3
|
|
|
4
4
|
const shortcuts: UserShortcuts<QuasarTheme> = [
|
|
5
|
-
[/^q-scrollarea$/, ([, c], { theme }) => `relative`],
|
|
5
|
+
[/^q-scrollarea$/, ([, c], { theme }) => `relative [contain:strict]`],
|
|
6
6
|
|
|
7
7
|
[
|
|
8
8
|
/^q-scrollarea__bar$/,
|
|
@@ -44,10 +44,7 @@ const shortcuts: UserShortcuts<QuasarTheme> = [
|
|
|
44
44
|
|
|
45
45
|
[/^q-scrollarea__thumb:active$/, ([, c], { theme }) => `active:opacity-50`],
|
|
46
46
|
|
|
47
|
-
[
|
|
48
|
-
/^q-scrollarea__content$/,
|
|
49
|
-
([, c], { theme }) => `!relative min-h-full min-w-full`
|
|
50
|
-
],
|
|
47
|
+
[/^q-scrollarea__content$/, ([, c], { theme }) => `min-h-full w-full`],
|
|
51
48
|
|
|
52
49
|
[
|
|
53
50
|
/^q-scrollarea--dark$/,
|
|
@@ -6,7 +6,16 @@ const shortcuts: UserShortcuts<QuasarTheme> = [
|
|
|
6
6
|
/^q-stepper$/,
|
|
7
7
|
([, c], { theme }) =>
|
|
8
8
|
theme.quasar?.components?.['q-stepper'] ??
|
|
9
|
-
`[box-shadow:0_1px_5px_rgba(0,_0,_0,_0.2),_0_2px_2px_rgba(0,_0,_0,_0.14),_0_3px_1px_-2px_rgba(0,_0,_0,_0.12)] rounded-[4px]
|
|
9
|
+
`[box-shadow:0_1px_5px_rgba(0,_0,_0,_0.2),_0_2px_2px_rgba(0,_0,_0,_0.14),_0_3px_1px_-2px_rgba(0,_0,_0,_0.12)] rounded-[4px]
|
|
10
|
+
bg-light-surface dark:bg-dark-surface
|
|
11
|
+
`
|
|
12
|
+
],
|
|
13
|
+
|
|
14
|
+
[
|
|
15
|
+
/^q-stepper__label$/,
|
|
16
|
+
([, c], { theme }) =>
|
|
17
|
+
theme.quasar?.components?.['q-stepper__label'] ??
|
|
18
|
+
`bg-light-surface dark:bg-dark-surface`
|
|
10
19
|
],
|
|
11
20
|
|
|
12
21
|
[
|
|
@@ -41,7 +50,16 @@ const shortcuts: UserShortcuts<QuasarTheme> = [
|
|
|
41
50
|
/^q-stepper--dark$/,
|
|
42
51
|
([, c], { theme }) =>
|
|
43
52
|
theme.quasar?.components?.['q-stepper--dark'] ??
|
|
44
|
-
`[box-shadow:0_1px_5px_rgba(255,_255,_255,_0.2),_0_2px_2px_rgba(255,_255,_255,_0.14),_0_3px_1px_-2px_rgba(255,_255,_255,_0.12)]
|
|
53
|
+
`[box-shadow:0_1px_5px_rgba(255,_255,_255,_0.2),_0_2px_2px_rgba(255,_255,_255,_0.14),_0_3px_1px_-2px_rgba(255,_255,_255,_0.12)]
|
|
54
|
+
[&_.q-stepper\\_\\_dot_span]:(text-[#000]) [&.q-stepper--bordered]:(border-[rgba(255,_255,_255,_0.28)])
|
|
55
|
+
[&_.q-stepper\\_\\_header--border]:(border-[rgba(255,_255,_255,_0.28)])
|
|
56
|
+
[&.q-stepper--horizontal_.q-stepper\\_\\_line:before]:(bg-[rgba(255,_255,_255,_0.28)])
|
|
57
|
+
[&.q-stepper--horizontal_.q-stepper\\_\\_line:after]:(bg-[rgba(255,_255,_255,_0.28)])
|
|
58
|
+
[&.q-stepper--vertical_.q-stepper\\_\\_dot:before]:(bg-[rgba(255,_255,_255,_0.28)])
|
|
59
|
+
[&.q-stepper--vertical_.q-stepper\\_\\_dot:after]:(bg-[rgba(255,_255,_255,_0.28)])
|
|
60
|
+
[&_.q-stepper\\_\\_tab--disabled]:(text-[rgba(255,_255,_255,_0.28)])
|
|
61
|
+
[&_.q-stepper\\_\\_tab--disabled_.q-stepper\\_\\_dot]:(bg-[rgba(255,_255,_255,_0.28)])
|
|
62
|
+
[&_.q-stepper\\_\\_tab--disabled_.q-stepper\\_\\_label]:(text-[rgba(255,_255,_255,_0.54)])`
|
|
45
63
|
],
|
|
46
64
|
|
|
47
65
|
[
|
|
@@ -55,7 +73,8 @@ const shortcuts: UserShortcuts<QuasarTheme> = [
|
|
|
55
73
|
/^q-stepper__tab--active$/,
|
|
56
74
|
([, c], { theme }) =>
|
|
57
75
|
theme.quasar?.components?.['q-stepper__tab--active'] ??
|
|
58
|
-
`
|
|
76
|
+
`text-light-primary dark:text-dark-primary [&_.q-stepper\\_\\_dot]:([text-shadow:0_0_0_currentColor])
|
|
77
|
+
[&_.q-stepper\\_\\_label]:([text-shadow:0_0_0_currentColor])`
|
|
59
78
|
],
|
|
60
79
|
|
|
61
80
|
[
|
|
@@ -153,7 +172,16 @@ __.q-stepper\\_\\_tab:last-child]:(items-end) [&_.q-stepper\\_\\_tab]:(px-[0] py
|
|
|
153
172
|
/^q-stepper--horizontal$/,
|
|
154
173
|
([, c], { theme }) =>
|
|
155
174
|
theme.quasar?.components?.['q-stepper--horizontal'] ??
|
|
156
|
-
`[&_.q-stepper\\_\\_step-inner]:(p-[24px])
|
|
175
|
+
`[&_.q-stepper\\_\\_step-inner]:(p-[24px])
|
|
176
|
+
[&_.q-stepper\\_\\_tab:first-child]:([border-top-left-radius:inherit])
|
|
177
|
+
[&_.q-stepper\\_\\_tab:last-child]:([border-top-right-radius:inherit])
|
|
178
|
+
[&_.q-stepper\\_\\_tab:first-child_.q-stepper\\_\\_dot:before]:(hidden)
|
|
179
|
+
[&_.q-stepper\\_\\_tab:last-child_.q-stepper\\_\\_label:after]:(hidden)
|
|
180
|
+
[&_.q-stepper\\_\\_tab:last-child_.q-stepper\\_\\_dot:after]:(hidden)
|
|
181
|
+
[&_.q-stepper\\_\\_tab]:(overflow-hidden)
|
|
182
|
+
[&_.q-stepper\\_\\_line]:(contain-layout)
|
|
183
|
+
[&_.q-stepper\\_\\_line:before]:(absolute top-2/4 h-px w-screen bg-[rgba(0,_0,_0,_0.12)])
|
|
184
|
+
[&_.q-stepper\\_\\_line:after]:(absolute top-2/4 h-px w-screen bg-[rgba(0,_0,_0,_0.12)]) [&_.q-stepper\\_\\_label:after]:(content-[''] left-full ml-[8px]) [&_.q-stepper\\_\\_dot:after]:(content-[''] left-full ml-[8px]) [&_.q-stepper\\_\\_dot:before]:(content-[''] right-full mr-[8px]) [&_>_.q-stepper\\_\\_nav]:(pt-[0] px-[24px] pb-[24px])`
|
|
157
185
|
],
|
|
158
186
|
|
|
159
187
|
[
|
|
@@ -6,13 +6,16 @@ const shortcuts: UserShortcuts<QuasarTheme> = [
|
|
|
6
6
|
/^q-tab$/,
|
|
7
7
|
([, c], { theme }) =>
|
|
8
8
|
theme.quasar?.components?.['q-tab'] ??
|
|
9
|
-
`px-[16px] py-[0] min-h-[48px] [transition:color_0.3s,_background-color_0.3s]
|
|
9
|
+
`px-[16px] py-[0] min-h-[48px] [transition:color_0.3s,_background-color_0.3s] whitespace-nowrap [color:inherit] no-underline
|
|
10
|
+
[&_.q-badge]:(top-[3px] -right-[12px])
|
|
11
|
+
[&_>_.q-focus-helper]:(!absolute !h-32px !w-52px !top-[calc(50%-23px)] !left-[calc(50%-26px)] !border-rd-16px)
|
|
12
|
+
`
|
|
10
13
|
],
|
|
11
14
|
|
|
12
15
|
[
|
|
13
16
|
/^q-tab--full$/,
|
|
14
17
|
([, c], { theme }) =>
|
|
15
|
-
theme.quasar?.components?.['q-tab--full'] ?? `min-h-
|
|
18
|
+
theme.quasar?.components?.['q-tab--full'] ?? `min-h-72px h-72px`
|
|
16
19
|
],
|
|
17
20
|
|
|
18
21
|
[
|
|
@@ -25,7 +28,7 @@ const shortcuts: UserShortcuts<QuasarTheme> = [
|
|
|
25
28
|
/^q-tab__content$/,
|
|
26
29
|
([, c], { theme }) =>
|
|
27
30
|
theme.quasar?.components?.['q-tab__content'] ??
|
|
28
|
-
`[height:inherit] px-[0] py-[4px] min-w-[40px] [&_.q-chip--floating]:(top-[0] -right-[16px])`
|
|
31
|
+
`[height:inherit] z-2 px-[0] py-[4px] min-w-[40px] [&_.q-chip--floating]:(top-[0] -right-[16px])`
|
|
29
32
|
],
|
|
30
33
|
|
|
31
34
|
[
|
|
@@ -67,14 +70,14 @@ const shortcuts: UserShortcuts<QuasarTheme> = [
|
|
|
67
70
|
/^q-tab__indicator$/,
|
|
68
71
|
([, c], { theme }) =>
|
|
69
72
|
theme.quasar?.components?.['q-tab__indicator'] ??
|
|
70
|
-
|
|
73
|
+
`opacity-0 h-[2px] bg-current`
|
|
71
74
|
],
|
|
72
75
|
|
|
73
76
|
[
|
|
74
77
|
/^q-tab--active$/,
|
|
75
78
|
([, c], { theme }) =>
|
|
76
79
|
theme.quasar?.components?.['q-tab--active'] ??
|
|
77
|
-
`[&_.q-tab\\_\\_indicator]:(opacity-100 origin-left)`
|
|
80
|
+
`text-light-primary dark:text-dark-primary [&_.q-tab\\_\\_indicator]:(opacity-100 origin-left)`
|
|
78
81
|
],
|
|
79
82
|
|
|
80
83
|
[
|
|
@@ -156,7 +159,14 @@ const shortcuts: UserShortcuts<QuasarTheme> = [
|
|
|
156
159
|
/^q-tabs--vertical$/,
|
|
157
160
|
([, c], { theme }) =>
|
|
158
161
|
theme.quasar?.components?.['q-tabs--vertical'] ??
|
|
159
|
-
`!block h-full [&_.q-tabs\\_\\_content]:(!block h-full)
|
|
162
|
+
`!block h-full [&_.q-tabs\\_\\_content]:(!block h-full)
|
|
163
|
+
[&_.q-tabs\\_\\_arrow]:(w-full h-[36px] text-center)
|
|
164
|
+
[&_.q-tabs\\_\\_arrow--left]:(top-[0] left-[0] right-[0])
|
|
165
|
+
[&_.q-tabs\\_\\_arrow--right]:(left-[0] right-[0] bottom-[0])
|
|
166
|
+
[&_.q-tab]:(px-[8px] py-[0])
|
|
167
|
+
[&_.q-tab\\_\\_indicator]:(h-[unset] w-2px min-h-100%)
|
|
168
|
+
[&_.q-tabs--not-scrollable_.q-tabs\\_\\_content]:(h-full)
|
|
169
|
+
[&_.q-tabs--dense_.q-tab\\_\\_content]:(min-w-[24px])`
|
|
160
170
|
],
|
|
161
171
|
|
|
162
172
|
[
|
|
@@ -63,9 +63,7 @@ const shortcuts: UserShortcuts<QuasarTheme> = [
|
|
|
63
63
|
`[&_.q-toggle\\_\\_track]:(bg-light-primary dark:bg-dark-primary)
|
|
64
64
|
[&_.q-toggle\\_\\_thumb]:(text-light-on-primary-container dark:text-light-on-primary-container left-[0.95em] top-[0.0625em] w-[0.875em] h-[0.875em])
|
|
65
65
|
[&_.q-toggle\\_\\_thumb:after]:(layer-components:!bg-light-on-primary dark:!bg-dark-on-primary)
|
|
66
|
-
[&_.q-toggle\\_\\_thumb_.q-icon]:(layer-components:text-[#fff] opacity-100)
|
|
67
|
-
[&:not(.disabled):focus_.q-toggle\\_\\_thumb:before]:(scale-200)
|
|
68
|
-
[&:not(.disabled):hover_.q-toggle\\_\\_thumb:before]:(scale-200)`
|
|
66
|
+
[&_.q-toggle\\_\\_thumb_.q-icon]:(layer-components:text-[#fff] opacity-100)`
|
|
69
67
|
],
|
|
70
68
|
|
|
71
69
|
[
|
|
@@ -17,7 +17,7 @@ const shortcuts: UserShortcuts<QuasarTheme> = [
|
|
|
17
17
|
/^q-toolbar__title$/,
|
|
18
18
|
([, c], { theme }) =>
|
|
19
19
|
theme.quasar?.components?.['q-toolbar__title'] ??
|
|
20
|
-
`flex-
|
|
20
|
+
`flex-initial min-w-[1px] max-w-full text-[21px] font-normal tracking-[0.01em] px-[12px] py-[0] [&:first-child]:(pl-0) [&:last-child]:(pr-0)`
|
|
21
21
|
]
|
|
22
22
|
]
|
|
23
23
|
|
package/src/styles/md3/index.ts
CHANGED
|
@@ -231,13 +231,21 @@ const style: QuasarStyle = {
|
|
|
231
231
|
export const setDefaultProps = ({
|
|
232
232
|
QBtn,
|
|
233
233
|
QBtnDropdown,
|
|
234
|
+
QBtnGroup,
|
|
234
235
|
QInput,
|
|
235
|
-
QBtnToggle
|
|
236
|
+
QBtnToggle,
|
|
237
|
+
QSelect,
|
|
238
|
+
QField,
|
|
239
|
+
QChip
|
|
236
240
|
}: {
|
|
237
241
|
QBtn: any
|
|
238
242
|
QBtnDropdown: any
|
|
243
|
+
QBtnGroup: any
|
|
239
244
|
QInput: any
|
|
240
245
|
QBtnToggle: any
|
|
246
|
+
QSelect: any
|
|
247
|
+
QField: any
|
|
248
|
+
QChip: any
|
|
241
249
|
}) => {
|
|
242
250
|
QBtn.props.rounded = {
|
|
243
251
|
type: QBtn.props.rounded,
|
|
@@ -247,6 +255,10 @@ export const setDefaultProps = ({
|
|
|
247
255
|
type: QBtnDropdown.props.rounded,
|
|
248
256
|
default: true
|
|
249
257
|
}
|
|
258
|
+
QBtnGroup.props.rounded = {
|
|
259
|
+
type: QBtnGroup.props.rounded,
|
|
260
|
+
default: true
|
|
261
|
+
}
|
|
250
262
|
QInput.props.filled = {
|
|
251
263
|
type: QInput.props.filled,
|
|
252
264
|
default: true
|
|
@@ -255,6 +267,18 @@ export const setDefaultProps = ({
|
|
|
255
267
|
type: QBtnToggle.props.rounded,
|
|
256
268
|
default: true
|
|
257
269
|
}
|
|
270
|
+
QSelect.props.filled = {
|
|
271
|
+
type: QSelect.props.filled,
|
|
272
|
+
default: true
|
|
273
|
+
}
|
|
274
|
+
QField.props.filled = {
|
|
275
|
+
type: QField.props.filled,
|
|
276
|
+
default: true
|
|
277
|
+
}
|
|
278
|
+
QChip.props.square = {
|
|
279
|
+
type: QChip.props.square,
|
|
280
|
+
default: true
|
|
281
|
+
}
|
|
258
282
|
}
|
|
259
283
|
|
|
260
284
|
export default style
|
package/src/theme.ts
CHANGED
|
@@ -383,6 +383,7 @@ export interface QuasarTheme {
|
|
|
383
383
|
'q-badge--outline'?: string
|
|
384
384
|
'q-badge--rounded'?: string
|
|
385
385
|
'q-banner'?: string
|
|
386
|
+
'q-banner__content'?: string
|
|
386
387
|
'q-banner--top-padding'?: string
|
|
387
388
|
'q-banner__avatar'?: string
|
|
388
389
|
'q-banner__actions'?: string
|
|
@@ -429,6 +430,7 @@ export interface QuasarTheme {
|
|
|
429
430
|
'q-btn-group--spread'?: string
|
|
430
431
|
'q-btn-toggle'?: string
|
|
431
432
|
'q-card'?: string
|
|
433
|
+
'q-card--filled'?: string
|
|
432
434
|
'q-card--bordered'?: string
|
|
433
435
|
'q-card--dark'?: string
|
|
434
436
|
'q-card__section'?: string
|
|
@@ -474,6 +476,7 @@ export interface QuasarTheme {
|
|
|
474
476
|
'q-message-text-content--sent'?: string
|
|
475
477
|
'q-message-text'?: string
|
|
476
478
|
'q-checkbox'?: string
|
|
479
|
+
'q-checkbox__label'?: string
|
|
477
480
|
'q-checkbox__native'?: string
|
|
478
481
|
'q-checkbox__bg'?: string
|
|
479
482
|
'q-checkbox__icon-container'?: string
|
|
@@ -730,6 +733,7 @@ export interface QuasarTheme {
|
|
|
730
733
|
'q-drawer__backdrop'?: string
|
|
731
734
|
'q-drawer__opener'?: string
|
|
732
735
|
'q-page'?: string
|
|
736
|
+
'q-page-sticky'?: string
|
|
733
737
|
'q-page-sticky--shrink'?: string
|
|
734
738
|
'q-body--layout-animate'?: string
|
|
735
739
|
'q-body--drawer-toggle'?: string
|
|
@@ -905,6 +909,7 @@ export interface QuasarTheme {
|
|
|
905
909
|
'q-splitter__before'?: string
|
|
906
910
|
'q-splitter__after'?: string
|
|
907
911
|
'q-stepper'?: string
|
|
912
|
+
'q-stepper__label'?: string
|
|
908
913
|
'q-stepper__title'?: string
|
|
909
914
|
'q-stepper__caption'?: string
|
|
910
915
|
'q-stepper__dot'?: string
|
|
@@ -1762,7 +1767,7 @@ export const generateTheme = (sourceColor: string): QuasarTheme => {
|
|
|
1762
1767
|
secondary: hexFromArgb(materialTheme.schemes.light.secondary),
|
|
1763
1768
|
accent: hexFromArgb(materialTheme.schemes.light.tertiary),
|
|
1764
1769
|
|
|
1765
|
-
'dark-page': hexFromArgb(materialTheme.
|
|
1770
|
+
'dark-page': hexFromArgb(materialTheme.schemes.dark.surface)
|
|
1766
1771
|
}
|
|
1767
1772
|
}
|
|
1768
1773
|
}
|