Skip to content

Commit

Permalink
[UI/#9] 버튼 마진값 수정
Browse files Browse the repository at this point in the history
  • Loading branch information
leeeyubin committed Jan 4, 2024
1 parent da52f03 commit 4948b47
Show file tree
Hide file tree
Showing 4 changed files with 133 additions and 131 deletions.
8 changes: 4 additions & 4 deletions app/src/main/AndroidManifest.xml
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@
</activity>

<activity
android:name="com.going.presentation.preferencetag.PreferenceTagActivity"
android:name="com.going.presentation.mock.MockActivity"
android:exported="true"
android:screenOrientation="portrait">
<intent-filter>
Expand All @@ -53,9 +53,9 @@
android:name="com.going.presentation.tendencytest.TendencyTestActivity"
android:exported="true" />

<!-- <activity-->
<!-- android:name="com.going.presentation.preference.PreferenceTagActivity"-->
<!-- android:exported="true" />-->
<activity
android:name="com.going.presentation.preferencetag.PreferenceTagActivity"
android:exported="true" />

</application>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,6 @@ class PreferenceTagActivity :

override fun onPreferenceSelected(preference: PreferenceData) {
// 선택된 취향 태그 처리
toast(" ${preference.number} 가 클릭 되었음!")
}

override fun onDestroy() {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,25 +18,28 @@ class PreferenceTagViewHolder(
tvPreferenceRight.text = item.rightPrefer

rgPreferenceTag.setOnCheckedChangeListener { group, checkedId ->
when(checkedId) {
when (checkedId) {
R.id.rb_preference_1 -> {
listener.onPreferenceSelected(item)
}

R.id.rb_preference_2 -> {
listener.onPreferenceSelected(item)
}

R.id.rb_preference_3 -> {
listener.onPreferenceSelected(item)
}

R.id.rb_preference_4 -> {
listener.onPreferenceSelected(item)
}

R.id.rb_preference_5 -> {
listener.onPreferenceSelected(item)
}
}
}

}
}
}
248 changes: 124 additions & 124 deletions presentation/src/main/res/layout/item_preference_tag.xml
Original file line number Diff line number Diff line change
@@ -1,130 +1,130 @@
<?xml version="1.0" encoding="utf-8"?>
<layout>
<data>

<variable
name="viewModel"
type="com.going.presentation.preferencetag.PreferenceTagViewHolder" />

</data>
<androidx.constraintlayout.widget.ConstraintLayout 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="wrap_content"
android:layout_marginBottom="8dp">

<androidx.constraintlayout.widget.ConstraintLayout
android:layout_width="345dp"
android:layout_height="127dp"
android:background="@color/white_000"
app:layout_constraintEnd_toEndOf="parent"
<androidx.constraintlayout.widget.ConstraintLayout 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="wrap_content"
android:layout_marginBottom="8dp">

<androidx.constraintlayout.widget.ConstraintLayout
android:layout_width="345dp"
android:layout_height="127dp"
android:background="@color/white_000"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="parent">

<TextView
android:id="@+id/tv_preference_number"
android:layout_width="24dp"
android:layout_height="24dp"
android:background="@color/gray_300"
android:gravity="center"
android:textColor="@color/black_000"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="parent">

<TextView
android:id="@+id/tv_preference_number"
android:layout_width="24dp"
android:layout_height="24dp"
android:background="@color/gray_300"
app:layout_constraintTop_toTopOf="parent"
tools:text="1" />

<TextView
android:id="@+id/tv_preference_left"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="27dp"
android:fontFamily="@font/pretendard_bold"
android:textColor="@color/black_000"
android:textSize="14sp"
app:layout_constraintEnd_toStartOf="@id/iv_preference_line"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="parent"
tools:text="휴식" />


<ImageView
android:id="@+id/iv_preference_line"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="10dp"
android:src="@drawable/ic_line_black"
app:layout_constraintEnd_toStartOf="@id/tv_preference_right"
app:layout_constraintStart_toEndOf="@id/tv_preference_left"
app:layout_constraintTop_toTopOf="@id/tv_preference_left" />

<TextView
android:id="@+id/tv_preference_right"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="27dp"
android:fontFamily="@font/pretendard_bold"
android:textColor="@color/black_000"
android:textSize="14sp"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toEndOf="@id/iv_preference_line"
app:layout_constraintTop_toTopOf="parent"
tools:text="관광" />

<RadioGroup
android:id="@+id/rg_preference_tag"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginBottom="23dp"
android:orientation="horizontal"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent">

<RadioButton
android:id="@+id/rb_preference_1"
style="@style/radio_preference_button_style"
android:layout_width="48dp"
android:layout_height="48dp"
android:layout_marginEnd="17dp"
android:background="@drawable/sel_rounded_corner_preference_tag_button"
android:gravity="center"
android:text="1"
android:textAppearance="@style/TextAppearance.Doorip.Body3.Medi" />

<RadioButton
android:id="@+id/rb_preference_2"
style="@style/radio_preference_button_style"
android:layout_width="48dp"
android:layout_height="48dp"
android:layout_marginEnd="17dp"
android:background="@drawable/sel_rounded_corner_preference_tag_button"
android:gravity="center"
android:textColor="@color/black_000"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="parent"
tools:text="1" />

<TextView
android:id="@+id/tv_preference_left"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="27dp"
android:fontFamily="@font/pretendard_bold"
android:textColor="@color/black_000"
android:textSize="14sp"
app:layout_constraintEnd_toStartOf="@id/iv_preference_line"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="parent"
tools:text="휴식" />


<ImageView
android:id="@+id/iv_preference_line"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="10dp"
android:src="@drawable/ic_line_black"
app:layout_constraintEnd_toStartOf="@id/tv_preference_right"
app:layout_constraintStart_toEndOf="@id/tv_preference_left"
app:layout_constraintTop_toTopOf="@id/tv_preference_left" />

<TextView
android:id="@+id/tv_preference_right"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="27dp"
android:fontFamily="@font/pretendard_bold"
android:textColor="@color/black_000"
android:textSize="14sp"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toEndOf="@id/iv_preference_line"
app:layout_constraintTop_toTopOf="parent"
tools:text="관광" />

<RadioGroup
android:id="@+id/rg_preference_tag"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginBottom="23dp"
android:orientation="horizontal"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent">

<RadioButton
android:id="@+id/rb_preference_1"
style="@style/radio_preference_button_style"
android:layout_width="48dp"
android:layout_height="48dp"
android:background="@drawable/sel_rounded_corner_preference_tag_button"
android:text="1"
android:textAppearance="@style/TextAppearance.Doorip.Body3.Medi" />

<RadioButton
android:id="@+id/rb_preference_2"
style="@style/radio_preference_button_style"
android:layout_width="48dp"
android:layout_height="48dp"
android:background="@drawable/sel_rounded_corner_preference_tag_button"
android:text="2" />

<RadioButton
android:id="@+id/rb_preference_3"
style="@style/radio_preference_button_style"
android:layout_width="48dp"
android:layout_height="48dp"
android:background="@drawable/sel_rounded_corner_preference_tag_button"
android:text="3" />

<RadioButton
android:id="@+id/rb_preference_4"
style="@style/radio_preference_button_style"
android:layout_width="48dp"
android:layout_height="48dp"
android:background="@drawable/sel_rounded_corner_preference_tag_button"
android:text="4" />

<RadioButton
android:id="@+id/rb_preference_5"
style="@style/radio_preference_button_style"
android:layout_width="48dp"
android:layout_height="48dp"
android:background="@drawable/sel_rounded_corner_preference_tag_button"
android:text="5" />

</RadioGroup>

</androidx.constraintlayout.widget.ConstraintLayout>
android:text="2" />

<RadioButton
android:id="@+id/rb_preference_3"
style="@style/radio_preference_button_style"
android:layout_width="48dp"
android:layout_height="48dp"
android:layout_marginEnd="17dp"
android:background="@drawable/sel_rounded_corner_preference_tag_button"
android:gravity="center"
android:text="3" />

<RadioButton
android:id="@+id/rb_preference_4"
style="@style/radio_preference_button_style"
android:layout_width="48dp"
android:layout_height="48dp"
android:layout_marginEnd="17dp"
android:background="@drawable/sel_rounded_corner_preference_tag_button"
android:gravity="center"
android:text="4" />

<RadioButton
android:id="@+id/rb_preference_5"
style="@style/radio_preference_button_style"
android:layout_width="48dp"
android:layout_height="48dp"
android:background="@drawable/sel_rounded_corner_preference_tag_button"
android:gravity="center"
android:text="5" />

</RadioGroup>

</androidx.constraintlayout.widget.ConstraintLayout>

</layout>
</androidx.constraintlayout.widget.ConstraintLayout>

0 comments on commit 4948b47

Please sign in to comment.