diff options
| author | Dustin Mierau <dustin@mierau.me> | 2024-06-30 17:46:30 -0700 |
|---|---|---|
| committer | Dustin Mierau <dustin@mierau.me> | 2024-06-30 17:46:30 -0700 |
| commit | 038df124a9c9d0ec7e7f3a7387669d5273a5bf49 (patch) | |
| tree | 47f9c39c14a4b48e83be1c42885d92bd88384d47 /Hotline | |
| parent | 3c352f194c7d14cc8a1ee23ec8fb7b834132d9a0 (diff) | |
A pass on icons. Sleeker toolbar window. Fix Accounts and News menu item disable states. Don't request banner from older servers. Cleanup News list display.
Diffstat (limited to 'Hotline')
75 files changed, 321 insertions, 114 deletions
diff --git a/Hotline/Application-macOS.swift b/Hotline/Application-macOS.swift index 63b127a..56ead01 100644 --- a/Hotline/Application-macOS.swift +++ b/Hotline/Application-macOS.swift @@ -214,7 +214,7 @@ struct Application: App { Button("Show News") { activeServerState?.selection = .news } - .disabled(activeHotline?.status != .loggedIn) + .disabled(activeHotline?.status != .loggedIn || (activeHotline?.serverVersion ?? 0) < 151) .keyboardShortcut(.init("2"), modifiers: .command) Button("Show Message Board") { activeServerState?.selection = .board @@ -229,7 +229,7 @@ struct Application: App { Button("Show Accounts") { activeServerState?.selection = .accounts } - .disabled(activeHotline?.status != .loggedIn || activeHotline?.access?.contains(.canOpenUsers) == false ) + .disabled(activeHotline?.status != .loggedIn || activeHotline?.access?.contains(.canOpenUsers) != true ) .keyboardShortcut(.init("5"), modifiers: .command) } } diff --git a/Hotline/Assets.xcassets/Admin Drop Box.imageset/Admin Drop Box.png b/Hotline/Assets.xcassets/Admin Drop Box.imageset/Admin Drop Box.png Binary files differindex 5d4bdb8..9905d7c 100644 --- a/Hotline/Assets.xcassets/Admin Drop Box.imageset/Admin Drop Box.png +++ b/Hotline/Assets.xcassets/Admin Drop Box.imageset/Admin Drop Box.png diff --git a/Hotline/Assets.xcassets/Admin Drop Box.imageset/Admin Drop Box@2x.png b/Hotline/Assets.xcassets/Admin Drop Box.imageset/Admin Drop Box@2x.png Binary files differindex 1ecf037..ad82349 100644 --- a/Hotline/Assets.xcassets/Admin Drop Box.imageset/Admin Drop Box@2x.png +++ b/Hotline/Assets.xcassets/Admin Drop Box.imageset/Admin Drop Box@2x.png diff --git a/Hotline/Assets.xcassets/Admin Drop Box.imageset/Admin Drop Box@3x.png b/Hotline/Assets.xcassets/Admin Drop Box.imageset/Admin Drop Box@3x.png Binary files differindex c0cf6ce..b80f711 100644 --- a/Hotline/Assets.xcassets/Admin Drop Box.imageset/Admin Drop Box@3x.png +++ b/Hotline/Assets.xcassets/Admin Drop Box.imageset/Admin Drop Box@3x.png diff --git a/Hotline/Assets.xcassets/Drop Box.imageset/Drop Box.png b/Hotline/Assets.xcassets/Drop Box.imageset/Drop Box.png Binary files differindex be8b501..09bf921 100644 --- a/Hotline/Assets.xcassets/Drop Box.imageset/Drop Box.png +++ b/Hotline/Assets.xcassets/Drop Box.imageset/Drop Box.png diff --git a/Hotline/Assets.xcassets/Drop Box.imageset/Drop Box@2x.png b/Hotline/Assets.xcassets/Drop Box.imageset/Drop Box@2x.png Binary files differindex 0249b96..6571289 100644 --- a/Hotline/Assets.xcassets/Drop Box.imageset/Drop Box@2x.png +++ b/Hotline/Assets.xcassets/Drop Box.imageset/Drop Box@2x.png diff --git a/Hotline/Assets.xcassets/Drop Box.imageset/Drop Box@3x.png b/Hotline/Assets.xcassets/Drop Box.imageset/Drop Box@3x.png Binary files differindex 4d5bad2..9d7e747 100644 --- a/Hotline/Assets.xcassets/Drop Box.imageset/Drop Box@3x.png +++ b/Hotline/Assets.xcassets/Drop Box.imageset/Drop Box@3x.png diff --git a/Hotline/Assets.xcassets/Folder.imageset/Folder.png b/Hotline/Assets.xcassets/Folder.imageset/Folder.png Binary files differindex e9909ab..381061c 100644 --- a/Hotline/Assets.xcassets/Folder.imageset/Folder.png +++ b/Hotline/Assets.xcassets/Folder.imageset/Folder.png diff --git a/Hotline/Assets.xcassets/Folder.imageset/Folder@2x.png b/Hotline/Assets.xcassets/Folder.imageset/Folder@2x.png Binary files differindex 860ca3b..df1c58d 100644 --- a/Hotline/Assets.xcassets/Folder.imageset/Folder@2x.png +++ b/Hotline/Assets.xcassets/Folder.imageset/Folder@2x.png diff --git a/Hotline/Assets.xcassets/Folder.imageset/Folder@3x.png b/Hotline/Assets.xcassets/Folder.imageset/Folder@3x.png Binary files differindex 9e7634b..10fe0e9 100644 --- a/Hotline/Assets.xcassets/Folder.imageset/Folder@3x.png +++ b/Hotline/Assets.xcassets/Folder.imageset/Folder@3x.png diff --git a/Hotline/Assets.xcassets/Message Board Post.imageset/Message Board Post.png b/Hotline/Assets.xcassets/Message Board Post.imageset/Message Board Post.png Binary files differindex 80f0f73..3d7fae1 100644 --- a/Hotline/Assets.xcassets/Message Board Post.imageset/Message Board Post.png +++ b/Hotline/Assets.xcassets/Message Board Post.imageset/Message Board Post.png diff --git a/Hotline/Assets.xcassets/Message Board Post.imageset/Message Board Post@2x.png b/Hotline/Assets.xcassets/Message Board Post.imageset/Message Board Post@2x.png Binary files differindex 990e5fd..1ccc659 100644 --- a/Hotline/Assets.xcassets/Message Board Post.imageset/Message Board Post@2x.png +++ b/Hotline/Assets.xcassets/Message Board Post.imageset/Message Board Post@2x.png diff --git a/Hotline/Assets.xcassets/Message Board Post.imageset/Message Board Post@3x.png b/Hotline/Assets.xcassets/Message Board Post.imageset/Message Board Post@3x.png Binary files differindex 6f293b5..98bd367 100644 --- a/Hotline/Assets.xcassets/Message Board Post.imageset/Message Board Post@3x.png +++ b/Hotline/Assets.xcassets/Message Board Post.imageset/Message Board Post@3x.png diff --git a/Hotline/Assets.xcassets/News Bundle.imageset/News Bundle.png b/Hotline/Assets.xcassets/News Bundle.imageset/News Bundle.png Binary files differindex b0f4ee4..1b154db 100644 --- a/Hotline/Assets.xcassets/News Bundle.imageset/News Bundle.png +++ b/Hotline/Assets.xcassets/News Bundle.imageset/News Bundle.png diff --git a/Hotline/Assets.xcassets/News Bundle.imageset/News Bundle@2x.png b/Hotline/Assets.xcassets/News Bundle.imageset/News Bundle@2x.png Binary files differindex 4728426..7583460 100644 --- a/Hotline/Assets.xcassets/News Bundle.imageset/News Bundle@2x.png +++ b/Hotline/Assets.xcassets/News Bundle.imageset/News Bundle@2x.png diff --git a/Hotline/Assets.xcassets/News Bundle.imageset/News Bundle@3x.png b/Hotline/Assets.xcassets/News Bundle.imageset/News Bundle@3x.png Binary files differindex cc7e0a2..f3adb80 100644 --- a/Hotline/Assets.xcassets/News Bundle.imageset/News Bundle@3x.png +++ b/Hotline/Assets.xcassets/News Bundle.imageset/News Bundle@3x.png diff --git a/Hotline/Assets.xcassets/News Category.imageset/News Category.png b/Hotline/Assets.xcassets/News Category.imageset/News Category.png Binary files differindex 5f58a1e..bf20da6 100644 --- a/Hotline/Assets.xcassets/News Category.imageset/News Category.png +++ b/Hotline/Assets.xcassets/News Category.imageset/News Category.png diff --git a/Hotline/Assets.xcassets/News Category.imageset/News Category@2x.png b/Hotline/Assets.xcassets/News Category.imageset/News Category@2x.png Binary files differindex d3eff96..a2a61a0 100644 --- a/Hotline/Assets.xcassets/News Category.imageset/News Category@2x.png +++ b/Hotline/Assets.xcassets/News Category.imageset/News Category@2x.png diff --git a/Hotline/Assets.xcassets/News Category.imageset/News Category@3x.png b/Hotline/Assets.xcassets/News Category.imageset/News Category@3x.png Binary files differindex 371d15a..5a6876e 100644 --- a/Hotline/Assets.xcassets/News Category.imageset/News Category@3x.png +++ b/Hotline/Assets.xcassets/News Category.imageset/News Category@3x.png diff --git a/Hotline/Assets.xcassets/Section Board.imageset/Contents.json b/Hotline/Assets.xcassets/Section Board.imageset/Contents.json new file mode 100644 index 0000000..65b1d04 --- /dev/null +++ b/Hotline/Assets.xcassets/Section Board.imageset/Contents.json @@ -0,0 +1,23 @@ +{ + "images" : [ + { + "filename" : "Section Board.png", + "idiom" : "universal", + "scale" : "1x" + }, + { + "filename" : "Section Board@2x.png", + "idiom" : "universal", + "scale" : "2x" + }, + { + "filename" : "Section Board@3x.png", + "idiom" : "universal", + "scale" : "3x" + } + ], + "info" : { + "author" : "xcode", + "version" : 1 + } +} diff --git a/Hotline/Assets.xcassets/Section Board.imageset/Section Board.png b/Hotline/Assets.xcassets/Section Board.imageset/Section Board.png Binary files differnew file mode 100644 index 0000000..6ebd353 --- /dev/null +++ b/Hotline/Assets.xcassets/Section Board.imageset/Section Board.png diff --git a/Hotline/Assets.xcassets/Section Board.imageset/Section Board@2x.png b/Hotline/Assets.xcassets/Section Board.imageset/Section Board@2x.png Binary files differnew file mode 100644 index 0000000..731fcfe --- /dev/null +++ b/Hotline/Assets.xcassets/Section Board.imageset/Section Board@2x.png diff --git a/Hotline/Assets.xcassets/Section Board.imageset/Section Board@3x.png b/Hotline/Assets.xcassets/Section Board.imageset/Section Board@3x.png Binary files differnew file mode 100644 index 0000000..754ce9b --- /dev/null +++ b/Hotline/Assets.xcassets/Section Board.imageset/Section Board@3x.png diff --git a/Hotline/Assets.xcassets/Section Chat.imageset/Contents.json b/Hotline/Assets.xcassets/Section Chat.imageset/Contents.json new file mode 100644 index 0000000..44d86bd --- /dev/null +++ b/Hotline/Assets.xcassets/Section Chat.imageset/Contents.json @@ -0,0 +1,23 @@ +{ + "images" : [ + { + "filename" : "Section Chat.png", + "idiom" : "universal", + "scale" : "1x" + }, + { + "filename" : "Section Chat@2x.png", + "idiom" : "universal", + "scale" : "2x" + }, + { + "filename" : "Section Chat@3x.png", + "idiom" : "universal", + "scale" : "3x" + } + ], + "info" : { + "author" : "xcode", + "version" : 1 + } +} diff --git a/Hotline/Assets.xcassets/Section Chat.imageset/Section Chat.png b/Hotline/Assets.xcassets/Section Chat.imageset/Section Chat.png Binary files differnew file mode 100644 index 0000000..6c60903 --- /dev/null +++ b/Hotline/Assets.xcassets/Section Chat.imageset/Section Chat.png diff --git a/Hotline/Assets.xcassets/Section Chat.imageset/Section Chat@2x.png b/Hotline/Assets.xcassets/Section Chat.imageset/Section Chat@2x.png Binary files differnew file mode 100644 index 0000000..88ae66a --- /dev/null +++ b/Hotline/Assets.xcassets/Section Chat.imageset/Section Chat@2x.png diff --git a/Hotline/Assets.xcassets/Section Chat.imageset/Section Chat@3x.png b/Hotline/Assets.xcassets/Section Chat.imageset/Section Chat@3x.png Binary files differnew file mode 100644 index 0000000..cb8cc7a --- /dev/null +++ b/Hotline/Assets.xcassets/Section Chat.imageset/Section Chat@3x.png diff --git a/Hotline/Assets.xcassets/Section Files.imageset/Contents.json b/Hotline/Assets.xcassets/Section Files.imageset/Contents.json new file mode 100644 index 0000000..9882c24 --- /dev/null +++ b/Hotline/Assets.xcassets/Section Files.imageset/Contents.json @@ -0,0 +1,23 @@ +{ + "images" : [ + { + "filename" : "Section Files.png", + "idiom" : "universal", + "scale" : "1x" + }, + { + "filename" : "Section Files@2x.png", + "idiom" : "universal", + "scale" : "2x" + }, + { + "filename" : "Section Files@3x.png", + "idiom" : "universal", + "scale" : "3x" + } + ], + "info" : { + "author" : "xcode", + "version" : 1 + } +} diff --git a/Hotline/Assets.xcassets/Section Files.imageset/Section Files.png b/Hotline/Assets.xcassets/Section Files.imageset/Section Files.png Binary files differnew file mode 100644 index 0000000..aed2e76 --- /dev/null +++ b/Hotline/Assets.xcassets/Section Files.imageset/Section Files.png diff --git a/Hotline/Assets.xcassets/Section Files.imageset/Section Files@2x.png b/Hotline/Assets.xcassets/Section Files.imageset/Section Files@2x.png Binary files differnew file mode 100644 index 0000000..11a22a6 --- /dev/null +++ b/Hotline/Assets.xcassets/Section Files.imageset/Section Files@2x.png diff --git a/Hotline/Assets.xcassets/Section Files.imageset/Section Files@3x.png b/Hotline/Assets.xcassets/Section Files.imageset/Section Files@3x.png Binary files differnew file mode 100644 index 0000000..dc4c1d8 --- /dev/null +++ b/Hotline/Assets.xcassets/Section Files.imageset/Section Files@3x.png diff --git a/Hotline/Assets.xcassets/Section News.imageset/Contents.json b/Hotline/Assets.xcassets/Section News.imageset/Contents.json new file mode 100644 index 0000000..f015c81 --- /dev/null +++ b/Hotline/Assets.xcassets/Section News.imageset/Contents.json @@ -0,0 +1,23 @@ +{ + "images" : [ + { + "filename" : "Section News.png", + "idiom" : "universal", + "scale" : "1x" + }, + { + "filename" : "Section News@2x.png", + "idiom" : "universal", + "scale" : "2x" + }, + { + "filename" : "Section News@3x.png", + "idiom" : "universal", + "scale" : "3x" + } + ], + "info" : { + "author" : "xcode", + "version" : 1 + } +} diff --git a/Hotline/Assets.xcassets/Section News.imageset/Section News.png b/Hotline/Assets.xcassets/Section News.imageset/Section News.png Binary files differnew file mode 100644 index 0000000..9285bf7 --- /dev/null +++ b/Hotline/Assets.xcassets/Section News.imageset/Section News.png diff --git a/Hotline/Assets.xcassets/Section News.imageset/Section News@2x.png b/Hotline/Assets.xcassets/Section News.imageset/Section News@2x.png Binary files differnew file mode 100644 index 0000000..b7479d6 --- /dev/null +++ b/Hotline/Assets.xcassets/Section News.imageset/Section News@2x.png diff --git a/Hotline/Assets.xcassets/Section News.imageset/Section News@3x.png b/Hotline/Assets.xcassets/Section News.imageset/Section News@3x.png Binary files differnew file mode 100644 index 0000000..1af6a13 --- /dev/null +++ b/Hotline/Assets.xcassets/Section News.imageset/Section News@3x.png diff --git a/Hotline/Assets.xcassets/Section Servers.imageset/Contents.json b/Hotline/Assets.xcassets/Section Servers.imageset/Contents.json new file mode 100644 index 0000000..4470c6f --- /dev/null +++ b/Hotline/Assets.xcassets/Section Servers.imageset/Contents.json @@ -0,0 +1,23 @@ +{ + "images" : [ + { + "filename" : "Section Servers.png", + "idiom" : "universal", + "scale" : "1x" + }, + { + "filename" : "Section Servers@2x.png", + "idiom" : "universal", + "scale" : "2x" + }, + { + "filename" : "Section Servers@3x.png", + "idiom" : "universal", + "scale" : "3x" + } + ], + "info" : { + "author" : "xcode", + "version" : 1 + } +} diff --git a/Hotline/Assets.xcassets/Section Servers.imageset/Section Servers.png b/Hotline/Assets.xcassets/Section Servers.imageset/Section Servers.png Binary files differnew file mode 100644 index 0000000..84d6fcc --- /dev/null +++ b/Hotline/Assets.xcassets/Section Servers.imageset/Section Servers.png diff --git a/Hotline/Assets.xcassets/Section Servers.imageset/Section Servers@2x.png b/Hotline/Assets.xcassets/Section Servers.imageset/Section Servers@2x.png Binary files differnew file mode 100644 index 0000000..9a9f80a --- /dev/null +++ b/Hotline/Assets.xcassets/Section Servers.imageset/Section Servers@2x.png diff --git a/Hotline/Assets.xcassets/Section Servers.imageset/Section Servers@3x.png b/Hotline/Assets.xcassets/Section Servers.imageset/Section Servers@3x.png Binary files differnew file mode 100644 index 0000000..0750d86 --- /dev/null +++ b/Hotline/Assets.xcassets/Section Servers.imageset/Section Servers@3x.png diff --git a/Hotline/Assets.xcassets/Section Settings.imageset/Contents.json b/Hotline/Assets.xcassets/Section Settings.imageset/Contents.json new file mode 100644 index 0000000..d58685d --- /dev/null +++ b/Hotline/Assets.xcassets/Section Settings.imageset/Contents.json @@ -0,0 +1,23 @@ +{ + "images" : [ + { + "filename" : "Section Settings.png", + "idiom" : "universal", + "scale" : "1x" + }, + { + "filename" : "Section Settings@2x.png", + "idiom" : "universal", + "scale" : "2x" + }, + { + "filename" : "Section Settings@3x.png", + "idiom" : "universal", + "scale" : "3x" + } + ], + "info" : { + "author" : "xcode", + "version" : 1 + } +} diff --git a/Hotline/Assets.xcassets/Section Settings.imageset/Section Settings.png b/Hotline/Assets.xcassets/Section Settings.imageset/Section Settings.png Binary files differnew file mode 100644 index 0000000..0289423 --- /dev/null +++ b/Hotline/Assets.xcassets/Section Settings.imageset/Section Settings.png diff --git a/Hotline/Assets.xcassets/Section Settings.imageset/Section Settings@2x.png b/Hotline/Assets.xcassets/Section Settings.imageset/Section Settings@2x.png Binary files differnew file mode 100644 index 0000000..5a8852a --- /dev/null +++ b/Hotline/Assets.xcassets/Section Settings.imageset/Section Settings@2x.png diff --git a/Hotline/Assets.xcassets/Section Settings.imageset/Section Settings@3x.png b/Hotline/Assets.xcassets/Section Settings.imageset/Section Settings@3x.png Binary files differnew file mode 100644 index 0000000..743f256 --- /dev/null +++ b/Hotline/Assets.xcassets/Section Settings.imageset/Section Settings@3x.png diff --git a/Hotline/Assets.xcassets/Section Users.imageset/Contents.json b/Hotline/Assets.xcassets/Section Users.imageset/Contents.json new file mode 100644 index 0000000..0a699ec --- /dev/null +++ b/Hotline/Assets.xcassets/Section Users.imageset/Contents.json @@ -0,0 +1,23 @@ +{ + "images" : [ + { + "filename" : "Section Users.png", + "idiom" : "universal", + "scale" : "1x" + }, + { + "filename" : "Section Users@2x.png", + "idiom" : "universal", + "scale" : "2x" + }, + { + "filename" : "Section Users@3x.png", + "idiom" : "universal", + "scale" : "3x" + } + ], + "info" : { + "author" : "xcode", + "version" : 1 + } +} diff --git a/Hotline/Assets.xcassets/Section Users.imageset/Section Users.png b/Hotline/Assets.xcassets/Section Users.imageset/Section Users.png Binary files differnew file mode 100644 index 0000000..f8c6695 --- /dev/null +++ b/Hotline/Assets.xcassets/Section Users.imageset/Section Users.png diff --git a/Hotline/Assets.xcassets/Section Users.imageset/Section Users@2x.png b/Hotline/Assets.xcassets/Section Users.imageset/Section Users@2x.png Binary files differnew file mode 100644 index 0000000..65752e7 --- /dev/null +++ b/Hotline/Assets.xcassets/Section Users.imageset/Section Users@2x.png diff --git a/Hotline/Assets.xcassets/Section Users.imageset/Section Users@3x.png b/Hotline/Assets.xcassets/Section Users.imageset/Section Users@3x.png Binary files differnew file mode 100644 index 0000000..be6312d --- /dev/null +++ b/Hotline/Assets.xcassets/Section Users.imageset/Section Users@3x.png diff --git a/Hotline/Assets.xcassets/Server Large.imageset/Server Large.png b/Hotline/Assets.xcassets/Server Large.imageset/Server Large.png Binary files differindex 0b5fbb7..5c416d4 100644 --- a/Hotline/Assets.xcassets/Server Large.imageset/Server Large.png +++ b/Hotline/Assets.xcassets/Server Large.imageset/Server Large.png diff --git a/Hotline/Assets.xcassets/Server Large.imageset/Server Large@2x.png b/Hotline/Assets.xcassets/Server Large.imageset/Server Large@2x.png Binary files differindex d99e32c..7de0b7e 100644 --- a/Hotline/Assets.xcassets/Server Large.imageset/Server Large@2x.png +++ b/Hotline/Assets.xcassets/Server Large.imageset/Server Large@2x.png diff --git a/Hotline/Assets.xcassets/Server Large.imageset/Server Large@3x.png b/Hotline/Assets.xcassets/Server Large.imageset/Server Large@3x.png Binary files differindex ce32a16..0e76c15 100644 --- a/Hotline/Assets.xcassets/Server Large.imageset/Server Large@3x.png +++ b/Hotline/Assets.xcassets/Server Large.imageset/Server Large@3x.png diff --git a/Hotline/Assets.xcassets/Server Message.imageset/4016.png b/Hotline/Assets.xcassets/Server Message.imageset/4016.png Binary files differdeleted file mode 100644 index a11fbea..0000000 --- a/Hotline/Assets.xcassets/Server Message.imageset/4016.png +++ /dev/null diff --git a/Hotline/Assets.xcassets/Server Message.imageset/4016@2x.png b/Hotline/Assets.xcassets/Server Message.imageset/4016@2x.png Binary files differdeleted file mode 100644 index ef90260..0000000 --- a/Hotline/Assets.xcassets/Server Message.imageset/4016@2x.png +++ /dev/null diff --git a/Hotline/Assets.xcassets/Server Message.imageset/4016@3x.png b/Hotline/Assets.xcassets/Server Message.imageset/4016@3x.png Binary files differdeleted file mode 100644 index a2646ee..0000000 --- a/Hotline/Assets.xcassets/Server Message.imageset/4016@3x.png +++ /dev/null diff --git a/Hotline/Assets.xcassets/Server Message.imageset/Contents.json b/Hotline/Assets.xcassets/Server Message.imageset/Contents.json index 7011bdf..ab3e25e 100644 --- a/Hotline/Assets.xcassets/Server Message.imageset/Contents.json +++ b/Hotline/Assets.xcassets/Server Message.imageset/Contents.json @@ -1,17 +1,17 @@ { "images" : [ { - "filename" : "4016.png", + "filename" : "Server Message.png", "idiom" : "universal", "scale" : "1x" }, { - "filename" : "4016@2x.png", + "filename" : "Server Message@2x.png", "idiom" : "universal", "scale" : "2x" }, { - "filename" : "4016@3x.png", + "filename" : "Server Message@3x.png", "idiom" : "universal", "scale" : "3x" } diff --git a/Hotline/Assets.xcassets/Server Message.imageset/Server Message.png b/Hotline/Assets.xcassets/Server Message.imageset/Server Message.png Binary files differnew file mode 100644 index 0000000..4640776 --- /dev/null +++ b/Hotline/Assets.xcassets/Server Message.imageset/Server Message.png diff --git a/Hotline/Assets.xcassets/Server Message.imageset/Server Message@2x.png b/Hotline/Assets.xcassets/Server Message.imageset/Server Message@2x.png Binary files differnew file mode 100644 index 0000000..4f1fddc --- /dev/null +++ b/Hotline/Assets.xcassets/Server Message.imageset/Server Message@2x.png diff --git a/Hotline/Assets.xcassets/Server Message.imageset/Server Message@3x.png b/Hotline/Assets.xcassets/Server Message.imageset/Server Message@3x.png Binary files differnew file mode 100644 index 0000000..c7a5a62 --- /dev/null +++ b/Hotline/Assets.xcassets/Server Message.imageset/Server Message@3x.png diff --git a/Hotline/Assets.xcassets/Server.imageset/Server.png b/Hotline/Assets.xcassets/Server.imageset/Server.png Binary files differindex 9395a0d..6e43e66 100644 --- a/Hotline/Assets.xcassets/Server.imageset/Server.png +++ b/Hotline/Assets.xcassets/Server.imageset/Server.png diff --git a/Hotline/Assets.xcassets/Server.imageset/Server@2x.png b/Hotline/Assets.xcassets/Server.imageset/Server@2x.png Binary files differindex d206fbd..c12c871 100644 --- a/Hotline/Assets.xcassets/Server.imageset/Server@2x.png +++ b/Hotline/Assets.xcassets/Server.imageset/Server@2x.png diff --git a/Hotline/Assets.xcassets/Server.imageset/Server@3x.png b/Hotline/Assets.xcassets/Server.imageset/Server@3x.png Binary files differindex 6341189..a04cf58 100644 --- a/Hotline/Assets.xcassets/Server.imageset/Server@3x.png +++ b/Hotline/Assets.xcassets/Server.imageset/Server@3x.png diff --git a/Hotline/Assets.xcassets/Tracker.imageset/Tracker.png b/Hotline/Assets.xcassets/Tracker.imageset/Tracker.png Binary files differindex 6fc5957..fed290f 100644 --- a/Hotline/Assets.xcassets/Tracker.imageset/Tracker.png +++ b/Hotline/Assets.xcassets/Tracker.imageset/Tracker.png diff --git a/Hotline/Assets.xcassets/Tracker.imageset/Tracker@2x.png b/Hotline/Assets.xcassets/Tracker.imageset/Tracker@2x.png Binary files differindex ba3b2bb..658829d 100644 --- a/Hotline/Assets.xcassets/Tracker.imageset/Tracker@2x.png +++ b/Hotline/Assets.xcassets/Tracker.imageset/Tracker@2x.png diff --git a/Hotline/Assets.xcassets/Tracker.imageset/Tracker@3x.png b/Hotline/Assets.xcassets/Tracker.imageset/Tracker@3x.png Binary files differindex 32e9056..5f79f9d 100644 --- a/Hotline/Assets.xcassets/Tracker.imageset/Tracker@3x.png +++ b/Hotline/Assets.xcassets/Tracker.imageset/Tracker@3x.png diff --git a/Hotline/Assets.xcassets/User.imageset/User.png b/Hotline/Assets.xcassets/User.imageset/User.png Binary files differindex 79b64a8..6a1a8c3 100644 --- a/Hotline/Assets.xcassets/User.imageset/User.png +++ b/Hotline/Assets.xcassets/User.imageset/User.png diff --git a/Hotline/Assets.xcassets/User.imageset/User@2x.png b/Hotline/Assets.xcassets/User.imageset/User@2x.png Binary files differindex 2ffd33c..4c025f7 100644 --- a/Hotline/Assets.xcassets/User.imageset/User@2x.png +++ b/Hotline/Assets.xcassets/User.imageset/User@2x.png diff --git a/Hotline/Assets.xcassets/User.imageset/User@3x.png b/Hotline/Assets.xcassets/User.imageset/User@3x.png Binary files differindex 3e30488..58f9167 100644 --- a/Hotline/Assets.xcassets/User.imageset/User@3x.png +++ b/Hotline/Assets.xcassets/User.imageset/User@3x.png diff --git a/Hotline/Models/Hotline.swift b/Hotline/Models/Hotline.swift index 70073c2..c57434a 100644 --- a/Hotline/Models/Hotline.swift +++ b/Hotline/Models/Hotline.swift @@ -667,6 +667,10 @@ class Hotline: Equatable, HotlineClientDelegate, HotlineFileClientDelegate { } @MainActor func downloadBanner(force: Bool = false) { + guard self.serverVersion >= 150 else { + return + } + if self.bannerClient != nil || force { self.bannerClient?.delegate = nil self.bannerClient?.cancel() diff --git a/Hotline/Shared/HotlinePanel.swift b/Hotline/Shared/HotlinePanel.swift index ee881a2..2db1038 100644 --- a/Hotline/Shared/HotlinePanel.swift +++ b/Hotline/Shared/HotlinePanel.swift @@ -1,7 +1,7 @@ import Cocoa import SwiftUI -fileprivate let HOTLINE_PANEL_SIZE: CGSize = CGSizeMake(476, 114) +fileprivate let HOTLINE_PANEL_SIZE: CGSize = CGSizeMake(468, 114 - 10) class HotlinePanel: NSPanel { init(_ view: HotlinePanelView) { diff --git a/Hotline/macOS/FilesView.swift b/Hotline/macOS/FilesView.swift index 7546f2a..2afa1a8 100644 --- a/Hotline/macOS/FilesView.swift +++ b/Hotline/macOS/FilesView.swift @@ -75,7 +75,7 @@ struct FileView: View { .opacity(file.isUnavailable ? 0.5 : 1.0) if file.isFolder && loading { - ProgressView().controlSize(.small).padding([.leading, .trailing], 1) + ProgressView().controlSize(.small).padding([.leading, .trailing], 5) } Spacer() if !file.isUnavailable { diff --git a/Hotline/macOS/HotlinePanelView.swift b/Hotline/macOS/HotlinePanelView.swift index 2d4c253..991946e 100644 --- a/Hotline/macOS/HotlinePanelView.swift +++ b/Hotline/macOS/HotlinePanelView.swift @@ -9,12 +9,15 @@ struct HotlinePanelView: View { Image(nsImage: ApplicationState.shared.activeServerBanner ?? NSImage(named: "Default Banner")!) .interpolation(.high) .resizable() - .scaledToFit() + .scaledToFill() .frame(width: 468, height: 60) - .clipShape(RoundedRectangle(cornerRadius: 6.0)) - .padding([.top, .leading, .trailing], 4) + .frame(minWidth: 468, maxWidth: 468, minHeight: 60, maxHeight: 60) + .clipped() + .background(.black) +// .clipShape(RoundedRectangle(cornerRadius: 6.0)) +// .padding([.top, .leading, .trailing], 4) - HStack(spacing: 16) { + HStack(spacing: 10) { Button { if NSEvent.modifierFlags.contains(.option) { openWindow(id: "server") @@ -24,25 +27,24 @@ struct HotlinePanelView: View { } } label: { - Image(systemName: "globe.americas.fill") + Image("Section Servers") .resizable() .scaledToFit() } .buttonStyle(.plain) - .frame(width: 18, height: 18) + .frame(width: 20, height: 20) .help("Hotline Servers") Button { ApplicationState.shared.activeServerState?.selection = .chat } label: { - Image(systemName: "bubble.fill") + Image("Section Chat") .resizable() .scaledToFit() } .buttonStyle(.plain) - .frame(width: 18, height: 18) - .opacity(ApplicationState.shared.activeServerState == nil ? 0.5 : 1.0) + .frame(width: 20, height: 20) .disabled(ApplicationState.shared.activeServerState == nil) .help("Public Chat") @@ -50,72 +52,88 @@ struct HotlinePanelView: View { ApplicationState.shared.activeServerState?.selection = .board } label: { - Image(systemName: "pin.fill") + Image("Section Board") .resizable() .scaledToFit() } .buttonStyle(.plain) - .frame(width: 18, height: 18) - .opacity(ApplicationState.shared.activeServerState == nil ? 0.5 : 1.0) + .frame(width: 20, height: 20) .disabled(ApplicationState.shared.activeServerState == nil) .help("Message Board") - Button { - ApplicationState.shared.activeServerState?.selection = .news - } - label: { - Image(systemName: "newspaper.fill") - .resizable() - .scaledToFit() + if let activeHotline = ApplicationState.shared.activeHotline, + activeHotline.serverVersion >= 151 { + Button { + ApplicationState.shared.activeServerState?.selection = .news + } + label: { + Image("Section News") + .resizable() + .scaledToFit() + } + .buttonStyle(.plain) + .frame(width: 20, height: 20) + .disabled(ApplicationState.shared.activeServerState == nil) + .help("News") } - .buttonStyle(.plain) - .frame(width: 18, height: 18) - .opacity(ApplicationState.shared.activeServerState == nil ? 0.5 : 1.0) - .disabled(ApplicationState.shared.activeServerState == nil) - .help("News") Button { ApplicationState.shared.activeServerState?.selection = .files } label: { - Image(systemName: "folder.fill") + Image("Section Files") .resizable() .scaledToFit() } .buttonStyle(.plain) - .frame(width: 18, height: 18) - .opacity(ApplicationState.shared.activeServerState == nil ? 0.5 : 1.0) + .frame(width: 20, height: 20) .disabled(ApplicationState.shared.activeServerState == nil) .help("Files") - Button { - ApplicationState.shared.activeServerState?.selection = .accounts - } - label: { - Image(systemName: "person.2.fill") - .resizable() - .scaledToFit() - } - .buttonStyle(.plain) - .frame(width: 18, height: 18) - .opacity(ApplicationState.shared.activeServerState == nil ? 0.5 : 1.0) - .disabled(ApplicationState.shared.activeServerState == nil || ApplicationState.shared.activeHotline?.access?.contains(.canOpenUsers) == false) - .help("Accounts") - Spacer() + if ApplicationState.shared.activeHotline?.access?.contains(.canOpenUsers) == true { + Button { + ApplicationState.shared.activeServerState?.selection = .accounts + } + label: { + Image("Section Users") + .resizable() + .scaledToFit() + } + .buttonStyle(.plain) + .frame(width: 20, height: 20) + .disabled(ApplicationState.shared.activeServerState == nil) + .help("Accounts") + } + SettingsLink(label: { - Image(systemName: "gearshape.fill") + Image("Section Settings") .resizable() .scaledToFit() }) .buttonStyle(.plain) - .frame(width: 18, height: 18) + .frame(width: 20, height: 20) .help("Settings") } - .padding(.top, 16) - .padding(.bottom, 16) - .padding([.leading, .trailing], 16) + .padding(.top, 12) + .padding(.bottom, 12) + .padding([.leading, .trailing], 12) + +// GroupBox { +// HStack(spacing: 0) { +// Text("Not Connected") +// .font(.system(size: 10.0)) +// .lineLimit(1) +// .truncationMode(.tail) +// .opacity(0.5) +// .padding(.vertical, 0.0) +// .padding(.horizontal, 4.0) +// +// Spacer() +// } +// } +// .padding([.leading, .bottom, .trailing], 4.0) } // .frame(width: 468) // .background(colorScheme == .dark ? .black : .white) diff --git a/Hotline/macOS/MessageBoardEditorView.swift b/Hotline/macOS/MessageBoardEditorView.swift index 1b49f4e..029616f 100644 --- a/Hotline/macOS/MessageBoardEditorView.swift +++ b/Hotline/macOS/MessageBoardEditorView.swift @@ -48,11 +48,11 @@ struct MessageBoardEditorView: View { Spacer() - Image("Message Board Post") - .resizable() - .scaledToFit() - .frame(width: 16, height: 16) - .padding(.trailing, 6) +// Image("Message Board Post") +// .resizable() +// .scaledToFit() +// .frame(width: 16, height: 16) +// .padding(.trailing, 6) Text("New Post") .fontWeight(.semibold) diff --git a/Hotline/macOS/NewsEditorView.swift b/Hotline/macOS/NewsEditorView.swift index a6f72ec..f69c846 100644 --- a/Hotline/macOS/NewsEditorView.swift +++ b/Hotline/macOS/NewsEditorView.swift @@ -88,7 +88,7 @@ struct NewsEditorView: View { } .buttonStyle(.plain) .frame(width: 22, height: 22) - .help("Post to Newsgroup") + .help("Post News") .disabled(title.isEmpty || text.isEmpty) } } diff --git a/Hotline/macOS/NewsItemView.swift b/Hotline/macOS/NewsItemView.swift index 5cd9ce4..9614663 100644 --- a/Hotline/macOS/NewsItemView.swift +++ b/Hotline/macOS/NewsItemView.swift @@ -79,29 +79,40 @@ struct NewsItemView: View { Spacer() - if news.type == .bundle || news.type == .category { - ZStack { -// Text("^[\(news.count) \(news.type == .bundle ? "Category" : "Post")](inflect: true)") - Text("\(news.count)") - .foregroundStyle(.clear) -// .font(.caption) - .lineLimit(1) - .padding([.leading, .trailing], 8) - .padding([.top, .bottom], 2) - .background(.secondary) - .clipShape(Capsule()) - - Text("\(news.count)") - .foregroundStyle(.white) -// .font(.caption) - .lineLimit(1) - .padding([.leading, .trailing], 8) - .padding([.top, .bottom], 2) - .blendMode(.destinationOut) - } - .drawingGroup(opaque: false) + if news.type == .category && news.count > 0 { + Text("^[\(news.count) Post](inflect: true)") + .lineLimit(1) + .foregroundStyle(.secondary) + .padding(.trailing, 8) } - if news.type == .article && news.articleUsername != nil { +// if news.type == .bundle { +// Text("\(news.count)") +// .lineLimit(1) +// .foregroundStyle(.tertiary) +// .padding(.trailing, 8) + +// ZStack { +// Text("^[\(news.count) \(news.type == .bundle ? "Category" : "Post")](inflect: true)") +// Text("\(news.count)") +// .foregroundStyle(.clear) +//// .font(.caption) +// .lineLimit(1) +// .padding([.leading, .trailing], 8) +// .padding([.top, .bottom], 2) +// .background(.secondary) +// .clipShape(Capsule()) +// +// Text("\(news.count)") +// .foregroundStyle(.white) +//// .font(.caption) +// .lineLimit(1) +// .padding([.leading, .trailing], 8) +// .padding([.top, .bottom], 2) +// .blendMode(.destinationOut) +// } +// .drawingGroup(opaque: false) +// } + else if news.type == .article && news.articleUsername != nil { if let d = news.articleDate { Text(NewsItemView.relativeDateFormatter.localizedString(for: d, relativeTo: Date.now)) .lineLimit(1) diff --git a/Hotline/macOS/NewsView.swift b/Hotline/macOS/NewsView.swift index 4469585..e4f4d21 100644 --- a/Hotline/macOS/NewsView.swift +++ b/Hotline/macOS/NewsView.swift @@ -138,7 +138,7 @@ struct NewsView: View { } label: { Image(systemName: "arrow.clockwise") } - .help("Reload Newsgroup") + .help("Reload News") .disabled(loading) } } diff --git a/Hotline/macOS/ServerView.swift b/Hotline/macOS/ServerView.swift index 7349d95..5e3678f 100644 --- a/Hotline/macOS/ServerView.swift +++ b/Hotline/macOS/ServerView.swift @@ -58,28 +58,35 @@ struct ServerMenuItem: Identifiable, Hashable { } struct ListItemView: View { - let icon: String + @Environment(\.controlActiveState) private var controlActiveState + + let icon: String? let title: String let unread: Bool var body: some View { - HStack { - Image(systemName: icon) + HStack(spacing: 5) { + if let i = icon { + Image(i) .resizable() + // .renderingMode(.template) .scaledToFit() - .frame(width: 16, height: 16) - .padding(.leading, 4) - Text(title) - .lineLimit(1) - .truncationMode(.tail) - Spacer() - if unread { - Circle() - .frame(width: 6, height: 6) - .padding(EdgeInsets(top: 0, leading: 8, bottom: 0, trailing: 2)) - .opacity(0.5) - } + .frame(width: 20, height: 20) +// .padding(.leading, 2) + .opacity(controlActiveState == .inactive ? 0.5 : 1.0) } + + Text(title) + .lineLimit(1) + .truncationMode(.tail) + Spacer() + if unread { + Circle() + .frame(width: 6, height: 6) + .padding(EdgeInsets(top: 0, leading: 8, bottom: 0, trailing: 2)) + .opacity(0.5) + } + } } } @@ -148,17 +155,17 @@ struct ServerView: View { @Binding var server: Server static var menuItems: [ServerMenuItem] = [ - ServerMenuItem(type: .chat, name: "Chat", image: "bubble"), - ServerMenuItem(type: .board, name: "Board", image: "pin"), - ServerMenuItem(type: .news, name: "News", image: "newspaper"), - ServerMenuItem(type: .files, name: "Files", image: "folder"), - ServerMenuItem(type: .accounts, name: "Accounts", image: "person.2"), + ServerMenuItem(type: .chat, name: "Chat", image: "Section Chat"), + ServerMenuItem(type: .board, name: "Board", image: "Section Board"), + ServerMenuItem(type: .news, name: "News", image: "Section News"), + ServerMenuItem(type: .files, name: "Files", image: "Section Files"), + ServerMenuItem(type: .accounts, name: "Accounts", image: "Section Users"), ] static var classicMenuItems: [ServerMenuItem] = [ - ServerMenuItem(type: .chat, name: "Chat", image: "bubble"), - ServerMenuItem(type: .board, name: "Board", image: "pin"), - ServerMenuItem(type: .files, name: "Files", image: "folder"), + ServerMenuItem(type: .chat, name: "Chat", image: "Section Chat"), + ServerMenuItem(type: .board, name: "Board", image: "Section Board"), + ServerMenuItem(type: .files, name: "Files", image: "Section Files"), ] enum FocusFields { @@ -211,7 +218,7 @@ struct ServerView: View { .resizable() .scaledToFit() - .frame(width: 24) + .frame(width: 28) .opacity(controlActiveState == .inactive ? 0.4 : 1.0) } } @@ -377,10 +384,14 @@ struct ServerView: View { } if model.transfers.count > 0 { + Divider() + self.transfersSection } if model.users.count > 0 { + Divider() + self.usersSection } } @@ -397,26 +408,28 @@ struct ServerView: View { } var transfersSection: some View { - Section("Transfers") { +// Section("Transfers") { ForEach(model.transfers) { transfer in TransferItemView(transfer: transfer) } - } +// } } var usersSection: some View { - Section("\(model.users.count) Online") { +// Section("\(model.users.count) Online") { ForEach(model.users) { user in - HStack { + HStack(spacing: 5) { if let iconImage = Hotline.getClassicIcon(Int(user.iconID)) { Image(nsImage: iconImage) .frame(width: 16, height: 16) - .padding(.leading, 4) + .padding(.leading, 2) + .padding(.trailing, 2) } else { Image("User") .frame(width: 16, height: 16) - .padding(.leading, 4) + .padding(.leading, 2) + .padding(.trailing, 2) } Text(user.name) @@ -435,7 +448,7 @@ struct ServerView: View { .opacity(controlActiveState == .inactive ? 0.5 : 1.0) .tag(ServerNavigationType.user(userID: user.id)) } - } +// } } var serverView: some View { @@ -453,7 +466,7 @@ struct ServerView: View { case .news: NewsView() .navigationTitle(model.serverTitle) - .navigationSubtitle("Newsgroup") + .navigationSubtitle("News") .navigationSplitViewColumnWidth(min: 250, ideal: 500) case .board: MessageBoardView() |