Page MenuHomePhabricator

Javascript users can change file text on the same page
Open, Needs TriagePublic13 Estimated Story Points

Description

Motivation
Javascript users should not have to switch the page for changing the file text. Instead, the same behaviour that is currently active on the sub page should be happening on the same page.

Mock

Bildschirmfoto 2019-05-21 um 13.24.01.png (382×992 px, 59 KB)

Acceptance Criteria

  • When a user with javascript clicks on "Edit file info", the editor opens inline
    • If the user clicks cancel, the file info is being shown that was displayed when "edit file info" was clicked
    • If the user clicks "Change file info", the new version is being displayed. however, the file is only actually changed when moving the whole file.
    • The HTML for the preview will be re-rendered
    • The category preview should update accordingly

Notes

  • General parsing of the wikitext can be done via api call, see TwoColConflict for example
  • Since we do our "own" category parsing we need to figure out the JS implementation for that
    • parse API might give us the categories for free ( apart from hidden categories )
    • hidden cats can be get from the API as well

Event Timeline

WMDE-Fisch set the point value for this task to 13.

The parse API is able to return the categories both as a list as well as HTML. In both cases the hidden categories are clearly flagged. If we can actually use the HTML version or need to iterate the list of category names is an open question. Example: https://en.wikipedia.org/wiki/Special:ApiSandbox#action=parse&format=json&text=%5B%5BCategory%3AAccuracy%20disputes%20from%20June%202014%5D%5D&prop=text%7Ccategories%7Ccategorieshtml