Skip to content

Commit

Permalink
remove cursor
Browse files Browse the repository at this point in the history
  • Loading branch information
mirdukkkkk committed Aug 19, 2024
1 parent 9628fa8 commit 1796cb3
Show file tree
Hide file tree
Showing 4 changed files with 21 additions and 68 deletions.
8 changes: 0 additions & 8 deletions src/components/Cursor/Cursor.module.css

This file was deleted.

31 changes: 0 additions & 31 deletions src/components/Cursor/Cursor.tsx

This file was deleted.

3 changes: 0 additions & 3 deletions src/components/Windows/Palette/Palette/Palette.tsx
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
import { useContext } from "preact/hooks";
import { PaletteGroup } from "../PaletteGroup/PaletteGroup";
import { PaletteContext } from "../../../../managers/palette";
import { CursorContext } from "../../../../managers/cursor";
import { ColorSelect } from "../ColorSelect/ColorSelect";
import { ColorCreate } from "../ColorCreate/ColorCreate";
import { ColorDelete } from "../ColorDelete/ColorDelete";
Expand All @@ -11,10 +10,8 @@ import styles from "./Palette.module.css";

export function Palette() {
const palette = useContext(PaletteContext)
const cursor = useContext(CursorContext);

palette.load()
cursor.setColor(palette.palette.value.selected)

return (
<div className={styles.palette}>
Expand Down
47 changes: 21 additions & 26 deletions src/pages/Home/index.tsx
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
import { PlaceContext, PlaceManager } from '../../managers/place';
import { PaletteContext, PaletteManager } from '../../managers/palette';
import { CursorContext, CursorManager } from "../../managers/cursor";
import { InfoContext, InfoManager } from '../../managers/info';
import { ProfileContext, ProfileManager } from '../../managers/profile';
import { CooldownContext, CooldownManager } from '../../managers/cooldown';
Expand All @@ -14,7 +13,6 @@ import { ModalContext, ModalManager } from '../../managers/modal';

import { lazy } from 'preact/compat';
import { Modal } from '../../components/Modal/Modal';
import { Cursor } from '../../components/Cursor/Cursor';

const Snow = lazy(() => import("../../components/Snow/Snow").then(r => r.Snow))
const Place = lazy(() => import("../../components/Place/Place").then(r => r.Place))
Expand All @@ -30,30 +28,27 @@ export function Home() {
</SettingsContext.Provider>
<InfoContext.Provider value={InfoManager}>
<ColorPickerContext.Provider value={ColorPickerManager}>
<CursorContext.Provider value={CursorManager}>
<Cursor />
<PlaceContext.Provider value={PlaceManager}>
<OverlayContext.Provider value={OverlayManager}>
<Place />
<NotificationsContext.Provider value={NotificationsManager}>
<TagsContext.Provider value={TagsManager}>
<ModalContext.Provider value={ModalManager}>
<Modal />
<ProfileContext.Provider value={ProfileManager}>
<CoordinatesContext.Provider value={CoordinatesManager}>
<CooldownContext.Provider value={CooldownManager}>
<PaletteContext.Provider value={PaletteManager}>
<TopBar />
</PaletteContext.Provider>
</CooldownContext.Provider>
</CoordinatesContext.Provider>
</ProfileContext.Provider>
</ModalContext.Provider>
</TagsContext.Provider>
</NotificationsContext.Provider>
</OverlayContext.Provider>
</PlaceContext.Provider>
</CursorContext.Provider>
<PlaceContext.Provider value={PlaceManager}>
<OverlayContext.Provider value={OverlayManager}>
<Place />
<NotificationsContext.Provider value={NotificationsManager}>
<TagsContext.Provider value={TagsManager}>
<ModalContext.Provider value={ModalManager}>
<Modal />
<ProfileContext.Provider value={ProfileManager}>
<CoordinatesContext.Provider value={CoordinatesManager}>
<CooldownContext.Provider value={CooldownManager}>
<PaletteContext.Provider value={PaletteManager}>
<TopBar />
</PaletteContext.Provider>
</CooldownContext.Provider>
</CoordinatesContext.Provider>
</ProfileContext.Provider>
</ModalContext.Provider>
</TagsContext.Provider>
</NotificationsContext.Provider>
</OverlayContext.Provider>
</PlaceContext.Provider>
</ColorPickerContext.Provider>
</InfoContext.Provider>
</>
Expand Down

0 comments on commit 1796cb3

Please sign in to comment.