1
0
mirror of https://gitlab.crans.org/nounous/ghostream.git synced 2024-12-23 01:32:19 +00:00

Hide sidebar widget if no url provided

This commit is contained in:
Alexandre Iooss 2020-10-04 11:57:42 +02:00
parent db0937dd1a
commit 3c16c11f38
No known key found for this signature in database
GPG Key ID: 6C79278F3FCDCC02

View File

@ -29,15 +29,19 @@
<rect width="4" height="14" x="11" y="1" rx="1"/> <rect width="4" height="14" x="11" y="1" rx="1"/>
</svg> </svg>
{{if .WidgetURL}}
<a href="#" id="sideWidgetToggle" class="ml-1" title="Cacher/Afficher le chat">»</a> <a href="#" id="sideWidgetToggle" class="ml-1" title="Cacher/Afficher le chat">»</a>
{{end}}
</p> </p>
</div> </div>
{{if .WidgetURL}}
<!-- Chat --> <!-- Chat -->
<div class="col-chat" id="sideWidget"> <div class="col-chat" id="sideWidget">
<iframe src="{{.WidgetURL}}" <iframe src="{{.WidgetURL}}"
title="Chat" sandbox="allow-scripts allow-forms allow-same-origin"></iframe> title="Chat" sandbox="allow-scripts allow-forms allow-same-origin"></iframe>
</div> </div>
{{end}}
</div> </div>
<script src="/static/js/sideWidget.js"></script> <script src="/static/js/sideWidget.js"></script>