Skip to content

Commit 01ede7e

Browse files
committed
Merge branch 'release/2.6.5'
2 parents c7b8b2c + cff9da0 commit 01ede7e

File tree

84 files changed

+367
-386
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

84 files changed

+367
-386
lines changed

Cryptomator.xcodeproj/project.pbxproj

+2-2
Original file line numberDiff line numberDiff line change
@@ -3320,7 +3320,7 @@
33203320
GCC_WARN_UNUSED_FUNCTION = YES;
33213321
GCC_WARN_UNUSED_VARIABLE = YES;
33223322
IPHONEOS_DEPLOYMENT_TARGET = 14.0;
3323-
MARKETING_VERSION = 2.6.4;
3323+
MARKETING_VERSION = 2.6.5;
33243324
MTL_ENABLE_DEBUG_INFO = INCLUDE_SOURCE;
33253325
MTL_FAST_MATH = YES;
33263326
ONLY_ACTIVE_ARCH = YES;
@@ -3382,7 +3382,7 @@
33823382
GCC_WARN_UNUSED_FUNCTION = YES;
33833383
GCC_WARN_UNUSED_VARIABLE = YES;
33843384
IPHONEOS_DEPLOYMENT_TARGET = 14.0;
3385-
MARKETING_VERSION = 2.6.4;
3385+
MARKETING_VERSION = 2.6.5;
33863386
MTL_ENABLE_DEBUG_INFO = NO;
33873387
MTL_FAST_MATH = YES;
33883388
OTHER_SWIFT_FLAGS = "-Xfrontend -warn-long-expression-type-checking=200 -Xfrontend -warn-long-function-bodies=200";

Cryptomator/AddVault/AddVaultSuccessViewController.swift

+1-1
Original file line numberDiff line numberDiff line change
@@ -68,7 +68,7 @@ private class VaultSuccessFooterView: UITableViewHeaderFooterView {
6868

6969
let text = NSMutableAttributedString(string: LocalizedString.getValue("addVault.success.footer"), attributes: [NSAttributedString.Key.foregroundColor: UIColor.secondaryLabel])
7070
text.append(NSAttributedString(string: " "))
71-
let learnMoreLink = NSAttributedString(string: LocalizedString.getValue("common.footer.learnMore"), attributes: [NSAttributedString.Key.link: URL(string: "https://docs.cryptomator.org/en/latest/ios/access-vault/#enable-cryptomator-in-files-app")!])
71+
let learnMoreLink = NSAttributedString(string: LocalizedString.getValue("common.footer.learnMore"), attributes: [NSAttributedString.Key.link: URL(string: "https://docs.cryptomator.org/ios/access-vault/#enable-cryptomator-in-files-app")!])
7272
text.append(learnMoreLink)
7373
textView.attributedText = text
7474
textView.isUserInteractionEnabled = true

Cryptomator/AddVault/LocalVault/LocalFileSystemAuthenticationViewModel.swift

+1-1
Original file line numberDiff line numberDiff line change
@@ -132,7 +132,7 @@ class LocalFileSystemAuthenticationInfoFooterViewModel: AttributedTextHeaderFoot
132132
let infoText = LocalizedString.getValue("localFileSystemAuthentication.info.footer")
133133
let text = NSMutableAttributedString(string: infoText)
134134
text.append(NSAttributedString(string: " "))
135-
let learnMoreLink = NSAttributedString(string: LocalizedString.getValue("common.footer.learnMore"), attributes: [NSAttributedString.Key.link: URL(string: "https://docs.cryptomator.org/en/latest/ios/cloud-management/#other-file-provider")!])
135+
let learnMoreLink = NSAttributedString(string: LocalizedString.getValue("common.footer.learnMore"), attributes: [NSAttributedString.Key.link: URL(string: "https://docs.cryptomator.org/ios/cloud-management/#other-file-provider")!])
136136
text.append(learnMoreLink)
137137
super.init(attributedText: text)
138138
}

Cryptomator/MainCoordinator.swift

-11
Original file line numberDiff line numberDiff line change
@@ -78,15 +78,6 @@ class MainCoordinator: NSObject, Coordinator, UINavigationControllerDelegate {
7878
rootViewController.showDetailViewController(detailNavigationController, sender: nil)
7979
}
8080

