mirror of
https://github.com/pierre42100/ComunicAndroid
synced 2025-07-06 10:02:54 +00:00
Created user page fragment
This commit is contained in:
36
app/src/main/res/layout/fragment_user_page.xml
Normal file
36
app/src/main/res/layout/fragment_user_page.xml
Normal file
@ -0,0 +1,36 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:tools="http://schemas.android.com/tools"
|
||||
android:orientation="vertical"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent">
|
||||
|
||||
<FrameLayout
|
||||
style="@style/UserPageHeader"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content">
|
||||
|
||||
<!-- User name and account image -->
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/user_account_image"
|
||||
android:layout_width="@dimen/account_image_default_width"
|
||||
android:layout_height="@dimen/account_image_default_height"
|
||||
android:src="@drawable/default_account_image"
|
||||
android:contentDescription="@string/user_image_description"/>
|
||||
|
||||
<TextView
|
||||
android:id="@+id/user_account_name"
|
||||
style="@style/UserPageName"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
tools:text="User name"/>
|
||||
</LinearLayout>
|
||||
|
||||
</FrameLayout>
|
||||
|
||||
</LinearLayout>
|
@ -8,4 +8,22 @@
|
||||
<item name="colorAccent">@color/colorAccent</item>
|
||||
</style>
|
||||
|
||||
<!-- User page fragment -->
|
||||
<!-- User page header -->
|
||||
<style name="UserPageHeader">
|
||||
<item name="android:background">@color/colorPrimary</item>
|
||||
<item name="android:paddingTop">1dp</item>
|
||||
<item name="android:paddingBottom">5dp</item>
|
||||
<item name="android:paddingStart">5dp</item>
|
||||
<item name="android:paddingEnd">5dp</item>
|
||||
</style>
|
||||
|
||||
<!-- User name -->
|
||||
<style name="UserPageName">
|
||||
<item name="android:layout_gravity">center</item>
|
||||
<item name="android:textColor">#ffffff</item>
|
||||
<item name="android:textSize">20sp</item>
|
||||
<item name="android:paddingStart">5dp</item>
|
||||
<item name="android:paddingEnd">5dp</item>
|
||||
</style>
|
||||
</resources>
|
||||
|
Reference in New Issue
Block a user