Commit graph

277 commits

Author SHA1 Message Date
Yukai Huang
ebee5a8d05 Use xss in script tag 2016-10-08 19:57:50 +08:00
Yukai Huang
8e11c19bed Move out script tag and use js instead 2016-10-08 08:13:40 +08:00
Laura Kyle
c43f068f6c Change wording of placeholder text 2016-10-02 21:39:45 -04:00
Wu Cheng-Han
21afa2de14 Fix undefined variable typo 2016-09-18 17:05:55 +08:00
Wu Cheng-Han
9b5856fff0 Fix text complete extra tags for blockquote and referral shouldn't match after the target search and referral regex now need two spaces when after some text 2016-09-18 17:05:29 +08:00
Wu Cheng-Han
93ec43c3dc Fix revision viewer might not update after data init, try to use editor operation queue to enhance updateView performance 2016-09-18 17:04:33 +08:00
Wu Cheng-Han
38b1477736 Fix syncscroll.js and index.js have circular dependency cause Reference Errors 2016-09-18 16:51:19 +08:00
Wu Cheng-Han
42145e4019 Update to support tiddlywiki and mediawiki syntax highlighting in editor 2016-09-18 16:40:51 +08:00
Wu Cheng-Han
591134007c Update to support shortcuts which can add or delete symbol surround text 2016-09-18 16:35:24 +08:00
Wu Cheng-Han
f1c9874ed0 Update to support save mode to url and parse mode from url 2016-09-18 16:33:33 +08:00
Wu Cheng-Han
3840308ab6 Update edit and publish icon and change toggle icon to make it straightforward, and add shortcut key reminder in modes' title 2016-09-18 16:32:26 +08:00
Wu Cheng-Han
9d71adc05c Add support of shortcut keys for changeMode 2016-09-18 16:30:08 +08:00
Wu Cheng-Han
c22791610c Fix scripts load order to prevent reference error, using query callback to prevent google api call before loaded 2016-09-18 16:27:21 +08:00
Wu Cheng-Han
4421c8ede7 Improve authorship markers update performance and use CodeMirror built-in operation queue to avoid making DOM busy 2016-09-18 16:22:50 +08:00
Wu Cheng-Han
87f4d05e8e Update to use proper way to render view and fix upload image error should response with code 2016-08-19 11:31:23 +08:00
Wu Cheng-Han
b4ad011dc1 Fix toc id naming to avoid overlap with user toc 2016-08-15 11:27:32 +08:00
Wu Cheng-Han
fddc2ab38b Fix textcomplete of extra tags for blockquote not match space character in the between 2016-08-15 11:02:11 +08:00
Wu Cheng-Han
67474aa1d4 Update realtime check and refresh event, compress data using LZString UTF16 to minimize network delay 2016-08-02 17:16:01 +08:00
Wu Cheng-Han
f49fc192f6 Workaround vim mode might overwrite copy keyMap on Windows 2016-08-02 10:54:50 +08:00
Wu Cheng-Han
4de73477b4 Fix TOC might not update after changeMode 2016-08-02 10:54:20 +08:00
Wu Cheng-Han
881e92b05a Update to make help modal and text complete hint using consistent reminder text 2016-08-01 16:00:37 +08:00
Wu Cheng-Han
65cff038a3 Update bootstrap to 3.3.7 and jQuery to 3.1.0 with related patches 2016-07-30 12:19:42 +08:00
Wu Cheng-Han
3a5bda3067 Fix idle.js not change isAway property on onAway and onAwayBack events 2016-07-30 11:32:19 +08:00
Wu Cheng-Han
f69a5361cb Update to make random color more discrete 2016-07-30 11:31:29 +08:00
Wu Cheng-Han
a8c12d0d21 Update user color style in online user list to make it super obvious 2016-07-30 11:30:12 +08:00
Wu Cheng-Han
a14e7953b5 Add support of showing authorship in editor and adjust related styles 2016-07-30 11:28:24 +08:00
Wu Cheng-Han
8791447ef9 Update to support slide preview in both mode 2016-07-30 11:07:08 +08:00
Wu Cheng-Han
246c9da574 Fix spellcheck settings from cookies might not a boolean in string type 2016-07-30 11:00:00 +08:00
Wu Cheng-Han
9e365b7c12 Update header toolbar menu to remove beta section and add extra section 2016-07-02 16:18:10 +08:00
Wu Cheng-Han
da7b6a340d Reduce realtime timeout and heartbeat interval to handle stale clients quicker 2016-07-02 16:15:05 +08:00
Wu Cheng-Han
1df5b4ce49 Fix retryOnDisconnect and timer not clean up after reconnected 2016-07-02 16:13:34 +08:00
Cheng-Han, Wu
65b91e0b66 Update to handle on view have smaller scrollHeight than editor's shouldn't syncScrollToView after changes 2016-06-21 21:48:02 +08:00
Cheng-Han, Wu
3454819522 Update to annotate scrollbar position of revision mark text 2016-06-21 21:47:11 +08:00
Cheng-Han, Wu
09fb120967 Update to support toggle editor theme and spellcheck in status bar 2016-06-21 21:45:45 +08:00
Cheng-Han, Wu
3424cdd771 Add support of embed pdf 2016-06-21 21:44:06 +08:00
Cheng-Han, Wu
a6a107eab9 Update to remove data lines attributes in the patialUpdate to gain better performance 2016-06-17 16:33:01 +08:00
Cheng-Han, Wu
73f6d383b5 Add minimumCompatibleVersion and update refresh modal to show more detail informations 2016-06-17 16:31:36 +08:00
Cheng-Han, Wu
03e68f92eb Fix locked or private permission should block any operation if owner is null 2016-06-17 16:29:45 +08:00
Cheng-Han, Wu
cb1e00d1d1 Add support of exporting raw html 2016-06-17 16:17:37 +08:00
Cheng-Han, Wu
4d24476316 Add revision modal with UIs and support to mark patch diff texts 2016-06-17 16:15:53 +08:00
Cheng-Han, Wu
d742b332eb Rearrange some code execute to make sure loaded is asset in correct position 2016-06-17 15:59:50 +08:00
Cheng-Han, Wu
a9fc8d0dff Update to bring up view rendering earlier on first loading 2016-06-17 15:59:25 +08:00
Cheng-Han, Wu
fe249c01f5 Fix updatePermission before loaded might cause duplicate view rendering 2016-06-17 15:58:51 +08:00
Cheng-Han, Wu
cca567453d Fix on paste long document to editor might cause scroll not syncing 2016-06-17 15:58:23 +08:00
Cheng-Han, Wu
2c58b05d05 Revert f32dee3796, because workaround has better performance and they might needed in some cases 2016-06-17 15:57:34 +08:00
Cheng-Han, Wu
30c8420e30 Revert 85e00cb2ef, it's needed for checking if cursor related element reach the viewport edge 2016-06-17 15:55:27 +08:00
Cheng-Han, Wu
fb87de74a5 Update to make cursortag default as hover mode to prevent tag overlay other lines 2016-06-17 15:52:11 +08:00
Cheng-Han, Wu
85e00cb2ef Remove doc top offset workaround for checkCursorTag and checkCursorMenu which cause cursors floating around 2016-06-04 10:49:53 +08:00
Cheng-Han, Wu
43ad625b82 Remove autoSyncscroll on updateView to avoid lost scroll position on other client editing 2016-06-04 10:49:30 +08:00
Cheng-Han, Wu
5c8df4a7a1 Fix to make socket keep retry after disconnect on server maintenance 2016-06-04 10:49:10 +08:00
Cheng-Han, Wu
dcc5ef2df6 Remove unnecessary editor refresh workaround because it already get fixed 2016-06-02 01:06:55 +08:00
Cheng-Han, Wu
f32dee3796 Remove checkEditorScrollbar workaround since CodeMirror 5.15.3 already fixed this issue, refer to CodeMirror #3896 2016-06-01 14:37:51 +08:00
Cheng-Han, Wu
16d5e3ea80 Add maintenance mode and update to gracefully exit process on signal 2016-06-01 14:18:54 +08:00
Cheng-Han, Wu
da45b7dc10 Improve resize performance and fix resize syncscroll not accurate 2016-05-30 11:38:27 +08:00
Cheng-Han, Wu
2c60f0dd67 Improve syncscroll performance and accuracy with few UX tweaks 2016-05-29 13:58:32 +08:00
Cheng-Han, Wu
5c861fd51e Update docs and textcomplete rules for image syntax with size specified 2016-05-27 13:39:54 +08:00
Cheng-Han, Wu
56840e784f Update textcomplete rules to support more conditions and fix hint typo 2016-05-27 13:38:59 +08:00
Cheng-Han, Wu
d90acf88e3 Update and fix editor might not sync scrolling from edit mode to both mode 2016-05-27 02:04:38 +08:00
Cheng-Han, Wu
e9b0ce8e04 Update to improve sync scroll to edit performance and fix sync scroll behavior on many situations 2016-05-27 00:12:07 +08:00
Cheng-Han, Wu
b28750f256 Update to improve syncscroll performance and add toggle for sync scrolling 2016-05-26 13:17:00 +08:00
Cheng-Han, Wu
bf1dc237a9 Add support of sync scrolling to edit area 2016-05-25 13:25:05 +08:00
Cheng-Han, Wu
97befb6238 Fix on paste or cut text might trigger syncscroll 2016-05-16 23:02:59 +08:00
Cheng-Han, Wu
eb5873a94d Update to move gitlab api path to sub path and fix its find user method for PR #121 2016-05-16 18:16:45 +08:00
Cheng-Han, Wu
9e75c5cdf4 Fix export snippet should check data before sending request and fix some code styles 2016-05-15 13:01:41 +08:00
Cheng-Han, Wu
4058306d4e Add back missing code for 1f4e1f09b6 2016-05-15 12:30:28 +08:00
Cheng-Han, Wu
1f4e1f09b6 Add some reminder for snippet before modal ajax 2016-05-15 12:22:51 +08:00
Cheng-Han, Wu
8a01b7242c Merge branch 'gitlab_snippets' of https://github.com/jccrofty30/hackmd into jccrofty30-gitlab_snippets
# Conflicts:
#	lib/response.js
2016-05-15 11:02:15 +08:00
Cheng-Han, Wu
a70ebf7762 Update to move dropbox app key setting to common.js and will auto load client-side related scripts 2016-05-15 10:54:24 +08:00
Jason Croft
930afdc337 Show only projects where user is creator, has project access >= 20, or has group access. 2016-05-13 10:32:30 -04:00
Jason Croft
edcb766b63 Apply "snippets_enabled only" logic to import modal.
Better parsing for snippet import.
Add python filetype.
2016-05-13 10:00:34 -04:00
Jason Croft
ba0a8f584a Filter out projects that don't have snippets enabled. 2016-05-12 14:26:55 -04:00
Jason Croft
30e602a740 Enable snippet exporting. 2016-05-12 12:28:08 -04:00
Jason Croft
c16345ab12 Can now select from available projects and snippets to build import URL. 2016-05-12 11:19:14 -04:00
Jason Croft
3dd3e6bc35 Allow importing from GitLab snippet 2016-05-11 17:05:25 -04:00
Jason Croft
70f6e5bc2c Define events for snippet actions 2016-05-09 22:38:13 -04:00
Jason Croft
476cabd109 Attach to snippet classes. 2016-05-09 17:07:02 -04:00
Cheng-Han, Wu
7aa21c8f19 Fix missusing for CodeMirror.Pass 2016-04-28 11:10:09 +08:00
Cheng-Han, Wu
efb188c9c1 Fix code styles 2016-04-24 12:30:16 +08:00
Cheng-Han, Wu
0bb3e53d58 Change fullScreen toggle to F10
because Mac OS X default might overwrite F11 and F12 behaviors
2016-04-24 12:29:55 +08:00
Cheng-Han, Wu
b1187a2014 Fix some indentation 2016-04-24 11:03:57 +08:00
Cheng-Han, Wu
42ac80eb0e Fix other CodeMirror.Pass usage 2016-04-24 10:49:22 +08:00
Zankio
3aa9204e57 Fix Esc in Vim mode 2016-04-23 23:35:23 +08:00
Cheng-Han, Wu
f693399c76 Fix view scroll position might lost when editor changes the last line and might get wrong knob position 2016-04-20 22:34:52 +08:00
Cheng-Han, Wu
7e69bfc40b Merge client index.js settings to common.js 2016-04-20 18:20:43 +08:00
Cheng-Han, Wu
0fb70a1487 Support experimental spell checking feature (en-US only), can be enabled by the YAML meta option 2016-04-20 18:09:36 +08:00
Cheng-Han, Wu
692903f1a1 Support import from gist, fix some minor typo and issues 2016-04-20 18:06:36 +08:00
Cheng-Han, Wu
49b51e478f Refactor server with Sequelize ORM, refactor server configs, now will show note status (created or updated) and support docs (note alias) 2016-04-20 18:03:55 +08:00
Cheng-Han, Wu
b347ea5414 Workaround editor might have wrong doc height and wrong simple scroll bar knob position when editor height changed 2016-04-20 16:17:24 +08:00
Cheng-Han, Wu
b996f801cc Updated to add statusPanel variable 2016-04-20 16:16:46 +08:00
Cheng-Han, Wu
3718238277 Fixed editor changes will cause syncScrollToView 2016-04-20 16:16:07 +08:00
Cheng-Han, Wu
85078fd328 Fixed minor bugs 2016-03-16 12:46:29 +08:00
Cheng-Han, Wu
a55ece023a Improved checkCursorMenu and checkCursorTag performance and fully rewrite its position method for UX and verified 2016-03-15 11:12:45 +08:00
Cheng-Han, Wu
ea703145c5 Fixed editor should not try to programmatically focus on mobile without click, touch or mouse events 2016-03-15 11:10:58 +08:00
Cheng-Han, Wu
40f9206190 Fixed mobile layout issues and improved editor layout styles 2016-03-15 11:10:08 +08:00
Cheng-Han, Wu
b5d9d28f2e Updated to handle Mac shortcut keys of "Cmd-Left" and "Cmd-Right" 2016-03-15 11:05:05 +08:00
Cheng-Han, Wu
25dd400708 Improved overall textcomplete performance and more cases and UX handling 2016-03-15 11:04:45 +08:00
Cheng-Han, Wu
88e6e8522f Updated to support containers syntax textcomplete 2016-03-15 11:01:01 +08:00
Cheng-Han, Wu
526f5c7e2e Improved update last info methods, only change DOM when necessary 2016-03-15 10:45:02 +08:00
Cheng-Han, Wu
b49d4e2261 Support mermaid in code block diagram and updated all diagram rendering method and styles 2016-03-04 23:26:27 +08:00
Cheng-Han, Wu
845ef9bad6 Support export to and import from Google Drive 2016-03-04 23:17:35 +08:00
Cheng-Han, Wu
8b16e0723d Added throttle for checkCursorMenu, gain much better input performance 2016-02-25 13:45:02 +08:00
Cheng-Han, Wu
d97e435b3b Fixed when change widthInput value not parse correctly which cause tab indent problems 2016-02-18 03:38:09 +08:00
Cheng-Han, Wu
b2b1be3dda Support set url path and use relative url, move raphael to bower and fixed minor issue in history 2016-02-16 20:08:44 -08:00
Cheng-Han, Wu
1b059775e5 Fixed editor tab key not handle correctly on multiple lines selections 2016-02-16 09:54:33 -06:00
Cheng-Han, Wu
26c40dca2d Fixed checkCursorTag element not valid 2016-02-15 19:16:48 -06:00
Cheng-Han, Wu
880f6bcf02 Updated to support lang attribute and styles in editor 2016-02-15 19:13:17 -06:00
Cheng-Han, Wu
8db142554f Updated rendering operations to improve performance 2016-02-11 14:35:25 -06:00
Cheng-Han, Wu
4c4a0e0f3f Fixed prevent XSS might break lots of tags and only need after rendered 2016-02-11 03:45:13 -06:00
Cheng-Han, Wu
176021ccd8 Fixed cursor-tag and cursor-menu might not on correct position 2016-02-11 02:38:19 -06:00
Cheng-Han, Wu
6700f033ab Prevent XSS in markdown rendering 2016-02-11 02:36:52 -06:00
Cheng-Han, Wu
5aad217d34 Support change keymap and indentation type with size in statusbar 2016-02-08 22:51:07 -06:00
Cheng-Han, Wu
44ac1b295c Workaround for cut or paste action might make scrollMap not correct and big documents have poor input performance 2016-02-02 13:56:10 -06:00
Cheng-Han, Wu
ce8f9b695c Fixed isInCode and code block textcomplete might not correct 2016-02-01 00:42:30 -06:00
Cheng-Han, Wu
ff2fc76491 Supported export to gist 2016-01-31 15:42:26 -06:00
Cheng-Han, Wu
eba84527c3 Fixed only "AUTH failed" error message would redirect to 403 2016-01-31 15:33:25 -06:00
Cheng-Han, Wu
2eec0ae35d Improved code block and emojiy textcomplete and match rules 2016-01-31 15:32:35 -06:00
Cheng-Han, Wu
eb4cb3f52f Fixed supportCharts name not match real syntax 2016-01-31 15:30:10 -06:00
Cheng-Han, Wu
e473a4e61b Fixed cursor id not valid to selector 2016-01-22 19:48:07 -06:00
Wu Cheng-Han
1b2a3108be Marked as 0.3.4 2016-01-19 10:06:22 -06:00
Wu Cheng-Han
75548df29e Added support of code block languages autocomplete for charts 2016-01-19 10:01:40 -06:00
Wu Cheng-Han
96931e6e3a Upgrade all dependencies and fixes afterward issues 2016-01-19 09:57:58 -06:00
Wu Cheng-Han
eaa8ccaccb Upgrade CodeMirror to 5.10.1 and now support fullscreen, jump-to-line in editor 2016-01-17 14:28:04 -06:00
Wu Cheng-Han
3fdceaaf06 Fixed history not update if note have no content and lz-string version mismatch 2016-01-17 09:59:03 -06:00
Wu Cheng-Han
eddff9e863 Added editor placeholder and auto set mode by content existence 2016-01-17 09:56:36 -06:00
Wu Cheng-Han
49c7dded45 Added private permission and clean up codes, solved potential race condition in realtime.js 2016-01-17 09:51:27 -06:00
Wu Cheng-Han
473212676a Fixed importFromUrl should parse by the file extension, and move to-markdown dependency to bower 2016-01-12 08:03:56 -06:00
Wu Cheng-Han
2ecec3b59a Support show last change user with profile and support YAML config inside the note with robots, lang, dir, breaks options 2016-01-12 08:01:42 -06:00
Wu Cheng-Han
f5010af4f1 Added 404 and 403 status on routes 2015-12-30 00:33:36 -05:00
Wu Cheng-Han
48d5889a30 Added support of slideshare and speakerdeck syntax and autocomplete 2015-12-22 17:51:07 -06:00
Wu Cheng-Han
9eb23603f4 Added support of toc syntax 2015-12-20 11:28:54 -06:00
Wu Cheng-Han
32a89e13cd Fixed possible bug in partialUpdate 2015-12-18 10:15:28 -06:00
Wu Cheng-Han
02cd3d633e Updated to show locked-modal instead signin-modal when permission is "locked" 2015-12-18 10:15:16 -06:00
Wu Cheng-Han
21ad5cfd60 Fixed toolbar buttons should prevent default event 2015-12-18 09:44:08 -06:00
Wu Cheng-Han
3d21e6b16d Fixed cursor animation might not correct because the page scroll involved 2015-12-18 09:43:23 -06:00
Wu Cheng-Han
031c96c72d Updated slide mode 2015-12-18 09:40:52 -06:00
Wu Cheng-Han
54b33f181f Fixed dropbox saver url not correct 2015-12-15 23:16:31 -06:00
xnum
f51b7370f0 Add Slide Mode
using reveal.js
and some part of reveal-md
2015-11-23 20:38:26 +08:00
Wu Cheng-Han
bc1f59af65 Marked as 0.3.3 2015-09-27 14:36:08 +08:00
Wu Cheng-Han
5f82df7eb2 Added support of export to HTML, and changed the navbar menu for consistency 2015-09-25 19:09:43 +08:00
Wu Cheng-Han
93b6288958 Updated editor default theme and some other options 2015-09-25 19:02:51 +08:00
Wu Cheng-Han
2b57b1849f Added support of titleReminder and handle when change occur on offline 2015-09-25 18:48:45 +08:00
Wu Cheng-Han
529c5f6c13 Added support of resizable editor 2015-09-25 18:46:08 +08:00
Wu Cheng-Han
b86a695f9c Added support of on changing from view mode to other mode will auto scroll to corresponding position 2015-09-25 18:41:03 +08:00
Wu Cheng-Han
4b81ee9104 Changed permission Editable icon to prevent misunderstanding 2015-09-25 18:38:38 +08:00
Wu Cheng-Han
c900703d75 Updated windowResize, page unload, page error and minor some tweaks for performance 2015-09-25 18:37:40 +08:00
Wu Cheng-Han
db956cc298 Workaround foldGutter not showing on first view 2015-09-25 18:35:18 +08:00
Wu Cheng-Han
b87463ae0d Added timeout on socket 2015-09-25 18:34:34 +08:00
Wu Cheng-Han
3ab04d4f02 Fixed saveInfo and restoreInfo might not get correct window size 2015-09-25 18:34:03 +08:00
Wu Cheng-Han
e0ff287652 Fixed toc might not have proper view in some cases 2015-09-25 18:32:33 +08:00
Wu Cheng-Han
fb8ead594a Updated resizeView, add or update user cursors to get proper view 2015-09-25 18:30:44 +08:00