Update from Vibe Studio

This commit is contained in:
Vibe Studio
2026-01-12 09:12:41 +00:00
parent a4605e311a
commit a6ae5199b0
29756 changed files with 2526222 additions and 278 deletions

View File

@@ -0,0 +1,16 @@
import React from 'react';
import type { WithFalse } from '../../typing';
export type GlobalFooterProps = {
links?: WithFalse<{
key?: string;
title: React.ReactNode;
href: string;
blankTarget?: boolean;
}[]>;
copyright?: React.ReactNode;
style?: React.CSSProperties;
prefixCls?: string;
className?: string;
};
declare const GlobalFooter: ({ className, prefixCls, links, copyright, style, }: GlobalFooterProps) => React.JSX.Element | null;
export { GlobalFooter };

View File

@@ -0,0 +1,42 @@
import { ConfigProvider } from 'antd';
import classNames from 'classnames';
import React, { useContext } from 'react';
import { useStyle } from "./style";
import { jsx as _jsx } from "react/jsx-runtime";
import { jsxs as _jsxs } from "react/jsx-runtime";
var GlobalFooter = function GlobalFooter(_ref) {
var className = _ref.className,
prefixCls = _ref.prefixCls,
links = _ref.links,
copyright = _ref.copyright,
style = _ref.style;
var context = useContext(ConfigProvider.ConfigContext);
var baseClassName = context.getPrefixCls(prefixCls || 'pro-global-footer');
var _useStyle = useStyle(baseClassName),
wrapSSR = _useStyle.wrapSSR,
hashId = _useStyle.hashId;
if ((links == null || links === false || Array.isArray(links) && links.length === 0) && (copyright == null || copyright === false)) {
return null;
}
return wrapSSR( /*#__PURE__*/_jsxs("div", {
className: classNames(baseClassName, hashId, className),
style: style,
children: [links && /*#__PURE__*/_jsx("div", {
className: "".concat(baseClassName, "-list ").concat(hashId).trim(),
children: links.map(function (link) {
return /*#__PURE__*/_jsx("a", {
className: "".concat(baseClassName, "-list-link ").concat(hashId).trim(),
title: link.key,
target: link.blankTarget ? '_blank' : '_self',
href: link.href,
rel: "noreferrer",
children: link.title
}, link.key);
})
}), copyright && /*#__PURE__*/_jsx("div", {
className: "".concat(baseClassName, "-copyright ").concat(hashId).trim(),
children: copyright
})]
}));
};
export { GlobalFooter };

View File

@@ -0,0 +1,10 @@
/// <reference types="react" />
import type { ProAliasToken } from '@ant-design/pro-provider';
export interface GlobalFooterToken extends ProAliasToken {
componentCls: string;
probgLayout?: string;
}
export declare function useStyle(prefixCls: string): {
wrapSSR: (node: import("react").ReactElement<any, string | import("react").JSXElementConstructor<any>>) => import("react").JSX.Element;
hashId: string;
};

View File

@@ -0,0 +1,40 @@
import _objectSpread from "@babel/runtime/helpers/esm/objectSpread2";
import _defineProperty from "@babel/runtime/helpers/esm/defineProperty";
import { useStyle as useAntdStyle } from '@ant-design/pro-provider';
var genFooterToolBarStyle = function genFooterToolBarStyle(token) {
return _defineProperty({}, token.componentCls, {
marginBlock: 0,
marginBlockStart: 48,
marginBlockEnd: 24,
marginInline: 0,
paddingBlock: 0,
paddingInline: 16,
textAlign: 'center',
'&-list': {
marginBlockEnd: 8,
color: token.colorTextSecondary,
'&-link': {
color: token.colorTextSecondary,
textDecoration: token.linkDecoration
},
'*:not(:last-child)': {
marginInlineEnd: 8
},
'&:hover': {
color: token.colorPrimary
}
},
'&-copyright': {
fontSize: '14px',
color: token.colorText
}
});
};
export function useStyle(prefixCls) {
return useAntdStyle('ProLayoutFooter', function (token) {
var proCardToken = _objectSpread(_objectSpread({}, token), {}, {
componentCls: ".".concat(prefixCls)
});
return [genFooterToolBarStyle(proCardToken)];
});
}