38 Commits

Author SHA1 Message Date
zadam
626af84f42 refactoring + uploading attachments WIP 2023-05-08 00:02:08 +02:00
zadam
0e4a040ed8 fixes of new attachment URLs 2023-04-17 22:40:53 +02:00
zadam
1fdb23746a uploading image to attachment 2023-03-16 18:34:39 +01:00
zadam
1b24276a4a always use template strings instead of string concatenation 2022-12-21 15:19:05 +01:00
zadam
dfb462cf35 introduced new exception classes for structured error reporting 2022-12-09 16:13:22 +01:00
zadam
342ae6e5e2 introduced new exception classes for structured error reporting 2022-12-09 16:04:13 +01:00
zadam
3faae63b84 set correct content type for error messages 2022-07-01 00:01:29 +02:00
Tom
3df712b64f refactor canvas-note to canvas 2022-05-10 13:43:05 +02:00
Tom
1a4bc0b989 clean up code 2022-05-03 22:06:24 +02:00
Tom
9771b441ad missing path2d support for freedawings, remove node-side rendering, allow async getContent()
* ## Excalidraw and SVG
 * 2022-04-16 - @thfrei
 *
 * Known issues:
 *  - excalidraw-to-svg (node.js) does not render any hand drawn (freedraw) paths. There is an issue with
 *    Path2D object not present in node-canvas library used by jsdom. (See Trilium PR for samples and other issues
 *    in respective library. Link will be added later). Related links:
 *     - https://github.com/Automattic/node-canvas/pull/2013
 *     - https://github.com/google/canvas-5-polyfill
 *     - https://github.com/Automattic/node-canvas/issues/1116
 *     - https://www.npmjs.com/package/path2d-polyfill
 *  - excalidraw-to-svg (node.js) takes quite some time to load an image (1-2s)
 *  - excalidraw-utils (browser) does render freedraw, however NOT freedraw with background
 *
 * Due to this issues, we opt to use **only excalidraw in the frontend**. Upon saving, we will also get the SVG
 * output from the live excalidraw instance. We will save this **SVG side by side the native excalidraw format
 * in the trilium note**.
 *
 * Pro: we will combat bit-rot. Showing the SVG will be very fast, since it is already rendered.
 * Con: The note will get bigger (maybe +30%?), we will generate more bandwith.
 *      (However, using trilium desktop instance, does not care too much about bandwidth. Size increase is probably
 *       acceptable, as a trade off.)
2022-04-19 00:21:20 +02:00
Tom
e156c6292b improve status 500 for canvas-note api/image.js 2022-04-19 00:17:39 +02:00
Tom
f354821f25 basic support for using api/images with canvas-note
http://localhost:8080/api/images/<noteId>/some-rando-text
2022-04-19 00:17:16 +02:00
zadam
564366861e prevent browser from caching images/files, fixes #2378 2021-11-25 20:24:42 +01:00
zadam
e57dee2f14 pasted images should have trimmed names if too long (too often it's just garbage), closes #2307 2021-11-04 21:48:46 +01:00
zadam
5f22864a93 support image/jpg as well, closes #2103 2021-08-31 22:02:38 +02:00
zadam
b660238a40 backend import unification 2021-06-29 22:15:57 +02:00
zadam
439ef4a8cb moved becca to top level source dir 2021-05-17 22:09:49 +02:00
zadam
ef0941479c fix undelete 2021-05-09 11:12:53 +02:00
zadam
1af10d48a2 becca conversion WIP 2021-05-02 11:23:58 +02:00
zadam
51f094f87f image handling consistency fixes 2020-06-28 23:10:45 +02:00
zadam
88348c560c syncification 2020-06-20 12:31:38 +02:00
zadam
ef61e22f1f local image storage fixes 2020-03-25 18:21:55 +01:00
zadam
8a92786012 save paste images locally WIP 2020-03-25 11:28:44 +01:00
zadam
712f67e983 uploading new image revisions, WIP 2019-11-08 22:34:30 +01:00
zadam
5d213eea7e basic webp support 2019-06-23 15:22:05 +02:00
zadam
25fe78012f upgrade to ckeditor 12.1.0 which fixes some upload issues 2019-04-15 21:08:31 +02:00
zadam
b7bd94b6b0 switchable image shrinking 2019-02-24 12:25:34 +01:00
zadam
45ddfef30a new import dialog 2019-02-10 14:33:13 +01:00
zadam
c487a95bc7 note content refactoring, WIP 2019-02-06 21:29:23 +01:00
azivner
21e952a7f0 note image detail 2018-11-08 10:30:35 +01:00
azivner
7bdbea81f1 enex import recognizes images, media references are converted to links 2018-11-05 12:52:50 +01:00
azivner
acc82f39c4 smaller refactorings continued 2018-04-01 11:42:12 -04:00
azivner
5d203b2278 removed sourceId where it's not necessary (stored in CLS instead) 2018-03-30 19:41:54 -04:00
azivner
795d50f02e converted of web (non-api) routes, basic conversion completed 2018-03-30 19:31:22 -04:00
azivner
aa57a64c61 converted image and maintainance routes 2018-03-30 17:07:41 -04:00
azivner
7b77e40514 added support for trilium-sender 2018-02-11 00:18:59 -05:00
azivner
b44412bc32 renaming of sql methods to fit getRows/getEntities model 2018-01-29 17:41:59 -05:00
azivner
52ad7f64b4 moved all sources to src directory 2018-01-28 22:18:15 -05:00