- Per your GDPR rights in Articles 13–15 and 20, we allow you to request any and all data we have stored about you. The only data we have about you personally is your email address and your Public Name, if you decided to set one. All other data (your Dictionary data) is visible and accessible via the Export button under your Dictionary's Settings. Send an email to help@lexicon.ga to request your information.
-
+
+
Request Your Data
+
+ Per your GDPR rights in Articles 13–15 and 20, we allow you to request any and all data we have stored about you. The only data we have about you personally is your email address and your Public Name, if you decided to set one. All other data (your Dictionary data) is visible and accessible via the Export button under your Dictionary's Settings. Send an email to help@lexicon.ga to request your information.
+
+
-
Delete Your Account
-
- Per your GDPR rights in Articles 17, if you wish for your account to be deleted, please contact us at help@lexicon.ga, and we will delete your account and all associated dictionaries and words as quickly as possible. Note that you can delete dictionaries yourself via your Dictionary's Settings.
-
-
- Anything that is deleted from our system is permanently and irretrievably removed from our system and cannot be restored, though search engines or internet archives may retain a cached version of your content (there is nothing we can do about this, and you will need to seek out removal of that information by directly contacting the services that are caching your data).
-
+
+
Delete Your Account
+
+ Per your GDPR rights in Articles 17, if you wish for your account to be deleted, please contact us at help@lexicon.ga, and we will delete your account and all associated dictionaries and words as quickly as possible. Note that you can delete dictionaries yourself via your Dictionary's Settings.
+
+
+ Anything that is deleted from our system is permanently and irretrievably removed from our system and cannot be restored, though search engines or internet archives may retain a cached version of your content (there is nothing we can do about this, and you will need to seek out removal of that information by directly contacting the services that are caching your data).
+
+
`;
accountActionsColumn.innerHTML = accountActionsHTML;
diff --git a/src/js/render/index.js b/src/js/render/index.js
index e2996a7..644dc5f 100644
--- a/src/js/render/index.js
+++ b/src/js/render/index.js
@@ -1,11 +1,13 @@
import { renderDictionaryDetails, renderPartsOfSpeech } from './details';
import { renderWords } from './words';
+import { renderTemplateSelectOptions } from './settings';
export function renderAll() {
renderTheme();
renderCustomCSS();
renderDictionaryDetails();
renderPartsOfSpeech();
+ renderTemplateSelectOptions();
renderWords();
}
diff --git a/src/js/render/settings.js b/src/js/render/settings.js
new file mode 100644
index 0000000..ca66e2f
--- /dev/null
+++ b/src/js/render/settings.js
@@ -0,0 +1,40 @@
+import { setupTemplateSelectOptions } from "../setupListeners/settings";
+
+export function renderTemplateSelectOptions() {
+ const { templates } = window.settings;
+
+ if (typeof templates !== 'undefined') {
+ const templatesOptionsHTML = templates.map((template, index) => {
+ return `' + templatesOptionsHTML;
+ });
+
+ setupTemplateSelectOptions();
+ }
+}
+
+export function showTemplateEditor(show = true) {
+ document.getElementById('templateFields').style.display = show ? '' : 'none';
+ if (show) {
+ document.getElementById('templateTextarea').focus();
+ } else {
+ clearTemplateEditor();
+ }
+}
+
+export function showSelectedTemplate(template, index) {
+ const nameField = document.getElementById('templateNameField');
+ nameField.value = template.name;
+ nameField.setAttribute('template', index.toString());
+ document.getElementById('templateTextarea').value = template.template;
+ showTemplateEditor(true);
+}
+
+export function clearTemplateEditor() {
+ document.getElementById('savedDetailsTemplates').value = '';
+ document.getElementById('templateNameField').value = '';
+ document.getElementById('templateTextarea').value = '';
+}
\ No newline at end of file
diff --git a/src/js/render/words.js b/src/js/render/words.js
index c15f36b..f8ccd27 100644
--- a/src/js/render/words.js
+++ b/src/js/render/words.js
@@ -13,6 +13,7 @@ import { getOpenEditForms, translateOrthography, parseReferences, getWordReferen
import { renderAd } from '../ads';
import { getPublicLink } from '../account/utilities';
import { renderPartsOfSpeech } from './details';
+import { renderTemplateSelectOptions } from './settings';
export function renderWord(savedWord, isPublic) {
const word = highlightSearchTerm({
@@ -186,6 +187,11 @@ export function renderEditForm(wordId = false) {
${wordHasAdvancedFields || window.settings.showAdvanced ? 'Hide' : 'Show'} Advanced Fields