Skip to content

Commit

Permalink
Merge pull request #174 from Infomaniak/repo-url
Browse files Browse the repository at this point in the history
feat: Use real data for repository URL in DataManagement screen
  • Loading branch information
KevinBoulongne authored Nov 13, 2024
2 parents 5ff9d78 + 016b51c commit a407899
Show file tree
Hide file tree
Showing 7 changed files with 10 additions and 10 deletions.
3 changes: 2 additions & 1 deletion app/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@ android {
}

buildConfigField("String", "RECAPTCHA_API_SITE_KEY", "\"6LfaxOgpAAAAAI3Sj4rtB2oAFjkRJILiGEt-LUsc\"")
buildConfigField ("String", "GITHUB_REPO_URL", "\"https://github.com/Infomaniak/android-SwissTransfer\"")
}

buildTypes {
Expand Down Expand Up @@ -92,7 +93,7 @@ dependencies {
// Compose
implementation(libs.androidx.activity.compose)
implementation(platform(libs.compose.bom))
implementation(libs.compose.foundation) //TODO: To be removed when compose 1.8.0 is stable
implementation(libs.compose.foundation) // TODO: To be removed when compose 1.8.0 is stable
implementation(libs.compose.ui)
implementation(libs.compose.ui.graphics)
implementation(libs.compose.material3)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,6 @@ import org.matomo.sdk.Tracker

object MatomoSwissTransfer : Matomo {

override val Context.tracker: Tracker get() = buildTracker() //TODO fetch appSettings for opt out
override val siteId: Int = -1 //TODO replace with the right site ID when we have one
override val Context.tracker: Tracker get() = buildTracker() // TODO: Fetch appSettings for opt-out
override val siteId: Int = -1 // TODO: Replace with the right site ID when we have one
}
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@ import androidx.compose.ui.Alignment
import androidx.compose.ui.Modifier
import androidx.compose.ui.platform.LocalContext
import androidx.compose.ui.res.stringResource
import com.infomaniak.swisstransfer.BuildConfig
import com.infomaniak.swisstransfer.R
import com.infomaniak.swisstransfer.ui.components.SharpRippleButton
import com.infomaniak.swisstransfer.ui.components.SwissTransferTopAppBar
Expand Down Expand Up @@ -57,7 +58,6 @@ fun SettingsDataManagementScreen(
) {

val context = LocalContext.current
val sourceCodeURL = stringResource(R.string.urlSourceCode) // TODO: Update this URL when we know what we want

SmallWindowTopAppBarScaffold(
smallWindowTopAppBar = {
Expand All @@ -84,7 +84,7 @@ fun SettingsDataManagementScreen(
)
SharpRippleButton(
modifier = Modifier.fillMaxWidth(),
onClick = { context.openUrl(sourceCodeURL) },
onClick = { context.openUrl(BuildConfig.GITHUB_REPO_URL) },
) {
Text(
text = stringResource(R.string.settingsDataManagementSourceCode),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -126,7 +126,7 @@ private fun HandleSendActionResult(
LaunchedEffect(getSendActionResult()) {
when (val actionResult = getSendActionResult()) {
is SendActionResult.Success -> navigateToUploadProgress(transferType(), actionResult.totalSize)
is SendActionResult.Failure -> Unit //TODO: Show error
is SendActionResult.Failure -> Unit // TODO: Show error
else -> Unit
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ fun UploadSourceChoiceBottomSheet(
titleRes = R.string.transferUploadSourceChoiceCamera,
onClick = {
closeBottomSheet()
/* TODO */
// TODO: Handle this feature
},
)
HorizontalDivider(Modifier.padding(horizontal = Margin.Medium))
Expand All @@ -62,7 +62,7 @@ fun UploadSourceChoiceBottomSheet(
titleRes = R.string.transferUploadSourceChoiceGallery,
onClick = {
closeBottomSheet()
/* TODO */
// TODO: Handle this feature
},
)
HorizontalDivider(Modifier.padding(horizontal = Margin.Medium))
Expand Down
1 change: 0 additions & 1 deletion app/src/main/res/values/strings.xml
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@
<string name="appName" translatable="false">SwissTransfer</string>
<string name="matomo" translatable="false">Matomo</string>
<string name="sentry" translatable="false">Sentry</string>
<string name="urlSourceCode" translatable="false">https://chk.me/83azQOl</string>

<string name="advancedSettingsTitle">Advanced settings</string>
<string name="buttonAddFiles">Add files</string>
Expand Down
2 changes: 1 addition & 1 deletion settings.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ dependencyResolutionManagement {
@Suppress("UnstableApiUsage")
repositories {
google()
// mavenLocal() // TODO Do not put this in production
// mavenLocal() // TODO: Do not put this in production
mavenCentral()
maven { url = uri("https://jitpack.io") }
}
Expand Down

0 comments on commit a407899

Please sign in to comment.