diff --git a/src/assets/img/README.md b/src/assets/img/README.md new file mode 100644 index 0000000..2aac4c2 --- /dev/null +++ b/src/assets/img/README.md @@ -0,0 +1,3 @@ +# Images + +Place any images here that we want optimized by Astro. Otherwise, put pre-optimized images in the `/public` folder. diff --git a/src/assets/img/cursor-auto.png b/src/assets/img/cursor-auto.png deleted file mode 100644 index c95fac3..0000000 Binary files a/src/assets/img/cursor-auto.png and /dev/null differ diff --git a/src/assets/img/cursor-dead.png b/src/assets/img/cursor-dead.png deleted file mode 100644 index f5338e7..0000000 Binary files a/src/assets/img/cursor-dead.png and /dev/null differ diff --git a/src/assets/img/cursor-pointer-clicked.png b/src/assets/img/cursor-pointer-clicked.png deleted file mode 100644 index c99ebc1..0000000 Binary files a/src/assets/img/cursor-pointer-clicked.png and /dev/null differ diff --git a/src/assets/img/cursor-pointer.png b/src/assets/img/cursor-pointer.png deleted file mode 100644 index 8a8f1f3..0000000 Binary files a/src/assets/img/cursor-pointer.png and /dev/null differ diff --git a/src/assets/img/cursor-rock-clicked.png b/src/assets/img/cursor-rock-clicked.png deleted file mode 100644 index 288d921..0000000 Binary files a/src/assets/img/cursor-rock-clicked.png and /dev/null differ diff --git a/src/assets/img/cursor-rock.png b/src/assets/img/cursor-rock.png deleted file mode 100644 index 372ddca..0000000 Binary files a/src/assets/img/cursor-rock.png and /dev/null differ diff --git a/src/assets/img/cursor-text.png b/src/assets/img/cursor-text.png deleted file mode 100644 index 89f3fd0..0000000 Binary files a/src/assets/img/cursor-text.png and /dev/null differ diff --git a/src/assets/svg/cursors/CursorAuto.svg b/src/assets/svg/cursors/CursorAuto.svg new file mode 100644 index 0000000..27124bc --- /dev/null +++ b/src/assets/svg/cursors/CursorAuto.svg @@ -0,0 +1,4 @@ + + + diff --git a/src/assets/svg/cursors/CursorDead.svg b/src/assets/svg/cursors/CursorDead.svg new file mode 100644 index 0000000..a32d7fb --- /dev/null +++ b/src/assets/svg/cursors/CursorDead.svg @@ -0,0 +1,8 @@ + + + + + diff --git a/src/assets/svg/cursors/CursorDeadClicked.svg b/src/assets/svg/cursors/CursorDeadClicked.svg new file mode 100644 index 0000000..7c8bfb4 --- /dev/null +++ b/src/assets/svg/cursors/CursorDeadClicked.svg @@ -0,0 +1,8 @@ + + + + + diff --git a/src/assets/svg/cursors/CursorHorns.svg b/src/assets/svg/cursors/CursorHorns.svg new file mode 100644 index 0000000..13bb4e1 --- /dev/null +++ b/src/assets/svg/cursors/CursorHorns.svg @@ -0,0 +1,6 @@ + + + + diff --git a/src/assets/svg/cursors/CursorHornsClicked.svg b/src/assets/svg/cursors/CursorHornsClicked.svg new file mode 100644 index 0000000..21c51df --- /dev/null +++ b/src/assets/svg/cursors/CursorHornsClicked.svg @@ -0,0 +1,6 @@ + + + + diff --git a/src/assets/svg/cursors/CursorPointer.svg b/src/assets/svg/cursors/CursorPointer.svg new file mode 100644 index 0000000..4dbfb53 --- /dev/null +++ b/src/assets/svg/cursors/CursorPointer.svg @@ -0,0 +1,6 @@ + + + + diff --git a/src/assets/svg/cursors/CursorPointerClicked.svg b/src/assets/svg/cursors/CursorPointerClicked.svg new file mode 100644 index 0000000..0d2bfb7 --- /dev/null +++ b/src/assets/svg/cursors/CursorPointerClicked.svg @@ -0,0 +1,6 @@ + + + + diff --git a/src/assets/svg/cursors/CursorText.svg b/src/assets/svg/cursors/CursorText.svg new file mode 100644 index 0000000..4b16968 --- /dev/null +++ b/src/assets/svg/cursors/CursorText.svg @@ -0,0 +1,4 @@ + + + diff --git a/src/components/Navigation.astro b/src/components/Navigation.astro index 39ac4f0..75670df 100644 --- a/src/components/Navigation.astro +++ b/src/components/Navigation.astro @@ -160,7 +160,7 @@ const {id, items = []} = Astro.props; text-transform: uppercase; letter-spacing: 0.2rem; white-space: nowrap; - /* Required for the `rock` cursor to work. */ + /* Required for the `horns` cursor to work. */ pointer-events: none; } @@ -182,7 +182,7 @@ const {id, items = []} = Astro.props; html[data-current-index='12'] .Item:nth-child(13) .Link, html[data-current-index='13'] .Item:nth-child(14) .Link, html[data-current-index='14'] .Item:nth-child(15) .Link { - cursor: url('../assets/img/cursor-rock.png'), not-allowed; + cursor: url('../assets/svg/cursors/CursorHorns.svg'), not-allowed; color: var(--color-primary); translate: calc(var(--nav-item-shift-x) * -1) 0; } @@ -202,7 +202,7 @@ const {id, items = []} = Astro.props; html[data-current-index='12'] .Item:nth-child(13) .Link:active, html[data-current-index='13'] .Item:nth-child(14) .Link:active, html[data-current-index='14'] .Item:nth-child(15) .Link:active { - cursor: url('../assets/img/cursor-rock-clicked.png'), not-allowed; + cursor: url('../assets/svg/cursors/CursorHornsClicked.svg'), not-allowed; } html[data-current-index='0'] .Item:nth-child(1) .Link::before, diff --git a/src/components/ProjectLogo.astro b/src/components/ProjectLogo.astro index 391955a..6742f60 100644 --- a/src/components/ProjectLogo.astro +++ b/src/components/ProjectLogo.astro @@ -68,7 +68,11 @@ const iconProps = { } div.ProjectLogo { - cursor: url('../assets/img/cursor-dead.png'), not-allowed; + cursor: url('../assets/svg/cursors/CursorDead.svg'), not-allowed; + + &:active { + cursor: url('../assets/svg/cursors/CursorDeadClicked.svg'), not-allowed; + } } .ProjectLogo > [data-icon] { diff --git a/src/sections/Intro.astro b/src/sections/Intro.astro index b504cb2..8d4c265 100644 --- a/src/sections/Intro.astro +++ b/src/sections/Intro.astro @@ -24,7 +24,7 @@ const {id, thumbnail} = Astro.props; Background image photographed by: Curtis Dulmage

