@windrun-huaiin/third-ui 5.2.0 → 5.3.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.
- package/dist/fuma/mdx/index.js +39 -17
- package/dist/fuma/mdx/index.js.map +1 -1
- package/dist/fuma/mdx/index.mjs +40 -18
- package/dist/fuma/mdx/index.mjs.map +1 -1
- package/dist/main/index.js +14 -0
- package/dist/main/index.js.map +1 -1
- package/dist/main/index.mjs +14 -0
- package/dist/main/index.mjs.map +1 -1
- package/package.json +1 -1
- package/src/fuma/mdx/zia-card.tsx +36 -7
- package/src/fuma/mdx/zia-file.tsx +15 -13
- package/src/main/footer.tsx +12 -0
package/dist/fuma/mdx/index.js
CHANGED
|
@@ -2533,24 +2533,46 @@ function cn(...inputs) {
|
|
|
2533
2533
|
}
|
|
2534
2534
|
|
|
2535
2535
|
// src/fuma/mdx/zia-card.tsx
|
|
2536
|
-
var import_link2 = __toESM(require("
|
|
2536
|
+
var import_link2 = __toESM(require("next/link"));
|
|
2537
2537
|
var import_jsx_runtime34 = require("react/jsx-runtime");
|
|
2538
2538
|
function ZiaCard(_a) {
|
|
2539
2539
|
var _b = _a, { icon, title, description } = _b, props = __objRest(_b, ["icon", "title", "description"]);
|
|
2540
|
-
const
|
|
2540
|
+
const validHref = typeof props.href === "string" && props.href.trim() !== "";
|
|
2541
|
+
const validDescription = typeof description === "string" && (description == null ? void 0 : description.trim()) !== "";
|
|
2542
|
+
if (validHref) {
|
|
2543
|
+
return /* @__PURE__ */ (0, import_jsx_runtime34.jsxs)(
|
|
2544
|
+
import_link2.default,
|
|
2545
|
+
__spreadProps(__spreadValues({
|
|
2546
|
+
href: props.href,
|
|
2547
|
+
"data-card": true,
|
|
2548
|
+
className: cn(
|
|
2549
|
+
"block rounded-lg border bg-fd-card p-4 text-fd-card-foreground shadow-md transition-colors @max-lg:col-span-full",
|
|
2550
|
+
"hover:bg-fd-accent/80",
|
|
2551
|
+
props.className
|
|
2552
|
+
)
|
|
2553
|
+
}, props), {
|
|
2554
|
+
children: [
|
|
2555
|
+
/* @__PURE__ */ (0, import_jsx_runtime34.jsx)("div", { className: "not-prose mb-2 w-fit rounded-md border bg-fd-muted p-1.5 text-fd-muted-foreground [&_svg]:size-4", children: icon ? icon : /* @__PURE__ */ (0, import_jsx_runtime34.jsx)(globalLucideIcons.CircleSmall, {}) }),
|
|
2556
|
+
/* @__PURE__ */ (0, import_jsx_runtime34.jsx)("h3", { className: "not-prose mb-1 text-sm font-medium line-clamp-2 min-h-[2.5rem]", children: title }),
|
|
2557
|
+
validDescription ? /* @__PURE__ */ (0, import_jsx_runtime34.jsx)("p", { className: "!my-0 text-sm text-fd-muted-foreground", children: description }) : /* @__PURE__ */ (0, import_jsx_runtime34.jsx)("p", { className: "!my-0 text-sm text-fd-muted-foreground opacity-0 select-none", children: "\xA0" }),
|
|
2558
|
+
props.children ? /* @__PURE__ */ (0, import_jsx_runtime34.jsx)("div", { className: "text-sm text-fd-muted-foreground prose-no-margin", children: props.children }) : null
|
|
2559
|
+
]
|
|
2560
|
+
})
|
|
2561
|
+
);
|
|
2562
|
+
}
|
|
2541
2563
|
return /* @__PURE__ */ (0, import_jsx_runtime34.jsxs)(
|
|
2542
|
-
|
|
2543
|
-
__spreadProps(__spreadValues({
|
|
2564
|
+
"div",
|
|
2565
|
+
__spreadProps(__spreadValues({
|
|
2544
2566
|
"data-card": true,
|
|
2545
2567
|
className: cn(
|
|
2546
2568
|
"block rounded-lg border bg-fd-card p-4 text-fd-card-foreground shadow-md transition-colors @max-lg:col-span-full",
|
|
2547
|
-
props.href && "hover:bg-fd-accent/80",
|
|
2548
2569
|
props.className
|
|
2549
|
-
)
|
|
2570
|
+
)
|
|
2571
|
+
}, props), {
|
|
2550
2572
|
children: [
|
|
2551
2573
|
/* @__PURE__ */ (0, import_jsx_runtime34.jsx)("div", { className: "not-prose mb-2 w-fit rounded-md border bg-fd-muted p-1.5 text-fd-muted-foreground [&_svg]:size-4", children: icon ? icon : /* @__PURE__ */ (0, import_jsx_runtime34.jsx)(globalLucideIcons.CircleSmall, {}) }),
|
|
2552
2574
|
/* @__PURE__ */ (0, import_jsx_runtime34.jsx)("h3", { className: "not-prose mb-1 text-sm font-medium line-clamp-2 min-h-[2.5rem]", children: title }),
|
|
2553
|
-
|
|
2575
|
+
validDescription ? /* @__PURE__ */ (0, import_jsx_runtime34.jsx)("p", { className: "!my-0 text-sm text-fd-muted-foreground", children: description }) : /* @__PURE__ */ (0, import_jsx_runtime34.jsx)("p", { className: "!my-0 text-sm text-fd-muted-foreground opacity-0 select-none", children: "\xA0" }),
|
|
2554
2576
|
props.children ? /* @__PURE__ */ (0, import_jsx_runtime34.jsx)("div", { className: "text-sm text-fd-muted-foreground prose-no-margin", children: props.children }) : null
|
|
2555
2577
|
]
|
|
2556
2578
|
})
|
|
@@ -3104,7 +3126,7 @@ function SiteX(_a) {
|
|
|
3104
3126
|
// src/fuma/mdx/zia-file.tsx
|
|
3105
3127
|
var import_react37 = require("react");
|
|
3106
3128
|
var import_collapsible = require("fumadocs-ui/components/ui/collapsible");
|
|
3107
|
-
var
|
|
3129
|
+
var import_link5 = __toESM(require("next/link"));
|
|
3108
3130
|
var import_jsx_runtime43 = require("react/jsx-runtime");
|
|
3109
3131
|
var itemVariants = "flex flex-row items-center gap-2 rounded-md px-2 py-1.5 text-sm hover:bg-fd-accent hover:text-fd-accent-foreground [&_svg]:size-4";
|
|
3110
3132
|
var anotionClass = "ms-2 px-2 py-0.5 rounded text-xs font-semibold bg-fd-accent/80 text-fd-accent-foreground dark:bg-white/20 dark:text-white";
|
|
@@ -3123,19 +3145,19 @@ function ZiaFile(_a) {
|
|
|
3123
3145
|
"href"
|
|
3124
3146
|
]);
|
|
3125
3147
|
const validHref = typeof href === "string" && href.trim() !== "";
|
|
3126
|
-
const Comp = validHref ? "a" : "div";
|
|
3127
3148
|
const validAnotion = typeof anotion === "string" && anotion.trim() !== "";
|
|
3128
|
-
|
|
3129
|
-
|
|
3130
|
-
__spreadValues(__spreadValues({
|
|
3131
|
-
className: cn(itemVariants, className)
|
|
3132
|
-
}, validHref ? { href, target: "_blank", rel: "noopener noreferrer" } : {}), rest),
|
|
3133
|
-
/* @__PURE__ */ (0, import_jsx_runtime43.jsxs)(import_jsx_runtime43.Fragment, { children: [
|
|
3149
|
+
if (validHref) {
|
|
3150
|
+
return /* @__PURE__ */ (0, import_jsx_runtime43.jsxs)(import_link5.default, { href, className: cn(itemVariants, className), children: [
|
|
3134
3151
|
icon,
|
|
3135
3152
|
/* @__PURE__ */ (0, import_jsx_runtime43.jsx)("span", { children: name }),
|
|
3136
3153
|
validAnotion && /* @__PURE__ */ (0, import_jsx_runtime43.jsx)("span", { className: anotionClass, children: anotion })
|
|
3137
|
-
] })
|
|
3138
|
-
|
|
3154
|
+
] });
|
|
3155
|
+
}
|
|
3156
|
+
return /* @__PURE__ */ (0, import_jsx_runtime43.jsxs)("div", __spreadProps(__spreadValues({ className: cn(itemVariants, className) }, rest), { children: [
|
|
3157
|
+
icon,
|
|
3158
|
+
/* @__PURE__ */ (0, import_jsx_runtime43.jsx)("span", { children: name }),
|
|
3159
|
+
validAnotion && /* @__PURE__ */ (0, import_jsx_runtime43.jsx)("span", { className: anotionClass, children: anotion })
|
|
3160
|
+
] }));
|
|
3139
3161
|
}
|
|
3140
3162
|
function ZiaFolder(_a) {
|
|
3141
3163
|
var _b = _a, {
|