chore: update dependencies, change compression, remove unneeded about string

This commit is contained in:
David Ralph
2022-11-25 16:32:28 +00:00
committed by GitHub
parent 822a8ff627
commit 84b99f815a
5 changed files with 26 additions and 22 deletions

View File

@@ -32,8 +32,10 @@ export default class FileUpload extends PureComponent {
return this.props.loadFunction(file);
}
// todo: change number
compressAccurately(file, 300).then(async (res) => {
compressAccurately(file, {
size: 450,
accuracy: 0.9
}).then(async (res) => {
if (settingsSize + res.size > 4850000) {
return toast(variables.getMessage('toasts.no_storage'));
}

View File

@@ -230,7 +230,7 @@ export default class About extends PureComponent {
</a>
<Tooltip title={'GitHub Sponsors'}>
<a
href={'https://github.com/sponsors/' + variables.constants.SPONSORS_USERNAME}
href={'https://github.com/sponsors/' + variables.constants.ORG_NAME}
target="_blank"
rel="noopener noreferrer"
>

View File

@@ -162,7 +162,10 @@ export default class CustomSettings extends PureComponent {
return this.customBackground(file, false, this.state.currentBackgroundIndex);
}
compressAccurately(file, 300).then(async (res) => {
compressAccurately(file, {
size: 450,
accuracy: 0.9
}).then(async (res) => {
if (settingsSize + res.size > 4850000) {
return toast(variables.getMessage('toasts.no_storage'));
}