@crvouga/mockingbird-notifications 0.1.0 → 0.2.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -24,19 +24,28 @@ var TEST_IDS = {
24
24
  /** Bottom-left message after an action, e.g. "Conversation archived." */
25
25
  toast: "toast",
26
26
  toastUndo: "toast-undo",
27
+ // ── Channel tabs ─────────────────────────────────────────────────────────────
28
+ /** The `role="tablist"` that switches between devices; `data-layout="grid" | "tabs"`. */
29
+ channelTabs: "channel-tabs",
30
+ /** One `role="tab"`; `data-value="all" | "sms" | "push" | "email" | "chat"`, `aria-selected`, `data-unread` (a count). */
31
+ channelTab: "channel-tab",
32
+ /** Unread badge on a tab whose device is not showing its newest arrivals (absent when 0). */
33
+ channelTabUnread: "channel-tab-unread",
27
34
  // ── SMS: Messages ────────────────────────────────────────────────────────────
28
- /** The phone; `data-screen="threads" | "conversation"`, `data-recipient`, `data-thread`. */
35
+ /** The phone; `data-screen="threads" | "conversation"`, `data-recipient`, `data-thread`, and `data-via="whatsapp"` while a WhatsApp chat is open. */
29
36
  smsDevice: "sms-device",
30
37
  /** Phone number `<select>`; option values are E.164 numbers. */
31
38
  smsRecipient: "sms-recipient",
32
39
  /** Unread SMS badge next to the column title (absent when 0). */
33
40
  smsUnreadCount: "sms-unread-count",
34
- /** One conversation in the list; `data-from` (the sender address), `data-unread`, `data-pinned`, `data-muted`. */
41
+ /** One conversation in the list; `data-from` (the sender address), `data-unread`, `data-pinned`, `data-muted`, `data-via`. */
35
42
  smsThread: "sms-thread",
36
43
  smsThreadName: "sms-thread-name",
37
44
  smsThreadPreview: "sms-thread-preview",
38
45
  smsThreadTime: "sms-thread-time",
39
46
  smsThreadUnread: "sms-thread-unread",
47
+ /** "WhatsApp" label on a WhatsApp conversation in the list. */
48
+ smsThreadVia: "sms-thread-via",
40
49
  /** Swipe actions behind a thread (also reachable with the keyboard: focus the thread, press Delete). */
41
50
  smsThreadDelete: "sms-thread-delete",
42
51
  smsThreadMute: "sms-thread-mute",
@@ -44,7 +53,7 @@ var TEST_IDS = {
44
53
  smsThreadToggleUnread: "sms-thread-toggle-unread",
45
54
  /** Shown when the phone has no messages. */
46
55
  smsEmpty: "sms-empty",
47
- /** An open conversation; `data-from`. */
56
+ /** An open conversation; `data-from`, `data-via="sms" | "whatsapp"`. */
48
57
  smsConversation: "sms-conversation",
49
58
  smsConversationTitle: "sms-conversation-title",
50
59
  smsBack: "sms-back",
@@ -141,6 +150,30 @@ var TEST_IDS = {
141
150
  emailAttachments: "email-attachments",
142
151
  /** One attachment; `data-filename`, `data-content-type`, `data-size`. */
143
152
  emailAttachment: "email-attachment",
153
+ // ── Chat: team chat window ──────────────────────────────────────────────────
154
+ /** The chat window; `data-recipient` (the open channel), `data-workspace`. */
155
+ chatDevice: "chat-device",
156
+ /** Channel `<select>`; option values are channel names (`#alerts`) or webhook paths. */
157
+ chatRecipient: "chat-recipient",
158
+ chatUnreadCount: "chat-unread-count",
159
+ chatWorkspace: "chat-workspace",
160
+ /** One channel in the sidebar; `data-to`, `data-unread` (a count), `aria-current`. */
161
+ chatChannel: "chat-channel",
162
+ /** The open channel's name in the header. */
163
+ chatTitle: "chat-title",
164
+ /** One message; notification attributes plus `data-method`, `data-ephemeral`, `data-thread`. */
165
+ chatMessage: "chat-message",
166
+ chatMessageAuthor: "chat-message-author",
167
+ chatMessageTime: "chat-message-time",
168
+ /** The message text, with mrkdwn formatting applied. */
169
+ chatMessageText: "chat-message-text",
170
+ /** Block Kit blocks; each block inside carries `data-block="<type>"`. */
171
+ chatMessageBlocks: "chat-message-blocks",
172
+ /** Legacy attachments; each one inside carries `data-color`. */
173
+ chatMessageAttachments: "chat-message-attachments",
174
+ /** One reaction; `data-name`, `data-count`. */
175
+ chatMessageReaction: "chat-message-reaction",
176
+ chatEmpty: "chat-empty",
144
177
  // ── Timeline + inspector ────────────────────────────────────────────────────
145
178
  timeline: "timeline",
146
179
  /** One row; notification attributes. Click it to inspect. */
@@ -154,7 +187,16 @@ var TEST_IDS = {
154
187
  /** One normalized field; `data-field`. */
155
188
  inspectorField: "inspector-field",
156
189
  /** The full record, normalized fields plus `raw`, as JSON text. */
157
- inspectorJson: "inspector-json"
190
+ inspectorJson: "inspector-json",
191
+ // ── Dashboard (mountDashboard) ───────────────────────────────────────────────
192
+ /** The dashboard root; `data-tab` is the open tab's id. */
193
+ dashboard: "dashboard",
194
+ /** One tab button; `data-tab` (`emulators`, `notifications`, or an embedder's id), `aria-selected`. */
195
+ dashboardTab: "dashboard-tab",
196
+ /** One tab's panel; `data-tab`. Hidden unless its tab is open. */
197
+ dashboardPanel: "dashboard-panel",
198
+ /** Notifications that arrived while another tab was open; `data-count`. Hidden at 0. */
199
+ dashboardBadge: "dashboard-badge"
158
200
  };
159
201
  var attr = (value) => JSON.stringify(value);
160
202
  var selectors = {
@@ -168,16 +210,26 @@ var selectors = {
168
210
  smsBubble: (filter = {}) => `[data-testid=${attr(TEST_IDS.smsBubble)}]${filter.from ? `[data-from=${attr(filter.from)}]` : ""}${filter.id ? `[data-notification-id=${attr(filter.id)}]` : ""}`,
169
211
  /** A conversation in the Messages list. */
170
212
  smsThread: (from) => `[data-testid=${attr(TEST_IDS.smsThread)}][data-from=${attr(from)}]`,
213
+ /** A channel tab: `"all"`, `"sms"`, `"push"`, `"email"` or `"chat"`. */
214
+ channelTab: (value) => `[data-testid=${attr(TEST_IDS.channelTab)}][data-value=${attr(value)}]`,
215
+ /** A chat message, optionally by id. */
216
+ chatMessage: (id) => `[data-testid=${attr(TEST_IDS.chatMessage)}]${id ? `[data-notification-id=${attr(id)}]` : ""}`,
217
+ /** A channel in the chat sidebar. */
218
+ chatChannel: (to) => `[data-testid=${attr(TEST_IDS.chatChannel)}][data-to=${attr(to)}]`,
171
219
  /** A push notification card, optionally by id. */
172
220
  pushNotification: (id) => `[data-testid=${attr(TEST_IDS.pushNotification)}]${id ? `[data-notification-id=${attr(id)}]` : ""}`,
173
221
  /** An inbox row, optionally by id. */
174
222
  emailRow: (id) => `[data-testid=${attr(TEST_IDS.emailRow)}]${id ? `[data-notification-id=${attr(id)}]` : ""}`,
175
223
  /** A timeline row, optionally by id. */
176
- timelineRow: (id) => `[data-testid=${attr(TEST_IDS.timelineRow)}]${id ? `[data-notification-id=${attr(id)}]` : ""}`
224
+ timelineRow: (id) => `[data-testid=${attr(TEST_IDS.timelineRow)}]${id ? `[data-notification-id=${attr(id)}]` : ""}`,
225
+ /** A dashboard tab button by tab id (`emulators`, `notifications`, …). */
226
+ dashboardTab: (id) => `[data-testid=${attr(TEST_IDS.dashboardTab)}][data-tab=${attr(id)}]`,
227
+ /** A dashboard tab's panel by tab id. */
228
+ dashboardPanel: (id) => `[data-testid=${attr(TEST_IDS.dashboardPanel)}][data-tab=${attr(id)}]`
177
229
  };
178
230
 
179
231
  export {
180
232
  TEST_IDS,
181
233
  selectors
182
234
  };
183
- //# sourceMappingURL=chunk-LM7R7AR7.js.map
235
+ //# sourceMappingURL=chunk-FBJ2DRHH.js.map
@@ -0,0 +1,7 @@
1
+ {
2
+ "version": 3,
3
+ "sources": ["../src/testids.ts"],
4
+ "sourcesContent": ["/**\n * Every `data-testid` the harness UI renders, and selector helpers for browser tests.\n *\n * Elements that show one notification also carry its fields as attributes, so a test can narrow by\n * what it knows instead of by position:\n *\n * data-notification-id data-channel data-service data-source data-to data-from\n * data-status data-created-at data-unread (\"true\" | \"false\")\n * data-via (\"whatsapp\", only on WhatsApp messages)\n *\n * The UI root (`TEST_IDS.app`) reports its state the same way: `data-ready` (\"true\" once the first\n * read finished), `data-view`, `data-namespace`, `data-count`, `data-version`, `data-connected`,\n * `data-sound`, `data-motion`, `data-layout` (\"grid\" = devices side by side, \"tabs\" = one device at\n * a time) and `data-tab` (the selected channel tab: \"all\", \"sms\", \"push\", \"email\" or \"chat\").\n *\n * This module has no dependencies, so Playwright, Cypress or WebdriverIO specs can import it.\n */\nexport const TEST_IDS = {\n /** The UI root. */\n app: \"notifications-app\",\n\n // \u2500\u2500 Top bar \u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\n topbar: \"topbar\",\n /** `<select>` of namespaces. */\n namespace: \"namespace\",\n /** Filter `<input>` (recipient, sender, text). */\n search: \"search\",\n /** View tabs; `aria-pressed=\"true\"` on the active one. */\n viewDevices: \"view-devices\",\n viewTimeline: \"view-timeline\",\n /** \"Follow new\" checkbox. */\n follow: \"follow\",\n /** Sound on/off button; `aria-pressed`. */\n sound: \"sound-toggle\",\n /** Live stream indicator; `data-state=\"live\" | \"reconnecting\"`. */\n connection: \"connection\",\n /** One pill per emulator; `data-name`, `data-service`, `data-ok`, `data-count`. */\n source: \"source\",\n /** Discovery or emulator errors, or the \"no emulators\" hint; `data-kind=\"error\" | \"empty\"`. */\n notice: \"notice\",\n /** Bottom-left message after an action, e.g. \"Conversation archived.\" */\n toast: \"toast\",\n toastUndo: \"toast-undo\",\n\n // \u2500\u2500 Channel tabs \u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\n /** The `role=\"tablist\"` that switches between devices; `data-layout=\"grid\" | \"tabs\"`. */\n channelTabs: \"channel-tabs\",\n /** One `role=\"tab\"`; `data-value=\"all\" | \"sms\" | \"push\" | \"email\" | \"chat\"`, `aria-selected`, `data-unread` (a count). */\n channelTab: \"channel-tab\",\n /** Unread badge on a tab whose device is not showing its newest arrivals (absent when 0). */\n channelTabUnread: \"channel-tab-unread\",\n\n // \u2500\u2500 SMS: Messages \u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\n /** The phone; `data-screen=\"threads\" | \"conversation\"`, `data-recipient`, `data-thread`, and `data-via=\"whatsapp\"` while a WhatsApp chat is open. */\n smsDevice: \"sms-device\",\n /** Phone number `<select>`; option values are E.164 numbers. */\n smsRecipient: \"sms-recipient\",\n /** Unread SMS badge next to the column title (absent when 0). */\n smsUnreadCount: \"sms-unread-count\",\n /** One conversation in the list; `data-from` (the sender address), `data-unread`, `data-pinned`, `data-muted`, `data-via`. */\n smsThread: \"sms-thread\",\n smsThreadName: \"sms-thread-name\",\n smsThreadPreview: \"sms-thread-preview\",\n smsThreadTime: \"sms-thread-time\",\n smsThreadUnread: \"sms-thread-unread\",\n /** \"WhatsApp\" label on a WhatsApp conversation in the list. */\n smsThreadVia: \"sms-thread-via\",\n /** Swipe actions behind a thread (also reachable with the keyboard: focus the thread, press Delete). */\n smsThreadDelete: \"sms-thread-delete\",\n smsThreadMute: \"sms-thread-mute\",\n smsThreadPin: \"sms-thread-pin\",\n smsThreadToggleUnread: \"sms-thread-toggle-unread\",\n /** Shown when the phone has no messages. */\n smsEmpty: \"sms-empty\",\n /** An open conversation; `data-from`, `data-via=\"sms\" | \"whatsapp\"`. */\n smsConversation: \"sms-conversation\",\n smsConversationTitle: \"sms-conversation-title\",\n smsBack: \"sms-back\",\n /** One message; carries the notification attributes plus `data-code` when it holds a one-time code. */\n smsBubble: \"sms-bubble\",\n smsBubbleMedia: \"sms-bubble-media\",\n /** The time revealed by swiping the conversation left. */\n smsBubbleTime: \"sms-bubble-time\",\n /** A reaction added with the long-press menu; `data-tapback`. */\n smsTapback: \"sms-tapback\",\n /** Centered date stamp between messages. */\n smsTimestamp: \"sms-timestamp\",\n /** One-time code suggestion above the keyboard; `data-code`. */\n smsCode: \"sms-code\",\n /** Long-press menu on a bubble. */\n smsMenu: \"sms-menu\",\n smsMenuCopy: \"sms-menu-copy\",\n /** One tapback in the menu; `data-tapback=\"heart\" | \"like\" | \"dislike\" | \"laugh\" | \"emphasize\" | \"question\"`. */\n smsMenuTapback: \"sms-menu-tapback\",\n\n // \u2500\u2500 Push: lock screen (iOS) / shade (Android) \u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\n /** The phone; `data-skin=\"ios\" | \"android\"`, `data-recipient`, `data-platform`. */\n pushDevice: \"push-device\",\n /** Device token `<select>`. */\n pushRecipient: \"push-recipient\",\n /** Skin buttons; `data-value`, `aria-pressed`. */\n pushSkin: \"push-skin\",\n pushUnreadCount: \"push-unread-count\",\n /** One notification; notification attributes plus `data-expanded`, `data-platform`, `data-app`, `data-stacked`. */\n pushNotification: \"push-notification\",\n pushNotificationApp: \"push-notification-app\",\n pushNotificationTitle: \"push-notification-title\",\n pushNotificationBody: \"push-notification-body\",\n pushNotificationTime: \"push-notification-time\",\n pushNotificationImage: \"push-notification-image\",\n /** The `data` payload, shown when expanded. */\n pushNotificationData: \"push-notification-data\",\n /** Service, status, badge and sound, shown when expanded. */\n pushNotificationMeta: \"push-notification-meta\",\n /** iOS: a group of notifications from one app; `data-app`, `data-count`, `data-open`. */\n pushGroup: \"push-group\",\n /** iOS: \"N more notifications\" under a collapsed group (click to open it); `data-count`. */\n pushGroupMore: \"push-group-more\",\n /** iOS: \"Show less\" on an open group. */\n pushGroupCollapse: \"push-group-collapse\",\n /** iOS: swipe-left actions. */\n pushClear: \"push-clear\",\n pushOptions: \"push-options\",\n /** iOS long-press preview; Android long-press settings. */\n pushPreview: \"push-preview\",\n pushSettings: \"push-settings\",\n /** Android \"Clear all\". */\n pushClearAll: \"push-clear-all\",\n pushEmpty: \"push-empty\",\n\n // \u2500\u2500 Email: web mail \u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\n /** The browser window; `data-screen=\"inbox\" | \"message\"`, `data-recipient`. */\n emailDevice: \"email-device\",\n /** Mailbox `<select>`; option values are lower-case addresses. */\n emailRecipient: \"email-recipient\",\n emailUnreadCount: \"email-unread-count\",\n /** One inbox row; notification attributes plus `data-starred`. */\n emailRow: \"email-row\",\n emailRowFrom: \"email-row-from\",\n emailRowSubject: \"email-row-subject\",\n emailRowSnippet: \"email-row-snippet\",\n emailRowDate: \"email-row-date\",\n emailRowService: \"email-row-service\",\n emailRowAttachment: \"email-row-attachment\",\n emailRowStar: \"email-row-star\",\n /** Hover actions on a row. */\n emailRowArchive: \"email-row-archive\",\n emailRowDelete: \"email-row-delete\",\n emailRowToggleRead: \"email-row-toggle-read\",\n emailRefresh: \"email-refresh\",\n emailEmpty: \"email-empty\",\n /** The open message; notification attributes. */\n emailOpen: \"email-open\",\n emailBack: \"email-back\",\n emailArchive: \"email-archive\",\n emailDelete: \"email-delete\",\n emailMarkUnread: \"email-mark-unread\",\n emailSubject: \"email-subject\",\n emailFromName: \"email-from-name\",\n emailFromAddress: \"email-from-address\",\n /** \"to me, \u2026\" line; click to toggle the details. */\n emailTo: \"email-to\",\n emailDate: \"email-date\",\n emailDetails: \"email-details\",\n /** One row of the details; `data-field=\"from\" | \"to\" | \"cc\" | \"bcc\" | \"reply-to\" | \"date\" | \"subject\" | \"mailed-by\" | \"message-id\"`. */\n emailDetail: \"email-detail\",\n /** The HTML body `<iframe>` (same origin: use `frameLocator`). */\n emailBody: \"email-body\",\n /** The plain-text body when there is no HTML. */\n emailText: \"email-text\",\n emailAttachments: \"email-attachments\",\n /** One attachment; `data-filename`, `data-content-type`, `data-size`. */\n emailAttachment: \"email-attachment\",\n\n // \u2500\u2500 Chat: team chat window \u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\n /** The chat window; `data-recipient` (the open channel), `data-workspace`. */\n chatDevice: \"chat-device\",\n /** Channel `<select>`; option values are channel names (`#alerts`) or webhook paths. */\n chatRecipient: \"chat-recipient\",\n chatUnreadCount: \"chat-unread-count\",\n chatWorkspace: \"chat-workspace\",\n /** One channel in the sidebar; `data-to`, `data-unread` (a count), `aria-current`. */\n chatChannel: \"chat-channel\",\n /** The open channel's name in the header. */\n chatTitle: \"chat-title\",\n /** One message; notification attributes plus `data-method`, `data-ephemeral`, `data-thread`. */\n chatMessage: \"chat-message\",\n chatMessageAuthor: \"chat-message-author\",\n chatMessageTime: \"chat-message-time\",\n /** The message text, with mrkdwn formatting applied. */\n chatMessageText: \"chat-message-text\",\n /** Block Kit blocks; each block inside carries `data-block=\"<type>\"`. */\n chatMessageBlocks: \"chat-message-blocks\",\n /** Legacy attachments; each one inside carries `data-color`. */\n chatMessageAttachments: \"chat-message-attachments\",\n /** One reaction; `data-name`, `data-count`. */\n chatMessageReaction: \"chat-message-reaction\",\n chatEmpty: \"chat-empty\",\n\n // \u2500\u2500 Timeline + inspector \u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\n timeline: \"timeline\",\n /** One row; notification attributes. Click it to inspect. */\n timelineRow: \"timeline-row\",\n timelineEmpty: \"timeline-empty\",\n /** The JSON inspector; notification attributes. Opened by clicking a timeline row or double-clicking any notification. */\n inspector: \"inspector\",\n inspectorTitle: \"inspector-title\",\n inspectorClose: \"inspector-close\",\n inspectorShowOnDevice: \"inspector-show-on-device\",\n /** One normalized field; `data-field`. */\n inspectorField: \"inspector-field\",\n /** The full record, normalized fields plus `raw`, as JSON text. */\n inspectorJson: \"inspector-json\",\n\n // \u2500\u2500 Dashboard (mountDashboard) \u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\n /** The dashboard root; `data-tab` is the open tab's id. */\n dashboard: \"dashboard\",\n /** One tab button; `data-tab` (`emulators`, `notifications`, or an embedder's id), `aria-selected`. */\n dashboardTab: \"dashboard-tab\",\n /** One tab's panel; `data-tab`. Hidden unless its tab is open. */\n dashboardPanel: \"dashboard-panel\",\n /** Notifications that arrived while another tab was open; `data-count`. Hidden at 0. */\n dashboardBadge: \"dashboard-badge\",\n} as const\n\nexport type TestId = (typeof TEST_IDS)[keyof typeof TEST_IDS]\n\nconst attr = (value: string) => JSON.stringify(value)\n\n/** CSS selectors for the harness UI. Each one works with `page.locator()` or `querySelector`. */\nexport const selectors = {\n /** `[data-testid=\"\u2026\"]` */\n testId: (id: TestId) => `[data-testid=${attr(id)}]`,\n /** The ready UI root: wait for this before asserting. */\n ready: () => `[data-testid=${attr(TEST_IDS.app)}][data-ready=\"true\"]`,\n /** Any element showing this notification (bubble, thread, card, row, open email, timeline row). */\n notification: (id: string) => `[data-notification-id=${attr(id)}]`,\n /** A message bubble, optionally from one sender. */\n smsBubble: (filter: { from?: string; id?: string } = {}) =>\n `[data-testid=${attr(TEST_IDS.smsBubble)}]${filter.from ? `[data-from=${attr(filter.from)}]` : \"\"}${filter.id ? `[data-notification-id=${attr(filter.id)}]` : \"\"}`,\n /** A conversation in the Messages list. */\n smsThread: (from: string) => `[data-testid=${attr(TEST_IDS.smsThread)}][data-from=${attr(from)}]`,\n /** A channel tab: `\"all\"`, `\"sms\"`, `\"push\"`, `\"email\"` or `\"chat\"`. */\n channelTab: (value: \"all\" | \"sms\" | \"push\" | \"email\" | \"chat\") =>\n `[data-testid=${attr(TEST_IDS.channelTab)}][data-value=${attr(value)}]`,\n /** A chat message, optionally by id. */\n chatMessage: (id?: string) =>\n `[data-testid=${attr(TEST_IDS.chatMessage)}]${id ? `[data-notification-id=${attr(id)}]` : \"\"}`,\n /** A channel in the chat sidebar. */\n chatChannel: (to: string) => `[data-testid=${attr(TEST_IDS.chatChannel)}][data-to=${attr(to)}]`,\n /** A push notification card, optionally by id. */\n pushNotification: (id?: string) =>\n `[data-testid=${attr(TEST_IDS.pushNotification)}]${id ? `[data-notification-id=${attr(id)}]` : \"\"}`,\n /** An inbox row, optionally by id. */\n emailRow: (id?: string) =>\n `[data-testid=${attr(TEST_IDS.emailRow)}]${id ? `[data-notification-id=${attr(id)}]` : \"\"}`,\n /** A timeline row, optionally by id. */\n timelineRow: (id?: string) =>\n `[data-testid=${attr(TEST_IDS.timelineRow)}]${id ? `[data-notification-id=${attr(id)}]` : \"\"}`,\n /** A dashboard tab button by tab id (`emulators`, `notifications`, \u2026). */\n dashboardTab: (id: string) =>\n `[data-testid=${attr(TEST_IDS.dashboardTab)}][data-tab=${attr(id)}]`,\n /** A dashboard tab's panel by tab id. */\n dashboardPanel: (id: string) =>\n `[data-testid=${attr(TEST_IDS.dashboardPanel)}][data-tab=${attr(id)}]`,\n}\n"],
5
+ "mappings": ";AAiBO,IAAM,WAAW;AAAA;AAAA,EAEtB,KAAK;AAAA;AAAA,EAGL,QAAQ;AAAA;AAAA,EAER,WAAW;AAAA;AAAA,EAEX,QAAQ;AAAA;AAAA,EAER,aAAa;AAAA,EACb,cAAc;AAAA;AAAA,EAEd,QAAQ;AAAA;AAAA,EAER,OAAO;AAAA;AAAA,EAEP,YAAY;AAAA;AAAA,EAEZ,QAAQ;AAAA;AAAA,EAER,QAAQ;AAAA;AAAA,EAER,OAAO;AAAA,EACP,WAAW;AAAA;AAAA;AAAA,EAIX,aAAa;AAAA;AAAA,EAEb,YAAY;AAAA;AAAA,EAEZ,kBAAkB;AAAA;AAAA;AAAA,EAIlB,WAAW;AAAA;AAAA,EAEX,cAAc;AAAA;AAAA,EAEd,gBAAgB;AAAA;AAAA,EAEhB,WAAW;AAAA,EACX,eAAe;AAAA,EACf,kBAAkB;AAAA,EAClB,eAAe;AAAA,EACf,iBAAiB;AAAA;AAAA,EAEjB,cAAc;AAAA;AAAA,EAEd,iBAAiB;AAAA,EACjB,eAAe;AAAA,EACf,cAAc;AAAA,EACd,uBAAuB;AAAA;AAAA,EAEvB,UAAU;AAAA;AAAA,EAEV,iBAAiB;AAAA,EACjB,sBAAsB;AAAA,EACtB,SAAS;AAAA;AAAA,EAET,WAAW;AAAA,EACX,gBAAgB;AAAA;AAAA,EAEhB,eAAe;AAAA;AAAA,EAEf,YAAY;AAAA;AAAA,EAEZ,cAAc;AAAA;AAAA,EAEd,SAAS;AAAA;AAAA,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