mirror of
https://github.com/transloadit/uppy.git
synced 2026-07-18 00:55:35 +00:00
meta: remove CJS-related hack in build:locale-pack script (#3764)
This commit is contained in:
parent
5a8a8d35be
commit
f10745ec27
22 changed files with 1 additions and 71 deletions
|
|
@ -93,18 +93,11 @@ async function generateLocaleDocs (pluginName) {
|
|||
// Replace all nodes after the locale heading until the next heading (or eof)
|
||||
headingRange(tree, rangeOptions, (start, _, end) => [
|
||||
start,
|
||||
{
|
||||
type: 'html',
|
||||
// `module.exports` is not allowed by eslint in our docs.
|
||||
// The script outputs an extra newline which also isn't excepted by eslint
|
||||
// TODO: remove the no-restricted-globals when switch to ESM is completed.
|
||||
value: '<!-- eslint-disable no-restricted-globals, no-multiple-empty-lines -->',
|
||||
},
|
||||
{
|
||||
type: 'code',
|
||||
lang: 'js',
|
||||
meta: null,
|
||||
value: fs.readFileSync(localePath, 'utf-8'),
|
||||
value: fs.readFileSync(localePath, 'utf-8').trimEnd(),
|
||||
},
|
||||
end,
|
||||
])
|
||||
|
|
|
|||
|
|
@ -65,8 +65,6 @@ Configures whether to show a dropdown which enables to choose the audio device t
|
|||
|
||||
### `locale: {}`
|
||||
|
||||
<!-- eslint-disable no-restricted-globals, no-multiple-empty-lines -->
|
||||
|
||||
```js
|
||||
export default {
|
||||
strings: {
|
||||
|
|
@ -98,5 +96,4 @@ export default {
|
|||
discardRecordedFile: 'Discard recorded file',
|
||||
},
|
||||
}
|
||||
|
||||
```
|
||||
|
|
|
|||
|
|
@ -115,15 +115,12 @@ This option is useful when uploading to an S3-like service that doesn’t reply
|
|||
|
||||
### `locale: {}`
|
||||
|
||||
<!-- eslint-disable no-restricted-globals, no-multiple-empty-lines -->
|
||||
|
||||
```js
|
||||
export default {
|
||||
strings: {
|
||||
timedOut: 'Upload stalled for %{seconds} seconds, aborting.',
|
||||
},
|
||||
}
|
||||
|
||||
```
|
||||
|
||||
## S3 Bucket configuration
|
||||
|
|
|
|||
|
|
@ -127,13 +127,10 @@ This option correlates to the [RequestCredentials value](https://developer.mozil
|
|||
|
||||
### `locale: {}`
|
||||
|
||||
<!-- eslint-disable no-restricted-globals, no-multiple-empty-lines -->
|
||||
|
||||
```js
|
||||
export default {
|
||||
strings: {
|
||||
pluginNameBox: 'Box',
|
||||
},
|
||||
}
|
||||
|
||||
```
|
||||
|
|
|
|||
|
|
@ -277,8 +277,6 @@ const uppy = new Uppy({
|
|||
|
||||
### `locale: {}`
|
||||
|
||||
<!-- eslint-disable no-restricted-globals, no-multiple-empty-lines -->
|
||||
|
||||
```js
|
||||
export default {
|
||||
strings: {
|
||||
|
|
@ -338,7 +336,6 @@ export default {
|
|||
},
|
||||
},
|
||||
}
|
||||
|
||||
```
|
||||
|
||||
### `store: defaultStore()`
|
||||
|
|
|
|||
|
|
@ -334,8 +334,6 @@ Dashboard ships with the `ThumbnailGenerator` plugin that adds small resized ima
|
|||
|
||||
### `locale: {}`
|
||||
|
||||
<!-- eslint-disable no-restricted-globals, no-multiple-empty-lines -->
|
||||
|
||||
```js
|
||||
export default {
|
||||
strings: {
|
||||
|
|
@ -425,7 +423,6 @@ export default {
|
|||
},
|
||||
},
|
||||
}
|
||||
|
||||
```
|
||||
|
||||
### `theme: 'light'`
|
||||
|
|
|
|||
|
|
@ -86,8 +86,6 @@ Optionally, specify a string of text that explains something about the upload fo
|
|||
|
||||
### `locale: {}`
|
||||
|
||||
<!-- eslint-disable no-restricted-globals, no-multiple-empty-lines -->
|
||||
|
||||
```js
|
||||
export default {
|
||||
strings: {
|
||||
|
|
@ -98,7 +96,6 @@ export default {
|
|||
browse: 'browse',
|
||||
},
|
||||
}
|
||||
|
||||
```
|
||||
|
||||
### `onDragOver(event)`
|
||||
|
|
|
|||
|
|
@ -127,13 +127,10 @@ This option correlates to the [RequestCredentials value](https://developer.mozil
|
|||
|
||||
### `locale: {}`
|
||||
|
||||
<!-- eslint-disable no-restricted-globals, no-multiple-empty-lines -->
|
||||
|
||||
```js
|
||||
export default {
|
||||
strings: {
|
||||
pluginNameDropbox: 'Dropbox',
|
||||
},
|
||||
}
|
||||
|
||||
```
|
||||
|
|
|
|||
|
|
@ -86,13 +86,10 @@ This option correlates to the [RequestCredentials value](https://developer.mozil
|
|||
|
||||
### `locale: {}`
|
||||
|
||||
<!-- eslint-disable no-restricted-globals, no-multiple-empty-lines -->
|
||||
|
||||
```js
|
||||
export default {
|
||||
strings: {
|
||||
pluginNameFacebook: 'Facebook',
|
||||
},
|
||||
}
|
||||
|
||||
```
|
||||
|
|
|
|||
|
|
@ -84,8 +84,6 @@ The `name` attribute for the `<input type="file">` element.
|
|||
|
||||
### `locale: {}`
|
||||
|
||||
<!-- eslint-disable no-restricted-globals, no-multiple-empty-lines -->
|
||||
|
||||
```js
|
||||
export default {
|
||||
strings: {
|
||||
|
|
@ -95,7 +93,6 @@ export default {
|
|||
chooseFiles: 'Choose files',
|
||||
},
|
||||
}
|
||||
|
||||
```
|
||||
|
||||
## Custom file input
|
||||
|
|
|
|||
|
|
@ -122,13 +122,10 @@ This option correlates to the [RequestCredentials value](https://developer.mozil
|
|||
|
||||
### `locale: {}`
|
||||
|
||||
<!-- eslint-disable no-restricted-globals, no-multiple-empty-lines -->
|
||||
|
||||
```js
|
||||
export default {
|
||||
strings: {
|
||||
pluginNameGoogleDrive: 'Google Drive',
|
||||
},
|
||||
}
|
||||
|
||||
```
|
||||
|
|
|
|||
|
|
@ -123,8 +123,6 @@ uppy.on('file-editor:complete', (updatedFile) => {
|
|||
|
||||
### `locale: {}`
|
||||
|
||||
<!-- eslint-disable no-restricted-globals, no-multiple-empty-lines -->
|
||||
|
||||
```js
|
||||
export default {
|
||||
strings: {
|
||||
|
|
@ -138,5 +136,4 @@ export default {
|
|||
aspectRatioPortrait: 'Crop portrait (9:16)',
|
||||
},
|
||||
}
|
||||
|
||||
```
|
||||
|
|
|
|||
|
|
@ -92,13 +92,10 @@ This option correlates to the [RequestCredentials value](https://developer.mozil
|
|||
|
||||
### `locale: {}`
|
||||
|
||||
<!-- eslint-disable no-restricted-globals, no-multiple-empty-lines -->
|
||||
|
||||
```js
|
||||
export default {
|
||||
strings: {
|
||||
pluginNameInstagram: 'Instagram',
|
||||
},
|
||||
}
|
||||
|
||||
```
|
||||
|
|
|
|||
|
|
@ -86,13 +86,10 @@ This option correlates to the [RequestCredentials value](https://developer.mozil
|
|||
|
||||
### `locale: {}`
|
||||
|
||||
<!-- eslint-disable no-restricted-globals, no-multiple-empty-lines -->
|
||||
|
||||
```js
|
||||
export default {
|
||||
strings: {
|
||||
pluginNameOneDrive: 'OneDrive',
|
||||
},
|
||||
}
|
||||
|
||||
```
|
||||
|
|
|
|||
|
|
@ -102,8 +102,6 @@ If no preferred video mime type is given, the ScreenCapture plugin will prefer t
|
|||
|
||||
### `locale: {}`
|
||||
|
||||
<!-- eslint-disable no-restricted-globals, no-multiple-empty-lines -->
|
||||
|
||||
```js
|
||||
export default {
|
||||
strings: {
|
||||
|
|
@ -116,5 +114,4 @@ export default {
|
|||
recording: 'Recording',
|
||||
},
|
||||
}
|
||||
|
||||
```
|
||||
|
|
|
|||
|
|
@ -120,8 +120,6 @@ const doneButtonHandler = () => {
|
|||
|
||||
### `locale: {}`
|
||||
|
||||
<!-- eslint-disable no-restricted-globals, no-multiple-empty-lines -->
|
||||
|
||||
```js
|
||||
export default {
|
||||
strings: {
|
||||
|
|
@ -172,7 +170,6 @@ export default {
|
|||
showErrorDetails: 'Show error details',
|
||||
},
|
||||
}
|
||||
|
||||
```
|
||||
|
||||
[`@uppy/file-input`]: /docs/file-input
|
||||
|
|
|
|||
|
|
@ -60,15 +60,12 @@ A unique identifier for this plugin. It defaults to `'ThumbnailGenerator'`.
|
|||
|
||||
### `locale: {}`
|
||||
|
||||
<!-- eslint-disable no-restricted-globals, no-multiple-empty-lines -->
|
||||
|
||||
```js
|
||||
export default {
|
||||
strings: {
|
||||
generatingThumbnails: 'Generating thumbnails...',
|
||||
},
|
||||
}
|
||||
|
||||
```
|
||||
|
||||
### `thumbnailWidth: 200`
|
||||
|
|
|
|||
|
|
@ -302,8 +302,6 @@ Limit the amount of uploads going on at the same time. Setting this to `0` means
|
|||
|
||||
### `locale: {}`
|
||||
|
||||
<!-- eslint-disable no-restricted-globals, no-multiple-empty-lines -->
|
||||
|
||||
```js
|
||||
export default {
|
||||
strings: {
|
||||
|
|
@ -316,7 +314,6 @@ export default {
|
|||
encoding: 'Encoding...',
|
||||
},
|
||||
}
|
||||
|
||||
```
|
||||
|
||||
## Errors
|
||||
|
|
|
|||
|
|
@ -84,8 +84,6 @@ This option correlates to the [RequestCredentials value](https://developer.mozil
|
|||
|
||||
### `locale: {}`
|
||||
|
||||
<!-- eslint-disable no-restricted-globals, no-multiple-empty-lines -->
|
||||
|
||||
```js
|
||||
export default {
|
||||
strings: {
|
||||
|
|
@ -99,7 +97,6 @@ export default {
|
|||
enterCorrectUrl: 'Incorrect URL: Please make sure you are entering a direct link to a file',
|
||||
},
|
||||
}
|
||||
|
||||
```
|
||||
|
||||
## Methods
|
||||
|
|
|
|||
|
|
@ -158,8 +158,6 @@ If no preferred image mime type is given, the Webcam plugin will prefer types li
|
|||
|
||||
### `locale: {}`
|
||||
|
||||
<!-- eslint-disable no-restricted-globals, no-multiple-empty-lines -->
|
||||
|
||||
```js
|
||||
export default {
|
||||
strings: {
|
||||
|
|
@ -189,5 +187,4 @@ export default {
|
|||
allowAccessDescription: 'In order to take pictures or record video with your camera, please allow camera access for this site.',
|
||||
},
|
||||
}
|
||||
|
||||
```
|
||||
|
|
|
|||
|
|
@ -231,8 +231,6 @@ Indicates whether cross-site Access-Control requests should be made using creden
|
|||
|
||||
### `locale: {}`
|
||||
|
||||
<!-- eslint-disable no-restricted-globals, no-multiple-empty-lines -->
|
||||
|
||||
```js
|
||||
export default {
|
||||
strings: {
|
||||
|
|
@ -240,7 +238,6 @@ export default {
|
|||
timedOut: 'Upload stalled for %{seconds} seconds, aborting.',
|
||||
},
|
||||
}
|
||||
|
||||
```
|
||||
|
||||
## POST Parameters / Form Fields
|
||||
|
|
|
|||
|
|
@ -90,15 +90,12 @@ This option correlates to the [RequestCredentials value](https://developer.mozil
|
|||
|
||||
### `locale: {}`
|
||||
|
||||
<!-- eslint-disable no-restricted-globals, no-multiple-empty-lines -->
|
||||
|
||||
```js
|
||||
export default {
|
||||
strings: {
|
||||
pluginNameZoom: 'Zoom',
|
||||
},
|
||||
}
|
||||
|
||||
```
|
||||
|
||||
## Zoom Marketplace
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue