mirror of
https://github.com/Spythere/pojazdownik.git
synced 2026-05-02 21:08:12 +00:00
chore: changed thumbnails & previews source
This commit is contained in:
+1
-1
@@ -6,7 +6,7 @@
|
||||
"scripts": {
|
||||
"dev": "vite",
|
||||
"build": "vue-tsc --noEmit && vite build",
|
||||
"preview": "yarn build && vite preview --port 4174",
|
||||
"preview": "yarn build && vite preview",
|
||||
"type-check": "vue-tsc --noEmit -p tsconfig.app.json --composite false",
|
||||
"lint": "eslint . --ext .vue,.js,.jsx,.cjs,.mjs,.ts,.tsx,.cts,.mts --fix --ignore-path .gitignore",
|
||||
"format": "prettier --write src/"
|
||||
|
||||
@@ -76,7 +76,7 @@
|
||||
<div class="thumbnail-container">
|
||||
<div>{{ stockType }}</div>
|
||||
<img
|
||||
:src="`https://rj.td2.info.pl/dist/img/thumbnails/${stockType}.png`"
|
||||
:src="`https://static.spythere.eu/thumbnails/${stockType}.png`"
|
||||
:title="stockType"
|
||||
style="opacity: 0"
|
||||
@error="(e) => onStockItemError(e, stockType)"
|
||||
|
||||
@@ -21,7 +21,7 @@
|
||||
|
||||
<img
|
||||
draggable="false"
|
||||
:src="`https://rj.td2.info.pl/dist/img/thumbnails/${stock.vehicleRef.type}.png`"
|
||||
:src="`https://static.spythere.eu/thumbnails/${stock.vehicleRef.type}.png`"
|
||||
:alt="stock.vehicleRef.type"
|
||||
:title="stock.vehicleRef.type"
|
||||
@error="stockImageError($event, stock)"
|
||||
|
||||
+5
-17
@@ -8,6 +8,9 @@ export default defineConfig({
|
||||
server: {
|
||||
port: 2138,
|
||||
},
|
||||
preview: {
|
||||
port: 4138,
|
||||
},
|
||||
plugins: [
|
||||
vue(),
|
||||
VitePWA({
|
||||
@@ -25,25 +28,10 @@ export default defineConfig({
|
||||
|
||||
runtimeCaching: [
|
||||
{
|
||||
urlPattern: new RegExp('^https://rj.td2.info.pl/dist/img/thumbnails/*', 'i'),
|
||||
urlPattern: /^https:\/\/.*\.spythere\.eu\/.*/i,
|
||||
handler: 'CacheFirst',
|
||||
options: {
|
||||
cacheName: 'swdr-images-cache',
|
||||
expiration: {
|
||||
maxEntries: 50,
|
||||
maxAgeSeconds: 60 * 60 * 24, // <== 1 day
|
||||
},
|
||||
cacheableResponse: {
|
||||
statuses: [200],
|
||||
},
|
||||
},
|
||||
},
|
||||
|
||||
{
|
||||
urlPattern: new RegExp('^https://stacjownik.spythere.eu/vehicles', 'i'),
|
||||
handler: 'NetworkFirst',
|
||||
options: {
|
||||
cacheName: 'vehicles-cache',
|
||||
cacheName: 'spythere-cache',
|
||||
},
|
||||
},
|
||||
],
|
||||
|
||||
Reference in New Issue
Block a user