-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #30 from Infomaniak/settings-theme
Use real wordings and icons for Theme Settings
- Loading branch information
Showing
12 changed files
with
285 additions
and
7 deletions.
There are no files selected for viewing
105 changes: 105 additions & 0 deletions
105
app/src/main/java/com/infomaniak/swisstransfer/ui/icons/app/BlackAndWhiteCircle.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,105 @@ | ||
package com.infomaniak.swisstransfer.ui.icons.app | ||
|
||
import androidx.compose.foundation.Image | ||
import androidx.compose.foundation.layout.Box | ||
import androidx.compose.foundation.layout.size | ||
import androidx.compose.runtime.Composable | ||
import androidx.compose.ui.Modifier | ||
import androidx.compose.ui.graphics.Color | ||
import androidx.compose.ui.graphics.PathFillType.Companion.NonZero | ||
import androidx.compose.ui.graphics.SolidColor | ||
import androidx.compose.ui.graphics.StrokeCap.Companion.Butt | ||
import androidx.compose.ui.graphics.StrokeJoin.Companion.Miter | ||
import androidx.compose.ui.graphics.vector.ImageVector | ||
import androidx.compose.ui.graphics.vector.ImageVector.Builder | ||
import androidx.compose.ui.graphics.vector.PathData | ||
import androidx.compose.ui.graphics.vector.group | ||
import androidx.compose.ui.graphics.vector.path | ||
import androidx.compose.ui.tooling.preview.Preview | ||
import androidx.compose.ui.unit.dp | ||
import com.infomaniak.swisstransfer.ui.icons.AppIcons | ||
|
||
val AppIcons.BlackAndWhiteCircle: ImageVector | ||
get() { | ||
if (_blackAndWhiteCircle != null) { | ||
return _blackAndWhiteCircle!! | ||
} | ||
_blackAndWhiteCircle = Builder( | ||
name = "BlackAndWhiteCircle", | ||
defaultWidth = 24.0.dp, | ||
defaultHeight = 24.0.dp, | ||
viewportWidth = 24.0f, | ||
viewportHeight = 24.0f | ||
).apply { | ||
path( | ||
fill = SolidColor(Color(0xFF000000)), | ||
stroke = null, | ||
strokeLineWidth = 0.0f, | ||
strokeLineCap = Butt, | ||
strokeLineJoin = Miter, | ||
strokeLineMiter = 4.0f, | ||
pathFillType = NonZero | ||
) { | ||
moveTo(12.0f, 0.0f) | ||
arcToRelative(12.0f, 12.0f, 0.0f, false, true, 12.0f, 12.0f) | ||
arcToRelative(12.0f, 12.0f, 0.0f, false, true, -12.0f, 12.0f) | ||
arcTo(12.0f, 12.0f, 0.0f, false, true, 0.0f, 12.0f) | ||
arcTo(12.0f, 12.0f, 0.0f, false, true, 12.0f, 0.0f) | ||
close() | ||
} | ||
group(clipPathData = PathData { | ||
moveTo(12.0f, 0.0f) | ||
arcToRelative(12.0f, 12.0f, 0.0f, false, true, 12.0f, 12.0f) | ||
arcToRelative(12.0f, 12.0f, 0.0f, false, true, -12.0f, 12.0f) | ||
arcTo(12.0f, 12.0f, 0.0f, false, true, 0.0f, 12.0f) | ||
arcTo(12.0f, 12.0f, 0.0f, false, true, 12.0f, 0.0f) | ||
close() | ||
}) { | ||
path( | ||
fill = SolidColor(Color(0xFFF5F5F5)), | ||
stroke = null, | ||
strokeLineWidth = 0.0f, | ||
strokeLineCap = Butt, | ||
strokeLineJoin = Miter, | ||
strokeLineMiter = 4.0f, | ||
pathFillType = NonZero | ||
) { | ||
moveTo(-4.5f, 27.5f) | ||
lineTo(27.0f, -2.5f) | ||
lineToRelative(-30.5f, -1.0f) | ||
close() | ||
} | ||
path( | ||
fill = null, | ||
stroke = SolidColor(Color(0xFF000000)), | ||
strokeLineWidth = 0.3f, | ||
strokeLineCap = Butt, | ||
strokeLineJoin = Miter, | ||
strokeLineMiter = 4.0f, | ||
pathFillType = NonZero | ||
) { | ||
moveTo(12.0f, 0.15f) | ||
arcTo(11.85f, 11.85f, 0.0f, false, true, 23.85f, 12.0f) | ||
arcTo(11.85f, 11.85f, 0.0f, false, true, 12.0f, 23.85f) | ||
arcTo(11.85f, 11.85f, 0.0f, false, true, 0.15f, 12.0f) | ||
arcTo(11.85f, 11.85f, 0.0f, false, true, 12.0f, 0.15f) | ||
close() | ||
} | ||
} | ||
}.build() | ||
return _blackAndWhiteCircle!! | ||
} | ||
|
||
private var _blackAndWhiteCircle: ImageVector? = null | ||
|
||
@Preview | ||
@Composable | ||
private fun Preview() { | ||
Box { | ||
Image( | ||
imageVector = AppIcons.BlackAndWhiteCircle, | ||
contentDescription = null, | ||
modifier = Modifier.size(AppIcons.previewSize) | ||
) | ||
} | ||
} |
61 changes: 61 additions & 0 deletions
61
app/src/main/java/com/infomaniak/swisstransfer/ui/icons/app/BlackCircle.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,61 @@ | ||
package com.infomaniak.swisstransfer.ui.icons.app | ||
|
||
import androidx.compose.foundation.Image | ||
import androidx.compose.foundation.layout.Box | ||
import androidx.compose.foundation.layout.size | ||
import androidx.compose.runtime.Composable | ||
import androidx.compose.ui.Modifier | ||
import androidx.compose.ui.graphics.Color | ||
import androidx.compose.ui.graphics.PathFillType.Companion.NonZero | ||
import androidx.compose.ui.graphics.SolidColor | ||
import androidx.compose.ui.graphics.StrokeCap.Companion.Butt | ||
import androidx.compose.ui.graphics.StrokeJoin.Companion.Miter | ||
import androidx.compose.ui.graphics.vector.ImageVector | ||
import androidx.compose.ui.graphics.vector.ImageVector.Builder | ||
import androidx.compose.ui.graphics.vector.path | ||
import androidx.compose.ui.tooling.preview.Preview | ||
import androidx.compose.ui.unit.dp | ||
import com.infomaniak.swisstransfer.ui.icons.AppIcons | ||
|
||
val AppIcons.BlackCircle: ImageVector | ||
get() { | ||
if (_blackCircle != null) { | ||
return _blackCircle!! | ||
} | ||
_blackCircle = Builder( | ||
name = "BlackCircle", | ||
defaultWidth = 24.0.dp, | ||
defaultHeight = 24.0.dp, | ||
viewportWidth = 24.0f, | ||
viewportHeight = 24.0f | ||
).apply { | ||
path( | ||
fill = SolidColor(Color(0xFF000000)), stroke = SolidColor(Color(0xFF000000)), | ||
strokeLineWidth = 0.3f, strokeLineCap = Butt, strokeLineJoin = Miter, | ||
strokeLineMiter = 4.0f, pathFillType = NonZero | ||
) { | ||
moveTo(12.0f, 0.15f) | ||
arcTo(11.85f, 11.85f, 0.0f, false, true, 23.85f, 12.0f) | ||
arcTo(11.85f, 11.85f, 0.0f, false, true, 12.0f, 23.85f) | ||
arcTo(11.85f, 11.85f, 0.0f, false, true, 0.15f, 12.0f) | ||
arcTo(11.85f, 11.85f, 0.0f, false, true, 12.0f, 0.15f) | ||
close() | ||
} | ||
} | ||
.build() | ||
return _blackCircle!! | ||
} | ||
|
||
private var _blackCircle: ImageVector? = null | ||
|
||
@Preview | ||
@Composable | ||
private fun Preview() { | ||
Box { | ||
Image( | ||
imageVector = AppIcons.BlackCircle, | ||
contentDescription = null, | ||
modifier = Modifier.size(AppIcons.previewSize) | ||
) | ||
} | ||
} |
64 changes: 64 additions & 0 deletions
64
app/src/main/java/com/infomaniak/swisstransfer/ui/icons/app/WhiteCircle.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,64 @@ | ||
package com.infomaniak.swisstransfer.ui.icons.app | ||
|
||
import androidx.compose.foundation.Image | ||
import androidx.compose.foundation.layout.Box | ||
import androidx.compose.foundation.layout.size | ||
import androidx.compose.runtime.Composable | ||
import androidx.compose.ui.Modifier | ||
import androidx.compose.ui.graphics.Color | ||
import androidx.compose.ui.graphics.PathFillType.Companion.NonZero | ||
import androidx.compose.ui.graphics.SolidColor | ||
import androidx.compose.ui.graphics.StrokeCap.Companion.Butt | ||
import androidx.compose.ui.graphics.StrokeJoin.Companion.Miter | ||
import androidx.compose.ui.graphics.vector.ImageVector | ||
import androidx.compose.ui.graphics.vector.ImageVector.Builder | ||
import androidx.compose.ui.graphics.vector.path | ||
import androidx.compose.ui.tooling.preview.Preview | ||
import androidx.compose.ui.unit.dp | ||
import com.infomaniak.swisstransfer.ui.icons.AppIcons | ||
|
||
val AppIcons.WhiteCircle: ImageVector | ||
get() { | ||
if (_whiteCircle != null) { | ||
return _whiteCircle!! | ||
} | ||
_whiteCircle = Builder( | ||
name = "WhiteCircle", | ||
defaultWidth = 24.0.dp, | ||
defaultHeight = 24.0.dp, | ||
viewportWidth = 24.0f, | ||
viewportHeight = 24.0f | ||
).apply { | ||
path( | ||
fill = SolidColor(Color(0xFFF5F5F5)), | ||
stroke = SolidColor(Color(0xFF000000)), | ||
strokeLineWidth = 0.3f, | ||
strokeLineCap = Butt, | ||
strokeLineJoin = Miter, | ||
strokeLineMiter = 4.0f, | ||
pathFillType = NonZero | ||
) { | ||
moveTo(12.0f, 0.15f) | ||
arcTo(11.85f, 11.85f, 0.0f, false, true, 23.85f, 12.0f) | ||
arcTo(11.85f, 11.85f, 0.0f, false, true, 12.0f, 23.85f) | ||
arcTo(11.85f, 11.85f, 0.0f, false, true, 0.15f, 12.0f) | ||
arcTo(11.85f, 11.85f, 0.0f, false, true, 12.0f, 0.15f) | ||
close() | ||
} | ||
}.build() | ||
return _whiteCircle!! | ||
} | ||
|
||
private var _whiteCircle: ImageVector? = null | ||
|
||
@Preview | ||
@Composable | ||
private fun Preview() { | ||
Box { | ||
Image( | ||
imageVector = AppIcons.WhiteCircle, | ||
contentDescription = null, | ||
modifier = Modifier.size(AppIcons.previewSize) | ||
) | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.