Commit Graph

807 Commits

Author SHA1 Message Date
Bobby Wibowo
446cacea7e
Merge branch 'ids-cache' into safe.fiery.me 2018-12-04 18:59:47 +07:00
Bobby Wibowo
07b4ef8fc2
Updates
Added a new config entry named "cacheFileIdentifiers". More info in config.sample.js file.

Improved some descriptions in config.sample.js file.

Added some CSS animations wherever applicable.

Bumped v1 version string.
2018-12-04 18:58:53 +07:00
Bobby Wibowo
a17cfb83a2
Enable ids caching by default 2018-12-03 16:32:26 +07:00
Bobby Wibowo
6af52341c9
Init ids-cache branch 2018-12-03 16:18:52 +07:00
Bobby Wibowo
6f03726b9d
Updated package.json 2018-12-03 14:24:10 +07:00
Bobby Wibowo
b6bd833110
Replace graphicsmagick with sharp 2018-12-03 14:20:13 +07:00
Pascal Temel
fa8ef06764 remove npm from package.json 2018-11-30 23:01:58 +01:00
Pascal Temel
05c17f2dc9 replace graphicsmagick with sharp 2018-11-30 22:58:42 +01:00
Bobby Wibowo
6543a87b11
Updates
Reworked unique name generator to prevent the same unique identifier from being used if it was already used with a different extension (e.i. If a file named aBcD.jpg already exists, then files such as aBcD.png or aBcD.txt may not exist).
This is mainly to deal with the fact that thumbnails are only being saved as PNG, so if the same unique name is being used by multiple image/video extensions, then only one of them will have the proper thumbnail.
If you already have existing files with matching unique name but varying extensions, unfortunately you can only deal with them manually for now (either allocating new unique names or deleting them altogether).

Added a new config option to filter files with no extension.

Files with no extensions will no longer have their original name appended to the allocated random name (e.i. A file named "textfile" used to become something like "aBcDtextfile", where "aBcD" was the allocated random name. Now it will only just become "aBcD").
In relation to that, utils.extname() function will now always return blank string if the file name does not seem to have any extension.
Though files such as '.DS_Store' (basically anything that starts with a dot) will still be accepted.
Examples:
.hiddenfile => .hiddenfile
.hiddenfile.sh => .sh
.hiddenfile.001 => .hiddenfile.001
.hiddenfile.sh.001 => .sh.001

Simplified error messages of /api/upload/finishchunks.

Most, if not all, of the error responses for /api/upload* will now have HTTP status code 400 (bad request) instead of 200 (ok).
I plan to generalize this for the other API routes in the future.

Updated home.js to properly handle formatted error message when the response's status code is not 200 (ok).

Bumped v1 version string (due to home.js).
2018-11-29 00:52:12 +07:00
Bobby Wibowo
6e160fa039
Added PrivateBin to footer links
Also updated fontello to include its icon
2018-11-24 20:58:33 +07:00
Bobby Wibowo
6149f46831
Updated package.json 2018-11-24 16:03:12 +07:00
Bobby Wibowo
4463e8de71
Updated .gitignore
Remove trailing-slash from dir ignores.
This will allow replacing said dirs with symlinks.
2018-11-24 15:33:05 +07:00
Bobby Wibowo
6af1f6f490
Removed chokidar resolution
I added the resolution since an issue was reported by Snyk.io.
But I recently noticed that it prevents installation on node 10.x.
I haven't checked whether the resolution is still necessary though.

Also removed .vscode settings.
I plan to add a cleaner way for this later.
2018-11-24 15:18:23 +07:00
Bobby Wibowo
86de83211e
Merge branch 'master' into safe.fiery.me 2018-11-23 04:39:04 +07:00
Kana
ee6e9875db
Merge pull request #165 from calvinc64/patch-1
Add https://vortex.64i.de/ to the list
2018-11-21 15:38:02 -03:00
Kana
4e2eb60613
Merge pull request #167 from hyperdefined/master
URL Change
2018-11-21 15:37:49 -03:00
Kana
cca2ec5ecf
Merge branch 'master' into patch-1 2018-11-21 15:37:25 -03:00
Kana
1ccc45c6ec
Merge pull request #164 from AZATEJ/patch-2
Add "criminals.host" to README
2018-11-21 15:36:19 -03:00
hyperdefined
029736fe72
my url changed 2018-11-21 09:28:01 -05:00
hyperdefined
0dd87f204f
Merge pull request #2 from WeebDev/master
updated
2018-11-21 09:27:22 -05:00
Bobby Wibowo
37ef743e8f
Merge branch 'master' into safe.fiery.me 2018-11-18 02:32:17 +07:00
Bobby Wibowo
dc7214cb38
Merge branch 'account-manager' into safe.fiery.me 2018-11-18 02:22:30 +07:00
Calvin_c64
b3ec39dbe8
Update README.md 2018-11-04 00:01:14 +01:00
Calvin_c64
40fa3bd5df
Update README.md 2018-11-03 23:58:49 +01:00
TRASHER
a1d5e43961
Update README.md 2018-10-24 11:29:12 +02:00
Bobby Wibowo
de87c37d66
Allows render.js to append version string to renders
Thus if you need to update an existing render, you just need to update v1 version string, and the new version string will be appended to the render's URL, thus forcing browser to refresh.

