Repository: Choices-js/Choices Branch: main Commit: 59feffe87448 Files: 199 Total size: 2.2 MB Directory structure: gitextract_040cemen/ ├── .browserslistrc ├── .codebeatignore ├── .codecov.yml ├── .editorconfig ├── .eslintrc.json ├── .git-blame-ignore-revs ├── .gitattributes ├── .github/ │ ├── ISSUE_TEMPLATE/ │ │ ├── bug_report.md │ │ └── feature_request.md │ ├── PULL_REQUEST_TEMPLATE.md │ ├── actions-scripts/ │ │ └── polyfills-sync.cjs │ ├── release-drafter.yml │ └── workflows/ │ ├── browsers.yml │ ├── bundlesize.yml │ ├── deploy-pages.yml │ ├── deployment.yml │ ├── lint.yml │ ├── polyfills-sync.yml │ ├── release-drafter.yml │ └── unit-tests.yml ├── .gitignore ├── .nvmrc ├── .prettierrc.json ├── .stylelintrc.json ├── .vscode/ │ ├── extensions.json │ ├── launch.json │ ├── settings.json │ └── tasks.json ├── CHANGELOG.md ├── CODE_OF_CONDUCT.md ├── CONTRIBUTING.md ├── LICENSE ├── README.md ├── babel.config.json ├── jsconfig.json ├── package.json ├── playwright.config.ts ├── public/ │ ├── assets/ │ │ ├── images/ │ │ │ ├── browserconfig.xml │ │ │ └── manifest.json │ │ ├── scripts/ │ │ │ ├── choices.js │ │ │ ├── choices.mjs │ │ │ ├── choices.search-basic.js │ │ │ ├── choices.search-basic.mjs │ │ │ ├── choices.search-kmp.js │ │ │ ├── choices.search-kmp.mjs │ │ │ ├── choices.search-prefix.js │ │ │ └── choices.search-prefix.mjs │ │ └── styles/ │ │ ├── base.css │ │ └── choices.css │ ├── index.html │ ├── robots.txt │ ├── test/ │ │ ├── data.json │ │ ├── disabled-data.json │ │ ├── select-multiple/ │ │ │ ├── index-performance.html │ │ │ └── index.html │ │ ├── select-one/ │ │ │ └── index.html │ │ └── text/ │ │ └── index.html │ └── types/ │ └── src/ │ ├── index.d.ts │ └── scripts/ │ ├── actions/ │ │ ├── choices.d.ts │ │ ├── groups.d.ts │ │ └── items.d.ts │ ├── choices.d.ts │ ├── components/ │ │ ├── container.d.ts │ │ ├── dropdown.d.ts │ │ ├── index.d.ts │ │ ├── input.d.ts │ │ ├── list.d.ts │ │ ├── wrapped-element.d.ts │ │ ├── wrapped-input.d.ts │ │ └── wrapped-select.d.ts │ ├── constants.d.ts │ ├── defaults.d.ts │ ├── interfaces/ │ │ ├── action-type.d.ts │ │ ├── build-flags.d.ts │ │ ├── choice-full.d.ts │ │ ├── class-names.d.ts │ │ ├── event-choice.d.ts │ │ ├── event-type.d.ts │ │ ├── group-full.d.ts │ │ ├── index.d.ts │ │ ├── input-choice.d.ts │ │ ├── input-group.d.ts │ │ ├── item.d.ts │ │ ├── keycode-map.d.ts │ │ ├── options.d.ts │ │ ├── passed-element-type.d.ts │ │ ├── passed-element.d.ts │ │ ├── position-options-type.d.ts │ │ ├── search.d.ts │ │ ├── state.d.ts │ │ ├── store.d.ts │ │ ├── string-pre-escaped.d.ts │ │ ├── string-untrusted.d.ts │ │ ├── templates.d.ts │ │ └── types.d.ts │ ├── lib/ │ │ ├── choice-input.d.ts │ │ ├── html-guard-statements.d.ts │ │ └── utils.d.ts │ ├── reducers/ │ │ ├── choices.d.ts │ │ ├── groups.d.ts │ │ └── items.d.ts │ ├── search/ │ │ ├── fuse.d.ts │ │ ├── index.d.ts │ │ ├── kmp.d.ts │ │ └── prefix-filter.d.ts │ ├── store/ │ │ └── store.d.ts │ └── templates.d.ts ├── scripts/ │ ├── lint-staged.config.js │ ├── rollup.config.mjs │ └── server.mjs ├── src/ │ ├── entry.js │ ├── index.ts │ ├── scripts/ │ │ ├── actions/ │ │ │ ├── choices.ts │ │ │ ├── groups.ts │ │ │ └── items.ts │ │ ├── choices.ts │ │ ├── components/ │ │ │ ├── container.ts │ │ │ ├── dropdown.ts │ │ │ ├── index.ts │ │ │ ├── input.ts │ │ │ ├── list.ts │ │ │ ├── wrapped-element.ts │ │ │ ├── wrapped-input.ts │ │ │ └── wrapped-select.ts │ │ ├── constants.ts │ │ ├── defaults.ts │ │ ├── interfaces/ │ │ │ ├── action-type.ts │ │ │ ├── build-flags.ts │ │ │ ├── choice-full.ts │ │ │ ├── class-names.ts │ │ │ ├── event-choice.ts │ │ │ ├── event-type.ts │ │ │ ├── group-full.ts │ │ │ ├── index.ts │ │ │ ├── input-choice.ts │ │ │ ├── input-group.ts │ │ │ ├── item.ts │ │ │ ├── keycode-map.ts │ │ │ ├── options.ts │ │ │ ├── passed-element-type.ts │ │ │ ├── passed-element.ts │ │ │ ├── position-options-type.ts │ │ │ ├── search.ts │ │ │ ├── state.ts │ │ │ ├── store.ts │ │ │ ├── string-pre-escaped.ts │ │ │ ├── string-untrusted.ts │ │ │ ├── templates.ts │ │ │ └── types.ts │ │ ├── lib/ │ │ │ ├── choice-input.ts │ │ │ ├── html-guard-statements.ts │ │ │ └── utils.ts │ │ ├── reducers/ │ │ │ ├── choices.ts │ │ │ ├── groups.ts │ │ │ └── items.ts │ │ ├── search/ │ │ │ ├── fuse.ts │ │ │ ├── index.ts │ │ │ ├── kmp.ts │ │ │ └── prefix-filter.ts │ │ ├── store/ │ │ │ └── store.ts │ │ └── templates.ts │ ├── styles/ │ │ ├── base.scss │ │ └── choices.scss │ └── tsconfig.json ├── test/ │ ├── scripts/ │ │ ├── actions/ │ │ │ ├── choices.test.ts │ │ │ ├── groups.test.ts │ │ │ └── items.test.ts │ │ ├── choices.test.ts │ │ ├── components/ │ │ │ ├── container.test.ts │ │ │ ├── dropdown.test.ts │ │ │ ├── input.test.ts │ │ │ ├── list.test.ts │ │ │ ├── wrapped-element.test.ts │ │ │ ├── wrapped-input.test.ts │ │ │ └── wrapped-select.test.ts │ │ ├── lib/ │ │ │ └── utils.test.ts │ │ ├── reducers/ │ │ │ ├── choices.test.ts │ │ │ ├── groups.test.ts │ │ │ └── items.test.ts │ │ ├── search/ │ │ │ └── index.test.ts │ │ ├── store/ │ │ │ └── store.test.ts │ │ └── templates.test.ts │ ├── setupFiles/ │ │ └── window-matchMedia.ts │ └── tsconfig.json ├── test-e2e/ │ ├── bundle-test.ts │ ├── hars/ │ │ ├── 0432285dab6a62ab5e6efaf4cb1272720e0c3f1b.json │ │ ├── 69c6136c671f1173ee6d6596d125e821dea44a4f.json │ │ ├── a8763b95c9f6c98156a9100e8bed82cb17b93ecd.json │ │ └── discogs.har │ ├── select-test-suit.ts │ ├── test-suit.ts │ ├── tests/ │ │ ├── demo-page.spec.ts │ │ ├── select-multiple-performance.spec.ts │ │ ├── select-multiple.spec.ts │ │ ├── select-one.spec.ts │ │ └── text.spec.ts │ ├── text-test-suit.ts │ └── tsconfig.json └── vitest.config.ts ================================================ FILE CONTENTS ================================================ ================================================ FILE: .browserslistrc ================================================ > 1% ================================================ FILE: .codebeatignore ================================================ public/** webpack.config.*.js *.js ================================================ FILE: .codecov.yml ================================================ coverage: parsers: javascript: enable_partials: yes ================================================ FILE: .editorconfig ================================================ root = true [*] indent_style = space indent_size = 2 end_of_line = lf charset = utf-8 trim_trailing_whitespace = true ================================================ FILE: .eslintrc.json ================================================ { "parser": "@typescript-eslint/parser", "plugins": ["@typescript-eslint", "prettier", "sort-class-members"], "extends": [ "airbnb-base", "airbnb-typescript", "plugin:prettier/recommended", "plugin:compat/recommended", "plugin:@typescript-eslint/recommended" ], "env": { "es6": true, "node": true, "browser": true }, "parserOptions": { "sourceType": "module", "project": true }, "rules": { "no-param-reassign": ["error", { "props": false }], "@typescript-eslint/explicit-function-return-type": "error", "import/no-named-as-default": "off", "import/prefer-default-export": "off", "import/no-extraneous-dependencies": [ "error", { "devDependencies": true } ], "no-console": [ "warn", { "allow": ["warn", "error"] } ], "no-plusplus": "off", "no-unused-expressions": "off", "no-underscore-dangle": "off", "consistent-return": "off", "import/no-useless-path-segments": "warn", "prefer-destructuring": [ "warn", { "array": false, "object": true } ], "curly": ["error", "all"], "newline-before-return": "error", "sort-class-members/sort-class-members": [ 2, { "order": [ "[static-properties]", "[static-methods]", "[properties]", "[conventional-private-properties]", "constructor", "[methods]", "[conventional-private-methods]" ], "accessorPairPositioning": "getThenSet" } ], "lines-between-class-members": "off", "@typescript-eslint/no-floating-promises": "error", "@typescript-eslint/no-namespace": "off", "react/jsx-filename-extension": [0], "import/extensions": [ "error", "ignorePackages", { "js": "never", "mjs": "never", "jsx": "never", "ts": "never", "tsx": "never" } ] }, "overrides": [ { "files": ["*.test.ts", "*.spec.ts"], "rules": { "no-await-in-loop": "off", "@typescript-eslint/explicit-function-return-type": "off", "no-restricted-syntax": "off", "compat/compat": "off", "no-new": "off", "@typescript-eslint/no-empty-function": "off", "@typescript-eslint/no-explicit-any": "off", "@typescript-eslint/no-non-null-assertion": "off", "@typescript-eslint/no-unused-expressions": "off", "@typescript-eslint/naming-convention": [ "error", { "selector": "default", "format": ["camelCase", "PascalCase", "UPPER_CASE"], "leadingUnderscore": "allow" } ] } } ], "settings": { "polyfills": [ "Array.from", "Array.prototype.find", "Array.prototype.includes", "Symbol", "Symbol.iterator", "DOMTokenList", "Object.assign", "CustomEvent", "Element.prototype.classList", "Element.prototype.closest", "Element.prototype.dataset", "Element.prototype.replaceChildren" ], "import/resolver": { "node": { "extensions": [".js", ".ts"] } } }, "ignorePatterns": ["node_modules/*", "public/*"] } ================================================ FILE: .git-blame-ignore-revs ================================================ # byte shaving (hoist semi-commonly variables, remove some low level low-usage functions) 157a47a44a01e3ce4b54ad211b1756ff59985bef 5bee41d7ff08e05442b232e3e552dcb6c703568d e9382df0ae63edfc7540f82f74cf969342c759c0 # prettier config change 00433d200d8cccc8b544fbc8f05d5e96bf8ccff7 # misc linting cleanup 00009d2effa8b41a6ce27ef8b06a35a04215aea6 62b786d1f13d0934137a62909d3a37db0a3e927e 5ad61841143508c9f91f0edd57f81f8b11066e0a 84a61cad1ddab1e851c98efa619a2cd35af434c1 33f573247e8badc9ee10defe326f13985342e09b b0199538a82d49de429f35546e412d14fc8bfeb9 ================================================ FILE: .gitattributes ================================================ ## GITATTRIBUTES FOR WEB PROJECTS # # These settings are for any web project. # # Details per file setting: # text These files should be normalized (i.e. convert CRLF to LF). # binary These files are binary and should be left untouched. # # Note that binary is a macro for -text -diff. ###################################################################### # Auto detect ## Handle line endings automatically for files detected as ## text and leave all files detected as binary untouched. ## This will handle all files NOT defined below. * text eol=lf # Source code *.css text eol=lf *.html text diff=html eol=lf *.js text eol=lf *.json text eol=lf *.scss text diff=css eol=lf *.ts text eol=lf # Documentation *.md text eol=lf *.txt text eol=lf AUTHORS text eol=lf CHANGELOG text eol=lf CHANGES text eol=lf CONTRIBUTING text eol=lf COPYING text eol=lf copyright text eol=lf *COPYRIGHT* text eol=lf INSTALL text eol=lf license text eol=lf LICENSE text eol=lf NEWS text eol=lf readme text eol=lf *README* text eol=lf TODO text eol=lf # Linters .eslintrc text eol=lf .stylelintrc text eol=lf # Configs .babelrc text eol=lf .browserslistrc text eol=lf .editorconfig text eol=lf .env text eol=lf .gitattributes text eol=lf .gitconfig text eol=lf package-lock.json text -diff eol=lf *.npmignore text eol=lf *.yaml text eol=lf *.yml text eol=lf browserslist text eol=lf # Graphics # SVG treated as an asset (binary) by default. *.svg text eol=lf *.png binary ================================================ FILE: .github/ISSUE_TEMPLATE/bug_report.md ================================================ --- name: Bug report about: Create a report to help us improve title: '' labels: bug assignees: '' --- **Describe the bug** A clear and concise description of what the bug is. **To Reproduce** Using https://jsfiddle.net/ to create a minimal reproducible example. Otherwise Steps to reproduce the behavior: 1. Go to '...' 2. Click on '....' 3. Scroll down to '....' 4. See error **Expected behavior** A clear and concise description of what you expected to happen. **Screenshots** If applicable, add screenshots to help explain your problem. **Choices version and bundle** - Version: [e.g. v11.0.0 choices.min.js] **Desktop (please complete the following information):** - OS: [e.g. iOS] - Browser [e.g. chrome, safari] - Version [e.g. 22] **Smartphone (please complete the following information):** - Device: [e.g. iPhone6] - OS: [e.g. iOS8.1] - Browser [e.g. stock browser, safari] - Version [e.g. 22] **Additional context** Add any other context about the problem here. ================================================ FILE: .github/ISSUE_TEMPLATE/feature_request.md ================================================ --- name: Feature request about: Suggest an idea for this project title: '' labels: feature request assignees: '' --- **Is your feature request related to a problem? Please describe.** A clear and concise description of what the problem is. Ex. I'm always frustrated when [...] **Describe the solution you'd like** A clear and concise description of what you want to happen. **Describe alternatives you've considered** A clear and concise description of any alternative solutions or features you've considered. **Additional context** Add any other context or screenshots about the feature request here. ================================================ FILE: .github/PULL_REQUEST_TEMPLATE.md ================================================ ## Description ## Screenshots (if appropriate) ## Types of changes - [ ] Chore (tooling change or documentation change) - [ ] Refactor (non-breaking change which maintains existing functionality) - [ ] Bug fix (non-breaking change which fixes an issue) - [ ] New feature (non-breaking change which adds functionality) - [ ] Breaking change (fix or feature that would cause existing functionality to not work as expected) ## Checklist - [ ] My code follows the code style of this project. - [ ] I have added new tests for the bug I fixed/the new feature I added. - [ ] I have modified existing tests for the bug I fixed/the new feature I added. - [ ] My change requires a change to the documentation. - [ ] I have updated the documentation accordingly. ================================================ FILE: .github/actions-scripts/polyfills-sync.cjs ================================================ const { readFileSync } = require('fs'); const path = require('path'); const assert = require('assert'); const readme = readFileSync(path.resolve(__dirname, '../../README.md'), 'utf8'); const polyfillsFromDocs = /^```polyfills\s*\n([^`]+)\n^```/m .exec(readme)[1] .split('\n') .map(v => v.trim()) .sort(); // @ts-ignore const polyfillsFromSettings = require('../../.eslintrc.json').settings.polyfills.sort(); assert.deepStrictEqual(polyfillsFromDocs, polyfillsFromSettings); ================================================ FILE: .github/release-drafter.yml ================================================ name-template: 'Draft (next release)' tag-template: 'v$NEXT_PATCH_VERSION' sort-direction: descending exclude-labels: - 'skip-changelog' - 'release' categories: - title: '🚨 Breaking changes' labels: - 'breaking change' - title: '🚀 Features' labels: - 'feature' - 'enhancement' - title: '🐛 Bug Fixes' labels: - 'bugfix' - title: '🔧 Maintenance' labels: - 'chore' - 'housekeeping' - 'refactor' - 'documentation' change-template: '- $TITLE @$AUTHOR (#$NUMBER)' template: | # Changes $CHANGES # Contributors $CONTRIBUTORS ================================================ FILE: .github/workflows/browsers.yml ================================================ name: End-to-end tests (playwright) on: push: branches: [ main ] paths: - 'src/**' - 'test-e2e/**' - 'package-lock.json' - '.browserslistrc' - 'babel.config.json' - 'public/index.html' - 'public/**/index.html' - '.github/workflows/browsers.yml' - 'playwright.config.ts' pull_request: paths: - 'src/**' - 'test-e2e/**' - 'package-lock.json' - '.browserslistrc' - 'babel.config.json' - 'public/index.html' - 'public/**/index.html' - '.github/workflows/browsers.yml' - 'playwright.config.ts' jobs: test-e2e-playwright: timeout-minutes: 60 strategy: fail-fast: false matrix: os: [windows-latest, macos-latest, ubuntu-latest] browser: [chromium, firefox, webkit] exclude: - os: windows-latest browser: webkit - os: windows-latest browser: firefox - os: macos-latest browser: firefox runs-on: ${{ matrix.os }} steps: - uses: actions/checkout@v4 with: fetch-depth: 1 - uses: actions/setup-node@v4 with: node-version: 24 cache: 'npm' - name: Install dependencies run: npm ci --no-audit - name: Install Playwright Browsers run: npx playwright install --with-deps - run: npx playwright install-deps - name: Run Playwright tests run: npx playwright test --project=${{ matrix.browser }} - uses: actions/upload-artifact@v4 name: Upload screenshots to GitHub Actions Artifacts if: failure() with: name: screenshot-${{ matrix.os }}-${{ matrix.browser }} path: test-results/**/*.png - uses: actions/upload-artifact@v4 name: Upload blob report to GitHub Actions Artifacts if: ${{ !cancelled() }} with: name: playwright-report-${{ matrix.os }}-${{ matrix.browser }} path: playwright-report/ retention-days: 30 ================================================ FILE: .github/workflows/bundlesize.yml ================================================ name: Bundle size checks on: push: branches: [ main ] paths: - '.github/workflows/bundlesize.yml' - 'src/scripts/**' - 'src/styles/**' - 'package-lock.json' - '.browserslistrc' pull_request: paths: - '.github/workflows/bundlesize.yml' - 'src/scripts/**' - 'src/styles/**' - 'package-lock.json' - '.browserslistrc' jobs: measure: runs-on: ubuntu-latest steps: - uses: actions/checkout@v4 with: fetch-depth: 1 - uses: actions/setup-node@v4 with: node-version: 24 cache: 'npm' - name: Install dependencies run: npm ci --no-audit - run: npm run build # we don't need to build here, as even minized assets expected to be commited - run: npm run bundlesize env: # token has expired, don't block the test #CI: true #BUNDLESIZE_GITHUB_TOKEN: ${{secrets.BUNDLESIZE_GITHUB_TOKEN}} CI_REPO_NAME: ${{ github.event.repository.name }} CI_REPO_OWNER: ${{ github.event.organization.login }} CI_COMMIT_SHA: ${{ github.event.after }} GIT_COMMIT: ${{ github.event.after }} CI_BRANCH: ${{ github.head_ref }} FORCE_COLOR: 2 ================================================ FILE: .github/workflows/deploy-pages.yml ================================================ name: Deploy Pages on: release: types: [published] workflow_dispatch: jobs: deploy-gh-pages: runs-on: ubuntu-latest steps: - uses: actions/checkout@v4 with: fetch-depth: 1 - uses: actions/setup-node@v4 with: node-version: 24 - name: Build run: | npm ci npm run build rm -rf public/test - name: Deploy uses: peaceiris/actions-gh-pages@v4 with: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} PUBLISH_BRANCH: gh-pages PUBLISH_DIR: ./public ================================================ FILE: .github/workflows/deployment.yml ================================================ name: Publish to npm on: release: types: [published] permissions: id-token: write # Required for OIDC contents: read jobs: publish-npm: runs-on: ubuntu-latest steps: - uses: actions/checkout@v4 with: fetch-depth: 1 - uses: actions/setup-node@v4 with: node-version: 24 - run: npm ci - run: npm publish --provenance --access public ================================================ FILE: .github/workflows/lint.yml ================================================ name: Code linting on: push: branches: [ main ] paths: - '.github/workflows/lint.yml' - 'src/scripts/**' - 'src/*.ts' - 'src/styles/**' - 'test/**' - 'test-e2e/**' - 'package-lock.json' - '.browserslistrc' - '.eslintrc.json' - '.editorconfig' - '.prettierrc.json' - '.stylelintrc.json' pull_request: paths: - '.github/workflows/lint.yml' - 'src/scripts/**' - 'src/*.ts' - 'src/styles/**' - 'test/**' - 'test-e2e/**' - 'package-lock.json' - '.browserslistrc' - '.eslintrc.json' - '.editorconfig' - '.prettierrc.json' - '.stylelintrc.json' jobs: lint: runs-on: ubuntu-latest steps: - uses: actions/checkout@v4 with: fetch-depth: 1 - uses: actions/setup-node@v4 with: node-version: 24 cache: 'npm' - name: Install dependencies run: npm ci --no-audit - name: run eslint run: npm run lint:js ## Can't use same eslint config for TypeScript and JavaScript ## TypeScript rules cause rule definition not found errors ## Can be re-enabled if this is resolved: https://github.com/eslint/eslint/issues/14851 # - name: Lint JS bundle # run: | # npm run js:build # npx eslint --no-ignore ./public/assets/scripts/*.js - name: run stylelint run: npm run lint:scss ================================================ FILE: .github/workflows/polyfills-sync.yml ================================================ name: Polyfills documentation on: pull_request: paths: - 'README.md' - '.browserslistrc' - '.eslintrc.json' jobs: sync: runs-on: ubuntu-latest steps: - uses: actions/checkout@v4 with: fetch-depth: 1 - uses: actions/setup-node@v4 with: node-version: 24 - name: Check Polyfills documentation and settings sync run: node .github/actions-scripts/polyfills-sync.cjs ================================================ FILE: .github/workflows/release-drafter.yml ================================================ name: Release drafter on: push: branches: [ main ] jobs: update-draft-release: runs-on: ubuntu-latest steps: - uses: release-drafter/release-drafter@v5 env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} ================================================ FILE: .github/workflows/unit-tests.yml ================================================ name: Unit tests on: push: branches: [ main ] paths: - '.github/workflows/unit-tests.yml' - 'src/scripts/**' - 'src/*.ts' - 'test/**' - 'package-lock.json' - '.browserslistrc' - 'babel.config.json' - 'vitest.config.ts' pull_request: paths: - '.github/workflows/unit-tests.yml' - 'src/scripts/**' - 'src/*.ts' - 'test/**' - 'package-lock.json' - '.browserslistrc' - 'babel.config.json' - 'vitest.config.ts' jobs: test-unit: runs-on: ubuntu-latest steps: - uses: actions/checkout@v4 with: fetch-depth: 1 - uses: actions/setup-node@v4 with: node-version: 24 cache: 'npm' - name: Install dependencies run: npm ci --no-audit - run: npm run build - run: npm run test:unit:coverage env: FORCE_COLOR: 2 - name: Upload coverage to Codecov run: bash <(curl -s https://codecov.io/bash) -f ./coverage/lcov.info -B ${{ github.head_ref }} -C ${{ github.sha }} -Z || echo 'Codecov upload failed' env: CI: true GITLAB_CI: true # pretend we are GitLab CI, while Codecov adding support for Github Actions CODECOV_ENV: github-action CODECOV_TOKEN: ${{secrets.CODECOV_TOKEN}} ================================================ FILE: .gitignore ================================================ node_modules npm-debug.log .DS_Store .idea .rollup.cache tsconfig.tsbuildinfo .npmrc .run # Test tests/reports tests/results .nyc_output coverage /test-results/ /playwright-report/ /blob-report/ /playwright/.cache/ ================================================ FILE: .nvmrc ================================================ v22.17.0 ================================================ FILE: .prettierrc.json ================================================ { "printWidth": 120, "singleQuote": true, "trailingComma": "all", "endOfLine": "lf", "overrides": [ { "files": ["*.svg"], "options": { "parser": "html", "htmlWhitespaceSensitivity": "ignore" } }, { "files": ["public/*.html"], "options": { "trailingComma": "es5" } } ] } ================================================ FILE: .stylelintrc.json ================================================ { "extends": "stylelint-config-standard-scss", "rules": { "media-feature-range-notation": null, "declaration-block-no-redundant-longhand-properties": null } } ================================================ FILE: .vscode/extensions.json ================================================ { // See http://go.microsoft.com/fwlink/?LinkId=827846 // for the documentation about the extensions.json format "recommendations": [ // we enforce ESLint rules, so, recommend extension "dbaeumer.vscode-eslint", // we use prettier, so, recommend extension "esbenp.prettier-vscode", // we are on GitHub, so, recommend extension "github.vscode-pull-request-github", // needed for our configured debug configuration with Chrome "msjsdiag.debugger-for-chrome" ] } ================================================ FILE: .vscode/launch.json ================================================ { "version": "0.2.0", "configurations": [ { "type": "chrome", "request": "launch", "name": "Launch Chrome", "preLaunchTask": "buildAndWatch", "url": "http://localhost:3001", "webRoot": "${workspaceFolder}", "sourceMapPathOverrides": { "webpack://Choices/*": "${workspaceFolder}/*" } }, ] } ================================================ FILE: .vscode/settings.json ================================================ { "eslint.enable": true, // prevent watch task failures on lint errors "eslint.autoFixOnSave": true, // switch off default VSCode formatting rules "javascript.format.enable": false, // Javascript prettier runs via ESLint "prettier.disableLanguages": ["javascript"], "[json]": { "editor.defaultFormatter": "esbenp.prettier-vscode" }, "[html]": { "editor.defaultFormatter": "esbenp.prettier-vscode" }, "[scss]": { "editor.defaultFormatter": "esbenp.prettier-vscode" }, "[javascript]": { "editor.formatOnSave": false }, "search.exclude": { "**/node_modules": true, "public/assets": true, "**/coverage": true }, // for Windows collaborators "files.eol": "\n", "files.encoding": "utf8", // associations for some files this project is using "files.associations": { ".browserslistrc": "gitignore", ".npmrc": "ini" }, // We use NPM as package manager "npm.packageManager": "npm", "npm.autoDetect": "on", "npm.fetchOnlinePackageInfo": true, "eslint.packageManager": "npm", "json.schemas": [ // Prettier config { "fileMatch": [".prettierrc.json"], "url": "http://json.schemastore.org/prettierrc" } ], "editor.codeActionsOnSave": { "source.fixAll.eslint": true }, "stylelint.validate": [ "css", "less", "postcss", "scss" ] } ================================================ FILE: .vscode/tasks.json ================================================ { // See https://go.microsoft.com/fwlink/?LinkId=733558 // for the documentation about the tasks.json format "version": "2.0.0", "tasks": [ { "type": "npm", "label": "buildAndWatch", "script": "js:watch", "group": { "kind": "build", "isDefault": true }, "isBackground": true, "presentation": { "echo": true, "reveal": "always", "focus": false, "panel": "dedicated", "showReuseMessage": true, "clear": false }, "problemMatcher": [ "$eslint-stylish", { "owner": "webpack", "fileLocation": "absolute", "pattern": [ { "regexp": "^Module build failed \\(from (\\.+)\\)", "file": 1, "line": 2, "column": 3 }, { "regexp": "\\s*TS\\d+:\\s*(.*)", "message": 1 } ], "severity": "error", "source": "webpack", "background": { "activeOnStart": true, "beginsPattern": "^Listening at", "endsPattern": "Compiled successfully\\." } } ] }, { "type": "npm", "script": "css:build", "group": "build", "problemMatcher": ["$node-sass"] }, { "type": "npm", "script": "lint", "problemMatcher": ["$eslint-stylish"] }, { "type": "npm", "script": "build", "group": "build" }, { "type": "npm", "script": "test", "group": "test" }, { "type": "npm", "script": "test:e2e", "group": "test" }, { "type": "npm", "script": "test:unit", "group": "test" }, ] } ================================================ FILE: CHANGELOG.md ================================================ # Changelog ## [11.2.0] (2026-01-05) ### Features - Add `searchRenderSelectedChoices` configuration option to control whether selected choices appear in search results for select-multiple inputs. Defaults to `true` (backward compatible behavior). Set to `false` to hide selected choices from search results. - Add support for `required` html attribute [#1332](https://github.com/Choices-js/Choices/pull/1332) - Note; This feature requires updating any css targeting the `.choices [hidden]` selector - Improve UX on the select dropdown [#1361](https://github.com/Choices-js/Choices/pull/1361) - Add `searchDisabledChoices` configuration option to allow disabled choices to appear in search results [#1357](https://github.com/Choices-js/Choices/pull/1357) - Add additional SCSS variables [#1304](https://github.com/Choices-js/Choices/pull/1304) - Add CSS custom properties support (+ dark mode for the intro page) (#1335](https://github.com/Choices-js/Choices/pull/1335) - Soften constraints on remove buttons [#1338](https://github.com/Choices-js/Choices/pull/1338) ### Bugfixes - Fix data-label-description from source html was not treated as trusted [#1365](https://github.com/Choices-js/Choices/pull/1365) - Fix kmp search not returning results as expected [#1364](https://github.com/Choices-js/Choices/pull/1364) - Fix selected choice was not reliably highlighted when opening the dropdown [#1339](https://github.com/Choices-js/Choices/pull/1339) - Define `[aria-selected]` for selectable choices per WAI-ARIA 1.2 spec, and avoid triple state with aria-selected [#1330](https://github.com/Choices-js/Choices/pull/1330) - Fix `appendGroupInSearch` option was non-functional [#1324](https://github.com/Choices-js/Choices/pull/1324) - When resolving the remove item/label/icon, add a 3rd argument item argument. Update default remove item label to use this (Fixes #1296) [#1323](https://github.com/Choices-js/Choices/pull/1323) - Fix `searchResultLimit` could not be set to `-1` when `renderChoiceLimit` was set [#1322](https://github.com/Choices-js/Choices/pull/1322) - Fix dropdown would stick closed when a search loses focus [#1308](https://github.com/Choices-js/Choices/pull/1308) - Fix `searchEnabled` being disabled for `select-multiple` did not work [#1366](https://github.com/Choices-js/Choices/pull/1366) ### Chore - Update callback argument documentation - Update development dependencies to fix npm install warning ## [11.1.0] (2025-03-14) ### Features - Support `