This commit is contained in:
1 parent
c96a7783dd
commit
b6960476a8
3 files changed
+19
-8
No files matched your search
@@ -21,7 +21,10 @@ object ActionShapes {
|
||||
/** New list — a sunny burst beside the Lists header. */
|
||||
val AddList: RoundedPolygon get() = MaterialShapes.Sunny
|
||||
|
||||
/** What [AddList] and [AddFilter] morph into on press. */
|
||||
/** New view — the same burst as [AddList], beside the views it adds to. */
|
||||
val AddView: RoundedPolygon get() = MaterialShapes.Sunny
|
||||
|
||||
/** What [AddList], [AddFilter] and [AddView] morph into on press. */
|
||||
val AddListPressed: RoundedPolygon get() = MaterialShapes.Circle
|
||||
|
||||
/** New filter — the same burst as [AddList], so both "add" actions read alike. */
|
||||
|
||||
@@ -301,9 +301,12 @@ fun TaskListScreen(
|
||||
// A list or a saved filter can become a view of its own (#59).
|
||||
if (list != null || savedFilter != null) {
|
||||
Box {
|
||||
IconButton(onClick = { menuOpen = true }) {
|
||||
Icon(Icons.Rounded.MoreVert, contentDescription = stringResource(R.string.more_options))
|
||||
}
|
||||
ActionButton(
|
||||
shape = ActionShapes.More,
|
||||
icon = Icons.Rounded.MoreVert,
|
||||
contentDescription = stringResource(R.string.more_options),
|
||||
onClick = { menuOpen = true },
|
||||
)
|
||||
DropdownMenu(expanded = menuOpen, onDismissRequest = { menuOpen = false }) {
|
||||
DropdownMenuItem(
|
||||
text = { Text(stringResource(R.string.view_pin)) },
|
||||
|
||||
@@ -11,7 +11,6 @@ import androidx.compose.material.icons.rounded.Add
|
||||
import androidx.compose.material.icons.rounded.ChevronRight
|
||||
import androidx.compose.material.icons.rounded.DragHandle
|
||||
import androidx.compose.material3.Icon
|
||||
import androidx.compose.material3.IconButton
|
||||
import androidx.compose.material3.MaterialTheme
|
||||
import androidx.compose.material3.Text
|
||||
import androidx.compose.foundation.layout.padding
|
||||
@@ -27,8 +26,10 @@ import androidx.hilt.lifecycle.viewmodel.compose.hiltViewModel
|
||||
import androidx.lifecycle.compose.collectAsStateWithLifecycle
|
||||
import de.jeanlucmakiola.agendula.R
|
||||
import de.jeanlucmakiola.agendula.domain.View
|
||||
import de.jeanlucmakiola.agendula.ui.common.ActionShapes
|
||||
import de.jeanlucmakiola.agendula.ui.settings.ChipAccent
|
||||
import de.jeanlucmakiola.agendula.ui.settings.CategoryIcon
|
||||
import de.jeanlucmakiola.floret.components.ActionButton
|
||||
import de.jeanlucmakiola.floret.components.CollapsingScaffold
|
||||
import de.jeanlucmakiola.floret.components.GroupedRow
|
||||
import de.jeanlucmakiola.floret.components.Position
|
||||
@@ -58,9 +59,13 @@ fun ManageViewsScreen(
|
||||
onBack = onBack,
|
||||
largeTopBar = false,
|
||||
actions = {
|
||||
IconButton(onClick = { onEditView(0) }) {
|
||||
Icon(Icons.Rounded.Add, contentDescription = stringResource(R.string.view_add))
|
||||
}
|
||||
ActionButton(
|
||||
shape = ActionShapes.AddView,
|
||||
morphTo = ActionShapes.AddListPressed,
|
||||
icon = Icons.Rounded.Add,
|
||||
contentDescription = stringResource(R.string.view_add),
|
||||
onClick = { onEditView(0) },
|
||||
)
|
||||
},
|
||||
) {
|
||||
if (home == null) return@CollapsingScaffold
|
||||
|
||||
Reference in new issue
Block a user