const require_runtime = require("../../_virtual/_rolldown/runtime.js");
const require_objectSpread2 = require("../../_virtual/_@oxc-project_runtime@0.122.0/helpers/objectSpread2.js");
const require_objectWithoutProperties = require("../../_virtual/_@oxc-project_runtime@0.122.0/helpers/objectWithoutProperties.js");
let react = require("react");
react = require_runtime.__toESM(react);
let antd = require("antd");
let dayjs = require("dayjs");
dayjs = require_runtime.__toESM(dayjs);
require("dayjs/locale/zh-cn");
let antd_es_locale_zh_CN = require("antd/es/locale/zh_CN");
antd_es_locale_zh_CN = require_runtime.__toESM(antd_es_locale_zh_CN);
require("dayjs/locale/ja");
require("dayjs/locale/pt");
//#region src/components/config-provider/index.tsx
const _excluded = ["locale"];
const ConfigProvider = (props) => {
	const { locale } = props, rest = require_objectWithoutProperties._objectWithoutProperties(props, _excluded);
	let localeData = locale;
	if (typeof locale === "string") {
		if (locale.toLowerCase() === "zh-cn") {
			dayjs.default.locale("zh-cn");
			localeData = antd_es_locale_zh_CN.default;
		} else if (locale.toLowerCase() === "en-us") {
			dayjs.default.locale("en");
			localeData = void 0;
		} else if (locale.toLowerCase() === "ja") dayjs.default.locale("ja");
		else if (locale.toLowerCase() === "pt") dayjs.default.locale("pt");
	}
	return /* @__PURE__ */ react.default.createElement(antd.ConfigProvider, require_objectSpread2._objectSpread2({ locale: localeData }, rest));
};
//#endregion
exports.default = ConfigProvider;
