Page MenuHomePhabricator

Make it less confusing to create root-level Phriction doc

Authored by amckinley on Dec 10 2018, 9:44 PM.



Without an existing root document, Phriction shows a nice little "fake" document as the landing page, which has its own nice "Edit this document" button. When showing that page, don't also render the standard "New Document" breadcrumb in the top right. That button always prompts first for a slug name, which is silly when the root document doesn't exist (because the slug name is required to be '').

Test Plan

Loaded Phriction with and without a root document.

Diff Detail

rP Phabricator
Automatic diff as part of commit; lint not applicable.
Automatic diff as part of commit; unit tests not applicable.

Event Timeline

amckinley created this revision.Dec 10 2018, 9:44 PM
amckinley requested review of this revision.Dec 10 2018, 9:46 PM
epriestley accepted this revision.Dec 10 2018, 9:49 PM

Maybe consider setIsWelcomeDocument() or setHideNewDocumentButton(), on first read it was a little surprising that the effect of showWelcomeDocument isn't to cause a welcome document to be shown.

This revision is now accepted and ready to land.Dec 10 2018, 9:49 PM
amckinley updated this revision to Diff 47429.Dec 10 2018, 10:00 PM

Change variable name.

This revision was automatically updated to reflect the committed changes.