Skip to content

Releases: rebeccathedev/search-parser

v1.0.0

Choose a tag to compare

@rebeccathedev rebeccathedev released this 27 Aug 11:51

What's changed

Search Parser 1.0 turns the component list into a full, extensible search language while preserving the original parse() workflow.

Query language

  • Add boolean expressions with AND, OR, NOT, parentheses, and implicit AND.
  • Add comparison operators: =, !=, >, >=, <, and <=.
  • Add explicit and open-ended ranges using .., such as date:2026-01-01..2026-12-31, score:10.., and score:..20.
  • Add null, missing, and existence queries.
  • Add escaping for quotes, colons, commas, backslashes, and parentheses.
  • Add structured parse diagnostics and strict parsing through parseResult().

Validation and integrations

  • Add typed field schemas for allowlisting, coercion, enum validation, and database-field mapping.
  • Add a parameterized SQL transform with named bindings and field-identifier validation.
  • Add an Elasticsearch transform supporting boolean, term, range, wildcard, and existence queries.
  • Make Eloquent transforms honor boolean expression grouping.
  • Add query counting, array conversion, and JSON serialization.

Bug fixes

  • Keep comma-separated Eloquent alternatives inside a nested WHERE group so OR clauses cannot escape surrounding conditions.
  • Correct the Eloquent hashtag transform namespace and field reference.
  • Use logical complements for negated comparisons and require all negated list alternatives to match.

Compatibility note

  • The original parse() and transform APIs remain available.
  • Legacy numeric ranges such as age:18-30 remain supported.
  • Use the explicit .. separator for date and text ranges; hyphenated values are now treated as literal values instead of ambiguous ranges.

Verification

  • 52 tests and 86 assertions pass on PHP 8.5.9.
  • All PHP source and test files pass syntax checks.
  • Composer strict validation passes.

Full changelog: v0.4...v1.0.0

v0.4

Choose a tag to compare

@rebeccathedev rebeccathedev released this 26 Aug 06:23

What's changed

  • Add support for PHP 8.5.
  • Upgrade PHPUnit to 13.3 and all transitive development dependencies.
  • Add Laravel 13's database component to development dependencies so Eloquent integration tests run in CI.
  • Modernize test doubles for PHPUnit 13 compatibility.
  • Run the GitHub Actions test suite on PHP 8.5.

Verification

  • 30 tests and 30 assertions pass on PHP 8.5.9.
  • Composer validation passes.
  • Composer audit reports no known security advisories.

Version 0.3

Choose a tag to compare

@rebeccathedev rebeccathedev released this 13 Dec 15:33

What's Changed

Breaking Changes

  • Minimum PHP version increased to 8.2 to match PHPUnit 11 requirements

Improvements

  • Updated README with modern styling and emojis for better readability
  • Added GitHub Actions CI workflow for automated testing
  • Improved test coverage and PHPUnit compatibility

Bug Fixes

  • Fixed tests to use main branch

Documentation

  • Replaced whitelist/blacklist terminology with allowlist/blocklist for more inclusive language

Version 0.2

Choose a tag to compare

@rebeccathedev rebeccathedev released this 14 May 20:36
  • Bugfix: enclosed strings using negation (!"foo bar") were not being properly negated.
  • Feature: add support for + and - to indicate required/negated.