Update docker.js

This commit is contained in:
Squidly271
2024-10-28 19:38:24 -04:00
committed by GitHub
parent ec36fd3c8e
commit fcec8111c3

View File

@@ -4,7 +4,7 @@ function addDockerContainerContext(container, image, template, started, paused,
var opts = [];
context.settings({right:false,above:false});
if (started && !paused) {
if (webui !== '' && webui != '#') opts.push({text:_('WebUI'), icon:'fa-globe', href:webui, target:'_blank'});
if (webui !== '' && webui != '#') opts.push({text:_('WebUI'), icon:'fa-globe', action:function(e){e.preventDefault();window.open(webui,'_blank');}});
if (tswebui !== '' && tswebui != '#') opts.push({text:_('Tailscale WebUI'), icon:'fa-globe', href:tswebui, target:'_blank'});
opts.push({text:_('Console'), icon:'fa-terminal', action:function(e){e.preventDefault(); openTerminal('docker',container,shell);}});
opts.push({divider:true});