<!--
SPDX-FileCopyrightText: 2023 Albert Vaca Cintora <albertvaka@gmail.com>

SPDX-License-Identifier: GPL-2.0-only OR GPL-3.0-only OR LicenseRef-KDE-Accepted-GPL
-->

<resources xmlns:tools="http://schemas.android.com/tools">
    <!-- NoActionBar because we use a Toolbar widget as ActionBar -->
    <style name="KdeConnectThemeBase" parent="Theme.Material3.DayNight.NoActionBar">
        <!-- The main color attributes -->
        <!-- Drawable definitions and overrides -->

        <item name="materialCardViewStyle">@style/KdeConnectCardStyle</item>

        <!-- https://github.com/material-components/material-components-android/issues/2732 -->
        <item name="alertDialogTheme">@style/KdeConnectDialogStyle</item>
    </style>

    <style name="KdeConnectTheme" parent="KdeConnectThemeBase" />

    <style name="KdeConnectThemeBase.NoActionBar" parent="KdeConnectTheme">
        <item name="windowActionBar">false</item>
        <item name="windowNoTitle">true</item>
    </style>

    <style name="KdeConnectTheme.NoActionBar" parent="KdeConnectThemeBase.NoActionBar" />

    <style name="KdeConnectTheme.Toolbar" parent="Widget.AppCompat.Toolbar">
    </style>

    <style name="KdeConnectDialogStyle" parent="ThemeOverlay.Material3.MaterialAlertDialog">
        <item name="android:layout" tools:ignore="PrivateResource">@layout/m3_alert_dialog</item>
        <item name="dialogCornerRadius" tools:ignore="PrivateResource">@dimen/m3_alert_dialog_corner_size</item>
    </style>

    <style name="KdeConnectCardStyle" parent="@style/Widget.Material3.CardView.Elevated"/>

    <style name="KdeConnectCardStyle.Filled" parent="@style/Widget.Material3.CardView.Filled"/>

    <style name="MainNavigationView">
    </style>

    <style name="KdeConnectButton.IconButton" parent="Widget.Material3.Button.IconButton.Filled">
        <item name="iconGravity">textStart</item>
        <item name="cornerRadius">24dp</item>
    </style>

    <style name="KdeConnectButton.IconButton.Secondary" parent="Widget.Material3.Button.IconButton.Filled.Tonal">
        <item name="iconGravity">textStart</item>
        <item name="cornerRadius">12dp</item>
    </style>

    <style name="ActionModeStyle" parent="Widget.AppCompat.ActionMode">
    </style>
    <style name="Theme.Transparent" parent="@style/Theme.AppCompat.NoActionBar">
        <item name="android:windowIsTranslucent">true</item>
        <item name="android:windowBackground">@android:color/transparent</item>
        <item name="android:windowContentOverlay">@null</item>
        <item name="android:windowNoTitle">true</item>
        <item name="android:windowIsFloating">true</item>
        <item name="android:backgroundDimEnabled">false</item>
    </style>

    <style name="AboutButton">
        <item name="android:layout_width">84dp</item>
        <item name="android:layout_height">84dp</item>
        <item name="android:layout_margin">4dp</item>
        <item name="android:background">?attr/selectableItemBackgroundBorderless</item>
    </style>
    <style name="AboutButton.TextView">
        <item name="android:layout_width">84dp</item>
        <item name="android:layout_height">wrap_content</item>
        <item name="android:layout_gravity">center</item>
        <item name="android:drawablePadding">4dp</item>
        <item name="android:gravity">center</item>
        <item name="android:textSize">12sp</item>
    </style>
</resources>
