Issue #690Opened December 28, 2017by TWCM0 reactions

Preview Command bug: exit the preview mode will run the sw-visibility command, when the sw-visibility stopped before go to preview mode.

Question

Hi @artf , The case is "switch-visibility" command stopped, then click the preview button or trigger preview command, it will go to preview mode, when exit the preview mode, the "sw-visibility" command ran, it haven't save the state before go to preview mode and cannot reset the visibility after stop the preview command.

Answers (3)

TWCMDecember 29, 20170 reactions

Hi @artf, I found that the command running sequence when click the preview button: image

Is it a bug ? this running sequence make me cannot get the correct classname of canvas' body. so cannot store the state before run the preview command. I cannot make a further development.

artfDecember 29, 20170 reactions

@tommywulove I tried this in the demo

editor.on('run:preview', () => console.log('run preview'))
editor.on('stop:preview', () => console.log('stop preview'))

and the sequence seems correct

TWCMDecember 29, 20170 reactions

@artf but why i click the preview button, it will trigger the stop command once , then run the command ?

Related Questions and Answers

Continue research with similar issue discussions.

Paid Plugins That Match This Issue

Curated by issue keywords and label relevance to help you ship faster.

View all plugins

Loading paid plugin recommendations...

Browse Plugin Categories

Jump directly to plugin category pages on the marketplace.