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

DateTimePicker component: Use color function for defining the background #10943

Merged
merged 1 commit into from
Oct 23, 2018

Conversation

mmtr
Copy link
Contributor

@mmtr mmtr commented Oct 23, 2018

Description

The last version of the @wordpress/components package provides an CSS file with invalid syntax because there is background property with a wrong value for the DateTimePicker component.

It seems that it was forgotten to include the color function on #7621, as this function will create a new color by adjusting it with the given shade.

This PR adds that function, so we can solve the import problems we have on Calypso using the latest packages.

How has this been tested?

I tested locally by generating a build and checking that the built CSS include a valid background value.

Testing instructions

  • Build the packages with npm run build:packages
  • Check that the generated file packages/components/build-style/style.css doesn't include any shade, specially the background properties between lines 1615 and 1629.
  • Check that the generated CSS can be imported using SCSS

Types of changes

Bug fix

Checklist:

  • My code is tested.
  • My code follows the WordPress code style.
  • My code follows the accessibility standards.
  • My code has proper inline documentation.

@mmtr
Copy link
Contributor Author

mmtr commented Oct 23, 2018

cc @vindl @gziolo

Copy link
Contributor

@Copons Copons left a comment

Choose a reason for hiding this comment

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

I'm not exactly sure how to test this in Gutenberg (@mmtr feel free to add a Testing Instructions section and maybe some before/after screenshots), but the lack of color function was definitely an error and this PR fixes it. ✨

@mmtr
Copy link
Contributor Author

mmtr commented Oct 23, 2018

@mmtr feel free to add a Testing Instructions section and maybe some before/after screenshots

Sorry about that, @Copons! I just added the instructions below:

Testing instructions

  • Build the packages with npm run build:packages
  • Check that the generated file packages/components/build-style/style.css doesn't include any shade, specially the background properties between lines 1615 and 1629.
  • Check that the generated CSS can be imported using SCSS

I don't think screenshots are needed here since we have not changed visually anything.

@gziolo gziolo added this to the 4.2 milestone Oct 23, 2018
@gziolo gziolo added [Type] Bug An existing feature does not function as intended [Package] Components /packages/components labels Oct 23, 2018
@gziolo gziolo merged commit b68327f into WordPress:master Oct 23, 2018
@mmtr mmtr deleted the fix/date-time-bg-color branch October 24, 2018 10:57
antpb pushed a commit to antpb/gutenberg that referenced this pull request Oct 26, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
[Package] Components /packages/components [Type] Bug An existing feature does not function as intended
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants