@medialane/ui 0.91.0 → 0.93.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.
@@ -0,0 +1,89 @@
1
+ "use strict";
2
+ "use client";
3
+ var __create = Object.create;
4
+ var __defProp = Object.defineProperty;
5
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
6
+ var __getOwnPropNames = Object.getOwnPropertyNames;
7
+ var __getProtoOf = Object.getPrototypeOf;
8
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
9
+ var __export = (target, all) => {
10
+ for (var name in all)
11
+ __defProp(target, name, { get: all[name], enumerable: true });
12
+ };
13
+ var __copyProps = (to, from, except, desc) => {
14
+ if (from && typeof from === "object" || typeof from === "function") {
15
+ for (let key of __getOwnPropNames(from))
16
+ if (!__hasOwnProp.call(to, key) && key !== except)
17
+ __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
18
+ }
19
+ return to;
20
+ };
21
+ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
22
+ // If the importer is in node compatibility mode or this is not an ESM
23
+ // file that has been converted to a CommonJS file using a Babel-
24
+ // compatible transform (i.e. "__esModule" has not been set), then set
25
+ // "default" to the CommonJS "module.exports" for node compatibility.
26
+ isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
27
+ mod
28
+ ));
29
+ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
30
+ var portfolio_bento_tile_exports = {};
31
+ __export(portfolio_bento_tile_exports, {
32
+ PortfolioBentoTile: () => PortfolioBentoTile
33
+ });
34
+ module.exports = __toCommonJS(portfolio_bento_tile_exports);
35
+ var import_jsx_runtime = require("react/jsx-runtime");
36
+ var import_link = __toESM(require("next/link"), 1);
37
+ var import_lucide_react = require("lucide-react");
38
+ var import_cn = require("../utils/cn.js");
39
+ const SIZE_CLASS = {
40
+ wide: "md:col-span-4 md:row-span-1",
41
+ tall: "md:col-span-2 md:row-span-2",
42
+ compact: "md:col-span-2 md:row-span-1"
43
+ };
44
+ function PortfolioBentoTile({
45
+ title,
46
+ href,
47
+ size = "compact",
48
+ action,
49
+ isEmpty,
50
+ emptyState,
51
+ children,
52
+ className
53
+ }) {
54
+ return /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(
55
+ "section",
56
+ {
57
+ className: (0, import_cn.cn)(
58
+ "rounded-2xl border border-border bg-card p-4 space-y-3 min-w-0",
59
+ SIZE_CLASS[size],
60
+ className
61
+ ),
62
+ children: [
63
+ /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", { className: "flex items-center justify-between gap-3", children: [
64
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)("h2", { className: "text-sm font-semibold text-foreground", children: title }),
65
+ /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", { className: "flex items-center gap-2 shrink-0", children: [
66
+ action,
67
+ /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(
68
+ import_link.default,
69
+ {
70
+ href,
71
+ className: "inline-flex items-center gap-1 text-xs font-medium text-muted-foreground hover:text-foreground transition-colors",
72
+ children: [
73
+ "See all",
74
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_lucide_react.ArrowRight, { className: "h-3 w-3" })
75
+ ]
76
+ }
77
+ )
78
+ ] })
79
+ ] }),
80
+ isEmpty ? emptyState : children
81
+ ]
82
+ }
83
+ );
84
+ }
85
+ // Annotate the CommonJS export names for ESM import in node:
86
+ 0 && (module.exports = {
87
+ PortfolioBentoTile
88
+ });
89
+ //# sourceMappingURL=portfolio-bento-tile.cjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../../src/components/portfolio-bento-tile.tsx"],"sourcesContent":["\"use client\";\n\nimport Link from \"next/link\";\nimport { ArrowRight } from \"lucide-react\";\nimport { cn } from \"../utils/cn.js\";\n\nexport interface PortfolioBentoTileProps {\n /** Tile heading, e.g. \"Collections\". */\n title: string;\n /** \"See all\" link target — also the tile's own click-through when there's no in-tile action. */\n href: string;\n /** Grid footprint. \"wide\" = full row, \"tall\" = 2 rows media-forward, \"compact\" = quarter width. */\n size?: \"wide\" | \"tall\" | \"compact\";\n /** Single primary in-tile action, rendered top-right of the tile header (e.g. a \"List\" button). */\n action?: React.ReactNode;\n /** True when this tile's content is empty — renders emptyState instead of children. */\n isEmpty?: boolean;\n emptyState?: React.ReactNode;\n children: React.ReactNode;\n className?: string;\n}\n\nconst SIZE_CLASS: Record<NonNullable<PortfolioBentoTileProps[\"size\"]>, string> = {\n wide: \"md:col-span-4 md:row-span-1\",\n tall: \"md:col-span-2 md:row-span-2\",\n compact: \"md:col-span-2 md:row-span-1\",\n};\n\n/**\n * A single bento cell on the portfolio landing page: a titled, media-forward\n * preview of one section (Collections, Assets, Tickets & memberships,\n * Activity) with an optional single primary action, expanding into its full\n * subpage via \"See all\" or the tile's own content links. Pure presentation —\n * content is supplied by the caller as children.\n */\nexport function PortfolioBentoTile({\n title,\n href,\n size = \"compact\",\n action,\n isEmpty,\n emptyState,\n children,\n className,\n}: PortfolioBentoTileProps) {\n return (\n <section\n className={cn(\n \"rounded-2xl border border-border bg-card p-4 space-y-3 min-w-0\",\n SIZE_CLASS[size],\n className,\n )}\n >\n <div className=\"flex items-center justify-between gap-3\">\n <h2 className=\"text-sm font-semibold text-foreground\">{title}</h2>\n <div className=\"flex items-center gap-2 shrink-0\">\n {action}\n <Link\n href={href}\n className=\"inline-flex items-center gap-1 text-xs font-medium text-muted-foreground hover:text-foreground transition-colors\"\n >\n See all\n <ArrowRight className=\"h-3 w-3\" />\n </Link>\n </div>\n </div>\n {isEmpty ? emptyState : children}\n </section>\n );\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAsDQ;AApDR,kBAAiB;AACjB,0BAA2B;AAC3B,gBAAmB;AAkBnB,MAAM,aAA2E;AAAA,EAC/E,MAAM;AAAA,EACN,MAAM;AAAA,EACN,SAAS;AACX;AASO,SAAS,mBAAmB;AAAA,EACjC;AAAA,EACA;AAAA,EACA,OAAO;AAAA,EACP;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AACF,GAA4B;AAC1B,SACE;AAAA,IAAC;AAAA;AAAA,MACC,eAAW;AAAA,QACT;AAAA,QACA,WAAW,IAAI;AAAA,QACf;AAAA,MACF;AAAA,MAEA;AAAA,qDAAC,SAAI,WAAU,2CACb;AAAA,sDAAC,QAAG,WAAU,yCAAyC,iBAAM;AAAA,UAC7D,6CAAC,SAAI,WAAU,oCACZ;AAAA;AAAA,YACD;AAAA,cAAC,YAAAA;AAAA,cAAA;AAAA,gBACC;AAAA,gBACA,WAAU;AAAA,gBACX;AAAA;AAAA,kBAEC,4CAAC,kCAAW,WAAU,WAAU;AAAA;AAAA;AAAA,YAClC;AAAA,aACF;AAAA,WACF;AAAA,QACC,UAAU,aAAa;AAAA;AAAA;AAAA,EAC1B;AAEJ;","names":["Link"]}
@@ -0,0 +1,27 @@
1
+ import * as react_jsx_runtime from 'react/jsx-runtime';
2
+
3
+ interface PortfolioBentoTileProps {
4
+ /** Tile heading, e.g. "Collections". */
5
+ title: string;
6
+ /** "See all" link target — also the tile's own click-through when there's no in-tile action. */
7
+ href: string;
8
+ /** Grid footprint. "wide" = full row, "tall" = 2 rows media-forward, "compact" = quarter width. */
9
+ size?: "wide" | "tall" | "compact";
10
+ /** Single primary in-tile action, rendered top-right of the tile header (e.g. a "List" button). */
11
+ action?: React.ReactNode;
12
+ /** True when this tile's content is empty — renders emptyState instead of children. */
13
+ isEmpty?: boolean;
14
+ emptyState?: React.ReactNode;
15
+ children: React.ReactNode;
16
+ className?: string;
17
+ }
18
+ /**
19
+ * A single bento cell on the portfolio landing page: a titled, media-forward
20
+ * preview of one section (Collections, Assets, Tickets & memberships,
21
+ * Activity) with an optional single primary action, expanding into its full
22
+ * subpage via "See all" or the tile's own content links. Pure presentation —
23
+ * content is supplied by the caller as children.
24
+ */
25
+ declare function PortfolioBentoTile({ title, href, size, action, isEmpty, emptyState, children, className, }: PortfolioBentoTileProps): react_jsx_runtime.JSX.Element;
26
+
27
+ export { PortfolioBentoTile, type PortfolioBentoTileProps };
@@ -0,0 +1,27 @@
1
+ import * as react_jsx_runtime from 'react/jsx-runtime';
2
+
3
+ interface PortfolioBentoTileProps {
4
+ /** Tile heading, e.g. "Collections". */
5
+ title: string;
6
+ /** "See all" link target — also the tile's own click-through when there's no in-tile action. */
7
+ href: string;
8
+ /** Grid footprint. "wide" = full row, "tall" = 2 rows media-forward, "compact" = quarter width. */
9
+ size?: "wide" | "tall" | "compact";
10
+ /** Single primary in-tile action, rendered top-right of the tile header (e.g. a "List" button). */
11
+ action?: React.ReactNode;
12
+ /** True when this tile's content is empty — renders emptyState instead of children. */
13
+ isEmpty?: boolean;
14
+ emptyState?: React.ReactNode;
15
+ children: React.ReactNode;
16
+ className?: string;
17
+ }
18
+ /**
19
+ * A single bento cell on the portfolio landing page: a titled, media-forward
20
+ * preview of one section (Collections, Assets, Tickets & memberships,
21
+ * Activity) with an optional single primary action, expanding into its full
22
+ * subpage via "See all" or the tile's own content links. Pure presentation —
23
+ * content is supplied by the caller as children.
24
+ */
25
+ declare function PortfolioBentoTile({ title, href, size, action, isEmpty, emptyState, children, className, }: PortfolioBentoTileProps): react_jsx_runtime.JSX.Element;
26
+
27
+ export { PortfolioBentoTile, type PortfolioBentoTileProps };
@@ -0,0 +1,55 @@
1
+ "use client";
2
+ import { jsx, jsxs } from "react/jsx-runtime";
3
+ import Link from "next/link";
4
+ import { ArrowRight } from "lucide-react";
5
+ import { cn } from "../utils/cn.js";
6
+ const SIZE_CLASS = {
7
+ wide: "md:col-span-4 md:row-span-1",
8
+ tall: "md:col-span-2 md:row-span-2",
9
+ compact: "md:col-span-2 md:row-span-1"
10
+ };
11
+ function PortfolioBentoTile({
12
+ title,
13
+ href,
14
+ size = "compact",
15
+ action,
16
+ isEmpty,
17
+ emptyState,
18
+ children,
19
+ className
20
+ }) {
21
+ return /* @__PURE__ */ jsxs(
22
+ "section",
23
+ {
24
+ className: cn(
25
+ "rounded-2xl border border-border bg-card p-4 space-y-3 min-w-0",
26
+ SIZE_CLASS[size],
27
+ className
28
+ ),
29
+ children: [
30
+ /* @__PURE__ */ jsxs("div", { className: "flex items-center justify-between gap-3", children: [
31
+ /* @__PURE__ */ jsx("h2", { className: "text-sm font-semibold text-foreground", children: title }),
32
+ /* @__PURE__ */ jsxs("div", { className: "flex items-center gap-2 shrink-0", children: [
33
+ action,
34
+ /* @__PURE__ */ jsxs(
35
+ Link,
36
+ {
37
+ href,
38
+ className: "inline-flex items-center gap-1 text-xs font-medium text-muted-foreground hover:text-foreground transition-colors",
39
+ children: [
40
+ "See all",
41
+ /* @__PURE__ */ jsx(ArrowRight, { className: "h-3 w-3" })
42
+ ]
43
+ }
44
+ )
45
+ ] })
46
+ ] }),
47
+ isEmpty ? emptyState : children
48
+ ]
49
+ }
50
+ );
51
+ }
52
+ export {
53
+ PortfolioBentoTile
54
+ };
55
+ //# sourceMappingURL=portfolio-bento-tile.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../../src/components/portfolio-bento-tile.tsx"],"sourcesContent":["\"use client\";\n\nimport Link from \"next/link\";\nimport { ArrowRight } from \"lucide-react\";\nimport { cn } from \"../utils/cn.js\";\n\nexport interface PortfolioBentoTileProps {\n /** Tile heading, e.g. \"Collections\". */\n title: string;\n /** \"See all\" link target — also the tile's own click-through when there's no in-tile action. */\n href: string;\n /** Grid footprint. \"wide\" = full row, \"tall\" = 2 rows media-forward, \"compact\" = quarter width. */\n size?: \"wide\" | \"tall\" | \"compact\";\n /** Single primary in-tile action, rendered top-right of the tile header (e.g. a \"List\" button). */\n action?: React.ReactNode;\n /** True when this tile's content is empty — renders emptyState instead of children. */\n isEmpty?: boolean;\n emptyState?: React.ReactNode;\n children: React.ReactNode;\n className?: string;\n}\n\nconst SIZE_CLASS: Record<NonNullable<PortfolioBentoTileProps[\"size\"]>, string> = {\n wide: \"md:col-span-4 md:row-span-1\",\n tall: \"md:col-span-2 md:row-span-2\",\n compact: \"md:col-span-2 md:row-span-1\",\n};\n\n/**\n * A single bento cell on the portfolio landing page: a titled, media-forward\n * preview of one section (Collections, Assets, Tickets & memberships,\n * Activity) with an optional single primary action, expanding into its full\n * subpage via \"See all\" or the tile's own content links. Pure presentation —\n * content is supplied by the caller as children.\n */\nexport function PortfolioBentoTile({\n title,\n href,\n size = \"compact\",\n action,\n isEmpty,\n emptyState,\n children,\n className,\n}: PortfolioBentoTileProps) {\n return (\n <section\n className={cn(\n \"rounded-2xl border border-border bg-card p-4 space-y-3 min-w-0\",\n SIZE_CLASS[size],\n className,\n )}\n >\n <div className=\"flex items-center justify-between gap-3\">\n <h2 className=\"text-sm font-semibold text-foreground\">{title}</h2>\n <div className=\"flex items-center gap-2 shrink-0\">\n {action}\n <Link\n href={href}\n className=\"inline-flex items-center gap-1 text-xs font-medium text-muted-foreground hover:text-foreground transition-colors\"\n >\n See all\n <ArrowRight className=\"h-3 w-3\" />\n </Link>\n </div>\n </div>\n {isEmpty ? emptyState : children}\n </section>\n );\n}\n"],"mappings":";AAsDQ,cAGE,YAHF;AApDR,OAAO,UAAU;AACjB,SAAS,kBAAkB;AAC3B,SAAS,UAAU;AAkBnB,MAAM,aAA2E;AAAA,EAC/E,MAAM;AAAA,EACN,MAAM;AAAA,EACN,SAAS;AACX;AASO,SAAS,mBAAmB;AAAA,EACjC;AAAA,EACA;AAAA,EACA,OAAO;AAAA,EACP;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AACF,GAA4B;AAC1B,SACE;AAAA,IAAC;AAAA;AAAA,MACC,WAAW;AAAA,QACT;AAAA,QACA,WAAW,IAAI;AAAA,QACf;AAAA,MACF;AAAA,MAEA;AAAA,6BAAC,SAAI,WAAU,2CACb;AAAA,8BAAC,QAAG,WAAU,yCAAyC,iBAAM;AAAA,UAC7D,qBAAC,SAAI,WAAU,oCACZ;AAAA;AAAA,YACD;AAAA,cAAC;AAAA;AAAA,gBACC;AAAA,gBACA,WAAU;AAAA,gBACX;AAAA;AAAA,kBAEC,oBAAC,cAAW,WAAU,WAAU;AAAA;AAAA;AAAA,YAClC;AAAA,aACF;AAAA,WACF;AAAA,QACC,UAAU,aAAa;AAAA;AAAA;AAAA,EAC1B;AAEJ;","names":[]}
@@ -0,0 +1,65 @@
1
+ "use strict";
2
+ "use client";
3
+ var __defProp = Object.defineProperty;
4
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
5
+ var __getOwnPropNames = Object.getOwnPropertyNames;
6
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
7
+ var __export = (target, all) => {
8
+ for (var name in all)
9
+ __defProp(target, name, { get: all[name], enumerable: true });
10
+ };
11
+ var __copyProps = (to, from, except, desc) => {
12
+ if (from && typeof from === "object" || typeof from === "function") {
13
+ for (let key of __getOwnPropNames(from))
14
+ if (!__hasOwnProp.call(to, key) && key !== except)
15
+ __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
16
+ }
17
+ return to;
18
+ };
19
+ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
20
+ var portfolio_chip_filter_exports = {};
21
+ __export(portfolio_chip_filter_exports, {
22
+ PortfolioChipFilter: () => PortfolioChipFilter
23
+ });
24
+ module.exports = __toCommonJS(portfolio_chip_filter_exports);
25
+ var import_jsx_runtime = require("react/jsx-runtime");
26
+ var import_cn = require("../utils/cn.js");
27
+ function PortfolioChipFilter({
28
+ options,
29
+ value,
30
+ onChange,
31
+ className
32
+ }) {
33
+ const all = { key: "all", label: "All" };
34
+ const items = [all, ...options];
35
+ return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
36
+ "div",
37
+ {
38
+ className: (0, import_cn.cn)(
39
+ "flex items-center gap-1.5 overflow-x-auto scrollbar-hide -mx-4 px-4 sm:-mx-6 sm:px-6 lg:-mx-8 lg:px-8",
40
+ className
41
+ ),
42
+ children: items.map((item) => {
43
+ const active = item.key === value;
44
+ return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
45
+ "button",
46
+ {
47
+ type: "button",
48
+ onClick: () => onChange(item.key),
49
+ className: (0, import_cn.cn)(
50
+ "shrink-0 rounded-full px-3.5 py-1.5 text-[13px] whitespace-nowrap transition-colors",
51
+ active ? "bg-primary text-primary-foreground font-medium" : "bg-muted text-muted-foreground hover:text-foreground"
52
+ ),
53
+ children: item.label
54
+ },
55
+ item.key
56
+ );
57
+ })
58
+ }
59
+ );
60
+ }
61
+ // Annotate the CommonJS export names for ESM import in node:
62
+ 0 && (module.exports = {
63
+ PortfolioChipFilter
64
+ });
65
+ //# sourceMappingURL=portfolio-chip-filter.cjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../../src/components/portfolio-chip-filter.tsx"],"sourcesContent":["\"use client\";\n\nimport { cn } from \"../utils/cn.js\";\n\nexport interface PortfolioChipFilterOption {\n key: string;\n label: string;\n}\n\nexport interface PortfolioChipFilterProps {\n options: PortfolioChipFilterOption[];\n /** Selected option key, or \"all\". */\n value: string;\n onChange: (key: string) => void;\n className?: string;\n}\n\n/**\n * Horizontally-scrollable chip row for fast lateral access across portfolio\n * sections (Instagram/YouTube-style filter chips) — narrows which bento\n * tiles are visible on the same page, never navigates to a different route.\n */\nexport function PortfolioChipFilter({\n options,\n value,\n onChange,\n className,\n}: PortfolioChipFilterProps) {\n const all: PortfolioChipFilterOption = { key: \"all\", label: \"All\" };\n const items = [all, ...options];\n\n return (\n <div\n className={cn(\n \"flex items-center gap-1.5 overflow-x-auto scrollbar-hide -mx-4 px-4 sm:-mx-6 sm:px-6 lg:-mx-8 lg:px-8\",\n className,\n )}\n >\n {items.map((item) => {\n const active = item.key === value;\n return (\n <button\n key={item.key}\n type=\"button\"\n onClick={() => onChange(item.key)}\n className={cn(\n \"shrink-0 rounded-full px-3.5 py-1.5 text-[13px] whitespace-nowrap transition-colors\",\n active\n ? \"bg-primary text-primary-foreground font-medium\"\n : \"bg-muted text-muted-foreground hover:text-foreground\",\n )}\n >\n {item.label}\n </button>\n );\n })}\n </div>\n );\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAyCU;AAvCV,gBAAmB;AAoBZ,SAAS,oBAAoB;AAAA,EAClC;AAAA,EACA;AAAA,EACA;AAAA,EACA;AACF,GAA6B;AAC3B,QAAM,MAAiC,EAAE,KAAK,OAAO,OAAO,MAAM;AAClE,QAAM,QAAQ,CAAC,KAAK,GAAG,OAAO;AAE9B,SACE;AAAA,IAAC;AAAA;AAAA,MACC,eAAW;AAAA,QACT;AAAA,QACA;AAAA,MACF;AAAA,MAEC,gBAAM,IAAI,CAAC,SAAS;AACnB,cAAM,SAAS,KAAK,QAAQ;AAC5B,eACE;AAAA,UAAC;AAAA;AAAA,YAEC,MAAK;AAAA,YACL,SAAS,MAAM,SAAS,KAAK,GAAG;AAAA,YAChC,eAAW;AAAA,cACT;AAAA,cACA,SACI,mDACA;AAAA,YACN;AAAA,YAEC,eAAK;AAAA;AAAA,UAVD,KAAK;AAAA,QAWZ;AAAA,MAEJ,CAAC;AAAA;AAAA,EACH;AAEJ;","names":[]}
@@ -0,0 +1,21 @@
1
+ import * as react_jsx_runtime from 'react/jsx-runtime';
2
+
3
+ interface PortfolioChipFilterOption {
4
+ key: string;
5
+ label: string;
6
+ }
7
+ interface PortfolioChipFilterProps {
8
+ options: PortfolioChipFilterOption[];
9
+ /** Selected option key, or "all". */
10
+ value: string;
11
+ onChange: (key: string) => void;
12
+ className?: string;
13
+ }
14
+ /**
15
+ * Horizontally-scrollable chip row for fast lateral access across portfolio
16
+ * sections (Instagram/YouTube-style filter chips) — narrows which bento
17
+ * tiles are visible on the same page, never navigates to a different route.
18
+ */
19
+ declare function PortfolioChipFilter({ options, value, onChange, className, }: PortfolioChipFilterProps): react_jsx_runtime.JSX.Element;
20
+
21
+ export { PortfolioChipFilter, type PortfolioChipFilterOption, type PortfolioChipFilterProps };
@@ -0,0 +1,21 @@
1
+ import * as react_jsx_runtime from 'react/jsx-runtime';
2
+
3
+ interface PortfolioChipFilterOption {
4
+ key: string;
5
+ label: string;
6
+ }
7
+ interface PortfolioChipFilterProps {
8
+ options: PortfolioChipFilterOption[];
9
+ /** Selected option key, or "all". */
10
+ value: string;
11
+ onChange: (key: string) => void;
12
+ className?: string;
13
+ }
14
+ /**
15
+ * Horizontally-scrollable chip row for fast lateral access across portfolio
16
+ * sections (Instagram/YouTube-style filter chips) — narrows which bento
17
+ * tiles are visible on the same page, never navigates to a different route.
18
+ */
19
+ declare function PortfolioChipFilter({ options, value, onChange, className, }: PortfolioChipFilterProps): react_jsx_runtime.JSX.Element;
20
+
21
+ export { PortfolioChipFilter, type PortfolioChipFilterOption, type PortfolioChipFilterProps };
@@ -0,0 +1,41 @@
1
+ "use client";
2
+ import { jsx } from "react/jsx-runtime";
3
+ import { cn } from "../utils/cn.js";
4
+ function PortfolioChipFilter({
5
+ options,
6
+ value,
7
+ onChange,
8
+ className
9
+ }) {
10
+ const all = { key: "all", label: "All" };
11
+ const items = [all, ...options];
12
+ return /* @__PURE__ */ jsx(
13
+ "div",
14
+ {
15
+ className: cn(
16
+ "flex items-center gap-1.5 overflow-x-auto scrollbar-hide -mx-4 px-4 sm:-mx-6 sm:px-6 lg:-mx-8 lg:px-8",
17
+ className
18
+ ),
19
+ children: items.map((item) => {
20
+ const active = item.key === value;
21
+ return /* @__PURE__ */ jsx(
22
+ "button",
23
+ {
24
+ type: "button",
25
+ onClick: () => onChange(item.key),
26
+ className: cn(
27
+ "shrink-0 rounded-full px-3.5 py-1.5 text-[13px] whitespace-nowrap transition-colors",
28
+ active ? "bg-primary text-primary-foreground font-medium" : "bg-muted text-muted-foreground hover:text-foreground"
29
+ ),
30
+ children: item.label
31
+ },
32
+ item.key
33
+ );
34
+ })
35
+ }
36
+ );
37
+ }
38
+ export {
39
+ PortfolioChipFilter
40
+ };
41
+ //# sourceMappingURL=portfolio-chip-filter.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../../src/components/portfolio-chip-filter.tsx"],"sourcesContent":["\"use client\";\n\nimport { cn } from \"../utils/cn.js\";\n\nexport interface PortfolioChipFilterOption {\n key: string;\n label: string;\n}\n\nexport interface PortfolioChipFilterProps {\n options: PortfolioChipFilterOption[];\n /** Selected option key, or \"all\". */\n value: string;\n onChange: (key: string) => void;\n className?: string;\n}\n\n/**\n * Horizontally-scrollable chip row for fast lateral access across portfolio\n * sections (Instagram/YouTube-style filter chips) — narrows which bento\n * tiles are visible on the same page, never navigates to a different route.\n */\nexport function PortfolioChipFilter({\n options,\n value,\n onChange,\n className,\n}: PortfolioChipFilterProps) {\n const all: PortfolioChipFilterOption = { key: \"all\", label: \"All\" };\n const items = [all, ...options];\n\n return (\n <div\n className={cn(\n \"flex items-center gap-1.5 overflow-x-auto scrollbar-hide -mx-4 px-4 sm:-mx-6 sm:px-6 lg:-mx-8 lg:px-8\",\n className,\n )}\n >\n {items.map((item) => {\n const active = item.key === value;\n return (\n <button\n key={item.key}\n type=\"button\"\n onClick={() => onChange(item.key)}\n className={cn(\n \"shrink-0 rounded-full px-3.5 py-1.5 text-[13px] whitespace-nowrap transition-colors\",\n active\n ? \"bg-primary text-primary-foreground font-medium\"\n : \"bg-muted text-muted-foreground hover:text-foreground\",\n )}\n >\n {item.label}\n </button>\n );\n })}\n </div>\n );\n}\n"],"mappings":";AAyCU;AAvCV,SAAS,UAAU;AAoBZ,SAAS,oBAAoB;AAAA,EAClC;AAAA,EACA;AAAA,EACA;AAAA,EACA;AACF,GAA6B;AAC3B,QAAM,MAAiC,EAAE,KAAK,OAAO,OAAO,MAAM;AAClE,QAAM,QAAQ,CAAC,KAAK,GAAG,OAAO;AAE9B,SACE;AAAA,IAAC;AAAA;AAAA,MACC,WAAW;AAAA,QACT;AAAA,QACA;AAAA,MACF;AAAA,MAEC,gBAAM,IAAI,CAAC,SAAS;AACnB,cAAM,SAAS,KAAK,QAAQ;AAC5B,eACE;AAAA,UAAC;AAAA;AAAA,YAEC,MAAK;AAAA,YACL,SAAS,MAAM,SAAS,KAAK,GAAG;AAAA,YAChC,WAAW;AAAA,cACT;AAAA,cACA,SACI,mDACA;AAAA,YACN;AAAA,YAEC,eAAK;AAAA;AAAA,UAVD,KAAK;AAAA,QAWZ;AAAA,MAEJ,CAAC;AAAA;AAAA,EACH;AAEJ;","names":[]}
@@ -1,10 +1,8 @@
1
1
  "use strict";
