Skip to content

Commit

Permalink
remove isDesktop
Browse files Browse the repository at this point in the history
  • Loading branch information
codekansas committed Sep 11, 2024
1 parent 176ed62 commit c0af204
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions frontend/src/components/landing/HeroASCIIArt.tsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
import { useCallback, useEffect, useRef, useState } from "react";
import { isDesktop } from "react-device-detect";
import { FaChevronDown } from "react-icons/fa";

import { useWindowSize } from "@/hooks/useWindowSize";
Expand Down Expand Up @@ -100,7 +99,7 @@ const HeroASCIIArt = () => {

// Unset cells in a circular radius around the mouse position
if (mousePosRef.current) {
const radius = isDesktop ? 20 : 10;
const radius = 20;
for (let dy = -radius; dy <= radius; dy++) {
for (let dx = -radius; dx <= radius; dx++) {
if (dx * dx + dy * dy <= radius * radius) {
Expand Down Expand Up @@ -147,7 +146,7 @@ const HeroASCIIArt = () => {
}

// Add a few random cells to introduce some variability
const factor = isDesktop ? 0.025 : 0.05;
const factor = 0.025;
for (let i = 0; i < Math.floor(rows * cols * factor); i++) {
const y = Math.floor(Math.random() * rows);
const x = Math.floor(Math.random() * cols);
Expand Down

0 comments on commit c0af204

Please sign in to comment.