From 01ad4b4221b7458ae65e5ddad64f44cf5afc797d Mon Sep 17 00:00:00 2001 From: "Alex A. Naanou" Date: Wed, 2 Nov 2022 15:06:43 +0300 Subject: [PATCH] refactoring .system/edit... Signed-off-by: Alex A. Naanou --- pwiki/page.js | 104 ++++++++++++++++++++++++-------------------------- pwiki2.html | 2 +- 2 files changed, 51 insertions(+), 55 deletions(-) diff --git a/pwiki/page.js b/pwiki/page.js index 4d18c46..aa9aa4b 100755 --- a/pwiki/page.js +++ b/pwiki/page.js @@ -2093,30 +2093,36 @@ module.System = { edit: { // XXX not sure if we should use .title or .name here... text: object.doc` + +

+ + @source(./title) + +

+
+ +
+
+ + @macro(titleeditor .) + @macro(texteditor .) + + @source(../title) (edit) - ../.. @source(../location/!) - - -

- - @source(./title) - -

-
-
+
`}, /*/ edit: { @@ -2156,26 +2162,21 @@ module.System = { text: object.doc` @load(./edit) - - -

- - @source(./title) - -

-
- @quote(./html) -
-
-
+ +
+ @quote(./html) +
+
+ + + +
visual @@ -2186,25 +2187,20 @@ module.System = { text: object.doc` @load(./edit) - - -

- - @source(./title) - -

-
-
-
+ +
+
+ + + +
visual diff --git a/pwiki2.html b/pwiki2.html index eb02cbc..df7eaf8 100755 --- a/pwiki2.html +++ b/pwiki2.html @@ -401,7 +401,7 @@ require(['./browser'], function(browser){ var titles = [...document.querySelectorAll('title')] titles[0].innerHTML = `${titles.length > 1 ? - titles.at(-1).innerHTML + titles.at(-1).innerText : this.title} — pWiki` // scroll to anchor element... this.hash