@silexlabs/silex 3.0.4 → 3.0.6

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@silexlabs/silex",
3
3
  "description": "Free and easy website builder for everyone.",
4
- "version": "3.0.4",
4
+ "version": "3.0.6",
5
5
  "version:backwardcompat": "3.0.0",
6
6
  "author": {
7
7
  "name": "Alex Hoyau",
@@ -83,6 +83,7 @@
83
83
  "start:preview": "http-server silex/hosting -o",
84
84
  "prepublishOnly": "$npm_execpath run lint && $npm_execpath test && $npm_execpath run build",
85
85
  "preversion": "$npm_execpath run prepublishOnly",
86
+ "prepack": "$npm_execpath run prepublishOnly",
86
87
  "build": "run-s build:css:release build:html build:client:release build:server:release build:plugins:client build:plugins:server",
87
88
  "webpack": "webpack --config webpack.config.js",
88
89
  "build:css:release": "sass --load-path ../../node_modules --load-path node_modules --no-source-map src/css/index.scss dist/client/css/admin.css",
@@ -99,7 +100,7 @@
99
100
  "lint:fix": "$npm_execpath run lint -- --fix",
100
101
  "test": "node --experimental-vm-modules `node_modules jest`/jest/bin/jest.js",
101
102
  "test:watch": "$npm_execpath test -- --watch",
102
- "prepare": "husky"
103
+ "prepare": "husky install && npm run build"
103
104
  },
104
105
  "dependencies": {
105
106
  "@fontsource/ubuntu": "^5.0.13",
@@ -77,9 +77,6 @@ export const settingsDialog = (editor, opts) => {
77
77
  const model = editor.getModel()
78
78
  model.set('settings', data.settings || {})
79
79
  model.set('name', data.name)
80
- editor.once('canvas:frame:load', () => {
81
- updateDom(editor)
82
- })
83
80
  })
84
81
  // Normal way to apply the head content to the DOM
85
82
  // fix #1559 Custom <head> code must be reapplied
@@ -207,6 +207,13 @@ async function progressiveLoadPages(editor: PublishableEditor, data: ProjectData
207
207
  if (data.styles) editor.setStyle(data.styles)
208
208
  if (data.assets) editor.AssetManager.add(data.assets)
209
209
 
210
+ await nextFrame()
211
+ setTimeout(() => {
212
+ // FIXME: Why is this setTimeout needed?
213
+ editor.trigger('storage:end:load', data)
214
+ editor.trigger('canvas:frame:load', editor)
215
+ })
216
+
210
217
  // Sélectionner la première page
211
218
  const firstPage = editor.Pages.getAll()[0]
212
219
  if (firstPage) editor.Pages.select(firstPage)