feat: Add the ability to paste images to editor (#10072)
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
import articlesAPI from 'dashboard/api/helpCenter/articles';
|
||||
import { uploadFile } from 'dashboard/helper/uploadHelper';
|
||||
import { uploadExternalImage, uploadFile } from 'dashboard/helper/uploadHelper';
|
||||
import { throwErrorMessage } from 'dashboard/store/utils/api';
|
||||
|
||||
import types from '../../mutation-types';
|
||||
@@ -132,6 +132,11 @@ export const actions = {
|
||||
return fileUrl;
|
||||
},
|
||||
|
||||
uploadExternalImage: async (_, { url }) => {
|
||||
const { fileUrl } = await uploadExternalImage(url);
|
||||
return fileUrl;
|
||||
},
|
||||
|
||||
reorder: async (_, { portalSlug, categorySlug, reorderedGroup }) => {
|
||||
try {
|
||||
await articlesAPI.reorderArticles({
|
||||
|
||||
Reference in New Issue
Block a user