Initial commit

This commit is contained in:
pasketti
2026-04-05 16:14:49 -04:00
commit ebee3a5534
14059 changed files with 2588797 additions and 0 deletions

90
node_modules/react-bootstrap/lib/utils/PropTypes.js generated vendored Normal file
View File

@@ -0,0 +1,90 @@
"use strict";
var _interopRequireDefault = require("@babel/runtime-corejs2/helpers/interopRequireDefault");
exports.__esModule = true;
exports.generatedId = generatedId;
exports.requiredRoles = requiredRoles;
exports.exclusiveRoles = exclusiveRoles;
var _propTypes = _interopRequireDefault(require("prop-types"));
var _createChainableTypeChecker = _interopRequireDefault(require("prop-types-extra/lib/utils/createChainableTypeChecker"));
var _ValidComponentChildren = _interopRequireDefault(require("./ValidComponentChildren"));
var idPropType = _propTypes.default.oneOfType([_propTypes.default.string, _propTypes.default.number]);
function generatedId(name) {
return function (props) {
var error = null;
if (!props.generateChildId) {
for (var _len = arguments.length, args = new Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {
args[_key - 1] = arguments[_key];
}
error = idPropType.apply(void 0, [props].concat(args));
if (!error && !props.id) {
error = new Error("In order to properly initialize the " + name + " in a way that is accessible to assistive technologies " + ("(such as screen readers) an `id` or a `generateChildId` prop to " + name + " is required"));
}
}
return error;
};
}
function requiredRoles() {
for (var _len2 = arguments.length, roles = new Array(_len2), _key2 = 0; _key2 < _len2; _key2++) {
roles[_key2] = arguments[_key2];
}
return (0, _createChainableTypeChecker.default)(function (props, propName, component) {
var missing;
roles.every(function (role) {
if (!_ValidComponentChildren.default.some(props.children, function (child) {
return child.props.bsRole === role;
})) {
missing = role;
return false;
}
return true;
});
if (missing) {
return new Error("(children) " + component + " - Missing a required child with bsRole: " + (missing + ". " + component + " must have at least one child of each of ") + ("the following bsRoles: " + roles.join(', ')));
}
return null;
});
}
function exclusiveRoles() {
for (var _len3 = arguments.length, roles = new Array(_len3), _key3 = 0; _key3 < _len3; _key3++) {
roles[_key3] = arguments[_key3];
}
return (0, _createChainableTypeChecker.default)(function (props, propName, component) {
var duplicate;
roles.every(function (role) {
var childrenWithRole = _ValidComponentChildren.default.filter(props.children, function (child) {
return child.props.bsRole === role;
});
if (childrenWithRole.length > 1) {
duplicate = role;
return false;
}
return true;
});
if (duplicate) {
return new Error("(children) " + component + " - Duplicate children detected of bsRole: " + (duplicate + ". Only one child each allowed with the following ") + ("bsRoles: " + roles.join(', ')));
}
return null;
});
}

37
node_modules/react-bootstrap/lib/utils/StyleConfig.js generated vendored Normal file
View File

@@ -0,0 +1,37 @@
"use strict";
exports.__esModule = true;
exports.Style = exports.State = exports.DEVICE_SIZES = exports.SIZE_MAP = exports.Size = void 0;
var Size = {
LARGE: 'large',
SMALL: 'small',
XSMALL: 'xsmall'
};
exports.Size = Size;
var SIZE_MAP = {
large: 'lg',
medium: 'md',
small: 'sm',
xsmall: 'xs',
lg: 'lg',
md: 'md',
sm: 'sm',
xs: 'xs'
};
exports.SIZE_MAP = SIZE_MAP;
var DEVICE_SIZES = ['lg', 'md', 'sm', 'xs'];
exports.DEVICE_SIZES = DEVICE_SIZES;
var State = {
SUCCESS: 'success',
WARNING: 'warning',
DANGER: 'danger',
INFO: 'info'
};
exports.State = State;
var Style = {
DEFAULT: 'default',
PRIMARY: 'primary',
LINK: 'link',
INVERSE: 'inverse'
};
exports.Style = Style;

View File

@@ -0,0 +1,197 @@
"use strict";
var _interopRequireDefault = require("@babel/runtime-corejs2/helpers/interopRequireDefault");
exports.__esModule = true;
exports.default = void 0;
var _react = _interopRequireDefault(require("react"));
// TODO: This module should be ElementChildren, and should use named exports.
/**
* Iterates through children that are typically specified as `props.children`,
* but only maps over children that are "valid components".
*
* The mapFunction provided index will be normalised to the components mapped,
* so an invalid component would not increase the index.
*
* @param {?*} children Children tree container.
* @param {function(*, int)} func.
* @param {*} context Context for func.
* @return {object} Object containing the ordered map of results.
*/
function map(children, func, context) {
var index = 0;
return _react.default.Children.map(children, function (child) {
if (!_react.default.isValidElement(child)) {
return child;
}
return func.call(context, child, index++);
});
}
/**
* Iterates through children that are "valid components".
*
* The provided forEachFunc(child, index) will be called for each
* leaf child with the index reflecting the position relative to "valid components".
*
* @param {?*} children Children tree container.
* @param {function(*, int)} func.
* @param {*} context Context for context.
*/
function forEach(children, func, context) {
var index = 0;
_react.default.Children.forEach(children, function (child) {
if (!_react.default.isValidElement(child)) {
return;
}
func.call(context, child, index++);
});
}
/**
* Count the number of "valid components" in the Children container.
*
* @param {?*} children Children tree container.
* @returns {number}
*/
function count(children) {
var result = 0;
_react.default.Children.forEach(children, function (child) {
if (!_react.default.isValidElement(child)) {
return;
}
++result;
});
return result;
}
/**
* Finds children that are typically specified as `props.children`,
* but only iterates over children that are "valid components".
*
* The provided forEachFunc(child, index) will be called for each
* leaf child with the index reflecting the position relative to "valid components".
*
* @param {?*} children Children tree container.
* @param {function(*, int)} func.
* @param {*} context Context for func.
* @returns {array} of children that meet the func return statement
*/
function filter(children, func, context) {
var index = 0;
var result = [];
_react.default.Children.forEach(children, function (child) {
if (!_react.default.isValidElement(child)) {
return;
}
if (func.call(context, child, index++)) {
result.push(child);
}
});
return result;
}
function find(children, func, context) {
var index = 0;
var result;
_react.default.Children.forEach(children, function (child) {
if (result) {
return;
}
if (!_react.default.isValidElement(child)) {
return;
}
if (func.call(context, child, index++)) {
result = child;
}
});
return result;
}
function every(children, func, context) {
var index = 0;
var result = true;
_react.default.Children.forEach(children, function (child) {
if (!result) {
return;
}
if (!_react.default.isValidElement(child)) {
return;
}
if (!func.call(context, child, index++)) {
result = false;
}
});
return result;
}
function some(children, func, context) {
var index = 0;
var result = false;
_react.default.Children.forEach(children, function (child) {
if (result) {
return;
}
if (!_react.default.isValidElement(child)) {
return;
}
if (func.call(context, child, index++)) {
result = true;
}
});
return result;
}
function toArray(children) {
var result = [];
_react.default.Children.forEach(children, function (child) {
if (!_react.default.isValidElement(child)) {
return;
}
result.push(child);
});
return result;
}
var _default = {
map: map,
forEach: forEach,
count: count,
find: find,
filter: filter,
every: every,
some: some,
toArray: toArray
};
exports.default = _default;
module.exports = exports["default"];

View File

@@ -0,0 +1,206 @@
"use strict";
var _interopRequireDefault = require("@babel/runtime-corejs2/helpers/interopRequireDefault");
exports.__esModule = true;
exports.prefix = prefix;
exports.getClassSet = getClassSet;
exports.splitBsProps = splitBsProps;
exports.splitBsPropsAndOmit = splitBsPropsAndOmit;
exports.addStyle = addStyle;
exports._curry = exports.bsSizes = exports.bsStyles = exports.bsClass = void 0;
var _entries = _interopRequireDefault(require("@babel/runtime-corejs2/core-js/object/entries"));
var _extends2 = _interopRequireDefault(require("@babel/runtime-corejs2/helpers/extends"));
var _invariant = _interopRequireDefault(require("invariant"));
var _propTypes = _interopRequireDefault(require("prop-types"));
var _StyleConfig = require("./StyleConfig");
// TODO: The publicly exposed parts of this should be in lib/BootstrapUtils.
function curry(fn) {
return function () {
for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {
args[_key] = arguments[_key];
}
var last = args[args.length - 1];
if (typeof last === 'function') {
return fn.apply(void 0, args);
}
return function (Component) {
return fn.apply(void 0, args.concat([Component]));
};
};
}
function prefix(props, variant) {
var bsClass = (props.bsClass || '').trim();
!(bsClass != null) ? process.env.NODE_ENV !== "production" ? (0, _invariant.default)(false, 'A `bsClass` prop is required for this component') : invariant(false) : void 0;
return bsClass + (variant ? "-" + variant : '');
}
var bsClass = curry(function (defaultClass, Component) {
var propTypes = Component.propTypes || (Component.propTypes = {});
var defaultProps = Component.defaultProps || (Component.defaultProps = {});
propTypes.bsClass = _propTypes.default.string;
defaultProps.bsClass = defaultClass;
return Component;
});
exports.bsClass = bsClass;
var bsStyles = curry(function (styles, defaultStyle, Component) {
if (typeof defaultStyle !== 'string') {
Component = defaultStyle;
defaultStyle = undefined;
}
var existing = Component.STYLES || [];
var propTypes = Component.propTypes || {};
styles.forEach(function (style) {
if (existing.indexOf(style) === -1) {
existing.push(style);
}
});
var propType = _propTypes.default.oneOf(existing); // expose the values on the propType function for documentation
Component.STYLES = existing;
propType._values = existing;
Component.propTypes = (0, _extends2.default)({}, propTypes, {
bsStyle: propType
});
if (defaultStyle !== undefined) {
var defaultProps = Component.defaultProps || (Component.defaultProps = {});
defaultProps.bsStyle = defaultStyle;
}
return Component;
});
exports.bsStyles = bsStyles;
var bsSizes = curry(function (sizes, defaultSize, Component) {
if (typeof defaultSize !== 'string') {
Component = defaultSize;
defaultSize = undefined;
}
var existing = Component.SIZES || [];
var propTypes = Component.propTypes || {};
sizes.forEach(function (size) {
if (existing.indexOf(size) === -1) {
existing.push(size);
}
});
var values = [];
existing.forEach(function (size) {
var mappedSize = _StyleConfig.SIZE_MAP[size];
if (mappedSize && mappedSize !== size) {
values.push(mappedSize);
}
values.push(size);
});
var propType = _propTypes.default.oneOf(values);
propType._values = values; // expose the values on the propType function for documentation
Component.SIZES = existing;
Component.propTypes = (0, _extends2.default)({}, propTypes, {
bsSize: propType
});
if (defaultSize !== undefined) {
if (!Component.defaultProps) {
Component.defaultProps = {};
}
Component.defaultProps.bsSize = defaultSize;
}
return Component;
});
exports.bsSizes = bsSizes;
function getClassSet(props) {
var _classes;
var classes = (_classes = {}, _classes[prefix(props)] = true, _classes);
if (props.bsSize) {
var bsSize = _StyleConfig.SIZE_MAP[props.bsSize] || props.bsSize;
classes[prefix(props, bsSize)] = true;
}
if (props.bsStyle) {
classes[prefix(props, props.bsStyle)] = true;
}
return classes;
}
function getBsProps(props) {
return {
bsClass: props.bsClass,
bsSize: props.bsSize,
bsStyle: props.bsStyle,
bsRole: props.bsRole
};
}
function isBsProp(propName) {
return propName === 'bsClass' || propName === 'bsSize' || propName === 'bsStyle' || propName === 'bsRole';
}
function splitBsProps(props) {
var elementProps = {};
(0, _entries.default)(props).forEach(function (_ref) {
var propName = _ref[0],
propValue = _ref[1];
if (!isBsProp(propName)) {
elementProps[propName] = propValue;
}
});
return [getBsProps(props), elementProps];
}
function splitBsPropsAndOmit(props, omittedPropNames) {
var isOmittedProp = {};
omittedPropNames.forEach(function (propName) {
isOmittedProp[propName] = true;
});
var elementProps = {};
(0, _entries.default)(props).forEach(function (_ref2) {
var propName = _ref2[0],
propValue = _ref2[1];
if (!isBsProp(propName) && !isOmittedProp[propName]) {
elementProps[propName] = propValue;
}
});
return [getBsProps(props), elementProps];
}
/**
* Add a style variant to a Component. Mutates the propTypes of the component
* in order to validate the new variant.
*/
function addStyle(Component) {
for (var _len2 = arguments.length, styleVariant = new Array(_len2 > 1 ? _len2 - 1 : 0), _key2 = 1; _key2 < _len2; _key2++) {
styleVariant[_key2 - 1] = arguments[_key2];
}
bsStyles(styleVariant, Component);
}
var _curry = curry;
exports._curry = _curry;

10
node_modules/react-bootstrap/lib/utils/capitalize.js generated vendored Normal file
View File

@@ -0,0 +1,10 @@
"use strict";
exports.__esModule = true;
exports.default = capitalize;
function capitalize(string) {
return "" + string.charAt(0).toUpperCase() + string.slice(1);
}
module.exports = exports["default"];

View File

@@ -0,0 +1,44 @@
"use strict";
exports.__esModule = true;
exports.default = void 0;
/**
* Safe chained function
*
* Will only create a new function if needed,
* otherwise will pass back existing functions or null.
*
* @param {function} functions to chain
* @returns {function|null}
*/
function createChainedFunction() {
for (var _len = arguments.length, funcs = new Array(_len), _key = 0; _key < _len; _key++) {
funcs[_key] = arguments[_key];
}
return funcs.filter(function (f) {
return f != null;
}).reduce(function (acc, f) {
if (typeof f !== 'function') {
throw new Error('Invalid Argument Type, must only provide functions, undefined, or null.');
}
if (acc === null) {
return f;
}
return function chainedFunction() {
for (var _len2 = arguments.length, args = new Array(_len2), _key2 = 0; _key2 < _len2; _key2++) {
args[_key2] = arguments[_key2];
}
acc.apply(this, args);
f.apply(this, args);
};
}, null);
}
var _default = createChainedFunction;
exports.default = _default;
module.exports = exports["default"];

View File

@@ -0,0 +1,76 @@
"use strict";
var _interopRequireDefault = require("@babel/runtime-corejs2/helpers/interopRequireDefault");
exports.__esModule = true;
exports._resetWarned = _resetWarned;
exports.default = void 0;
var _inheritsLoose2 = _interopRequireDefault(require("@babel/runtime-corejs2/helpers/inheritsLoose"));
var _warning = _interopRequireDefault(require("warning"));
var warned = {};
function deprecationWarning(oldname, newname, link) {
var message;
if (typeof oldname === 'object') {
message = oldname.message;
} else {
message = oldname + " is deprecated. Use " + newname + " instead.";
if (link) {
message += "\nYou can read more about it at " + link;
}
}
if (warned[message]) {
return;
}
process.env.NODE_ENV !== "production" ? (0, _warning.default)(false, message) : void 0;
warned[message] = true;
}
deprecationWarning.wrapper = function (Component) {
for (var _len = arguments.length, args = new Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {
args[_key - 1] = arguments[_key];
}
return (
/*#__PURE__*/
function (_Component) {
(0, _inheritsLoose2.default)(DeprecatedComponent, _Component);
function DeprecatedComponent() {
return _Component.apply(this, arguments) || this;
}
var _proto = DeprecatedComponent.prototype;
_proto.componentWillMount = function componentWillMount() {
deprecationWarning.apply(void 0, args);
if (_Component.prototype.componentWillMount) {
var _Component$prototype$;
for (var _len2 = arguments.length, methodArgs = new Array(_len2), _key2 = 0; _key2 < _len2; _key2++) {
methodArgs[_key2] = arguments[_key2];
}
(_Component$prototype$ = _Component.prototype.componentWillMount).call.apply(_Component$prototype$, [this].concat(methodArgs));
}
};
return DeprecatedComponent;
}(Component)
);
};
var _default = deprecationWarning;
exports.default = _default;
function _resetWarned() {
warned = {};
}

20
node_modules/react-bootstrap/lib/utils/index.js generated vendored Normal file
View File

@@ -0,0 +1,20 @@
"use strict";
var _interopRequireDefault = require("@babel/runtime-corejs2/helpers/interopRequireDefault");
var _interopRequireWildcard = require("@babel/runtime-corejs2/helpers/interopRequireWildcard");
exports.__esModule = true;
exports.bootstrapUtils = void 0;
var _bootstrapUtils = _interopRequireWildcard(require("./bootstrapUtils"));
exports.bootstrapUtils = _bootstrapUtils;
var _createChainedFunction2 = _interopRequireDefault(require("./createChainedFunction"));
exports.createChainedFunction = _createChainedFunction2.default;
var _ValidComponentChildren2 = _interopRequireDefault(require("./ValidComponentChildren"));
exports.ValidComponentChildren = _ValidComponentChildren2.default;

View File

@@ -0,0 +1,27 @@
"use strict";
var _interopRequireDefault = require("@babel/runtime-corejs2/helpers/interopRequireDefault");
exports.__esModule = true;
exports.default = splitComponentProps;
var _entries = _interopRequireDefault(require("@babel/runtime-corejs2/core-js/object/entries"));
function splitComponentProps(props, Component) {
var componentPropTypes = Component.propTypes;
var parentProps = {};
var childProps = {};
(0, _entries.default)(props).forEach(function (_ref) {
var propName = _ref[0],
propValue = _ref[1];
if (componentPropTypes[propName]) {
parentProps[propName] = propValue;
} else {
childProps[propName] = propValue;
}
});
return [parentProps, childProps];
}
module.exports = exports["default"];