This commit is contained in:
2026-05-25 17:08:18 +08:00
parent df501f6151
commit f1259b71b5
9178 changed files with 1626125 additions and 0 deletions
+29
View File
@@ -0,0 +1,29 @@
function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
import { clsx } from 'clsx';
import CSSMotion from '@rc-component/motion';
import * as React from 'react';
export default function Mask(props) {
const {
prefixCls,
open,
zIndex,
mask,
motion,
mobile
} = props;
if (!mask) {
return null;
}
return /*#__PURE__*/React.createElement(CSSMotion, _extends({}, motion, {
motionAppear: true,
visible: open,
removeOnLeave: true
}), ({
className
}) => /*#__PURE__*/React.createElement("div", {
style: {
zIndex
},
className: clsx(`${prefixCls}-mask`, mobile && `${prefixCls}-mobile-mask`, className)
}));
}