• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    迪恩网络公众号

florent37/Shrine-MaterialDesign2: implementation of Material Design 2 Shrine pro ...

原作者: [db:作者] 来自: 网络 收藏 邀请

开源软件名称(OpenSource Name):

florent37/Shrine-MaterialDesign2

开源软件地址(OpenSource Url):

https://github.com/florent37/Shrine-MaterialDesign2

开源编程语言(OpenSource Language):

Kotlin 100.0%

开源软件介绍(OpenSource Introduction):

Shrine-MaterialDesign2

Trying to reproduce some elements of Material Design 2 Shrine project on Android

https://material.io/design/material-studies/shrine.html#about-shrine

shrine_video

About Shrine

The Shrine app provides an online marketplace featuring lifestyle and fashion items from promoted labels. Shrine’s brand aesthetic is modern, elegant, and sophisticated, and is the unifying concept behind the various brands and products showcased.

shrine_info_1

Overlapping sheets

The underlying theme of Shrine’s interaction model is that of three overlapping sheets. The bottom sheet has the navigation and branding elements; the middle sheet has the main content; and the top sheet has the shopping cart. shrine_info_2

Implementation

I used ShapeOfView to allow views to have a custom shape,

https://github.com/florent37/ShapeOfView

implementation 'com.github.florent37:shapeofview:1.0.7'

Here, to remove my view's corners, using CutCornerView

shrine_info_2

Button

shape_button

 <com.github.florent37.shapeofview.shapes.CutCornerView
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        
        android:elevation="3dp"
        
        app:shape_cutCorner_bottomLeftSize="12dp"
        app:shape_cutCorner_bottomRightSize="12dp"
        app:shape_cutCorner_topLeftSize="12dp"
        app:shape_cutCorner_topRightSize="12dp">

        <android.support.constraint.ConstraintLayout
            android:id="@+id/addToCart"
            android:layout_width="match_parent"
            android:layout_height="wrap_content"
            android:background="@android:color/white"
            android:foreground="?attr/selectableItemBackground">
            
            <ImageView ... />
            
            <TextView ... />

Sheets

sheets

<com.github.florent37.shapeofview.shapes.CutCornerView
    android:id="@+id/middleSheet"
    android:layout_width="0dp"
    android:layout_height="0dp"
    android:layout_marginTop="16dp"
    android:elevation="4dp"
    app:layout_constraintBottom_toBottomOf="parent"
    app:layout_constraintEnd_toEndOf="parent"
    app:layout_constraintStart_toStartOf="parent"
    app:layout_constraintTop_toBottomOf="@+id/menu"
    app:shape_cutCorner_topLeftSize="42dp"
    tools:showIn="@layout/activity_main">

    <android.support.constraint.ConstraintLayout
        android:layout_width="match_parent"
        android:layout_height="match_parent"
        android:background="@android:color/white">

Fiches Plateau Moto : https://www.fiches-plateau-moto.fr/




鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap