@remit/ui 0.0.193 → 0.0.195
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.
- package/package.json +1 -1
- package/src/components/account-service-change-dialog.stories.tsx +1 -1
- package/src/components/account-service-choice.stories.tsx +1 -1
- package/src/components/account-service-status.stories.tsx +1 -1
- package/src/components/account-service-toggles.stories.tsx +2 -1
- package/src/components/address-display.stories.tsx +1 -1
- package/src/components/address-tag.stories.tsx +1 -1
- package/src/components/agenda-composer.render.test.ts +1 -0
- package/src/components/agenda-composer.stories.tsx +3 -1
- package/src/components/agenda-flow.stories.tsx +1 -1
- package/src/components/agenda-flow.tsx +3 -0
- package/src/components/agenda-panels.stories.tsx +1 -1
- package/src/components/app-password-hint.stories.tsx +1 -1
- package/src/components/app-top-bar.stories.tsx +1 -1
- package/src/components/attachment-list.stories.tsx +1 -1
- package/src/components/attendee-row.stories.tsx +1 -1
- package/src/components/auth-card.stories.tsx +1 -1
- package/src/components/auth-footer.stories.tsx +1 -1
- package/src/components/auth-hero.stories.tsx +1 -1
- package/src/components/auto-moved-badge.stories.tsx +1 -1
- package/src/components/banner.stories.tsx +1 -1
- package/src/components/bottom-sheet.stories.tsx +1 -1
- package/src/components/brief-empty.stories.tsx +1 -1
- package/src/components/brief-section.stories.tsx +1 -1
- package/src/components/brief-sections.stories.tsx +1 -1
- package/src/components/calendar-clash-strip.stories.tsx +1 -1
- package/src/components/calendar-event-chip.stories.tsx +1 -1
- package/src/components/calendar-grid.stories.tsx +1 -1
- package/src/components/calendar-invite-card.stories.tsx +1 -1
- package/src/components/calendar-list.stories.tsx +1 -1
- package/src/components/calendar-parse-badge.stories.tsx +1 -1
- package/src/components/calendar-slot-offers.render.test.ts +7 -1
- package/src/components/calendar-slot-offers.stories.tsx +8 -2
- package/src/components/calendar-suggestion-deck.stories.tsx +1 -1
- package/src/components/calendar-toolbar.stories.tsx +1 -1
- package/src/components/calendar-types.ts +2 -0
- package/src/components/category-badge.stories.tsx +1 -1
- package/src/components/category-presentation.stories.tsx +1 -1
- package/src/components/checkbox.stories.tsx +1 -1
- package/src/components/compose-action-bar.stories.tsx +1 -1
- package/src/components/compose-address-field.stories.tsx +1 -1
- package/src/components/compose-body.stories.tsx +1 -1
- package/src/components/compose-header.stories.tsx +1 -1
- package/src/components/compose-language-chip.stories.tsx +1 -1
- package/src/components/compose-language-setting.stories.tsx +1 -1
- package/src/components/compose-mode-toggle.stories.tsx +1 -1
- package/src/components/compose-smtp-missing-banner.stories.tsx +1 -1
- package/src/components/confirm-dialog.stories.tsx +1 -1
- package/src/components/custom-recurrence.stories.tsx +1 -1
- package/src/components/dialog.stories.tsx +1 -1
- package/src/components/event-detail.stories.tsx +1 -1
- package/src/components/event-editor.render.test.ts +23 -0
- package/src/components/event-editor.stories.tsx +32 -5
- package/src/components/event-editor.tsx +78 -50
- package/src/components/event-quick-entry.stories.tsx +1 -1
- package/src/components/event-suggestion-card.stories.tsx +1 -1
- package/src/components/filter-rule-editor.stories.tsx +1 -1
- package/src/components/filter-sheet.stories.tsx +1 -1
- package/src/components/folder-manage-actions.stories.tsx +1 -1
- package/src/components/folder-manager.stories.tsx +1 -1
- package/src/components/folder-rename-dialog.stories.tsx +1 -1
- package/src/components/folder-row.stories.tsx +1 -1
- package/src/components/folder-tree-picker.stories.tsx +1 -1
- package/src/components/intelligence-calendar-fixtures.ts +7 -1
- package/src/components/intelligence-panel-calendar.stories.tsx +2 -1
- package/src/components/intelligence-panel.stories.tsx +1 -1
- package/src/components/isolated-email-frame.stories.tsx +1 -1
- package/src/components/label-chip.stories.tsx +1 -1
- package/src/components/list-result-header.stories.tsx +1 -1
- package/src/components/mail-action-toolbar.stories.tsx +1 -1
- package/src/components/mail-header.stories.tsx +2 -1
- package/src/components/message-body-view.stories.tsx +1 -1
- package/src/components/message-list-pane.stories.tsx +1 -1
- package/src/components/message-list-state.stories.tsx +1 -1
- package/src/components/message-row.stories.tsx +1 -1
- package/src/components/message-settlement.stories.tsx +1 -1
- package/src/components/mobile-message-action-bar.stories.tsx +1 -1
- package/src/components/mobile-search-view.stories.tsx +1 -1
- package/src/components/nav-sidebar.stories.tsx +1 -1
- package/src/components/new-folder-action.stories.tsx +1 -1
- package/src/components/new-folder-form.stories.tsx +1 -1
- package/src/components/outbox-row.stories.tsx +1 -1
- package/src/components/plain-text-editor.stories.tsx +1 -1
- package/src/components/popover-menu.stories.tsx +1 -1
- package/src/components/primitives.stories.tsx +1 -1
- package/src/components/progress-bar.stories.tsx +1 -1
- package/src/components/pull-to-refresh.stories.tsx +1 -1
- package/src/components/quarantine-section.stories.tsx +1 -1
- package/src/components/quoted-text.stories.tsx +1 -1
- package/src/components/reading-pane.stories.tsx +1 -1
- package/src/components/recurrence-scope-prompt.stories.tsx +1 -1
- package/src/components/refresh-button.stories.tsx +1 -1
- package/src/components/rescue-banner.stories.tsx +1 -1
- package/src/components/rescue-candidate-row.stories.tsx +1 -1
- package/src/components/rescue-from-spam-flow.stories.tsx +1 -1
- package/src/components/rich-text-editor.stories.tsx +1 -1
- package/src/components/role-appointment-list.stories.tsx +1 -1
- package/src/components/role-appointment-prompt.stories.tsx +1 -1
- package/src/components/row-actions.stories.tsx +1 -1
- package/src/components/search-bar.stories.tsx +1 -1
- package/src/components/search-chip-input.stories.tsx +1 -1
- package/src/components/search-conversion-notice.stories.tsx +1 -1
- package/src/components/search-results.stories.tsx +1 -1
- package/src/components/search-token-chip.stories.tsx +1 -1
- package/src/components/selection-top-bar.stories.tsx +1 -1
- package/src/components/self-update-progress-overlay.stories.tsx +1 -1
- package/src/components/self-update.stories.tsx +1 -1
- package/src/components/sender-trust-indicator.stories.tsx +1 -1
- package/src/components/settings-primitives.stories.tsx +1 -1
- package/src/components/shell-top-bar.stories.tsx +1 -1
- package/src/components/slide-panel.stories.tsx +1 -1
- package/src/components/spam-results-offer.stories.tsx +1 -1
- package/src/components/swipeable-row.stories.tsx +1 -1
- package/src/components/touch-list-body.stories.tsx +1 -1
- package/src/components/wizard.stories.tsx +1 -1
- package/src/index.ts +4 -0
- package/src/lib/agenda-time.ts +15 -0
- package/src/lib/calendar-slot-pick.test.ts +25 -5
- package/src/lib/calendar-slot-pick.ts +13 -3
|
@@ -8,7 +8,7 @@ import { EventEditor } from "./event-editor.js";
|
|
|
8
8
|
* one click away, but they do not charge the common case for their existence.
|
|
9
9
|
*/
|
|
10
10
|
const meta: Meta<typeof EventEditor> = {
|
|
11
|
-
title: "Calendar/Event editor",
|
|
11
|
+
title: "Design System/Calendar/Event editor",
|
|
12
12
|
component: EventEditor,
|
|
13
13
|
parameters: { layout: "padded" },
|
|
14
14
|
};
|
|
@@ -44,6 +44,7 @@ const seed: EventDraft = {
|
|
|
44
44
|
title: "",
|
|
45
45
|
date: "2026-06-12",
|
|
46
46
|
startTime: "13:00",
|
|
47
|
+
endDate: "2026-06-12",
|
|
47
48
|
endTime: "14:00",
|
|
48
49
|
allDay: false,
|
|
49
50
|
calendarId: "c1",
|
|
@@ -53,7 +54,7 @@ const seed: EventDraft = {
|
|
|
53
54
|
repeat: "",
|
|
54
55
|
};
|
|
55
56
|
|
|
56
|
-
/** 23:00 to 01:00, which
|
|
57
|
+
/** 23:00 to 01:00 on the same day, which runs backwards. */
|
|
57
58
|
const backwards: EventDraft = {
|
|
58
59
|
...seed,
|
|
59
60
|
title: "Release window",
|
|
@@ -61,6 +62,22 @@ const backwards: EventDraft = {
|
|
|
61
62
|
endTime: "01:00",
|
|
62
63
|
};
|
|
63
64
|
|
|
65
|
+
/** 23:00 to 01:00 the next morning: one night, not a backwards hour. */
|
|
66
|
+
const overnight: EventDraft = {
|
|
67
|
+
...backwards,
|
|
68
|
+
endDate: "2026-06-13",
|
|
69
|
+
};
|
|
70
|
+
|
|
71
|
+
/** Three whole days, Friday through Sunday. */
|
|
72
|
+
const weekend: EventDraft = {
|
|
73
|
+
...seed,
|
|
74
|
+
title: "Offsite",
|
|
75
|
+
startTime: "",
|
|
76
|
+
endTime: "",
|
|
77
|
+
allDay: true,
|
|
78
|
+
endDate: "2026-06-14",
|
|
79
|
+
};
|
|
80
|
+
|
|
64
81
|
function Live({
|
|
65
82
|
startExpanded,
|
|
66
83
|
seed: initial = seed,
|
|
@@ -97,14 +114,24 @@ export const Folded: Story = { render: () => <Live startExpanded={false} /> };
|
|
|
97
114
|
export const Unfolded: Story = { render: () => <Live startExpanded /> };
|
|
98
115
|
|
|
99
116
|
/**
|
|
100
|
-
* An end before the start
|
|
101
|
-
*
|
|
102
|
-
*
|
|
117
|
+
* An end before the start reads the span backwards. The form keeps what was
|
|
118
|
+
* typed, names the problem under the fields and holds the save until it is
|
|
119
|
+
* fixed.
|
|
103
120
|
*/
|
|
104
121
|
export const EndBeforeStart: Story = {
|
|
105
122
|
render: () => <Live startExpanded={false} seed={backwards} />,
|
|
106
123
|
};
|
|
107
124
|
|
|
125
|
+
/** A night that runs past midnight ends on the next day, and saves. */
|
|
126
|
+
export const RunsPastMidnight: Story = {
|
|
127
|
+
render: () => <Live startExpanded={false} seed={overnight} />,
|
|
128
|
+
};
|
|
129
|
+
|
|
130
|
+
/** An all-day event reads from its first day to its last. */
|
|
131
|
+
export const AllDaySpan: Story = {
|
|
132
|
+
render: () => <Live startExpanded={false} seed={weekend} />,
|
|
133
|
+
};
|
|
134
|
+
|
|
108
135
|
/**
|
|
109
136
|
* Guests are opt-in. A store with nowhere to put them leaves the field out, so
|
|
110
137
|
* the default form has none: a box that takes names and drops them is worse
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { ChevronDown, ChevronRight, Repeat } from "lucide-react";
|
|
2
2
|
import { type ReactNode, useId } from "react";
|
|
3
|
+
import { addDays, daysFrom } from "../lib/agenda-time.js";
|
|
3
4
|
import { calendarColorClasses } from "../lib/calendar-color.js";
|
|
4
5
|
import { cn } from "../lib/cn.js";
|
|
5
6
|
import { NO_REPEAT, repeatChoices } from "../lib/recurrence.js";
|
|
@@ -72,20 +73,52 @@ export function EventTitleField({
|
|
|
72
73
|
}
|
|
73
74
|
|
|
74
75
|
/**
|
|
75
|
-
*
|
|
76
|
-
* over —
|
|
77
|
-
* to save it rather than swapping the
|
|
76
|
+
* An end before the start is a span the calendar reads backwards, not a night
|
|
77
|
+
* that runs over — a night that runs over ends on the next day, and says so.
|
|
78
|
+
* The form names the problem and refuses to save it rather than swapping the
|
|
79
|
+
* fields behind whoever typed them.
|
|
78
80
|
*/
|
|
79
81
|
export function endsBeforeStart(draft: EventDraft): boolean {
|
|
80
|
-
if (draft.
|
|
82
|
+
if (draft.date === "" || draft.endDate === "") return false;
|
|
83
|
+
if (draft.allDay) return draft.endDate < draft.date;
|
|
81
84
|
if (draft.startTime === "" || draft.endTime === "") return false;
|
|
82
|
-
return
|
|
85
|
+
return (
|
|
86
|
+
`${draft.endDate}T${draft.endTime}` < `${draft.date}T${draft.startTime}`
|
|
87
|
+
);
|
|
88
|
+
}
|
|
89
|
+
|
|
90
|
+
export function withStartDate(draft: EventDraft, date: string): EventDraft {
|
|
91
|
+
if (date === "") return { ...draft, date };
|
|
92
|
+
if (draft.endDate === "") return { ...draft, date, endDate: date };
|
|
93
|
+
if (draft.date === "") return { ...draft, date };
|
|
94
|
+
return {
|
|
95
|
+
...draft,
|
|
96
|
+
date,
|
|
97
|
+
endDate: addDays(date, daysFrom(draft.date, draft.endDate)),
|
|
98
|
+
};
|
|
99
|
+
}
|
|
100
|
+
|
|
101
|
+
export function withAllDay(draft: EventDraft, allDay: boolean): EventDraft {
|
|
102
|
+
const overnight =
|
|
103
|
+
draft.date !== "" &&
|
|
104
|
+
draft.endDate === addDays(draft.date, 1) &&
|
|
105
|
+
draft.startTime !== "" &&
|
|
106
|
+
draft.endTime !== "" &&
|
|
107
|
+
draft.endTime < draft.startTime;
|
|
108
|
+
if (allDay && overnight) return { ...draft, allDay, endDate: draft.date };
|
|
109
|
+
return { ...draft, allDay };
|
|
83
110
|
}
|
|
84
111
|
|
|
85
112
|
export function EventWhenField({ draft, onChange, touch }: EventFieldProps) {
|
|
86
113
|
const fieldHeight = touch ? "min-h-11" : "";
|
|
87
114
|
const backwards = endsBeforeStart(draft);
|
|
88
115
|
const messageId = useId();
|
|
116
|
+
const invalid = {
|
|
117
|
+
"aria-invalid": backwards,
|
|
118
|
+
"aria-describedby": backwards ? messageId : undefined,
|
|
119
|
+
};
|
|
120
|
+
const dateClass = cn("w-40", fieldHeight, backwards && "border-danger/60");
|
|
121
|
+
const timeClass = cn("w-28", fieldHeight, backwards && "border-danger/60");
|
|
89
122
|
return (
|
|
90
123
|
<div className="flex flex-col gap-1.5">
|
|
91
124
|
<div className="flex flex-wrap items-center gap-2">
|
|
@@ -93,57 +126,51 @@ export function EventWhenField({ draft, onChange, touch }: EventFieldProps) {
|
|
|
93
126
|
type="date"
|
|
94
127
|
value={draft.date}
|
|
95
128
|
aria-label="Date"
|
|
129
|
+
{...invalid}
|
|
130
|
+
onChange={(e) => onChange(withStartDate(draft, e.target.value))}
|
|
131
|
+
className={dateClass}
|
|
132
|
+
/>
|
|
133
|
+
{!draft.allDay && (
|
|
134
|
+
<Input
|
|
135
|
+
type="time"
|
|
136
|
+
value={draft.startTime}
|
|
137
|
+
aria-label="Start time"
|
|
138
|
+
{...invalid}
|
|
139
|
+
onChange={(e) =>
|
|
140
|
+
setField({ draft, onChange }, "startTime", e.target.value)
|
|
141
|
+
}
|
|
142
|
+
className={timeClass}
|
|
143
|
+
/>
|
|
144
|
+
)}
|
|
145
|
+
<span className="text-sm text-fg-subtle">to</span>
|
|
146
|
+
<Input
|
|
147
|
+
type="date"
|
|
148
|
+
value={draft.endDate}
|
|
149
|
+
aria-label="End date"
|
|
150
|
+
min={draft.date === "" ? undefined : draft.date}
|
|
151
|
+
{...invalid}
|
|
96
152
|
onChange={(e) =>
|
|
97
|
-
setField({ draft, onChange }, "
|
|
153
|
+
setField({ draft, onChange }, "endDate", e.target.value)
|
|
98
154
|
}
|
|
99
|
-
className={
|
|
155
|
+
className={dateClass}
|
|
100
156
|
/>
|
|
101
|
-
{draft.allDay
|
|
102
|
-
<
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
onChange={(e) =>
|
|
113
|
-
setField({ draft, onChange }, "startTime", e.target.value)
|
|
114
|
-
}
|
|
115
|
-
className={cn(
|
|
116
|
-
"w-28",
|
|
117
|
-
fieldHeight,
|
|
118
|
-
backwards && "border-danger/60",
|
|
119
|
-
)}
|
|
120
|
-
/>
|
|
121
|
-
<span className="text-sm text-fg-subtle">to</span>
|
|
122
|
-
<Input
|
|
123
|
-
type="time"
|
|
124
|
-
value={draft.endTime}
|
|
125
|
-
aria-label="End time"
|
|
126
|
-
min={draft.startTime === "" ? undefined : draft.startTime}
|
|
127
|
-
aria-invalid={backwards}
|
|
128
|
-
aria-describedby={backwards ? messageId : undefined}
|
|
129
|
-
onChange={(e) =>
|
|
130
|
-
setField({ draft, onChange }, "endTime", e.target.value)
|
|
131
|
-
}
|
|
132
|
-
className={cn(
|
|
133
|
-
"w-28",
|
|
134
|
-
fieldHeight,
|
|
135
|
-
backwards && "border-danger/60",
|
|
136
|
-
)}
|
|
137
|
-
/>
|
|
138
|
-
</>
|
|
157
|
+
{!draft.allDay && (
|
|
158
|
+
<Input
|
|
159
|
+
type="time"
|
|
160
|
+
value={draft.endTime}
|
|
161
|
+
aria-label="End time"
|
|
162
|
+
{...invalid}
|
|
163
|
+
onChange={(e) =>
|
|
164
|
+
setField({ draft, onChange }, "endTime", e.target.value)
|
|
165
|
+
}
|
|
166
|
+
className={timeClass}
|
|
167
|
+
/>
|
|
139
168
|
)}
|
|
140
169
|
<label className="flex items-center gap-2 text-sm text-fg-muted">
|
|
141
170
|
<input
|
|
142
171
|
type="checkbox"
|
|
143
172
|
checked={draft.allDay}
|
|
144
|
-
onChange={(e) =>
|
|
145
|
-
setField({ draft, onChange }, "allDay", e.target.checked)
|
|
146
|
-
}
|
|
173
|
+
onChange={(e) => onChange(withAllDay(draft, e.target.checked))}
|
|
147
174
|
className="size-4 accent-current"
|
|
148
175
|
/>
|
|
149
176
|
All day
|
|
@@ -151,8 +178,9 @@ export function EventWhenField({ draft, onChange, touch }: EventFieldProps) {
|
|
|
151
178
|
</div>
|
|
152
179
|
{backwards && (
|
|
153
180
|
<p id={messageId} className="text-xs text-danger" role="alert">
|
|
154
|
-
|
|
155
|
-
|
|
181
|
+
{draft.allDay
|
|
182
|
+
? `Ends before it starts. Move the end to ${draft.date} or later.`
|
|
183
|
+
: `Ends before it starts. Move the end past ${draft.date} ${draft.startTime}, or start earlier.`}
|
|
156
184
|
</p>
|
|
157
185
|
)}
|
|
158
186
|
</div>
|
|
@@ -10,7 +10,7 @@ import { EventQuickEntry } from "./event-quick-entry.js";
|
|
|
10
10
|
* correction happens before the event exists.
|
|
11
11
|
*/
|
|
12
12
|
const meta: Meta<typeof EventQuickEntry> = {
|
|
13
|
-
title: "Calendar/Quick entry",
|
|
13
|
+
title: "Design System/Calendar/Quick entry",
|
|
14
14
|
component: EventQuickEntry,
|
|
15
15
|
parameters: { layout: "padded" },
|
|
16
16
|
};
|
|
@@ -9,7 +9,7 @@ import { EventSuggestionCard } from "./event-suggestion-card.js";
|
|
|
9
9
|
* to notice and take back off the calendar.
|
|
10
10
|
*/
|
|
11
11
|
const meta: Meta<typeof EventSuggestionCard> = {
|
|
12
|
-
title: "Calendar/Suggestion card",
|
|
12
|
+
title: "Design System/Calendar/Suggestion card",
|
|
13
13
|
component: EventSuggestionCard,
|
|
14
14
|
parameters: { layout: "padded" },
|
|
15
15
|
decorators: [
|
|
@@ -26,7 +26,7 @@ import {
|
|
|
26
26
|
import type { FolderTreeNode } from "./folder-tree-picker.js";
|
|
27
27
|
|
|
28
28
|
const meta: Meta<typeof FilterRuleEditor> = {
|
|
29
|
-
title: "FilterRuleEditor",
|
|
29
|
+
title: "Design System/Filters/FilterRuleEditor",
|
|
30
30
|
component: FilterRuleEditor,
|
|
31
31
|
parameters: { layout: "padded" },
|
|
32
32
|
decorators: [
|
|
@@ -4,7 +4,7 @@ import { FolderManageActions } from "./folder-manage-actions.js";
|
|
|
4
4
|
import { FolderRow } from "./folder-row.js";
|
|
5
5
|
|
|
6
6
|
const meta: Meta<typeof FolderManageActions> = {
|
|
7
|
-
title: "
|
|
7
|
+
title: "Design System/Folders/FolderManageActions",
|
|
8
8
|
component: FolderManageActions,
|
|
9
9
|
parameters: { layout: "centered" },
|
|
10
10
|
};
|
|
@@ -3,7 +3,7 @@ import { useState } from "react";
|
|
|
3
3
|
import { FolderRenameDialog } from "./folder-rename-dialog.js";
|
|
4
4
|
|
|
5
5
|
const meta: Meta<typeof FolderRenameDialog> = {
|
|
6
|
-
title: "
|
|
6
|
+
title: "Design System/Folders/FolderRenameDialog",
|
|
7
7
|
component: FolderRenameDialog,
|
|
8
8
|
parameters: { layout: "fullscreen" },
|
|
9
9
|
};
|
|
@@ -68,7 +68,7 @@ const longFolders: FolderTreeNode[] = [
|
|
|
68
68
|
];
|
|
69
69
|
|
|
70
70
|
const meta: Meta<typeof FolderTreePicker> = {
|
|
71
|
-
title: "
|
|
71
|
+
title: "Design System/Folders/FolderTreePicker",
|
|
72
72
|
component: FolderTreePicker,
|
|
73
73
|
parameters: { layout: "centered" },
|
|
74
74
|
};
|
|
@@ -231,7 +231,13 @@ const thursdayProposals: CalendarProposal[] = [
|
|
|
231
231
|
const THURSDAY = "2026-06-11";
|
|
232
232
|
|
|
233
233
|
function slot(startTime: string, endTime: string): CalendarSlotPick {
|
|
234
|
-
return {
|
|
234
|
+
return {
|
|
235
|
+
date: THURSDAY,
|
|
236
|
+
endDate: THURSDAY,
|
|
237
|
+
startTime,
|
|
238
|
+
endTime,
|
|
239
|
+
allDay: false,
|
|
240
|
+
};
|
|
235
241
|
}
|
|
236
242
|
|
|
237
243
|
const thursdaySlots: CalendarSlotPick[] = [
|
|
@@ -36,7 +36,8 @@ import { IntelligencePanel } from "./intelligence-panel.js";
|
|
|
36
36
|
* sends no reply, so the card says so where the press happens.
|
|
37
37
|
*/
|
|
38
38
|
const meta: Meta = {
|
|
39
|
-
title: "
|
|
39
|
+
title: "Playground/Proposed/Calendar/Intelligence panel calendar tab",
|
|
40
|
+
tags: ["proposed"],
|
|
40
41
|
parameters: { layout: "centered" },
|
|
41
42
|
};
|
|
42
43
|
export default meta;
|
|
@@ -20,7 +20,7 @@ const base: IntelligenceData = {
|
|
|
20
20
|
};
|
|
21
21
|
|
|
22
22
|
const meta: Meta<typeof IntelligencePanel> = {
|
|
23
|
-
title: "
|
|
23
|
+
title: "Playground/Shipped/Mail/IntelligencePanel",
|
|
24
24
|
component: IntelligencePanel,
|
|
25
25
|
parameters: { layout: "centered" },
|
|
26
26
|
};
|
|
@@ -205,7 +205,7 @@ const DESIGNED = { background: true, spacing: true };
|
|
|
205
205
|
const BARE = { background: false, spacing: false };
|
|
206
206
|
|
|
207
207
|
const meta: Meta<typeof IsolatedEmailFrame> = {
|
|
208
|
-
title: "
|
|
208
|
+
title: "Design System/Mail/IsolatedEmailFrame",
|
|
209
209
|
component: IsolatedEmailFrame,
|
|
210
210
|
parameters: { layout: "fullscreen" },
|
|
211
211
|
argTypes: {
|
|
@@ -3,7 +3,7 @@ import { labelColorOptions } from "../lib/label-color.js";
|
|
|
3
3
|
import { LabelChip } from "./label-chip.js";
|
|
4
4
|
|
|
5
5
|
const meta: Meta<typeof LabelChip> = {
|
|
6
|
-
title: "Primitives/LabelChip",
|
|
6
|
+
title: "Design System/Primitives/LabelChip",
|
|
7
7
|
component: LabelChip,
|
|
8
8
|
parameters: { layout: "padded" },
|
|
9
9
|
};
|
|
@@ -12,7 +12,7 @@ const listPaneFrame: Decorator = (Story) => (
|
|
|
12
12
|
);
|
|
13
13
|
|
|
14
14
|
const meta: Meta<typeof ListResultHeader> = {
|
|
15
|
-
title: "
|
|
15
|
+
title: "Design System/Mail/ListResultHeader",
|
|
16
16
|
component: ListResultHeader,
|
|
17
17
|
parameters: { layout: "centered" },
|
|
18
18
|
decorators: [listPaneFrame],
|
|
@@ -2,7 +2,7 @@ import type { Decorator, Meta, StoryObj } from "@storybook/react";
|
|
|
2
2
|
import { MailActionToolbar } from "./mail-action-toolbar.js";
|
|
3
3
|
|
|
4
4
|
const meta: Meta<typeof MailActionToolbar> = {
|
|
5
|
-
title: "
|
|
5
|
+
title: "Design System/Mail/MailActionToolbar",
|
|
6
6
|
component: MailActionToolbar,
|
|
7
7
|
parameters: { layout: "centered" },
|
|
8
8
|
decorators: [
|
|
@@ -126,7 +126,8 @@ function MailScreen({
|
|
|
126
126
|
}
|
|
127
127
|
|
|
128
128
|
const meta: Meta<typeof MailHeader> = {
|
|
129
|
-
title: "
|
|
129
|
+
title: "Playground/Proposed/Mail/MailHeader",
|
|
130
|
+
tags: ["proposed"],
|
|
130
131
|
component: MailHeader,
|
|
131
132
|
parameters: { layout: "centered" },
|
|
132
133
|
decorators: [phoneFrame],
|
|
@@ -179,7 +179,7 @@ const PANE: Decorator = (Story) => (
|
|
|
179
179
|
);
|
|
180
180
|
|
|
181
181
|
const meta: Meta<typeof MessageBodyView> = {
|
|
182
|
-
title: "
|
|
182
|
+
title: "Design System/Mail/MessageBodyView",
|
|
183
183
|
component: MessageBodyView,
|
|
184
184
|
parameters: { layout: "padded" },
|
|
185
185
|
argTypes: {
|
|
@@ -60,7 +60,7 @@ const sections: ThreadSection[] = [
|
|
|
60
60
|
];
|
|
61
61
|
|
|
62
62
|
const meta: Meta<typeof MessageListPane> = {
|
|
63
|
-
title: "
|
|
63
|
+
title: "Playground/Shipped/Mail/MessageListPane",
|
|
64
64
|
component: MessageListPane,
|
|
65
65
|
parameters: { layout: "centered" },
|
|
66
66
|
args: {
|
|
@@ -129,7 +129,7 @@ export function EmptyStateComparison() {
|
|
|
129
129
|
}
|
|
130
130
|
|
|
131
131
|
const meta: Meta<typeof MessageListEmpty> = {
|
|
132
|
-
title: "
|
|
132
|
+
title: "Playground/Shipped/Mail/MessageListState",
|
|
133
133
|
component: MessageListEmpty,
|
|
134
134
|
parameters: { layout: "fullscreen" },
|
|
135
135
|
excludeStories: ["EmptyStateComparison"],
|
|
@@ -184,7 +184,7 @@ const labeled = [noLabel, oneLabel, twoLabels, severalLabels, longLabelName];
|
|
|
184
184
|
const all = [read, unread, starred, suspicious, withAttachment, withCategory];
|
|
185
185
|
|
|
186
186
|
const meta: Meta = {
|
|
187
|
-
title: "
|
|
187
|
+
title: "Design System/Mail/MessageRow",
|
|
188
188
|
parameters: { layout: "padded" },
|
|
189
189
|
};
|
|
190
190
|
export default meta;
|
|
@@ -15,7 +15,7 @@ const moveSlot = (
|
|
|
15
15
|
);
|
|
16
16
|
|
|
17
17
|
const meta: Meta<typeof MobileMessageActionBar> = {
|
|
18
|
-
title: "
|
|
18
|
+
title: "Design System/Mail/MobileMessageActionBar",
|
|
19
19
|
component: MobileMessageActionBar,
|
|
20
20
|
parameters: { layout: "centered" },
|
|
21
21
|
decorators: [
|
|
@@ -310,7 +310,7 @@ function Harness({
|
|
|
310
310
|
}
|
|
311
311
|
|
|
312
312
|
const meta: Meta<typeof MobileSearchView> = {
|
|
313
|
-
title: "
|
|
313
|
+
title: "Playground/Shipped/Mail/Search/MobileSearchView",
|
|
314
314
|
component: MobileSearchView,
|
|
315
315
|
parameters: { layout: "centered" },
|
|
316
316
|
decorators: [phoneFrame],
|
|
@@ -4,7 +4,7 @@ import { FolderRow } from "./folder-row.js";
|
|
|
4
4
|
import { NewFolderAction } from "./new-folder-action.js";
|
|
5
5
|
|
|
6
6
|
const meta: Meta<typeof NewFolderAction> = {
|
|
7
|
-
title: "
|
|
7
|
+
title: "Design System/Folders/NewFolderAction",
|
|
8
8
|
component: NewFolderAction,
|
|
9
9
|
parameters: { layout: "centered" },
|
|
10
10
|
};
|
|
@@ -3,7 +3,7 @@ import { type ReactNode, useState } from "react";
|
|
|
3
3
|
import { NewFolderForm } from "./new-folder-form.js";
|
|
4
4
|
|
|
5
5
|
const meta: Meta<typeof NewFolderForm> = {
|
|
6
|
-
title: "
|
|
6
|
+
title: "Design System/Folders/NewFolderForm",
|
|
7
7
|
component: NewFolderForm,
|
|
8
8
|
parameters: { layout: "centered" },
|
|
9
9
|
};
|
|
@@ -2,7 +2,7 @@ import type { Meta, StoryObj } from "@storybook/react";
|
|
|
2
2
|
import { OutboxRow } from "./outbox-row.js";
|
|
3
3
|
|
|
4
4
|
const meta: Meta<typeof OutboxRow> = {
|
|
5
|
-
title: "Mail/OutboxRow",
|
|
5
|
+
title: "Design System/Mail/OutboxRow",
|
|
6
6
|
component: OutboxRow,
|
|
7
7
|
parameters: { layout: "padded" },
|
|
8
8
|
args: {
|
|
@@ -4,7 +4,7 @@ import { useState } from "react";
|
|
|
4
4
|
import { PopoverMenu, PopoverMenuRow } from "./popover-menu.js";
|
|
5
5
|
|
|
6
6
|
const meta: Meta<typeof PopoverMenu> = {
|
|
7
|
-
title: "
|
|
7
|
+
title: "Design System/Primitives/PopoverMenu",
|
|
8
8
|
component: PopoverMenu,
|
|
9
9
|
parameters: { layout: "centered" },
|
|
10
10
|
render: (args) => (
|
|
@@ -2,7 +2,7 @@ import type { Meta, StoryObj } from "@storybook/react";
|
|
|
2
2
|
import { ProgressBar } from "./progress-bar.js";
|
|
3
3
|
|
|
4
4
|
const meta: Meta<typeof ProgressBar> = {
|
|
5
|
-
title: "
|
|
5
|
+
title: "Design System/Primitives/ProgressBar",
|
|
6
6
|
component: ProgressBar,
|
|
7
7
|
parameters: { layout: "padded" },
|
|
8
8
|
render: (args) => (
|
|
@@ -24,7 +24,7 @@ function PhoneFrame({ children }: { children: React.ReactNode }) {
|
|
|
24
24
|
}
|
|
25
25
|
|
|
26
26
|
const meta: Meta<typeof PullToRefresh> = {
|
|
27
|
-
title: "Primitives/PullToRefresh",
|
|
27
|
+
title: "Design System/Primitives/PullToRefresh",
|
|
28
28
|
component: PullToRefresh,
|
|
29
29
|
parameters: { layout: "padded" },
|
|
30
30
|
render: (args) => (
|
|
@@ -15,7 +15,7 @@ const [unterminatedBoundary, unknownCharset, truncatedBody, shapeUnread] =
|
|
|
15
15
|
const demoIssueUrl = "https://github.com/remit-mail/reader/issues/new";
|
|
16
16
|
|
|
17
17
|
const meta: Meta<typeof QuarantineSection> = {
|
|
18
|
-
title: "Settings/Quarantine",
|
|
18
|
+
title: "Design System/Settings/Quarantine",
|
|
19
19
|
component: QuarantineSection,
|
|
20
20
|
parameters: { layout: "padded" },
|
|
21
21
|
args: { onCutBug: () => {} },
|
|
@@ -2,7 +2,7 @@ import type { Meta, StoryObj } from "@storybook/react";
|
|
|
2
2
|
import { QuotedText } from "./quoted-text.js";
|
|
3
3
|
|
|
4
4
|
const meta: Meta<typeof QuotedText> = {
|
|
5
|
-
title: "Mail/QuotedText",
|
|
5
|
+
title: "Design System/Mail/QuotedText",
|
|
6
6
|
component: QuotedText,
|
|
7
7
|
parameters: { layout: "padded" },
|
|
8
8
|
};
|
|
@@ -108,7 +108,7 @@ Groeten,
|
|
|
108
108
|
Ingrid`;
|
|
109
109
|
|
|
110
110
|
const meta: Meta<typeof ReadingPane> = {
|
|
111
|
-
title: "
|
|
111
|
+
title: "Playground/Shipped/Mail/ReadingPane",
|
|
112
112
|
component: ReadingPane,
|
|
113
113
|
parameters: { layout: "fullscreen" },
|
|
114
114
|
render: (args) => (
|
|
@@ -7,7 +7,7 @@ import { RecurrenceScopePrompt } from "./recurrence-scope-prompt.js";
|
|
|
7
7
|
* is still an intention.
|
|
8
8
|
*/
|
|
9
9
|
const meta: Meta<typeof RecurrenceScopePrompt> = {
|
|
10
|
-
title: "Calendar/Recurrence scope",
|
|
10
|
+
title: "Design System/Calendar/Recurrence scope",
|
|
11
11
|
component: RecurrenceScopePrompt,
|
|
12
12
|
parameters: { layout: "padded" },
|
|
13
13
|
};
|
|
@@ -2,7 +2,7 @@ import type { Meta, StoryObj } from "@storybook/react";
|
|
|
2
2
|
import { RefreshButton } from "./refresh-button.js";
|
|
3
3
|
|
|
4
4
|
const meta: Meta<typeof RefreshButton> = {
|
|
5
|
-
title: "Mail/RefreshButton",
|
|
5
|
+
title: "Design System/Mail/RefreshButton",
|
|
6
6
|
component: RefreshButton,
|
|
7
7
|
args: {
|
|
8
8
|
label: "Refresh inbox",
|