Skip to content

Commit

Permalink
Merge branch 'develop' into feature/default-button
Browse files Browse the repository at this point in the history
  • Loading branch information
yuni-ju authored Apr 14, 2022
2 parents 154dfb9 + a9f2a16 commit f42ba13
Show file tree
Hide file tree
Showing 11 changed files with 89 additions and 4 deletions.
14 changes: 14 additions & 0 deletions .github/ISSUE_TEMPLATE/create-new-issue.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
---
name: Create new issue
about: 새로운 이슈를 등록합니다!
title: ''
labels: ''
assignees: ''

---

### 배경
- 본 이슈를 등록하게 된 이유를 설명합니다.(AS-IS, TO-BE)

### 내용
- 본 이슈의 목표를 구체적으로 어떻게 달성할 것인가에 대해 설명합니다.
12 changes: 12 additions & 0 deletions .github/PULL_REQUEST_TEMPLATE.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
### 내용
- 본 PR이 어떤 기능에 대한 작업인지, 이슈를 참조하여 간략하게 설명합니다.

### 작업 사항
- 변경된 코드에 대해 다른 사람들이 빠르게 구조 및 내용을 이해할 수 있도록 간략하게 설명합니다.

### 변경 전 VS 변경 후
|변경 전|변경 후|
|---|---|
|<img src="" width="300" />|<img src="" width="300" />|

### 참고
8 changes: 7 additions & 1 deletion app/build.gradle
Original file line number Diff line number Diff line change
@@ -1,16 +1,18 @@
plugins {
id 'com.android.application'
id 'org.jetbrains.kotlin.android'
id 'kotlin-kapt'
id 'com.google.gms.google-services'
id 'com.google.firebase.crashlytics'
id 'dagger.hilt.android.plugin'
}

android {
compileSdk 32

defaultConfig {
applicationId "com.moyerun.moyeorun_android"
minSdk 21
minSdk 26
targetSdk 32
versionCode 1
versionName "1.0"
Expand Down Expand Up @@ -74,4 +76,8 @@ dependencies {
implementation platform('com.google.firebase:firebase-bom:29.2.0')
implementation 'com.google.firebase:firebase-analytics-ktx'
implementation 'com.google.firebase:firebase-crashlytics-ktx'

// Hilt
implementation "com.google.dagger:hilt-android:$hilt_version"
kapt "com.google.dagger:hilt-android-compiler:$hilt_version"
}
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
package com.moyerun.moyeorun_android

import android.app.Application
import dagger.hilt.android.HiltAndroidApp

@HiltAndroidApp
class MoyeoRunApplication: Application() {

override fun onCreate() {
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
package com.moyerun.moyeorun_android.common.extension

import android.app.Activity
import android.widget.Toast

fun Activity.toast(msg: String, isShort: Boolean = true) {
Toast.makeText(this, msg, if (isShort) Toast.LENGTH_SHORT else Toast.LENGTH_LONG).show()
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
package com.moyerun.moyeorun_android.common.extension

import android.widget.Toast
import androidx.fragment.app.Fragment

fun Fragment.toast(msg: String, isShort: Boolean = false) {
Toast.makeText(context, msg, if (isShort) Toast.LENGTH_SHORT else Toast.LENGTH_LONG).show()
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
package com.moyerun.moyeorun_android.common.extension

import android.view.View

fun View.setOnDebounceClickListener(interval: Long = 1000L, action: (View?) -> Unit) {
val debounceClickListener = object : View.OnClickListener {
private var lastClickedMillis = 0L

override fun onClick(view: View?) {
val now = System.currentTimeMillis()
if (now - lastClickedMillis < interval) {
return
}
lastClickedMillis = now
action.invoke(view)
}
}
setOnClickListener(debounceClickListener)
}
3 changes: 2 additions & 1 deletion app/src/main/res/values-night/themes.xml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,8 @@
<item name="colorSecondaryVariant">@color/main_light_blue</item>
<item name="colorOnSecondary">@color/main_black</item>
<!-- Status bar color. -->
<item name="android:statusBarColor" tools:targetApi="l">?attr/colorPrimaryVariant</item>
<item name="android:statusBarColor" tools:targetApi="l">@android:color/transparent</item>
<item name="android:windowLightStatusBar">true</item>
<!-- Customize your theme here. -->
<item name="android:colorBackground">@color/main_white</item>
</style>
Expand Down
7 changes: 6 additions & 1 deletion app/src/main/res/values/colors.xml
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,13 @@
<color name="main_green">#00F2B8</color>
<color name="main_yellow">#FFDD64</color>
<color name="main_light_blue">#EEF4FF</color>

<!-- text colors -->
<color name="text_default_black">#333333</color>
<color name="text_gray">#828282</color>
<color name="text_hint_gray">#A9A9A9</color>

<!-- extra colors -->
<!-- button colors -->
<color name="button_pressed_true">#0047D0</color>
<color name="button_enable_false">#C4C4C4</color>
<color name="button_text_enable_false">#828282</color>
Expand Down
9 changes: 8 additions & 1 deletion app/src/main/res/values/themes.xml
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,15 @@
<item name="colorSecondaryVariant">@color/main_light_blue</item>
<item name="colorOnSecondary">@color/main_black</item>
<!-- Status bar color. -->
<item name="android:statusBarColor" tools:targetApi="l">?attr/colorPrimaryVariant</item>
<item name="android:statusBarColor" tools:targetApi="l">@android:color/transparent</item>
<item name="android:windowLightStatusBar">true</item>
<!-- Customize your theme here. -->
<item name="android:colorBackground">@color/main_white</item>
<!-- Text -->
<item name="android:textColor">@color/text_default_black</item>
<item name="android:editTextColor">@color/text_default_black</item>
<item name="android:textColorHint">@color/text_hint_gray</item>
<item name="android:textSize">18dp</item>
</style>

</resources>
3 changes: 3 additions & 0 deletions build.gradle
Original file line number Diff line number Diff line change
@@ -1,7 +1,10 @@
buildscript {
ext.hilt_version = '2.40.2'

dependencies {
classpath 'com.google.gms:google-services:4.3.10'
classpath 'com.google.firebase:firebase-crashlytics-gradle:2.8.1'
classpath "com.google.dagger:hilt-android-gradle-plugin:$hilt_version"
}
}

Expand Down

0 comments on commit f42ba13

Please sign in to comment.