Comments (6)
Yes, it seems that you are actually overriding the hooks instead of adding event listeners. Maybe adding properties like onaddedfile
etc for adding event listeners to dropzone events would work. I think this problem is compounded by the fact that access to the Dropzone instance is impossible by actions unless you extend the component.
from ember-cli-dropzonejs.
I am having trouble understanding the issue. How would I go to recreate this problem?
Also, @kkamkou try assigning a function property instead of an action to the complete attribute
.
from ember-cli-dropzonejs.
try assigning a function property instead of an action
It doesn't matter. In the variant you propose me, I lose the context of the callback. And it won't fix the problem.
Yes, it seems that you are actually overriding the hooks instead of adding event listeners.
true
I am having trouble understanding the issue.
I see it from the code. All you need to do (in case you want to fix it) is to register events like events and not like an attribute. forEach() if (this.complete is function) {dropzone.on('complete', this.complete)}
from ember-cli-dropzonejs.
@kkamkou oohh yes I see. Thanks for pointing this out. Will definitely fix this.
from ember-cli-dropzonejs.
Fixed the event handling logic 7eb7b33.
Declare the event function in controller for example:
addedFileEvent: Ember.computed(function() {
return function() {
// do something...
};
}),
Declare component
{{drop-zone url=http://example.com addfile=addedFileEvent}}
You can update to version 0.7.0
to have this fix
from ember-cli-dropzonejs.
It works, thank you.
from ember-cli-dropzonejs.
Related Issues (20)
- No way to set timeout configuration option HOT 1
- Content Security Policy
- Usage in yarn workspaces
- Chunking
- Remove dropzone from bower dependencies HOT 6
- What's the best way of changing the URL before the upload starts HOT 5
- how do I use multiple drop-zone instances? HOT 2
- When extending the drop-zone component, "this" is not the component HOT 2
- Q: autoProcessQueue=false, how to start processing HOT 3
- Dynamic Options Hash HOT 2
- Use new fastboot guard HOT 4
- override init method error HOT 2
- Fix breaking changes in FastBoot 1.0 HOT 1
- Cannot find module 'broccoli-stew' HOT 7
- Option `includeDropzoneCss` is not implemented HOT 2
- includeDropzoneCss:false is not working HOT 2
- Missing `renameFile` function HOT 4
- Uncaught Error: No URL provided. HOT 7
- Fails to build with Dropzone 5.5.0 HOT 1
- How to trigger reset event ? HOT 2
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 ember-cli-dropzonejs.