GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — dragEnd event not sent when single-clicking gutter · Issue #283 · angular-split/angular-split

dragEnd event not sent when single-clicking gutter #283

New issue
Copy link
New issue
Copy link
Closed
#284
Closed
dragEnd event not sent when single-clicking gutter#283
#284
Copy link
Labels
bughelp wanted

Description

@pweissenbacher
pweissenbacher
opened on Dec 7, 2020
Issue body actions

Describe the bug
Package version: 4.0.0
When dragging the gutter, the events "dragStart/dragEnd" are working fine.
But when soley clicking the gutter, the dragStart event is fired, but the dragEnd event is not.

To Reproduce
Look at the small Stackblitz example (dragging not updating, but events fired as described)
StackBlitz Dev Mode
StackBlitz App Mode

Activity

  1. pweissenbacher
    added
    bug
    on Dec 7, 2020
  2. beeman
    added
    help wanted
    on Dec 7, 2020
  3. nomeaning777 commented on Dec 8, 2020

    @nomeaning777
    nomeaning777
    on Dec 8, 2020
    Contributor
    More actions

    In the current implementation, the component fires dragStart when a mouse button is pressed.
    However, it fires dragEnd only when the mouse cursor is moved and the button is released.
    If mouse cursor is not moved, it emits gutterClick/gutterDblClick.
    https://github.com/angular-split/angular-split/blob/main/projects/angular-split/src/lib/component/split.component.ts#L709

    I think it is better to fire dragStart event only when a mouse button is pressed and the cursor is moved.
    I will be happy to create a PR if this breaking change is acceptable.

  4. beeman commented on Dec 8, 2020

    @beeman
    beeman
    on Dec 8, 2020
    Contributor
    More actions

    @nomeaning777 I'm definitely interested in a PR that adds support for this (or maybe, fixes the bug that dragStart gets emitted when nothing gets dragged).

    It would be awesome if it could be implemented with minimal amount of code changes, and add some cypress tests that prove the behavior.

    I think we can publish that in a major version, maybe it can go into v5.

  5. nomeaning777
    added 3 commits that reference this issue on Dec 9, 2020

    fix: fire dragStart event only when a cursor is moved (angular-split#283

    9dc0184

    fix: fire dragStart event only when a cursor is moved (angular-split#283

    9f33c5e

    fix: fire dragStart event only when a cursor is moved (angular-split#283

    ec5a968
  6. beeman
    closed this as completedin #284on Dec 18, 2020
  7. beeman
    added a commit that references this issue on Dec 18, 2020

    fix: fire dragStart event only when a cursor is moved (#283)

    00a6755
  8. beeman commented on Dec 18, 2020

    @beeman
    beeman
    on Dec 18, 2020
    Contributor
    More actions

    This fix is released in version 5.0.0 thanks to @nomeaning777 🎉

    https://stackblitz.com/edit/angular-ivy-xhc5bj?file=src/app/app.component.html

  9. angular-split
    locked and limited conversation to collaborators on Feb 18, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    bughelp wanted

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions

      You are visitor 01402503 — GeezerVison does not store the pages you look up.
      Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.