@fairmint/ui 0.3.42 → 0.4.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/_virtual/index3.cjs +5 -3
- package/dist/_virtual/index3.cjs.map +1 -1
- package/dist/_virtual/index3.js +5 -2
- package/dist/_virtual/index3.js.map +1 -1
- package/dist/_virtual/index4.cjs +3 -5
- package/dist/_virtual/index4.cjs.map +1 -1
- package/dist/_virtual/index4.js +2 -5
- package/dist/_virtual/index4.js.map +1 -1
- package/dist/components/FairmintLogo/FairmintLogoMark.cjs.map +1 -1
- package/dist/components/FairmintLogo/FairmintLogoMark.d.ts +1 -1
- package/dist/components/FairmintLogo/FairmintLogoMark.js.map +1 -1
- package/dist/components/FairmintLogo/FairmintLogoMarkRounded.cjs +16 -7
- package/dist/components/FairmintLogo/FairmintLogoMarkRounded.cjs.map +1 -1
- package/dist/components/FairmintLogo/FairmintLogoMarkRounded.d.ts +17 -8
- package/dist/components/FairmintLogo/FairmintLogoMarkRounded.d.ts.map +1 -1
- package/dist/components/FairmintLogo/FairmintLogoMarkRounded.js +16 -7
- package/dist/components/FairmintLogo/FairmintLogoMarkRounded.js.map +1 -1
- package/dist/components/layout/AppHeader/AppHeader.cjs.map +1 -1
- package/dist/components/layout/AppHeader/AppHeader.d.ts +2 -2
- package/dist/components/layout/AppHeader/AppHeader.d.ts.map +1 -1
- package/dist/components/layout/AppHeader/AppHeader.js.map +1 -1
- package/dist/components/layout/SideNav/studioNavFixtures.d.ts +2 -2
- package/dist/components/layout/SideNav/studioNavFixtures.d.ts.map +1 -1
- package/dist/components/primitives/muiCompat.cjs +34 -1
- package/dist/components/primitives/muiCompat.cjs.map +1 -1
- package/dist/components/primitives/muiCompat.d.ts +1 -1
- package/dist/components/primitives/muiCompat.d.ts.map +1 -1
- package/dist/components/primitives/muiCompat.js +34 -1
- package/dist/components/primitives/muiCompat.js.map +1 -1
- package/dist/components/specific/EquityRibbonChart/FairmintRibbonMark.cjs.map +1 -1
- package/dist/components/specific/EquityRibbonChart/FairmintRibbonMark.d.ts +2 -1
- package/dist/components/specific/EquityRibbonChart/FairmintRibbonMark.d.ts.map +1 -1
- package/dist/components/specific/EquityRibbonChart/FairmintRibbonMark.js.map +1 -1
- package/dist/fairmint-ui.cjs +0 -2
- package/dist/fairmint-ui.cjs.map +1 -1
- package/dist/fairmint-ui.js +0 -2
- package/dist/fairmint-ui.js.map +1 -1
- package/dist/index.d.ts +1 -3
- package/dist/index.d.ts.map +1 -1
- package/dist/node_modules/@mantine/form/esm/hooks/use-form-status/use-form-status.cjs +1 -1
- package/dist/node_modules/@mantine/form/esm/hooks/use-form-status/use-form-status.js +1 -1
- package/dist/node_modules/prop-types/index.cjs +1 -1
- package/dist/node_modules/prop-types/index.js +1 -1
- package/dist/styles.css +79 -79
- package/package.json +1 -1
- package/dist/components/FairmintLogo/FairmintBrandLogo.cjs +0 -66
- package/dist/components/FairmintLogo/FairmintBrandLogo.cjs.map +0 -1
- package/dist/components/FairmintLogo/FairmintBrandLogo.d.ts +0 -46
- package/dist/components/FairmintLogo/FairmintBrandLogo.d.ts.map +0 -1
- package/dist/components/FairmintLogo/FairmintBrandLogo.js +0 -66
- package/dist/components/FairmintLogo/FairmintBrandLogo.js.map +0 -1
- package/dist/components/FairmintLogo/brandLogoLayout.cjs +0 -25
- package/dist/components/FairmintLogo/brandLogoLayout.cjs.map +0 -1
- package/dist/components/FairmintLogo/brandLogoLayout.d.ts +0 -19
- package/dist/components/FairmintLogo/brandLogoLayout.d.ts.map +0 -1
- package/dist/components/FairmintLogo/brandLogoLayout.js +0 -25
- package/dist/components/FairmintLogo/brandLogoLayout.js.map +0 -1
package/dist/_virtual/index3.cjs
CHANGED
|
@@ -1,5 +1,7 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
2
|
+
const _commonjsHelpers = require("./_commonjsHelpers.cjs");
|
|
3
|
+
const index = require("../node_modules/fast-deep-equal/index.cjs");
|
|
4
|
+
var fastDeepEqualExports = index.__require();
|
|
5
|
+
const isEqual = /* @__PURE__ */ _commonjsHelpers.getDefaultExportFromCjs(fastDeepEqualExports);
|
|
6
|
+
module.exports = isEqual;
|
|
5
7
|
//# sourceMappingURL=index3.cjs.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index3.cjs","sources":[],"sourcesContent":[],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"index3.cjs","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;"}
|
package/dist/_virtual/index3.js
CHANGED
|
@@ -1,5 +1,8 @@
|
|
|
1
|
-
|
|
1
|
+
import { getDefaultExportFromCjs } from "./_commonjsHelpers.js";
|
|
2
|
+
import { __require as requireFastDeepEqual } from "../node_modules/fast-deep-equal/index.js";
|
|
3
|
+
var fastDeepEqualExports = requireFastDeepEqual();
|
|
4
|
+
const isEqual = /* @__PURE__ */ getDefaultExportFromCjs(fastDeepEqualExports);
|
|
2
5
|
export {
|
|
3
|
-
|
|
6
|
+
isEqual as default
|
|
4
7
|
};
|
|
5
8
|
//# sourceMappingURL=index3.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index3.js","sources":[],"sourcesContent":[],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"index3.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;"}
|
package/dist/_virtual/index4.cjs
CHANGED
|
@@ -1,7 +1,5 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
const isEqual = /* @__PURE__ */ _commonjsHelpers.getDefaultExportFromCjs(fastDeepEqualExports);
|
|
6
|
-
module.exports = isEqual;
|
|
2
|
+
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
3
|
+
var propTypes = { exports: {} };
|
|
4
|
+
exports.__module = propTypes;
|
|
7
5
|
//# sourceMappingURL=index4.cjs.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index4.cjs","sources":[],"sourcesContent":[],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"index4.cjs","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;"}
|
package/dist/_virtual/index4.js
CHANGED
|
@@ -1,8 +1,5 @@
|
|
|
1
|
-
|
|
2
|
-
import { __require as requireFastDeepEqual } from "../node_modules/fast-deep-equal/index.js";
|
|
3
|
-
var fastDeepEqualExports = requireFastDeepEqual();
|
|
4
|
-
const isEqual = /* @__PURE__ */ getDefaultExportFromCjs(fastDeepEqualExports);
|
|
1
|
+
var propTypes = { exports: {} };
|
|
5
2
|
export {
|
|
6
|
-
|
|
3
|
+
propTypes as __module
|
|
7
4
|
};
|
|
8
5
|
//# sourceMappingURL=index4.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index4.js","sources":[],"sourcesContent":[],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"index4.js","sources":[],"sourcesContent":[],"names":[],"mappings":";"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"FairmintLogoMark.cjs","sources":["../../../src/components/FairmintLogo/FairmintLogoMark.tsx"],"sourcesContent":["import type { CSSProperties } from \"react\";\nimport { useId } from \"react\";\nimport { LOGO_MARK_BARS, LOGO_MARK_VIEWBOX, logoColors, logoFills } from \"../../theme/logo\";\n\nexport type FairmintLogoMarkFill = \"gradient\" | \"white\" | \"black\";\n\nexport interface FairmintLogoMarkProps {\n /** Square size in pixels. @default 32 */\n size?: number;\n /** Bar fill style. @default \"gradient\" */\n fill?: FairmintLogoMarkFill;\n /** Number of ascending bars (3 or 4). @default 4 */\n barCount?: 3 | 4;\n /**\n * Accessible name when the mark is standalone (nav icon, favicon).\n * Omit or pass `\"\"` when decorative inside a labeled lockup or link.\n */\n alt?: string;\n className?: string;\n style?: CSSProperties;\n}\n\nfunction resolveBarFill(fill: FairmintLogoMarkFill, gradientId: string): string {\n if (fill === \"gradient\") {\n return `url(#${gradientId})`;\n }\n return fill === \"white\" ? logoFills.white : logoFills.black;\n}\n\n/**\n * Simplified brand mark — flat ascending bars with the wordmark gradient.\n *
|
|
1
|
+
{"version":3,"file":"FairmintLogoMark.cjs","sources":["../../../src/components/FairmintLogo/FairmintLogoMark.tsx"],"sourcesContent":["import type { CSSProperties } from \"react\";\nimport { useId } from \"react\";\nimport { LOGO_MARK_BARS, LOGO_MARK_VIEWBOX, logoColors, logoFills } from \"../../theme/logo\";\n\nexport type FairmintLogoMarkFill = \"gradient\" | \"white\" | \"black\";\n\nexport interface FairmintLogoMarkProps {\n /** Square size in pixels. @default 32 */\n size?: number;\n /** Bar fill style. @default \"gradient\" */\n fill?: FairmintLogoMarkFill;\n /** Number of ascending bars (3 or 4). @default 4 */\n barCount?: 3 | 4;\n /**\n * Accessible name when the mark is standalone (nav icon, favicon).\n * Omit or pass `\"\"` when decorative inside a labeled lockup or link.\n */\n alt?: string;\n className?: string;\n style?: CSSProperties;\n}\n\nfunction resolveBarFill(fill: FairmintLogoMarkFill, gradientId: string): string {\n if (fill === \"gradient\") {\n return `url(#${gradientId})`;\n }\n return fill === \"white\" ? logoFills.white : logoFills.black;\n}\n\n/**\n * Simplified brand mark — flat ascending bars with the wordmark gradient.\n * Not used in product chrome; prefer `FairmintLogoMarkRounded`.\n */\nexport function FairmintLogoMark({\n size = 32,\n fill = \"gradient\",\n barCount = 4,\n alt,\n className,\n style,\n}: FairmintLogoMarkProps) {\n const gradientId = useId();\n const bars = LOGO_MARK_BARS.slice(0, barCount);\n const barFill = resolveBarFill(fill, gradientId);\n const isDecorative = !alt;\n\n return (\n <svg\n viewBox={`0 0 ${LOGO_MARK_VIEWBOX.width} ${LOGO_MARK_VIEWBOX.height}`}\n width={size}\n height={size}\n className={className}\n style={{ display: \"block\", flexShrink: 0, ...style }}\n xmlns=\"http://www.w3.org/2000/svg\"\n aria-hidden={isDecorative || undefined}\n role={isDecorative ? undefined : \"img\"}\n aria-label={isDecorative ? undefined : alt}\n >\n {!isDecorative && <title>{alt}</title>}\n {bars.map((bar) => (\n <rect\n key={`${bar.x}-${bar.y}`}\n x={bar.x}\n y={bar.y}\n width={bar.width}\n height={bar.height}\n fill={barFill}\n />\n ))}\n {fill === \"gradient\" && (\n <defs>\n <linearGradient\n id={gradientId}\n x1=\"0\"\n y1=\"24\"\n x2=\"48\"\n y2=\"24\"\n gradientUnits=\"userSpaceOnUse\"\n >\n {logoColors.gradientStops.map((stop) => (\n <stop key={stop.offset} offset={stop.offset} stopColor={stop.color} />\n ))}\n </linearGradient>\n </defs>\n )}\n </svg>\n );\n}\n"],"names":["logoFills","useId","LOGO_MARK_BARS","jsxs","LOGO_MARK_VIEWBOX","jsx","logoColors"],"mappings":";;;;;AAsBA,SAAS,eAAe,MAA4B,YAA4B;AAC9E,MAAI,SAAS,YAAY;AACvB,WAAO,QAAQ,UAAU;AAAA,EAC3B;AACA,SAAO,SAAS,UAAUA,KAAAA,UAAU,QAAQA,KAAAA,UAAU;AACxD;AAMO,SAAS,iBAAiB;AAAA,EAC/B,OAAO;AAAA,EACP,OAAO;AAAA,EACP,WAAW;AAAA,EACX;AAAA,EACA;AAAA,EACA;AACF,GAA0B;AACxB,QAAM,aAAaC,MAAAA,MAAA;AACnB,QAAM,OAAOC,KAAAA,eAAe,MAAM,GAAG,QAAQ;AAC7C,QAAM,UAAU,eAAe,MAAM,UAAU;AAC/C,QAAM,eAAe,CAAC;AAEtB,SACEC,2BAAAA;AAAAA,IAAC;AAAA,IAAA;AAAA,MACC,SAAS,OAAOC,KAAAA,kBAAkB,KAAK,IAAIA,KAAAA,kBAAkB,MAAM;AAAA,MACnE,OAAO;AAAA,MACP,QAAQ;AAAA,MACR;AAAA,MACA,OAAO,EAAE,SAAS,SAAS,YAAY,GAAG,GAAG,MAAA;AAAA,MAC7C,OAAM;AAAA,MACN,eAAa,gBAAgB;AAAA,MAC7B,MAAM,eAAe,SAAY;AAAA,MACjC,cAAY,eAAe,SAAY;AAAA,MAEtC,UAAA;AAAA,QAAA,CAAC,gBAAgBC,2BAAAA,IAAC,SAAA,EAAO,UAAA,IAAA,CAAI;AAAA,QAC7B,KAAK,IAAI,CAAC,QACTA,2BAAAA;AAAAA,UAAC;AAAA,UAAA;AAAA,YAEC,GAAG,IAAI;AAAA,YACP,GAAG,IAAI;AAAA,YACP,OAAO,IAAI;AAAA,YACX,QAAQ,IAAI;AAAA,YACZ,MAAM;AAAA,UAAA;AAAA,UALD,GAAG,IAAI,CAAC,IAAI,IAAI,CAAC;AAAA,QAAA,CAOzB;AAAA,QACA,SAAS,cACRA,2BAAAA,IAAC,QAAA,EACC,UAAAA,2BAAAA;AAAAA,UAAC;AAAA,UAAA;AAAA,YACC,IAAI;AAAA,YACJ,IAAG;AAAA,YACH,IAAG;AAAA,YACH,IAAG;AAAA,YACH,IAAG;AAAA,YACH,eAAc;AAAA,YAEb,UAAAC,KAAAA,WAAW,cAAc,IAAI,CAAC,SAC7BD,2BAAAA,IAAC,QAAA,EAAuB,QAAQ,KAAK,QAAQ,WAAW,KAAK,MAAA,GAAlD,KAAK,MAAoD,CACrE;AAAA,UAAA;AAAA,QAAA,EACH,CACF;AAAA,MAAA;AAAA,IAAA;AAAA,EAAA;AAIR;;"}
|
|
@@ -17,7 +17,7 @@ export interface FairmintLogoMarkProps {
|
|
|
17
17
|
}
|
|
18
18
|
/**
|
|
19
19
|
* Simplified brand mark — flat ascending bars with the wordmark gradient.
|
|
20
|
-
*
|
|
20
|
+
* Not used in product chrome; prefer `FairmintLogoMarkRounded`.
|
|
21
21
|
*/
|
|
22
22
|
export declare function FairmintLogoMark({ size, fill, barCount, alt, className, style, }: FairmintLogoMarkProps): import("react").JSX.Element;
|
|
23
23
|
//# sourceMappingURL=FairmintLogoMark.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"FairmintLogoMark.js","sources":["../../../src/components/FairmintLogo/FairmintLogoMark.tsx"],"sourcesContent":["import type { CSSProperties } from \"react\";\nimport { useId } from \"react\";\nimport { LOGO_MARK_BARS, LOGO_MARK_VIEWBOX, logoColors, logoFills } from \"../../theme/logo\";\n\nexport type FairmintLogoMarkFill = \"gradient\" | \"white\" | \"black\";\n\nexport interface FairmintLogoMarkProps {\n /** Square size in pixels. @default 32 */\n size?: number;\n /** Bar fill style. @default \"gradient\" */\n fill?: FairmintLogoMarkFill;\n /** Number of ascending bars (3 or 4). @default 4 */\n barCount?: 3 | 4;\n /**\n * Accessible name when the mark is standalone (nav icon, favicon).\n * Omit or pass `\"\"` when decorative inside a labeled lockup or link.\n */\n alt?: string;\n className?: string;\n style?: CSSProperties;\n}\n\nfunction resolveBarFill(fill: FairmintLogoMarkFill, gradientId: string): string {\n if (fill === \"gradient\") {\n return `url(#${gradientId})`;\n }\n return fill === \"white\" ? logoFills.white : logoFills.black;\n}\n\n/**\n * Simplified brand mark — flat ascending bars with the wordmark gradient.\n *
|
|
1
|
+
{"version":3,"file":"FairmintLogoMark.js","sources":["../../../src/components/FairmintLogo/FairmintLogoMark.tsx"],"sourcesContent":["import type { CSSProperties } from \"react\";\nimport { useId } from \"react\";\nimport { LOGO_MARK_BARS, LOGO_MARK_VIEWBOX, logoColors, logoFills } from \"../../theme/logo\";\n\nexport type FairmintLogoMarkFill = \"gradient\" | \"white\" | \"black\";\n\nexport interface FairmintLogoMarkProps {\n /** Square size in pixels. @default 32 */\n size?: number;\n /** Bar fill style. @default \"gradient\" */\n fill?: FairmintLogoMarkFill;\n /** Number of ascending bars (3 or 4). @default 4 */\n barCount?: 3 | 4;\n /**\n * Accessible name when the mark is standalone (nav icon, favicon).\n * Omit or pass `\"\"` when decorative inside a labeled lockup or link.\n */\n alt?: string;\n className?: string;\n style?: CSSProperties;\n}\n\nfunction resolveBarFill(fill: FairmintLogoMarkFill, gradientId: string): string {\n if (fill === \"gradient\") {\n return `url(#${gradientId})`;\n }\n return fill === \"white\" ? logoFills.white : logoFills.black;\n}\n\n/**\n * Simplified brand mark — flat ascending bars with the wordmark gradient.\n * Not used in product chrome; prefer `FairmintLogoMarkRounded`.\n */\nexport function FairmintLogoMark({\n size = 32,\n fill = \"gradient\",\n barCount = 4,\n alt,\n className,\n style,\n}: FairmintLogoMarkProps) {\n const gradientId = useId();\n const bars = LOGO_MARK_BARS.slice(0, barCount);\n const barFill = resolveBarFill(fill, gradientId);\n const isDecorative = !alt;\n\n return (\n <svg\n viewBox={`0 0 ${LOGO_MARK_VIEWBOX.width} ${LOGO_MARK_VIEWBOX.height}`}\n width={size}\n height={size}\n className={className}\n style={{ display: \"block\", flexShrink: 0, ...style }}\n xmlns=\"http://www.w3.org/2000/svg\"\n aria-hidden={isDecorative || undefined}\n role={isDecorative ? undefined : \"img\"}\n aria-label={isDecorative ? undefined : alt}\n >\n {!isDecorative && <title>{alt}</title>}\n {bars.map((bar) => (\n <rect\n key={`${bar.x}-${bar.y}`}\n x={bar.x}\n y={bar.y}\n width={bar.width}\n height={bar.height}\n fill={barFill}\n />\n ))}\n {fill === \"gradient\" && (\n <defs>\n <linearGradient\n id={gradientId}\n x1=\"0\"\n y1=\"24\"\n x2=\"48\"\n y2=\"24\"\n gradientUnits=\"userSpaceOnUse\"\n >\n {logoColors.gradientStops.map((stop) => (\n <stop key={stop.offset} offset={stop.offset} stopColor={stop.color} />\n ))}\n </linearGradient>\n </defs>\n )}\n </svg>\n );\n}\n"],"names":[],"mappings":";;;AAsBA,SAAS,eAAe,MAA4B,YAA4B;AAC9E,MAAI,SAAS,YAAY;AACvB,WAAO,QAAQ,UAAU;AAAA,EAC3B;AACA,SAAO,SAAS,UAAU,UAAU,QAAQ,UAAU;AACxD;AAMO,SAAS,iBAAiB;AAAA,EAC/B,OAAO;AAAA,EACP,OAAO;AAAA,EACP,WAAW;AAAA,EACX;AAAA,EACA;AAAA,EACA;AACF,GAA0B;AACxB,QAAM,aAAa,MAAA;AACnB,QAAM,OAAO,eAAe,MAAM,GAAG,QAAQ;AAC7C,QAAM,UAAU,eAAe,MAAM,UAAU;AAC/C,QAAM,eAAe,CAAC;AAEtB,SACE;AAAA,IAAC;AAAA,IAAA;AAAA,MACC,SAAS,OAAO,kBAAkB,KAAK,IAAI,kBAAkB,MAAM;AAAA,MACnE,OAAO;AAAA,MACP,QAAQ;AAAA,MACR;AAAA,MACA,OAAO,EAAE,SAAS,SAAS,YAAY,GAAG,GAAG,MAAA;AAAA,MAC7C,OAAM;AAAA,MACN,eAAa,gBAAgB;AAAA,MAC7B,MAAM,eAAe,SAAY;AAAA,MACjC,cAAY,eAAe,SAAY;AAAA,MAEtC,UAAA;AAAA,QAAA,CAAC,gBAAgB,oBAAC,SAAA,EAAO,UAAA,IAAA,CAAI;AAAA,QAC7B,KAAK,IAAI,CAAC,QACT;AAAA,UAAC;AAAA,UAAA;AAAA,YAEC,GAAG,IAAI;AAAA,YACP,GAAG,IAAI;AAAA,YACP,OAAO,IAAI;AAAA,YACX,QAAQ,IAAI;AAAA,YACZ,MAAM;AAAA,UAAA;AAAA,UALD,GAAG,IAAI,CAAC,IAAI,IAAI,CAAC;AAAA,QAAA,CAOzB;AAAA,QACA,SAAS,cACR,oBAAC,QAAA,EACC,UAAA;AAAA,UAAC;AAAA,UAAA;AAAA,YACC,IAAI;AAAA,YACJ,IAAG;AAAA,YACH,IAAG;AAAA,YACH,IAAG;AAAA,YACH,IAAG;AAAA,YACH,eAAc;AAAA,YAEb,UAAA,WAAW,cAAc,IAAI,CAAC,SAC7B,oBAAC,QAAA,EAAuB,QAAQ,KAAK,QAAQ,WAAW,KAAK,MAAA,GAAlD,KAAK,MAAoD,CACrE;AAAA,UAAA;AAAA,QAAA,EACH,CACF;AAAA,MAAA;AAAA,IAAA;AAAA,EAAA;AAIR;"}
|
|
@@ -6,17 +6,26 @@ const LOGO_MARK_ROUNDED_VIEWBOX = { width: 36, height: 36 };
|
|
|
6
6
|
const LOGO_MARK_ROUNDED_TILE = logo.logoColors.markRoundedTile;
|
|
7
7
|
const SIDE_NAV_COLLAPSED_LOGO_FRAME = 48;
|
|
8
8
|
const SIDE_NAV_COLLAPSED_LOGO_SIZE = 36;
|
|
9
|
+
function resolveGlyphColor(variant, glyphColor) {
|
|
10
|
+
if (glyphColor) {
|
|
11
|
+
return glyphColor;
|
|
12
|
+
}
|
|
13
|
+
return variant === "black" ? logo.logoFills.black : logo.logoFills.white;
|
|
14
|
+
}
|
|
9
15
|
function FairmintLogoMarkRounded({
|
|
10
16
|
size = 32,
|
|
11
17
|
frameSize,
|
|
18
|
+
variant = "tile",
|
|
12
19
|
tileColor = LOGO_MARK_ROUNDED_TILE,
|
|
13
|
-
glyphColor
|
|
20
|
+
glyphColor,
|
|
14
21
|
alt,
|
|
15
22
|
className,
|
|
16
23
|
style
|
|
17
24
|
}) {
|
|
18
25
|
const isDecorative = !alt;
|
|
19
26
|
const resolvedFrame = frameSize && frameSize > size ? frameSize : void 0;
|
|
27
|
+
const showTile = variant === "tile";
|
|
28
|
+
const resolvedGlyph = resolveGlyphColor(variant, glyphColor);
|
|
20
29
|
const mark = /* @__PURE__ */ jsxRuntime.jsxs(
|
|
21
30
|
"svg",
|
|
22
31
|
{
|
|
@@ -31,25 +40,25 @@ function FairmintLogoMarkRounded({
|
|
|
31
40
|
"aria-label": isDecorative ? void 0 : alt,
|
|
32
41
|
children: [
|
|
33
42
|
!isDecorative && /* @__PURE__ */ jsxRuntime.jsx("title", { children: alt }),
|
|
34
|
-
/* @__PURE__ */ jsxRuntime.jsx("rect", { width: "36", height: "36", rx: "8", fill: tileColor }),
|
|
43
|
+
showTile && /* @__PURE__ */ jsxRuntime.jsx("rect", { width: "36", height: "36", rx: "8", fill: tileColor }),
|
|
35
44
|
/* @__PURE__ */ jsxRuntime.jsxs("g", { transform: "translate(18 18.07) scale(1.12) translate(-18 -18.07)", children: [
|
|
36
|
-
/* @__PURE__ */ jsxRuntime.jsx("path", { d: "M12.4661 20.3562V26.446H15.1251V18.7954L12.4661 20.3562Z", fill:
|
|
45
|
+
/* @__PURE__ */ jsxRuntime.jsx("path", { d: "M12.4661 20.3562V26.446H15.1251V18.7954L12.4661 20.3562Z", fill: resolvedGlyph }),
|
|
37
46
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
38
47
|
"path",
|
|
39
48
|
{
|
|
40
49
|
d: "M22.5714 22.7206V18.7932L19.9113 20.354V22.9428C19.9113 25.447 20.5768 26.7091 23.391 26.7091C24.0115 26.7091 24.9416 26.6194 25.4954 26.3556V24.1164C25.1627 24.3598 24.5198 24.4499 24.055 24.4499C22.8819 24.4499 22.5714 23.7836 22.5714 22.7206Z",
|
|
41
|
-
fill:
|
|
50
|
+
fill: resolvedGlyph
|
|
42
51
|
}
|
|
43
52
|
),
|
|
44
53
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
45
54
|
"path",
|
|
46
55
|
{
|
|
47
56
|
d: "M16.4329 9.42847C13.1307 9.42847 12.4656 11.3557 12.4656 14.3028V15.822H15.1254V13.8818C15.1254 12.7079 15.3456 11.6881 16.8315 11.6881C17.2086 11.6881 17.5629 11.7555 17.9388 11.8445L18.1148 9.5829C17.5625 9.47197 17.0071 9.42847 16.4329 9.42847Z",
|
|
48
|
-
fill:
|
|
57
|
+
fill: resolvedGlyph
|
|
49
58
|
}
|
|
50
59
|
),
|
|
51
|
-
/* @__PURE__ */ jsxRuntime.jsx("path", { d: "M22.5714 12.7273H19.9113V15.8081H22.5714V12.7273Z", fill:
|
|
52
|
-
/* @__PURE__ */ jsxRuntime.jsx("path", { d: "M25.7283 15.8218H10.2717V18.0841H25.7283V15.8218Z", fill:
|
|
60
|
+
/* @__PURE__ */ jsxRuntime.jsx("path", { d: "M22.5714 12.7273H19.9113V15.8081H22.5714V12.7273Z", fill: resolvedGlyph }),
|
|
61
|
+
/* @__PURE__ */ jsxRuntime.jsx("path", { d: "M25.7283 15.8218H10.2717V18.0841H25.7283V15.8218Z", fill: resolvedGlyph })
|
|
53
62
|
] })
|
|
54
63
|
]
|
|
55
64
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"FairmintLogoMarkRounded.cjs","sources":["../../../src/components/FairmintLogo/FairmintLogoMarkRounded.tsx"],"sourcesContent":["import type { CSSProperties } from \"react\";\nimport { logoColors, logoFills } from \"../../theme/logo\";\n\n/** Product FT mark — rounded square tile from the brand icon asset. */\nexport const LOGO_MARK_ROUNDED_VIEWBOX = { width: 36, height: 36 } as const;\n\n/** Default tile fill from the FT Mark Rounded Square source asset. */\nexport const LOGO_MARK_ROUNDED_TILE = logoColors.markRoundedTile;\n\n/**\n * Collapsed SideNav layout: 48×48 frame with a 36×36 mark centered inside\n * (white/transparent padding around the tile).\n */\nexport const SIDE_NAV_COLLAPSED_LOGO_FRAME = 48;\nexport const SIDE_NAV_COLLAPSED_LOGO_SIZE = 36;\n\nexport interface FairmintLogoMarkRoundedProps {\n /** Square size of the
|
|
1
|
+
{"version":3,"file":"FairmintLogoMarkRounded.cjs","sources":["../../../src/components/FairmintLogo/FairmintLogoMarkRounded.tsx"],"sourcesContent":["import type { CSSProperties } from \"react\";\nimport { logoColors, logoFills } from \"../../theme/logo\";\n\n/** Product FT mark — rounded square tile from the brand icon asset. */\nexport const LOGO_MARK_ROUNDED_VIEWBOX = { width: 36, height: 36 } as const;\n\n/** Default tile fill from the FT Mark Rounded Square source asset. */\nexport const LOGO_MARK_ROUNDED_TILE = logoColors.markRoundedTile;\n\n/**\n * Collapsed SideNav layout: 48×48 frame with a 36×36 mark centered inside\n * (white/transparent padding around the tile).\n */\nexport const SIDE_NAV_COLLAPSED_LOGO_FRAME = 48;\nexport const SIDE_NAV_COLLAPSED_LOGO_SIZE = 36;\n\nexport type FairmintLogoMarkRoundedVariant = \"tile\" | \"black\" | \"white\";\n\nexport interface FairmintLogoMarkRoundedProps {\n /** Square size of the mark in pixels. @default 32 */\n size?: number;\n /**\n * Outer frame size. When set larger than `size`, centers the mark in a\n * transparent square (e.g. frame 48 + size 36 for collapsed SideNav).\n */\n frameSize?: number;\n /**\n * `tile` — purple rounded square with white FT glyph (collapsed nav / app icon).\n * `black` — standalone FT ligature for light mode.\n * `white` — standalone FT ligature for dark mode.\n * @default \"tile\"\n */\n variant?: FairmintLogoMarkRoundedVariant;\n /** Rounded tile fill. Applies to `variant=\"tile\"`. @default LOGO_MARK_ROUNDED_TILE */\n tileColor?: string;\n /** Glyph fill override. Defaults from `variant`. */\n glyphColor?: string;\n /**\n * Accessible name when the mark is standalone (collapsed nav, favicon).\n * Omit or pass `\"\"` when decorative inside a labeled lockup or link.\n */\n alt?: string;\n className?: string;\n style?: CSSProperties;\n}\n\nfunction resolveGlyphColor(\n variant: FairmintLogoMarkRoundedVariant,\n glyphColor: string | undefined,\n): string {\n if (glyphColor) {\n return glyphColor;\n }\n return variant === \"black\" ? logoFills.black : logoFills.white;\n}\n\n/**\n * Fairmint FT mark — preferred collapsed SideNav / app-icon lockup.\n * Source geometry: FT Mark Rounded Square. `variant=\"tile\"` fills `size` with\n * the purple rounded square; `black` / `white` render the ligature alone for\n * light and dark surfaces. Optional `frameSize` adds transparent padding.\n */\nexport function FairmintLogoMarkRounded({\n size = 32,\n frameSize,\n variant = \"tile\",\n tileColor = LOGO_MARK_ROUNDED_TILE,\n glyphColor,\n alt,\n className,\n style,\n}: FairmintLogoMarkRoundedProps) {\n const isDecorative = !alt;\n const resolvedFrame = frameSize && frameSize > size ? frameSize : undefined;\n const showTile = variant === \"tile\";\n const resolvedGlyph = resolveGlyphColor(variant, glyphColor);\n\n const mark = (\n <svg\n viewBox={`0 0 ${LOGO_MARK_ROUNDED_VIEWBOX.width} ${LOGO_MARK_ROUNDED_VIEWBOX.height}`}\n width={size}\n height={size}\n className={resolvedFrame ? undefined : className}\n style={{ display: \"block\", flexShrink: 0, ...(resolvedFrame ? undefined : style) }}\n xmlns=\"http://www.w3.org/2000/svg\"\n aria-hidden={isDecorative || undefined}\n role={isDecorative ? undefined : \"img\"}\n aria-label={isDecorative ? undefined : alt}\n >\n {!isDecorative && <title>{alt}</title>}\n {/* Tile fills the viewBox — padding belongs on `frameSize`, not inside the SVG. */}\n {showTile && <rect width=\"36\" height=\"36\" rx=\"8\" fill={tileColor} />}\n <g transform=\"translate(18 18.07) scale(1.12) translate(-18 -18.07)\">\n <path d=\"M12.4661 20.3562V26.446H15.1251V18.7954L12.4661 20.3562Z\" fill={resolvedGlyph} />\n <path\n d=\"M22.5714 22.7206V18.7932L19.9113 20.354V22.9428C19.9113 25.447 20.5768 26.7091 23.391 26.7091C24.0115 26.7091 24.9416 26.6194 25.4954 26.3556V24.1164C25.1627 24.3598 24.5198 24.4499 24.055 24.4499C22.8819 24.4499 22.5714 23.7836 22.5714 22.7206Z\"\n fill={resolvedGlyph}\n />\n <path\n d=\"M16.4329 9.42847C13.1307 9.42847 12.4656 11.3557 12.4656 14.3028V15.822H15.1254V13.8818C15.1254 12.7079 15.3456 11.6881 16.8315 11.6881C17.2086 11.6881 17.5629 11.7555 17.9388 11.8445L18.1148 9.5829C17.5625 9.47197 17.0071 9.42847 16.4329 9.42847Z\"\n fill={resolvedGlyph}\n />\n <path d=\"M22.5714 12.7273H19.9113V15.8081H22.5714V12.7273Z\" fill={resolvedGlyph} />\n <path d=\"M25.7283 15.8218H10.2717V18.0841H25.7283V15.8218Z\" fill={resolvedGlyph} />\n </g>\n </svg>\n );\n\n if (!resolvedFrame) {\n return mark;\n }\n\n return (\n <span\n className={className}\n style={{\n display: \"inline-flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n width: resolvedFrame,\n height: resolvedFrame,\n flexShrink: 0,\n ...style,\n }}\n >\n {mark}\n </span>\n );\n}\n"],"names":["logoColors","logoFills","jsxs","jsx"],"mappings":";;;;AAIO,MAAM,4BAA4B,EAAE,OAAO,IAAI,QAAQ,GAAA;AAGvD,MAAM,yBAAyBA,KAAAA,WAAW;AAM1C,MAAM,gCAAgC;AACtC,MAAM,+BAA+B;AAgC5C,SAAS,kBACP,SACA,YACQ;AACR,MAAI,YAAY;AACd,WAAO;AAAA,EACT;AACA,SAAO,YAAY,UAAUC,KAAAA,UAAU,QAAQA,KAAAA,UAAU;AAC3D;AAQO,SAAS,wBAAwB;AAAA,EACtC,OAAO;AAAA,EACP;AAAA,EACA,UAAU;AAAA,EACV,YAAY;AAAA,EACZ;AAAA,EACA;AAAA,EACA;AAAA,EACA;AACF,GAAiC;AAC/B,QAAM,eAAe,CAAC;AACtB,QAAM,gBAAgB,aAAa,YAAY,OAAO,YAAY;AAClE,QAAM,WAAW,YAAY;AAC7B,QAAM,gBAAgB,kBAAkB,SAAS,UAAU;AAE3D,QAAM,OACJC,2BAAAA;AAAAA,IAAC;AAAA,IAAA;AAAA,MACC,SAAS,OAAO,0BAA0B,KAAK,IAAI,0BAA0B,MAAM;AAAA,MACnF,OAAO;AAAA,MACP,QAAQ;AAAA,MACR,WAAW,gBAAgB,SAAY;AAAA,MACvC,OAAO,EAAE,SAAS,SAAS,YAAY,GAAG,GAAI,gBAAgB,SAAY,MAAA;AAAA,MAC1E,OAAM;AAAA,MACN,eAAa,gBAAgB;AAAA,MAC7B,MAAM,eAAe,SAAY;AAAA,MACjC,cAAY,eAAe,SAAY;AAAA,MAEtC,UAAA;AAAA,QAAA,CAAC,gBAAgBC,2BAAAA,IAAC,SAAA,EAAO,UAAA,IAAA,CAAI;AAAA,QAE7B,YAAYA,2BAAAA,IAAC,QAAA,EAAK,OAAM,MAAK,QAAO,MAAK,IAAG,KAAI,MAAM,UAAA,CAAW;AAAA,QAClED,2BAAAA,KAAC,KAAA,EAAE,WAAU,yDACX,UAAA;AAAA,UAAAC,2BAAAA,IAAC,QAAA,EAAK,GAAE,4DAA2D,MAAM,eAAe;AAAA,UACxFA,2BAAAA;AAAAA,YAAC;AAAA,YAAA;AAAA,cACC,GAAE;AAAA,cACF,MAAM;AAAA,YAAA;AAAA,UAAA;AAAA,UAERA,2BAAAA;AAAAA,YAAC;AAAA,YAAA;AAAA,cACC,GAAE;AAAA,cACF,MAAM;AAAA,YAAA;AAAA,UAAA;AAAA,UAERA,2BAAAA,IAAC,QAAA,EAAK,GAAE,qDAAoD,MAAM,eAAe;AAAA,UACjFA,2BAAAA,IAAC,QAAA,EAAK,GAAE,qDAAoD,MAAM,cAAA,CAAe;AAAA,QAAA,EAAA,CACnF;AAAA,MAAA;AAAA,IAAA;AAAA,EAAA;AAIJ,MAAI,CAAC,eAAe;AAClB,WAAO;AAAA,EACT;AAEA,SACEA,2BAAAA;AAAAA,IAAC;AAAA,IAAA;AAAA,MACC;AAAA,MACA,OAAO;AAAA,QACL,SAAS;AAAA,QACT,YAAY;AAAA,QACZ,gBAAgB;AAAA,QAChB,OAAO;AAAA,QACP,QAAQ;AAAA,QACR,YAAY;AAAA,QACZ,GAAG;AAAA,MAAA;AAAA,MAGJ,UAAA;AAAA,IAAA;AAAA,EAAA;AAGP;;;;;;"}
|
|
@@ -12,17 +12,25 @@ export declare const LOGO_MARK_ROUNDED_TILE: "#825BFF";
|
|
|
12
12
|
*/
|
|
13
13
|
export declare const SIDE_NAV_COLLAPSED_LOGO_FRAME = 48;
|
|
14
14
|
export declare const SIDE_NAV_COLLAPSED_LOGO_SIZE = 36;
|
|
15
|
+
export type FairmintLogoMarkRoundedVariant = "tile" | "black" | "white";
|
|
15
16
|
export interface FairmintLogoMarkRoundedProps {
|
|
16
|
-
/** Square size of the
|
|
17
|
+
/** Square size of the mark in pixels. @default 32 */
|
|
17
18
|
size?: number;
|
|
18
19
|
/**
|
|
19
|
-
* Outer frame size. When set larger than `size`, centers the
|
|
20
|
+
* Outer frame size. When set larger than `size`, centers the mark in a
|
|
20
21
|
* transparent square (e.g. frame 48 + size 36 for collapsed SideNav).
|
|
21
22
|
*/
|
|
22
23
|
frameSize?: number;
|
|
23
|
-
/**
|
|
24
|
+
/**
|
|
25
|
+
* `tile` — purple rounded square with white FT glyph (collapsed nav / app icon).
|
|
26
|
+
* `black` — standalone FT ligature for light mode.
|
|
27
|
+
* `white` — standalone FT ligature for dark mode.
|
|
28
|
+
* @default "tile"
|
|
29
|
+
*/
|
|
30
|
+
variant?: FairmintLogoMarkRoundedVariant;
|
|
31
|
+
/** Rounded tile fill. Applies to `variant="tile"`. @default LOGO_MARK_ROUNDED_TILE */
|
|
24
32
|
tileColor?: string;
|
|
25
|
-
/** Glyph fill
|
|
33
|
+
/** Glyph fill override. Defaults from `variant`. */
|
|
26
34
|
glyphColor?: string;
|
|
27
35
|
/**
|
|
28
36
|
* Accessible name when the mark is standalone (collapsed nav, favicon).
|
|
@@ -33,9 +41,10 @@ export interface FairmintLogoMarkRoundedProps {
|
|
|
33
41
|
style?: CSSProperties;
|
|
34
42
|
}
|
|
35
43
|
/**
|
|
36
|
-
* Fairmint FT mark
|
|
37
|
-
* Source geometry: FT Mark Rounded Square.
|
|
38
|
-
* `
|
|
44
|
+
* Fairmint FT mark — preferred collapsed SideNav / app-icon lockup.
|
|
45
|
+
* Source geometry: FT Mark Rounded Square. `variant="tile"` fills `size` with
|
|
46
|
+
* the purple rounded square; `black` / `white` render the ligature alone for
|
|
47
|
+
* light and dark surfaces. Optional `frameSize` adds transparent padding.
|
|
39
48
|
*/
|
|
40
|
-
export declare function FairmintLogoMarkRounded({ size, frameSize, tileColor, glyphColor, alt, className, style, }: FairmintLogoMarkRoundedProps): import("react").JSX.Element;
|
|
49
|
+
export declare function FairmintLogoMarkRounded({ size, frameSize, variant, tileColor, glyphColor, alt, className, style, }: FairmintLogoMarkRoundedProps): import("react").JSX.Element;
|
|
41
50
|
//# sourceMappingURL=FairmintLogoMarkRounded.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"FairmintLogoMarkRounded.d.ts","sourceRoot":"","sources":["../../../src/components/FairmintLogo/FairmintLogoMarkRounded.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,OAAO,CAAC;AAG3C,uEAAuE;AACvE,eAAO,MAAM,yBAAyB;;;CAAqC,CAAC;AAE5E,sEAAsE;AACtE,eAAO,MAAM,sBAAsB,WAA6B,CAAC;AAEjE;;;GAGG;AACH,eAAO,MAAM,6BAA6B,KAAK,CAAC;AAChD,eAAO,MAAM,4BAA4B,KAAK,CAAC;AAE/C,MAAM,WAAW,4BAA4B;IAC3C,
|
|
1
|
+
{"version":3,"file":"FairmintLogoMarkRounded.d.ts","sourceRoot":"","sources":["../../../src/components/FairmintLogo/FairmintLogoMarkRounded.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,OAAO,CAAC;AAG3C,uEAAuE;AACvE,eAAO,MAAM,yBAAyB;;;CAAqC,CAAC;AAE5E,sEAAsE;AACtE,eAAO,MAAM,sBAAsB,WAA6B,CAAC;AAEjE;;;GAGG;AACH,eAAO,MAAM,6BAA6B,KAAK,CAAC;AAChD,eAAO,MAAM,4BAA4B,KAAK,CAAC;AAE/C,MAAM,MAAM,8BAA8B,GAAG,MAAM,GAAG,OAAO,GAAG,OAAO,CAAC;AAExE,MAAM,WAAW,4BAA4B;IAC3C,qDAAqD;IACrD,IAAI,CAAC,EAAE,MAAM,CAAC;IACd;;;OAGG;IACH,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB;;;;;OAKG;IACH,OAAO,CAAC,EAAE,8BAA8B,CAAC;IACzC,sFAAsF;IACtF,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,oDAAoD;IACpD,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB;;;OAGG;IACH,GAAG,CAAC,EAAE,MAAM,CAAC;IACb,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,KAAK,CAAC,EAAE,aAAa,CAAC;CACvB;AAYD;;;;;GAKG;AACH,wBAAgB,uBAAuB,CAAC,EACtC,IAAS,EACT,SAAS,EACT,OAAgB,EAChB,SAAkC,EAClC,UAAU,EACV,GAAG,EACH,SAAS,EACT,KAAK,GACN,EAAE,4BAA4B,+BAyD9B"}
|
|
@@ -4,17 +4,26 @@ const LOGO_MARK_ROUNDED_VIEWBOX = { width: 36, height: 36 };
|
|
|
4
4
|
const LOGO_MARK_ROUNDED_TILE = logoColors.markRoundedTile;
|
|
5
5
|
const SIDE_NAV_COLLAPSED_LOGO_FRAME = 48;
|
|
6
6
|
const SIDE_NAV_COLLAPSED_LOGO_SIZE = 36;
|
|
7
|
+
function resolveGlyphColor(variant, glyphColor) {
|
|
8
|
+
if (glyphColor) {
|
|
9
|
+
return glyphColor;
|
|
10
|
+
}
|
|
11
|
+
return variant === "black" ? logoFills.black : logoFills.white;
|
|
12
|
+
}
|
|
7
13
|
function FairmintLogoMarkRounded({
|
|
8
14
|
size = 32,
|
|
9
15
|
frameSize,
|
|
16
|
+
variant = "tile",
|
|
10
17
|
tileColor = LOGO_MARK_ROUNDED_TILE,
|
|
11
|
-
glyphColor
|
|
18
|
+
glyphColor,
|
|
12
19
|
alt,
|
|
13
20
|
className,
|
|
14
21
|
style
|
|
15
22
|
}) {
|
|
16
23
|
const isDecorative = !alt;
|
|
17
24
|
const resolvedFrame = frameSize && frameSize > size ? frameSize : void 0;
|
|
25
|
+
const showTile = variant === "tile";
|
|
26
|
+
const resolvedGlyph = resolveGlyphColor(variant, glyphColor);
|
|
18
27
|
const mark = /* @__PURE__ */ jsxs(
|
|
19
28
|
"svg",
|
|
20
29
|
{
|
|
@@ -29,25 +38,25 @@ function FairmintLogoMarkRounded({
|
|
|
29
38
|
"aria-label": isDecorative ? void 0 : alt,
|
|
30
39
|
children: [
|
|
31
40
|
!isDecorative && /* @__PURE__ */ jsx("title", { children: alt }),
|
|
32
|
-
/* @__PURE__ */ jsx("rect", { width: "36", height: "36", rx: "8", fill: tileColor }),
|
|
41
|
+
showTile && /* @__PURE__ */ jsx("rect", { width: "36", height: "36", rx: "8", fill: tileColor }),
|
|
33
42
|
/* @__PURE__ */ jsxs("g", { transform: "translate(18 18.07) scale(1.12) translate(-18 -18.07)", children: [
|
|
34
|
-
/* @__PURE__ */ jsx("path", { d: "M12.4661 20.3562V26.446H15.1251V18.7954L12.4661 20.3562Z", fill:
|
|
43
|
+
/* @__PURE__ */ jsx("path", { d: "M12.4661 20.3562V26.446H15.1251V18.7954L12.4661 20.3562Z", fill: resolvedGlyph }),
|
|
35
44
|
/* @__PURE__ */ jsx(
|
|
36
45
|
"path",
|
|
37
46
|
{
|
|
38
47
|
d: "M22.5714 22.7206V18.7932L19.9113 20.354V22.9428C19.9113 25.447 20.5768 26.7091 23.391 26.7091C24.0115 26.7091 24.9416 26.6194 25.4954 26.3556V24.1164C25.1627 24.3598 24.5198 24.4499 24.055 24.4499C22.8819 24.4499 22.5714 23.7836 22.5714 22.7206Z",
|
|
39
|
-
fill:
|
|
48
|
+
fill: resolvedGlyph
|
|
40
49
|
}
|
|
41
50
|
),
|
|
42
51
|
/* @__PURE__ */ jsx(
|
|
43
52
|
"path",
|
|
44
53
|
{
|
|
45
54
|
d: "M16.4329 9.42847C13.1307 9.42847 12.4656 11.3557 12.4656 14.3028V15.822H15.1254V13.8818C15.1254 12.7079 15.3456 11.6881 16.8315 11.6881C17.2086 11.6881 17.5629 11.7555 17.9388 11.8445L18.1148 9.5829C17.5625 9.47197 17.0071 9.42847 16.4329 9.42847Z",
|
|
46
|
-
fill:
|
|
55
|
+
fill: resolvedGlyph
|
|
47
56
|
}
|
|
48
57
|
),
|
|
49
|
-
/* @__PURE__ */ jsx("path", { d: "M22.5714 12.7273H19.9113V15.8081H22.5714V12.7273Z", fill:
|
|
50
|
-
/* @__PURE__ */ jsx("path", { d: "M25.7283 15.8218H10.2717V18.0841H25.7283V15.8218Z", fill:
|
|
58
|
+
/* @__PURE__ */ jsx("path", { d: "M22.5714 12.7273H19.9113V15.8081H22.5714V12.7273Z", fill: resolvedGlyph }),
|
|
59
|
+
/* @__PURE__ */ jsx("path", { d: "M25.7283 15.8218H10.2717V18.0841H25.7283V15.8218Z", fill: resolvedGlyph })
|
|
51
60
|
] })
|
|
52
61
|
]
|
|
53
62
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"FairmintLogoMarkRounded.js","sources":["../../../src/components/FairmintLogo/FairmintLogoMarkRounded.tsx"],"sourcesContent":["import type { CSSProperties } from \"react\";\nimport { logoColors, logoFills } from \"../../theme/logo\";\n\n/** Product FT mark — rounded square tile from the brand icon asset. */\nexport const LOGO_MARK_ROUNDED_VIEWBOX = { width: 36, height: 36 } as const;\n\n/** Default tile fill from the FT Mark Rounded Square source asset. */\nexport const LOGO_MARK_ROUNDED_TILE = logoColors.markRoundedTile;\n\n/**\n * Collapsed SideNav layout: 48×48 frame with a 36×36 mark centered inside\n * (white/transparent padding around the tile).\n */\nexport const SIDE_NAV_COLLAPSED_LOGO_FRAME = 48;\nexport const SIDE_NAV_COLLAPSED_LOGO_SIZE = 36;\n\nexport interface FairmintLogoMarkRoundedProps {\n /** Square size of the
|
|
1
|
+
{"version":3,"file":"FairmintLogoMarkRounded.js","sources":["../../../src/components/FairmintLogo/FairmintLogoMarkRounded.tsx"],"sourcesContent":["import type { CSSProperties } from \"react\";\nimport { logoColors, logoFills } from \"../../theme/logo\";\n\n/** Product FT mark — rounded square tile from the brand icon asset. */\nexport const LOGO_MARK_ROUNDED_VIEWBOX = { width: 36, height: 36 } as const;\n\n/** Default tile fill from the FT Mark Rounded Square source asset. */\nexport const LOGO_MARK_ROUNDED_TILE = logoColors.markRoundedTile;\n\n/**\n * Collapsed SideNav layout: 48×48 frame with a 36×36 mark centered inside\n * (white/transparent padding around the tile).\n */\nexport const SIDE_NAV_COLLAPSED_LOGO_FRAME = 48;\nexport const SIDE_NAV_COLLAPSED_LOGO_SIZE = 36;\n\nexport type FairmintLogoMarkRoundedVariant = \"tile\" | \"black\" | \"white\";\n\nexport interface FairmintLogoMarkRoundedProps {\n /** Square size of the mark in pixels. @default 32 */\n size?: number;\n /**\n * Outer frame size. When set larger than `size`, centers the mark in a\n * transparent square (e.g. frame 48 + size 36 for collapsed SideNav).\n */\n frameSize?: number;\n /**\n * `tile` — purple rounded square with white FT glyph (collapsed nav / app icon).\n * `black` — standalone FT ligature for light mode.\n * `white` — standalone FT ligature for dark mode.\n * @default \"tile\"\n */\n variant?: FairmintLogoMarkRoundedVariant;\n /** Rounded tile fill. Applies to `variant=\"tile\"`. @default LOGO_MARK_ROUNDED_TILE */\n tileColor?: string;\n /** Glyph fill override. Defaults from `variant`. */\n glyphColor?: string;\n /**\n * Accessible name when the mark is standalone (collapsed nav, favicon).\n * Omit or pass `\"\"` when decorative inside a labeled lockup or link.\n */\n alt?: string;\n className?: string;\n style?: CSSProperties;\n}\n\nfunction resolveGlyphColor(\n variant: FairmintLogoMarkRoundedVariant,\n glyphColor: string | undefined,\n): string {\n if (glyphColor) {\n return glyphColor;\n }\n return variant === \"black\" ? logoFills.black : logoFills.white;\n}\n\n/**\n * Fairmint FT mark — preferred collapsed SideNav / app-icon lockup.\n * Source geometry: FT Mark Rounded Square. `variant=\"tile\"` fills `size` with\n * the purple rounded square; `black` / `white` render the ligature alone for\n * light and dark surfaces. Optional `frameSize` adds transparent padding.\n */\nexport function FairmintLogoMarkRounded({\n size = 32,\n frameSize,\n variant = \"tile\",\n tileColor = LOGO_MARK_ROUNDED_TILE,\n glyphColor,\n alt,\n className,\n style,\n}: FairmintLogoMarkRoundedProps) {\n const isDecorative = !alt;\n const resolvedFrame = frameSize && frameSize > size ? frameSize : undefined;\n const showTile = variant === \"tile\";\n const resolvedGlyph = resolveGlyphColor(variant, glyphColor);\n\n const mark = (\n <svg\n viewBox={`0 0 ${LOGO_MARK_ROUNDED_VIEWBOX.width} ${LOGO_MARK_ROUNDED_VIEWBOX.height}`}\n width={size}\n height={size}\n className={resolvedFrame ? undefined : className}\n style={{ display: \"block\", flexShrink: 0, ...(resolvedFrame ? undefined : style) }}\n xmlns=\"http://www.w3.org/2000/svg\"\n aria-hidden={isDecorative || undefined}\n role={isDecorative ? undefined : \"img\"}\n aria-label={isDecorative ? undefined : alt}\n >\n {!isDecorative && <title>{alt}</title>}\n {/* Tile fills the viewBox — padding belongs on `frameSize`, not inside the SVG. */}\n {showTile && <rect width=\"36\" height=\"36\" rx=\"8\" fill={tileColor} />}\n <g transform=\"translate(18 18.07) scale(1.12) translate(-18 -18.07)\">\n <path d=\"M12.4661 20.3562V26.446H15.1251V18.7954L12.4661 20.3562Z\" fill={resolvedGlyph} />\n <path\n d=\"M22.5714 22.7206V18.7932L19.9113 20.354V22.9428C19.9113 25.447 20.5768 26.7091 23.391 26.7091C24.0115 26.7091 24.9416 26.6194 25.4954 26.3556V24.1164C25.1627 24.3598 24.5198 24.4499 24.055 24.4499C22.8819 24.4499 22.5714 23.7836 22.5714 22.7206Z\"\n fill={resolvedGlyph}\n />\n <path\n d=\"M16.4329 9.42847C13.1307 9.42847 12.4656 11.3557 12.4656 14.3028V15.822H15.1254V13.8818C15.1254 12.7079 15.3456 11.6881 16.8315 11.6881C17.2086 11.6881 17.5629 11.7555 17.9388 11.8445L18.1148 9.5829C17.5625 9.47197 17.0071 9.42847 16.4329 9.42847Z\"\n fill={resolvedGlyph}\n />\n <path d=\"M22.5714 12.7273H19.9113V15.8081H22.5714V12.7273Z\" fill={resolvedGlyph} />\n <path d=\"M25.7283 15.8218H10.2717V18.0841H25.7283V15.8218Z\" fill={resolvedGlyph} />\n </g>\n </svg>\n );\n\n if (!resolvedFrame) {\n return mark;\n }\n\n return (\n <span\n className={className}\n style={{\n display: \"inline-flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n width: resolvedFrame,\n height: resolvedFrame,\n flexShrink: 0,\n ...style,\n }}\n >\n {mark}\n </span>\n );\n}\n"],"names":[],"mappings":";;AAIO,MAAM,4BAA4B,EAAE,OAAO,IAAI,QAAQ,GAAA;AAGvD,MAAM,yBAAyB,WAAW;AAM1C,MAAM,gCAAgC;AACtC,MAAM,+BAA+B;AAgC5C,SAAS,kBACP,SACA,YACQ;AACR,MAAI,YAAY;AACd,WAAO;AAAA,EACT;AACA,SAAO,YAAY,UAAU,UAAU,QAAQ,UAAU;AAC3D;AAQO,SAAS,wBAAwB;AAAA,EACtC,OAAO;AAAA,EACP;AAAA,EACA,UAAU;AAAA,EACV,YAAY;AAAA,EACZ;AAAA,EACA;AAAA,EACA;AAAA,EACA;AACF,GAAiC;AAC/B,QAAM,eAAe,CAAC;AACtB,QAAM,gBAAgB,aAAa,YAAY,OAAO,YAAY;AAClE,QAAM,WAAW,YAAY;AAC7B,QAAM,gBAAgB,kBAAkB,SAAS,UAAU;AAE3D,QAAM,OACJ;AAAA,IAAC;AAAA,IAAA;AAAA,MACC,SAAS,OAAO,0BAA0B,KAAK,IAAI,0BAA0B,MAAM;AAAA,MACnF,OAAO;AAAA,MACP,QAAQ;AAAA,MACR,WAAW,gBAAgB,SAAY;AAAA,MACvC,OAAO,EAAE,SAAS,SAAS,YAAY,GAAG,GAAI,gBAAgB,SAAY,MAAA;AAAA,MAC1E,OAAM;AAAA,MACN,eAAa,gBAAgB;AAAA,MAC7B,MAAM,eAAe,SAAY;AAAA,MACjC,cAAY,eAAe,SAAY;AAAA,MAEtC,UAAA;AAAA,QAAA,CAAC,gBAAgB,oBAAC,SAAA,EAAO,UAAA,IAAA,CAAI;AAAA,QAE7B,YAAY,oBAAC,QAAA,EAAK,OAAM,MAAK,QAAO,MAAK,IAAG,KAAI,MAAM,UAAA,CAAW;AAAA,QAClE,qBAAC,KAAA,EAAE,WAAU,yDACX,UAAA;AAAA,UAAA,oBAAC,QAAA,EAAK,GAAE,4DAA2D,MAAM,eAAe;AAAA,UACxF;AAAA,YAAC;AAAA,YAAA;AAAA,cACC,GAAE;AAAA,cACF,MAAM;AAAA,YAAA;AAAA,UAAA;AAAA,UAER;AAAA,YAAC;AAAA,YAAA;AAAA,cACC,GAAE;AAAA,cACF,MAAM;AAAA,YAAA;AAAA,UAAA;AAAA,UAER,oBAAC,QAAA,EAAK,GAAE,qDAAoD,MAAM,eAAe;AAAA,UACjF,oBAAC,QAAA,EAAK,GAAE,qDAAoD,MAAM,cAAA,CAAe;AAAA,QAAA,EAAA,CACnF;AAAA,MAAA;AAAA,IAAA;AAAA,EAAA;AAIJ,MAAI,CAAC,eAAe;AAClB,WAAO;AAAA,EACT;AAEA,SACE;AAAA,IAAC;AAAA,IAAA;AAAA,MACC;AAAA,MACA,OAAO;AAAA,QACL,SAAS;AAAA,QACT,YAAY;AAAA,QACZ,gBAAgB;AAAA,QAChB,OAAO;AAAA,QACP,QAAQ;AAAA,QACR,YAAY;AAAA,QACZ,GAAG;AAAA,MAAA;AAAA,MAGJ,UAAA;AAAA,IAAA;AAAA,EAAA;AAGP;"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"AppHeader.cjs","sources":["../../../../src/components/layout/AppHeader/AppHeader.tsx"],"sourcesContent":["import { Burger, Group } from \"@mantine/core\";\nimport type { ReactNode } from \"react\";\n\nexport interface AppHeaderProps {\n /** Logo element (typically FairmintLogo). */\n logo
|
|
1
|
+
{"version":3,"file":"AppHeader.cjs","sources":["../../../../src/components/layout/AppHeader/AppHeader.tsx"],"sourcesContent":["import { Burger, Group } from \"@mantine/core\";\nimport type { ReactNode } from \"react\";\n\nexport interface AppHeaderProps {\n /** Logo element (typically FairmintLogo). Omit in product shells — wordmark lives in SideNav. */\n logo?: ReactNode;\n /** Right-aligned content (user menu, actions). */\n rightSection?: ReactNode;\n /** Whether mobile nav is open. Controls burger state. */\n mobileNavOpened?: boolean;\n /** Toggle mobile nav callback. */\n onMobileNavToggle?: () => void;\n /** Header height in pixels. @default 60 */\n height?: number;\n}\n\nexport function AppHeader({\n logo,\n rightSection,\n mobileNavOpened = false,\n onMobileNavToggle,\n height = 60,\n}: AppHeaderProps) {\n return (\n <Group h={height} px=\"md\" justify=\"space-between\">\n <Group>\n {onMobileNavToggle && (\n <Burger\n opened={mobileNavOpened}\n onClick={onMobileNavToggle}\n hiddenFrom=\"sm\"\n size=\"sm\"\n aria-label=\"Toggle navigation\"\n />\n )}\n {logo}\n </Group>\n {rightSection}\n </Group>\n );\n}\n"],"names":["Group","jsxs","jsx","Burger"],"mappings":";;;;;AAgBO,SAAS,UAAU;AAAA,EACxB;AAAA,EACA;AAAA,EACA,kBAAkB;AAAA,EAClB;AAAA,EACA,SAAS;AACX,GAAmB;AACjB,yCACGA,aAAA,EAAM,GAAG,QAAQ,IAAG,MAAK,SAAQ,iBAChC,UAAA;AAAA,IAAAC,gCAACD,MAAAA,OAAA,EACE,UAAA;AAAA,MAAA,qBACCE,2BAAAA;AAAAA,QAACC,OAAAA;AAAAA,QAAA;AAAA,UACC,QAAQ;AAAA,UACR,SAAS;AAAA,UACT,YAAW;AAAA,UACX,MAAK;AAAA,UACL,cAAW;AAAA,QAAA;AAAA,MAAA;AAAA,MAGd;AAAA,IAAA,GACH;AAAA,IACC;AAAA,EAAA,GACH;AAEJ;;"}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { ReactNode } from 'react';
|
|
2
2
|
export interface AppHeaderProps {
|
|
3
|
-
/** Logo element (typically FairmintLogo). */
|
|
4
|
-
logo
|
|
3
|
+
/** Logo element (typically FairmintLogo). Omit in product shells — wordmark lives in SideNav. */
|
|
4
|
+
logo?: ReactNode;
|
|
5
5
|
/** Right-aligned content (user menu, actions). */
|
|
6
6
|
rightSection?: ReactNode;
|
|
7
7
|
/** Whether mobile nav is open. Controls burger state. */
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"AppHeader.d.ts","sourceRoot":"","sources":["../../../../src/components/layout/AppHeader/AppHeader.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAEvC,MAAM,WAAW,cAAc;IAC7B,
|
|
1
|
+
{"version":3,"file":"AppHeader.d.ts","sourceRoot":"","sources":["../../../../src/components/layout/AppHeader/AppHeader.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAEvC,MAAM,WAAW,cAAc;IAC7B,iGAAiG;IACjG,IAAI,CAAC,EAAE,SAAS,CAAC;IACjB,kDAAkD;IAClD,YAAY,CAAC,EAAE,SAAS,CAAC;IACzB,yDAAyD;IACzD,eAAe,CAAC,EAAE,OAAO,CAAC;IAC1B,kCAAkC;IAClC,iBAAiB,CAAC,EAAE,MAAM,IAAI,CAAC;IAC/B,2CAA2C;IAC3C,MAAM,CAAC,EAAE,MAAM,CAAC;CACjB;AAED,wBAAgB,SAAS,CAAC,EACxB,IAAI,EACJ,YAAY,EACZ,eAAuB,EACvB,iBAAiB,EACjB,MAAW,GACZ,EAAE,cAAc,+BAkBhB"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"AppHeader.js","sources":["../../../../src/components/layout/AppHeader/AppHeader.tsx"],"sourcesContent":["import { Burger, Group } from \"@mantine/core\";\nimport type { ReactNode } from \"react\";\n\nexport interface AppHeaderProps {\n /** Logo element (typically FairmintLogo). */\n logo
|
|
1
|
+
{"version":3,"file":"AppHeader.js","sources":["../../../../src/components/layout/AppHeader/AppHeader.tsx"],"sourcesContent":["import { Burger, Group } from \"@mantine/core\";\nimport type { ReactNode } from \"react\";\n\nexport interface AppHeaderProps {\n /** Logo element (typically FairmintLogo). Omit in product shells — wordmark lives in SideNav. */\n logo?: ReactNode;\n /** Right-aligned content (user menu, actions). */\n rightSection?: ReactNode;\n /** Whether mobile nav is open. Controls burger state. */\n mobileNavOpened?: boolean;\n /** Toggle mobile nav callback. */\n onMobileNavToggle?: () => void;\n /** Header height in pixels. @default 60 */\n height?: number;\n}\n\nexport function AppHeader({\n logo,\n rightSection,\n mobileNavOpened = false,\n onMobileNavToggle,\n height = 60,\n}: AppHeaderProps) {\n return (\n <Group h={height} px=\"md\" justify=\"space-between\">\n <Group>\n {onMobileNavToggle && (\n <Burger\n opened={mobileNavOpened}\n onClick={onMobileNavToggle}\n hiddenFrom=\"sm\"\n size=\"sm\"\n aria-label=\"Toggle navigation\"\n />\n )}\n {logo}\n </Group>\n {rightSection}\n </Group>\n );\n}\n"],"names":[],"mappings":";;;AAgBO,SAAS,UAAU;AAAA,EACxB;AAAA,EACA;AAAA,EACA,kBAAkB;AAAA,EAClB;AAAA,EACA,SAAS;AACX,GAAmB;AACjB,8BACG,OAAA,EAAM,GAAG,QAAQ,IAAG,MAAK,SAAQ,iBAChC,UAAA;AAAA,IAAA,qBAAC,OAAA,EACE,UAAA;AAAA,MAAA,qBACC;AAAA,QAAC;AAAA,QAAA;AAAA,UACC,QAAQ;AAAA,UACR,SAAS;AAAA,UACT,YAAW;AAAA,UACX,MAAK;AAAA,UACL,cAAW;AAAA,QAAA;AAAA,MAAA;AAAA,MAGd;AAAA,IAAA,GACH;AAAA,IACC;AAAA,EAAA,GACH;AAEJ;"}
|
|
@@ -13,7 +13,7 @@ export declare const studioLegacyWithFundraisingSections: NonNullable<SideNavPro
|
|
|
13
13
|
/** Master / venture fund portals — no Cap Table / Fundraising / Grants / Tax. */
|
|
14
14
|
export declare const studioFundSections: NonNullable<SideNavProps["sections"]>;
|
|
15
15
|
/** Labels that must appear for the unified (new portal) Studio nav. */
|
|
16
|
-
export declare const STUDIO_UNIFIED_TOP_LEVEL_LABELS: readonly ["Dashboard", "Stakeholders", "Cap Table", "Fundraising", "Grants", "Tax & Compliance", "Documents"];
|
|
16
|
+
export declare const STUDIO_UNIFIED_TOP_LEVEL_LABELS: readonly ["Dashboard", "Stakeholders", "Cap Table", "Fundraising", "Grants", "Tax & Compliance", "Documents", "Settings"];
|
|
17
17
|
/** Labels that must appear for the classic legacy Studio nav. */
|
|
18
|
-
export declare const STUDIO_LEGACY_TOP_LEVEL_LABELS: readonly ["Dashboard", "Stakeholders", "Investments", "Cap Table", "Shares", "SAFEs", "Warrants", "Grants", "Tax & Compliance", "Documents"];
|
|
18
|
+
export declare const STUDIO_LEGACY_TOP_LEVEL_LABELS: readonly ["Dashboard", "Stakeholders", "Investments", "Cap Table", "Shares", "SAFEs", "Warrants", "Grants", "Tax & Compliance", "Documents", "Settings"];
|
|
19
19
|
//# sourceMappingURL=studioNavFixtures.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"studioNavFixtures.d.ts","sourceRoot":"","sources":["../../../../src/components/layout/SideNav/studioNavFixtures.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"studioNavFixtures.d.ts","sourceRoot":"","sources":["../../../../src/components/layout/SideNav/studioNavFixtures.tsx"],"names":[],"mappings":"AAeA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,WAAW,CAAC;AA+G9C,kGAAkG;AAClG,eAAO,MAAM,qBAAqB,EAAE,WAAW,CAAC,YAAY,CAAC,UAAU,CAAC,CAKvE,CAAC;AAEF,wDAAwD;AACxD,eAAO,MAAM,4BAA4B,EAAE,WAAW,CAAC,YAAY,CAAC,UAAU,CAAC,CAe9E,CAAC;AAEF;;;GAGG;AACH,eAAO,MAAM,oBAAoB,EAAE,WAAW,CAAC,YAAY,CAAC,UAAU,CAAC,CAiBtE,CAAC;AAEF,kFAAkF;AAClF,eAAO,MAAM,mCAAmC,EAAE,WAAW,CAAC,YAAY,CAAC,UAAU,CAAC,CAkBrF,CAAC;AAEF,iFAAiF;AACjF,eAAO,MAAM,kBAAkB,EAAE,WAAW,CAAC,YAAY,CAAC,UAAU,CAAC,CAoBpE,CAAC;AAEF,uEAAuE;AACvE,eAAO,MAAM,+BAA+B,2HASlC,CAAC;AAEX,iEAAiE;AACjE,eAAO,MAAM,8BAA8B,0JAYjC,CAAC"}
|
|
@@ -24,6 +24,7 @@ const Modal = require("../../node_modules/@mantine/core/esm/components/Modal/Mod
|
|
|
24
24
|
const Stack$1 = require("../../node_modules/@mantine/core/esm/components/Stack/Stack.cjs");
|
|
25
25
|
const Menu = require("../../node_modules/@mantine/core/esm/components/Menu/Menu.cjs");
|
|
26
26
|
const TextInput = require("../../node_modules/@mantine/core/esm/components/TextInput/TextInput.cjs");
|
|
27
|
+
const colors = require("../../theme/colors.cjs");
|
|
27
28
|
dayjs_min.extend(customParseFormat);
|
|
28
29
|
const compatBreakpointKeys = ["xs", "sm", "md", "lg", "xl"];
|
|
29
30
|
const compatFallbackBreakpoints = {
|
|
@@ -96,6 +97,34 @@ const mapCompatSize = (size) => {
|
|
|
96
97
|
}
|
|
97
98
|
return void 0;
|
|
98
99
|
};
|
|
100
|
+
const mantineChipVariants = /* @__PURE__ */ new Set([
|
|
101
|
+
"default",
|
|
102
|
+
"dot",
|
|
103
|
+
"filled",
|
|
104
|
+
"gradient",
|
|
105
|
+
"light",
|
|
106
|
+
"outline",
|
|
107
|
+
"transparent",
|
|
108
|
+
"white"
|
|
109
|
+
]);
|
|
110
|
+
const mapChipVariant = (variant) => {
|
|
111
|
+
if (variant === "outlined") return "outline";
|
|
112
|
+
if (typeof variant === "string" && mantineChipVariants.has(variant)) return variant;
|
|
113
|
+
return void 0;
|
|
114
|
+
};
|
|
115
|
+
const chipBadgeColorMap = {
|
|
116
|
+
default: colors.colors.neutral,
|
|
117
|
+
error: colors.colors.error,
|
|
118
|
+
info: colors.colors.info,
|
|
119
|
+
primary: colors.colors.primary,
|
|
120
|
+
secondary: colors.colors.neutral,
|
|
121
|
+
success: colors.colors.success,
|
|
122
|
+
warning: colors.colors.warning
|
|
123
|
+
};
|
|
124
|
+
const mapChipBadgeColor = (color) => {
|
|
125
|
+
if (typeof color !== "string" || !color) return colors.colors.neutral;
|
|
126
|
+
return chipBadgeColorMap[color] || color;
|
|
127
|
+
};
|
|
99
128
|
const mapCompatIconButtonSize = (size) => size === "small" ? "sm" : size === "medium" ? "md" : size === "large" ? "lg" : size;
|
|
100
129
|
const optionalBoolean = (value) => typeof value === "boolean" ? value : void 0;
|
|
101
130
|
const optionalString = (value) => typeof value === "string" ? value : void 0;
|
|
@@ -893,7 +922,9 @@ const Chip = ({
|
|
|
893
922
|
icon,
|
|
894
923
|
onClick,
|
|
895
924
|
onDelete,
|
|
925
|
+
size,
|
|
896
926
|
sx: sx2,
|
|
927
|
+
variant,
|
|
897
928
|
...props
|
|
898
929
|
}) => {
|
|
899
930
|
const chipClassName = [
|
|
@@ -948,9 +979,11 @@ const Chip = ({
|
|
|
948
979
|
Badge.Badge,
|
|
949
980
|
{
|
|
950
981
|
className: chipClassName,
|
|
951
|
-
color:
|
|
982
|
+
color: mapChipBadgeColor(color),
|
|
952
983
|
leftSection: icon ? /* @__PURE__ */ jsxRuntime.jsx("span", { className: "fairmint-chip-icon", children: icon }) : void 0,
|
|
984
|
+
size: mapCompatSize(size),
|
|
953
985
|
style: { textTransform: "none", ...sxToStyle(sx2) },
|
|
986
|
+
variant: mapChipVariant(variant),
|
|
954
987
|
...props,
|
|
955
988
|
children: content
|
|
956
989
|
}
|