Skip to content

Commit

Permalink
Merge pull request #26 from NaJuDoRyeong/feature/#23-StoryDetail
Browse files Browse the repository at this point in the history
Feature/#23 story detail
  • Loading branch information
KDW03 authored Sep 26, 2023
2 parents 363452b + 7b256be commit 3646661
Show file tree
Hide file tree
Showing 547 changed files with 893 additions and 124 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ import com.najudoryeong.mineme.feature.home.navigation.homeNavigationRoute
import com.najudoryeong.mineme.feature.home.navigation.homeScreen
import com.najudoryeong.mineme.feature.story.navigation.settingsScreen
import com.najudoryeong.mineme.feature.story.navigation.storyScreen
import com.najudoryeong.mineme.feature.story.navigation.writeStoryScreen
import com.najudoryeong.mineme.ui.DoAppState

@Composable
Expand All @@ -28,6 +29,10 @@ fun DoNavHost(
//todo onStoryClick
storyScreen(onStoryClick = {}, showCalendar = appState.shouldShowCalendar)

writeStoryScreen(
onBackClick = navController::popBackStack
)

settingsScreen()
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -27,11 +27,13 @@ enum class TopLevelDestination(
unselectedIcon = DoIcons.Story.resourceId,
iconTextId = storyR.string.story,
titleTextId = storyR.string.story,
actionIcon = DoIcons.write_story.resourceId
),
settings(
selectedIcon = DoIcons.OnSettings.resourceId,
unselectedIcon = DoIcons.settings.resourceId,
iconTextId = settingsR.string.settings,
titleTextId = settingsR.string.settings,
)

}
20 changes: 13 additions & 7 deletions app/src/main/java/com/najudoryeong/mineme/ui/DoApp.kt
Original file line number Diff line number Diff line change
Expand Up @@ -87,12 +87,16 @@ fun DoApp(
contentWindowInsets = WindowInsets(0, 0, 0, 0),
snackbarHost = { SnackbarHost(snackbarHostState) },
bottomBar = {
DoBottomBar(
destinations = appState.topLevelDestinations,
onNavigateToDestination = appState::navigateToTopLevelDestination,
currentDestination = appState.currentDestination,
modifier = Modifier.testTag("DoBottomBar"),
)
val destination = appState.currentTopLevelDestination
if (destination in TopLevelDestination.values()){
DoBottomBar(
destinations = appState.topLevelDestinations,
onNavigateToDestination = appState::navigateToTopLevelDestination,
currentDestination = appState.currentDestination,
modifier = Modifier.testTag("DoBottomBar"),
)
}

}
) { padding ->

Expand Down Expand Up @@ -130,7 +134,9 @@ fun DoApp(
colors = TopAppBarDefaults.centerAlignedTopAppBarColors(
containerColor = Color.Transparent,
),
onActionClick = {},
onActionClick = {
appState.navigateToWriteStory()
},
onNavigationClick = {
appState.updateShowCalendar()
},
Expand Down
5 changes: 5 additions & 0 deletions app/src/main/java/com/najudoryeong/mineme/ui/DoAppState.kt
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ import com.najudoryeong.mineme.feature.home.navigation.homeNavigationRoute
import com.najudoryeong.mineme.feature.home.navigation.navigateToHome
import com.najudoryeong.mineme.feature.story.navigation.navigateToSettings
import com.najudoryeong.mineme.feature.story.navigation.navigateToStory
import com.najudoryeong.mineme.feature.story.navigation.navigateToWriteStory
import com.najudoryeong.mineme.feature.story.navigation.settingsNavigationRoute
import com.najudoryeong.mineme.feature.story.navigation.storyNavigationRoute
import com.najudoryeong.mineme.navigation.TopLevelDestination
Expand Down Expand Up @@ -96,6 +97,10 @@ class DoAppState(
shouldShowCalendar.value = !shouldShowCalendar.value
}

fun navigateToWriteStory() {
navController.navigateToWriteStory()
}

/**
trace 함수는 특정 작업의 성능 추적을 수행하기 위해 사용
*/
Expand Down
Binary file modified core/data/build/tmp/kapt3/incApCache/demoDebug/apt-cache.bin
Binary file not shown.
Binary file not shown.
Binary file modified core/data/build/tmp/kapt3/incApCache/demoDebug/java-cache.bin
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Original file line number Diff line number Diff line change
Expand Up @@ -12,3 +12,4 @@ int drawable settings 0x0
int drawable story 0x0
int drawable top_region 0x0
int drawable top_story 0x0
int drawable writestory 0x0
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#Tue Sep 26 16:24:34 KST 2023
#Wed Sep 27 01:06:21 KST 2023
com.najudoryeong.mineme.core.designsystem-main-7\:/drawable/appmainimage.xml=C\:\\Users\\kimdowoo\\AndroidStudioProjects\\mineme\\core\\designsystem\\build\\intermediates\\packaged_res\\demoDebug\\drawable\\appmainimage.xml
com.najudoryeong.mineme.core.designsystem-main-7\:/drawable/default_me.xml=C\:\\Users\\kimdowoo\\AndroidStudioProjects\\mineme\\core\\designsystem\\build\\intermediates\\packaged_res\\demoDebug\\drawable\\default_me.xml
com.najudoryeong.mineme.core.designsystem-main-7\:/drawable/default_mine.xml=C\:\\Users\\kimdowoo\\AndroidStudioProjects\\mineme\\core\\designsystem\\build\\intermediates\\packaged_res\\demoDebug\\drawable\\default_mine.xml
Expand All @@ -13,3 +13,4 @@ com.najudoryeong.mineme.core.designsystem-main-7\:/drawable/settings.xml=C\:\\Us
com.najudoryeong.mineme.core.designsystem-main-7\:/drawable/story.xml=C\:\\Users\\kimdowoo\\AndroidStudioProjects\\mineme\\core\\designsystem\\build\\intermediates\\packaged_res\\demoDebug\\drawable\\story.xml
com.najudoryeong.mineme.core.designsystem-main-7\:/drawable/top_region.xml=C\:\\Users\\kimdowoo\\AndroidStudioProjects\\mineme\\core\\designsystem\\build\\intermediates\\packaged_res\\demoDebug\\drawable\\top_region.xml
com.najudoryeong.mineme.core.designsystem-main-7\:/drawable/top_story.xml=C\:\\Users\\kimdowoo\\AndroidStudioProjects\\mineme\\core\\designsystem\\build\\intermediates\\packaged_res\\demoDebug\\drawable\\top_story.xml
com.najudoryeong.mineme.core.designsystem-main-7\:/drawable/writestory.xml=C\:\\Users\\kimdowoo\\AndroidStudioProjects\\mineme\\core\\designsystem\\build\\intermediates\\packaged_res\\demoDebug\\drawable\\writestory.xml
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
<?xml version="1.0" encoding="utf-8"?>
<merger version="3"><dataSet aapt-namespace="http://schemas.android.com/apk/res-auto" config="main$Generated" generated="true" ignore_pattern="!.svn:!.git:!.ds_store:!*.scc:.*:&lt;dir>_*:!CVS:!thumbs.db:!picasa.ini:!*~"><source path="C:\Users\kimdowoo\AndroidStudioProjects\mineme\core\designsystem\src\main\res"/></dataSet><dataSet aapt-namespace="http://schemas.android.com/apk/res-auto" config="main" generated-set="main$Generated" ignore_pattern="!.svn:!.git:!.ds_store:!*.scc:.*:&lt;dir>_*:!CVS:!thumbs.db:!picasa.ini:!*~"><source path="C:\Users\kimdowoo\AndroidStudioProjects\mineme\core\designsystem\src\main\res"><file name="appmainimage" path="C:\Users\kimdowoo\AndroidStudioProjects\mineme\core\designsystem\src\main\res\drawable\appmainimage.xml" qualifiers="" type="drawable"/><file name="default_me" path="C:\Users\kimdowoo\AndroidStudioProjects\mineme\core\designsystem\src\main\res\drawable\default_me.xml" qualifiers="" type="drawable"/><file name="default_mine" path="C:\Users\kimdowoo\AndroidStudioProjects\mineme\core\designsystem\src\main\res\drawable\default_mine.xml" qualifiers="" type="drawable"/><file name="heart" path="C:\Users\kimdowoo\AndroidStudioProjects\mineme\core\designsystem\src\main\res\drawable\heart.xml" qualifiers="" type="drawable"/><file name="home" path="C:\Users\kimdowoo\AndroidStudioProjects\mineme\core\designsystem\src\main\res\drawable\home.xml" qualifiers="" type="drawable"/><file name="no_story" path="C:\Users\kimdowoo\AndroidStudioProjects\mineme\core\designsystem\src\main\res\drawable\no_story.xml" qualifiers="" type="drawable"/><file name="no_story_instory" path="C:\Users\kimdowoo\AndroidStudioProjects\mineme\core\designsystem\src\main\res\drawable\no_story_instory.xml" qualifiers="" type="drawable"/><file name="onhome" path="C:\Users\kimdowoo\AndroidStudioProjects\mineme\core\designsystem\src\main\res\drawable\onhome.xml" qualifiers="" type="drawable"/><file name="onsettings" path="C:\Users\kimdowoo\AndroidStudioProjects\mineme\core\designsystem\src\main\res\drawable\onsettings.xml" qualifiers="" type="drawable"/><file name="onstory" path="C:\Users\kimdowoo\AndroidStudioProjects\mineme\core\designsystem\src\main\res\drawable\onstory.xml" qualifiers="" type="drawable"/><file name="settings" path="C:\Users\kimdowoo\AndroidStudioProjects\mineme\core\designsystem\src\main\res\drawable\settings.xml" qualifiers="" type="drawable"/><file name="story" path="C:\Users\kimdowoo\AndroidStudioProjects\mineme\core\designsystem\src\main\res\drawable\story.xml" qualifiers="" type="drawable"/><file name="top_region" path="C:\Users\kimdowoo\AndroidStudioProjects\mineme\core\designsystem\src\main\res\drawable\top_region.xml" qualifiers="" type="drawable"/><file name="top_story" path="C:\Users\kimdowoo\AndroidStudioProjects\mineme\core\designsystem\src\main\res\drawable\top_story.xml" qualifiers="" type="drawable"/></source></dataSet><dataSet aapt-namespace="http://schemas.android.com/apk/res-auto" config="demo$Generated" generated="true" ignore_pattern="!.svn:!.git:!.ds_store:!*.scc:.*:&lt;dir>_*:!CVS:!thumbs.db:!picasa.ini:!*~"><source path="C:\Users\kimdowoo\AndroidStudioProjects\mineme\core\designsystem\src\demo\res"/></dataSet><dataSet aapt-namespace="http://schemas.android.com/apk/res-auto" config="demo" generated-set="demo$Generated" ignore_pattern="!.svn:!.git:!.ds_store:!*.scc:.*:&lt;dir>_*:!CVS:!thumbs.db:!picasa.ini:!*~"><source path="C:\Users\kimdowoo\AndroidStudioProjects\mineme\core\designsystem\src\demo\res"/></dataSet><dataSet aapt-namespace="http://schemas.android.com/apk/res-auto" config="debug$Generated" generated="true" ignore_pattern="!.svn:!.git:!.ds_store:!*.scc:.*:&lt;dir>_*:!CVS:!thumbs.db:!picasa.ini:!*~"><source path="C:\Users\kimdowoo\AndroidStudioProjects\mineme\core\designsystem\src\debug\res"/></dataSet><dataSet aapt-namespace="http://schemas.android.com/apk/res-auto" config="debug" generated-set="debug$Generated" ignore_pattern="!.svn:!.git:!.ds_store:!*.scc:.*:&lt;dir>_*:!CVS:!thumbs.db:!picasa.ini:!*~"><source path="C:\Users\kimdowoo\AndroidStudioProjects\mineme\core\designsystem\src\debug\res"/></dataSet><dataSet aapt-namespace="http://schemas.android.com/apk/res-auto" config="generated$Generated" generated="true" ignore_pattern="!.svn:!.git:!.ds_store:!*.scc:.*:&lt;dir>_*:!CVS:!thumbs.db:!picasa.ini:!*~"/><dataSet aapt-namespace="http://schemas.android.com/apk/res-auto" config="generated" generated-set="generated$Generated" ignore_pattern="!.svn:!.git:!.ds_store:!*.scc:.*:&lt;dir>_*:!CVS:!thumbs.db:!picasa.ini:!*~"/><dataSet aapt-namespace="http://schemas.android.com/apk/res-auto" config="variant$Generated" generated="true" ignore_pattern="!.svn:!.git:!.ds_store:!*.scc:.*:&lt;dir>_*:!CVS:!thumbs.db:!picasa.ini:!*~"><source path="C:\Users\kimdowoo\AndroidStudioProjects\mineme\core\designsystem\src\demoDebug\res"/></dataSet><dataSet aapt-namespace="http://schemas.android.com/apk/res-auto" config="variant" generated-set="variant$Generated" ignore_pattern="!.svn:!.git:!.ds_store:!*.scc:.*:&lt;dir>_*:!CVS:!thumbs.db:!picasa.ini:!*~"><source path="C:\Users\kimdowoo\AndroidStudioProjects\mineme\core\designsystem\src\demoDebug\res"/></dataSet><mergedItems/></merger>
<merger version="3"><dataSet aapt-namespace="http://schemas.android.com/apk/res-auto" config="main$Generated" generated="true" ignore_pattern="!.svn:!.git:!.ds_store:!*.scc:.*:&lt;dir>_*:!CVS:!thumbs.db:!picasa.ini:!*~"><source path="C:\Users\kimdowoo\AndroidStudioProjects\mineme\core\designsystem\src\main\res"/></dataSet><dataSet aapt-namespace="http://schemas.android.com/apk/res-auto" config="main" generated-set="main$Generated" ignore_pattern="!.svn:!.git:!.ds_store:!*.scc:.*:&lt;dir>_*:!CVS:!thumbs.db:!picasa.ini:!*~"><source path="C:\Users\kimdowoo\AndroidStudioProjects\mineme\core\designsystem\src\main\res"><file name="appmainimage" path="C:\Users\kimdowoo\AndroidStudioProjects\mineme\core\designsystem\src\main\res\drawable\appmainimage.xml" qualifiers="" type="drawable"/><file name="default_me" path="C:\Users\kimdowoo\AndroidStudioProjects\mineme\core\designsystem\src\main\res\drawable\default_me.xml" qualifiers="" type="drawable"/><file name="default_mine" path="C:\Users\kimdowoo\AndroidStudioProjects\mineme\core\designsystem\src\main\res\drawable\default_mine.xml" qualifiers="" type="drawable"/><file name="heart" path="C:\Users\kimdowoo\AndroidStudioProjects\mineme\core\designsystem\src\main\res\drawable\heart.xml" qualifiers="" type="drawable"/><file name="home" path="C:\Users\kimdowoo\AndroidStudioProjects\mineme\core\designsystem\src\main\res\drawable\home.xml" qualifiers="" type="drawable"/><file name="no_story" path="C:\Users\kimdowoo\AndroidStudioProjects\mineme\core\designsystem\src\main\res\drawable\no_story.xml" qualifiers="" type="drawable"/><file name="no_story_instory" path="C:\Users\kimdowoo\AndroidStudioProjects\mineme\core\designsystem\src\main\res\drawable\no_story_instory.xml" qualifiers="" type="drawable"/><file name="onhome" path="C:\Users\kimdowoo\AndroidStudioProjects\mineme\core\designsystem\src\main\res\drawable\onhome.xml" qualifiers="" type="drawable"/><file name="onsettings" path="C:\Users\kimdowoo\AndroidStudioProjects\mineme\core\designsystem\src\main\res\drawable\onsettings.xml" qualifiers="" type="drawable"/><file name="onstory" path="C:\Users\kimdowoo\AndroidStudioProjects\mineme\core\designsystem\src\main\res\drawable\onstory.xml" qualifiers="" type="drawable"/><file name="settings" path="C:\Users\kimdowoo\AndroidStudioProjects\mineme\core\designsystem\src\main\res\drawable\settings.xml" qualifiers="" type="drawable"/><file name="story" path="C:\Users\kimdowoo\AndroidStudioProjects\mineme\core\designsystem\src\main\res\drawable\story.xml" qualifiers="" type="drawable"/><file name="top_region" path="C:\Users\kimdowoo\AndroidStudioProjects\mineme\core\designsystem\src\main\res\drawable\top_region.xml" qualifiers="" type="drawable"/><file name="top_story" path="C:\Users\kimdowoo\AndroidStudioProjects\mineme\core\designsystem\src\main\res\drawable\top_story.xml" qualifiers="" type="drawable"/><file name="writestory" path="C:\Users\kimdowoo\AndroidStudioProjects\mineme\core\designsystem\src\main\res\drawable\writestory.xml" qualifiers="" type="drawable"/></source></dataSet><dataSet aapt-namespace="http://schemas.android.com/apk/res-auto" config="demo$Generated" generated="true" ignore_pattern="!.svn:!.git:!.ds_store:!*.scc:.*:&lt;dir>_*:!CVS:!thumbs.db:!picasa.ini:!*~"><source path="C:\Users\kimdowoo\AndroidStudioProjects\mineme\core\designsystem\src\demo\res"/></dataSet><dataSet aapt-namespace="http://schemas.android.com/apk/res-auto" config="demo" generated-set="demo$Generated" ignore_pattern="!.svn:!.git:!.ds_store:!*.scc:.*:&lt;dir>_*:!CVS:!thumbs.db:!picasa.ini:!*~"><source path="C:\Users\kimdowoo\AndroidStudioProjects\mineme\core\designsystem\src\demo\res"/></dataSet><dataSet aapt-namespace="http://schemas.android.com/apk/res-auto" config="debug$Generated" generated="true" ignore_pattern="!.svn:!.git:!.ds_store:!*.scc:.*:&lt;dir>_*:!CVS:!thumbs.db:!picasa.ini:!*~"><source path="C:\Users\kimdowoo\AndroidStudioProjects\mineme\core\designsystem\src\debug\res"/></dataSet><dataSet aapt-namespace="http://schemas.android.com/apk/res-auto" config="debug" generated-set="debug$Generated" ignore_pattern="!.svn:!.git:!.ds_store:!*.scc:.*:&lt;dir>_*:!CVS:!thumbs.db:!picasa.ini:!*~"><source path="C:\Users\kimdowoo\AndroidStudioProjects\mineme\core\designsystem\src\debug\res"/></dataSet><dataSet aapt-namespace="http://schemas.android.com/apk/res-auto" config="generated$Generated" generated="true" ignore_pattern="!.svn:!.git:!.ds_store:!*.scc:.*:&lt;dir>_*:!CVS:!thumbs.db:!picasa.ini:!*~"/><dataSet aapt-namespace="http://schemas.android.com/apk/res-auto" config="generated" generated-set="generated$Generated" ignore_pattern="!.svn:!.git:!.ds_store:!*.scc:.*:&lt;dir>_*:!CVS:!thumbs.db:!picasa.ini:!*~"/><dataSet aapt-namespace="http://schemas.android.com/apk/res-auto" config="variant$Generated" generated="true" ignore_pattern="!.svn:!.git:!.ds_store:!*.scc:.*:&lt;dir>_*:!CVS:!thumbs.db:!picasa.ini:!*~"><source path="C:\Users\kimdowoo\AndroidStudioProjects\mineme\core\designsystem\src\demoDebug\res"/></dataSet><dataSet aapt-namespace="http://schemas.android.com/apk/res-auto" config="variant" generated-set="variant$Generated" ignore_pattern="!.svn:!.git:!.ds_store:!*.scc:.*:&lt;dir>_*:!CVS:!thumbs.db:!picasa.ini:!*~"><source path="C:\Users\kimdowoo\AndroidStudioProjects\mineme\core\designsystem\src\demoDebug\res"/></dataSet><mergedItems/></merger>
Binary file not shown.
Original file line number Diff line number Diff line change
Expand Up @@ -14,3 +14,4 @@ drawable settings
drawable story
drawable top_region
drawable top_story
drawable writestory
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Original file line number Diff line number Diff line change
Expand Up @@ -13,3 +13,4 @@ drawable settings
drawable story
drawable top_region
drawable top_story
drawable writestory
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
13
46
0
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
package com.najudoryeong.mineme.core.designsystem.component

import androidx.compose.animation.AnimatedVisibility
import androidx.compose.animation.Crossfade
import androidx.compose.animation.core.tween
import androidx.compose.animation.fadeIn
import androidx.compose.animation.fadeOut
import androidx.compose.animation.slideInHorizontally
import androidx.compose.animation.slideOutHorizontally
import androidx.compose.runtime.Composable


@Composable
fun AnimatedScreen(isVisible: Boolean, content: @Composable () -> Unit) {
AnimatedVisibility(
visible = isVisible,
enter = fadeIn() + slideInHorizontally(),
exit = fadeOut() + slideOutHorizontally()
) {
content()
}
}


Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
package com.najudoryeong.mineme.core.designsystem.component

import androidx.annotation.StringRes
import androidx.compose.foundation.layout.fillMaxWidth
import androidx.compose.material3.Button
import androidx.compose.material3.ButtonDefaults
import androidx.compose.material3.MaterialTheme
import androidx.compose.material3.Text
import androidx.compose.runtime.Composable
import androidx.compose.ui.Modifier
import androidx.compose.ui.graphics.Color
import androidx.compose.ui.res.stringResource

@Composable
fun CustomBottomButton(
modifier: Modifier = Modifier,
@StringRes textRes: Int,
enabled: Boolean = true,
onClick: () -> Unit = {}
) {

Button(
onClick = onClick,
modifier = modifier.fillMaxWidth(),
enabled = enabled,
colors = ButtonDefaults.buttonColors(
containerColor = Color(0xFFFFDB94),
disabledContainerColor = Color.White
)
) {
Text(
text = stringResource(id = textRes),
color = Color.Black,
style = MaterialTheme.typography.bodyLarge
)
}

}
Loading

0 comments on commit 3646661

Please sign in to comment.