You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
NewEduCoderBuild/20834.async.js

1540 lines
53 KiB

"use strict";
(self["webpackChunk"] = self["webpackChunk"] || []).push([[20834],{
/***/ 40875:
/*!******************************************************************!*\
!*** ./node_modules/_antd@5.9.0@antd/es/menu/OverrideContext.js ***!
\******************************************************************/
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) {
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */ J: function() { return /* binding */ OverrideProvider; }
/* harmony export */ });
/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! react */ 59301);
/* harmony import */ var _space_Compact__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../space/Compact */ 33234);
/* harmony import */ var rc_util__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! rc-util */ 70425);
"use client";
var __rest = undefined && undefined.__rest || function (s, e) {
var t = {};
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0) t[p] = s[p];
if (s != null && typeof Object.getOwnPropertySymbols === "function") for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i])) t[p[i]] = s[p[i]];
}
return t;
};
const OverrideContext = /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0__.createContext(null);
/** @internal Only used for Dropdown component. Do not use this in your production. */
const OverrideProvider = /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0__.forwardRef((props, ref) => {
const {
children
} = props,
restProps = __rest(props, ["children"]);
const override = react__WEBPACK_IMPORTED_MODULE_0__.useContext(OverrideContext);
const context = react__WEBPACK_IMPORTED_MODULE_0__.useMemo(() => Object.assign(Object.assign({}, override), restProps), [override, restProps.prefixCls,
// restProps.expandIcon, Not mark as deps since this is a ReactNode
restProps.mode, restProps.selectable
// restProps.validator, Not mark as deps since this is a function
]);
return /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0__.createElement(OverrideContext.Provider, {
value: context
}, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0__.createElement(_space_Compact__WEBPACK_IMPORTED_MODULE_2__/* .NoCompactStyle */ .BR, null, (0,rc_util__WEBPACK_IMPORTED_MODULE_1__.supportNodeRef)(children) ? /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0__.cloneElement(children, {
ref
}) : children));
});
/** @internal Only used for Dropdown component. Do not use this in your production. */
/* harmony default export */ __webpack_exports__.Z = (OverrideContext);
/***/ }),
/***/ 20834:
/*!*********************************************************************!*\
!*** ./node_modules/_antd@5.9.0@antd/es/menu/index.js + 11 modules ***!
\*********************************************************************/
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) {
// EXPORTS
__webpack_require__.d(__webpack_exports__, {
Z: function() { return /* binding */ es_menu; }
});
// EXTERNAL MODULE: ./node_modules/_rc-menu@9.12.4@rc-menu/es/index.js + 26 modules
var es = __webpack_require__(15285);
// EXTERNAL MODULE: ./node_modules/_react@17.0.2@react/index.js
var _react_17_0_2_react = __webpack_require__(59301);
// EXTERNAL MODULE: ./node_modules/_antd@5.9.0@antd/es/layout/Sider.js + 3 modules
var Sider = __webpack_require__(45818);
// EXTERNAL MODULE: ./node_modules/_classnames@2.5.1@classnames/index.js
var _classnames_2_5_1_classnames = __webpack_require__(92310);
var _classnames_2_5_1_classnames_default = /*#__PURE__*/__webpack_require__.n(_classnames_2_5_1_classnames);
// EXTERNAL MODULE: ./node_modules/_antd@5.9.0@antd/es/config-provider/context.js
var context = __webpack_require__(36355);
;// CONCATENATED MODULE: ./node_modules/_antd@5.9.0@antd/es/menu/MenuDivider.js
"use client";
var __rest = undefined && undefined.__rest || function (s, e) {
var t = {};
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0) t[p] = s[p];
if (s != null && typeof Object.getOwnPropertySymbols === "function") for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i])) t[p[i]] = s[p[i]];
}
return t;
};
const MenuDivider = props => {
const {
prefixCls: customizePrefixCls,
className,
dashed
} = props,
restProps = __rest(props, ["prefixCls", "className", "dashed"]);
const {
getPrefixCls
} = _react_17_0_2_react.useContext(context/* ConfigContext */.E_);
const prefixCls = getPrefixCls('menu', customizePrefixCls);
const classString = _classnames_2_5_1_classnames_default()({
[`${prefixCls}-item-divider-dashed`]: !!dashed
}, className);
return /*#__PURE__*/_react_17_0_2_react.createElement(es/* Divider */.iz, Object.assign({
className: classString
}, restProps));
};
/* harmony default export */ var menu_MenuDivider = (MenuDivider);
// EXTERNAL MODULE: ./node_modules/_rc-util@5.44.4@rc-util/es/Children/toArray.js
var toArray = __webpack_require__(11592);
// EXTERNAL MODULE: ./node_modules/_rc-util@5.44.4@rc-util/es/omit.js
var omit = __webpack_require__(2738);
// EXTERNAL MODULE: ./node_modules/_antd@5.9.0@antd/es/tooltip/index.js + 3 modules
var tooltip = __webpack_require__(6848);
// EXTERNAL MODULE: ./node_modules/_antd@5.9.0@antd/es/_util/reactNode.js
var reactNode = __webpack_require__(92343);
;// CONCATENATED MODULE: ./node_modules/_antd@5.9.0@antd/es/menu/MenuContext.js
"use client";
const MenuContext = /*#__PURE__*/(0,_react_17_0_2_react.createContext)({
prefixCls: '',
firstLevel: true,
inlineCollapsed: false
});
/* harmony default export */ var menu_MenuContext = (MenuContext);
;// CONCATENATED MODULE: ./node_modules/_antd@5.9.0@antd/es/menu/MenuItem.js
"use client";
const MenuItem = props => {
var _a;
const {
className,
children,
icon,
title,
danger
} = props;
const {
prefixCls,
firstLevel,
direction,
disableMenuItemTitleTooltip,
inlineCollapsed: isInlineCollapsed
} = _react_17_0_2_react.useContext(menu_MenuContext);
const renderItemChildren = inlineCollapsed => {
const wrapNode = /*#__PURE__*/_react_17_0_2_react.createElement("span", {
className: `${prefixCls}-title-content`
}, children);
// inline-collapsed.md demo 依赖 span 来隐藏文字,有 icon 属性,则内部包裹一个 span
// ref: https://github.com/ant-design/ant-design/pull/23456
if (!icon || (0,reactNode/* isValidElement */.l$)(children) && children.type === 'span') {
if (children && inlineCollapsed && firstLevel && typeof children === 'string') {
return /*#__PURE__*/_react_17_0_2_react.createElement("div", {
className: `${prefixCls}-inline-collapsed-noicon`
}, children.charAt(0));
}
}
return wrapNode;
};
const {
siderCollapsed
} = _react_17_0_2_react.useContext(Sider/* SiderContext */.D);
let tooltipTitle = title;
if (typeof title === 'undefined') {
tooltipTitle = firstLevel ? children : '';
} else if (title === false) {
tooltipTitle = '';
}
const tooltipProps = {
title: tooltipTitle
};
if (!siderCollapsed && !isInlineCollapsed) {
tooltipProps.title = null;
// Reset `open` to fix control mode tooltip display not correct
// ref: https://github.com/ant-design/ant-design/issues/16742
tooltipProps.open = false;
}
const childrenLength = (0,toArray/* default */.Z)(children).length;
let returnNode = /*#__PURE__*/_react_17_0_2_react.createElement(es/* Item */.ck, Object.assign({}, (0,omit/* default */.Z)(props, ['title', 'icon', 'danger']), {
className: _classnames_2_5_1_classnames_default()({
[`${prefixCls}-item-danger`]: danger,
[`${prefixCls}-item-only-child`]: (icon ? childrenLength + 1 : childrenLength) === 1
}, className),
title: typeof title === 'string' ? title : undefined
}), (0,reactNode/* cloneElement */.Tm)(icon, {
className: _classnames_2_5_1_classnames_default()((0,reactNode/* isValidElement */.l$)(icon) ? (_a = icon.props) === null || _a === void 0 ? void 0 : _a.className : '', `${prefixCls}-item-icon`)
}), renderItemChildren(isInlineCollapsed));
if (!disableMenuItemTitleTooltip) {
returnNode = /*#__PURE__*/_react_17_0_2_react.createElement(tooltip/* default */.Z, Object.assign({}, tooltipProps, {
placement: direction === 'rtl' ? 'left' : 'right',
overlayClassName: `${prefixCls}-inline-collapsed-tooltip`
}), returnNode);
}
return returnNode;
};
/* harmony default export */ var menu_MenuItem = (MenuItem);
;// CONCATENATED MODULE: ./node_modules/_antd@5.9.0@antd/es/menu/SubMenu.js
"use client";
const SubMenu = props => {
var _a;
const {
popupClassName,
icon,
title,
theme: customTheme
} = props;
const context = _react_17_0_2_react.useContext(menu_MenuContext);
const {
prefixCls,
inlineCollapsed,
theme: contextTheme
} = context;
const parentPath = (0,es/* useFullPath */.Xl)();
let titleNode;
if (!icon) {
titleNode = inlineCollapsed && !parentPath.length && title && typeof title === 'string' ? /*#__PURE__*/_react_17_0_2_react.createElement("div", {
className: `${prefixCls}-inline-collapsed-noicon`
}, title.charAt(0)) : /*#__PURE__*/_react_17_0_2_react.createElement("span", {
className: `${prefixCls}-title-content`
}, title);
} else {
// inline-collapsed.md demo 依赖 span 来隐藏文字,有 icon 属性,则内部包裹一个 span
// ref: https://github.com/ant-design/ant-design/pull/23456
const titleIsSpan = (0,reactNode/* isValidElement */.l$)(title) && title.type === 'span';
titleNode = /*#__PURE__*/_react_17_0_2_react.createElement(_react_17_0_2_react.Fragment, null, (0,reactNode/* cloneElement */.Tm)(icon, {
className: _classnames_2_5_1_classnames_default()((0,reactNode/* isValidElement */.l$)(icon) ? (_a = icon.props) === null || _a === void 0 ? void 0 : _a.className : '', `${prefixCls}-item-icon`)
}), titleIsSpan ? title : /*#__PURE__*/_react_17_0_2_react.createElement("span", {
className: `${prefixCls}-title-content`
}, title));
}
const contextValue = _react_17_0_2_react.useMemo(() => Object.assign(Object.assign({}, context), {
firstLevel: false
}), [context]);
return /*#__PURE__*/_react_17_0_2_react.createElement(menu_MenuContext.Provider, {
value: contextValue
}, /*#__PURE__*/_react_17_0_2_react.createElement(es/* SubMenu */.Wd, Object.assign({}, (0,omit/* default */.Z)(props, ['icon']), {
title: titleNode,
popupClassName: _classnames_2_5_1_classnames_default()(prefixCls, popupClassName, `${prefixCls}-${customTheme || contextTheme}`)
})));
};
/* harmony default export */ var menu_SubMenu = (SubMenu);
// EXTERNAL MODULE: ./node_modules/_@ant-design_icons@5.6.1@@ant-design/icons/es/icons/EllipsisOutlined.js + 1 modules
var EllipsisOutlined = __webpack_require__(18785);
// EXTERNAL MODULE: ./node_modules/_rc-util@5.44.4@rc-util/es/index.js
var _rc_util_5_44_4_rc_util_es = __webpack_require__(70425);
// EXTERNAL MODULE: ./node_modules/_antd@5.9.0@antd/es/_util/motion.js
var motion = __webpack_require__(62892);
// EXTERNAL MODULE: ./node_modules/_antd@5.9.0@antd/es/menu/OverrideContext.js
var OverrideContext = __webpack_require__(40875);
;// CONCATENATED MODULE: ./node_modules/_antd@5.9.0@antd/es/menu/hooks/useItems.js
"use client";
var useItems_rest = undefined && undefined.__rest || function (s, e) {
var t = {};
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0) t[p] = s[p];
if (s != null && typeof Object.getOwnPropertySymbols === "function") for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i])) t[p[i]] = s[p[i]];
}
return t;
};
function convertItemsToNodes(list) {
return (list || []).map((opt, index) => {
if (opt && typeof opt === 'object') {
const _a = opt,
{
label,
children,
key,
type
} = _a,
restProps = useItems_rest(_a, ["label", "children", "key", "type"]);
const mergedKey = key !== null && key !== void 0 ? key : `tmp-${index}`;
// MenuItemGroup & SubMenuItem
if (children || type === 'group') {
if (type === 'group') {
// Group
return /*#__PURE__*/_react_17_0_2_react.createElement(es/* ItemGroup */.BW, Object.assign({
key: mergedKey
}, restProps, {
title: label
}), convertItemsToNodes(children));
}
// Sub Menu
return /*#__PURE__*/_react_17_0_2_react.createElement(menu_SubMenu, Object.assign({
key: mergedKey
}, restProps, {
title: label
}), convertItemsToNodes(children));
}
// MenuItem & Divider
if (type === 'divider') {
return /*#__PURE__*/_react_17_0_2_react.createElement(menu_MenuDivider, Object.assign({
key: mergedKey
}, restProps));
}
return /*#__PURE__*/_react_17_0_2_react.createElement(menu_MenuItem, Object.assign({
key: mergedKey
}, restProps), label);
}
return null;
}).filter(opt => opt);
}
// FIXME: Move logic here in v5
/**
* We simply convert `items` to ReactNode for reuse origin component logic. But we need move all the
* logic from component into this hooks when in v5
*/
function useItems(items) {
return _react_17_0_2_react.useMemo(() => {
if (!items) {
return items;
}
return convertItemsToNodes(items);
}, [items]);
}
// EXTERNAL MODULE: ./node_modules/_@ctrl_tinycolor@3.6.1@@ctrl/tinycolor/dist/module/index.js
var dist_module = __webpack_require__(64993);
// EXTERNAL MODULE: ./node_modules/_antd@5.9.0@antd/es/style/index.js
var style = __webpack_require__(17313);
// EXTERNAL MODULE: ./node_modules/_antd@5.9.0@antd/es/style/motion/collapse.js
var collapse = __webpack_require__(8378);
// EXTERNAL MODULE: ./node_modules/_antd@5.9.0@antd/es/style/motion/slide.js
var slide = __webpack_require__(13826);
// EXTERNAL MODULE: ./node_modules/_antd@5.9.0@antd/es/style/motion/zoom.js
var zoom = __webpack_require__(29878);
// EXTERNAL MODULE: ./node_modules/_antd@5.9.0@antd/es/theme/util/genComponentStyleHook.js
var genComponentStyleHook = __webpack_require__(83116);
// EXTERNAL MODULE: ./node_modules/_antd@5.9.0@antd/es/theme/util/statistic.js
var statistic = __webpack_require__(37613);
;// CONCATENATED MODULE: ./node_modules/_antd@5.9.0@antd/es/menu/style/horizontal.js
"use client";
const getHorizontalStyle = token => {
const {
componentCls,
motionDurationSlow,
horizontalLineHeight,
colorSplit,
lineWidth,
lineType,
itemPaddingInline
} = token;
return {
[`${componentCls}-horizontal`]: {
lineHeight: horizontalLineHeight,
border: 0,
borderBottom: `${lineWidth}px ${lineType} ${colorSplit}`,
boxShadow: 'none',
'&::after': {
display: 'block',
clear: 'both',
height: 0,
content: '"\\20"'
},
// ======================= Item =======================
[`${componentCls}-item, ${componentCls}-submenu`]: {
position: 'relative',
display: 'inline-block',
verticalAlign: 'bottom',
paddingInline: itemPaddingInline
},
[`> ${componentCls}-item:hover,
> ${componentCls}-item-active,
> ${componentCls}-submenu ${componentCls}-submenu-title:hover`]: {
backgroundColor: 'transparent'
},
[`${componentCls}-item, ${componentCls}-submenu-title`]: {
transition: [`border-color ${motionDurationSlow}`, `background ${motionDurationSlow}`].join(',')
},
// ===================== Sub Menu =====================
[`${componentCls}-submenu-arrow`]: {
display: 'none'
}
}
};
};
/* harmony default export */ var horizontal = (getHorizontalStyle);
;// CONCATENATED MODULE: ./node_modules/_antd@5.9.0@antd/es/menu/style/rtl.js
"use client";
const getRTLStyle = _ref => {
let {
componentCls,
menuArrowOffset
} = _ref;
return {
[`${componentCls}-rtl`]: {
direction: 'rtl'
},
[`${componentCls}-submenu-rtl`]: {
transformOrigin: '100% 0'
},
// Vertical Arrow
[`${componentCls}-rtl${componentCls}-vertical,
${componentCls}-submenu-rtl ${componentCls}-vertical`]: {
[`${componentCls}-submenu-arrow`]: {
'&::before': {
transform: `rotate(-45deg) translateY(-${menuArrowOffset})`
},
'&::after': {
transform: `rotate(45deg) translateY(${menuArrowOffset})`
}
}
}
};
};
/* harmony default export */ var rtl = (getRTLStyle);
;// CONCATENATED MODULE: ./node_modules/_antd@5.9.0@antd/es/menu/style/theme.js
"use client";
const accessibilityFocus = token => Object.assign({}, (0,style/* genFocusOutline */.oN)(token));
const getThemeStyle = (token, themeSuffix) => {
const {
componentCls,
itemColor,
itemSelectedColor,
groupTitleColor,
itemBg,
subMenuItemBg,
itemSelectedBg,
activeBarHeight,
activeBarWidth,
activeBarBorderWidth,
motionDurationSlow,
motionEaseInOut,
motionEaseOut,
itemPaddingInline,
motionDurationMid,
itemHoverColor,
lineType,
colorSplit,
// Disabled
itemDisabledColor,
// Danger
dangerItemColor,
dangerItemHoverColor,
dangerItemSelectedColor,
dangerItemActiveBg,
dangerItemSelectedBg,
itemHoverBg,
itemActiveBg,
menuSubMenuBg,
// Horizontal
horizontalItemSelectedColor,
horizontalItemSelectedBg,
horizontalItemBorderRadius,
horizontalItemHoverBg,
popupBg
} = token;
return {
[`${componentCls}-${themeSuffix}, ${componentCls}-${themeSuffix} > ${componentCls}`]: {
color: itemColor,
background: itemBg,
[`&${componentCls}-root:focus-visible`]: Object.assign({}, accessibilityFocus(token)),
// ======================== Item ========================
[`${componentCls}-item-group-title`]: {
color: groupTitleColor
},
[`${componentCls}-submenu-selected`]: {
[`> ${componentCls}-submenu-title`]: {
color: itemSelectedColor
}
},
// Disabled
[`${componentCls}-item-disabled, ${componentCls}-submenu-disabled`]: {
color: `${itemDisabledColor} !important`
},
// Hover
[`${componentCls}-item:not(${componentCls}-item-selected):not(${componentCls}-submenu-selected)`]: {
[`&:hover, > ${componentCls}-submenu-title:hover`]: {
color: itemHoverColor
}
},
[`&:not(${componentCls}-horizontal)`]: {
[`${componentCls}-item:not(${componentCls}-item-selected)`]: {
'&:hover': {
backgroundColor: itemHoverBg
},
'&:active': {
backgroundColor: itemActiveBg
}
},
[`${componentCls}-submenu-title`]: {
'&:hover': {
backgroundColor: itemHoverBg
},
'&:active': {
backgroundColor: itemActiveBg
}
}
},
// Danger - only Item has
[`${componentCls}-item-danger`]: {
color: dangerItemColor,
[`&${componentCls}-item:hover`]: {
[`&:not(${componentCls}-item-selected):not(${componentCls}-submenu-selected)`]: {
color: dangerItemHoverColor
}
},
[`&${componentCls}-item:active`]: {
background: dangerItemActiveBg
}
},
[`${componentCls}-item a`]: {
'&, &:hover': {
color: 'inherit'
}
},
[`${componentCls}-item-selected`]: {
color: itemSelectedColor,
// Danger
[`&${componentCls}-item-danger`]: {
color: dangerItemSelectedColor
},
[`a, a:hover`]: {
color: 'inherit'
}
},
[`& ${componentCls}-item-selected`]: {
backgroundColor: itemSelectedBg,
// Danger
[`&${componentCls}-item-danger`]: {
backgroundColor: dangerItemSelectedBg
}
},
[`${componentCls}-item, ${componentCls}-submenu-title`]: {
[`&:not(${componentCls}-item-disabled):focus-visible`]: Object.assign({}, accessibilityFocus(token))
},
[`&${componentCls}-submenu > ${componentCls}`]: {
backgroundColor: menuSubMenuBg
},
[`&${componentCls}-popup > ${componentCls}`]: {
backgroundColor: popupBg
},
// ====================== Horizontal ======================
[`&${componentCls}-horizontal`]: Object.assign(Object.assign({}, themeSuffix === 'dark' ? {
borderBottom: 0
} : {}), {
[`> ${componentCls}-item, > ${componentCls}-submenu`]: {
top: activeBarBorderWidth,
marginTop: -activeBarBorderWidth,
marginBottom: 0,
borderRadius: horizontalItemBorderRadius,
'&::after': {
position: 'absolute',
insetInline: itemPaddingInline,
bottom: 0,
borderBottom: `${activeBarHeight}px solid transparent`,
transition: `border-color ${motionDurationSlow} ${motionEaseInOut}`,
content: '""'
},
[`&:hover, &-active, &-open`]: {
background: horizontalItemHoverBg,
'&::after': {
borderBottomWidth: activeBarHeight,
borderBottomColor: horizontalItemSelectedColor
}
},
[`&-selected`]: {
color: horizontalItemSelectedColor,
backgroundColor: horizontalItemSelectedBg,
'&:hover': {
backgroundColor: horizontalItemSelectedBg
},
'&::after': {
borderBottomWidth: activeBarHeight,
borderBottomColor: horizontalItemSelectedColor
}
}
}
}),
// ================== Inline & Vertical ===================
//
[`&${componentCls}-root`]: {
[`&${componentCls}-inline, &${componentCls}-vertical`]: {
borderInlineEnd: `${activeBarBorderWidth}px ${lineType} ${colorSplit}`
}
},
// ======================== Inline ========================
[`&${componentCls}-inline`]: {
// Sub
[`${componentCls}-sub${componentCls}-inline`]: {
background: subMenuItemBg
},
// Item
[`${componentCls}-item, ${componentCls}-submenu-title`]: activeBarBorderWidth && activeBarWidth ? {
width: `calc(100% + ${activeBarBorderWidth}px)`
} : {},
[`${componentCls}-item`]: {
position: 'relative',
'&::after': {
position: 'absolute',
insetBlock: 0,
insetInlineEnd: 0,
borderInlineEnd: `${activeBarWidth}px solid ${itemSelectedColor}`,
transform: 'scaleY(0.0001)',
opacity: 0,
transition: [`transform ${motionDurationMid} ${motionEaseOut}`, `opacity ${motionDurationMid} ${motionEaseOut}`].join(','),
content: '""'
},
// Danger
[`&${componentCls}-item-danger`]: {
'&::after': {
borderInlineEndColor: dangerItemSelectedColor
}
}
},
[`${componentCls}-selected, ${componentCls}-item-selected`]: {
'&::after': {
transform: 'scaleY(1)',
opacity: 1,
transition: [`transform ${motionDurationMid} ${motionEaseInOut}`, `opacity ${motionDurationMid} ${motionEaseInOut}`].join(',')
}
}
}
}
};
};
/* harmony default export */ var theme = (getThemeStyle);
;// CONCATENATED MODULE: ./node_modules/_antd@5.9.0@antd/es/menu/style/vertical.js
"use client";
const getVerticalInlineStyle = token => {
const {
componentCls,
itemHeight,
itemMarginInline,
padding,
menuArrowSize,
marginXS,
itemMarginBlock
} = token;
const paddingWithArrow = padding + menuArrowSize + marginXS;
return {
[`${componentCls}-item`]: {
position: 'relative',
overflow: 'hidden'
},
[`${componentCls}-item, ${componentCls}-submenu-title`]: {
height: itemHeight,
lineHeight: `${itemHeight}px`,
paddingInline: padding,
overflow: 'hidden',
textOverflow: 'ellipsis',
marginInline: itemMarginInline,
marginBlock: itemMarginBlock,
width: `calc(100% - ${itemMarginInline * 2}px)`
},
[`> ${componentCls}-item,
> ${componentCls}-submenu > ${componentCls}-submenu-title`]: {
height: itemHeight,
lineHeight: `${itemHeight}px`
},
[`${componentCls}-item-group-list ${componentCls}-submenu-title,
${componentCls}-submenu-title`]: {
paddingInlineEnd: paddingWithArrow
}
};
};
const getVerticalStyle = token => {
const {
componentCls,
iconCls,
itemHeight,
colorTextLightSolid,
dropdownWidth,
controlHeightLG,
motionDurationMid,
motionEaseOut,
paddingXL,
itemMarginInline,
fontSizeLG,
motionDurationSlow,
paddingXS,
boxShadowSecondary,
collapsedWidth,
collapsedIconSize
} = token;
const inlineItemStyle = {
height: itemHeight,
lineHeight: `${itemHeight}px`,
listStylePosition: 'inside',
listStyleType: 'disc'
};
return [{
[componentCls]: {
[`&-inline, &-vertical`]: Object.assign({
[`&${componentCls}-root`]: {
boxShadow: 'none'
}
}, getVerticalInlineStyle(token))
},
[`${componentCls}-submenu-popup`]: {
[`${componentCls}-vertical`]: Object.assign(Object.assign({}, getVerticalInlineStyle(token)), {
boxShadow: boxShadowSecondary
})
}
},
// Vertical only
{
[`${componentCls}-submenu-popup ${componentCls}-vertical${componentCls}-sub`]: {
minWidth: dropdownWidth,
maxHeight: `calc(100vh - ${controlHeightLG * 2.5}px)`,
padding: '0',
overflow: 'hidden',
borderInlineEnd: 0,
// https://github.com/ant-design/ant-design/issues/22244
// https://github.com/ant-design/ant-design/issues/26812
"&:not([class*='-active'])": {
overflowX: 'hidden',
overflowY: 'auto'
}
}
},
// Inline Only
{
[`${componentCls}-inline`]: {
width: '100%',
// Motion enhance for first level
[`&${componentCls}-root`]: {
[`${componentCls}-item, ${componentCls}-submenu-title`]: {
display: 'flex',
alignItems: 'center',
transition: [`border-color ${motionDurationSlow}`, `background ${motionDurationSlow}`, `padding ${motionDurationMid} ${motionEaseOut}`].join(','),
[`> ${componentCls}-title-content`]: {
flex: 'auto',
minWidth: 0,
overflow: 'hidden',
textOverflow: 'ellipsis'
},
'> *': {
flex: 'none'
}
}
},
// >>>>> Sub
[`${componentCls}-sub${componentCls}-inline`]: {
padding: 0,
border: 0,
borderRadius: 0,
boxShadow: 'none',
[`& > ${componentCls}-submenu > ${componentCls}-submenu-title`]: inlineItemStyle,
[`& ${componentCls}-item-group-title`]: {
paddingInlineStart: paddingXL
}
},
// >>>>> Item
[`${componentCls}-item`]: inlineItemStyle
}
},
// Inline Collapse Only
{
[`${componentCls}-inline-collapsed`]: {
width: collapsedWidth,
[`&${componentCls}-root`]: {
[`${componentCls}-item, ${componentCls}-submenu ${componentCls}-submenu-title`]: {
[`> ${componentCls}-inline-collapsed-noicon`]: {
fontSize: fontSizeLG,
textAlign: 'center'
}
}
},
[`> ${componentCls}-item,
> ${componentCls}-item-group > ${componentCls}-item-group-list > ${componentCls}-item,
> ${componentCls}-item-group > ${componentCls}-item-group-list > ${componentCls}-submenu > ${componentCls}-submenu-title,
> ${componentCls}-submenu > ${componentCls}-submenu-title`]: {
insetInlineStart: 0,
paddingInline: `calc(50% - ${fontSizeLG / 2}px - ${itemMarginInline}px)`,
textOverflow: 'clip',
[`
${componentCls}-submenu-arrow,
${componentCls}-submenu-expand-icon
`]: {
opacity: 0
},
[`${componentCls}-item-icon, ${iconCls}`]: {
margin: 0,
fontSize: collapsedIconSize,
lineHeight: `${itemHeight}px`,
'+ span': {
display: 'inline-block',
opacity: 0
}
}
},
[`${componentCls}-item-icon, ${iconCls}`]: {
display: 'inline-block'
},
'&-tooltip': {
pointerEvents: 'none',
[`${componentCls}-item-icon, ${iconCls}`]: {
display: 'none'
},
'a, a:hover': {
color: colorTextLightSolid
}
},
[`${componentCls}-item-group-title`]: Object.assign(Object.assign({}, style/* textEllipsis */.vS), {
paddingInline: paddingXS
})
}
}];
};
/* harmony default export */ var vertical = (getVerticalStyle);
;// CONCATENATED MODULE: ./node_modules/_antd@5.9.0@antd/es/menu/style/index.js
"use client";
const genMenuItemStyle = token => {
const {
componentCls,
motionDurationSlow,
motionDurationMid,
motionEaseInOut,
motionEaseOut,
iconCls,
iconSize,
iconMarginInlineEnd
} = token;
return {
// >>>>> Item
[`${componentCls}-item, ${componentCls}-submenu-title`]: {
position: 'relative',
display: 'block',
margin: 0,
whiteSpace: 'nowrap',
cursor: 'pointer',
transition: [`border-color ${motionDurationSlow}`, `background ${motionDurationSlow}`, `padding ${motionDurationSlow} ${motionEaseInOut}`].join(','),
[`${componentCls}-item-icon, ${iconCls}`]: {
minWidth: iconSize,
fontSize: iconSize,
transition: [`font-size ${motionDurationMid} ${motionEaseOut}`, `margin ${motionDurationSlow} ${motionEaseInOut}`, `color ${motionDurationSlow}`].join(','),
'+ span': {
marginInlineStart: iconMarginInlineEnd,
opacity: 1,
transition: [`opacity ${motionDurationSlow} ${motionEaseInOut}`, `margin ${motionDurationSlow}`, `color ${motionDurationSlow}`].join(',')
}
},
[`${componentCls}-item-icon`]: Object.assign({}, (0,style/* resetIcon */.Ro)()),
[`&${componentCls}-item-only-child`]: {
[`> ${iconCls}, > ${componentCls}-item-icon`]: {
marginInlineEnd: 0
}
}
},
// Disabled state sets text to gray and nukes hover/tab effects
[`${componentCls}-item-disabled, ${componentCls}-submenu-disabled`]: {
background: 'none !important',
cursor: 'not-allowed',
'&::after': {
borderColor: 'transparent !important'
},
a: {
color: 'inherit !important'
},
[`> ${componentCls}-submenu-title`]: {
color: 'inherit !important',
cursor: 'not-allowed'
}
}
};
};
const genSubMenuArrowStyle = token => {
const {
componentCls,
motionDurationSlow,
motionEaseInOut,
borderRadius,
menuArrowSize,
menuArrowOffset
} = token;
return {
[`${componentCls}-submenu`]: {
[`&-expand-icon, &-arrow`]: {
position: 'absolute',
top: '50%',
insetInlineEnd: token.margin,
width: menuArrowSize,
color: 'currentcolor',
transform: 'translateY(-50%)',
transition: `transform ${motionDurationSlow} ${motionEaseInOut}, opacity ${motionDurationSlow}`
},
'&-arrow': {
// →
'&::before, &::after': {
position: 'absolute',
width: menuArrowSize * 0.6,
height: menuArrowSize * 0.15,
backgroundColor: 'currentcolor',
borderRadius,
transition: [`background ${motionDurationSlow} ${motionEaseInOut}`, `transform ${motionDurationSlow} ${motionEaseInOut}`, `top ${motionDurationSlow} ${motionEaseInOut}`, `color ${motionDurationSlow} ${motionEaseInOut}`].join(','),
content: '""'
},
'&::before': {
transform: `rotate(45deg) translateY(-${menuArrowOffset})`
},
'&::after': {
transform: `rotate(-45deg) translateY(${menuArrowOffset})`
}
}
}
};
};
// =============================== Base ===============================
const getBaseStyle = token => {
const {
antCls,
componentCls,
fontSize,
motionDurationSlow,
motionDurationMid,
motionEaseInOut,
paddingXS,
padding,
colorSplit,
lineWidth,
zIndexPopup,
borderRadiusLG,
subMenuItemBorderRadius,
menuArrowSize,
menuArrowOffset,
lineType,
menuPanelMaskInset,
groupTitleLineHeight,
groupTitleFontSize
} = token;
return [
// Misc
{
'': {
[`${componentCls}`]: Object.assign(Object.assign({}, (0,style/* clearFix */.dF)()), {
// Hidden
[`&-hidden`]: {
display: 'none'
}
})
},
[`${componentCls}-submenu-hidden`]: {
display: 'none'
}
}, {
[componentCls]: Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({}, (0,style/* resetComponent */.Wf)(token)), (0,style/* clearFix */.dF)()), {
marginBottom: 0,
paddingInlineStart: 0,
// Override default ul/ol
fontSize,
lineHeight: 0,
listStyle: 'none',
outline: 'none',
// Magic cubic here but smooth transition
transition: `width ${motionDurationSlow} cubic-bezier(0.2, 0, 0, 1) 0s`,
[`ul, ol`]: {
margin: 0,
padding: 0,
listStyle: 'none'
},
// Overflow ellipsis
[`&-overflow`]: {
display: 'flex',
[`${componentCls}-item`]: {
flex: 'none'
}
},
[`${componentCls}-item, ${componentCls}-submenu, ${componentCls}-submenu-title`]: {
borderRadius: token.itemBorderRadius
},
[`${componentCls}-item-group-title`]: {
padding: `${paddingXS}px ${padding}px`,
fontSize: groupTitleFontSize,
lineHeight: groupTitleLineHeight,
transition: `all ${motionDurationSlow}`
},
[`&-horizontal ${componentCls}-submenu`]: {
transition: [`border-color ${motionDurationSlow} ${motionEaseInOut}`, `background ${motionDurationSlow} ${motionEaseInOut}`].join(',')
},
[`${componentCls}-submenu, ${componentCls}-submenu-inline`]: {
transition: [`border-color ${motionDurationSlow} ${motionEaseInOut}`, `background ${motionDurationSlow} ${motionEaseInOut}`, `padding ${motionDurationMid} ${motionEaseInOut}`].join(',')
},
[`${componentCls}-submenu ${componentCls}-sub`]: {
cursor: 'initial',
transition: [`background ${motionDurationSlow} ${motionEaseInOut}`, `padding ${motionDurationSlow} ${motionEaseInOut}`].join(',')
},
[`${componentCls}-title-content`]: {
transition: `color ${motionDurationSlow}`
},
[`${componentCls}-item a`]: {
'&::before': {
position: 'absolute',
inset: 0,
backgroundColor: 'transparent',
content: '""'
}
},
// Removed a Badge related style seems it's safe
// https://github.com/ant-design/ant-design/issues/19809
// >>>>> Divider
[`${componentCls}-item-divider`]: {
overflow: 'hidden',
lineHeight: 0,
borderColor: colorSplit,
borderStyle: lineType,
borderWidth: 0,
borderTopWidth: lineWidth,
marginBlock: lineWidth,
padding: 0,
'&-dashed': {
borderStyle: 'dashed'
}
}
}), genMenuItemStyle(token)), {
[`${componentCls}-item-group`]: {
[`${componentCls}-item-group-list`]: {
margin: 0,
padding: 0,
[`${componentCls}-item, ${componentCls}-submenu-title`]: {
paddingInline: `${fontSize * 2}px ${padding}px`
}
}
},
// ======================= Sub Menu =======================
'&-submenu': {
'&-popup': {
position: 'absolute',
zIndex: zIndexPopup,
borderRadius: borderRadiusLG,
boxShadow: 'none',
transformOrigin: '0 0',
[`&${componentCls}-submenu`]: {
background: 'transparent'
},
// https://github.com/ant-design/ant-design/issues/13955
'&::before': {
position: 'absolute',
inset: `${menuPanelMaskInset}px 0 0`,
zIndex: -1,
width: '100%',
height: '100%',
opacity: 0,
content: '""'
}
},
// https://github.com/ant-design/ant-design/issues/13955
'&-placement-rightTop::before': {
top: 0,
insetInlineStart: menuPanelMaskInset
},
[`
&-placement-leftTop,
&-placement-bottomRight,
`]: {
transformOrigin: '100% 0'
},
[`
&-placement-leftBottom,
&-placement-topRight,
`]: {
transformOrigin: '100% 100%'
},
[`
&-placement-rightBottom,
&-placement-topLeft,
`]: {
transformOrigin: '0 100%'
},
[`
&-placement-bottomLeft,
&-placement-rightTop,
`]: {
transformOrigin: '0 0'
},
[`
&-placement-leftTop,
&-placement-leftBottom
`]: {
paddingInlineEnd: token.paddingXS
},
[`
&-placement-rightTop,
&-placement-rightBottom
`]: {
paddingInlineStart: token.paddingXS
},
[`
&-placement-topRight,
&-placement-topLeft
`]: {
paddingBottom: token.paddingXS
},
[`
&-placement-bottomRight,
&-placement-bottomLeft
`]: {
paddingTop: token.paddingXS
},
[`> ${componentCls}`]: Object.assign(Object.assign(Object.assign({
borderRadius: borderRadiusLG
}, genMenuItemStyle(token)), genSubMenuArrowStyle(token)), {
[`${componentCls}-item, ${componentCls}-submenu > ${componentCls}-submenu-title`]: {
borderRadius: subMenuItemBorderRadius
},
[`${componentCls}-submenu-title::after`]: {
transition: `transform ${motionDurationSlow} ${motionEaseInOut}`
}
})
}
}), genSubMenuArrowStyle(token)), {
[`&-inline-collapsed ${componentCls}-submenu-arrow,
&-inline ${componentCls}-submenu-arrow`]: {
// ↓
'&::before': {
transform: `rotate(-45deg) translateX(${menuArrowOffset})`
},
'&::after': {
transform: `rotate(45deg) translateX(-${menuArrowOffset})`
}
},
[`${componentCls}-submenu-open${componentCls}-submenu-inline > ${componentCls}-submenu-title > ${componentCls}-submenu-arrow`]: {
// ↑
transform: `translateY(-${menuArrowSize * 0.2}px)`,
'&::after': {
transform: `rotate(-45deg) translateX(-${menuArrowOffset})`
},
'&::before': {
transform: `rotate(45deg) translateX(${menuArrowOffset})`
}
}
})
},
// Integration with header element so menu items have the same height
{
[`${antCls}-layout-header`]: {
[componentCls]: {
lineHeight: 'inherit'
}
}
}];
};
// ============================== Export ==============================
/* harmony default export */ var menu_style = ((prefixCls, injectStyle) => {
const useOriginHook = (0,genComponentStyleHook/* default */.Z)('Menu', token => {
// Dropdown will handle menu style self. We do not need to handle this.
if (injectStyle === false) {
return [];
}
const {
colorBgElevated,
colorPrimary,
colorTextLightSolid,
controlHeightLG,
fontSize,
darkItemColor,
darkDangerItemColor,
darkItemBg,
darkSubMenuItemBg,
darkItemSelectedColor,
darkItemSelectedBg,
darkDangerItemSelectedBg,
darkItemHoverBg,
darkGroupTitleColor,
darkItemHoverColor,
darkItemDisabledColor,
darkDangerItemHoverColor,
darkDangerItemSelectedColor,
darkDangerItemActiveBg
} = token;
const menuArrowSize = fontSize / 7 * 5;
// Menu Token
const menuToken = (0,statistic/* merge */.TS)(token, {
menuArrowSize,
menuHorizontalHeight: controlHeightLG * 1.15,
menuArrowOffset: `${menuArrowSize * 0.25}px`,
menuPanelMaskInset: -7,
menuSubMenuBg: colorBgElevated
});
const menuDarkToken = (0,statistic/* merge */.TS)(menuToken, {
itemColor: darkItemColor,
itemHoverColor: darkItemHoverColor,
groupTitleColor: darkGroupTitleColor,
itemSelectedColor: darkItemSelectedColor,
itemBg: darkItemBg,
popupBg: darkItemBg,
subMenuItemBg: darkSubMenuItemBg,
itemActiveBg: 'transparent',
itemSelectedBg: darkItemSelectedBg,
activeBarHeight: 0,
activeBarBorderWidth: 0,
itemHoverBg: darkItemHoverBg,
// Disabled
itemDisabledColor: darkItemDisabledColor,
// Danger
dangerItemColor: darkDangerItemColor,
dangerItemHoverColor: darkDangerItemHoverColor,
dangerItemSelectedColor: darkDangerItemSelectedColor,
dangerItemActiveBg: darkDangerItemActiveBg,
dangerItemSelectedBg: darkDangerItemSelectedBg,
menuSubMenuBg: darkSubMenuItemBg,
// Horizontal
horizontalItemSelectedColor: colorTextLightSolid,
horizontalItemSelectedBg: colorPrimary
});
return [
// Basic
getBaseStyle(menuToken),
// Horizontal
horizontal(menuToken),
// Vertical
vertical(menuToken),
// Theme
theme(menuToken, 'light'), theme(menuDarkToken, 'dark'),
// RTL
rtl(menuToken),
// Motion
(0,collapse/* default */.Z)(menuToken), (0,slide/* initSlideMotion */.oN)(menuToken, 'slide-up'), (0,slide/* initSlideMotion */.oN)(menuToken, 'slide-down'), (0,zoom/* initZoomMotion */._y)(menuToken, 'zoom-big')];
}, token => {
const {
colorPrimary,
colorError,
colorTextDisabled,
colorErrorBg,
colorText,
colorTextDescription,
colorBgContainer,
colorFillAlter,
colorFillContent,
lineWidth,
lineWidthBold,
controlItemBgActive,
colorBgTextHover,
controlHeightLG,
lineHeight,
colorBgElevated,
marginXXS,
padding,
fontSize,
controlHeightSM,
fontSizeLG,
colorTextLightSolid,
colorErrorHover
} = token;
const colorTextDark = new dist_module/* TinyColor */.C(colorTextLightSolid).setAlpha(0.65).toRgbString();
return {
dropdownWidth: 160,
zIndexPopup: token.zIndexPopupBase + 50,
radiusItem: token.borderRadiusLG,
itemBorderRadius: token.borderRadiusLG,
radiusSubMenuItem: token.borderRadiusSM,
subMenuItemBorderRadius: token.borderRadiusSM,
colorItemText: colorText,
itemColor: colorText,
colorItemTextHover: colorText,
itemHoverColor: colorText,
colorItemTextHoverHorizontal: colorPrimary,
horizontalItemHoverColor: colorPrimary,
colorGroupTitle: colorTextDescription,
groupTitleColor: colorTextDescription,
colorItemTextSelected: colorPrimary,
itemSelectedColor: colorPrimary,
colorItemTextSelectedHorizontal: colorPrimary,
horizontalItemSelectedColor: colorPrimary,
colorItemBg: colorBgContainer,
itemBg: colorBgContainer,
colorItemBgHover: colorBgTextHover,
itemHoverBg: colorBgTextHover,
colorItemBgActive: colorFillContent,
itemActiveBg: controlItemBgActive,
colorSubItemBg: colorFillAlter,
subMenuItemBg: colorFillAlter,
colorItemBgSelected: controlItemBgActive,
itemSelectedBg: controlItemBgActive,
colorItemBgSelectedHorizontal: 'transparent',
horizontalItemSelectedBg: 'transparent',
colorActiveBarWidth: 0,
activeBarWidth: 0,
colorActiveBarHeight: lineWidthBold,
activeBarHeight: lineWidthBold,
colorActiveBarBorderSize: lineWidth,
activeBarBorderWidth: lineWidth,
// Disabled
colorItemTextDisabled: colorTextDisabled,
itemDisabledColor: colorTextDisabled,
// Danger
colorDangerItemText: colorError,
dangerItemColor: colorError,
colorDangerItemTextHover: colorError,
dangerItemHoverColor: colorError,
colorDangerItemTextSelected: colorError,
dangerItemSelectedColor: colorError,
colorDangerItemBgActive: colorErrorBg,
dangerItemActiveBg: colorErrorBg,
colorDangerItemBgSelected: colorErrorBg,
dangerItemSelectedBg: colorErrorBg,
itemMarginInline: token.marginXXS,
horizontalItemBorderRadius: 0,
horizontalItemHoverBg: 'transparent',
itemHeight: controlHeightLG,
groupTitleLineHeight: lineHeight,
collapsedWidth: controlHeightLG * 2,
popupBg: colorBgElevated,
itemMarginBlock: marginXXS,
itemPaddingInline: padding,
horizontalLineHeight: `${controlHeightLG * 1.15}px`,
iconSize: fontSize,
iconMarginInlineEnd: controlHeightSM - fontSize,
collapsedIconSize: fontSizeLG,
groupTitleFontSize: fontSize,
// Disabled
darkItemDisabledColor: new dist_module/* TinyColor */.C(colorTextLightSolid).setAlpha(0.25).toRgbString(),
// Dark
darkItemColor: colorTextDark,
darkDangerItemColor: colorError,
darkItemBg: '#001529',
darkSubMenuItemBg: '#000c17',
darkItemSelectedColor: colorTextLightSolid,
darkItemSelectedBg: colorPrimary,
darkDangerItemSelectedBg: colorError,
darkItemHoverBg: 'transparent',
darkGroupTitleColor: colorTextDark,
darkItemHoverColor: colorTextLightSolid,
darkDangerItemHoverColor: colorErrorHover,
darkDangerItemSelectedColor: colorTextLightSolid,
darkDangerItemActiveBg: colorError
};
}, {
deprecatedTokens: [['colorGroupTitle', 'groupTitleColor'], ['radiusItem', 'itemBorderRadius'], ['radiusSubMenuItem', 'subMenuItemBorderRadius'], ['colorItemText', 'itemColor'], ['colorItemTextHover', 'itemHoverColor'], ['colorItemTextHoverHorizontal', 'horizontalItemHoverColor'], ['colorItemTextSelected', 'itemSelectedColor'], ['colorItemTextSelectedHorizontal', 'horizontalItemSelectedColor'], ['colorItemTextDisabled', 'itemDisabledColor'], ['colorDangerItemText', 'dangerItemColor'], ['colorDangerItemTextHover', 'dangerItemHoverColor'], ['colorDangerItemTextSelected', 'dangerItemSelectedColor'], ['colorDangerItemBgActive', 'dangerItemActiveBg'], ['colorDangerItemBgSelected', 'dangerItemSelectedBg'], ['colorItemBg', 'itemBg'], ['colorItemBgHover', 'itemHoverBg'], ['colorSubItemBg', 'subMenuItemBg'], ['colorItemBgActive', 'itemActiveBg'], ['colorItemBgSelectedHorizontal', 'horizontalItemSelectedBg'], ['colorActiveBarWidth', 'activeBarWidth'], ['colorActiveBarHeight', 'activeBarHeight'], ['colorActiveBarBorderSize', 'activeBarBorderWidth'], ['colorItemBgSelected', 'itemSelectedBg']]
});
return useOriginHook(prefixCls);
});
;// CONCATENATED MODULE: ./node_modules/_antd@5.9.0@antd/es/menu/menu.js
"use client";
var menu_rest = undefined && undefined.__rest || function (s, e) {
var t = {};
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0) t[p] = s[p];
if (s != null && typeof Object.getOwnPropertySymbols === "function") for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i])) t[p[i]] = s[p[i]];
}
return t;
};
const InternalMenu = /*#__PURE__*/(0,_react_17_0_2_react.forwardRef)((props, ref) => {
var _a, _b;
const override = _react_17_0_2_react.useContext(OverrideContext/* default */.Z);
const overrideObj = override || {};
const {
getPrefixCls,
getPopupContainer,
direction,
menu
} = _react_17_0_2_react.useContext(context/* ConfigContext */.E_);
const rootPrefixCls = getPrefixCls();
const {
prefixCls: customizePrefixCls,
className,
style,
theme = 'light',
expandIcon,
_internalDisableMenuItemTitleTooltip,
inlineCollapsed,
siderCollapsed,
items,
children,
rootClassName,
mode,
selectable,
onClick,
overflowedIndicatorPopupClassName
} = props,
restProps = menu_rest(props, ["prefixCls", "className", "style", "theme", "expandIcon", "_internalDisableMenuItemTitleTooltip", "inlineCollapsed", "siderCollapsed", "items", "children", "rootClassName", "mode", "selectable", "onClick", "overflowedIndicatorPopupClassName"]);
const passedProps = (0,omit/* default */.Z)(restProps, ['collapsedWidth']);
// ========================= Items ===========================
const mergedChildren = useItems(items) || children;
// ======================== Warning ==========================
false ? 0 : void 0;
false ? 0 : void 0;
false ? 0 : void 0;
(_a = overrideObj.validator) === null || _a === void 0 ? void 0 : _a.call(overrideObj, {
mode
});
// ========================== Click ==========================
// Tell dropdown that item clicked
const onItemClick = (0,_rc_util_5_44_4_rc_util_es.useEvent)(function () {
var _a;
onClick === null || onClick === void 0 ? void 0 : onClick.apply(void 0, arguments);
(_a = overrideObj.onClick) === null || _a === void 0 ? void 0 : _a.call(overrideObj);
});
// ========================== Mode ===========================
const mergedMode = overrideObj.mode || mode;
// ======================= Selectable ========================
const mergedSelectable = selectable !== null && selectable !== void 0 ? selectable : overrideObj.selectable;
// ======================== Collapsed ========================
// Inline Collapsed
const mergedInlineCollapsed = _react_17_0_2_react.useMemo(() => {
if (siderCollapsed !== undefined) {
return siderCollapsed;
}
return inlineCollapsed;
}, [inlineCollapsed, siderCollapsed]);
const defaultMotions = {
horizontal: {
motionName: `${rootPrefixCls}-slide-up`
},
inline: (0,motion/* default */.Z)(rootPrefixCls),
other: {
motionName: `${rootPrefixCls}-zoom-big`
}
};
const prefixCls = getPrefixCls('menu', customizePrefixCls || overrideObj.prefixCls);
const [wrapSSR, hashId] = menu_style(prefixCls, !override);
const menuClassName = _classnames_2_5_1_classnames_default()(`${prefixCls}-${theme}`, menu === null || menu === void 0 ? void 0 : menu.className, className);
// ====================== Expand Icon ========================
let mergedExpandIcon;
if (typeof expandIcon === 'function') {
mergedExpandIcon = expandIcon;
} else if (expandIcon === null || expandIcon === false) {
mergedExpandIcon = null;
} else if (overrideObj.expandIcon === null || overrideObj.expandIcon === false) {
mergedExpandIcon = null;
} else {
const beClone = expandIcon !== null && expandIcon !== void 0 ? expandIcon : overrideObj.expandIcon;
mergedExpandIcon = (0,reactNode/* cloneElement */.Tm)(beClone, {
className: _classnames_2_5_1_classnames_default()(`${prefixCls}-submenu-expand-icon`, (0,reactNode/* isValidElement */.l$)(beClone) ? (_b = beClone.props) === null || _b === void 0 ? void 0 : _b.className : '')
});
}
// ======================== Context ==========================
const contextValue = _react_17_0_2_react.useMemo(() => ({
prefixCls,
inlineCollapsed: mergedInlineCollapsed || false,
direction,
firstLevel: true,
theme,
mode: mergedMode,
disableMenuItemTitleTooltip: _internalDisableMenuItemTitleTooltip
}), [prefixCls, mergedInlineCollapsed, direction, _internalDisableMenuItemTitleTooltip, theme]);
// ========================= Render ==========================
return wrapSSR( /*#__PURE__*/_react_17_0_2_react.createElement(OverrideContext/* default */.Z.Provider, {
value: null
}, /*#__PURE__*/_react_17_0_2_react.createElement(menu_MenuContext.Provider, {
value: contextValue
}, /*#__PURE__*/_react_17_0_2_react.createElement(es/* default */.ZP, Object.assign({
getPopupContainer: getPopupContainer,
overflowedIndicator: /*#__PURE__*/_react_17_0_2_react.createElement(EllipsisOutlined/* default */.Z, null),
overflowedIndicatorPopupClassName: _classnames_2_5_1_classnames_default()(prefixCls, `${prefixCls}-${theme}`, overflowedIndicatorPopupClassName),
mode: mergedMode,
selectable: mergedSelectable,
onClick: onItemClick
}, passedProps, {
inlineCollapsed: mergedInlineCollapsed,
style: Object.assign(Object.assign({}, menu === null || menu === void 0 ? void 0 : menu.style), style),
className: menuClassName,
prefixCls: prefixCls,
direction: direction,
defaultMotions: defaultMotions,
expandIcon: mergedExpandIcon,
ref: ref,
rootClassName: _classnames_2_5_1_classnames_default()(rootClassName, hashId)
}), mergedChildren))));
});
/* harmony default export */ var menu = (InternalMenu);
;// CONCATENATED MODULE: ./node_modules/_antd@5.9.0@antd/es/menu/index.js
"use client";
const Menu = /*#__PURE__*/(0,_react_17_0_2_react.forwardRef)((props, ref) => {
const menuRef = (0,_react_17_0_2_react.useRef)(null);
const context = _react_17_0_2_react.useContext(Sider/* SiderContext */.D);
(0,_react_17_0_2_react.useImperativeHandle)(ref, () => ({
menu: menuRef.current,
focus: options => {
var _a;
(_a = menuRef.current) === null || _a === void 0 ? void 0 : _a.focus(options);
}
}));
return /*#__PURE__*/_react_17_0_2_react.createElement(menu, Object.assign({
ref: menuRef
}, props, context));
});
Menu.Item = menu_MenuItem;
Menu.SubMenu = menu_SubMenu;
Menu.Divider = menu_MenuDivider;
Menu.ItemGroup = es/* ItemGroup */.BW;
if (false) {}
/* harmony default export */ var es_menu = (Menu);
/***/ })
}]);