mirror of
https://github.com/transloadit/uppy.git
synced 2026-07-17 16:50:22 +00:00
Update Linter (#2796)
* relocate .vscode
* Switch to transloadit linter
* Update .eslintrc.json
* autofix code
* unlink and install eslint-config-transloadit@1.1.1
* Change 0 to "off"
* Don't change 'use strict'
* Do not vertically align
* disable key-spacing
* add import/no-extraneous-dependencies per package
* add more react/a11y warnings
* Revert "autofix code"
This reverts commit 14c8a8cde8.
* add import/no-extraneous-dependencies per example and main package
* autofix code (2)
* Allow devDependencies in ./bin
* Change import/no-extraneous-dependencies to warn again
* upgrade linter
* Set import/no-extraneous-dependencies to warn
This commit is contained in:
parent
6cb90c613c
commit
764c2ccada
311 changed files with 4118 additions and 2795 deletions
|
|
@ -24,15 +24,15 @@ const formUppy = robodog.form('#test-form', {
|
|||
debug: true,
|
||||
fields: ['message'],
|
||||
restrictions: {
|
||||
allowedFileTypes: ['.png']
|
||||
allowedFileTypes: ['.png'],
|
||||
},
|
||||
waitForEncoding: true,
|
||||
params: {
|
||||
auth: { key: TRANSLOADIT_KEY },
|
||||
template_id: TEMPLATE_ID
|
||||
template_id: TEMPLATE_ID,
|
||||
},
|
||||
modal: true,
|
||||
progressBar: '#test-form .progress'
|
||||
progressBar: '#test-form .progress',
|
||||
})
|
||||
|
||||
formUppy.on('error', (err) => {
|
||||
|
|
@ -51,15 +51,15 @@ const formUppyWithDashboard = robodog.form('#dashboard-form', {
|
|||
debug: true,
|
||||
fields: ['message'],
|
||||
restrictions: {
|
||||
allowedFileTypes: ['.png']
|
||||
allowedFileTypes: ['.png'],
|
||||
},
|
||||
waitForEncoding: true,
|
||||
note: 'Only PNG files please!',
|
||||
params: {
|
||||
auth: { key: TRANSLOADIT_KEY },
|
||||
template_id: TEMPLATE_ID
|
||||
template_id: TEMPLATE_ID,
|
||||
},
|
||||
dashboard: '#dashboard-form .dashboard'
|
||||
dashboard: '#dashboard-form .dashboard',
|
||||
})
|
||||
|
||||
window.formUppyWithDashboard = formUppyWithDashboard
|
||||
|
|
@ -70,8 +70,8 @@ const dashboard = robodog.dashboard('#dashboard', {
|
|||
note: 'Images will be resized with Transloadit',
|
||||
params: {
|
||||
auth: { key: TRANSLOADIT_KEY },
|
||||
template_id: TEMPLATE_ID
|
||||
}
|
||||
template_id: TEMPLATE_ID,
|
||||
},
|
||||
})
|
||||
|
||||
window.dashboard = dashboard
|
||||
|
|
@ -83,16 +83,16 @@ window.dashboard = dashboard
|
|||
function openModal () {
|
||||
robodog.pick({
|
||||
restrictions: {
|
||||
allowedFileTypes: ['.png']
|
||||
allowedFileTypes: ['.png'],
|
||||
},
|
||||
waitForEncoding: true,
|
||||
params: {
|
||||
auth: { key: TRANSLOADIT_KEY },
|
||||
template_id: TEMPLATE_ID
|
||||
template_id: TEMPLATE_ID,
|
||||
},
|
||||
providers: [
|
||||
'webcam'
|
||||
]
|
||||
'webcam',
|
||||
],
|
||||
// if providers need custom config
|
||||
// webcam: {
|
||||
// option: 'whatever'
|
||||
|
|
@ -113,8 +113,8 @@ window.doUpload = (event) => {
|
|||
waitForEncoding: true,
|
||||
params: {
|
||||
auth: { key: TRANSLOADIT_KEY },
|
||||
template_id: TEMPLATE_ID
|
||||
}
|
||||
template_id: TEMPLATE_ID,
|
||||
},
|
||||
}).then((result) => {
|
||||
resultEl.classList.remove('hidden')
|
||||
errorEl.classList.add('hidden')
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue