-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* updated dependencies * WIP * router * api and pages * search page WIP * slots * various tweaks * storybook * model migration - first pass * v-model * EntityMonitor fixes * $navigation and $set * beforeUnmount, eventbus methods * removed .native * icon * fixes after revision of all pages * User page to use vuelidate * replaced vee-validate with vuelidate * issue viewer page fixes and refactoring * various tweaks and fixes * ts errors fixes WIP * typescript cleanup * removed old main file * bundle size tweaks * vitest * fixed eslint errors * update readme and makefile * reverse order of css loaded * remove errors * Update HistogramSlider.vue * add change listener to FilterRange * remove custom slider * default number formatting --------- Co-authored-by: Daniele Guido <[email protected]>
- Loading branch information
1 parent
4b06cd1
commit 17d9d8b
Showing
269 changed files
with
21,204 additions
and
61,692 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,10 +1,10 @@ | ||
VUE_APP_TYPEKIT_ID="clh1ecw" | ||
VUE_APP_MIDDLELAYER_API="http://localhost:3030" | ||
VUE_APP_MIDDLELAYER_MEDIA_PATH="/media" | ||
VUE_APP_MIDDLELAYER_API_PATH="/" | ||
VUE_APP_MIDDLELAYER_API_SOCKET_PATH="/socket.io/" | ||
VUE_APP_TAWK_TO_SITE_ID= | ||
VUE_APP_BASE_URL="https://impresso-project.ch" | ||
VUE_APP_MAINTENANCE= | ||
VUE_APP_GIT_REPO="https://github.com/impresso/impresso-frontend" | ||
VUE_APP_MIDDLE_LAYER_GIT_REPO="https://github.com/impresso/impresso-middle-layer" | ||
VITE_TYPEKIT_ID="clh1ecw" | ||
VITE_MIDDLELAYER_API="http://localhost:3030" | ||
VITE_MIDDLELAYER_MEDIA_PATH="/media" | ||
VITE_MIDDLELAYER_API_PATH="/" | ||
VITE_MIDDLELAYER_API_SOCKET_PATH="/socket.io/" | ||
VITE_TAWK_TO_SITE_ID= | ||
VITE_BASE_URL="https://impresso-project.ch" | ||
VITE_MAINTENANCE= | ||
VITE_GIT_REPO="https://github.com/impresso/impresso-frontend" | ||
VITE_MIDDLE_LAYER_GIT_REPO="https://github.com/impresso/impresso-middle-layer" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
VUE_APP_MIDDLELAYER_API="http://localhost:3030" | ||
VUE_APP_MIDDLELAYER_API_PATH="/" | ||
VUE_APP_MIDDLELAYER_API_SOCKET_PATH="/socket.io" | ||
VUE_APP_USE_PROXY_MIDDLEWARE=true | ||
VITE_MIDDLELAYER_API="http://localhost:3030" | ||
VITE_MIDDLELAYER_API_PATH="/" | ||
VITE_MIDDLELAYER_API_SOCKET_PATH="/socket.io" | ||
VITE_USE_PROXY_MIDDLEWARE=true |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
VUE_APP_MIDDLELAYER_API="" | ||
VUE_APP_MIDDLELAYER_MEDIA_PATH="/api/media" | ||
VUE_APP_MIDDLELAYER_API_PATH="/api" | ||
VUE_APP_MIDDLELAYER_API_SOCKET_PATH="/api/socket.io/" | ||
VUE_APP_TAWK_TO_SITE_ID="5c49872f51410568a1081bed" | ||
VUE_APP_GA_TRACKING_ID="UA-115750203-1" | ||
VITE_MIDDLELAYER_API="" | ||
VITE_MIDDLELAYER_MEDIA_PATH="/api/media" | ||
VITE_MIDDLELAYER_API_PATH="/api" | ||
VITE_MIDDLELAYER_API_SOCKET_PATH="/api/socket.io/" | ||
VITE_TAWK_TO_SITE_ID="5c49872f51410568a1081bed" | ||
VITE_GA_TRACKING_ID="UA-115750203-1" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,26 @@ | ||
/* eslint-env node */ | ||
require('@rushstack/eslint-patch/modern-module-resolution') | ||
|
||
module.exports = { | ||
extends: ['eslint:recommended', 'plugin:@typescript-eslint/recommended'], | ||
parser: '@typescript-eslint/parser', | ||
plugins: ['@typescript-eslint'], | ||
root: true, | ||
}; | ||
extends: [ | ||
'plugin:vue/vue3-essential', | ||
'eslint:recommended', | ||
'@vue/eslint-config-typescript', | ||
'@vue/eslint-config-prettier/skip-formatting', | ||
'plugin:storybook/recommended' | ||
], | ||
overrides: [ | ||
{ | ||
files: ['cypress/e2e/**/*.{cy,spec}.{js,ts,jsx,tsx}', 'cypress/support/**/*.{js,ts,jsx,tsx}'], | ||
extends: ['plugin:cypress/recommended'] | ||
} | ||
], | ||
parserOptions: { | ||
ecmaVersion: 'latest' | ||
}, | ||
rules: { | ||
'vue/multi-word-component-names': ['warn'], | ||
'vue/no-v-text-v-html-on-component': ['warn'] | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,8 @@ | ||
{ | ||
"printWidth": 100, | ||
"tabWidth": 2, | ||
"useTabs": false, | ||
"$schema": "https://json.schemastore.org/prettierrc", | ||
"semi": false, | ||
"tabWidth": 2, | ||
"singleQuote": true, | ||
"trailingComma": "all" | ||
"printWidth": 100, | ||
"trailingComma": "none" | ||
} |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
import type { StorybookConfig } from '@storybook/vue3-vite' | ||
|
||
const config: StorybookConfig = { | ||
stories: ['../src/**/*.mdx', '../src/**/*.stories.@(js|jsx|mjs|ts|tsx)'], | ||
addons: [ | ||
'@storybook/addon-links', | ||
'@storybook/addon-essentials', | ||
'@chromatic-com/storybook', | ||
'@storybook/addon-interactions' | ||
], | ||
framework: { | ||
name: '@storybook/vue3-vite', | ||
options: {} | ||
}, | ||
env: (config) => ({ | ||
...config, | ||
// use rest transport in storybook to make mocking easier | ||
VITE_API_TRANSPORT: 'rest', | ||
VITE_MIDDLELAYER_API_BASE_URL: '/api' | ||
}) | ||
} | ||
export default config |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,49 @@ | ||
import { http, HttpResponse } from 'msw'; | ||
|
||
const getYearFacetHandler = http.get('/api/search-facets/search/year', () => { | ||
const numBuckets = 200 | ||
return HttpResponse.json({ | ||
type: 'year', | ||
numBuckets, | ||
buckets: Array.from({ length: numBuckets }, (_, i) => { | ||
const c = Math.floor(Math.random() * 10000) | ||
|
||
return { | ||
count: c, | ||
val: String(1800 + i), | ||
uid: String(1800 + i), | ||
item: { | ||
y: 1800 + i, | ||
refs: { | ||
c: c, | ||
a: c, | ||
} | ||
} | ||
} | ||
}) | ||
}); | ||
}) | ||
|
||
const getEntity = http.get('/api/entities/*', () => { | ||
return HttpResponse.json({}) | ||
}) | ||
|
||
const getMe = http.get('/api/me', () => { | ||
return HttpResponse.json({ | ||
firstname: 'John', | ||
lastname: 'Doe', | ||
email: '[email protected]', | ||
uid: '123', | ||
username: 'johndoe', | ||
isActive: true, | ||
isStaff: false, | ||
emailAccepted: false, | ||
}) | ||
}) | ||
|
||
|
||
export const handlers = { | ||
getYearFacetHandler, | ||
getEntity, | ||
getMe, | ||
} |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,51 @@ | ||
import type { Preview } from '@storybook/vue3' | ||
import { setup } from "@storybook/vue3" | ||
import { initialize, mswLoader } from 'msw-storybook-addon' | ||
import globalComponents from '../src/plugins/globalComponents' | ||
import { newI18n } from '../src/plugins/i18n' | ||
import pinia from '../src/plugins/pinia' | ||
import { handlers as mswHandlers } from './mswHandlers' | ||
|
||
import 'dripicons/webfont/webfont.css' | ||
import 'impresso-theme/dist/css/bootpresso.css' | ||
import '../src/assets/legacy/bootstrap-vue.css' | ||
|
||
/* | ||
* Initializes MSW | ||
* See https://github.com/mswjs/msw-storybook-addon#configuring-msw | ||
* to learn how to customize it | ||
*/ | ||
const worker = initialize({ | ||
onUnhandledRequest: ({ url, method }) => { | ||
const pathname = new URL(url).pathname | ||
if (pathname.startsWith('/api/')) { | ||
throw new Error(`Please add a request handler for ${method} ${pathname}`) | ||
} | ||
}, | ||
}) | ||
|
||
// it won't load the handlers without this call. May be a bug | ||
worker.use(...[]) | ||
|
||
setup(app => { | ||
app.use(pinia) | ||
app.use(newI18n()) | ||
app.use(globalComponents) | ||
}) | ||
|
||
const preview: Preview = { | ||
parameters: { | ||
controls: { | ||
matchers: { | ||
color: /(background|color)$/i, | ||
date: /Date$/i | ||
} | ||
}, | ||
msw: { | ||
handlers: mswHandlers, | ||
}, | ||
}, | ||
loaders: [mswLoader], | ||
} | ||
|
||
export default preview |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
{ | ||
"jest.enable": false, | ||
"editor.formatOnSave": true, | ||
"editor.defaultFormatter": "esbenp.prettier-vscode" | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
import { defineConfig } from 'cypress' | ||
|
||
export default defineConfig({ | ||
e2e: { | ||
specPattern: 'cypress/e2e/**/*.{cy,spec}.{js,jsx,ts,tsx}', | ||
baseUrl: 'http://localhost:4173' | ||
} | ||
}) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
/// <reference types="vite/client" /> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.