Update SwiftGen files
This commit is contained in:
parent
5b35297a6d
commit
366ff3ebf1
|
@ -286,9 +286,11 @@ internal enum Asset {
|
|||
internal static let hideme = ImageAsset(name: "hideme")
|
||||
internal static let mullvad = ImageAsset(name: "mullvad")
|
||||
internal static let nordvpn = ImageAsset(name: "nordvpn")
|
||||
internal static let oeck = ImageAsset(name: "oeck")
|
||||
internal static let pia = ImageAsset(name: "pia")
|
||||
internal static let placeholder = ImageAsset(name: "placeholder")
|
||||
internal static let protonvpn = ImageAsset(name: "protonvpn")
|
||||
internal static let surfshark = ImageAsset(name: "surfshark")
|
||||
internal static let torguard = ImageAsset(name: "torguard")
|
||||
internal static let tunnelbear = ImageAsset(name: "tunnelbear")
|
||||
internal static let vyprvpn = ImageAsset(name: "vyprvpn")
|
||||
|
@ -313,7 +315,8 @@ internal struct ImageAsset {
|
|||
#if os(iOS) || os(tvOS)
|
||||
let image = Image(named: name, in: bundle, compatibleWith: nil)
|
||||
#elseif os(macOS)
|
||||
let image = bundle.image(forResource: NSImage.Name(name))
|
||||
let name = NSImage.Name(self.name)
|
||||
let image = (bundle == .main) ? NSImage(named: name) : bundle.image(forResource: name)
|
||||
#elseif os(watchOS)
|
||||
let image = Image(named: name)
|
||||
#endif
|
||||
|
@ -342,7 +345,11 @@ internal extension ImageAsset.Image {
|
|||
// swiftlint:disable convenience_type
|
||||
private final class BundleToken {
|
||||
static let bundle: Bundle = {
|
||||
Bundle(for: BundleToken.self)
|
||||
#if SWIFT_PACKAGE
|
||||
return Bundle.module
|
||||
#else
|
||||
return Bundle(for: BundleToken.self)
|
||||
#endif
|
||||
}()
|
||||
}
|
||||
// swiftlint:enable convenience_type
|
||||
|
|
|
@ -6,7 +6,7 @@ import Foundation
|
|||
import UIKit
|
||||
|
||||
// swiftlint:disable superfluous_disable_command
|
||||
// swiftlint:disable file_length
|
||||
// swiftlint:disable file_length implicit_return
|
||||
|
||||
// MARK: - Storyboard Scenes
|
||||
|
||||
|
@ -80,6 +80,11 @@ internal struct SceneType<T: UIViewController> {
|
|||
}
|
||||
return controller
|
||||
}
|
||||
|
||||
@available(iOS 13.0, tvOS 13.0, *)
|
||||
internal func instantiate(creator block: @escaping (NSCoder) -> T?) -> T {
|
||||
return storyboard.storyboard.instantiateViewController(identifier: identifier, creator: block)
|
||||
}
|
||||
}
|
||||
|
||||
internal struct InitialSceneType<T: UIViewController> {
|
||||
|
@ -91,12 +96,24 @@ internal struct InitialSceneType<T: UIViewController> {
|
|||
}
|
||||
return controller
|
||||
}
|
||||
|
||||
@available(iOS 13.0, tvOS 13.0, *)
|
||||
internal func instantiate(creator block: @escaping (NSCoder) -> T?) -> T {
|
||||
guard let controller = storyboard.storyboard.instantiateInitialViewController(creator: block) else {
|
||||
fatalError("Storyboard \(storyboard.storyboardName) does not have an initial scene.")
|
||||
}
|
||||
return controller
|
||||
}
|
||||
}
|
||||
|
||||
// swiftlint:disable convenience_type
|
||||
private final class BundleToken {
|
||||
static let bundle: Bundle = {
|
||||
Bundle(for: BundleToken.self)
|
||||
#if SWIFT_PACKAGE
|
||||
return Bundle.module
|
||||
#else
|
||||
return Bundle(for: BundleToken.self)
|
||||
#endif
|
||||
}()
|
||||
}
|
||||
// swiftlint:enable convenience_type
|
||||
|
|
|
@ -56,11 +56,3 @@ internal extension SegueType where RawValue == String {
|
|||
self.init(rawValue: identifier)
|
||||
}
|
||||
}
|
||||
|
||||
// swiftlint:disable convenience_type
|
||||
private final class BundleToken {
|
||||
static let bundle: Bundle = {
|
||||
Bundle(for: BundleToken.self)
|
||||
}()
|
||||
}
|
||||
// swiftlint:enable convenience_type
|
||||
|
|
|
@ -8,7 +8,7 @@ import Foundation
|
|||
// MARK: - Strings
|
||||
|
||||
// swiftlint:disable explicit_type_interface function_parameter_count identifier_name line_length
|
||||
// swiftlint:disable nesting type_body_length type_name
|
||||
// swiftlint:disable nesting type_body_length type_name vertical_whitespace_opening_braces
|
||||
internal enum L10n {
|
||||
internal enum App {
|
||||
internal enum Account {
|
||||
|
@ -254,10 +254,6 @@ internal enum L10n {
|
|||
internal enum Guidance {
|
||||
internal enum Footer {
|
||||
internal enum Infrastructure {
|
||||
/// Use your %@ website credentials.
|
||||
internal static func hideme(_ p1: Any) -> String {
|
||||
return L10n.tr("Core", "account.sections.guidance.footer.infrastructure.hideme", String(describing: p1))
|
||||
}
|
||||
/// Use your %@ website credentials. Your username is usually numeric (without spaces).
|
||||
internal static func mullvad(_ p1: Any) -> String {
|
||||
return L10n.tr("Core", "account.sections.guidance.footer.infrastructure.mullvad", String(describing: p1))
|
||||
|
@ -274,10 +270,6 @@ internal enum L10n {
|
|||
internal static func protonvpn(_ p1: Any) -> String {
|
||||
return L10n.tr("Core", "account.sections.guidance.footer.infrastructure.protonvpn", String(describing: p1))
|
||||
}
|
||||
/// Use your %@ service credentials, which may differ from website credentials.
|
||||
internal static func torguard(_ p1: Any) -> String {
|
||||
return L10n.tr("Core", "account.sections.guidance.footer.infrastructure.torguard", String(describing: p1))
|
||||
}
|
||||
/// Use your %@ website credentials. Your username is usually your e-mail.
|
||||
internal static func tunnelbear(_ p1: Any) -> String {
|
||||
return L10n.tr("Core", "account.sections.guidance.footer.infrastructure.tunnelbear", String(describing: p1))
|
||||
|
@ -290,6 +282,16 @@ internal enum L10n {
|
|||
internal static func windscribe(_ p1: Any) -> String {
|
||||
return L10n.tr("Core", "account.sections.guidance.footer.infrastructure.windscribe", String(describing: p1))
|
||||
}
|
||||
internal enum Default {
|
||||
/// Use your %@ service credentials, which may differ from website credentials.
|
||||
internal static func specific(_ p1: Any) -> String {
|
||||
return L10n.tr("Core", "account.sections.guidance.footer.infrastructure.default.specific", String(describing: p1))
|
||||
}
|
||||
/// Use your %@ website credentials.
|
||||
internal static func web(_ p1: Any) -> String {
|
||||
return L10n.tr("Core", "account.sections.guidance.footer.infrastructure.default.web", String(describing: p1))
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -1102,7 +1104,7 @@ internal enum L10n {
|
|||
}
|
||||
}
|
||||
// swiftlint:enable explicit_type_interface function_parameter_count identifier_name line_length
|
||||
// swiftlint:enable nesting type_body_length type_name
|
||||
// swiftlint:enable nesting type_body_length type_name vertical_whitespace_opening_braces
|
||||
|
||||
// MARK: - Implementation Details
|
||||
|
||||
|
@ -1116,7 +1118,11 @@ extension L10n {
|
|||
// swiftlint:disable convenience_type
|
||||
private final class BundleToken {
|
||||
static let bundle: Bundle = {
|
||||
Bundle(for: BundleToken.self)
|
||||
#if SWIFT_PACKAGE
|
||||
return Bundle.module
|
||||
#else
|
||||
return Bundle(for: BundleToken.self)
|
||||
#endif
|
||||
}()
|
||||
}
|
||||
// swiftlint:enable convenience_type
|
||||
|
|
|
@ -286,6 +286,7 @@ internal enum Asset {
|
|||
internal static let hideme = ImageAsset(name: "hideme")
|
||||
internal static let mullvad = ImageAsset(name: "mullvad")
|
||||
internal static let nordvpn = ImageAsset(name: "nordvpn")
|
||||
internal static let oeck = ImageAsset(name: "oeck")
|
||||
internal static let pia = ImageAsset(name: "pia")
|
||||
internal static let placeholder = ImageAsset(name: "placeholder")
|
||||
internal static let protonvpn = ImageAsset(name: "protonvpn")
|
||||
|
|
Loading…
Reference in New Issue