mirror of
https://github.com/farmOS/farmOS.git
synced 2024-02-23 11:37:38 +01:00
Add styles for default flags.
This commit is contained in:
parent
d127a9400a
commit
7b3de137e2
3 changed files with 49 additions and 0 deletions
38
modules/ui/theme/css/flag.css
Normal file
38
modules/ui/theme/css/flag.css
Normal file
|
@ -0,0 +1,38 @@
|
|||
/**
|
||||
* @file
|
||||
* Styling for farmOS flags.
|
||||
*/
|
||||
|
||||
/*
|
||||
* Default style for flags.
|
||||
*
|
||||
* Based on the Claro + Gin button--small.
|
||||
*/
|
||||
.flag {
|
||||
display: inline-block;
|
||||
margin: 0.25rem 0;
|
||||
padding: .3rem .5rem;
|
||||
text-align: center;
|
||||
text-decoration: none;
|
||||
color: var(--colorGinButtonText);
|
||||
border: 2px solid var(--colorGinPrimary);
|
||||
border-radius: 12px;
|
||||
background-color: var(--colorGinPrimary);
|
||||
font-size: .79rem;
|
||||
font-weight: 700;
|
||||
line-height: 1rem;
|
||||
-webkit-appearance: none;
|
||||
-webkit-font-smoothing: antialiased;
|
||||
}
|
||||
.flag--monitor {
|
||||
background-color: var(--colorGinPrimary);
|
||||
border-color: var(--colorGinPrimary);
|
||||
}
|
||||
.flag--monitor {
|
||||
background-color: var(--colorGinDanger);
|
||||
border-color: var(--colorGinDanger);
|
||||
}
|
||||
.flag--review {
|
||||
background-color: var(--colorGinWarning);
|
||||
border-color: var(--colorGinWarning);
|
||||
}
|
|
@ -6,3 +6,7 @@ footer:
|
|||
css:
|
||||
theme:
|
||||
css/footer.css: {}
|
||||
flag:
|
||||
css:
|
||||
theme:
|
||||
css/flag.css: {}
|
||||
|
|
|
@ -20,3 +20,10 @@ function farm_ui_theme_preprocess_toolbar(&$variables) {
|
|||
function farm_ui_theme_block_view_farm_powered_by_block_alter(array &$build, BlockPluginInterface $block) {
|
||||
$build['#attached']['library'][] = 'farm_ui_theme/footer';
|
||||
}
|
||||
|
||||
/**
|
||||
* Implements hook_preprocess_HOOK().
|
||||
*/
|
||||
function farm_ui_theme_preprocess_field__flag(array &$variables) {
|
||||
$variables['#attached']['library'][] = 'farm_ui_theme/flag';
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue