mirror of
https://github.com/flynx/pWiki.git
synced 2025-10-29 01:50:07 +00:00
tweaks and notes...
Signed-off-by: Alex A. Naanou <alex.nanou@gmail.com>
This commit is contained in:
parent
22a73a07e8
commit
8ef755c616
@ -193,7 +193,7 @@ var Outline = {
|
||||
&& (data.collapsed ?
|
||||
node.setAttribute('collapsed', '')
|
||||
: node.removeAttribute('collapsed'))
|
||||
if(data.text){
|
||||
if(data.text != null){
|
||||
var text = node.querySelector('textarea')
|
||||
var html = node.querySelector('span')
|
||||
if(this.__code2html__){
|
||||
@ -352,10 +352,13 @@ var Outline = {
|
||||
.replace(/\s*(?<!\\)\[[Xx]\]\s*/gm,
|
||||
style('check', '<input type="checkbox" checked>'))
|
||||
// basic styling...
|
||||
// XXX revise...
|
||||
.replace(/(?<!\\)\*(?=[^\s*])(([^*]|\\\*)*[^\s*])(?<!\\)\*/gm, '<b>$1</b>')
|
||||
.replace(/(?<!\\)~(?=[^\s~])(([^~]|\\~)*[^\s~])(?<!\\)~/gm, '<s>$1</s>')
|
||||
.replace(/(?<!\\)_(?=[^\s_])(([^_]|\\_)*[^\s_])(?<!\\)_/gm, '<i>$1</i>')
|
||||
.replace(/(?<!\\)`(?=[^\s_])(([^`]|\\`)*[^\s_])(?<!\\)`/gm, '<code>$1</code>')
|
||||
.replace(/(?<!\\)`(?=[^\s])(([^`]|\\`)*[^\s])(?<!\\)`/gm, '<code>$1</code>')
|
||||
// XXX support "\==" in mark...
|
||||
.replace(/(?<!\\)==(?=[^\s])(.*[^\s])(?<!\\)==/gm, '<mark>$1</mark>')
|
||||
// characters...
|
||||
// XXX use ligatures for these???
|
||||
.replace(/(?<!\\)---(?!-)/gm, '—')
|
||||
|
||||
@ -78,8 +78,16 @@ var setup = function(){
|
||||
- indent/deindent
|
||||
- edit node
|
||||
- markdown: tables
|
||||
- /^\s*(\|\s+.*\s+\|)\s*$/m -> <table><tr><td>$1</td></tr><table>
|
||||
- /\n\s*\|\s+/ -> <tr><td>
|
||||
- /\s+\|\s*\n/ -> </td></tr>
|
||||
- /\s+\|\s+/ -> </td><td>
|
||||
- ASAP: fix quotes...
|
||||
- empty item height is a bit off...
|
||||
- handle links gracefully
|
||||
- ~handle links gracefully -- open/edit
|
||||
_just click in the empty space_~
|
||||
- ~<a href="about:blank">this takes the whole element</a>~
|
||||
- this breaks if link is exactly line width -- should we ensure empty space?
|
||||
- ~serialize/deserialize~
|
||||
- ~add optional text styling to nodes~
|
||||
-
|
||||
@ -110,6 +118,7 @@ var setup = function(){
|
||||
- ---
|
||||
- Markers: ASAP, BUG, FIX, HACK, STUB, WARNING, and CAUTION
|
||||
- Basic inline *bold*, _italic_ and ~striked~
|
||||
- Marking ==text==
|
||||
- Inline [X] checkboxes [_]
|
||||
- To do items/blocks
|
||||
- [_] undone item
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user