-
-
Notifications
You must be signed in to change notification settings - Fork 7
/
plugin.xml
93 lines (93 loc) · 5.12 KB
/
plugin.xml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
<?xml version='1.0' encoding='utf-8'?>
<plugin id="cordova-plugin-facebook-account-kit" version="0.1.6" xmlns="http://apache.org/cordova/ns/plugins/1.0" xmlns:android="http://schemas.android.com/apk/res/android">
<name>FacebookAccountKitLogin</name>
<description>
Facebook Account Kit Login Plugin - Allows email and mobile logins using Facebook Account Kit. Now with background colors customization also available.
Docs: https://github.com/Mhusain/FacebookAccountKit
</description>
<license>Apache 2.0</license>
<preference name="APP_ID" />
<preference name="APP_NAME" />
<preference name="AK_TOKEN" />
<APP_ID>123456789</APP_ID>
<APP_NAME>myApplication</APP_NAME>
<AK_TOKEN>AccountKitClientToken</AK_TOKEN>
<js-module name="FacebookAccountKitLogin" src="www/FacebookAccountKitLogin.js">
<clobbers target="FacebookAccountKit" />
</js-module>
<!-- ios configuration starts-->
<platform name="ios">
<config-file parent="/*" target="config.xml">
<feature name="FacebookAccountKitLogin">
<param name="ios-package" onload="true" value="FacebookAccountKitLogin" />
</feature>
</config-file>
<source-file src="src/ios/FacebookAccountKitLogin.m" />
<config-file parent="FacebookAppID" target="*-Info.plist">
<string>$APP_ID</string>
</config-file>
<config-file parent="AccountKitClientToken" target="*-Info.plist">
<string>$AK_TOKEN</string>
</config-file>
<config-file parent="FacebookDisplayName" target="*-Info.plist">
<string>$APP_NAME</string>
</config-file>
<config-file parent="CFBundleURLTypes" target="*-Info.plist">
<array>
<dict>
<key>CFBundleURLSchemes</key>
<array>
<string>ak$APP_ID</string>
</array>
</dict>
</array>
</config-file>
<!-- account kit framework-->
<framework custom="true" src="src/ios/AccountKit.framework" />
<framework custom="true" src="src/ios/AccountKitStrings.bundle" />
</platform>
<!-- ios configuration ends-->
<!-- android configuration starts-->
<platform name="android">
<config-file parent="/*" target="res/xml/config.xml">
<feature name="FacebookAccountKitLogin">
<param name="android-package" value="org.apache.cordova.FacebookAccountKit.FacebookAccountKitLogin" />
</feature>
</config-file>
<source-file src="src/android/FacebookAccountKitLogin.xml" target-dir="res/values" />
<config-file parent="/*" target="res/values/FacebookAccountKitLogin.xml">
<string name="fbak_app_id">$APP_ID</string>
<string name="fbak_app_name">$APP_NAME</string>
<string name="fbak_app_ak_token">$AK_TOKEN</string>
<style name="AccountKitLoginTheme" parent="Theme.AccountKit">
<item name="com_accountkit_background_color">#EEF6FF</item>
<item name="com_accountkit_button_background_color">#96BDEB</item>
<item name="com_accountkit_button_disabled_background_color">#96BDEB</item>
<item name="com_accountkit_button_border_color">#96BDEB</item>
<item name="com_accountkit_button_text_color">#ffffff</item>
<item name="com_accountkit_header_background_color">#96BDEB</item>
<item name="com_accountkit_header_text_color">#ffffff</item>
<item name="com_accountkit_input_background_color">#EEF6FF</item>
<item name="com_accountkit_input_border_color">#96BDEB</item>
<item name="com_accountkit_input_text_color">#da4a11</item>
<item name="com_accountkit_text_color">#da4a11</item>
<item name="com_accountkit_title_text_color">#da4a11</item>
</style>
</config-file>
<config-file parent="application" target="AndroidManifest.xml">
<meta-data android:name="com.facebook.accountkit.ApplicationName" android:value="@string/fbak_app_name" />
<meta-data android:name="com.facebook.sdk.ApplicationId" android:value="@string/fbak_app_id" />
<meta-data android:name="com.facebook.accountkit.ClientToken" android:value="@string/fbak_app_ak_token" />
<meta-data android:name="com.facebook.accountkit.FacebookAppEventsEnabled" android:value="false"/>
<activity android:name="com.facebook.accountkit.ui.AccountKitActivity" tools:replace="android:theme" android:theme="@style/AccountKitLoginTheme">
</activity>
</config-file>
<edit-config file="AndroidManifest.xml" target="/manifest" mode="merge">
<manifest xmlns:tools="http://schemas.android.com/tools" />
</edit-config>
<source-file src="src/android/FacebookAccountKitLogin.java" target-dir="src/org/apache/cordova/FacebookAccountKit" />
<!-- account kit framework-->
<framework src="com.facebook.android:account-kit-sdk:4.+"/>
</platform>
<!-- android configuration ends-->
</plugin>