The sort picker climbs to the navigation bar — principal slot, centered
Same three conditional pickers, now riding the nav bar's center instead of the bottom bar, width-capped so the segments don't sprawl. Claude-Session: https://claude.ai/code/session_01SR4XGjmBE16ZUYWpfFHXwY
This commit is contained in:
@@ -81,13 +81,14 @@ struct BoardScreen: View {
|
||||
@ToolbarContentBuilder
|
||||
private var sortToolbarItem: some ToolbarContent {
|
||||
if case .ready = session.phase, let snapshot = session.snapshot, !snapshot.lanes.isEmpty {
|
||||
ToolbarItem(placement: .bottomBar) {
|
||||
ToolbarItem(placement: .principal) {
|
||||
Picker("Sort", selection: sortOrder) {
|
||||
Text("Manual").tag(ItemSortOrder.manual)
|
||||
Text("Name").tag(ItemSortOrder.name)
|
||||
Text("Recent").tag(ItemSortOrder.recent)
|
||||
}
|
||||
.pickerStyle(.segmented)
|
||||
.frame(maxWidth: 260)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -81,12 +81,13 @@ struct BoardsTabView: View {
|
||||
@ToolbarContentBuilder
|
||||
private var sortToolbarItem: some ToolbarContent {
|
||||
if case .ready = index.phase, !index.boards.isEmpty {
|
||||
ToolbarItem(placement: .bottomBar) {
|
||||
ToolbarItem(placement: .principal) {
|
||||
Picker("Sort", selection: sortOrder) {
|
||||
Text("Name").tag(BoardSortOrder.name)
|
||||
Text("Recent").tag(BoardSortOrder.recent)
|
||||
}
|
||||
.pickerStyle(.segmented)
|
||||
.frame(maxWidth: 260)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -96,13 +96,14 @@ struct LaneScreen: View {
|
||||
@ToolbarContentBuilder
|
||||
private var sortToolbarItem: some ToolbarContent {
|
||||
if let lane, !lane.cards.isEmpty {
|
||||
ToolbarItem(placement: .bottomBar) {
|
||||
ToolbarItem(placement: .principal) {
|
||||
Picker("Sort", selection: sortOrder) {
|
||||
Text("Manual").tag(ItemSortOrder.manual)
|
||||
Text("Name").tag(ItemSortOrder.name)
|
||||
Text("Recent").tag(ItemSortOrder.recent)
|
||||
}
|
||||
.pickerStyle(.segmented)
|
||||
.frame(maxWidth: 260)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user