aboutsummaryrefslogtreecommitdiff
path: root/node_modules/yaml/dist/schema/json
diff options
context:
space:
mode:
authorMinteck <contact@minteck.org>2022-06-04 08:51:19 +0200
committerMinteck <contact@minteck.org>2022-06-04 08:51:19 +0200
commitb22f6770c8bd084d66950655203c61dd701b3d90 (patch)
tree873d7fb19584ec2709b95cc1ca05a1fc7cfd0fc4 /node_modules/yaml/dist/schema/json
parent383285ecd5292bf9a825e05904955b937de84cc9 (diff)
downloadequestriadb-b22f6770c8bd084d66950655203c61dd701b3d90.tar.gz
equestriadb-b22f6770c8bd084d66950655203c61dd701b3d90.tar.bz2
equestriadb-b22f6770c8bd084d66950655203c61dd701b3d90.zip
Remove node_modules
Diffstat (limited to 'node_modules/yaml/dist/schema/json')
-rw-r--r--node_modules/yaml/dist/schema/json/schema.d.ts2
-rw-r--r--node_modules/yaml/dist/schema/json/schema.js64
2 files changed, 0 insertions, 66 deletions
diff --git a/node_modules/yaml/dist/schema/json/schema.d.ts b/node_modules/yaml/dist/schema/json/schema.d.ts
deleted file mode 100644
index a166ca2..0000000
--- a/node_modules/yaml/dist/schema/json/schema.d.ts
+++ /dev/null
@@ -1,2 +0,0 @@
-import { CollectionTag, ScalarTag } from '../types.js';
-export declare const schema: (ScalarTag | CollectionTag)[];
diff --git a/node_modules/yaml/dist/schema/json/schema.js b/node_modules/yaml/dist/schema/json/schema.js
deleted file mode 100644
index 31d0b4d..0000000
--- a/node_modules/yaml/dist/schema/json/schema.js
+++ /dev/null
@@ -1,64 +0,0 @@
-'use strict';
-
-var Scalar = require('../../nodes/Scalar.js');
-var map = require('../common/map.js');
-var seq = require('../common/seq.js');
-
-function intIdentify(value) {
- return typeof value === 'bigint' || Number.isInteger(value);
-}
-const stringifyJSON = ({ value }) => JSON.stringify(value);
-const jsonScalars = [
- {
- identify: value => typeof value === 'string',
- default: true,
- tag: 'tag:yaml.org,2002:str',
- resolve: str => str,
- stringify: stringifyJSON
- },
- {
- identify: value => value == null,
- createNode: () => new Scalar.Scalar(null),
- default: true,
- tag: 'tag:yaml.org,2002:null',
- test: /^null$/,
- resolve: () => null,
- stringify: stringifyJSON
- },
- {
- identify: value => typeof value === 'boolean',
- default: true,
- tag: 'tag:yaml.org,2002:bool',
- test: /^true|false$/,
- resolve: str => str === 'true',
- stringify: stringifyJSON
- },
- {
- identify: intIdentify,
- default: true,
- tag: 'tag:yaml.org,2002:int',
- test: /^-?(?:0|[1-9][0-9]*)$/,
- resolve: (str, _onError, { intAsBigInt }) => intAsBigInt ? BigInt(str) : parseInt(str, 10),
- stringify: ({ value }) => intIdentify(value) ? value.toString() : JSON.stringify(value)
- },
- {
- identify: value => typeof value === 'number',
- default: true,
- tag: 'tag:yaml.org,2002:float',
- test: /^-?(?:0|[1-9][0-9]*)(?:\.[0-9]*)?(?:[eE][-+]?[0-9]+)?$/,
- resolve: str => parseFloat(str),
- stringify: stringifyJSON
- }
-];
-const jsonError = {
- default: true,
- tag: '',
- test: /^/,
- resolve(str, onError) {
- onError(`Unresolved plain scalar ${JSON.stringify(str)}`);
- return str;
- }
-};
-const schema = [map.map, seq.seq].concat(jsonScalars, jsonError);
-
-exports.schema = schema;