Feature: The letter navigation knows which letters lead somewhere
Description
The letter navigation of the profile list and list-and-detail plugins offered
all 26 letters, whether or not a single profile would be listed under them.
The list action now tells its template which letters lead to a list that is not
empty: the new template variable alphabet maps each letter from
a to z to a boolean.
It is computed under exactly the constraints of the list itself - storage
folders, the function type and organisational unit filters of the content
element, the hidden records setting, the language and its fallback, enable
fields and workspace, and what listeners of
Modify and
Modify add - but without the letter a visitor selected,
so the active letter never narrows the others. It takes one database statement,
and it is computed only while the content element has the navigation switched on
and no profiles are selected by hand.
The repository method behind it is public:
Profile.
Impact
A project template can read alphabet to render a letter without
profiles differently.
Modify and
Modify are
dispatched twice for a list that shows the navigation - once for the list, once
for its letters. A listener that narrows the list narrows the letters as long
as it answers both calls alike.
The letters do not reflect a listener of
Modify that
assigns other profiles to the view, and in a workspace preview a profile deleted
or hidden only in the workspace still makes its letter available - the same
precision as the list's pagination count. See Which letters lead somewhere.