Share dialog does not auto-close after sharing or clicking outside
Bug Description
The "Share Content" (分享内容) modal dialog does not automatically dismiss in the following scenarios:
- Clicking outside the modal (on the overlay/backdrop) — the dialog stays open.
- After performing a share action — e.g. clicking "Copy Link" (复制链接) or "System Share" (系统分享), the dialog remains open instead of closing to confirm the action succeeded.
The user is forced to manually click the close (X) button every time.
Steps to Reproduce
- Open any entry/article in Folo.
- Click the share button to open the "Share Content" (分享内容) dialog.
- Do either of the following:
- (a) Click on the backdrop / area outside the dialog, or
- (b) Click "Copy Link" (复制链接) or "System Share" (系统分享).
- Observe that the dialog stays open.
Expected Behavior
- Clicking outside the modal should close it (standard modal interaction).
- After a share action completes (especially "Copy Link"), the modal should auto-close to give clear feedback that the action succeeded.
Actual Behavior
- The modal remains open in both scenarios.
- The user must manually click the X button to dismiss it.
Screenshot
See attached screenshot — the share dialog stays open after interacting with it.
Environment
- OS: macOS
- Date observed: 2026-07-19
Suggested Fix
The share modal component likely needs:
- An
onInteractOutside / onPointerDownOutside handler that calls the close handler (if built on Radix Dialog / Popover).
- An
onShareComplete callback invoked after each share action (copy link, system share, social share) that triggers onOpenChange(false) / setOpen(false).
This would bring the share dialog in line with standard modal UX and improve perceived responsiveness of share actions.
Share dialog does not auto-close after sharing or clicking outside
Bug Description
The "Share Content" (分享内容) modal dialog does not automatically dismiss in the following scenarios:
The user is forced to manually click the close (X) button every time.
Steps to Reproduce
Expected Behavior
Actual Behavior
Screenshot
See attached screenshot — the share dialog stays open after interacting with it.
Environment
Suggested Fix
The share modal component likely needs:
onInteractOutside/onPointerDownOutsidehandler that calls the close handler (if built on Radix Dialog / Popover).onShareCompletecallback invoked after each share action (copy link, system share, social share) that triggersonOpenChange(false)/setOpen(false).This would bring the share dialog in line with standard modal UX and improve perceived responsiveness of share actions.