uppy/packages/@uppy/url/src
Artur Paikin 4e54483e61 core: setOptions for Core and plugins (#1728)
* Add a method to update options in Core

* Add a method to update options in Plugin (for any plugins)

* Allow re-initializing i18n locales after they’ve been updated with .setOptions

* use rest spread instead of Object.assign

* override setOptions in plugins to include i18nInit

* merge restrictions object in setOptions

* check that newOpts exists

* add spread ...

* don’t double merge

* add i18nInit to all plugins that use translation strings

* add setOptions tests to Core and Dashboard

* add setOptions docs for Core and Plugins

* fix tests for thumbnail-generator by adding plugins: {} to mock core

cause ThumbnailGenerator now calls this.setPluginState, which expects `core.state.plugins`

* also update meta with setOptions if it’s passed, change the way this.opts is set in core

@goto-bus-stop does this look ok? merging restrictions opts in core

* if locale was passed to setOptions(), call plugin.setOptions() on all plugins, so that i18n updates

* add Dashboard test that checks if locale is updated from Core via setOptions()

* Reafactor website Dashboard example to use setOptions and allow selecting a locale

🎉
2019-11-04 10:33:30 +01:00
..
utils Update eslint to v6 (#1777) 2019-08-13 21:45:30 +03:00
index.js core: setOptions for Core and plugins (#1728) 2019-11-04 10:33:30 +01:00
style.scss Tweak the Import button spacing 2019-04-10 14:57:18 +03:00
UrlUI.js Upgrade standard to v14 (#1860) 2019-10-09 14:53:02 +02:00