Skip to content

Commit d8f8e3c

Browse files
jonasbarkalejandro-all-win-softwareremonh87
authored
Add Swift Package Manager Support (#2019) (#2035)
* Add Swift Package Manager Support (#2019) * chore: added swift package manager support * chore: fixed issues with cocoapods * chore: updated stripe_ios changelog * chore: updated stripe_ios pubspec version * Resolve swiftpm conflicts (#2041) * Address sheet (#2020) * feat: create android binding for addresssheet * feat: create addressheet model * feat: add correct mapping for addressheet * feat: create ios addressheet implementation * fix auto close ios addressheet * fix: give widget small height to fix flutter requirements * chore: add documentation --------- Co-authored-by: Remon <[email protected]> * chore: added missing imports --------- Co-authored-by: Rémon <[email protected]> Co-authored-by: Remon <[email protected]> --------- Co-authored-by: Alejandro Castillo <[email protected]> Co-authored-by: Rémon <[email protected]> Co-authored-by: Remon <[email protected]>
1 parent b53fda8 commit d8f8e3c

Some content is hidden

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

51 files changed

+256
-57
lines changed

example/ios/Runner.xcodeproj/project.pbxproj

Lines changed: 28 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,7 @@
1616
97C146FE1CF9000F007C117D /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 97C146FD1CF9000F007C117D /* Assets.xcassets */; };
1717
97C147011CF9000F007C117D /* LaunchScreen.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 97C146FF1CF9000F007C117D /* LaunchScreen.storyboard */; };
1818
C1C00DE1D4D140D43FF1F838 /* Pods_Runner.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 0319CE3D006F4355FEBFB2E6 /* Pods_Runner.framework */; };
19+
78A318202AECB46A00862997 /* FlutterGeneratedPluginSwiftPackage in Frameworks */ = {isa = PBXBuildFile; productRef = 78A3181F2AECB46A00862997 /* FlutterGeneratedPluginSwiftPackage */; };
1920
/* End PBXBuildFile section */
2021

