i think it is bug but i am not sure maybe i did sth wrong.
PS. if you know how change it and keep the functionality and visibility, please let me know
<?page title="Preumowa" contentType="text/html;charset=UTF-8"?>
<zk>
<window id="mainWindow" border="normal" apply="org.zkoss.bind.BindComposer">
<button label="works" upload="true,maxsize=50000, multiple=true, native" onUpload="@command('addDocument',typDokumentu='PU')"/>
<tabbox>
<tabs>
<tab label="tab1"/>
<tab label="tab2"/>
</tabs>
<tabpanels>
<tabpanel>
<button label="works" upload="true,maxsize=50000, multiple=true, native" onUpload="@command('addDocument',typDokumentu='PU')"/>
</tabpanel>
<tabpanel>
<button label="doesn't work" upload="true,maxsize=50000, multiple=true, native" onUpload="@command('addDocument',typDokumentu='PU')"/>
</tabpanel>
</tabpanels>
</tabbox>
</window>
</zk>
This was/is a bug in zk.
You have already created a bug tracker for it.
This is the original bug tracker.
Here is a zk fiddle with your code, strangly enough it works on the fiddle.