Skip to content

Commit

Permalink
Merge pull request #9 from taetae98coding/develop
Browse files Browse the repository at this point in the history
1.3.2
  • Loading branch information
taetae98coding authored Dec 18, 2024
2 parents bc1301c + 0db377a commit 824b532
Show file tree
Hide file tree
Showing 254 changed files with 12,800 additions and 7,729 deletions.
13 changes: 13 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,19 @@

All notable changes to this project will be documented in this file.

## [1.3.2] - 2024-12-18

### 🚀 Features

- App - BuddyGroupMemo Detail update, finish, delete
- Android - multi instance

### 🐛 Bug Fixes

- App - MemoDetailRoute Finish, Delete Button
- App - MemoDetail Update
- Server - filter not fcm requester

## [1.3.1] - 2024-12-10

### 🚀 Features
Expand Down
18 changes: 9 additions & 9 deletions Diary/Diary.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -186,7 +186,7 @@
);
runOnlyForDeploymentPostprocessing = 0;
shellPath = /bin/sh;
shellScript = "cd \"$SRCROOT/..\"\n\n./gradlew buildCocoapods\n\ncase \"${CONFIGURATION}\" in\n \"DevDebug\" )\n./gradlew :app:platform:ios:embedAndSignAppleFrameworkForXcode -Pbuildkonfig.flavor=dev ;;\n \"DevRelease\" )\n./gradlew :app:platform:ios:embedAndSignAppleFrameworkForXcode -Pbuildkonfig.flavor=dev ;;\n \"RealDebug\" )\n./gradlew :app:platform:ios:embedAndSignAppleFrameworkForXcode -Pbuildkonfig.flavor=real ;;\n \"RealRelease\" )\n./gradlew :app:platform:ios:embedAndSignAppleFrameworkForXcode -Pbuildkonfig.flavor=real ;;\n*)\n;;\nesac\n";
shellScript = "cd \"$SRCROOT/..\"\n\ncase \"${CONFIGURATION}\" in\n \"DevDebug\" )\n./gradlew :app:platform:ios:embedAndSignAppleFrameworkForXcode -Pbuildkonfig.flavor=dev ;;\n \"DevRelease\" )\n./gradlew :app:platform:ios:embedAndSignAppleFrameworkForXcode -Pbuildkonfig.flavor=dev ;;\n \"RealDebug\" )\n./gradlew :app:platform:ios:embedAndSignAppleFrameworkForXcode -Pbuildkonfig.flavor=real ;;\n \"RealRelease\" )\n./gradlew :app:platform:ios:embedAndSignAppleFrameworkForXcode -Pbuildkonfig.flavor=real ;;\n*)\n;;\nesac\n";
};
/* End PBXShellScriptBuildPhase section */

