@wwtdev/bsds-css 2.0.9 → 2.1.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/dist/components/_accordions.scss +1 -1
- package/dist/components/_badge.scss +43 -16
- package/dist/components/_buttons.scss +4 -10
- package/dist/components/_circle-buttons.scss +5 -3
- package/dist/components/_filter-buttons.scss +101 -0
- package/dist/components/_form-input-composite.scss +13 -7
- package/dist/components/_form-input-search.scss +35 -5
- package/dist/components/_form-text-fields.scss +20 -9
- package/dist/components/accordions.css +1 -1
- package/dist/components/badge.css +43 -16
- package/dist/components/buttons.css +4 -10
- package/dist/components/circle-buttons.css +5 -3
- package/dist/components/filter-buttons.css +97 -0
- package/dist/components/form-input-composite.css +13 -7
- package/dist/components/form-input-search.css +35 -5
- package/dist/components/form-text-fields.css +20 -9
- package/dist/wwt-bsds-wc-base.css +9 -0
- package/dist/wwt-bsds.css +202 -50
- package/dist/wwt-bsds.min.css +1 -1
- package/package.json +1 -1
|
@@ -0,0 +1,97 @@
|
|
|
1
|
+
/*
|
|
2
|
+
custom properties:
|
|
3
|
+
--filterbtn-caret-size
|
|
4
|
+
--filterbtn-caret-transform
|
|
5
|
+
--filterbtn-color
|
|
6
|
+
--filterbtn-focus-color
|
|
7
|
+
--filterbtn-height
|
|
8
|
+
--filterbtn-text-size
|
|
9
|
+
--filterbtn-weight
|
|
10
|
+
*/
|
|
11
|
+
|
|
12
|
+
button:where(.bs-filter-button) {
|
|
13
|
+
flex-shrink: 0;
|
|
14
|
+
}
|
|
15
|
+
|
|
16
|
+
.bs-filter-button {
|
|
17
|
+
align-items: center;
|
|
18
|
+
border-radius: 0.25rem;
|
|
19
|
+
color: var(--filterbtn-color, var(--bs-ink-blue));
|
|
20
|
+
column-gap: 0.5rem;
|
|
21
|
+
cursor: pointer;
|
|
22
|
+
display: inline-flex;
|
|
23
|
+
font-size: var(--filterbtn-text-size, var(--bs-text-base));
|
|
24
|
+
font-weight: var(--filterbtn-weight, 400);
|
|
25
|
+
height: var(--filterbtn-height, 2rem);
|
|
26
|
+
line-height: 1.5;
|
|
27
|
+
outline: solid var(--filterbtn-focus-color, transparent) .125rem;
|
|
28
|
+
outline-offset: -.125rem;
|
|
29
|
+
padding-inline: .5rem;
|
|
30
|
+
transition: outline-color 100ms ease-in-out;
|
|
31
|
+
width: max-content;
|
|
32
|
+
}
|
|
33
|
+
|
|
34
|
+
.bs-filter-button :where(.bs-icon),
|
|
35
|
+
.bs-filter-button :where(span:has(svg:only-child)) {
|
|
36
|
+
display: block;
|
|
37
|
+
height: var(--filterbtn-caret-size, 1rem);
|
|
38
|
+
line-height: 1;
|
|
39
|
+
transform: var(--filterbtn-caret-transform, rotate(0deg));
|
|
40
|
+
transform-origin: center;
|
|
41
|
+
transition: var(--bs-trans-rotate180);
|
|
42
|
+
width: var(--filterbtn-caret-size, 1rem);
|
|
43
|
+
}
|
|
44
|
+
|
|
45
|
+
.bs-filter-button:where([data-size="sm"],[data-size="xs"]) {
|
|
46
|
+
--filterbtn-height: 1.75rem;
|
|
47
|
+
--filterbtn-text-size: var(--bs-text-sm);
|
|
48
|
+
--filterbtn-caret-size: .75rem;
|
|
49
|
+
}
|
|
50
|
+
|
|
51
|
+
.bs-filter-button:where([data-size="sm"]) {
|
|
52
|
+
--filterbtn-text-size: var(--bs-text-sm);
|
|
53
|
+
}
|
|
54
|
+
|
|
55
|
+
.bs-filter-button:where([data-size="xs"]) {
|
|
56
|
+
--filterbtn-text-size: var(--bs-text-xs);
|
|
57
|
+
--filterbtn-weight: 600;
|
|
58
|
+
}
|
|
59
|
+
|
|
60
|
+
/* Hover state */
|
|
61
|
+
.bs-filter-button:hover {
|
|
62
|
+
--filterbtn-color: var(--bs-blue-base);
|
|
63
|
+
}
|
|
64
|
+
|
|
65
|
+
/* Focus state */
|
|
66
|
+
.bs-filter-button:where(:focus-visible) {
|
|
67
|
+
--filterbtn-focus-color: var(--bs-blue-base);
|
|
68
|
+
}
|
|
69
|
+
|
|
70
|
+
/* Filter open state */
|
|
71
|
+
.bs-filter-button:where([aria-expanded="true"],[data-open="true"]) {
|
|
72
|
+
--filterbtn-caret-transform: rotate(180deg);
|
|
73
|
+
}
|
|
74
|
+
|
|
75
|
+
/* Badge non-standard color */
|
|
76
|
+
.bs-filter-button :where(.bs-badge) {
|
|
77
|
+
--badge-bg: var(--bs-ink-blue);
|
|
78
|
+
}
|
|
79
|
+
|
|
80
|
+
:where(.dark) .bs-filter-button :where(.bs-badge) {
|
|
81
|
+
--badge-bg: var(--bs-blue-medium);
|
|
82
|
+
}
|
|
83
|
+
|
|
84
|
+
.bs-filter-button:hover :where(.bs-badge) {
|
|
85
|
+
--badge-bg: var(--filterbtn-color);
|
|
86
|
+
}
|
|
87
|
+
|
|
88
|
+
/* Disabled state */
|
|
89
|
+
.bs-filter-button:where(:disabled) {
|
|
90
|
+
--filterbtn-color: var(--bs-ink-disabled);
|
|
91
|
+
cursor: default;
|
|
92
|
+
}
|
|
93
|
+
|
|
94
|
+
.bs-filter-button:where(:disabled) :where(.bs-badge) {
|
|
95
|
+
--badge-bg: var(--bs-bg-disabled);
|
|
96
|
+
--badge-text: var(--bs-ink-disabled);
|
|
97
|
+
}
|
|
@@ -10,7 +10,7 @@
|
|
|
10
10
|
border-radius: .25rem;
|
|
11
11
|
color: var(--bs-ink-base);
|
|
12
12
|
display: flex;
|
|
13
|
-
height: 2.5rem;
|
|
13
|
+
height: var(--input-addon-height, 2.5rem);
|
|
14
14
|
overflow: hidden;
|
|
15
15
|
padding: 0;
|
|
16
16
|
pointer-events: none;
|
|
@@ -52,7 +52,7 @@ and issues with box-sizing
|
|
|
52
52
|
flex-shrink: 0;
|
|
53
53
|
position: relative;
|
|
54
54
|
}
|
|
55
|
-
.bs-input-addon > :where([data-autowidth]:not([data-autowidth="false"]), .bs-input-addon, bs-input) {
|
|
55
|
+
.bs-input-addon > :where([data-autowidth]:not([data-autowidth="false"]), .bs-input-addon, bs-input, .bs-input) {
|
|
56
56
|
flex-grow: 1;
|
|
57
57
|
flex-shrink: 1;
|
|
58
58
|
}
|
|
@@ -73,6 +73,7 @@ and issues with box-sizing
|
|
|
73
73
|
.bs-input-addon > *,
|
|
74
74
|
.bs-input-addon :where(input, select),
|
|
75
75
|
.bs-input-addon :is(bs-input, bs-select) :where(input, select),
|
|
76
|
+
.bs-input-addon :is(input, select):where(.bs-input, .bs-select),
|
|
76
77
|
.bs-input-addon :where(.bs-input-addon) {
|
|
77
78
|
--input-border: transparent;
|
|
78
79
|
--input-border-width: 0px;
|
|
@@ -82,9 +83,11 @@ and issues with box-sizing
|
|
|
82
83
|
--input-addon-nested-border: transparent;
|
|
83
84
|
}
|
|
84
85
|
|
|
85
|
-
.bs-input-addon :where(:focus-within) :where(input, select),
|
|
86
|
+
.bs-input-addon :where(:focus-within) :where(input, select, button),
|
|
86
87
|
.bs-input-addon :where(:focus-within) :is(bs-input, bs-select) :where(input, select),
|
|
87
|
-
.bs-input-addon :where(input, select):where(
|
|
88
|
+
.bs-input-addon :where(:focus-within) :is(input, select, button):where(.bs-input, .bs-select),
|
|
89
|
+
.bs-input-addon :where(input, select, button):where(:focus, :focus-within, :focus-visible),
|
|
90
|
+
.bs-input-addon :is(input, select):where(.bs-input, .bs-select):where(:focus, :focus-within, :focus-visible),
|
|
88
91
|
.bs-input-addon :is(bs-input, bs-select) :where(input, select):where(:focus, :focus-within, :focus-visible) {
|
|
89
92
|
--input-border: transparent;
|
|
90
93
|
box-shadow: none;
|
|
@@ -138,6 +141,7 @@ and issues with box-sizing
|
|
|
138
141
|
.bs-input-addon:where(:not([data-multifocus]):focus-within),
|
|
139
142
|
.bs-input-addon:where([data-multifocus="false"]:focus-within),
|
|
140
143
|
.bs-input-addon:where([data-multifocus]:not([data-multifocus="false"])) :where(input, select):where(:focus, :focus-within, :focus-visible),
|
|
144
|
+
.bs-input-addon:where([data-multifocus]:not([data-multifocus="false"])) :is(input, select):where(.bs-input, .bs-select):where(:focus, :focus-within, :focus-visible),
|
|
141
145
|
.bs-input-addon:where([data-multifocus]:not([data-multifocus="false"])) :is(bs-input, bs-select) :where(input, select):where(:focus, :focus-within, :focus-visible) {
|
|
142
146
|
--input-border: var(--focus-border);
|
|
143
147
|
position: relative;
|
|
@@ -153,11 +157,13 @@ and issues with box-sizing
|
|
|
153
157
|
z-index: 1;
|
|
154
158
|
}
|
|
155
159
|
|
|
156
|
-
.bs-input-addon:where([data-multifocus]:not([data-multifocus="false"])) > :where(:not(.bs-input-addon)) > :where(input:focus, select:focus),
|
|
160
|
+
.bs-input-addon:where([data-multifocus]:not([data-multifocus="false"])) > :where(:not(.bs-input-addon)) > :where(input:focus, select:focus, button:focus),
|
|
161
|
+
.bs-input-addon:where([data-multifocus]:not([data-multifocus="false"])) > :is(input, select):where(.bs-input, .bs-select):where(:focus),
|
|
157
162
|
.bs-input-addon:where([data-multifocus]:not([data-multifocus="false"])) > :is(bs-input, bs-select) :where(input:focus, select:focus),
|
|
158
|
-
.bs-input-addon:where([data-multifocus]:not([data-multifocus="false"])) > :where(input:focus, select:focus) {
|
|
163
|
+
.bs-input-addon:where([data-multifocus]:not([data-multifocus="false"])) > :where(input:focus, select:focus, button:focus) {
|
|
159
164
|
border-radius: .25rem;
|
|
160
165
|
box-shadow: var(--focus-border) 0px 0px 0px 1px inset;
|
|
166
|
+
z-index: 1;
|
|
161
167
|
}
|
|
162
168
|
|
|
163
169
|
.bs-input-addon:where(:not([data-multifocus]):focus-within)::after,
|
|
@@ -182,7 +188,7 @@ and issues with box-sizing
|
|
|
182
188
|
|
|
183
189
|
/* -------- Disabled styles -------- */
|
|
184
190
|
.bs-input-addon:where([data-disabled]:not([data-disabled="false"])),
|
|
185
|
-
.bs-input-addon:where([data-disabled]:not([data-disabled="false"]))
|
|
191
|
+
.bs-input-addon:where([data-disabled]:not([data-disabled="false"])) .bs-button {
|
|
186
192
|
--input-bg: var(--bs-gray-200);
|
|
187
193
|
--input-border: var(--bs-gray-400);
|
|
188
194
|
color: var(--bs-gray-400);
|
|
@@ -7,12 +7,13 @@
|
|
|
7
7
|
box-sizing: content-box;
|
|
8
8
|
}
|
|
9
9
|
|
|
10
|
-
.bs-input-search
|
|
11
|
-
--icon-size: 1.75rem;
|
|
12
|
-
padding
|
|
10
|
+
.bs-input-search :where([data-component="bs-icon-search"]) {
|
|
11
|
+
--icon-size: var(--search-icon-size, 1.75rem);
|
|
12
|
+
padding: var(--search-icon-padding, 0 0 0 .75rem);
|
|
13
13
|
}
|
|
14
14
|
|
|
15
|
-
|
|
15
|
+
/* Clear Button */
|
|
16
|
+
.bs-input-search button {
|
|
16
17
|
align-items: center;
|
|
17
18
|
background-color: transparent;
|
|
18
19
|
cursor: pointer;
|
|
@@ -23,8 +24,37 @@
|
|
|
23
24
|
transition: transform 100ms ease-in-out;
|
|
24
25
|
}
|
|
25
26
|
|
|
26
|
-
.bs-input-search
|
|
27
|
+
.bs-input-search button:where(:active) {
|
|
27
28
|
transform: scale(0.97);
|
|
28
29
|
transform-origin: center;
|
|
29
30
|
box-shadow: inset 0px 0px 4px 1px var(--bs-blue-base);
|
|
30
31
|
}
|
|
32
|
+
|
|
33
|
+
.bs-input-search button:where(:focus) {
|
|
34
|
+
border-radius: .25rem;
|
|
35
|
+
box-shadow: var(--focus-border) 0px 0px 0px 1px inset;
|
|
36
|
+
z-index: 1;
|
|
37
|
+
}
|
|
38
|
+
|
|
39
|
+
|
|
40
|
+
/* Filter variant */
|
|
41
|
+
|
|
42
|
+
.bs-input-search:where([data-variant="filter"]) {
|
|
43
|
+
--focus-border: transparent;
|
|
44
|
+
--input-border: transparent;
|
|
45
|
+
--input-addon-height: 1.5rem;
|
|
46
|
+
--input-caret: var(--bs-blue-base);
|
|
47
|
+
--input-padding-block: 0 0.125rem;
|
|
48
|
+
--input-padding-inline: 0.5rem;
|
|
49
|
+
--input-placeholder: var(--bs-ink-light);
|
|
50
|
+
--input-text-size: var(--bs-text-sm);
|
|
51
|
+
--search-icon-size: 1rem;
|
|
52
|
+
--search-icon-padding: 0;
|
|
53
|
+
}
|
|
54
|
+
|
|
55
|
+
/* -------- Disabled styles -------- */
|
|
56
|
+
.bs-input-addon:where([data-variant="filter"][data-disabled="true"]),
|
|
57
|
+
.bs-input-addon:where([data-variant="filter"][data-disabled="true"]) :is(.bs-button, .bs-input) {
|
|
58
|
+
--input-bg: var(--bs-bg-base);
|
|
59
|
+
--input-border: transparent;
|
|
60
|
+
}
|
|
@@ -4,26 +4,36 @@
|
|
|
4
4
|
margin-top: 0.25rem;
|
|
5
5
|
}
|
|
6
6
|
|
|
7
|
+
/*
|
|
8
|
+
Custom properties:
|
|
9
|
+
--input-bg (background color)
|
|
10
|
+
--input-border (border color)
|
|
11
|
+
--input-border-width (border width)
|
|
12
|
+
--input-caret (caret color)
|
|
13
|
+
--input-padding-block (padding block)
|
|
14
|
+
--input-padding-inline (padding inline)
|
|
15
|
+
--input-placeholder (placeholder color)
|
|
16
|
+
--input-text-size (font size)
|
|
17
|
+
*/
|
|
18
|
+
|
|
7
19
|
input:where(:not([type='checkbox'], [type='radio'], [type='file'], [type='range'])),
|
|
8
20
|
textarea,
|
|
9
21
|
select,
|
|
10
22
|
:is(.bs-input, .bs-select, .bs-textarea) {
|
|
11
|
-
--input-bg: var(--bs-bg-base);
|
|
12
|
-
--input-border: var(--bs-violet-medium);
|
|
13
23
|
appearance: none;
|
|
14
|
-
background-color: var(--input-bg);
|
|
15
|
-
border-color: var(--input-border);
|
|
24
|
+
background-color: var(--input-bg, var(--bs-bg-base));
|
|
25
|
+
border-color: var(--input-border, var(--bs-violet-medium));
|
|
16
26
|
border-radius: 0.25rem;
|
|
17
27
|
border-style: solid;
|
|
18
28
|
border-width: var(--input-border-width, 1px);
|
|
19
|
-
caret-color: var(--bs-blue-base);
|
|
29
|
+
caret-color: var(--input-caret, var(--bs-blue-base));
|
|
20
30
|
color: var(--bs-ink-base);
|
|
21
|
-
font-size: var(--bs-text-base);
|
|
31
|
+
font-size: var(--input-text-size, var(--bs-text-base));
|
|
22
32
|
font-weight: 400;
|
|
23
33
|
height: 2.5rem;
|
|
24
34
|
line-height: var(--bs-leading-base);
|
|
25
|
-
|
|
26
|
-
padding-inline: 0.75rem;
|
|
35
|
+
padding-block: var(--input-padding-block, 0.0625rem);
|
|
36
|
+
padding-inline: var(--input-padding-inline, 0.75rem);
|
|
27
37
|
}
|
|
28
38
|
|
|
29
39
|
input:where(:not([type='checkbox'], [type='radio'], [type='file'], [type='range'])),
|
|
@@ -48,7 +58,7 @@ textarea {
|
|
|
48
58
|
|
|
49
59
|
:is(input, textarea, select)::placeholder,
|
|
50
60
|
:is(.bs-input, .bs-select, .bs-textarea)::placeholder {
|
|
51
|
-
color: var(--bs-violet-lightest);
|
|
61
|
+
color: var(--input-placeholder, var(--bs-violet-lightest));
|
|
52
62
|
}
|
|
53
63
|
:is(input, textarea, select):where(:focus-visible)::placeholder,
|
|
54
64
|
:is(.bs-input, .bs-select, .bs-textarea):where(:focus-visible)::placeholder {
|
|
@@ -58,6 +68,7 @@ textarea {
|
|
|
58
68
|
:is(input:where(:not([type='checkbox'], [type='radio'])), textarea, select):where(:focus-visible),
|
|
59
69
|
:is(.bs-input, .bs-select, .bs-textarea):where(:focus-visible) {
|
|
60
70
|
--input-border: var(--bs-blue-base);
|
|
71
|
+
outline-style: none;
|
|
61
72
|
outline-width: 0px;
|
|
62
73
|
}
|
|
63
74
|
|
|
@@ -811,6 +811,15 @@ a:where(.bs-link):where(:focus:not(:focus-visible)) {
|
|
|
811
811
|
box-shadow: var(--bs-shadow-profilePhoto);
|
|
812
812
|
}
|
|
813
813
|
|
|
814
|
+
:root {
|
|
815
|
+
/* get design sign off on these first
|
|
816
|
+
--bs-trans-color: color 100ms ease-in-out;
|
|
817
|
+
--bs-trans-outline-color: outline-color 100ms ease-in-out;
|
|
818
|
+
*/
|
|
819
|
+
|
|
820
|
+
--bs-trans-rotate180: transform 200ms ease-in-out;
|
|
821
|
+
}
|
|
822
|
+
|
|
814
823
|
/* Specificity should be either (0, 1, 0) (class-based) or (0, 0, 1) (element-based) for each selector */
|
|
815
824
|
|
|
816
825
|
.box {
|