@windrun-huaiin/third-ui 5.10.2 → 5.11.0

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.
@@ -6592,7 +6592,7 @@ module.exports = __toCommonJS(server_exports);
6592
6592
 
6593
6593
  // src/fuma/fuma-page-genarator.tsx
6594
6594
  var import_page = require("fumadocs-ui/page");
6595
- var import_react41 = require("react");
6595
+ var import_react42 = require("react");
6596
6596
 
6597
6597
  // ../base-ui/src/assets/github.tsx
6598
6598
  var import_react = __toESM(require("react"), 1);
@@ -9378,46 +9378,10 @@ function getElementRef(element) {
9378
9378
  return element.props.ref || element.ref;
9379
9379
  }
9380
9380
 
9381
- // ../../node_modules/.pnpm/class-variance-authority@0.7.1/node_modules/class-variance-authority/dist/index.mjs
9382
- var import_clsx2 = require("clsx");
9383
- var falsyToString = (value2) => typeof value2 === "boolean" ? `${value2}` : value2 === 0 ? "0" : value2;
9384
- var cx = import_clsx2.clsx;
9385
- var cva = (base, config) => (props) => {
9386
- var _config_compoundVariants;
9387
- if ((config === null || config === void 0 ? void 0 : config.variants) == null) return cx(base, props === null || props === void 0 ? void 0 : props.class, props === null || props === void 0 ? void 0 : props.className);
9388
- const { variants, defaultVariants } = config;
9389
- const getVariantClassNames = Object.keys(variants).map((variant) => {
9390
- const variantProp = props === null || props === void 0 ? void 0 : props[variant];
9391
- const defaultVariantProp = defaultVariants === null || defaultVariants === void 0 ? void 0 : defaultVariants[variant];
9392
- if (variantProp === null) return null;
9393
- const variantKey = falsyToString(variantProp) || falsyToString(defaultVariantProp);
9394
- return variants[variant][variantKey];
9395
- });
9396
- const propsWithoutUndefined = props && Object.entries(props).reduce((acc, param) => {
9397
- let [key, value2] = param;
9398
- if (value2 === void 0) {
9399
- return acc;
9400
- }
9401
- acc[key] = value2;
9402
- return acc;
9403
- }, {});
9404
- const getCompoundVariantClassNames = config === null || config === void 0 ? void 0 : (_config_compoundVariants = config.compoundVariants) === null || _config_compoundVariants === void 0 ? void 0 : _config_compoundVariants.reduce((acc, param) => {
9405
- let _a = param, { class: cvClass, className: cvClassName } = _a, compoundVariantOptions = __objRest(_a, ["class", "className"]);
9406
- return Object.entries(compoundVariantOptions).every((param2) => {
9407
- let [key, value2] = param2;
9408
- return Array.isArray(value2) ? value2.includes(__spreadValues(__spreadValues({}, defaultVariants), propsWithoutUndefined)[key]) : __spreadValues(__spreadValues({}, defaultVariants), propsWithoutUndefined)[key] === value2;
9409
- }) ? [
9410
- ...acc,
9411
- cvClass,
9412
- cvClassName
9413
- ] : acc;
9414
- }, []);
9415
- return cx(base, getVariantClassNames, getCompoundVariantClassNames, props === null || props === void 0 ? void 0 : props.class, props === null || props === void 0 ? void 0 : props.className);
9416
- };
9417
-
9418
9381
  // ../base-ui/src/ui/button.tsx
9382
+ var import_class_variance_authority = require("class-variance-authority");
9419
9383
  var import_jsx_runtime39 = require("react/jsx-runtime");
