Skip to content

Commit

Permalink
Move to hosted weblate and app translation info in app
Browse files Browse the repository at this point in the history
  • Loading branch information
Lambada10 committed Nov 1, 2024
1 parent 09a2f12 commit 969229a
Show file tree
Hide file tree
Showing 4 changed files with 40 additions and 1 deletion.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ A simple Android app to download lyrics (.lrc files) for songs in your music lib
You can download the latest version of the app from the [releases page](https://github.com/Lambada10/SongSync/releases).

### Translation
If you would like to help translating this app, you can do so [here](https://translate.nift4.org/engage/songsync/).
If you would like to help translating this app, you can do so [here](https://hosted.weblate.org/engage/songsync/).

### License
This project is licensed under the GNU General Public License v3.0 - see the [LICENSE](https://github.com/Lambada10/SongSync/blob/master/LICENSE) file for details.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@ import pl.lambada.songsync.ui.screens.settings.components.SdCardPathSetting
import pl.lambada.songsync.ui.screens.settings.components.ShowPathSwitch
import pl.lambada.songsync.ui.screens.settings.components.SupportSection
import pl.lambada.songsync.ui.screens.settings.components.SyncedLyricsSwitch
import pl.lambada.songsync.ui.screens.settings.components.TranslationSection
import pl.lambada.songsync.ui.screens.settings.components.TranslationSwitch
import pl.lambada.songsync.ui.screens.settings.components.UpdateAvailableDialog
import pl.lambada.songsync.util.ext.getVersion
Expand Down Expand Up @@ -145,6 +146,8 @@ fun SettingsScreen(

item { SupportSection(uriHandler = uriHandler) }

item { TranslationSection(uriHandler = uriHandler) }

item { ContributorsSection(uriHandler = uriHandler) }

item { CreditsSection(uriHandler = uriHandler) }
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
package pl.lambada.songsync.ui.screens.settings.components

import androidx.compose.foundation.clickable
import androidx.compose.foundation.layout.Column
import androidx.compose.foundation.layout.padding
import androidx.compose.material3.MaterialTheme
import androidx.compose.material3.Text
import androidx.compose.runtime.Composable
import androidx.compose.ui.Modifier
import androidx.compose.ui.platform.UriHandler
import androidx.compose.ui.res.stringResource
import androidx.compose.ui.unit.dp
import androidx.compose.ui.unit.sp
import pl.lambada.songsync.ui.components.SettingsItem
import pl.lambada.songsync.R

@Composable
fun TranslationSection(uriHandler: UriHandler) {
SettingsItem(label = stringResource(id = R.string.translation)) {
Column(
modifier = Modifier
.clickable { uriHandler.openUri("https://hosted.weblate.org/engage/songsync/") }
.padding(horizontal = 22.dp, vertical = 16.dp)
) {
Text(stringResource(id = R.string.help_us_translate))
Text(
text = stringResource(id = R.string.translation_website),
color = MaterialTheme.colorScheme.outline,
fontSize = 12.sp
)
}
}
}
3 changes: 3 additions & 0 deletions app/src/main/res/values/strings.xml
Original file line number Diff line number Diff line change
Expand Up @@ -143,4 +143,7 @@
<string name="settings">Settings</string>
<string name="date_added">Date added</string>
<string name="date_modified">Date modified</string>
<string name="translation">Translation</string>
<string name="help_us_translate">Help us translate the app to your language!</string>
<string name="translation_website">Open Weblate</string>
</resources>

0 comments on commit 969229a

Please sign in to comment.