diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml
index 2a2ac5d8..3a660220 100644
--- a/.github/workflows/build.yml
+++ b/.github/workflows/build.yml
@@ -1,6 +1,6 @@
on:
push:
- branches:
+ branches:
- master
name: Build
jobs:
@@ -10,14 +10,28 @@ jobs:
strategy:
matrix:
destination: [
- 'platform=iOS Simulator,OS=12.4,name=iPhone X',
- 'platform=tvOS Simulator,OS=12.4,name=Apple TV 4']
+ 'platform=Any iOS Simulator',
+ 'platform=Any tvOS Simulator',
+ 'platform=macOS,arch=x86_64',
+ 'platform=macOS,arch=arm64',
+ 'platform=macCatalyst,arch=x86_64',
+ 'platform=macCatalyst,arch=arm64',
+ ]
steps:
- name: Checkout
uses: actions/checkout@master
- name: Build
run: |
pod install
- set -o pipefail && xcodebuild clean build -workspace Hero.xcworkspace -scheme Hero -destination "${destination}" CODE_SIGN_IDENTITY="" CODE_SIGNING_REQUIRED=NO ONLY_ACTIVE_ARCH=NO
- env:
- destination: ${{ matrix.destination }}
\ No newline at end of file
+ set -o pipefail && \
+ xcodebuild clean build \
+ -workspace Hero.xcworkspace \
+ -scheme Hero \
+ -destination "${destination}" \
+ -parallelizeTargets -showBuildTimingSummary \
+ -enableCodeCoverage YES \
+ CODE_SIGN_IDENTITY="" \
+ CODE_SIGNING_REQUIRED=NO \
+ | xcpretty
+ env:
+ destination: ${{ matrix.destination }}
diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml
index eba75f01..0aeabec2 100644
--- a/.github/workflows/test.yml
+++ b/.github/workflows/test.yml
@@ -1,22 +1,23 @@
+# test.yml
+# Unit Test
name: Unit Test
-
-on:
+'on':
pull_request:
paths:
- - "**.swift"
- - "**.xcodeproj"
- - "**.m"
- - "**.h"
- - "**.podspec"
- - "Podfile"
- - "Podfile.lock"
- - "test.yml"
+ - '**.swift'
+ - '**.xcodeproj'
+ - '**.m'
+ - '**.h'
+ - '**.podspec'
+ - Podfile
+ - Podfile.lock
+ - '**/test.yml'
jobs:
swiftpm:
name: Test iOS (swiftpm)
runs-on: macOS-latest
env:
- DEVELOPER_DIR: /Applications/Xcode_12.4.app/Contents/Developer
+ DEVELOPER_DIR: /Applications/Xcode_14.2.app/Contents/Developer
steps:
- name: Checkout
uses: actions/checkout@master
@@ -24,75 +25,42 @@ jobs:
run: |
pod install
set -o pipefail && swift test --parallel
- iOS:
+ XCode:
name: Test iOS
runs-on: macOS-latest
env:
- DEVELOPER_DIR: /Applications/Xcode_12.4.app/Contents/Developer
+ DEVELOPER_DIR: /Applications/Xcode_14.2.app/Contents/Developer
strategy:
- matrix:
- destination: [
- 'platform=iOS Simulator,OS=14.4,name=iPhone 12'
- ]
+ matrix:
+ run-config:
+ - scheme: Hero
+ platform: iOS
+ action: test
+ code-coverage: true
+ - scheme: Hero (tvOS)
+ platform: tvOS
+ action: build
+ code-coverage: false
steps:
- name: Checkout
uses: actions/checkout@master
- - name: iOS - ${{ matrix.destination }}
+ - name: CocoaPods - ${{ matrix.run-config.destination }}
run: |
pod install
- set -o pipefail && xcodebuild clean test -workspace Hero.xcworkspace -scheme Hero -destination "${destination}" -configuration "Debug" -showBuildTimingSummary -enableThreadSanitizer YES -enableCodeCoverage YES CODE_SIGN_IDENTITY="" CODE_SIGNING_REQUIRED=NO ONLY_ACTIVE_ARCH=YES | xcpretty
- bash <(curl -s https://codecov.io/bash)
- env:
- destination: ${{ matrix.destination }}
- - name: Upload Code Coverage
- run: |
- bash <(curl -s https://codecov.io/bash)
- env:
- CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
- # iOS-legacy:
- # name: Test iOS
- # runs-on: macOS-latest
- # env:
- # DEVELOPER_DIR: /Applications/Xcode_10.3.1.app/Contents/Developer
- # strategy:
- # matrix:
- # destination: [
- # 'platform=iOS Simulator,OS=10.3.1,name=iPhone 7'
- # ]
- # steps:
- # - name: Checkout
- # uses: actions/checkout@master
- # - name: iOS - ${{ matrix.destination }}
- # run: |
- # xcversion simulators --install='iOS 10.3.1'
- # pod install
- # set -o pipefail && xcodebuild clean test -workspace Hero.xcworkspace -scheme Hero -destination "${destination}" -parallelizeTargets -showBuildTimingSummary -enableThreadSanitizer YES -enableCodeCoverage YES CODE_SIGN_IDENTITY="" CODE_SIGNING_REQUIRED=NO ONLY_ACTIVE_ARCH=NO | xcpretty
- # bash <(curl -s https://codecov.io/bash)
- # env:
- # destination: ${{ matrix.destination }}
- # - name: Upload Code Coverage
- # run: |
- # bash <(curl -s https://codecov.io/bash)
- # env:
- # CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
- tvOS:
- name: Test tvOS
- runs-on: macOS-latest
- env:
- DEVELOPER_DIR: /Applications/Xcode_12.4.app/Contents/Developer
- strategy:
- matrix:
- destination: [
- 'platform=tvOS Simulator,OS=14.3,name=Apple TV 4K'
- ]
- steps:
- - name: Checkout
- uses: actions/checkout@master
- - name: tvOS - ${{ matrix.destination }}
- run: |
- pod install
- set -o pipefail && xcodebuild clean build -workspace Hero.xcworkspace -scheme "Hero (tvOS)" -destination "${destination}" -parallelizeTargets -showBuildTimingSummary -enableThreadSanitizer YES CODE_SIGN_IDENTITY="" CODE_SIGNING_REQUIRED=NO ONLY_ACTIVE_ARCH=YES | xcpretty
- env:
- destination: ${{ matrix.destination }}
+ - name: Test - ${{ matrix.run-config.platform }}
+ uses: mxcl/xcodebuild@v2.0
+ with:
+ platform: ${{ matrix.run-config.platform }}
+ action: ${{ matrix.run-config.action }}
+ code-coverage: ${{ matrix.run-config.code-coverage }}
+ configuration: Debug
+ scheme: ${{ matrix.run-config.scheme }}
+ workspace: Hero.xcworkspace
+
+ - name: Upload Code Coverage
+ uses: codecov/codecov-action@v3
+ if: ${{ matrix.run-config.code-coverage }}
+ with:
+ token: ${{ secrets.CODECOV_TOKEN }}
diff --git a/.jazzy.yaml b/.jazzy.yaml
index 25b13bfc..a1e71f45 100644
--- a/.jazzy.yaml
+++ b/.jazzy.yaml
@@ -1,6 +1,6 @@
# ---- About ----
module: Hero
-module_version: 1.6.2
+module_version: 1.6.4
author: HeroTransitions
readme: README.md
copyright: 'See [license](https://github.com/HeroTransitions/Hero/blob/develop/LICENSE) for more details.'
diff --git a/.makefiles/ios.mk b/.makefiles/ios.mk
index e6d64710..a1984d4d 100644
--- a/.makefiles/ios.mk
+++ b/.makefiles/ios.mk
@@ -187,7 +187,7 @@ test:
#> Make a .zip package of frameworks
package:
- carthage build --no-skip-current --platform $(PLATFORM)
+ carthage build --no-skip-current --platform $(PLATFORM) --use-xcframeworks --cache-builds
carthage archive $(MODULE_NAME)
#> tag and release to github
@@ -207,4 +207,3 @@ open:
#> Setup the project, git-hooks etc
init:
git config core.hooksPath .githooks
-
diff --git a/CHANGELOG.md b/CHANGELOG.md
index d0978aa7..c1f48f66 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -3,6 +3,25 @@
The changelog for `Hero`. Also see the [releases](https://github.com/HeroTransitions/Hero/releases) on GitHub.
--------------------------------------
+
+## [1.6.4](https://github.com/HeroTransitions/Hero/releases/tag/1.6.4)
+
+- Fix XCode 16
+
+## [1.6.3](https://github.com/HeroTransitions/Hero/releases/tag/1.6.3)
+
+- 1ac98e7 Adaption for visionOS.
+- 5e05761 Merge pull request #771 from HeroTransitions/feature/CICDFix
+- c9a98cf CI/CI build and test, matrix platforms fix?
+- 2f8096d build.yml test.yml update github runner env
+- 45aed92 Readme add api docs link
+- a7d2682 README.md update ios/xcode version badges
+- 211df4b README.md Add unit test and swift pm action badges
+- bff4221 swiftlint fix
+- a47dce4 Merge pull request #749 from tadija/feature/xcode14-warnings
+- fd2ba86 Fix lint warnings
+- 5c053a6 Fix build warnings with Xcode 14.0
+
## [1.6.2](https://github.com/HeroTransitions/Hero/releases/tag/1.6.2)
### Fixed
@@ -92,7 +111,7 @@ The changelog for `Hero`. Also see the [releases](https://github.com/HeroTransit
[#430](https://github.com/HeroTransitions/Hero/pull/430) by [@bradphilips](https://github.com/bradphilips)
### Fixed
-- Fixed shadows being cutoff by snapshots.
+- Fixed shadows being cutoff by snapshots.
[#440](https://github.com/HeroTransitions/Hero/pull/440) by [@2blane](https://github.com/2blane)
- Fixed animation flickering on CALayer animation.
[f4dab9](https://github.com/HeroTransitions/Hero/commit/f4dab9ed2ab88ae065605199d5aca7706b07c2ad) by [@lkzhao](https://github.com/lkzhao)
diff --git a/DEVELOP.md b/DEVELOP.md
new file mode 100644
index 00000000..4c6e3149
--- /dev/null
+++ b/DEVELOP.md
@@ -0,0 +1,19 @@
+# Develop.md
+
+## Releases
+
+1. Make release brach `git-flow release start x.x.x`
+2. Search find/replace current version in XCode project
+3. Update `CHANGELOG.md`
+4. Run swift lint autocorrect `make autocorrect`
+5. Change version in `jazzy.yml`
+6. Run `make jazzy`
+7. Commit changes.
+8. Create GitHub release
+9. Create CocoaPods release
+ 1. ` pod lib lint`
+10. Finish release
+ 1. `git-flow release finish x.x.x`
+ 2. `git push --tags`
+11. Public CocoaPod release
+ 1. `pod trunk push`
diff --git a/Hero.podspec b/Hero.podspec
index eaee1914..d2c61314 100644
--- a/Hero.podspec
+++ b/Hero.podspec
@@ -2,7 +2,7 @@
Pod::Spec.new do |s|
s.name = 'Hero'
- s.version = '1.6.2'
+ s.version = '1.6.4'
s.summary = 'Elegant transition library for iOS'
s.description = <<-DESC
diff --git a/Hero.xcodeproj/project.pbxproj b/Hero.xcodeproj/project.pbxproj
index a39b056e..1cab81a3 100644
--- a/Hero.xcodeproj/project.pbxproj
+++ b/Hero.xcodeproj/project.pbxproj
@@ -3,7 +3,7 @@
archiveVersion = 1;
classes = {
};
- objectVersion = 53;
+ objectVersion = 54;
objects = {
/* Begin PBXBuildFile section */
@@ -1201,7 +1201,6 @@
"@executable_path/Frameworks",
"@loader_path/Frameworks",
);
- MARKETING_VERSION = 1.6.2;
PRODUCT_BUNDLE_IDENTIFIER = com.lkzhao.Hero;
PRODUCT_NAME = Hero;
SDKROOT = appletvos;
@@ -1233,7 +1232,6 @@
"@executable_path/Frameworks",
"@loader_path/Frameworks",
);
- MARKETING_VERSION = 1.6.2;
PRODUCT_BUNDLE_IDENTIFIER = com.lkzhao.Hero;
PRODUCT_NAME = Hero;
SDKROOT = appletvos;
@@ -1259,7 +1257,6 @@
"$(inherited)",
"@executable_path/Frameworks",
);
- MARKETING_VERSION = 1.6.2;
PRODUCT_BUNDLE_IDENTIFIER = com.lkzhao.HeroTvOSExamples;
PRODUCT_NAME = "$(TARGET_NAME)";
SDKROOT = appletvos;
@@ -1282,7 +1279,6 @@
"$(inherited)",
"@executable_path/Frameworks",
);
- MARKETING_VERSION = 1.6.2;
PRODUCT_BUNDLE_IDENTIFIER = com.lkzhao.HeroTvOSExamples;
PRODUCT_NAME = "$(TARGET_NAME)";
SDKROOT = appletvos;
@@ -1315,7 +1311,6 @@
"@executable_path/Frameworks",
"@loader_path/Frameworks",
);
- MARKETING_VERSION = 1.6.2;
PRODUCT_BUNDLE_IDENTIFIER = com.lkzhao.Hero;
PRODUCT_NAME = Hero;
SKIP_INSTALL = YES;
@@ -1347,7 +1342,6 @@
"@executable_path/Frameworks",
"@loader_path/Frameworks",
);
- MARKETING_VERSION = 1.6.2;
PRODUCT_BUNDLE_IDENTIFIER = com.lkzhao.Hero;
PRODUCT_NAME = Hero;
SKIP_INSTALL = YES;
@@ -1409,6 +1403,7 @@
GCC_WARN_UNUSED_FUNCTION = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
IPHONEOS_DEPLOYMENT_TARGET = 10.0;
+ MARKETING_VERSION = 1.6.4;
MTL_ENABLE_DEBUG_INFO = YES;
ONLY_ACTIVE_ARCH = YES;
SDKROOT = iphoneos;
@@ -1464,6 +1459,7 @@
GCC_WARN_UNUSED_FUNCTION = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
IPHONEOS_DEPLOYMENT_TARGET = 10.0;
+ MARKETING_VERSION = 1.6.4;
MTL_ENABLE_DEBUG_INFO = NO;
SDKROOT = iphoneos;
SWIFT_COMPILATION_MODE = wholemodule;
@@ -1486,7 +1482,6 @@
"$(inherited)",
"@executable_path/Frameworks",
);
- MARKETING_VERSION = 1.6.2;
OTHER_LDFLAGS = (
"$(inherited)",
"-framework",
@@ -1519,7 +1514,6 @@
"$(inherited)",
"@executable_path/Frameworks",
);
- MARKETING_VERSION = 1.6.2;
OTHER_LDFLAGS = (
"$(inherited)",
"-framework",
diff --git a/Makefile b/Makefile
index 659e900d..e2e4f354 100644
--- a/Makefile
+++ b/Makefile
@@ -23,7 +23,7 @@ jazzy:
#> Markdown API using sourcedocs; https://github.com/eneko/SourceDocs
sourcedocs:
- @sourcedocs generate -clean --spm-module Hero --output-folder docs
+ @sourcedocs generate --clean --output-folder docs
#> Run tests
swift_test:
diff --git a/Package.md b/Package.md
new file mode 100644
index 00000000..cda49c8f
--- /dev/null
+++ b/Package.md
@@ -0,0 +1,40 @@
+# Package: **Hero**
+
+## Products
+
+List of products in this package:
+
+| Product | Type | Targets |
+| ------- | ---- | ------- |
+| Hero | library | Hero |
+
+_Libraries denoted 'automatic' can be both static or dynamic._
+
+## Modules
+
+### Program Modules
+
+| Module | Type | Dependencies |
+| ------ | ---- | ------------ |
+| Hero | Regular | |
+
+### Test Modules
+
+| Module | Type | Dependencies |
+| ------ | ---- | ------------ |
+| HeroTests | Test | |
+
+## External Dependencies
+
+This package has zero dependencies 🎉
+
+## Requirements
+
+### Minimum Required Versions
+
+| Platform | Version |
+| -------- | ------- |
+| tvOS | 10.0 |
+| iOS | 10.0 |
+
+This file was generated by [SourceDocs](https://github.com/eneko/SourceDocs) on 2024-02-06 02:01:40 +0000
\ No newline at end of file
diff --git a/PackageModules.dot b/PackageModules.dot
new file mode 100644
index 00000000..e149229c
--- /dev/null
+++ b/PackageModules.dot
@@ -0,0 +1,24 @@
+digraph ModuleDependencyGraph {
+ rankdir = LR
+ graph [fontname="Helvetica-light", style = filled, color = "#eaeaea"]
+ node [shape=box, fontname="Helvetica", style=filled]
+ edge [color="#545454"]
+
+ subgraph clusterRegular {
+ label = "Program Modules"
+ node [color="#caecec"]
+ "Hero"
+ }
+ subgraph clusterTest {
+ label = "Test Modules"
+ node [color="#aaccee"]
+ "HeroTests"
+ }
+ subgraph clusterExternal {
+ label = "External Dependencies"
+ node [color="#eeccaa"]
+ ""
+ }
+
+ "HeroTests" -> ""
+}
\ No newline at end of file
diff --git a/Podfile.lock b/Podfile.lock
index 87af3479..389011cc 100644
--- a/Podfile.lock
+++ b/Podfile.lock
@@ -15,4 +15,4 @@ SPEC CHECKSUMS:
PODFILE CHECKSUM: 5c14933c915eeee6fbe5ecdd950d3da01c4a0a86
-COCOAPODS: 1.10.1
+COCOAPODS: 1.11.3
diff --git a/README.md b/README.md
index 789e7708..e1fb8779 100644
--- a/README.md
+++ b/README.md
@@ -77,7 +77,7 @@ for cell in redCells {
You can do these in the **storyboard** too!
-
+
## Installation
@@ -150,7 +150,7 @@ let package = Package(
targets: ["MyPackage"]),
],
dependencies: [
- .package(url: "https://github.com/HeroTransitions/Hero.git", .upToNextMajor(from: "1.6.2"))
+ .package(url: "https://github.com/HeroTransitions/Hero.git", .upToNextMajor(from: "1.6.3"))
],
targets: [
.target(
diff --git a/Sources/HeroContext.swift b/Sources/HeroContext.swift
index c98b5a4a..ad1e6214 100644
--- a/Sources/HeroContext.swift
+++ b/Sources/HeroContext.swift
@@ -140,14 +140,6 @@ extension HeroContext {
unhide(view: view)
- // capture a snapshot without alpha, cornerRadius, or shadows
- let oldMaskedCorners: CACornerMask = {
- if #available(iOS 11, tvOS 11, *) {
- return view.layer.maskedCorners
- } else {
- return []
- }
- }()
let oldCornerRadius = view.layer.cornerRadius
let oldAlpha = view.alpha
let oldShadowRadius = view.layer.shadowRadius
@@ -229,7 +221,12 @@ extension HeroContext {
}
#endif
- if #available(iOS 11, tvOS 11, *) {
+ if #available(iOSApplicationExtension 11.0, tvOSApplicationExtension 11.0, iOS 11, tvOS 11, *) {
+ // capture a snapshot without alpha, cornerRadius, or shadows
+ let oldMaskedCorners: CACornerMask = {
+ return view.layer.maskedCorners
+ }()
+
view.layer.maskedCorners = oldMaskedCorners
}
view.layer.cornerRadius = oldCornerRadius
diff --git a/Sources/Transition/HeroTransition+UITabBarControllerDelegate.swift b/Sources/Transition/HeroTransition+UITabBarControllerDelegate.swift
index 2fa1daf0..525147a4 100644
--- a/Sources/Transition/HeroTransition+UITabBarControllerDelegate.swift
+++ b/Sources/Transition/HeroTransition+UITabBarControllerDelegate.swift
@@ -34,7 +34,7 @@ extension HeroTransition: UITabBarControllerDelegate {
}
return true
}
-
+#if !os(visionOS)
public func tabBarController(_ tabBarController: UITabBarController, interactionControllerFor animationController: UIViewControllerAnimatedTransitioning) -> UIViewControllerInteractiveTransitioning? {
return interactiveTransitioning
}
@@ -50,6 +50,8 @@ extension HeroTransition: UITabBarControllerDelegate {
self.inTabBarController = true
return self
}
+#endif
+
}
#endif
diff --git a/docs/Classes.html b/docs/Classes.html
index 8ea73517..62e17ac4 100644
--- a/docs/Classes.html
+++ b/docs/Classes.html
@@ -21,7 +21,7 @@