9420
- var buttonVariants = cva(
9384
+ var buttonVariants = (0, import_class_variance_authority.cva)(
9421
9385
  "inline-flex items-center gap-2 whitespace-nowrap rounded-md text-sm ring-offset-background transition-colors focus-visible:outline-hidden focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:pointer-events-none disabled:opacity-50 [&_svg]:pointer-events-none [&_svg]:size-4 [&_svg]:shrink-0",
9422
9386
  {
9423
9387
  variants: {
@@ -9507,38 +9471,60 @@ function LastUpdatedDate({ date }) {
9507
9471
  ] });
9508
9472
  }
9509
9473
 
9474
+ // src/fuma/mdx/banner.tsx
9475
+ var import_class_variance_authority2 = require("class-variance-authority");
9476
+ var import_react39 = require("react");
9477
+ var import_jsx_runtime42 = require("react/jsx-runtime");
9478
+ var buttonVariants2 = (0, import_class_variance_authority2.cva)(
9479
+ "inline-flex items-center justify-center rounded-md p-2 text-sm font-medium transition-colors duration-100 disabled:pointer-events-none disabled:opacity-50",
9480
+ {
9481
+ variants: {
9482
+ color: {
9483
+ primary: "bg-primary text-primary-foreground hover:bg-primary/80",
9484
+ outline: "border hover:bg-accent hover:text-accent-foreground",
9485
+ ghost: "hover:bg-accent hover:text-accent-foreground",
9486
+ secondary: "border bg-secondary text-secondary-foreground hover:bg-accent hover:text-accent-foreground"
9487
+ },
9488
+ size: {
9489
+ sm: "gap-1 px-2 py-1.5 text-xs",
9490
+ icon: "p-1.5 [&_svg]:size-5",
9491
+ "icon-sm": "p-1.5 [&_svg]:size-4.5"
9492
+ }
9493
+ }
9494
+ }
9495
+ );
9496
+
9510
9497
  // src/fuma/mdx/fuma-banner-suit.tsx
9511
- var import_banner = require("fumadocs-ui/components/banner");
9512
9498
  var import_next_intl = require("next-intl");
9513
- var import_jsx_runtime42 = require("react/jsx-runtime");
9499
+ var import_jsx_runtime43 = require("react/jsx-runtime");
9514
9500
 
9515
9501
  // src/fuma/mdx/fuma-github-info.tsx
9516
- var import_react39 = require("react");
9517
- var import_jsx_runtime43 = require("react/jsx-runtime");
9502
+ var import_react40 = require("react");
9503
+ var import_jsx_runtime44 = require("react/jsx-runtime");
9518
9504
 
9519
9505
  // src/fuma/mdx/site-x.tsx
9520
9506
  var import_next_intl2 = require("next-intl");
9521
- var import_jsx_runtime44 = require("react/jsx-runtime");
9507
+ var import_jsx_runtime45 = require("react/jsx-runtime");
9522
9508
 
9523
9509
  // src/fuma/mdx/zia-file.tsx
9524
- var import_react40 = require("react");
9510
+ var import_react41 = require("react");
9525
9511
  var import_collapsible = require("fumadocs-ui/components/ui/collapsible");
9526
9512
  var import_link5 = __toESM(require("next/link"));
9527
- var import_jsx_runtime45 = require("react/jsx-runtime");
9513
+ var import_jsx_runtime46 = require("react/jsx-runtime");
9528
9514
 
9529
9515
  // src/fuma/mdx/toc-footer-wrapper.tsx
9530
- var import_jsx_runtime46 = require("react/jsx-runtime");
9516
+ var import_jsx_runtime47 = require("react/jsx-runtime");
9531
9517
  function TocFooterWrapper({ lastModified, editPath, githubBaseUrl, copyButtonComponent }) {
9532
9518
  const showEdit = githubBaseUrl && editPath;
9533
- return /* @__PURE__ */ (0, import_jsx_runtime46.jsxs)("div", { className: "flex flex-col gap-y-2 items-start m-4", children: [
9534
- /* @__PURE__ */ (0, import_jsx_runtime46.jsx)(LastUpdatedDate, { date: lastModified }),
9519
+ return /* @__PURE__ */ (0, import_jsx_runtime47.jsxs)("div", { className: "flex flex-col gap-y-2 items-start m-4", children: [
9520
+ /* @__PURE__ */ (0, import_jsx_runtime47.jsx)(LastUpdatedDate, { date: lastModified }),
9535
9521
  copyButtonComponent,
9536
- showEdit && /* @__PURE__ */ (0, import_jsx_runtime46.jsx)(EditOnGitHub, { url: `${githubBaseUrl}${editPath}` })
9522
+ showEdit && /* @__PURE__ */ (0, import_jsx_runtime47.jsx)(EditOnGitHub, { url: `${githubBaseUrl}${editPath}` })
9537
9523
  ] });
9538
9524
  }
9539
9525
 
9540
9526
  // src/fuma/fuma-page-genarator.tsx
9541
- var import_jsx_runtime47 = require("react/jsx-runtime");
9527
+ var import_jsx_runtime48 = require("react/jsx-runtime");
9542
9528
  function createFumaPage({
9543
9529
  sourceKey,
9544
9530
  mdxContentSource,
@@ -9554,20 +9540,20 @@ function createFumaPage({
9554
9540
  const { slug, locale } = yield params;
9555
9541
  const page = mdxContentSource.getPage(slug, locale);
9556
9542
  if (!page) {
9557
- return /* @__PURE__ */ (0, import_jsx_runtime47.jsx)(FallbackPage, { siteIcon });
9543
+ return /* @__PURE__ */ (0, import_jsx_runtime48.jsx)(FallbackPage, { siteIcon });
9558
9544
  }
9559
9545
  const path2 = githubBaseUrl ? `${mdxSourceDir}/${page.file.path}` : void 0;
9560
- const tocFooterElement = /* @__PURE__ */ (0, import_jsx_runtime47.jsx)(
9546
+ const tocFooterElement = /* @__PURE__ */ (0, import_jsx_runtime48.jsx)(
9561
9547
  TocFooterWrapper,
9562
9548
  {
9563
9549
  lastModified: page.data.date,
9564
- copyButtonComponent: copyButtonComponent ? (0, import_react41.cloneElement)(copyButtonComponent, { sourceKey }) : void 0,
9550
+ copyButtonComponent: copyButtonComponent ? (0, import_react42.cloneElement)(copyButtonComponent, { sourceKey }) : void 0,
9565
9551
  editPath: path2,
9566
9552
  githubBaseUrl
9567
9553
  }
9568
9554
  );
9569
9555
  const MDX = page.data.body;
9570
- return /* @__PURE__ */ (0, import_jsx_runtime47.jsxs)(
9556
+ return /* @__PURE__ */ (0, import_jsx_runtime48.jsxs)(
9571
9557
  import_page.DocsPage,
9572
9558
  {
9573
9559
  tableOfContent: { style: "clerk", single: false, footer: tocFooterElement },
@@ -9576,9 +9562,9 @@ function createFumaPage({
9576
9562
  full: page.data.full,
9577
9563
  article: { className: "max-sm:pb-16" },
9578
9564
  children: [
9579
- /* @__PURE__ */ (0, import_jsx_runtime47.jsx)(import_page.DocsTitle, { children: page.data.title }),
9580
- /* @__PURE__ */ (0, import_jsx_runtime47.jsx)(import_page.DocsDescription, { className: "mb-2", children: page.data.description }),
9581
- /* @__PURE__ */ (0, import_jsx_runtime47.jsx)(import_page.DocsBody, { className: "text-fd-foreground/80", children: /* @__PURE__ */ (0, import_jsx_runtime47.jsx)(MDX, { components: getMDXComponents() }) })
9565
+ /* @__PURE__ */ (0, import_jsx_runtime48.jsx)(import_page.DocsTitle, { children: page.data.title }),
9566
+ /* @__PURE__ */ (0, import_jsx_runtime48.jsx)(import_page.DocsDescription, { className: "mb-2", children: page.data.description }),
9567
+ /* @__PURE__ */ (0, import_jsx_runtime48.jsx)(import_page.DocsBody, { className: "text-fd-foreground/80", children: /* @__PURE__ */ (0, import_jsx_runtime48.jsx)(MDX, { components: getMDXComponents() }) })
9582
9568
  ]
9583
9569
  }
9584
9570
  );