Skip to content

Commit 0110a6b

Browse files
authored
chore: updated examples & add shadow example (#394)
* chore: updated examples * chore: updated react-native
1 parent 224816e commit 0110a6b

Some content is hidden

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

50 files changed

+1904
-2486
lines changed

example/android/app/build.gradle

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -170,7 +170,7 @@ android {
170170
def abi = output.getFilter(OutputFile.ABI)
171171
if (abi != null) { // null for the universal-debug, universal-release variants
172172
output.versionCodeOverride =
173-
versionCodes.get(abi) * 1048576 + defaultConfig.versionCode
173+
defaultConfig.versionCode * 1000 + versionCodes.get(abi)
174174
}
175175

176176
}

example/android/app/src/debug/AndroidManifest.xml

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,5 +4,10 @@
44

55
<uses-permission android:name="android.permission.SYSTEM_ALERT_WINDOW"/>
66

7-
<application android:usesCleartextTraffic="true" tools:targetApi="28" tools:ignore="GoogleAppIndexingWarning" />
7+
<application
8+
android:usesCleartextTraffic="true"
9+
tools:targetApi="28"
10+
tools:ignore="GoogleAppIndexingWarning">
11+
<activity android:name="com.facebook.react.devsupport.DevSettingsActivity" />
12+
</application>
813
</manifest>

example/android/app/src/main/AndroidManifest.xml

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,8 +21,6 @@
2121
<category android:name="android.intent.category.LAUNCHER" />
2222
</intent-filter>
2323
</activity>
24-
<activity android:name="com.facebook.react.devsupport.DevSettingsActivity" />
25-
2624
<meta-data
2725
android:name="com.google.android.geo.API_KEY"
2826
android:value="AIzaSyBAefhRlXEH3vCko-zZTX6PHllTR6av4WI"/>

example/android/app/src/main/res/values/styles.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
<resources>
22

33
<!-- Base application theme. -->
4-
<style name="AppTheme" parent="Theme.AppCompat.Light.NoActionBar">
4+
<style name="AppTheme" parent="Theme.AppCompat.DayNight.NoActionBar">
55
<!-- Customize your theme here. -->
66
<item name="android:textColor">#000000</item>
77
</style>

example/android/build.gradle

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,17 +2,18 @@
22

33
buildscript {
44
ext {
5-
buildToolsVersion = "29.0.2"
6-
minSdkVersion = 16
5+
buildToolsVersion = "29.0.3"
6+
minSdkVersion = 21
77
compileSdkVersion = 29
88
targetSdkVersion = 29
9+
ndkVersion = "20.1.5948944"
910
}
1011
repositories {
1112
google()
1213
jcenter()
1314
}
1415
dependencies {
15-
classpath("com.android.tools.build:gradle:3.5.3")
16+
classpath("com.android.tools.build:gradle:4.1.0")
1617

1718
// NOTE: Do not place your application dependencies here; they belong
1819
// in the individual module build.gradle files

example/android/gradle.properties

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,4 +19,4 @@
1919

2020
android.useAndroidX=true
2121
android.enableJetifier=true
22-
FLIPPER_VERSION=0.54.0
22+
FLIPPER_VERSION=0.75.1
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
distributionBase=GRADLE_USER_HOME
22
distributionPath=wrapper/dists
3-
distributionUrl=https\://services.gradle.org/distributions/gradle-6.2-all.zip
3+
distributionUrl=https\://services.gradle.org/distributions/gradle-6.7-all.zip
44
zipStoreBase=GRADLE_USER_HOME
55
zipStorePath=wrapper/dists

example/ios/BottomSheetExample.xcodeproj/project.pbxproj

Lines changed: 45 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
archiveVersion = 1;
44
classes = {
55
};
6-
objectVersion = 46;
6+
objectVersion = 54;
77
objects = {
88

99
/* Begin PBXBuildFile section */
@@ -121,6 +121,7 @@
121121
13B07F8E1A680F5B00A75B9A /* Resources */,
122122
00DD1BFF1BD5951E006B06BC /* Bundle React Native code and images */,
123123
E4EE1BC00881AC99341D4CF3 /* [CP] Copy Pods Resources */,
124+
8B4135FD57168B6119E4AC70 /* [CP] Embed Pods Frameworks */,
124125
);
125126
buildRules = (
126127
);
@@ -137,7 +138,7 @@
137138
83CBB9F71A601CBA00E9B192 /* Project object */ = {
138139
isa = PBXProject;
139140
attributes = {
140-
LastUpgradeCheck = 0940;
141+
LastUpgradeCheck = 1240;
141142
ORGANIZATIONNAME = "Mo Gorhom";
142143
TargetAttributes = {
143144
13B07F861A680F5B00A75B9A = {
@@ -147,11 +148,12 @@
147148
};
148149
};
149150
buildConfigurationList = 83CBB9FA1A601CBA00E9B192 /* Build configuration list for PBXProject "BottomSheetExample" */;
150-
compatibilityVersion = "Xcode 3.2";
151-
developmentRegion = English;
151+
compatibilityVersion = "Xcode 12.0";
152+
developmentRegion = en;
152153
hasScannedForEncodings = 0;
153154
knownRegions = (
154-
English,
155+
Base,
156+
en,
155157
);
156158
mainGroup = 83CBB9F61A601CBA00E9B192;
157159
productRefGroup = 83CBBA001A601CBA00E9B192 /* Products */;
@@ -190,6 +192,23 @@
190192
shellPath = /bin/sh;
191193
shellScript = "cd $PROJECT_DIR/..\nexport NODE_BINARY=node\nexport ENTRY_FILE=\"index.ts\"\n./node_modules/react-native/scripts/react-native-xcode.sh\n";
192194
};
195+
8B4135FD57168B6119E4AC70 /* [CP] Embed Pods Frameworks */ = {
196+
isa = PBXShellScriptBuildPhase;
197+
buildActionMask = 2147483647;
198+
files = (
199+
);
200+
inputFileListPaths = (
201+
"${PODS_ROOT}/Target Support Files/Pods-BottomSheetExample/Pods-BottomSheetExample-frameworks-${CONFIGURATION}-input-files.xcfilelist",
202+
);
203+
name = "[CP] Embed Pods Frameworks";
204+
outputFileListPaths = (
205+
"${PODS_ROOT}/Target Support Files/Pods-BottomSheetExample/Pods-BottomSheetExample-frameworks-${CONFIGURATION}-output-files.xcfilelist",
206+
);
207+
runOnlyForDeploymentPostprocessing = 0;
208+
shellPath = /bin/sh;
209+
shellScript = "\"${PODS_ROOT}/Target Support Files/Pods-BottomSheetExample/Pods-BottomSheetExample-frameworks.sh\"\n";
210+
showEnvVarsInLog = 0;
211+
};
193212
CCCC07BCAFDEF1FCADC0D0C9 /* [CP] Check Pods Manifest.lock */ = {
194213
isa = PBXShellScriptBuildPhase;
195214
buildActionMask = 2147483647;
@@ -217,13 +236,12 @@
217236
buildActionMask = 2147483647;
218237
files = (
219238
);
220-
inputPaths = (
221-
"${PODS_ROOT}/Target Support Files/Pods-BottomSheetExample/Pods-BottomSheetExample-resources.sh",
222-
"${PODS_CONFIGURATION_BUILD_DIR}/React-Core/AccessibilityResources.bundle",
239+
inputFileListPaths = (
240+
"${PODS_ROOT}/Target Support Files/Pods-BottomSheetExample/Pods-BottomSheetExample-resources-${CONFIGURATION}-input-files.xcfilelist",
223241
);
224242
name = "[CP] Copy Pods Resources";
225-
outputPaths = (
226-
"${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/AccessibilityResources.bundle",
243+
outputFileListPaths = (
244+
"${PODS_ROOT}/Target Support Files/Pods-BottomSheetExample/Pods-BottomSheetExample-resources-${CONFIGURATION}-output-files.xcfilelist",
227245
);
228246
runOnlyForDeploymentPostprocessing = 0;
229247
shellPath = /bin/sh;
@@ -274,8 +292,12 @@
274292
CURRENT_PROJECT_VERSION = 1;
275293
DEAD_CODE_STRIPPING = NO;
276294
DEVELOPMENT_TEAM = 4P8A237MEX;
295+
"EXCLUDED_ARCHS[sdk=iphonesimulator*]" = arm64;
277296
INFOPLIST_FILE = BottomSheetExample/Info.plist;
278-
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks";
297+
LD_RUNPATH_SEARCH_PATHS = (
298+
"$(inherited)",
299+
"@executable_path/Frameworks",
300+
);
279301
OTHER_CFLAGS = (
280302
"$(inherited)",
281303
"-DFB_SONARKIT_ENABLED=1",
@@ -303,8 +325,12 @@
303325
CLANG_ENABLE_MODULES = YES;
304326
CURRENT_PROJECT_VERSION = 1;
305327
DEVELOPMENT_TEAM = 4P8A237MEX;
328+
"EXCLUDED_ARCHS[sdk=iphonesimulator*]" = arm64;
306329
INFOPLIST_FILE = BottomSheetExample/Info.plist;
307-
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks";
330+
LD_RUNPATH_SEARCH_PATHS = (
331+
"$(inherited)",
332+
"@executable_path/Frameworks",
333+
);
308334
ONLY_ACTIVE_ARCH = YES;
309335
OTHER_CFLAGS = (
310336
"$(inherited)",
@@ -346,6 +372,7 @@
346372
CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES;
347373
CLANG_WARN_OBJC_LITERAL_CONVERSION = YES;
348374
CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
375+
CLANG_WARN_QUOTED_INCLUDE_IN_FRAMEWORK_HEADER = YES;
349376
CLANG_WARN_RANGE_LOOP_ANALYSIS = YES;
350377
CLANG_WARN_STRICT_PROTOTYPES = YES;
351378
CLANG_WARN_SUSPICIOUS_MOVE = YES;
@@ -356,6 +383,7 @@
356383
ENABLE_BITCODE = NO;
357384
ENABLE_STRICT_OBJC_MSGSEND = YES;
358385
ENABLE_TESTABILITY = YES;
386+
"EXCLUDED_ARCHS[sdk=iphonesimulator*]" = "";
359387
GCC_C_LANGUAGE_STANDARD = gnu99;
360388
GCC_DYNAMIC_NO_PIC = NO;
361389
GCC_NO_COMMON_BLOCKS = YES;
@@ -371,7 +399,7 @@
371399
GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
372400
GCC_WARN_UNUSED_FUNCTION = YES;
373401
GCC_WARN_UNUSED_VARIABLE = YES;
374-
IPHONEOS_DEPLOYMENT_TARGET = 10.0;
402+
IPHONEOS_DEPLOYMENT_TARGET = 12.0;
375403
MTL_ENABLE_DEBUG_INFO = YES;
376404
ONLY_ACTIVE_ARCH = YES;
377405
SDKROOT = iphoneos;
@@ -400,6 +428,7 @@
400428
CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES;
401429
CLANG_WARN_OBJC_LITERAL_CONVERSION = YES;
402430
CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
431+
CLANG_WARN_QUOTED_INCLUDE_IN_FRAMEWORK_HEADER = YES;
403432
CLANG_WARN_RANGE_LOOP_ANALYSIS = YES;
404433
CLANG_WARN_STRICT_PROTOTYPES = YES;
405434
CLANG_WARN_SUSPICIOUS_MOVE = YES;
@@ -410,6 +439,7 @@
410439
ENABLE_BITCODE = NO;
411440
ENABLE_NS_ASSERTIONS = NO;
412441
ENABLE_STRICT_OBJC_MSGSEND = YES;
442+
"EXCLUDED_ARCHS[sdk=iphonesimulator*]" = "";
413443
GCC_C_LANGUAGE_STANDARD = gnu99;
414444
GCC_NO_COMMON_BLOCKS = YES;
415445
GCC_WARN_64_TO_32_BIT_CONVERSION = YES;
@@ -418,10 +448,11 @@
418448
GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
419449
GCC_WARN_UNUSED_FUNCTION = YES;
420450
GCC_WARN_UNUSED_VARIABLE = YES;
421-
IPHONEOS_DEPLOYMENT_TARGET = 10.0;
451+
IPHONEOS_DEPLOYMENT_TARGET = 12.0;
422452
MTL_ENABLE_DEBUG_INFO = NO;
423453
ONLY_ACTIVE_ARCH = YES;
424454
SDKROOT = iphoneos;
455+
SWIFT_COMPILATION_MODE = wholemodule;
425456
VALIDATE_PRODUCT = YES;
426457
};
427458
name = Release;

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

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<?xml version="1.0" encoding="UTF-8"?>
22
<Scheme
3-
LastUpgradeVersion = "0940"
3+
LastUpgradeVersion = "1240"
44
version = "1.3">
55
<BuildAction
66
parallelizeBuildables = "NO"
@@ -50,6 +50,8 @@
5050
ReferencedContainer = "container:BottomSheetExample.xcodeproj">
5151
</BuildableReference>
5252
</MacroExpansion>
53+
<Testables>
54+
</Testables>
5355
</TestAction>
5456
<LaunchAction
5557
buildConfiguration = "Debug"

example/ios/BottomSheetExample/AppDelegate.m

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,11 @@ - (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(
4242
moduleName:@"BottomSheetExample"
4343
initialProperties:nil];
4444

45-
rootView.backgroundColor = [[UIColor alloc] initWithRed:1.0f green:1.0f blue:1.0f alpha:1];
45+
if (@available(iOS 13.0, *)) {
46+
rootView.backgroundColor = [UIColor systemBackgroundColor];
47+
} else {
48+
rootView.backgroundColor = [UIColor whiteColor];
49+
}
4650

4751
self.window = [[UIWindow alloc] initWithFrame:[UIScreen mainScreen].bounds];
4852
UIViewController *rootViewController = [UIViewController new];

0 commit comments

Comments
 (0)