Przeglądaj źródła

[RN] Don't bundle fonts we don't use

master
Saúl Ibarra Corretgé 7 lat temu
rodzic
commit
011a46ce2d

+ 1
- 2
android/sdk/build.gradle Wyświetl plik

@@ -114,11 +114,10 @@ android.libraryVariants.all { def variant ->
114 114
     def assetsDir = variant.mergeAssets.outputDir
115 115
 
116 116
     variant.mergeAssets.doLast {
117
-        // Bundle fonts in react-native-vector-icons
117
+        // Bundle fonts
118 118
         //
119 119
         copy {
120 120
             from("${projectDir}/../../fonts/jitsi.ttf")
121
-            from("${projectDir}/../../node_modules/react-native-vector-icons/Fonts/")
122 121
             into("${assetsDir}/fonts")
123 122
         }
124 123
 

+ 19
- 0
ios/sdk/sdk.xcodeproj/project.pbxproj Wyświetl plik

@@ -285,6 +285,7 @@
285 285
 				0BD906E31EC0C00300C8C18E /* Resources */,
286 286
 				0BCA49651EC4B77500B793EE /* Package React bundle */,
287 287
 				C7BC10B338C94EEB98048E64 /* [CP] Copy Pods Resources */,
288
+				0B64F7BE2175DFEA005009CD /* Remove unneeded fonts */,
288 289
 			);
289 290
 			buildRules = (
290 291
 			);
@@ -350,6 +351,24 @@
350 351
 /* End PBXResourcesBuildPhase section */
351 352
 
352 353
 /* Begin PBXShellScriptBuildPhase section */
354
+		0B64F7BE2175DFEA005009CD /* Remove unneeded fonts */ = {
355
+			isa = PBXShellScriptBuildPhase;
356
+			buildActionMask = 2147483647;
357
+			files = (
358
+			);
359
+			inputFileListPaths = (
360
+			);
361
+			inputPaths = (
362
+			);
363
+			name = "Remove unneeded fonts";
364
+			outputFileListPaths = (
365
+			);
366
+			outputPaths = (
367
+			);
368
+			runOnlyForDeploymentPostprocessing = 0;
369
+			shellPath = /bin/sh;
370
+			shellScript = "# We need to manually do this because react-native-vecotr-icons lists fonts as resources in the Pod spec file\n# so they are automatically added.\n\nshopt -s extglob\n\nrm -f ${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/!(jitsi).ttf\n";
371
+		};
353 372
 		0BCA49651EC4B77500B793EE /* Package React bundle */ = {
354 373
 			isa = PBXShellScriptBuildPhase;
355 374
 			buildActionMask = 2147483647;

+ 0
- 1
ios/sdk/src/Info.plist Wyświetl plik

@@ -20,7 +20,6 @@
20 20
 	<string>$(CURRENT_PROJECT_VERSION)</string>
21 21
 	<key>JitsiMeetFonts</key>
22 22
 	<array>
23
-		<string>FontAwesome.ttf</string>
24 23
 		<string>jitsi.ttf</string>
25 24
 	</array>
26 25
 	<key>LSApplicationQueriesSchemes</key>

Ładowanie…
Anuluj
Zapisz