From e06ec920f7a5d784e674c4c4b4e6d1da3dc7391d Mon Sep 17 00:00:00 2001 From: Piotr Russ Date: Mon, 16 Nov 2020 00:10:28 +0100 Subject: api, login, auth --- node_modules/clone-deep/LICENSE | 21 +++++++ node_modules/clone-deep/README.md | 97 +++++++++++++++++++++++++++++++ node_modules/clone-deep/index.js | 54 ++++++++++++++++++ node_modules/clone-deep/package.json | 107 +++++++++++++++++++++++++++++++++++ 4 files changed, 279 insertions(+) create mode 100644 node_modules/clone-deep/LICENSE create mode 100644 node_modules/clone-deep/README.md create mode 100644 node_modules/clone-deep/index.js create mode 100644 node_modules/clone-deep/package.json (limited to 'node_modules/clone-deep') diff --git a/node_modules/clone-deep/LICENSE b/node_modules/clone-deep/LICENSE new file mode 100644 index 0000000..3f2eca1 --- /dev/null +++ b/node_modules/clone-deep/LICENSE @@ -0,0 +1,21 @@ +The MIT License (MIT) + +Copyright (c) 2014-2017, Jon Schlinkert. + +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/node_modules/clone-deep/README.md b/node_modules/clone-deep/README.md new file mode 100644 index 0000000..7337291 --- /dev/null +++ b/node_modules/clone-deep/README.md @@ -0,0 +1,97 @@ +# clone-deep [![NPM version](https://img.shields.io/npm/v/clone-deep.svg?style=flat)](https://www.npmjs.com/package/clone-deep) [![NPM monthly downloads](https://img.shields.io/npm/dm/clone-deep.svg?style=flat)](https://npmjs.org/package/clone-deep) [![NPM total downloads](https://img.shields.io/npm/dt/clone-deep.svg?style=flat)](https://npmjs.org/package/clone-deep) [![Linux Build Status](https://img.shields.io/travis/jonschlinkert/clone-deep.svg?style=flat&label=Travis)](https://travis-ci.org/jonschlinkert/clone-deep) + +> Recursively (deep) clone JavaScript native types, like Object, Array, RegExp, Date as well as primitives. + +Please consider following this project's author, [Jon Schlinkert](https://github.com/jonschlinkert), and consider starring the project to show your :heart: and support. + +## Install + +Install with [npm](https://www.npmjs.com/): + +```sh +$ npm install --save clone-deep +``` + +## Usage + +```js +var cloneDeep = require('clone-deep'); + +var obj = {a: 'b'}; +var arr = [obj]; + +var copy = cloneDeep(arr); +obj.c = 'd'; + +console.log(copy); +//=> [{a: 'b'}] + +console.log(arr); +//=> [{a: 'b', c: 'd'}] +``` + +## Heads up! + +The `instanceClone` function is invoked to clone objects that are not "plain" objects (as defined by [isPlainObject](#isPlainObject)`isPlainObject`) if it is provided. If `instanceClone` is not specified, it will not attempt to clone non-plain objects, and will copy the object reference. + +## Attribution + +Based on [mout's](https://github.com/mout/mout) implementation of deepClone. + +## About + +
+Contributing + +Pull requests and stars are always welcome. For bugs and feature requests, [please create an issue](../../issues/new). + +
+ +
+Running Tests + +Running and reviewing unit tests is a great way to get familiarized with a library and its API. You can install dependencies and run tests with the following command: + +```sh +$ npm install && npm test +``` + +
+ +
+Building docs + +_(This project's readme.md is generated by [verb](https://github.com/verbose/verb-generate-readme), please don't edit the readme directly. Any changes to the readme must be made in the [.verb.md](.verb.md) readme template.)_ + +To generate the readme, run the following command: + +```sh +$ npm install -g verbose/verb#dev verb-generate-readme && verb +``` + +
+ +### Related projects + +You might also be interested in these projects: + +* [is-plain-object](https://www.npmjs.com/package/is-plain-object): Returns true if an object was created by the `Object` constructor. | [homepage](https://github.com/jonschlinkert/is-plain-object "Returns true if an object was created by the `Object` constructor.") +* [isobject](https://www.npmjs.com/package/isobject): Returns true if the value is an object and not an array or null. | [homepage](https://github.com/jonschlinkert/isobject "Returns true if the value is an object and not an array or null.") +* [kind-of](https://www.npmjs.com/package/kind-of): Get the native type of a value. | [homepage](https://github.com/jonschlinkert/kind-of "Get the native type of a value.") +* [shallow-clone](https://www.npmjs.com/package/shallow-clone): Make a shallow clone of an object, array or primitive. | [homepage](https://github.com/jonschlinkert/shallow-clone "Make a shallow clone of an object, array or primitive.") + +### Author + +**Jon Schlinkert** + +* [github/jonschlinkert](https://github.com/jonschlinkert) +* [twitter/jonschlinkert](https://twitter.com/jonschlinkert) + +### License + +Copyright © 2017, [Jon Schlinkert](https://github.com/jonschlinkert). +Released under the [MIT License](LICENSE). + +*** + +_This file was generated by [verb-generate-readme](https://github.com/verbose/verb-generate-readme), v0.6.0, on November 16, 2017._ \ No newline at end of file diff --git a/node_modules/clone-deep/index.js b/node_modules/clone-deep/index.js new file mode 100644 index 0000000..6c66e4e --- /dev/null +++ b/node_modules/clone-deep/index.js @@ -0,0 +1,54 @@ +'use strict'; + +/** + * Module dependenices + */ + +var isObject = require('is-plain-object'); +var clone = require('shallow-clone'); +var typeOf = require('kind-of'); +var forOwn = require('for-own'); + +/** + * Recursively clone native types. + */ + +function cloneDeep(val, instanceClone) { + switch (typeOf(val)) { + case 'object': + return cloneObjectDeep(val, instanceClone); + case 'array': + return cloneArrayDeep(val, instanceClone); + default: { + return clone(val); + } + } +} + +function cloneObjectDeep(obj, instanceClone) { + if (isObject(obj) || (instanceClone === true && typeOf(obj) === 'object')) { + var res = {}; + forOwn(obj, function(val, key) { + this[key] = cloneDeep(val, instanceClone); + }, res); + return res; + } + if (typeof instanceClone === 'function') { + return instanceClone(obj); + } + return obj; +} + +function cloneArrayDeep(arr, instanceClone) { + var res = []; + for (var i = 0; i < arr.length; i++) { + res[i] = cloneDeep(arr[i], instanceClone); + } + return res; +} + +/** + * Expose `cloneDeep` + */ + +module.exports = cloneDeep; diff --git a/node_modules/clone-deep/package.json b/node_modules/clone-deep/package.json new file mode 100644 index 0000000..f9b8415 --- /dev/null +++ b/node_modules/clone-deep/package.json @@ -0,0 +1,107 @@ +{ + "_from": "clone-deep@^2.0.1", + "_id": "clone-deep@2.0.2", + "_inBundle": false, + "_integrity": "sha512-SZegPTKjCgpQH63E+eN6mVEEPdQBOUzjyJm5Pora4lrwWRFS8I0QAxV/KD6vV/i0WuijHZWQC1fMsPEdxfdVCQ==", + "_location": "/clone-deep", + "_phantomChildren": {}, + "_requested": { + "type": "range", + "registry": true, + "raw": "clone-deep@^2.0.1", + "name": "clone-deep", + "escapedName": "clone-deep", + "rawSpec": "^2.0.1", + "saveSpec": null, + "fetchSpec": "^2.0.1" + }, + "_requiredBy": [ + "/sass-loader" + ], + "_resolved": "https://registry.npmjs.org/clone-deep/-/clone-deep-2.0.2.tgz", + "_shasum": "00db3a1e173656730d1188c3d6aced6d7ea97713", + "_spec": "clone-deep@^2.0.1", + "_where": "/home/pruss/Dev/3-minute-website/node_modules/sass-loader", + "author": { + "name": "Jon Schlinkert", + "url": "https://github.com/jonschlinkert" + }, + "bugs": { + "url": "https://github.com/jonschlinkert/clone-deep/issues" + }, + "bundleDependencies": false, + "dependencies": { + "for-own": "^1.0.0", + "is-plain-object": "^2.0.4", + "kind-of": "^6.0.0", + "shallow-clone": "^1.0.0" + }, + "deprecated": false, + "description": "Recursively (deep) clone JavaScript native types, like Object, Array, RegExp, Date as well as primitives.", + "devDependencies": { + "gulp-format-md": "^1.0.0", + "mocha": "3.5.2" + }, + "engines": { + "node": ">=0.10.0" + }, + "files": [ + "index.js" + ], + "homepage": "https://github.com/jonschlinkert/clone-deep", + "keywords": [ + "array", + "assign", + "clone", + "clone-array", + "clone-array-deep", + "clone-date", + "clone-deep", + "clone-object", + "clone-object-deep", + "clone-reg-exp", + "clone-regex", + "clone-regexp", + "date", + "deep", + "extend", + "mixin", + "mixin-object", + "object", + "shallow", + "util", + "utility" + ], + "license": "MIT", + "main": "index.js", + "name": "clone-deep", + "repository": { + "type": "git", + "url": "git+https://github.com/jonschlinkert/clone-deep.git" + }, + "scripts": { + "test": "mocha" + }, + "verb": { + "toc": false, + "layout": "default", + "tasks": [ + "readme" + ], + "plugins": [ + "gulp-format-md" + ], + "related": { + "list": [ + "is-plain-object", + "isobject", + "kind-of", + "shallow-clone" + ] + }, + "lint": { + "reflinks": true + } + }, + "version": "2.0.2" +} -- cgit v1.2.3