Add Robot_JoyIt driver
This commit is contained in:
3
node_modules/babel-preset-current-node-syntax/.github/FUNDING.yml
generated
vendored
Normal file
3
node_modules/babel-preset-current-node-syntax/.github/FUNDING.yml
generated
vendored
Normal file
@@ -0,0 +1,3 @@
|
||||
# These are supported funding model platforms
|
||||
|
||||
github: [nicolo-ribaudo]
|
||||
49
node_modules/babel-preset-current-node-syntax/.github/workflows/nodejs.yml
generated
vendored
Normal file
49
node_modules/babel-preset-current-node-syntax/.github/workflows/nodejs.yml
generated
vendored
Normal file
@@ -0,0 +1,49 @@
|
||||
# This workflow will do a clean install of node dependencies, build the source code and run tests across different versions of node
|
||||
# For more information see: https://help.github.com/actions/language-and-framework-guides/using-nodejs-with-github-actions
|
||||
|
||||
name: Node.js CI
|
||||
|
||||
on:
|
||||
push:
|
||||
branches: [main]
|
||||
pull_request:
|
||||
branches: [main]
|
||||
|
||||
jobs:
|
||||
build:
|
||||
runs-on: ubuntu-latest
|
||||
|
||||
strategy:
|
||||
matrix:
|
||||
node-version:
|
||||
[
|
||||
"10.0",
|
||||
"10.19",
|
||||
"12.4",
|
||||
"12.8",
|
||||
"13.11",
|
||||
"14.3",
|
||||
"14",
|
||||
"15",
|
||||
"16.10",
|
||||
"16.11",
|
||||
"17",
|
||||
"18.19",
|
||||
"18.20",
|
||||
"19",
|
||||
"20.9",
|
||||
"20.10",
|
||||
"21",
|
||||
"22",
|
||||
]
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@v2
|
||||
- name: Use Node.js latest
|
||||
uses: actions/setup-node@v1
|
||||
- run: npm install
|
||||
- name: Use Node.js ${{ matrix.node-version }}
|
||||
uses: actions/setup-node@v1
|
||||
with:
|
||||
node-version: ${{ matrix.node-version }}
|
||||
- run: npm test
|
||||
27
node_modules/babel-preset-current-node-syntax/package.json
generated
vendored
27
node_modules/babel-preset-current-node-syntax/package.json
generated
vendored
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "babel-preset-current-node-syntax",
|
||||
"version": "1.0.1",
|
||||
"version": "1.2.0",
|
||||
"description": "A Babel preset that enables parsing of proposals supported by the current Node.js version.",
|
||||
"main": "src/index.js",
|
||||
"repository": {
|
||||
@@ -12,30 +12,35 @@
|
||||
"url": "https://github.com/nicolo-ribaudo"
|
||||
},
|
||||
"scripts": {
|
||||
"test": "node ./test/index.js",
|
||||
"prepublish": "./scripts/check-yarn-bug.sh"
|
||||
"test": "node ./test/index.js"
|
||||
},
|
||||
"dependencies": {
|
||||
"@babel/plugin-syntax-async-generators": "^7.8.4",
|
||||
"@babel/plugin-syntax-bigint": "^7.8.3",
|
||||
"@babel/plugin-syntax-class-properties": "^7.8.3",
|
||||
"@babel/plugin-syntax-import-meta": "^7.8.3",
|
||||
"@babel/plugin-syntax-class-properties": "^7.12.13",
|
||||
"@babel/plugin-syntax-class-static-block": "^7.14.5",
|
||||
"@babel/plugin-syntax-import-attributes": "^7.24.7",
|
||||
"@babel/plugin-syntax-import-meta": "^7.10.4",
|
||||
"@babel/plugin-syntax-json-strings": "^7.8.3",
|
||||
"@babel/plugin-syntax-logical-assignment-operators": "^7.8.3",
|
||||
"@babel/plugin-syntax-logical-assignment-operators": "^7.10.4",
|
||||
"@babel/plugin-syntax-nullish-coalescing-operator": "^7.8.3",
|
||||
"@babel/plugin-syntax-numeric-separator": "^7.8.3",
|
||||
"@babel/plugin-syntax-numeric-separator": "^7.10.4",
|
||||
"@babel/plugin-syntax-object-rest-spread": "^7.8.3",
|
||||
"@babel/plugin-syntax-optional-catch-binding": "^7.8.3",
|
||||
"@babel/plugin-syntax-optional-chaining": "^7.8.3",
|
||||
"@babel/plugin-syntax-top-level-await": "^7.8.3"
|
||||
"@babel/plugin-syntax-private-property-in-object": "^7.14.5",
|
||||
"@babel/plugin-syntax-top-level-await": "^7.14.5"
|
||||
},
|
||||
"peerDependencies": {
|
||||
"@babel/core": "^7.0.0"
|
||||
"@babel/core": "^7.0.0 || ^8.0.0-0"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@babel/core": "7.0.0",
|
||||
"@babel/core": "7.25.2",
|
||||
"@babel/core-8": "npm:@babel/core@^8.0.0-beta.1",
|
||||
"@babel/parser-7.0.0": "npm:@babel/parser@7.0.0",
|
||||
"@babel/parser-7.12.0": "npm:@babel/parser@7.12.0",
|
||||
"@babel/parser-7.22.0": "npm:@babel/parser@7.22.0",
|
||||
"@babel/parser-7.9.0": "npm:@babel/parser@7.9.0"
|
||||
},
|
||||
"license": "MIT"
|
||||
}
|
||||
}
|
||||
|
||||
5
node_modules/babel-preset-current-node-syntax/scripts/check-yarn-bug.sh
generated
vendored
5
node_modules/babel-preset-current-node-syntax/scripts/check-yarn-bug.sh
generated
vendored
@@ -1,5 +0,0 @@
|
||||
if grep 3155328e5 .yarn/releases/yarn-*.cjs -c; then
|
||||
echo "Your version of yarn is affected by https://github.com/yarnpkg/berry/issues/1882"
|
||||
echo "Please run \`sed -i -e \"s/3155328e5/4567890e5/g\" .yarn/releases/yarn-*.cjs\`"
|
||||
exit 1
|
||||
fi
|
||||
75
node_modules/babel-preset-current-node-syntax/src/index.js
generated
vendored
75
node_modules/babel-preset-current-node-syntax/src/index.js
generated
vendored
@@ -1,4 +1,24 @@
|
||||
const tests = {
|
||||
function works(test) {
|
||||
try {
|
||||
// Wrap the test in a function to only test the syntax, without executing it
|
||||
(0, eval)(`(() => { ${test} })`);
|
||||
return true;
|
||||
} catch (_error) {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
function getPluginsList(tests) {
|
||||
const plugins = [];
|
||||
for (const [name, cases] of Object.entries(tests)) {
|
||||
if (cases.some(works)) {
|
||||
plugins.push(require.resolve(`@babel/plugin-syntax-${name}`));
|
||||
}
|
||||
}
|
||||
return plugins;
|
||||
}
|
||||
|
||||
const babel7OnlyPlugins = getPluginsList({
|
||||
// ECMAScript 2018
|
||||
"object-rest-spread": ["({ ...{} })", "({ ...x } = {})"], // Babel 7.2.0
|
||||
"async-generators": ["async function* f() {}"], // Babel 7.2.0
|
||||
@@ -8,37 +28,30 @@ const tests = {
|
||||
"json-strings": ["'\\u2028'"], // Babel 7.2.0
|
||||
|
||||
// ECMAScript 2020
|
||||
"bigint": ["1n"], // Babel 7.8.0
|
||||
bigint: ["1n"], // Babel 7.8.0
|
||||
"optional-chaining": ["a?.b"], // Babel 7.9.0
|
||||
"nullish-coalescing-operator": ["a ?? b"], // Babel 7.9.0
|
||||
// import.meta is handled manually
|
||||
|
||||
// Stage 3
|
||||
// ECMAScript 2021
|
||||
"numeric-separator": ["1_2"],
|
||||
"logical-assignment-operators": ["a ||= b", "a &&= b", "a ??= c"],
|
||||
|
||||
// ECMAScript 2022
|
||||
"class-properties": [
|
||||
"(class { x = 1 })",
|
||||
"(class { #x = 1 })",
|
||||
"(class { #x() {} })",
|
||||
],
|
||||
"logical-assignment-operators": ["a ||= b", "a &&= b", "a ??= c"],
|
||||
};
|
||||
"private-property-in-object": ["(class { #x; m() { #x in y } })"],
|
||||
"class-static-block": ["(class { static {} })"],
|
||||
// top-level await is handled manually
|
||||
|
||||
const plugins = [];
|
||||
const works = (test) => {
|
||||
try {
|
||||
// Wrap the test in a function to only test the syntax, without executing it
|
||||
(0, eval)(`(() => { ${test} })`);
|
||||
return true;
|
||||
} catch (_error) {
|
||||
return false;
|
||||
}
|
||||
};
|
||||
// Stage 3
|
||||
// import attributes is handled manually
|
||||
});
|
||||
|
||||
for (const [name, cases] of Object.entries(tests)) {
|
||||
if (cases.some(works)) {
|
||||
plugins.push(require.resolve(`@babel/plugin-syntax-${name}`));
|
||||
}
|
||||
}
|
||||
const commonPlugins = getPluginsList({});
|
||||
|
||||
// import.meta is only allowed in modules, and modules can only be evaluated
|
||||
// synchronously. For this reason, we cannot detect import.meta support at
|
||||
@@ -46,12 +59,28 @@ for (const [name, cases] of Object.entries(tests)) {
|
||||
const major = parseInt(process.versions.node, 10);
|
||||
const minor = parseInt(process.versions.node.match(/^\d+\.(\d+)/)[1], 10);
|
||||
if (major > 10 || (major === 10 && minor >= 4)) {
|
||||
plugins.push(require.resolve("@babel/plugin-syntax-import-meta"));
|
||||
babel7OnlyPlugins.push(require.resolve("@babel/plugin-syntax-import-meta"));
|
||||
}
|
||||
// Same for top level await - it is only supported in modules. It is supported
|
||||
// from 14.3.0
|
||||
if (major > 14 || (major === 14 && minor >= 3)) {
|
||||
plugins.push(require.resolve("@babel/plugin-syntax-top-level-await"));
|
||||
babel7OnlyPlugins.push(
|
||||
require.resolve("@babel/plugin-syntax-top-level-await")
|
||||
);
|
||||
}
|
||||
// Similar for import attributes
|
||||
if (
|
||||
major > 20 ||
|
||||
(major === 20 && minor >= 10) ||
|
||||
(major === 18 && minor >= 20)
|
||||
) {
|
||||
babel7OnlyPlugins.push(
|
||||
require.resolve("@babel/plugin-syntax-import-attributes")
|
||||
);
|
||||
}
|
||||
|
||||
module.exports = () => ({ plugins });
|
||||
module.exports = ({ version }) => ({
|
||||
plugins: version.startsWith("7.")
|
||||
? babel7OnlyPlugins.concat(commonPlugins)
|
||||
: commonPlugins,
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user