add all frontend files

This commit is contained in:
2026-01-17 15:16:36 -05:00
parent ff16ae7858
commit e40287e4aa
25704 changed files with 1935289 additions and 0 deletions

7
node_modules/rc-checkbox/LICENSE.md generated vendored Normal file
View File

@@ -0,0 +1,7 @@
The MIT License (MIT) Copyright (c) 2016 React Components
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.

112
node_modules/rc-checkbox/README.md generated vendored Normal file
View File

@@ -0,0 +1,112 @@
# rc-checkbox
---
Checkbox ui component for react.
[![NPM version][npm-image]][npm-url]
[![npm download][download-image]][download-url]
[![build status][github-actions-image]][github-actions-url]
[![Codecov][codecov-image]][codecov-url]
[![bundle size][bundlephobia-image]][bundlephobia-url]
[![dumi][dumi-image]][dumi-url]
[npm-image]: http://img.shields.io/npm/v/rc-checkbox.svg?style=flat-square
[npm-url]: http://npmjs.org/package/rc-checkbox
[travis-image]: https://img.shields.io/travis/react-component/checkbox/master?style=flat-square
[travis-url]: https://travis-ci.com/react-component/checkbox
[github-actions-image]: https://github.com/react-component/checkbox/workflows/CI/badge.svg
[github-actions-url]: https://github.com/react-component/checkbox/actions
[codecov-image]: https://img.shields.io/codecov/c/github/react-component/checkbox/master.svg?style=flat-square
[codecov-url]: https://app.codecov.io/gh/react-component/checkbox
[david-url]: https://david-dm.org/react-component/checkbox
[david-image]: https://david-dm.org/react-component/checkbox/status.svg?style=flat-square
[david-dev-url]: https://david-dm.org/react-component/checkbox?type=dev
[david-dev-image]: https://david-dm.org/react-component/checkbox/dev-status.svg?style=flat-square
[download-image]: https://img.shields.io/npm/dm/rc-checkbox.svg?style=flat-square
[download-url]: https://npmjs.org/package/rc-checkbox
[bundlephobia-url]: https://bundlephobia.com/package/rc-checkbox
[bundlephobia-image]: https://badgen.net/bundlephobia/minzip/rc-checkbox
[dumi-url]: https://github.com/umijs/dumi
[dumi-image]: https://img.shields.io/badge/docs%20by-dumi-blue?style=flat-square
## Install
[![rc-checkbox](https://nodei.co/npm/rc-checkbox.png)](https://npmjs.org/package/rc-checkbox)
## Usage
```js
import checkbox from 'rc-checkbox';
export default () => <checkbox />;
```
## Compatibility
| [<img src="https://raw.githubusercontent.com/alrra/browser-logos/master/src/edge/edge_48x48.png" alt="IE / Edge" width="24px" height="24px" />](http://godban.github.io/browsers-support-badges/)<br>IE / Edge | [<img src="https://raw.githubusercontent.com/alrra/browser-logos/master/src/firefox/firefox_48x48.png" alt="Firefox" width="24px" height="24px" />](http://godban.github.io/browsers-support-badges/)<br>Firefox | [<img src="https://raw.githubusercontent.com/alrra/browser-logos/master/src/chrome/chrome_48x48.png" alt="Chrome" width="24px" height="24px" />](http://godban.github.io/browsers-support-badges/)<br>Chrome | [<img src="https://raw.githubusercontent.com/alrra/browser-logos/master/src/safari/safari_48x48.png" alt="Safari" width="24px" height="24px" />](http://godban.github.io/browsers-support-badges/)<br>Safari | [<img src="https://raw.githubusercontent.com/alrra/browser-logos/master/src/electron/electron_48x48.png" alt="Electron" width="24px" height="24px" />](http://godban.github.io/browsers-support-badges/)<br>Electron |
| --- | --- | --- | --- | --- |
| IE11, Edge | last 2 versions | last 2 versions | last 2 versions | last 2 versions |
## API
<table class="table table-bordered table-striped">
<thead>
<tr>
<th style="width: 100px;">name</th>
<th style="width: 50px;">type</th>
<th style="width: 50px;">default</th>
<th>description</th>
</tr>
</thead>
<tbody>
<tr>
<td>prefixCls</td>
<td>String</td>
<td>rc-checkbox</td>
<td></td>
</tr>
<tr>
<td>className</td>
<td>String</td>
<td>''</td>
<td>additional class name of root node</td>
</tr>
<tr>
<td>name</td>
<td>String</td>
<td></td>
<td>same with native input checkbox</td>
</tr>
<tr>
<td>checked</td>
<td>enum: 0,1,2</td>
<td></td>
<td></td>
</tr>
<tr>
<td>defaultChecked</td>
<td>enum: 0,1,2</td>
<td>0</td>
<td>same with native input checkbox</td>
<tr>
<td>onChange</td>
<td>Function(e:Event, checked:Number)</td>
<td></td>
<td>called when checkbox is changed. e is native event, checked is original checked state.</td>
</tr>
</tbody>
</table>
## Development
```
npm install
npm start
```
Online demo: http://react-component.github.io/checkbox/
## License
rc-checkbox is released under the MIT license.

134
node_modules/rc-checkbox/assets/index.css generated vendored Normal file
View File

@@ -0,0 +1,134 @@
/* Default state */
.rc-checkbox {
white-space: nowrap;
cursor: pointer;
outline: none;
display: inline-block;
position: relative;
line-height: 1;
vertical-align: middle;
}
.rc-checkbox:hover .rc-checkbox-inner,
.rc-checkbox-input:focus + .rc-checkbox-inner {
border-color: #3dbcf6;
}
.rc-checkbox-inner {
position: relative;
top: 0;
left: 0;
display: inline-block;
width: 14px;
height: 14px;
border-width: 1px;
border-style: solid;
border-radius: 3px;
border-color: #d9d9d9;
background-color: #ffffff;
transition: border-color 0.3s cubic-bezier(0.68, -0.55, 0.27, 1.55), background-color 0.3s cubic-bezier(0.68, -0.55, 0.27, 1.55);
}
.rc-checkbox-inner:after {
-webkit-transform: rotate(45deg);
transform: rotate(45deg);
position: absolute;
left: 4px;
top: 1px;
display: table;
width: 5px;
height: 8px;
border: 2px solid #ffffff;
border-top: 0;
border-left: 0;
content: ' ';
animation-timing-function: cubic-bezier(0.68, -0.55, 0.27, 1.55);
animation-duration: 0.3s;
animation-name: amCheckboxOut;
}
.rc-checkbox-input {
position: absolute;
left: 0;
z-index: 9999;
cursor: pointer;
opacity: 0;
top: 0;
bottom: 0;
right: 0;
}
/* Checked state */
.rc-checkbox-checked:hover .rc-checkbox-inner {
border-color: #3dbcf6;
}
.rc-checkbox-checked .rc-checkbox-inner {
border-color: #3dbcf6;
background-color: #3dbcf6;
}
.rc-checkbox-checked .rc-checkbox-inner:after {
transform: rotate(45deg);
position: absolute;
left: 4px;
top: 1px;
display: table;
width: 5px;
height: 8px;
border: 2px solid #ffffff;
border-top: 0;
border-left: 0;
content: ' ';
animation-timing-function: cubic-bezier(0.68, -0.55, 0.27, 1.55);
animation-duration: 0.3s;
animation-name: amCheckboxOut;
}
@media print {
.rc-checkbox-checked .rc-checkbox-inner {
box-shadow: inset 0 0 0 16px #3dbcf6;
}
}
.rc-checkbox-disabled.rc-checkbox-checked:hover .rc-checkbox-inner {
border-color: #d9d9d9;
}
.rc-checkbox-disabled.rc-checkbox-checked .rc-checkbox-inner {
background-color: #f3f3f3;
border-color: #d9d9d9;
}
.rc-checkbox-disabled.rc-checkbox-checked .rc-checkbox-inner:after {
animation-name: none;
border-color: #cccccc;
}
@media print {
.rc-checkbox-disabled.rc-checkbox-checked .rc-checkbox-inner {
box-shadow: inset 0 0 0 16px #f3f3f3;
}
}
.rc-checkbox-disabled:hover .rc-checkbox-inner {
border-color: #d9d9d9;
}
.rc-checkbox-disabled .rc-checkbox-inner {
border-color: #d9d9d9;
background-color: #f3f3f3;
}
.rc-checkbox-disabled .rc-checkbox-inner:after {
animation-name: none;
border-color: #f3f3f3;
}
.rc-checkbox-disabled .rc-checkbox-input {
cursor: default;
}
@keyframes amCheckboxIn {
0% {
opacity: 0;
transform-origin: 50% 50%;
transform: scale(0, 0) rotate(45deg);
}
100% {
opacity: 1;
transform-origin: 50% 50%;
transform: scale(1, 1) rotate(45deg);
}
}
@keyframes amCheckboxOut {
0% {
opacity: 1;
}
100% {
opacity: 0;
}
}

22
node_modules/rc-checkbox/es/index.d.ts generated vendored Normal file
View File

@@ -0,0 +1,22 @@
import * as React from 'react';
export interface CheckboxChangeEvent {
target: CheckboxChangeEventTarget;
stopPropagation: () => void;
preventDefault: () => void;
nativeEvent: React.ChangeEvent<HTMLInputElement>['nativeEvent'];
}
export interface CheckboxChangeEventTarget extends CheckboxProps {
checked: boolean;
}
export interface CheckboxRef {
focus: (options?: FocusOptions) => void;
blur: () => void;
input: HTMLInputElement | null;
nativeElement: HTMLElement | null;
}
export interface CheckboxProps extends Omit<React.InputHTMLAttributes<HTMLInputElement>, 'onChange'> {
prefixCls?: string;
onChange?: (e: CheckboxChangeEvent) => void;
}
export declare const Checkbox: React.ForwardRefExoticComponent<CheckboxProps & React.RefAttributes<CheckboxRef>>;
export default Checkbox;

85
node_modules/rc-checkbox/es/index.js generated vendored Normal file
View File

@@ -0,0 +1,85 @@
import _extends from "@babel/runtime/helpers/esm/extends";
import _objectSpread from "@babel/runtime/helpers/esm/objectSpread2";
import _defineProperty from "@babel/runtime/helpers/esm/defineProperty";
import _slicedToArray from "@babel/runtime/helpers/esm/slicedToArray";
import _objectWithoutProperties from "@babel/runtime/helpers/esm/objectWithoutProperties";
var _excluded = ["prefixCls", "className", "style", "checked", "disabled", "defaultChecked", "type", "title", "onChange"];
import classNames from 'classnames';
import useMergedState from "rc-util/es/hooks/useMergedState";
import * as React from 'react';
import { forwardRef, useImperativeHandle, useRef } from 'react';
export var Checkbox = /*#__PURE__*/forwardRef(function (props, ref) {
var _props$prefixCls = props.prefixCls,
prefixCls = _props$prefixCls === void 0 ? 'rc-checkbox' : _props$prefixCls,
className = props.className,
style = props.style,
checked = props.checked,
disabled = props.disabled,
_props$defaultChecked = props.defaultChecked,
defaultChecked = _props$defaultChecked === void 0 ? false : _props$defaultChecked,
_props$type = props.type,
type = _props$type === void 0 ? 'checkbox' : _props$type,
title = props.title,
onChange = props.onChange,
inputProps = _objectWithoutProperties(props, _excluded);
var inputRef = useRef(null);
var holderRef = useRef(null);
var _useMergedState = useMergedState(defaultChecked, {
value: checked
}),
_useMergedState2 = _slicedToArray(_useMergedState, 2),
rawValue = _useMergedState2[0],
setRawValue = _useMergedState2[1];
useImperativeHandle(ref, function () {
return {
focus: function focus(options) {
var _inputRef$current;
(_inputRef$current = inputRef.current) === null || _inputRef$current === void 0 || _inputRef$current.focus(options);
},
blur: function blur() {
var _inputRef$current2;
(_inputRef$current2 = inputRef.current) === null || _inputRef$current2 === void 0 || _inputRef$current2.blur();
},
input: inputRef.current,
nativeElement: holderRef.current
};
});
var classString = classNames(prefixCls, className, _defineProperty(_defineProperty({}, "".concat(prefixCls, "-checked"), rawValue), "".concat(prefixCls, "-disabled"), disabled));
var handleChange = function handleChange(e) {
if (disabled) {
return;
}
if (!('checked' in props)) {
setRawValue(e.target.checked);
}
onChange === null || onChange === void 0 || onChange({
target: _objectSpread(_objectSpread({}, props), {}, {
type: type,
checked: e.target.checked
}),
stopPropagation: function stopPropagation() {
e.stopPropagation();
},
preventDefault: function preventDefault() {
e.preventDefault();
},
nativeEvent: e.nativeEvent
});
};
return /*#__PURE__*/React.createElement("span", {
className: classString,
title: title,
style: style,
ref: holderRef
}, /*#__PURE__*/React.createElement("input", _extends({}, inputProps, {
className: "".concat(prefixCls, "-input"),
ref: inputRef,
onChange: handleChange,
disabled: disabled,
checked: !!rawValue,
type: type
})), /*#__PURE__*/React.createElement("span", {
className: "".concat(prefixCls, "-inner")
}));
});
export default Checkbox;

22
node_modules/rc-checkbox/lib/index.d.ts generated vendored Normal file
View File

@@ -0,0 +1,22 @@
import * as React from 'react';
export interface CheckboxChangeEvent {
target: CheckboxChangeEventTarget;
stopPropagation: () => void;
preventDefault: () => void;
nativeEvent: React.ChangeEvent<HTMLInputElement>['nativeEvent'];
}
export interface CheckboxChangeEventTarget extends CheckboxProps {
checked: boolean;
}
export interface CheckboxRef {
focus: (options?: FocusOptions) => void;
blur: () => void;
input: HTMLInputElement | null;
nativeElement: HTMLElement | null;
}
export interface CheckboxProps extends Omit<React.InputHTMLAttributes<HTMLInputElement>, 'onChange'> {
prefixCls?: string;
onChange?: (e: CheckboxChangeEvent) => void;
}
export declare const Checkbox: React.ForwardRefExoticComponent<CheckboxProps & React.RefAttributes<CheckboxRef>>;
export default Checkbox;

95
node_modules/rc-checkbox/lib/index.js generated vendored Normal file
View File

@@ -0,0 +1,95 @@
"use strict";
var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
var _typeof = require("@babel/runtime/helpers/typeof");
Object.defineProperty(exports, "__esModule", {
value: true
});
exports.default = exports.Checkbox = void 0;
var _extends2 = _interopRequireDefault(require("@babel/runtime/helpers/extends"));
var _objectSpread2 = _interopRequireDefault(require("@babel/runtime/helpers/objectSpread2"));
var _defineProperty2 = _interopRequireDefault(require("@babel/runtime/helpers/defineProperty"));
var _slicedToArray2 = _interopRequireDefault(require("@babel/runtime/helpers/slicedToArray"));
var _objectWithoutProperties2 = _interopRequireDefault(require("@babel/runtime/helpers/objectWithoutProperties"));
var _classnames = _interopRequireDefault(require("classnames"));
var _useMergedState3 = _interopRequireDefault(require("rc-util/lib/hooks/useMergedState"));
var _react = _interopRequireWildcard(require("react"));
var React = _react;
var _excluded = ["prefixCls", "className", "style", "checked", "disabled", "defaultChecked", "type", "title", "onChange"];
function _getRequireWildcardCache(e) { if ("function" != typeof WeakMap) return null; var r = new WeakMap(), t = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(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; }
var Checkbox = exports.Checkbox = /*#__PURE__*/(0, _react.forwardRef)(function (props, ref) {
var _props$prefixCls = props.prefixCls,
prefixCls = _props$prefixCls === void 0 ? 'rc-checkbox' : _props$prefixCls,
className = props.className,
style = props.style,
checked = props.checked,
disabled = props.disabled,
_props$defaultChecked = props.defaultChecked,
defaultChecked = _props$defaultChecked === void 0 ? false : _props$defaultChecked,
_props$type = props.type,
type = _props$type === void 0 ? 'checkbox' : _props$type,
title = props.title,
onChange = props.onChange,
inputProps = (0, _objectWithoutProperties2.default)(props, _excluded);
var inputRef = (0, _react.useRef)(null);
var holderRef = (0, _react.useRef)(null);
var _useMergedState = (0, _useMergedState3.default)(defaultChecked, {
value: checked
}),
_useMergedState2 = (0, _slicedToArray2.default)(_useMergedState, 2),
rawValue = _useMergedState2[0],
setRawValue = _useMergedState2[1];
(0, _react.useImperativeHandle)(ref, function () {
return {
focus: function focus(options) {
var _inputRef$current;
(_inputRef$current = inputRef.current) === null || _inputRef$current === void 0 || _inputRef$current.focus(options);
},
blur: function blur() {
var _inputRef$current2;
(_inputRef$current2 = inputRef.current) === null || _inputRef$current2 === void 0 || _inputRef$current2.blur();
},
input: inputRef.current,
nativeElement: holderRef.current
};
});
var classString = (0, _classnames.default)(prefixCls, className, (0, _defineProperty2.default)((0, _defineProperty2.default)({}, "".concat(prefixCls, "-checked"), rawValue), "".concat(prefixCls, "-disabled"), disabled));
var handleChange = function handleChange(e) {
if (disabled) {
return;
}
if (!('checked' in props)) {
setRawValue(e.target.checked);
}
onChange === null || onChange === void 0 || onChange({
target: (0, _objectSpread2.default)((0, _objectSpread2.default)({}, props), {}, {
type: type,
checked: e.target.checked
}),
stopPropagation: function stopPropagation() {
e.stopPropagation();
},
preventDefault: function preventDefault() {
e.preventDefault();
},
nativeEvent: e.nativeEvent
});
};
return /*#__PURE__*/React.createElement("span", {
className: classString,
title: title,
style: style,
ref: holderRef
}, /*#__PURE__*/React.createElement("input", (0, _extends2.default)({}, inputProps, {
className: "".concat(prefixCls, "-input"),
ref: inputRef,
onChange: handleChange,
disabled: disabled,
checked: !!rawValue,
type: type
})), /*#__PURE__*/React.createElement("span", {
className: "".concat(prefixCls, "-inner")
}));
});
var _default = exports.default = Checkbox;

84
node_modules/rc-checkbox/package.json generated vendored Normal file
View File

@@ -0,0 +1,84 @@
{
"name": "rc-checkbox",
"version": "3.5.0",
"description": "checkbox ui component for react",
"keywords": [
"react",
"react-component",
"react-checkbox",
"checkbox"
],
"homepage": "http://github.com/react-component/checkbox",
"bugs": {
"url": "http://github.com/react-component/checkbox/issues"
},
"repository": {
"type": "git",
"url": "git@github.com:react-component/checkbox.git"
},
"license": "MIT",
"main": "lib/index.js",
"module": "es/index.js",
"typings": "es/index.d.ts",
"files": [
"assets/*.css",
"es",
"lib"
],
"scripts": {
"build": "dumi build",
"compile": "father build && lessc assets/index.less assets/index.css",
"coverage": "jest --coverage",
"gh-pages": "npm run build && father doc deploy -d .docs",
"lint": "eslint src/ --ext .tsx,.ts",
"prepare": "husky install && dumi setup",
"prepublishOnly": "npm run compile && np --yolo --no-publish",
"start": "dumi dev",
"test": "jest"
},
"lint-staged": {
"*.{js,jsx,less,md,json}": [
"prettier --write"
],
"*.ts?(x)": [
"prettier --parser=typescript --write"
]
},
"dependencies": {
"@babel/runtime": "^7.10.1",
"classnames": "^2.3.2",
"rc-util": "^5.25.2"
},
"devDependencies": {
"@rc-component/father-plugin": "^1.0.1",
"@testing-library/react": "^14.1.2 ",
"@testing-library/jest-dom": "^6.1.5",
"@testing-library/user-event": "^14.4.3",
"@types/classnames": "^2.3.1",
"@types/jest": "^29.2.4",
"@types/react": "^18.0.26",
"@types/react-dom": "^18.0.9",
"@umijs/fabric": "^4.0.1",
"@umijs/test": "^4.0.34",
"coveralls": "^3.0.6",
"dumi": "^2.0.12",
"eslint": "^8.55.0",
"eslint-plugin-jest": "^27.6.0",
"eslint-plugin-unicorn": "^50.0.1",
"father": "^4.1.1",
"husky": "9.0.5",
"jest": "^29.3.1",
"jest-environment-jsdom": "^29.3.1",
"less": "^4.2.0",
"lint-staged": "^15.1.0",
"np": "^9.0.0",
"react": "^18.2.0",
"react-dom": "^18.2.0",
"ts-node": "^10.9.1",
"typescript": "^5.2.2"
},
"peerDependencies": {
"react": ">=16.9.0",
"react-dom": ">=16.9.0"
}
}