Expand Down Expand Up @@ -272,10 +272,10 @@
ASSETCATALOG_COMPILER_GLOBAL_ACCENT_COLOR_NAME = AccentColor;
CODE_SIGN_ENTITLEMENTS = Diary/Diary.entitlements;
CODE_SIGN_IDENTITY = "Apple Development";
CODE_SIGN_STYLE = Manual;
CODE_SIGN_STYLE = Automatic;
CURRENT_PROJECT_VERSION = 1;
DEVELOPMENT_ASSET_PATHS = "\"Diary/Preview Content\"";
DEVELOPMENT_TEAM = "";
DEVELOPMENT_TEAM = 4TV6L66XZ8;
ENABLE_PREVIEWS = YES;
ENABLE_USER_SCRIPT_SANDBOXING = NO;
GENERATE_INFOPLIST_FILE = YES;
Expand All @@ -292,7 +292,7 @@
"$(inherited)",
"@executable_path/Frameworks",
);
MARKETING_VERSION = 1.3.1;
MARKETING_VERSION = 1.3.2;
PRODUCT_BUNDLE_IDENTIFIER = io.github.taetae98coding.diary.debug;
PRODUCT_NAME = "$(TARGET_NAME)";
PROVISIONING_PROFILE_SPECIFIER = "";
Expand Down Expand Up @@ -388,7 +388,7 @@
"$(inherited)",
"@executable_path/Frameworks",
);
MARKETING_VERSION = 1.3.1;
MARKETING_VERSION = 1.3.2;
PRODUCT_BUNDLE_IDENTIFIER = io.github.taetae98coding.diary;
PRODUCT_NAME = "$(TARGET_NAME)";
PROVISIONING_PROFILE_SPECIFIER = "";
Expand Down Expand Up @@ -490,7 +490,7 @@
"$(inherited)",
"@executable_path/Frameworks",
);
MARKETING_VERSION = 1.3.1;
MARKETING_VERSION = 1.3.2;
PRODUCT_BUNDLE_IDENTIFIER = io.github.taetae98coding.diary.dev.debug;
PRODUCT_NAME = "$(TARGET_NAME)";
PROVISIONING_PROFILE_SPECIFIER = "";
Expand Down Expand Up @@ -564,10 +564,10 @@
ASSETCATALOG_COMPILER_GLOBAL_ACCENT_COLOR_NAME = AccentColor;
CODE_SIGN_ENTITLEMENTS = Diary/Diary.entitlements;
CODE_SIGN_IDENTITY = "Apple Development";
CODE_SIGN_STYLE = Manual;
CODE_SIGN_STYLE = Automatic;
CURRENT_PROJECT_VERSION = 1;
DEVELOPMENT_ASSET_PATHS = "\"Diary/Preview Content\"";
DEVELOPMENT_TEAM = "";
DEVELOPMENT_TEAM = 4TV6L66XZ8;
ENABLE_PREVIEWS = YES;
ENABLE_USER_SCRIPT_SANDBOXING = NO;
GENERATE_INFOPLIST_FILE = YES;
Expand All @@ -584,7 +584,7 @@
"$(inherited)",
"@executable_path/Frameworks",
);
MARKETING_VERSION = 1.3.1;
MARKETING_VERSION = 1.3.2;
PRODUCT_BUNDLE_IDENTIFIER = io.github.taetae98coding.diary.dev;
PRODUCT_NAME = "$(TARGET_NAME)";
PROVISIONING_PROFILE_SPECIFIER = "";
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ import kotlinx.coroutines.launch
public fun CalendarTopBar(
state: CalendarState,
modifier: Modifier = Modifier,
navigationIcon: @Composable () -> Unit = {},
navigationIcon: @Composable () -> Unit = {},
actions: @Composable RowScope.() -> Unit = {},
) {
CenterAlignedTopAppBar(
Expand Down Expand Up @@ -61,7 +61,7 @@ public fun CalendarTopBar(
}
},
modifier = modifier,
navigationIcon = navigationIcon,
navigationIcon = navigationIcon,
actions = actions,
)
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,16 +7,16 @@ import io.github.taetae98coding.diary.core.design.system.theme.DiaryTheme
@DiaryPreview
@Composable
private fun CalendarHomeScreenPreview() {
DiaryTheme {
CalendarScaffold(
state = rememberCalendarScaffoldState(
onFilter = {},
),
onSelectDate = {},
hasFilterProvider = { false },
textItemListProvider = { emptyList() },
holidayListProvider = { emptyList() },
onCalendarItemClick = {},
)
}
DiaryTheme {
CalendarScaffold(
state = rememberCalendarScaffoldState(
onFilter = {},
),
onSelectDate = {},
hasFilterProvider = { false },
textItemListProvider = { emptyList() },
holidayListProvider = { emptyList() },
onCalendarItemClick = {},
)
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -32,93 +32,92 @@ import kotlinx.datetime.LocalDate

@Composable
public fun CalendarScaffold(
state: CalendarScaffoldState,
onSelectDate: (ClosedRange<LocalDate>) -> Unit,
hasFilterProvider: () -> Boolean,
textItemListProvider: () -> List<CalendarItemUiState.Text>,
holidayListProvider: () -> List<CalendarItemUiState.Holiday>,
onCalendarItemClick: (Any) -> Unit,
modifier: Modifier = Modifier,
navigationIcon: @Composable () -> Unit = {},
state: CalendarScaffoldState,
onSelectDate: (ClosedRange<LocalDate>) -> Unit,
hasFilterProvider: () -> Boolean,
textItemListProvider: () -> List<CalendarItemUiState.Text>,
holidayListProvider: () -> List<CalendarItemUiState.Holiday>,
onCalendarItemClick: (Any) -> Unit,
modifier: Modifier = Modifier,
navigationIcon: @Composable () -> Unit = {},
) {
val coroutineScope = rememberCoroutineScope()
val coroutineScope = rememberCoroutineScope()

Scaffold(
modifier = modifier
.onPreviewKeyEvent {
when {
!state.calendarState.isScrollInProgress && it.key == Key.DirectionRight -> {
coroutineScope.launch { state.calendarState.animateScrollToForward() }
true
}
Scaffold(
modifier = modifier
.onPreviewKeyEvent {
when {
!state.calendarState.isScrollInProgress && it.key == Key.DirectionRight -> {
coroutineScope.launch { state.calendarState.animateScrollToForward() }
true
}

!state.calendarState.isScrollInProgress && it.key == Key.DirectionLeft -> {
coroutineScope.launch { state.calendarState.animateScrollToBackward() }
true
}
!state.calendarState.isScrollInProgress && it.key == Key.DirectionLeft -> {
coroutineScope.launch { state.calendarState.animateScrollToBackward() }
true
}

it.key == Key.F1 -> {
state.onFilter()
true
}
it.key == Key.F1 -> {
state.onFilter()
true
}

!state.calendarState.isScrollInProgress && it.key == Key.F2 -> {
coroutineScope.launch { state.calendarState.animateScrollToToday() }
true
}
!state.calendarState.isScrollInProgress && it.key == Key.F2 -> {
coroutineScope.launch { state.calendarState.animateScrollToToday() }
true
}

else -> false
}
}
.focusRequester(state.focusRequester)
.focusable(),
topBar = {
CalendarTopBar(
state = state.calendarState,
actions = {
IconButton(onClick = state.onFilter) {
Crossfade(hasFilterProvider()) { hasFilter ->
if (hasFilter) {
FilterIcon(tint = DiaryTheme.color.primary)
} else {
FilterOffIcon()
}
}
}
else -> false
}
}.focusRequester(state.focusRequester)
.focusable(),
topBar = {
CalendarTopBar(
state = state.calendarState,
actions = {
IconButton(onClick = state.onFilter) {
Crossfade(hasFilterProvider()) { hasFilter ->
if (hasFilter) {
FilterIcon(tint = DiaryTheme.color.primary)
} else {
FilterOffIcon()
}
}
}

IconButton(onClick = { coroutineScope.launch { state.calendarState.animateScrollToToday() } }) {
TodayIcon()
}
},
navigationIcon = navigationIcon,
)
},
) {
var today by remember { mutableStateOf(LocalDate.todayIn()) }
IconButton(onClick = { coroutineScope.launch { state.calendarState.animateScrollToToday() } }) {
TodayIcon()
}
},
navigationIcon = navigationIcon,
)
},
) {
var today by remember { mutableStateOf(LocalDate.todayIn()) }

Calendar(
state = state.calendarState,
primaryDateListProvider = { listOf(today) },
textItemListProvider = textItemListProvider,
holidayListProvider = holidayListProvider,
onCalendarItemClick = onCalendarItemClick,
modifier = Modifier
.fillMaxSize()
.padding(it)
.calendarDateRangeSelectable(
state = state.calendarState,
onSelectDate = onSelectDate,
),
)
Calendar(
state = state.calendarState,
primaryDateListProvider = { listOf(today) },
textItemListProvider = textItemListProvider,
holidayListProvider = holidayListProvider,
onCalendarItemClick = onCalendarItemClick,
modifier = Modifier
.fillMaxSize()
.padding(it)
.calendarDateRangeSelectable(
state = state.calendarState,
onSelectDate = onSelectDate,
),
)

LifecycleResumeEffect(Unit) {
today = LocalDate.todayIn()
onPauseOrDispose { }
}
}
LifecycleResumeEffect(Unit) {
today = LocalDate.todayIn()
onPauseOrDispose { }
}
}

LifecycleResumeEffect(state.focusRequester) {
state.focusRequester.requestFocus()
onPauseOrDispose { }
}
LifecycleResumeEffect(state.focusRequester) {
state.focusRequester.requestFocus()
onPauseOrDispose { }
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@ import androidx.compose.ui.focus.FocusRequester
import io.github.taetae98coding.diary.core.calendar.compose.state.CalendarState

public class CalendarScaffoldState(
public val onFilter: () -> Unit,
public val calendarState: CalendarState,
public val onFilter: () -> Unit,
public val calendarState: CalendarState,
) {
public val focusRequester: FocusRequester = FocusRequester()
public val focusRequester: FocusRequester = FocusRequester()
}
Original file line number Diff line number Diff line change
Expand Up @@ -6,14 +6,14 @@ import io.github.taetae98coding.diary.core.calendar.compose.state.rememberCalend

@Composable
public fun rememberCalendarScaffoldState(
onFilter: () -> Unit,
onFilter: () -> Unit,
): CalendarScaffoldState {
val calendarState = rememberCalendarState()
val calendarState = rememberCalendarState()

return remember {
CalendarScaffoldState(
onFilter = onFilter,
calendarState = calendarState,
)
}
return remember {
CalendarScaffoldState(
onFilter = onFilter,
calendarState = calendarState,
)
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
package io.github.taetae98coding.diary.core.compose.error

import androidx.compose.foundation.layout.Box
import androidx.compose.foundation.layout.Column
import androidx.compose.material3.Text
import androidx.compose.material3.TextButton
import androidx.compose.runtime.Composable
import androidx.compose.runtime.remember
import androidx.compose.ui.Alignment
import androidx.compose.ui.Modifier
import io.github.taetae98coding.diary.core.design.system.emoji.Emoji
import io.github.taetae98coding.diary.core.design.system.theme.DiaryTheme

@Composable
public fun NetworkError(
onRetry: () -> Unit,
modifier: Modifier = Modifier,
) {
Box(
modifier = modifier,
contentAlignment = Alignment.Center,
) {
Column(horizontalAlignment = Alignment.CenterHorizontally) {
val emoji = remember { Emoji.check.random() }

Text(
text = "네트워크 상태를 확인해 주세요 $emoji",
style = DiaryTheme.typography.headlineMedium,
)
TextButton(onClick = onRetry) {
Text(text = "새로고침")
}
}
}
}
Loading

0 comments on commit 824b532

Please sign in to comment.