google-labs-jules[bot] d0c617fdd7 chore: migrate button component to components/button
Moves the `button` component to `components/button` and creates re-exports in the original `button` directory for backward compatibility.
This change also updates internal imports and includes copyright headers in the re-export files.
2025-12-09 19:25:30 +00:00

38 lines
827 B
SCSS

//
// Copyright 2021 Google LLC
// SPDX-License-Identifier: Apache-2.0
//
// go/keep-sorted start
@use 'sass:list';
@use 'sass:map';
// go/keep-sorted end
// go/keep-sorted start
@use '../../../tokens';
// go/keep-sorted end
@mixin theme($tokens) {
$supported-tokens: tokens.$md-comp-filled-tonal-button-supported-tokens;
@each $token, $value in $tokens {
@if list.index($supported-tokens, $token) == null {
@error 'Token `#{$token}` is not a supported token.';
}
@if $value {
--md-filled-tonal-button-#{$token}: #{$value};
}
}
}
@mixin styles() {
$tokens: tokens.md-comp-filled-tonal-button-values();
:host {
// Only use the logical properties.
$tokens: map.remove($tokens, 'container-shape');
@each $token, $value in $tokens {
--_#{$token}: #{$value};
}
}
}