|
|
@@ -172,7 +172,7 @@ final class DashboardView: NSView {
|
|
|
contentStack.topAnchor.constraint(equalTo: chromeContainer.topAnchor),
|
|
|
contentStack.bottomAnchor.constraint(equalTo: chromeContainer.bottomAnchor),
|
|
|
|
|
|
- sidebar.widthAnchor.constraint(equalToConstant: 225),
|
|
|
+ sidebar.widthAnchor.constraint(equalToConstant: 218),
|
|
|
mainHost.widthAnchor.constraint(greaterThanOrEqualToConstant: 720),
|
|
|
|
|
|
mainOverlay.leadingAnchor.constraint(equalTo: mainHost.leadingAnchor),
|
|
|
@@ -347,7 +347,7 @@ final class DashboardView: NSView {
|
|
|
inner.translatesAutoresizingMaskIntoConstraints = false
|
|
|
inner.orientation = .vertical
|
|
|
inner.spacing = 10
|
|
|
- inner.alignment = .leading
|
|
|
+ inner.alignment = .centerX
|
|
|
|
|
|
let proIcon = NSImageView()
|
|
|
proIcon.translatesAutoresizingMaskIntoConstraints = false
|
|
|
@@ -358,7 +358,7 @@ final class DashboardView: NSView {
|
|
|
let proEyebrow = NSTextField(labelWithString: "Premium")
|
|
|
proEyebrow.font = .systemFont(ofSize: 11, weight: .heavy)
|
|
|
proEyebrow.textColor = Theme.proAccent
|
|
|
- proEyebrow.alignment = .left
|
|
|
+ proEyebrow.alignment = .center
|
|
|
|
|
|
let eyebrowRow = NSStackView(views: [proIcon, proEyebrow])
|
|
|
eyebrowRow.orientation = .horizontal
|
|
|
@@ -368,18 +368,23 @@ final class DashboardView: NSView {
|
|
|
let headline = NSTextField(labelWithString: "Upgrade to Pro")
|
|
|
headline.font = .systemFont(ofSize: 16, weight: .bold)
|
|
|
headline.textColor = Theme.primaryText
|
|
|
- headline.alignment = .left
|
|
|
+ headline.alignment = .center
|
|
|
|
|
|
let upgradeDescription = NSTextField(wrappingLabelWithString: "Unlimited AI matches, smart alerts, and interview prep—all in one place.")
|
|
|
upgradeDescription.font = .systemFont(ofSize: 12, weight: .regular)
|
|
|
upgradeDescription.textColor = Theme.secondaryText
|
|
|
- upgradeDescription.preferredMaxLayoutWidth = 165
|
|
|
+ upgradeDescription.alignment = .center
|
|
|
+ // Sidebar content width is 190pt (218 − edge insets); card must stay within that band.
|
|
|
+ let cardWidth: CGFloat = 186
|
|
|
+ let innerContentWidth = cardWidth - 28
|
|
|
+ upgradeDescription.preferredMaxLayoutWidth = innerContentWidth
|
|
|
|
|
|
let upgradeButton = NSButton(title: "Upgrade to Pro", target: self, action: #selector(didTapUpgradeToPro))
|
|
|
upgradeButton.isBordered = false
|
|
|
upgradeButton.bezelStyle = .rounded
|
|
|
upgradeButton.font = .systemFont(ofSize: 13, weight: .bold)
|
|
|
upgradeButton.contentTintColor = Theme.proCTAText
|
|
|
+ upgradeButton.alignment = .center
|
|
|
upgradeButton.wantsLayer = true
|
|
|
upgradeButton.layer?.backgroundColor = Theme.proCTABackground.cgColor
|
|
|
upgradeButton.layer?.cornerRadius = 20
|
|
|
@@ -394,7 +399,6 @@ final class DashboardView: NSView {
|
|
|
upgradeCard.addSubview(accentBar)
|
|
|
upgradeCard.addSubview(inner)
|
|
|
|
|
|
- let cardWidth: CGFloat = 197
|
|
|
NSLayoutConstraint.activate([
|
|
|
upgradeCard.widthAnchor.constraint(equalToConstant: cardWidth),
|
|
|
|