Преглед на файлове

add “Loading...” from providers to i18n so we can translate it

Artur Paikin преди 6 години
родител
ревизия
749cc1388b
променени са 3 файла, в които са добавени 4 реда и са изтрити 3 реда
  1. 2 1
      packages/@uppy/core/src/index.js
  2. 1 1
      packages/@uppy/provider-views/src/Loader.js
  3. 1 1
      packages/@uppy/provider-views/src/index.js

+ 2 - 1
packages/@uppy/core/src/index.js

@@ -52,7 +52,8 @@ class Uppy {
         cancel: 'Cancel',
         logOut: 'Log out',
         filter: 'Filter',
-        resetFilter: 'Reset filter'
+        resetFilter: 'Reset filter',
+        loading: 'Loading...'
       }
     }
 

+ 1 - 1
packages/@uppy/provider-views/src/Loader.js

@@ -2,6 +2,6 @@ const { h } = require('preact')
 
 module.exports = (props) => {
   return <div class="uppy-Provider-loading">
-    <span>Loading...</span>
+    <span>{props.i18n('loading')}</span>
   </div>
 }

+ 1 - 1
packages/@uppy/provider-views/src/index.js

@@ -523,7 +523,7 @@ module.exports = class ProviderView {
     if (this.plugin.getPluginState().loading) {
       return (
         <CloseWrapper onUnmount={this.clearSelection}>
-          <LoaderView />
+          <LoaderView i18n={this.plugin.uppy.i18n} />
         </CloseWrapper>
       )
     }