From 82b9f5cf0e72d31b6fa8576e99b0f51de4910a9b Mon Sep 17 00:00:00 2001 From: Raphael Beer Date: Mon, 13 Apr 2020 15:13:59 +0200 Subject: [PATCH] Change: default :autosave to false --- webapp/components/Editor/Editor.spec.js | 10 ++++++---- webapp/components/Editor/Editor.vue | 2 +- 2 files changed, 7 insertions(+), 5 deletions(-) diff --git a/webapp/components/Editor/Editor.spec.js b/webapp/components/Editor/Editor.spec.js index 332af9035..149124d44 100644 --- a/webapp/components/Editor/Editor.spec.js +++ b/webapp/components/Editor/Editor.spec.js @@ -161,14 +161,14 @@ describe('Editor.vue', () => { beforeAll(() => jest.useFakeTimers()) afterAll(() => jest.useRealTimers()) - describe('when false', () => { + describe('when false (default)', () => { const content = '

NOOP WIP

' beforeEach(async () => { propsData = { // // plugin ignores all changes (transactions) on this instance - autosave: false, + // autosave: false (default) } mocks = { $t: (t) => t, @@ -192,7 +192,7 @@ describe('Editor.vue', () => { beforeEach(async () => { propsData = { - // :autosave defaults to true + autosave: true, } mocks = { $t: (t) => t, @@ -239,7 +239,9 @@ describe('Editor.vue', () => { const content = '

Comment WIP

' beforeEach(async () => { - propsData = {} + propsData = { + autosave: true, + } mocks = { $t: (t) => t, } diff --git a/webapp/components/Editor/Editor.vue b/webapp/components/Editor/Editor.vue index 93bb39c0f..137ab669c 100644 --- a/webapp/components/Editor/Editor.vue +++ b/webapp/components/Editor/Editor.vue @@ -54,7 +54,7 @@ export default { users: { type: Array, default: () => null }, // If 'null', than the Mention extention is not assigned. hashtags: { type: Array, default: () => null }, // If 'null', than the Hashtag extention is not assigned. doc: { type: Object, default: () => {} }, - autosave: { type: Boolean, default: true }, + autosave: { type: Boolean, default: false }, value: { type: String, default: '',