100 Commits
Author SHA1 Message Date
Mickael 847b389df8 Merge branch 'master' into fix/s3 2025-01-10 16:22:50 +11:00
MickaelK 8ace343b86 fix (s3): better handling of missing size info 2025-01-10 16:20:28 +11:00
Mickael 29db7d6934 fix (#799): s3 - versitygw bug
* fix (s3): bug on versitygw

the plugin would break on versitgw which on some version isn't sending
the size metadata, ending with a null pointer dereference.

I wasn't able to replicate this on my own but the bug report shows:

2025/01/10 04:35:47 http: panic serving 130.194.66.248:54701: runtime error: invalid memory address or nil pointer dereference
goroutine 5590 [running]:
net/http.(*conn).serve.func1()
        /usr/local/go/src/net/http/server.go:1947 +0xbe
panic({0x19c2740?, 0x535ece0?})
        /usr/local/go/src/runtime/panic.go:785 +0x132
github.com/mickael-kerjean/filestash/server/plugin/plg_backend_s3.S3Backend.Ls.func1(0xc000986bd0, 0xe0?)
        /home/server/plugin/plg_backend_s3/index.go:218 +0x18a
github.com/aws/aws-sdk-go/service/s3.(*S3).ListObjectsV2PagesWithContext(0xc0005b01a8, {0x46ae758, 0xc000f187e0}, 0xc0006649a0, 0xc0005d7270, {0x0, 0x0, 0x0})
        /home/vendor/github.com/aws/aws-sdk-go/service/s3/api.go:7654 +0x1ad
github.com/mickael-kerjean/filestash/server/plugin/plg_backend_s3.S3Backend.Ls({0xc0005b0178, 0xc00074cd80, 0xc000f188a0, {0x46ae758, 0xc000f187e0}, 0x32}, {0xc0008810f0?, 0x99?})
        /home/server/plugin/plg_backend_s3/index.go:202 +0x31a
github.com/mickael-kerjean/filestash/filestash-enterprise/plugins/utils.wrapper.Ls({{0x46b77c0, 0xc000f18ff0}, {0x5511fc0, 0x0, 0x0}}, {0xc0008810f0?, 0x165dc9a?})
        /home/filestash-enterprise/plugins/utils/authorisation.go:64 +0x94
github.com/mickael-kerjean/filestash/server/ctrl.FileLs(0xc000001d40, {0x46a8bc8, 0xc000f18810}, 0xc000227680)
        /home/server/ctrl/files.go:136 +0x7a2
github.com/mickael-kerjean/filestash/server/middleware.LoggedInOnly.func1(0xc000001d40?, {0x46a8bc8, 0xc000f18810}, 0x0?)
        /home/server/middleware/session.go:23 +0x2e
github.com/mickael-kerjean/filestash/server/middleware.SessionStart.func1(0xc000001d40, {0x46a8bc8, 0xc000f18810}, 0xc000227680)
        /home/server/middleware/session.go:77 +0x2e7
github.com/mickael-kerjean/filestash/server/middleware.WithPublicAPI.func1(0xc000001d40, {0x46a8bc8, 0xc000f18810}, 0xc000227680)
        /home/server/middleware/http.go:115 +0x3a7
github.com/mickael-kerjean/filestash/server/middleware.SecureOrigin.func1(0xc000001d40, {0x46a8bc8, 0xc000f18810}, 0xc000227680)
        /home/server/middleware/http.go:99 +0x4a2
github.com/mickael-kerjean/filestash/server/middleware.SecureHeaders.func1(0xc000001d40, {0x46a8bc8, 0xc000f18810}, 0xc000227680)
        /home/server/middleware/http.go:79 +0x28c
github.com/mickael-kerjean/filestash/server/middleware.ApiHeaders.func1(0xc000001d40, {0x46a8bc8, 0xc000f18810}, 0xc000227680)
        /home/server/middleware/http.go:22 +0x29d
github.com/mickael-kerjean/filestash/server.Build.NewMiddlewareChain.func18({0x46a8cb8, 0xc000904000}, 0xc000227680)
        /home/server/middleware/index.go:28 +0x17b
net/http.HandlerFunc.ServeHTTP(0xc000227540?, {0x46a8cb8?, 0xc000904000?}, 0x52f069?)
        /usr/local/go/src/net/http/server.go:2220 +0x29
github.com/gorilla/mux.(*Router).ServeHTTP(0xc000000480, {0x46a8cb8, 0xc000904000}, 0xc000227400)
        /home/vendor/github.com/gorilla/mux/mux.go:212 +0x1e2
net/http.serverHandler.ServeHTTP({0xc000c41d40?}, {0x46a8cb8?, 0xc000904000?}, 0x6?)
        /usr/local/go/src/net/http/server.go:3210 +0x8e
net/http.(*conn).serve(0xc00059d950, {0x46ae758, 0xc000832240})
        /usr/local/go/src/net/http/server.go:2092 +0x5d0
created by net/http.(*Server).Serve in goroutine 135
        /usr/local/go/src/net/http/server.go:3360 +0x485

* fix (s3): versitygw issue

* fix (uint64): size
2025-01-10 16:13:33 +11:00
MickaelK e74159f526 fix (uint64): size 2025-01-10 16:12:06 +11:00
MickaelK 4b0de2454a fix (s3): versitygw issue 2025-01-10 16:05:19 +11:00
Mickael 0d8ea12517 fix (s3): bug on versitygw (#798)
the plugin would break on versitgw which on some version isn't sending
the size metadata, ending with a null pointer dereference.

I wasn't able to replicate this on my own but the bug report shows:

2025/01/10 04:35:47 http: panic serving 130.194.66.248:54701: runtime error: invalid memory address or nil pointer dereference
goroutine 5590 [running]:
net/http.(*conn).serve.func1()
        /usr/local/go/src/net/http/server.go:1947 +0xbe
panic({0x19c2740?, 0x535ece0?})
        /usr/local/go/src/runtime/panic.go:785 +0x132
github.com/mickael-kerjean/filestash/server/plugin/plg_backend_s3.S3Backend.Ls.func1(0xc000986bd0, 0xe0?)
        /home/server/plugin/plg_backend_s3/index.go:218 +0x18a
github.com/aws/aws-sdk-go/service/s3.(*S3).ListObjectsV2PagesWithContext(0xc0005b01a8, {0x46ae758, 0xc000f187e0}, 0xc0006649a0, 0xc0005d7270, {0x0, 0x0, 0x0})
        /home/vendor/github.com/aws/aws-sdk-go/service/s3/api.go:7654 +0x1ad
github.com/mickael-kerjean/filestash/server/plugin/plg_backend_s3.S3Backend.Ls({0xc0005b0178, 0xc00074cd80, 0xc000f188a0, {0x46ae758, 0xc000f187e0}, 0x32}, {0xc0008810f0?, 0x99?})
        /home/server/plugin/plg_backend_s3/index.go:202 +0x31a
github.com/mickael-kerjean/filestash/filestash-enterprise/plugins/utils.wrapper.Ls({{0x46b77c0, 0xc000f18ff0}, {0x5511fc0, 0x0, 0x0}}, {0xc0008810f0?, 0x165dc9a?})
        /home/filestash-enterprise/plugins/utils/authorisation.go:64 +0x94
github.com/mickael-kerjean/filestash/server/ctrl.FileLs(0xc000001d40, {0x46a8bc8, 0xc000f18810}, 0xc000227680)
        /home/server/ctrl/files.go:136 +0x7a2
github.com/mickael-kerjean/filestash/server/middleware.LoggedInOnly.func1(0xc000001d40?, {0x46a8bc8, 0xc000f18810}, 0x0?)
        /home/server/middleware/session.go:23 +0x2e
github.com/mickael-kerjean/filestash/server/middleware.SessionStart.func1(0xc000001d40, {0x46a8bc8, 0xc000f18810}, 0xc000227680)
        /home/server/middleware/session.go:77 +0x2e7
github.com/mickael-kerjean/filestash/server/middleware.WithPublicAPI.func1(0xc000001d40, {0x46a8bc8, 0xc000f18810}, 0xc000227680)
        /home/server/middleware/http.go:115 +0x3a7
github.com/mickael-kerjean/filestash/server/middleware.SecureOrigin.func1(0xc000001d40, {0x46a8bc8, 0xc000f18810}, 0xc000227680)
        /home/server/middleware/http.go:99 +0x4a2
github.com/mickael-kerjean/filestash/server/middleware.SecureHeaders.func1(0xc000001d40, {0x46a8bc8, 0xc000f18810}, 0xc000227680)
        /home/server/middleware/http.go:79 +0x28c
github.com/mickael-kerjean/filestash/server/middleware.ApiHeaders.func1(0xc000001d40, {0x46a8bc8, 0xc000f18810}, 0xc000227680)
        /home/server/middleware/http.go:22 +0x29d
github.com/mickael-kerjean/filestash/server.Build.NewMiddlewareChain.func18({0x46a8cb8, 0xc000904000}, 0xc000227680)
        /home/server/middleware/index.go:28 +0x17b
net/http.HandlerFunc.ServeHTTP(0xc000227540?, {0x46a8cb8?, 0xc000904000?}, 0x52f069?)
        /usr/local/go/src/net/http/server.go:2220 +0x29
github.com/gorilla/mux.(*Router).ServeHTTP(0xc000000480, {0x46a8cb8, 0xc000904000}, 0xc000227400)
        /home/vendor/github.com/gorilla/mux/mux.go:212 +0x1e2
net/http.serverHandler.ServeHTTP({0xc000c41d40?}, {0x46a8cb8?, 0xc000904000?}, 0x6?)
        /usr/local/go/src/net/http/server.go:3210 +0x8e
net/http.(*conn).serve(0xc00059d950, {0x46ae758, 0xc000832240})
        /usr/local/go/src/net/http/server.go:2092 +0x5d0
created by net/http.(*Server).Serve in goroutine 135
        /usr/local/go/src/net/http/server.go:3360 +0x485
2025-01-10 15:52:28 +11:00
MickaelK 5c2c5e2dca fix (s3): bug on versitygw
the plugin would break on versitgw which on some version isn't sending
the size metadata, ending with a null pointer dereference.

I wasn't able to replicate this on my own but the bug report shows:

2025/01/10 04:35:47 http: panic serving 130.194.66.248:54701: runtime error: invalid memory address or nil pointer dereference
goroutine 5590 [running]:
net/http.(*conn).serve.func1()
        /usr/local/go/src/net/http/server.go:1947 +0xbe
panic({0x19c2740?, 0x535ece0?})
        /usr/local/go/src/runtime/panic.go:785 +0x132
github.com/mickael-kerjean/filestash/server/plugin/plg_backend_s3.S3Backend.Ls.func1(0xc000986bd0, 0xe0?)
        /home/server/plugin/plg_backend_s3/index.go:218 +0x18a
github.com/aws/aws-sdk-go/service/s3.(*S3).ListObjectsV2PagesWithContext(0xc0005b01a8, {0x46ae758, 0xc000f187e0}, 0xc0006649a0, 0xc0005d7270, {0x0, 0x0, 0x0})
        /home/vendor/github.com/aws/aws-sdk-go/service/s3/api.go:7654 +0x1ad
github.com/mickael-kerjean/filestash/server/plugin/plg_backend_s3.S3Backend.Ls({0xc0005b0178, 0xc00074cd80, 0xc000f188a0, {0x46ae758, 0xc000f187e0}, 0x32}, {0xc0008810f0?, 0x99?})
        /home/server/plugin/plg_backend_s3/index.go:202 +0x31a
github.com/mickael-kerjean/filestash/filestash-enterprise/plugins/utils.wrapper.Ls({{0x46b77c0, 0xc000f18ff0}, {0x5511fc0, 0x0, 0x0}}, {0xc0008810f0?, 0x165dc9a?})
        /home/filestash-enterprise/plugins/utils/authorisation.go:64 +0x94
github.com/mickael-kerjean/filestash/server/ctrl.FileLs(0xc000001d40, {0x46a8bc8, 0xc000f18810}, 0xc000227680)
        /home/server/ctrl/files.go:136 +0x7a2
github.com/mickael-kerjean/filestash/server/middleware.LoggedInOnly.func1(0xc000001d40?, {0x46a8bc8, 0xc000f18810}, 0x0?)
        /home/server/middleware/session.go:23 +0x2e
github.com/mickael-kerjean/filestash/server/middleware.SessionStart.func1(0xc000001d40, {0x46a8bc8, 0xc000f18810}, 0xc000227680)
        /home/server/middleware/session.go:77 +0x2e7
github.com/mickael-kerjean/filestash/server/middleware.WithPublicAPI.func1(0xc000001d40, {0x46a8bc8, 0xc000f18810}, 0xc000227680)
        /home/server/middleware/http.go:115 +0x3a7
github.com/mickael-kerjean/filestash/server/middleware.SecureOrigin.func1(0xc000001d40, {0x46a8bc8, 0xc000f18810}, 0xc000227680)
        /home/server/middleware/http.go:99 +0x4a2
github.com/mickael-kerjean/filestash/server/middleware.SecureHeaders.func1(0xc000001d40, {0x46a8bc8, 0xc000f18810}, 0xc000227680)
        /home/server/middleware/http.go:79 +0x28c
github.com/mickael-kerjean/filestash/server/middleware.ApiHeaders.func1(0xc000001d40, {0x46a8bc8, 0xc000f18810}, 0xc000227680)
        /home/server/middleware/http.go:22 +0x29d
github.com/mickael-kerjean/filestash/server.Build.NewMiddlewareChain.func18({0x46a8cb8, 0xc000904000}, 0xc000227680)
        /home/server/middleware/index.go:28 +0x17b
net/http.HandlerFunc.ServeHTTP(0xc000227540?, {0x46a8cb8?, 0xc000904000?}, 0x52f069?)
        /usr/local/go/src/net/http/server.go:2220 +0x29
github.com/gorilla/mux.(*Router).ServeHTTP(0xc000000480, {0x46a8cb8, 0xc000904000}, 0xc000227400)
        /home/vendor/github.com/gorilla/mux/mux.go:212 +0x1e2
net/http.serverHandler.ServeHTTP({0xc000c41d40?}, {0x46a8cb8?, 0xc000904000?}, 0x6?)
        /usr/local/go/src/net/http/server.go:3210 +0x8e
net/http.(*conn).serve(0xc00059d950, {0x46ae758, 0xc000832240})
        /usr/local/go/src/net/http/server.go:2092 +0x5d0
created by net/http.(*Server).Serve in goroutine 135
        /usr/local/go/src/net/http/server.go:3360 +0x485
2025-01-10 15:49:53 +11:00
MickaelK 41923ef500 fix (firefox): input sizing across browser
before this, there was some annoying discrepencies with the way Firefox
would render input compared to chrome. Unfortunatly we couldn't find a
better way than fixing the height to fix it up
2025-01-06 15:46:22 +11:00
MickaelK 8d27075ddb chore (3d): refactor 3d viewer 2025-01-05 15:10:09 +11:00
MickaelK 24f3150c53 feature (svg): svg opener via threejs 2025-01-03 01:48:41 +11:00
MickaelK 2ac816dc9c feature (table): table opener app 2025-01-02 19:44:02 +11:00
MickaelK 2b872a07be fix (docker-compose): #790 #791 2024-12-31 05:49:36 +11:00
MickaelK 23c5bf53f5 fix (virtual): virtual scroll in fileviewer
there was an issue from a page viewer virtual scroll enabled typing a
search that would return a small amount of result with a scrollbar.

in those condition the scroll event would still be called with the
previous incorrect data
2024-12-29 19:55:36 +11:00
MickaelK 0a2f3c6b3c fix (menubar): filename regression 2024-12-29 19:14:01 +11:00
MickaelK 4baeae2f59 feature (errorpage): ux for error page 2024-12-29 18:44:01 +11:00
MickaelK b19d7bba24 fix (nav): newtab navigation using ctrl key 2024-12-29 01:23:40 +11:00
MickaelK 67f651e418 chore (editor): css vim 2024-12-29 01:02:36 +11:00
MickaelK c4ee866db6 fix (menubar): difference chrome / firefox 2024-12-28 18:03:46 +11:00
MickaelK 3315130fb1 feature (dbf): dbf file opener 2024-12-28 02:42:29 +11:00
MickaelK 607b7a00ad chore (refactoring): cleanup 2024-12-28 02:21:34 +11:00
MickaelK 95ddc2e27f feature (error): nicer error page 2024-12-24 18:23:29 +11:00
MickaelK 866cda05c3 feature (shp): native shp handling 2024-12-24 18:10:22 +11:00
MickaelK c1aead5916 chore (3dviewer): improve UX for layer selection 2024-12-24 00:22:41 +11:00
MickaelK 71b14e6eaf feature (3d): embed 3d viewer anywhere
This contains a bunch of things packaged in 1:

1) UI improvements for the 3D viewer to support all sort of file types
   and create a nice rendering in a clean way with all sort of options

2) enable people to use Filestash as an SDK so we can embed the 3d viewer
   elsewhere
