frappe-ui 0.0.76 → 0.0.78
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
|
@@ -36,7 +36,20 @@
|
|
|
36
36
|
leave-to="opacity-0 translate-y-4 sm:translate-y-0 sm:scale-95"
|
|
37
37
|
>
|
|
38
38
|
<div
|
|
39
|
-
class="my-8 inline-block w-full
|
|
39
|
+
class="my-8 inline-block w-full transform overflow-hidden rounded-lg bg-white text-left align-middle shadow-xl transition-all"
|
|
40
|
+
:class="{
|
|
41
|
+
'max-w-7xl': options.size === '7xl',
|
|
42
|
+
'max-w-6xl': options.size === '6xl',
|
|
43
|
+
'max-w-5xl': options.size === '5xl',
|
|
44
|
+
'max-w-4xl': options.size === '4xl',
|
|
45
|
+
'max-w-3xl': options.size === '3xl',
|
|
46
|
+
'max-w-2xl': options.size === '2xl',
|
|
47
|
+
'max-w-xl': options.size === 'xl',
|
|
48
|
+
'max-w-md': options.size === 'md',
|
|
49
|
+
'max-w-lg': options.size === 'lg' || !options.size,
|
|
50
|
+
'max-w-sm': options.size === 'sm',
|
|
51
|
+
'max-w-xs': options.size === 'xs',
|
|
52
|
+
}"
|
|
40
53
|
>
|
|
41
54
|
<slot name="body">
|
|
42
55
|
<slot name="body-main">
|
|
@@ -76,7 +89,10 @@
|
|
|
76
89
|
</DialogTitle>
|
|
77
90
|
|
|
78
91
|
<slot name="body-content">
|
|
79
|
-
<p
|
|
92
|
+
<p
|
|
93
|
+
class="text-base text-gray-600"
|
|
94
|
+
v-if="options.message"
|
|
95
|
+
>
|
|
80
96
|
{{ options.message }}
|
|
81
97
|
</p>
|
|
82
98
|
</slot>
|
|
@@ -1 +1,5 @@
|
|
|
1
1
|
export { default } from './TextEditor.vue'
|
|
2
|
+
export { default as TextEditor } from './TextEditor.vue'
|
|
3
|
+
export { default as TextEditorBubbleMenu } from './TextEditorBubbleMenu.vue'
|
|
4
|
+
export { default as TextEditorFixedMenu } from './TextEditorFixedMenu.vue'
|
|
5
|
+
export { default as TextEditorFloatingMenu } from './TextEditorFloatingMenu.vue'
|
|
@@ -79,18 +79,9 @@ export function createListResource(options, vm, getResource) {
|
|
|
79
79
|
onSuccess(data) {
|
|
80
80
|
if (data.length > 0 && out.originalData) {
|
|
81
81
|
let doc = data[0]
|
|
82
|
-
|
|
83
|
-
out.originalData = out.originalData.filter(
|
|
84
|
-
(d) => d.name !== doc.name
|
|
85
|
-
)
|
|
86
|
-
out.originalData = [
|
|
87
|
-
out.originalData.slice(0, index),
|
|
88
|
-
data,
|
|
89
|
-
out.originalData.slice(index),
|
|
90
|
-
].flat()
|
|
82
|
+
updateRowInListResource(out.doctype, doc)
|
|
91
83
|
}
|
|
92
84
|
|
|
93
|
-
out.data = transform(out.originalData)
|
|
94
85
|
options.fetchOne?.onSuccess?.call(vm, out.data)
|
|
95
86
|
},
|
|
96
87
|
onError: options.fetchOne?.onError,
|
|
@@ -258,6 +249,7 @@ export function getCachedListResource(cacheKey) {
|
|
|
258
249
|
}
|
|
259
250
|
|
|
260
251
|
export function updateRowInListResource(doctype, doc) {
|
|
252
|
+
if (!doc.name) return
|
|
261
253
|
let resources = resourcesByDocType[doctype] || []
|
|
262
254
|
for (let resource of resources) {
|
|
263
255
|
if (resource.originalData) {
|