feat: display module for chunithm
Also make the progress bar all shiny
This commit is contained in:
@ -5,6 +5,7 @@ import ConfirmDialog from 'primevue/confirmdialog';
|
||||
import Dialog from 'primevue/dialog';
|
||||
import InputIcon from 'primevue/inputicon';
|
||||
import InputText from 'primevue/inputtext';
|
||||
import ProgressBar from 'primevue/progressbar';
|
||||
import ScrollPanel from 'primevue/scrollpanel';
|
||||
import Tab from 'primevue/tab';
|
||||
import TabList from 'primevue/tablist';
|
||||
@ -43,7 +44,7 @@ const isProfileDisabled = computed(() => prf.current === null);
|
||||
const updateProgress: Ref<number | null> = ref(null);
|
||||
|
||||
listen<number>('update-progress', (ev) => {
|
||||
updateProgress.value = ev.payload;
|
||||
updateProgress.value = Math.floor(ev.payload * 100);
|
||||
});
|
||||
|
||||
listen<undefined>('update-end', (_) => {
|
||||
@ -152,7 +153,7 @@ listen<{ message: string; header: string }>('invoke-error', (event) => {
|
||||
header="Updating"
|
||||
:style="{ width: '200px' }"
|
||||
>
|
||||
{{ ((updateProgress ?? 0) * 100).toFixed(0) }}%
|
||||
<ProgressBar :value="updateProgress ?? undefined" />
|
||||
</Dialog>
|
||||
|
||||
<Tabs
|
||||
@ -331,4 +332,10 @@ body {
|
||||
.p-tooltip {
|
||||
min-width: 300px;
|
||||
}
|
||||
|
||||
.p-progressbar,
|
||||
.p-progressbar-value,
|
||||
.p-progressbar-label {
|
||||
transition-duration: 0s !important;
|
||||
}
|
||||
</style>
|
||||
|
Reference in New Issue
Block a user