From f35d7e5037edb53e951052ee4d1472daff1fdd8a Mon Sep 17 00:00:00 2001 From: Matthew Meszaros Date: Mon, 31 Aug 2026 04:19:20 -0700 Subject: [PATCH] feat: address CodeRabbit review on the segment ID chip: narrow the API reference sentence to endpoints that operate on an existing segment, add an aria-label and a polite sr-only status to the copy button so the copied state reaches assistive technology --- docs/content/docs/api/reference/contacts.mdx | 2 +- .../app/app/contacts/segments/[id]/page.tsx | 26 ++++++++++++------- 2 files changed, 17 insertions(+), 11 deletions(-) diff --git a/docs/content/docs/api/reference/contacts.mdx b/docs/content/docs/api/reference/contacts.mdx index fffe6cd8..a72fae15 100644 --- a/docs/content/docs/api/reference/contacts.mdx +++ b/docs/content/docs/api/reference/contacts.mdx @@ -982,7 +982,7 @@ Auth: **Scope** `READ_CRM` ยท **Org permission** `view_contacts` ## Segments -Segments are saved contact audiences: a list of conditions plus per-contact manual overrides. Membership is evaluated live on every read, so a segment never needs rebuilding. Every segment endpoint takes the contact scopes, except enrolling into a campaign, which writes leads and takes `WRITE_CAMPAIGNS`. Every endpoint here addresses a segment by its `id`; besides `GET /segments`, the dashboard shows it on the segment page header (click to copy) and in the row menu of the Segments tab. +Segments are saved contact audiences: a list of conditions plus per-contact manual overrides. Membership is evaluated live on every read, so a segment never needs rebuilding. Every segment endpoint takes the contact scopes, except enrolling into a campaign, which writes leads and takes `WRITE_CAMPAIGNS`. Endpoints that operate on an existing segment address it by its `id`; besides `GET /segments`, the dashboard shows that ID on the segment page header (click to copy) and in the row menu of the Segments tab. A segment object: diff --git a/web/src/app/app/contacts/segments/[id]/page.tsx b/web/src/app/app/contacts/segments/[id]/page.tsx index 978382dc..2e41856a 100644 --- a/web/src/app/app/contacts/segments/[id]/page.tsx +++ b/web/src/app/app/contacts/segments/[id]/page.tsx @@ -149,16 +149,22 @@ function SegmentIdChip({ id }: { id: string }) { } } return ( - + <> + + + {copied ? "Segment ID copied" : ""} + + ); }