@veritone-ce/design-system 1.12.28 → 1.12.29
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/assets/theme.d.ts +13 -11
- package/dist/assets/theme.js +53 -42
- package/dist/components/Alert/index.d.ts +22 -0
- package/dist/components/Alert/index.js +62 -0
- package/dist/components/AudioSlider/index.d.ts +12 -0
- package/dist/components/AudioSlider/index.js +73 -0
- package/dist/components/Box/index.d.ts +9 -4
- package/dist/components/Box/index.js +11 -10
- package/dist/components/Breadcrumbs/index.d.ts +6 -3
- package/dist/components/Breadcrumbs/index.js +15 -13
- package/dist/components/Button/Indicator.js +6 -4
- package/dist/components/Button/index.d.ts +14 -5
- package/dist/components/Button/index.js +27 -26
- package/dist/components/Checkbox/index.d.ts +10 -3
- package/dist/components/Checkbox/index.js +11 -14
- package/dist/components/Drawer/index.d.ts +12 -4
- package/dist/components/Drawer/index.js +12 -10
- package/dist/components/FileUploader/index.d.ts +21 -8
- package/dist/components/FileUploader/index.js +70 -102
- package/dist/components/FileUploader/useUploadFile.d.ts +1 -1
- package/dist/components/FileUploader/useUploadFile.js +10 -9
- package/dist/components/FormControlLabel/index.d.ts +9 -4
- package/dist/components/FormControlLabel/index.js +11 -10
- package/dist/components/Input/index.d.ts +22 -4
- package/dist/components/Input/index.js +27 -13
- package/dist/components/LinearProgress/index.d.ts +9 -4
- package/dist/components/LinearProgress/index.js +9 -37
- package/dist/components/Link/index.d.ts +7 -4
- package/dist/components/Link/index.js +13 -4
- package/dist/components/List/index.d.ts +8 -4
- package/dist/components/List/index.js +10 -10
- package/dist/components/ListItem/index.d.ts +8 -4
- package/dist/components/ListItem/index.js +10 -10
- package/dist/components/ListItemButton/index.d.ts +10 -4
- package/dist/components/ListItemButton/index.js +12 -10
- package/dist/components/ListItemText/index.d.ts +8 -4
- package/dist/components/ListItemText/index.js +10 -10
- package/dist/components/MenuFlyout/index.d.ts +11 -5
- package/dist/components/MenuFlyout/index.js +9 -19
- package/dist/components/Modal/index.d.ts +7 -4
- package/dist/components/Modal/index.js +10 -21
- package/dist/components/Panel/index.d.ts +7 -6
- package/dist/components/Panel/index.js +7 -16
- package/dist/components/ProgressIndicator/DefaultProgress.d.ts +2 -2
- package/dist/components/ProgressIndicator/DefaultProgress.js +10 -15
- package/dist/components/ProgressIndicator/MLProgress.d.ts +5 -2
- package/dist/components/ProgressIndicator/MLProgress.js +9 -14
- package/dist/components/ProgressIndicator/index.d.ts +13 -4
- package/dist/components/ProgressIndicator/index.js +4 -2
- package/dist/components/RadioButton/index.d.ts +15 -5
- package/dist/components/RadioButton/index.js +12 -17
- package/dist/components/RadioGroup/index.d.ts +28 -4
- package/dist/components/RadioGroup/index.js +13 -10
- package/dist/components/Select/index.d.ts +35 -9
- package/dist/components/Select/index.js +29 -30
- package/dist/components/StatusChip/index.d.ts +10 -8
- package/dist/components/StatusChip/index.js +12 -16
- package/dist/components/Step/index.d.ts +21 -4
- package/dist/components/Step/index.js +12 -11
- package/dist/components/StepLabel/index.d.ts +11 -4
- package/dist/components/StepLabel/index.js +10 -10
- package/dist/components/Stepper/index.d.ts +16 -7
- package/dist/components/Stepper/index.js +9 -11
- package/dist/components/Table/index.d.ts +85 -0
- package/dist/components/Table/index.js +123 -0
- package/dist/components/Tabs/index.d.ts +10 -6
- package/dist/components/Tabs/index.js +40 -48
- package/dist/components/ThemeProvider/index.d.ts +8 -2
- package/dist/components/ThemeProvider/index.js +12 -6
- package/dist/components/Toast/index.d.ts +5 -21
- package/dist/components/Toast/index.js +17 -51
- package/dist/components/Typography/index.d.ts +9 -3
- package/dist/components/Typography/index.js +10 -11
- package/dist/components/UtilityRail/index.d.ts +4 -3
- package/dist/components/UtilityRail/index.js +10 -18
- package/dist/components/ZeroState/index.d.ts +2 -0
- package/dist/components/ZeroState/index.js +25 -0
- package/dist/components/icons/HomeOutlinedIcon/index.d.ts +5 -0
- package/dist/components/icons/HomeOutlinedIcon/index.js +15 -0
- package/dist/components/icons/IconGroups/index.d.ts +5 -0
- package/dist/components/icons/IconGroups/index.js +16 -0
- package/dist/components/icons/IconListItem/index.d.ts +7 -0
- package/dist/components/icons/IconListItem/index.js +17 -0
- package/dist/index.d.ts +57 -23
- package/dist/index.js +85 -38
- package/package.json +4 -3
- package/dist/components/Button/useButtonProps.d.ts +0 -3
- package/dist/components/Button/useButtonProps.js +0 -26
- package/dist/components/CustomSlider/index.d.ts +0 -12
- package/dist/components/CustomSlider/index.js +0 -89
- package/dist/components/HomeOutlinedIcon/index.d.ts +0 -5
- package/dist/components/HomeOutlinedIcon/index.js +0 -22
- package/dist/components/IconGroups/index.d.ts +0 -5
- package/dist/components/IconGroups/index.js +0 -23
- package/dist/components/IconListItem/index.d.ts +0 -7
- package/dist/components/IconListItem/index.js +0 -27
- package/dist/components/ModelGridView/index.d.ts +0 -15
- package/dist/components/ModelGridView/index.js +0 -330
- package/dist/components/Tabs/Badge.d.ts +0 -7
- package/dist/components/Tabs/Badge.js +0 -29
|
@@ -1,20 +1,13 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
|
|
3
|
-
function _typeof(obj) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) { return typeof obj; } : function (obj) { return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }, _typeof(obj); }
|
|
4
3
|
Object.defineProperty(exports, "__esModule", {
|
|
5
4
|
value: true
|
|
6
5
|
});
|
|
7
6
|
exports["default"] = void 0;
|
|
8
7
|
var _material = require("@mui/material");
|
|
8
|
+
var _react = _interopRequireDefault(require("react"));
|
|
9
9
|
var _jsxRuntime = require("react/jsx-runtime");
|
|
10
|
-
|
|
11
|
-
function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
|
|
12
|
-
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { _defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
|
|
13
|
-
function _defineProperty(obj, key, value) { key = _toPropertyKey(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
14
|
-
function _toPropertyKey(arg) { var key = _toPrimitive(arg, "string"); return _typeof(key) === "symbol" ? key : String(key); }
|
|
15
|
-
function _toPrimitive(input, hint) { if (_typeof(input) !== "object" || input === null) return input; var prim = input[Symbol.toPrimitive]; if (prim !== undefined) { var res = prim.call(input, hint || "default"); if (_typeof(res) !== "object") return res; throw new TypeError("@@toPrimitive must return a primitive value."); } return (hint === "string" ? String : Number)(input); }
|
|
16
|
-
function _objectWithoutProperties(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }
|
|
17
|
-
function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }
|
|
10
|
+
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
18
11
|
/**
|
|
19
12
|
- Use a StatusChip to display the status of some action to the user.
|
|
20
13
|
- Veritone stock options derive from the required `status` prop and include Complete, Processing, or Error. Their corresponding colors derive from Veritone's Design System guidelines.
|
|
@@ -26,18 +19,21 @@ function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) r
|
|
|
26
19
|
- Pass an MUI stock color option to `color` prop **OR** pass a custom color Hex Value to `coloroverride` prop.
|
|
27
20
|
**/
|
|
28
21
|
|
|
29
|
-
var StatusChip = function StatusChip(
|
|
30
|
-
var label = _ref.label,
|
|
31
|
-
props = _objectWithoutProperties(_ref, _excluded);
|
|
22
|
+
var StatusChip = function StatusChip(props) {
|
|
32
23
|
return /*#__PURE__*/(0, _jsxRuntime.jsx)(_material.Box, {
|
|
33
24
|
sx: {
|
|
34
25
|
display: "inline-flex",
|
|
35
26
|
position: "relative"
|
|
36
27
|
},
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
"data-testid":
|
|
40
|
-
|
|
28
|
+
className: props.className,
|
|
29
|
+
children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_material.Chip, {
|
|
30
|
+
"data-testid": props['data-testid'],
|
|
31
|
+
label: props.label ? props.label : props.status,
|
|
32
|
+
color: props.color,
|
|
33
|
+
clickable: props.clickable,
|
|
34
|
+
disabled: props.disabled,
|
|
35
|
+
onClick: props.onClick
|
|
36
|
+
})
|
|
41
37
|
});
|
|
42
38
|
};
|
|
43
39
|
var _default = StatusChip;
|
|
@@ -1,6 +1,23 @@
|
|
|
1
|
-
import
|
|
2
|
-
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { SxProps, Theme } from '@mui/system';
|
|
3
|
+
export type StepProps = {
|
|
3
4
|
'data-testid'?: string;
|
|
4
|
-
|
|
5
|
-
|
|
5
|
+
/**
|
|
6
|
+
* Sets the step as active. Is passed to child components.
|
|
7
|
+
*/
|
|
8
|
+
active?: boolean;
|
|
9
|
+
/**
|
|
10
|
+
* Mark the step as completed. Is passed to child components.
|
|
11
|
+
*/
|
|
12
|
+
completed?: boolean;
|
|
13
|
+
/**
|
|
14
|
+
* If `true`, the step is disabled, will also disable the button if
|
|
15
|
+
* `StepButton` is a child of `Step`. Is passed to child components.
|
|
16
|
+
*/
|
|
17
|
+
disabled?: boolean;
|
|
18
|
+
children?: React.ReactNode;
|
|
19
|
+
sx?: SxProps<Theme>;
|
|
20
|
+
className?: string;
|
|
21
|
+
};
|
|
22
|
+
declare const Step: (props: StepProps) => import("react/jsx-runtime").JSX.Element;
|
|
6
23
|
export default Step;
|
|
@@ -1,22 +1,23 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
|
|
3
|
-
function _typeof(obj) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) { return typeof obj; } : function (obj) { return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }, _typeof(obj); }
|
|
4
3
|
Object.defineProperty(exports, "__esModule", {
|
|
5
4
|
value: true
|
|
6
5
|
});
|
|
7
6
|
exports["default"] = void 0;
|
|
8
7
|
var _material = require("@mui/material");
|
|
8
|
+
var _react = _interopRequireDefault(require("react"));
|
|
9
9
|
var _jsxRuntime = require("react/jsx-runtime");
|
|
10
|
-
function
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
10
|
+
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
11
|
+
var Step = function Step(props) {
|
|
12
|
+
return /*#__PURE__*/(0, _jsxRuntime.jsx)(_material.Step, {
|
|
13
|
+
"data-testid": props['data-testid'],
|
|
14
|
+
active: props.active,
|
|
15
|
+
completed: props.completed,
|
|
16
|
+
disabled: props.disabled,
|
|
17
|
+
sx: props.sx,
|
|
18
|
+
className: props.className,
|
|
19
|
+
children: props.children
|
|
20
|
+
});
|
|
20
21
|
};
|
|
21
22
|
var _default = Step;
|
|
22
23
|
exports["default"] = _default;
|
|
@@ -1,6 +1,13 @@
|
|
|
1
|
-
import
|
|
2
|
-
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
import { SxProps, Theme } from '@mui/system';
|
|
3
|
+
export type StepLabelProps = {
|
|
3
4
|
'data-testid'?: string;
|
|
4
|
-
|
|
5
|
-
|
|
5
|
+
/**
|
|
6
|
+
* In most cases will simply be a string containing a title for the label.
|
|
7
|
+
*/
|
|
8
|
+
children?: React.ReactNode;
|
|
9
|
+
sx?: SxProps<Theme>;
|
|
10
|
+
className?: string;
|
|
11
|
+
};
|
|
12
|
+
declare const StepLabel: (props: StepLabelProps) => import("react/jsx-runtime").JSX.Element;
|
|
6
13
|
export default StepLabel;
|
|
@@ -6,17 +6,17 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
6
6
|
});
|
|
7
7
|
exports["default"] = void 0;
|
|
8
8
|
var _material = require("@mui/material");
|
|
9
|
+
var React = _interopRequireWildcard(require("react"));
|
|
9
10
|
var _jsxRuntime = require("react/jsx-runtime");
|
|
10
|
-
function
|
|
11
|
-
function
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
return /*#__PURE__*/(0, _jsxRuntime.jsx)(_material.StepLabel, _objectSpread({}, props));
|
|
11
|
+
function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
|
|
12
|
+
function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || _typeof(obj) !== "object" && typeof obj !== "function") { return { "default": obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj["default"] = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
|
|
13
|
+
var StepLabel = function StepLabel(props) {
|
|
14
|
+
return /*#__PURE__*/(0, _jsxRuntime.jsx)(_material.StepLabel, {
|
|
15
|
+
"data-testid": props['data-testid'],
|
|
16
|
+
sx: props.sx,
|
|
17
|
+
className: props.className,
|
|
18
|
+
children: props.children
|
|
19
|
+
});
|
|
20
20
|
};
|
|
21
21
|
var _default = StepLabel;
|
|
22
22
|
exports["default"] = _default;
|
|
@@ -1,13 +1,22 @@
|
|
|
1
|
-
import
|
|
2
|
-
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { SxProps, Theme } from '@mui/system';
|
|
3
|
+
export type StepperProps = {
|
|
3
4
|
'data-testid'?: string;
|
|
4
|
-
|
|
5
|
+
/**
|
|
6
|
+
* Set the active step (zero based index).
|
|
7
|
+
* Set to -1 to disable all the steps.
|
|
8
|
+
* @default 0
|
|
9
|
+
*/
|
|
10
|
+
activeStep?: number;
|
|
11
|
+
/**
|
|
12
|
+
* Two or more `<Step />` components.
|
|
13
|
+
*/
|
|
14
|
+
children?: React.ReactNode;
|
|
15
|
+
sx?: SxProps<Theme>;
|
|
16
|
+
className?: string;
|
|
17
|
+
};
|
|
5
18
|
/**
|
|
6
19
|
The Stepper is used for highlighting where a user is in a progression of steps.
|
|
7
|
-
For additional information see:
|
|
8
|
-
https://mui.com/material-ui/react-stepper/ ,
|
|
9
|
-
https://mui.com/material-ui/api/step/ ,
|
|
10
|
-
https://mui.com/material-ui/api/step-label/ .
|
|
11
20
|
**/
|
|
12
21
|
declare const Stepper: (props: StepperProps) => import("react/jsx-runtime").JSX.Element;
|
|
13
22
|
export default Stepper;
|
|
@@ -5,23 +5,21 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
5
5
|
});
|
|
6
6
|
exports["default"] = void 0;
|
|
7
7
|
var _material = require("@mui/material");
|
|
8
|
+
var _react = _interopRequireDefault(require("react"));
|
|
8
9
|
var _jsxRuntime = require("react/jsx-runtime");
|
|
9
|
-
function
|
|
10
|
-
function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
|
|
11
|
-
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { _defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
|
|
12
|
-
function _defineProperty(obj, key, value) { key = _toPropertyKey(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
13
|
-
function _toPropertyKey(arg) { var key = _toPrimitive(arg, "string"); return _typeof(key) === "symbol" ? key : String(key); }
|
|
14
|
-
function _toPrimitive(input, hint) { if (_typeof(input) !== "object" || input === null) return input; var prim = input[Symbol.toPrimitive]; if (prim !== undefined) { var res = prim.call(input, hint || "default"); if (_typeof(res) !== "object") return res; throw new TypeError("@@toPrimitive must return a primitive value."); } return (hint === "string" ? String : Number)(input); }
|
|
10
|
+
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
15
11
|
/**
|
|
16
12
|
The Stepper is used for highlighting where a user is in a progression of steps.
|
|
17
|
-
For additional information see:
|
|
18
|
-
https://mui.com/material-ui/react-stepper/ ,
|
|
19
|
-
https://mui.com/material-ui/api/step/ ,
|
|
20
|
-
https://mui.com/material-ui/api/step-label/ .
|
|
21
13
|
**/
|
|
22
14
|
|
|
23
15
|
var Stepper = function Stepper(props) {
|
|
24
|
-
return /*#__PURE__*/(0, _jsxRuntime.jsx)(_material.Stepper,
|
|
16
|
+
return /*#__PURE__*/(0, _jsxRuntime.jsx)(_material.Stepper, {
|
|
17
|
+
"data-testid": props['data-testid'],
|
|
18
|
+
activeStep: props.activeStep,
|
|
19
|
+
sx: props.sx,
|
|
20
|
+
className: props.className,
|
|
21
|
+
children: props.children
|
|
22
|
+
});
|
|
25
23
|
};
|
|
26
24
|
var _default = Stepper;
|
|
27
25
|
exports["default"] = _default;
|
|
@@ -0,0 +1,85 @@
|
|
|
1
|
+
import { TablePaginationProps as MuiTablePaginationProps, TableSortLabelProps as MuiTableSortLabelProps } from '@mui/material';
|
|
2
|
+
import React from 'react';
|
|
3
|
+
import { SxProps, Theme } from '@mui/system';
|
|
4
|
+
export type TableProps = {
|
|
5
|
+
'data-testid'?: string;
|
|
6
|
+
/**
|
|
7
|
+
* Set the header sticky.
|
|
8
|
+
*
|
|
9
|
+
* ⚠️ It doesn't work with IE11.
|
|
10
|
+
* @default false
|
|
11
|
+
*/
|
|
12
|
+
stickyHeader?: boolean;
|
|
13
|
+
children?: React.ReactNode;
|
|
14
|
+
sx?: SxProps<Theme>;
|
|
15
|
+
className?: string;
|
|
16
|
+
};
|
|
17
|
+
export declare const Table: (props: TableProps) => import("react/jsx-runtime").JSX.Element;
|
|
18
|
+
export type TableBodyProps = {
|
|
19
|
+
'data-testid'?: string;
|
|
20
|
+
children?: React.ReactNode;
|
|
21
|
+
sx?: SxProps<Theme>;
|
|
22
|
+
className?: string;
|
|
23
|
+
};
|
|
24
|
+
export declare const TableBody: (props: TableBodyProps) => import("react/jsx-runtime").JSX.Element;
|
|
25
|
+
export type TableCellProps = {
|
|
26
|
+
'data-testid'?: string;
|
|
27
|
+
variant?: 'header' | 'data';
|
|
28
|
+
align?: 'left' | 'center' | 'right' | 'justify' | 'inherit';
|
|
29
|
+
colSpan?: number;
|
|
30
|
+
headers?: string;
|
|
31
|
+
rowSpan?: number;
|
|
32
|
+
scope?: string;
|
|
33
|
+
abbr?: string;
|
|
34
|
+
sortDirection?: 'asc' | 'desc' | false;
|
|
35
|
+
children?: React.ReactNode;
|
|
36
|
+
sx?: SxProps<Theme>;
|
|
37
|
+
className?: string;
|
|
38
|
+
};
|
|
39
|
+
export declare const TableCell: ({ variant, ...props }: TableCellProps) => import("react/jsx-runtime").JSX.Element;
|
|
40
|
+
export type TableContainerProps = {
|
|
41
|
+
'data-testid'?: string;
|
|
42
|
+
children?: React.ReactNode;
|
|
43
|
+
sx?: SxProps<Theme>;
|
|
44
|
+
className?: string;
|
|
45
|
+
};
|
|
46
|
+
export declare const TableContainer: (props: TableContainerProps) => import("react/jsx-runtime").JSX.Element;
|
|
47
|
+
export type TableFooterProps = {
|
|
48
|
+
'data-testid'?: string;
|
|
49
|
+
children?: React.ReactNode;
|
|
50
|
+
sx?: SxProps<Theme>;
|
|
51
|
+
className?: string;
|
|
52
|
+
};
|
|
53
|
+
export declare const TableFooter: (props: TableFooterProps) => import("react/jsx-runtime").JSX.Element;
|
|
54
|
+
export type TableHeadProps = {
|
|
55
|
+
'data-testid'?: string;
|
|
56
|
+
children?: React.ReactNode;
|
|
57
|
+
sx?: SxProps<Theme>;
|
|
58
|
+
className?: string;
|
|
59
|
+
};
|
|
60
|
+
export declare const TableHead: (props: TableHeadProps) => import("react/jsx-runtime").JSX.Element;
|
|
61
|
+
export type TablePaginationProps = {
|
|
62
|
+
'data-testid'?: string;
|
|
63
|
+
} & MuiTablePaginationProps;
|
|
64
|
+
export declare const TablePagination: (props: TablePaginationProps) => import("react/jsx-runtime").JSX.Element;
|
|
65
|
+
export type TableRowProps = {
|
|
66
|
+
'data-testid'?: string;
|
|
67
|
+
children?: React.ReactNode;
|
|
68
|
+
/**
|
|
69
|
+
* If `true`, the table row will shade on hover.
|
|
70
|
+
* @default false
|
|
71
|
+
*/
|
|
72
|
+
hover?: boolean;
|
|
73
|
+
/**
|
|
74
|
+
* If `true`, the table row will have the selected shading.
|
|
75
|
+
* @default false
|
|
76
|
+
*/
|
|
77
|
+
selected?: boolean;
|
|
78
|
+
sx?: SxProps<Theme>;
|
|
79
|
+
className?: string;
|
|
80
|
+
};
|
|
81
|
+
export declare const TableRow: (props: TableRowProps) => import("react/jsx-runtime").JSX.Element;
|
|
82
|
+
export type TableSortLabelProps = {
|
|
83
|
+
'data-testid'?: string;
|
|
84
|
+
} & MuiTableSortLabelProps;
|
|
85
|
+
export declare const TableSortLabel: (props: TableSortLabelProps) => import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1,123 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
function _typeof(obj) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) { return typeof obj; } : function (obj) { return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }, _typeof(obj); }
|
|
4
|
+
Object.defineProperty(exports, "__esModule", {
|
|
5
|
+
value: true
|
|
6
|
+
});
|
|
7
|
+
exports.TableSortLabel = exports.TableRow = exports.TablePagination = exports.TableHead = exports.TableFooter = exports.TableContainer = exports.TableCell = exports.TableBody = exports.Table = void 0;
|
|
8
|
+
var _material = require("@mui/material");
|
|
9
|
+
var _react = _interopRequireDefault(require("react"));
|
|
10
|
+
var _styles = require("@mui/material/styles");
|
|
11
|
+
var _jsxRuntime = require("react/jsx-runtime");
|
|
12
|
+
var _excluded = ["variant"];
|
|
13
|
+
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
14
|
+
function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
|
|
15
|
+
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { _defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
|
|
16
|
+
function _defineProperty(obj, key, value) { key = _toPropertyKey(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
17
|
+
function _toPropertyKey(arg) { var key = _toPrimitive(arg, "string"); return _typeof(key) === "symbol" ? key : String(key); }
|
|
18
|
+
function _toPrimitive(input, hint) { if (_typeof(input) !== "object" || input === null) return input; var prim = input[Symbol.toPrimitive]; if (prim !== undefined) { var res = prim.call(input, hint || "default"); if (_typeof(res) !== "object") return res; throw new TypeError("@@toPrimitive must return a primitive value."); } return (hint === "string" ? String : Number)(input); }
|
|
19
|
+
function _objectWithoutProperties(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }
|
|
20
|
+
function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }
|
|
21
|
+
var Table = function Table(props) {
|
|
22
|
+
return /*#__PURE__*/(0, _jsxRuntime.jsx)(_material.Table, {
|
|
23
|
+
"data-testid": props['data-testid'],
|
|
24
|
+
stickyHeader: props.stickyHeader,
|
|
25
|
+
sx: props.sx,
|
|
26
|
+
className: props.className,
|
|
27
|
+
children: props.children
|
|
28
|
+
});
|
|
29
|
+
};
|
|
30
|
+
exports.Table = Table;
|
|
31
|
+
var TableBody = function TableBody(props) {
|
|
32
|
+
return /*#__PURE__*/(0, _jsxRuntime.jsx)(_material.TableBody, {
|
|
33
|
+
"data-testid": props['data-testid'],
|
|
34
|
+
sx: props.sx,
|
|
35
|
+
className: props.className,
|
|
36
|
+
children: props.children
|
|
37
|
+
});
|
|
38
|
+
};
|
|
39
|
+
exports.TableBody = TableBody;
|
|
40
|
+
var TableCell = function TableCell(_ref) {
|
|
41
|
+
var _ref$variant = _ref.variant,
|
|
42
|
+
variant = _ref$variant === void 0 ? 'data' : _ref$variant,
|
|
43
|
+
props = _objectWithoutProperties(_ref, _excluded);
|
|
44
|
+
return /*#__PURE__*/(0, _jsxRuntime.jsx)(_material.TableCell, {
|
|
45
|
+
"data-testid": props['data-testid'],
|
|
46
|
+
component: variant === 'header' ? 'th' : 'td',
|
|
47
|
+
align: props.align,
|
|
48
|
+
colSpan: props.colSpan,
|
|
49
|
+
headers: props.headers,
|
|
50
|
+
rowSpan: props.rowSpan,
|
|
51
|
+
scope: props.scope,
|
|
52
|
+
abbr: props.abbr,
|
|
53
|
+
sortDirection: props.sortDirection,
|
|
54
|
+
sx: props.sx,
|
|
55
|
+
className: props.className,
|
|
56
|
+
children: props.children
|
|
57
|
+
});
|
|
58
|
+
};
|
|
59
|
+
exports.TableCell = TableCell;
|
|
60
|
+
var StyledMuiTableContainer = (0, _styles.styled)(_material.TableContainer)({
|
|
61
|
+
'& .MuiTableCell-root': {
|
|
62
|
+
lineHeight: '21px',
|
|
63
|
+
fontWeight: 400
|
|
64
|
+
}
|
|
65
|
+
});
|
|
66
|
+
var TableContainer = function TableContainer(props) {
|
|
67
|
+
return /*#__PURE__*/(0, _jsxRuntime.jsx)(StyledMuiTableContainer, {
|
|
68
|
+
"data-testid": props['data-testid'],
|
|
69
|
+
sx: props.sx,
|
|
70
|
+
className: props.className,
|
|
71
|
+
children: props.children
|
|
72
|
+
});
|
|
73
|
+
};
|
|
74
|
+
exports.TableContainer = TableContainer;
|
|
75
|
+
var TableFooter = function TableFooter(props) {
|
|
76
|
+
return /*#__PURE__*/(0, _jsxRuntime.jsx)(_material.TableFooter, {
|
|
77
|
+
"data-testid": props['data-testid'],
|
|
78
|
+
sx: props.sx,
|
|
79
|
+
className: props.className,
|
|
80
|
+
children: props.children
|
|
81
|
+
});
|
|
82
|
+
};
|
|
83
|
+
exports.TableFooter = TableFooter;
|
|
84
|
+
var TableHead = function TableHead(props) {
|
|
85
|
+
return /*#__PURE__*/(0, _jsxRuntime.jsx)(_material.TableHead, {
|
|
86
|
+
"data-testid": props['data-testid'],
|
|
87
|
+
sx: props.sx,
|
|
88
|
+
className: props.className,
|
|
89
|
+
children: props.children
|
|
90
|
+
});
|
|
91
|
+
};
|
|
92
|
+
exports.TableHead = TableHead;
|
|
93
|
+
var TablePagination = function TablePagination(props) {
|
|
94
|
+
return /*#__PURE__*/(0, _jsxRuntime.jsx)(_material.TablePagination, _objectSpread({}, props));
|
|
95
|
+
};
|
|
96
|
+
exports.TablePagination = TablePagination;
|
|
97
|
+
var StyledMuiTableRow = (0, _styles.styled)(_material.TableRow)(function (_ref2) {
|
|
98
|
+
var theme = _ref2.theme;
|
|
99
|
+
return {
|
|
100
|
+
'& .MuiTableCell-root': {
|
|
101
|
+
borderBottomColor: theme.palette.text.disabled,
|
|
102
|
+
padding: '14.25px 16px',
|
|
103
|
+
'&.MuiTableCell-paddingNone': {
|
|
104
|
+
padding: 0
|
|
105
|
+
}
|
|
106
|
+
}
|
|
107
|
+
};
|
|
108
|
+
});
|
|
109
|
+
var TableRow = function TableRow(props) {
|
|
110
|
+
return /*#__PURE__*/(0, _jsxRuntime.jsx)(StyledMuiTableRow, {
|
|
111
|
+
"data-testid": props['data-testid'],
|
|
112
|
+
hover: props.hover,
|
|
113
|
+
selected: props.selected,
|
|
114
|
+
sx: props.sx,
|
|
115
|
+
className: props.className,
|
|
116
|
+
children: props.children
|
|
117
|
+
});
|
|
118
|
+
};
|
|
119
|
+
exports.TableRow = TableRow;
|
|
120
|
+
var TableSortLabel = function TableSortLabel(props) {
|
|
121
|
+
return /*#__PURE__*/(0, _jsxRuntime.jsx)(_material.TableSortLabel, _objectSpread({}, props));
|
|
122
|
+
};
|
|
123
|
+
exports.TableSortLabel = TableSortLabel;
|
|
@@ -1,12 +1,16 @@
|
|
|
1
|
-
import {
|
|
2
|
-
|
|
1
|
+
import { SxProps, Theme } from '@mui/system';
|
|
2
|
+
import * as React from 'react';
|
|
3
|
+
export type Tab = {
|
|
3
4
|
'data-testid'?: string;
|
|
4
5
|
label: string;
|
|
5
6
|
count?: number;
|
|
6
|
-
content?: string;
|
|
7
7
|
};
|
|
8
8
|
export type BasicTabsProps = {
|
|
9
|
-
tabs:
|
|
9
|
+
tabs: Tab[];
|
|
10
|
+
value: number;
|
|
11
|
+
onChange?(event: React.SyntheticEvent, value: number): void;
|
|
12
|
+
sx?: SxProps<Theme>;
|
|
13
|
+
className?: string;
|
|
10
14
|
};
|
|
11
|
-
declare
|
|
12
|
-
export default
|
|
15
|
+
declare function Tabs(props: BasicTabsProps): import("react/jsx-runtime").JSX.Element;
|
|
16
|
+
export default Tabs;
|
|
@@ -5,54 +5,46 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
5
5
|
value: true
|
|
6
6
|
});
|
|
7
7
|
exports["default"] = void 0;
|
|
8
|
-
var _react = require("react");
|
|
9
8
|
var _material = require("@mui/material");
|
|
10
|
-
var
|
|
9
|
+
var React = _interopRequireWildcard(require("react"));
|
|
11
10
|
var _jsxRuntime = require("react/jsx-runtime");
|
|
12
|
-
|
|
13
|
-
function
|
|
14
|
-
function
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
_useState2 = _slicedToArray(_useState, 2),
|
|
32
|
-
selectedTab = _useState2[0],
|
|
33
|
-
setSelectedTab = _useState2[1];
|
|
34
|
-
var handleChange = function handleChange(event, newValue) {
|
|
35
|
-
setSelectedTab(newValue);
|
|
36
|
-
};
|
|
37
|
-
return /*#__PURE__*/(0, _jsxRuntime.jsxs)("div", {
|
|
38
|
-
children: [/*#__PURE__*/(0, _jsxRuntime.jsx)(_material.Tabs, _objectSpread(_objectSpread({
|
|
39
|
-
value: selectedTab,
|
|
40
|
-
onChange: handleChange
|
|
41
|
-
}, props), {}, {
|
|
42
|
-
children: tabs.map(function (tab, index) {
|
|
43
|
-
var _tab$count;
|
|
44
|
-
return /*#__PURE__*/(0, _react.createElement)(_material.Tab, _objectSpread(_objectSpread({}, tab), {}, {
|
|
45
|
-
key: index,
|
|
46
|
-
value: index,
|
|
47
|
-
label: /*#__PURE__*/(0, _jsxRuntime.jsx)(_Badge["default"], {
|
|
48
|
-
badgeCount: (_tab$count = tab.count) !== null && _tab$count !== void 0 ? _tab$count : 0,
|
|
49
|
-
label: tab.label
|
|
50
|
-
}),
|
|
51
|
-
disableRipple: true
|
|
52
|
-
}));
|
|
53
|
-
})
|
|
54
|
-
})), tabs[selectedTab].content && tabs[selectedTab].content]
|
|
11
|
+
function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
|
|
12
|
+
function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || _typeof(obj) !== "object" && typeof obj !== "function") { return { "default": obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj["default"] = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
|
|
13
|
+
function Tabs(props) {
|
|
14
|
+
return /*#__PURE__*/(0, _jsxRuntime.jsx)(_material.Tabs, {
|
|
15
|
+
value: props.value,
|
|
16
|
+
onChange: props.onChange,
|
|
17
|
+
sx: props.sx,
|
|
18
|
+
className: props.className,
|
|
19
|
+
children: props.tabs.map(function (tab, index) {
|
|
20
|
+
var _tab$count;
|
|
21
|
+
return /*#__PURE__*/(0, _jsxRuntime.jsx)(_material.Tab, {
|
|
22
|
+
value: index,
|
|
23
|
+
label: /*#__PURE__*/(0, _jsxRuntime.jsx)(BadgeLabel, {
|
|
24
|
+
count: (_tab$count = tab.count) !== null && _tab$count !== void 0 ? _tab$count : 0,
|
|
25
|
+
label: tab.label
|
|
26
|
+
}),
|
|
27
|
+
disableRipple: true
|
|
28
|
+
}, index);
|
|
29
|
+
})
|
|
55
30
|
});
|
|
56
|
-
}
|
|
57
|
-
var _default =
|
|
58
|
-
exports["default"] = _default;
|
|
31
|
+
}
|
|
32
|
+
var _default = Tabs;
|
|
33
|
+
exports["default"] = _default;
|
|
34
|
+
function BadgeLabel(props) {
|
|
35
|
+
return /*#__PURE__*/(0, _jsxRuntime.jsxs)(_material.Box, {
|
|
36
|
+
sx: {
|
|
37
|
+
display: 'flex',
|
|
38
|
+
alignItems: 'center',
|
|
39
|
+
justifyContent: 'center',
|
|
40
|
+
gap: 1.5
|
|
41
|
+
},
|
|
42
|
+
children: [/*#__PURE__*/(0, _jsxRuntime.jsx)(_material.Typography, {
|
|
43
|
+
variant: "body2",
|
|
44
|
+
children: props.label
|
|
45
|
+
}), /*#__PURE__*/(0, _jsxRuntime.jsx)(_material.Badge, {
|
|
46
|
+
badgeContent: props.count,
|
|
47
|
+
color: "primary"
|
|
48
|
+
})]
|
|
49
|
+
});
|
|
50
|
+
}
|
|
@@ -1,3 +1,9 @@
|
|
|
1
|
-
import {
|
|
2
|
-
|
|
1
|
+
import { Theme } from '@mui/system';
|
|
2
|
+
import React from 'react';
|
|
3
|
+
export declare const defaultTheme: import("@mui/material").Theme;
|
|
4
|
+
export type ThemeProviderProps = {
|
|
5
|
+
theme?: Theme;
|
|
6
|
+
children?: React.ReactNode;
|
|
7
|
+
};
|
|
8
|
+
declare const ThemeProvider: (props: ThemeProviderProps) => import("react/jsx-runtime").JSX.Element;
|
|
3
9
|
export default ThemeProvider;
|
|
@@ -3,16 +3,22 @@
|
|
|
3
3
|
Object.defineProperty(exports, "__esModule", {
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
|
-
exports["default"] = void 0;
|
|
6
|
+
exports.defaultTheme = exports["default"] = void 0;
|
|
7
7
|
var _system = require("@mui/system");
|
|
8
|
-
var _theme =
|
|
8
|
+
var _theme = require("../../assets/theme");
|
|
9
|
+
var _react = _interopRequireDefault(require("react"));
|
|
9
10
|
var _jsxRuntime = require("react/jsx-runtime");
|
|
10
11
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
11
|
-
var
|
|
12
|
-
|
|
12
|
+
var defaultTheme = (0, _theme.createDesignSystemTheme)();
|
|
13
|
+
exports.defaultTheme = defaultTheme;
|
|
14
|
+
var ThemeProvider = function ThemeProvider(props) {
|
|
15
|
+
var theme = _react["default"].useMemo(function () {
|
|
16
|
+
var _props$theme;
|
|
17
|
+
return (_props$theme = props.theme) !== null && _props$theme !== void 0 ? _props$theme : defaultTheme;
|
|
18
|
+
}, [props.theme]);
|
|
13
19
|
return /*#__PURE__*/(0, _jsxRuntime.jsx)(_system.ThemeProvider, {
|
|
14
|
-
theme:
|
|
15
|
-
children: children
|
|
20
|
+
theme: theme,
|
|
21
|
+
children: props.children
|
|
16
22
|
});
|
|
17
23
|
};
|
|
18
24
|
var _default = ThemeProvider;
|