Partial migration for format widgets
When format widgets were initially introduced, node defs were only partially updated when a refresh node def operation was performed. As a workaround, format widgets include this additional information in names of the selections. This less than desirable and should be phased out. As every single update has had users that fail to reload the page and run old javascript, I plan to release this change in three phases. - (this commit) Check for format widget definitions in format widget options as well. - Modify the format widget defs to be included in the options instead of names - Only check for format widget defs in options and remove the code for parsing names
This commit is contained in:
+2
-1
@@ -1126,7 +1126,8 @@ function addFormatWidgets(nodeType) {
|
||||
formatWidget._value = value;
|
||||
} else {
|
||||
formatWidget._value = fullDef[0];
|
||||
for (let wDef of fullDef[1]) {
|
||||
let formatWidgets = formatWidgetoptions?.formats?.[fullDef[0]] ?? fullDef[1]
|
||||
for (let wDef of formatWidgets) {
|
||||
//create widgets. Heavy borrowed from web/scripts/app.js
|
||||
//default implementation doesn't work since it automatically adds
|
||||
//the widget in the wrong spot.
|
||||
|
||||
Reference in New Issue
Block a user