Customize edit button in code flow file header
What does this MR do and why?
Customize edit button in code flow file header
Move variant-deciding logic from `web_ide_link.vue` to `blob_header.vue`
so that we can override it for the code flow file viewer `<blob-header>`
Changelog: changed
EE: true
References
Please include cross links to any resources that are relevant to this MR. This will give reviewers and future readers helpful context to give an efficient review of the changes introduced.
- issue: Follow-up from Add the right side of 'code flow... (#475022 - closed) • Miranda Fluharty • 17.7 • On track
- original discussion: !158532 (comment 2020646152)
- storybook documentation: https://docs.gitlab.com/ee/development/fe_guide/storybook.html
MR acceptance checklist
Please evaluate this MR against the MR acceptance checklist. It helps you analyze changes to reduce risks in quality, performance, reliability, security, and maintainability.
Screenshots or screen recordings
| Before | After |
|---|---|
blue confirm-variant Edit button in file header |
white default-variant Edit button in file header |
How to set up and validate locally
git checkout 475022-code-flow-use-default-variant-for-edit-button
- set up Advanced SAST scanning for a project - clone this test project to get started
- run a pipeline for the default branch - the
gitlab-advanced-sastjob should run and find some vulnerabilities (here's a troubleshooting guide in case it doesn't) - navigate to the project, and in the sidebar choose
Secure=>Vulnerability report - click on the "Improper neutralization..." vulnerability
- click on the
Code flowtab - check that the
Editbutton uses thedefaultstyling (see screenshots)
to run tests
yarn install && yarn jest code_flow web_ide_link
Related to #475022 (closed)
Edited by Miranda Fluharty

