11<template >
2- <v-card >
2+ <v-card max-width = " 100em " >
33 <template v-slot :loader >
44 <v-progress-linear
55 color =" primary"
4848 <vue-markdown :source =" stepDescription" ></vue-markdown >
4949 </v-card-text >
5050 </v-card >
51- <v-card id =" console" theme =" dark" outlined rounded =" 0" height =" 30em" max-height =" 30em" max-width = " 100em "
51+ <v-card id =" console" theme =" dark" outlined rounded =" 0" height =" 30em" max-height =" 30em"
5252 style =" font-family : monospace ; overflow : scroll " >
5353 <v-card-text v-html =" consoleOutput" ></v-card-text >
5454 </v-card >
5555 <v-progress-linear color =" primary" :model-value =" (currentStep - 1) / steps.length * 100" />
5656 <v-timeline direction =" horizontal" side =" end" >
5757 <v-timeline-item size =" small" v-for =" (stepName, step) in steps" :ref =" `${step + 1}-step`"
58- :icon =" currentStep - 1 > step ? 'mdi-check' : ''" fill-dot dot-color =" primary" >{{ stepName }}
58+ :icon =" currentStep - 1 > step ? 'mdi-check' : ''" fill-dot dot-color =" primary" >{{ getStepTitle( stepName) }}
5959 </v-timeline-item >
6060 </v-timeline >
6161 </v-card-text >
@@ -82,6 +82,7 @@ let getStepInterval: NodeJS.Timer | null = null;
8282let consoleOutput: string = ' ' ;
8383let currentStep: number = 1 ;
8484let steps: string [] = [];
85+ let features: any = [];
8586
8687export default defineComponent ({
8788 components: {
@@ -90,6 +91,7 @@ export default defineComponent({
9091 data() {
9192 return {
9293 steps ,
94+ features ,
9395 currentStep ,
9496 consoleOutput ,
9597 getStepInterval ,
@@ -106,16 +108,19 @@ export default defineComponent({
106108 logoUrl ,
107109 };
108110 },
109- mounted() {
110- axios .default .get (' /api/steps' )
111- .then (
112- (backendSteps ) => {
113- this .steps = backendSteps .data .steps ;
114- },
115- );
111+ async mounted() {
112+ this .steps = (await axios .default .get (' /api/steps' )).data .steps
113+ this .features = (await axios .default .get (' /api/features' )).data
114+
116115 this .getStepInterval = setInterval (this .getCurrentStep .bind (this ), 3000 ) as NodeJS .Timer ;
117116 },
118117 methods: {
118+ getStepTitle(stepName : string ) {
119+ if (stepName == ' flavour' ) {
120+ return ' Flavour'
121+ }
122+ return this .features [stepName ].Title
123+ },
119124 async doOAuth() {
120125 if (this .oAuthCode !== ' ' ) {
121126 await navigator .clipboard .writeText (this .oAuthCode );
0 commit comments