@adminforth/markdown 1.2.6 → 1.2.8
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/build.log +2 -2
- package/custom/MarkdownEditor.vue +79 -2
- package/dist/custom/MarkdownEditor.vue +79 -2
- package/dist/index.js +3 -1
- package/index.ts +4 -2
- package/package.json +1 -1
package/build.log
CHANGED
|
@@ -10,5 +10,5 @@ custom/package-lock.json
|
|
|
10
10
|
custom/package.json
|
|
11
11
|
custom/tsconfig.json
|
|
12
12
|
|
|
13
|
-
sent
|
|
14
|
-
total size is
|
|
13
|
+
sent 171,313 bytes received 115 bytes 342,856.00 bytes/sec
|
|
14
|
+
total size is 170,853 speedup is 1.00
|
|
@@ -186,9 +186,9 @@ onBeforeUnmount(() => {
|
|
|
186
186
|
});
|
|
187
187
|
</script>
|
|
188
188
|
|
|
189
|
-
<style>
|
|
189
|
+
<style lang="scss">
|
|
190
190
|
#editor [contenteditable="true"] {
|
|
191
|
-
@apply bg-transparent outline-none border-none shadow-none transition-none min-h-10 p-2
|
|
191
|
+
@apply bg-transparent outline-none border-none shadow-none transition-none min-h-10 p-2;
|
|
192
192
|
}
|
|
193
193
|
|
|
194
194
|
#editor [contenteditable="true"].is-focused {
|
|
@@ -224,4 +224,81 @@ onBeforeUnmount(() => {
|
|
|
224
224
|
}
|
|
225
225
|
|
|
226
226
|
|
|
227
|
+
.editor, .milkdown {
|
|
228
|
+
border-radius: 6px;
|
|
229
|
+
}
|
|
230
|
+
|
|
231
|
+
.ProseMirror [data-placeholder]::before {
|
|
232
|
+
color: #6b7280;
|
|
233
|
+
}
|
|
234
|
+
|
|
235
|
+
.milkdown milkdown-block-handle .operation-item:hover {
|
|
236
|
+
@apply bg-gray-200 dark:bg-gray-600;
|
|
237
|
+
}
|
|
238
|
+
|
|
239
|
+
.milkdown milkdown-slash-menu .tab-group ul li:hover {
|
|
240
|
+
@apply bg-gray-200 dark:bg-gray-600;
|
|
241
|
+
}
|
|
242
|
+
|
|
243
|
+
.milkdown milkdown-toolbar {
|
|
244
|
+
@apply bg-gray-50 border border-gray-300 text-gray-900 dark:bg-gray-700 dark:border-gray-600 dark:placeholder-gray-400 dark:text-white;
|
|
245
|
+
}
|
|
246
|
+
|
|
247
|
+
.milkdown milkdown-toolbar .toolbar-item:hover {
|
|
248
|
+
@apply bg-gray-200 dark:bg-gray-600;
|
|
249
|
+
}
|
|
250
|
+
|
|
251
|
+
.milkdown milkdown-latex-inline-edit {
|
|
252
|
+
@apply bg-gray-200
|
|
253
|
+
}
|
|
254
|
+
|
|
255
|
+
.milkdown milkdown-latex-inline-edit .container button:hover {
|
|
256
|
+
@apply bg-gray-300 dark:bg-gray-500;
|
|
257
|
+
}
|
|
258
|
+
|
|
259
|
+
.milkdown milkdown-link-edit > .link-edit {
|
|
260
|
+
@apply bg-gray-50 border border-gray-300 text-gray-900 dark:bg-gray-700 dark:border-gray-600 dark:placeholder-gray-400 dark:text-white;
|
|
261
|
+
}
|
|
262
|
+
|
|
263
|
+
.milkdown milkdown-code-block .cm-editor {
|
|
264
|
+
@apply bg-gray-50 border border-gray-300 text-gray-900 dark:bg-gray-700 dark:border-gray-600 dark:placeholder-gray-400 dark:text-white;
|
|
265
|
+
}
|
|
266
|
+
|
|
267
|
+
.ͼo .cm-activeLineGutter {
|
|
268
|
+
@apply bg-gray-200 dark:bg-gray-600;
|
|
269
|
+
}
|
|
270
|
+
|
|
271
|
+
.ͼo .cm-activeLine {
|
|
272
|
+
@apply bg-gray-200 dark:bg-gray-600;
|
|
273
|
+
}
|
|
274
|
+
|
|
275
|
+
.cm-content {
|
|
276
|
+
padding-left: 0px !important;
|
|
277
|
+
padding-right: 0px !important;
|
|
278
|
+
}
|
|
279
|
+
|
|
280
|
+
.milkdown milkdown-code-block .list-wrapper {
|
|
281
|
+
@apply bg-gray-50 border border-gray-300 text-gray-900 dark:bg-gray-700 dark:border-gray-600 dark:placeholder-gray-400 dark:text-white;
|
|
282
|
+
}
|
|
283
|
+
|
|
284
|
+
.milkdown milkdown-code-block .language-list-item:hover {
|
|
285
|
+
@apply bg-gray-200 dark:bg-gray-600;
|
|
286
|
+
}
|
|
287
|
+
|
|
288
|
+
.milkdown milkdown-code-block .tools .language-button {
|
|
289
|
+
@apply bg-gray-50 border border-gray-300 text-gray-900 dark:bg-gray-700 dark:border-gray-600 dark:placeholder-gray-400 dark:text-white;
|
|
290
|
+
}
|
|
291
|
+
|
|
292
|
+
.milkdown milkdown-code-block .tools .language-button:hover {
|
|
293
|
+
@apply bg-gray-200 dark:bg-gray-600;
|
|
294
|
+
}
|
|
295
|
+
|
|
296
|
+
.milkdown::selection {
|
|
297
|
+
background-color: #6b7280;
|
|
298
|
+
}
|
|
299
|
+
|
|
300
|
+
.ͼ4 .cm-line ::selection, .ͼ4 .cm-line::selection {
|
|
301
|
+
background-color: #6b7280 !important;
|
|
302
|
+
}
|
|
303
|
+
|
|
227
304
|
</style>
|
|
@@ -186,9 +186,9 @@ onBeforeUnmount(() => {
|
|
|
186
186
|
});
|
|
187
187
|
</script>
|
|
188
188
|
|
|
189
|
-
<style>
|
|
189
|
+
<style lang="scss">
|
|
190
190
|
#editor [contenteditable="true"] {
|
|
191
|
-
@apply bg-transparent outline-none border-none shadow-none transition-none min-h-10 p-2
|
|
191
|
+
@apply bg-transparent outline-none border-none shadow-none transition-none min-h-10 p-2;
|
|
192
192
|
}
|
|
193
193
|
|
|
194
194
|
#editor [contenteditable="true"].is-focused {
|
|
@@ -224,4 +224,81 @@ onBeforeUnmount(() => {
|
|
|
224
224
|
}
|
|
225
225
|
|
|
226
226
|
|
|
227
|
+
.editor, .milkdown {
|
|
228
|
+
border-radius: 6px;
|
|
229
|
+
}
|
|
230
|
+
|
|
231
|
+
.ProseMirror [data-placeholder]::before {
|
|
232
|
+
color: #6b7280;
|
|
233
|
+
}
|
|
234
|
+
|
|
235
|
+
.milkdown milkdown-block-handle .operation-item:hover {
|
|
236
|
+
@apply bg-gray-200 dark:bg-gray-600;
|
|
237
|
+
}
|
|
238
|
+
|
|
239
|
+
.milkdown milkdown-slash-menu .tab-group ul li:hover {
|
|
240
|
+
@apply bg-gray-200 dark:bg-gray-600;
|
|
241
|
+
}
|
|
242
|
+
|
|
243
|
+
.milkdown milkdown-toolbar {
|
|
244
|
+
@apply bg-gray-50 border border-gray-300 text-gray-900 dark:bg-gray-700 dark:border-gray-600 dark:placeholder-gray-400 dark:text-white;
|
|
245
|
+
}
|
|
246
|
+
|
|
247
|
+
.milkdown milkdown-toolbar .toolbar-item:hover {
|
|
248
|
+
@apply bg-gray-200 dark:bg-gray-600;
|
|
249
|
+
}
|
|
250
|
+
|
|
251
|
+
.milkdown milkdown-latex-inline-edit {
|
|
252
|
+
@apply bg-gray-200
|
|
253
|
+
}
|
|
254
|
+
|
|
255
|
+
.milkdown milkdown-latex-inline-edit .container button:hover {
|
|
256
|
+
@apply bg-gray-300 dark:bg-gray-500;
|
|
257
|
+
}
|
|
258
|
+
|
|
259
|
+
.milkdown milkdown-link-edit > .link-edit {
|
|
260
|
+
@apply bg-gray-50 border border-gray-300 text-gray-900 dark:bg-gray-700 dark:border-gray-600 dark:placeholder-gray-400 dark:text-white;
|
|
261
|
+
}
|
|
262
|
+
|
|
263
|
+
.milkdown milkdown-code-block .cm-editor {
|
|
264
|
+
@apply bg-gray-50 border border-gray-300 text-gray-900 dark:bg-gray-700 dark:border-gray-600 dark:placeholder-gray-400 dark:text-white;
|
|
265
|
+
}
|
|
266
|
+
|
|
267
|
+
.ͼo .cm-activeLineGutter {
|
|
268
|
+
@apply bg-gray-200 dark:bg-gray-600;
|
|
269
|
+
}
|
|
270
|
+
|
|
271
|
+
.ͼo .cm-activeLine {
|
|
272
|
+
@apply bg-gray-200 dark:bg-gray-600;
|
|
273
|
+
}
|
|
274
|
+
|
|
275
|
+
.cm-content {
|
|
276
|
+
padding-left: 0px !important;
|
|
277
|
+
padding-right: 0px !important;
|
|
278
|
+
}
|
|
279
|
+
|
|
280
|
+
.milkdown milkdown-code-block .list-wrapper {
|
|
281
|
+
@apply bg-gray-50 border border-gray-300 text-gray-900 dark:bg-gray-700 dark:border-gray-600 dark:placeholder-gray-400 dark:text-white;
|
|
282
|
+
}
|
|
283
|
+
|
|
284
|
+
.milkdown milkdown-code-block .language-list-item:hover {
|
|
285
|
+
@apply bg-gray-200 dark:bg-gray-600;
|
|
286
|
+
}
|
|
287
|
+
|
|
288
|
+
.milkdown milkdown-code-block .tools .language-button {
|
|
289
|
+
@apply bg-gray-50 border border-gray-300 text-gray-900 dark:bg-gray-700 dark:border-gray-600 dark:placeholder-gray-400 dark:text-white;
|
|
290
|
+
}
|
|
291
|
+
|
|
292
|
+
.milkdown milkdown-code-block .tools .language-button:hover {
|
|
293
|
+
@apply bg-gray-200 dark:bg-gray-600;
|
|
294
|
+
}
|
|
295
|
+
|
|
296
|
+
.milkdown::selection {
|
|
297
|
+
background-color: #6b7280;
|
|
298
|
+
}
|
|
299
|
+
|
|
300
|
+
.ͼ4 .cm-line ::selection, .ͼ4 .cm-line::selection {
|
|
301
|
+
background-color: #6b7280 !important;
|
|
302
|
+
}
|
|
303
|
+
|
|
227
304
|
</style>
|
package/dist/index.js
CHANGED
|
@@ -125,7 +125,8 @@ export default class MarkdownPlugin extends AdminForthPlugin {
|
|
|
125
125
|
[options.attachments.attachmentRecordIdFieldName]: recordId,
|
|
126
126
|
[options.attachments.attachmentResourceIdFieldName]: resourceConfig.resourceId,
|
|
127
127
|
},
|
|
128
|
-
adminUser
|
|
128
|
+
adminUser,
|
|
129
|
+
response: {}
|
|
129
130
|
});
|
|
130
131
|
console.log('Successfully created record for:', s3Path);
|
|
131
132
|
}
|
|
@@ -150,6 +151,7 @@ export default class MarkdownPlugin extends AdminForthPlugin {
|
|
|
150
151
|
recordId: a[attachmentPrimaryKeyField.name],
|
|
151
152
|
adminUser,
|
|
152
153
|
record: a,
|
|
154
|
+
response: {}
|
|
153
155
|
});
|
|
154
156
|
})));
|
|
155
157
|
});
|
package/index.ts
CHANGED
|
@@ -67,7 +67,7 @@ export default class MarkdownPlugin extends AdminForthPlugin {
|
|
|
67
67
|
Please configure adapter in such way that it will store objects publicly (e.g. for S3 use 'public-read' ACL).
|
|
68
68
|
`);
|
|
69
69
|
}
|
|
70
|
-
this.uploadPlugin = plugin;
|
|
70
|
+
this.uploadPlugin = plugin as AdminForthPlugin;
|
|
71
71
|
}
|
|
72
72
|
|
|
73
73
|
column.components.show = {
|
|
@@ -139,7 +139,8 @@ export default class MarkdownPlugin extends AdminForthPlugin {
|
|
|
139
139
|
[options.attachments.attachmentRecordIdFieldName]: recordId,
|
|
140
140
|
[options.attachments.attachmentResourceIdFieldName]: resourceConfig.resourceId,
|
|
141
141
|
},
|
|
142
|
-
adminUser
|
|
142
|
+
adminUser,
|
|
143
|
+
response: {} as any
|
|
143
144
|
}
|
|
144
145
|
);
|
|
145
146
|
console.log('Successfully created record for:', s3Path);
|
|
@@ -169,6 +170,7 @@ export default class MarkdownPlugin extends AdminForthPlugin {
|
|
|
169
170
|
recordId: a[attachmentPrimaryKeyField.name],
|
|
170
171
|
adminUser,
|
|
171
172
|
record: a,
|
|
173
|
+
response: {} as any
|
|
172
174
|
}
|
|
173
175
|
)
|
|
174
176
|
}))
|