Also updated javelin_1.png since apparently I missed a tiny bit of watermark.
2018-10-23 18:02:19 +07:00
Bobby Wibowo
1517778ed7
Improve 2018-10-19 22:10:30 +07:00
Bobby Wibowo
e5417f0aa2
Restore modals to their original size after done with viewing originals 2018-10-19 21:57:15 +07:00
Bobby Wibowo
a3c9eeb3c5
Optimized all renders using OptiPNG (only ~1% decrease though) 2018-10-18 21:00:35 +07:00
Bobby Wibowo
dd6934c540
Fixed lazyload breaking in uploads result 2018-10-18 20:40:47 +07:00
Bobby Wibowo
2bdb1d7245
Do not save into localStorage if render is enabled
We do not really want to save anything into user's storage/cookie unless necessary
2018-10-18 20:34:05 +07:00
Bobby Wibowo
cf570347e6
Updates
* Added ship waifu renders to homepage. These renders are toggleable since some of them maybe a bit NSFW-ish (state saved to browser's local storage).

* Updated lazyload to v10.19.0.

* Git commit URL is now have dotted bottom border.

* Thumbnail modal (the one that appears when you click display thumbnail button in lists view) now have a "Load original" button. For images it will simply load the original images, but for videos it will show a video player (relies on the browser's support for <video> tag). Thumbs view will now also have the "display thumbnail" button.

* Small changes to "add to album" modal.

* Small changes to alignment to modals in general.
2018-10-18 20:26:40 +07:00
Bobby Wibowo
0403684038
Fixed albums listing not working 2018-10-14 02:35:46 +07:00
Bobby Wibowo
4862512471
Removed stray console.log() 2018-10-13 18:09:54 +07:00
Bobby Wibowo
4456ba4b4d
Fixed authController.js 2018-10-13 18:09:09 +07:00
Bobby Wibowo
fcf4c00de7
Moved permission-related functions to permissionController
Fix: non-root staffs are now able to delete files by any users (previously they could only list them).
2018-10-13 18:06:58 +07:00
Bobby Wibowo
c763d9b1ea
Fixed thumb/list view setting not being saved 2018-10-13 11:09:39 +07:00
Bobby Wibowo
94dbfa9d96
Fixed broken description in file name length menu 2018-10-12 17:28:42 +07:00
Bobby Wibowo
8e46eaf4ac
Added disk usage column to manage users 2018-10-12 17:19:14 +07:00
Bobby Wibowo
31f44a1b91
Added ID and uploads count columns into manage users
Updated client-side check of user's enabled status to match server-side

Removed a bunch of console.log()'s from development
2018-10-12 16:42:16 +07:00
Bobby Wibowo
5cf8480959
Updated _globals.njk
Bumped version string (v3). I updated fontello in this branch but I forgot to update its version string.
2018-10-12 16:11:39 +07:00
Bobby Wibowo
f0998a8532
Merge branch 'safe.fiery.me' into account-manager 2018-10-12 02:24:41 +07:00
Bobby Wibowo
0e3ac72721
Fixed album pages
Previously album pages would still use utils.getPrettyBytes(), but one of the previous commits got rid of it in favor of client-side solution.

I forgot to update album pages to also use client-side solution, but this commit fixes it.

On a side note, I also switched all instances of consts to var in the function.
2018-10-12 02:21:19 +07:00
Bobby Wibowo
3708f53044
Added user group option to edit user modal
Also simplified selector for file's add to album modal
2018-10-11 00:33:11 +07:00
Bobby Wibowo
c3d4c237cb
Init account-manager branch 2018-10-10 02:52:41 +07:00
Bobby Wibowo
0745456cac
Updated sharex.js again
Haha, sorry about this, getting sleepy.
Removed a stray console.log().
2018-10-09 02:36:07 +07:00
Bobby Wibowo
57947df4db
Updated sharex.js
Oops, my bad, I forgot to include protocol into the URL field.
2018-10-09 02:33:06 +07:00
Bobby Wibowo
2f6c728e64
Updates
Moved page.prepareShareX() to a single JS file named sharex.js. It'll be loaded in home and dashboard pages, and both home.js and dashboard.js will rely on the function provided by it.

The generated ShareX config file will also properly support cases where the safe is being hosted in a subdir now (e.i. https://example.com/lolisafe).
2018-10-09 02:30:22 +07:00
Bobby Wibowo
5bd343638a
Updates
Moved utils.getPrettyBytes() and utils.getPrettySize() to client's dashboard.js.

Thus, server will no longer return prettified size and date (it'll be prettified by the client instead).

To be honest, I don't even know why I had them in server-side, it's obviously better this way.
2018-10-09 01:54:16 +07:00
Bobby Wibowo
e2831f2181
Updates
* uploadController.js: expect some multer error codes and don't log their stack traces to console when they occur.

* yarn.lock: added integrity field (yarn's new addition).
2018-10-08 23:14:10 +07:00