@basis-ng/styles 0.0.1-alpha.16 → 0.0.1-alpha.160
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/package.json +27 -36
- package/src/components/alert.css +58 -0
- package/src/components/badge.css +37 -0
- package/src/components/button-group.css +16 -0
- package/src/components/button.css +82 -0
- package/src/components/calendar.css +56 -0
- package/src/components/card.css +24 -0
- package/src/components/checkbox.css +66 -0
- package/src/components/command-options.css +17 -0
- package/src/components/command.css +20 -0
- package/src/components/dialog.css +41 -0
- package/src/components/drawer.css +34 -0
- package/src/components/input-group.css +138 -0
- package/src/components/input.css +62 -0
- package/src/components/{label.component.css → label.css} +70 -74
- package/src/components/menu.css +159 -0
- package/src/components/option.css +37 -0
- package/src/components/otp.css +69 -0
- package/src/components/range.css +29 -0
- package/src/components/{row-item.component.css → row-item.css} +14 -14
- package/src/components/{row.component.css → row.css} +48 -56
- package/src/components/select-options.css +56 -0
- package/src/components/select.css +210 -0
- package/src/components/sheet.css +34 -0
- package/src/components/spinner.css +3 -0
- package/src/components/switch.css +48 -0
- package/src/components/tabs.css +88 -0
- package/src/components/textarea-group.css +63 -0
- package/src/components/textarea.css +38 -0
- package/src/components/tooltip.css +37 -0
- package/src/components/tree.css +50 -0
- package/src/index.css +80 -39
- package/src/utilities/general.css +7 -0
- package/src/utilities/index.css +2 -0
- package/src/utilities/sizes.css +7 -0
- package/src/components/alert.component.css +0 -71
- package/src/components/attached-box.component.css +0 -84
- package/src/components/badge.component.css +0 -58
- package/src/components/bottom-sheet.component.css +0 -49
- package/src/components/button-group.component.css +0 -20
- package/src/components/button.component.css +0 -165
- package/src/components/checkbox.component.css +0 -41
- package/src/components/color-picker.component.css +0 -34
- package/src/components/combobox-options.component.css +0 -41
- package/src/components/combobox.component.css +0 -8
- package/src/components/command-options.component.css +0 -33
- package/src/components/command.component.css +0 -45
- package/src/components/icon.component.css +0 -5
- package/src/components/input-group.component.css +0 -110
- package/src/components/input.component.css +0 -70
- package/src/components/menu-group.component.css +0 -18
- package/src/components/menu-item-checkbox.component.css +0 -32
- package/src/components/menu-item-radio.component.css +0 -32
- package/src/components/menu-item.component.css +0 -32
- package/src/components/menu-label.component.css +0 -4
- package/src/components/menu.component.css +0 -32
- package/src/components/option.component.css +0 -26
- package/src/components/range.component.css +0 -39
- package/src/components/select-options.component.css +0 -41
- package/src/components/select.component.css +0 -8
- package/src/components/side-sheet.component.css +0 -59
- package/src/components/spinner.component.css +0 -13
- package/src/components/switch.component.css +0 -68
- package/src/components/tab.component.css +0 -41
- package/src/components/table.component.css +0 -34
- package/src/components/tabs.component.css +0 -18
- package/src/components/textarea.component.css +0 -40
- package/src/components/tooltip.component.css +0 -45
- package/src/components/tree-node.component.css +0 -77
- package/src/components/tree.component.css +0 -7
package/package.json
CHANGED
|
@@ -1,46 +1,37 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@basis-ng/styles",
|
|
3
|
-
"version": "0.0.1-alpha.
|
|
3
|
+
"version": "0.0.1-alpha.160",
|
|
4
4
|
"description": "CSS foundation for @basis-ng/primitives components",
|
|
5
5
|
"main": "src/index.css",
|
|
6
6
|
"exports": {
|
|
7
7
|
".": "./src/index.css",
|
|
8
|
-
"./alert": "./src/components/alert.
|
|
9
|
-
"./
|
|
10
|
-
"./
|
|
11
|
-
"./
|
|
12
|
-
"./button
|
|
13
|
-
"./
|
|
14
|
-
"./
|
|
15
|
-
"./
|
|
16
|
-
"./
|
|
17
|
-
"./
|
|
18
|
-
"./
|
|
19
|
-
"./
|
|
20
|
-
"./
|
|
21
|
-
"./
|
|
22
|
-
"./
|
|
23
|
-
"./menu-item": "./src/components/menu-item.component.css",
|
|
24
|
-
"./menu-label": "./src/components/menu-label.component.css",
|
|
25
|
-
"./menu": "./src/components/menu.component.css",
|
|
26
|
-
"./option": "./src/components/option.component.css",
|
|
27
|
-
"./range": "./src/components/range.component.css",
|
|
28
|
-
"./row-item": "./src/components/row-item.component.css",
|
|
29
|
-
"./row": "./src/components/row.component.css",
|
|
8
|
+
"./alert": "./src/components/alert.css",
|
|
9
|
+
"./badge": "./src/components/badge.css",
|
|
10
|
+
"./drawer": "./src/components/drawer.css",
|
|
11
|
+
"./button-group": "./src/components/button-group.css",
|
|
12
|
+
"./button": "./src/components/button.css",
|
|
13
|
+
"./checkbox": "./src/components/checkbox.css",
|
|
14
|
+
"./input-group": "./src/components/input-group.css",
|
|
15
|
+
"./textarea-group": "./src/components/textarea-group.css",
|
|
16
|
+
"./input": "./src/components/input.css",
|
|
17
|
+
"./label": "./src/components/label.css",
|
|
18
|
+
"./menu": "./src/components/menu.css",
|
|
19
|
+
"./option": "./src/components/option.css",
|
|
20
|
+
"./range": "./src/components/range.css",
|
|
21
|
+
"./row-item": "./src/components/row-item.css",
|
|
22
|
+
"./row": "./src/components/row.css",
|
|
30
23
|
"./search": "./src/components/search.component.css",
|
|
31
|
-
"./select": "./src/components/select.
|
|
32
|
-
"./select-
|
|
33
|
-
"./
|
|
34
|
-
"./
|
|
35
|
-
"./
|
|
36
|
-
"./
|
|
37
|
-
"./
|
|
38
|
-
"./
|
|
39
|
-
"./
|
|
40
|
-
"./
|
|
41
|
-
"./
|
|
42
|
-
"./tree-node": "./src/components/tree-node.component.css",
|
|
43
|
-
"./tree": "./src/components/tree.component.css"
|
|
24
|
+
"./select": "./src/components/select.css",
|
|
25
|
+
"./select-option": "./src/components/select-option.css",
|
|
26
|
+
"./sheet": "./src/components/sheet.css",
|
|
27
|
+
"./spinner": "./src/components/spinner.css",
|
|
28
|
+
"./switch": "./src/components/switch.css",
|
|
29
|
+
"./tabs": "./src/components/tabs.css",
|
|
30
|
+
"./textarea": "./src/components/textarea.css",
|
|
31
|
+
"./tooltip": "./src/components/tooltip.css",
|
|
32
|
+
"./tree": "./src/components/tree.css",
|
|
33
|
+
"./dialog": "./src/components/dialog.css",
|
|
34
|
+
"./calendar": "./src/components/calendar.css"
|
|
44
35
|
},
|
|
45
36
|
"files": [
|
|
46
37
|
"src/**/*.css"
|
|
@@ -0,0 +1,58 @@
|
|
|
1
|
+
/* Alert styles — Base / Types / Sizes / Close */
|
|
2
|
+
|
|
3
|
+
/* Use the same selector the primitive exposes: `b-alert` */
|
|
4
|
+
|
|
5
|
+
b-alert {
|
|
6
|
+
@apply flex items-start gap-4 p-4 rounded-size-md w-full box-border max-w-full font-sans;
|
|
7
|
+
|
|
8
|
+
.icon {
|
|
9
|
+
@apply flex-shrink-0 self-start;
|
|
10
|
+
}
|
|
11
|
+
|
|
12
|
+
.content {
|
|
13
|
+
@apply flex-1 flex flex-col gap-1;
|
|
14
|
+
|
|
15
|
+
.title {
|
|
16
|
+
@apply font-semibold;
|
|
17
|
+
}
|
|
18
|
+
|
|
19
|
+
.body {
|
|
20
|
+
@apply text-sm;
|
|
21
|
+
}
|
|
22
|
+
}
|
|
23
|
+
|
|
24
|
+
/* Default: info */
|
|
25
|
+
@apply bg-info/20 text-info-foreground dark:bg-info-dark/20 dark:text-info-foreground-dark;
|
|
26
|
+
|
|
27
|
+
/* Types (match primitive's `type` input): use `b-type-` prefix to avoid classname collisions */
|
|
28
|
+
&.b-type-success {
|
|
29
|
+
@apply bg-success/20 inset-ring-1 text-success-foreground dark:bg-success-dark/20 dark:text-success-foreground-dark inset-ring-success/90 dark:inset-ring-success-dark/30;
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
&.b-type-error {
|
|
33
|
+
@apply bg-destructive/20 inset-ring-1 text-destructive dark:bg-destructive-dark/20 dark:text-destructive-dark inset-ring-destructive/30 dark:inset-ring-destructive-dark/30;
|
|
34
|
+
}
|
|
35
|
+
|
|
36
|
+
&.b-type-warning {
|
|
37
|
+
@apply bg-warning/20 inset-ring-1 text-warning-foreground dark:bg-warning-dark/20 dark:text-warning-foreground-dark inset-ring-warning/90 dark:inset-ring-warning-dark/30;
|
|
38
|
+
}
|
|
39
|
+
|
|
40
|
+
&.b-type-info {
|
|
41
|
+
@apply bg-info/20 inset-ring-1 text-info-foreground dark:bg-info-dark/20 dark:text-info-foreground-dark inset-ring-info/90 dark:inset-ring-info-dark/30;
|
|
42
|
+
}
|
|
43
|
+
|
|
44
|
+
/* Sizes */
|
|
45
|
+
&.b-size-sm {
|
|
46
|
+
@apply p-2 text-sm;
|
|
47
|
+
}
|
|
48
|
+
&.b-size-md {
|
|
49
|
+
@apply p-4 text-base;
|
|
50
|
+
}
|
|
51
|
+
&.b-size-lg {
|
|
52
|
+
@apply p-6 text-lg;
|
|
53
|
+
}
|
|
54
|
+
|
|
55
|
+
.close-btn {
|
|
56
|
+
@apply ml-auto bg-transparent border-0 cursor-pointer p-1 rounded;
|
|
57
|
+
}
|
|
58
|
+
}
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
span[b-badge] {
|
|
2
|
+
/* Base */
|
|
3
|
+
@apply inline-flex items-center gap-2 px-2 py-1 font-medium text-sm rounded-size-md;
|
|
4
|
+
@apply bg-primary text-primary-foreground dark:bg-primary-dark dark:text-primary-foreground-dark;
|
|
5
|
+
|
|
6
|
+
/* Variants */
|
|
7
|
+
&.b-variant-primary {
|
|
8
|
+
@apply bg-primary text-primary-foreground dark:bg-primary-dark dark:text-primary-foreground-dark;
|
|
9
|
+
}
|
|
10
|
+
|
|
11
|
+
&.b-variant-secondary {
|
|
12
|
+
@apply bg-secondary text-secondary-foreground dark:bg-secondary-dark dark:text-secondary-foreground-dark;
|
|
13
|
+
}
|
|
14
|
+
|
|
15
|
+
&.b-variant-ghost {
|
|
16
|
+
@apply bg-transparent text-secondary-foreground dark:text-secondary-foreground-dark;
|
|
17
|
+
}
|
|
18
|
+
|
|
19
|
+
&.b-variant-outlined {
|
|
20
|
+
@apply bg-transparent inset-ring-1 inset-ring-ring text-secondary-foreground dark:inset-ring-ring-dark dark:text-secondary-foreground-dark;
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
&.b-variant-destructive {
|
|
24
|
+
@apply bg-destructive text-destructive-foreground dark:bg-destructive-dark dark:text-destructive-foreground-dark;
|
|
25
|
+
}
|
|
26
|
+
|
|
27
|
+
/* Sizes */
|
|
28
|
+
&.b-size-sm {
|
|
29
|
+
@apply px-1.5 py-0.5 text-xs rounded-size-sm;
|
|
30
|
+
}
|
|
31
|
+
&.b-size-md {
|
|
32
|
+
@apply px-2 py-1 text-sm rounded-size-md;
|
|
33
|
+
}
|
|
34
|
+
&.b-size-lg {
|
|
35
|
+
@apply px-2.5 py-1 text-base rounded-size-lg;
|
|
36
|
+
}
|
|
37
|
+
}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
b-button-group {
|
|
2
|
+
@apply flex;
|
|
3
|
+
|
|
4
|
+
&:not(.spaced) {
|
|
5
|
+
button:not(:last-child) {
|
|
6
|
+
@apply rounded-tr-none rounded-br-none -mr-[1px];
|
|
7
|
+
}
|
|
8
|
+
button:not(:first-child) {
|
|
9
|
+
@apply rounded-tl-none rounded-bl-none;
|
|
10
|
+
}
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
&.spaced {
|
|
14
|
+
@apply gap-2;
|
|
15
|
+
}
|
|
16
|
+
}
|
|
@@ -0,0 +1,82 @@
|
|
|
1
|
+
/* Button styles — grouped sections: Base / Variants / Sizes / States / Squared */
|
|
2
|
+
button[b-button] {
|
|
3
|
+
/* Base */
|
|
4
|
+
@apply transition-colors duration-150 flex items-center justify-center gap-x-1.5 disabled:opacity-50 disabled:cursor-not-allowed;
|
|
5
|
+
|
|
6
|
+
/* Default spacing/typography applied when no explicit size is present */
|
|
7
|
+
@apply px-3 py-0 text-sm h-8 rounded-size-md;
|
|
8
|
+
|
|
9
|
+
/* Default visual (primary) applied when no explicit variant is present */
|
|
10
|
+
@apply bg-primary text-primary-foreground hover:bg-primary/80;
|
|
11
|
+
@apply dark:bg-primary-dark dark:text-primary-foreground-dark dark:hover:bg-primary-dark/80;
|
|
12
|
+
|
|
13
|
+
/* Variants */
|
|
14
|
+
&.b-variant-primary {
|
|
15
|
+
@apply bg-primary text-primary-foreground hover:bg-primary/80;
|
|
16
|
+
@apply dark:bg-primary-dark dark:text-primary-foreground-dark dark:hover:bg-primary-dark/80;
|
|
17
|
+
}
|
|
18
|
+
&.b-variant-secondary {
|
|
19
|
+
@apply bg-secondary/10 text-secondary-foreground hover:bg-secondary/20;
|
|
20
|
+
@apply dark:bg-secondary-dark/20 dark:text-secondary-foreground-dark dark:hover:bg-secondary-dark/30;
|
|
21
|
+
}
|
|
22
|
+
&.b-variant-ghost {
|
|
23
|
+
@apply bg-transparent text-secondary-foreground hover:bg-secondary/10;
|
|
24
|
+
@apply dark:text-secondary-foreground-dark dark:hover:bg-secondary-dark/20;
|
|
25
|
+
}
|
|
26
|
+
&.b-variant-outlined {
|
|
27
|
+
@apply bg-transparent text-secondary-foreground border border-secondary/20 hover:bg-secondary/10 shadow-xs;
|
|
28
|
+
@apply dark:bg-transparent dark:text-secondary-foreground-dark dark:border-secondary-dark/30 dark:hover:bg-secondary-dark/10 shadow-xs;
|
|
29
|
+
}
|
|
30
|
+
&.b-variant-destructive {
|
|
31
|
+
@apply bg-destructive text-destructive-foreground inset-ring-1 inset-ring-destructive hover:bg-destructive/90 hover:inset-ring-destructive/80;
|
|
32
|
+
@apply dark:bg-destructive-dark dark:text-destructive-foreground-dark dark:inset-ring-destructive-dark dark:hover:bg-destructive-dark/90 dark:hover:inset-ring-destructive-dark/80;
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
/* Sizes */
|
|
36
|
+
&.b-size-sm {
|
|
37
|
+
@apply px-2 py-0 text-xs h-6 rounded-size-sm gap-1;
|
|
38
|
+
}
|
|
39
|
+
&.b-size-md {
|
|
40
|
+
@apply px-3 py-0 text-sm h-8 rounded-size-md gap-1.5;
|
|
41
|
+
}
|
|
42
|
+
&.b-size-lg {
|
|
43
|
+
@apply px-4 py-0 text-base h-10 rounded-size-lg gap-2;
|
|
44
|
+
}
|
|
45
|
+
|
|
46
|
+
/* States */
|
|
47
|
+
&.b-active,
|
|
48
|
+
&:focus-visible {
|
|
49
|
+
@apply outline-2 outline-offset-4 outline-primary;
|
|
50
|
+
@apply dark:outline-primary-dark;
|
|
51
|
+
}
|
|
52
|
+
&.b-variant-destructive.b-active,
|
|
53
|
+
&.b-variant-destructive:focus-visible {
|
|
54
|
+
@apply outline-2 outline-offset-4 outline-destructive;
|
|
55
|
+
@apply dark:outline-destructive-dark;
|
|
56
|
+
}
|
|
57
|
+
|
|
58
|
+
/* Squared */
|
|
59
|
+
&.b-squared {
|
|
60
|
+
@apply aspect-square p-0 flex items-center justify-center;
|
|
61
|
+
}
|
|
62
|
+
&.b-squared.b-size-sm {
|
|
63
|
+
@apply size-6;
|
|
64
|
+
}
|
|
65
|
+
&.b-squared.b-size-md {
|
|
66
|
+
@apply size-8;
|
|
67
|
+
}
|
|
68
|
+
&.b-squared.b-size-lg {
|
|
69
|
+
@apply size-10;
|
|
70
|
+
}
|
|
71
|
+
|
|
72
|
+
/* Rounded full - extra horizontal padding */
|
|
73
|
+
&.b-rounded-full:not(.b-squared) {
|
|
74
|
+
@apply px-4;
|
|
75
|
+
}
|
|
76
|
+
&.b-size-sm.b-rounded-full:not(.b-squared) {
|
|
77
|
+
@apply px-3;
|
|
78
|
+
}
|
|
79
|
+
&.b-size-lg.b-rounded-full:not(.b-squared) {
|
|
80
|
+
@apply px-5;
|
|
81
|
+
}
|
|
82
|
+
}
|
|
@@ -0,0 +1,56 @@
|
|
|
1
|
+
/* Calendar component styles - simple, utility-first classes matching project conventions */
|
|
2
|
+
b-calendar {
|
|
3
|
+
@apply w-full min-w-60 flex flex-col gap-1;
|
|
4
|
+
|
|
5
|
+
header.b-calendar-header {
|
|
6
|
+
@apply flex gap-0.5 w-full justify-between;
|
|
7
|
+
|
|
8
|
+
.b-calendar-header {
|
|
9
|
+
@apply flex items-center justify-between mb-2;
|
|
10
|
+
}
|
|
11
|
+
|
|
12
|
+
.b-calendar-title {
|
|
13
|
+
@apply font-medium text-sm;
|
|
14
|
+
@apply px-3 py-1 rounded-size-sm text-sm font-medium cursor-pointer bg-transparent hover:bg-secondary/10 dark:hover:bg-secondary-dark/10;
|
|
15
|
+
}
|
|
16
|
+
|
|
17
|
+
.b-calendar-nav {
|
|
18
|
+
@apply inline-flex items-center justify-center w-8 h-8 rounded-size-sm cursor-pointer bg-transparent hover:bg-secondary/10 dark:hover:bg-secondary-dark/10;
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
.b-calendar-title:focus {
|
|
22
|
+
@apply outline-none ring-2 ring-primary/10;
|
|
23
|
+
}
|
|
24
|
+
}
|
|
25
|
+
|
|
26
|
+
table.b-calendar-table {
|
|
27
|
+
@apply w-full table table-fixed border-collapse;
|
|
28
|
+
|
|
29
|
+
.b-calendar-weekday {
|
|
30
|
+
@apply text-xs text-center h-6;
|
|
31
|
+
}
|
|
32
|
+
|
|
33
|
+
.b-calendar-cell {
|
|
34
|
+
@apply text-center rounded-size-sm w-full h-8 place-content-center;
|
|
35
|
+
|
|
36
|
+
&.b-active {
|
|
37
|
+
@apply bg-primary text-primary-foreground;
|
|
38
|
+
@apply dark:bg-primary-dark dark:text-primary-foreground-dark;
|
|
39
|
+
|
|
40
|
+
&[data-outside] {
|
|
41
|
+
@apply text-primary-foreground;
|
|
42
|
+
@apply dark:text-primary-foreground-dark;
|
|
43
|
+
}
|
|
44
|
+
}
|
|
45
|
+
|
|
46
|
+
&[data-outside] {
|
|
47
|
+
@apply opacity-50;
|
|
48
|
+
}
|
|
49
|
+
|
|
50
|
+
&:not(.b-active):hover,
|
|
51
|
+
&:not(.b-active):focus {
|
|
52
|
+
@apply bg-secondary/10 dark:bg-secondary-dark/10 cursor-pointer;
|
|
53
|
+
}
|
|
54
|
+
}
|
|
55
|
+
}
|
|
56
|
+
}
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
b-card {
|
|
2
|
+
@apply flex flex-col gap-4 p-6 bg-background inset-ring-1 inset-ring-ring rounded-size-lg;
|
|
3
|
+
@apply dark:bg-background-dark dark:inset-ring-ring-dark;
|
|
4
|
+
|
|
5
|
+
b-card-header {
|
|
6
|
+
@apply flex flex-col gap-1;
|
|
7
|
+
|
|
8
|
+
b-card-title {
|
|
9
|
+
@apply text-base font-semibold opacity-100;
|
|
10
|
+
}
|
|
11
|
+
|
|
12
|
+
b-card-description {
|
|
13
|
+
@apply text-sm opacity-70;
|
|
14
|
+
}
|
|
15
|
+
}
|
|
16
|
+
|
|
17
|
+
b-card-content {
|
|
18
|
+
@apply flex flex-col gap-2;
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
b-card-footer {
|
|
22
|
+
@apply flex justify-end gap-2;
|
|
23
|
+
}
|
|
24
|
+
}
|
|
@@ -0,0 +1,66 @@
|
|
|
1
|
+
button[b-checkbox] {
|
|
2
|
+
/* Base */
|
|
3
|
+
@apply inline-flex items-center justify-center align-middle select-none text-secondary-foreground bg-background inset-ring-1 inset-ring-ring shadow-xs;
|
|
4
|
+
@apply dark:bg-background-dark dark:text-secondary-foreground-dark dark:inset-ring-ring-dark;
|
|
5
|
+
@apply size-5 rounded-size-sm;
|
|
6
|
+
|
|
7
|
+
&:not([data-disabled]) {
|
|
8
|
+
@apply cursor-pointer hover:bg-secondary/20;
|
|
9
|
+
@apply dark:hover:bg-secondary-dark/30;
|
|
10
|
+
}
|
|
11
|
+
|
|
12
|
+
&[data-disabled] {
|
|
13
|
+
@apply opacity-50 cursor-not-allowed;
|
|
14
|
+
}
|
|
15
|
+
|
|
16
|
+
&[data-state='checked'] {
|
|
17
|
+
@apply bg-primary text-primary-foreground inset-ring-primary;
|
|
18
|
+
@apply dark:bg-primary-dark dark:text-primary-foreground-dark dark:inset-ring-primary-dark;
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
&[data-state='checked']:not([data-disabled]) {
|
|
22
|
+
@apply hover:bg-primary/80;
|
|
23
|
+
@apply dark:hover:bg-primary-dark/80;
|
|
24
|
+
}
|
|
25
|
+
|
|
26
|
+
&:focus-visible {
|
|
27
|
+
@apply outline-2 outline-offset-4 outline-primary;
|
|
28
|
+
@apply dark:outline-primary-dark;
|
|
29
|
+
}
|
|
30
|
+
|
|
31
|
+
/* Sizes */
|
|
32
|
+
&.b-size-sm {
|
|
33
|
+
@apply size-4 rounded-size-xs;
|
|
34
|
+
}
|
|
35
|
+
&.b-size-lg {
|
|
36
|
+
@apply size-6 rounded-size-md;
|
|
37
|
+
}
|
|
38
|
+
|
|
39
|
+
.b-checkbox-indicator {
|
|
40
|
+
@apply pointer-events-none flex items-center justify-center text-current;
|
|
41
|
+
}
|
|
42
|
+
|
|
43
|
+
&.b-size-sm .b-checkbox-indicator svg {
|
|
44
|
+
@apply h-2.5 w-2.5;
|
|
45
|
+
}
|
|
46
|
+
|
|
47
|
+
&.b-size-md .b-checkbox-indicator svg {
|
|
48
|
+
@apply h-3 w-3;
|
|
49
|
+
}
|
|
50
|
+
|
|
51
|
+
&.b-size-lg .b-checkbox-indicator svg {
|
|
52
|
+
@apply h-3.5 w-3.5;
|
|
53
|
+
}
|
|
54
|
+
|
|
55
|
+
&[data-state='unchecked'] .b-checkbox-indicator {
|
|
56
|
+
@apply opacity-0 scale-75;
|
|
57
|
+
}
|
|
58
|
+
|
|
59
|
+
&[data-state='checked'] .b-checkbox-indicator {
|
|
60
|
+
@apply opacity-100 scale-100;
|
|
61
|
+
}
|
|
62
|
+
|
|
63
|
+
svg {
|
|
64
|
+
@apply block;
|
|
65
|
+
}
|
|
66
|
+
}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
ul[b-command-options] {
|
|
2
|
+
list-style: none;
|
|
3
|
+
box-sizing: border-box;
|
|
4
|
+
margin: 0;
|
|
5
|
+
position: relative;
|
|
6
|
+
display: flex;
|
|
7
|
+
flex-direction: column;
|
|
8
|
+
gap: 0.25rem;
|
|
9
|
+
width: 100%;
|
|
10
|
+
overflow-y: auto;
|
|
11
|
+
padding: 0;
|
|
12
|
+
scrollbar-width: thin;
|
|
13
|
+
|
|
14
|
+
.no-options-message {
|
|
15
|
+
padding: 0.5rem 0.75rem;
|
|
16
|
+
}
|
|
17
|
+
}
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
b-command {
|
|
2
|
+
padding: 0.25rem;
|
|
3
|
+
box-sizing: border-box;
|
|
4
|
+
margin: 0;
|
|
5
|
+
position: relative;
|
|
6
|
+
background: var(--background, #ffffff);
|
|
7
|
+
box-shadow: 0 0 0.25rem 0.125rem rgba(1, 1, 1, 0.01);
|
|
8
|
+
border-radius: clamp(0rem, var(--radius, 0.5rem), 0.5rem);
|
|
9
|
+
border: 1px solid color-mix(in srgb, var(--foreground, #798194) 10%, var(--background, #ffffff));
|
|
10
|
+
display: flex;
|
|
11
|
+
flex-direction: column;
|
|
12
|
+
gap: 0.25rem;
|
|
13
|
+
width: 100%;
|
|
14
|
+
|
|
15
|
+
input {
|
|
16
|
+
&:focus-visible {
|
|
17
|
+
outline: none !important;
|
|
18
|
+
}
|
|
19
|
+
}
|
|
20
|
+
}
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
b-dialog-content {
|
|
2
|
+
animation: b-dialog-enter 150ms ease-in-out;
|
|
3
|
+
|
|
4
|
+
&.leaving {
|
|
5
|
+
transform: scale(0.9);
|
|
6
|
+
opacity: 0;
|
|
7
|
+
transition:
|
|
8
|
+
transform 150ms ease-in-out,
|
|
9
|
+
opacity 150ms ease-in-out;
|
|
10
|
+
}
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
.b-dialog-backdrop {
|
|
14
|
+
background-color: rgba(0, 0, 0, 0.08);
|
|
15
|
+
animation: b-dialog-backdrop-enter 150ms ease-in-out;
|
|
16
|
+
}
|
|
17
|
+
|
|
18
|
+
:has(b-dialog-content.leaving) .b-dialog-backdrop {
|
|
19
|
+
opacity: 0;
|
|
20
|
+
transition: opacity 150ms ease-in-out;
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
@keyframes b-dialog-enter {
|
|
24
|
+
0% {
|
|
25
|
+
opacity: 0;
|
|
26
|
+
transform: scale(0.9);
|
|
27
|
+
}
|
|
28
|
+
100% {
|
|
29
|
+
opacity: 1;
|
|
30
|
+
transform: scale(1);
|
|
31
|
+
}
|
|
32
|
+
}
|
|
33
|
+
|
|
34
|
+
@keyframes b-dialog-backdrop-enter {
|
|
35
|
+
0% {
|
|
36
|
+
opacity: 0;
|
|
37
|
+
}
|
|
38
|
+
100% {
|
|
39
|
+
opacity: 1;
|
|
40
|
+
}
|
|
41
|
+
}
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
b-drawer {
|
|
2
|
+
@apply fixed bottom-0 left-0 right-0 mx-auto bg-background dark:bg-background-dark rounded-t-lg border border-secondary dark:border-secondary-dark border-b-0 flex flex-col z-[999] will-change-transform shadow-2xl touch-none select-none pt-10 box-border overflow-hidden h-1/2;
|
|
3
|
+
transition: transform 0.5s cubic-bezier(0.32, 0.72, 0, 1);
|
|
4
|
+
transform: translateY(100%);
|
|
5
|
+
|
|
6
|
+
&.dragging {
|
|
7
|
+
transition: none;
|
|
8
|
+
}
|
|
9
|
+
|
|
10
|
+
.drag-section {
|
|
11
|
+
@apply w-full h-10 flex items-center justify-center cursor-grab touch-none absolute top-0;
|
|
12
|
+
|
|
13
|
+
.drag-indicator {
|
|
14
|
+
@apply w-1/5 h-1 bg-secondary dark:bg-secondary-dark rounded;
|
|
15
|
+
}
|
|
16
|
+
}
|
|
17
|
+
|
|
18
|
+
.drawer-content {
|
|
19
|
+
@apply flex-1 overflow-auto;
|
|
20
|
+
}
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
html:has(b-drawer.open) {
|
|
24
|
+
overflow: hidden;
|
|
25
|
+
}
|
|
26
|
+
|
|
27
|
+
@keyframes fadeIn {
|
|
28
|
+
from {
|
|
29
|
+
opacity: 0;
|
|
30
|
+
}
|
|
31
|
+
to {
|
|
32
|
+
opacity: 1;
|
|
33
|
+
}
|
|
34
|
+
}
|
|
@@ -0,0 +1,138 @@
|
|
|
1
|
+
b-input-group {
|
|
2
|
+
/* Base */
|
|
3
|
+
@apply flex overflow-hidden items-center;
|
|
4
|
+
@apply bg-secondary/10 text-secondary-foreground inset-ring-1 inset-ring-ring shadow-xs;
|
|
5
|
+
@apply dark:bg-secondary-dark/40 dark:text-secondary-foreground-dark dark:inset-ring-ring-dark shadow-xs;
|
|
6
|
+
|
|
7
|
+
/* Base md by default */
|
|
8
|
+
@apply px-2.5 py-0 text-sm h-8 rounded-size-md gap-1.5;
|
|
9
|
+
|
|
10
|
+
&:has(> button[b-button]:first-child) {
|
|
11
|
+
@apply pl-1!;
|
|
12
|
+
}
|
|
13
|
+
|
|
14
|
+
&:has(> button[b-button]:last-child) {
|
|
15
|
+
@apply pr-1!;
|
|
16
|
+
}
|
|
17
|
+
|
|
18
|
+
/* Internal input adjustments when placed inside group */
|
|
19
|
+
input[b-input] {
|
|
20
|
+
@apply outline-0! px-0! inset-ring-0 w-full! rounded-none! bg-transparent hover:bg-transparent shadow-none;
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
/* Internal button adjustments when placed inside group */
|
|
24
|
+
button[b-button] {
|
|
25
|
+
@apply inset-ring-0 shadow-none rounded-size-sm;
|
|
26
|
+
}
|
|
27
|
+
|
|
28
|
+
/* Squared buttons should match the input group height */
|
|
29
|
+
button[b-button].b-squared {
|
|
30
|
+
@apply h-full! w-auto! aspect-square;
|
|
31
|
+
}
|
|
32
|
+
|
|
33
|
+
/* Focus state when any inner input is focused (and not readonly) */
|
|
34
|
+
&:has(input[b-input]:focus-visible:not(:read-only)) {
|
|
35
|
+
/* Focus outline remains primary for contrast */
|
|
36
|
+
@apply outline-2 outline-offset-2 outline-primary dark:outline-primary-dark;
|
|
37
|
+
|
|
38
|
+
/* Override outline color if invalid while focused */
|
|
39
|
+
&:has(input[b-input][data-invalid]) {
|
|
40
|
+
@apply outline-destructive dark:outline-destructive-dark;
|
|
41
|
+
}
|
|
42
|
+
}
|
|
43
|
+
|
|
44
|
+
/* Disabled inner input visual tweak */
|
|
45
|
+
input[b-input]:disabled {
|
|
46
|
+
@apply opacity-60 pointer-events-none;
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
/* Invalid state styles (group reflects error) */
|
|
50
|
+
&:has(input[b-input][data-invalid]) {
|
|
51
|
+
@apply text-destructive placeholder:text-destructive bg-destructive/20 inset-ring-1 inset-ring-destructive/20;
|
|
52
|
+
@apply dark:text-destructive-dark dark:placeholder:text-destructive-dark dark:bg-destructive-dark/20 dark:inset-ring-destructive-dark/20;
|
|
53
|
+
|
|
54
|
+
button[b-button] {
|
|
55
|
+
@apply text-destructive placeholder:text-destructive bg-destructive/20 inset-ring-1 inset-ring-destructive/20;
|
|
56
|
+
@apply dark:text-destructive-dark dark:placeholder:text-destructive-dark dark:bg-destructive-dark/20 dark:inset-ring-destructive-dark/20;
|
|
57
|
+
}
|
|
58
|
+
|
|
59
|
+
/* Icon strokes inside when error */
|
|
60
|
+
i svg {
|
|
61
|
+
stroke: var(--color-destructive-foreground, currentColor);
|
|
62
|
+
}
|
|
63
|
+
}
|
|
64
|
+
|
|
65
|
+
/* Size variants (normalized to Tailwind scale, matching input sizes) */
|
|
66
|
+
&:has(input[b-input].b-size-sm) {
|
|
67
|
+
/* small */
|
|
68
|
+
@apply px-2 py-0 text-xs h-6 rounded-size-sm gap-1;
|
|
69
|
+
}
|
|
70
|
+
|
|
71
|
+
&:has(input[b-input].b-size-md) {
|
|
72
|
+
/* medium */
|
|
73
|
+
@apply px-2.5 py-0 text-sm h-8 rounded-size-md gap-1.5;
|
|
74
|
+
|
|
75
|
+
&:has(> button[b-button]:first-child) {
|
|
76
|
+
@apply pl-1!;
|
|
77
|
+
}
|
|
78
|
+
|
|
79
|
+
&:has(> button[b-button]:last-child) {
|
|
80
|
+
@apply pr-1!;
|
|
81
|
+
}
|
|
82
|
+
}
|
|
83
|
+
|
|
84
|
+
&:has(input[b-input].b-size-lg) {
|
|
85
|
+
/* large */
|
|
86
|
+
@apply px-3 py-0 text-base h-10 rounded-size-lg gap-2;
|
|
87
|
+
|
|
88
|
+
&:has(> button[b-button]:first-child) {
|
|
89
|
+
@apply pl-1!;
|
|
90
|
+
}
|
|
91
|
+
|
|
92
|
+
&:has(> button[b-button]:last-child) {
|
|
93
|
+
@apply pr-1!;
|
|
94
|
+
}
|
|
95
|
+
}
|
|
96
|
+
|
|
97
|
+
/* Prevent icons from shrinking inside the group */
|
|
98
|
+
> ng-icon {
|
|
99
|
+
@apply shrink-0;
|
|
100
|
+
}
|
|
101
|
+
|
|
102
|
+
/* Rounded full - extra horizontal padding */
|
|
103
|
+
&.b-rounded-full {
|
|
104
|
+
@apply px-4;
|
|
105
|
+
|
|
106
|
+
&:has(> button[b-button]:first-child) {
|
|
107
|
+
@apply pl-1!;
|
|
108
|
+
}
|
|
109
|
+
|
|
110
|
+
&:has(> button[b-button]:last-child) {
|
|
111
|
+
@apply pr-1!;
|
|
112
|
+
}
|
|
113
|
+
}
|
|
114
|
+
|
|
115
|
+
&:has(input[b-input].b-size-sm).b-rounded-full {
|
|
116
|
+
@apply px-3;
|
|
117
|
+
|
|
118
|
+
&:has(> button[b-button]:first-child) {
|
|
119
|
+
@apply pl-1!;
|
|
120
|
+
}
|
|
121
|
+
|
|
122
|
+
&:has(> button[b-button]:last-child) {
|
|
123
|
+
@apply pr-1!;
|
|
124
|
+
}
|
|
125
|
+
}
|
|
126
|
+
|
|
127
|
+
&:has(input[b-input].b-size-lg).b-rounded-full {
|
|
128
|
+
@apply px-5;
|
|
129
|
+
|
|
130
|
+
&:has(> button[b-button]:first-child) {
|
|
131
|
+
@apply pl-1!;
|
|
132
|
+
}
|
|
133
|
+
|
|
134
|
+
&:has(> button[b-button]:last-child) {
|
|
135
|
+
@apply pr-1!;
|
|
136
|
+
}
|
|
137
|
+
}
|
|
138
|
+
}
|