From 3caf154ad05a0a4682255cb2d7e7df57b8d9e190 Mon Sep 17 00:00:00 2001 From: Dianliang233 Date: Fri, 9 Aug 2024 11:24:48 +0800 Subject: [PATCH] Add cooldown progress bar --- src/tools/meleeDamage/App.vue | 76 +++++++++++++++++++++++------------ 1 file changed, 51 insertions(+), 25 deletions(-) diff --git a/src/tools/meleeDamage/App.vue b/src/tools/meleeDamage/App.vue index 5b9bd0e..ad0f5a0 100644 --- a/src/tools/meleeDamage/App.vue +++ b/src/tools/meleeDamage/App.vue @@ -14,7 +14,7 @@ import { CdxToggleButtonGroup, type MenuItemData, } from '@wikimedia/codex' -import { cdxIconTrash } from '@wikimedia/codex-icons' +import { cdxIconAdd, cdxIconTrash } from '@wikimedia/codex-icons' import CalcField from '@/components/CalcField.vue' import { parseWikitext } from '@/utils/i18n.ts' @@ -534,33 +534,59 @@ function selectOutput() { -
- - +
+
+ + -
- + + + {{ t('meleeDamage.attackCondition.setFullCooldown') }} + +
+
+ + + + {{ t('meleeDamage.attackCondition.critical') }} + + +
+ +
+
+
- - {{ t('meleeDamage.attackCondition.setFullCooldown') }} -
- - - - - {{ t('meleeDamage.attackCondition.critical') }} - - + + {{ `${Math.round(cooldownProgress * 100)}%` }} +