mirror of
https://github.com/Dimillian/IceCubesApp.git
synced 2024-11-23 00:40:59 +00:00
Add a setting to disable secondary column on iPad / macOS
This commit is contained in:
parent
d7c2e65479
commit
c5e43394c8
18 changed files with 58 additions and 1 deletions
|
@ -114,7 +114,8 @@ struct IceCubesApp: App {
|
|||
}
|
||||
}
|
||||
if proxy.frame(in: .global).width > (.maxColumnWidth + .secondaryColumnWidth),
|
||||
appAccountsManager.currentClient.isAuth
|
||||
appAccountsManager.currentClient.isAuth,
|
||||
userPreferences.showiPadSecondaryColumn
|
||||
{
|
||||
Divider().edgesIgnoringSafeArea(.all)
|
||||
NotificationsTab(popToRootTab: $popToRootTab, lockedType: nil)
|
||||
|
|
|
@ -85,10 +85,19 @@ struct DisplaySettingsView: View {
|
|||
Text("settings.display.font.scaling-\(String(format: "%.1f", userPreferences.fontSizeScale))")
|
||||
.font(.scaledBody)
|
||||
}
|
||||
.alignmentGuide(.listRowSeparatorLeading) { d in
|
||||
d[.leading]
|
||||
}
|
||||
Toggle("settings.display.translate-button", isOn: $userPreferences.showTranslateButton)
|
||||
}
|
||||
.listRowBackground(theme.primaryBackgroundColor)
|
||||
|
||||
if UIDevice.current.userInterfaceIdiom == .pad {
|
||||
Section("settings.display.section.ipad") {
|
||||
Toggle("settings.display.show-ipad-column", isOn: $userPreferences.showiPadSecondaryColumn)
|
||||
}
|
||||
}
|
||||
|
||||
Section {
|
||||
Button {
|
||||
theme.followSystemColorScheme = true
|
||||
|
|
|
@ -155,6 +155,9 @@
|
|||
"settings.haptic.tab-selection" = "Tab Selection";
|
||||
"settings.haptic.buttons" = "Button Press";
|
||||
|
||||
"settings.display.section.ipad" = "iPad";
|
||||
"settings.display.show-ipad-column" = "Enable secondary column";
|
||||
|
||||
// MARK: Tabs
|
||||
"tab.explore" = "Exploreu";
|
||||
"tab.federated" = "Federat";
|
||||
|
|
|
@ -153,6 +153,9 @@
|
|||
"settings.haptic.tab-selection" = "Tabauswahl";
|
||||
"settings.haptic.buttons" = "Knopfdruck";
|
||||
|
||||
"settings.display.section.ipad" = "iPad";
|
||||
"settings.display.show-ipad-column" = "Enable secondary column";
|
||||
|
||||
"enum.expand-media.show" = "Alle zeigen";
|
||||
"enum.expand-media.hide" = "Alle ausblenden";
|
||||
"enum.expand-media.hide-sensitive" = "Sensible ausblenden";
|
||||
|
|
|
@ -157,6 +157,9 @@
|
|||
"settings.haptic.tab-selection" = "Tab Selection";
|
||||
"settings.haptic.buttons" = "Button Press";
|
||||
|
||||
"settings.display.section.ipad" = "iPad";
|
||||
"settings.display.show-ipad-column" = "Enable secondary column";
|
||||
|
||||
// MARK: Tabs
|
||||
"tab.explore" = "Explore";
|
||||
"tab.federated" = "Federated";
|
||||
|
|
|
@ -157,6 +157,9 @@
|
|||
"settings.haptic.tab-selection" = "Tab Selection";
|
||||
"settings.haptic.buttons" = "Button Press";
|
||||
|
||||
"settings.display.section.ipad" = "iPad";
|
||||
"settings.display.show-ipad-column" = "Enable secondary column";
|
||||
|
||||
// MARK: Tabs
|
||||
"tab.explore" = "Explore";
|
||||
"tab.federated" = "Federated";
|
||||
|
|
|
@ -153,6 +153,9 @@
|
|||
"settings.haptic.tab-selection" = "Tab Selection";
|
||||
"settings.haptic.buttons" = "Button Press";
|
||||
|
||||
"settings.display.section.ipad" = "iPad";
|
||||
"settings.display.show-ipad-column" = "Enable secondary column";
|
||||
|
||||
"enum.expand-media.show" = "Siempre";
|
||||
"enum.expand-media.hide" = "Nunca";
|
||||
"enum.expand-media.hide-sensitive" = "Ocultar contenido sensible";
|
||||
|
|
|
@ -156,6 +156,9 @@
|
|||
"settings.haptic.tab-selection" = "Sélection d'onglet";
|
||||
"settings.haptic.buttons" = "Appui bouton";
|
||||
|
||||
"settings.display.section.ipad" = "iPad";
|
||||
"settings.display.show-ipad-column" = "Enable secondary column";
|
||||
|
||||
// MARK: Tabs
|
||||
"tab.explore" = "Explorer";
|
||||
"tab.federated" = "Fédéré";
|
||||
|
|
|
@ -156,6 +156,9 @@
|
|||
"settings.haptic.tab-selection" = "Selezione Tab";
|
||||
"settings.haptic.buttons" = "Pressione dei bottoni";
|
||||
|
||||
"settings.display.section.ipad" = "iPad";
|
||||
"settings.display.show-ipad-column" = "Enable secondary column";
|
||||
|
||||
// MARK: Tabs
|
||||
"tab.explore" = "Esplora";
|
||||
"tab.federated" = "Federazione";
|
||||
|
|
|
@ -156,6 +156,9 @@
|
|||
"settings.haptic.tab-selection" = "タブセレクト";
|
||||
"settings.haptic.buttons" = "ボタン操作時";
|
||||
|
||||
"settings.display.section.ipad" = "iPad";
|
||||
"settings.display.show-ipad-column" = "Enable secondary column";
|
||||
|
||||
// MARK: Tabs
|
||||
"tab.explore" = "エクスプローラー";
|
||||
"tab.federated" = "連合";
|
||||
|
|
|
@ -156,6 +156,9 @@
|
|||
"settings.haptic.tab-selection" = "하단 탭 바를 누를 때";
|
||||
"settings.haptic.buttons" = "버튼을 누를 때";
|
||||
|
||||
"settings.display.section.ipad" = "iPad";
|
||||
"settings.display.show-ipad-column" = "Enable secondary column";
|
||||
|
||||
// MARK: Tabs
|
||||
"tab.explore" = "둘러보기";
|
||||
"tab.federated" = "연합";
|
||||
|
|
|
@ -156,6 +156,9 @@
|
|||
"settings.haptic.tab-selection" = "Tab Selection";
|
||||
"settings.haptic.buttons" = "Button Press";
|
||||
|
||||
"settings.display.section.ipad" = "iPad";
|
||||
"settings.display.show-ipad-column" = "Enable secondary column";
|
||||
|
||||
// MARK: Tabs
|
||||
"tab.explore" = "Utforsk";
|
||||
"tab.federated" = "Federert";
|
||||
|
|
|
@ -153,6 +153,9 @@
|
|||
"settings.haptic.tab-selection" = "Tabselectie";
|
||||
"settings.haptic.buttons" = "Knoppen";
|
||||
|
||||
"settings.display.section.ipad" = "iPad";
|
||||
"settings.display.show-ipad-column" = "Enable secondary column";
|
||||
|
||||
// MARK: Tabs
|
||||
"tab.explore" = "Ontdekken";
|
||||
"tab.federated" = "Gefedereerd";
|
||||
|
|
|
@ -156,6 +156,9 @@
|
|||
"settings.haptic.tab-selection" = "Wybór zakładki";
|
||||
"settings.haptic.buttons" = "Naciśnięcie przycisku";
|
||||
|
||||
"settings.display.section.ipad" = "iPad";
|
||||
"settings.display.show-ipad-column" = "Enable secondary column";
|
||||
|
||||
// MARK: Tabs
|
||||
"tab.explore" = "Odkrywaj";
|
||||
"tab.federated" = "Globalny";
|
||||
|
|
|
@ -156,6 +156,9 @@
|
|||
"settings.haptic.tab-selection" = "Tab Selection";
|
||||
"settings.haptic.buttons" = "Button Press";
|
||||
|
||||
"settings.display.section.ipad" = "iPad";
|
||||
"settings.display.show-ipad-column" = "Enable secondary column";
|
||||
|
||||
// MARK: Tabs
|
||||
"tab.explore" = "Explorar";
|
||||
"tab.federated" = "Linha global";
|
||||
|
|
|
@ -156,6 +156,9 @@
|
|||
"settings.haptic.tab-selection" = "Tab Selection";
|
||||
"settings.haptic.buttons" = "Button Press";
|
||||
|
||||
"settings.display.section.ipad" = "iPad";
|
||||
"settings.display.show-ipad-column" = "Enable secondary column";
|
||||
|
||||
// MARK: Tabs
|
||||
"tab.explore" = "Keşfet";
|
||||
"tab.federated" = "Birleştirilmiş";
|
||||
|
|
|
@ -156,6 +156,9 @@
|
|||
"settings.display.font.custom" = "自定义";
|
||||
"settings.display.font.scaling-%@" = "字体缩放:%@";
|
||||
|
||||
"settings.display.section.ipad" = "iPad";
|
||||
"settings.display.show-ipad-column" = "Enable secondary column";
|
||||
|
||||
// MARK: Tabs
|
||||
"tab.explore" = "探索";
|
||||
"tab.federated" = "跨站";
|
||||
|
|
|
@ -36,6 +36,8 @@ public class UserPreferences: ObservableObject {
|
|||
@AppStorage("haptic_timeline") public var hapticTimelineEnabled = true
|
||||
@AppStorage("haptic_button_press") public var hapticButtonPressEnabled = true
|
||||
|
||||
@AppStorage("show_second_column_ipad") public var showiPadSecondaryColumn = true
|
||||
|
||||
public var postVisibility: Models.Visibility {
|
||||
if useInstanceContentSettings {
|
||||
return serverPreferences?.postVisibility ?? .pub
|
||||
|
|
Loading…
Reference in a new issue