Package com.example.examer.ui.components

Types

Link copied to clipboard
data class NavigationDrawerDestination(    val icon: ImageVector,     val name: String,     val onClick: () -> Unit)

A data class that models a destination in a navigation drawer.

Link copied to clipboard
data class NavigationDrawerItemColors(val backgroundColor: Color, val contentColor: Color)

Data class that holds the colors that are related to NavigationDrawerItem.

Link copied to clipboard
object NavigationDrawerItemDefaults

Contains the default values used by NavigationDrawerItem.

Functions

Link copied to clipboard
@Composable
fun AlertDialog(    title: String,     message: String,     confirmText: String,     onConfirmButtonClick: () -> Unit,     onDismissRequest: () -> Unit)
@Composable
fun AlertDialog(    title: String,     message: String,     confirmText: String,     onConfirmButtonClick: () -> Unit,     dismissButtonText: String,     onDismissButtonClick: () -> Unit,     onDismissRequest: () -> Unit)
Link copied to clipboard
@Composable
fun CircularLoadingProgressOverlay(    modifier: Modifier = Modifier,     overlayColor: Color = Color.Black,     isOverlayVisible: Boolean,     content: @Composable () -> Unit)

Displays an overlay over the content with a circular progress indicator.It takes up the entire size of size of its parent.

Link copied to clipboard
@ExperimentalCoilApi
@Composable
fun ExamerNavigationScaffold(    currentlyLoggedInUser: ExamerUser,     imagePainter: ImagePainter,     modifier: Modifier = Modifier,     scaffoldState: ScaffoldState = rememberScaffoldState(),     isTopAppBarVisible: Boolean = true,     navigationIconImageVector: ImageVector = Icons.Filled.Menu,     onNavigationIconClick: () -> Unit? = null,     isDrawerGesturesEnabled: Boolean = true,     isNavigationDrawerDestinationSelected: (NavigationDrawerDestination) -> Boolean? = null,     navigationDrawerDestinations: List<NavigationDrawerDestination>,     onSignOutButtonClick: () -> Unit? = null,     content: @Composable (PaddingValues) -> Unit)

A scaffold that manages the topAppbar and NavigationDrawer.

Link copied to clipboard
@Composable
fun ExamerSingleLineTextField(    modifier: Modifier = Modifier,     value: String,     placeholder: @Composable () -> Unit? = null,     leadingIcon: @Composable () -> Unit? = null,     trailingIcon: @Composable () -> Unit? = null,     keyboardActions: KeyboardActions = KeyboardActions.Default,     isError: Boolean = false,     visualTransformation: VisualTransformation = VisualTransformation.None,     label: @Composable () -> Unit? = null,     onValueChange: (String) -> Unit)

A single lined material themed OutlinedTextField with custom color presets that match the app's theme.

Link copied to clipboard
@Composable
fun MultiChoiceQuestionCard(    questionNumber: Int,     question: String,     options: Array<String>,     mark: Int,     currentlySelectedIndex: Int,     onOptionClick: (index: Int, questionNumber: Int, string: String) -> Unit,     modifier: Modifier = Modifier)
Link copied to clipboard
@Composable
fun NavigationDrawerItem(    icon: ImageVector,     label: String,     isSelected: Boolean = false,     onClick: () -> Unit? = null,     activeColors: NavigationDrawerItemColors = NavigationDrawerItemDefaults.activeColors,     inactiveColors: NavigationDrawerItemColors = NavigationDrawerItemDefaults.inactiveColors,     shape: RoundedCornerShape = NavigationDrawerItemDefaults.shape)

A navigation item that is meant to be used within a Navigation Drawer.