File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -9,8 +9,9 @@ function App() {
99 < div className = "App" >
1010 < Global
1111 styles = { css `
12- background-color : ${ settings . mainColor } ;
13- color : ${ settings . fontColor } ;
12+ body {
13+ color : ${ settings . fontColor } ;
14+ }
1415 ` }
1516 />
1617 < Desktop />
Load diff This file was deleted.
Original file line number Diff line number Diff line change 1- import styled from "@emotion/styled" ;
2-
31import TopBar from "../TopBar" ;
42import Content from "../Content" ;
53import BottomBar from "../BottomBar" ;
64import useSystemSettings from "../../stores/systemSettingsStore" ;
75
8- interface DesktopProps { }
9-
10- const StyledDesktop = styled . div `
11- height: 100dvh;
12- width: 100dvw;
13- display: grid;
14- grid-template-rows: 42px auto 84px;
15- grid-template-columns: auto;
16- grid-template-areas:
17- "top-bar"
18- "content"
19- "bottom-bar";
20- gap: 10px;
21- ` ;
6+ import { StyledBackground , StyledDesktop } from "./Styled.Desktop" ;
227
23- const StyledBackground = styled . div < { backgroundUrl : string } > `
24- height: 100%;
25- width: 100%;
26- position: absolute;
27- grid-area: none;
28- z-index: -1;
29- background-image: url(${ ( props ) => props . backgroundUrl } );
30- background-size: cover;
31- background-repeat: no-repeat;
32- background-position: center;
33- ` ;
8+ interface DesktopProps { }
349
3510// eslint-disable-next-line no-empty-pattern
3611function Desktop ( { } : DesktopProps ) {
Original file line number Diff line number Diff line change 1+ import styled from "@emotion/styled" ;
2+
3+ export const StyledDesktop = styled . div `
4+ height: 100dvh;
5+ width: 100dvw;
6+ display: grid;
7+ grid-template-rows: 42px auto 84px;
8+ grid-template-columns: auto;
9+ grid-template-areas:
10+ "top-bar"
11+ "content"
12+ "bottom-bar";
13+ gap: 10px;
14+ ` ;
15+
16+ export const StyledBackground = styled . div < { backgroundUrl : string } > `
17+ height: 100%;
18+ width: 100%;
19+ position: absolute;
20+ grid-area: none;
21+ z-index: -1;
22+ background-image: url(${ ( props ) => props . backgroundUrl } );
23+ background-size: cover;
24+ background-repeat: no-repeat;
25+ background-position: center;
26+ ` ;
Load diff This file was deleted.
Load diff This file was deleted.
Original file line number Diff line number Diff line change 1- import { v4 as uuid } from "uuid" ;
2-
31import useDateTime from "../../../hooks/useDateTime" ;
4- import useWindowManagerStore from "../../../stores/windowManagerStore" ;
5- import BorderedApp from "../../BorderedApp" ;
6-
7- import "./ClockMenu.scss" ;
82
9- const windowType = "clock ";
3+ import { StyledClockMenu , StyledTimeContainer } from "./Styled.ClockMenu ";
104
115interface ClockMenuProps { }
126
137// eslint-disable-next-line no-empty-pattern
148function ClockMenu ( { } : ClockMenuProps ) {
15- const winMan = useWindowManagerStore ( ) ;
169 const dateTime = useDateTime ( {
1710 tickFrequency : 1 ,
1811 tickFrequencyUnit : "minute" ,
1912 template : "hh:mm" ,
2013 } ) ;
2114
22- function handleClick ( ) {
23- const id = uuid ( ) ;
24- winMan . addWindow ( windowType , id , {
25- component : BorderedApp ,
26- props : {
27- title : "Calendar" ,
28- initialDimensions : { height : 500 , width : 500 } ,
29- type : windowType ,
30- id : id ,
31- } ,
32- key : id ,
33- } ) ;
34- }
3515 return (
36- < div id = "clock-menu" onClick = { ( ) => handleClick ( ) } >
37- < div id = "clock-menu__time-container" >
16+ < StyledClockMenu id = "clock-menu" >
17+ < StyledTimeContainer id = "clock-menu__time-container" >
3818 < span id = "clock-menu__time" > { dateTime . formatted } </ span >
39- </ div >
40- </ div >
19+ </ StyledTimeContainer >
20+ </ StyledClockMenu >
4121 ) ;
4222}
4323
Original file line number Diff line number Diff line change 1- #clock-menu {
1+ import styled from "@emotion/styled" ;
2+
3+ export const StyledClockMenu = styled . div `
24 grid-area: clock-menu;
35 width: 100%;
46 height: 100%;
1214 border-radius: 50px;
1315 transition: ease 0.2s;
1416 }
17+ ` ;
1518
16- & __time-container {
17- padding : 0 10px ;
18- cursor : default ;
19- }
20- }
19+ export const StyledTimeContainer = styled . div `
20+ padding: 0 10px;
21+ ` ;
You can’t perform that action at this time.
0 commit comments