<?xml version='1.0' encoding='utf-8'?>
<widget android-activityName="GOBOOKING" id="com.bossitalia.gobooking"
    xmlns="http://www.w3.org/ns/widgets"
    xmlns:android="http://schemas.android.com/apk/res/android"
    xmlns:gap="http://phonegap.com/ns/1.0">

    <!-- General Info -->

    <name>GoBooking</name>
    <description>An app for booking from BOSS S.r.l.</description>
    <author email="sviluppo@bossitalia.com" href="https://www.bossitalia.com/">Contact us</author>
    <content src="index.html" />

    <!-- Platforms Target -->

    <engine name="android" spec="14.0.1"/>
    <engine name="ios" spec="7.0.1" />

    <!-- Permissions -->

    <access origin="*"/>
    <allow-intent href="sms:*" />
    <allow-intent href="tel:*" />
    <allow-intent href="geo:*" />
    <allow-intent href="mailto:*" />
    <allow-intent href="file://*/*" />
    <allow-intent href="http://*/*" />
    <allow-intent href="https://*/*" />
    <allow-navigation href="http://*/*" />
    <allow-navigation href="https://*/*" />

    <!-- SCHEME and DOMAIN  -->

    <preference name="scheme" value="ionic" />
    <preference name="hostname" value="localhost" />
    <preference name="Scheme" value="ionic" />
    <preference name="iosScheme" value="ionic" />
    <preference name="Hostname" value="localhost" />
    <preference name="WKPort" value="" />

    <!-- Preferences -->

    <preference name="webviewbounce" value="false" />
    <preference name="KeyboardResize" value="false" />
    <preference name="BackupWebStorage" value="none" />
    <preference name="DisallowOverscroll" value="true" />
    <preference name="StatusBarStyle" value="lightcontent" />
    <preference name="StatusBarOverlaysWebView" value="false" />
    <preference name="KeyboardDisplayRequiresUserAction" value="false"/>

    <!-- Splash screen -->
    <preference name="AutoHideSplashScreen" value="true" />
    <preference name="ShowSplashScreenSpinner" value="false" />
    <preference name="FadeSplashScreenDuration" value="400" />
    <preference name="SplashScreenDelay" value="3000" />

    <!-- Hooks -->

    <hook src="www/hooks/fwk-after-prepare-hooks.js" type="after_prepare" />
    <hook src="www/hooks/fwk-after-plugin-add-hooks.js" type="after_plugin_add" />
    <hook src="www/hooks/fwk-after-prepare-copy-build-extra-hooks.js" type="after_prepare" />
    <hook src="www/hooks/fwk-after-compile-hooks.js" type="after_compile" />
    <hook src="www/hooks/fwk-before-build-hooks.js" type="before_build" />

    <!-- Android -->

    <platform name="android">

        <!-- Deep Linking Configuration -->
        <config-file target="AndroidManifest.xml" parent="/manifest/application/activity">
            <intent-filter>
                <action android:name="android.intent.action.VIEW" />
                <category android:name="android.intent.category.DEFAULT" />
                <category android:name="android.intent.category.BROWSABLE" />
                <data android:scheme="bossitaliagobooking" android:host="*" />
            </intent-filter>
        </config-file>

        <preference name="AndroidXEnabled" value="true" />

        <!-- Status bar overlay for edge-to-edge on Android only -->
        <preference name="StatusBarOverlaysWebView" value="true" />

        <!-- SDK version -->
        <preference name="android-minSdkVersion" value="22" />
        <preference name="android-maxSdkVersion" value="36" />
        <preference name="android-targetSdkVersion" value="36" />

        <!-- Splashscreens -->
        <preference name="AndroidWindowSplashScreenAnimatedIcon" value="www/res/icon/app/icon.xml" />
        <resource-file src="www/res/assets/colors.xml" target="/app/src/main/res/values/colors.xml" />
        <icon background="@color/background" density="ldpi" foreground="www/res/icon/app/icon.xml" src="www/res/icon/app/icon-ldpi.png" />
        <icon background="@color/background" density="mdpi" foreground="www/res/icon/app/icon.xml" src="www/res/icon/app/icon-mdpi.png" />
        <icon background="@color/background" density="hdpi" foreground="www/res/icon/app/icon.xml" src="www/res/icon/app/icon-hdpi.png" />
        <icon background="@color/background" density="xhdpi" foreground="www/res/icon/app/icon.xml" src="www/res/icon/app/icon-xhdpi.png" />
        <icon background="@color/background" density="xxhdpi" foreground="www/res/icon/app/icon.xml" src="www/res/icon/app/icon-xxhdpi.png" />
        <icon background="@color/background" density="xxxhdpi" foreground="www/res/icon/app/icon.xml" src="www/res/icon/app/icon-xxxhdpi.png" />

        <!-- Push Configurations -->
        <!-- Don't remove the below line! -->
        <!-- Don't modify this resources-file list because it's generate-->


        <!-- Push Icons -->
        <resource-file src="www/res/icon/push/mipmap-mdpi/ic_notification.png" target="app/src/main/res/mipmap-mdpi/ic_notification.png" />
        <resource-file src="www/res/icon/push/mipmap-hdpi/ic_notification.png" target="app/src/main/res/mipmap-hdpi/ic_notification.png" />
        <resource-file src="www/res/icon/push/mipmap-xhdpi/ic_notification.png" target="app/src/main/res/mipmap-xhdpi/ic_notification.png" />
        <resource-file src="www/res/icon/push/mipmap-xxhdpi/ic_notification.png" target="app/src/main/res/mipmap-xxhdpi/ic_notification.png" />
        <resource-file src="www/res/icon/push/mipmap-xxxhdpi/ic_notification.png" target="app/src/main/res/mipmap-xxxhdpi/ic_notification.png" />

        <!-- Allow Extenal Storage capacity -->
        <!-- Allow older android to choose photos from Gallery -->
        <edit-config file="app/src/main/AndroidManifest.xml" mode="merge" target="/manifest/application">
            <application android:requestLegacyExternalStorage="true"/>
        </edit-config>

        <!-- Necessary to show the icon with the background app or closed -->
        <config-file target="AndroidManifest.xml" parent="/manifest/application">
            <meta-data android:name="com.google.firebase.messaging.default_notification_icon" android:resource="@mipmap/ic_notification" />
        </config-file>

        <config-file target="AndroidManifest.xml" parent="/manifest">
            <uses-permission android:name="android.permission.POST_NOTIFICATIONS"/>
        </config-file>

        <!-- Maintains the image screen ratio avoid image streching -->
        <preference name="SplashMaintainAspectRatio" value="true" />

        <preference name="AndroidInsecureFileModeEnabled" value="true" />

        <!-- Edge-to-edge support required for Android 16 (SDK 36) -->
        <preference name="AndroidEdgeToEdge" value="true" />

        <!-- Cutout fix: allow to extend view below the 'notch' when edge-to-edge is enabled -->
        <preference name="AndroidInsecureFlags" value="LAYOUT_IN_DISPLAY_CUTOUT_MODE_SHORT_EDGES" />

    </platform>

    <!-- iOS -->

    <platform name="ios">

        <!-- Deep Linking Configuration -->
        <config-file target="*-Info.plist" parent="CFBundleURLTypes">
            <array>
                <dict>
                    <key>CFBundleURLName</key>
                    <string>com.bossitalia.gobooking</string>
                    <key>CFBundleURLSchemes</key>
                    <array>
                        <string>bossitaliagobooking</string>
                    </array>
                </dict>
            </array>
        </config-file>

        <preference name="deployment-target" value="13.0" />

        <!-- CORS -->

        <!-- From cordova-ios 6.x doc. -->
        <preference name="scheme" value="ionic" />
        <preference name="hostname" value="localhost" />

        <!-- From cordova-plugin-ionic-migrate-storage github -->
        <preference name="Scheme" value="ionic" />
        <preference name="iosScheme" value="ionic" />
        <preference name="Hostname" value="localhost" />
        <preference name="WKPort" value="" />

        <!-- Storage Porting -->
        <!-- From 'file__0.localstorage' format to 'app_localhost_0.localstorage' -->
        <preference name="MIGRATE_STORAGE_ORIGINAL_SCHEME" value="file" />
        <preference name="MIGRATE_STORAGE_ORIGINAL_HOSTNAME" value="" />
        <preference name="MIGRATE_STORAGE_ORIGINAL_PORT_NUMBER" value="0" />

        <!-- Push Firebase -->
        <resource-file src="www/res/configurations/push/GoogleService-Info.plist" />

        <!-- Resouces -->
        <icon height="20" src="www/res/icon/app/Icon-20.png" width="20" />
        <icon height="48" src="www/res/icon/app/AppIcon24x24@2x.png" width="48" />
        <icon height="55" src="www/res/icon/app/AppIcon27.5x27.5@2x.png" width="55" />
        <icon height="88" src="www/res/icon/app/AppIcon44x44@2x.png" width="88" />
        <icon height="172" src="www/res/icon/app/AppIcon86x86@2x.png" width="172" />
        <icon height="196" src="www/res/icon/app/AppIcon98x98@2x.png" width="196" />
        <icon height="29" src="www/res/icon/app/Icon-Small.png" width="29" />
        <icon height="40" src="www/res/icon/app/Icon-Small-40.png" width="40" />
        <icon height="40" src="www/res/icon/app/AppIcon24x24@2x.png" width="40" />
        <icon height="40" src="www/res/icon/app/Icon-20@2x.png" width="40" />
        <icon height="50" src="www/res/icon/app/Icon-50.png" width="50" />
        <icon height="57" src="www/res/icon/app/Icon.png" width="57" />
        <icon height="58" src="www/res/icon/app/AppIcon29x29@2x.png" width="58" />
        <icon height="60" src="www/res/icon/app/Icon-20@3x.png" width="60" />
        <icon height="58" src="www/res/icon/app/Icon-Small@2x.png" width="58" />
        <icon height="72" src="www/res/icon/app/Icon-72.png" width="72" />
        <icon height="76" src="www/res/icon/app/Icon-76.png" width="76" />
        <icon height="80" src="www/res/icon/app/Icon-Small-40@2x.png" width="80" />
        <icon height="80" src="www/res/icon/app/AppIcon40x40@2x.png" width="80" />
        <icon height="80" src="www/res/icon/app/Icon-Small-40@2x.png" width="80" />
        <icon height="87" src="www/res/icon/app/Icon-Small@3x.png" width="87" />
        <icon height="87" src="www/res/icon/app/AppIcon29x29@3x.png" width="87" />
        <icon height="100" src="www/res/icon/app/Icon-50@2x.png" width="100" />
        <icon height="114" src="www/res/icon/app/Icon@2x.png" width="114" />
        <icon height="120" src="www/res/icon/app/Icon-60@2x.png" width="120" />
        <icon height="120" src="www/res/icon/app/Icon-Small-40@3x.png" width="120" />
        <icon height="144" src="www/res/icon/app/Icon-72@2x.png" width="144" />
        <icon height="152" src="www/res/icon/app/Icon-76@2x.png" width="152" />
        <icon height="167" src="www/res/icon/app/Icon-83.5@2x.png" width="167" />
        <icon height="180" src="www/res/icon/app/Icon-60@3x.png" width="180" />
        <icon height="1024" src="www/res/icon/app/icon-1024.png" width="1024" />

        <splash src="www/res/splashscreen/Default@2x~universal~anyany.png"/>

    </platform>

    <!-- PLUGINS LIST -->
    <!-- DONT ERASE LINE BELOW -->
    <!-- Don't modify this plugins list because it's generate-->
	<plugin name="cordova-plugin-screen-orientation" spec="3.0.2"/>
	<plugin name="cordova-plugin-app-version" spec="0.1.9"/>
	<plugin name="cordova-plugin-calendar" spec="5.1.6"/>
	<plugin name="cordova-plugin-call-number" spec="1.0.1"/>
	<plugin name="cordova-plugin-device" spec="1.1.7"/>
	<plugin name="cordova-plugin-file" spec="6.0.2"/>
	<plugin name="cordova-plugin-ionic-keyboard" spec="2.2.0"/>
	<plugin name="cordova-plugin-media-capture" spec="3.0.3">
		<variable name="PHOTOLIBRARY_USAGE_DESCRIPTION" value="Allow_the_app_to_access_your_photos" />
	</plugin>
	<plugin name="cordova-plugin-network-information" spec="1.3.4"/>
	<plugin name="cordova-plugin-statusbar" spec="2.4.3"/>
	<plugin name="cordova.plugins.diagnostic" spec="6.1.0"/>
	<plugin name="cordova-plugin-file-opener2" spec="4.0.0"/>
	<plugin name="cordova-plugin-customurlscheme" spec="5.0.2">
		<variable name="URL_SCHEME" value="bossitaliagobooking" />
	</plugin>
	<plugin name="https://github.com/havesource/cordova-plugin-push.git#7.0.0" />
	<plugin name="cordova-plugin-sign-in-with-apple" spec="0.1.2"/>
	<plugin name="cordova-plugin-wkwebview-inject-cookie" spec="1.0.6"/>
	<plugin name="https://github.com/campagna91/cordova-plugin-ionic-migrate-storage" />
	<plugin name="cordova-plugin-wkwebview-file-xhr" spec="3.0.0"/>
	<plugin name="cordova-plugin-camera" spec="4.1.0">
		<variable name="CAMERA_USAGE_DESCRIPTION" value="Allow_the_app_to_use_your_camera" />
		<variable name="PHOTOLIBRARY_USAGE_DESCRIPTION" value="Allow_the_app_to_access_your_photos" />
	</plugin>
	<plugin name="cordova-plugin-whitelist" spec="1.3.3"/>
	<plugin name="cordova-plugin-browsertab" spec="0.2.0"/>
	<plugin name="cordova-plugin-fbsdk" spec="4.0.4">
		<variable name="APP_ID" value="2553981324652029" />
		<variable name="APP_NAME" value="com.bossitalia.gobooking" />
		<variable name="CLIENT_TOKEN" value="2553981324652029" />
	</plugin>
</widget>
