Skip to content

Commit

Permalink
remove all references to gvl_translations
Browse files Browse the repository at this point in the history
  • Loading branch information
gilluminate committed Jul 17, 2024
1 parent 3cb8368 commit f7fa793
Show file tree
Hide file tree
Showing 12 changed files with 8 additions and 1,082 deletions.
3 changes: 1 addition & 2 deletions clients/fides-js/__tests__/__fixtures__/mock_experience.json
Original file line number Diff line number Diff line change
Expand Up @@ -133,6 +133,5 @@
]
}
],
"gvl": {},
"gvl_translations": {}
"gvl": {}
}
4 changes: 2 additions & 2 deletions clients/fides-js/__tests__/lib/i18n/i18n-utils.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -370,7 +370,7 @@ describe("i18n-utils", () => {
const [, loadedMessagesEn] = mockI18n.load.mock.calls[0];
const [, loadedMessagesEs] = mockI18n.load.mock.calls[1];

// Confirm that the English gvl_translations are loaded
// Confirm that the English GVL translations are loaded
const expectedMessagesEn: Record<string, RegExp> = {
// Example purposes
"exp.tcf.purposes.1.name": /^Store and\/or access/,
Expand Down Expand Up @@ -401,7 +401,7 @@ describe("i18n-utils", () => {
expect(loadedMessagesEn[id]).toMatch(regex);
});

// Confirm that the Spanish gvl_translations are loaded
// Confirm that the Spanish GVL translations are loaded
const expectedMessagesEs: Record<string, RegExp> = {
// Example purposes
"exp.tcf.purposes.1.name": /^Almacenar la información/,
Expand Down
2 changes: 0 additions & 2 deletions clients/fides-js/src/lib/consent-types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@ import type { Fides, FidesOptions } from "../docs";
import type { GPPFieldMapping, GPPSettings } from "./gpp/types";
import type {
GVLJson,
GVLTranslations,
TCFFeatureRecord,
TCFFeatureSave,
TCFPurposeConsentRecord,
Expand Down Expand Up @@ -414,7 +413,6 @@ export type PrivacyExperience = {
*/
experience_config?: ExperienceConfig; // NOTE: uses our client-side ExperienceConfig type
gvl?: GVLJson; // NOTE: uses our client-side GVLJson type
gvl_translations?: GVLTranslations;
meta?: ExperienceMeta;
available_locales?: string[];
};
Expand Down
2 changes: 1 addition & 1 deletion clients/fides-js/src/lib/i18n/i18n-utils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -146,7 +146,7 @@ export function extractDefaultLocaleFromExperience(
}

/**
* Helper function to extract all the translated messages from the "gvl_translations"
* Helper function to extract all the translated messages from the GVL translations
* API response. Returns an object that maps locales -> messages, e.g.
* {
* "en": {
Expand Down
1 change: 0 additions & 1 deletion clients/fides-js/src/services/api.ts
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,6 @@ export const fetchExperience = async (
// that have no relevant experiences
const experience: PrivacyExperience = (body.items && body.items[0]) ?? {};
debugLog(debug, "Recieved experience response from Fides API", experience);
delete experience.gvl_translations;
return experience;
} catch (e) {
debugLog(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -179,8 +179,7 @@
]
}
],
"gvl": {},
"gvl_translations": {}
"gvl": {}
}
],
"total": 1,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -107,8 +107,7 @@
]
}
],
"gvl": {},
"gvl_translations": {}
"gvl": {}
}
],
"total": 1,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -130,7 +130,6 @@
}
],
"gvl": {},
"gvl_translations": {},
"meta": {
"version_hash": null,
"accept_all_fides_string": null,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -179,8 +179,7 @@
]
}
],
"gvl": {},
"gvl_translations": {}
"gvl": {}
}
],
"total": 1,
Expand Down
1,064 changes: 0 additions & 1,064 deletions clients/privacy-center/cypress/fixtures/consent/experience_tcf.json

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
Expand Up @@ -191,8 +191,7 @@
]
}
],
"gvl": {},
"gvl_translations": {}
"gvl": {}
},
"geolocation": {
"country": "US",
Expand Down
1 change: 0 additions & 1 deletion src/fides/api/models/privacy_experience.py
Original file line number Diff line number Diff line change
Expand Up @@ -535,7 +535,6 @@ def show_banner(self) -> bool:
tcf_system_consents: List = []
tcf_system_legitimate_interests: List = []
gvl: Optional[Dict] = {}
gvl_translations: Optional[Dict] = {}
# TCF Developer-Friendly Meta added at runtime as the result of build_tc_data_for_mobile
meta: Dict = {}

Expand Down

0 comments on commit f7fa793

Please sign in to comment.