frappe-ui 0.1.247 → 0.1.249
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json
CHANGED
|
@@ -127,7 +127,7 @@
|
|
|
127
127
|
:disabled="dateObj.disabled"
|
|
128
128
|
@click="
|
|
129
129
|
!dateObj.disabled &&
|
|
130
|
-
|
|
130
|
+
handleDateCellClick(dateObj.date, togglePopover)
|
|
131
131
|
"
|
|
132
132
|
>
|
|
133
133
|
{{ dateObj.date.date() }}
|
|
@@ -268,7 +268,7 @@ const view = ref<ViewMode>('date')
|
|
|
268
268
|
const currentYear = ref<number>(dayjs().year())
|
|
269
269
|
const currentMonth = ref<number>(dayjs().month())
|
|
270
270
|
const DATE_FORMAT = 'YYYY-MM-DD'
|
|
271
|
-
const DATE_TIME_FORMAT = 'YYYY-MM-DD
|
|
271
|
+
const DATE_TIME_FORMAT = 'YYYY-MM-DD HH:mm:ss'
|
|
272
272
|
|
|
273
273
|
const selectedDate = ref<string>('') // YYYY-MM-DD
|
|
274
274
|
const timeValue = ref<string>('') // HH:mm:ss
|
|
@@ -94,7 +94,6 @@ const props = withDefaults(defineProps<TextEditorProps>(), {
|
|
|
94
94
|
tags: () => [],
|
|
95
95
|
})
|
|
96
96
|
|
|
97
|
-
const model = defineModel()
|
|
98
97
|
const emit = defineEmits<TextEditorEmits>()
|
|
99
98
|
|
|
100
99
|
const editor = ref<Editor | null>(null)
|
|
@@ -120,12 +119,10 @@ const editorProps = computed(() => {
|
|
|
120
119
|
})
|
|
121
120
|
|
|
122
121
|
watch(
|
|
123
|
-
() =>
|
|
124
|
-
(
|
|
125
|
-
const val = content || modelVal
|
|
126
|
-
|
|
122
|
+
() => props.content,
|
|
123
|
+
(val) => {
|
|
127
124
|
if (editor.value) {
|
|
128
|
-
|
|
125
|
+
let currentHTML = editor.value.getHTML()
|
|
129
126
|
if (currentHTML !== val) {
|
|
130
127
|
editor.value.commands.setContent(val)
|
|
131
128
|
}
|
|
@@ -156,7 +153,7 @@ watch(
|
|
|
156
153
|
|
|
157
154
|
onMounted(() => {
|
|
158
155
|
editor.value = new Editor({
|
|
159
|
-
content: props.content ||
|
|
156
|
+
content: props.content || null,
|
|
160
157
|
editorProps: editorProps.value,
|
|
161
158
|
editable: props.editable,
|
|
162
159
|
autofocus: props.autofocus,
|
|
@@ -240,9 +237,7 @@ onMounted(() => {
|
|
|
240
237
|
...(props.extensions || []),
|
|
241
238
|
],
|
|
242
239
|
onUpdate: ({ editor }) => {
|
|
243
|
-
|
|
244
|
-
emit('change', html)
|
|
245
|
-
model.value = html
|
|
240
|
+
emit('change', editor.getHTML())
|
|
246
241
|
},
|
|
247
242
|
onTransaction: ({ editor }) => {
|
|
248
243
|
emit('transaction', editor)
|