diff options
Diffstat (limited to 'includes/external/addressbook/node_modules/lowercase-keys')
5 files changed, 99 insertions, 0 deletions
diff --git a/includes/external/addressbook/node_modules/lowercase-keys/index.d.ts b/includes/external/addressbook/node_modules/lowercase-keys/index.d.ts new file mode 100644 index 0000000..c500205 --- /dev/null +++ b/includes/external/addressbook/node_modules/lowercase-keys/index.d.ts @@ -0,0 +1,14 @@ +/** +Lowercase the keys of an object. + +@returns A new object with the keys lowercased. + +@example +``` +import lowercaseKeys from 'lowercase-keys'; + +lowercaseKeys({FOO: true, bAr: false}); +//=> {foo: true, bar: false} +``` +*/ +export default function lowercaseKeys<T>(object: Record<string, T>): Record<string, T>; diff --git a/includes/external/addressbook/node_modules/lowercase-keys/index.js b/includes/external/addressbook/node_modules/lowercase-keys/index.js new file mode 100644 index 0000000..c1e27e4 --- /dev/null +++ b/includes/external/addressbook/node_modules/lowercase-keys/index.js @@ -0,0 +1,3 @@ +export default function lowercaseKeys(object) { + return Object.fromEntries(Object.entries(object).map(([key, value]) => [key.toLowerCase(), value])); +} diff --git a/includes/external/addressbook/node_modules/lowercase-keys/license b/includes/external/addressbook/node_modules/lowercase-keys/license new file mode 100644 index 0000000..fa7ceba --- /dev/null +++ b/includes/external/addressbook/node_modules/lowercase-keys/license @@ -0,0 +1,9 @@ +MIT License + +Copyright (c) Sindre Sorhus <sindresorhus@gmail.com> (https://sindresorhus.com) + +Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. diff --git a/includes/external/addressbook/node_modules/lowercase-keys/package.json b/includes/external/addressbook/node_modules/lowercase-keys/package.json new file mode 100644 index 0000000..dd9e591 --- /dev/null +++ b/includes/external/addressbook/node_modules/lowercase-keys/package.json @@ -0,0 +1,41 @@ +{ + "name": "lowercase-keys", + "version": "3.0.0", + "description": "Lowercase the keys of an object", + "license": "MIT", + "repository": "sindresorhus/lowercase-keys", + "funding": "https://github.com/sponsors/sindresorhus", + "author": { + "name": "Sindre Sorhus", + "email": "sindresorhus@gmail.com", + "url": "https://sindresorhus.com" + }, + "type": "module", + "exports": "./index.js", + "engines": { + "node": "^12.20.0 || ^14.13.1 || >=16.0.0" + }, + "scripts": { + "test": "xo && ava && tsd" + }, + "files": [ + "index.js", + "index.d.ts" + ], + "keywords": [ + "object", + "assign", + "extend", + "properties", + "lowercase", + "lower-case", + "case", + "keys", + "key" + ], + "devDependencies": { + "ava": "^3.15.0", + "tsd": "^0.18.0", + "xo": "^0.45.0" + } +} diff --git a/includes/external/addressbook/node_modules/lowercase-keys/readme.md b/includes/external/addressbook/node_modules/lowercase-keys/readme.md new file mode 100644 index 0000000..cea0af5 --- /dev/null +++ b/includes/external/addressbook/node_modules/lowercase-keys/readme.md @@ -0,0 +1,32 @@ +# lowercase-keys + +> Lowercase the keys of an object + +Check out [`map-obj`](https://github.com/sindresorhus/map-obj) if you need support for deep iteration. + +## Install + +```sh +npm install lowercase-keys +``` + +## Usage + +```js +import lowercaseKeys from 'lowercase-keys'; + +lowercaseKeys({FOO: true, bAr: false}); +//=> {foo: true, bar: false} +``` + +## API + +### lowercaseKeys(object) + +Returns a new object with the keys lowercased. + +## lowercase-keys for enterprise + +Available as part of the Tidelift Subscription. + +The maintainers of lowercase-keys and thousands of other packages are working with Tidelift to deliver commercial support and maintenance for the open source dependencies you use to build your applications. Save time, reduce risk, and improve code health, while paying the maintainers of the exact dependencies you use. [Learn more.](https://tidelift.com/subscription/pkg/npm-lowercase-keys?utm_source=npm-lowercase-keys&utm_medium=referral&utm_campaign=enterprise&utm_term=repo) |