Skip to content

Commit

Permalink
Allow hardcoded values and resource bindings in IncludeInPage, Visibl…
Browse files Browse the repository at this point in the history
…e properties

It only produced a warning, but still,
hardcoded values and resource bindings are already supported
in both properties.
  • Loading branch information
exyi committed Aug 2, 2023
1 parent f059d47 commit 7ecda72
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 6 deletions.
2 changes: 1 addition & 1 deletion src/Framework/Framework/Controls/DotvvmControl.cs
Original file line number Diff line number Diff line change
Expand Up @@ -115,7 +115,7 @@ public ClientIDMode ClientIDMode
/// <remarks>
/// Essentially wraps Knockout's 'if' binding.
/// </remarks>
[MarkupOptions(AllowHardCodedValue = false)]
[MarkupOptions]
public bool IncludeInPage
{
get { return (bool)GetValue(IncludeInPageProperty)!; }
Expand Down
2 changes: 1 addition & 1 deletion src/Framework/Framework/Controls/HtmlGenericControl.cs
Original file line number Diff line number Diff line change
Expand Up @@ -133,7 +133,7 @@ public string? InnerText
/// <summary>
/// Gets or sets whether the control is visible. When set to false, `style="display: none"` will be added to this control.
/// </summary>
[MarkupOptions(AllowHardCodedValue = false)]
[MarkupOptions]
public bool Visible
{
get { return (bool)GetValue(VisibleProperty)!; }
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -564,8 +564,7 @@
},
"IncludeInPage": {
"type": "System.Boolean",
"defaultValue": true,
"onlyBindings": true
"defaultValue": true
}
},
"DotVVM.Framework.Controls.EmptyData": {
Expand Down Expand Up @@ -1016,8 +1015,7 @@
},
"Visible": {
"type": "System.Boolean",
"defaultValue": true,
"onlyBindings": true
"defaultValue": true
}
},
"DotVVM.Framework.Controls.HtmlLiteral": {
Expand Down

0 comments on commit 7ecda72

Please sign in to comment.