diff --git a/docs/configuration/custom_controls.rst b/docs/configuration/custom_controls.rst
index eb9af385..369255cd 100644
--- a/docs/configuration/custom_controls.rst
+++ b/docs/configuration/custom_controls.rst
@@ -98,22 +98,22 @@ of the types: ``name`` and ``type``.
Types
-----
-.. _sec-configuration-custom_controls-types:
+.. _sec-configuration-custom_controls-types-sections:
Sections
........
-.. _sec-configuration-custom_controls-types:
+.. _sec-configuration-custom_controls-types-rows:
Rows
....
-.. _sec-configuration-custom_controls-types:
+.. _sec-configuration-custom_controls-types-section_rows:
Section rows
............
-.. _sec-configuration-custom_controls-types:
+.. _sec-configuration-custom_controls-types-commands:
Commands
........
diff --git a/src/octoprint/static/js/app/viewmodels/control.js b/src/octoprint/static/js/app/viewmodels/control.js
index 4c045b2a..dfd96d96 100644
--- a/src/octoprint/static/js/app/viewmodels/control.js
+++ b/src/octoprint/static/js/app/viewmodels/control.js
@@ -125,8 +125,13 @@ $(function() {
if (control.type == "feedback_command" || control.type == "feedback") {
control.output = ko.observable("");
self.feedbackControlLookup[control.name] = control.output;
- } else if (control.type == "section" || control.type == "row" || control.type == "section_row") {
+ }
+
+ if (control.hasOwnProperty("children")) {
control.children = self._processControls(control.children);
+ if (!control.hasOwnProperty("layout") || !(control.layout == "vertical" || control.layout == "horizontal")) {
+ control.layout = "vertical";
+ }
}
if (control.hasOwnProperty("input")) {
@@ -324,12 +329,9 @@ $(function() {
self.displayMode = function (customControl) {
switch (customControl.type) {
+ case "container":
case "section":
return "customControls_sectionTemplate";
- case "row":
- return "customControls_rowTemplate";
- case "section_row":
- return "customControls_sectionRowTemplate";
case "command":
case "commands":
case "script":
diff --git a/src/octoprint/templates/tabs/control.jinja2 b/src/octoprint/templates/tabs/control.jinja2
index 1c589e57..8f9ce2d0 100644
--- a/src/octoprint/templates/tabs/control.jinja2
+++ b/src/octoprint/templates/tabs/control.jinja2
@@ -106,25 +106,21 @@
-
-