Skip to content
Snippets Groups Projects
Commit 793d5a00 authored by Martin Leblanc's avatar Martin Leblanc
Browse files

ISTWCMS-5732: css for new filter look, includes new buttons styles

parent a1eb5a0c
No related branches found
No related tags found
1 merge request!40Feature/istwcms 5732 m26lebla update filter look
Showing
with 79 additions and 212 deletions
......@@ -144,3 +144,37 @@ $button-font-size: var(--font-size-1) !default;
pointer-events: none;
}
}
%button--standard {
border: 1px solid var(--uw-black) !important;
background: var(--uw-white) !important;
color: var(--uw-black) !important;
padding: var(--size-1) var(--size-2);
width:auto;
&:hover,
&:focus {
border: 1px solid transparent !important;
background: var(--gray-2) !important;
color: var(--uw-black) !important;
}
&:active{
border: 1px solid var(--uw-black) !important;
}
}
%button--highlight {
border: 1px solid var(--uw-black) !important;
color: var(--uw-white) !important;
background: var(--uw-black) !important;
padding: var(--size-1) var(--size-2);
width:auto;
&:hover,
&:focus {
border: 1px solid transparent !important;
background: var(--gray-2) !important;
color: var(--uw-black) !important;
}
&:active{
border: 1px solid var(--uw-black) !important;
}
}
......@@ -6,6 +6,45 @@
.button,
button{
@include button();
// This custom button class, included as an example, is not output by Drupal by default.
&.button--medium {
font-size: var(--font-size-000);
padding: var(--size-105);
&:hover,
&:focus {
padding: var(--size-105);
}
}
&.button--small {
font-size: var(--font-size-0000);
padding: var(--size-1);
&:hover,
&:focus {
padding: var(--size-1);
}
}
&.button--unstyled {
background-color: transparent !important;
color: inherit;
padding: 0 !important;
text-decoration: underline;
}
}
// Drupal outputs this class on buttons that can delete content.
.button--cancel,
.button[data-drupal-selector="edit-cancel"]{
background-color: var(--orange-5);
color: var(--uw-white);
&:hover,
&:focus {
background-color: var(--orange-9);
color: var(--uw-white);
}
}
.button[data-drupal-selector="edit-cancel"]{
line-height: 2.125;
}
// Drupal outputs this class on buttons that can delete content.
......@@ -25,26 +64,6 @@ button{
}
}
// This custom button class, included as an example, is not output by Drupal by default.
.button--medium {
font-size: var(--font-size-000);
padding: var(--size-105);
&:hover,
&:focus {
padding: var(--size-105);
}
}
// This custom button class, included as an example, is not output by Drupal by default.
.button--small {
font-size: var(--font-size-0000);
padding: var(--size-1);
&:hover,
&:focus {
padding: var(--size-1);
}
}
// Drupal outputs this class on buttons that can delete content.
.button--primary {
background-color: var(--green-8);
......@@ -67,20 +86,10 @@ button{
}
}
// Drupal outputs this class on buttons that can delete content.
.button--cancel,
.button[data-drupal-selector="edit-cancel"]{
background-color: var(--orange-5);
color: var(--uw-white);
&:hover,
&:focus {
background-color: var(--orange-9);
color: var(--uw-white);
}
}
.button[data-drupal-selector="edit-cancel"]{
line-height: 2.125;
}
// Css within pattern lab.
.pattern-lab-content .mobile-menu-button,
.pl-c-pattern__extra-toggle{
......
---
el: .button--cancel
title: Cancel Button
---
__Variables:__
* is_button_tag: [boolean] Whether to output as a button element.
* is_demo: [boolean] Whether to show extra demo examples.
* is_disabled: [boolean] Whether this button is disabled. Not used for links.
* modifier_classes: [string] Classes to modify the default component styling.
* url: [string] URL of the button.
* text: [string] Text of the button.
{% set button_modifier_classes -%}
button--cancel {{ modifier_classes }}
{%- endset %}
{% include '@components/button/button.twig' with {
'url': url,
'text': text,
'modifier_classes': button_modifier_classes,
} %}
---
el: .button--danger
title: Danger Button
---
__Variables:__
* is_button_tag: [boolean] Whether to output as a button element.
* is_demo: [boolean] Whether to show extra demo examples.
* is_disabled: [boolean] Whether this button is disabled. Not used for links.
* modifier_classes: [string] Classes to modify the default component styling.
* url: [string] URL of the button.
* text: [string] Text of the button.
{% set button_modifier_classes -%}
button--danger {{ modifier_classes }}
{%- endset %}
{% include '@components/button/button.twig' with {
'url': url,
'text': text,
'modifier_classes': button_modifier_classes,
} %}
---
el: .button--large
title: Large Button
---
__Variables:__
* is_button_tag: [boolean] Whether to output as a button element.
* is_demo: [boolean] Whether to show extra demo examples.
* is_disabled: [boolean] Whether this button is disabled. Not used for links.
* modifier_classes: [string] Classes to modify the default component styling.
* url: [string] URL of the button.
* text: [string] Text of the button.
{% set button_modifier_classes -%}
button--large {{ modifier_classes }}
{%- endset %}
{% include '@components/button/button.twig' with {
'url': url,
'text': text,
'modifier_classes': button_modifier_classes,
} %}
---
el: .button--medium
title: Medium Button
---
__Variables:__
* is_button_tag: [boolean] Whether to output as a button element.
* is_demo: [boolean] Whether to show extra demo examples.
* is_disabled: [boolean] Whether this button is disabled. Not used for links.
* modifier_classes: [string] Classes to modify the default component styling.
* url: [string] URL of the button.
* text: [string] Text of the button.
{% set button_modifier_classes -%}
button--medium {{ modifier_classes }}
{%- endset %}
{% include '@components/button/button.twig' with {
'url': url,
'text': text,
'modifier_classes': button_modifier_classes,
} %}
---
el: .button--primary
title: Primary Button (save)
---
__Variables:__
* is_button_tag: [boolean] Whether to output as a button element.
* is_demo: [boolean] Whether to show extra demo examples.
* is_disabled: [boolean] Whether this button is disabled. Not used for links.
* modifier_classes: [string] Classes to modify the default component styling.
* url: [string] URL of the button.
* text: [string] Text of the button.
{% set button_modifier_classes -%}
button--primary {{ modifier_classes }}
{%- endset %}
{% include '@components/button/button.twig' with {
'url': url,
'text': text,
'modifier_classes': button_modifier_classes,
} %}
---
is_button_tag: true
is_demo: true
url: '#'
text: 'Save'
text_demo: 'Save Button'
---
el: .button--secondary
title: Secondary Button
---
__Variables:__
* is_button_tag: [boolean] Whether to output as a button element.
* is_demo: [boolean] Whether to show extra demo examples.
* is_disabled: [boolean] Whether this button is disabled. Not used for links.
* modifier_classes: [string] Classes to modify the default component styling.
* url: [string] URL of the button.
* text: [string] Text of the button.
{% set button_modifier_classes -%}
button--secondary {{ modifier_classes }}
{%- endset %}
{% include '@components/button/button.twig' with {
'url': url,
'text': text,
'modifier_classes': button_modifier_classes,
} %}
\ No newline at end of file
---
is_button_tag: true
is_demo: true
url: '#'
text: 'Revert'
text_demo: 'Revert Button'
---
el: .button--small
title: Small Button
---
__Variables:__
* is_button_tag: [boolean] Whether to output as a button element.
* is_demo: [boolean] Whether to show extra demo examples.
* is_disabled: [boolean] Whether this button is disabled. Not used for links.
* modifier_classes: [string] Classes to modify the default component styling.
* url: [string] URL of the button.
* text: [string] Text of the button.
{% set button_modifier_classes -%}
button--small {{ modifier_classes }}
{%- endset %}
{% include '@components/button/button.twig' with {
'url': url,
'text': text,
'modifier_classes': button_modifier_classes,
} %}
---
is_button_tag: true
is_demo: true
url: '#'
text: 'Button'
text_demo: 'Link Button'
---
modifier_classes: ''
is_button_tag: true
is_demo: true
is_disabled: false
autofocus: false
formaction: 'form_action'
form: 'form_id'
formmethod: ''
formtarget: 'form_target'
name: ''
formenctype: ''
value: ''
url: '#'
text: 'Button'
text_demo: 'Link Button'
type: ''
modifier_classes: ''
btnclick : |
alert('Hello World!');
text_demo: 'Button'
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment