@oscarpalmer/oui 0.31.0 → 0.32.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.
@@ -1,11 +1,7 @@
1
1
  /*! https://github.com/oscarpalmer/oui */
2
2
 
3
3
  :where(.oui-pill, .oui-tag) {
4
- --oui-shadow-mixed: color-mix(
5
- in oklab,
6
- var(--oui-shadow, var(--oui-gray-6)),
7
- transparent 92.5%
8
- );
4
+ --oui-shadow-mixed: color-mix(in oklab, var(--oui-shadow, var(--oui-gray-6)), transparent 92.5%);
9
5
  box-shadow: inset 0 1px 0 0 transparent, 0 0 0 1px var(--oui-shadow-mixed), 0 1px 2px -0.5px var(--oui-shadow-mixed), 0 2px 4px -1px var(--oui-shadow-mixed);
10
6
  display: inline-flex;
11
7
  flex-flow: row nowrap;
@@ -23,14 +23,14 @@
23
23
  background-repeat: no-repeat;
24
24
  background-size: 1em;
25
25
  }
26
- :where([oui-combobox-anchor]:not([disabled], [readonly], [aria-disabled=true i]):focus), :where([oui-combobox]:focus-within [oui-combobox-anchor]:not([disabled], [readonly], [aria-disabled=true i])) {
26
+ :where([oui-combobox-anchor]:not([disabled], [readonly], [aria-disabled=true i]):focus), :where([oui-combobox-anchor]:not([disabled], [readonly], [aria-disabled=true i]):has(+ [oui-combobox-content]:focus-within)) {
27
27
  --oui-border-value: var(--oui-blue-5);
28
28
  --oui-foreground-value: inherit;
29
29
  --oui-outline-percentage: 75%;
30
30
  --oui-outline-value: var(--oui-blue-6);
31
31
  }
32
32
  @media (hover: hover) {
33
- :where(:not([disabled], [readonly], [aria-disabled=true i]) [oui-combobox-anchor]:hover) {
33
+ :where([oui-combobox-anchor]:not([disabled], [readonly], [aria-disabled=true i]):hover) {
34
34
  --oui-border-value: var(--oui-blue-4);
35
35
  --oui-foreground-percentage: 0%;
36
36
  --oui-foreground-value: inherit;
@@ -38,14 +38,14 @@
38
38
  --oui-outline-value: var(--oui-blue-6);
39
39
  }
40
40
  }
41
- :where(:is([disabled], [readonly], [aria-disabled=true i]) [oui-combobox-anchor]) {
41
+ :where([oui-combobox-anchor]:is([disabled], [readonly], [aria-disabled=true i])) {
42
42
  --oui-foreground-percentage: 25%;
43
43
  font-style: italic;
44
44
  }
45
- :where(:is([disabled], [readonly], [aria-disabled=true i]) [oui-combobox-anchor]:focus) {
45
+ :where([oui-combobox-anchor]:is([disabled], [readonly], [aria-disabled=true i]):focus) {
46
46
  --oui-outline-percentage: 75%;
47
47
  }
48
- :where(:is([disabled], [aria-disabled=true i]) [oui-combobox-anchor]) {
48
+ :where([oui-combobox-anchor]:is([disabled], [aria-disabled=true i])) {
49
49
  --oui-background-percentage: 50%;
50
50
  }
51
51
 
@@ -91,8 +91,97 @@
91
91
  font-style: italic;
92
92
  }
93
93
 
94
+ :where([oui-combobox-filter], [oui-combobox-header])::after {
95
+ content: "";
96
+ width: 100%;
97
+ height: 0.25em;
98
+ background-image: linear-gradient(to bottom, rgba(0, 0, 0, 0.125), transparent);
99
+ position: absolute;
100
+ bottom: -0.25em;
101
+ left: 0;
102
+ }
103
+
104
+ :where([oui-combobox-filter]) {
105
+ padding: 0.75em;
106
+ background-color: var(--oui-yellow-0);
107
+ border-radius: 0.25em 0.25em 0 0;
108
+ position: relative;
109
+ z-index: 1;
110
+ }
111
+
112
+ :where([oui-combobox-filter-input]) {
113
+ --oui-background-percentage: 0%;
114
+ --oui-foreground-percentage: 0%;
115
+ --oui-outline-percentage: 100%;
116
+ --oui-outline-value: var(--oui-blue-6);
117
+ outline: 4px solid color-mix(in oklab, var(--oui-outline-value), transparent var(--oui-outline-percentage));
118
+ outline-offset: 0;
119
+ transition: 0.125s ease-in-out;
120
+ align-content: center;
121
+ background-color: color-mix(in oklab, var(--oui-background-value), transparent var(--oui-background-percentage));
122
+ border: 1px solid var(--oui-border-value, var(--oui-gray-3));
123
+ box-shadow: inset 0 2px 4px -1px var(--oui-gray-3);
124
+ color: color-mix(in oklab, var(--oui-foreground-value, inherit), transparent var(--oui-foreground-percentage));
125
+ -webkit-text-fill-color: color-mix(in oklab, var(--oui-foreground-value, inherit), transparent var(--oui-foreground-percentage));
126
+ --oui-background-value: var(--oui-absolute);
127
+ --oui-border-value: var(--oui-yellow-3);
128
+ width: 100%;
129
+ padding: 0.5em 0.75em;
130
+ outline-width: 0;
131
+ border-radius: 0.25em;
132
+ font-size: 0.875rem;
133
+ }
134
+ :where(:where([oui-combobox-filter-input]):not([disabled], [readonly], [aria-disabled=true i]):focus) {
135
+ --oui-border-value: var(--oui-blue-5);
136
+ --oui-foreground-value: inherit;
137
+ --oui-outline-percentage: 75%;
138
+ --oui-outline-value: var(--oui-blue-6);
139
+ }
140
+ @media (hover: hover) {
141
+ :where(:where([oui-combobox-filter-input]):not([disabled], [readonly], [aria-disabled=true i]):hover) {
142
+ --oui-border-value: var(--oui-blue-4);
143
+ --oui-foreground-percentage: 0%;
144
+ --oui-foreground-value: inherit;
145
+ --oui-outline-percentage: 90%;
146
+ --oui-outline-value: var(--oui-blue-6);
147
+ }
148
+ }
149
+ :where(:where([oui-combobox-filter-input]):is([disabled], [readonly], [aria-disabled=true i])) {
150
+ --oui-foreground-percentage: 25%;
151
+ font-style: italic;
152
+ }
153
+ :where(:where([oui-combobox-filter-input]):is([disabled], [readonly], [aria-disabled=true i]):focus) {
154
+ --oui-outline-percentage: 75%;
155
+ }
156
+ :where(:where([oui-combobox-filter-input]):is([disabled], [aria-disabled=true i])) {
157
+ --oui-background-percentage: 50%;
158
+ }
159
+
160
+ :where([oui-combobox-filter-label]) {
161
+ width: 1px !important;
162
+ height: 1px !important;
163
+ padding: 0 !important;
164
+ clip-path: inset(50%) !important;
165
+ overflow: hidden !important;
166
+ border: 0 !important;
167
+ white-space: nowrap !important;
168
+ display: inline-flex;
169
+ position: absolute;
170
+ }
171
+
172
+ :where([oui-combobox-header]) {
173
+ padding: 0.5em 1em;
174
+ background-color: var(--oui-gray-0);
175
+ font-size: 0.75em;
176
+ font-weight: bold;
177
+ position: sticky;
178
+ top: 0;
179
+ z-index: 1;
180
+ }
181
+
94
182
  :where([oui-combobox-list]) {
95
183
  overflow: auto;
184
+ position: relative;
96
185
  }
97
186
 
98
187
  :where([oui-combobox-option]) {
@@ -136,11 +225,7 @@
136
225
  }
137
226
 
138
227
  :where([oui-combobox-selection-item]) {
139
- --oui-shadow-mixed: color-mix(
140
- in oklab,
141
- var(--oui-shadow, var(--oui-gray-6)),
142
- transparent 92.5%
143
- );
228
+ --oui-shadow-mixed: color-mix(in oklab, var(--oui-shadow, var(--oui-gray-6)), transparent 92.5%);
144
229
  box-shadow: inset 0 1px 0 0 transparent, 0 0 0 1px var(--oui-shadow-mixed), 0 1px 2px -0.5px var(--oui-shadow-mixed), 0 2px 4px -1px var(--oui-shadow-mixed);
145
230
  display: inline-flex;
146
231
  flex-flow: row nowrap;