Skip to content

Correct Label Gun clear-action tooltip modifier and add regression coverage#551

Draft
Copilot wants to merge 3 commits into
1.19.2from
copilot/fix-label-gun-tooltip
Draft

Correct Label Gun clear-action tooltip modifier and add regression coverage#551
Copilot wants to merge 3 commits into
1.19.2from
copilot/fix-label-gun-tooltip

Conversation

Copilot AI commented Jun 15, 2026

Copy link
Copy Markdown

The Label Gun tooltip was expected to document modifier-click behavior (e.g., ctrl/alt combinations), but the clear-label hint showed the wrong modifier. This updates the tooltip wiring so on-hover guidance matches actual keybind behavior.

  • Tooltip mapping fix

    • In LabelGunItem.appendHoverText, the clear reminder now references LABEL_GUN_CLEAR_MODIFIER_KEY instead of LABEL_GUN_PULL_MODIFIER_KEY.
    • This aligns the displayed combo with the clear action semantics.
  • Regression guard

    • Added LabelGunTooltipTests to assert the clear tooltip reminder stays wired to the clear modifier key in source, preventing accidental key regression in future edits.
lines.add(
    LABEL_GUN_ITEM_TOOLTIP_CLEAR_REMINDER.getComponent(
        SFMKeyMappings.getKeyDisplay(SFMKeyMappings.LABEL_GUN_CLEAR_MODIFIER_KEY),
        SFMKeyMappings.getKeyDisplay(options.keyUse)
    ).withStyle(ChatFormatting.GRAY)
);

Copilot AI changed the title [WIP] Fix label gun tooltip to include ctrl+click info Correct Label Gun clear-action tooltip modifier and add regression coverage Jun 15, 2026
Copilot AI requested a review from TeamDman June 15, 2026 22:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants