mirror of
https://github.com/smyalygames/checklist-tester.git
synced 2025-11-30 01:39:38 +01:00
refactor(connector): change casing for Composable functions
This commit is contained in:
@@ -83,18 +83,18 @@ class Actions (dbActions: List<Action>) : Screen {
|
||||
) {
|
||||
|
||||
item {
|
||||
header()
|
||||
Header()
|
||||
}
|
||||
|
||||
items(
|
||||
items = inputs,
|
||||
key = { input -> input.id }
|
||||
) { item ->
|
||||
actionItem(item)
|
||||
ActionItem(item)
|
||||
}
|
||||
|
||||
item {
|
||||
footer(navigator, viewModel, screenModel)
|
||||
Footer(navigator, viewModel, screenModel)
|
||||
}
|
||||
}
|
||||
|
||||
@@ -112,7 +112,7 @@ class Actions (dbActions: List<Action>) : Screen {
|
||||
}
|
||||
|
||||
@Composable
|
||||
private fun header() {
|
||||
private fun Header() {
|
||||
Text(
|
||||
text = "Edit Actions",
|
||||
style = MaterialTheme.typography.headlineSmall
|
||||
@@ -120,7 +120,7 @@ class Actions (dbActions: List<Action>) : Screen {
|
||||
}
|
||||
|
||||
@Composable
|
||||
private fun actionItem(item: Action) {
|
||||
private fun ActionItem(item: Action) {
|
||||
Column (
|
||||
verticalArrangement = Arrangement.spacedBy(itemPadding)
|
||||
) {
|
||||
@@ -174,7 +174,7 @@ class Actions (dbActions: List<Action>) : Screen {
|
||||
|
||||
@OptIn(ExperimentalResourceApi::class)
|
||||
@Composable
|
||||
private fun footer(navigator: Navigator, viewModel: InterfaceState, screenModel: ActionsScreenModel) {
|
||||
private fun Footer(navigator: Navigator, viewModel: InterfaceState, screenModel: ActionsScreenModel) {
|
||||
Row (
|
||||
Modifier.fillMaxWidth(),
|
||||
horizontalArrangement = Arrangement.SpaceBetween
|
||||
|
||||
@@ -72,7 +72,7 @@ class ListProcedures (
|
||||
) {
|
||||
LazyColumn(state = lazyState) {
|
||||
items(procedures) { procedure ->
|
||||
procedureItem(procedure, viewModel, screenModel)
|
||||
ProcedureItem(procedure, viewModel, screenModel)
|
||||
}
|
||||
}
|
||||
VerticalScrollbar(
|
||||
@@ -90,7 +90,7 @@ class ListProcedures (
|
||||
|
||||
@OptIn(ExperimentalResourceApi::class)
|
||||
@Composable
|
||||
private fun procedureItem(procedure: Procedure, viewModel: InterfaceState, screenModel: ActionsScreenModel) {
|
||||
private fun ProcedureItem(procedure: Procedure, viewModel: InterfaceState, screenModel: ActionsScreenModel) {
|
||||
var expanded by remember { mutableStateOf(false) }
|
||||
|
||||
Box(
|
||||
@@ -111,7 +111,7 @@ class ListProcedures (
|
||||
trailingContent = { Icon(painterResource(Res.drawable.expand_more_24px), "Open Procedure Menu") }
|
||||
)
|
||||
|
||||
procedureMenu(
|
||||
ProcedureMenu(
|
||||
procedure = procedure,
|
||||
viewModel = viewModel,
|
||||
screenModel = screenModel,
|
||||
@@ -124,7 +124,7 @@ class ListProcedures (
|
||||
}
|
||||
|
||||
@Composable
|
||||
private fun procedureMenu(
|
||||
private fun ProcedureMenu(
|
||||
procedure: Procedure,
|
||||
viewModel: InterfaceState,
|
||||
screenModel: ActionsScreenModel,
|
||||
|
||||
@@ -56,7 +56,7 @@ class ListProjects(private val projects: List<Project>) : Screen {
|
||||
) {
|
||||
LazyColumn(state = state) {
|
||||
items(projects) { project ->
|
||||
projectItem(project, viewModel, tabNavigator)
|
||||
ProjectItem(project, viewModel, tabNavigator)
|
||||
}
|
||||
}
|
||||
VerticalScrollbar(
|
||||
@@ -74,7 +74,7 @@ class ListProjects(private val projects: List<Project>) : Screen {
|
||||
|
||||
|
||||
@Composable
|
||||
private fun projectItem(project: Project, viewModel: InterfaceState, tabNavigator: TabNavigator) {
|
||||
private fun ProjectItem(project: Project, viewModel: InterfaceState, tabNavigator: TabNavigator) {
|
||||
ListItem(
|
||||
modifier = Modifier
|
||||
.clickable(
|
||||
|
||||
Reference in New Issue
Block a user