<?xml version='1.0' encoding='utf-8'?>
<plugin id="cordova-plugin-cashfree-pg" version="1.1.0" xmlns="http://apache.org/cordova/ns/plugins/1.0">
    <name>CFPaymentGateway</name>
    <js-module name="CFPaymentGateway" src="dist/CFPaymentGateway.js">
        <clobbers target="CFPaymentGateway"/>
    </js-module>
    <platform name="ios">
        <config-file parent="/*" target="config.xml">
            <feature name="CFPaymentGateway">
                <param name="ios-package" value="CFPaymentGateway"/>
            </feature>
        </config-file>
        <source-file src="src/ios/CFPaymentGateway.swift"/>

        <config-file target="*-Info.plist" parent="LSApplicationQueriesSchemes">
            <array>
                <string>amazonpay</string>
                <string>upi</string>
                <string>credpay</string>
                <string>bhim</string>
                <string>paytmmp</string>
                <string>phonepe</string>
                <string>tez</string>
                <string>navipay</string>
                <string>mobikwik</string>
                <string>myairtel</string>
                <string>popclubapp</string>
                <string>super</string>
                <string>kiwi</string>
                <string>simplypayupi</string>
                <string>whatsapp-consumer</string>
            </array>
        </config-file>
        <config-file target="*-Info.plist" parent="LSApplicationCategoryType">
        </config-file>
        <podspec>
            <config>
                <source url="https://github.com/CocoaPods/specs.git"/>
            </config>
            <pods use-frameworks="true">
                <pod name="CashfreePG" spec="~>2.4.0"/>
            </pods>
        </podspec>
    </platform>
    <platform name="android">
        <framework custom="true" src="src/android/CashfreePGSDK.gradle" type="gradleReference"/>
        <config-file parent="/*" target="res/xml/config.xml">
            <feature name="CFPaymentGateway">
                <param name="android-package" value="com.cashfree.pg.cordova.CFPaymentGateway"/>
            </feature>
        </config-file>
        <config-file parent="/*" target="AndroidManifest.xml"/>
        <source-file src="src/android/CFPaymentGateway.java"
                     target-dir="src/com/cashfree/pg/cordova"/>
    </platform>
</plugin>
