Closed kamleshkatpara closed 7 years ago
- I am able to upload and load images into the asset manager. The thing I am missing on is after uploading the image, it is not reflected immediately in the asset manager image list.
Here is the problem
handleAdd: '<?php base_url(); ?>/dragdropeditor/dragdrop/upload',
In https://github.com/artf/grapesjs/blob/dev/src/asset_manager/config/config.js I explain why you need it
// Handle the image url submit from the built-in 'Add image' form
// @example
// handleAdd: (textFromInput) => {
// // some check...
// editor.AssetManager.add(textFromInput);
// }
handleAdd: '',
So in your case, just remove it, you don't need it. You can hide Add image
input with CSS if you want
- I want to show the preview button for newsletter as used for webpage templates
I remove it here https://github.com/artf/grapesjs-preset-newsletter/blob/master/src/buttons.js#L36-L37 You can add it back
Hi @artf
Not sure about using https://github.com/artf/grapesjs-preset-newsletter/blob/master/src/buttons.js#L36-L37
I am using the compressed version: `
` Also I wanted to know why Add image button does not seem to work ? I mean not clear about it > I am able to upload and load images into the asset manager. > The thing I am missing on is after uploading the image, it is not reflected immediately in the asset manager image list. Why do I have to refresh the page every time. Is it possible to load the images directly after uploadingThe Add button works exactly as expected, it shouldn't upload/download stuff. If you need custom behaviors add your UI
Why do I have to refresh the page every time. Is it possible to load the images directly after uploading
I've already told you where is the problem... read my previous answer
This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.
Hi @artf @arthuralmeidap @sonnylloyd @cmcintosh @daniel-farina
Thank you so much for developing such a awesome framework. I tried to achieve almost all the functionalities in grapesjs preset newsletter.
Just need some help on this two little things :
1) I am able to upload and load images into the asset manager. The thing I am missing on is after uploading the image, it is not reflected immediately in the asset manager image list.
I have already followed issues https://github.com/artf/grapesjs/issues/216 and https://github.com/artf/grapesjs/issues/372
It does not seem to work.
This is my json response from the server after uploading the files :
[{"type":"image","src":"http://cimailer.dev/uploads/1.jpg","height":"350","weight":"250"},{"type":"image","src":"http://cimailer.dev/uploads/Capture.JPG","height":"350","weight":"250"}]
This is my complete code :
Also I observed that the Add image button does not seem to work,
If I try to give it a online path it will show the image but won't download and add it to the assets manager. And it does not work for local path.
Any way I can achieve it, if not how can I hide it.
2) I want to show the preview button for newsletter as used for webpage templates :
Thank you.