Class SerenityHubCatalogGrouper
Derives a display group for a catalog entry from its real MenuPath, so Create/Browse/Advanced can
render grouped Foldout sections instead of one flat grid (UX feedback round 4) without a new catalog field
to maintain — the existing Tools/Serenity/... menu taxonomy already encodes the domain.
Rule: split the path after Tools/Serenity/. When the first remaining segment matches the entry's own
SerenityHubCategory (the common case — a Create entry filed under
Tools/Serenity/Create/Audio/...), the group is the next segment down ("Audio"), or
GeneralGroupName when that category segment is immediately followed by the entry's own title
with no intermediate segment between them. When the first segment does NOT match the category (an Advanced
entry filed under its real home, e.g. Tools/Serenity/Docs/... or Tools/Serenity/Validate/...),
the group is that first segment itself, regardless of how many more segments the path has. A path with only
one segment after Tools/Serenity/ at all (no domain folder, e.g. Tools/Serenity/Clone
Directory) has nothing to derive a group from and falls into GeneralGroupName.
Inheritance
SerenityHubCatalogGrouper
Assembly: Serenity.UnityLocalization.Installation.Editor.dll
Syntax
public static class SerenityHubCatalogGrouper
Fields
GeneralGroupName
Declaration
public const string GeneralGroupName = "General"
Field Value
Methods
Declaration
public static IReadOnlyList<SerenityHubCatalogGroup> GroupByMenuPath(IReadOnlyList<SerenityHubToolEntry> entries)
Parameters
Returns
ResolveGroupName(SerenityHubToolEntry)
Resolves the single group entry belongs to.
Declaration
public static string ResolveGroupName(SerenityHubToolEntry entry)
Parameters
Returns