Menus only fade in and out under Reduce motion, through floret-kit's FloretDropdownMenu (#157)
This commit is contained in:
1 parent
14bb0d3eb3
commit
ed26d5ba7a
4 files changed
+7
-7
No files matched your search
@@ -51,7 +51,7 @@ import androidx.compose.material.icons.rounded.Notifications
|
||||
import androidx.compose.material.icons.rounded.Repeat
|
||||
import androidx.compose.material.icons.rounded.MoreVert
|
||||
import androidx.compose.material3.AlertDialog
|
||||
import androidx.compose.material3.DropdownMenu
|
||||
import de.jeanlucmakiola.floret.components.FloretDropdownMenu
|
||||
import androidx.compose.material3.DropdownMenuItem
|
||||
import androidx.compose.material3.Checkbox
|
||||
import androidx.compose.material3.TextButton
|
||||
@@ -177,7 +177,7 @@ fun TaskDetailScreen(
|
||||
contentDescription = stringResource(R.string.more_options),
|
||||
onClick = { menuOpen = true },
|
||||
)
|
||||
DropdownMenu(expanded = menuOpen, onDismissRequest = { menuOpen = false }) {
|
||||
FloretDropdownMenu(expanded = menuOpen, onDismissRequest = { menuOpen = false }) {
|
||||
val cancelled = task.status == TaskStatus.CANCELLED
|
||||
DropdownMenuItem(
|
||||
text = {
|
||||
|
||||
@@ -52,7 +52,7 @@ import androidx.compose.material.icons.rounded.ExpandMore
|
||||
import androidx.compose.material.icons.rounded.Flag
|
||||
import androidx.compose.material.icons.rounded.MoreVert
|
||||
import androidx.compose.material.icons.rounded.PushPin
|
||||
import androidx.compose.material3.DropdownMenu
|
||||
import de.jeanlucmakiola.floret.components.FloretDropdownMenu
|
||||
import androidx.compose.material3.DropdownMenuItem
|
||||
import androidx.compose.material3.Checkbox
|
||||
import androidx.compose.material3.ExperimentalMaterial3Api
|
||||
@@ -300,7 +300,7 @@ fun TaskListScreen(
|
||||
contentDescription = stringResource(R.string.more_options),
|
||||
onClick = { menuOpen = true },
|
||||
)
|
||||
DropdownMenu(expanded = menuOpen, onDismissRequest = { menuOpen = false }) {
|
||||
FloretDropdownMenu(expanded = menuOpen, onDismissRequest = { menuOpen = false }) {
|
||||
DropdownMenuItem(
|
||||
text = { Text(stringResource(R.string.view_pin)) },
|
||||
leadingIcon = { Icon(Icons.Rounded.PushPin, contentDescription = null) },
|
||||
|
||||
@@ -14,7 +14,6 @@ import androidx.compose.material.icons.rounded.ExpandMore
|
||||
import androidx.compose.material.icons.rounded.Checklist
|
||||
import androidx.compose.material3.DropdownMenuGroup
|
||||
import androidx.compose.material3.DropdownMenuItem
|
||||
import androidx.compose.material3.DropdownMenuPopup
|
||||
import androidx.compose.material3.ExperimentalMaterial3ExpressiveApi
|
||||
import androidx.compose.material3.Icon
|
||||
import androidx.compose.material3.MaterialTheme
|
||||
@@ -37,6 +36,7 @@ import androidx.compose.ui.text.style.TextOverflow
|
||||
import androidx.compose.ui.unit.dp
|
||||
import de.jeanlucmakiola.agendula.R
|
||||
import de.jeanlucmakiola.agendula.domain.View
|
||||
import de.jeanlucmakiola.floret.components.FloretDropdownMenuPopup
|
||||
|
||||
/**
|
||||
* The view's name in the home top bar, which opens the view menu: every view,
|
||||
@@ -77,7 +77,7 @@ fun ViewSwitcher(
|
||||
Icon(Icons.Rounded.ExpandMore, contentDescription = switcherLabel)
|
||||
}
|
||||
}
|
||||
DropdownMenuPopup(expanded = open, onDismissRequest = { open = false }) {
|
||||
FloretDropdownMenuPopup(expanded = open, onDismissRequest = { open = false }) {
|
||||
DropdownMenuGroup(shapes = MenuDefaults.groupShape(0, 2)) {
|
||||
views.forEachIndexed { index, view ->
|
||||
val selected = view.id == activeViewId
|
||||
|
||||
+1
-1
Submodule floret-kit updated: a11f3e9f57...bc9d22089c.
Reference in new issue
Block a user