2
2
  "use client";
3
- var __create = Object.create;
4
3
  var __defProp = Object.defineProperty;
5
4
  var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
6
5
  var __getOwnPropNames = Object.getOwnPropertyNames;
7
- var __getProtoOf = Object.getPrototypeOf;
8
6
  var __hasOwnProp = Object.prototype.hasOwnProperty;
9
7
  var __export = (target, all) => {
10
8
  for (var name in all)
@@ -18,14 +16,6 @@ var __copyProps = (to, from, except, desc) => {
18
16
  }
19
17
  return to;
20
18
  };
21
- var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
22
- // If the importer is in node compatibility mode or this is not an ESM
23
- // file that has been converted to a CommonJS file using a Babel-
24
- // compatible transform (i.e. "__esModule" has not been set), then set
25
- // "default" to the CommonJS "module.exports" for node compatibility.
26
- isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
27
- mod
28
- ));
29
19
  var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
30
20
  var portfolio_overview_exports = {};
31
21
  __export(portfolio_overview_exports, {
@@ -33,120 +23,43 @@ __export(portfolio_overview_exports, {
33
23
  });
34
24
  module.exports = __toCommonJS(portfolio_overview_exports);
35
25
  var import_jsx_runtime = require("react/jsx-runtime");
36
- var import_link = __toESM(require("next/link"), 1);
37
- var import_lucide_react = require("lucide-react");
26
+ var import_react = require("react");
38
27
  var import_cn = require("../utils/cn.js");
39
- const ATTENTION_DOT = {
40
- destructive: "bg-destructive",
41
- warning: "bg-amber-500",
42
- primary: "bg-primary"
43
- };
44
- function SectionHeading({
45
- title,
46
- href
47
- }) {
48
- return /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", { className: "flex items-center justify-between gap-3", children: [
49
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)("h2", { className: "text-sm font-semibold text-foreground", children: title }),
50
- href && /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(
51
- import_link.default,
52
- {
53
- href,
54
- className: "inline-flex items-center gap-1 text-xs font-medium text-muted-foreground hover:text-foreground transition-colors",
55
- children: [
56
- "View all",
57
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_lucide_react.ArrowRight, { className: "h-3 w-3" })
58
- ]
59
- }
60
- )
61
- ] });
62
- }
28
+ var import_portfolio_bento_tile = require("./portfolio-bento-tile.js");
29
+ var import_portfolio_chip_filter = require("./portfolio-chip-filter.js");
63
30
  function PortfolioOverview({
64
- attention,
65
- stats,
66
- quickActions,
67
- assetsSlot,
68
- assetsHref,
69
- activitySlot,
70
- activityHref,
31
+ tiles,
71
32
  isEmpty,
72
33
  emptyState,
73
34
  className
74
35
  }) {
75
- const pending = (attention ?? []).filter((item) => item.count > 0);
36
+ const [selected, setSelected] = (0, import_react.useState)("all");
37
+ if (isEmpty) {
38
+ return /* @__PURE__ */ (0, import_jsx_runtime.jsx)("div", { className, children: emptyState });
39
+ }
40
+ const visibleTiles = selected === "all" ? tiles : tiles.filter((t) => t.key === selected);
76
41
  return /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", { className: (0, import_cn.cn)("space-y-6", className), children: [
77
- pending.length > 0 && /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("section", { className: "rounded-xl border border-primary/25 bg-primary/[0.04] p-4 sm:p-5 space-y-3", children: [
78
- /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", { className: "flex items-center gap-2 text-primary", children: [
79
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_lucide_react.BellRing, { className: "h-4 w-4" }),
80
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)("h2", { className: "text-sm font-semibold", children: "Needs your attention" })
81
- ] }),
82
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)("div", { className: "grid gap-2 sm:grid-cols-2", children: pending.map((item) => /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(
83
- import_link.default,
84
- {
85
- href: item.href,
86
- className: "flex items-center justify-between gap-3 rounded-lg bg-card border border-border/60 px-3.5 py-2.5 active:opacity-80 hover:border-border transition-colors",
87
- children: [
88
- /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("span", { className: "flex items-center gap-2.5 min-w-0", children: [
89
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
90
- "span",
91
- {
92
- className: (0, import_cn.cn)(
93
- "h-2 w-2 rounded-full shrink-0",
94
- ATTENTION_DOT[item.tone ?? "primary"]
95
- )
96
- }
97
- ),
98
- /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("span", { className: "min-w-0", children: [
99
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", { className: "block text-sm font-medium text-foreground truncate", children: item.label }),
100
- item.description && /* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", { className: "block text-xs text-muted-foreground truncate", children: item.description })
101
- ] })
102
- ] }),
103
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_lucide_react.ArrowRight, { className: "h-4 w-4 text-muted-foreground shrink-0" })
104
- ]
105
- },
106
- item.href + item.label
107
- )) })
108
- ] }),
109
- (stats && stats.length > 0 || quickActions && quickActions.length > 0) && /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", { className: "space-y-3", children: [
110
- stats && stats.length > 0 && /* @__PURE__ */ (0, import_jsx_runtime.jsx)("div", { className: "flex items-center gap-2 flex-wrap", children: stats.map((stat) => {
111
- if (stat.value == null) {
112
- return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
113
- "span",
114
- {
115
- className: "bg-muted rounded-full px-3 py-1.5 w-20 h-7 animate-pulse inline-block"
116
- },
117
- stat.label
118
- );
119
- }
120
- const pill = /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("span", { className: "inline-flex items-baseline gap-1.5 rounded-full bg-muted px-3 py-1.5 text-[13px] whitespace-nowrap", children: [
121
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", { className: "font-semibold text-foreground tabular-nums", children: stat.value }),
122
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", { className: "text-muted-foreground", children: stat.label }),
123
- stat.sub && /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("span", { className: "text-muted-foreground/70", children: [
124
- "\xB7 ",
125
- stat.sub
126
- ] })
127
- ] });
128
- return stat.href ? /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_link.default, { href: stat.href, className: "active:opacity-80", children: pill }, stat.label) : /* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", { children: pill }, stat.label);
129
- }) }),
130
- quickActions && quickActions.length > 0 && /* @__PURE__ */ (0, import_jsx_runtime.jsx)("div", { className: "flex items-center gap-2 flex-wrap", children: quickActions.map((action) => /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
131
- import_link.default,
132
- {
133
- href: action.href,
134
- className: "inline-flex items-center rounded-full border border-border bg-card px-4 py-1.5 text-[13px] font-medium text-foreground active:opacity-80 hover:border-primary/40 transition-colors",
135
- children: action.label
136
- },
137
- action.href
138
- )) })
139
- ] }),
140
- isEmpty ? emptyState : /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", { className: "grid gap-6 lg:grid-cols-5", children: [
141
- assetsSlot && /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("section", { className: "lg:col-span-3 space-y-3", children: [
142
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)(SectionHeading, { title: "Your assets", href: assetsHref }),
143
- assetsSlot
144
- ] }),
145
- activitySlot && /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("section", { className: "lg:col-span-2 space-y-3", children: [
146
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)(SectionHeading, { title: "Recent activity", href: activityHref }),
147
- activitySlot
148
- ] })
149
- ] })
42
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
43
+ import_portfolio_chip_filter.PortfolioChipFilter,
44
+ {
45
+ options: tiles.map((t) => ({ key: t.key, label: t.title })),
46
+ value: selected,
47
+ onChange: setSelected
48
+ }
49
+ ),
50
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)("div", { className: "grid grid-cols-1 md:grid-cols-4 gap-4 auto-rows-min", children: visibleTiles.map((tile) => /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
51
+ import_portfolio_bento_tile.PortfolioBentoTile,
52
+ {
53
+ title: tile.title,
54
+ href: tile.href,
55
+ size: tile.size,
56
+ action: tile.action,
57
+ isEmpty: tile.isEmpty,
58
+ emptyState: tile.emptyState,
59
+ children: tile.content
60
+ },
61
+ tile.key
62
+ )) })
150
63
  ] });
