Skip to content

Commit

Permalink
Remove unused vanilla-cookieconsent (#3535)
Browse files Browse the repository at this point in the history
  • Loading branch information
imnasnainaec authored Jan 24, 2025
1 parent b1db050 commit 6946b24
Show file tree
Hide file tree
Showing 5 changed files with 3 additions and 45 deletions.
25 changes: 0 additions & 25 deletions docs/user_guide/assets/licenses/frontend_licenses.txt
Original file line number Diff line number Diff line change
Expand Up @@ -5254,31 +5254,6 @@ OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.


vanilla-cookieconsent 3.0.1
MIT
MIT License

Copyright (c) 2020-2024 Orest Bida

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.


void-elements 3.1.0
MIT
(The MIT License)
Expand Down
8 changes: 1 addition & 7 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 1 addition & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -81,8 +81,7 @@
"redux-thunk": "^3.1.0",
"ts-key-enum": "^2.0.12",
"uuid": "^9.0.1",
"validator": "^13.11.0",
"vanilla-cookieconsent": "^3.0.1"
"validator": "^13.11.0"
},
"devDependencies": {
"@babel/plugin-proposal-private-property-in-object": "^7.21.11",
Expand Down
10 changes: 1 addition & 9 deletions src/types/Redux/analytics.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
import { PayloadAction, createSlice } from "@reduxjs/toolkit";
import { getUserPreferences } from "vanilla-cookieconsent";

import { StoreActionTypes } from "rootRedux/actions";
import { defaultState } from "types/Redux/analyticsReduxTypes";
Expand All @@ -11,22 +10,15 @@ const analyticsSlice = createSlice({
changePageAction: (state, action) => {
state.currentPage = action.payload;
},
updateConsentAction: (state) => {
state.consent = getUserPreferences().acceptType === "all";
},
},
extraReducers: (builder) =>
builder.addCase(StoreActionTypes.RESET, () => defaultState),
});

const { changePageAction, updateConsentAction } = analyticsSlice.actions;
const { changePageAction } = analyticsSlice.actions;

export default analyticsSlice.reducer;

export function changePage(newPage: string): PayloadAction {
return changePageAction(newPage);
}

export function updateConsent(): PayloadAction {
return updateConsentAction();
}
2 changes: 0 additions & 2 deletions src/types/Redux/analyticsReduxTypes.ts
Original file line number Diff line number Diff line change
@@ -1,9 +1,7 @@
export interface AnalyticsState {
consent: boolean;
currentPage: string;
}

export const defaultState: AnalyticsState = {
consent: false,
currentPage: "",
};

0 comments on commit 6946b24

Please sign in to comment.