mirror of
https://github.com/FBukovina/Atoll.git
synced 2026-10-27 15:14:33 +00:00
Feature: Favourites
This commit is contained in:
parent
79b16570b5
commit
5321352184
7 changed files with 627 additions and 32 deletions
|
|
@ -1589,6 +1589,7 @@ struct ClipboardSettings: View {
|
|||
@Default(.enableClipboardManager) var enableClipboardManager
|
||||
@Default(.clipboardHistorySize) var clipboardHistorySize
|
||||
@Default(.showClipboardIcon) var showClipboardIcon
|
||||
@Default(.clipboardWindowMode) var clipboardWindowMode
|
||||
|
||||
var body: some View {
|
||||
Form {
|
||||
|
|
@ -1611,6 +1612,8 @@ struct ClipboardSettings: View {
|
|||
Section {
|
||||
Defaults.Toggle("Show Clipboard Icon", key: .showClipboardIcon)
|
||||
|
||||
Defaults.Toggle("Window Mode", key: .clipboardWindowMode)
|
||||
|
||||
HStack {
|
||||
Text("History Size")
|
||||
Spacer()
|
||||
|
|
@ -1631,6 +1634,13 @@ struct ClipboardSettings: View {
|
|||
.foregroundColor(.secondary)
|
||||
}
|
||||
|
||||
HStack {
|
||||
Text("Pinned Items")
|
||||
Spacer()
|
||||
Text("\(clipboardManager.pinnedItems.count)")
|
||||
.foregroundColor(.secondary)
|
||||
}
|
||||
|
||||
HStack {
|
||||
Text("Monitoring Status")
|
||||
Spacer()
|
||||
|
|
@ -1640,7 +1650,7 @@ struct ClipboardSettings: View {
|
|||
} header: {
|
||||
Text("Settings")
|
||||
} footer: {
|
||||
Text("The clipboard icon appears in the header next to the settings gear when enabled. Use the global shortcut Cmd+Shift+V or click the icon to access history.")
|
||||
Text("Window Mode shows clipboard in a moveable window like Raycast with tabs for history and favorites. When disabled, clipboard appears in a popover attached to the Dynamic Island.")
|
||||
}
|
||||
|
||||
Section {
|
||||
|
|
@ -1649,10 +1659,17 @@ struct ClipboardSettings: View {
|
|||
}
|
||||
.foregroundColor(.red)
|
||||
.disabled(clipboardManager.clipboardHistory.isEmpty)
|
||||
|
||||
Button("Clear Pinned Items") {
|
||||
clipboardManager.pinnedItems.removeAll()
|
||||
clipboardManager.savePinnedItemsToDefaults()
|
||||
}
|
||||
.foregroundColor(.red)
|
||||
.disabled(clipboardManager.pinnedItems.isEmpty)
|
||||
} header: {
|
||||
Text("Actions")
|
||||
} footer: {
|
||||
Text("This will permanently delete all stored clipboard history. The clipboard button is located to the left of the settings gear in the header.")
|
||||
Text("Clear clipboard history removes recent copies. Clear pinned items removes your favorites. Both actions are permanent.")
|
||||
}
|
||||
|
||||
if !clipboardManager.clipboardHistory.isEmpty {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue