Skip to content

Commit

Permalink
Add "Category: " before category menu in create and edit entry
Browse files Browse the repository at this point in the history
  • Loading branch information
Dominik Heckner committed Jun 24, 2022
1 parent 9a35c7e commit ed9a724
Show file tree
Hide file tree
Showing 3 changed files with 19 additions and 11 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -5,13 +5,10 @@ import de.hsfl.budgetBinder.common.Category
import androidx.compose.runtime.Composable
import de.hsfl.budgetBinder.compose.theme.AppStylesheet
import de.hsfl.budgetBinder.presentation.CategoryImageToIcon
import org.jetbrains.compose.web.ExperimentalComposeWebSvgApi
import org.jetbrains.compose.web.attributes.ButtonType
import org.jetbrains.compose.web.attributes.type
import org.jetbrains.compose.web.css.*
import org.jetbrains.compose.web.dom.*
import org.jetbrains.compose.web.svg.Circle
import org.jetbrains.compose.web.svg.Svg


/*Main Container for every mayor layout*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -202,8 +202,15 @@ fun EntryCreateView(
}
}
Div(attrs = { classes(AppStylesheet.flex50) }) {
ChooseCategoryMenu(categoryList, entryCategoryIDTextField) { id ->
viewModel.onEvent(EntryEvent.EnteredCategoryID(id))
Div(
attrs = {
classes(AppStylesheet.margin)
}
) {
Text("Category: ")
ChooseCategoryMenu(categoryList, entryCategoryIDTextField) { id ->
viewModel.onEvent(EntryEvent.EnteredCategoryID(id))
}
}
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -203,12 +203,16 @@ fun EntryEditView(
Label(forId = "checkbox-1") { Text("repeat") }
}
}
Div(attrs = {
classes(AppStylesheet.flex50)
style { alignItems(AlignItems.Stretch) }
}) {
ChooseCategoryMenu(categoryList, entryCategoryIDTextField) { id ->
viewModel.onEvent(EntryEvent.EnteredCategoryID(id))
Div(attrs = { classes(AppStylesheet.flex50) }) {
Div(
attrs = {
classes(AppStylesheet.margin)
}
) {
Text("Category: ")
ChooseCategoryMenu(categoryList, entryCategoryIDTextField) { id ->
viewModel.onEvent(EntryEvent.EnteredCategoryID(id))
}
}
}
}
Expand Down

0 comments on commit ed9a724

Please sign in to comment.