Free and Open source Web Builder Framework. Next generation tool for building templates without coding
BSD-3-CLAUSE License
Bot releases are visible (Hide)
Published by artf about 2 months ago
Full Changelog: https://github.com/GrapesJS/grapesjs/compare/v0.21.12...v0.21.13
Published by artf 4 months ago
Components.addType
editor.Components.addType('hero-section', {
model: { ... },
block: { label: 'Hero section' },
});
component.setName
method to simplify component name update.Full Changelog: https://github.com/GrapesJS/grapesjs/compare/0.21.11...v0.21.12
Published by artf 4 months ago
block:category:update
event for listening block category updates.trait:category:update
event for listening trait category updates.<template>
elements #5857draggable
changes #5943Full Changelog: https://github.com/GrapesJS/grapesjs/compare/v0.21.10...0.21.11
config.pageManager.selected
option #5463Full Changelog: https://github.com/GrapesJS/grapesjs/compare/v0.21.9...v0.21.10
Published by artf 7 months ago
multiUploadSuffix
config to AssetManager by @merlinschumacher in https://github.com/GrapesJS/grapesjs/pull/5672
emptyValue
property to StyleManager stack type #5583onPaste
and onKeydown
options to RTE module #5682StyleManagerConfig.sectors.properties
#5613Full Changelog: https://github.com/GrapesJS/grapesjs/compare/v0.21.8...v0.21.9
Published by artf 10 months ago
/
in class names by @mahmudz https://github.com/GrapesJS/grapesjs/pull/5433
nomodule
attribute for canvas.scripts
optionsdelegate
property to Component. Example of usage https://github.com/GrapesJS/grapesjs/discussions/5507
Component.replaceWith
(now returns always an array of components)component:styleUpdate
on component.addStyle/setStyle
#5424id
in HTML export #5441rte:disable
on component move #5545Full Changelog: https://github.com/GrapesJS/grapesjs/compare/v0.21.7...v0.21.8
Published by artf about 1 year ago
src/styles
back to the distributed package (will be removed with the next breaking change release) #5392Full Changelog: https://github.com/GrapesJS/grapesjs/compare/v0.21.6...v0.21.7
Published by artf about 1 year ago
dist/grapes.mjs
)@container
CSS at-rule #5372Full Changelog: https://github.com/GrapesJS/grapesjs/compare/v0.21.5...v0.21.6
Published by artf about 1 year ago
editor.Components.canMove
API
component.setClass
#5319component.badgable
is false
#5340Full Changelog: https://github.com/GrapesJS/grapesjs/compare/v0.21.4...v0.21.5
Published by artf about 1 year ago
config.canvas.allowExternalDrop
option #5242null
#5229state
and device
for component related styles #5213Full Changelog: https://github.com/GrapesJS/grapesjs/compare/v0.21.3...v0.21.4
Published by artf over 1 year ago
addStyles
option to editor.Css.setRule
#5173usePlugin is not a function
#5167PropertyStack
in bundled dts file #5154defaults
as functions #5199Full Changelog: https://github.com/GrapesJS/grapesjs/compare/v0.21.2...v0.21.3
Published by artf over 1 year ago
disableTextInnerChilds
option to Components module configuration.grapesjs.init({
// ...
domComponents: {
// disable all inner childs
disableTextInnerChilds: true,
// disable all except link components
disableTextInnerChilds: (child) => !child.is('link'),
}
})
usePlugin
for a better TS support with plugins
Component.forEachChild
method.Components.addType
component:styleUpdate
on component style changes #4897addStyle(string, string)
#5105fonts
folderFull Changelog: https://github.com/GrapesJS/grapesjs/compare/v0.21.1...v0.21.2
Published by artf over 1 year ago
⚠️ POSSIBLY BREAKING CHANGE
The biggest change we introduce with this release is the complete rewrite of modules to Typescript. This deprecates the old ./index.d.ts
(manually updated) in favor of ./dist/index.d.ts
(generated from the source).
So there are no real changes to the core API itself if not the new TS declaration file which includes type/interfaces changes in order to bring more naming consistency with the code.
This is how you might have used the import of types in the previous version:
import type grapesjs from 'grapesjs';
// plugin
const plugin: grapesjs.Plugin = function (editor: grapesjs.Editor, opt: ...) {...};
Now you can get types directly without specifying the grapesjs namespace (which is the most common way to import types):
import type { Editor, Plugin } from 'grapesjs';
// plugin
const plugin: Plugin = function (editor: Editor, opt: ...) {...};
noCustom
option to Component.getName()
in order to skip custom name assigned to the component.rename
method to SelectorManagerfetchOptions
to AssetManager configsshowOffsetsSelected
#4998args
by @Zaxcoding in https://github.com/GrapesJS/grapesjs/pull/4910
Full Changelog: https://github.com/GrapesJS/grapesjs/compare/v0.20.4...v0.21.1
Published by artf over 1 year ago
storage:load
/storage:store
events https://github.com/artf/grapesjs/discussions/4826
@
to Selector.escapeName
#4865Full Changelog: https://github.com/GrapesJS/grapesjs/compare/v0.20.3...v0.20.4
Published by artf almost 2 years ago
Full Changelog: https://github.com/artf/grapesjs/compare/v0.20.2...v0.20.3
Published by artf almost 2 years ago
"
, '
, ``` in node content)_undoexc
from the Component JSON #4763Full Changelog: https://github.com/artf/grapesjs/compare/v0.20.1...v0.20.2
Published by artf about 2 years ago
If for any reason you're still using the legacy API for registering your custom components you have to switch to the documented one.
Legacy API (which uses extended components via typeModelOrView.extend
):
Components.addType('component-id', {
model: defaultModel.extend({
defaults: {
...defaultModel.prototype.defaults,
someProp: '...',
// ...
}
}),
// same for the view
});
Current API:
Components.addType('component-id', {
model: {
defaults: {
someProp: '...',
// ...
}
},
// same for the view
});
el
prop to onEnd
arguments in Resizer #4579mousePosFetcher
also on start
in Resizer #4580Components.resetFromString
to avoid removing cloned elements during RTE editing (CLOSE https://github.com/artf/grapesjs/issues/4559)"TypeError: this.parseStyle is not a function"
when setStyles
is called internally @collins-lagat https://github.com/artf/grapesjs/pull/4520
Full Changelog: https://github.com/artf/grapesjs/compare/v0.19.5...v0.20.1
Published by artf over 2 years ago
Component.parents()
method.Published by artf over 2 years ago
editor.store(currentStorageOptions)
and editor.load(currentStorageOptions)
are now asynchronous methods and returns respectivly the stored and loaded project data (their first argument is not a callback anymore).store
/load
are also asynchronous now and the signature of their arguments is also changed.editor.StorageManager.add('new-storage-id', {
load(keys, clb, clbErr) {...},
store(data, clb, clbErr) {...},
}
After
editor.StorageManager.add('new-storage-id', {
async load(storageOptions) {...},
async store(data, storageOptions) {...},
}
config.storageManager.options[STORAGE_TYPE]
default configurations.storageManager.checkLocal
-> storageManager.options.local.checkLocal
storageManager.headers
-> storageManager.options.remote.headers
storageManager.urlStore
-> storageManager.options.remote.urlStore
storageManager.urlLoad
-> storageManager.options.remote.urlLoad
storageManager.contentTypeJson
-> storageManager.options.remote.contentTypeJson
storageManager.credentials
-> storageManager.options.remote.credentials
storageManager.fetchOptions
-> storageManager.options.remote.fetchOptions
config.domComponents.storeWrapper
options. The project data will always store the wrapper of your pages.storeHtml
, storeCss
, storeComponents
, storeStyles
, beforeSend
, onComplete
, params
. The project data JSON doesn't extract any HTML/CSS from your pages anymore, but you're still able to extend your storages in order to enrich your data.config.canvas.frameContent
and config.canvas.frameStyle
options (frameStyle
deprecates config.baseCss
).editor.getProjectData()
, editor.loadProjectData(json)
methods.config.projectData
option.componentFirst
option and combined classes #4310Published by artf over 2 years ago
config.wrapperIsBody
, config.exportWrapper
options.wrapper
component itself to indicate what tagName
to use and how to output the HTML.wrapper
as any other component and specify your logic.editor.Components.addType('wrapper', {
model: {
defaults: {
tagName: 'div', // use `div` instead of `body` in HTML export
},
// Skip wrapper in the HTML output
toHTML(opts) {
return this.getInnerHTML(opts);
}
}
})
index.d.ts
file. Thanks to @erdomke