From ea4b5d49b91f857bd26c3097deb6186e917b2b2f Mon Sep 17 00:00:00 2001 From: Kirill Kamakin Date: Sat, 13 Nov 2021 11:52:20 +0300 Subject: [PATCH] Extract margin_small --- .../res/layout/fragment_authentication.xml | 32 +++++++++---------- app/src/main/res/values/dimens.xml | 4 +++ 2 files changed, 20 insertions(+), 16 deletions(-) create mode 100644 app/src/main/res/values/dimens.xml diff --git a/app/src/main/res/layout/fragment_authentication.xml b/app/src/main/res/layout/fragment_authentication.xml index 6eeb3e0..591e5d3 100644 --- a/app/src/main/res/layout/fragment_authentication.xml +++ b/app/src/main/res/layout/fragment_authentication.xml @@ -11,10 +11,10 @@ style="@style/Widget.MaterialComponents.TextInputLayout.OutlinedBox" android:layout_width="0dp" android:layout_height="wrap_content" - android:layout_marginStart="8dp" - android:layout_marginTop="8dp" - android:layout_marginEnd="8dp" - android:layout_marginBottom="8dp" + android:layout_marginStart="@dimen/margin_small" + android:layout_marginTop="@dimen/margin_small" + android:layout_marginEnd="@dimen/margin_small" + android:layout_marginBottom="@dimen/margin_small" android:hint="@string/fragment_authentication_input_hint_email" app:layout_constraintBottom_toTopOf="@+id/password_input_layout" app:layout_constraintEnd_toEndOf="parent" @@ -35,10 +35,10 @@ style="@style/Widget.MaterialComponents.TextInputLayout.OutlinedBox" android:layout_width="0dp" android:layout_height="wrap_content" - android:layout_marginStart="8dp" - android:layout_marginTop="8dp" - android:layout_marginEnd="8dp" - android:layout_marginBottom="8dp" + android:layout_marginStart="@dimen/margin_small" + android:layout_marginTop="@dimen/margin_small" + android:layout_marginEnd="@dimen/margin_small" + android:layout_marginBottom="@dimen/margin_small" android:hint="@string/fragment_authentication_input_hint_password" app:layout_constraintBottom_toTopOf="@+id/url_input_layout" app:layout_constraintEnd_toEndOf="parent" @@ -57,10 +57,10 @@ style="@style/Widget.MaterialComponents.TextInputLayout.OutlinedBox" android:layout_width="0dp" android:layout_height="wrap_content" - android:layout_marginStart="8dp" - android:layout_marginTop="8dp" - android:layout_marginEnd="8dp" - android:layout_marginBottom="8dp" + android:layout_marginStart="@dimen/margin_small" + android:layout_marginTop="@dimen/margin_small" + android:layout_marginEnd="@dimen/margin_small" + android:layout_marginBottom="@dimen/margin_small" android:hint="@string/fragment_authnetication_input_hint_url" app:layout_constraintBottom_toTopOf="@+id/button" app:layout_constraintEnd_toEndOf="parent" @@ -78,10 +78,10 @@ android:id="@+id/button" android:layout_width="wrap_content" android:layout_height="wrap_content" - android:layout_marginStart="8dp" - android:layout_marginTop="8dp" - android:layout_marginEnd="8dp" - android:layout_marginBottom="8dp" + android:layout_marginStart="@dimen/margin_small" + android:layout_marginTop="@dimen/margin_small" + android:layout_marginEnd="@dimen/margin_small" + android:layout_marginBottom="@dimen/margin_small" android:text="@string/fragment_authentication_button_login" app:layout_constraintBottom_toBottomOf="parent" app:layout_constraintEnd_toEndOf="parent" diff --git a/app/src/main/res/values/dimens.xml b/app/src/main/res/values/dimens.xml new file mode 100644 index 0000000..1f2708e --- /dev/null +++ b/app/src/main/res/values/dimens.xml @@ -0,0 +1,4 @@ + + + 8dp + \ No newline at end of file