MediaWiki:Stenli

From Wikibase Personal data
Revision as of 10:19, 12 January 2020 by Stenli karanxha (talk | contribs) (Small formatting changes)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

Status

Currently all instance of (P3)-data controller (Q96) have a popup that appears with text "Do a GDPR SAR to this controller!". This is not flexible enough, as:

For more information on how this is achieved, see Architecture of SAR service.

Goal

Instead of a one-link popup with `mw.notify`, aim for introducing a form just below the name of a company (where User:Podehaye/mwhtml.js introduces material). This form will lead to several buttons, generated according to user characteristics (where they live, for instance). The form should rely on autocompletion client-side based on data stored in LocalStorage.

Intermediate goals

  1. Replace the popup to instead introduce content in the DOM where User:Podehaye/mwhtml.js does.
  2. Replace the mailto link by a basic form asking to enter first name, last name.
  3. Improve the (auto generated) form to ask also for the data specified in the page through requires (P122).
  4. Rely on data stored somewhere in protected user script space to autocomplete.
  5. Rely on LocalStorage.

There have been some initial efforts at using LocalStorage, detailed in Development of SAR service. However, this relied on some initial fairly nasty code. I think the code behind MediaWiki:Gadget-QuickPresets.js is much more neatly structured and helpful for the non-LocalStorage parts.

Instructions

The goal of the work is not only to achieve the objectives, but also to catalyze a community of developers helping towards those goals. Therefore documentation is crucial.

Tasks

  • Read through User:Podehaye/mwhtml.js, MediaWiki:Gadget-QuickPresets.js, Architecture of SAR service, Development of SAR service (and scripts documented therein) to see all the different ways already used to implement at the interface of Javascript, SPARQL and Wikibase. This *needs* to happen on the wiki, ideally in the MediaWiki namespace (but we can easily start here and then cannibalize). Link heavily to Wikidata/Wikipedia/WikiMedia Foundation properties wherever possible. There should be two layers to this doc: the different ways one can use (atomic techniques), and how these ways are bundled to create specific solutions (e.g. described at MediaWiki:Gadget-QuickPresets/doc). Currently the doc mixes both layers often, which reduces modularity.
  • Get started on intermediate goals.

Process documentation

The development process for each task will be documented, to be used as a blueprint / todo list for future implementations.

Replace pop-up with DOM modification
Replace mailto link with a form
Integrate in the form data specified in the page
Use data stored in a protected script to autocomplete
Use LocalStorage

Product documentation

The finished products (templates, gadgets) will be documented in their own pages, with links included here for completeness.