Commit 1c7f701e authored by SusanneFischer's avatar SusanneFischer
Browse files

dark mode

parent 6b959e2d
......@@ -46,7 +46,7 @@ class RentalItemChoiceAdapter(
}
}
var colorResId = if (holder.isSelected) {
R.color.colorSecondaryLight
R.color.colorPrimary
} else {
R.color.surface
}
......
<?xml version="1.0" encoding="utf-8"?>
<selector xmlns:android="http://schemas.android.com/apk/res/android">
<item android:alpha="0.20" android:color="@color/colorPrimary" android:state_enabled="true" />
<item android:alpha="0.12" android:color="@color/onSecondary" />
</selector>
\ No newline at end of file
<?xml version="1.0" encoding="utf-8"?>
<selector xmlns:android="http://schemas.android.com/apk/res/android">
<item android:alpha="@dimen/mtrl_low_ripple_pressed_alpha" android:color="@color/colorPrimaryLight" android:state_pressed="true" />
<item android:alpha="@dimen/mtrl_low_ripple_focused_alpha" android:color="@color/colorPrimaryLight" android:state_focused="true" android:state_hovered="true" />
<item android:alpha="@dimen/mtrl_low_ripple_focused_alpha" android:color="@color/colorPrimaryLight" android:state_focused="true" />
<item android:alpha="@dimen/mtrl_low_ripple_hovered_alpha" android:color="@color/colorPrimaryLight" android:state_hovered="true" />
<item android:alpha="@dimen/mtrl_low_ripple_default_alpha" android:color="@color/colorPrimaryLight" />
</selector>
\ No newline at end of file
<?xml version="1.0" encoding="utf-8"?>
<selector xmlns:android="http://schemas.android.com/apk/res/android">
<!-- 24% opacity -->
<item android:alpha="0.24" android:color="@color/colorPrimaryLight" android:state_enabled="true" android:state_selected="true" />
<item android:alpha="0.24" android:color="@color/colorPrimaryLight" android:state_checked="true" android:state_enabled="true" />
<!-- 12% of 87% opacity -->
<item android:alpha="0.10" android:color="@color/onSecondary" android:state_enabled="true" />
<item android:alpha="0.12" android:color="@color/disabled" />
</selector>
\ No newline at end of file
<?xml version="1.0" encoding="utf-8"?>
<selector xmlns:android="http://schemas.android.com/apk/res/android">
<item android:color="@color/onSecondary" android:state_enabled="true" />
<item android:color="@color/disabled" />
</selector>
\ No newline at end of file
<?xml version="1.0" encoding="utf-8"?>
<selector xmlns:android="http://schemas.android.com/apk/res/android">
<item android:alpha="@dimen/mtrl_low_ripple_pressed_alpha" android:color="@color/colorPrimaryLight" android:state_pressed="true" />
<item android:alpha="@dimen/mtrl_low_ripple_focused_alpha" android:color="@color/colorPrimaryLight" android:state_focused="true" android:state_hovered="true" />
<item android:alpha="@dimen/mtrl_low_ripple_focused_alpha" android:color="@color/colorPrimaryLight" android:state_focused="true" />
<item android:alpha="@dimen/mtrl_low_ripple_hovered_alpha" android:color="@color/colorPrimaryLight" android:state_hovered="true" />
<item android:alpha="@dimen/mtrl_low_ripple_default_alpha" android:color="@color/colorPrimaryLight" />
</selector>
\ No newline at end of file
<?xml version="1.0" encoding="utf-8"?>
<selector xmlns:android="http://schemas.android.com/apk/res/android">
<!-- disabled state -->
<item android:color="@color/disabled" android:state_enabled="false" />
<item android:color="@color/colorPrimaryLight" />
</selector>
\ No newline at end of file
<?xml version="1.0" encoding="utf-8"?>
<selector xmlns:android="http://schemas.android.com/apk/res/android">
<item android:color="@color/colorPrimaryLight" android:state_focused="true" />
<!-- 4% overlay over 42% colorOnSurface -->
<item android:alpha="0.46" android:color="@color/colorPrimaryLight" android:state_hovered="true" />
<item android:alpha="0.38" android:color="@color/colorPrimaryLight" android:state_enabled="false" />
<item android:alpha="0.42" android:color="@color/colorPrimary" />
</selector>
\ No newline at end of file
<?xml version="1.0" encoding="utf-8"?>
<vector xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
android:width="24dp"
android:height="24dp"
android:viewportWidth="24.0"
android:viewportHeight="24.0"
tools:ignore="NewApi">
<path
android:fillColor="@color/onSecondary"
android:pathData="M12,12m-12,0a12,12 0,1 1,24 0a12,12 0,1 1,-24 0" />
<path
android:fillColor="@color/colorSecondary"
android:pathData="M9.189,15.939l-3.127,-3.128l-1.061,1.061l4.189,4.189l9,-9l-1.061,-1.061z"
android:strokeWidth="1"
android:strokeColor="@color/colorSecondary" />
</vector>
\ No newline at end of file
......@@ -17,6 +17,8 @@
android:layout_width="match_parent"
android:layout_height="?attr/actionBarSize"
app:navigationIcon="?attr/homeAsUpIndicator"
android:background="?attr/colorPrimary"
android:theme="@style/ThemeOverlay.AppCompat.Light"
app:title="@string/booking" />
</com.google.android.material.appbar.AppBarLayout>
......
......@@ -17,6 +17,8 @@
android:layout_width="match_parent"
android:layout_height="?attr/actionBarSize"
app:navigationIcon="?attr/homeAsUpIndicator"
android:background="?attr/colorPrimary"
android:theme="@style/ThemeOverlay.AppCompat.Light"
app:title="@string/new_rental" />
</com.google.android.material.appbar.AppBarLayout>
......
......@@ -21,6 +21,7 @@
android:layout_marginStart="32dp"
android:gravity="center_vertical"
android:text="@string/app_name"
android:textColor="@color/colorSecondary"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintStart_toEndOf="@id/appbar_profile_image"
app:layout_constraintTop_toTopOf="parent" />
......
......@@ -73,7 +73,6 @@
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="Veranstaltung:"
android:textColor="@color/colorSecondaryLight"
app:layout_constraintBottom_toBottomOf="@id/event_title_text"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="@id/event_title_text" />
......@@ -106,7 +105,6 @@
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="Status:"
android:textColor="@color/colorSecondaryLight"
android:visibility="gone"
app:layout_constraintBottom_toBottomOf="@id/status_text"
app:layout_constraintStart_toStartOf="parent"
......@@ -118,7 +116,6 @@
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="Abholung:"
android:textColor="@color/colorSecondaryLight"
app:layout_constraintBottom_toBottomOf="@id/event_pickup_text"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="@id/event_pickup_text" />
......@@ -140,7 +137,6 @@
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="Rückgabe:"
android:textColor="@color/colorSecondaryLight"
app:layout_constraintBottom_toBottomOf="@id/event_return_text"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="@id/event_return_text" />
......
......@@ -47,6 +47,7 @@
android:gravity="center_vertical|start"
android:maxLines="1"
android:text="Gegenstand"
android:textColor="@color/colorSecondary"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintEnd_toStartOf="@id/item_information_button"
app:layout_constraintStart_toStartOf="parent"
......@@ -60,6 +61,7 @@
android:padding="4dp"
android:scaleType="fitCenter"
android:src="@drawable/ic_info"
android:tint="@color/colorSecondary"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintEnd_toEndOf="parent" />
......
......@@ -25,7 +25,6 @@
android:layout_marginEnd="8dp"
android:background="@android:color/transparent"
android:src="@drawable/ic_delete"
android:tint="@color/error"
app:layout_constraintBottom_toBottomOf="@id/item_circle_image_view"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintTop_toTopOf="@id/item_circle_image_view" />
......
......@@ -34,7 +34,6 @@
android:layout_height="wrap_content"
android:gravity="center"
android:text="März '21"
android:textColor="@color/colorSecondaryLight"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="@id/rental_day" />
......@@ -68,7 +67,6 @@
android:layout_height="wrap_content"
android:layout_marginTop="8dp"
android:text="Laufend"
android:textColor="@color/colorSecondaryLight"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="@id/rental_event_name" />
</androidx.constraintlayout.widget.ConstraintLayout>
......
<resources>
<!-- Base application theme. -->
<style name="AppTheme" parent="Theme.MaterialComponents.DayNight.NoActionBar">
<!-- Customize your theme here. -->
<item name="windowNoTitle">true</item>
<item name="android:windowNoTitle">true</item>
<item name="colorPrimary">@color/colorPrimary</item>
<item name="colorPrimaryDark">@color/colorPrimaryDark</item>
<item name="colorAccent">@color/colorSecondaryLight</item>
<item name="background">@color/onBackground</item>
<item name="colorError">@color/errorNight</item>
<item name="colorControlActivated">@color/colorPrimaryLight</item>
<item name="colorControlNormal">@color/colorPrimary</item>
<item name="colorControlHighlight">@color/colorPrimaryLight</item>
<item name="colorOnPrimary">@color/onSurface</item>
<item name="colorOnSurface">@color/onSecondary</item>
<item name="materialButtonStyle">@style/MaterialButton</item>
<item name="sliderStyle">@style/Slider</item>
<item name="textAppearanceHeadline1">@style/Headline1</item>
<item name="textAppearanceHeadline2">@style/Headline2</item>
<item name="textAppearanceHeadline3">@style/Headline3</item>
<item name="textAppearanceHeadline4">@style/Headline4</item>
<item name="textAppearanceHeadline5">@style/Headline5</item>
<item name="textAppearanceHeadline6">@style/Headline6</item>
<item name="textAppearanceSubtitle1">@style/Subtitle1</item>
<item name="textAppearanceSubtitle2">@style/Subtitle2</item>
<item name="textAppearanceBody1">@style/Body1</item>
<item name="textAppearanceBody2">@style/Body2</item>
<item name="textAppearanceButton">@style/Button</item>
<item name="textAppearanceCaption">@style/Caption</item>
<item name="textAppearanceOverline">@style/Overline</item>
<item name="android:textViewStyle">@style/Body2</item>
<item name="textInputStyle">@style/OutlinedBox</item>
<item name="floatingActionButtonStyle">@style/FloatingActionButton</item>
<item name="materialCalendarFullscreenTheme">@style/MaterialCalendarOverlay</item>
</style>
<style name="FirebaseTheme" parent="FirebaseUI">
<item name="windowNoTitle">true</item>
<item name="colorPrimary">@color/colorPrimary</item>
<item name="colorPrimaryDark">@color/colorPrimaryDark</item>
<item name="colorAccent">@color/colorPrimary</item>
<item name="colorSecondary">@color/colorPrimary</item>
<item name="colorControlActivated">@color/colorPrimaryLight</item>
<item name="colorControlNormal">@color/colorPrimary</item>
<item name="colorControlHighlight">@color/colorPrimaryLight</item>
<item name="android:textColor">@color/onSecondary</item>
<item name="android:windowBackground">@color/colorSecondary</item>
<item name="android:editTextColor">@color/onSecondary</item>
<item name="materialCalendarFullscreenTheme">@style/MaterialCalendarOverlay</item>
</style>
<style name="MaterialCalendarOverlay" parent="@style/ThemeOverlay.MaterialComponents.MaterialCalendar.Fullscreen">
<item name="materialCalendarStyle">@style/MaterialCalendar</item>
</style>
<style name="MaterialCalendar" parent="@style/Widget.MaterialComponents.MaterialCalendar.Fullscreen">
<item name="android:windowFullscreen">false</item>
</style>
<style name="RadioButton" parent="Widget.AppCompat.CompoundButton.RadioButton">
<item name="android:textColor">@color/onSecondary</item>
<item name="android:buttonTint">@color/colorPrimary</item>
</style>
<style name="MaterialButton" parent="Widget.MaterialComponents.Button">
<item name="android:textColor">@color/onPrimary</item>
<item name="backgroundTint">@color/color_primary_state_list</item>
<item name="iconTint">@color/onPrimary</item>
<item name="iconSize">24dp</item>
</style>
<style name="MaterialButton.Outlined.Primary" parent="Widget.MaterialComponents.Button.OutlinedButton">
<item name="android:textColor">@color/color_primary_state_list</item>
<item name="iconTint">@color/onSecondary</item>
<item name="iconSize">24dp</item>
</style>
<style name="MaterialButton.Outlined.Secondary" parent="Widget.MaterialComponents.Button.OutlinedButton">
<item name="android:textColor">@color/color_primary_state_list</item>
<item name="rippleColor">@color/color_primary_ripple</item>
<item name="iconSize">24dp</item>
<item name="iconTint">@color/onSecondary</item>
</style>
<style name="MaterialImageButton" parent="Widget.MaterialComponents.Button">
<item name="android:tint">@color/colorPrimary</item>
<item name="android:minWidth">20dp</item>
</style>
<style name="FloatingActionButton" parent="Widget.MaterialComponents.FloatingActionButton">
<item name="sdMainFabClosedBackgroundColor">@color/colorPrimary</item>
<item name="sdMainFabOpenedBackgroundColor">@color/colorPrimary</item>
<item name="backgroundTint">@color/colorPrimary</item>
<item name="tint">@color/colorSecondary</item>
<item name="rippleColor">@color/colorSecondary</item>
</style>
<style name="ExtendedFloatingActionButton" parent="Widget.MaterialComponents.ExtendedFloatingActionButton">
<item name="backgroundTint">@color/colorPrimary</item>
<item name="android:textColor">@color/colorSecondary</item>
<item name="iconTint">@color/colorSecondary</item>
<item name="tint">@color/colorSecondary</item>
</style>
<style name="BottomNavigation">
<item name="itemIconTint">@color/colorSecondary</item>
<item name="itemTextColor">@color/colorSecondary</item>
<item name="backgroundTint">@color/colorPrimary</item>
</style>
<style name="OutlinedBox" parent="Widget.MaterialComponents.TextInputLayout.OutlinedBox">
<item name="hintTextColor">@color/colorPrimaryLight</item>
<item name="boxStrokeColor">@color/outlined_box_stroke_color_night</item>
<item name="boxStrokeWidth">2dp</item>
<item name="android:textAppearance">@style/Body1</item>
<item name="startIconTint">@color/onSecondary</item>
<item name="endIconTint">@color/onSecondary</item>
<item name="boxStrokeErrorColor">@color/errorNight</item>
<item name="errorTextColor">@color/errorNight</item>
<item name="materialThemeOverlay">@style/TextInput.TextAppearence</item>
</style>
<style name="OutlinedBox.ExposedDropdownMenu" parent="Widget.MaterialComponents.TextInputLayout.OutlinedBox.ExposedDropdownMenu">
<item name="hintTextColor">@color/colorPrimaryLight</item>
<item name="boxStrokeColor">@color/outlined_box_stroke_color_night</item>
<item name="boxStrokeWidth">2dp</item>
<item name="android:textAppearance">@style/Body1</item>
<item name="startIconTint">@color/onSecondary</item>
<item name="endIconTint">@color/onSecondary</item>
<item name="boxStrokeErrorColor">@color/errorNight</item>
<item name="errorTextColor">@color/errorNight</item>
<item name="materialThemeOverlay">@style/TextInput.TextAppearence</item>
</style>
<style name="TextInput.TextAppearence" parent="Widget.MaterialComponents.TextInputLayout.OutlinedBox">
<item name="textAppearanceSubtitle1">@style/Body1</item>
<item name="textAppearanceCaption">@style/Caption</item>
</style>
<style name="Chip.Action" parent="Widget.MaterialComponents.Chip.Action">
<item name="chipBackgroundColor">@color/chip_action_background_color_night</item>
<item name="android:textColor">@color/chip_text_color_night</item>
</style>
<style name="Chip.Entry" parent="Widget.MaterialComponents.Chip.Entry">
<item name="chipBackgroundColor">@color/chip_selectable_background_color_night</item>
<item name="rippleColor">@color/chip_ripple_color_night</item>
<item name="android:textColor">@color/chip_text_color_night</item>
<item name="checkedIcon">@drawable/chip_checked_circle_night</item>
</style>
<style name="Chip.Filter" parent="Widget.MaterialComponents.Chip.Filter">
<item name="chipBackgroundColor">@color/chip_selectable_background_color_night</item>
<item name="rippleColor">@color/chip_ripple_color_night</item>
<item name="android:textColor">@color/chip_text_color_night</item>
</style>
<style name="Chip.Choice" parent="Widget.MaterialComponents.Chip.Choice">
<item name="chipBackgroundColor">@color/chip_selectable_background_color_night</item>
<item name="rippleColor">@color/chip_ripple_color_night</item>
<item name="android:textColor">@color/chip_text_color_night</item>
</style>
<style name="Slider" parent="Widget.MaterialComponents.Slider">
<item name="thumbColor">@color/colorPrimary</item>
<item name="thumbRadius">10dp</item>
<item name="trackColorActive">@color/colorPrimary</item>
<item name="trackColorInactive">@color/onSecondary</item>
<item name="android:stepSize">1.0</item>
<item name="labelStyle">@style/Tooltip</item>
</style>
<style name="Tooltip" parent="Widget.MaterialComponents.Tooltip">
<item name="shapeAppearance">@style/Tooltip.Shape</item>
<item name="backgroundTint">@color/onSecondary</item>
<item name="android:textColor">@color/colorSecondary</item>
</style>
<style name="Tooltip.Shape" parent="ShapeAppearance.MaterialComponents.Tooltip">
<item name="cornerSize">50%</item>
</style>
<style name="Headline1" parent="TextAppearance.MaterialComponents.Headline1">
<item name="fontFamily">@font/montserrat_light</item>
<item name="android:fontFamily">@font/montserrat_light</item>
<item name="android:textSize">96sp</item>
<item name="android:textColor">@color/onSecondary</item>
</style>
<style name="Headline2" parent="TextAppearance.MaterialComponents.Headline2">
<item name="fontFamily">@font/montserrat_light</item>
<item name="android:fontFamily">@font/montserrat_light</item>
<item name="android:textSize">60sp</item>
<item name="android:textColor">@color/onSecondary</item>
</style>
<style name="Headline3" parent="TextAppearance.MaterialComponents.Headline3">
<item name="fontFamily">@font/montserrat_regular</item>
<item name="android:fontFamily">@font/montserrat_regular</item>
<item name="android:textSize">48sp</item>
<item name="android:textColor">@color/onSecondary</item>
</style>
<style name="Headline4" parent="TextAppearance.MaterialComponents.Headline4">
<item name="fontFamily">@font/montserrat_regular</item>
<item name="android:fontFamily">@font/montserrat_regular</item>
<item name="android:textSize">34sp</item>
<item name="android:textColor">@color/onSecondary</item>
</style>
<style name="Headline5" parent="TextAppearance.MaterialComponents.Headline5">
<item name="fontFamily">@font/montserrat_regular</item>
<item name="android:fontFamily">@font/montserrat_regular</item>
<item name="android:textSize">24sp</item>
<item name="android:textColor">@color/onSecondary</item>
</style>
<style name="Headline6" parent="TextAppearance.MaterialComponents.Headline6">
<item name="fontFamily">@font/montserrat_regular</item>
<item name="android:fontFamily">@font/montserrat_regular</item>
<item name="android:textSize">20sp</item>
<item name="android:textColor">@color/onSecondary</item>
</style>
<style name="Subtitle1" parent="TextAppearance.MaterialComponents.Subtitle1">
<item name="fontFamily">@font/montserrat_regular</item>
<item name="android:fontFamily">@font/montserrat_regular</item>
<item name="android:textSize">16sp</item>
<item name="android:textColor">@color/onSecondary</item>
</style>
<style name="Subtitle2" parent="TextAppearance.MaterialComponents.Subtitle2">
<item name="fontFamily">@font/montserrat_regular</item>
<item name="android:fontFamily">@font/montserrat_regular</item>
<item name="android:textSize">14sp</item>
<item name="android:textColor">@color/onSecondary</item>
</style>
<style name="Body1" parent="TextAppearance.MaterialComponents.Body1">
<item name="fontFamily">@font/roboto_regular</item>
<item name="android:fontFamily">@font/roboto_regular</item>
<item name="android:textSize">16sp</item>
<item name="android:textColor">@color/onSecondary</item>
</style>
<style name="Body2" parent="TextAppearance.MaterialComponents.Body2">
<item name="fontFamily">@font/roboto_regular</item>
<item name="android:fontFamily">@font/roboto_regular</item>
<item name="android:textSize">14sp</item>
<item name="android:textColor">@color/onSecondary</item>
</style>
<style name="Button" parent="TextAppearance.MaterialComponents.Button">
<item name="fontFamily">@font/roboto_medium</item>
<item name="android:fontFamily">@font/roboto_medium</item>
<item name="android:textSize">14sp</item>
<item name="android:textAllCaps">true</item>
<item name="android:textColor">@color/onSecondary</item>
</style>
<style name="Caption" parent="TextAppearance.MaterialComponents.Caption">
<item name="fontFamily">@font/roboto_regular</item>
<item name="android:fontFamily">@font/roboto_regular</item>
<item name="android:textSize">12sp</item>
<item name="android:textColor">@color/onSecondary</item>
</style>
<style name="Overline" parent="TextAppearance.MaterialComponents.Overline">
<item name="fontFamily">@font/roboto_regular</item>
<item name="android:fontFamily">@font/roboto_regular</item>
<item name="android:textSize">10sp</item>
<item name="android:textAllCaps">true</item>
<item name="android:textColor">@color/onSecondary</item>
</style>
</resources>
......@@ -9,6 +9,7 @@
<color name="background">#ffffff</color>
<color name="surface">#ffffff</color>
<color name="error">#97070c</color>
<color name="errorNight">#f74b51</color>
<color name="disabled">#757575</color>
<color name="onPrimary">#000000</color>
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment