forked from phenom/healer-man
Release Healer Man 0.1.6
This commit is contained in:
1 parent
55cfd43d66
commit
b12fb84859
96 files changed
+10874
-609
No files matched your search
@@ -82,7 +82,11 @@ function ActionSlot({
|
||||
const cooldownLabel = (item?.cooldownRemaining ?? 0) > 0.05
|
||||
? ", cooling down"
|
||||
: "";
|
||||
const targetLabel = item?.target === "friendly" ? ", targets selected ally or self" : "";
|
||||
const targetLabel = item?.target === "friendly"
|
||||
? ", targets selected ally or self"
|
||||
: item?.target === "any"
|
||||
? ", targets selected enemy or ally"
|
||||
: "";
|
||||
const resourceLabel = item?.resourceCost
|
||||
? `, costs ${item.resourceCost} ${item.resourceLabel ?? "resource"}`
|
||||
: "";
|
||||
@@ -93,7 +97,7 @@ function ActionSlot({
|
||||
return (
|
||||
<button
|
||||
type="button"
|
||||
className={`action-slot action-slot--${control} ${item ? "" : "action-slot--empty"} ${unavailable ? "action-slot--disabled" : ""} ${item?.target === "friendly" ? "action-slot--friendly" : ""} ${cooldown > 0 ? "action-slot--cooldown" : ""}`}
|
||||
className={`action-slot action-slot--${control} ${item ? "" : "action-slot--empty"} ${unavailable ? "action-slot--disabled" : ""} ${item?.target === "friendly" || item?.target === "any" ? "action-slot--friendly" : ""} ${cooldown > 0 ? "action-slot--cooldown" : ""}`}
|
||||
style={style}
|
||||
aria-disabled={unavailable}
|
||||
aria-label={item ? `${item.name}, ${chord}${targetLabel}${resourceLabel}${lockedLabel}${cooldownLabel}` : `Empty binding, ${chord}`}
|
||||
@@ -114,6 +118,7 @@ function ActionSlot({
|
||||
<strong>{item?.name ?? "Empty"}</strong>
|
||||
{item?.lockedUntilLevel ? <span className="action-slot__unlock">LVL {item.lockedUntilLevel}</span> : null}
|
||||
{item?.target === "friendly" ? <span className="action-slot__target">ALLY</span> : null}
|
||||
{item?.target === "any" ? <span className="action-slot__target">ANY</span> : null}
|
||||
{item?.resourceCost ? <small aria-hidden="true">{item.resourceCost}</small> : null}
|
||||
{cooldown > 0 && <i className="action-slot__cooldown" aria-hidden="true" />}
|
||||
{(item?.cooldownRemaining ?? 0) > 0.05 && (
|
||||
@@ -183,7 +188,8 @@ export function ActionBar({
|
||||
? `Unlocks at level ${inspectedItem.lockedUntilLevel}`
|
||||
: inspectedItem.resourceCost
|
||||
? `${inspectedItem.resourceCost} ${inspectedItem.resourceLabel ?? "resource"}`
|
||||
: inspectedItem.target === "friendly" ? "Friendly target" : "Ready"
|
||||
: inspectedItem.target === "friendly" ? "Friendly target"
|
||||
: inspectedItem.target === "any" ? "Enemy or friendly target" : "Ready"
|
||||
: inspectedControl ? "Empty binding" : "Focus a button for details"}</span>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
Reference in new issue
Block a user