From f44065c7f843eca120e8f48343ae8d12e0e4b9a7 Mon Sep 17 00:00:00 2001 From: Christian Beer Date: Mon, 17 Jul 2023 11:13:12 +0200 Subject: [PATCH 01/13] visionOS compatibility by removing haptic feedback --- Sources/Models/WhatsNew+HapticFeedback.swift | 4 ++-- Tests/WhatsNewVersionStoreTests.swift | 3 +++ 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/Sources/Models/WhatsNew+HapticFeedback.swift b/Sources/Models/WhatsNew+HapticFeedback.swift index 3ee87e8..39377c3 100644 --- a/Sources/Models/WhatsNew+HapticFeedback.swift +++ b/Sources/Models/WhatsNew+HapticFeedback.swift @@ -9,7 +9,7 @@ public extension WhatsNew { /// The WhatsNew HapticFeedback enum HapticFeedback: Hashable { - #if os(iOS) + #if os(iOS) && !os(xrOS) /// Impact HapticFeedback case impact( style: UIImpactFeedbackGenerator.FeedbackStyle? = nil, @@ -32,7 +32,7 @@ public extension WhatsNew.HapticFeedback { /// Call HapticFeedback as function to execute the HapticFeedback func callAsFunction() { - #if os(iOS) + #if os(iOS) && !os(xrOS) switch self { case .impact(let style, let intensity): let feedbackGenerator = style.flatMap(UIImpactFeedbackGenerator.init) ?? .init() diff --git a/Tests/WhatsNewVersionStoreTests.swift b/Tests/WhatsNewVersionStoreTests.swift index 42e0d96..8b0901c 100644 --- a/Tests/WhatsNewVersionStoreTests.swift +++ b/Tests/WhatsNewVersionStoreTests.swift @@ -82,12 +82,15 @@ final class WhatsNewVersionStoreTests: WhatsNewKitTestCase { (fakeNSUbiquitousKeyValueStore.store[version.key] as? String).flatMap(WhatsNew.Version.init) ) ubiquitousKeyValueWhatsNewVersionStore.removeAll() + // TODO: Check why this doesn't work on xrOS +#if !os(xrOS) XCTAssert( ubiquitousKeyValueWhatsNewVersionStore.presentedVersions.isEmpty ) XCTAssert( fakeNSUbiquitousKeyValueStore.store.isEmpty ) +#endif } } From 426d2454b84f1508b4c6e903a86b6e86f3f1e42a Mon Sep 17 00:00:00 2001 From: Alexandre Reol Date: Thu, 18 Jan 2024 17:32:10 +0100 Subject: [PATCH 02/13] Add visionsOS compatibility --- Package.swift | 5 +++-- Sources/View/WhatsNewView+FeaturesPadding.swift | 2 +- Sources/View/WhatsNewView+FooterPadding.swift | 2 +- 3 files changed, 5 insertions(+), 4 deletions(-) diff --git a/Package.swift b/Package.swift index fa03e7e..ddccf48 100644 --- a/Package.swift +++ b/Package.swift @@ -1,4 +1,4 @@ -// swift-tools-version:5.3 +// swift-tools-version:5.9 import PackageDescription @@ -6,7 +6,8 @@ let package = Package( name: "WhatsNewKit", platforms: [ .iOS(.v13), - .macOS(.v11) + .macOS(.v11), + .visionOS(.v1) ], products: [ .library( diff --git a/Sources/View/WhatsNewView+FeaturesPadding.swift b/Sources/View/WhatsNewView+FeaturesPadding.swift index 8b70ad1..8592275 100644 --- a/Sources/View/WhatsNewView+FeaturesPadding.swift +++ b/Sources/View/WhatsNewView+FeaturesPadding.swift @@ -30,7 +30,7 @@ extension WhatsNewView.FeaturesPadding: ViewModifier { func body( content: Content ) -> some View { - #if os(macOS) + #if os(macOS) || os(visionOS) content.padding(.horizontal) #else if self.horizontalSizeClass == .regular { diff --git a/Sources/View/WhatsNewView+FooterPadding.swift b/Sources/View/WhatsNewView+FooterPadding.swift index 8418714..300ecc3 100644 --- a/Sources/View/WhatsNewView+FooterPadding.swift +++ b/Sources/View/WhatsNewView+FooterPadding.swift @@ -30,7 +30,7 @@ extension WhatsNewView.FooterPadding: ViewModifier { func body( content: Content ) -> some View { - #if os(macOS) + #if os(macOS) || os(visionOS) content.padding(.bottom, 30) #else if self.horizontalSizeClass == .regular { From 39272ae89d7a6ed8cba1aac9a940da721ace2542 Mon Sep 17 00:00:00 2001 From: Sven Tiigi Date: Thu, 18 Jan 2024 19:41:07 +0100 Subject: [PATCH 03/13] Fixed tests --- Tests/WhatsNewVersionStoreTests.swift | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/Tests/WhatsNewVersionStoreTests.swift b/Tests/WhatsNewVersionStoreTests.swift index 8b0901c..6127660 100644 --- a/Tests/WhatsNewVersionStoreTests.swift +++ b/Tests/WhatsNewVersionStoreTests.swift @@ -67,6 +67,10 @@ final class WhatsNewVersionStoreTests: WhatsNewKitTestCase { override func set(_ value: Any?, forKey defaultName: String) { self.store[defaultName] = value } + + override func removeObject(forKey aKey: String) { + self.store.removeValue(forKey: aKey) + } } let fakeNSUbiquitousKeyValueStore = FakeNSUbiquitousKeyValueStore() let ubiquitousKeyValueWhatsNewVersionStore = NSUbiquitousKeyValueWhatsNewVersionStore( @@ -82,15 +86,12 @@ final class WhatsNewVersionStoreTests: WhatsNewKitTestCase { (fakeNSUbiquitousKeyValueStore.store[version.key] as? String).flatMap(WhatsNew.Version.init) ) ubiquitousKeyValueWhatsNewVersionStore.removeAll() - // TODO: Check why this doesn't work on xrOS -#if !os(xrOS) XCTAssert( ubiquitousKeyValueWhatsNewVersionStore.presentedVersions.isEmpty ) XCTAssert( fakeNSUbiquitousKeyValueStore.store.isEmpty ) -#endif } } From 9e8833da8b43e49be4ce23b54893005308fafd75 Mon Sep 17 00:00:00 2001 From: Sven Tiigi Date: Thu, 18 Jan 2024 19:41:15 +0100 Subject: [PATCH 04/13] Updated os name --- Sources/Models/WhatsNew+HapticFeedback.swift | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Sources/Models/WhatsNew+HapticFeedback.swift b/Sources/Models/WhatsNew+HapticFeedback.swift index 39377c3..b13d8f0 100644 --- a/Sources/Models/WhatsNew+HapticFeedback.swift +++ b/Sources/Models/WhatsNew+HapticFeedback.swift @@ -9,7 +9,7 @@ public extension WhatsNew { /// The WhatsNew HapticFeedback enum HapticFeedback: Hashable { - #if os(iOS) && !os(xrOS) + #if os(iOS) && !os(visionOS) /// Impact HapticFeedback case impact( style: UIImpactFeedbackGenerator.FeedbackStyle? = nil, @@ -32,7 +32,7 @@ public extension WhatsNew.HapticFeedback { /// Call HapticFeedback as function to execute the HapticFeedback func callAsFunction() { - #if os(iOS) && !os(xrOS) + #if os(iOS) && !os(visionOS) switch self { case .impact(let style, let intensity): let feedbackGenerator = style.flatMap(UIImpactFeedbackGenerator.init) ?? .init() From f9151b648145050c0bcc93555c6f7881e83fde68 Mon Sep 17 00:00:00 2001 From: Sven Tiigi Date: Thu, 18 Jan 2024 19:44:27 +0100 Subject: [PATCH 05/13] Use macos-latest --- .github/workflows/build_and_test.yml | 14 +++++++------- .github/workflows/build_example_project.yml | 10 +++++----- .github/workflows/deploy_documentation.yml | 4 ++-- 3 files changed, 14 insertions(+), 14 deletions(-) diff --git a/.github/workflows/build_and_test.yml b/.github/workflows/build_and_test.yml index 21f958f..2ee5ade 100644 --- a/.github/workflows/build_and_test.yml +++ b/.github/workflows/build_and_test.yml @@ -4,19 +4,19 @@ on: workflow_dispatch: push: paths: - - 'Sources/**' - - 'Tests/**' - - '!Sources/Documentation.docc/**' + - "Sources/**" + - "Tests/**" + - "!Sources/Documentation.docc/**" pull_request: paths: - - 'Sources/**' - - 'Tests/**' - - '!Sources/Documentation.docc/**' + - "Sources/**" + - "Tests/**" + - "!Sources/Documentation.docc/**" jobs: iOS: name: Build and test on iOS - runs-on: macOS-12 + runs-on: macos-latest steps: - uses: actions/checkout@v3 - name: Build diff --git a/.github/workflows/build_example_project.yml b/.github/workflows/build_example_project.yml index 1504b02..d40cd55 100644 --- a/.github/workflows/build_example_project.yml +++ b/.github/workflows/build_example_project.yml @@ -4,17 +4,17 @@ on: workflow_dispatch: push: paths: - - 'Example/**' - - 'Sources/**' + - "Example/**" + - "Sources/**" pull_request: paths: - - 'Example/**' - - 'Sources/**' + - "Example/**" + - "Sources/**" jobs: build: name: Build iOS example project - runs-on: macOS-12 + runs-on: macos-latest steps: - name: Checkout uses: actions/checkout@v2 diff --git a/.github/workflows/deploy_documentation.yml b/.github/workflows/deploy_documentation.yml index 519bc61..80e9966 100644 --- a/.github/workflows/deploy_documentation.yml +++ b/.github/workflows/deploy_documentation.yml @@ -5,7 +5,7 @@ on: push: branches: - main - + permissions: contents: read pages: write @@ -17,7 +17,7 @@ concurrency: jobs: build: - runs-on: macos-12 + runs-on: macos-latest steps: - name: Checkout uses: actions/checkout@v3 From a4a0e5774312a006b67f6213a7cf9235ab6d9769 Mon Sep 17 00:00:00 2001 From: Sven Tiigi Date: Thu, 18 Jan 2024 19:51:45 +0100 Subject: [PATCH 06/13] Updated example app --- Example/Example.xcodeproj/project.pbxproj | 16 +++++++++++++--- .../xcshareddata/xcschemes/Example-iOS.xcscheme | 2 +- .../xcschemes/Example-macOS.xcscheme | 2 +- 3 files changed, 15 insertions(+), 5 deletions(-) diff --git a/Example/Example.xcodeproj/project.pbxproj b/Example/Example.xcodeproj/project.pbxproj index 04cf8f6..1a0ced0 100644 --- a/Example/Example.xcodeproj/project.pbxproj +++ b/Example/Example.xcodeproj/project.pbxproj @@ -149,7 +149,7 @@ attributes = { BuildIndependentTargetsInParallel = 1; LastSwiftUpdateCheck = 1320; - LastUpgradeCheck = 1320; + LastUpgradeCheck = 1520; TargetAttributes = { 3D5FCF732767887E00D3211F = { CreatedOnToolsVersion = 13.1; @@ -258,6 +258,7 @@ DEBUG_INFORMATION_FORMAT = dwarf; ENABLE_STRICT_OBJC_MSGSEND = YES; ENABLE_TESTABILITY = YES; + ENABLE_USER_SCRIPT_SANDBOXING = YES; GCC_C_LANGUAGE_STANDARD = gnu11; GCC_DYNAMIC_NO_PIC = NO; GCC_NO_COMMON_BLOCKS = YES; @@ -319,6 +320,7 @@ DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; ENABLE_NS_ASSERTIONS = NO; ENABLE_STRICT_OBJC_MSGSEND = YES; + ENABLE_USER_SCRIPT_SANDBOXING = YES; GCC_C_LANGUAGE_STANDARD = gnu11; GCC_NO_COMMON_BLOCKS = YES; GCC_WARN_64_TO_32_BIT_CONVERSION = YES; @@ -359,9 +361,12 @@ MARKETING_VERSION = 1.0; PRODUCT_BUNDLE_IDENTIFIER = "de.tiigi.WhatsNewKit.Example-iOS"; PRODUCT_NAME = "WhatsNewKit-Example"; + SUPPORTED_PLATFORMS = "iphoneos iphonesimulator xros xrsimulator"; + SUPPORTS_MACCATALYST = NO; + SUPPORTS_XR_DESIGNED_FOR_IPHONE_IPAD = NO; SWIFT_EMIT_LOC_STRINGS = YES; SWIFT_VERSION = 5.0; - TARGETED_DEVICE_FAMILY = "1,2"; + TARGETED_DEVICE_FAMILY = "1,2,7"; }; name = Debug; }; @@ -387,9 +392,12 @@ MARKETING_VERSION = 1.0; PRODUCT_BUNDLE_IDENTIFIER = "de.tiigi.WhatsNewKit.Example-iOS"; PRODUCT_NAME = "WhatsNewKit-Example"; + SUPPORTED_PLATFORMS = "iphoneos iphonesimulator xros xrsimulator"; + SUPPORTS_MACCATALYST = NO; + SUPPORTS_XR_DESIGNED_FOR_IPHONE_IPAD = NO; SWIFT_EMIT_LOC_STRINGS = YES; SWIFT_VERSION = 5.0; - TARGETED_DEVICE_FAMILY = "1,2"; + TARGETED_DEVICE_FAMILY = "1,2,7"; }; name = Release; }; @@ -403,6 +411,7 @@ CODE_SIGN_STYLE = Automatic; COMBINE_HIDPI_IMAGES = YES; CURRENT_PROJECT_VERSION = 1; + DEAD_CODE_STRIPPING = YES; DEVELOPMENT_ASSET_PATHS = ""; ENABLE_PREVIEWS = YES; GENERATE_INFOPLIST_FILE = YES; @@ -431,6 +440,7 @@ CODE_SIGN_STYLE = Automatic; COMBINE_HIDPI_IMAGES = YES; CURRENT_PROJECT_VERSION = 1; + DEAD_CODE_STRIPPING = YES; DEVELOPMENT_ASSET_PATHS = ""; ENABLE_PREVIEWS = YES; GENERATE_INFOPLIST_FILE = YES; diff --git a/Example/Example.xcodeproj/xcshareddata/xcschemes/Example-iOS.xcscheme b/Example/Example.xcodeproj/xcshareddata/xcschemes/Example-iOS.xcscheme index da2bdc1..899d3c9 100644 --- a/Example/Example.xcodeproj/xcshareddata/xcschemes/Example-iOS.xcscheme +++ b/Example/Example.xcodeproj/xcshareddata/xcschemes/Example-iOS.xcscheme @@ -1,6 +1,6 @@ Date: Thu, 18 Jan 2024 19:54:12 +0100 Subject: [PATCH 07/13] Updated README.md --- README.md | 27 +-------------------------- 1 file changed, 1 insertion(+), 26 deletions(-) diff --git a/README.md b/README.md index 570f36e..3e0ea3a 100644 --- a/README.md +++ b/README.md @@ -59,7 +59,7 @@ struct ContentView: View { - [x] Easily present your new app features 🤩 - [x] Automatic & Manual presentation mode ✅ - [x] Support for SwiftUI, UIKit and AppKit 🧑‍🎨 -- [x] Runs on iOS and macOS 📱 🖥 +- [x] Runs on iOS, macOS and visionOS 📱 🖥 👓 - [x] Adjustable layout 🔧 ## Installation @@ -530,28 +530,3 @@ guard let whatsNewViewController = WhatsNewViewController( // WhatsNewVersionStore when the WhatsNewViewController gets dismissed self.present(whatsNewViewController, animated: true) ``` - -## License - -``` -WhatsNewKit -Copyright (c) 2022 Sven Tiigi sven.tiigi@gmail.com - -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is -furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN -THE SOFTWARE. -``` From 143a50e01d261a9d058a6514e0ee196890c25d5c Mon Sep 17 00:00:00 2001 From: Sven Tiigi Date: Sat, 20 Jan 2024 22:43:32 +0100 Subject: [PATCH 08/13] Updated Package.swift --- Package.swift | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/Package.swift b/Package.swift index ddccf48..35e20b8 100644 --- a/Package.swift +++ b/Package.swift @@ -1,4 +1,4 @@ -// swift-tools-version:5.9 +// swift-tools-version: 5.9 import PackageDescription @@ -12,7 +12,9 @@ let package = Package( products: [ .library( name: "WhatsNewKit", - targets: ["WhatsNewKit"] + targets: [ + "WhatsNewKit" + ] ) ], targets: [ @@ -22,7 +24,9 @@ let package = Package( ), .testTarget( name: "WhatsNewKitTests", - dependencies: ["WhatsNewKit"], + dependencies: [ + "WhatsNewKit" + ], path: "Tests" ) ] From 82a621673aab297dd6ea614162520ef8f9228b63 Mon Sep 17 00:00:00 2001 From: Sven Tiigi Date: Sat, 20 Jan 2024 23:19:40 +0100 Subject: [PATCH 09/13] Updated Example app --- Example/Example.xcodeproj/project.pbxproj | 176 +++--------------- .../xcschemes/Example-macOS.xcscheme | 78 -------- ...{Example-iOS.xcscheme => Example.xcscheme} | 6 +- .../AccentColor.colorset/Contents.json | 0 .../AppIcon.appiconset}/AppIcon-1024px.png | Bin .../AppIcon.appiconset}/Contents.json | 6 + .../macOS-AppIcon-1024px.png | Bin .../macOS-AppIcon-128px-128pt@1x.png | Bin .../macOS-AppIcon-16px-16pt@1x.png | Bin .../macOS-AppIcon-256px-128pt@2x.png | Bin .../macOS-AppIcon-256px-256pt@1x.png | Bin .../macOS-AppIcon-32px-16pt@2x.png | Bin .../macOS-AppIcon-32px-32pt@1x.png | Bin .../macOS-AppIcon-512px-256pt@2x.png | Bin .../macOS-AppIcon-512px.png | Bin .../macOS-AppIcon-64px-32pt@2x.png | Bin .../Contents.json | 0 Example/Example/ContentView.swift | 9 +- .../AppIcon-iOS.appiconset/Contents.json | 14 -- .../AccentColor.colorset/Contents.json | 15 -- .../Assets-macOS.xcassets/Contents.json | 6 - .../Resources/Entitlements.entitlements | 10 - 22 files changed, 31 insertions(+), 289 deletions(-) delete mode 100644 Example/Example.xcodeproj/xcshareddata/xcschemes/Example-macOS.xcscheme rename Example/Example.xcodeproj/xcshareddata/xcschemes/{Example-iOS.xcscheme => Example.xcscheme} (95%) rename Example/Example/{Resources/Assets-iOS.xcassets => Assets.xcassets}/AccentColor.colorset/Contents.json (100%) rename Example/Example/{Resources/Assets-iOS.xcassets/AppIcon-iOS.appiconset => Assets.xcassets/AppIcon.appiconset}/AppIcon-1024px.png (100%) rename Example/Example/{Resources/Assets-macOS.xcassets/AppIcon-macOS.appiconset => Assets.xcassets/AppIcon.appiconset}/Contents.json (91%) rename Example/Example/{Resources/Assets-macOS.xcassets/AppIcon-macOS.appiconset => Assets.xcassets/AppIcon.appiconset}/macOS-AppIcon-1024px.png (100%) rename Example/Example/{Resources/Assets-macOS.xcassets/AppIcon-macOS.appiconset => Assets.xcassets/AppIcon.appiconset}/macOS-AppIcon-128px-128pt@1x.png (100%) rename Example/Example/{Resources/Assets-macOS.xcassets/AppIcon-macOS.appiconset => Assets.xcassets/AppIcon.appiconset}/macOS-AppIcon-16px-16pt@1x.png (100%) rename Example/Example/{Resources/Assets-macOS.xcassets/AppIcon-macOS.appiconset => Assets.xcassets/AppIcon.appiconset}/macOS-AppIcon-256px-128pt@2x.png (100%) rename Example/Example/{Resources/Assets-macOS.xcassets/AppIcon-macOS.appiconset => Assets.xcassets/AppIcon.appiconset}/macOS-AppIcon-256px-256pt@1x.png (100%) rename Example/Example/{Resources/Assets-macOS.xcassets/AppIcon-macOS.appiconset => Assets.xcassets/AppIcon.appiconset}/macOS-AppIcon-32px-16pt@2x.png (100%) rename Example/Example/{Resources/Assets-macOS.xcassets/AppIcon-macOS.appiconset => Assets.xcassets/AppIcon.appiconset}/macOS-AppIcon-32px-32pt@1x.png (100%) rename Example/Example/{Resources/Assets-macOS.xcassets/AppIcon-macOS.appiconset => Assets.xcassets/AppIcon.appiconset}/macOS-AppIcon-512px-256pt@2x.png (100%) rename Example/Example/{Resources/Assets-macOS.xcassets/AppIcon-macOS.appiconset => Assets.xcassets/AppIcon.appiconset}/macOS-AppIcon-512px.png (100%) rename Example/Example/{Resources/Assets-macOS.xcassets/AppIcon-macOS.appiconset => Assets.xcassets/AppIcon.appiconset}/macOS-AppIcon-64px-32pt@2x.png (100%) rename Example/Example/{Resources/Assets-iOS.xcassets => Assets.xcassets}/Contents.json (100%) delete mode 100644 Example/Example/Resources/Assets-iOS.xcassets/AppIcon-iOS.appiconset/Contents.json delete mode 100644 Example/Example/Resources/Assets-macOS.xcassets/AccentColor.colorset/Contents.json delete mode 100644 Example/Example/Resources/Assets-macOS.xcassets/Contents.json delete mode 100644 Example/Example/Resources/Entitlements.entitlements diff --git a/Example/Example.xcodeproj/project.pbxproj b/Example/Example.xcodeproj/project.pbxproj index 1a0ced0..22315ac 100644 --- a/Example/Example.xcodeproj/project.pbxproj +++ b/Example/Example.xcodeproj/project.pbxproj @@ -10,12 +10,7 @@ 3D5FCF782767887F00D3211F /* App.swift in Sources */ = {isa = PBXBuildFile; fileRef = 3D5FCF772767887F00D3211F /* App.swift */; }; 3D5FCF7A2767887F00D3211F /* ContentView.swift in Sources */ = {isa = PBXBuildFile; fileRef = 3D5FCF792767887F00D3211F /* ContentView.swift */; }; 3D5FCF88276788FE00D3211F /* WhatsNewKit in Frameworks */ = {isa = PBXBuildFile; productRef = 3D5FCF87276788FE00D3211F /* WhatsNewKit */; }; - 3D9996C8276E112A00438FB6 /* ExamplesView.swift in Sources */ = {isa = PBXBuildFile; fileRef = 3DA482052769E7F900F526B0 /* ExamplesView.swift */; }; - 3D9996C9276E112C00438FB6 /* ContentView.swift in Sources */ = {isa = PBXBuildFile; fileRef = 3D5FCF792767887F00D3211F /* ContentView.swift */; }; - 3D9996CB276E113100438FB6 /* App.swift in Sources */ = {isa = PBXBuildFile; fileRef = 3D5FCF772767887F00D3211F /* App.swift */; }; - 3D9996CD276E118C00438FB6 /* WhatsNewKit in Frameworks */ = {isa = PBXBuildFile; productRef = 3D9996CC276E118C00438FB6 /* WhatsNewKit */; }; - 3D999702276E141A00438FB6 /* Assets-macOS.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 3D999701276E141A00438FB6 /* Assets-macOS.xcassets */; }; - 3D999705276E144B00438FB6 /* Assets-iOS.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 3D999703276E144800438FB6 /* Assets-iOS.xcassets */; }; + 3D999705276E144B00438FB6 /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 3D999703276E144800438FB6 /* Assets.xcassets */; }; 3DA482062769E7F900F526B0 /* ExamplesView.swift in Sources */ = {isa = PBXBuildFile; fileRef = 3DA482052769E7F900F526B0 /* ExamplesView.swift */; }; /* End PBXBuildFile section */ @@ -24,10 +19,7 @@ 3D5FCF772767887F00D3211F /* App.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = App.swift; sourceTree = ""; }; 3D5FCF792767887F00D3211F /* ContentView.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ContentView.swift; sourceTree = ""; }; 3D5FCF85276788F900D3211F /* WhatsNewKit */ = {isa = PBXFileReference; lastKnownFileType = folder; name = WhatsNewKit; path = ..; sourceTree = ""; }; - 3D9996B8276E10CE00438FB6 /* Example-macOS.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = "Example-macOS.app"; sourceTree = BUILT_PRODUCTS_DIR; }; - 3D9996C3276E10D000438FB6 /* Entitlements.entitlements */ = {isa = PBXFileReference; lastKnownFileType = text.plist.entitlements; path = Entitlements.entitlements; sourceTree = ""; }; - 3D999701276E141A00438FB6 /* Assets-macOS.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = "Assets-macOS.xcassets"; sourceTree = ""; }; - 3D999703276E144800438FB6 /* Assets-iOS.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = "Assets-iOS.xcassets"; sourceTree = ""; }; + 3D999703276E144800438FB6 /* Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Assets.xcassets; sourceTree = ""; }; 3DA482052769E7F900F526B0 /* ExamplesView.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ExamplesView.swift; sourceTree = ""; }; /* End PBXFileReference section */ @@ -40,14 +32,6 @@ ); runOnlyForDeploymentPostprocessing = 0; }; - 3D9996B5276E10CE00438FB6 /* Frameworks */ = { - isa = PBXFrameworksBuildPhase; - buildActionMask = 2147483647; - files = ( - 3D9996CD276E118C00438FB6 /* WhatsNewKit in Frameworks */, - ); - runOnlyForDeploymentPostprocessing = 0; - }; /* End PBXFrameworksBuildPhase section */ /* Begin PBXGroup section */ @@ -65,7 +49,6 @@ isa = PBXGroup; children = ( 3D5FCF742767887F00D3211F /* WhatsNewKit-Example.app */, - 3D9996B8276E10CE00438FB6 /* Example-macOS.app */, ); name = Products; sourceTree = ""; @@ -76,7 +59,7 @@ 3D5FCF772767887F00D3211F /* App.swift */, 3D5FCF792767887F00D3211F /* ContentView.swift */, 3DA482052769E7F900F526B0 /* ExamplesView.swift */, - 3D999700276E131F00438FB6 /* Resources */, + 3D999703276E144800438FB6 /* Assets.xcassets */, ); path = Example; sourceTree = ""; @@ -88,22 +71,12 @@ name = Frameworks; sourceTree = ""; }; - 3D999700276E131F00438FB6 /* Resources */ = { - isa = PBXGroup; - children = ( - 3D999703276E144800438FB6 /* Assets-iOS.xcassets */, - 3D999701276E141A00438FB6 /* Assets-macOS.xcassets */, - 3D9996C3276E10D000438FB6 /* Entitlements.entitlements */, - ); - path = Resources; - sourceTree = ""; - }; /* End PBXGroup section */ /* Begin PBXNativeTarget section */ - 3D5FCF732767887E00D3211F /* Example-iOS */ = { + 3D5FCF732767887E00D3211F /* Example */ = { isa = PBXNativeTarget; - buildConfigurationList = 3D5FCF822767888000D3211F /* Build configuration list for PBXNativeTarget "Example-iOS" */; + buildConfigurationList = 3D5FCF822767888000D3211F /* Build configuration list for PBXNativeTarget "Example" */; buildPhases = ( 3D5FCF702767887E00D3211F /* Sources */, 3D5FCF712767887E00D3211F /* Frameworks */, @@ -113,7 +86,7 @@ ); dependencies = ( ); - name = "Example-iOS"; + name = Example; packageProductDependencies = ( 3D5FCF87276788FE00D3211F /* WhatsNewKit */, ); @@ -121,26 +94,6 @@ productReference = 3D5FCF742767887F00D3211F /* WhatsNewKit-Example.app */; productType = "com.apple.product-type.application"; }; - 3D9996B7276E10CE00438FB6 /* Example-macOS */ = { - isa = PBXNativeTarget; - buildConfigurationList = 3D9996C4276E10D000438FB6 /* Build configuration list for PBXNativeTarget "Example-macOS" */; - buildPhases = ( - 3D9996B4276E10CE00438FB6 /* Sources */, - 3D9996B5276E10CE00438FB6 /* Frameworks */, - 3D9996B6276E10CE00438FB6 /* Resources */, - ); - buildRules = ( - ); - dependencies = ( - ); - name = "Example-macOS"; - packageProductDependencies = ( - 3D9996CC276E118C00438FB6 /* WhatsNewKit */, - ); - productName = "Example-macOS"; - productReference = 3D9996B8276E10CE00438FB6 /* Example-macOS.app */; - productType = "com.apple.product-type.application"; - }; /* End PBXNativeTarget section */ /* Begin PBXProject section */ @@ -154,9 +107,6 @@ 3D5FCF732767887E00D3211F = { CreatedOnToolsVersion = 13.1; }; - 3D9996B7276E10CE00438FB6 = { - CreatedOnToolsVersion = 13.2; - }; }; }; buildConfigurationList = 3D5FCF6F2767887E00D3211F /* Build configuration list for PBXProject "Example" */; @@ -172,8 +122,7 @@ projectDirPath = ""; projectRoot = ""; targets = ( - 3D5FCF732767887E00D3211F /* Example-iOS */, - 3D9996B7276E10CE00438FB6 /* Example-macOS */, + 3D5FCF732767887E00D3211F /* Example */, ); }; /* End PBXProject section */ @@ -183,15 +132,7 @@ isa = PBXResourcesBuildPhase; buildActionMask = 2147483647; files = ( - 3D999705276E144B00438FB6 /* Assets-iOS.xcassets in Resources */, - ); - runOnlyForDeploymentPostprocessing = 0; - }; - 3D9996B6276E10CE00438FB6 /* Resources */ = { - isa = PBXResourcesBuildPhase; - buildActionMask = 2147483647; - files = ( - 3D999702276E141A00438FB6 /* Assets-macOS.xcassets in Resources */, + 3D999705276E144B00438FB6 /* Assets.xcassets in Resources */, ); runOnlyForDeploymentPostprocessing = 0; }; @@ -208,16 +149,6 @@ ); runOnlyForDeploymentPostprocessing = 0; }; - 3D9996B4276E10CE00438FB6 /* Sources */ = { - isa = PBXSourcesBuildPhase; - buildActionMask = 2147483647; - files = ( - 3D9996C9276E112C00438FB6 /* ContentView.swift in Sources */, - 3D9996CB276E113100438FB6 /* App.swift in Sources */, - 3D9996C8276E112A00438FB6 /* ExamplesView.swift in Sources */, - ); - runOnlyForDeploymentPostprocessing = 0; - }; /* End PBXSourcesBuildPhase section */ /* Begin XCBuildConfiguration section */ @@ -273,7 +204,7 @@ GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; GCC_WARN_UNUSED_FUNCTION = YES; GCC_WARN_UNUSED_VARIABLE = YES; - IPHONEOS_DEPLOYMENT_TARGET = 15.0; + IPHONEOS_DEPLOYMENT_TARGET = 17.0; MTL_ENABLE_DEBUG_INFO = INCLUDE_SOURCE; MTL_FAST_MATH = YES; ONLY_ACTIVE_ARCH = YES; @@ -329,7 +260,7 @@ GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; GCC_WARN_UNUSED_FUNCTION = YES; GCC_WARN_UNUSED_VARIABLE = YES; - IPHONEOS_DEPLOYMENT_TARGET = 15.0; + IPHONEOS_DEPLOYMENT_TARGET = 17.0; MTL_ENABLE_DEBUG_INFO = NO; MTL_FAST_MATH = YES; SDKROOT = iphoneos; @@ -342,7 +273,7 @@ 3D5FCF832767888000D3211F /* Debug */ = { isa = XCBuildConfiguration; buildSettings = { - ASSETCATALOG_COMPILER_APPICON_NAME = "AppIcon-iOS"; + ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; ASSETCATALOG_COMPILER_GLOBAL_ACCENT_COLOR_NAME = AccentColor; CODE_SIGN_STYLE = Automatic; CURRENT_PROJECT_VERSION = 1; @@ -354,15 +285,18 @@ INFOPLIST_KEY_UILaunchScreen_Generation = YES; INFOPLIST_KEY_UISupportedInterfaceOrientations_iPad = "UIInterfaceOrientationPortrait UIInterfaceOrientationPortraitUpsideDown UIInterfaceOrientationLandscapeLeft UIInterfaceOrientationLandscapeRight"; INFOPLIST_KEY_UISupportedInterfaceOrientations_iPhone = "UIInterfaceOrientationPortrait UIInterfaceOrientationLandscapeLeft UIInterfaceOrientationLandscapeRight"; + IPHONEOS_DEPLOYMENT_TARGET = 17.0; LD_RUNPATH_SEARCH_PATHS = ( "$(inherited)", "@executable_path/Frameworks", ); + MACOSX_DEPLOYMENT_TARGET = 14.0; MARKETING_VERSION = 1.0; PRODUCT_BUNDLE_IDENTIFIER = "de.tiigi.WhatsNewKit.Example-iOS"; PRODUCT_NAME = "WhatsNewKit-Example"; - SUPPORTED_PLATFORMS = "iphoneos iphonesimulator xros xrsimulator"; + SUPPORTED_PLATFORMS = "iphoneos iphonesimulator macosx xros xrsimulator"; SUPPORTS_MACCATALYST = NO; + SUPPORTS_MAC_DESIGNED_FOR_IPHONE_IPAD = NO; SUPPORTS_XR_DESIGNED_FOR_IPHONE_IPAD = NO; SWIFT_EMIT_LOC_STRINGS = YES; SWIFT_VERSION = 5.0; @@ -373,7 +307,7 @@ 3D5FCF842767888000D3211F /* Release */ = { isa = XCBuildConfiguration; buildSettings = { - ASSETCATALOG_COMPILER_APPICON_NAME = "AppIcon-iOS"; + ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; ASSETCATALOG_COMPILER_GLOBAL_ACCENT_COLOR_NAME = AccentColor; CODE_SIGN_STYLE = Automatic; CURRENT_PROJECT_VERSION = 1; @@ -385,15 +319,18 @@ INFOPLIST_KEY_UILaunchScreen_Generation = YES; INFOPLIST_KEY_UISupportedInterfaceOrientations_iPad = "UIInterfaceOrientationPortrait UIInterfaceOrientationPortraitUpsideDown UIInterfaceOrientationLandscapeLeft UIInterfaceOrientationLandscapeRight"; INFOPLIST_KEY_UISupportedInterfaceOrientations_iPhone = "UIInterfaceOrientationPortrait UIInterfaceOrientationLandscapeLeft UIInterfaceOrientationLandscapeRight"; + IPHONEOS_DEPLOYMENT_TARGET = 17.0; LD_RUNPATH_SEARCH_PATHS = ( "$(inherited)", "@executable_path/Frameworks", ); + MACOSX_DEPLOYMENT_TARGET = 14.0; MARKETING_VERSION = 1.0; PRODUCT_BUNDLE_IDENTIFIER = "de.tiigi.WhatsNewKit.Example-iOS"; PRODUCT_NAME = "WhatsNewKit-Example"; - SUPPORTED_PLATFORMS = "iphoneos iphonesimulator xros xrsimulator"; + SUPPORTED_PLATFORMS = "iphoneos iphonesimulator macosx xros xrsimulator"; SUPPORTS_MACCATALYST = NO; + SUPPORTS_MAC_DESIGNED_FOR_IPHONE_IPAD = NO; SUPPORTS_XR_DESIGNED_FOR_IPHONE_IPAD = NO; SWIFT_EMIT_LOC_STRINGS = YES; SWIFT_VERSION = 5.0; @@ -401,64 +338,6 @@ }; name = Release; }; - 3D9996C5276E10D000438FB6 /* Debug */ = { - isa = XCBuildConfiguration; - buildSettings = { - ASSETCATALOG_COMPILER_APPICON_NAME = "AppIcon-macOS"; - ASSETCATALOG_COMPILER_GLOBAL_ACCENT_COLOR_NAME = AccentColor; - CODE_SIGN_ENTITLEMENTS = Example/Resources/Entitlements.entitlements; - CODE_SIGN_IDENTITY = "-"; - CODE_SIGN_STYLE = Automatic; - COMBINE_HIDPI_IMAGES = YES; - CURRENT_PROJECT_VERSION = 1; - DEAD_CODE_STRIPPING = YES; - DEVELOPMENT_ASSET_PATHS = ""; - ENABLE_PREVIEWS = YES; - GENERATE_INFOPLIST_FILE = YES; - INFOPLIST_KEY_NSHumanReadableCopyright = ""; - LD_RUNPATH_SEARCH_PATHS = ( - "$(inherited)", - "@executable_path/../Frameworks", - ); - MACOSX_DEPLOYMENT_TARGET = 12.1; - MARKETING_VERSION = 1.0; - PRODUCT_BUNDLE_IDENTIFIER = "de.tiigi.WhatsNewKit.Example-macOS"; - PRODUCT_NAME = "$(TARGET_NAME)"; - SDKROOT = macosx; - SWIFT_EMIT_LOC_STRINGS = YES; - SWIFT_VERSION = 5.0; - }; - name = Debug; - }; - 3D9996C6276E10D000438FB6 /* Release */ = { - isa = XCBuildConfiguration; - buildSettings = { - ASSETCATALOG_COMPILER_APPICON_NAME = "AppIcon-macOS"; - ASSETCATALOG_COMPILER_GLOBAL_ACCENT_COLOR_NAME = AccentColor; - CODE_SIGN_ENTITLEMENTS = Example/Resources/Entitlements.entitlements; - CODE_SIGN_IDENTITY = "-"; - CODE_SIGN_STYLE = Automatic; - COMBINE_HIDPI_IMAGES = YES; - CURRENT_PROJECT_VERSION = 1; - DEAD_CODE_STRIPPING = YES; - DEVELOPMENT_ASSET_PATHS = ""; - ENABLE_PREVIEWS = YES; - GENERATE_INFOPLIST_FILE = YES; - INFOPLIST_KEY_NSHumanReadableCopyright = ""; - LD_RUNPATH_SEARCH_PATHS = ( - "$(inherited)", - "@executable_path/../Frameworks", - ); - MACOSX_DEPLOYMENT_TARGET = 12.1; - MARKETING_VERSION = 1.0; - PRODUCT_BUNDLE_IDENTIFIER = "de.tiigi.WhatsNewKit.Example-macOS"; - PRODUCT_NAME = "$(TARGET_NAME)"; - SDKROOT = macosx; - SWIFT_EMIT_LOC_STRINGS = YES; - SWIFT_VERSION = 5.0; - }; - name = Release; - }; /* End XCBuildConfiguration section */ /* Begin XCConfigurationList section */ @@ -471,7 +350,7 @@ defaultConfigurationIsVisible = 0; defaultConfigurationName = Release; }; - 3D5FCF822767888000D3211F /* Build configuration list for PBXNativeTarget "Example-iOS" */ = { + 3D5FCF822767888000D3211F /* Build configuration list for PBXNativeTarget "Example" */ = { isa = XCConfigurationList; buildConfigurations = ( 3D5FCF832767888000D3211F /* Debug */, @@ -480,15 +359,6 @@ defaultConfigurationIsVisible = 0; defaultConfigurationName = Release; }; - 3D9996C4276E10D000438FB6 /* Build configuration list for PBXNativeTarget "Example-macOS" */ = { - isa = XCConfigurationList; - buildConfigurations = ( - 3D9996C5276E10D000438FB6 /* Debug */, - 3D9996C6276E10D000438FB6 /* Release */, - ); - defaultConfigurationIsVisible = 0; - defaultConfigurationName = Release; - }; /* End XCConfigurationList section */ /* Begin XCSwiftPackageProductDependency section */ @@ -496,10 +366,6 @@ isa = XCSwiftPackageProductDependency; productName = WhatsNewKit; }; - 3D9996CC276E118C00438FB6 /* WhatsNewKit */ = { - isa = XCSwiftPackageProductDependency; - productName = WhatsNewKit; - }; /* End XCSwiftPackageProductDependency section */ }; rootObject = 3D5FCF6C2767887E00D3211F /* Project object */; diff --git a/Example/Example.xcodeproj/xcshareddata/xcschemes/Example-macOS.xcscheme b/Example/Example.xcodeproj/xcshareddata/xcschemes/Example-macOS.xcscheme deleted file mode 100644 index 7a55684..0000000 --- a/Example/Example.xcodeproj/xcshareddata/xcschemes/Example-macOS.xcscheme +++ /dev/null @@ -1,78 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/Example/Example.xcodeproj/xcshareddata/xcschemes/Example-iOS.xcscheme b/Example/Example.xcodeproj/xcshareddata/xcschemes/Example.xcscheme similarity index 95% rename from Example/Example.xcodeproj/xcshareddata/xcschemes/Example-iOS.xcscheme rename to Example/Example.xcodeproj/xcshareddata/xcschemes/Example.xcscheme index 899d3c9..2e077aa 100644 --- a/Example/Example.xcodeproj/xcshareddata/xcschemes/Example-iOS.xcscheme +++ b/Example/Example.xcodeproj/xcshareddata/xcschemes/Example.xcscheme @@ -16,7 +16,7 @@ BuildableIdentifier = "primary" BlueprintIdentifier = "3D5FCF732767887E00D3211F" BuildableName = "WhatsNewKit-Example.app" - BlueprintName = "Example-iOS" + BlueprintName = "Example" ReferencedContainer = "container:Example.xcodeproj"> @@ -46,7 +46,7 @@ BuildableIdentifier = "primary" BlueprintIdentifier = "3D5FCF732767887E00D3211F" BuildableName = "WhatsNewKit-Example.app" - BlueprintName = "Example-iOS" + BlueprintName = "Example" ReferencedContainer = "container:Example.xcodeproj"> @@ -63,7 +63,7 @@ BuildableIdentifier = "primary" BlueprintIdentifier = "3D5FCF732767887E00D3211F" BuildableName = "WhatsNewKit-Example.app" - BlueprintName = "Example-iOS" + BlueprintName = "Example" ReferencedContainer = "container:Example.xcodeproj"> diff --git a/Example/Example/Resources/Assets-iOS.xcassets/AccentColor.colorset/Contents.json b/Example/Example/Assets.xcassets/AccentColor.colorset/Contents.json similarity index 100% rename from Example/Example/Resources/Assets-iOS.xcassets/AccentColor.colorset/Contents.json rename to Example/Example/Assets.xcassets/AccentColor.colorset/Contents.json diff --git a/Example/Example/Resources/Assets-iOS.xcassets/AppIcon-iOS.appiconset/AppIcon-1024px.png b/Example/Example/Assets.xcassets/AppIcon.appiconset/AppIcon-1024px.png similarity index 100% rename from Example/Example/Resources/Assets-iOS.xcassets/AppIcon-iOS.appiconset/AppIcon-1024px.png rename to Example/Example/Assets.xcassets/AppIcon.appiconset/AppIcon-1024px.png diff --git a/Example/Example/Resources/Assets-macOS.xcassets/AppIcon-macOS.appiconset/Contents.json b/Example/Example/Assets.xcassets/AppIcon.appiconset/Contents.json similarity index 91% rename from Example/Example/Resources/Assets-macOS.xcassets/AppIcon-macOS.appiconset/Contents.json rename to Example/Example/Assets.xcassets/AppIcon.appiconset/Contents.json index f93a293..d2ac95b 100644 --- a/Example/Example/Resources/Assets-macOS.xcassets/AppIcon-macOS.appiconset/Contents.json +++ b/Example/Example/Assets.xcassets/AppIcon.appiconset/Contents.json @@ -1,5 +1,11 @@ { "images" : [ + { + "filename" : "AppIcon-1024px.png", + "idiom" : "universal", + "platform" : "ios", + "size" : "1024x1024" + }, { "filename" : "macOS-AppIcon-16px-16pt@1x.png", "idiom" : "mac", diff --git a/Example/Example/Resources/Assets-macOS.xcassets/AppIcon-macOS.appiconset/macOS-AppIcon-1024px.png b/Example/Example/Assets.xcassets/AppIcon.appiconset/macOS-AppIcon-1024px.png similarity index 100% rename from Example/Example/Resources/Assets-macOS.xcassets/AppIcon-macOS.appiconset/macOS-AppIcon-1024px.png rename to Example/Example/Assets.xcassets/AppIcon.appiconset/macOS-AppIcon-1024px.png diff --git a/Example/Example/Resources/Assets-macOS.xcassets/AppIcon-macOS.appiconset/macOS-AppIcon-128px-128pt@1x.png b/Example/Example/Assets.xcassets/AppIcon.appiconset/macOS-AppIcon-128px-128pt@1x.png similarity index 100% rename from Example/Example/Resources/Assets-macOS.xcassets/AppIcon-macOS.appiconset/macOS-AppIcon-128px-128pt@1x.png rename to Example/Example/Assets.xcassets/AppIcon.appiconset/macOS-AppIcon-128px-128pt@1x.png diff --git a/Example/Example/Resources/Assets-macOS.xcassets/AppIcon-macOS.appiconset/macOS-AppIcon-16px-16pt@1x.png b/Example/Example/Assets.xcassets/AppIcon.appiconset/macOS-AppIcon-16px-16pt@1x.png similarity index 100% rename from Example/Example/Resources/Assets-macOS.xcassets/AppIcon-macOS.appiconset/macOS-AppIcon-16px-16pt@1x.png rename to Example/Example/Assets.xcassets/AppIcon.appiconset/macOS-AppIcon-16px-16pt@1x.png diff --git a/Example/Example/Resources/Assets-macOS.xcassets/AppIcon-macOS.appiconset/macOS-AppIcon-256px-128pt@2x.png b/Example/Example/Assets.xcassets/AppIcon.appiconset/macOS-AppIcon-256px-128pt@2x.png similarity index 100% rename from Example/Example/Resources/Assets-macOS.xcassets/AppIcon-macOS.appiconset/macOS-AppIcon-256px-128pt@2x.png rename to Example/Example/Assets.xcassets/AppIcon.appiconset/macOS-AppIcon-256px-128pt@2x.png diff --git a/Example/Example/Resources/Assets-macOS.xcassets/AppIcon-macOS.appiconset/macOS-AppIcon-256px-256pt@1x.png b/Example/Example/Assets.xcassets/AppIcon.appiconset/macOS-AppIcon-256px-256pt@1x.png similarity index 100% rename from Example/Example/Resources/Assets-macOS.xcassets/AppIcon-macOS.appiconset/macOS-AppIcon-256px-256pt@1x.png rename to Example/Example/Assets.xcassets/AppIcon.appiconset/macOS-AppIcon-256px-256pt@1x.png diff --git a/Example/Example/Resources/Assets-macOS.xcassets/AppIcon-macOS.appiconset/macOS-AppIcon-32px-16pt@2x.png b/Example/Example/Assets.xcassets/AppIcon.appiconset/macOS-AppIcon-32px-16pt@2x.png similarity index 100% rename from Example/Example/Resources/Assets-macOS.xcassets/AppIcon-macOS.appiconset/macOS-AppIcon-32px-16pt@2x.png rename to Example/Example/Assets.xcassets/AppIcon.appiconset/macOS-AppIcon-32px-16pt@2x.png diff --git a/Example/Example/Resources/Assets-macOS.xcassets/AppIcon-macOS.appiconset/macOS-AppIcon-32px-32pt@1x.png b/Example/Example/Assets.xcassets/AppIcon.appiconset/macOS-AppIcon-32px-32pt@1x.png similarity index 100% rename from Example/Example/Resources/Assets-macOS.xcassets/AppIcon-macOS.appiconset/macOS-AppIcon-32px-32pt@1x.png rename to Example/Example/Assets.xcassets/AppIcon.appiconset/macOS-AppIcon-32px-32pt@1x.png diff --git a/Example/Example/Resources/Assets-macOS.xcassets/AppIcon-macOS.appiconset/macOS-AppIcon-512px-256pt@2x.png b/Example/Example/Assets.xcassets/AppIcon.appiconset/macOS-AppIcon-512px-256pt@2x.png similarity index 100% rename from Example/Example/Resources/Assets-macOS.xcassets/AppIcon-macOS.appiconset/macOS-AppIcon-512px-256pt@2x.png rename to Example/Example/Assets.xcassets/AppIcon.appiconset/macOS-AppIcon-512px-256pt@2x.png diff --git a/Example/Example/Resources/Assets-macOS.xcassets/AppIcon-macOS.appiconset/macOS-AppIcon-512px.png b/Example/Example/Assets.xcassets/AppIcon.appiconset/macOS-AppIcon-512px.png similarity index 100% rename from Example/Example/Resources/Assets-macOS.xcassets/AppIcon-macOS.appiconset/macOS-AppIcon-512px.png rename to Example/Example/Assets.xcassets/AppIcon.appiconset/macOS-AppIcon-512px.png diff --git a/Example/Example/Resources/Assets-macOS.xcassets/AppIcon-macOS.appiconset/macOS-AppIcon-64px-32pt@2x.png b/Example/Example/Assets.xcassets/AppIcon.appiconset/macOS-AppIcon-64px-32pt@2x.png similarity index 100% rename from Example/Example/Resources/Assets-macOS.xcassets/AppIcon-macOS.appiconset/macOS-AppIcon-64px-32pt@2x.png rename to Example/Example/Assets.xcassets/AppIcon.appiconset/macOS-AppIcon-64px-32pt@2x.png diff --git a/Example/Example/Resources/Assets-iOS.xcassets/Contents.json b/Example/Example/Assets.xcassets/Contents.json similarity index 100% rename from Example/Example/Resources/Assets-iOS.xcassets/Contents.json rename to Example/Example/Assets.xcassets/Contents.json diff --git a/Example/Example/ContentView.swift b/Example/Example/ContentView.swift index 278a0b1..5af7366 100644 --- a/Example/Example/ContentView.swift +++ b/Example/Example/ContentView.swift @@ -12,15 +12,8 @@ extension ContentView: View { /// The content and behavior of the view var body: some View { - Group { - #if os(macOS) + NavigationStack { ExamplesView() - #else - NavigationView { - ExamplesView() - } - .navigationViewStyle(.stack) - #endif } .whatsNewSheet() } diff --git a/Example/Example/Resources/Assets-iOS.xcassets/AppIcon-iOS.appiconset/Contents.json b/Example/Example/Resources/Assets-iOS.xcassets/AppIcon-iOS.appiconset/Contents.json deleted file mode 100644 index 9241206..0000000 --- a/Example/Example/Resources/Assets-iOS.xcassets/AppIcon-iOS.appiconset/Contents.json +++ /dev/null @@ -1,14 +0,0 @@ -{ - "images" : [ - { - "filename" : "AppIcon-1024px.png", - "idiom" : "universal", - "platform" : "ios", - "size" : "1024x1024" - } - ], - "info" : { - "author" : "xcode", - "version" : 1 - } -} diff --git a/Example/Example/Resources/Assets-macOS.xcassets/AccentColor.colorset/Contents.json b/Example/Example/Resources/Assets-macOS.xcassets/AccentColor.colorset/Contents.json deleted file mode 100644 index 6112869..0000000 --- a/Example/Example/Resources/Assets-macOS.xcassets/AccentColor.colorset/Contents.json +++ /dev/null @@ -1,15 +0,0 @@ -{ - "colors" : [ - { - "color" : { - "platform" : "universal", - "reference" : "systemBlueColor" - }, - "idiom" : "universal" - } - ], - "info" : { - "author" : "xcode", - "version" : 1 - } -} diff --git a/Example/Example/Resources/Assets-macOS.xcassets/Contents.json b/Example/Example/Resources/Assets-macOS.xcassets/Contents.json deleted file mode 100644 index 73c0059..0000000 --- a/Example/Example/Resources/Assets-macOS.xcassets/Contents.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "info" : { - "author" : "xcode", - "version" : 1 - } -} diff --git a/Example/Example/Resources/Entitlements.entitlements b/Example/Example/Resources/Entitlements.entitlements deleted file mode 100644 index f2ef3ae..0000000 --- a/Example/Example/Resources/Entitlements.entitlements +++ /dev/null @@ -1,10 +0,0 @@ - - - - - com.apple.security.app-sandbox - - com.apple.security.files.user-selected.read-only - - - From 3b94b3bf6feb01b7bbe5373f5f21219650cf7e96 Mon Sep 17 00:00:00 2001 From: Sven Tiigi Date: Sat, 20 Jan 2024 23:19:48 +0100 Subject: [PATCH 10/13] Use primary as default for visionOS --- Sources/Models/WhatsNew+SecondaryAction.swift | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/Sources/Models/WhatsNew+SecondaryAction.swift b/Sources/Models/WhatsNew+SecondaryAction.swift index 2d840fa..f1b9798 100644 --- a/Sources/Models/WhatsNew+SecondaryAction.swift +++ b/Sources/Models/WhatsNew+SecondaryAction.swift @@ -31,7 +31,13 @@ public extension WhatsNew { /// - action: The Action public init( title: Text, - foregroundColor: Color = .accentColor, + foregroundColor: Color = { + #if os(visionOS) + .primary + #else + .accentColor + #endif + }(), hapticFeedback: HapticFeedback? = nil, action: Action ) { From 91103be81510f531e72f147535ebf8ba5dea56dd Mon Sep 17 00:00:00 2001 From: Sven Tiigi Date: Sun, 28 Jan 2024 18:30:34 +0100 Subject: [PATCH 11/13] Updated compiler directive for visionOS platform --- Sources/View/WhatsNewView+FeaturesPadding.swift | 4 ++-- Sources/View/WhatsNewView+FooterPadding.swift | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/Sources/View/WhatsNewView+FeaturesPadding.swift b/Sources/View/WhatsNewView+FeaturesPadding.swift index 8592275..21ace7a 100644 --- a/Sources/View/WhatsNewView+FeaturesPadding.swift +++ b/Sources/View/WhatsNewView+FeaturesPadding.swift @@ -7,7 +7,7 @@ extension WhatsNewView { /// The WhatsNewView FeaturesPadding ViewModifier struct FeaturesPadding { - #if os(iOS) + #if os(iOS) || os(visionOS) /// The Horizontal SizeClass @Environment(\.horizontalSizeClass) private var horizontalSizeClass @@ -30,7 +30,7 @@ extension WhatsNewView.FeaturesPadding: ViewModifier { func body( content: Content ) -> some View { - #if os(macOS) || os(visionOS) + #if os(macOS) content.padding(.horizontal) #else if self.horizontalSizeClass == .regular { diff --git a/Sources/View/WhatsNewView+FooterPadding.swift b/Sources/View/WhatsNewView+FooterPadding.swift index 300ecc3..34b2580 100644 --- a/Sources/View/WhatsNewView+FooterPadding.swift +++ b/Sources/View/WhatsNewView+FooterPadding.swift @@ -7,7 +7,7 @@ extension WhatsNewView { /// The WhatsNewView FooterPadding ViewModifier struct FooterPadding { - #if os(iOS) + #if os(iOS) || os(visionOS) /// The Horizontal SizeClass @Environment(\.horizontalSizeClass) private var horizontalSizeClass @@ -30,7 +30,7 @@ extension WhatsNewView.FooterPadding: ViewModifier { func body( content: Content ) -> some View { - #if os(macOS) || os(visionOS) + #if os(macOS) content.padding(.bottom, 30) #else if self.horizontalSizeClass == .regular { From 75b4b608b68c6e2ca56523c51321f9bc23ec84b6 Mon Sep 17 00:00:00 2001 From: Sven Tiigi Date: Sun, 28 Jan 2024 18:33:18 +0100 Subject: [PATCH 12/13] Include visionOS --- Sources/Extensions/Text+WhatsNewText.swift | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Sources/Extensions/Text+WhatsNewText.swift b/Sources/Extensions/Text+WhatsNewText.swift index 702864d..0f11e05 100644 --- a/Sources/Extensions/Text+WhatsNewText.swift +++ b/Sources/Extensions/Text+WhatsNewText.swift @@ -10,7 +10,7 @@ extension Text { whatsNewText: WhatsNew.Text ) { // Check if iOS 15 or greater is available - if #available(iOS 15.0, macOS 12.0, *) { + if #available(iOS 15.0, macOS 12.0, visionOS 1.0, *) { // Initialize with AttributedString self.init( AttributedString( From b67d126029c8cb44912a51672c7f9dfa56068b27 Mon Sep 17 00:00:00 2001 From: Sven Tiigi Date: Thu, 1 Feb 2024 20:25:49 +0100 Subject: [PATCH 13/13] Use macos-14 --- .github/workflows/build_and_test.yml | 4 ++-- .github/workflows/build_example_project.yml | 2 +- .github/workflows/deploy_documentation.yml | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/.github/workflows/build_and_test.yml b/.github/workflows/build_and_test.yml index 2ee5ade..9dc3345 100644 --- a/.github/workflows/build_and_test.yml +++ b/.github/workflows/build_and_test.yml @@ -16,7 +16,7 @@ on: jobs: iOS: name: Build and test on iOS - runs-on: macos-latest + runs-on: macos-14 steps: - uses: actions/checkout@v3 - name: Build @@ -25,7 +25,7 @@ jobs: run: xcodebuild test-without-building -scheme WhatsNewKit -destination 'platform=iOS Simulator,name=iPhone 14' macOS: name: Build and test on macOS - runs-on: macos-latest + runs-on: macos-14 steps: - uses: actions/checkout@v3 - name: Build diff --git a/.github/workflows/build_example_project.yml b/.github/workflows/build_example_project.yml index d40cd55..a43e69f 100644 --- a/.github/workflows/build_example_project.yml +++ b/.github/workflows/build_example_project.yml @@ -14,7 +14,7 @@ on: jobs: build: name: Build iOS example project - runs-on: macos-latest + runs-on: macos-14 steps: - name: Checkout uses: actions/checkout@v2 diff --git a/.github/workflows/deploy_documentation.yml b/.github/workflows/deploy_documentation.yml index 80e9966..99c1bf4 100644 --- a/.github/workflows/deploy_documentation.yml +++ b/.github/workflows/deploy_documentation.yml @@ -17,7 +17,7 @@ concurrency: jobs: build: - runs-on: macos-latest + runs-on: macos-14 steps: - name: Checkout uses: actions/checkout@v3