mirror of
https://github.com/SamEyeBam/animate.git
synced 2025-09-27 22:45:25 +00:00
larry babby and threejs for glsl
This commit is contained in:
21
webGl/my-threejs-test/node_modules/@parcel/namer-default/LICENSE
generated
vendored
Normal file
21
webGl/my-threejs-test/node_modules/@parcel/namer-default/LICENSE
generated
vendored
Normal file
@@ -0,0 +1,21 @@
|
||||
MIT License
|
||||
|
||||
Copyright (c) 2017-present Devon Govett
|
||||
|
||||
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.
|
124
webGl/my-threejs-test/node_modules/@parcel/namer-default/lib/DefaultNamer.js
generated
vendored
Normal file
124
webGl/my-threejs-test/node_modules/@parcel/namer-default/lib/DefaultNamer.js
generated
vendored
Normal file
@@ -0,0 +1,124 @@
|
||||
"use strict";
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
exports.default = void 0;
|
||||
function _plugin() {
|
||||
const data = require("@parcel/plugin");
|
||||
_plugin = function () {
|
||||
return data;
|
||||
};
|
||||
return data;
|
||||
}
|
||||
function _diagnostic() {
|
||||
const data = _interopRequireWildcard(require("@parcel/diagnostic"));
|
||||
_diagnostic = function () {
|
||||
return data;
|
||||
};
|
||||
return data;
|
||||
}
|
||||
function _assert() {
|
||||
const data = _interopRequireDefault(require("assert"));
|
||||
_assert = function () {
|
||||
return data;
|
||||
};
|
||||
return data;
|
||||
}
|
||||
function _path() {
|
||||
const data = _interopRequireDefault(require("path"));
|
||||
_path = function () {
|
||||
return data;
|
||||
};
|
||||
return data;
|
||||
}
|
||||
function _nullthrows() {
|
||||
const data = _interopRequireDefault(require("nullthrows"));
|
||||
_nullthrows = function () {
|
||||
return data;
|
||||
};
|
||||
return data;
|
||||
}
|
||||
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
||||
function _getRequireWildcardCache(e) { if ("function" != typeof WeakMap) return null; var r = new WeakMap(), t = new WeakMap(); return (_getRequireWildcardCache = function (e) { return e ? t : r; })(e); }
|
||||
function _interopRequireWildcard(e, r) { if (!r && e && e.__esModule) return e; if (null === e || "object" != typeof e && "function" != typeof e) return { default: e }; var t = _getRequireWildcardCache(r); if (t && t.has(e)) return t.get(e); var n = { __proto__: null }, a = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var u in e) if ("default" !== u && Object.prototype.hasOwnProperty.call(e, u)) { var i = a ? Object.getOwnPropertyDescriptor(e, u) : null; i && (i.get || i.set) ? Object.defineProperty(n, u, i) : n[u] = e[u]; } return n.default = e, t && t.set(e, n), n; }
|
||||
const COMMON_NAMES = new Set(['index', 'src', 'lib']);
|
||||
const ALLOWED_EXTENSIONS = {
|
||||
js: ['js', 'mjs', 'cjs']
|
||||
};
|
||||
var _default = exports.default = new (_plugin().Namer)({
|
||||
name({
|
||||
bundle,
|
||||
bundleGraph
|
||||
}) {
|
||||
let bundleGroup = bundleGraph.getBundleGroupsContainingBundle(bundle)[0];
|
||||
let bundleGroupBundles = bundleGraph.getBundlesInBundleGroup(bundleGroup, {
|
||||
includeInline: true
|
||||
});
|
||||
let isEntry = bundleGraph.isEntryBundleGroup(bundleGroup);
|
||||
if (bundle.needsStableName) {
|
||||
let entryBundlesOfType = bundleGroupBundles.filter(b => b.needsStableName && b.type === bundle.type);
|
||||
(0, _assert().default)(entryBundlesOfType.length === 1,
|
||||
// Otherwise, we'd end up naming two bundles the same thing.
|
||||
`Bundle group cannot have more than one entry bundle of the same type. The offending bundle type is ${entryBundlesOfType[0].type}`);
|
||||
}
|
||||
let mainBundle = (0, _nullthrows().default)(bundleGroupBundles.find(b => b.getEntryAssets().some(a => a.id === bundleGroup.entryAssetId)));
|
||||
if (bundle.id === mainBundle.id && isEntry && bundle.target && bundle.target.distEntry != null) {
|
||||
let loc = bundle.target.loc;
|
||||
let distEntry = bundle.target.distEntry;
|
||||
let distExtension = _path().default.extname(bundle.target.distEntry).slice(1);
|
||||
let allowedExtensions = ALLOWED_EXTENSIONS[bundle.type] || [bundle.type];
|
||||
if (!allowedExtensions.includes(distExtension) && loc) {
|
||||
let fullName = _path().default.relative(_path().default.dirname(loc.filePath), _path().default.join(bundle.target.distDir, distEntry));
|
||||
let err = new (_diagnostic().default)({
|
||||
diagnostic: {
|
||||
message: (0, _diagnostic().md)`Target "${bundle.target.name}" declares an output file path of "${fullName}" which does not match the compiled bundle type "${bundle.type}".`,
|
||||
codeFrames: [{
|
||||
filePath: loc.filePath,
|
||||
codeHighlights: [(0, _diagnostic().convertSourceLocationToHighlight)(loc, (0, _diagnostic().md)`Did you mean "${fullName.slice(0, -_path().default.extname(fullName).length) + '.' + bundle.type}"?`)]
|
||||
}],
|
||||
hints: [`Try changing the file extension of "${bundle.target.name}" in ${_path().default.relative(process.cwd(), loc.filePath)}.`]
|
||||
}
|
||||
});
|
||||
throw err;
|
||||
}
|
||||
return bundle.target.distEntry;
|
||||
}
|
||||
|
||||
// Base split bundle names on the first bundle in their group.
|
||||
// e.g. if `index.js` imports `foo.css`, the css bundle should be called
|
||||
// `index.css`.
|
||||
let name = nameFromContent(mainBundle, isEntry, bundleGroup.entryAssetId, bundleGraph.getEntryRoot(bundle.target));
|
||||
if (!bundle.needsStableName) {
|
||||
name += '.' + bundle.hashReference;
|
||||
}
|
||||
return name + '.' + bundle.type;
|
||||
}
|
||||
});
|
||||
function nameFromContent(bundle, isEntry, entryAssetId, entryRoot) {
|
||||
let entryFilePath = (0, _nullthrows().default)(bundle.getEntryAssets().find(a => a.id === entryAssetId)).filePath;
|
||||
let name = basenameWithoutExtension(entryFilePath);
|
||||
|
||||
// If this is an entry bundle, use the original relative path.
|
||||
if (bundle.needsStableName) {
|
||||
// Match name of target entry if possible, but with a different extension.
|
||||
if (isEntry && bundle.target.distEntry != null) {
|
||||
return basenameWithoutExtension(bundle.target.distEntry);
|
||||
}
|
||||
return _path().default.join(_path().default.relative(entryRoot, _path().default.dirname(entryFilePath)), name).replace(/\.\.(\/|\\)/g, 'up_$1');
|
||||
} else {
|
||||
// If this is an index file or common directory name, use the parent
|
||||
// directory name instead, which is probably more descriptive.
|
||||
while (COMMON_NAMES.has(name)) {
|
||||
entryFilePath = _path().default.dirname(entryFilePath);
|
||||
name = _path().default.basename(entryFilePath);
|
||||
if (name.startsWith('.')) {
|
||||
name = name.replace('.', '');
|
||||
}
|
||||
}
|
||||
return name || 'bundle';
|
||||
}
|
||||
}
|
||||
function basenameWithoutExtension(file) {
|
||||
return _path().default.basename(file, _path().default.extname(file));
|
||||
}
|
28
webGl/my-threejs-test/node_modules/@parcel/namer-default/package.json
generated
vendored
Normal file
28
webGl/my-threejs-test/node_modules/@parcel/namer-default/package.json
generated
vendored
Normal file
@@ -0,0 +1,28 @@
|
||||
{
|
||||
"name": "@parcel/namer-default",
|
||||
"version": "2.12.0",
|
||||
"license": "MIT",
|
||||
"publishConfig": {
|
||||
"access": "public"
|
||||
},
|
||||
"funding": {
|
||||
"type": "opencollective",
|
||||
"url": "https://opencollective.com/parcel"
|
||||
},
|
||||
"repository": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/parcel-bundler/parcel.git"
|
||||
},
|
||||
"main": "lib/DefaultNamer.js",
|
||||
"source": "src/DefaultNamer.js",
|
||||
"engines": {
|
||||
"node": ">= 12.0.0",
|
||||
"parcel": "^2.12.0"
|
||||
},
|
||||
"dependencies": {
|
||||
"@parcel/diagnostic": "2.12.0",
|
||||
"@parcel/plugin": "2.12.0",
|
||||
"nullthrows": "^1.1.1"
|
||||
},
|
||||
"gitHead": "2059029ee91e5f03a273b0954d3e629d7375f986"
|
||||
}
|
145
webGl/my-threejs-test/node_modules/@parcel/namer-default/src/DefaultNamer.js
generated
vendored
Normal file
145
webGl/my-threejs-test/node_modules/@parcel/namer-default/src/DefaultNamer.js
generated
vendored
Normal file
@@ -0,0 +1,145 @@
|
||||
// @flow strict-local
|
||||
|
||||
import type {Bundle, FilePath} from '@parcel/types';
|
||||
|
||||
import {Namer} from '@parcel/plugin';
|
||||
import ThrowableDiagnostic, {
|
||||
convertSourceLocationToHighlight,
|
||||
md,
|
||||
} from '@parcel/diagnostic';
|
||||
import assert from 'assert';
|
||||
import path from 'path';
|
||||
import nullthrows from 'nullthrows';
|
||||
|
||||
const COMMON_NAMES = new Set(['index', 'src', 'lib']);
|
||||
const ALLOWED_EXTENSIONS = {
|
||||
js: ['js', 'mjs', 'cjs'],
|
||||
};
|
||||
|
||||
export default (new Namer({
|
||||
name({bundle, bundleGraph}) {
|
||||
let bundleGroup = bundleGraph.getBundleGroupsContainingBundle(bundle)[0];
|
||||
let bundleGroupBundles = bundleGraph.getBundlesInBundleGroup(bundleGroup, {
|
||||
includeInline: true,
|
||||
});
|
||||
let isEntry = bundleGraph.isEntryBundleGroup(bundleGroup);
|
||||
|
||||
if (bundle.needsStableName) {
|
||||
let entryBundlesOfType = bundleGroupBundles.filter(
|
||||
b => b.needsStableName && b.type === bundle.type,
|
||||
);
|
||||
assert(
|
||||
entryBundlesOfType.length === 1,
|
||||
// Otherwise, we'd end up naming two bundles the same thing.
|
||||
`Bundle group cannot have more than one entry bundle of the same type. The offending bundle type is ${entryBundlesOfType[0].type}`,
|
||||
);
|
||||
}
|
||||
|
||||
let mainBundle = nullthrows(
|
||||
bundleGroupBundles.find(b =>
|
||||
b.getEntryAssets().some(a => a.id === bundleGroup.entryAssetId),
|
||||
),
|
||||
);
|
||||
|
||||
if (
|
||||
bundle.id === mainBundle.id &&
|
||||
isEntry &&
|
||||
bundle.target &&
|
||||
bundle.target.distEntry != null
|
||||
) {
|
||||
let loc = bundle.target.loc;
|
||||
let distEntry = bundle.target.distEntry;
|
||||
let distExtension = path.extname(bundle.target.distEntry).slice(1);
|
||||
let allowedExtensions = ALLOWED_EXTENSIONS[bundle.type] || [bundle.type];
|
||||
if (!allowedExtensions.includes(distExtension) && loc) {
|
||||
let fullName = path.relative(
|
||||
path.dirname(loc.filePath),
|
||||
path.join(bundle.target.distDir, distEntry),
|
||||
);
|
||||
let err = new ThrowableDiagnostic({
|
||||
diagnostic: {
|
||||
message: md`Target "${bundle.target.name}" declares an output file path of "${fullName}" which does not match the compiled bundle type "${bundle.type}".`,
|
||||
codeFrames: [
|
||||
{
|
||||
filePath: loc.filePath,
|
||||
codeHighlights: [
|
||||
convertSourceLocationToHighlight(
|
||||
loc,
|
||||
md`Did you mean "${
|
||||
fullName.slice(0, -path.extname(fullName).length) +
|
||||
'.' +
|
||||
bundle.type
|
||||
}"?`,
|
||||
),
|
||||
],
|
||||
},
|
||||
],
|
||||
hints: [
|
||||
`Try changing the file extension of "${
|
||||
bundle.target.name
|
||||
}" in ${path.relative(process.cwd(), loc.filePath)}.`,
|
||||
],
|
||||
},
|
||||
});
|
||||
throw err;
|
||||
}
|
||||
|
||||
return bundle.target.distEntry;
|
||||
}
|
||||
|
||||
// Base split bundle names on the first bundle in their group.
|
||||
// e.g. if `index.js` imports `foo.css`, the css bundle should be called
|
||||
// `index.css`.
|
||||
let name = nameFromContent(
|
||||
mainBundle,
|
||||
isEntry,
|
||||
bundleGroup.entryAssetId,
|
||||
bundleGraph.getEntryRoot(bundle.target),
|
||||
);
|
||||
if (!bundle.needsStableName) {
|
||||
name += '.' + bundle.hashReference;
|
||||
}
|
||||
|
||||
return name + '.' + bundle.type;
|
||||
},
|
||||
}): Namer);
|
||||
|
||||
function nameFromContent(
|
||||
bundle: Bundle,
|
||||
isEntry: boolean,
|
||||
entryAssetId: string,
|
||||
entryRoot: FilePath,
|
||||
): string {
|
||||
let entryFilePath = nullthrows(
|
||||
bundle.getEntryAssets().find(a => a.id === entryAssetId),
|
||||
).filePath;
|
||||
let name = basenameWithoutExtension(entryFilePath);
|
||||
|
||||
// If this is an entry bundle, use the original relative path.
|
||||
if (bundle.needsStableName) {
|
||||
// Match name of target entry if possible, but with a different extension.
|
||||
if (isEntry && bundle.target.distEntry != null) {
|
||||
return basenameWithoutExtension(bundle.target.distEntry);
|
||||
}
|
||||
|
||||
return path
|
||||
.join(path.relative(entryRoot, path.dirname(entryFilePath)), name)
|
||||
.replace(/\.\.(\/|\\)/g, 'up_$1');
|
||||
} else {
|
||||
// If this is an index file or common directory name, use the parent
|
||||
// directory name instead, which is probably more descriptive.
|
||||
while (COMMON_NAMES.has(name)) {
|
||||
entryFilePath = path.dirname(entryFilePath);
|
||||
name = path.basename(entryFilePath);
|
||||
if (name.startsWith('.')) {
|
||||
name = name.replace('.', '');
|
||||
}
|
||||
}
|
||||
|
||||
return name || 'bundle';
|
||||
}
|
||||
}
|
||||
|
||||
function basenameWithoutExtension(file) {
|
||||
return path.basename(file, path.extname(file));
|
||||
}
|
Reference in New Issue
Block a user