[go: up one dir, main page]

Skip to content

Rearrange and introduce overflow menu to single file page

This issue looks at updating the changes to the single file/blob view so that button are rearranged and simplified so that the page is more focused.

Changes to the top area are common both to the directory and single file/blob view and are handled in this epic Common directory and blob page structure changes (&13018).

Current Proposal
image image

Overflow menu

Move the following actions into an overflow menu:

  • Copy permalink: copies permalink to clipboard. Current behaviour updates the URL of browser to permalinke
    • On copy should display toast saying "Copied permalink"
  • Lock file: same flow as current
  • Replace file: same flow as current
  • Delete file: same flow as current
Edit menu (no changes) Overflow menu
image image

Narrow viewport experience

The narrow viewport experience currently displays a lot of buttons and without a proper layout system the button groups do not rearrange in the most optimal manner.

Showing two versions here "Markdown" and a code file because of the extra "preview" and "TOC" dropdown that appears for a Markdown file.

Current - Narrow viewport Markdown Proposal - Narrow viewport Markdown
image update - file - mobile-3.jpg
Current - Narrow viewport code Proposal - Narrow viewport code
image update - file - mobile-4.jpg

Narrow viewport actions menu

For consistency between the different types of files (those with preview and those without), the proposed update moves the action of "Copy file contents", "Open raw" and "Download" to the Actions dropdown menu.

update - file - mobile-2.jpg

Edited by Alyssa Trinh