Uncaught SyntaxError: Unexpected end of input
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.
Read full answer below āQuestion
blockManager.add('design', {
label: 'design',
content: {
script: function () {
$.ajax({
url: parent.DrupalBasePath + '/api/v1/rnode_operations',
method: 'POST',
dataType: 'json'
}).done(function( data ) {
Example.show('Custom button clicked');
console.log( data )
});
var dialog = parent.bootbox.dialog({
title: 'Flyiers',
message: '<p>Fliers</p>',
buttons: {
noclose: {
label: 'Load More',
className: 'btn-info',
callback: function(){
Example.show('Custom button clicked');
return false;
}
}
}
});
},
style: {
width: '100px',
height: '100px',
'background-color': 'red',
}
},
attributes: {class: 'gjs-fonts gjs-f-image gjs-block gjs-one-bg gjs-four-color-h'},
});Answers (1)
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.
Related Questions and Answers
Continue research with similar issue discussions.
Issue #1308
I am not able to insert icon and its class in html element
bm.add('test-block', { label: "Icons", category: "Prismanote Blocks", content: { script: function () { var d = window.parent.window.modalJ;...
Issue #792
Script property using function don't work with blocks
In Components & JS docs there's this example: This works perfectly. But I couldn't use a function instead of a string in script, as is said...
Issue #1724
[QUESTION] link custom traits to my custom blocks
Hi, i have created a custom traits and custom blocks but i try to link my blocks in traits, it does not shows in settings option my custom...
Issue #958
Unable to create a popup by using bootbox or any other way.
Unable to create bootbox popup. Below is my code:- var blockManager = editor.BlockManager; blockManager.add('design', { label: 'Design', co...
Paid Plugins That Match This Issue
Curated by issue keywords and label relevance to help you ship faster.
Loading paid plugin recommendations...
Check the open-source GrapesJS plugins on GitHub or run a quick search in our free catalog.
Browse free plugins āPremium plugins ship with support, regular updates, and production-ready features ā save days of integration work.
Browse premium plugins āBrowse Plugin Categories
Jump directly to plugin category pages on the marketplace.