Commit d091f5d1 authored by Eric Eastwood's avatar Eric Eastwood

Update submit button label to "Add"

Remove prop because it no longer contains "related issue" in it
and probably doesn't need to be customized anymore

See https://gitlab.com/gitlab-org/gitlab-ce/issues/34336
parent 6b46c47b
......@@ -12,10 +12,6 @@ export default {
type: String,
required: true,
},
addButtonLabel: {
type: String,
required: true,
},
pendingReferences: {
type: Array,
required: false,
......@@ -144,7 +140,7 @@ export default {
class="js-add-issuable-form-add-button btn btn-new pull-left"
@click="onFormSubmit"
:disabled="isSubmitButtonDisabled">
{{ addButtonLabel }}
Add
<loadingIcon
ref="loadingIcon"
v-if="isSubmitting"
......
......@@ -141,7 +141,6 @@ export default {
:is-submitting="isSubmitting"
:input-value="inputValue"
:pending-references="pendingReferences"
add-button-label="Add related issues"
:auto-complete-sources="autoCompleteSources" />
</div>
<div
......
......@@ -45,7 +45,6 @@ describe('AddIssuableForm', () => {
vm = new AddIssuableForm({
propsData: {
inputValue: '',
addButtonLabel: 'Submit',
pendingReferences: [],
},
}).$mount();
......@@ -62,7 +61,6 @@ describe('AddIssuableForm', () => {
vm = new AddIssuableForm({
propsData: {
inputValue: 'foo',
addButtonLabel: 'Submit',
pendingReferences: [],
},
}).$mount();
......@@ -76,13 +74,11 @@ describe('AddIssuableForm', () => {
describe('with references', () => {
const inputValue = 'foo #123';
const addButtonLabel = 'Add issuable';
beforeEach(() => {
vm = new AddIssuableForm({
propsData: {
inputValue,
addButtonLabel,
pendingReferences: [
issuable1.reference,
issuable2.reference,
......@@ -91,10 +87,6 @@ describe('AddIssuableForm', () => {
}).$mount();
});
it('should put button label in place', () => {
expect(vm.$refs.addButton.textContent.trim()).toEqual(addButtonLabel);
});
it('should put input value in place', () => {
expect(vm.$refs.input.value).toEqual(inputValue);
});
......@@ -113,7 +105,6 @@ describe('AddIssuableForm', () => {
vm = new AddIssuableForm({
propsData: {
inputValue: '',
addButtonLabel: 'Submit',
pendingReferences: [
issuable1.reference,
issuable2.reference,
......@@ -153,7 +144,6 @@ describe('AddIssuableForm', () => {
vm = new AddIssuableForm({
propsData: {
inputValue: '',
addButtonLabel: 'Add issuable',
pendingIssuables: [
issuable1,
],
......
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