Skip to content

Commit

Permalink
wip: Allow to define the version of the theme as well as the version …
Browse files Browse the repository at this point in the history
…of the KDK theme #11
  • Loading branch information
cnouguier committed Jun 12, 2024
1 parent e2bb54a commit 5ff247e
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 4 deletions.
4 changes: 2 additions & 2 deletions themes/kdk/login/fragments/footer.ftl
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@
<div class="row justify-center items-center q-gutter-x-sm">
<q-icon id="theme-info" name="las la-info-circle" size="xs">
<q-tooltip class="bg-primary text-white text-caption">
<div>${msg('themeVersion')}: <b>{{ getVersion().theme }}</b></div>
<div>${msg('kdkThemeVersion')}: <b>{{ getVersion().kdkTheme }}</b></div>
<div>${msg('themeVersion')}: <b>{{ getVersion()?.theme }}</b></div>
<div>${msg('kdkThemeVersion')}: <b>{{ getVersion()?.kdkTheme }}</b></div>
</q-tooltip>
</q-icon>
<div>|</div>
Expand Down
7 changes: 5 additions & 2 deletions themes/kdk/login/template.ftl
Original file line number Diff line number Diff line change
Expand Up @@ -97,12 +97,15 @@
Retrieve theme informations
-->
<script id="informations" type="application/json">
{ }
</script>
<script>
(async function () {
const response = await fetch('${url.resourcesPath}/theme.json')
const informations = document.querySelector('#informations')
informations.text = await response.text()
if (response.ok) {
const informations = document.querySelector('#informations')
informations.text = await response.text()
}
})()
</script>
<!--
Expand Down

0 comments on commit 5ff247e

Please sign in to comment.