diff --git a/.eslintrc b/.eslintrc
new file mode 100644
index 00000000..b72b9895
--- /dev/null
+++ b/.eslintrc
@@ -0,0 +1,20 @@
+{
+ "root": true,
+ "plugins": [
+ "@typescript-eslint"
+ ],
+ "extends": [
+ "eslint:recommended",
+ "plugin:@typescript-eslint/recommended",
+ "plugin:vue/vue3-recommended"
+ ],
+ "parser": "vue-eslint-parser",
+ "parserOptions": {
+ "parser": "@typescript-eslint/parser"
+ },
+ "rules": {
+ "no-undef": "off",
+ "vue/multi-word-component-names": "off",
+ "vue/no-v-html": "off"
+ }
+}
diff --git a/.eslintrc.cjs b/.eslintrc.cjs
deleted file mode 100644
index f67fb027..00000000
--- a/.eslintrc.cjs
+++ /dev/null
@@ -1,50 +0,0 @@
-module.exports = {
- root: true,
-
- env: {
- browser: true,
- },
-
- extends: [
- 'airbnb-base',
- 'plugin:vue/vue3-essential',
- '@vue/eslint-config-typescript'
- ],
- globals: {
- ga: true, // Google Analytics
- cordova: true,
- __statics: true,
- process: true,
- Capacitor: true,
- chrome: true,
- },
-
- // add your custom rules here
- rules: {
- 'no-param-reassign': 'off',
- 'import/first': 'off',
- 'import/named': 'error',
- 'import/namespace': 'error',
- 'import/default': 'error',
- 'import/export': 'error',
- 'import/extensions': 'off',
- 'import/no-unresolved': 'off',
- 'import/no-extraneous-dependencies': 'off',
- 'import/prefer-default-export': 'off',
- 'import/no-mutable-exports': 'off',
- 'prefer-promise-reject-errors': 'off',
- 'no-use-before-define': 'off',
- 'no-return-assign': 'off',
- 'vue/multi-word-component-names': 'off',
- 'no-promise-executor-return': 'off',
- 'vue/no-deprecated-slot-attribute': 'off',
- 'no-throw-literal': 'off',
- 'class-methods-use-this': 'off',
-
- // allow debugger during development only
- 'no-debugger': process.env.NODE_ENV === 'production' ? 'error' : 'off',
- 'max-len': 0,
- 'allow-parens': 'off',
- 'no-plusplus': ['error', { allowForLoopAfterthoughts: true }],
- },
-};
diff --git a/.stylelintrc b/.stylelintrc
new file mode 100644
index 00000000..20a117c1
--- /dev/null
+++ b/.stylelintrc
@@ -0,0 +1,20 @@
+{
+ "extends": ["stylelint-config-standard"],
+ "overrides": [
+ {
+ "files": ["*.scss", "**/*.scss"],
+ "extends": ["stylelint-config-standard-scss"]
+ },
+ {
+ "files": ["*.vue", "**/*.vue"],
+ "extends": [
+ "stylelint-config-standard-scss",
+ "stylelint-config-standard-vue/scss"
+ ]
+ }
+ ],
+ "rules": {
+ "at-rule-no-unknown": null,
+ "no-descending-specificity": null
+ }
+}
diff --git a/cypress.config.cjs b/cypress.config.cjs
index 5757b74c..13c1e355 100644
--- a/cypress.config.cjs
+++ b/cypress.config.cjs
@@ -4,6 +4,7 @@ module.exports = defineConfig({
viewportWidth: 1400,
viewportHeight: 800,
experimentalSourceRewriting: true,
+ chromeWebSecurity: false,
screenshotsFolder: 'tests/cypress/screenshots',
downloadsFolder: 'tests/cypress/downloads',
fixturesFolder: 'tests/cypress/fixtures',
diff --git a/examples/gfl-local.html b/examples/gfl-local.html
index a5bcd7a9..ec4adf50 100644
--- a/examples/gfl-local.html
+++ b/examples/gfl-local.html
@@ -21,9 +21,7 @@
-
-
diff --git a/src/components/LoadingSpinner.vue b/src/components/LoadingSpinner.vue
new file mode 100644
index 00000000..a4f05644
--- /dev/null
+++ b/src/components/LoadingSpinner.vue
@@ -0,0 +1,39 @@
+
+
+
+
+
diff --git a/src/components/Notification.vue b/src/components/MessageBox.vue
similarity index 92%
rename from src/components/Notification.vue
rename to src/components/MessageBox.vue
index ef5d3a73..a691d6fc 100644
--- a/src/components/Notification.vue
+++ b/src/components/MessageBox.vue
@@ -8,7 +8,10 @@
/>
{{ title || message }}
-
+
diff --git a/src/components/TreeView.vue b/src/components/TreeView.vue
index a080caa9..8a0b9622 100644
--- a/src/components/TreeView.vue
+++ b/src/components/TreeView.vue
@@ -1,42 +1,47 @@
-
+
- {{ node.label }}
+
+ {{ node.label }}
+
diff --git a/src/components/annotations/AnnotationIcon.vue b/src/components/annotations/AnnotationIcon.vue
index aa341a30..37199625 100644
--- a/src/components/annotations/AnnotationIcon.vue
+++ b/src/components/annotations/AnnotationIcon.vue
@@ -16,7 +16,3 @@ interface Props {
defineProps
();
-
-
diff --git a/src/components/annotations/AnnotationsList.vue b/src/components/annotations/AnnotationsList.vue
index 44551136..f117f4d2 100644
--- a/src/components/annotations/AnnotationsList.vue
+++ b/src/components/annotations/AnnotationsList.vue
@@ -2,8 +2,8 @@
{} : toggle(annotation)"
>
@@ -22,7 +25,7 @@
diff --git a/src/components/annotations/AnnotationsView.vue b/src/components/annotations/AnnotationsView.vue
index 72c3ff3b..777e3ba2 100644
--- a/src/components/annotations/AnnotationsView.vue
+++ b/src/components/annotations/AnnotationsView.vue
@@ -9,7 +9,7 @@
:toggle="toggle"
:types="types"
/>
-
-
-
diff --git a/src/components/base/BaseButton.vue b/src/components/base/BaseButton.vue
index 59823575..abb040ec 100644
--- a/src/components/base/BaseButton.vue
+++ b/src/components/base/BaseButton.vue
@@ -92,16 +92,31 @@ classes['t-bg-transparent hover:t-bg-gray-300/30 dark:hover:t-bg-gray-600 '
-
diff --git a/src/components/base/BaseCheckbox.vue b/src/components/base/BaseCheckbox.vue
index c38a8d4e..edfe722a 100644
--- a/src/components/base/BaseCheckbox.vue
+++ b/src/components/base/BaseCheckbox.vue
@@ -57,16 +57,24 @@ function getAriaChecked(): AriaChecked {
-
-
-
+
+
+
diff --git a/src/components/base/BaseDialog.vue b/src/components/base/BaseDialog.vue
index afae6ccf..8dbf9413 100644
--- a/src/components/base/BaseDialog.vue
+++ b/src/components/base/BaseDialog.vue
@@ -2,7 +2,7 @@
import Dialog from 'primevue/dialog';
import { useConfigStore } from '@/stores/config';
-const props = withDefaults(defineProps<{
+withDefaults(defineProps<{
modelValue: boolean,
title?: string,
closable?: boolean
@@ -13,13 +13,6 @@ const configStore = useConfigStore();
const emit = defineEmits<{(event: 'update:modelValue', payload: boolean): void;
}>();
-
-function close() {
- emit('update:modelValue', false);
-}
-function open() {
- emit('update:modelValue', true);
-}
diff --git a/src/components/base/BaseDropdown.vue b/src/components/base/BaseDropdown.vue
index c48c2277..23f228fd 100644
--- a/src/components/base/BaseDropdown.vue
+++ b/src/components/base/BaseDropdown.vue
@@ -5,13 +5,12 @@
icon-position="right"
:text="buttonText"
@click="emit('update:modelValue', !modelValue)"
- >
-
+ />
-
+
diff --git a/src/components/base/BaseIcon.vue b/src/components/base/BaseIcon.vue
index cad20299..87bd124b 100644
--- a/src/components/base/BaseIcon.vue
+++ b/src/components/base/BaseIcon.vue
@@ -9,7 +9,7 @@ defineProps();
-
+
diff --git a/src/components/header/TitleBar.vue b/src/components/header/TitleBar.vue
index 8b43bd34..d8307cbe 100644
--- a/src/components/header/TitleBar.vue
+++ b/src/components/header/TitleBar.vue
@@ -2,10 +2,16 @@
-
+
{{ collectionTitle }}
-
+
{{ manifestTitle }}
- {{ labels.item }} {{ item.n }}
+ {{ labels.item }} {{ item.n }}
-
+
TIDO Viewer
@@ -44,7 +56,7 @@ export interface Props {
item: Item
}
-const props = withDefaults(defineProps(), {
+withDefaults(defineProps(), {
item: () => - {}
})
diff --git a/src/components/header/Tools.vue b/src/components/header/ToolBar.vue
similarity index 81%
rename from src/components/header/Tools.vue
rename to src/components/header/ToolBar.vue
index ccc67562..d6c54afb 100644
--- a/src/components/header/Tools.vue
+++ b/src/components/header/ToolBar.vue
@@ -1,7 +1,7 @@
-
-
+
+
@@ -10,7 +10,7 @@
import { computed } from 'vue';
import { useConfigStore } from '@/stores/config';
import SoftwareInfo from '@/components/header/SoftwareInfo.vue';
-import Language from '@/components/header/Language.vue';
+import LanguageSwitch from '@/components/header/LanguageSwitch.vue';
import DarkModeToggle from '@/components/header/DarkModeToggle.vue';
const configStore = useConfigStore();
diff --git a/src/components/metadata/Actor.vue b/src/components/metadata/Actor.vue
index f63e9251..7491ab0a 100644
--- a/src/components/metadata/Actor.vue
+++ b/src/components/metadata/Actor.vue
@@ -1,9 +1,13 @@
-
+
{{ $t(getRole(actorItem)) }}
-
+
@@ -17,7 +21,7 @@ export interface Props {
data: Actor[]
}
-const props = withDefaults(defineProps
(), {
+withDefaults(defineProps(), {
data: () => [],
});
@@ -28,7 +32,3 @@ function getRole(actorItem: Actor) : string {
return role[0];
}
-
-
diff --git a/src/components/metadata/CollectionMetadata.vue b/src/components/metadata/CollectionMetadata.vue
index beda728d..898f8b16 100644
--- a/src/components/metadata/CollectionMetadata.vue
+++ b/src/components/metadata/CollectionMetadata.vue
@@ -1,8 +1,17 @@
-