mirror of
https://github.com/ionic-team/ionic-framework.git
synced 2026-03-13 10:22:08 +08:00
67 lines
1.7 KiB
SCSS
67 lines
1.7 KiB
SCSS
|
|
// Material Design Chip
|
|
// --------------------------------------------------
|
|
|
|
/// @prop - Margin of the chip
|
|
$chip-md-margin: 2px 0 !default;
|
|
|
|
/// @prop - Height of the chip
|
|
$chip-md-height: 32px !default;
|
|
|
|
/// @prop - Border radius of the chip
|
|
$chip-md-border-radius: 16px !default;
|
|
|
|
/// @prop - Font size of the chip
|
|
$chip-md-font-size: 13px !default;
|
|
|
|
/// @prop - Text color of the chip
|
|
$chip-md-text-color: rgba(0, 0, 0, .87) !default;
|
|
|
|
/// @prop - Background color of the chip
|
|
$chip-md-background-color: rgba(0, 0, 0, .12) !default;
|
|
|
|
/// @prop - Margin of the label in the chip
|
|
$chip-md-label-margin: 0 10px !default;
|
|
|
|
/// @prop - Background color of the icon in the chip
|
|
$chip-md-icon-background-color: color($colors-md, primary) !default;
|
|
|
|
/// @prop - Text color of the icon in the chip
|
|
$chip-md-icon-text-color: color-contrast($colors-md, $chip-md-icon-background-color) !default;
|
|
|
|
|
|
.chip-md {
|
|
margin: $chip-md-margin;
|
|
|
|
height: $chip-md-height;
|
|
|
|
border-radius: $chip-md-border-radius;
|
|
font-size: $chip-md-font-size;
|
|
line-height: $chip-md-height;
|
|
color: $chip-md-text-color;
|
|
background: $chip-md-background-color;
|
|
}
|
|
|
|
.chip-md > ion-label {
|
|
margin: $chip-md-label-margin;
|
|
}
|
|
|
|
.chip-md > ion-icon {
|
|
color: $chip-md-icon-text-color;
|
|
background-color: $chip-md-icon-background-color;
|
|
}
|
|
|
|
|
|
// Generate Material Design Chip Colors
|
|
// --------------------------------------------------
|
|
|
|
@each $color-name, $color-base, $color-contrast in get-colors($colors-md) {
|
|
|
|
.chip-md-#{$color-name},
|
|
.chip-md .icon-md-#{$color-name} {
|
|
color: $color-contrast;
|
|
background-color: $color-base;
|
|
}
|
|
|
|
}
|