1
0
mirror of https://github.com/invoiceninja/invoiceninja.git synced 2024-11-08 20:22:42 +01:00

Merge proposal undo/redo

This commit is contained in:
Hillel Coren 2018-04-15 21:28:03 +03:00
parent ee61638cd6
commit d4cd12fdf1

View File

@ -7,6 +7,7 @@ $(function() {
components: {!! json_encode($entity ? $entity->html : '') !!},
style: {!! json_encode($entity ? $entity->css : '') !!},
showDevices: false,
noticeOnUnload: false,
plugins: ['gjs-preset-newsletter'],
pluginsOpts: {
'gjs-preset-newsletter': {
@ -14,7 +15,13 @@ $(function() {
}
},
storageManager: {
type: 'none'
type: 'none',
autosave: false,
autoload: false,
storeComponents: false,
storeStyles: false,
storeHtml: false,
storeCss: false,
},
assetManager: {
assets: {!! json_encode($documents) !!},
@ -36,6 +43,20 @@ $(function() {
}
});
var panelManager = grapesjsEditor.Panels;
panelManager.addButton('options', [{
id: 'undo',
className: 'fa fa-undo',
command: 'undo',
attributes: { title: 'Undo (CTRL/CMD + Z)'}
},{
id: 'redo',
className: 'fa fa-repeat',
attributes: {title: 'Redo'},
command: 'redo',
attributes: { title: 'Redo (CTRL/CMD + SHIFT + Z)' }
}]);
var blockManager = grapesjsEditor.BlockManager;
@foreach ($snippets as $snippet)