diff --git a/experiments/outline-editor/editor.css b/experiments/outline-editor/editor.css index e4033d1..616e886 100755 --- a/experiments/outline-editor/editor.css +++ b/experiments/outline-editor/editor.css @@ -47,30 +47,13 @@ display: none; } -.editor .children { -} - -.editor .header, -.editor .outline { - display: block; - position: relative; - - padding: 1em var(--outline-padding); - padding-bottom: 1.2em -} - -/* virtual empty block... */ -.editor .outline:empty:after { - content: "Empty"; - display: block; - font-style: italic; - color: rgba(0,0,0,0.2); -} -.editor .outline:empty:hover:after { -} /* header */ .editor .header { + margin: 1em var(--outline-padding); + padding-bottom: 1.2em; + + border-bottom: solid 1px rgba(0,0,0,0.15); } .editor .header:empty { display: none; @@ -91,6 +74,25 @@ } +.editor .outline { + display: block; + position: relative; + + padding: 1em var(--outline-padding); + padding-bottom: 1.2em; +} + +/* virtual empty block... */ +.editor .outline:empty:after { + content: "Empty"; + display: block; + font-style: italic; + color: rgba(0,0,0,0.2); +} +.editor .outline:empty:hover:after { +} + + .editor .outline .block { position: relative; outline: none; diff --git a/experiments/outline-editor/editor.js b/experiments/outline-editor/editor.js index e651ba5..c9adb38 100755 --- a/experiments/outline-editor/editor.js +++ b/experiments/outline-editor/editor.js @@ -1329,7 +1329,7 @@ var Outline = { // ...putting the same pattern in a normal group and // returning it works fine... //.replace(/(?<=[\n\h]*)(?:(?:\n|^)\s*\w*\s*::\s*[^\n]*\s*)*$/, - .replace(/([\n\t ]*)(?:(?:\n|^)[\t ]*\w*[\t ]*::[\t ]*[^\n]*[\t ]*)+$/, + .replace(/([\n\t ]*)(?:(?:\n|^)[\t ]*\w+[\t ]*::[\t ]*[^\n]+[\t ]*)+$/, function(match, ws){ var attrs = match .trim() diff --git a/experiments/outline-editor/index.html b/experiments/outline-editor/index.html index 32b4748..2179ee4 100755 --- a/experiments/outline-editor/index.html +++ b/experiments/outline-editor/index.html @@ -51,7 +51,6 @@ var setup = function(){ - BUG: mobile browsers behave quite chaotically ignoring parts of the styling... - - ## ToDo: - - crop: make path clickable - undo collapsed:: true - edit stack (position, action, ...) @@ -112,6 +111,7 @@ var setup = function(){ - empty item height is a bit off... - search? - _...not sure if search should be internal or external yet..._ + - DONE crop: make path clickable - DONE Q: crop: should we control crop via "crop-in"/"crop-out" instead of crop/uncrop?? - _crop-in/crop-out seems more natural..._ - DONE crop: show crop path (and depth)