The Parsoid error messages are missing a couple of parameters, according
to the json i18n files; this patch fixes that issue.
Change-Id: I4232c0b71ecc6d6f1220db3988e67d9cd4eb3d58
This makes the dialog's behavior much more robust, especially when
confronted with overly long and complex references.
* Limit the height of list items to avoid the situation where a
single item overflows the dialog. This makes it especially hard
to navigate with the cursor keys. We can't see any more what's
going on. The proposed height is intentionally a very high upper
bound, equivalent to about 2/3 of the dialog's height.
* Limit the name on the right side to take up less than half of an
item. The left side is for the content. Usually the names are very
short anyway. But if a name is long it currently creates a mess
where the name is intertwined with the content.
* Break overly long words in references.
* Changing the opacity to use upstream values makes the dimmed names
a bit darker. I think this is good, even necessary for legibility.
Technical changes:
* Use LESS variables from upstream, where possible.
* Remove redundant `relative` already set upstream.
Bug: T372385
Change-Id: Ie59b7b7e4aa7eadc8f82b39884313f5aa8cfd950
I think that the message is more clear when it starts with the
subject we're describing. That also seems to be the case in other
messages here.
It also aligns with the wording in referenceslist-missing-parent:
"There are subreferences with a missing parent reference."
Bug: T372871
Change-Id: If9a49faccb6cbe2000b15a2d28bd66565cce0e90
Pushes per-group knowledge down into a structured object and give it
an interface, separated from the singleton cache across all groups.
Also changes the behavior of orphaned subrefs so that they're still
rendered as subrefs, with an error placeholder where the parent
should be.
Bug: T372871
Change-Id: I84e679a8365f3fbfabaf344d99f56f6d069c0776
Based on the mobile version evaluation in task T370876, indentation is aligned for subrefs in the reflist for mobile view to match the web version
Bug: T371666
Change-Id: I40a3fe0b9cc607365e0ead26cf554921fe0abc5b
Caller can be more ignorant about what happens inside the mock.
Mostly, this patch is meant to prepare for an internal refactor,
minimizing test changes.
Bug: T372871
Change-Id: Ie08624fea4a89ce6a6f61d5430cf5b7eb95278fa
The model is now fully owned by the edit panel and I could not find
any usages of this outside of that class using codesearch.
Bug: T369005
Change-Id: I911fee99d6c910e6e40e0b3cbdb4c7ab60b413c6
Making sure that change events form the fields are handled in the
panel and forwarded to the dialog with the information needed.
Also slighly moving some calls in the setup process that inits
the dialog and removing some duplication. Calling focus on the
edit panel only makes sense in the ready step. Not during setup.
Bug: T369005
Change-Id: I4f9a022a06ec6543b106620eae030235b8f6712b
This moves existing code around a little bit without changing
anything, as proven by the tests.
This is motivated by Iaca0e14.
Change-Id: I30366d32b07f87f238b045f0d7817686b5cc26bd
It's always a string anyway. Also improve the test coverage. The
localization was pretty much untested before.
Change-Id: Ie6f34c67ae7dd9559346eb45a2604e14c5633991
The main benefit is that this makes it more obvious what is actually
under test, and what's not.
This is mainly motivated by the ongoing work in Iaca0e14.
Change-Id: Icbf1b824ba1f5468dbdb30445134db2b568e19f8
That's another step to separate the editing form the dialog. The dialog should not know about internals of the edit panel.
And eventually the dialog can get rid of the referenceModel property.
Bug: T369005
Change-Id: I9cf3a68ef58bc5791497af362c0572734e4bcadd
The message cite_references_link_many_format_backlink_labels contains
e.g. "a b c …" and so on, to be used as alternative backlink labels
when a single reference is re-used multiple times. The default numeric
rendering is "1.1 1.2 …" and so on.
The two labels end in the message cite_references_link_many_format as
parameters $2 and $3. But only one of the two parameters is ever used.
By default the alternative label in $3 is unused.
This implies that everything about these alternative backlink labels
including the error message is effectively dead code most of the time,
never to be seen on the majority of wikis.
This change makes it possible to disable the message without breaking
anything. Instead the code will silently fallback to the default
behavior of showing the numeric label. This is much more efficient
than rendering possibly hundreds of error messages that never show
up anyhere. The same optimization is already done for the extremely
similar cite_link_label_group-… messages, see
FootnoteMarkFormatter::fetchCustomizedLinkLabel.
This is also partly motivated by T335129 as well as T321217.
Change-Id: Iab818d7db7eddaf7091234f6a22a18cdff70f8e8
This is a direct follow up for I6f05842 where we already started
supporting dashes, but converted them to underscores. The only change
in this patch is that the CSS class will use the message key as it
is, without the dashes being converted to underscores. I added a test
case specifically for this.
Bug: T352676
Change-Id: Ic22e897c27b8371e3b1ed63932b619e7af71bd5c