PHPackages                             hugoseigle/symfony-ux-autocomplete-select-all - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. hugoseigle/symfony-ux-autocomplete-select-all

ActiveSymfony-bundle

hugoseigle/symfony-ux-autocomplete-select-all
=============================================

Select or deselect every option in a Symfony UX Autocomplete field.

v1.0.1(yesterday)40[6 PRs](https://github.com/HugoSEIGLE/symfony-ux-autocomplete-select-all/pulls)MITJavaScriptPHP &gt;=8.2CI passing

Since Jul 23Pushed today1 watchersCompare

[ Source](https://github.com/HugoSEIGLE/symfony-ux-autocomplete-select-all)[ Packagist](https://packagist.org/packages/hugoseigle/symfony-ux-autocomplete-select-all)[ Docs](https://github.com/HugoSEIGLE/symfony-ux-autocomplete-select-all)[ RSS](/packages/hugoseigle-symfony-ux-autocomplete-select-all/feed)WikiDiscussions main Synced today

READMEChangelog (2)Dependencies (9)Versions (3)Used By (0)

Symfony UX Autocomplete Select All
==================================

[](#symfony-ux-autocomplete-select-all)

[![Latest stable version](https://camo.githubusercontent.com/fc10157b98dc1ab79efc33f2fa8281ce78cbfafbd4ccf6b3034701c6a33c8337/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f6875676f736569676c652f73796d666f6e792d75782d6175746f636f6d706c6574652d73656c6563742d616c6c3f6c6162656c3d737461626c65)](https://packagist.org/packages/hugoseigle/symfony-ux-autocomplete-select-all)[![Total downloads](https://camo.githubusercontent.com/732627c8a542da3fb215517c369f81e4aba3ef2b71d5f63c42eee036245a544d/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f64742f6875676f736569676c652f73796d666f6e792d75782d6175746f636f6d706c6574652d73656c6563742d616c6c3f6c6162656c3d646f776e6c6f616473)](https://packagist.org/packages/hugoseigle/symfony-ux-autocomplete-select-all/stats)[![Monthly downloads](https://camo.githubusercontent.com/3e43ebf4a88b8b085ed650bf140cf3137faa237b9f88ff8141fad3d743636596/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f646d2f6875676f736569676c652f73796d666f6e792d75782d6175746f636f6d706c6574652d73656c6563742d616c6c3f6c6162656c3d6d6f6e74686c79)](https://packagist.org/packages/hugoseigle/symfony-ux-autocomplete-select-all/stats)[![GitHub stars](https://camo.githubusercontent.com/0c1ffa3524ca98ea6dbb12ad605b7bfec006618f1441657d0dd36b5957657125/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f73746172732f4875676f534549474c452f73796d666f6e792d75782d6175746f636f6d706c6574652d73656c6563742d616c6c3f7374796c653d666c6174)](https://github.com/HugoSEIGLE/symfony-ux-autocomplete-select-all/stargazers)[![Latest release](https://camo.githubusercontent.com/497012bca31a46538a7c86dc78fa3cf2996a5888a3992a4de5b9dbd49d453f1c/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f762f72656c656173652f4875676f534549474c452f73796d666f6e792d75782d6175746f636f6d706c6574652d73656c6563742d616c6c3f6c6162656c3d72656c65617365)](https://github.com/HugoSEIGLE/symfony-ux-autocomplete-select-all/releases)

[![CI](https://github.com/HugoSEIGLE/symfony-ux-autocomplete-select-all/actions/workflows/ci.yaml/badge.svg)](https://github.com/HugoSEIGLE/symfony-ux-autocomplete-select-all/actions/workflows/ci.yaml)[![CodeQL](https://github.com/HugoSEIGLE/symfony-ux-autocomplete-select-all/actions/workflows/codeql.yaml/badge.svg)](https://github.com/HugoSEIGLE/symfony-ux-autocomplete-select-all/actions/workflows/codeql.yaml)[![PHP](https://camo.githubusercontent.com/e1fba19fe10a4f7ab56ed1925770d014229f9789610db81fa576e4418ad18ede/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f646570656e64656e63792d762f6875676f736569676c652f73796d666f6e792d75782d6175746f636f6d706c6574652d73656c6563742d616c6c2f7068703f6c6162656c3d504850)](composer.json)[![License](https://camo.githubusercontent.com/f84026e11ecf42d1c2aee8318e442260bbda02eba42ecda234cf5993f920a786/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f6c2f6875676f736569676c652f73796d666f6e792d75782d6175746f636f6d706c6574652d73656c6563742d616c6c)](LICENSE)

A small Symfony UX bundle that adds accessible **Select all** and **Deselect all** controls to a multiple [Symfony UX Autocomplete](https://symfony.com/bundles/ux-autocomplete/current/index.html)field.

It follows the endpoint's pagination, reuses the Tom Select instance managed by Symfony UX and works with both AssetMapper and Webpack Encore.

[![Autocomplete Select All demo](docs/images/demo.svg)](docs/images/demo.svg)

Features
--------

[](#features)

- Selects results across every remote autocomplete page.
- Supports Symfony UX's `next_page` response and the historical 10-item page format.
- Keeps controls synchronized when the selection changes.
- Uses Stimulus values and targets for labels, classes and advanced settings.
- Aborts in-flight requests and removes every listener and generated element on `disconnect()`.
- Does not instantiate or replace Tom Select.
- Supports grouped Symfony UX Autocomplete responses.

Requirements
------------

[](#requirements)

DependencySupported versionsPHP8.2, 8.3, 8.4Symfony6.4, 7.x, 8.xSymfony UX Autocomplete2.17 or later in the 2.x seriesStimulus3.2 or laterAssetsAssetMapper or Webpack EncoreInstallation
------------

[](#installation)

```
composer require hugoseigle/symfony-ux-autocomplete-select-all
```

If Symfony Flex does not register third-party bundles in your application, enable it manually:

```
// config/bundles.php
use HugoSeigle\SymfonyUx\AutocompleteSelectAll\SymfonyUxAutocompleteSelectAllBundle;

return [
    // ...
    SymfonyUxAutocompleteSelectAllBundle::class => ['all' => true],
];
```

The package exposes its controller through the standard Symfony UX asset manifest. AssetMapper consumes it directly; Encore installs and resolves the corresponding npm package through the usual Symfony UX workflow.

See the complete [installation guide](docs/installation.md), including manual AssetMapper and Encore setup.

Usage
-----

[](#usage)

Place this controller on a wrapper and mark the multiple autocomplete field as its `field` target:

```
{% set select_all_controller =
    'hugoseigle/symfony-ux-autocomplete-select-all/select-all' %}

```

The autocomplete endpoint keeps its normal Symfony UX response:

```
{
    "results": [
        { "value": "1", "text": "France" },
        { "value": "2", "text": "Germany" }
    ],
    "next_page": "/autocomplete/countries?page=2"
}
```

No separate URL is needed: by default, the controller reads the URL value already configured on Symfony UX Autocomplete.

Configuration
-------------

[](#configuration)

Stimulus valueTypeDefaultPurpose`url`stringAutocomplete URLOverrides the endpoint used by Select all`selectAllLabel`string`Select All`Select button label`deselectAllLabel`string`Deselect All`Clear button label`selectAllClasses`string`btn btn-outline-primary btn-sm select-all-button`Select button classes`deselectAllClasses`string`btn btn-outline-danger btn-sm unselect-all-button`Clear button classes`controlsClasses`string`autocomplete-select-all-controls`Generated controls wrapper classes`pageSize`number`10`Legacy pagination fallback size`maxPages`number`1000`Pagination loop safety limitButtons use the native `hidden` attribute, so Bootstrap is optional. Replace the class values when using another design system.

See [configuration](docs/configuration.md) and [examples](docs/examples.md) for custom controls, Symfony Forms and both asset systems.

Demo
----

[](#demo)

The [`demo/`](demo/) directory is a complete Symfony 6.4 AssetMapper application. It installs this bundle from its parent directory with a Composer `path` repository.

```
cd demo
composer install
symfony serve
```

Then open the URL printed by Symfony CLI.

Contributing
------------

[](#contributing)

Bug reports and pull requests are welcome. Read [CONTRIBUTING.md](CONTRIBUTING.md)for the local workflow, quality checks and contribution rules.

Please report vulnerabilities privately as described in [SECURITY.md](SECURITY.md).

Roadmap
-------

[](#roadmap)

- Publish the 1.x Composer and npm packages.
- Add optional progress feedback for very large datasets.
- Evaluate an opt-in confirmation threshold before selecting thousands of records.
- Track future Symfony UX Autocomplete pagination changes without relying on private APIs.

Backward compatibility follows semantic versioning. See [CHANGELOG.md](CHANGELOG.md) for release notes.

License
-------

[](#license)

Symfony UX Autocomplete Select All is released under the [MIT License](LICENSE).

###  Health Score

41

—

FairBetter than 87% of packages

Maintenance100

Actively maintained with recent releases

Popularity4

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity47

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~0 days

Total

2

Last Release

1d ago

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/102899493?v=4)[Hugo Seigle](/maintainers/HugoSEIGLE)[@HugoSEIGLE](https://github.com/HugoSEIGLE)

---

Top Contributors

[![HugoSEIGLE](https://avatars.githubusercontent.com/u/102899493?v=4)](https://github.com/HugoSEIGLE "HugoSEIGLE (14 commits)")

---

Tags

autocompletejavascriptselect-allstimulussymfonytomselectuxsymfonyautocompletesymfony-uxstimulustom-select

###  Code Quality

TestsPHPUnit

Static AnalysisPHPStan

Code StylePHP CS Fixer

Type Coverage Yes

### Embed Badge

![Health badge](/badges/hugoseigle-symfony-ux-autocomplete-select-all/health.svg)

```
[![Health](https://phpackages.com/badges/hugoseigle-symfony-ux-autocomplete-select-all/health.svg)](https://phpackages.com/packages/hugoseigle-symfony-ux-autocomplete-select-all)
```

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
