|
265 | 265 | } |
266 | 266 | } |
267 | 267 |
|
| 268 | +/* Chip */ |
| 269 | + |
| 270 | +.mistica-chip { |
| 271 | + font-weight: var(--mistica-font-weight-indicator); |
| 272 | + font-size: var(--mistica-font-size-2); |
| 273 | + line-height: var(--mistica-line-height-2); |
| 274 | + color: var(--mistica-color-textPrimary); |
| 275 | + border: 1px solid var(--mistica-color-control); |
| 276 | + border-radius: var(--mistica-border-radius-indicator); |
| 277 | + background: var(--mistica-color-backgroundContainer); |
| 278 | + position: relative; |
| 279 | + overflow: hidden; |
| 280 | + min-width: 72px; |
| 281 | + min-height: 40px; |
| 282 | + padding: 0 20px; |
| 283 | + display: inline-flex; |
| 284 | + align-items: center; |
| 285 | + justify-content: center; |
| 286 | + text-decoration: none; |
| 287 | +} |
| 288 | +label.mistica-chip { |
| 289 | + padding: 0; |
| 290 | + border: none; |
| 291 | + overflow: visible; |
| 292 | + background: transparent; |
| 293 | +} |
| 294 | +label.mistica-chip > span { |
| 295 | + border: 1px solid var(--mistica-color-control); |
| 296 | + border-radius: var(--mistica-border-radius-indicator); |
| 297 | + background: var(--mistica-color-backgroundContainer); |
| 298 | + position: relative; |
| 299 | + overflow: hidden; |
| 300 | + min-width: 72px; |
| 301 | + min-height: 40px; |
| 302 | + padding: 0 20px; |
| 303 | + display: flex; |
| 304 | + align-items: center; |
| 305 | +} |
| 306 | + |
| 307 | +@media (min-width: 1024px) { |
| 308 | + .mistica-chip, |
| 309 | + label.mistica-chip > span { |
| 310 | + min-width: 56px; |
| 311 | + min-height: 32px; |
| 312 | + padding: 0 12px; |
| 313 | + } |
| 314 | +} |
| 315 | + |
| 316 | +button.mistica-chip, |
| 317 | +a.mistica-chip, |
| 318 | +label.mistica-chip { |
| 319 | + cursor: pointer; |
| 320 | + user-select: none; |
| 321 | +} |
| 322 | + |
| 323 | +button.mistica-chip:before, |
| 324 | +a.mistica-chip:before, |
| 325 | +label.mistica-chip > span:before { |
| 326 | + position: absolute; |
| 327 | + content: ''; |
| 328 | + top: 0; |
| 329 | + left: 0; |
| 330 | + width: 100%; |
| 331 | + height: 100%; |
| 332 | + background: transparent; |
| 333 | + transition: background-color 0.1s ease-in-out; |
| 334 | +} |
| 335 | + |
| 336 | +button.mistica-chip:hover:before, |
| 337 | +a.mistica-chip:hover:before, |
| 338 | +label.mistica-chip > input:hover + span:before { |
| 339 | + background: var(--mistica-color-backgroundContainerHover); |
| 340 | +} |
| 341 | + |
| 342 | +button.mistica-chip:active:before, |
| 343 | +a.mistica-chip:active:before, |
| 344 | +label.mistica-chip > input:active + span:before { |
| 345 | + background: var(--mistica-color-backgroundContainerPressed); |
| 346 | +} |
| 347 | + |
| 348 | +label.mistica-chip > input { |
| 349 | + appearance: none; |
| 350 | + position: absolute; |
| 351 | + top: 0; |
| 352 | + left: 0; |
| 353 | + width: 100%; |
| 354 | + height: 100%; |
| 355 | + margin: 0; |
| 356 | + padding: 0; |
| 357 | + border-radius: var(--mistica-border-radius-indicator); |
| 358 | + outline-offset: 0; |
| 359 | +} |
| 360 | + |
| 361 | +label.mistica-chip > input:checked + span { |
| 362 | + color: var(--mistica-color-textActivated); |
| 363 | + background: var(--mistica-color-brandLow); |
| 364 | + border-color: var(--mistica-color-controlActivated); |
| 365 | +} |
| 366 | + |
| 367 | +.mistica-chip > button { |
| 368 | + display: flex; |
| 369 | + align-items: center; |
| 370 | + justify-content: center; |
| 371 | + background: transparent; |
| 372 | + border: none; |
| 373 | + color: inherit; |
| 374 | + font: inherit; |
| 375 | + cursor: pointer; |
| 376 | + padding: 0; |
| 377 | + margin: 0; |
| 378 | + min-width: 24px; |
| 379 | + min-height: 24px; |
| 380 | + margin-left: 4px; |
| 381 | + margin-right: -4px; |
| 382 | +} |
| 383 | + |
| 384 | +.mistica-chip > button > svg { |
| 385 | + width: 1rem; |
| 386 | + height: 1rem; |
| 387 | +} |
| 388 | + |
268 | 389 | /* Tag */ |
269 | 390 | [class^='mistica-tag'] { |
270 | 391 | font-weight: var(--mistica-font-weight-indicator); |
|
0 commit comments