Plugin position after hide and show

It seems the plugin position is stored just before closePlugin. so if users move plugin window and plugin goes hidden, and visible again via figma.ui.hide and methods, the position of plugin will be the last position before close not before hide.
It will be great if accepts some options like position, width, height and also figma.ui.hide accepts message option.