mirror of
https://github.com/transloadit/uppy.git
synced 2026-07-23 18:29:09 +00:00
core: Rename view to orchestrator
This commit is contained in:
parent
76a7255155
commit
7dbdd2aec7
4 changed files with 4 additions and 3 deletions
|
|
@ -53,6 +53,7 @@ Ideas that will be planned and find their way into a release at one point
|
|||
- [ ] website: Decide on tagline(s) (@kvz, @hedgerh, @arturi, @tim-kos)
|
||||
- [ ] website: Polish taglines (@arturi)
|
||||
- [ ] website: scrollbars on code samples (@arturi)
|
||||
- [x] core: Rename `view` to `orchestrator` (@kvz)
|
||||
- [x] core: Rename `progress` to `progressindicator` (@kvz)
|
||||
- [x] website: utilize browserify index exposers to rid ourselves of `../../../..` in examples (@kvz)
|
||||
- [x] core: Pluralize collections (locales, just l like plugins) (@kvz)
|
||||
|
|
|
|||
|
|
@ -21,7 +21,7 @@ export default class Core {
|
|||
this.opts = Object.assign({}, defaultOptions, opts)
|
||||
|
||||
// Dictates in what order different plugin types are ran:
|
||||
this.types = [ 'presetter', 'view', 'progressindicator', 'acquirer', 'uploader', 'presenter' ]
|
||||
this.types = [ 'presetter', 'orchestrator', 'progressindicator', 'acquirer', 'uploader', 'presenter' ]
|
||||
|
||||
this.type = 'core'
|
||||
|
||||
|
|
|
|||
|
|
@ -8,7 +8,7 @@ import Utils from '../core/Utils'
|
|||
export default class Modal extends Plugin {
|
||||
constructor (core, opts) {
|
||||
super(core, opts)
|
||||
this.type = 'view'
|
||||
this.type = 'orchestrator'
|
||||
|
||||
// set default options
|
||||
const defaultOptions = {
|
||||
|
|
|
|||
|
|
@ -25,7 +25,7 @@ const files = uppy
|
|||
1. Core class `Uppy` accepts object `options` (with general options), and exposes methods `.use` for adding plugins and `.set` for setting options.
|
||||
2. We create a new instance of `Uppy` and call `.use` on it, passing the plugins and their options.
|
||||
3. Then `run` is called to get things going.
|
||||
4. Plugins have types: `presetter`, `view`, `progressindicator`, `acquirer`, `uploader`, and `presenter` (more could be added in the future). When `use` is called, each plugin’s `run` method is added to an array of corresponding types, `methods`.
|
||||
4. Plugins have types: `presetter`, `orchestrator`, `progressindicator`, `acquirer`, `uploader`, and `presenter` (more could be added in the future). When `use` is called, each plugin’s `run` method is added to an array of corresponding types, `methods`.
|
||||
5. Ok, now the tricky part. Core’s method `run` iterates over plugin types in a waterfall manner — each `runTypes` runs its `method`s in parallel and returns an array of results (files) to the next plugin type in the waterfall. This way we first get all the of files from `DragDrop`, `Dropbox`, `Instagram` and other inputs — then parse them somehow — and then upload:
|
||||
|
||||

|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue