Change: default :autosave to false

This commit is contained in:
Raphael Beer 2020-04-13 15:13:59 +02:00
parent 726a34a30c
commit 82b9f5cf0e
No known key found for this signature in database
GPG Key ID: C1AC5E018B25EF11
2 changed files with 7 additions and 5 deletions

View File

@ -161,14 +161,14 @@ describe('Editor.vue', () => {
beforeAll(() => jest.useFakeTimers())
afterAll(() => jest.useRealTimers())
describe('when false', () => {
describe('when false (default)', () => {
const content = '<p>NOOP WIP</p>'
beforeEach(async () => {
propsData = {
// <hc-editor :autosave="false" />
// 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 = '<p>Comment WIP</p>'
beforeEach(async () => {
propsData = {}
propsData = {
autosave: true,
}
mocks = {
$t: (t) => t,
}

View File

@ -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: '',