Page 1 of 1

Style broken

Posted: Mon Nov 14, 2016 4:22 am
by 303248153
Like this image, how can I fix it?

Re: Style broken

Posted: Mon Nov 14, 2016 9:43 am
by 303248153
After some digging I found stiDesignerPaintPanel covered stiDesignerToolBar and stiDesignerWorkPanel.
But if I click some button the position will be fixed.
I fixed this problem by running following code after create designer.

Code: Select all

setTimeout(function() {
	$("#StiDesignerhidePropertiesPanelButton").click().click();
	$("#StiDesignerhomeToolButton").click();
	$("#StiDesigner_Viewer").parent().css("top", "25px");
}, 0);
I still don't known where is wrong, but it work, thanks god.

Re: Style broken

Posted: Wed Nov 16, 2016 5:58 am
by HighAley
Hello.

We met such issue before. You should try to render the Designer after timeout.

Code: Select all

setTimeout(function(){
    designer.renderHtml("content");
}
Thank you.

Re: Style broken

Posted: Fri Nov 18, 2016 1:42 am
by 303248153
Thanks, your code work.

Code: Select all

setTimeout(() => designer.renderHtml("designerContent"), 0);
I use code like above.

Re: Style broken

Posted: Fri Nov 18, 2016 5:13 am
by Andrew
Hello,

Thank you for sharing your code with other developers.

Have a nice day!