implement import/export for typographie
This commit is contained in:
@@ -11,6 +11,7 @@ import de.mm20.launcher2.themes.colors.DefaultLightColorScheme
|
||||
import de.mm20.launcher2.themes.colors.EmptyCorePalette
|
||||
import de.mm20.launcher2.themes.shapes.Shapes
|
||||
import de.mm20.launcher2.themes.transparencies.Transparencies
|
||||
import de.mm20.launcher2.themes.typography.Typography
|
||||
import kotlinx.serialization.Serializable
|
||||
import kotlinx.serialization.SerializationException
|
||||
import kotlinx.serialization.json.JsonObject
|
||||
@@ -26,6 +27,7 @@ data class ThemeBundle(
|
||||
val name: String,
|
||||
val author: String? = null,
|
||||
val colors: Colors? = null,
|
||||
val typography: Typography? = null,
|
||||
val shapes: Shapes? = null,
|
||||
val transparencies: Transparencies? = null,
|
||||
/**
|
||||
|
||||
@@ -216,6 +216,7 @@ sealed interface FontWeight {
|
||||
* Absolute font weight, e.g. 400 for normal, 700 for bold.
|
||||
*/
|
||||
@JvmInline
|
||||
@Serializable
|
||||
value class Absolute(val weight: Int) : FontWeight
|
||||
|
||||
/**
|
||||
@@ -224,5 +225,6 @@ sealed interface FontWeight {
|
||||
* the emphasized style with a relative weight of 100 will have a weight of 500,
|
||||
*/
|
||||
@JvmInline
|
||||
@Serializable
|
||||
value class Relative(val relativeWeight: Int) : FontWeight
|
||||
}
|
||||
Reference in New Issue
Block a user