2122
/* Begin PBXContainerItemProxy section */
@@ -81,6 +82,7 @@
8182
isa = PBXFrameworksBuildPhase;
8283
buildActionMask = 2147483647;
8384
files = (
85+
78A318202AECB46A00862997 /* FlutterGeneratedPluginSwiftPackage in Frameworks */,
8486
C1C00DE1D4D140D43FF1F838 /* Pods_Runner.framework in Frameworks */,
8587
);
8688
runOnlyForDeploymentPostprocessing = 0;
@@ -189,6 +191,9 @@
189191
productType = "com.apple.product-type.bundle.unit-test";
190192
};
191193
97C146ED1CF9000F007C117D /* Runner */ = {
194+
packageProductDependencies = (
195+
78A3181F2AECB46A00862997 /* FlutterGeneratedPluginSwiftPackage */,
196+
);
192197
isa = PBXNativeTarget;
193198
buildConfigurationList = 97C147051CF9000F007C117D /* Build configuration list for PBXNativeTarget "Runner" */;
194199
buildPhases = (
@@ -214,6 +219,9 @@
214219

215220
/* Begin PBXProject section */
216221
97C146E61CF9000F007C117D /* Project object */ = {
222+
packageReferences = (
223+
781AD8BC2B33823900A9FFBB /* XCLocalSwiftPackageReference "Flutter/ephemeral/Packages/FlutterGeneratedPluginSwiftPackage" */,
224+
);
217225
isa = PBXProject;
218226
attributes = {
219227
LastUpgradeCheck = 1510;
@@ -453,7 +461,7 @@
453461
GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
454462
GCC_WARN_UNUSED_FUNCTION = YES;
455463
GCC_WARN_UNUSED_VARIABLE = YES;
456-
IPHONEOS_DEPLOYMENT_TARGET = 12.0;
464+
IPHONEOS_DEPLOYMENT_TARGET = 13.0;
457465
MTL_ENABLE_DEBUG_INFO = NO;
458466
SDKROOT = iphoneos;
459467
SUPPORTED_PLATFORMS = iphoneos;
@@ -473,7 +481,7 @@
473481
DEVELOPMENT_TEAM = 87RQQPQ85J;
474482
ENABLE_BITCODE = NO;
475483
INFOPLIST_FILE = Runner/Info.plist;
476-
IPHONEOS_DEPLOYMENT_TARGET = 12.0;
484+
IPHONEOS_DEPLOYMENT_TARGET = 13.0;
477485
LD_RUNPATH_SEARCH_PATHS = (
478486
"$(inherited)",
479487
"@executable_path/Frameworks",
@@ -502,7 +510,7 @@
502510
CURRENT_PROJECT_VERSION = 1;
503511
GCC_C_LANGUAGE_STANDARD = gnu11;
504512
GENERATE_INFOPLIST_FILE = YES;
505-
IPHONEOS_DEPLOYMENT_TARGET = 15.0;
513+
IPHONEOS_DEPLOYMENT_TARGET = 13.0;
506514
LD_RUNPATH_SEARCH_PATHS = (
507515
"$(inherited)",
508516
"@executable_path/Frameworks",
@@ -535,7 +543,7 @@
535543
CURRENT_PROJECT_VERSION = 1;
536544
GCC_C_LANGUAGE_STANDARD = gnu11;
537545
GENERATE_INFOPLIST_FILE = YES;
538-
IPHONEOS_DEPLOYMENT_TARGET = 15.0;
546+
IPHONEOS_DEPLOYMENT_TARGET = 13.0;
539547
LD_RUNPATH_SEARCH_PATHS = (
540548
"$(inherited)",
541549
"@executable_path/Frameworks",
@@ -567,7 +575,7 @@
567575
CURRENT_PROJECT_VERSION = 1;
568576
GCC_C_LANGUAGE_STANDARD = gnu11;
569577
GENERATE_INFOPLIST_FILE = YES;
570-
IPHONEOS_DEPLOYMENT_TARGET = 15.0;
578+
IPHONEOS_DEPLOYMENT_TARGET = 13.0;
571579
LD_RUNPATH_SEARCH_PATHS = (
572580
"$(inherited)",
573581
"@executable_path/Frameworks",
@@ -630,7 +638,7 @@
630638
GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
631639
GCC_WARN_UNUSED_FUNCTION = YES;
632640
GCC_WARN_UNUSED_VARIABLE = YES;
633-
IPHONEOS_DEPLOYMENT_TARGET = 12.0;
641+
IPHONEOS_DEPLOYMENT_TARGET = 13.0;
634642
MTL_ENABLE_DEBUG_INFO = YES;
635643
ONLY_ACTIVE_ARCH = YES;
636644
SDKROOT = iphoneos;
@@ -679,7 +687,7 @@
679687
GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
680688
GCC_WARN_UNUSED_FUNCTION = YES;
681689
GCC_WARN_UNUSED_VARIABLE = YES;
682-
IPHONEOS_DEPLOYMENT_TARGET = 12.0;
690+
IPHONEOS_DEPLOYMENT_TARGET = 13.0;
683691
MTL_ENABLE_DEBUG_INFO = NO;
684692
SDKROOT = iphoneos;
685693
SUPPORTED_PLATFORMS = iphoneos;
@@ -728,7 +736,7 @@
728736
DEVELOPMENT_TEAM = 87RQQPQ85J;
729737
ENABLE_BITCODE = NO;
730738
INFOPLIST_FILE = Runner/Info.plist;
731-
IPHONEOS_DEPLOYMENT_TARGET = 12.0;
739+
IPHONEOS_DEPLOYMENT_TARGET = 13.0;
732740
LD_RUNPATH_SEARCH_PATHS = (
733741
"$(inherited)",
734742
"@executable_path/Frameworks",
@@ -775,6 +783,18 @@
775783
defaultConfigurationName = Release;
776784
};
777785
/* End XCConfigurationList section */
786+
/* Begin XCLocalSwiftPackageReference section */
787+
781AD8BC2B33823900A9FFBB /* XCLocalSwiftPackageReference "Flutter/ephemeral/Packages/FlutterGeneratedPluginSwiftPackage" */ = {
788+
isa = XCLocalSwiftPackageReference;
789+
relativePath = Flutter/ephemeral/Packages/FlutterGeneratedPluginSwiftPackage;
790+
};
791+
/* End XCLocalSwiftPackageReference section */
792+
/* Begin XCSwiftPackageProductDependency section */
793+
78A3181F2AECB46A00862997 /* FlutterGeneratedPluginSwiftPackage */ = {
794+
isa = XCSwiftPackageProductDependency;
795+
productName = FlutterGeneratedPluginSwiftPackage;
796+
};
797+
/* End XCSwiftPackageProductDependency section */
778798
};
779799
rootObject = 97C146E61CF9000F007C117D /* Project object */;
780800
}

example/ios/Runner.xcodeproj/project.xcworkspace/xcshareddata/swiftpm/Package.resolved

Lines changed: 15 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

example/ios/Runner.xcodeproj/xcshareddata/xcschemes/Runner.xcscheme

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,24 @@
55
<BuildAction
66
parallelizeBuildables = "YES"
77
buildImplicitDependencies = "YES">
8+
<PreActions>
9+
<ExecutionAction
10+
ActionType = "Xcode.IDEStandardExecutionActionsCore.ExecutionActionType.ShellScriptAction">
11+
<ActionContent
12+
title = "Run Prepare Flutter Framework Script"
13+
scriptText = "/bin/sh &quot;$FLUTTER_ROOT/packages/flutter_tools/bin/xcode_backend.sh&quot; prepare&#10;">
14+
<EnvironmentBuildable>
15+
<BuildableReference
16+
BuildableIdentifier = "primary"
17+
BlueprintIdentifier = "97C146ED1CF9000F007C117D"
18+
BuildableName = "Runner.app"
19+
BlueprintName = "Runner"
20+
ReferencedContainer = "container:Runner.xcodeproj">
21+
</BuildableReference>
22+
</EnvironmentBuildable>
23+
</ActionContent>
24+
</ExecutionAction>
25+
</PreActions>
826
<BuildActionEntries>
927
<BuildActionEntry
1028
buildForTesting = "YES"

example/ios/Runner.xcworkspace/xcshareddata/swiftpm/Package.resolved

Lines changed: 15 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

example/macos/Podfile.lock

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,4 +13,4 @@ SPEC CHECKSUMS:
1313

1414
PODFILE CHECKSUM: 353c8bcc5d5b0994e508d035b5431cfe18c1dea7
1515

16-
COCOAPODS: 1.12.1
16+
COCOAPODS: 1.16.2
Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,13 @@
11
import Cocoa
22
import FlutterMacOS
33

4-
@NSApplicationMain
4+
@main
55
class AppDelegate: FlutterAppDelegate {
66
override func applicationShouldTerminateAfterLastWindowClosed(_ sender: NSApplication) -> Bool {
77
return true
88
}
9+
10+
override func applicationSupportsSecureRestorableState(_ app: NSApplication) -> Bool {
11+
return true
12+
}
913
}

packages/stripe_ios/CHANGELOG.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,8 @@
1+
## 11.3.1
2+
3+
**Features**
4+
- Adds support for Swift Package Manager for compatibility with new projects.
5+
16
## 11.3.0
27
Align with Stripe React Native [0.39.0](https://github.com/stripe/stripe-react-native/releases/tag/v0.39.0):
38
**Features**

packages/stripe_ios/ios/Assets/.gitkeep

Whitespace-only changes.

packages/stripe_ios/ios/Classes/StripeIosPlugin.h

Lines changed: 0 additions & 8 deletions
This file was deleted.

packages/stripe_ios/ios/Classes/StripeIosPlugin.m

Lines changed: 0 additions & 22 deletions
This file was deleted.

0 commit comments

Comments
 (0)