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

Adjust RangeControl to add the stepper control and allow type selection #2125

Merged
merged 6 commits into from
Apr 15, 2020

Conversation

chipsnyder
Copy link
Contributor

@chipsnyder chipsnyder commented Apr 7, 2020

Fixes: #1992
gutenberg WordPress/gutenberg#21465

Description

This PR refactors the RangeControl component to allow the optional parameter type to allow selection between the Stepper control or a slider control on Mobile.

Since the range control is being used in multiple places right now as a slider control, I made the slider the default option.

This PR also updates the gallery component to pass in type=stepper to test the other use flow. The gallery component was also the only place where I could find references to the stepper control.

How has this been tested?

Stepper:

  1. Open a gallery block with multiple images
  2. Expect to see the stepper control under the columns option

Slider:

  1. Open a control using the RangeControl. Examples:

    • Button: Border Radius
    • Cover Block: Minimum height in pixels, Background opacity
    • Latest-Posts: Number of items, Excerpt length
  2. Expect to see the slider control

PR submission checklist:

  • I have considered adding unit tests where possible.
  • I have considered if this change warrants user-facing release notes and have added them to RELEASE-NOTES.txt if necessary.

@peril-wordpress-mobile
Copy link

peril-wordpress-mobile bot commented Apr 8, 2020

You can trigger optional full suite of UI tests for these changes by visiting CircleCI here.

@pinarol
Copy link
Contributor

pinarol commented Apr 13, 2020

I am changing the milestone of this PR as 1.27 because the 1.26 release branch will be cut quite soon. Let me know if you instead wanted to include this to 1.26.

@pinarol pinarol modified the milestones: 1.26, 1.27 Apr 13, 2020
Copy link
Contributor

@geriux geriux left a comment

Choose a reason for hiding this comment

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

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
[Type] Enhancement Improves a current area of the editor [Type] Technical Debt
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Refactor RangeControl to render Stepper or Slider inside
3 participants