2022-02-21 12:22:59 +00:00
|
|
|
---
|
|
|
|
type: css
|
|
|
|
---
|
|
|
|
# Panel
|
|
|
|
|
|
|
|
Very basic 'panel' card-like CSS component currently used for menu-panels.
|
|
|
|
|
|
|
|
When building components using `panel` please make use of the CSS custom
|
|
|
|
properties available to help maintain consistency within the panel.
|
|
|
|
|
|
|
|
**Very important**: Please avoid using style attributes for doing this the
|
|
|
|
below is only for illustrative purposes. Please use this CSS component as a
|
|
|
|
building block for other CSS instead.
|
|
|
|
|
|
|
|
```hbs preview-template
|
|
|
|
<figure>
|
|
|
|
<figcaption>Panel with no padding (in dark mode)</figcaption>
|
UI: Update Consul UI colors to use HDS colors (#16111)
* update red color variables to hds
* change background red to be one step lighter
* map oranges
* map greens
* map blues
* map greys
* delete themes, colours: lemon, magenta, strawberry, and vault color aliases
* add unmapped rainbow colours
* replace white and transparent vars, remove unused semantic vars and frame placeholders
* small tweaks to improve contrast, change node health status x/check colours for non-voters to match design doc, replace semantic colour action w hds colour
* add unmapped grays, remove dark theme, manually set nav bar to use dark colours
* map consul pink colour
* map yellows
* add unmapped oranges, delete light theme
* remove readme, base variables, clean up dangling colours
* Start working on the nav disclosure menus
* Update main-nav-horizontal dropdowns
* Format template
* Update box-shadow tokens
* Replace --tone- usage with tokens
* Update nav disabled state and panel border colour
* Replace rgb usage on tile
* Fix permissions modal overlay
* More fixes
* Replace orange-500 with amber-200
* Update badge colors
* Update vertical sidebar colors
* Remove top border on consul peer list ul
---------
Co-authored-by: wenincode <tyler.wendlandt@hashicorp.com>
2023-02-27 16:30:12 +00:00
|
|
|
<div class={{class-map 'panel' 'theme-dark'}} ...attributes>
|
2022-02-21 12:22:59 +00:00
|
|
|
<div>
|
|
|
|
<p>Some text purposefully with no padding</p>
|
|
|
|
</div>
|
|
|
|
<hr />
|
|
|
|
<div>
|
|
|
|
<p>Along with a separator ^ again purposefully with no padding</p>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</figure>
|
|
|
|
<figure>
|
|
|
|
<figcaption>Panel using inherited padding for consistency</figcaption>
|
UI: Update Consul UI colors to use HDS colors (#16111)
* update red color variables to hds
* change background red to be one step lighter
* map oranges
* map greens
* map blues
* map greys
* delete themes, colours: lemon, magenta, strawberry, and vault color aliases
* add unmapped rainbow colours
* replace white and transparent vars, remove unused semantic vars and frame placeholders
* small tweaks to improve contrast, change node health status x/check colours for non-voters to match design doc, replace semantic colour action w hds colour
* add unmapped grays, remove dark theme, manually set nav bar to use dark colours
* map consul pink colour
* map yellows
* add unmapped oranges, delete light theme
* remove readme, base variables, clean up dangling colours
* Start working on the nav disclosure menus
* Update main-nav-horizontal dropdowns
* Format template
* Update box-shadow tokens
* Replace --tone- usage with tokens
* Update nav disabled state and panel border colour
* Replace rgb usage on tile
* Fix permissions modal overlay
* More fixes
* Replace orange-500 with amber-200
* Update badge colors
* Update vertical sidebar colors
* Remove top border on consul peer list ul
---------
Co-authored-by: wenincode <tyler.wendlandt@hashicorp.com>
2023-02-27 16:30:12 +00:00
|
|
|
<div class={{class-map 'panel'}} ...attributes>
|
2022-02-21 12:22:59 +00:00
|
|
|
<Action
|
|
|
|
style={{style-map
|
|
|
|
(array 'width' '100%')
|
UI: Update Consul UI colors to use HDS colors (#16111)
* update red color variables to hds
* change background red to be one step lighter
* map oranges
* map greens
* map blues
* map greys
* delete themes, colours: lemon, magenta, strawberry, and vault color aliases
* add unmapped rainbow colours
* replace white and transparent vars, remove unused semantic vars and frame placeholders
* small tweaks to improve contrast, change node health status x/check colours for non-voters to match design doc, replace semantic colour action w hds colour
* add unmapped grays, remove dark theme, manually set nav bar to use dark colours
* map consul pink colour
* map yellows
* add unmapped oranges, delete light theme
* remove readme, base variables, clean up dangling colours
* Start working on the nav disclosure menus
* Update main-nav-horizontal dropdowns
* Format template
* Update box-shadow tokens
* Replace --tone- usage with tokens
* Update nav disabled state and panel border colour
* Replace rgb usage on tile
* Fix permissions modal overlay
* More fixes
* Replace orange-500 with amber-200
* Update badge colors
* Update vertical sidebar colors
* Remove top border on consul peer list ul
---------
Co-authored-by: wenincode <tyler.wendlandt@hashicorp.com>
2023-02-27 16:30:12 +00:00
|
|
|
(array 'border-bottom' '1px solid var(--tone-border)')
|
2022-02-21 12:22:59 +00:00
|
|
|
(array 'padding' 'var(--padding-x) var(--padding-y)')
|
|
|
|
}}
|
|
|
|
>
|
|
|
|
Full Width Button
|
|
|
|
</Action>
|
UI: Update Consul UI colors to use HDS colors (#16111)
* update red color variables to hds
* change background red to be one step lighter
* map oranges
* map greens
* map blues
* map greys
* delete themes, colours: lemon, magenta, strawberry, and vault color aliases
* add unmapped rainbow colours
* replace white and transparent vars, remove unused semantic vars and frame placeholders
* small tweaks to improve contrast, change node health status x/check colours for non-voters to match design doc, replace semantic colour action w hds colour
* add unmapped grays, remove dark theme, manually set nav bar to use dark colours
* map consul pink colour
* map yellows
* add unmapped oranges, delete light theme
* remove readme, base variables, clean up dangling colours
* Start working on the nav disclosure menus
* Update main-nav-horizontal dropdowns
* Format template
* Update box-shadow tokens
* Replace --tone- usage with tokens
* Update nav disabled state and panel border colour
* Replace rgb usage on tile
* Fix permissions modal overlay
* More fixes
* Replace orange-500 with amber-200
* Update badge colors
* Update vertical sidebar colors
* Remove top border on consul peer list ul
---------
Co-authored-by: wenincode <tyler.wendlandt@hashicorp.com>
2023-02-27 16:30:12 +00:00
|
|
|
<div style={{style-map (array 'padding' 'var(--padding-x) var(--padding-y)')}}>
|
2022-02-21 12:22:59 +00:00
|
|
|
<p>Some text with padding</p>
|
|
|
|
</div>
|
|
|
|
<hr />
|
UI: Update Consul UI colors to use HDS colors (#16111)
* update red color variables to hds
* change background red to be one step lighter
* map oranges
* map greens
* map blues
* map greys
* delete themes, colours: lemon, magenta, strawberry, and vault color aliases
* add unmapped rainbow colours
* replace white and transparent vars, remove unused semantic vars and frame placeholders
* small tweaks to improve contrast, change node health status x/check colours for non-voters to match design doc, replace semantic colour action w hds colour
* add unmapped grays, remove dark theme, manually set nav bar to use dark colours
* map consul pink colour
* map yellows
* add unmapped oranges, delete light theme
* remove readme, base variables, clean up dangling colours
* Start working on the nav disclosure menus
* Update main-nav-horizontal dropdowns
* Format template
* Update box-shadow tokens
* Replace --tone- usage with tokens
* Update nav disabled state and panel border colour
* Replace rgb usage on tile
* Fix permissions modal overlay
* More fixes
* Replace orange-500 with amber-200
* Update badge colors
* Update vertical sidebar colors
* Remove top border on consul peer list ul
---------
Co-authored-by: wenincode <tyler.wendlandt@hashicorp.com>
2023-02-27 16:30:12 +00:00
|
|
|
<div style={{style-map (array 'padding' 'var(--padding-x) var(--padding-y)')}}>
|
2022-02-21 12:22:59 +00:00
|
|
|
<p>Along with a separator ^ again with padding</p>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</figure>
|
|
|
|
<figure>
|
|
|
|
<figcaption>Panel using larger padding and different color borders</figcaption>
|
|
|
|
<div
|
UI: Update Consul UI colors to use HDS colors (#16111)
* update red color variables to hds
* change background red to be one step lighter
* map oranges
* map greens
* map blues
* map greys
* delete themes, colours: lemon, magenta, strawberry, and vault color aliases
* add unmapped rainbow colours
* replace white and transparent vars, remove unused semantic vars and frame placeholders
* small tweaks to improve contrast, change node health status x/check colours for non-voters to match design doc, replace semantic colour action w hds colour
* add unmapped grays, remove dark theme, manually set nav bar to use dark colours
* map consul pink colour
* map yellows
* add unmapped oranges, delete light theme
* remove readme, base variables, clean up dangling colours
* Start working on the nav disclosure menus
* Update main-nav-horizontal dropdowns
* Format template
* Update box-shadow tokens
* Replace --tone- usage with tokens
* Update nav disabled state and panel border colour
* Replace rgb usage on tile
* Fix permissions modal overlay
* More fixes
* Replace orange-500 with amber-200
* Update badge colors
* Update vertical sidebar colors
* Remove top border on consul peer list ul
---------
Co-authored-by: wenincode <tyler.wendlandt@hashicorp.com>
2023-02-27 16:30:12 +00:00
|
|
|
class={{class-map 'panel'}}
|
|
|
|
style={{style-map
|
|
|
|
(array '--padding-x' '24px')
|
|
|
|
(array '--padding-y' '24px')
|
|
|
|
(array '--tone-border' 'var(--token-color-consul-foreground)')
|
2022-02-21 12:22:59 +00:00
|
|
|
}}
|
|
|
|
...attributes
|
|
|
|
>
|
|
|
|
<Action
|
|
|
|
style={{style-map
|
|
|
|
(array 'width' '100%')
|
UI: Update Consul UI colors to use HDS colors (#16111)
* update red color variables to hds
* change background red to be one step lighter
* map oranges
* map greens
* map blues
* map greys
* delete themes, colours: lemon, magenta, strawberry, and vault color aliases
* add unmapped rainbow colours
* replace white and transparent vars, remove unused semantic vars and frame placeholders
* small tweaks to improve contrast, change node health status x/check colours for non-voters to match design doc, replace semantic colour action w hds colour
* add unmapped grays, remove dark theme, manually set nav bar to use dark colours
* map consul pink colour
* map yellows
* add unmapped oranges, delete light theme
* remove readme, base variables, clean up dangling colours
* Start working on the nav disclosure menus
* Update main-nav-horizontal dropdowns
* Format template
* Update box-shadow tokens
* Replace --tone- usage with tokens
* Update nav disabled state and panel border colour
* Replace rgb usage on tile
* Fix permissions modal overlay
* More fixes
* Replace orange-500 with amber-200
* Update badge colors
* Update vertical sidebar colors
* Remove top border on consul peer list ul
---------
Co-authored-by: wenincode <tyler.wendlandt@hashicorp.com>
2023-02-27 16:30:12 +00:00
|
|
|
(array 'border-bottom' '1px solid var(--tone-border)')
|
2022-02-21 12:22:59 +00:00
|
|
|
(array 'padding' 'var(--padding-x) var(--padding-y)')
|
|
|
|
}}
|
|
|
|
>
|
|
|
|
Full Width Button
|
|
|
|
</Action>
|
UI: Update Consul UI colors to use HDS colors (#16111)
* update red color variables to hds
* change background red to be one step lighter
* map oranges
* map greens
* map blues
* map greys
* delete themes, colours: lemon, magenta, strawberry, and vault color aliases
* add unmapped rainbow colours
* replace white and transparent vars, remove unused semantic vars and frame placeholders
* small tweaks to improve contrast, change node health status x/check colours for non-voters to match design doc, replace semantic colour action w hds colour
* add unmapped grays, remove dark theme, manually set nav bar to use dark colours
* map consul pink colour
* map yellows
* add unmapped oranges, delete light theme
* remove readme, base variables, clean up dangling colours
* Start working on the nav disclosure menus
* Update main-nav-horizontal dropdowns
* Format template
* Update box-shadow tokens
* Replace --tone- usage with tokens
* Update nav disabled state and panel border colour
* Replace rgb usage on tile
* Fix permissions modal overlay
* More fixes
* Replace orange-500 with amber-200
* Update badge colors
* Update vertical sidebar colors
* Remove top border on consul peer list ul
---------
Co-authored-by: wenincode <tyler.wendlandt@hashicorp.com>
2023-02-27 16:30:12 +00:00
|
|
|
<div style={{style-map (array 'padding' 'var(--padding-x) var(--padding-y)')}}>
|
2022-02-21 12:22:59 +00:00
|
|
|
<p>Some text with padding</p>
|
|
|
|
</div>
|
|
|
|
<hr />
|
UI: Update Consul UI colors to use HDS colors (#16111)
* update red color variables to hds
* change background red to be one step lighter
* map oranges
* map greens
* map blues
* map greys
* delete themes, colours: lemon, magenta, strawberry, and vault color aliases
* add unmapped rainbow colours
* replace white and transparent vars, remove unused semantic vars and frame placeholders
* small tweaks to improve contrast, change node health status x/check colours for non-voters to match design doc, replace semantic colour action w hds colour
* add unmapped grays, remove dark theme, manually set nav bar to use dark colours
* map consul pink colour
* map yellows
* add unmapped oranges, delete light theme
* remove readme, base variables, clean up dangling colours
* Start working on the nav disclosure menus
* Update main-nav-horizontal dropdowns
* Format template
* Update box-shadow tokens
* Replace --tone- usage with tokens
* Update nav disabled state and panel border colour
* Replace rgb usage on tile
* Fix permissions modal overlay
* More fixes
* Replace orange-500 with amber-200
* Update badge colors
* Update vertical sidebar colors
* Remove top border on consul peer list ul
---------
Co-authored-by: wenincode <tyler.wendlandt@hashicorp.com>
2023-02-27 16:30:12 +00:00
|
|
|
<div style={{style-map (array 'padding' 'var(--padding-x) var(--padding-y)')}}>
|
2022-02-21 12:22:59 +00:00
|
|
|
<p>Along with a separator ^ again with padding</p>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</figure>
|
|
|
|
```
|
|
|
|
|
|
|
|
```css
|
|
|
|
.panel {
|
|
|
|
@extend %panel;
|
|
|
|
}
|
|
|
|
.panel hr {
|
|
|
|
@extend %panel-separator;
|
|
|
|
}
|
|
|
|
```
|
|
|
|
|
|
|
|
## CSS Properties
|
|
|
|
|
UI: Update Consul UI colors to use HDS colors (#16111)
* update red color variables to hds
* change background red to be one step lighter
* map oranges
* map greens
* map blues
* map greys
* delete themes, colours: lemon, magenta, strawberry, and vault color aliases
* add unmapped rainbow colours
* replace white and transparent vars, remove unused semantic vars and frame placeholders
* small tweaks to improve contrast, change node health status x/check colours for non-voters to match design doc, replace semantic colour action w hds colour
* add unmapped grays, remove dark theme, manually set nav bar to use dark colours
* map consul pink colour
* map yellows
* add unmapped oranges, delete light theme
* remove readme, base variables, clean up dangling colours
* Start working on the nav disclosure menus
* Update main-nav-horizontal dropdowns
* Format template
* Update box-shadow tokens
* Replace --tone- usage with tokens
* Update nav disabled state and panel border colour
* Replace rgb usage on tile
* Fix permissions modal overlay
* More fixes
* Replace orange-500 with amber-200
* Update badge colors
* Update vertical sidebar colors
* Remove top border on consul peer list ul
---------
Co-authored-by: wenincode <tyler.wendlandt@hashicorp.com>
2023-02-27 16:30:12 +00:00
|
|
|
| Property | Type | Default | Description |
|
|
|
|
| --------------- | -------- | --------------------------------- | -------------------------------------------------------------------- |
|
|
|
|
| `--tone-border` | `color` | --token-color-palette-neutral-300 | Default color for all borders |
|
|
|
|
| `--padding-x` | `length` | 14px | Default x padding to be used for padding values within the component |
|
|
|
|
| `--padding-y` | `length` | 14px | Default y padding to be used for padding values within the component |
|