From d0e7c971d6e3b0c1ab1cdc46273d7ba60b6a43d9 Mon Sep 17 00:00:00 2001 From: RodriiAndino Date: Fri, 27 Sep 2024 11:48:21 -0300 Subject: [PATCH] refactor: update ESLint configuration, improve ProjectsGallery component, and enhance styles - Changed module.exports to export const in .eslintrc.js - Updated ProjectsGallery to use dataset for technology filtering - Improved SVG favicon design - Adjusted CSS styles for better layout and animations - Modified project features in JSON files for clarity - Refined UI text for better readability --- .eslintrc.js | 84 +++++++++---------- public/favicon.svg | 21 ++++- src/components/Projects/ProjectsGallery.jsx | 6 +- .../Projects/styles/projects-gallery-card.css | 45 +++++----- .../Projects/styles/projects-gallery.css | 6 +- src/data/projects_en.json | 2 +- src/data/projects_es.json | 2 +- src/i18n/ui.js | 6 +- 8 files changed, 98 insertions(+), 74 deletions(-) diff --git a/.eslintrc.js b/.eslintrc.js index fe69def..b158ef3 100644 --- a/.eslintrc.js +++ b/.eslintrc.js @@ -1,45 +1,43 @@ -module.exports = { - overrides: [ - { - extends: [ - 'eslint:recommended', - 'plugin:prettier/recommended', - 'plugin:astro/recommended' - ], - files: ['*.astro'], - plugins: ['astro'], - env: { - node: true, - 'astro/astro': true, - es2020: true - }, - parser: 'astro-eslint-parser', - parserOptions: { - parser: '@typescript-eslint/parser', - extraFileExtensions: ['.astro'], - sourceType: 'module' - }, - rules: { - 'astro/no-conflict-set-directives': 'error', - 'astro/no-unused-define-vars-in-style': 'error' - } +export const overrides = [ + { + extends: [ + 'eslint:recommended', + 'plugin:prettier/recommended', + 'plugin:astro/recommended' + ], + files: ['*.astro'], + plugins: ['astro'], + env: { + node: true, + 'astro/astro': true, + es2020: true }, - { - files: ['**/*.astro/*.js', '*.astro/*.js'], - env: { - browser: true, - es2020: true - }, - parserOptions: { - sourceType: 'module' - }, - rules: { - 'prettier/prettier': 'error', - 'astro/known-attributes': 'warn', - 'astro/no-raw-text': 'warn', - 'astro/require-lang': 'warn', - 'astro/sort-attributes': 'warn' - } + parser: 'astro-eslint-parser', + parserOptions: { + parser: '@typescript-eslint/parser', + extraFileExtensions: ['.astro'], + sourceType: 'module' + }, + rules: { + 'astro/no-conflict-set-directives': 'error', + 'astro/no-unused-define-vars-in-style': 'error' + } + }, + { + files: ['**/*.astro/*.js', '*.astro/*.js'], + env: { + browser: true, + es2020: true + }, + parserOptions: { + sourceType: 'module' + }, + rules: { + 'prettier/prettier': 'error', + 'astro/known-attributes': 'warn', + 'astro/no-raw-text': 'warn', + 'astro/require-lang': 'warn', + 'astro/sort-attributes': 'warn' } - ] -} + } +] diff --git a/public/favicon.svg b/public/favicon.svg index f157bd1..2bc8909 100644 --- a/public/favicon.svg +++ b/public/favicon.svg @@ -1,9 +1,24 @@ - - + + + + - + \ No newline at end of file diff --git a/src/components/Projects/ProjectsGallery.jsx b/src/components/Projects/ProjectsGallery.jsx index 3bf0a57..38db483 100644 --- a/src/components/Projects/ProjectsGallery.jsx +++ b/src/components/Projects/ProjectsGallery.jsx @@ -35,7 +35,8 @@ export default function ProjectsGallery({ projects, locale }) { } const handleFilterClick = event => { - const technology = event.target.textContent + const technology = event.currentTarget.dataset.technology + handleFilter(technology) handleShowFilter() } @@ -88,11 +89,14 @@ export default function ProjectsGallery({ projects, locale }) { {uniqueTechnologies.map(technology => (