AddThisFeature

Labels and Tags

Organise records with reusable labels you can filter by.

moderate Data & Content

What it adds

A label catalog with a defined scope, normalised names, safe rename and delete, and label-based filtering on every list.

What your agent is told to do

5
  1. 1

    Decide the scope of the catalog before anything else — per user, per workspace, or global — and enforce it in every query. Mixing scopes later is a migration, not a setting.

  2. 2

    Normalise names on the way in: trim whitespace, collapse internal spaces, and compare case-insensitively so 'Urgent', 'urgent' and ' urgent ' cannot coexist. Store the display form the user typed.

  3. 3

    Make rename a true rename on the label record, so every record already carrying it updates at once. Never implement rename as delete-and-recreate.

  4. 4

    Deleting a label must remove it from every record that has it in the same operation, and must warn with the affected count first. An assignment pointing at a deleted label is a bug that shows up as a blank chip months later.

  5. 5

    Add label filtering to every list that shows these records, including combining multiple labels. Do not build a new chip-entry control for assigning labels — that input is owned by Tag Input; use it.

Edge cases it handles

6
  • Role-gated creation: some apps want anyone to apply labels but only admins to create new ones. Make that a setting, not a hardcoded rule.
  • Colour is decoration, never the only signal — a label must be identifiable by its name for colour-blind users and in monochrome contexts.
  • Cap the number of labels per record and the label name length, and say so before the user hits the limit.
  • Merging two labels that mean the same thing must reassign records without creating duplicate assignments.
  • A record whose labels the viewer cannot all see must not leak the hidden ones through filter counts or autocomplete.
  • Filtering by several labels needs a defined meaning — all of them or any of them — shown in the UI rather than assumed.

Definition of done

8
  • Label scope is enforced in every query, with no cross-scope leakage.
  • Names are normalised so case and whitespace variants cannot create duplicates.
  • Renaming updates every record instantly; deleting removes assignments and warns with a count first.
  • Label creation can be restricted by role independently of label use.
  • Every list showing these records can be filtered by one or more labels, with the combining rule stated.
  • Assignment uses the existing tag input control rather than a new one.
  • The feature matches the existing design system.
  • No existing functionality is broken.

Related features

How it works

  1. 1

    Copy the link

    Grab the Markdown instruction URL for this feature.

  2. 2

    Give it to your AI

    Paste it into Claude Code, Cursor, v0, Lovable — whatever you build with.

  3. 3

    It inspects, then implements

    Your agent reads your existing app first, then adds the feature to fit it.

Works with your stack

These instructions are written to adapt. They tell the agent to detect your framework, match your existing design system, and reuse what you already have — rather than assuming a particular stack.

Need it tighter than that? Customize the feature and tell it exactly what you're running.