Commit bf5163da authored by Enrique Alcántara's avatar Enrique Alcántara

Merge branch 'mfluharty-blob-viewer-button-group' into 'master'

Make blob viewer lock button group smoothly with other buttons

See merge request gitlab-org/gitlab!81851
parents 9fb971c2 9cafd899
......@@ -90,11 +90,8 @@ export default {
</script>
<template>
<span>
<gl-button :disabled="!canLock" :loading="lockLoading" @click="showModal">
{{ lockButtonTitle }}
</gl-button>
<gl-button :disabled="!canLock" :loading="lockLoading" @click="showModal">
{{ lockButtonTitle }}
<gl-modal
modal-id="lock-file-modal"
:visible="isModalVisible"
......@@ -108,5 +105,5 @@ export default {
{{ lockConfirmText }}
</p>
</gl-modal>
</span>
</gl-button>
</template>
......@@ -59,10 +59,10 @@ describe('LockButton component', () => {
isLocked | label
${false} | ${'Lock'}
${true} | ${'Unlock'}
`('renders the correct button labels', ({ isLocked, label }) => {
`('renders the $label button label', ({ isLocked, label }) => {
createComponent({ isLocked });
expect(findLockButton().text()).toBe(label);
expect(findLockButton().text()).toContain(label);
});
it('passes the correct prop if lockLoading is set to true', async () => {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment