-
I'm trying to autocomplete the available widgets and fields when typing I didn't find a place in $tw.wiki where I can get a full list of widgets and macros. Seems I have had too many questions since I started writing the WYSIWYG editor... |
Beta Was this translation helpful? Give feedback.
Replies: 3 comments 5 replies
-
MacrosSeems it didn't store the macro in a list or global variable when encountering it. And when parsing macros, they are transformed into So maybe there is no global macro list, macros are re-parsed every time and put into the tree when generating every widget tree. |
Beta Was this translation helpful? Give feedback.
-
For querying available widgets, see the discussion at this issue: #6453 Macros are trickier since they can be defined by users and are just variables. You could try autocompleting based on the variables defined in the context of the editor. |
Beta Was this translation helpful? Give feedback.
-
I can get macro list now, but I hope there can be a way to get corresponding examples... Currently, user will still don't know what these meacros means. Like in #6670 , I hope there can be a way to add fields for example usages to macros and widgets. Or probably use a new system tag to match the readme of macros to the macro definitions. And show readme in the preview of dropdown just like what we have in snippet autocomplete dropdown and wikilink autocomplete dropdown: |
Beta Was this translation helpful? Give feedback.
For querying available widgets, see the discussion at this issue: #6453
Macros are trickier since they can be defined by users and are just variables. You could try autocompleting based on the variables defined in the context of the editor.
https://tiddlywiki.com/#variables%20Operator