1- import { GrafanaTheme } from '@grafana/data' ;
1+ import { GrafanaTheme2 } from '@grafana/data' ;
22import { css } from '@emotion/css' ;
33
4- export const getStyles = ( ( theme : GrafanaTheme ) => {
4+ export const getStyles = ( ( theme : GrafanaTheme2 ) => {
55 const containerBorder = theme . isDark
6- ? theme . palette . dark9
7- : theme . palette . gray5 ;
6+ ? theme . v1 . palette . dark9
7+ : theme . v1 . palette . gray5 ;
88
99 return {
1010 container : css `
1111 top : -1px ;
1212 position : absolute;
1313 right : 544px ;
14- box-shadow : 0px 0px 20px ${ theme . colors . dropdownShadow } ;
15- background-color : ${ theme . colors . bodyBg } ;
14+ box-shadow : 0px 0px 20px ${ theme . v1 . colors . dropdownShadow } ;
15+ background-color : ${ theme . v1 . colors . bodyBg } ;
1616 z-index : -1 ;
1717 border : 1px solid ${ containerBorder } ;
1818 border-radius : 2px 0 0 2px ;
1919
2020 & : after {
2121 display : block;
22- background-color : ${ theme . colors . bodyBg } ;
22+ background-color : ${ theme . v1 . colors . bodyBg } ;
2323 width : 19px ;
2424 height : 100% ;
2525 content : '' ;
2626 position : absolute;
2727 top : 0 ;
2828 right : -19px ;
29- border-left : 1px solid ${ theme . colors . border1 } ;
29+ border-left : 1px solid ${ theme . v1 . colors . border1 } ;
3030 }
3131 ` ,
3232 modal : css `
33- z-index : ${ theme . zIndex . modal } ;
33+ z-index : ${ theme . v1 . zIndex . modal } ;
3434 ` ,
3535 content : css `
3636 margin : 0 auto;
@@ -44,22 +44,22 @@ export const getStyles = ((theme: GrafanaTheme) => {
4444 left : 0 ;
4545 background : # 202226 ;
4646 opacity : 0.7 ;
47- z-index : ${ theme . zIndex . modalBackdrop } ;
47+ z-index : ${ theme . v1 . zIndex . modalBackdrop } ;
4848 text-align : center;
4949 ` ,
5050 } ;
5151} ) ;
5252
53- export const getBodyStyles = ( ( theme : GrafanaTheme ) => {
53+ export const getBodyStyles = ( ( theme : GrafanaTheme2 ) => {
5454 const containerBorder = theme . isDark
55- ? theme . palette . dark9
56- : theme . palette . gray5 ;
55+ ? theme . v1 . palette . dark9
56+ : theme . v1 . palette . gray5 ;
5757
5858 return {
5959 title : css `
6060 color : ${ theme . colors . text } ;
61- background-color : ${ theme . colors . bodyBg } ;
62- font-size : ${ theme . typography . size . md } ;
61+ background-color : ${ theme . v1 . colors . bodyBg } ;
62+ font-size : ${ theme . v1 . typography . size . md } ;
6363 border : 1px solid transparent;
6464
6565 & : hover {
@@ -69,10 +69,10 @@ export const getBodyStyles = ((theme: GrafanaTheme) => {
6969 body : css `
7070 z-index : ${ theme . zIndex . modal } ;
7171 position : fixed;
72- background-color : ${ theme . colors . bodyBg } ;
72+ background-color : ${ theme . v1 . colors . bodyBg } ;
7373 width : 268px ;
7474
75- box-shadow : 0px 0px 20px ${ theme . colors . dropdownShadow } ;
75+ box-shadow : 0px 0px 20px ${ theme . v1 . colors . dropdownShadow } ;
7676 border : 1px solid ${ containerBorder } ;
7777 border-radius : 2px 0 0 2px ;
7878
@@ -83,13 +83,13 @@ export const getBodyStyles = ((theme: GrafanaTheme) => {
8383 background-color : inherit;
8484 color : ${ theme . colors . text } ;
8585 border : 0 ;
86- font-weight : ${ theme . typography . weight . semibold } ;
86+ font-weight : ${ theme . v1 . typography . weight . semibold } ;
8787 }
8888
8989 .react-calendar__month-view__weekdays {
9090 background-color : inherit;
9191 text-align : center;
92- color : ${ theme . palette . blue77 } ;
92+ color : ${ theme . v1 . palette . blue77 } ;
9393
9494 abbr {
9595 border : 0 ;
@@ -119,9 +119,9 @@ export const getBodyStyles = ((theme: GrafanaTheme) => {
119119
120120 .react-calendar__tile--active ,
121121 .react-calendar__tile--active : hover {
122- color : ${ theme . palette . white } ;
123- font-weight : ${ theme . typography . weight . semibold } ;
124- background : ${ theme . palette . blue95 } ;
122+ color : ${ theme . v1 . palette . white } ;
123+ font-weight : ${ theme . v1 . typography . weight . semibold } ;
124+ background : ${ theme . v1 . palette . blue95 } ;
125125 box-shadow : none;
126126 border : 0px ;
127127 }
@@ -130,12 +130,12 @@ export const getBodyStyles = ((theme: GrafanaTheme) => {
130130 .react-calendar__tile--rangeStart {
131131 padding : 0 ;
132132 border : 0px ;
133- color : ${ theme . palette . white } ;
134- font-weight : ${ theme . typography . weight . semibold } ;
135- background : ${ theme . palette . blue95 } ;
133+ color : ${ theme . v1 . palette . white } ;
134+ font-weight : ${ theme . v1 . typography . weight . semibold } ;
135+ background : ${ theme . v1 . palette . blue95 } ;
136136
137137 abbr {
138- background-color : ${ theme . palette . blue77 } ;
138+ background-color : ${ theme . v1 . palette . blue77 } ;
139139 border-radius : 100px ;
140140 display : block;
141141 padding-top : 2px ;
0 commit comments