How to open a dialog from jiraIssueContents

I am new to JIRA dev, but I couldn’t find a straight answer how to trigger a dialog.

I want to open a dialog window triggered by the button in jiraIssueContents.

What I do:

"modules": {
         "jiraIssueContents": [
"target": {
					"type": "web_panel",
					"url": "/aPlugin.html"
				 "tooltip": {
				  "value": "This is a tooltip"
                 "key": "startPlugin",
				 "icon": {
					"width": 20,
					"height": 20,
					"url": "/icon.jpg"
                 "name": {
                     "value": "button name"

<html lang="en">
        <link rel="stylesheet" href="" media="all">
        <script src="" async></script>
	<script>'ISSUE_QUICK_ADD_CLICKED', function(event){
		  // display a dialog when quick add button was clicked. event = { isNewToIssue: boolean }
		  // isNewToIssue is true if this is first time content panel being added to current issue.
		  // isNewToIssue is false if content panel is already on issue view, and it is selected.
				key: 'sized-panel',
				width: '500px',
				height: '200px',
				chrome: true,
				header: JSON.stringify(event)

Solved myself. I switched to ACE and used dialogs from atlassian-connect.json

Hi Tomasz, Can I get workaround you did for this using ACE?