2019-04-26 19:16:03 +02:00
|
|
|
$mobile-menu-breakpoint: md;
|
|
|
|
|
|
2017-08-15 15:25:18 +02:00
|
|
|
.sidemenu {
|
2017-08-17 14:00:41 +02:00
|
|
|
position: fixed;
|
2017-08-14 12:26:24 +02:00
|
|
|
display: flex;
|
2017-08-15 15:25:18 +02:00
|
|
|
flex-flow: column;
|
2017-08-14 12:26:24 +02:00
|
|
|
flex-direction: column;
|
2016-02-18 19:47:00 +01:00
|
|
|
width: $side-menu-width;
|
2017-12-01 16:31:55 +03:00
|
|
|
z-index: $zindex-sidemenu;
|
2020-03-24 10:30:53 +01:00
|
|
|
|
2016-02-15 15:27:41 +01:00
|
|
|
a:focus {
|
|
|
|
|
text-decoration: none;
|
|
|
|
|
}
|
|
|
|
|
|
2017-12-04 12:37:00 +01:00
|
|
|
.sidemenu__logo_small_breakpoint {
|
|
|
|
|
display: none;
|
2017-08-17 14:00:41 +02:00
|
|
|
}
|
2017-12-04 12:37:00 +01:00
|
|
|
|
|
|
|
|
.sidemenu__close {
|
|
|
|
|
display: none;
|
2017-08-17 14:00:41 +02:00
|
|
|
}
|
2019-03-11 13:18:22 +01:00
|
|
|
|
2019-04-26 19:16:03 +02:00
|
|
|
@include media-breakpoint-up($mobile-menu-breakpoint) {
|
2020-04-04 15:39:43 +02:00
|
|
|
background: $side-menu-bg;
|
2019-03-11 13:18:22 +01:00
|
|
|
height: auto;
|
|
|
|
|
box-shadow: $side-menu-shadow;
|
|
|
|
|
position: relative;
|
|
|
|
|
z-index: $zindex-sidemenu;
|
|
|
|
|
}
|
2017-12-07 16:25:21 +01:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
// body class that hides sidemenu
|
|
|
|
|
.sidemenu-hidden {
|
|
|
|
|
.sidemenu {
|
|
|
|
|
display: none;
|
|
|
|
|
}
|
2017-12-04 12:37:00 +01:00
|
|
|
}
|
|
|
|
|
|
2017-08-15 14:49:12 +02:00
|
|
|
.sidemenu__top {
|
2019-03-27 08:48:24 +01:00
|
|
|
padding-top: 40px;
|
2017-08-15 14:49:12 +02:00
|
|
|
flex-grow: 1;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.sidemenu__bottom {
|
|
|
|
|
padding-bottom: $spacer;
|
2019-03-11 13:18:22 +01:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.sidemenu__top,
|
|
|
|
|
.sidemenu__bottom {
|
2017-08-17 14:00:41 +02:00
|
|
|
display: none;
|
2019-03-11 13:18:22 +01:00
|
|
|
|
2019-04-26 19:16:03 +02:00
|
|
|
@include media-breakpoint-up($mobile-menu-breakpoint) {
|
2019-03-11 13:18:22 +01:00
|
|
|
display: block;
|
|
|
|
|
}
|
2017-08-15 14:49:12 +02:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.sidemenu-item {
|
|
|
|
|
position: relative;
|
|
|
|
|
@include left-brand-border();
|
|
|
|
|
|
2019-04-26 19:16:03 +02:00
|
|
|
@include media-breakpoint-up($mobile-menu-breakpoint) {
|
2017-12-04 12:37:00 +01:00
|
|
|
&.active,
|
|
|
|
|
&:hover {
|
|
|
|
|
background-color: $side-menu-item-hover-bg;
|
|
|
|
|
@include left-brand-border-gradient();
|
2017-08-15 14:49:12 +02:00
|
|
|
|
2017-12-04 12:37:00 +01:00
|
|
|
.dropdown-menu {
|
2020-04-13 09:58:40 +02:00
|
|
|
border: none;
|
2017-12-04 12:37:00 +01:00
|
|
|
margin: 0;
|
|
|
|
|
display: block;
|
|
|
|
|
opacity: 0;
|
|
|
|
|
top: 0px;
|
|
|
|
|
// important to overlap it otherwise it can be hidden
|
|
|
|
|
// again by the mouse getting outside the hover space
|
|
|
|
|
left: $side-menu-width - 2px;
|
2018-03-06 14:16:10 +01:00
|
|
|
@include animation('dropdown-anim 150ms ease-in-out 100ms forwards');
|
2017-12-19 16:22:41 +01:00
|
|
|
z-index: $zindex-sidemenu;
|
2017-12-04 12:37:00 +01:00
|
|
|
}
|
2016-02-15 15:27:41 +01:00
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
2017-08-15 14:49:12 +02:00
|
|
|
.dropup.sidemenu-item:hover .dropdown-menu {
|
|
|
|
|
top: auto !important;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.sidemenu-link {
|
2020-04-13 09:58:40 +02:00
|
|
|
color: $side-menu-icon-color !important;
|
2017-08-15 14:49:12 +02:00
|
|
|
line-height: 42px;
|
|
|
|
|
padding: 0px 10px 0px 10px;
|
|
|
|
|
display: block;
|
|
|
|
|
position: relative;
|
|
|
|
|
font-size: 16px;
|
|
|
|
|
border: 1px solid transparent;
|
2017-10-14 21:17:16 +02:00
|
|
|
text-align: center;
|
2017-08-15 14:49:12 +02:00
|
|
|
|
|
|
|
|
img {
|
|
|
|
|
border-radius: 50%;
|
|
|
|
|
width: 28px;
|
|
|
|
|
height: 28px;
|
2017-12-19 16:22:41 +01:00
|
|
|
box-shadow: 0 0 14px 2px rgba(255, 255, 255, 0.05);
|
2017-08-15 14:49:12 +02:00
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
2016-02-20 14:40:16 -05:00
|
|
|
@include keyframes(dropdown-anim) {
|
2016-02-20 09:02:12 -05:00
|
|
|
0% {
|
|
|
|
|
opacity: 0;
|
2017-08-16 15:03:49 +02:00
|
|
|
//transform: translate3d(-5%,0,0);
|
2016-02-20 09:02:12 -05:00
|
|
|
}
|
|
|
|
|
100% {
|
|
|
|
|
opacity: 1;
|
2017-08-16 15:03:49 +02:00
|
|
|
//transform: translate3d(0,0,0);
|
2016-02-20 09:02:12 -05:00
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
2016-02-15 15:27:41 +01:00
|
|
|
.icon-circle {
|
2017-08-14 22:47:04 +02:00
|
|
|
width: 35px;
|
|
|
|
|
height: 35px;
|
2016-02-15 15:27:41 +01:00
|
|
|
display: inline-block;
|
@grafana/ui: Create Icon component and replace part of the icons (#23402)
* Part1: Unicons implementation (#23197)
* Create a new Icon component
* Update icons in main sidebar
* Update icons in Useful links and in react components on main site
* Update icons in Useful links and in main top navigation
* Adjust sizing
* Update panel navigation and timepicker
* Update icons in Panel menu
* NewPanelEditor: Fixed so that test alert rule works in new edit mode (#23179)
* Update icons in add panel widget
* Resolve merge conflict
* Fix part of the test errors and type errors
* Fix storybook errors
* Update getAvailableIcons import in storybook knobs
* Fix import path
* Fix SyntaxError: Cannot use import statement outside a module in test environment error
* Remove dynamic imports
* Remove types as using @ts-ignore
* Update snapshot test
* Add @iconscout/react-unicons to the shouldExclude list as it is blundled with es2015 syntax
* Remove color prop from icon, remove color implemetation in mono icons
* Update navbar styling
* Move toPascalCase to utils/string
Co-authored-by: Torkel Ödegaard <torkel@grafana.com>
* Resolve type errors resulted from merge
* Part2: Unicons implementation (#23266)
* Create a new Icon component
* Update icons in main sidebar
* Update icons in Useful links and in react components on main site
* Update icons in Useful links and in main top navigation
* Adjust sizing
* Update panel navigation and timepicker
* Update icons in Panel menu
* Update icons in add panel widget
* Resolve merge conflict
* Fix part of the test errors and type errors
* Fix storybook errors
* Update getAvailableIcons import in storybook knobs
* Fix import path
* Fix SyntaxError: Cannot use import statement outside a module in test environment error
* Remove dynamic imports
* Remove types as using @ts-ignore
* Update snapshot test
* Add @iconscout/react-unicons to the shouldExclude list as it is blundled with es2015 syntax
* Implment icons in Tabs
* Implement icons in search items and empty list
* Update buttons
* Update button-related snapshot tests
* Update icons in modals and page headers
* Create anfular wrapper and update all icons on search screen
* Update sizing, remove colors, update snapshot tests
* Remove color prop from icon, remove color implemetation in mono icons
* Remove color props from monochrome icons
* Complete update of icons for search screen
* Update icons for infor tooltips, playlist, permissions
* Support temporarly font awesome icons used in enterprise grafana
* Part1: Unicons implementation (#23197)
* Create a new Icon component
* Update icons in main sidebar
* Update icons in Useful links and in react components on main site
* Update icons in Useful links and in main top navigation
* Adjust sizing
* Update panel navigation and timepicker
* Update icons in Panel menu
* NewPanelEditor: Fixed so that test alert rule works in new edit mode (#23179)
* Update icons in add panel widget
* Resolve merge conflict
* Fix part of the test errors and type errors
* Fix storybook errors
* Update getAvailableIcons import in storybook knobs
* Fix import path
* Fix SyntaxError: Cannot use import statement outside a module in test environment error
* Remove dynamic imports
* Remove types as using @ts-ignore
* Update snapshot test
* Add @iconscout/react-unicons to the shouldExclude list as it is blundled with es2015 syntax
* Remove color prop from icon, remove color implemetation in mono icons
* Update navbar styling
* Move toPascalCase to utils/string
Co-authored-by: Torkel Ödegaard <torkel@grafana.com>
* Icons update
* Add optional chaining to for isFontAwesome variable
Co-authored-by: Torkel Ödegaard <torkel@grafana.com>
* Part3: Unicons implementation (#23356)
* Create a new Icon component
* Update icons in main sidebar
* Update icons in Useful links and in react components on main site
* Update icons in Useful links and in main top navigation
* Adjust sizing
* Update panel navigation and timepicker
* Update icons in Panel menu
* Update icons in add panel widget
* Resolve merge conflict
* Fix part of the test errors and type errors
* Fix storybook errors
* Update getAvailableIcons import in storybook knobs
* Fix import path
* Fix SyntaxError: Cannot use import statement outside a module in test environment error
* Remove dynamic imports
* Remove types as using @ts-ignore
* Update snapshot test
* Add @iconscout/react-unicons to the shouldExclude list as it is blundled with es2015 syntax
* Implment icons in Tabs
* Implement icons in search items and empty list
* Update buttons
* Update button-related snapshot tests
* Update icons in modals and page headers
* Create anfular wrapper and update all icons on search screen
* Update sizing, remove colors, update snapshot tests
* Remove color prop from icon, remove color implemetation in mono icons
* Remove color props from monochrome icons
* Complete update of icons for search screen
* Update icons for infor tooltips, playlist, permissions
* Support temporarly font awesome icons used in enterprise grafana
* Part1: Unicons implementation (#23197)
* Create a new Icon component
* Update icons in main sidebar
* Update icons in Useful links and in react components on main site
* Update icons in Useful links and in main top navigation
* Adjust sizing
* Update panel navigation and timepicker
* Update icons in Panel menu
* NewPanelEditor: Fixed so that test alert rule works in new edit mode (#23179)
* Update icons in add panel widget
* Resolve merge conflict
* Fix part of the test errors and type errors
* Fix storybook errors
* Update getAvailableIcons import in storybook knobs
* Fix import path
* Fix SyntaxError: Cannot use import statement outside a module in test environment error
* Remove dynamic imports
* Remove types as using @ts-ignore
* Update snapshot test
* Add @iconscout/react-unicons to the shouldExclude list as it is blundled with es2015 syntax
* Remove color prop from icon, remove color implemetation in mono icons
* Update navbar styling
* Move toPascalCase to utils/string
Co-authored-by: Torkel Ödegaard <torkel@grafana.com>
* Update icons in Explore
* Update icons in alerting
* Update + and x buttons
* Update icons in configurations and settings
* Update close icons
* Update icons in rich history
* Update alert messages
* Add optional chaining to for isFontAwesome variable
* Remove icon mock, set up jest.config
* Fix navbar plus icon
* Fir enable-bacground to enableBackgournd
Co-authored-by: Torkel Ödegaard <torkel@grafana.com>
* Merge remote branch origin master to icons-unicons
* Revert "Merge remote branch origin master to icons-unicons"
This reverts commit 3f25d50a39a940883fefe73ce51219139c1ed37f.
* Size-up dashnav icons
* Fix alerting icons, panel headers, update tests
* Fix typecheck error
* Adjustments - add panel icon, spacing
* Set TerserPlugin sourceMap to false to prevent running out of memory when publishing storybook
Co-authored-by: Torkel Ödegaard <torkel@grafana.com>
2020-04-08 14:33:31 +02:00
|
|
|
position: relative;
|
2017-06-12 16:46:02 +02:00
|
|
|
|
2016-02-15 15:27:41 +01:00
|
|
|
img {
|
|
|
|
|
position: relative;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
2017-06-08 23:13:38 +02:00
|
|
|
.side-menu-header {
|
2017-06-12 21:11:22 +02:00
|
|
|
padding: 10px 10px 10px 20px;
|
2017-06-22 18:11:29 -04:00
|
|
|
white-space: nowrap;
|
2017-06-08 23:13:38 +02:00
|
|
|
background-color: $side-menu-item-hover-bg;
|
2017-08-15 14:49:12 +02:00
|
|
|
font-size: 17px;
|
2020-04-13 09:58:40 +02:00
|
|
|
color: $side-menu-header-color;
|
2016-02-15 15:27:41 +01:00
|
|
|
}
|
|
|
|
|
|
2019-01-25 06:44:32 +01:00
|
|
|
.side-menu-header-link {
|
2020-04-13 09:58:40 +02:00
|
|
|
color: $side-menu-header-color !important;
|
2019-01-22 08:12:48 +01:00
|
|
|
border: none !important;
|
|
|
|
|
padding: 0 !important;
|
|
|
|
|
}
|
|
|
|
|
|
2019-01-25 06:44:32 +01:00
|
|
|
.dropdown-menu--sidemenu > li > .side-menu-header-link:hover {
|
|
|
|
|
color: #fff !important;
|
|
|
|
|
background-color: $side-menu-item-hover-bg !important;
|
|
|
|
|
}
|
|
|
|
|
|
2018-04-16 16:25:28 +02:00
|
|
|
.sidemenu-subtitle {
|
2019-03-27 08:48:24 +01:00
|
|
|
padding: $space-sm $space-md $space-sm;
|
2018-04-16 13:37:05 +02:00
|
|
|
font-size: $font-size-sm;
|
|
|
|
|
color: $text-color-weak;
|
2018-04-16 16:25:28 +02:00
|
|
|
border-bottom: 1px solid $dropdownDividerBottom;
|
2019-03-11 11:33:15 +01:00
|
|
|
margin-bottom: $space-xs;
|
2018-04-16 16:25:28 +02:00
|
|
|
white-space: nowrap;
|
2018-04-16 13:37:05 +02:00
|
|
|
}
|
|
|
|
|
|
2017-08-16 15:03:49 +02:00
|
|
|
li.sidemenu-org-switcher {
|
|
|
|
|
border-bottom: 1px solid $dropdownDividerBottom;
|
2016-02-15 15:27:41 +01:00
|
|
|
}
|
|
|
|
|
|
2017-08-16 15:03:49 +02:00
|
|
|
.sidemenu-org-switcher__org-name {
|
|
|
|
|
font-size: $font-size-base;
|
2016-02-15 15:27:41 +01:00
|
|
|
}
|
|
|
|
|
|
2017-08-16 15:03:49 +02:00
|
|
|
.sidemenu-org-switcher__org-current {
|
|
|
|
|
font-size: $font-size-xs;
|
|
|
|
|
color: $text-color-weak;
|
|
|
|
|
position: relative;
|
|
|
|
|
top: -2px;
|
2016-02-15 15:27:41 +01:00
|
|
|
}
|
|
|
|
|
|
2017-08-16 15:03:49 +02:00
|
|
|
.sidemenu-org-switcher__switch {
|
|
|
|
|
font-size: $font-size-sm;
|
2019-03-27 08:48:24 +01:00
|
|
|
padding-left: $space-lg;
|
2017-08-16 15:03:49 +02:00
|
|
|
display: flex;
|
|
|
|
|
align-items: center;
|
|
|
|
|
> i.fa.fa-random {
|
2019-03-11 11:33:15 +01:00
|
|
|
margin-right: $space-xs;
|
2017-08-16 15:03:49 +02:00
|
|
|
top: 1px;
|
|
|
|
|
}
|
|
|
|
|
}
|
2017-08-17 14:00:41 +02:00
|
|
|
|
2017-12-07 16:25:21 +01:00
|
|
|
.sidemenu__logo {
|
2017-08-17 14:00:41 +02:00
|
|
|
display: block;
|
2019-03-27 08:48:24 +01:00
|
|
|
padding: 6px 14px 6px 9px;
|
2017-08-17 14:00:41 +02:00
|
|
|
min-height: $navbarHeight;
|
2017-11-01 14:23:46 +01:00
|
|
|
position: relative;
|
2018-03-27 10:41:47 +02:00
|
|
|
height: $navbarHeight - 1px;
|
2017-08-17 14:00:41 +02:00
|
|
|
|
|
|
|
|
&:hover {
|
2020-03-24 10:30:53 +01:00
|
|
|
background: lightOrDark($gray33, $gray25);
|
2017-08-17 14:00:41 +02:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
img {
|
2021-01-27 15:02:04 +01:00
|
|
|
width: 26px;
|
2017-08-17 14:00:41 +02:00
|
|
|
position: relative;
|
2017-10-16 09:55:55 +02:00
|
|
|
top: 5px;
|
2021-01-27 15:02:04 +01:00
|
|
|
left: 8px;
|
2017-08-17 14:00:41 +02:00
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
2019-04-26 19:16:03 +02:00
|
|
|
@include media-breakpoint-down(sm) {
|
2017-12-04 12:37:00 +01:00
|
|
|
.sidemenu-open--xs {
|
2018-03-06 14:16:10 +01:00
|
|
|
li {
|
2019-04-26 19:16:03 +02:00
|
|
|
font-size: $font-size-md;
|
2018-03-06 14:16:10 +01:00
|
|
|
}
|
|
|
|
|
|
2017-12-04 12:37:00 +01:00
|
|
|
.sidemenu {
|
|
|
|
|
width: 100%;
|
2018-03-06 14:16:10 +01:00
|
|
|
background: $side-menu-bg-mobile;
|
2017-12-04 12:37:00 +01:00
|
|
|
height: auto;
|
|
|
|
|
box-shadow: $side-menu-shadow;
|
|
|
|
|
position: relative;
|
|
|
|
|
z-index: $zindex-sidemenu;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.sidemenu__close {
|
|
|
|
|
display: block;
|
|
|
|
|
font-size: $font-size-md;
|
2017-12-07 16:25:21 +01:00
|
|
|
position: relative;
|
|
|
|
|
top: -3px;
|
2017-12-04 12:37:00 +01:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.sidemenu__top,
|
|
|
|
|
.sidemenu__bottom {
|
|
|
|
|
display: block;
|
|
|
|
|
}
|
2018-03-06 14:16:10 +01:00
|
|
|
.sidemenu-item {
|
|
|
|
|
border-right: 2px solid transparent;
|
|
|
|
|
}
|
2017-12-04 12:37:00 +01:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.sidemenu {
|
|
|
|
|
.sidemenu__logo {
|
|
|
|
|
display: none;
|
|
|
|
|
}
|
2017-12-07 16:25:21 +01:00
|
|
|
|
2017-12-04 12:37:00 +01:00
|
|
|
.sidemenu__logo_small_breakpoint {
|
2021-01-27 15:02:04 +01:00
|
|
|
padding: 13px;
|
2017-12-04 12:37:00 +01:00
|
|
|
display: flex;
|
|
|
|
|
flex-direction: row;
|
|
|
|
|
justify-content: space-between;
|
|
|
|
|
align-items: baseline;
|
2021-01-27 15:02:04 +01:00
|
|
|
cursor: pointer;
|
2017-12-04 12:37:00 +01:00
|
|
|
|
2017-12-07 16:25:21 +01:00
|
|
|
.fa-bars {
|
|
|
|
|
font-size: 25px;
|
2017-12-04 12:37:00 +01:00
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.sidemenu__top {
|
2019-03-27 08:48:24 +01:00
|
|
|
padding-top: 0;
|
2017-12-04 12:37:00 +01:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.side-menu-header {
|
|
|
|
|
padding-left: 10px;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.sidemenu-link {
|
|
|
|
|
text-align: left;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.sidemenu-icon {
|
2017-12-19 16:22:41 +01:00
|
|
|
display: none;
|
2017-12-04 12:37:00 +01:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.dropdown-menu--sidemenu {
|
|
|
|
|
display: block;
|
|
|
|
|
position: unset;
|
|
|
|
|
width: 100%;
|
|
|
|
|
float: none;
|
2019-03-12 08:10:31 +01:00
|
|
|
margin-bottom: $space-sm;
|
2017-12-04 12:37:00 +01:00
|
|
|
|
|
|
|
|
> li > a {
|
|
|
|
|
padding-left: 15px;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.sidemenu__bottom {
|
|
|
|
|
.dropdown-menu--sidemenu {
|
|
|
|
|
display: flex;
|
|
|
|
|
flex-direction: column-reverse;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|