Skip to content

Commit

Permalink
add dowload originals setting in UI
Browse files Browse the repository at this point in the history
  • Loading branch information
toto04 committed Feb 24, 2024
1 parent d717292 commit 5ebddfd
Show file tree
Hide file tree
Showing 3 changed files with 212 additions and 198 deletions.
10 changes: 10 additions & 0 deletions src/client/views/Settings.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -196,6 +196,16 @@ export const SettingsModal: FC<{ onClose: () => void }> = props => {
/>
<span className="desc">{t("concurrentDownloads_desc")}</span>
</div>
<div className="setting">
<span>{t("downloadOriginals")}</span>
<Switch
onChange={v =>
updateSettigns({ ...settings, downloadOriginals: v })
}
checked={settings.downloadOriginals}
/>
<span className="desc">{t("downloadOriginals_desc")}</span>
</div>
</div>

<button
Expand Down
200 changes: 101 additions & 99 deletions static/locales/en/client.json
Original file line number Diff line number Diff line change
@@ -1,104 +1,106 @@
{
"mainView": {
"lastSynced": "Last synced",
"readableTime": {
"never": "Never",
"now": "Right now",
"minute_one": "One minute ago",
"minute_other": "{{count}} minutes ago",
"hour_one": "One hour ago",
"hour_other": "{{count}} hours ago",
"day_one": "Yesterday",
"day_other": "{{count}} Days ago",
"months": "Months ago +"
},
"stop": "Stop",
"sync": "Sync now",
"loginToSync": "login to sync",
"login": "Log in...",
"notConnected": "Not connected",
"updateAvailable": "Update available, click to install",
"notifications": {
"no_notifications": "Good news! No notifications ✨",
"setAllRead": "Set all as read"
}
"mainView": {
"lastSynced": "Last synced",
"readableTime": {
"never": "Never",
"now": "Right now",
"minute_one": "One minute ago",
"minute_other": "{{count}} minutes ago",
"hour_one": "One hour ago",
"hour_other": "{{count}} hours ago",
"day_one": "Yesterday",
"day_other": "{{count}} Days ago",
"months": "Months ago +"
},
"syncSettings": {
"downloadFolder": "Download folder",
"open": "Open",
"edit": "Edit",
"syncEvery": "Sync every",
"ai": {
"hour_one": "1 hour",
"hour_other": "{{count}} hours",
"day_one": "1 day",
"day_other": "{{count}} days",
"week": "1 week"
}
},
"syncProgress": {
"total": "Total",
"noConnection": "Waiting for connection...",
"noLogin": "Login to start syncing!",
"newFiles_one": "{{count}} new file downloaded",
"newFiles_other": "{{count}} new files downloaded",
"prevNewFiles_one": "{{count}} new file downloaded in background",
"prevNewFiles_other": "{{count}} new files downloaded in background",
"viewFiles": "View files",
"resultMessage": {
"success": "Everything is up to date!",
"stopped": "Sync aborted",
"networkError": "Cannot reach the server, check your connection or try again later",
"fsError": "Cannot write the file: that could be either you don't have write permission to the download folder or there's a file that need overwrite open in another program",
"unknownError": "An unknown error has occured, try again later"
},
"statusMessage": {
"idle": "Ready to download",
"fetchingCourses": "Fetching courses...",
"fetchingFiles": "Looking for new files to download...",
"downloading": "Downloading..."
}
},
"newFiles": {
"newFiles_one": "{{count}} new file downloaded",
"newFiles_other": "{{count}} new files downloaded",
"reveal": "Reveal",
"open": "Open"
"stop": "Stop",
"sync": "Sync now",
"loginToSync": "login to sync",
"login": "Log in...",
"notConnected": "Not connected",
"updateAvailable": "Update available, click to install",
"notifications": {
"no_notifications": "Good news! No notifications ✨",
"setAllRead": "Set all as read"
}
},
"syncSettings": {
"downloadFolder": "Download folder",
"open": "Open",
"edit": "Edit",
"syncEvery": "Sync every",
"ai": {
"hour_one": "1 hour",
"hour_other": "{{count}} hours",
"day_one": "1 day",
"day_other": "{{count}} days",
"week": "1 week"
}
},
"syncProgress": {
"total": "Total",
"noConnection": "Waiting for connection...",
"noLogin": "Login to start syncing!",
"newFiles_one": "{{count}} new file downloaded",
"newFiles_other": "{{count}} new files downloaded",
"prevNewFiles_one": "{{count}} new file downloaded in background",
"prevNewFiles_other": "{{count}} new files downloaded in background",
"viewFiles": "View files",
"resultMessage": {
"success": "Everything is up to date!",
"stopped": "Sync aborted",
"networkError": "Cannot reach the server, check your connection or try again later",
"fsError": "Cannot write the file: that could be either you don't have write permission to the download folder or there's a file that need overwrite open in another program",
"unknownError": "An unknown error has occured, try again later"
},
"settings": {
"settings": "Settings",
"colorTheme": "Color theme",
"theme": {
"system": "use system",
"light": "light theme",
"dark": "dark theme"
},
"language": "Language",
"automaticUpdates": "Keep the app up to date",
"automaticUpdates_desc": "WeBeep Sync will periodically check for new updates, and will install them automatically",
"openAtLogin": "Open app at login",
"keepOpenInBackground": "Keep open in background",
"keepOpenInBackground_desc": "Keep the app running in background while all windows are closed. If autosync is enabled, they will happen in background too",
"showInTray": "Show app in tray",
"trayWarning": "With the tray disabled, you wont be able to tell if the app is running. Once you close the window, you'll need to relaunch the app to open it again. If you have autosyncs enabled, those will keep going in the background.",
"notifications": "Send a notification when new files are downloaded in background",
"msgNotifications": "Send a notification when I recieve a new message in WeBeep",
"newCourses": "Sync new courses",
"newCourses_desc": "When new courses are found, automatically add them to the courses that will be synced",
"concurrentDownloads": "Concurrent downloads",
"concurrentDownloads_desc": "A higher number of concurrent downloads can increase download speeds, but could put more load on your network. A lower number is preferable for slower connections.",
"logout": "Log out",
"cancel": "Cancel",
"ok": "Ok"
"statusMessage": {
"idle": "Ready to download",
"fetchingCourses": "Fetching courses...",
"fetchingFiles": "Looking for new files to download...",
"downloading": "Downloading..."
}
},
"newFiles": {
"newFiles_one": "{{count}} new file downloaded",
"newFiles_other": "{{count}} new files downloaded",
"reveal": "Reveal",
"open": "Open"
},
"settings": {
"settings": "Settings",
"colorTheme": "Color theme",
"theme": {
"system": "use system",
"light": "light theme",
"dark": "dark theme"
},
"courseList": {
"courses": "Courses",
"courses_desc": "Select which courses you want to keep synced and rename the folders",
"row": {
"tooShort": "The name cannot be empty",
"tooLong": "Max 255 characters!",
"invalidCharacters": "These characters cannot be used: ",
"errPerm": "Cannot rename the folder, you might have a file open inside of it"
}
"language": "Language",
"automaticUpdates": "Keep the app up to date",
"automaticUpdates_desc": "WeBeep Sync will periodically check for new updates, and will install them automatically",
"openAtLogin": "Open app at login",
"keepOpenInBackground": "Keep open in background",
"keepOpenInBackground_desc": "Keep the app running in background while all windows are closed. If autosync is enabled, they will happen in background too",
"showInTray": "Show app in tray",
"trayWarning": "With the tray disabled, you wont be able to tell if the app is running. Once you close the window, you'll need to relaunch the app to open it again. If you have autosyncs enabled, those will keep going in the background.",
"notifications": "Send a notification when new files are downloaded in background",
"msgNotifications": "Send a notification when I recieve a new message in WeBeep",
"newCourses": "Sync new courses",
"newCourses_desc": "When new courses are found, automatically add them to the courses that will be synced",
"concurrentDownloads": "Concurrent downloads",
"concurrentDownloads_desc": "A higher number of concurrent downloads can increase download speeds, but could put more load on your network. A lower number is preferable for slower connections.",
"downloadOriginals": "Keep an original copy of modified files",
"downloadOriginals_desc": "If active, when you modify a file, its original version will be downloaded and overwrutten with \"_ORIGINAL\" appended to the file name.",
"logout": "Log out",
"cancel": "Cancel",
"ok": "Ok"
},
"courseList": {
"courses": "Courses",
"courses_desc": "Select which courses you want to keep synced and rename the folders",
"row": {
"tooShort": "The name cannot be empty",
"tooLong": "Max 255 characters!",
"invalidCharacters": "These characters cannot be used: ",
"errPerm": "Cannot rename the folder, you might have a file open inside of it"
}
}
}
}
Loading

0 comments on commit 5ebddfd

Please sign in to comment.