# Bug OP-11962 - Click started in modal, but dragged outside closes the modal

Project: OpenProject
Status: closed
URL: https://community.openproject.org/work_packages/OP-11962

## Open points

_No work packages_

## Details

| Attribute | Value |
| --- | --- |
| Date |  |
| Priority | Medium |
| Module |  |
| Target versions | 12.4.4 |
| Observed in versions |  |
| Sprint | 12.4.4 |
| Backlog bucket |  |
| Bug found in version (deprecated) |  |
| Found in mobile app version |  |
| Follow-up feedback e-mail |  |
| Requires doc change | No |
| Accessibility | No |
| Pull preview |  |
| List |  |
| Labels |  |

## People

| Attribute | Value |
| --- | --- |
| Assignee |  |
| Accountable |  |
| Product manager |  |
| Developers |  |
| Designer |  |
| Ordered by |  |
| Signed off by |  |
| Interest by |  |

## Planning

| Attribute | Value |
| --- | --- |
| Relevance |  |

## Costs

| Attribute | Value |
| --- | --- |
| Votes |  |
| Work |  |
| Labor costs |  |

## Description

### Steps to reproduce

_Please write down the steps to reproduce. Try to write down all necessary preconditions (what permissions do you have, are other users involved?). Example:_

1.  Create a wiki page
2.  Add and open a code block modal
3.  Click within the modal, and hold the mouse down, moving it to the modal overlay
4.  Let go of the mouse button

### What is the buggy behavior?

_Please describe the bug with as most details as possible. Example:_

*   The modal closes

### What is the expected behavior?

_Describe how the application should behave like. Example:_

1.  The modal closes only when actively clicked in the overlay

###   

Clicking and dragging happens all the time in the modal when selecting content, especially in the editor. The modal should not close on a mouseup on the overlay.
