Markdown Shortcut Keys
Problem to solve
When editing markdown text in a textbox, a user should be able to change the markup of the text by highlighting the text and pressing shortcut keys to change the markup. Table 1: Key Sequence to Markdown Formatting demonstrates example key sequences to markdown changes that would be desired based to allow for easy markdown editing for users.
Table 1: Key Sequence to Markdown Formatting
Key Sequence | Markdown Fromatting |
---|---|
ctrl + b | Bold |
ctrl + i | italics |
ctrl + alt + 1 | # Heading 1 |
ctrl + alt + 2 | ## Heading 2 |
ctrl + alt + 3 | ### Heading 3 |
ctrl + alt + 4 | #### Heading 4 |
ctrl + q | quote |
ctrl + l | (mylink)[https://mylink.com] |
ctrl + e | * my bulleted list |
ctrl + n | 1. my numbered list |
ctrl + t | * [ ] my tasked list |
Intended users
Anyone who has to write markdown text in Gitlab.
- Rachel (Release Manager)
- Parker (Product Manager)
- Delaney (Development Team Lead)
- Sasha (Software Developer)
- Presley (Product Designer)
- Devon (DevOps Engineer)
- Sidney (Systems Administrator)
- Sam (Security Analyst)
- Dana (Data Analyst)
- Simone (Software Engineer in Test)
- Allison (Application Ops)
Personas are described at https://about.gitlab.com/handbook/marketing/product-marketing/roles-personas/ -->
Further details
Proposal
My knowledge of web development is not very broad, but you should be able to detect when a user is editing a markdown text box and begin to listen for the markdown shortcuts and edit the textbox appropriately. I know the cursor position is able to be detected, I am not sure the capabilities of detecting what is highlighted within the page, but given the maturity of browsers today I would be surprised if the capability was not there.
It is recommended to perform appropriate surveys to assure that the appropriate keystrokes are decided correctly based on typical user experience across a broad range of products. Table 2: Key Sequence to Markdown Formatting that Are typical behaviors you will find in word processors like Microsoft Word.
Table 2: Key Sequence to Markdown Formatting that Are Typical
Key Sequence | Markdown Fromatting |
---|---|
ctrl + b | Bold |
ctrl + i | italics |
ctrl + alt + 1 | # Heading 1 |
ctrl + alt + 2 | ## Heading 2 |
ctrl + alt + 3 | ### Heading 3 |
ctrl + alt + 4 | #### Heading 4 |
Permissions and Security
No additional permissions and security needed.
Documentation
This change will likely need to be documented in (User Shortcuts)[https://docs.gitlab.com/ee/user/shortcuts.html].
Availability & Testing
Unit test changes should be sufficient for this issue, on the assumption of Gitlab's architecture this change should occur only in the frontend code.
What does success look like, and how can we measure that?
Success Metrics
-
The number of times the shortcuts are used * (the average time to type the formatting - the average time to type in the shortcut key sequence or press the buttons on the top right) = the amount of labor time saved of Gitlab customers
Acceptance Criteria
-
Given a user familiar with the typical shortcuts in word processing, without have seen the documented shortcuts for this issue listed in Gitlab's documentation, that the user should be able to guess 75% or more of the shortcuts available correctly -
Over 90% of markdown formatting options should be supported with key sequence shortcuts
What is the type of buyer?
Reasonably this should be core, it is not a very expensive request. This is a feature request from a current software developer. I know we are paying for licenses right now but I am not sure what tier.
Is this a cross-stage feature?
I am not sure, my assumption is no.