Skip to content

Commit 7d44465

Browse files
committed
feat: update footer component to handle version display and links dynamically
- Modified the footer component to conditionally display the current versions of Orchestrator and Daemon, replacing hardcoded values with dynamic bindings. - Added tooltips to provide additional information about the installed versions and links to their respective release pages, improving user experience and accessibility. - Updated the layout to ensure proper handling of version updates and visibility of available updates.
1 parent 8afdf42 commit 7d44465

File tree

2 files changed

+30
-14
lines changed

2 files changed

+30
-14
lines changed

apps/web/src/components/layouts/default/footer.vue

Lines changed: 26 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -2,31 +2,47 @@
22
q-footer(:class="$q.dark.isActive ? 'bg-dark' : 'bg-white'" bordered)
33
q-bar(:class="$q.dark.isActive ? 'bg-dark' : 'bg-white text-black'")
44
a(
5-
:href="'https://github.com/Libertech-FR/sesame-orchestrator/releases/tag/' + (orchestratorVersion?.currentVersion || '0.0.0')"
6-
target="_blank"
5+
:href="orchestratorVersion?.currentVersion ? 'https://github.com/Libertech-FR/sesame-orchestrator/releases/tag/' + orchestratorVersion?.currentVersion : 'javascript:void(0)'"
6+
:target="orchestratorVersion?.currentVersion ? '_blank' : undefined"
77
rel="noopener noreferrer"
88
style="color: inherit; text-decoration: none;"
99
)
10+
q-tooltip.text-body2(
11+
v-if="orchestratorVersion?.currentVersion"
12+
anchor="top middle"
13+
self="bottom middle"
14+
)
15+
| Version d’Orchestrator actuellement installée : {{ orchestratorVersion?.currentVersion ? ('v' + orchestratorVersion?.currentVersion) : 'N/A' }}.
16+
br
17+
small.text-caption Cliquez pour ouvrir la page de version et consulter les notes de publication.
1018
small.gt-xs Orchestrator 
11-
small(v-text="'v' + (orchestratorVersion?.currentVersion || '0.0.0')")
12-
small.bold  / 
19+
small.text-grey-7(v-text="orchestratorVersion?.currentVersion ? ('v' + orchestratorVersion?.currentVersion) : 'N/A'")
20+
q-separator.q-mx-sm(vertical inset style="width: 2px;")
1321
a(
14-
:href="'https://github.com/Libertech-FR/sesame-daemon/releases/tag/' + (daemonVersion?.currentVersion || '0.0.0')"
15-
target="_blank"
22+
:href="daemonVersion?.currentVersion ? 'https://github.com/Libertech-FR/sesame-daemon/releases/tag/' + daemonVersion?.currentVersion : 'javascript:void(0)'"
23+
:target="daemonVersion?.currentVersion ? '_blank' : undefined"
1624
rel="noopener noreferrer"
1725
style="color: inherit; text-decoration: none;"
1826
)
27+
q-tooltip.text-body2(
28+
v-if="daemonVersion?.currentVersion"
29+
anchor="top middle"
30+
self="bottom middle"
31+
)
32+
| Version de Daemon actuellement installée : {{ daemonVersion?.currentVersion ? ('v' + daemonVersion?.currentVersion) : 'N/A' }}.
33+
br
34+
small.text-caption Cliquez pour ouvrir la page de version et consulter les notes de publication.
1935
small.gt-xs Daemon 
20-
small(v-text="'v' + (daemonVersion?.currentVersion || '0.0.0')")
21-
div.q-pr-xs
36+
small.text-grey-7(v-text="daemonVersion?.currentVersion ? ('v' + daemonVersion?.currentVersion) : 'N/A'")
37+
q-separator.q-mx-sm(v-if='orchestratorVersion?.updateAvailable || daemonVersion?.updateAvailable' vertical inset style="width: 2px;")
2238
q-btn.q-px-xs(
2339
v-show="orchestratorVersion?.updateAvailable"
2440
flat stretch icon="mdi-alert-box" color="amber-9"
2541
href="https://github.com/Libertech-FR/sesame-orchestrator/releases" target="_blank"
2642
) Orchestrator
2743
q-tooltip.text-body2.bg-amber-9
2844
| MÀJ. disponible (
29-
span(v-text="orchestratorVersion?.lastVersion || '0.0.0'")
45+
span(v-text="orchestratorVersion?.lastVersion")
3046
| )
3147
q-btn.q-px-xs(
3248
v-show="daemonVersion?.updateAvailable"
@@ -35,7 +51,7 @@
3551
) Daemon
3652
q-tooltip.text-body2.bg-amber-9
3753
| MÀJ. disponible (
38-
span(v-text="daemonVersion?.lastVersion || '0.0.0'")
54+
span(v-text="daemonVersion?.lastVersion")
3955
| )
4056
q-space
4157
sesame-core-help-buttons

apps/web/src/layouts/default.vue

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -45,13 +45,13 @@ export default defineNuxtComponent({
4545
eventSeamlessCurrent: 0,
4646
eventSeamlessCurrentJobs: {},
4747
orchestratorVersion: {
48-
currentVersion: '0.0.0',
49-
lastVersion: '0.0.0',
48+
currentVersion: null,
49+
lastVersion: null,
5050
updateAvailable: false,
5151
},
5252
daemonVersion: {
53-
currentVersion: '0.0.0',
54-
lastVersion: '0.0.0',
53+
currentVersion: null,
54+
lastVersion: null,
5555
updateAvailable: false,
5656
},
5757
}

0 commit comments

Comments
 (0)