Esri / calcite-design-system

A monorepo containing the packages for Esri's Calcite Design System
https://developers.arcgis.com/calcite-design-system/
Other
282 stars 77 forks source link

[Dialog] Add `escapeDisabled` prop #10080

Closed ellenupp closed 1 month ago

ellenupp commented 1 month ago

Check existing issues

Description

Add prop to disable closing dialog on escape key. Modal, which we need to replace, had this.

We have a lot of complicated workflows (element configuration) in modals and don't want people to accidentally close out of it. Especially when the escape key can be used for other purposes in the modal like closing dropdowns.

Acceptance Criteria

When escapeDisabled is present, disables the closing of the component on escape key.

Relevant Info

No response

Which Component

calcite-dialog

Example Use Case

No response

Priority impact

impact - p2 - want for an upcoming milestone

Calcite package

Esri team

ArcGIS Dashboards

github-actions[bot] commented 1 month ago

Installed and assigned for verification.

DitwanP commented 1 month ago

Moving back to in dev to resolve an issue where the panel is still closing the dialog even with the escapeDisabled prop present.

github-actions[bot] commented 1 month ago

Installed and assigned for verification.

DitwanP commented 1 month ago

🍡 Verified on 2.12.0-next.24 https://codepen.io/Ditwan-Price/pen/eYwybyr