From eeaa6a4da80c4aaa9ee9a67b84cf9d8bed465f13 Mon Sep 17 00:00:00 2001 From: "Michal Dziekonski (mdz)" Date: Sat, 16 Dec 2023 14:41:54 +0100 Subject: [PATCH] feat: Improve contrast of job queue items count (#1678) Co-authored-by: Stefan Dej --- src/components/panels/StatusPanel.vue | 12 ++++++++++-- src/locales/cz.json | 2 +- src/locales/da.json | 2 +- src/locales/de.json | 2 +- src/locales/en.json | 2 +- src/locales/es.json | 2 +- src/locales/fr.json | 2 +- src/locales/hu.json | 2 +- src/locales/it.json | 2 +- src/locales/ja.json | 2 +- src/locales/ko.json | 2 +- src/locales/nl.json | 2 +- src/locales/pl.json | 2 +- src/locales/pt.json | 2 +- src/locales/ru.json | 2 +- src/locales/tr.json | 2 +- src/locales/uk.json | 2 +- src/locales/zh.json | 2 +- src/locales/zh_TW.json | 2 +- 19 files changed, 28 insertions(+), 20 deletions(-) diff --git a/src/components/panels/StatusPanel.vue b/src/components/panels/StatusPanel.vue index 793bd8b53..a193f0a5b 100644 --- a/src/components/panels/StatusPanel.vue +++ b/src/components/panels/StatusPanel.vue @@ -91,7 +91,11 @@ {{ $t('Panels.StatusPanel.Status') }} {{ $t('Panels.StatusPanel.Files') }} - {{ $t('Panels.StatusPanel.Jobqueue', { count: jobsCount }) }} + + + {{ $t('Panels.StatusPanel.Jobqueue') }} + + @@ -173,7 +177,11 @@ export default class StatusPanel extends Mixins(BaseMixin) { } get jobsCount() { - return this.$store.getters['server/jobQueue/getJobsCount'] ?? 0 + return this.jobs.length ?? 0 + } + + get jobQueueBadgeColor() { + return this.jobsCount > 0 ? 'primary darken-2' : 'grey darken-2' } get current_filename() { diff --git a/src/locales/cz.json b/src/locales/cz.json index 228e1af95..b40f8b5f4 100644 --- a/src/locales/cz.json +++ b/src/locales/cz.json @@ -600,7 +600,7 @@ "Files": "Soubory", "Flow": "Průtok", "Headline": "Stav", - "Jobqueue": "Seznam úloh ({count})", + "Jobqueue": "Seznam úloh", "JobqueueMoreFiles": "žádné další úlohy | jedna další úloha | {count} dalších úloh", "Layer": "Vrstva", "Max": "max", diff --git a/src/locales/da.json b/src/locales/da.json index 06d87292d..1e0f9061c 100644 --- a/src/locales/da.json +++ b/src/locales/da.json @@ -668,7 +668,7 @@ "Files": "Filer", "Flow": "Flow", "Headline": "Status", - "Jobqueue": "Jobkø: ({count})", + "Jobqueue": "Jobkø", "JobqueueMoreFiles": "Ikke flere jobs | Et job til | {count} jobs tilbage", "Layer": "Lag", "Max": "maks", diff --git a/src/locales/de.json b/src/locales/de.json index 10ab43ba8..3ba45b186 100644 --- a/src/locales/de.json +++ b/src/locales/de.json @@ -676,7 +676,7 @@ "Files": "Dateien", "Flow": "Fluss", "Headline": "Status", - "Jobqueue": "Warteschlange ({count})", + "Jobqueue": "Warteschlange", "JobqueueMoreFiles": "keine weiteren Aufträge | einen weiteren Auftrag | {count} weitere Aufträge", "Layer": "Schicht", "Max": "max", diff --git a/src/locales/en.json b/src/locales/en.json index 2c376a130..643ccf94a 100644 --- a/src/locales/en.json +++ b/src/locales/en.json @@ -676,7 +676,7 @@ "Files": "Files", "Flow": "Flow", "Headline": "Status", - "Jobqueue": "Job Queue ({count})", + "Jobqueue": "Job Queue", "JobqueueMoreFiles": "no more jobs | one more job | {count} more jobs", "Layer": "Layer", "Max": "max", diff --git a/src/locales/es.json b/src/locales/es.json index ca9a4825c..79fde2cb6 100644 --- a/src/locales/es.json +++ b/src/locales/es.json @@ -638,7 +638,7 @@ "Files": "Archivos", "Flow": "Flujo", "Headline": "Estado", - "Jobqueue": "Cola de trabajo ({count})", + "Jobqueue": "Cola de trabajo", "JobqueueMoreFiles": "no mas trabajos | un trabajo mas | {count} trabajos mas", "Layer": "Capa", "Max": "max", diff --git a/src/locales/fr.json b/src/locales/fr.json index 3acc3abeb..29359ae44 100644 --- a/src/locales/fr.json +++ b/src/locales/fr.json @@ -670,7 +670,7 @@ "Files": "Fichiers", "Flow": "Débit", "Headline": "Statut", - "Jobqueue": "File d'attente ({count})", + "Jobqueue": "File d'attente", "JobqueueMoreFiles": "pas de travaux | un travail | {count} travaux", "Layer": "Couche", "Max": "max", diff --git a/src/locales/hu.json b/src/locales/hu.json index a9e9fb57d..bac5776ac 100644 --- a/src/locales/hu.json +++ b/src/locales/hu.json @@ -543,7 +543,7 @@ "Files": "Fájlok", "Flow": "Anyagáramlás", "Headline": "Állapot", - "Jobqueue": "Várólista ({count})", + "Jobqueue": "Várólista", "JobqueueMoreFiles": "Nincs több munka | Még egy munka | {count} munka hátra", "Layer": "Réteg", "Max": "max", diff --git a/src/locales/it.json b/src/locales/it.json index b389d6327..c3149a23b 100644 --- a/src/locales/it.json +++ b/src/locales/it.json @@ -668,7 +668,7 @@ "Files": "Files", "Flow": "Flusso", "Headline": "Stato", - "Jobqueue": "Coda di lavoro ({count})", + "Jobqueue": "Coda di lavoro", "JobqueueMoreFiles": "niente più lavori | resta un lavoro | restano {count} lavori", "Layer": "Layer", "Max": "max", diff --git a/src/locales/ja.json b/src/locales/ja.json index f83e6388e..fc744aa71 100644 --- a/src/locales/ja.json +++ b/src/locales/ja.json @@ -600,7 +600,7 @@ "Files": "ファイル", "Flow": "フロー", "Headline": "状態", - "Jobqueue": "ジョブキュー ({count})", + "Jobqueue": "ジョブキュー", "JobqueueMoreFiles": "ジョブなし | あとひとつのジョブ | あと {count}個のジョブ", "Layer": "層", "Max": "最大", diff --git a/src/locales/ko.json b/src/locales/ko.json index db66d0fb4..51ee3ef87 100644 --- a/src/locales/ko.json +++ b/src/locales/ko.json @@ -601,7 +601,7 @@ "Files": "파일", "Flow": "유량", "Headline": "출력 상태", - "Jobqueue": "작업 대기열({count})", + "Jobqueue": "작업 대기열", "JobqueueMoreFiles": "더 이상 작업 없음 | 1개 이상의 작업 | {count}개 이상의 작업", "Layer": "레이어", "Max": "최대", diff --git a/src/locales/nl.json b/src/locales/nl.json index 7219ff20e..4690724da 100644 --- a/src/locales/nl.json +++ b/src/locales/nl.json @@ -600,7 +600,7 @@ "Files": "Bestanden", "Flow": "Flow", "Headline": "Status", - "Jobqueue": "Wachtrij ({count})", + "Jobqueue": "Wachtrij", "JobqueueMoreFiles": "geen jobs meer | nog een job | {count} jobs", "Layer": "Laag", "Max": "max", diff --git a/src/locales/pl.json b/src/locales/pl.json index c7c4a7e99..da91fd503 100644 --- a/src/locales/pl.json +++ b/src/locales/pl.json @@ -668,7 +668,7 @@ "Files": "Pliki", "Flow": "Przepływ", "Headline": "Status", - "Jobqueue": "W kolejce ({count})", + "Jobqueue": "W kolejce", "JobqueueMoreFiles": "brak więcej wydruków | jeszcze jeden wydruk | {count} więcej wydruków", "Layer": "Warstwa", "Max": "Maks.", diff --git a/src/locales/pt.json b/src/locales/pt.json index 290597e79..2674c4bbc 100644 --- a/src/locales/pt.json +++ b/src/locales/pt.json @@ -607,7 +607,7 @@ "Files": "Arquivos", "Flow": "Fluxo", "Headline": "Status", - "Jobqueue": "Fila de trabalhos ({count})", + "Jobqueue": "Fila de trabalhos", "JobqueueMoreFiles": "nenhum trabalho | mais um trabalho | {count} mais trabalhos", "Layer": "Camada", "Max": "max", diff --git a/src/locales/ru.json b/src/locales/ru.json index b8e046b1d..7724ba0ab 100644 --- a/src/locales/ru.json +++ b/src/locales/ru.json @@ -607,7 +607,7 @@ "Files": "Файлы", "Flow": "Поток", "Headline": "Статус", - "Jobqueue": "Очередь ({count})", + "Jobqueue": "Очередь", "JobqueueMoreFiles": "Нет больше задач | Еще одна задача | Еще {count} задач(и)", "Layer": "Слой", "Max": "макс.", diff --git a/src/locales/tr.json b/src/locales/tr.json index 812ec8b8d..7b44299e8 100644 --- a/src/locales/tr.json +++ b/src/locales/tr.json @@ -639,7 +639,7 @@ "Files": "Dosyalar", "Flow": "Akış", "Headline": "Durum", - "Jobqueue": "İş Kuyruğu ({count})", + "Jobqueue": "İş Kuyruğu", "JobqueueMoreFiles": "daha fazla iş yok | bir iş daha var | {count} iş daha var", "Layer": "Katman", "Max": "maks.", diff --git a/src/locales/uk.json b/src/locales/uk.json index 10d1e5993..02e6b68ca 100644 --- a/src/locales/uk.json +++ b/src/locales/uk.json @@ -553,7 +553,7 @@ "Files": "Файли", "Flow": "Потік", "Headline": "Статус", - "Jobqueue": "Черга робіт ({count})", + "Jobqueue": "Черга робіт", "JobqueueMoreFiles": "більше нема робіт | ще одна робота | {count} більше робіт", "Layer": "Шар", "Max": "макс", diff --git a/src/locales/zh.json b/src/locales/zh.json index c7c728db7..9f5a29050 100644 --- a/src/locales/zh.json +++ b/src/locales/zh.json @@ -668,7 +668,7 @@ "Files": "文件", "Flow": "流量", "Headline": "状态", - "Jobqueue": "任务队列({count})", + "Jobqueue": "任务队列", "JobqueueMoreFiles": "没有任务 | 一个任务 | {count}个任务", "Layer": "打印层", "Max": "最高", diff --git a/src/locales/zh_TW.json b/src/locales/zh_TW.json index 6a386fc9c..7209586b7 100644 --- a/src/locales/zh_TW.json +++ b/src/locales/zh_TW.json @@ -579,7 +579,7 @@ "Files": "檔案", "Flow": "流量", "Headline": "狀態", - "Jobqueue": "任務隊列({count})", + "Jobqueue": "任務隊列", "JobqueueMoreFiles": "沒有任務 | 一個任務 | {count}個任務", "Layer": "層", "Max": "最高",