diff --git a/web_interface/templates/v3/partials/plugin_config.html b/web_interface/templates/v3/partials/plugin_config.html index d5033a86..937d1fd7 100644 --- a/web_interface/templates/v3/partials/plugin_config.html +++ b/web_interface/templates/v3/partials/plugin_config.html @@ -58,7 +58,7 @@ {% if field_type == 'integer' %}step="1"{% else %}step="any"{% endif %} class="form-input w-full rounded-md border-gray-300 shadow-sm focus:border-blue-500 focus:ring-blue-500 bg-white text-black placeholder:text-gray-500"> - {# Array - check for file upload widget first (to avoid breaking static-image plugin), then array of objects #} + {# Array - check for file upload widget first (to avoid breaking static-image plugin), then checkbox-group, then array of objects #} {% elif field_type == 'array' %} {% set x_widget = prop.get('x-widget') or prop.get('x_widget') %} {% if x_widget == 'file-upload' %} @@ -152,6 +152,30 @@ + {% elif x_widget == 'checkbox-group' %} + {# Checkbox group widget for multi-select arrays with enum items #} + {% set array_value = value if value is not none and value is iterable and value is not string else (prop.default if prop.default is defined and prop.default is iterable and prop.default is not string else []) %} + {% set items_schema = prop.get('items') or {} %} + {% set enum_items = items_schema.get('enum') or [] %} + {% set x_options = prop.get('x-options') or {} %} + {% set labels = x_options.get('labels') or {} %} + +