Hi Joshua,

I would assume the problem lies in how json-editor detects what 
framework/version is being used and to assign the corresponding css classes 
accordingly. I believe you need to:

   1. declare that manually
   2. extract / import all the required row / column css from whichever 
   framework you chose as your favourite

Looking at things further, this issue suggest that you do, in fact, declare 
that manually via the theme property...

https://github.com/jdorn/json-editor/issues/358

Now, looking at the code of the widget, I am thinking that this function is 
problematic / incomplete:

JSONEditorWidget.prototype.getOptionsFromAttributes = function() { ... }

   1. first of all, it should possibly not interpret options as 
   text-references
      - but use the default way of declaring them via *option:{{!!foo}}* not 
      *option:"!!foo"*
   2. it doesn't seem to handle any options other than *schema* and 
   *jsonOutput*
      - instead, it should read any arbitrary attributes not specifically 
      declared upfront
         - e.g. also theme: "bootstrap3" iconlib: "fontawesome4"
      - if needed, *btheado* could iterate over an array of supported 
      (tested) options, e.g
         - params = ["schema","jsonOutput","theme","iconlib"]
         - and then iterate over those and perhaps use a switch case to 
         handle exceptions, if necessary
      - however, the current widget architecture does allow to read / catch 
      undeclared attributes within the widget
         - without them being predefined as actual widget properties
         - e.g.: $:/core/modules/widgets/action-setfield.js#L60 
         
<https://github.com/Jermolene/TiddlyWiki5/blob/72941f3e9a916948222ff7be540d896e2b1901f6/core/modules/widgets/action-setfield.js#L60>
            - see the each loop where any field not prefixed $ is 
            interpreted as a tiddler-field-name
            - compare: ActionSetFieldWidget 
            <http://tiddlywiki.com/#ActionSetFieldWidget> (last "parameter)
         - json-editor should do the same thing
            - use attributes prefixed with $ for any that need special 
            handling
               - for now, I don't think there should be any
               - the special handling for *schema* and *jsonOutput* should 
               be removed, imho
                  - schema could be initialized as "*{}*" and then 
                  overwritten with any declared attribute
               - just use any attributes not prefixed $ as options for the 
            json-editor
         
Tobias.

-- 
You received this message because you are subscribed to the Google Groups 
"TiddlyWiki" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/tiddlywiki.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/tiddlywiki/713118e4-b1b0-4d58-a56e-5dbc331b733d%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to