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

[iOS] - Cleanup UI and Strings #27858

Merged
merged 1 commit into from
Feb 28, 2025
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
Expand Up @@ -25,7 +25,7 @@ struct LeoAssetsPlugin: BuildToolPlugin {
}

// Check to make sure the plugin is being used correctly in SPM
guard let target = target as? SourceModuleTarget else {
guard target is SourceModuleTarget else {
Diagnostics.error("Attempted to use `LeoAssetsPlugin` on an unsupported module target")
return []
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ public struct AIChatTermsAndConditionsView: View {
.multilineTextAlignment(.leading)
.frame(maxWidth: .infinity, alignment: .leading)
.fixedSize(horizontal: false, vertical: true)
.font(.body.weight(.semibold))
.font(.headline)
.foregroundStyle(Color(braveSystemName: .textPrimary))

Text(
Expand Down Expand Up @@ -53,10 +53,7 @@ public struct AIChatTermsAndConditionsView: View {
.padding([.leading, .trailing], 16)
.frame(maxWidth: .infinity)
.foregroundStyle(Color(braveSystemName: .schemesOnPrimary))
.background(
Color(braveSystemName: .buttonBackground),
in: Capsule()
)
.background(Color(braveSystemName: .buttonBackground), in: .capsule)
}
)
.buttonStyle(.plain)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -27,13 +27,10 @@ struct AIChatBusyErrorView: View {
},
label: {
Text(Strings.AIChat.retryActionTitle)
.font(.body.weight(.semibold))
.font(.headline)
.padding()
.foregroundStyle(Color(braveSystemName: .schemesOnPrimary))
.background(
Color(braveSystemName: .buttonBackground),
in: Capsule()
)
.background(Color(braveSystemName: .buttonBackground), in: .capsule)
}
)
.buttonStyle(.plain)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -27,13 +27,10 @@ struct AIChatContextLimitErrorView: View {
},
label: {
Text(Strings.AIChat.newChatActionTitle)
.font(.body.weight(.semibold))
.font(.headline)
.padding()
.foregroundStyle(Color(braveSystemName: .schemesOnPrimary))
.background(
Color(braveSystemName: .buttonBackground),
in: Capsule()
)
.background(Color(braveSystemName: .buttonBackground), in: .capsule)
}
)
.buttonStyle(.plain)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -27,14 +27,11 @@ struct AIChatNetworkErrorView: View {
},
label: {
Text(Strings.AIChat.retryActionTitle)
.font(.body.weight(.semibold))
.font(.headline)
.foregroundColor(Color(braveSystemName: .schemesOnPrimary))
.padding()
.foregroundStyle(.white)
.background(
Color(braveSystemName: .buttonBackground),
in: Capsule()
)
.background(Color(braveSystemName: .buttonBackground), in: .capsule)
}
)
.buttonStyle(.plain)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -27,13 +27,10 @@ struct AIChatSessionExpiredErrorView: View {
},
label: {
Text(Strings.AIChat.refreshCredentialsActionTitle)
.font(.body.weight(.semibold))
.font(.headline)
.padding()
.foregroundStyle(Color(braveSystemName: .schemesOnPrimary))
.background(
Color(braveSystemName: .buttonBackground),
in: Capsule()
)
.background(Color(braveSystemName: .buttonBackground), in: .capsule)
}
)
.buttonStyle(.plain)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -128,7 +128,6 @@ struct AIChatFeedbackToastView: View {
} label: {
Label {
Text(Strings.close)

} icon: {
Image(systemName: "xmark")
.foregroundStyle(Color(braveSystemName: .primary30))
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -365,7 +365,7 @@ struct AIChatFeedbackView: View {
var body: some View {
VStack {
Text(Strings.AIChat.feedbackViewMainTitle)
.font(.body.weight(.semibold))
.font(.headline)
.frame(maxWidth: .infinity, alignment: .leading)
.padding()

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,14 +21,14 @@ struct AIChatMessageHeaderView: View {
.background(Color(braveSystemName: .containerHighlight), in: Circle())

Text(Strings.AIChat.youMessageTitle)
.font(.body.weight(.semibold))
.font(.headline)
.foregroundStyle(Color(braveSystemName: .textTertiary))
} else {
AIChatProductIcon(containerShape: Circle(), padding: 6.0)
.font(.callout)

Text(Strings.AIChat.leoAssistantNameTitle)
.font(.body.weight(.semibold))
.font(.headline)
.foregroundStyle(Color(braveSystemName: .textTertiary))
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -128,7 +128,7 @@ struct AIChatPaywallView: View {
}
.background(
Color(braveSystemName: .primitivePrimary10)
.edgesIgnoringSafeArea(.all)
.ignoresSafeArea()
.overlay(
Image("leo-product", bundle: .module),
alignment: .topTrailing
Expand Down Expand Up @@ -221,7 +221,7 @@ struct AIChatPaywallView: View {
? Strings.AIChat.paywallPurchaseActionIntroOfferTitle
: Strings.AIChat.paywallPurchaseActionTitle
)
.font(.body.weight(.semibold))
.font(.headline)
.foregroundColor(Color(.white))
.padding()
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -133,7 +133,7 @@ struct PremiumUpsellTitleView: View {
.font(.body.weight(.medium))
.lineLimit(2)
.truncationMode(.tail)
.frame(maxWidth: .infinity, alignment: .center)
.frame(maxWidth: .infinity)
.fixedSize(horizontal: false, vertical: true)
.foregroundStyle(foregroundTextColor)
case .rateLimit:
Expand Down

This file was deleted.

This file was deleted.

Empty file.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

Loading
Loading