Skip to content

Commit

Permalink
[feat/#18] 신고하기 바텀시트 다이어로그 구현
Browse files Browse the repository at this point in the history
  • Loading branch information
Jokwanhee committed Jul 14, 2024
1 parent cce935e commit 9c02248
Show file tree
Hide file tree
Showing 3 changed files with 65 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ import com.depromeet.core.base.BaseActivity
import com.depromeet.presentation.R
import com.depromeet.presentation.databinding.ActivityStadiumDetailBinding
import com.depromeet.presentation.viewfinder.compose.StadiumDetailScreen
import com.depromeet.presentation.viewfinder.dialog.ReportDialog
import com.depromeet.presentation.viewfinder.dialog.StadiumFilterMonthsDialog
import com.depromeet.presentation.viewfinder.dialog.StadiumSelectSeatDialog
import com.depromeet.presentation.viewfinder.sample.ReviewContent
Expand Down Expand Up @@ -55,6 +56,9 @@ class StadiumDetailActivity : BaseActivity<ActivityStadiumDetailBinding>({
StadiumFilterMonthsDialog.newInstance()
.show(supportFragmentManager, StadiumFilterMonthsDialog.TAG)
},
onClickReport = {
ReportDialog.newInstance()
.show(supportFragmentManager, ReportDialog.TAG)
}
)
}
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
package com.depromeet.presentation.viewfinder.dialog

import android.os.Bundle
import android.view.View
import com.depromeet.core.base.BindingBottomSheetDialog
import com.depromeet.presentation.R
import com.depromeet.presentation.databinding.FragmentReportDialogBinding
import com.depromeet.presentation.extension.toast

class ReportDialog : BindingBottomSheetDialog<FragmentReportDialogBinding>(
R.layout.fragment_report_dialog,
FragmentReportDialogBinding::inflate
) {
companion object {
const val TAG = "ReportDialog"

fun newInstance(): ReportDialog {
val args = Bundle()

val fragment = ReportDialog()
fragment.arguments = args
return fragment
}
}

override fun onCreate(savedInstanceState: Bundle?) {
super.onCreate(savedInstanceState)
setStyle(STYLE_NORMAL, R.style.TransparentBottomSheetDialogFragment)
}

override fun onViewCreated(view: View, savedInstanceState: Bundle?) {
super.onViewCreated(view, savedInstanceState)

binding.tvReport.setOnClickListener {
toast("구글폼 드가자")
}
}
}
23 changes: 23 additions & 0 deletions presentation/src/main/res/layout/fragment_report_dialog.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
<?xml version="1.0" encoding="utf-8"?>
<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"
android:background="@drawable/rect_white_fill_32">

<TextView
android:id="@+id/tv_report"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginVertical="30dp"
android:padding="12dp"
android:text="신고하기"
android:textColor="#121212"
android:textSize="20sp"
android:textStyle="bold"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="parent" />

</androidx.constraintlayout.widget.ConstraintLayout>

0 comments on commit 9c02248

Please sign in to comment.