Skip to content

Conversation

@CodeDead
Copy link
Owner

@CodeDead CodeDead commented May 2, 2025

No description provided.

@CodeDead CodeDead added enhancement New feature or improvement dependencies Pull requests that update a dependency file labels May 2, 2025
@CodeDead CodeDead self-assigned this May 2, 2025
@CodeDead CodeDead requested a review from Copilot May 2, 2025 17:43

This comment was marked as outdated.

@CodeDead CodeDead requested a review from Copilot May 2, 2025 17:55
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR removes all analytics and cookie consent functionality from the application. The key changes include:

  • Removal of the ReactGA analytics calls and related cookie consent code in multiple route components.
  • Cleanup of state management and actions related to cookie preferences in reducers and context providers.
  • Simplification of the App component by eliminating cookie banner logic and associated functionality.

Reviewed Changes

Copilot reviewed 14 out of 26 changed files in this pull request and generated no comments.

Show a summary per file
File Description
src/routes/Generate/index.jsx Removed ReactGA import and calls; dropped allowCookies reference from state destructuring.
src/routes/Advisor/index.jsx Removed ReactGA import and calls; updated language assignment to use consistent indexing.
src/routes/About/index.jsx Removed ReactGA import and calls; simplified state usage by removing cookie-related props.
src/reducers/MainReducer/index.js Removed allowCookies case and associated localStorage usage from the reducer.
src/reducers/MainReducer/Actions/index.js Removed action creator for allowCookies.
src/reducers/MainReducer/Actions/actionTypes.js Removed action type constant for allowCookies.
src/contexts/MainContextProvider/index.jsx Removed initialization logic for allowCookies and hasSetCookies from the context.
src/components/App/index.jsx Removed ReactGA integration and cookie banner logic, streamlining the App component.
Files not reviewed (12)
  • .dockerignore: Language not supported
  • Dockerfile: Language not supported
  • package.json: Language not supported
  • src/languages/de_de.json: Language not supported
  • src/languages/en_us.json: Language not supported
  • src/languages/es_es.json: Language not supported
  • src/languages/fr_fr.json: Language not supported
  • src/languages/jp_jp.json: Language not supported
  • src/languages/nl_nl.json: Language not supported
  • src/languages/ru_ru.json: Language not supported
  • src/languages/tr_tr.json: Language not supported
  • src/languages/zh_cn.json: Language not supported
Comments suppressed due to low confidence (4)

src/routes/Generate/index.jsx:36

  • [nitpick] Consider using a more descriptive name than 'state1' (for example, 'mainState') to improve clarity and consistency across components.
const [state1, d1] = useContext(MainContext);

src/reducers/MainReducer/index.js:101

  • [nitpick] After removing cookie analytics features, ensure that any related legacy localStorage usage (like 'localStorage.allowCookies') is fully cleaned up to prevent future confusion.
case SET_ALLOW_COOKIES:

src/components/App/index.jsx:8

  • [nitpick] Confirm that the removal of the ReactGA import and all associated references is aligned with the removal of analytics; update any related documentation accordingly.
import ReactGA from 'react-ga4';

src/contexts/MainContextProvider/index.jsx:30

  • [nitpick] Verify that removed properties (allowCookies and hasSetCookies) are not referenced in other parts of the codebase and that the context state remains clear and consistent.
const initState = { autoUpdate, loading: false, colorOnDark, tips, sortByStrength };

@CodeDead CodeDead merged commit 1eced8d into development May 2, 2025
7 checks passed
@CodeDead CodeDead deleted the feature/remove-analytics branch May 2, 2025 18:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

dependencies Pull requests that update a dependency file enhancement New feature or improvement

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants