Fokus-Ansicht in der Vorschau (F)
Blendet Werkzeugleiste, Tabs, Matchday-Kopf, Filterleiste und Seitenleiste aus – übrig bleiben Bild, Filmstreifen mit Bildinfo und das IPTC-Panel rechts. Schalter unten neben dem Panel-Knopf, Taste F, Bild-Menü; wird gemerkt, Seitenleiste kommt beim Verlassen wie vorher zurück. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_012bGzgsxrmbBhDzeMV2L57D
This commit is contained in:
1 parent
bfaea219c6
commit
80d5b4181f
6 files changed
+30
-5
No files matched your search
@@ -8,17 +8,21 @@ struct ContentView: View {
|
||||
@EnvironmentObject var uploads: UploadQueue
|
||||
@State private var keyboard = KeyboardMonitor()
|
||||
@Environment(\.openWindow) private var openWindow
|
||||
@State private var columns: NavigationSplitViewVisibility = .automatic
|
||||
@State private var columnsBeforeFocus: NavigationSplitViewVisibility = .automatic
|
||||
|
||||
var body: some View {
|
||||
NavigationSplitView {
|
||||
NavigationSplitView(columnVisibility: $columns) {
|
||||
PMSidebar()
|
||||
.navigationSplitViewColumnWidth(min: 200, ideal: 260, max: 420)
|
||||
} detail: {
|
||||
VStack(spacing: 0) {
|
||||
TabBar()
|
||||
if state.folder != nil && state.matchdayActive { MatchdayHeader() }
|
||||
if state.folder != nil { ContactSheetHeader() }
|
||||
Rectangle().fill(LK.border).frame(height: 1)
|
||||
if !state.focusActive {
|
||||
TabBar()
|
||||
if state.folder != nil && state.matchdayActive { MatchdayHeader() }
|
||||
if state.folder != nil { ContactSheetHeader() }
|
||||
Rectangle().fill(LK.border).frame(height: 1)
|
||||
}
|
||||
if state.folder == nil {
|
||||
EmptyStateView()
|
||||
} else if state.items.isEmpty && !state.loadingMetadata {
|
||||
@@ -36,6 +40,11 @@ struct ContentView: View {
|
||||
.tint(LK.amber)
|
||||
.navigationTitle(state.folder?.lastPathComponent ?? "Lichtkasten")
|
||||
.toolbar { MainToolbar() }
|
||||
.toolbar(state.focusActive ? .hidden : .visible, for: .windowToolbar)
|
||||
.onChange(of: state.focusActive) { _, on in
|
||||
// the sidebar goes too, and comes back as it was
|
||||
if on { columnsBeforeFocus = columns; columns = .detailOnly } else { columns = columnsBeforeFocus }
|
||||
}
|
||||
.searchable(text: $state.searchText, placement: .toolbar, prompt: "Dateiname, IPTC …")
|
||||
.background(WindowAccessor { state.browserWindow = $0 })
|
||||
.onAppear { keyboard.install(state: state) }
|
||||
|
||||
@@ -75,6 +75,11 @@ struct PreviewView: View {
|
||||
Button { state.settings.loupePanel.toggle() } label: { Image(systemName: "sidebar.right") }
|
||||
.buttonStyle(LKButtonStyle(compact: true))
|
||||
.help("IPTC-Panel ein/aus")
|
||||
Button { state.focusMode.toggle() } label: {
|
||||
Image(systemName: state.focusMode ? "arrow.down.right.and.arrow.up.left" : "arrow.up.left.and.arrow.down.right")
|
||||
}
|
||||
.buttonStyle(LKButtonStyle(primary: state.focusMode, compact: true))
|
||||
.help(state.focusMode ? "Leisten oben wieder zeigen (F)" : "Fokus: Leisten oben ausblenden (F)")
|
||||
}
|
||||
}
|
||||
.padding(.horizontal, 16)
|
||||
|
||||
Reference in new issue
Block a user