-

+

Curtis Dulmage. Front end web developer. Ottawa, Canada. Here are a few of my most recent projects. Please diff --git a/src/styles/global.css b/src/styles/global.css index e2db479..c988c20 100644 --- a/src/styles/global.css +++ b/src/styles/global.css @@ -84,7 +84,7 @@ html { body { font-family: 'Outfit Variable', var(--font-stack-sans-serif); - cursor: url('../assets/img/cursor-auto.png'), auto; + cursor: url('../assets/svg/cursors/CursorAuto.svg'), auto; } /* --- Page load --- */ @@ -290,32 +290,18 @@ code, cite, blockquote, figcaption { - cursor: url('../assets/img/cursor-text.png'), text; + cursor: url('../assets/svg/cursors/CursorText.svg'), text; } a, button { &, & * { - cursor: url('../assets/img/cursor-pointer.png'), pointer; + cursor: url('../assets/svg/cursors/CursorPointer.svg'), pointer; } &:active, &:active * { - cursor: url('../assets/img/cursor-pointer-clicked.png'), pointer; + cursor: url('../assets/svg/cursors/CursorPointerClicked.svg'), pointer; } } - -/* -.preload-cursors b { - cursor: url('../assets/img/cursor-drag-clicked.png'), auto; -} -*/ - -.preload-cursors u { - cursor: url('../assets/img/cursor-pointer-clicked.png'), pointer; -} - -.preload-cursors i { - cursor: url('../assets/img/cursor-rock-clicked.png'), pointer; -}