Preserving issue label history when labels are renamed or removed
On issues where a system note references a label which no longer exists, we see currently something like the following (from #22921 (closed)):
We have no way of knowing what ~19492
used to point to, and it just looks arcane and ugly to someone who doesn't understand the ~labelname
syntax.
I propose that instead of using label IDs when creating system notes, we use the ~"label name"
syntax instead. This way we can continue to render them as labels, and we can even remember their name, e.g.:
Since we don't have a label to reference, we won't know its original color or description. That's fine, we can just make it a muted gray color and have the tooltip reveal that the label no longer exists:
The only downside to this is that labels which are renamed won't track the same way they do with their ID-based approach now, but I think I'd rather see the label name that was assigned when the system note was created rather than the label as it is named currently. If we want to see the current label name, we'll still see that in the issue metadata on the sidebar.