Просмотр исходного кода

Match feature card arrow borders with their card styling.

Use the same border color, width, and hover behavior on chevron circles as the surrounding feature cards.

Co-authored-by: Cursor <cursoragent@cursor.com>
AhtashamShahzad1 7 часов назад
Родитель
Сommit
560831100c
1 измененных файлов с 5 добавлено и 2 удалено
  1. 5 2
      smart_printer/UIComponents.swift

+ 5 - 2
smart_printer/UIComponents.swift

@@ -465,7 +465,7 @@ final class FeatureCardView: NSView, AppearanceRefreshable {
465 465
         arrowButton.isBordered = false
466 466
         arrowButton.wantsLayer = true
467 467
         arrowButton.layer?.cornerRadius = 13
468
-        arrowButton.layer?.borderWidth = 1
468
+        arrowButton.layer?.borderWidth = 1.5
469 469
         arrowButton.translatesAutoresizingMaskIntoConstraints = false
470 470
         if let arrow = NSImage(systemSymbolName: "chevron.right", accessibilityDescription: "Open") {
471 471
             let config = NSImage.SymbolConfiguration(pointSize: 10, weight: .semibold)
@@ -515,7 +515,9 @@ final class FeatureCardView: NSView, AppearanceRefreshable {
515 515
     private func setHovered(_ hovering: Bool) {
516 516
         isHovered = hovering
517 517
         applyHoverLift(hovering)
518
-        layer?.borderWidth = hovering ? 2 : 1.5
518
+        let borderWidth: CGFloat = hovering ? 2 : 1.5
519
+        layer?.borderWidth = borderWidth
520
+        arrowButton.layer?.borderWidth = borderWidth
519 521
     }
520 522
 
521 523
     func refreshAppearance() {
@@ -525,6 +527,7 @@ final class FeatureCardView: NSView, AppearanceRefreshable {
525 527
         titleLabel.refreshThemeLabelColor()
526 528
         subtitleLabel.refreshThemeLabelColor()
527 529
         arrowButton.layer?.backgroundColor = AppTheme.elevatedBackground.cgColor
530
+        arrowButton.layer?.borderWidth = isHovered ? 2 : 1.5
528 531
         arrowButton.layer?.borderColor = AppTheme.paywallBorder.cgColor
529 532
         arrowButton.contentTintColor = AppTheme.textSecondary
530 533
         if isHovered {