feat(UI): improve filesize input and use it in settings (#721)

* Improve file size input component layout

* Fix filesize input value not getting set

* Allow arbitrary props on filesize input

* Update config variables to support filesize type and integrate FileSizeInput component

* Update i18n entries

* WARNING GUESSES: Update translation descriptions for max size and chunk size in multiple languages

* Fix config service not being aware of filesize type

* Fix backend config service not being aware of filesize type

* Move FileSizeInput component to core
This commit is contained in:
Aaron
2024-12-31 15:25:49 +01:00
committed by GitHub
parent b58dcdba0b
commit 53c05518df
35 changed files with 151 additions and 125 deletions

View File

@@ -25,8 +25,10 @@ const get = (key: string, configVariables: Config[]): any => {
const value = configVariable.value ?? configVariable.defaultValue;
if (configVariable.type == "number") return parseInt(value);
if (configVariable.type == "boolean") return value == "true";
if (configVariable.type == "number" || configVariable.type == "filesize")
return parseInt(value);
if (configVariable.type == "boolean")
return value == "true";
if (configVariable.type == "string" || configVariable.type == "text")
return value;
};