卡片交互效果

This commit is contained in:
zhangyuanzhen
2020-03-11 20:33:24 +08:00
parent 0e63b8f2b4
commit 1827af85c6
47 changed files with 2155 additions and 55 deletions

Binary file not shown.

Before

Width:  |  Height:  |  Size: 5.3 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 16 KiB

After

Width:  |  Height:  |  Size: 5.0 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 13 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.6 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 9.0 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.7 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 13 KiB

After

Width:  |  Height:  |  Size: 12 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.6 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 8.6 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.9 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 13 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.9 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 8.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.6 KiB

View File

@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
<androidx.constraintlayout.widget.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
android:layout_width="match_parent"
android:layout_height="match_parent"
@@ -7,19 +7,40 @@
android:paddingBottom="@dimen/module_apps_navigation_icon_paddingBottom"
>
<androidx.recyclerview.widget.RecyclerView
<com.yarolegovich.discretescrollview.DiscreteScrollView
android:id="@+id/module_apps_id_scroller"
android:layout_width="@dimen/dp_480"
android:layout_height="@dimen/module_apps_navigation_icon_height"
android:layout_width="@dimen/dp_523"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintLeft_toLeftOf="parent"
android:layout_height="@dimen/module_apps_navigation_icon_container_height"
>
</androidx.recyclerview.widget.RecyclerView>
</com.yarolegovich.discretescrollview.DiscreteScrollView>
<ImageView
android:id="@+id/module_apps_id_apps"
android:layout_width="@dimen/module_apps_navigation_icon_width"
android:layout_marginTop="@dimen/dp_18"
android:layout_height="@dimen/module_apps_navigation_icon_height"
app:layout_constraintLeft_toRightOf="@id/module_apps_id_scroller"
app:layout_constraintTop_toTopOf="@id/module_apps_id_scroller"
android:layout_marginLeft="@dimen/module_apps_navigation_icon_marginLeft"
android:src="@drawable/module_apps_ic_apps"
/>
<TextView
android:layout_width="wrap_content"
android:gravity="center"
android:layout_marginLeft="@dimen/dp_37"
app:layout_constraintLeft_toRightOf="@id/module_apps_id_scroller"
app:layout_constraintTop_toBottomOf="@id/module_apps_id_apps"
android:layout_height="wrap_content"
android:text="全部应用"
android:maxLines="1"
android:layout_marginTop="24px"
android:textColor="#FFFFFFFF"
android:textSize="26.25px"
/>
</LinearLayout>
</androidx.constraintlayout.widget.ConstraintLayout>

View File

@@ -1,26 +1,24 @@
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:gravity="center"
android:layout_marginLeft="@dimen/dp_30"
android:layout_marginRight="@dimen/dp_30"
android:layout_width="@dimen/dp_137"
android:layout_height="match_parent"
android:gravity="center|bottom"
android:orientation="vertical">
<ImageView
android:id="@+id/module_apps_id_app_icon"
android:layout_width="@dimen/module_apps_navigation_icon_width"
android:layout_width="@dimen/dp_112"
android:scaleType="fitXY"
android:layout_height="@dimen/module_apps_navigation_icon_height" />
android:layout_height="@dimen/dp_112" />
<TextView
android:id="@+id/module_apps_id_app_name"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="@dimen/module_apps_app_name_marginTop"
android:layout_marginTop="@dimen/dp_24"
android:gravity="center"
android:maxLines="1"
android:textColor="#FFFFFF"
android:textSize="@dimen/module_apps_app_name_textSize" />
android:textSize="@dimen/dp_26" />
</LinearLayout>

View File

@@ -5,9 +5,9 @@
<dimen name="module_apps_indicator_width">30px</dimen>
<dimen name="module_apps_indicator_interval">4px</dimen>
<dimen name="module_apps_indicator_marginBottom">103px</dimen>
<dimen name="module_apps_navigation_icon_width">120px</dimen>
<dimen name="module_apps_navigation_icon_height">120px</dimen>
<dimen name="module_apps_navigation_icon_marginLeft">60px</dimen>
<dimen name="module_apps_navigation_icon_width">94px</dimen>
<dimen name="module_apps_navigation_icon_height">94px</dimen>
<dimen name="module_apps_navigation_icon_marginLeft">43px</dimen>
<dimen name="module_apps_navigation_icon_paddingBottom">60px</dimen>
<dimen name="module_apps_app_name_marginTop">32px</dimen>
<dimen name="module_apps_app_name_textSize">32px</dimen>

View File

@@ -14,4 +14,5 @@
<dimen name="module_apps_page_paddingLeft">220px</dimen>
<dimen name="module_apps_page_paddingRight">220px</dimen>
<dimen name="module_apps_page_item_verticalSpacing">154px</dimen>
<dimen name="module_apps_navigation_icon_container_height">174px</dimen>
</resources>