Skip to content

Conversation

@kean
Copy link
Contributor

@kean kean commented Oct 28, 2024

Fixes #23709

Screenshot 2024-10-28 at 1 55 02 PM Screenshot 2024-10-28 at 1 54 58 PM

RCA

In one of the previous releases, func primary was moved to UIColor without implementing a Jetpack-specific variant.

In the previous versions, these would map to:

// wp
static let primary = MurielColor(name: .blue)
// jp
static let primary = MurielColor(name: .jetpackGreen)

To test:

Regression Notes

  1. Potential unintended areas of impact

  2. What I did to test those areas of impact (or what existing automated tests I relied on)

  3. What automated tests I added (or what prevented me from doing so)

PR submission checklist:

  • I have completed the Regression Notes.
  • I have considered adding unit tests for my changes.
  • I have considered adding accessibility improvements for my changes.
  • I have considered if this change warrants user-facing release notes and have added them to RELEASE-NOTES.txt if necessary.

Testing checklist:

  • WordPress.com sites and self-hosted Jetpack sites.
  • Portrait and landscape orientations.
  • Light and dark modes.
  • Fonts: Larger, smaller and bold text.
  • High contrast.
  • VoiceOver.
  • Languages with large words or with letters/accents not frequently used in English.
  • Right-to-left languages. (Even if translation isn’t complete, formatting should still respect the right-to-left layout)
  • iPhone and iPad.
  • Multi-tasking: Split view and Slide over. (iPad)

@dangermattic
Copy link
Collaborator

dangermattic commented Oct 28, 2024

1 Warning
⚠️ This PR is assigned to the milestone 25.5. The due date for this milestone has already passed.
Please assign it to a milestone with a later deadline or check whether the release for this milestone has already been finished.

Generated by 🚫 Danger

static let brand = CSColor.WordPressBlue.base

static func brand(_ shade: ColorStudioShade) -> UIColor {
CSColor.WordPressBlue.shade(shade)
Copy link
Contributor Author

Choose a reason for hiding this comment

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

There is a bit of a mess with this naming, and it might be worth refining it later.

  • brand is a confusing name because A8C has multiple brands and wpios sometimes uses Jetpack brand colors
  • WordPressBlue is a confusing name because it's actually "WordPress.Com Blue"
  • primary is a confusing name because in SwiftUI Color.primary typically means primary text color (black/white)
  • tint is a confusing name because jpios sometimes uses .label and sometimes uses Jetpack green as a tint color

I don't have suggestions how to solve it because a lot of this complexity isn't incidental.

@kean kean requested a review from jkmassel October 28, 2024 18:14
@kean kean added the Stats label Oct 28, 2024
@kean kean added this to the 25.5 milestone Oct 28, 2024
@wpmobilebot
Copy link
Contributor

WordPress Alpha📲 You can test the changes from this Pull Request in WordPress Alpha by scanning the QR code below to install the corresponding build.
App NameWordPress Alpha WordPress Alpha
ConfigurationRelease-Alpha
Build Numberpr23712-30056b6
Version25.4.1
Bundle IDorg.wordpress.alpha
Commit30056b6
App Center BuildWPiOS - One-Offs #10878
Automatticians: You can use our internal self-serve MC tool to give yourself access to App Center if needed.

@wpmobilebot
Copy link
Contributor

Jetpack Alpha📲 You can test the changes from this Pull Request in Jetpack Alpha by scanning the QR code below to install the corresponding build.
App NameJetpack Alpha Jetpack Alpha
ConfigurationRelease-Alpha
Build Numberpr23712-30056b6
Version25.4.1
Bundle IDcom.jetpack.alpha
Commit30056b6
App Center Buildjetpack-installable-builds #9919
Automatticians: You can use our internal self-serve MC tool to give yourself access to App Center if needed.

CSColor.WordPressBlue.shade(shade)
}

static let primary = CSColor.Blue.base
Copy link
Contributor Author

Choose a reason for hiding this comment

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

I haven't tested every single place where these are used, but there are a bit obscure parts, and the logic seems sound as it's simply revert to the previous behavior.

@kean kean enabled auto-merge October 28, 2024 21:01
@kean kean disabled auto-merge October 29, 2024 23:13
@kean kean merged commit 4f10b8f into trunk Oct 29, 2024
23 of 26 checks passed
@kean kean deleted the fix/primary-color branch October 29, 2024 23:13
@kean kean mentioned this pull request Oct 30, 2024
14 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Stats: Bar graph colors mismatched across light and dark modes

5 participants