2024-12-23 18:50:23 +11:00
MickaelK 43d07e8555 chore (type): error type / handling 2024-12-23 06:47:20 +11:00
MickaelK 1aa1a7d5e9 fix (deadlock): thumbnail issue in plg_image_c 2024-12-22 03:06:48 +11:00
MickaelK 5eab8c68ba fix (canary): download button with shared links 2024-12-19 14:40:16 +11:00
MickaelK 4ef1c2bbd8 chore (gomod): #780 2024-12-18 09:27:46 +11:00
MickaelK 8422268a21 fix (#771): search from text editor 2024-12-14 20:49:26 +11:00
MickaelK f268d27967 feature (postMessage): iframe RPC via postMessage 2024-12-14 00:46:50 +11:00
MickaelK b787403a1e chore (sidebar): display rules 2024-12-13 10:11:01 +11:00
MickaelK 44f4cc74f0 fix (wopi): wopi handler fileID 2024-12-13 00:42:00 +11:00
MickaelK 6eb3ed8b40 chore (login): forward URL params in login 2024-12-12 22:31:37 +11:00
MickaelK e0de8261a6 fix (wopi): path handling 2024-12-12 17:52:20 +11:00
Mickael 1d06c785bc fix (wopi): wopi config (#785) 2024-12-12 16:07:34 +11:00
MickaelK b3a44918e1 feature (office): enable wopi office docs 2024-12-12 10:58:38 +11:00
MickaelK 023b0189fe fix (share): filename issue in shared link 2024-12-10 21:55:09 +11:00
MickaelK 003c4a9737 fix (filename): weird filenames
I've tried a lot of things to make the URL look nice but somehow there's
always a bug to handle all possible scenarios. Eg:

/test/test#test%20with a: space.txt

maybe one day, we can make the urls looks nicer but this would need a
significant revamp, until that happen, that will do.

tip: don't understimate the work it takes to do it nicely, I've tried to
do this 2 times quickly and everytime there's a edge case that make
things not working and breaking other odd stuff
2024-12-10 21:51:17 +11:00
MickaelK 5df9fad3b4 chore (downloader): error handling 2024-12-10 17:04:22 +11:00
MickaelK aa3f76ebb0 fix (about): incorrect plugin list 2024-12-10 09:46:53 +11:00
MickaelK 9895842d90 fix (admin): checkbox position issue 2024-12-10 00:42:32 +11:00
MickaelK d6bc0d55f1 chore (banner): auth middleware banners 2024-12-10 00:42:06 +11:00
MickaelK 5a3feaeab4 fix (upload): canary upload edge case 2024-12-09 13:03:18 +11:00
MickaelK 4b8926a3da fix (favicon): canary favicon
before this commit, we've had issues with overrides which wouldn't set
the favicon properly
2024-12-09 13:01:12 +11:00
MickaelK 7828d0c315 feature (template): additional templating funcs 2024-12-09 12:04:00 +11:00
MickaelK afd2f2566e fix (jenkins): broken build after refactoring 2024-12-09 09:03:05 +11:00
MickaelK 60b83e36a9 fix (linter): canary linter 2024-12-06 18:32:58 +11:00
MickaelK 799ba868c3 feature (plg_authenticate_local): local source of user 2024-12-06 18:28:33 +11:00
MickaelK bc68bf50fe fix (audit): canary audit engine compat 2024-12-06 12:43:01 +11:00
MickaelK e35158c259 chore (plg_authentication_simple): banner update 2024-12-06 07:21:41 +11:00
MickaelK b317a50609 chore (plg_authenticate_simple): banner dashboard 2024-12-06 07:07:40 +11:00
MickaelK 9f8a4f515f Merge branch 'master' of ssh://github.com/mickael-kerjean/filestash 2024-12-06 00:13:50 +11:00
MickaelK e06b2329a1 fix (editor): blank screen with binary data 2024-12-06 00:13:24 +11:00
MickaelK 609fd308c1 fix (caching): cache invalidation issue
until this, if a user tries to connect to the same backend with a
different path, the frontend would flicker as we'd get things from the
wrong cache key
2024-12-05 23:30:58 +11:00
MickaelK d6b618988d fix (caching): cache invalidation issue
until this, if a user tries to connect to the same backend with a
different path, the frontend would flicker as we'd get things from the
wrong cache key
2024-12-05 23:30:18 +11:00
MickaelK d56cdd3cc3 chore (plg_authenticate_simple): additional debug info 2024-12-05 22:46:59 +11:00
MickaelK 8d70b7e26c feature (plg_authenticate_simple): auth facade with a gui 2024-12-05 22:34:01 +11:00
MickaelK edea084ace feature (admin): enable banner in form 2024-12-05 17:54:20 +11:00
MickaelK b1a35c7f54 fix (css): css rule issue 2024-12-05 17:51:47 +11:00
MickaelK 72b4acbad8 fix (typo): html bug 2024-12-04 22:58:39 +11:00
MickaelK c7dcf29f11 fix (public): login redirection 2024-12-04 17:08:51 +11:00
MickaelK 97a82423a4 fix (tus): edge case on tus protocol 2024-12-04 16:05:28 +11:00
MickaelK 387631bf7e fix (upload): validation issue in upload task 2024-12-04 13:09:17 +11:00
MickaelK ddb1e6fd53 feature (upload): canary - upload design 2024-12-04 13:07:17 +11:00
MickaelK 50b99a005c fix (upload): canary upload fab button 2024-12-04 10:34:34 +11:00
MickaelK dba8bc000a fix (cloudflare): cloudflare cache issue 2024-12-03 23:35:15 +11:00
MickaelK 1b47b613b6 fix (cloudflare): cloudflare chunked issue 2024-12-03 23:14:13 +11:00
MickaelK f2e006b545 chore (about): css in about page 2024-12-03 12:16:15 +11:00
MickaelK 5cd126d762 feature (form): enable markdown links 2024-12-03 11:56:31 +11:00
MickaelK 4a2d4d62ed fix (translation): missing danish translation 2024-12-03 10:58:19 +11:00
MickaelK 009cf9656e feature (translation): new translation key 2024-12-03 10:25:39 +11:00
MickaelK e77093ad8b feature (admin): about page design 2024-12-03 02:19:23 +11:00
MickaelK f4007544b9 fix (form): read only form fields
we used to have the readonly attribute but somehow it's not supported by
all fields, eg: select. As such when something is read only we disable
the field
2024-12-03 01:53:49 +11:00
MickaelK ab8e9f7641 fix (upload): smart file list refresh
before this commit, the issue was:

1. whenever uploading a large folder, any upload would trigger the ls change, resulting in a lot of unecessary dom
changes which in case the user is browsing through a lot of picture would trigger some flickering in the thumbnail.

2. large upload would be slow as virtual.before would call change
   detection and refresh the list of files within the folder constantly

now by avoiding mutations we effectively just rerender when something we
are interested changes: aka something change in the current folder the
user is in
2024-12-02 22:02:12 +11:00
MickaelK 177961c62d fix (plg_video_thumbnail): error when backend doesn't support fileseek 2024-12-02 17:24:03 +11:00
MickaelK 0dfa9b3335 fix (panic): concurrent map access
this fix a panic that can be replicated using the video thumbnail
plugin, opening up a page with a lot of videos. Under the hood, the
server would call ffmpeg that would make a bunch of HTTP range requests
that would call the cache concurrently, hence causing the panic
2024-12-02 16:28:38 +11:00
MickaelK ff67ed97ed feature (thumbnail): video thumbnail plugin
up until now, the stance was to refuse video thumbnail because it's too
slow but really many people don't seem to care that much about it and
keep insisting to have it.

With this solution, it's not in the base build but it gives an
option for those people to make it happen
2024-12-02 15:39:25 +11:00
MickaelK c343338983 fix (upload): canary file uploader 2024-12-02 12:11:29 +11:00
MickaelK a72925c5d8 fix (build): ts fix 2024-11-30 15:08:35 +11:00
MickaelK 487895abee fix (canary): retry mechanism on upload 2024-11-29 22:46:26 +11:00
MickaelK ac9d1a4980 feature (tus): chunked upload via TUS
instead of inventing a new protocol for chunked upload that can be
resumed, we might as well use something that already exists like TUS.

As such we removed our custom implementation to favor that standard
2024-11-29 15:04:34 +11:00
MickaelK c556a404f7 fix (chunked): progress calculation
issue:
1. create a 2MB file: dd if=/dev/zero of=testfile bs=1024 count=2048
2. size chunk to 1MB

what we see: progress up to 50%, then stop and jump to 100%
2024-11-28 02:25:02 +11:00
MickaelK 016afe6923 fix (checkbox): checkbox in dark mode 2024-11-28 02:12:18 +11:00
MickaelK 5e420cf5f3 fix (config): save config when disk is full
before this, if the user had a full disk, there wouldn't be any error
reported back whenever editing something in the admin
console as file.Close() would return nil ....

The only way to go around it is to wait for the sync to be done.
2024-11-28 02:03:35 +11:00
MickaelK 8303ae54f0 fix (fatal): edge case causing fatal issue
I've seen the case where someone ran out of disk with a corrupted config
file which gave the following fatal error in the login screen:

Uncaught TypeError: Cannot read properties of null (reading 'map')

with a stacktrace pointing to: ctrl_form.js:22:63

this fixes the assumptions on the config file so as to not trigger the
fatal error but head to the nicer error cases where it would say:

Internal Error: There is nothing here.

which is much nicer for end users than "Cannot read properties of null"
2024-11-28 01:50:43 +11:00
MickaelK 2914443789 chore (linter): linter and code verif 2024-11-28 01:46:53 +11:00
MickaelK 0dea98d4bd fix (chunked): chunked upload connection close
only close connection when using chunked upload. This is key if you must
use something like to work with Cloudflare
2024-11-28 01:32:41 +11:00
MickaelK de5e2d9583 fix (cloudflare): proxy with size limit
Cloudflare does limit the size of file upload by an arbitrary number. We
can go around that by using chunked upload but somehow that wasn't
enough, to circumvent that issue, we make it clear to the proxy it
should close the connection and we hope the problem we go away
2024-11-27 23:45:39 +11:00
MickaelK 63f1c780fc Merge branch 'master' of ssh://github.com/mickael-kerjean/filestash 2024-11-27 00:54:59 +11:00
MickaelK 87a1987219 feature (upload): support for chunked uploads 2024-11-27 00:52:29 +11:00
Mickael c7d48c9226 fix (webpack): webpack deps issue - #772
* fix (webpack): another webpack issue

* fix (webpack): uglify plugin is broken
2024-11-20 16:59:59 +11:00
MickaelK 12b27e3416 fix (webpack): uglify plugin is broken 2024-11-20 16:58:24 +11:00
MickaelK 0da11bf8cd fix (webpack): another webpack issue 2024-11-20 16:55:04 +11:00
MickaelK 69529b2bec fix (lint): linter and ts check 2024-11-20 16:06:43 +11:00
MickaelK 8aa33143d3 fix (sharelink): default path in shared link
regression where shared link are created without a path. This was
reported by a customer
2024-11-20 15:48:48 +11:00
MickaelK 66cc697b25 feature (tag): tag feature behind canary flag 2024-11-19 14:54:38 +11:00
MickaelK 92673f9ae3 feature (sidebar): sidebar toggle button 2024-11-18 23:41:35 +11:00
MickaelK 8c3c28ffbc fix (image): image viewer loader display 2024-11-18 18:49:40 +11:00
MickaelK 291d989ef9 fix (sidebar): better config on default
on a mobile like screen, the sidebar wouldn't be hidden entirely, it
would still show the border artifact. We need to make sure the default
is to be of class hidden to prevent such artefact
2024-11-18 17:35:48 +11:00
MickaelK 5181b1b49b fix (audio): audio context bug
whenever reading an audio file, quitting and coming back, the audio
context under wavesurfer.backend.ac would show a currentTime that is not
actually reset properly. Closing or trying several trick didn't fix the
issue, hence this approach which is quite dirty but work.

Overall wavesurfer has some weird tendencies, this is just one more hack
within the audio player
2024-11-18 16:19:17 +11:00