1- import type { CSSInterpolation } from "@emotion/css/dist/declarations/src/create-instance" ;
21import { css , type Interpolation , type Theme , useTheme } from "@emotion/react" ;
32import Button from "@mui/material/Button" ;
43import Link from "@mui/material/Link" ;
@@ -15,7 +14,6 @@ import { TerminalIcon } from "components/Icons/TerminalIcon";
1514import { VSCodeIcon } from "components/Icons/VSCodeIcon" ;
1615import { Stack } from "components/Stack/Stack" ;
1716import dayjs from "dayjs" ;
18- import { type ClassName , useClassName } from "hooks/useClassName" ;
1917import {
2018 AppWindowIcon ,
2119 CircleAlertIcon ,
@@ -53,7 +51,6 @@ export const DeploymentBannerView: FC<DeploymentBannerViewProps> = ({
5351 fetchStats,
5452} ) => {
5553 const theme = useTheme ( ) ;
56- const summaryTooltip = useClassName ( classNames . summaryTooltip , [ ] ) ;
5754
5855 const aggregatedMinutes = useMemo ( ( ) => {
5956 if ( ! stats ) {
@@ -128,7 +125,10 @@ export const DeploymentBannerView: FC<DeploymentBannerViewProps> = ({
128125 } }
129126 >
130127 < Tooltip
131- classes = { { tooltip : summaryTooltip } }
128+ classes = { {
129+ tooltip :
130+ "ml-3 mb-1 w-[400px] p-4 text-sm text-content-primary bg-surface-secondary border border-solid border-border pointer-events-none" ,
131+ } }
132132 title = {
133133 healthErrors . length > 0 ? (
134134 < >
@@ -236,10 +236,10 @@ export const DeploymentBannerView: FC<DeploymentBannerViewProps> = ({
236236 < div css = { styles . value } >
237237 < VSCodeIcon
238238 css = { css `
239- & * {
240- fill : currentColor;
241- }
242- `}
239+ & * {
240+ fill : currentColor;
241+ }
242+ `}
243243 />
244244 { typeof stats ?. session_count . vscode === "undefined"
245245 ? "-"
@@ -251,10 +251,10 @@ export const DeploymentBannerView: FC<DeploymentBannerViewProps> = ({
251251 < div css = { styles . value } >
252252 < JetBrainsIcon
253253 css = { css `
254- & * {
255- fill : currentColor;
256- }
257- `}
254+ & * {
255+ fill : currentColor;
256+ }
257+ `}
258258 />
259259 { typeof stats ?. session_count . jetbrains === "undefined"
260260 ? "-"
@@ -303,20 +303,20 @@ export const DeploymentBannerView: FC<DeploymentBannerViewProps> = ({
303303 css = { [
304304 styles . value ,
305305 css `
306- margin : 0 ;
307- padding : 0 8px ;
308- height : unset;
309- min-height : unset;
310- font-size : unset;
311- color : unset;
312- border : 0 ;
313- min-width : unset;
314- font-family : inherit;
306+ margin : 0 ;
307+ padding : 0 8px ;
308+ height : unset;
309+ min-height : unset;
310+ font-size : unset;
311+ color : unset;
312+ border : 0 ;
313+ min-width : unset;
314+ font-family : inherit;
315315
316- & svg {
317- margin-right : 4px ;
318- }
319- `,
316+ & svg {
317+ margin-right : 4px ;
318+ }
319+ `,
320320 ] }
321321 onClick = { ( ) => {
322322 if ( fetchStats ) {
@@ -410,41 +410,27 @@ const getHealthErrors = (health: HealthcheckReport) => {
410410 return warnings ;
411411} ;
412412
413- const classNames = {
414- summaryTooltip : ( css , theme ) => css `
415- ${ theme . typography . body2 as CSSInterpolation }
416-
417- margin : 0 0 4px 12px ;
418- width : 400px ;
419- padding : 16px ;
420- color : ${ theme . palette . text . primary } ;
421- background-color : ${ theme . palette . background . paper } ;
422- border : 1px solid ${ theme . palette . divider } ;
423- pointer-events : none;
424- ` ,
425- } satisfies Record < string , ClassName > ;
426-
427413const styles = {
428414 statusBadge : ( theme ) => css `
429- display : flex;
430- align-items : center;
431- justify-content : center;
432- padding : 0 12px ;
433- height : 100% ;
434- color : ${ theme . experimental . l1 . text } ;
415+ display : flex;
416+ align-items : center;
417+ justify-content : center;
418+ padding : 0 12px ;
419+ height : 100% ;
420+ color : ${ theme . experimental . l1 . text } ;
435421
436- & svg {
437- width : 16px ;
438- height : 16px ;
439- }
440- `,
422+ & svg {
423+ width : 16px ;
424+ height : 16px ;
425+ }
426+ `,
441427 unhealthy : {
442428 backgroundColor : colors . red [ 700 ] ,
443429 } ,
444430 group : css `
445- display : flex;
446- align-items : center;
447- `,
431+ display : flex;
432+ align-items : center;
433+ `,
448434 category : ( theme ) => ( {
449435 marginRight : 16 ,
450436 color : theme . palette . text . primary ,
@@ -455,15 +441,15 @@ const styles = {
455441 color : theme . palette . text . secondary ,
456442 } ) ,
457443 value : css `
458- display : flex;
459- align-items : center;
460- gap : 4px ;
444+ display : flex;
445+ align-items : center;
446+ gap : 4px ;
461447
462- & svg {
463- width : 12px ;
464- height : 12px ;
465- }
466- `,
448+ & svg {
449+ width : 12px ;
450+ height : 12px ;
451+ }
452+ `,
467453 separator : ( theme ) => ( {
468454 color : theme . palette . text . disabled ,
469455 } ) ,
0 commit comments