diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 71163bd..eac5daf 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -9,20 +9,15 @@ jobs: build: name: Build runs-on: ubuntu-latest - steps: - uses: actions/checkout@v4 - uses: oven-sh/setup-bun@v1 - - name: Install dependencies run: bun install - - name: Build run: bun run build - - name: Install Firebase CLI run: bun install -g firebase-tools - - name: Deploy to Firebase env: FIREBASE_TOKEN: ${{ secrets.FIREBASE_TOKEN }} diff --git a/README.md b/README.md index 6cdf96d..4846f46 100644 --- a/README.md +++ b/README.md @@ -3,7 +3,8 @@ ![Uptime Badge](https://uptime.donado.co/api/badge/4/uptime/24) ![Uptime Badge](https://uptime.donado.co/api/badge/4/ping/24) -Screenshot 2024-05-05 at 00 52 13 +Screenshot 2024-05-08 at 05 42 01 +Screenshot 2024-05-08 at 05 42 12 ## ¿Cómo contribuir? @@ -294,3 +295,4 @@ Agrega la nueva palabra directamente en el archivo `src/data.json`, asegurate de ## Agradecimientos - Andres Urquina: Autor del icono [Ilustración Bailarina - Carnaval de Barranquilla, Colombia.](https://www.flickr.com/photos/andresurquina/16246891029) + Andres Urquina: Autor del icono [Ilustración Bailarina - Carnaval de Barranquilla, Colombia.](https://www.flickr.com/photos/andresurquina/16246891029) diff --git a/src/App.tsx b/src/App.tsx index c11f65f..fc099b7 100644 --- a/src/App.tsx +++ b/src/App.tsx @@ -36,7 +36,7 @@ const App = function App() { const emptyResults = results.length === 0; return ( -
+
diff --git a/src/components/LazyLoadingSearchResults.tsx b/src/components/LazyLoadingSearchResults.tsx index e8d34f9..cc1bbc0 100644 --- a/src/components/LazyLoadingSearchResults.tsx +++ b/src/components/LazyLoadingSearchResults.tsx @@ -1,4 +1,4 @@ -import { Suspense, useEffect, useState } from 'react'; +import { Suspense, startTransition, useEffect, useState } from 'react'; import WordCard from './WordCard'; @@ -24,7 +24,7 @@ export default function LazyLoadingSearchResults({ firstResults.length + lazyLoaded.length !== results.length || (results.length > CHUNK_SIZE && lazyLoaded.length === 0) ) { - setTimeout(() => { + startTransition(() => { setLazyLoaded( results .slice(CHUNK_SIZE, results.length) @@ -32,7 +32,7 @@ export default function LazyLoadingSearchResults({ )), ); - }, 100); + }); } }, [results, currentWord, firstResults, lazyLoaded]); diff --git a/src/components/SearchBar.tsx b/src/components/SearchBar.tsx index b0e06b0..9712312 100644 --- a/src/components/SearchBar.tsx +++ b/src/components/SearchBar.tsx @@ -31,7 +31,7 @@ function Input({ onSearch, word }: { onSearch: (value: string) => void; word: st void; word: st placeholder="Buscar palabra" value={word} /> -
+
diff --git a/src/components/WordCard.tsx b/src/components/WordCard.tsx index be7f31b..dbf06b8 100644 --- a/src/components/WordCard.tsx +++ b/src/components/WordCard.tsx @@ -25,10 +25,10 @@ export default function WordCard({ word, currentWord }: Props) { ); return ( -
+
{synonyms.length > 0 && ( -
Sin. {highlightText(synonyms, 'px-2')}
+
Sin. {highlightText(synonyms)}
)} {highlightText(word.text, 'h-full text-3xl')}