feat(app): unify composer attachments with pill + lightbox redesign

Images and GitHub issues/PRs now live in one draft-store list (ComposerAttachment union) with cwd persisted on the draft. Paperclip becomes a + drop-up menu; queue button removed. Each pill uses a shared AttachmentPill wrapper with a corner-X that mirrors the auto-update toast spec. Pill body opens the attachment: GitHub via openExternalUrl, images via a new fullscreen AttachmentLightbox. GitHub picker auto-closes on select.
This commit is contained in:
Mohamed Boudra
2026-04-17 11:36:08 +07:00
parent 11524dc349
commit 3838a8b969
25 changed files with 2994 additions and 735 deletions
+8 -2
View File
@@ -81,6 +81,8 @@ export interface ComboboxProps {
desktopFixedHeight?: number;
/** Content rendered above the scroll area on desktop (sticky header). */
stickyHeader?: ReactNode;
/** When true, selecting an option does not close the picker (multi-select mode). */
keepOpenOnSelect?: boolean;
anchorRef: React.RefObject<View | null>;
children?: ReactNode;
}
@@ -262,6 +264,7 @@ export function Combobox({
desktopMinWidth,
desktopFixedHeight,
stickyHeader,
keepOpenOnSelect = false,
anchorRef,
children,
}: ComboboxProps): ReactElement {
@@ -587,9 +590,11 @@ export function Combobox({
const handleSelect = useCallback(
(id: string) => {
onSelect(id);
handleClose();
if (!keepOpenOnSelect) {
handleClose();
}
},
[handleClose, onSelect],
[handleClose, keepOpenOnSelect, onSelect],
);
const handleSubmitSearch = useCallback(() => {
@@ -779,6 +784,7 @@ export function Combobox({
</>
) : (
<>
{stickyHeader}
{searchable ? searchInput : null}
{effectiveOptionsPosition === "above-search" ? (
<ScrollView