gpui-component/crates/ui/src
王子凌 b016d9fff4
modal: Fix close Modal by clicking overlay to support closing layer by layer. (#771)
Fix the issue that wrongly trigger `overlay` click event for the
layer-stacked `modals`.

Fix #772 

I.E. When clicking the `overlay`, only the last modal will possibly be
hide(If the last modal is not `overlayClosable`, click the overlay, all
the modals will not be hide).


![gif](https://github.com/user-attachments/assets/96ac97fc-6b6d-463d-bce9-393e6236c5df)

I had tried another solution:

![image](https://github.com/user-attachments/assets/d9882d70-c82c-4397-a5ff-65cd49dc08ab)

![image](https://github.com/user-attachments/assets/3855fb6b-4aac-4c7c-9581-3b0843ef78dc)

If this one is better than prev, I will commit it~

---------

Co-authored-by: Jason Lee <huacnlee@gmail.com>
2025-04-03 13:29:31 +08:00
..
button Use normal cursor for buttons. (#760) 2025-04-01 17:59:27 +08:00
dock dock: Fix to sync active state to panels when collapse dock. (#770) 2025-04-03 13:13:29 +08:00
highlighter text_view: Add syntax highlight to CodeBlock. (#684) 2025-03-04 21:50:50 +08:00
input list: Add secondary confirm support to list. (#769) 2025-04-02 16:45:27 +08:00
list list: Add secondary confirm support to list. (#769) 2025-04-02 16:45:27 +08:00
resizable panel: Only highlight resize handle when dragging. (#629) 2025-02-14 18:42:56 +08:00
scroll scrollbar: Update min thumb size to 24px. (#766) 2025-04-02 11:37:19 +08:00
sidebar Use normal cursor for buttons. (#760) 2025-04-01 17:59:27 +08:00
tab Use normal cursor for buttons. (#760) 2025-04-01 17:59:27 +08:00
table chore: Upgrade GPUI 3 (#587) 2025-01-27 03:58:48 +08:00
text description_list: Add to support border style to DescriptionList vertical layout. (#706) 2025-03-11 17:59:56 +08:00
time list: Add secondary confirm support to list. (#769) 2025-04-02 16:45:27 +08:00
accordion.rs Use normal cursor for buttons. (#760) 2025-04-01 17:59:27 +08:00
actions.rs list: Add secondary confirm support to list. (#769) 2025-04-02 16:45:27 +08:00
alert.rs button: Add warning, success, info variant to Button. (#745) 2025-03-27 10:15:53 +08:00
animation.rs Add exit animation to Notification. 2024-08-30 11:24:55 +08:00
badge.rs chore: Upgrade GPUI 3 (#587) 2025-01-27 03:58:48 +08:00
breadcrumb.rs chore: Upgrade GPUI 3 (#587) 2025-01-27 03:58:48 +08:00
checkbox.rs checkbox: Add children to Radio, Checkbox to display long texts. (#724) 2025-03-20 19:12:48 +08:00
clipboard.rs chore: Update GPUI 2025/03/20 and fix spawn method. (#725) 2025-03-20 21:23:50 +08:00
color_picker.rs list: Add secondary confirm support to list. (#769) 2025-04-02 16:45:27 +08:00
colors.rs tag: Add color to Tag to support more colors. (#698) 2025-03-07 21:41:04 +08:00
context_menu.rs chore: Upgrade GPUI 3 (#587) 2025-01-27 03:58:48 +08:00
description_list.rs description_list: Fix incorrect align items for horizontal layout (#730) 2025-03-24 17:15:46 +08:00
divider.rs chore: Upgrade GPUI 3 (#587) 2025-01-27 03:58:48 +08:00
drawer.rs list: Add secondary confirm support to list. (#769) 2025-04-02 16:45:27 +08:00
dropdown.rs list: Add secondary confirm support to list. (#769) 2025-04-02 16:45:27 +08:00
event.rs chore: Upgrade GPUI 3 (#587) 2025-01-27 03:58:48 +08:00
focusable.rs chore: Upgrade GPUI 3 (#587) 2025-01-27 03:58:48 +08:00
form.rs chore: Upgrade GPUI 3 (#587) 2025-01-27 03:58:48 +08:00
history.rs history: Ensure unique History in redos and undos when push. (#761) 2025-04-01 19:35:16 +08:00
icon.rs menu: Add external link icon to link menu item. (#734) 2025-03-24 22:30:29 +08:00
indicator.rs chore: Upgrade GPUI 3 (#587) 2025-01-27 03:58:48 +08:00
kbd.rs kdb: Add min width 20px to Kdb. (#700) 2025-03-10 17:12:43 +08:00
label.rs label: Fix typo (#722) 2025-03-19 14:15:49 +08:00
lib.rs list: Add secondary confirm support to list. (#769) 2025-04-02 16:45:27 +08:00
link.rs chore: Upgrade GPUI 3 (#587) 2025-01-27 03:58:48 +08:00
modal.rs modal: Fix close Modal by clicking overlay to support closing layer by layer. (#771) 2025-04-03 13:29:31 +08:00
notification.rs Use normal cursor for buttons. (#760) 2025-04-01 17:59:27 +08:00
popover.rs list: Add secondary confirm support to list. (#769) 2025-04-02 16:45:27 +08:00
popup_menu.rs list: Add secondary confirm support to list. (#769) 2025-04-02 16:45:27 +08:00
progress.rs theme: Ensure all elements to use radius. (#596) 2025-02-03 19:03:16 +08:00
radio.rs checkbox: Add children to Radio, Checkbox to display long texts. (#724) 2025-03-20 19:12:48 +08:00
root.rs modal: Fix close Modal by clicking overlay to support closing layer by layer. (#771) 2025-04-03 13:29:31 +08:00
skeleton.rs theme: Ensure all elements to use radius. (#596) 2025-02-03 19:03:16 +08:00
slider.rs chore: Upgrade for GPUI API changes. (#589) 2025-01-29 16:49:17 +08:00
styled.rs tab: Add xsmall, large style to Tab. (#680) 2025-03-04 10:26:12 +08:00
svg_img.rs svg_img: Use system fonts to support CJK characters (#750) 2025-03-27 14:44:04 +08:00
switch.rs Use normal cursor for buttons. (#760) 2025-04-01 17:59:27 +08:00
tab.rs Add TabBar 2024-06-25 19:07:05 +08:00
table.rs list: Add secondary confirm support to list. (#769) 2025-04-02 16:45:27 +08:00
tag.rs tag: Add color to Tag to support more colors. (#698) 2025-03-07 21:41:04 +08:00
theme.rs theme: Update table_head_foreground (#753) 2025-03-31 15:12:54 +08:00
title_bar.rs Use normal cursor for buttons. (#760) 2025-04-01 17:59:27 +08:00
tooltip.rs text_view: Update Switch, Checkbox, Radio to let label method support TextView. (#649) 2025-02-24 15:49:54 +08:00
virtual_list.rs chore: Upgrade GPUI 3 (#587) 2025-01-27 03:58:48 +08:00
webview.rs webview: Update visible state when hide or show (#654) 2025-02-25 11:49:29 +08:00
window_border.rs chore: Update GPUI 2025/03/31 (#752) 2025-03-31 10:31:39 +08:00