81-
// Temporarily added for December 2024 Sale
82-
func showPurchase() {
83-
let modalNavigationController = BaseNavigationController()
84-
let child = PurchaseCoordinator(navigationController: modalNavigationController)
85-
childCoordinators.append(child)
86-
navigationController.topViewController?.present(modalNavigationController, animated: true)
87-
child.start()
88-
}
89-
9081
// MARK: - UINavigationControllerDelegate
9182

9283
func navigationController(_ navigationController: UINavigationController, didShow viewController: UIViewController, animated: Bool) {
@@ -124,8 +115,6 @@ extension MainCoordinator: StoreObserverDelegate {
124115
switch transaction {
125116
case .fullVersion, .yearlySubscription:
126117
showFullVersionAlert()
127-
// Temporarily added for December 2024 Sale
128-
NotificationCenter.default.post(name: .purchasedFullVersionNotification, object: nil)
129118
case let .freeTrial(expiresOn):
130119
showTrialAlert(expirationDate: expiresOn)
131120
case .unknown:

Cryptomator/Purchase/Cells/PurchaseCell.swift

-2
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,6 @@ import UIKit
1212

1313
struct PurchaseCellViewModel: Hashable {
1414
let productName: String
15-
let productDetail: String?
1615
let price: String
1716
let purchaseDetail: String?
1817
let purchaseButtonViewModel = PurchaseButtonViewModel()
@@ -37,7 +36,6 @@ class PurchaseCell: IAPCell {
3736

3837
func configure(with viewModel: PurchaseCellViewModel) {
3938
productTitleLabel.text = viewModel.productName
40-
productDetailLabel.text = viewModel.productDetail
4139
accessory.button.setTitle(viewModel.price, for: .normal)
4240
accessory.detailLabel.text = viewModel.purchaseDetail
4341
accessory.configure(with: viewModel.purchaseButtonViewModel)

Cryptomator/Purchase/PurchaseCoordinator.swift

-2
Original file line numberDiff line numberDiff line change
@@ -54,8 +54,6 @@ class PurchaseCoordinator: Coordinator {
5454
}
5555
self.unlockedPro()
5656
}
57-
// Temporarily added for December 2024 Sale
58-
NotificationCenter.default.post(name: .purchasedFullVersionNotification, object: nil)
5957
}
6058

6159
func handleRestoreResult(_ result: RestoreTransactionsResult) {

Cryptomator/Purchase/PurchaseViewModel.swift

-24
Original file line numberDiff line numberDiff line change
@@ -33,23 +33,6 @@ class PurchaseViewModel: BaseIAPViewModel, ProductFetching {
3333
return LocalizedString.getValue("purchase.title")
3434
}
3535

36-
// Temporarily added for December 2024 Sale
37-
override var infoText: NSAttributedString? {
38-
let currentYear = Calendar.current.component(.year, from: Date())
39-
let currentMonth = Calendar.current.component(.month, from: Date())
40-
if currentYear == 2024 && currentMonth == 12 {
41-
return NSAttributedString(
42-
string: "*Note: The discount amount may vary by region.",
43-
attributes: [
44-
.font: UIFont.preferredFont(forTextStyle: .footnote),
45-
.foregroundColor: UIColor.secondaryLabel
46-
]
47-
)
48-
} else {
49-
return nil
50-
}
51-
}
52-
5336
private let cryptomatorSettings: CryptomatorSettings
5437

5538
init(storeManager: IAPStore = StoreManager.shared, iapManager: IAPManager = StoreObserver.shared, cryptomatorSettings: CryptomatorSettings = CryptomatorUserDefaults.shared, minimumDisplayTime: TimeInterval = 1.0) {
@@ -73,7 +56,6 @@ class PurchaseViewModel: BaseIAPViewModel, ProductFetching {
7356
cells.append(.trialCell(TrialCellViewModel(expirationDate: trialExpirationDate)))
7457
} else {
7558
cells.append(.purchaseCell(PurchaseCellViewModel(productName: LocalizedString.getValue("purchase.product.trial"),
76-
productDetail: nil,
7759
price: LocalizedString.getValue("purchase.product.pricing.free"),
7860
purchaseDetail: LocalizedString.getValue("purchase.product.trial.duration"),
7961
productIdentifier: .thirtyDayTrial)))
@@ -83,7 +65,6 @@ class PurchaseViewModel: BaseIAPViewModel, ProductFetching {
8365
private func addSubscriptionItem() {
8466
if let product = products[.yearlySubscription], let localizedPrice = product.localizedPrice {
8567
let viewModel = PurchaseCellViewModel(productName: LocalizedString.getValue("purchase.product.yearlySubscription"),
86-
productDetail: nil,
8768
price: localizedPrice,
8869
purchaseDetail: LocalizedString.getValue("purchase.product.yearlySubscription.duration"),
8970
productIdentifier: .yearlySubscription)
@@ -93,12 +74,7 @@ class PurchaseViewModel: BaseIAPViewModel, ProductFetching {
9374

9475
private func addLifetimeLicenseItem() {
9576
if let product = products[.fullVersion], let localizedPrice = product.localizedPrice {
96-
// Temporarily added for December 2024 Sale
97-
let currentYear = Calendar.current.component(.year, from: Date())
98-
let currentMonth = Calendar.current.component(.month, from: Date())
99-
let productDetail = currentYear == 2024 && currentMonth == 12 ? "🎁 33%* off in December" : nil
10077
let viewModel = PurchaseCellViewModel(productName: LocalizedString.getValue("purchase.product.lifetimeLicense"),
101-
productDetail: productDetail,
10278
price: localizedPrice,
10379
purchaseDetail: LocalizedString.getValue("purchase.product.lifetimeLicense.duration"),
10480
productIdentifier: .fullVersion)

Cryptomator/Purchase/UpgradeViewModel.swift

-2
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,6 @@ class UpgradeViewModel: BaseIAPViewModel, ProductFetching {
3434
func addFreeUpgradeItem() {
3535
guard products[.freeUpgrade] != nil else { return }
3636
let viewModel = PurchaseCellViewModel(productName: LocalizedString.getValue("purchase.product.freeUpgrade"),
37-
productDetail: nil,
3837
price: LocalizedString.getValue("purchase.product.pricing.free"),
3938
purchaseDetail: nil,
4039
productIdentifier: .freeUpgrade)
@@ -44,7 +43,6 @@ class UpgradeViewModel: BaseIAPViewModel, ProductFetching {
4443
func addPaidUpgradeItem() {
4544
if let product = products[.paidUpgrade], let localizedPrice = product.localizedPrice {
4645
let viewModel = PurchaseCellViewModel(productName: LocalizedString.getValue("purchase.product.donateAndUpgrade"),
47-
productDetail: nil,
4846
price: localizedPrice,
4947
purchaseDetail: LocalizedString.getValue("purchase.product.lifetimeLicense.duration"),
5048
productIdentifier: .paidUpgrade)

Cryptomator/Resources/about.html

+1-1
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ <h2>Privacy Policy</h2>
2828

2929
<h2>Connect</h2>
3030
<ul>
31-
<li><a href="https://twitter.com/Cryptomator">Twitter @Cryptomator</a></li>
31+
<li><a href="https://mastodon.online/@cryptomator">Mastodon @[email protected]</a></li>
3232
<li><a href="https://facebook.com/Cryptomator">Facebook /Cryptomator</a></li>
3333
</ul>
3434

Cryptomator/Settings/SettingsCoordinator.swift

+1-1
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,7 @@ class SettingsCoordinator: Coordinator {
7070
}
7171

7272
func openShortcutsGuide() {
73-
if let shortcutsGuideURL = URL(string: "https://docs.cryptomator.org/en/latest/ios/shortcuts-guide/") {
73+
if let shortcutsGuideURL = URL(string: "https://docs.cryptomator.org/ios/shortcuts-guide/") {
7474
UIApplication.shared.open(shortcutsGuideURL)
7575
}
7676
}

Cryptomator/VaultDetail/KeepUnlocked/KeepUnlockedSectionFooterViewModel.swift

+1-1
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ class KeepUnlockedSectionFooterViewModel: BindableAttributedTextHeaderFooterView
3737
}
3838
let text = NSMutableAttributedString(string: infoText)
3939
text.append(NSAttributedString(string: " "))
40-
let learnMoreLink = NSAttributedString(string: LocalizedString.getValue("common.footer.learnMore"), attributes: [NSAttributedString.Key.link: URL(string: "https://docs.cryptomator.org/en/latest/ios/vault-management/#unlock-duration")!])
40+
let learnMoreLink = NSAttributedString(string: LocalizedString.getValue("common.footer.learnMore"), attributes: [NSAttributedString.Key.link: URL(string: "https://docs.cryptomator.org/ios/vault-management/#unlock-duration")!])
4141
text.append(learnMoreLink)
4242
return text
4343
}

Cryptomator/VaultDetail/UnlockSectionFooterViewModel.swift

+8-5
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@
66
// Copyright © 2021 Skymatic GmbH. All rights reserved.
77
//
88

9+
import CryptomatorCloudAccessCore
910
import CryptomatorCommonCore
1011
import Foundation
1112

@@ -31,21 +32,23 @@ class UnlockSectionFooterViewModel: HeaderFooterViewModel {
3132
}
3233

3334
var biometryTypeName: String?
35+
var vaultInfo: VaultInfo
3436

35-
init(vaultUnlocked: Bool, biometricalUnlockEnabled: Bool, biometryTypeName: String?, keepUnlockedDuration: KeepUnlockedDuration) {
37+
init(vaultUnlocked: Bool, biometricalUnlockEnabled: Bool, biometryTypeName: String?, keepUnlockedDuration: KeepUnlockedDuration, vaultInfo: VaultInfo) {
3638
self.vaultUnlocked = vaultUnlocked
3739
self.biometricalUnlockEnabled = biometricalUnlockEnabled
3840
self.biometryTypeName = biometryTypeName
39-
let titleText = UnlockSectionFooterViewModel.getTitleText(vaultUnlocked: vaultUnlocked, biometricalUnlockEnabled: biometricalUnlockEnabled, biometryTypeName: biometryTypeName, keepUnlockedDuration: keepUnlockedDuration)
41+
let titleText = UnlockSectionFooterViewModel.getTitleText(vaultUnlocked: vaultUnlocked, biometricalUnlockEnabled: biometricalUnlockEnabled, biometryTypeName: biometryTypeName, keepUnlockedDuration: keepUnlockedDuration, vaultInfo: vaultInfo)
4042
self.title = Bindable(titleText)
4143
self.keepUnlockedDuration = keepUnlockedDuration
44+
self.vaultInfo = vaultInfo
4245
}
4346

4447
private func updateTitle() {
45-
title.value = UnlockSectionFooterViewModel.getTitleText(vaultUnlocked: vaultUnlocked, biometricalUnlockEnabled: biometricalUnlockEnabled, biometryTypeName: biometryTypeName, keepUnlockedDuration: keepUnlockedDuration)
48+
title.value = UnlockSectionFooterViewModel.getTitleText(vaultUnlocked: vaultUnlocked, biometricalUnlockEnabled: biometricalUnlockEnabled, biometryTypeName: biometryTypeName, keepUnlockedDuration: keepUnlockedDuration, vaultInfo: vaultInfo)
4649
}
4750

48-
private static func getTitleText(vaultUnlocked: Bool, biometricalUnlockEnabled: Bool, biometryTypeName: String?, keepUnlockedDuration: KeepUnlockedDuration) -> String {
51+
private static func getTitleText(vaultUnlocked: Bool, biometricalUnlockEnabled: Bool, biometryTypeName: String?, keepUnlockedDuration: KeepUnlockedDuration, vaultInfo: VaultInfo) -> String {
4952
let unlockedText: String
5053
if vaultUnlocked {
5154
unlockedText = LocalizedString.getValue("vaultDetail.unlocked.footer")
@@ -62,7 +65,7 @@ class UnlockSectionFooterViewModel: HeaderFooterViewModel {
6265
keepUnlockedText = String(format: LocalizedString.getValue("vaultDetail.keepUnlocked.footer.limitedDuration"), keepUnlockedDuration.description ?? "")
6366
}
6467
var footerText = "\(unlockedText)\n\n\(keepUnlockedText)"
65-
if let biometryTypeName = biometryTypeName {
68+
if vaultInfo.vaultConfigType != .hub, let biometryTypeName = biometryTypeName {
6669
let biometricalUnlockText: String
6770
if biometricalUnlockEnabled {
6871
biometricalUnlockText = String(format: LocalizedString.getValue("vaultDetail.enabledBiometricalUnlock.footer"), biometryTypeName)

Cryptomator/VaultDetail/VaultDetailInfoFooterViewModel.swift

+1-1
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ class VaultDetailInfoFooterViewModel: BindableAttributedTextHeaderFooterViewMode
2626
let infoText = loggedInText + LocalizedString.getValue("vaultDetail.info.footer.accessVault")
2727
let text = NSMutableAttributedString(string: infoText)
2828
text.append(NSAttributedString(string: " "))
29-
let learnMoreLink = NSAttributedString(string: LocalizedString.getValue("common.footer.learnMore"), attributes: [NSAttributedString.Key.link: URL(string: "https://docs.cryptomator.org/en/latest/ios/access-vault/#enable-cryptomator-in-files-app")!])
29+
let learnMoreLink = NSAttributedString(string: LocalizedString.getValue("common.footer.learnMore"), attributes: [NSAttributedString.Key.link: URL(string: "https://docs.cryptomator.org/ios/access-vault/#enable-cryptomator-in-files-app")!])
3030
text.append(learnMoreLink)
3131
return text
3232
}

Cryptomator/VaultDetail/VaultDetailViewModel.swift

+5-3
Original file line numberDiff line numberDiff line change
@@ -121,7 +121,7 @@ class VaultDetailViewModel: VaultDetailViewModelProtocol {
121121

122122
private var lockSectionCells: [BindableTableViewCellViewModel] {
123123
var cells: [BindableTableViewCellViewModel] = [lockButton, keepUnlockedCellViewModel]
124-
if let biometryTypeName = context.enrolledBiometricsAuthenticationName() {
124+
if vaultInfo.vaultConfigType != .hub, let biometryTypeName = context.enrolledBiometricsAuthenticationName() {
125125
let switchCellViewModel = getSwitchCellViewModel(biometryTypeName: biometryTypeName)
126126
cells.append(switchCellViewModel)
127127
}
@@ -146,7 +146,7 @@ class VaultDetailViewModel: VaultDetailViewModelProtocol {
146146
.lockingSection: unlockSectionFooterViewModel,
147147
.removeVaultSection: BaseHeaderFooterViewModel(title: LocalizedString.getValue("vaultDetail.removeVault.footer"))]
148148

149-
private lazy var unlockSectionFooterViewModel = UnlockSectionFooterViewModel(vaultUnlocked: vaultInfo.vaultIsUnlocked.value, biometricalUnlockEnabled: biometricalUnlockEnabled, biometryTypeName: context.enrolledBiometricsAuthenticationName(), keepUnlockedDuration: currentKeepUnlockedDuration.value)
149+
private lazy var unlockSectionFooterViewModel = UnlockSectionFooterViewModel(vaultUnlocked: vaultInfo.vaultIsUnlocked.value, biometricalUnlockEnabled: biometricalUnlockEnabled, biometryTypeName: context.enrolledBiometricsAuthenticationName(), keepUnlockedDuration: currentKeepUnlockedDuration.value, vaultInfo: vaultInfo)
150150

151151
private lazy var vaultInfoCellViewModel = BindableTableViewCellViewModel(title: vaultInfo.vaultName, detailTitle: vaultInfo.vaultPath.path, detailTitleTextColor: .secondaryLabel, image: UIImage(vaultIconFor: vaultInfo.cloudProviderType, state: .normal), selectionStyle: .none)
152152
private lazy var renameVaultCellViewModel = ButtonCellViewModel.createDisclosureButton(action: VaultDetailButtonAction.showRenameVault, title: LocalizedString.getValue("vaultDetail.button.renameVault"), detailTitle: vaultName)
@@ -270,7 +270,9 @@ class VaultDetailViewModel: VaultDetailViewModelProtocol {
270270
}
271271

272272
private func vaultIsEligibleToMove() -> Bool {
273-
if case CloudProviderType.localFileSystem = vaultInfo.cloudProviderType {
273+
if vaultInfo.vaultConfigType == .hub {
274+
return false
275+
} else if case CloudProviderType.localFileSystem = vaultInfo.cloudProviderType {
274276
return false
275277
}
276278
return vaultInfo.vaultPath != CloudPath("/")

0 commit comments

Comments
 (0)