Skip to content
Closed
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 @@ -21,7 +21,7 @@ protocol FAQViewInteraction: AnyObject {

protocol FAQViewState: AnyObject, ObservableObject {
var faqItems: [FAQViewItem] { get set }
var footerText: LocalizedStringKey { get }
var footerText: AttributedString { get }
}

// MARK: - Model
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,10 +11,19 @@ final class FAQViewModel: FAQViewModelLifeCycle, FAQViewInteraction, FAQViewStat
private let mapper: QuestionViewMappable

@Published var faqItems: [FAQViewItem] = []
let footerText: LocalizedStringKey = {
let footerText: AttributedString = {
let email = "hi@animalproject.ge"
let link = "[\(email)](mailto:\(email))"
return LocalizedStringKey(L10n.Faq.Footer.text(link))
var text = AttributedString(
L10n.Faq.Footer.text(email)
)

if let range = text.range(of: email) {
text[range].link = URL(string: "mailto:\(email)")
text[range].foregroundColor = .blue
Copy link

Copilot AI Feb 10, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The hardcoded .blue color for the email link breaks the design system convention. The codebase consistently uses designEngine.colors for all color styling. If a link-specific color is needed, it should be added to the design engine's color palette rather than hardcoded here.

Copilot uses AI. Check for mistakes.
text[range].underlineStyle = .single
}

return text
}()

// MARK: - Initialization
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -62,10 +62,9 @@ struct FAQView<ViewModel: FAQViewModelProtocol>: View {
Text(viewModel.footerText)
.textSelection(.enabled)
.font(designEngine.fonts.primary.regular(16)?.font)
.foregroundColor(designEngine.colors.textPrimary.color)
.accentColor(designEngine.colors.textPrimary.color)
.multilineTextAlignment(.center)
Comment on lines 62 to 65
Copy link

Copilot AI Feb 10, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The removal of .foregroundColor(designEngine.colors.textPrimary.color) means the non-link text in the footer will no longer have a defined color and will use the system default. This is inconsistent with other text elements in the view (like headerText at line 47 and text in QuestionRow at lines 101 and 114) which explicitly set foregroundColor using the design engine. The footer text should maintain consistent styling with the rest of the view.

Copilot uses AI. Check for mistakes.
.frame(maxWidth: .infinity)
.tint(.blue)
Copy link

Copilot AI Feb 10, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The hardcoded .blue color breaks the design system convention used throughout the codebase. All other views use designEngine.colors for color styling (e.g., designEngine.colors.textPrimary.color, designEngine.colors.textSecondary.color). This should use an appropriate color from the design engine instead. Consider adding a link or accent color to the design engine if one doesn't exist, or use an existing color that matches the design requirements.

Copilot uses AI. Check for mistakes.
Copy link
Copy Markdown
Collaborator

@kishorepran kishorepran Feb 25, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

please check suggest to stick to design engine based project colors if not any special circumstances

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No need all these changes. .tint is enough.
And it is better to use designEngine instead of hardcoded values.

.tint(designEngine.colors.elementSpecial.color)

}
}

Expand Down
Loading