diff --git a/docs/examples/chart-bar-election-grouped.json b/docs/examples/chart-bar-election-grouped.json index 8319d53e5..d5a31aca9 100644 --- a/docs/examples/chart-bar-election-grouped.json +++ b/docs/examples/chart-bar-election-grouped.json @@ -144,7 +144,7 @@ "ui-notification" ], "showPathInSidebar": false, - "showPageTitle": false, + "headerContent": "none", "navigationStyle": "icon", "titleBarStyle": "default" }, @@ -166,4 +166,4 @@ "widgetGap": "12px" } } -] \ No newline at end of file +] diff --git a/docs/examples/chart-bar-finance-grouped.json b/docs/examples/chart-bar-finance-grouped.json index 596703521..3672b466f 100644 --- a/docs/examples/chart-bar-finance-grouped.json +++ b/docs/examples/chart-bar-finance-grouped.json @@ -144,7 +144,7 @@ "ui-notification" ], "showPathInSidebar": false, - "showPageTitle": false, + "headerContent": "none", "navigationStyle": "icon", "titleBarStyle": "default" }, @@ -166,4 +166,4 @@ "widgetGap": "12px" } } -] \ No newline at end of file +] diff --git a/docs/examples/chart-bar-sw-characters.json b/docs/examples/chart-bar-sw-characters.json index f81b11398..5f504c908 100644 --- a/docs/examples/chart-bar-sw-characters.json +++ b/docs/examples/chart-bar-sw-characters.json @@ -207,7 +207,7 @@ "ui-notification" ], "showPathInSidebar": false, - "showPageTitle": false, + "headerContent": "none", "navigationStyle": "icon", "titleBarStyle": "default" }, @@ -229,4 +229,4 @@ "widgetGap": "12px" } } -] \ No newline at end of file +] diff --git a/docs/examples/chart-histogram-bins.json b/docs/examples/chart-histogram-bins.json index 65ee7bd29..8234b095e 100644 --- a/docs/examples/chart-histogram-bins.json +++ b/docs/examples/chart-histogram-bins.json @@ -131,7 +131,7 @@ "ui-notification" ], "showPathInSidebar": false, - "showPageTitle": false, + "headerContent": "none", "navigationStyle": "icon", "titleBarStyle": "default" }, @@ -153,4 +153,4 @@ "widgetGap": "12px" } } -] \ No newline at end of file +] diff --git a/docs/examples/chart-histogram-categories.json b/docs/examples/chart-histogram-categories.json index 3c5e4b872..492dfd096 100644 --- a/docs/examples/chart-histogram-categories.json +++ b/docs/examples/chart-histogram-categories.json @@ -325,7 +325,7 @@ "ui-notification" ], "showPathInSidebar": false, - "showPageTitle": false, + "headerContent": "none", "navigationStyle": "icon", "titleBarStyle": "default" }, @@ -347,4 +347,4 @@ "widgetGap": "12px" } } -] \ No newline at end of file +] diff --git a/docs/examples/chart-histogram-series.json b/docs/examples/chart-histogram-series.json index 6b4f79bb1..fef1db871 100644 --- a/docs/examples/chart-histogram-series.json +++ b/docs/examples/chart-histogram-series.json @@ -183,7 +183,7 @@ "ui-notification" ], "showPathInSidebar": false, - "showPageTitle": false, + "headerContent": "none", "navigationStyle": "icon", "titleBarStyle": "default" }, @@ -205,4 +205,4 @@ "widgetGap": "12px" } } -] \ No newline at end of file +] diff --git a/docs/examples/chart-line-multiple.json b/docs/examples/chart-line-multiple.json index 2cc73cbb5..fc588e2f7 100644 --- a/docs/examples/chart-line-multiple.json +++ b/docs/examples/chart-line-multiple.json @@ -177,7 +177,7 @@ "ui-notification" ], "showPathInSidebar": false, - "showPageTitle": false, + "headerContent": "none", "navigationStyle": "icon", "titleBarStyle": "default" }, @@ -199,4 +199,4 @@ "widgetGap": "12px" } } -] \ No newline at end of file +] diff --git a/docs/examples/chart-line-timestamp.json b/docs/examples/chart-line-timestamp.json index 39104d60e..9323121c2 100644 --- a/docs/examples/chart-line-timestamp.json +++ b/docs/examples/chart-line-timestamp.json @@ -163,7 +163,7 @@ "ui-notification" ], "showPathInSidebar": false, - "showPageTitle": false, + "headerContent": "none", "navigationStyle": "icon", "titleBarStyle": "default" }, @@ -185,4 +185,4 @@ "widgetGap": "12px" } } -] \ No newline at end of file +] diff --git a/docs/examples/chart-pie-doughnut.json b/docs/examples/chart-pie-doughnut.json index 4d132f106..72284477b 100644 --- a/docs/examples/chart-pie-doughnut.json +++ b/docs/examples/chart-pie-doughnut.json @@ -251,7 +251,7 @@ "ui-notification" ], "showPathInSidebar": false, - "showPageTitle": false, + "headerContent": "none", "navigationStyle": "icon", "titleBarStyle": "default" }, @@ -273,4 +273,4 @@ "widgetGap": "12px" } } -] \ No newline at end of file +] diff --git a/docs/examples/chart-scatter-grouped.json b/docs/examples/chart-scatter-grouped.json index a15f49e1e..58b73be82 100644 --- a/docs/examples/chart-scatter-grouped.json +++ b/docs/examples/chart-scatter-grouped.json @@ -144,7 +144,7 @@ "ui-notification" ], "showPathInSidebar": false, - "showPageTitle": false, + "headerContent": "none", "navigationStyle": "icon", "titleBarStyle": "default" }, @@ -166,4 +166,4 @@ "widgetGap": "12px" } } -] \ No newline at end of file +] diff --git a/docs/examples/group-dialog-type.json b/docs/examples/group-dialog-type.json index 71e5fdc0f..49dca8590 100644 --- a/docs/examples/group-dialog-type.json +++ b/docs/examples/group-dialog-type.json @@ -162,7 +162,7 @@ "ui-notification" ], "showPathInSidebar": false, - "showPageTitle": false, + "headerContent": "none", "navigationStyle": "icon", "titleBarStyle": "default" }, @@ -212,4 +212,4 @@ "density": "default" } } -] \ No newline at end of file +] diff --git a/docs/examples/ui-button-hold.json b/docs/examples/ui-button-hold.json index ae8c19225..b2e249d36 100644 --- a/docs/examples/ui-button-hold.json +++ b/docs/examples/ui-button-hold.json @@ -237,7 +237,7 @@ "ui-notification" ], "showPathInSidebar": false, - "showPageTitle": false, + "headerContent": "none", "navigationStyle": "icon", "titleBarStyle": "default" }, @@ -260,4 +260,4 @@ "density": "default" } } -] \ No newline at end of file +] diff --git a/docs/examples/ui-text-suffix.json b/docs/examples/ui-text-suffix.json index f5fcd2b49..cd3b1f9d6 100644 --- a/docs/examples/ui-text-suffix.json +++ b/docs/examples/ui-text-suffix.json @@ -109,7 +109,7 @@ "ui-notification" ], "showPathInSidebar": false, - "showPageTitle": false, + "headerContent": "none", "navigationStyle": "default", "titleBarStyle": "default" }, @@ -131,4 +131,4 @@ "widgetGap": "6px" } } -] \ No newline at end of file +] diff --git a/nodes/config/locales/en-US/ui_base.json b/nodes/config/locales/en-US/ui_base.json index 9ffb0c767..68e989808 100644 --- a/nodes/config/locales/en-US/ui_base.json +++ b/nodes/config/locales/en-US/ui_base.json @@ -25,7 +25,11 @@ "titleBarStyleFixed": "Fixed", "sidebar": "Sidebar Options", "showPath": "Include Page Path in Label", - "showPageTitle": "Show Page Name in Header", + "headerContent": "Content", + "headerDashboard": "Dashboard name", + "headerPage": "Page name", + "headerDashboardPage": "Dashboard name (Page name)", + "headerNone": "None", "navigationStyle": "Style", "navigationStyleDefault": "Collapsing (default)", "navigationStyleFixed": "Fixed", @@ -63,4 +67,4 @@ "darkest": "var(--nrdb-node-darkest)" } } -} \ No newline at end of file +} diff --git a/nodes/config/ui_base.html b/nodes/config/ui_base.html index 1269d0ceb..492da5b6f 100644 --- a/nodes/config/ui_base.html +++ b/nodes/config/ui_base.html @@ -339,8 +339,8 @@ showPathInSidebar: { value: false }, - showPageTitle: { - value: true + headerContent: { + value: 'page' }, navigationStyle: { value: 'default' @@ -370,12 +370,19 @@ $('#node-config-input-titleBarStyle').val('default') } - // backward compatibility for including page name - if (this.showPageTitle === undefined) { - // set to true - this.showPageTitle = true - // update the jquery checkbox - $('#node-config-input-showPageTitle').prop('checked', true) + // backward compatibility for including header content + // The headerContent replaces the old (boolean) showPageTitle + if (this.headerContent === undefined) { + let showPageTitle = (this.showPageTitle === undefined) ? true : this.showPageTitle + + if (showPageTitle) { + this.headerContent = 'page' + $('#node-config-input-headerContent').val('page') + } + else { + this.headerContent = 'none' + $('#node-config-input-headerContent').val('none') + } } if (this.appIcon) { @@ -2437,9 +2444,14 @@ -