notes and tweaks...

Signed-off-by: Alex A. Naanou <alex.nanou@gmail.com>
This commit is contained in:
Alex A. Naanou 2023-10-11 01:57:21 +03:00
parent 273c14aa20
commit 14fec24aaf
3 changed files with 28 additions and 11 deletions

View File

@ -350,6 +350,13 @@ editor .outline [tabindex]:focus {
/*margin-left: 0;*/ /*margin-left: 0;*/
} }
/* code... */
.editor .outline [tabindex]>span code {
padding: 0.1em 0.3em;
font-family: monospace;
background: rgba(0,0,0,0.07);
border-radius: 0.2em;
}
/*********************************************************************/ /*********************************************************************/

View File

@ -339,9 +339,10 @@ var Outline = {
.replace(/(?<!\\)\[[X]\]/gm, .replace(/(?<!\\)\[[X]\]/gm,
style('check', '<input class="check" type="checkbox" checked>')) style('check', '<input class="check" type="checkbox" checked>'))
// basic styling... // basic styling...
.replace(/(?<!\\)\*(?=[^\s*])([^*]*[^\s*])(?<!\\)\*/gm, '<b>$1</b>') .replace(/(?<!\\)\*(?=[^\s*])(([^*]|\\\*)*[^\s*])(?<!\\)\*/gm, '<b>$1</b>')
.replace(/(?<!\\)~(?=[^\s~])([^~]*[^\s~])(?<!\\)~/gm, '<s>$1</s>') .replace(/(?<!\\)~(?=[^\s~])(([^~]|\\~)*[^\s~])(?<!\\)~/gm, '<s>$1</s>')
.replace(/(?<!\\)_(?=[^\s_])([^_]*[^\s_])(?<!\\)_/gm, '<i>$1</i>') .replace(/(?<!\\)_(?=[^\s_])(([^_]|\\_)*[^\s_])(?<!\\)_/gm, '<i>$1</i>')
.replace(/(?<!\\)`(?=[^\s_])(([^`]|\\`)*[^\s_])(?<!\\)`/gm, '<code>$1</code>')
// quoting... // quoting...
.replace(/(?<!\\)\\(.)/gm, '$1') .replace(/(?<!\\)\\(.)/gm, '$1')
return elem }, return elem },

View File

@ -36,20 +36,29 @@ var setup = function(){
- Bonsai - Bonsai
- -
- ## ToDo - ## ToDo
- shifting nodes up/down - ASAP: editor: bksapce/del at start/end of a block should join it with prev/next
- need to reach checkboxes from keyboard - ASAP: editor: pressing enter in text edit mode should split text into two blocks
- editor: bksapce/del at start/end of a block should join it with prev/next - ASAP: editor: shifting nodes up/down
- editor: pressing enter in text edit mode should split text into two blocks - ASAP: editor: `-` at start of line is interpreted as block marker...
- editor: caret - editor: caret
- ~go to next/prev element's start/end when moving off last/first char~ - ~go to next/prev element's start/end when moving off last/first char~
- handle up/down on wrapped blocks - handle up/down on wrapped blocks
_...can't seem to get caret line in a non-hacky way_ _...can't seem to get caret line in a non-hacky way_
- editor: semi-live update styles - ~editor: semi-live update styles~
- need to reach checkboxes via keyboard
- persistent empty first/last node (a button to create a new node) - persistent empty first/last node (a button to create a new node)
- add completion percentage to blocks with todo's nested - add completion percentage to blocks with todo's nested:
either by default oron '%%' or '[%]' placeholder - `[%]`, `%%`, or something similar...
...ratio between all nested open checkboxes to checked (???)
- read-only mode - read-only mode
- should bulets be on the same level as nodes or offset??
- A) justified to bulet:
* list item
* list item
block text
- B) justified to text _(current)_:
* list item
* list item
block text
- ~do a better expand/collapse icons~ - ~do a better expand/collapse icons~
- ~loading from DOM -- fill textarea~ - ~loading from DOM -- fill textarea~
- ~focus management~ - ~focus management~