151
64
  }
152
65
  // Annotate the CommonJS export names for ESM import in node:
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/components/portfolio-overview.tsx"],"sourcesContent":["\"use client\";\n\nimport Link from \"next/link\";\nimport { ArrowRight, BellRing } from \"lucide-react\";\nimport { cn } from \"../utils/cn.js\";\n\nexport interface PortfolioAttentionItem {\n /** e.g. \"2 offers received\" — caller composes count + label. */\n label: string;\n /** Short helper line, e.g. \"Accept, counter, or decline\". */\n description?: string;\n href: string;\n count: number;\n tone?: \"destructive\" | \"warning\" | \"primary\";\n}\n\nexport interface PortfolioOverviewStat {\n label: string;\n /** Pass null while loading. */\n value: string | number | null;\n sub?: string;\n href?: string;\n}\n\nexport interface PortfolioQuickAction {\n label: string;\n href: string;\n}\n\nexport interface PortfolioOverviewProps {\n /** Pending items needing action. The panel renders only when a count > 0. */\n attention?: PortfolioAttentionItem[];\n stats?: PortfolioOverviewStat[];\n /** Shortcut row under the stat tiles (\"Create asset\", ). */\n quickActions?: PortfolioQuickAction[];\n /** Recent-assets cards, rendered by the app. */\n assetsSlot?: React.ReactNode;\n assetsHref?: string;\n /** Recent-activity rows, rendered by the app. */\n activitySlot?: React.ReactNode;\n activityHref?: string;\n /** First-run state; rendered instead of the columns when `isEmpty`. */\n isEmpty?: boolean;\n emptyState?: React.ReactNode;\n className?: string;\n}\n\nconst ATTENTION_DOT: Record<\n NonNullable<PortfolioAttentionItem[\"tone\"]>,\n string\n> = {\n destructive: \"bg-destructive\",\n warning: \"bg-amber-500\",\n primary: \"bg-primary\",\n};\n\nfunction SectionHeading({\n title,\n href,\n}: {\n title: string;\n href?: string;\n}) {\n return (\n <div className=\"flex items-center justify-between gap-3\">\n <h2 className=\"text-sm font-semibold text-foreground\">{title}</h2>\n {href && (\n <Link\n href={href}\n className=\"inline-flex items-center gap-1 text-xs font-medium text-muted-foreground hover:text-foreground transition-colors\"\n >\n View all\n <ArrowRight className=\"h-3 w-3\" />\n </Link>\n )}\n </div>\n );\n}\n\n/**\n * Portfolio landing page layout: needs-attention panel, clickable stat tiles,\n * and recent assets/activity columns. Pure presentation — the app injects\n * counts, stats, and rendered cards.\n */\nexport function PortfolioOverview({\n attention,\n stats,\n quickActions,\n assetsSlot,\n assetsHref,\n activitySlot,\n activityHref,\n isEmpty,\n emptyState,\n className,\n}: PortfolioOverviewProps) {\n const pending = (attention ?? []).filter((item) => item.count > 0);\n\n return (\n <div className={cn(\"space-y-6\", className)}>\n {pending.length > 0 && (\n <section className=\"rounded-xl border border-primary/25 bg-primary/[0.04] p-4 sm:p-5 space-y-3\">\n <div className=\"flex items-center gap-2 text-primary\">\n <BellRing className=\"h-4 w-4\" />\n <h2 className=\"text-sm font-semibold\">Needs your attention</h2>\n </div>\n <div className=\"grid gap-2 sm:grid-cols-2\">\n {pending.map((item) => (\n <Link\n key={item.href + item.label}\n href={item.href}\n className=\"flex items-center justify-between gap-3 rounded-lg bg-card border border-border/60 px-3.5 py-2.5 active:opacity-80 hover:border-border transition-colors\"\n >\n <span className=\"flex items-center gap-2.5 min-w-0\">\n <span\n className={cn(\n \"h-2 w-2 rounded-full shrink-0\",\n ATTENTION_DOT[item.tone ?? \"primary\"],\n )}\n />\n <span className=\"min-w-0\">\n <span className=\"block text-sm font-medium text-foreground truncate\">\n {item.label}\n </span>\n {item.description && (\n <span className=\"block text-xs text-muted-foreground truncate\">\n {item.description}\n </span>\n )}\n </span>\n </span>\n <ArrowRight className=\"h-4 w-4 text-muted-foreground shrink-0\" />\n </Link>\n ))}\n </div>\n </section>\n )}\n\n {((stats && stats.length > 0) || (quickActions && quickActions.length > 0)) && (\n <div className=\"space-y-3\">\n {stats && stats.length > 0 && (\n <div className=\"flex items-center gap-2 flex-wrap\">\n {stats.map((stat) => {\n if (stat.value == null) {\n return (\n <span\n key={stat.label}\n className=\"bg-muted rounded-full px-3 py-1.5 w-20 h-7 animate-pulse inline-block\"\n />\n );\n }\n const pill = (\n <span className=\"inline-flex items-baseline gap-1.5 rounded-full bg-muted px-3 py-1.5 text-[13px] whitespace-nowrap\">\n <span className=\"font-semibold text-foreground tabular-nums\">\n {stat.value}\n </span>\n <span className=\"text-muted-foreground\">{stat.label}</span>\n {stat.sub && (\n <span className=\"text-muted-foreground/70\">\n · {stat.sub}\n </span>\n )}\n </span>\n );\n return stat.href ? (\n <Link key={stat.label} href={stat.href} className=\"active:opacity-80\">\n {pill}\n </Link>\n ) : (\n <span key={stat.label}>{pill}</span>\n );\n })}\n </div>\n )}\n\n {quickActions && quickActions.length > 0 && (\n <div className=\"flex items-center gap-2 flex-wrap\">\n {quickActions.map((action) => (\n <Link\n key={action.href}\n href={action.href}\n className=\"inline-flex items-center rounded-full border border-border bg-card px-4 py-1.5 text-[13px] font-medium text-foreground active:opacity-80 hover:border-primary/40 transition-colors\"\n >\n {action.label}\n </Link>\n ))}\n </div>\n )}\n </div>\n )}\n\n {isEmpty ? (\n emptyState\n ) : (\n <div className=\"grid gap-6 lg:grid-cols-5\">\n {assetsSlot && (\n <section className=\"lg:col-span-3 space-y-3\">\n <SectionHeading title=\"Your assets\" href={assetsHref} />\n {assetsSlot}\n </section>\n )}\n {activitySlot && (\n <section className=\"lg:col-span-2 space-y-3\">\n <SectionHeading title=\"Recent activity\" href={activityHref} />\n {activitySlot}\n </section>\n )}\n </div>\n )}\n </div>\n );\n}\n"],"mappings":"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","names":["Link"]}
1
+ {"version":3,"sources":["../../src/components/portfolio-overview.tsx"],"sourcesContent":["\"use client\";\n\nimport { useState } from \"react\";\nimport { cn } from \"../utils/cn.js\";\nimport { PortfolioBentoTile, type PortfolioBentoTileProps } from \"./portfolio-bento-tile.js\";\nimport { PortfolioChipFilter } from \"./portfolio-chip-filter.js\";\n\nexport interface PortfolioBentoTileConfig {\n /** Matches a PortfolioChipFilter option key. */\n key: string;\n title: string;\n href: string;\n size?: PortfolioBentoTileProps[\"size\"];\n /** Single primary in-tile action (e.g. a \"List\" button). */\n action?: React.ReactNode;\n isEmpty?: boolean;\n emptyState?: React.ReactNode;\n content: React.ReactNode;\n}\n\nexport interface PortfolioOverviewProps {\n tiles: PortfolioBentoTileConfig[];\n /** First-run state across the whole portfolio (zero holdings, zero activity). */\n isEmpty?: boolean;\n emptyState?: React.ReactNode;\n className?: string;\n}\n\n/**\n * Portfolio landing page: a content-first bento dashboard. Each tile is a\n * fast preview of one section (Collections, Assets, Tickets & memberships,\n * Activity, ) that expands into its full subpage. A chip row gives fast\n * lateral access across sections without navigating away. Pure\n * presentation — the app supplies each tile's rendered content; this\n * component only handles layout, filtering, and empty states.\n */\nexport function PortfolioOverview({\n tiles,\n isEmpty,\n emptyState,\n className,\n}: PortfolioOverviewProps) {\n const [selected, setSelected] = useState(\"all\");\n\n if (isEmpty) {\n return <div className={className}>{emptyState}</div>;\n }\n\n const visibleTiles =\n selected === \"all\" ? tiles : tiles.filter((t) => t.key === selected);\n\n return (\n <div className={cn(\"space-y-6\", className)}>\n <PortfolioChipFilter\n options={tiles.map((t) => ({ key: t.key, label: t.title }))}\n value={selected}\n onChange={setSelected}\n />\n <div className=\"grid grid-cols-1 md:grid-cols-4 gap-4 auto-rows-min\">\n {visibleTiles.map((tile) => (\n <PortfolioBentoTile\n key={tile.key}\n title={tile.title}\n href={tile.href}\n size={tile.size}\n action={tile.action}\n isEmpty={tile.isEmpty}\n emptyState={tile.emptyState}\n >\n {tile.content}\n </PortfolioBentoTile>\n ))}\n </div>\n </div>\n );\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AA6CW;AA3CX,mBAAyB;AACzB,gBAAmB;AACnB,kCAAiE;AACjE,mCAAoC;AA+B7B,SAAS,kBAAkB;AAAA,EAChC;AAAA,EACA;AAAA,EACA;AAAA,EACA;AACF,GAA2B;AACzB,QAAM,CAAC,UAAU,WAAW,QAAI,uBAAS,KAAK;AAE9C,MAAI,SAAS;AACX,WAAO,4CAAC,SAAI,WAAuB,sBAAW;AAAA,EAChD;AAEA,QAAM,eACJ,aAAa,QAAQ,QAAQ,MAAM,OAAO,CAAC,MAAM,EAAE,QAAQ,QAAQ;AAErE,SACE,6CAAC,SAAI,eAAW,cAAG,aAAa,SAAS,GACvC;AAAA;AAAA,MAAC;AAAA;AAAA,QACC,SAAS,MAAM,IAAI,CAAC,OAAO,EAAE,KAAK,EAAE,KAAK,OAAO,EAAE,MAAM,EAAE;AAAA,QAC1D,OAAO;AAAA,QACP,UAAU;AAAA;AAAA,IACZ;AAAA,IACA,4CAAC,SAAI,WAAU,uDACZ,uBAAa,IAAI,CAAC,SACjB;AAAA,MAAC;AAAA;AAAA,QAEC,OAAO,KAAK;AAAA,QACZ,MAAM,KAAK;AAAA,QACX,MAAM,KAAK;AAAA,QACX,QAAQ,KAAK;AAAA,QACb,SAAS,KAAK;AAAA,QACd,YAAY,KAAK;AAAA,QAEhB,eAAK;AAAA;AAAA,MARD,KAAK;AAAA,IASZ,CACD,GACH;AAAA,KACF;AAEJ;","names":[]}