Comments (7)
Hi @mpflanzer,
I understand this use case and will think about a possible solution. 👍🏼
from ngx-dropzone.
Hi @mpflanzer
I added a new mode
property and released it with v17.1.0. Please test it out and see if this works for you.
from ngx-dropzone.
Hi @marcelimati,
thanks for your feature request. The current behavior is actually intended because the form/input state management should be handled by the library consumer. From the library perspective, I don't know how you store the selected files.
What exactly would be your use case for this?
from ngx-dropzone.
Actually nevermind, because I could just add to array file elements whenever input changes, for example I would add 2 files, two times. Then I would have total 4 files in my array, even though in this library array there are only 2. Then if I want to remove some files i would just splice my array, so don't need to make that change in the library.
Cheers.
from ngx-dropzone.
Yeah, that's exactly what I thought you would do. 👍🏼
from ngx-dropzone.
I have the same use case that I would like the behavior to be to add files instead of overwriting the previous ones. In my case the dropzone is part of a bigger form-group that is eventually going to be submitted.
The solution above works but it means I need to create an extra form control for the dropzone and copy file entries to the form control of the form group. More convenient would be to just use the form control that is already in the group and have an option to tell the dropzone to append to the form control it's using instead of just setting the value.
from ngx-dropzone.
Took me a bit longer, but it's working as expected for me. Thanks!
from ngx-dropzone.
Related Issues (9)
- Cannot find module 'cdk' or its corresponding type HOT 1
- Dependency on RXJS 6.6 for Angular 16 HOT 1
- Suggestion: icon parameter, default preview style HOT 4
- Suggestion: support directories on drag and drop HOT 10
- Update to Angular 17 HOT 2
- [ERROR The ngx-dropzone component requires a child of <input type="file" fileInput />. HOT 5
- Any way to make its markup work on Angular 15? HOT 3
- Suggestion: support a directory selection in Open File dialog HOT 4
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from ngx-dropzone.