aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--.github/workflows/build.yml141
-rw-r--r--.travis.yml125
-rw-r--r--compiler/.gitignore1
-rw-r--r--compiler/app/Main.hs32
-rw-r--r--compiler/app/ViewerDist.hs39
-rw-r--r--compiler/package.yaml14
-rw-r--r--compiler/src/Caching.hs6
-rw-r--r--compiler/src/Compiler.hs6
-rw-r--r--compiler/src/Input.hs6
-rw-r--r--compiler/src/ItemProcessors.hs1
-rw-r--r--compiler/stack.yaml7
-rw-r--r--compiler/stack.yaml.lock8
-rw-r--r--ldgallery-quickstart.7.md22
-rw-r--r--readme.md4
-rw-r--r--scripts/dev_win_build.cmd5
-rw-r--r--scripts/dev_win_compiler_build.cmd5
-rw-r--r--scripts/dev_win_compiler_compile_example.cmd (renamed from scripts/dev_win_compile_example.cmd)0
-rw-r--r--scripts/dev_win_compiler_help.cmd (renamed from scripts/dev_win_help.cmd)0
-rw-r--r--scripts/dev_win_start_vueui.cmd44
-rw-r--r--scripts/dev_win_viewer_deps_install.cmd22
-rw-r--r--viewer/.browserslistrc7
-rw-r--r--viewer/.prettierrc.js1
-rw-r--r--viewer/ldgallery-viewer.7.md47
-rw-r--r--viewer/package-lock.json14182
-rw-r--r--viewer/package.json62
-rw-r--r--viewer/public/index.html2
-rw-r--r--viewer/readme.md19
-rw-r--r--viewer/src/@types/ItemType.ts19
-rw-r--r--viewer/src/@types/gallery.d.ts185
-rw-r--r--viewer/src/@types/scrollposition.d.ts2
-rw-r--r--viewer/src/@types/splashscreen.d.ts25
-rw-r--r--viewer/src/@types/tag.d.ts40
-rw-r--r--viewer/src/assets/scss/global.scss2
-rw-r--r--viewer/src/components/LdBreadcrumb.vue22
-rw-r--r--viewer/src/components/LdCommand.vue23
-rw-r--r--viewer/src/components/LdCommandSearch.vue6
-rw-r--r--viewer/src/components/LdCommandSort.vue11
-rw-r--r--viewer/src/components/LdGallery.vue12
-rw-r--r--viewer/src/components/LdInformation.vue20
-rw-r--r--viewer/src/components/LdKeyPress.vue2
-rw-r--r--viewer/src/components/LdProposition.vue39
-rw-r--r--viewer/src/components/LdTagInput.vue21
-rw-r--r--viewer/src/components/LdThumbnail.vue13
-rw-r--r--viewer/src/components/LdTitle.vue5
-rw-r--r--viewer/src/components/async/Markdown.vue123
-rw-r--r--viewer/src/components/async/index.ts4
-rw-r--r--viewer/src/components/item_handlers/LdAudioViewer.vue5
-rw-r--r--viewer/src/components/item_handlers/LdDirectoryViewer.vue (renamed from viewer/src/components/item_handlers/LdDirectory.vue)9
-rw-r--r--viewer/src/components/item_handlers/LdDownloadViewer.vue (renamed from viewer/src/components/item_handlers/LdDownload.vue)7
-rw-r--r--viewer/src/components/item_handlers/LdPdfViewer.vue7
-rw-r--r--viewer/src/components/item_handlers/LdPictureViewer.vue (renamed from viewer/src/components/item_handlers/LdPicture.vue)9
-rw-r--r--viewer/src/components/item_handlers/LdPlainTextViewer.vue3
-rw-r--r--viewer/src/components/item_handlers/LdVideoViewer.vue7
-rw-r--r--viewer/src/locales/en.json2
-rw-r--r--viewer/src/main.ts13
-rw-r--r--viewer/src/plugins/index.ts8
-rw-r--r--viewer/src/services/fetchWithCheck.ts7
-rw-r--r--viewer/src/services/indexfactory.ts32
-rw-r--r--viewer/src/services/indexsearch.ts24
-rw-r--r--viewer/src/services/itemComparators.ts13
-rw-r--r--viewer/src/services/ldzoom.ts9
-rw-r--r--viewer/src/services/navigation.ts15
-rw-r--r--viewer/src/store/galleryStore.ts30
-rw-r--r--viewer/src/store/index.ts7
-rw-r--r--viewer/src/store/uiStore.ts34
-rw-r--r--viewer/src/views/GalleryNavigation.vue16
-rw-r--r--viewer/src/views/GallerySearch.vue5
-rw-r--r--viewer/src/views/MainLayout.vue93
-rw-r--r--viewer/src/views/PanelLeft.vue14
-rw-r--r--viewer/src/views/PanelTop.vue2
-rw-r--r--viewer/src/views/SplashScreen.vue68
-rw-r--r--viewer/yarn.lock9737
72 files changed, 10765 insertions, 14793 deletions
diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml
new file mode 100644
index 0000000..190a0df
--- /dev/null
+++ b/.github/workflows/build.yml
@@ -0,0 +1,141 @@
1name: Build
2on: pull_request
3
4jobs:
5 build-viewer:
6 runs-on: ubuntu-20.04
7 steps:
8 - uses: actions/checkout@v2
9 - uses: actions/setup-node@v1
10 with:
11 # Latest version officially tested for Ld
12 node-version: 12.22.2
13 - name: Lint and build Node.js Vue project
14 working-directory: viewer
15 run: |
16 yarn
17 yarn run lint
18 yarn run build
19 - uses: actions/upload-artifact@v2
20 with:
21 name: viewer-dist
22 path: viewer/dist
23
24 # TODO: do not hard-code the CI install path in the output binary
25 # See https://github.com/ldgallery/ldgallery/issues/286
26 build-compiler:
27 strategy:
28 fail-fast: false
29 matrix:
30 os: [ ubuntu-20.04, windows-2019 ]
31 runs-on: ${{ matrix.os }}
32 steps:
33 - uses: actions/checkout@v2
34 - uses: actions/cache@v2
35 with:
36 path: ~/.stack
37 key: compiler-${{ runner.os }}-${{ hashFiles('compiler/stack.yaml') }}
38 - uses: haskell/actions/setup@v1
39 with:
40 ghc-version: 8.10.4
41 enable-stack: true
42 - name: Build Haskell Stack project
43 working-directory: compiler
44 shell: bash
45 run: |
46 STACK_ROOT=~/.stack # make it the same on all platforms
47 stack setup --no-terminal
48 stack build --no-terminal \
49 --flag ldgallery-compiler:portable \
50 --copy-bins \
51 --local-bin-path dist
52 - uses: actions/upload-artifact@v2
53 with:
54 name: compiler-dist-${{ matrix.os }}
55 path: compiler/dist
56
57 # TODO: generate a distro-agnostic Linux package.
58 # See https://github.com/ldgallery/ldgallery/issues/285
59 archive-linux:
60 needs: [ build-viewer, build-compiler ]
61 runs-on: ubuntu-20.04
62 steps:
63 - uses: actions/checkout@v2
64 - name: Bundle ldgallery viewer
65 uses: actions/download-artifact@v2
66 with:
67 name: viewer-dist
68 path: dist/viewer
69 - name: Bundle ldgallery compiler
70 uses: actions/download-artifact@v2
71 with:
72 name: compiler-dist-ubuntu-20.04
73 path: dist
74 - name: Install build dependencies
75 run: |
76 sudo apt-get update -qq
77 sudo apt-get install -y pandoc
78 - name: Build manuals
79 run: |
80 pandoc --standalone --to man ldgallery-quickstart.7.md --output dist/ldgallery-quickstart.7
81 pandoc --standalone --to man compiler/ldgallery.1.md --output dist/ldgallery.1
82 pandoc --standalone --to man viewer/ldgallery-viewer.7.md --output dist/ldgallery-viewer.7
83 cp changelog.md dist/
84 cp license.md dist/
85 - uses: actions/upload-artifact@v2
86 with:
87 name: archive-linux-amd64
88 path: dist
89
90 archive-windows:
91 needs: [ build-viewer, build-compiler ]
92 runs-on: ubuntu-20.04
93 steps:
94 - uses: actions/checkout@v2
95 - uses: actions/cache@v2
96 with:
97 path: ~/downloads
98 key: archive-windows-vendored
99 - name: Bundle ldgallery viewer
100 uses: actions/download-artifact@v2
101 with:
102 name: viewer-dist
103 path: dist/viewer
104 - name: Bundle ldgallery compiler
105 uses: actions/download-artifact@v2
106 with:
107 name: compiler-dist-windows-2019
108