diff --git a/website/src/api-usage-example.ejs b/website/src/api-usage-example.ejs index 42bacaa0a..d1eb8371b 100644 --- a/website/src/api-usage-example.ejs +++ b/website/src/api-usage-example.ejs @@ -1,19 +1,11 @@ import Uppy from 'uppy/lib/core' import Dashboard from 'uppy/lib/plugins/Dashboard' -import Tus10 from 'uppy/lib/plugins/Tus10' -import MetaData from 'uppy/lib/plugins/MetaData' +import Tus from 'uppy/lib/plugins/Tus' -const uppy = Uppy({autoProceed: false}) - .use(Dashboard, {trigger: '#select-files', target: '#upload-form', replaceTargetContent: true}) - .use(Tus10, {endpoint: '://master.tus.io/files/'}) - .use(MetaData, { - fields: [ - { id: 'license', name: 'License', value: 'Creative Commons', placeholder: 'specify license' }, - { id: 'caption', name: 'Caption', value: 'none', placeholder: 'describe what the image is about' } - ] - }) -uppy.run() - -uppy.on('success', (files) => { - console.log(`Upload complete! We’ve uploaded these files: ${files}`) -}) \ No newline at end of file +Uppy({ autoProceed: false }) + .use(Dashboard, { trigger: '#select-files' }) + .use(Tus, { endpoint: 'https://master.tus.io/files/' }) + .run() + .on('complete', (result) => { + console.log('Upload result:', result) + }) \ No newline at end of file diff --git a/website/src/examples/dashboard/app.es6 b/website/src/examples/dashboard/app.es6 index 47b738b34..235d4fc06 100644 --- a/website/src/examples/dashboard/app.es6 +++ b/website/src/examples/dashboard/app.es6 @@ -36,7 +36,9 @@ function uppyInit () { trigger: '.UppyModalOpenerBtn', inline: opts.DashboardInline, target: opts.DashboardInline ? '.DashboardContainer' : 'body', + replaceTargetContent: true, note: opts.restrictions ? 'Images and video only, 2–3 files, up to 1 MB' : '', + maxHeight: 450, metaFields: [ { id: 'license', name: 'License', placeholder: 'specify license' }, { id: 'caption', name: 'Caption', placeholder: 'describe what the image is about' } diff --git a/website/src/examples/dashboard/index.ejs b/website/src/examples/dashboard/index.ejs index a7dfa98fa..bd4d01901 100644 --- a/website/src/examples/dashboard/index.ejs +++ b/website/src/examples/dashboard/index.ejs @@ -40,8 +40,10 @@ const uppy = Uppy({ .use(Dashboard, { trigger: '.UppyModalOpenerBtn', inline: true, - target: '.DashboardContainer' + target: '.DashboardContainer', + replaceTargetContent: true, note: 'Images and video only, 2–3 files, up to 1 MB', + maxHeight: 450, metaFields: [ { id: 'license', name: 'License', placeholder: 'specify license' }, { id: 'caption', name: 'Caption', placeholder: 'describe what the image is about' } diff --git a/website/src/examples/dragdrop/app.html b/website/src/examples/dragdrop/app.html index 621691c0d..936886512 100644 --- a/website/src/examples/dragdrop/app.html +++ b/website/src/examples/dragdrop/app.html @@ -1,8 +1,8 @@ -
Please see documentation for details.
+Hey there stranger! Uppy
is in the early stages of development and the example section
is our playground. Things might not yet work, but we're working hard to improve this.
|
|
|