Vector assets (plus icon and umbrella icon) and layout components added in order to create the first page :)
This commit is contained in:
parent
9fd97503d9
commit
2733f4def2
@ -1,5 +0,0 @@
|
||||
<vector android:height="24dp" android:tint="#D22E12"
|
||||
android:viewportHeight="24" android:viewportWidth="24"
|
||||
android:width="24dp" xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<path android:fillColor="@android:color/white" android:pathData="M12,2C6.48,2 2,6.48 2,12s4.48,10 10,10 10,-4.48 10,-10S17.52,2 12,2zM17,13h-4v4h-2v-4L7,13v-2h4L11,7h2v4h4v2z"/>
|
||||
</vector>
|
||||
@ -1,5 +1,5 @@
|
||||
<vector android:height="24dp" android:tint="#D2D2D2"
|
||||
<vector android:height="400dp" android:tint="#9CB6B5B5"
|
||||
android:viewportHeight="24" android:viewportWidth="24"
|
||||
android:width="24dp" xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<path android:fillColor="@android:color/white" android:pathData="M14.5,6.92L13,5.77V3.88V3.4c0,-0.26 0.22,-0.48 0.5,-0.48c0.28,0 0.5,0.21 0.5,0.48V4h2V3.4C16,2.07 14.88,1 13.5,1C12.12,1 11,2.07 11,3.4v0.48v1.89L9.5,6.92L6,6.07l5.05,15.25C11.2,21.77 11.6,22 12,22s0.8,-0.23 0.95,-0.69L18,6.07L14.5,6.92zM13.28,8.5l0.76,0.58l0.92,-0.23L13,14.8V8.29L13.28,8.5zM9.96,9.09l0.76,-0.58L11,8.29v6.51L9.03,8.86L9.96,9.09z"/>
|
||||
android:width="400dp" xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<path android:fillColor="#A1A0A0" android:pathData="M14.5,6.92L13,5.77V3.88V3.4c0,-0.26 0.22,-0.48 0.5,-0.48c0.28,0 0.5,0.21 0.5,0.48V4h2V3.4C16,2.07 14.88,1 13.5,1C12.12,1 11,2.07 11,3.4v0.48v1.89L9.5,6.92L6,6.07l5.05,15.25C11.2,21.77 11.6,22 12,22s0.8,-0.23 0.95,-0.69L18,6.07L14.5,6.92zM13.28,8.5l0.76,0.58l0.92,-0.23L13,14.8V8.29L13.28,8.5zM9.96,9.09l0.76,-0.58L11,8.29v6.51L9.03,8.86L9.96,9.09z"/>
|
||||
</vector>
|
||||
@ -1,48 +1,53 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<androidx.constraintlayout.widget.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
xmlns:tools="http://schemas.android.com/tools"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
tools:context=".MainActivity">
|
||||
tools:context=".MainActivity"
|
||||
android:orientation="vertical">
|
||||
|
||||
<com.google.android.material.appbar.AppBarLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:theme="@style/Theme.MyWeather.AppBarOverlay">
|
||||
|
||||
<androidx.appcompat.widget.Toolbar
|
||||
android:id="@+id/toolbar"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:background="#F60707"
|
||||
android:minHeight="?attr/actionBarSize"
|
||||
android:theme="?attr/actionBarTheme"
|
||||
android:layout_height="?attr/actionBarSize"
|
||||
android:background="?attr/colorPrimary"
|
||||
app:title="MyWeather"
|
||||
tools:layout_editor_absoluteX="0dp"
|
||||
tools:layout_editor_absoluteY="-2dp" />
|
||||
app:popupTheme="@style/Theme.MyWeather.PopupOverlay" />
|
||||
|
||||
<com.google.android.material.floatingactionbutton.FloatingActionButton
|
||||
android:id="@+id/floatingActionButton4"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:clickable="true"
|
||||
app:backgroundTint="#FB0C0C"
|
||||
app:rippleColor="#EC0A0A"
|
||||
app:srcCompat="@drawable/ic_baseline_add_circle_24"
|
||||
tools:layout_editor_absoluteX="330dp"
|
||||
tools:layout_editor_absoluteY="632dp" />
|
||||
</com.google.android.material.appbar.AppBarLayout>
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/imageView"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="530dp"
|
||||
app:srcCompat="@drawable/ic_baseline_umbrella_24" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/textView"
|
||||
android:layout_width="233dp"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="51dp"
|
||||
android:textSize="20sp"
|
||||
android:gravity="center"
|
||||
android:layout_marginRight="10dp"
|
||||
android:layout_marginLeft="10dp"
|
||||
android:text="Please click on the 'Add' button in order to add a city"
|
||||
tools:layout_editor_absoluteX="89dp"
|
||||
tools:layout_editor_absoluteY="566dp" />
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/imageView"
|
||||
android:layout_width="320dp"
|
||||
android:layout_height="552dp"
|
||||
app:srcCompat="@drawable/ic_baseline_umbrella_24"
|
||||
tools:layout_editor_absoluteX="45dp"
|
||||
tools:layout_editor_absoluteY="89dp" />
|
||||
<com.google.android.material.floatingactionbutton.FloatingActionButton
|
||||
android:id="@+id/fab"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="bottom|end"
|
||||
android:layout_margin="@dimen/fab_margin"
|
||||
app:backgroundTint="#FF0202"
|
||||
app:rippleColor="#FFFFFF"
|
||||
app:srcCompat="@android:drawable/ic_input_add" />
|
||||
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
</LinearLayout>
|
||||
@ -4,11 +4,11 @@
|
||||
<!-- Primary brand color. -->
|
||||
<item name="colorPrimary">@color/purple_200</item>
|
||||
<item name="colorPrimaryVariant">@color/purple_700</item>
|
||||
<item name="colorOnPrimary">@color/black</item>
|
||||
<item name="colorOnPrimary">@color/white</item>
|
||||
<!-- Secondary brand color. -->
|
||||
<item name="colorSecondary">@color/teal_200</item>
|
||||
<item name="colorSecondaryVariant">@color/teal_200</item>
|
||||
<item name="colorOnSecondary">@color/black</item>
|
||||
<item name="colorSecondary">@color/red</item>
|
||||
<item name="colorSecondaryVariant">@color/red</item>
|
||||
<item name="colorOnSecondary">@color/white</item>
|
||||
<!-- Status bar color. -->
|
||||
<item name="android:statusBarColor" tools:targetApi="l">?attr/colorPrimaryVariant</item>
|
||||
<!-- Customize your theme here. -->
|
||||
|
||||
@ -7,4 +7,5 @@
|
||||
<color name="teal_700">#FF018786</color>
|
||||
<color name="black">#FF000000</color>
|
||||
<color name="white">#FFFFFFFF</color>
|
||||
<color name="red">#FB1100</color>
|
||||
</resources>
|
||||
4
app/src/main/res/values/dimens.xml
Normal file
4
app/src/main/res/values/dimens.xml
Normal file
@ -0,0 +1,4 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<resources>
|
||||
<dimen name="fab_margin" />
|
||||
</resources>
|
||||
@ -1,3 +1,12 @@
|
||||
<resources>
|
||||
<string name="app_name">My Weather</string>
|
||||
<string name="action_settings">Settings</string>
|
||||
<!-- Strings used for fragments for navigation -->
|
||||
<string name="first_fragment_label">First Fragment</string>
|
||||
<string name="second_fragment_label">Second Fragment</string>
|
||||
<string name="next">Next</string>
|
||||
<string name="previous">Previous</string>
|
||||
|
||||
<string name="hello_first_fragment">Hello first fragment</string>
|
||||
<string name="hello_second_fragment">Hello second fragment. Arg: %1$s</string>
|
||||
</resources>
|
||||
@ -2,15 +2,24 @@
|
||||
<!-- Base application theme. -->
|
||||
<style name="Theme.MyWeather" parent="Theme.MaterialComponents.DayNight.DarkActionBar">
|
||||
<!-- Primary brand color. -->
|
||||
<item name="colorPrimary">@color/purple_500</item>
|
||||
<item name="colorPrimaryVariant">@color/purple_700</item>
|
||||
<item name="colorPrimary">@color/red</item>
|
||||
<item name="colorPrimaryVariant">@color/red</item>
|
||||
<item name="colorOnPrimary">@color/white</item>
|
||||
<!-- Secondary brand color. -->
|
||||
<item name="colorSecondary">@color/teal_200</item>
|
||||
<item name="colorSecondaryVariant">@color/teal_700</item>
|
||||
<item name="colorOnSecondary">@color/black</item>
|
||||
<item name="colorSecondary">@color/red</item>
|
||||
<item name="colorSecondaryVariant">@color/red</item>
|
||||
<item name="colorOnSecondary">@color/white</item>
|
||||
<!-- Status bar color. -->
|
||||
<item name="android:statusBarColor" tools:targetApi="l">?attr/colorPrimaryVariant</item>
|
||||
<!-- Customize your theme here. -->
|
||||
</style>
|
||||
|
||||
<style name="Theme.MyWeather.NoActionBar">
|
||||
<item name="windowActionBar">false</item>
|
||||
<item name="windowNoTitle">true</item>
|
||||
</style>
|
||||
|
||||
<style name="Theme.MyWeather.AppBarOverlay" parent="ThemeOverlay.AppCompat.Dark.ActionBar" />
|
||||
|
||||
<style name="Theme.MyWeather.PopupOverlay" parent="ThemeOverlay.AppCompat.Light" />
|
||||
</resources>
|
||||
Loading…
Reference in New Issue
Block a user