From 4bf7d8f27a5134e1656a478b52459b671a60058b Mon Sep 17 00:00:00 2001 From: "Alex A. Naanou" Date: Sun, 11 Sep 2022 08:52:38 +0300 Subject: [PATCH] notes... Signed-off-by: Alex A. Naanou --- pwiki/page.js | 4 ++++ pwiki/store/base.js | 4 ++++ pwiki2.js | 12 ++++++++++-- 3 files changed, 18 insertions(+), 2 deletions(-) diff --git a/pwiki/page.js b/pwiki/page.js index a3231c7..068cb6f 100755 --- a/pwiki/page.js +++ b/pwiki/page.js @@ -2021,6 +2021,10 @@ module.Test = { // this is shown by most listers by adding an :all argument to the url... '.hidden': { text: 'Hidden page...' }, + '.hidden/subpage': { + text: 'visible subpage...' }, + '.hidden/.hidden': { + text: 'hidden subpage...' }, slots: { text: object.doc` diff --git a/pwiki/store/base.js b/pwiki/store/base.js index fe209aa..c252a53 100755 --- a/pwiki/store/base.js +++ b/pwiki/store/base.js @@ -358,6 +358,9 @@ module.BaseStore = { // skip metadata paths... if(p.includes('*')){ return res } + // XXX HIDE .hide_paths + if(pwpath.basename(p)[0] == '.' + /*/ if((pwpath.basename(p)[0] == '.' // XXX CACHE this??? || (that.hide_paths @@ -365,6 +368,7 @@ module.BaseStore = { .reduce(function(res, h){ return res === true || p.startsWith(h) }, false))) + //*/ && !all){ return res } var m = p.match(pattern) diff --git a/pwiki2.js b/pwiki2.js index ec109aa..deff9e9 100755 --- a/pwiki2.js +++ b/pwiki2.js @@ -1,8 +1,16 @@ /********************************************************************** * * -* XXX changing the URL does not start the spinner... -* XXX HIDE revise .hide_paths... +* XXX BUG: .hide_paths: +* - hidden dir should hide all the children -- BROKEN +* (see /.hidden/suppage) +* - listing a hidden subtree should work regardless of :all -- BROKEN +* (see: /.hidden/tree) +* XXX BUG: changing the URL does not start the spinner... +* chech: +* - url (hashchange) +* - click link +* - history back/foreward * XXX Q: can we access fs from a pwa??? * XXX start writing docs in pwiki * - WYSIWYG markdown editor/viewer (ASAP)