As an editor on the client I want to be warned if I can't make an edit on the repository in order to not waste my time.
Problem:
The Item where the statement is coming from might be protected on the repository or the editor might be blocked. In this case we want to tell them that they can't edit the statement they are trying to edit.
We have 3 cases that can happen:
- The item is fully protected
- The item is semi-protected
- The user is blocked on Wikidata
Screenshots/mockups:
more details in figma mock
Desktop - Fully protected
Desktop - Semi-protected
Desktop - Blocked on repository
Mobile version (please note that typography switches to 16px size/24px line-height on mobile)
(Blocked on client +) blocked on repo+ protected on repo
Desktop - Cascade protection client
Desktop - Cascade protection repo
Links in mocks
- fully protected: $repourl/wiki/Project:Page_protection_policy
- administrator(s): $repourl/wiki/Project:Administrators
- protected: $repourl/wiki/Project:Page_protection_policy
- protection log: $repourl/wiki/Special:Log/protect?page=Q$
- editing disputes: $repourl/wiki/Project:Edit_warring
- discuss this item: link to discussion page of respective item
- semi-protected: $repourl/wiki/Project:Page_protection_policy
- autoconfirmed/confirmed users: $repourl/wiki/Project:Autoconfirmed_users
- log in: link to the client's log in page
- create an account on $repoName: link to the client's account creation page (side-note from charlie: not sure about this one since editors might think that this is where they'll need to make the edits to get autoconfirmed but then still won't be able to edit since the auto confirmation happened on the wrong wiki)
BDD
GIVEN a protected Item
WHEN a user without the necessary edit rights tries to edit it in the bridge
THEN an error message is shown when opening the bridge
AND the edit can't be performed
GIVEN an editor that is blocked on the repository
WHEN they try to edit in the bridge
THEN an error message is shown when opening the bridge
AND the edit can't be performed
Acceptance criteria:
- loading bar is replaced by error message as soon as possible (but abiding by the constraints listed in this ticket T232468) due to any of the reasons listed
- the editability status depends on the Item the statement is coming from (which is not necessarily the one connected to the article via the sitelink)
- These screens do not have a save button
- The green-blueish side margin outlined on the specs must always be respected: margin sizes will not change due to text size changes
- In case of triple error, notifications should be displayed following the order established by the designs: blockage on client + blockage on repo + item protection
- Error notifications are accompanied by an expandable link component (find specs in WiKit): the link displays the error details on click/press
- In case only a single message is displayed, then the expandable link is activated by default (error details are displayed) (See example "Desktop - Fully protected")
- In case of a negative permission result (i.e. when showing the error(s)), the opening of bridge should not be tracked (as implemented in T231204).