Closed larsyencken closed 1 year ago
This is an exploration of using Gsheet as the replacement fro Wordpress admin features, starting with the publication workflow.
An example spreadsheet for managing articles and their publication
sequenceDiagram
Author ->> Gdocs: write draft
Author ->> Gsheet: register article
Author ->> Gsheet: publish article
Gsheet ->> Gsheet: run appscript
Gsheet ->> Baker: send baking request w/ document ID
Baker ->> Gdocs: get document content
Gdocs -->> Baker: receive document content
Baker ->> Baker: process ArchieML
Baker ->> Grapher DB: save JSON
Baker ->> Baker: bake site
Authors write ArchieML documents in Gdocs, then list them with their metadata in the companion spreadsheet.
Gsheet as an admin for managing articles is not convincing. Favour tighter integration in bespoke admin.
With most of the article metadata pushed to the document frontmatter, there is little to no content left in this sheet. This makes the value of spreadsheet functions and scripting features equally limited. Versioning and commenting are probably among the most salient features spreadsheet offer (incidentally not specific to the format), but fail to outweigh the benefit of tighter relationships between charts and articles (including referential integrity), a visible and well-known limitation of the current system.
Roughly by order of importance
Pros
Cons
Admin screen for managing google docs based articles (lo-fi wireframe)
Done with Lo-Fi Wireframe Kit
Wireframe update:
graph LR
A{Is published} -->|Yes| D
A -->|No| B[fa:fa-cloud-upload-alt Publish]
D{Has updates} -->|Yes| C[fa:fa-redo-alt Update]
D{Has updates} --> F[Unpublish]
Wireframe update:
Wireframe update:
In order to simplify the publishing workflow for authors, we want the slug to be automatically derived from the title upon publishing
Source of truth
With the slug edited in the admin, we can...
... in a more straightforward way than if the slug was typed in as text in the document frontmatter. It also promotes a tighter feedback loop for errors or suggestions.
With the slug edited in the admin, authors can carry out all publication workflow related tasks in the same place, instead of going back and forth between the document (for editing metadata) and the admin (for validation).
Status update (Tues 13th)
With the biggest part of the UI / UX work done on Admin for managing Google Docs articles, I'm moving more confidently on the implementation of the basic publication flow this week, including:
I'm aiming to get the happy path handled by the end of the week, to run through a first feedback cycle during cooldown. The rest will most likely span over 2/3 of the next cycle, giving one (maybe two) additional opportunities for feedback. Some of the "source of truth" discussions haven't fully landed yet. This brings a layer of uncertainty which we should account for.
Status update (Sep 14)
A demo a of the (now abandoned) early implementation of the wireframes above (commit from Sep 14)
Feedback from individual sessions with @larsyencken (Sept 20) and @eoo-owid (Sept 22):
Status update Thu 29
After experimenting with editing the title in the admin, I'm bringing it back to the google doc. The split is roughly:
By keeping the content metadata in the google doc, authors get to save more complete drafts of published articles, including the content metadata. Otherwise, when the content metadata is saved in the admin, authors have to publish straightaway or discard their changes - as changes to published articles cannot be saved. Keeping content metadata in the google doc might also make it easier to leave comments related to these fields, although this has been deemed a minor concern thanks to the :skip section.
The slug will remain in the admin.
Another dimension for these source of truth considerations is the complexity of the data being entered. Titles are simple strings but authors or categories might benefit from a tighter integration in the admin, to provide a better editing UX as well as enforcing referential integrity between e.g. articles and their categories. As an example, this would prevent deleting a category used by an article and also allow for renaming categories across all articles.
Status update on current cycle scope - Oct 7 For @larsyencken, @mathisonian
nice to have
Notify when leaving the page with unsaved edits in non-gdocs metadata. Gdocs metadata is saved either way in gdocs, so nothing is lost if the preview is closed with unpublished changes - which is not the case for non-gdocs metadata.Thanks for the update Matthieu, looks like it's coming together.
Can you please update the issue summary at the top, and perhaps reorganise the checklist into things that are completed on-branch vs things that have passed review and shipped?
For this project, it would probably look like this:
Status update - Oct 13
This was the last remaining item in scope. PR opened: https://github.com/owid/owid-grapher/pull/1703
(original description by @mlbrgl)
As part of the migration from Wordpress to google docs (#1597), we're replacing the Wordpress block editor with Google docs.
Beyond editing documents, Wordpress provides some non-editor features, such as publication workflows, media management, document management or category management.
This issue aims at filling some of this gap, starting with document management. Other candidate CMS features of the current set-up can be found in the CMS glossary, which will serve as a basis for migration decisions around CMS features.
A possible approach has been developed in the https://github.com/owid/owid-show experiment and might be ported over to https://github.com/owid/owid-grapher. Some other approaches will be considered as well, in anticipation of the port of all remaining CMS features into this new foundation.
Cycle 2022.5 (Aug 29 -> Sep 16)
Wireframes, background work
Cycle 2022.6 (Sep 26 -> Oct 14)
Completed on branch, awaiting PR review
Merged and shipped ⏳
Additional scope