Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: 🎸 share default text #95

Merged
merged 1 commit into from
Jan 2, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -1,6 +1,16 @@
{
"sourceLanguage" : "en",
"strings" : {
"I found an app to increase BeReal's friends, try it.\n%@" : {
"localizations" : {
"ja" : {
"stringUnit" : {
"state" : "translated",
"value" : "BeRealの友だち増やせるアプリ見つけたからやってみてw w w\n%@"
}
}
}
},
"Just a little... Too much swiping... Please help me share BeMatch... 🙏." : {
"localizations" : {
"ja" : {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,13 @@ public struct RecommendationEmptyLogic {
}

public struct State: Equatable {
var sharedURL = Constants.appStoreForEmptyURL
var shareURL = Constants.appStoreForEmptyURL
var shareText: String {
return String(
localized: "I found an app to increase BeReal's friends, try it.\n\(shareURL.absoluteString)",
bundle: .module
)
}
@BindingState var isPresented = false
public init() {}
}
Expand Down Expand Up @@ -63,7 +69,7 @@ public struct RecommendationEmptyLogic {
return .none

case let .currentUserResponse(.success(data)):
state.sharedURL = data.currentUser.gender == .female
state.shareURL = data.currentUser.gender == .female
? Constants.appStoreFemaleForEmptyURL
: Constants.appStoreForEmptyURL
return .none
Expand Down Expand Up @@ -124,7 +130,7 @@ public struct RecommendationEmptyView: View {
.onAppear { store.send(.onAppear) }
.sheet(isPresented: viewStore.$isPresented) {
ActivityView(
activityItems: [viewStore.sharedURL],
activityItems: [viewStore.shareText],
applicationActivities: nil
) { activityType, result, _, _ in
store.send(
Expand Down