Skip to content

Commit 93d8c1d

Browse files
committed
Merge branch 'main' into focus
2 parents ccc5ffc + e396791 commit 93d8c1d

13 files changed

Lines changed: 425 additions & 285 deletions
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
"react-loqate": minor
3+
---
4+
5+
Add disableBrowserAutocomplete prop to prevent browser autocomplete interference with address suggestions. This prop defaults to true, disabling browser autocomplete by setting autoComplete="react-loqate-address-search" on the input field.

.changeset/modern-pens-worry.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
'react-loqate': patch
3+
---
4+
5+
Update test dependencies and fix all test warnings
File renamed without changes.

README.md

Lines changed: 14 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -32,19 +32,20 @@ import 'react-loqate/dist/index.css';
3232

3333
### Props
3434

35-
| name | type | required | example | description |
36-
| ---------- | ----------------------------------------------------- | -------- | ------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------- |
37-
| apiKey | string | yes | "AA11-AA11-AA11-AA11" | Loqate API key |
38-
| locale | string | yes | "en-GB" | Language to be used |
39-
| onSelect | (address) => void | yes | address => console.log(address) | Callback with for Loqate response |
40-
| countries | string[] | no | ["GB", "NL"] | Countries to search in |
41-
| limit | number | no | 10 | Number of options to show |
42-
| classes | `{ input?: string, list?: string, listItem?: string}` | no | { list: 'list' } | Classnames for the components |
43-
| components | see [Customization](#Customization) | no | { Input: CustomInput, List: CustomList, ListItem: CustomListItem, } | Components to overwrite the default ones |
44-
| inline | boolean | no | true | Render results inline with the input |
45-
| debounce | number | no | 100 | Debounce the calls to the Loqate API |
46-
| bias | boolean | no | true | Bias feature when using capture v4 enabled key.<br>Requires origin to be set. |
47-
| origin | string | no | "93.184.216.34" | Name or ISO 2 or 3 character code of a country, WGS84 coordinates (comma separated) or IP address |
35+
| name | type | required | example | description |
36+
| -------------------------- | ----------------------------------------------------- | -------- | ------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------- |
37+
| apiKey | string | yes | "AA11-AA11-AA11-AA11" | Loqate API key |
38+
| locale | string | yes | "en-GB" | Language to be used |
39+
| onSelect | (address) => void | yes | address => console.log(address) | Callback with for Loqate response |
40+
| countries | string[] | no | ["GB", "NL"] | Countries to search in |
41+
| limit | number | no | 10 | Number of options to show |
42+
| classes | `{ input?: string, list?: string, listItem?: string}` | no | { list: 'list' } | Classnames for the components |
43+
| components | see [Customization](#Customization) | no | { Input: CustomInput, List: CustomList, ListItem: CustomListItem, } | Components to overwrite the default ones |
44+
| inline | boolean | no | true | Render results inline with the input |
45+
| debounce | number | no | 100 | Debounce the calls to the Loqate API |
46+
| bias | boolean | no | true | Bias feature when using capture v4 enabled key.<br>Requires origin to be set. |
47+
| origin | string | no | "93.184.216.34" | Name or ISO 2 or 3 character code of a country, WGS84 coordinates (comma separated) or IP address |
48+
| disableBrowserAutocomplete | boolean | no | false | Disable browser autocomplete on the input field (defaults to true) |
4849

4950
### Customization
5051

package.json

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
{
22
"name": "react-loqate",
33
"version": "3.0.1",
4+
"type": "module",
45
"license": "MIT",
56
"author": "Bram Kaashoek",
67
"main": "dist/index.js",
@@ -61,25 +62,24 @@
6162
"@storybook/test": "8.0.8",
6263
"@testing-library/jest-dom": "6.4.2",
6364
"@testing-library/react": "15.0.2",
64-
"@testing-library/react-hooks": "8.0.1",
6565
"@testing-library/user-event": "^14.5.2",
6666
"@types/react": "18.0.27",
6767
"@types/react-dom": "18.0.10",
6868
"@typescript-eslint/eslint-plugin": "7.7.0",
69-
"@vitest/coverage-v8": "1.2.1",
69+
"@vitest/coverage-v8": "3.2.4",
7070
"eslint-plugin-prettier": "4.2.1",
7171
"eslint-plugin-storybook": "0.8.0",
7272
"husky": "9.0.11",
7373
"jsdom": "21.1.0",
7474
"lint-staged": "^15.2.2",
75-
"msw": "2.2.14",
75+
"msw": "2.11.1",
7676
"react": "18.2.0",
7777
"react-dom": "18.2.0",
7878
"storybook": "8.0.8",
7979
"tslib": "2.4.1",
8080
"tsup": "8.0.2",
8181
"typescript": "4.9.4",
82-
"vitest": "1.2.1"
82+
"vitest": "3.2.4"
8383
},
8484
"peerDependencies": {
8585
"react": ">=18",

0 commit comments

Comments
 (0)