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

Possibility of (fileSelected) event on ngxDragAndDrop #87

Open
mrklika opened this issue Oct 28, 2020 · 1 comment
Open

Possibility of (fileSelected) event on ngxDragAndDrop #87

mrklika opened this issue Oct 28, 2020 · 1 comment

Comments

@mrklika
Copy link

mrklika commented Oct 28, 2020

Hi, is there any possibility of adding some helper outputs like fileSelected on ngxDragAndDrop?

Assume that I have one form with 2 instances of fileSelect:

       <div
        class="my-drop-zone"
        ngxDragAndDrop
        *ngxInputFile>
        <span class="__drop-text">Click to select...</span>
      </div>
       <div
        class="my-drop-zone"
        ngxDragAndDrop
        *ngxInputFile>
        <span class="__drop-text">Click to select...</span>
      </div>

and I want to store my files in the file queue by keys like:

coverImage: [ FILE ]

gallery: [ FILE, FILE, FILE ]

only available available this._uploader.onAddToQueue$ listens to queue without the option to focus on a single file drop or select.

Would be great to have something like:

       <div
        class="my-drop-zone"
        ngxDragAndDrop
        *ngxInputFile
       (fileSelected)="addToQueue({ key: 'coverImage', file: $event })">
        <span class="__drop-text">Click to select...</span>
      </div>
@wKoza
Copy link
Owner

wKoza commented Nov 15, 2020

Hi @mrklika,
Seems interesting. I'll try to do that the next week.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants