[editor] Add bot version to frontend

Signed-off-by: Knut Ahlers <knut@ahlers.me>
This commit is contained in:
Knut Ahlers 2022-01-20 01:16:05 +01:00
parent a501dcd81d
commit 71ea4a0c34
Signed by: luzifer
GPG key ID: 0066F03ED215AD7D
2 changed files with 17 additions and 0 deletions

View file

@ -59,11 +59,13 @@ func registerEditorFrontend() {
KnownEvents []*string
TemplateFunctions []string
TwitchClientID string
Version string
}{
IRCBadges: twitch.KnownBadges,
KnownEvents: knownEvents,
TemplateFunctions: tplFuncs.GetFuncNames(),
TwitchClientID: cfg.TwitchClient,
Version: version,
}); err != nil {
http.Error(w, err.Error(), http.StatusInternalServerError)
}

View file

@ -112,6 +112,21 @@
<span v-else>Disconnected from Bot</span>
</b-tooltip>
</b-nav-text>
<b-nav-text class="ml-2">
<font-awesome-icon
id="botInfo"
fixed-width
class="mr-1"
:icon="['fas', 'info-circle']"
/>
<b-tooltip
target="botInfo"
triggers="hover"
>
Version: <code>{{ $root.vars.Version }}</code>
</b-tooltip>
</b-nav-text>
</b-navbar-nav>
</b-collapse>
</b-navbar>