Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Clicking a entry in a dropdown, also triggers a click in the backdrop #1224

Closed
2 tasks done
Stefei opened this issue Apr 17, 2024 · 2 comments
Closed
2 tasks done

Clicking a entry in a dropdown, also triggers a click in the backdrop #1224

Stefei opened this issue Apr 17, 2024 · 2 comments
Labels
type: bug Something isn't working type: duplicate This issue or pull request already exists

Comments

@Stefei
Copy link

Stefei commented Apr 17, 2024

Prerequisites

  • I have read the Contributing Guidelines.
  • I have not leaked any internal/restricted information like screenshots, videos, code snippets, links etc.

What happened?

Clicking a entry in a dropdown, will also trigger a click in the backdrop. This is a problem for us, because we use a modal that closes if the user clicks outside of the modal bounds.

What type of frontend framework are you seeing the problem on?

Angular, JavaScript

Which version of iX do you use?

v2.1.0

Code to produce this issue.

import { Component } from '@angular/core';

@Component({
  selector: 'app-example',
  template: `
    <div style="background-color:#ffffff; height: 1000px" onclick="console.log('backdrop clicked')">
    <ix-button #trigger>Open</ix-button>
    <ix-dropdown [ixDropdownTrigger]="trigger">
      <ix-dropdown-header label="Category"></ix-dropdown-header>
      <ix-dropdown-item label="Item 2"></ix-dropdown-item>
      <ix-dropdown-item label="Item 3"></ix-dropdown-item>
      <ix-dropdown-item label="Item 4"></ix-dropdown-item>
      <ix-divider></ix-divider>
      <ix-dropdown-item label="Item 5"></ix-dropdown-item>
    </ix-dropdown>
    </div>
  `,
})
export default class Dropdown {
}
@Stefei Stefei added the triage We discuss this topic in our internal weekly label Apr 17, 2024
@danielleroux
Copy link
Collaborator

@matthiashader matthiashader added type: bug Something isn't working type: duplicate This issue or pull request already exists and removed triage We discuss this topic in our internal weekly labels May 8, 2024
@matthiashader
Copy link
Collaborator

As this is a duplicate of #1229, this issue will be closed and further be discussed there.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type: bug Something isn't working type: duplicate This issue or pull request already exists
Projects
None yet
Development

No branches or pull requests

3 participants