-
-
Notifications
You must be signed in to change notification settings - Fork 118
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
Deprecate FileUpload
component and FileDropzone
attribute args
#706
Conversation
@@ -129,6 +141,77 @@ export default class FileDropzoneComponent extends Component<FileDropzoneArgs> { | |||
window.document && | |||
'draggable' in document.createElement('span'))(); | |||
|
|||
constructor(owner: unknown, args: FileDropzoneArgs) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is checking args in the constructor the best way to do this?
deprecate( | ||
`\`<FileUpload>\` is deprecated. Use \`{{file-queue}}\` helper with \`{{queue.selectFile}}\` modifier.`, | ||
false, | ||
{ | ||
for: 'ember-file-upload', | ||
id: 'file-upload', | ||
since: { enabled: 'v5.0.0' }, | ||
until: 'v6.0.0', | ||
} | ||
); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There's a lot of deprecated arguments also – but I figured a single deprecation warning with a (soon to be added) link to good upgrade docs is the best way forward here.
/** | ||
* Whether to add multiple files to the queue at once. | ||
* | ||
* If set to false only one file will be added when dropping mulitple files. | ||
* | ||
* @defaultValue true | ||
*/ | ||
multiple?: boolean; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Decided not to deprecate as I can't think of an easy way to suggest a user implementation of the same feature.
<FIleUpload>
component and <FileDropzone>
args
<FIleUpload>
component and <FileDropzone>
args<FileUpload>
component and <FileDropzone>
args
acfb333
to
26fc2e3
Compare
Deploying with Cloudflare Pages
|
<FileUpload>
component and <FileDropzone>
argsFileUpload
component and FileDropzone
attribute args
Register all v5 deprecations until v6. This includes the entire
FileUpload
component.