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

Activated state is kept on activable element #13044

Closed
jrmlt opened this issue Oct 4, 2017 · 2 comments
Closed

Activated state is kept on activable element #13044

jrmlt opened this issue Oct 4, 2017 · 2 comments

Comments

@jrmlt
Copy link

jrmlt commented Oct 4, 2017

Ionic version:
[X] 3.x

I'm submitting a ...
[X ] bug report

Current behavior:
The .activated class is kept on a activable element when the finger or mouse is released on an non-activable element

Expected behavior:
When releasing the finger or the mouse, whatever the position, the current activated state should be cleared

Steps to reproduce:

  • Click or touch a button at its border
  • Slide the mouse or finger outside the button
  • The activated state is kept

Related code:

pointerEnd(ev: any, pointerEventType: number) {
    if (!this.dispatchClick) return;

    runInDev(() => this.lastTouchEnd = Date.now());

    if (!this.startCoord) {
      return;
    }
    if (this.activator && ev.target !== this.plt.doc()) {
      let activatableEle = getActivatableTarget(ev.target);
      if (activatableEle) { <============================= HERE
        this.activator.upAction(ev, activatableEle, this.startCoord);
      }
    }
    if (this.usePolyfill && pointerEventType === POINTER_EVENT_TYPE_TOUCH && this.app.isEnabled()) {
      this.handleTapPolyfill(ev);
    }
    this.startCoord = null;
  }

Ionic info:

cli packages: 

    @ionic/cli-utils  : 1.12.0
    ionic (Ionic CLI) : 3.12.0

local packages:

    @ionic/app-scripts : 2.1.3
    Ionic Framework    : ionic-angular 3.6.0

System:

    Node : v6.11.0
    npm  : 5.2.0
    OS   : Windows 10

Misc:

    backend : legacy
@kensodemann
Copy link
Member

Hello! Thank you for opening an issue with us!

We will look into this.

Thank you for using Ionic

@ionitron-bot
Copy link

ionitron-bot bot commented Sep 1, 2018

Thanks for the issue! This issue is being locked to prevent comments that are not relevant to the original issue. If this is still an issue with the latest version of Ionic, please create a new issue and ensure the template is fully filled out.

@ionitron-bot ionitron-bot bot locked and limited conversation to collaborators Sep 1, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants