mirror of
https://github.com/flynx/pWiki.git
synced 2025-12-27 05:01:57 +00:00
minor bugfix...
Signed-off-by: Alex A. Naanou <alex.nanou@gmail.com>
This commit is contained in:
parent
2eabff3ab9
commit
d7cc854781
@ -960,6 +960,7 @@ object.Constructor('Page', BasePage, {
|
|||||||
// e.g.
|
// e.g.
|
||||||
// <macro src="/test/*/resolved"> ... </macro>
|
// <macro src="/test/*/resolved"> ... </macro>
|
||||||
// ...does not work yet...
|
// ...does not work yet...
|
||||||
|
// ....currently resolved returns promises....
|
||||||
macro: Macro(
|
macro: Macro(
|
||||||
['name', 'src', 'sort', 'text', 'join', 'else', ['strict', 'nonstrict']],
|
['name', 'src', 'sort', 'text', 'join', 'else', ['strict', 'nonstrict']],
|
||||||
async function(args, body, state){
|
async function(args, body, state){
|
||||||
@ -1114,12 +1115,12 @@ object.Constructor('Page', BasePage, {
|
|||||||
data()
|
data()
|
||||||
// multiple matches...
|
// multiple matches...
|
||||||
: data instanceof Array ?
|
: data instanceof Array ?
|
||||||
data
|
Promise.all(data
|
||||||
.map(function(d){
|
.map(function(d){
|
||||||
return typeof(d) == 'function'?
|
return typeof(d) == 'function'?
|
||||||
d()
|
d()
|
||||||
: d.text })
|
: d.text })
|
||||||
.flat()
|
.flat())
|
||||||
: data.text )}).call(this) },
|
: data.text )}).call(this) },
|
||||||
set raw(value){
|
set raw(value){
|
||||||
this.__update__({text: value}) },
|
this.__update__({text: value}) },
|
||||||
@ -1432,7 +1433,7 @@ module.System = {
|
|||||||
location: function(){
|
location: function(){
|
||||||
return this.get('..').path },
|
return this.get('..').path },
|
||||||
// XXX this can be a list for pattern paths...
|
// XXX this can be a list for pattern paths...
|
||||||
resolved: function(){
|
resolved: async function(){
|
||||||
return this.get('..').resolve() },
|
return this.get('..').resolve() },
|
||||||
dir: function(){
|
dir: function(){
|
||||||
return this.get('..').dir },
|
return this.get('..').dir },
|
||||||
|
|||||||
37
pwiki2.js
37
pwiki2.js
@ -1,6 +1,8 @@
|
|||||||
/**********************************************************************
|
/**********************************************************************
|
||||||
*
|
*
|
||||||
*
|
*
|
||||||
|
* XXX does @macro(..) have to follow the same overloading rules as @slot(..)???
|
||||||
|
* ...does it??
|
||||||
* XXX GENERATOR make pattern path parsing a generator...
|
* XXX GENERATOR make pattern path parsing a generator...
|
||||||
* ...experiment with a controllable iterator/range thing...
|
* ...experiment with a controllable iterator/range thing...
|
||||||
* This would require:
|
* This would require:
|
||||||
@ -15,6 +17,7 @@
|
|||||||
* XXX with the current implementation of filters
|
* XXX with the current implementation of filters
|
||||||
* this can't work as a generator...
|
* this can't work as a generator...
|
||||||
* ...might be a good idea to make filters local only...
|
* ...might be a good idea to make filters local only...
|
||||||
|
* XXX slots/macros might also pose a problem...
|
||||||
* 2) all the macros that can source pages to produce generators:
|
* 2) all the macros that can source pages to produce generators:
|
||||||
* @include(..) -- DONE
|
* @include(..) -- DONE
|
||||||
* @source(..) -- DONE
|
* @source(..) -- DONE
|
||||||
@ -23,14 +26,23 @@
|
|||||||
* 3) experiment with back-drivable generators...
|
* 3) experiment with back-drivable generators...
|
||||||
* this can be implemented/tested in parallel and integrated into
|
* this can be implemented/tested in parallel and integrated into
|
||||||
* the main pipeline if proven successful...
|
* the main pipeline if proven successful...
|
||||||
* XXX ranges in pattern paths...
|
* XXX ranges in pattern paths -- page-size=X page=Y | from=X to=Y / ...
|
||||||
* ...url syntax???
|
* ...url syntax???
|
||||||
|
* XXX differenced in behaviour between _abc and abc, either need to make
|
||||||
|
* them the same or document the differences and the reasons behind
|
||||||
|
* them...
|
||||||
* XXX BUG?: markdown: when parsing chunks each chunk gets an open/closed
|
* XXX BUG?: markdown: when parsing chunks each chunk gets an open/closed
|
||||||
* <p> inserted at start/end -- this breaks stuff returned by macros...
|
* <p> inserted at start/end -- this breaks stuff returned by macros...
|
||||||
* ...there are two ways to dance around this:
|
* ...there are two ways to dance around this:
|
||||||
* - make filters run a bit more globaly -- per block...
|
* - make filters run a bit more globaly -- per block...
|
||||||
* - find a local parser...
|
* - find a local parser...
|
||||||
* XXX add something like /stores to list store info...
|
* XXX introspection:
|
||||||
|
* /stores
|
||||||
|
* list stores...
|
||||||
|
* /info
|
||||||
|
* list page/store info
|
||||||
|
* /storage
|
||||||
|
* list storage usage / limits
|
||||||
* XXX OPTIMIZE: /tree is really slow...
|
* XXX OPTIMIZE: /tree is really slow...
|
||||||
* ...is the problem purely in the async/await playing ping-pong???
|
* ...is the problem purely in the async/await playing ping-pong???
|
||||||
* XXX BUG: FF: conflict between object.run and PouchDB...
|
* XXX BUG: FF: conflict between object.run and PouchDB...
|
||||||
@ -65,7 +77,8 @@
|
|||||||
* - page actions
|
* - page actions
|
||||||
* - delete -- DONE
|
* - delete -- DONE
|
||||||
* - copy/move -- DONE
|
* - copy/move -- DONE
|
||||||
* - migrate bootstrap --
|
* - resolved (async) --
|
||||||
|
* - migrate/rewrite bootstrap --
|
||||||
* - store topology --
|
* - store topology --
|
||||||
* - sync and sync conf --
|
* - sync and sync conf --
|
||||||
* - images
|
* - images
|
||||||
@ -78,19 +91,21 @@
|
|||||||
* - markdown -- DONE
|
* - markdown -- DONE
|
||||||
* - WikiWord -- DONE
|
* - WikiWord -- DONE
|
||||||
* - dom filter mechanics -- DONE
|
* - dom filter mechanics -- DONE
|
||||||
* - filters / dom filters:
|
* - filters
|
||||||
* - markdown??
|
* - markdown (???) -- ???
|
||||||
* - wikiword (control)
|
|
||||||
* this can be done in one of two ways:
|
* this can be done in one of two ways:
|
||||||
* - wrapping blocks in elemens
|
* - wrapping blocks in elemens
|
||||||
* ...requires negative filter calls, either on -wikiword
|
* ...requires negative filter calls, either on -wikiword
|
||||||
* or a different filter like nowikiwords...
|
* or a different filter like nowikiwords...
|
||||||
* - tags (current)
|
* - tags (current)
|
||||||
* - raw / code -- DONE?
|
* - raw / code -- DONE?
|
||||||
* - all (tree) -- DONE
|
* - nl2br --
|
||||||
* - nl2br
|
* - nowhitespace --
|
||||||
* - path2link (wikiword?) -- DONE
|
* clear extra whitespace from text elements
|
||||||
|
* - dom filters:
|
||||||
* - editor
|
* - editor
|
||||||
|
* basic -- DONE
|
||||||
|
* see: /System/edit
|
||||||
* MediumEditor (markdown-plugin)
|
* MediumEditor (markdown-plugin)
|
||||||
* https://github.com/yabwe/medium-editor
|
* https://github.com/yabwe/medium-editor
|
||||||
* https://github.com/IonicaBizau/medium-editor-markdown
|
* https://github.com/IonicaBizau/medium-editor-markdown
|
||||||
@ -104,6 +119,10 @@
|
|||||||
* - not sure if it works on mobile
|
* - not sure if it works on mobile
|
||||||
* + small
|
* + small
|
||||||
* tiptap (no-markdown, investigate y.js)
|
* tiptap (no-markdown, investigate y.js)
|
||||||
|
* - wikiword / path2link --
|
||||||
|
* ..do we need to be able to control this???
|
||||||
|
* - templates
|
||||||
|
* - all (tree) -- DONE
|
||||||
* - configuration
|
* - configuration
|
||||||
* - defaults
|
* - defaults
|
||||||
* - System/config (global)
|
* - System/config (global)
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user