Update the readme
This commit is contained in:
parent
2056348ec0
commit
8fdc6f12ab
2 changed files with 13 additions and 34 deletions
16
README.md
16
README.md
|
|
@ -1,11 +1,15 @@
|
|||
This is a Kotlin Multiplatform project targeting Desktop.
|
||||
|
||||
* `/composeApp` is for code that will be shared across your Compose Multiplatform applications.
|
||||
It contains several subfolders:
|
||||
- `commonMain` is for code that’s common for all targets.
|
||||
- Other folders are for Kotlin code that will be compiled for only the platform indicated in the folder name.
|
||||
For example, if you want to use Apple’s CoreCrypto for the iOS part of your Kotlin app,
|
||||
`iosMain` would be the right folder for such calls.
|
||||
Recommended configuration :
|
||||
|
||||
* Server :
|
||||
- Run : `Kotlin configuration` with main class : `com.pixelized.server.lwa.ApplicationKt`
|
||||
- build : `Gradle configuration : "server:buildFatJar"`
|
||||
|
||||
* Client :
|
||||
- Run the debug version of the app : `Gradle configuration : "composeApp:run"`
|
||||
- Run the release version of the app : `Gradle configuration : "composeApp:runRelease"`
|
||||
- Build the release version of the app for MacOS : `Gradle configuration : "composeApp:packageReleaseDmg"`
|
||||
- Build the release version of the app for Windows : `Gradle configuration : "composeApp:packageReleaseMsi"`
|
||||
|
||||
Learn more about [Kotlin Multiplatform](https://www.jetbrains.com/help/kotlin-multiplatform-dev/get-started.html)…
|
||||
|
|
@ -1,6 +1,7 @@
|
|||
package com.pixelized.desktop.lwa.ui.screen.gamemaster.items
|
||||
|
||||
import androidx.compose.foundation.background
|
||||
import androidx.compose.foundation.clickable
|
||||
import androidx.compose.foundation.layout.Arrangement
|
||||
import androidx.compose.foundation.layout.Box
|
||||
import androidx.compose.foundation.layout.Column
|
||||
|
|
@ -103,6 +104,7 @@ fun GMCharacter(
|
|||
Box(
|
||||
modifier = Modifier
|
||||
.clip(shape = remember { RoundedCornerShape(8.dp) })
|
||||
.clickable(onClick = onEdit)
|
||||
.background(color = MaterialTheme.lwa.colorScheme.elevated.base1dp)
|
||||
.then(other = modifier),
|
||||
) {
|
||||
|
|
@ -129,9 +131,8 @@ fun GMCharacter(
|
|||
),
|
||||
)
|
||||
}
|
||||
MenuActions(
|
||||
OverflowActionMenu(
|
||||
character = character,
|
||||
onEdit = onEdit,
|
||||
onAction = onAction,
|
||||
)
|
||||
}
|
||||
|
|
@ -153,32 +154,6 @@ fun GMCharacter(
|
|||
}
|
||||
}
|
||||
|
||||
@Composable
|
||||
private fun MenuActions(
|
||||
modifier: Modifier = Modifier,
|
||||
character: GMCharacterUio,
|
||||
onEdit: () -> Unit,
|
||||
onAction: (Action) -> Unit,
|
||||
) {
|
||||
Row(
|
||||
modifier = modifier,
|
||||
) {
|
||||
IconButton(
|
||||
onClick = onEdit
|
||||
) {
|
||||
Icon(
|
||||
imageVector = Icons.Default.Edit,
|
||||
tint = MaterialTheme.lwa.colorScheme.base.primary,
|
||||
contentDescription = null,
|
||||
)
|
||||
}
|
||||
OverflowActionMenu(
|
||||
character = character,
|
||||
onAction = onAction,
|
||||
)
|
||||
}
|
||||
}
|
||||
|
||||
@Composable
|
||||
private fun OverflowActionMenu(
|
||||
modifier: Modifier = Modifier,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue