2019-04-26 12:16:03 -05:00
|
|
|
$mobile-menu-breakpoint: md;
|
|
|
|
|
2017-08-15 08:25:18 -05:00
|
|
|
.sidemenu {
|
2017-08-17 07:00:41 -05:00
|
|
|
position: fixed;
|
2017-08-14 05:26:24 -05:00
|
|
|
display: flex;
|
2017-08-15 08:25:18 -05:00
|
|
|
flex-flow: column;
|
2017-08-14 05:26:24 -05:00
|
|
|
flex-direction: column;
|
2016-02-18 12:47:00 -06:00
|
|
|
width: $side-menu-width;
|
2017-12-01 07:31:55 -06:00
|
|
|
z-index: $zindex-sidemenu;
|
2020-03-24 04:30:53 -05:00
|
|
|
|
2016-02-15 08:27:41 -06:00
|
|
|
a:focus {
|
|
|
|
text-decoration: none;
|
|
|
|
}
|
|
|
|
|
2017-12-04 05:37:00 -06:00
|
|
|
.sidemenu__logo_small_breakpoint {
|
|
|
|
display: none;
|
2017-08-17 07:00:41 -05:00
|
|
|
}
|
2017-12-04 05:37:00 -06:00
|
|
|
|
|
|
|
.sidemenu__close {
|
|
|
|
display: none;
|
2017-08-17 07:00:41 -05:00
|
|
|
}
|
2019-03-11 07:18:22 -05:00
|
|
|
|
2019-04-26 12:16:03 -05:00
|
|
|
@include media-breakpoint-up($mobile-menu-breakpoint) {
|
2020-04-04 08:39:43 -05:00
|
|
|
background: $side-menu-bg;
|
2019-03-11 07:18:22 -05:00
|
|
|
height: auto;
|
|
|
|
box-shadow: $side-menu-shadow;
|
|
|
|
position: relative;
|
|
|
|
z-index: $zindex-sidemenu;
|
|
|
|
}
|
2017-12-07 09:25:21 -06:00
|
|
|
}
|
|
|
|
|
|
|
|
// body class that hides sidemenu
|
|
|
|
.sidemenu-hidden {
|
|
|
|
.sidemenu {
|
|
|
|
display: none;
|
|
|
|
}
|
2017-12-04 05:37:00 -06:00
|
|
|
}
|
|
|
|
|
2017-08-15 07:49:12 -05:00
|
|
|
.sidemenu__top {
|
2019-03-27 02:48:24 -05:00
|
|
|
padding-top: 40px;
|
2017-08-15 07:49:12 -05:00
|
|
|
flex-grow: 1;
|
|
|
|
}
|
|
|
|
|
|
|
|
.sidemenu__bottom {
|
|
|
|
padding-bottom: $spacer;
|
2019-03-11 07:18:22 -05:00
|
|
|
}
|
|
|
|
|
|
|
|
.sidemenu__top,
|
|
|
|
.sidemenu__bottom {
|
2017-08-17 07:00:41 -05:00
|
|
|
display: none;
|
2019-03-11 07:18:22 -05:00
|
|
|
|
2019-04-26 12:16:03 -05:00
|
|
|
@include media-breakpoint-up($mobile-menu-breakpoint) {
|
2019-03-11 07:18:22 -05:00
|
|
|
display: block;
|
|
|
|
}
|
2017-08-15 07:49:12 -05:00
|
|
|
}
|
|
|
|
|
|
|
|
.sidemenu-item {
|
|
|
|
position: relative;
|
|
|
|
@include left-brand-border();
|
|
|
|
|
2019-04-26 12:16:03 -05:00
|
|
|
@include media-breakpoint-up($mobile-menu-breakpoint) {
|
2017-12-04 05:37:00 -06:00
|
|
|
&.active,
|
|
|
|
&:hover {
|
|
|
|
background-color: $side-menu-item-hover-bg;
|
|
|
|
@include left-brand-border-gradient();
|
2017-08-15 07:49:12 -05:00
|
|
|
|
2017-12-04 05:37:00 -06:00
|
|
|
.dropdown-menu {
|
2020-04-13 02:58:40 -05:00
|
|
|
border: none;
|
2017-12-04 05:37:00 -06: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 07:16:10 -06:00
|
|
|
@include animation('dropdown-anim 150ms ease-in-out 100ms forwards');
|
2017-12-19 09:22:41 -06:00
|
|
|
z-index: $zindex-sidemenu;
|
2017-12-04 05:37:00 -06:00
|
|
|
}
|
2016-02-15 08:27:41 -06:00
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2017-08-15 07:49:12 -05:00
|
|
|
.dropup.sidemenu-item:hover .dropdown-menu {
|
|
|
|
top: auto !important;
|
|
|
|
}
|
|
|
|
|
|
|
|
.sidemenu-link {
|
2020-04-13 02:58:40 -05:00
|
|
|
color: $side-menu-icon-color !important;
|
2017-08-15 07:49:12 -05:00
|
|
|
line-height: 42px;
|
|
|
|
padding: 0px 10px 0px 10px;
|
|
|
|
display: block;
|
|
|
|
position: relative;
|
|
|
|
font-size: 16px;
|
|
|
|
border: 1px solid transparent;
|
2017-10-14 14:17:16 -05:00
|
|
|
text-align: center;
|
2017-08-15 07:49:12 -05:00
|
|
|
|
|
|
|
img {
|
|
|
|
border-radius: 50%;
|
|
|
|
width: 28px;
|
|
|
|
height: 28px;
|
2017-12-19 09:22:41 -06:00
|
|
|
box-shadow: 0 0 14px 2px rgba(255, 255, 255, 0.05);
|
2017-08-15 07:49:12 -05:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2016-02-20 13:40:16 -06:00
|
|
|
@include keyframes(dropdown-anim) {
|
2016-02-20 08:02:12 -06:00
|
|
|
0% {
|
|
|
|
opacity: 0;
|
2017-08-16 08:03:49 -05:00
|
|
|
//transform: translate3d(-5%,0,0);
|
2016-02-20 08:02:12 -06:00
|
|
|
}
|
|
|
|
100% {
|
|
|
|
opacity: 1;
|
2017-08-16 08:03:49 -05:00
|
|
|
//transform: translate3d(0,0,0);
|
2016-02-20 08:02:12 -06:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2016-02-15 08:27:41 -06:00
|
|
|
.icon-circle {
|
2017-08-14 15:47:04 -05:00
|
|
|
width: 35px;
|
|
|
|
height: 35px;
|
2016-02-15 08:27:41 -06: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 07:33:31 -05:00
|
|
|
position: relative;
|
2017-06-12 09:46:02 -05:00
|
|
|
|
2016-02-15 08:27:41 -06:00
|
|
|
img {
|
|
|
|
position: relative;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2017-06-08 16:13:38 -05:00
|
|
|
.side-menu-header {
|
2017-06-12 14:11:22 -05:00
|
|
|
padding: 10px 10px 10px 20px;
|
2017-06-22 17:11:29 -05:00
|
|
|
white-space: nowrap;
|
2017-06-08 16:13:38 -05:00
|
|
|
background-color: $side-menu-item-hover-bg;
|
2017-08-15 07:49:12 -05:00
|
|
|
font-size: 17px;
|
2020-04-13 02:58:40 -05:00
|
|
|
color: $side-menu-header-color;
|
2016-02-15 08:27:41 -06:00
|
|
|
}
|
|
|
|
|
2019-01-24 23:44:32 -06:00
|
|
|
.side-menu-header-link {
|
2020-04-13 02:58:40 -05:00
|
|
|
color: $side-menu-header-color !important;
|
2019-01-22 01:12:48 -06:00
|
|
|
border: none !important;
|
|
|
|
padding: 0 !important;
|
|
|
|
}
|
|
|
|
|
2019-01-24 23:44:32 -06:00
|
|
|
.dropdown-menu--sidemenu > li > .side-menu-header-link:hover {
|
|
|
|
color: #fff !important;
|
|
|
|
background-color: $side-menu-item-hover-bg !important;
|
|
|
|
}
|
|
|
|
|
2018-04-16 09:25:28 -05:00
|
|
|
.sidemenu-subtitle {
|
2019-03-27 02:48:24 -05:00
|
|
|
padding: $space-sm $space-md $space-sm;
|
2018-04-16 06:37:05 -05:00
|
|
|
font-size: $font-size-sm;
|
|
|
|
color: $text-color-weak;
|
2018-04-16 09:25:28 -05:00
|
|
|
border-bottom: 1px solid $dropdownDividerBottom;
|
2019-03-11 05:33:15 -05:00
|
|
|
margin-bottom: $space-xs;
|
2018-04-16 09:25:28 -05:00
|
|
|
white-space: nowrap;
|
2018-04-16 06:37:05 -05:00
|
|
|
}
|
|
|
|
|
2017-08-16 08:03:49 -05:00
|
|
|
li.sidemenu-org-switcher {
|
|
|
|
border-bottom: 1px solid $dropdownDividerBottom;
|
2016-02-15 08:27:41 -06:00
|
|
|
}
|
|
|
|
|
2017-08-16 08:03:49 -05:00
|
|
|
.sidemenu-org-switcher__org-name {
|
|
|
|
font-size: $font-size-base;
|
2016-02-15 08:27:41 -06:00
|
|
|
}
|
|
|
|
|
2017-08-16 08:03:49 -05:00
|
|
|
.sidemenu-org-switcher__org-current {
|
|
|
|
font-size: $font-size-xs;
|
|
|
|
color: $text-color-weak;
|
|
|
|
position: relative;
|
|
|
|
top: -2px;
|
2016-02-15 08:27:41 -06:00
|
|
|
}
|
|
|
|
|
2017-08-16 08:03:49 -05:00
|
|
|
.sidemenu-org-switcher__switch {
|
|
|
|
font-size: $font-size-sm;
|
2019-03-27 02:48:24 -05:00
|
|
|
padding-left: $space-lg;
|
2017-08-16 08:03:49 -05:00
|
|
|
display: flex;
|
|
|
|
align-items: center;
|
|
|
|
> i.fa.fa-random {
|
2019-03-11 05:33:15 -05:00
|
|
|
margin-right: $space-xs;
|
2017-08-16 08:03:49 -05:00
|
|
|
top: 1px;
|
|
|
|
}
|
|
|
|
}
|
2017-08-17 07:00:41 -05:00
|
|
|
|
2017-12-07 09:25:21 -06:00
|
|
|
.sidemenu__logo {
|
2017-08-17 07:00:41 -05:00
|
|
|
display: block;
|
2019-03-27 02:48:24 -05:00
|
|
|
padding: 6px 14px 6px 9px;
|
2017-08-17 07:00:41 -05:00
|
|
|
min-height: $navbarHeight;
|
2017-11-01 08:23:46 -05:00
|
|
|
position: relative;
|
2018-03-27 03:41:47 -05:00
|
|
|
height: $navbarHeight - 1px;
|
2017-08-17 07:00:41 -05:00
|
|
|
|
|
|
|
&:hover {
|
2020-03-24 04:30:53 -05:00
|
|
|
background: lightOrDark($gray33, $gray25);
|
2017-08-17 07:00:41 -05:00
|
|
|
}
|
|
|
|
|
|
|
|
img {
|
2021-01-27 08:02:04 -06:00
|
|
|
width: 26px;
|
2017-08-17 07:00:41 -05:00
|
|
|
position: relative;
|
2017-10-16 02:55:55 -05:00
|
|
|
top: 5px;
|
2021-01-27 08:02:04 -06:00
|
|
|
left: 8px;
|
2017-08-17 07:00:41 -05:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2019-04-26 12:16:03 -05:00
|
|
|
@include media-breakpoint-down(sm) {
|
2017-12-04 05:37:00 -06:00
|
|
|
.sidemenu-open--xs {
|
2018-03-06 07:16:10 -06:00
|
|
|
li {
|
2019-04-26 12:16:03 -05:00
|
|
|
font-size: $font-size-md;
|
2018-03-06 07:16:10 -06:00
|
|
|
}
|
|
|
|
|
2017-12-04 05:37:00 -06:00
|
|
|
.sidemenu {
|
|
|
|
width: 100%;
|
2018-03-06 07:16:10 -06:00
|
|
|
background: $side-menu-bg-mobile;
|
2017-12-04 05:37:00 -06: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 09:25:21 -06:00
|
|
|
position: relative;
|
|
|
|
top: -3px;
|
2017-12-04 05:37:00 -06:00
|
|
|
}
|
|
|
|
|
|
|
|
.sidemenu__top,
|
|
|
|
.sidemenu__bottom {
|
|
|
|
display: block;
|
|
|
|
}
|
2018-03-06 07:16:10 -06:00
|
|
|
.sidemenu-item {
|
|
|
|
border-right: 2px solid transparent;
|
|
|
|
}
|
2017-12-04 05:37:00 -06:00
|
|
|
}
|
|
|
|
|
|
|
|
.sidemenu {
|
|
|
|
.sidemenu__logo {
|
|
|
|
display: none;
|
|
|
|
}
|
2017-12-07 09:25:21 -06:00
|
|
|
|
2017-12-04 05:37:00 -06:00
|
|
|
.sidemenu__logo_small_breakpoint {
|
2021-01-27 08:02:04 -06:00
|
|
|
padding: 13px;
|
2017-12-04 05:37:00 -06:00
|
|
|
display: flex;
|
|
|
|
flex-direction: row;
|
|
|
|
justify-content: space-between;
|
|
|
|
align-items: baseline;
|
2021-01-27 08:02:04 -06:00
|
|
|
cursor: pointer;
|
2017-12-04 05:37:00 -06:00
|
|
|
|
2017-12-07 09:25:21 -06:00
|
|
|
.fa-bars {
|
|
|
|
font-size: 25px;
|
2017-12-04 05:37:00 -06:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
.sidemenu__top {
|
2019-03-27 02:48:24 -05:00
|
|
|
padding-top: 0;
|
2017-12-04 05:37:00 -06:00
|
|
|
}
|
|
|
|
|
|
|
|
.side-menu-header {
|
|
|
|
padding-left: 10px;
|
|
|
|
}
|
|
|
|
|
|
|
|
.sidemenu-link {
|
|
|
|
text-align: left;
|
|
|
|
}
|
|
|
|
|
|
|
|
.sidemenu-icon {
|
2017-12-19 09:22:41 -06:00
|
|
|
display: none;
|
2017-12-04 05:37:00 -06:00
|
|
|
}
|
|
|
|
|
|
|
|
.dropdown-menu--sidemenu {
|
|
|
|
display: block;
|
|
|
|
position: unset;
|
|
|
|
width: 100%;
|
|
|
|
float: none;
|
2019-03-12 02:10:31 -05:00
|
|
|
margin-bottom: $space-sm;
|
2017-12-04 05:37:00 -06:00
|
|
|
|
|
|
|
> li > a {
|
|
|
|
padding-left: 15px;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
.sidemenu__bottom {
|
|
|
|
.dropdown-menu--sidemenu {
|
|
|
|
display: flex;
|
|
|
|
flex-direction: column-reverse;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|