Can't expand/collapse categories in widget designer if category name is more than 2 words
I have an MVC Widget with many properties and category names such as "Personal Registration Content" and"Search Results Content" and "Tabs".
When I drop my widget on a page, click Edit, and choose the categorized view of the properties, I'm able to expand and collapse the "Tabs" category but not the other two. When I renamed the categories to "PersonalRegistration Content" and "SearchResults Content", I was able to then expand and collapse the categories. It appears that the bug is only when the category name has more than 2 words.
The Sitefinity Version is 7.0.5108.0.
Here's the exception and stack trace I found in my Chrome console when the categories failed to expand/collapse:
DOMException
code: 12
message: "Failed to execute 'webkitMatchesSelector' on 'Element': ':radio, :checkbox, select, option' is not a valid selector."
name: "SyntaxError"
stack: "Error: Failed to execute 'webkitMatchesSelector' on 'Element': ':radio, :checkbox, select, option' is not a valid selector.
at Error (native)
at Function.g.querySelectorAll.nt.matchesSelector (localhost:13303/ScriptResource.axd
at Function.v.extend.filter (localhost:13303/ScriptResource.axd
at v.fn.extend.is (localhost:13303/ScriptResource.axd
at HTMLFormElement.<anonymous> (localhost:13303/Telerik.Web.UI.WebResource.axd
at HTMLFormElement.v.event.dispatch (localhost:13303/ScriptResource.axd
at HTMLFormElement.o.handle.u (localhost:13303/ScriptResource.axd
Hi Bo,
This seems a bug for custom attributes and I have logged it in our Feedback portal.
As workaround and as you mentioned, you can remove the spaces and write the Category name PascalCase, for example:
[Category(
"MyCategoryName"
)]
public
string
HeaderText
get
;
set
;