When I run this code
winbox.resize("50%", "50%");
The window is resized but it loses the border styling, in particular the rounded border, it becomes straight
Using the maximize button and minimize button after this restores the styling so there seems to be a problem with the resize function