v0.13.0
- new - PWA supported. - fix - touch scroll not working when scroll on $SlideViewer.
This commit is contained in:
parent
473ae64295
commit
396b67a9b3
1
dist/assets/index-C_mg4_Pk.js
vendored
Normal file
1
dist/assets/index-C_mg4_Pk.js
vendored
Normal file
File diff suppressed because one or more lines are too long
1
dist/assets/index-DUv7nhbW.js
vendored
1
dist/assets/index-DUv7nhbW.js
vendored
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
7
dist/index.html
vendored
7
dist/index.html
vendored
@ -2,7 +2,8 @@
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta charset="UTF-8" />
|
||||
<!-- <link rel="icon" type="image/svg+xml" href="/vite.svg" /> -->
|
||||
<link rel="manifest" href="/statics/manifest.json" />
|
||||
<link rel="icon" type="image/svg+xml" href="/statics/danbooru-viewer-icon.png" />
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
||||
<title>Danbooru Viewer</title>
|
||||
<script type="module" src="https://unpkg.com/ionicons@7.1.0/dist/ionicons/ionicons.esm.js"></script>
|
||||
@ -16,8 +17,8 @@
|
||||
|
||||
gtag('config', 'G-59HBGP98WR');
|
||||
</script>
|
||||
<script type="module" crossorigin src="/assets/index-DUv7nhbW.js"></script>
|
||||
<link rel="stylesheet" crossorigin href="/assets/index-Bmz9OSnh.css">
|
||||
<script type="module" crossorigin src="/assets/index-C_mg4_Pk.js"></script>
|
||||
<link rel="stylesheet" crossorigin href="/assets/index-g15FC_9F.css">
|
||||
</head>
|
||||
<body>
|
||||
</body>
|
||||
|
BIN
dist/statics/danbooru-viewer-app-icon@2x.png
vendored
Normal file
BIN
dist/statics/danbooru-viewer-app-icon@2x.png
vendored
Normal file
Binary file not shown.
After Width: | Height: | Size: 3.3 KiB |
BIN
dist/statics/danbooru-viewer-icon.png
vendored
Normal file
BIN
dist/statics/danbooru-viewer-icon.png
vendored
Normal file
Binary file not shown.
After Width: | Height: | Size: 1.1 KiB |
27
dist/statics/manifest.json
vendored
Normal file
27
dist/statics/manifest.json
vendored
Normal file
@ -0,0 +1,27 @@
|
||||
{
|
||||
"lang": "en",
|
||||
"name": "Danbooru Viewer",
|
||||
"theme_color": "#1E1E2C",
|
||||
"background_color": "#1E1E2C",
|
||||
"short_name": "Danbooru Viewer",
|
||||
"description": "Danbooru images viewer, modern style user interface.",
|
||||
"start_url": "/",
|
||||
"dir": "ltr",
|
||||
"orientation": "any",
|
||||
"display": "standalone",
|
||||
"categories": [
|
||||
"photo"
|
||||
],
|
||||
"icons": [
|
||||
{
|
||||
"src": "/statics/danbooru-viewer-icon.png",
|
||||
"sizes": "128x128",
|
||||
"type": "image/png"
|
||||
},
|
||||
{
|
||||
"src": "/statics/danbooru-viewer-app-icon@2x.png",
|
||||
"sizes": "512x512",
|
||||
"type": "image/png"
|
||||
}
|
||||
]
|
||||
}
|
@ -2,7 +2,8 @@
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta charset="UTF-8" />
|
||||
<!-- <link rel="icon" type="image/svg+xml" href="/vite.svg" /> -->
|
||||
<link rel="manifest" href="/statics/manifest.json" />
|
||||
<link rel="icon" type="image/svg+xml" href="/statics/danbooru-viewer-icon.png" />
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
||||
<title>Danbooru Viewer</title>
|
||||
<link rel="stylesheet" href="/index.scss">
|
||||
|
@ -2,7 +2,7 @@
|
||||
"name": "danbooru-viewer",
|
||||
"module": "index.ts",
|
||||
"type": "module",
|
||||
"version": "0.12.1",
|
||||
"version": "0.13.0",
|
||||
"scripts": {
|
||||
"dev": "bun x vite",
|
||||
"build": "bun x vite build",
|
||||
|
BIN
public/statics/danbooru-viewer-app-icon@2x.png
Normal file
BIN
public/statics/danbooru-viewer-app-icon@2x.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 3.3 KiB |
BIN
public/statics/danbooru-viewer-icon.png
Normal file
BIN
public/statics/danbooru-viewer-icon.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 1.1 KiB |
27
public/statics/manifest.json
Normal file
27
public/statics/manifest.json
Normal file
@ -0,0 +1,27 @@
|
||||
{
|
||||
"lang": "en",
|
||||
"name": "Danbooru Viewer",
|
||||
"theme_color": "#1E1E2C",
|
||||
"background_color": "#1E1E2C",
|
||||
"short_name": "Danbooru Viewer",
|
||||
"description": "Danbooru images viewer, modern style user interface.",
|
||||
"start_url": "/",
|
||||
"dir": "ltr",
|
||||
"orientation": "any",
|
||||
"display": "standalone",
|
||||
"categories": [
|
||||
"photo"
|
||||
],
|
||||
"icons": [
|
||||
{
|
||||
"src": "/statics/danbooru-viewer-icon.png",
|
||||
"sizes": "128x128",
|
||||
"type": "image/png"
|
||||
},
|
||||
{
|
||||
"src": "/statics/danbooru-viewer-app-icon@2x.png",
|
||||
"sizes": "512x512",
|
||||
"type": "image/png"
|
||||
}
|
||||
]
|
||||
}
|
@ -74,12 +74,15 @@ const app = new Elysia()
|
||||
return data
|
||||
})
|
||||
})
|
||||
.get('/statics/*', (res => {
|
||||
return Bun.file(`./dist/${res.path}`)
|
||||
}))
|
||||
.listen(3030);
|
||||
console.log('Start listening: 3030')
|
||||
export type Server = typeof app;
|
||||
|
||||
function og(property: string, content: string) {
|
||||
return `<meta property=${property} content="${content}">`
|
||||
function og(property: string, content: string | undefined) {
|
||||
return `<meta property=${property} content="${content ?? ''}">`
|
||||
}
|
||||
|
||||
export function digitalUnit(bytes: number) {
|
||||
|
@ -1,4 +1,4 @@
|
||||
import { $Container, $Element, $Node, $Pointer, $PointerManager, type $ContainerContentType, type $ContainerEventMap, type $EventMap } from "elexis";
|
||||
import { $Container, $Element, $Node, $Pointer, $PointerDirection, $PointerManager, type $ContainerContentType, type $ContainerEventMap, type $EventMap } from "elexis";
|
||||
|
||||
export class $SlideViewer extends $Container<HTMLElement, $SlideViewerEventMap> {
|
||||
pointers = new $PointerManager(this);
|
||||
@ -28,6 +28,7 @@ export class $SlideViewer extends $Container<HTMLElement, $SlideViewerEventMap>
|
||||
containerStartLeft = this.$container.offsetLeft;
|
||||
})
|
||||
this.pointers.on('move', ($pointer, e) => {
|
||||
if ($pointer.direction !== $PointerDirection.Horizontal) return;
|
||||
e.preventDefault();
|
||||
containerLeft = containerStartLeft + $pointer.move_x;
|
||||
if (containerLeft > containerStartLeft && this.slideList.at(0)?.slideId() === this.slideId) return;
|
||||
|
@ -12,7 +12,7 @@
|
||||
margin: 1rem;
|
||||
position: relative;
|
||||
transition: all 0.3s ease;
|
||||
touch-action: none;
|
||||
touch-action: pan-y;
|
||||
|
||||
@media (max-width: 800px) {
|
||||
width: 100%;
|
||||
|
Loading…
Reference in New Issue
Block a user