Skip to content

Commit

Permalink
fix(sched): run on OS launch
Browse files Browse the repository at this point in the history
  • Loading branch information
YassinEldeeb committed Apr 2, 2022
1 parent 70d875a commit 6f24f0c
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 4 deletions.
1 change: 1 addition & 0 deletions schedular/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@ pub fn start_schedular(exit: Arc<Mutex<bool>>) {

if !skip_update_on_startup {
// Run on OS launch
update_wallpaper(&conf, false).unwrap();

let minutes = get_minutes_left(&conf);
if minutes <= 0 {
Expand Down
8 changes: 4 additions & 4 deletions website/components/Nav.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import { Link } from "./Link";
export const Nav = () => {
const [openDrawer, setOpenDrawer] = useState(false);

const OpenDrawerHandler = () => {
const OpenDrawerHandler = async () => {
setOpenDrawer(!openDrawer);
};

Expand Down Expand Up @@ -47,8 +47,8 @@ export const Nav = () => {
return (
<div
onClick={OpenDrawerHandler}
className={`py-48 flex flex-col lg:hidden w-screen h-screen absolute left-0 top-0 transition duration-200 bg-[#FABE2C] ${
openDrawer ? "translate-x-0" : "translate-x-full"
className={`py-48 flex flex-col lg:hidden w-screen h-screen absolute left-0 top-0 transition duration-200 bg-[#FABE2C] drawer ${
openDrawer ? "drawer-open" : ""
}`}
>
<ul className="grow list-none flex justify-around flex-col">
Expand Down Expand Up @@ -118,7 +118,7 @@ export const Nav = () => {
)}
</div>

{openDrawer && <MobileNavLinks />}
{true && <MobileNavLinks />}

<div className="hidden lg:flex">
<DesktopNavLinks />
Expand Down
9 changes: 9 additions & 0 deletions website/styles/globals.css
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,15 @@ img {
width: 100%;
}

.drawer {
transition: 0.2s all ease-in-out;
transform: translateX(100%);
}

.drawer-open {
transform: translateX(0%);
}

@media screen and (max-width: 1024px) {
.swiper-button-next::after,
.swiper-button-prev::after {
Expand Down

1 comment on commit 6f24f0c

@vercel
Copy link

@vercel vercel bot commented on 6f24f0c Apr 2, 2022

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please sign in to comment.