|
|
<?xml version="1.0" encoding="utf-8"?>
|
|
|
<RelativeLayout 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"
|
|
|
android:background="@color/col_6f7"
|
|
|
android:orientation="vertical">
|
|
|
|
|
|
<androidx.core.widget.NestedScrollView
|
|
|
android:layout_width="match_parent"
|
|
|
android:layout_height="match_parent">
|
|
|
|
|
|
<LinearLayout
|
|
|
android:layout_width="match_parent"
|
|
|
android:layout_height="match_parent"
|
|
|
android:orientation="vertical"
|
|
|
android:padding="@dimen/dp_14">
|
|
|
|
|
|
<androidx.constraintlayout.widget.ConstraintLayout
|
|
|
android:id="@+id/mConst"
|
|
|
android:layout_width="match_parent"
|
|
|
android:layout_height="wrap_content"
|
|
|
android:layout_marginBottom="12dp"
|
|
|
android:background="@drawable/shape_sleep_bg_8dp">
|
|
|
|
|
|
<TextView
|
|
|
android:id="@+id/compare_tv"
|
|
|
android:layout_width="wrap_content"
|
|
|
android:layout_height="wrap_content"
|
|
|
android:layout_marginLeft="@dimen/dp_16"
|
|
|
android:layout_marginTop="@dimen/dp_22"
|
|
|
android:layout_marginRight="@dimen/dp_12"
|
|
|
android:layout_marginBottom="@dimen/dp_27"
|
|
|
android:drawableRight="@mipmap/arrow_right"
|
|
|
android:drawablePadding="@dimen/dp_6"
|
|
|
android:gravity="center_vertical"
|
|
|
android:text="查看数据对比"
|
|
|
android:textColor="@color/col_c7c"
|
|
|
android:textSize="@dimen/dp_13"
|
|
|
android:textStyle="bold"
|
|
|
app:layout_constraintRight_toRightOf="parent"
|
|
|
app:layout_constraintTop_toTopOf="parent" />
|
|
|
|
|
|
<TextView
|
|
|
android:layout_width="wrap_content"
|
|
|
android:layout_height="wrap_content"
|
|
|
android:layout_marginLeft="@dimen/dp_16"
|
|
|
android:layout_marginTop="@dimen/dp_22"
|
|
|
android:layout_marginBottom="@dimen/dp_27"
|
|
|
android:drawableLeft="@drawable/shape_head_tip_new"
|
|
|
android:drawablePadding="@dimen/dp_10"
|
|
|
android:text="当前心率"
|
|
|
android:textColor="#313131"
|
|
|
android:textSize="@dimen/sp_17"
|
|
|
android:textStyle="bold"
|
|
|
app:layout_constraintLeft_toLeftOf="parent"
|
|
|
app:layout_constraintTop_toTopOf="parent" />
|
|
|
|
|
|
<FrameLayout
|
|
|
android:id="@+id/mFl"
|
|
|
android:layout_width="wrap_content"
|
|
|
android:layout_height="wrap_content"
|
|
|
android:layout_marginTop="@dimen/dp_56"
|
|
|
app:layout_constraintLeft_toLeftOf="parent"
|
|
|
app:layout_constraintRight_toRightOf="parent"
|
|
|
app:layout_constraintTop_toTopOf="parent">
|
|
|
|
|
|
<ImageView
|
|
|
android:layout_width="wrap_content"
|
|
|
android:layout_height="wrap_content"
|
|
|
android:background="@mipmap/ic_bg_oval" />
|
|
|
|
|
|
<LinearLayout
|
|
|
android:layout_width="wrap_content"
|
|
|
android:layout_height="wrap_content"
|
|
|
android:layout_gravity="center"
|
|
|
android:orientation="vertical">
|
|
|
|
|
|
<LinearLayout
|
|
|
android:layout_width="wrap_content"
|
|
|
android:layout_height="wrap_content"
|
|
|
android:orientation="horizontal">
|
|
|
|
|
|
<TextView
|
|
|
android:id="@+id/tvXinLv"
|
|
|
android:layout_width="wrap_content"
|
|
|
android:layout_height="wrap_content"
|
|
|
android:textColor="@color/col_02c"
|
|
|
android:textSize="@dimen/dp_35"
|
|
|
android:textStyle="bold"
|
|
|
tools:text="85" />
|
|
|
|
|
|
<TextView
|
|
|
android:layout_width="wrap_content"
|
|
|
android:layout_height="wrap_content"
|
|
|
android:text="次/分"
|
|
|
android:textColor="@color/col_02c"
|
|
|
android:textSize="@dimen/sp_13"
|
|
|
android:textStyle="bold" />
|
|
|
|
|
|
</LinearLayout>
|
|
|
|
|
|
<TextView
|
|
|
android:id="@+id/tvTestTime"
|
|
|
android:layout_width="wrap_content"
|
|
|
android:layout_height="wrap_content"
|
|
|
android:layout_gravity="center"
|
|
|
tools:text="次/分"
|
|
|
android:textColor="@color/col_6B6"
|
|
|
android:textSize="@dimen/sp_12"
|
|
|
android:textStyle="bold" />
|
|
|
|
|
|
</LinearLayout>
|
|
|
|
|
|
</FrameLayout>
|
|
|
|
|
|
<com.xty.common.weight.FullCircleInfo
|
|
|
android:id="@+id/mFull"
|
|
|
android:layout_width="match_parent"
|
|
|
android:layout_height="200dp"
|
|
|
android:visibility="gone"
|
|
|
app:bottom_size="@dimen/dp_15"
|
|
|
app:bottom_txt="-"
|
|
|
app:center_txt="-"
|
|
|
app:layout_constraintLeft_toLeftOf="parent"
|
|
|
app:layout_constraintRight_toRightOf="parent"
|
|
|
app:layout_constraintTop_toTopOf="parent"
|
|
|
app:showValue="90"
|
|
|
app:top_size="@dimen/dp_15"
|
|
|
app:top_txt="当前心率"
|
|
|
app:unit="次/分"
|
|
|
app:value_size="@dimen/dp_30" />
|
|
|
|
|
|
<include
|
|
|
android:id="@+id/mOrganView"
|
|
|
layout="@layout/organ_view"
|
|
|
android:layout_width="match_parent"
|
|
|
android:layout_height="wrap_content"
|
|
|
android:layout_marginTop="@dimen/dp_10"
|
|
|
android:layout_marginBottom="@dimen/dp_20"
|
|
|
app:layout_constraintBottom_toBottomOf="parent"
|
|
|
app:layout_constraintTop_toBottomOf="@+id/mFl" />
|
|
|
|
|
|
</androidx.constraintlayout.widget.ConstraintLayout>
|
|
|
|
|
|
<LinearLayout
|
|
|
android:layout_width="match_parent"
|
|
|
android:layout_height="wrap_content"
|
|
|
android:layout_marginBottom="@dimen/dp_12"
|
|
|
android:background="@drawable/shape_sleep_bg_8dp"
|
|
|
android:orientation="vertical">
|
|
|
|
|
|
<LinearLayout
|
|
|
android:layout_width="match_parent"
|
|
|
android:layout_height="wrap_content"
|
|
|
android:layout_marginTop="@dimen/dp_22"
|
|
|
android:gravity="center_vertical"
|
|
|
android:orientation="horizontal">
|
|
|
|
|
|
<TextView
|
|
|
android:id="@+id/tvProfession"
|
|
|
android:layout_width="wrap_content"
|
|
|
android:layout_height="wrap_content"
|
|
|
android:layout_marginLeft="@dimen/dp_16"
|
|
|
android:drawableLeft="@drawable/shape_head_tip_new"
|
|
|
android:drawablePadding="@dimen/dp_10"
|
|
|
android:text="心率情况"
|
|
|
android:textColor="#313131"
|
|
|
android:textSize="@dimen/sp_17"
|
|
|
android:textStyle="bold" />
|
|
|
|
|
|
<View
|
|
|
android:layout_width="0dp"
|
|
|
android:layout_height="0dp"
|
|
|
android:layout_weight="1" />
|
|
|
|
|
|
<TextView
|
|
|
android:layout_width="wrap_content"
|
|
|
android:layout_height="wrap_content"
|
|
|
android:layout_marginRight="@dimen/dp_16"
|
|
|
android:text="单位:次/分" />
|
|
|
|
|
|
</LinearLayout>
|
|
|
|
|
|
<LinearLayout
|
|
|
android:id="@+id/mConstBottom"
|
|
|
android:layout_width="match_parent"
|
|
|
android:layout_height="wrap_content"
|
|
|
android:layout_below="@+id/mConst"
|
|
|
android:orientation="horizontal"
|
|
|
android:paddingBottom="@dimen/dp_21">
|
|
|
|
|
|
<com.xty.common.weight.MyShowValue
|
|
|
android:id="@+id/mAvg"
|
|
|
android:layout_width="0dp"
|
|
|
android:layout_height="wrap_content"
|
|
|
android:layout_weight="1"
|
|
|
app:desc="平均心率"
|
|
|
app:num="-"
|
|
|
app:units=""
|
|
|
app:unt_color="@color/col_02c"
|
|
|
app:values_color="@color/col_02c" />
|
|
|
|
|
|
<com.xty.common.weight.MyShowValue
|
|
|
android:id="@+id/mMax"
|
|
|
android:layout_width="0dp"
|
|
|
android:layout_height="wrap_content"
|
|
|
android:layout_weight="1"
|
|
|
app:desc="最高心率"
|
|
|
app:num="-"
|
|
|
app:units="" />
|
|
|
|
|
|
<com.xty.common.weight.MyShowValue
|
|
|
android:id="@+id/mMin"
|
|
|
android:layout_width="0dp"
|
|
|
android:layout_height="wrap_content"
|
|
|
android:layout_weight="1"
|
|
|
app:desc="最低心率"
|
|
|
app:num="-"
|
|
|
app:units="" />
|
|
|
|
|
|
</LinearLayout>
|
|
|
|
|
|
</LinearLayout>
|
|
|
|
|
|
<LinearLayout
|
|
|
android:layout_width="match_parent"
|
|
|
android:layout_height="wrap_content"
|
|
|
android:background="@drawable/shape_sleep_bg_8dp"
|
|
|
android:orientation="vertical"
|
|
|
android:paddingLeft="@dimen/dp_11"
|
|
|
android:paddingTop="@dimen/dp_20"
|
|
|
android:paddingRight="@dimen/dp_11"
|
|
|
android:paddingBottom="@dimen/dp_20">
|
|
|
|
|
|
<RadioGroup
|
|
|
android:id="@+id/mGroup"
|
|
|
android:layout_width="match_parent"
|
|
|
android:layout_height="@dimen/dp_30"
|
|
|
android:layout_below="@+id/mConstBottom"
|
|
|
android:layout_gravity="center"
|
|
|
android:layout_marginLeft="@dimen/dp_60"
|
|
|
android:layout_marginTop="@dimen/dp_10"
|
|
|
android:layout_marginRight="@dimen/dp_60"
|
|
|
android:background="@drawable/shape_radio_group_bg"
|
|
|
android:orientation="horizontal"
|
|
|
android:visibility="gone">
|
|
|
|
|
|
<RadioButton
|
|
|
android:id="@+id/mDay"
|
|
|
android:layout_width="0dp"
|
|
|
android:layout_height="match_parent"
|
|
|
android:layout_weight="1"
|
|
|
android:background="@drawable/sel_radio"
|
|
|
android:button="@null"
|
|
|
android:checked="true"
|
|
|
android:color="@android:color/transparent"
|
|
|
android:gravity="center"
|
|
|
android:text="日" />
|
|
|
|
|
|
<RadioButton
|
|
|
android:id="@+id/mWeek"
|
|
|
android:layout_width="0dp"
|
|
|
android:layout_height="match_parent"
|
|
|
android:layout_weight="1"
|
|
|
android:background="@drawable/sel_radio"
|
|
|
android:button="@null"
|
|
|
android:color="@android:color/transparent"
|
|
|
android:gravity="center"
|
|
|
android:text="周" />
|
|
|
|
|
|
<RadioButton
|
|
|
android:id="@+id/mMonth"
|
|
|
android:layout_width="0dp"
|
|
|
android:layout_height="match_parent"
|
|
|
android:layout_weight="1"
|
|
|
android:background="@drawable/sel_radio"
|
|
|
android:button="@null"
|
|
|
android:color="@android:color/transparent"
|
|
|
android:gravity="center"
|
|
|
android:text="月" />
|
|
|
|
|
|
<RadioButton
|
|
|
android:id="@+id/mYear"
|
|
|
android:layout_width="0dp"
|
|
|
android:layout_height="match_parent"
|
|
|
android:layout_weight="1"
|
|
|
android:background="@drawable/sel_radio"
|
|
|
android:button="@null"
|
|
|
android:gravity="center"
|
|
|
android:text="年" />
|
|
|
|
|
|
</RadioGroup>
|
|
|
|
|
|
<TextView
|
|
|
android:id="@+id/mTvTime"
|
|
|
android:layout_width="wrap_content"
|
|
|
android:layout_height="wrap_content"
|
|
|
android:layout_gravity="center"
|
|
|
android:drawableRight="@mipmap/ic_down_show"
|
|
|
android:drawablePadding="@dimen/dp_10"
|
|
|
android:gravity="center"
|
|
|
android:paddingTop="@dimen/dp_10"
|
|
|
android:textColor="@color/col_455"
|
|
|
android:textSize="@dimen/sp_16"
|
|
|
android:visibility="gone" />
|
|
|
|
|
|
<androidx.constraintlayout.widget.ConstraintLayout
|
|
|
android:layout_width="match_parent"
|
|
|
android:layout_height="@dimen/dp_40"
|
|
|
android:orientation="horizontal">
|
|
|
|
|
|
<com.xty.common.weight.tablayout.CommonTabLayout
|
|
|
android:id="@+id/commonTabLayout"
|
|
|
android:layout_width="0dp"
|
|
|
android:layout_height="match_parent"
|
|
|
android:layout_marginEnd="@dimen/dp_12"
|
|
|
app:layout_constraintBottom_toBottomOf="parent"
|
|
|
app:layout_constraintEnd_toStartOf="@+id/tvHideDate"
|
|
|
app:layout_constraintStart_toStartOf="parent"
|
|
|
app:layout_constraintTop_toTopOf="parent"
|
|
|
app:tl_iconVisible="false"
|
|
|
app:tl_indicator_color="@color/col_02c"
|
|
|
app:tl_indicator_corner_radius="@dimen/dp_2"
|
|
|
app:tl_indicator_height="@dimen/dp_3"
|
|
|
app:tl_indicator_width="@dimen/dp_16"
|
|
|
app:tl_textSelectColor="@color/col_02c"
|
|
|
app:tl_textUnselectColor="#7C7C7C"
|
|
|
app:tl_textsize="@dimen/sp_15"
|
|
|
app:tl_textsizeSelected="@dimen/sp_15" />
|
|
|
|
|
|
<ImageView
|
|
|
android:id="@+id/ivPosition"
|
|
|
android:layout_width="wrap_content"
|
|
|
android:layout_height="wrap_content"
|
|
|
android:layout_marginEnd="9dp"
|
|
|
android:padding="5dp"
|
|
|
android:src="@mipmap/ic_arrow_down"
|
|
|
app:layout_constraintBottom_toBottomOf="parent"
|
|
|
app:layout_constraintEnd_toEndOf="parent"
|
|
|
app:layout_constraintTop_toTopOf="parent" />
|
|
|
|
|
|
<TextView
|
|
|
android:id="@+id/tvHideDate"
|
|
|
android:layout_width="wrap_content"
|
|
|
android:layout_height="wrap_content"
|
|
|
android:text="2023-02-24 至 2023-02-24"
|
|
|
android:textColor="#313131"
|
|
|
android:textSize="@dimen/sp_12"
|
|
|
android:visibility="invisible"
|
|
|
app:layout_constraintBottom_toBottomOf="parent"
|
|
|
app:layout_constraintEnd_toStartOf="@+id/ivPosition"
|
|
|
app:layout_constraintTop_toTopOf="parent" />
|
|
|
|
|
|
<TextView
|
|
|
android:id="@+id/tvShowDate"
|
|
|
android:layout_width="wrap_content"
|
|
|
android:layout_height="wrap_content"
|
|
|
android:text="2023-02-24"
|
|
|
android:textColor="#313131"
|
|
|
android:textSize="@dimen/sp_12"
|
|
|
app:layout_constraintBottom_toBottomOf="parent"
|
|
|
app:layout_constraintEnd_toStartOf="@+id/ivPosition"
|
|
|
app:layout_constraintTop_toTopOf="parent" />
|
|
|
|
|
|
</androidx.constraintlayout.widget.ConstraintLayout>
|
|
|
|
|
|
<RelativeLayout
|
|
|
android:layout_width="match_parent"
|
|
|
android:layout_height="wrap_content"
|
|
|
android:layout_marginTop="@dimen/dp_20"
|
|
|
android:gravity="center_vertical">
|
|
|
|
|
|
<TextView
|
|
|
android:id="@+id/mTip"
|
|
|
android:layout_width="wrap_content"
|
|
|
android:layout_height="wrap_content"
|
|
|
android:layout_centerVertical="true"
|
|
|
android:layout_marginLeft="@dimen/dp_11"
|
|
|
android:layout_marginRight="@dimen/dp_20"
|
|
|
android:drawableStart="@mipmap/ic_info_icon"
|
|
|
android:drawablePadding="@dimen/dp_5"
|
|
|
android:text="@string/tip_head"
|
|
|
android:textSize="@dimen/sp_12"
|
|
|
android:textColor="@color/col_7c7"
|
|
|
tools:ignore="UseCompatTextViewDrawableXml" />
|
|
|
|
|
|
<ImageView
|
|
|
android:id="@+id/zhexian_tv"
|
|
|
android:layout_width="wrap_content"
|
|
|
android:layout_height="wrap_content"
|
|
|
android:layout_alignParentBottom="true"
|
|
|
android:layout_toStartOf="@+id/zhuzhuan_tv"
|
|
|
android:paddingLeft="@dimen/dp_10"
|
|
|
android:paddingTop="@dimen/dp_8"
|
|
|
android:paddingRight="@dimen/dp_10"
|
|
|
android:paddingBottom="@dimen/dp_8"
|
|
|
android:src="@mipmap/ic_zhexiant" />
|
|
|
|
|
|
<ImageView
|
|
|
android:id="@+id/zhuzhuan_tv"
|
|
|
android:layout_width="wrap_content"
|
|
|
android:layout_height="wrap_content"
|
|
|
android:layout_alignParentBottom="true"
|
|
|
android:layout_toStartOf="@+id/mDesc"
|
|
|
android:paddingLeft="@dimen/dp_10"
|
|
|
android:paddingTop="@dimen/dp_8"
|
|
|
android:paddingRight="@dimen/dp_10"
|
|
|
android:paddingBottom="@dimen/dp_8"
|
|
|
android:src="@mipmap/ic_shuzhuangtu_yixuan" />
|
|
|
|
|
|
<TextView
|
|
|
android:id="@+id/mDesc"
|
|
|
android:layout_width="wrap_content"
|
|
|
android:layout_height="wrap_content"
|
|
|
android:layout_alignParentRight="true"
|
|
|
android:layout_centerVertical="true"
|
|
|
android:layout_marginStart="@dimen/dp_4"
|
|
|
android:layout_marginRight="@dimen/dp_4"
|
|
|
android:drawableLeft="@drawable/shape_hint_bg"
|
|
|
android:drawablePadding="@dimen/dp_4"
|
|
|
android:gravity="center|right"
|
|
|
android:text="正常心率:50-100次/分"
|
|
|
android:textColor="@color/col_c7c"
|
|
|
android:textSize="@dimen/sp_12"
|
|
|
android:textStyle="bold" />
|
|
|
|
|
|
</RelativeLayout>
|
|
|
|
|
|
<com.github.mikephil.charting.charts.LineChart
|
|
|
android:id="@+id/mLineChart"
|
|
|
android:layout_width="match_parent"
|
|
|
android:layout_height="200dp"
|
|
|
android:visibility="gone" />
|
|
|
|
|
|
<com.github.mikephil.charting.charts.BarChart
|
|
|
android:id="@+id/mBarChart"
|
|
|
android:layout_width="match_parent"
|
|
|
android:layout_height="200dp" />
|
|
|
|
|
|
</LinearLayout>
|
|
|
|
|
|
<TextView
|
|
|
android:id="@+id/tv_tips"
|
|
|
android:layout_width="wrap_content"
|
|
|
android:layout_height="wrap_content"
|
|
|
android:textColor="@color/col_313"
|
|
|
android:layout_marginTop="@dimen/dp_17"
|
|
|
android:textSize="@dimen/sp_15"
|
|
|
android:text="了解心率:\n心率是指人体心脏每分钟搏动的次数,为人的基本生命体征之一;成年人安静状态下的心率一般为50-100次每分钟,其通常会因年龄、性别或其他生理因素产生个体差异。运动时心跳会加速,心肺功能较好的运动员心率通常会比普通成年人的心跳要慢。"
|
|
|
/>
|
|
|
</LinearLayout>
|
|
|
|
|
|
</androidx.core.widget.NestedScrollView>
|
|
|
|
|
|
</RelativeLayout>
|