Closed Bug 2062007 Opened 3 months ago Closed 14 days ago

Add category row and chip markup

Categories

(Calendar :: Calendar Frontend, task)

task
Points:
2

Tracking

(Not tracked)

RESOLVED FIXED
162 Branch

People

(Reporter: arschmitz, Assigned: arschmitz)

References

(Blocks 2 open bugs)

Details

(Whiteboard: [calendar-ui-create-edit])

Attachments

(1 external file)

Summary:
Add the structure and styles for the category row. This story does not load categories or connect the controls to event data.

Links:

Acceptance criteria:

  • Use the shared row from Bug 2061586.
  • Add the markup for Add category, the category list, selected chips, and each chip's remove button.
  • Add the markup for +x more and the area that shows the remaining categories.
  • Keep each chip on one line. Cut off long text at the end of that line.
  • Provide styles for category labels and colors.
  • Keep overflow inside the dialog. It must not make the dialog grow or change position.
  • Give controls translated labels, accessible names, and visible keyboard focus.

Required implementation details:

  • Use fixed sample data in tests to show empty, filled, long-label, and overflow states.
  • Do not add category lookup, Redux subscriptions, draft changes, or Save behavior.
  • Leave real category colors, the visible chip count, and control actions to Bug 2084433.

Minimum test coverage:

  • Check the markup and labels.
  • Check single-line chips, long labels, and scrolling.
  • Check supported themes, display densities, and forced colors.
  • Run automated accessibility checks where supported.

Out of scope:

  • Loading categories, adding or removing selections, calculating +x more, and saving.
  • Broader category or event-color work beyond the designed row and chips.
Blocks: 2062008
Type: enhancement → task

TB-Tools story description:

Summary:

Implement main-dialog category selection and selected-category chips using serializable draft state.

Links:

Questions and concerns:

Acceptance criteria:

  • The main dialog provides an accessible Add category control and selected-category chips/tags.
  • The current session’s selected categories render through stable storeObserver selections of a plain category draft. Do not use getters that pull state from the store.
  • The category draft holds only plain stable IDs or labels and design-relevant color/label metadata. It contains no preference object, calIEvent, calendar object, DOM node, or popup state.
  • Selecting or removing a category dispatches a narrow category-section patch and changes draft state only. Chip removal is keyboard accessible.
  • Category-choice lookup, popup-open state, active option, type-ahead text, and layout measurement remain local control state. They do not enter Redux.
  • A memoized selector derives the full selected-category view model from store state; responsive chip capacity and +x more layout remain DOM/controller-local.
  • The main view shows two or three chips as space allows, then displays +x more. Tooltip/full-list behavior for +x more remains explicitly TBD until product/design confirms it.
  • Category color and label treatment follows the design. Visible chip overflow must not grow or re-position the dialog; initial hydrated chips are accounted for before show readiness completes.
  • A route/session replacement clears obsolete local category interaction and prevents stale selection or removal events from patching the newer draft.
  • Bug 2062008 owns edit-source category mapping and Save-time event-property conversion.
  • Add focused tests for Add category entry, selected-chip display, keyboard removal, serializable draft-only patches, two/three-chip capacity, +x more TBD behavior, color/label presentation, stale-session protection, readiness/overflow behavior, and axe coverage where supported.

Out of scope:

  • Event-property mapping, category persistence, preference writes, generic category-service infrastructure, a final +x more tooltip/full-list decision, and direct calendar mutation.

TB-Tools story description:

Summary:

Implement main-dialog category selection and selected-category chips using serializable draft state.

Links:

Questions and concerns:

  • The SOW includes “Add to personal category” but lists broader event category/color work as a future improvement. Confirm whether this story is limited to the Zeplin row-and-chips MVP. (additional work is out of scope)

  • Planning: Questions - Q15 Category MVP Scope And Overflow Disclosure

Acceptance criteria:

  • The main dialog provides an accessible Add category control and selected-category chips/tags.
  • The current session’s selected categories render through stable storeObserver selections of a plain category draft. Do not use getters that pull state from the store.
  • The category draft holds only plain stable IDs or labels and design-relevant color/label metadata. It contains no preference object, calIEvent, calendar object, DOM node, or popup state.
  • Selecting or removing a category dispatches a narrow category-section patch and changes draft state only. Chip removal is keyboard accessible.
  • Category-choice lookup, popup-open state, active option, type-ahead text, and layout measurement remain local control state. They do not enter Redux.
  • A memoized selector derives the full selected-category view model from store state; responsive chip capacity and +x more layout remain DOM/controller-local.
  • The main view shows two or three chips as space allows, then displays +x more. Tooltip/full-list behavior for +x more remains explicitly TBD until product/design confirms it.
  • Category color and label treatment follows the design. Visible chip overflow must not grow or re-position the dialog; initial hydrated chips are accounted for before show readiness completes.
  • A route/session replacement clears obsolete local category interaction and prevents stale selection or removal events from patching the newer draft.
  • Bug 2062008 owns edit-source category mapping and Save-time event-property conversion.
  • Add focused tests for Add category entry, selected-chip display, keyboard removal, serializable draft-only patches, two/three-chip capacity, +x more TBD behavior, color/label presentation, stale-session protection, readiness/overflow behavior, and axe coverage where supported.

Out of scope:

  • Event-property mapping, category persistence, preference writes, generic category-service infrastructure, a final +x more tooltip/full-list decision, and direct calendar mutation.

TB-Tools story description:

Summary:

Implement main-dialog category selection and selected-category chips using serializable draft state.

Links:

Questions and concerns:

  • The SOW includes “Add to personal category” but lists broader event category/color work as a future improvement. Confirm whether this story is limited to the Zeplin row-and-chips MVP. (additional work is out of scope)

  • Planning: Questions - Q15 Category MVP Scope And Overflow Disclosure

Acceptance criteria:

  • The main dialog provides an accessible Add category control and selected-category chips/tags.
  • The current session’s selected categories render through stable storeObserver selections of a plain category draft. Do not use getters that pull state from the store.
  • The category draft holds only plain stable IDs or labels and design-relevant color/label metadata. It contains no preference object, calIEvent, calendar object, DOM node, or popup state.
  • Selecting or removing a category dispatches a narrow category-section patch and changes draft state only. Chip removal is keyboard accessible.
  • Category-choice lookup, popup-open state, active option, type-ahead text, and layout measurement remain local control state. They do not enter Redux.
  • A memoized selector derives the full selected-category view model from store state; responsive chip capacity and +x more layout remain DOM/controller-local.
  • The main view shows two or three chips as space allows, then displays +x more. Tooltip/full-list behavior for +x more will scroll within the dialog.
  • A single chip can not be multiple lines and truncates any overflowed text at the end of the line.
  • Category color and label treatment follows the design. Visible chip overflow must not grow or re-position the dialog; initial hydrated chips are accounted for before show readiness completes.
  • A route/session replacement clears obsolete local category interaction and prevents stale selection or removal events from patching the newer draft.
  • Bug 2062008 owns edit-source category mapping and Save-time event-property conversion.
  • Add focused tests for Add category entry, selected-chip display, keyboard removal, serializable draft-only patches, two/three-chip capacity, +x more TBD behavior, color/label presentation, stale-session protection, readiness/overflow behavior, and axe coverage where supported.

Out of scope:

  • Event-property mapping, category persistence, preference writes, generic category-service infrastructure, a final +x more tooltip/full-list decision, and direct calendar mutation.

TB-Tools story description:

Summary:
Add the structure and styles for the category row. This story does not load categories or connect the controls to event data.

Links:

Acceptance criteria:

  • Use the shared row from Bug 2061586.
  • Add the markup for Add category, the category list, selected chips, and each chip's remove button.
  • Add the markup for +x more and the area that shows the remaining categories.
  • Keep each chip on one line. Cut off long text at the end of that line.
  • Provide styles for category labels and colors.
  • Keep overflow inside the dialog. It must not make the dialog grow or change position.
  • Give controls translated labels, accessible names, and visible keyboard focus.

Required implementation details:

  • Use fixed sample data in tests to show empty, filled, long-label, and overflow states.
  • Do not add category lookup, Redux subscriptions, draft changes, or Save behavior.
  • Leave real category colors, the visible chip count, and control actions to Bug 2084433.

Minimum test coverage:

  • Check the markup and labels.
  • Check single-line chips, long labels, and scrolling.
  • Check supported themes, display densities, and forced colors.
  • Run automated accessibility checks where supported.

Out of scope:

  • Loading categories, adding or removing selections, calculating +x more, and saving.
  • Broader category or event-color work beyond the designed row and chips.
Points: --- → 5
Assignee: nobody → arschmitz
Blocks: 2084433
Points: 5 → 2
Summary: Implement category selection and selected category chips → Add category row and chip markup
No longer blocks: 2062008
Status: NEW → ASSIGNED

Add the shared category row, translated controls, reusable chip markup, and bounded scrolling styles. Include keyboard, accessibility, theme, and layout coverage.

Target Milestone: --- → 162 Branch

Pushed by jtracey@thunderbird.net:
https://hg.mozilla.org/comm-central/rev/bc7afa8155db
Add category row and chip markup. r=tobyp

Status: ASSIGNED → RESOLVED
Closed: 14 days ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: