[SettingsControls] Switch to object type for ItemTemplate property#417
Conversation
|
@dotnet-policy-service agree |
niels9001
left a comment
There was a problem hiding this comment.
Tested.. works great. Great job @yourordinarycat :)!
This can be merged once the XAML styler issue is resolved:
D:\a\Labs-Windows\Labs-Windows\ApplyXamlStyling.ps1 : XAML Styling is incorrect, please run locally:
ApplyXamlStyling.ps1 -Main
If you run ApplyXamlStyling.ps1 -Main and push the changes CI should pass :)
|
Should pass now - as an aside, is there something I'm missing from my setup? The script was failing initially: I could fix it by replacing line 100:
With:
Not sure if it's just a me thing, but it did work, so it should be good for now~ |
|
@yourordinarycat Running |


The ItemsRepeater.ItemTemplate property allows using a
DataTemplate,DataTemplateSelectororIElementFactory. This is quite convenient to have, and to allow for this, the property is of typeIInspectable(and from C# we seeobject:D)SettingsExpanderhas anItemTemplateproperty as well, but it only allows setting aDataTemplate, and because of the lack of extra properties in theItemsRepeater, it's not possible to use a template selector or element factory. This PR addresses the problem by switching to object for theItemTemplateproperty.