Skip to content

Improvement/simple range slider#72

Merged
JorchCortez merged 17 commits intoTheCodeRaccoons:mainfrom
matthewcsimpson:improvement/simple-range-slider
Mar 20, 2026
Merged

Improvement/simple range slider#72
JorchCortez merged 17 commits intoTheCodeRaccoons:mainfrom
matthewcsimpson:improvement/simple-range-slider

Conversation

@matthewcsimpson
Copy link
Copy Markdown
Contributor

@matthewcsimpson matthewcsimpson commented Mar 19, 2026

New Feature: RangeSliderSimple

Description

Adds RangeSliderSimple, which uses browser native handles instead of custom elements.
Also updated the failing tests on CMSFilter and CMSSelect

DEMO

https://codepen.io/matthewcsimpson/pen/myrwZgb

Related Issues

closes #71

Checklist

  • Feature has been tested locally with all relevant use cases.
  • Documentation has been updated (if necessary).
  • PR does not match another non-stale PR currently opened
  • PR name matches the format [ feature ]: Feature Name (versions separated by comma). More details here
  • PR's base is the develop branch.
  • Your Feature matches the standards laid out here

Additional Notes

This pull request introduces new documentation and automated tests for several utility scripts, as well as updates to the README.md to clarify usage of range slider scripts. The most important changes are the addition of Jest tests for RangeSlider and RangeSliderSimple, and comprehensive documentation for CookieConsent, CopyToClipboard, CountUp, and DateCountDown. These improvements enhance both the reliability and usability of the project.

Testing improvements:

  • Added Jest tests for RangeSlider and RangeSliderSimple, covering initialization, attribute wiring, and global registration via window.webtricks. (__tests__/RangeSlider.test.js, __tests__/RangeSliderSimple.test.js) [1] [2]

Documentation enhancements:

README improvements:

  • Expanded instructions for range slider scripts, clarifying the distinction between RangeSlider.js and RangeSliderSimple.js, and providing usage examples for both.

These changes collectively improve the project's test coverage, documentation clarity, and user onboarding experience.

@matthewcsimpson matthewcsimpson marked this pull request as ready for review March 19, 2026 19:21
Copilot AI review requested due to automatic review settings March 19, 2026 19:21
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

This PR introduces a new RangeSliderSimple module (native dual-range inputs) to address slider drag/handle usability, and updates documentation + tests around range sliders and related utilities. It also adjusts a couple of Webflow-only scripts to behave consistently in jsdom-based tests and improves CI coverage reporting.

Changes:

  • Added Dist/Functional/RangeSliderSimple.js (native-thumb dual-handle slider) plus docs and Jest tests.
  • Refactored Dist/Functional/RangeSlider.js to be self-contained and added Jest tests.
  • Documentation formatting updates across multiple script docs; minor adjustments to CI coverage artifact/summary and .gitignore.

Reviewed changes

Copilot reviewed 21 out of 27 changed files in this pull request and generated 11 comments.

Show a summary per file
File Description
README.md Adds guidance + jsDelivr examples for RangeSlider vs RangeSliderSimple
package-lock.json Updates lockfile package version to 1.0.0
docs/WebflowOnly/TabsSlider.md Formatting/whitespace tweaks
docs/WebflowOnly/RenderStatic.md Formatting/whitespace tweaks
docs/WebflowOnly/MirrorClick.md Formatting/whitespace tweaks
docs/WebflowOnly/HideContainer.md Formatting/whitespace tweaks
docs/WebflowOnly/CMSSelect.md Formatting/whitespace tweaks
docs/WebflowOnly/CMSFilter.md Formatting/whitespace tweaks
docs/Functional/ShareLink.md Formatting/whitespace tweaks
docs/Functional/ReadTime.md Formatting/whitespace tweaks
docs/Functional/RangeSliderSimple.md New documentation for RangeSliderSimple
docs/Functional/RangeSlider.md Updates RangeSlider docs and links to RangeSliderSimple
docs/Functional/Marquee.md Formatting/whitespace tweaks
docs/Functional/FormCheck.md Formatting/whitespace tweaks
docs/Functional/FormatNumbers.md Formatting/whitespace tweaks
docs/Functional/DateCountDown.md Formatting/whitespace tweaks
docs/Functional/CountUp.md Formatting/whitespace tweaks
docs/Functional/CopyToClipboard.md Formatting/whitespace tweaks
docs/Functional/CookieConsent.md Formatting/whitespace tweaks
Dist/WebflowOnly/CMSSelect.js Uses textContent/trim for option text to stabilize behavior in jsdom
Dist/WebflowOnly/CMSFilter.js Uses textContent for result count to stabilize behavior in jsdom
Dist/Functional/RangeSliderSimple.js Adds new native-thumb dual-handle slider implementation
Dist/Functional/RangeSlider.js Makes RangeSlider self-contained + adds CommonJS export for tests/bundlers
.gitignore Ignores coverage/ output
.github/workflows/tests.yml Uploads coverage artifacts + job summary only when coverage exists
tests/RangeSliderSimple.test.js Adds basic Jest coverage for RangeSliderSimple initialization/global registration
tests/RangeSlider.test.js Adds basic Jest coverage for RangeSlider initialization/global registration

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread Dist/Functional/RangeSliderSimple.js Outdated
Comment thread Dist/Functional/RangeSliderSimple.js Outdated
Comment thread Dist/Functional/RangeSliderSimple.js Outdated
Comment thread Dist/Functional/RangeSliderSimple.js Outdated
Comment thread docs/Functional/RangeSliderSimple.md Outdated
Comment thread README.md Outdated
Comment thread docs/Functional/RangeSlider.md Outdated
Comment thread Dist/Functional/RangeSlider.js Outdated
Comment thread Dist/Functional/RangeSlider.js
Comment thread Dist/Functional/RangeSlider.js Outdated
@JorchCortez
Copy link
Copy Markdown
Contributor

@matthewcsimpson Looks good but let's just test that the update adding Number instead of parseInt is working properly. it will be the user's problem if they want int or float but we should be able to handle both.

@matthewcsimpson
Copy link
Copy Markdown
Contributor Author

@matthewcsimpson Looks good but let's just test that the update adding Number instead of parseInt is working properly. it will be the user's problem if they want int or float but we should be able to handle both.

All the feedback pieces resolved and the tests all pass.

@JorchCortez JorchCortez merged commit bf0dca5 into TheCodeRaccoons:main Mar 20, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[BUG]: Range Slider Movement & Drag Area

3 participants