@hdb-c360/c360-shared-ui 0.1.0 → 0.1.2
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/components/badge.d.ts +8 -7
- package/dist/components/badge.d.ts.map +1 -1
- package/dist/components/badge.js +11 -19
- package/dist/components/badge.js.map +1 -1
- package/dist/components/brand-card.d.ts +8 -0
- package/dist/components/brand-card.d.ts.map +1 -0
- package/dist/components/brand-card.js +6 -0
- package/dist/components/brand-card.js.map +1 -0
- package/dist/components/button.d.ts +6 -9
- package/dist/components/button.d.ts.map +1 -1
- package/dist/components/button.js +14 -30
- package/dist/components/button.js.map +1 -1
- package/dist/components/card.d.ts +7 -7
- package/dist/components/card.d.ts.map +1 -1
- package/dist/components/card.js +8 -8
- package/dist/components/card.js.map +1 -1
- package/dist/components/content-container.d.ts +3 -0
- package/dist/components/content-container.d.ts.map +1 -0
- package/dist/components/content-container.js +6 -0
- package/dist/components/content-container.js.map +1 -0
- package/dist/components/data-table-shell.d.ts +20 -0
- package/dist/components/data-table-shell.d.ts.map +1 -0
- package/dist/components/data-table-shell.js +9 -0
- package/dist/components/data-table-shell.js.map +1 -0
- package/dist/components/empty-state.d.ts +6 -5
- package/dist/components/empty-state.d.ts.map +1 -1
- package/dist/components/empty-state.js +3 -3
- package/dist/components/empty-state.js.map +1 -1
- package/dist/components/error-state.d.ts +14 -0
- package/dist/components/error-state.d.ts.map +1 -0
- package/dist/components/error-state.js +8 -0
- package/dist/components/error-state.js.map +1 -0
- package/dist/components/form-field-wrapper.d.ts +12 -0
- package/dist/components/form-field-wrapper.d.ts.map +1 -0
- package/dist/components/form-field-wrapper.js +6 -0
- package/dist/components/form-field-wrapper.js.map +1 -0
- package/dist/components/gradient-button.d.ts +3 -0
- package/dist/components/gradient-button.d.ts.map +1 -0
- package/dist/components/gradient-button.js +6 -0
- package/dist/components/gradient-button.js.map +1 -0
- package/dist/components/index.d.ts +10 -0
- package/dist/components/index.d.ts.map +1 -1
- package/dist/components/index.js +10 -0
- package/dist/components/index.js.map +1 -1
- package/dist/components/input.d.ts +4 -4
- package/dist/components/input.d.ts.map +1 -1
- package/dist/components/input.js +4 -4
- package/dist/components/input.js.map +1 -1
- package/dist/components/loading-state.d.ts +8 -0
- package/dist/components/loading-state.d.ts.map +1 -0
- package/dist/components/loading-state.js +6 -0
- package/dist/components/loading-state.js.map +1 -0
- package/dist/components/page-header.d.ts +5 -4
- package/dist/components/page-header.d.ts.map +1 -1
- package/dist/components/page-header.js +3 -3
- package/dist/components/page-header.js.map +1 -1
- package/dist/components/section-card.d.ts +12 -0
- package/dist/components/section-card.d.ts.map +1 -0
- package/dist/components/section-card.js +7 -0
- package/dist/components/section-card.js.map +1 -0
- package/dist/components/skeleton.d.ts +2 -2
- package/dist/components/skeleton.d.ts.map +1 -1
- package/dist/components/skeleton.js +3 -3
- package/dist/components/skeleton.js.map +1 -1
- package/dist/components/status-badge.d.ts +9 -0
- package/dist/components/status-badge.d.ts.map +1 -0
- package/dist/components/status-badge.js +37 -0
- package/dist/components/status-badge.js.map +1 -0
- package/dist/components/switch.d.ts +6 -0
- package/dist/components/switch.d.ts.map +1 -0
- package/dist/components/switch.js +9 -0
- package/dist/components/switch.js.map +1 -0
- package/dist/components/table.d.ts +7 -7
- package/dist/components/table.d.ts.map +1 -1
- package/dist/components/table.js +8 -8
- package/dist/components/table.js.map +1 -1
- package/dist/index.d.ts +2 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +2 -0
- package/dist/index.js.map +1 -1
- package/dist/styles.css +26 -116
- package/dist/theme/c360-theme.d.ts +10 -0
- package/dist/theme/c360-theme.d.ts.map +1 -0
- package/dist/theme/c360-theme.js +90 -0
- package/dist/theme/c360-theme.js.map +1 -0
- package/dist/theme/colorData.d.ts +111 -0
- package/dist/theme/colorData.d.ts.map +1 -0
- package/dist/theme/colorData.js +151 -0
- package/dist/theme/colorData.js.map +1 -0
- package/dist/theme/index.d.ts +3 -0
- package/dist/theme/index.d.ts.map +1 -0
- package/dist/theme/index.js +3 -0
- package/dist/theme/index.js.map +1 -0
- package/dist/theme-augmentation.d.ts +34 -0
- package/dist/theme-augmentation.d.ts.map +1 -0
- package/dist/theme-augmentation.js +2 -0
- package/dist/theme-augmentation.js.map +1 -0
- package/package.json +13 -9
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"loading-state.d.ts","sourceRoot":"","sources":["../../src/components/loading-state.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAsC,KAAK,UAAU,EAAE,MAAM,eAAe,CAAC;AAEpF,UAAU,iBAAkB,SAAQ,UAAU;IAAG,IAAI,CAAC,EAAE,MAAM,CAAC;IAAC,UAAU,CAAC,EAAE,OAAO,CAAA;CAAE;AAEtF,wBAAgB,YAAY,CAAC,EAAE,IAAQ,EAAE,UAAiB,EAAE,GAAG,KAAK,EAAE,EAAE,iBAAiB,+BAOxF"}
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
|
+
import { Card, CardContent, Skeleton, Stack } from "@mui/material";
|
|
3
|
+
export function LoadingState({ rows = 4, showHeader = true, ...props }) {
|
|
4
|
+
return (_jsxs(Stack, { spacing: 4, ...props, children: [showHeader ? _jsxs(Stack, { direction: "row", spacing: 4, sx: { alignItems: "center" }, children: [_jsx(Skeleton, { variant: "rounded", width: 40, height: 40 }), _jsxs(Stack, { spacing: 1, sx: { flex: 1 }, children: [_jsx(Skeleton, { width: 224 }), _jsx(Skeleton, { width: "40%" })] })] }) : null, _jsx(Card, { variant: "outlined", children: _jsx(CardContent, { children: _jsx(Stack, { spacing: 2, children: Array.from({ length: rows }).map((_, index) => _jsx(Skeleton, { variant: "rounded", height: 48 }, index)) }) }) })] }));
|
|
5
|
+
}
|
|
6
|
+
//# sourceMappingURL=loading-state.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"loading-state.js","sourceRoot":"","sources":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"react";
|
|
3
|
+
interface PageHeaderProps extends BoxProps {
|
|
3
4
|
title: string;
|
|
4
5
|
description?: string;
|
|
5
|
-
actions?:
|
|
6
|
+
actions?: ReactNode;
|
|
6
7
|
}
|
|
7
|
-
export declare function PageHeader({ title, description, actions,
|
|
8
|
+
export declare function PageHeader({ title, description, actions, sx, ...props }: PageHeaderProps): import("react").JSX.Element;
|
|
8
9
|
export {};
|
|
9
10
|
//# sourceMappingURL=page-header.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"page-header.d.ts","sourceRoot":"","sources":["../../src/components/page-header.tsx"],"names":[],"mappings":"AAAA,OAAO,
|
|
1
|
+
{"version":3,"file":"page-header.d.ts","sourceRoot":"","sources":["../../src/components/page-header.tsx"],"names":[],"mappings":"AAAA,OAAO,EAA0B,KAAK,QAAQ,EAAE,MAAM,eAAe,CAAC;AACtE,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAEvC,UAAU,eAAgB,SAAQ,QAAQ;IACxC,KAAK,EAAE,MAAM,CAAC;IACd,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,OAAO,CAAC,EAAE,SAAS,CAAC;CACrB;AAED,wBAAgB,UAAU,CAAC,EAAE,KAAK,EAAE,WAAW,EAAE,OAAO,EAAE,EAAE,EAAE,GAAG,KAAK,EAAE,EAAE,eAAe,+BAUxF"}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
|
-
import {
|
|
3
|
-
export function PageHeader({ title, description, actions,
|
|
4
|
-
return (_jsxs(
|
|
2
|
+
import { Box, Stack, Typography } from "@mui/material";
|
|
3
|
+
export function PageHeader({ title, description, actions, sx, ...props }) {
|
|
4
|
+
return (_jsxs(Box, { sx: { display: "flex", flexDirection: { xs: "column", md: "row" }, alignItems: { md: "flex-start" }, justifyContent: "space-between", gap: 4, ...sx }, ...props, children: [_jsxs(Box, { sx: { minWidth: 0 }, children: [_jsx(Typography, { component: "h1", variant: "h4", children: title }), description ? _jsx(Typography, { color: "text.secondary", sx: { mt: 1, maxWidth: 920 }, children: description }) : null] }), actions ? _jsx(Stack, { direction: "row", useFlexGap: true, spacing: 2, sx: { flexWrap: "wrap" }, children: actions }) : null] }));
|
|
5
5
|
}
|
|
6
6
|
//# sourceMappingURL=page-header.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"page-header.js","sourceRoot":"","sources":["../../src/components/page-header.tsx"],"names":[],"mappings":";
|
|
1
|
+
{"version":3,"file":"page-header.js","sourceRoot":"","sources":["../../src/components/page-header.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,GAAG,EAAE,KAAK,EAAE,UAAU,EAAiB,MAAM,eAAe,CAAC;AAStE,MAAM,UAAU,UAAU,CAAC,EAAE,KAAK,EAAE,WAAW,EAAE,OAAO,EAAE,EAAE,EAAE,GAAG,KAAK,EAAmB;IACvF,OAAO,CACL,MAAC,GAAG,IAAC,EAAE,EAAE,EAAE,OAAO,EAAE,MAAM,EAAE,aAAa,EAAE,EAAE,EAAE,EAAE,QAAQ,EAAE,EAAE,EAAE,KAAK,EAAE,EAAE,UAAU,EAAE,EAAE,EAAE,EAAE,YAAY,EAAE,EAAE,cAAc,EAAE,eAAe,EAAE,GAAG,EAAE,CAAC,EAAE,GAAG,EAAE,EAAE,KAAM,KAAK,aACnK,MAAC,GAAG,IAAC,EAAE,EAAE,EAAE,QAAQ,EAAE,CAAC,EAAE,aACtB,KAAC,UAAU,IAAC,SAAS,EAAC,IAAI,EAAC,OAAO,EAAC,IAAI,YAAE,KAAK,GAAc,EAC3D,WAAW,CAAC,CAAC,CAAC,KAAC,UAAU,IAAC,KAAK,EAAC,gBAAgB,EAAC,EAAE,EAAE,EAAE,EAAE,EAAE,CAAC,EAAE,QAAQ,EAAE,GAAG,EAAE,YAAG,WAAW,GAAc,CAAC,CAAC,CAAC,IAAI,IAC7G,EACL,OAAO,CAAC,CAAC,CAAC,KAAC,KAAK,IAAC,SAAS,EAAC,KAAK,EAAC,UAAU,QAAC,OAAO,EAAE,CAAC,EAAE,EAAE,EAAE,EAAE,QAAQ,EAAE,MAAM,EAAE,YAAG,OAAO,GAAS,CAAC,CAAC,CAAC,IAAI,IACvG,CACP,CAAC;AACJ,CAAC"}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { type CardProps } from "@mui/material";
|
|
2
|
+
import type { ReactNode } from "react";
|
|
3
|
+
interface SectionCardProps extends CardProps {
|
|
4
|
+
title?: string;
|
|
5
|
+
description?: string;
|
|
6
|
+
actions?: ReactNode;
|
|
7
|
+
icon?: ReactNode;
|
|
8
|
+
padded?: boolean;
|
|
9
|
+
}
|
|
10
|
+
export declare function SectionCard({ title, description, actions, icon, children, padded, sx, ...props }: SectionCardProps): import("react").JSX.Element;
|
|
11
|
+
export {};
|
|
12
|
+
//# sourceMappingURL=section-card.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"section-card.d.ts","sourceRoot":"","sources":["../../src/components/section-card.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAyC,KAAK,SAAS,EAAE,MAAM,eAAe,CAAC;AACtF,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAEvC,UAAU,gBAAiB,SAAQ,SAAS;IAC1C,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,OAAO,CAAC,EAAE,SAAS,CAAC;IACpB,IAAI,CAAC,EAAE,SAAS,CAAC;IACjB,MAAM,CAAC,EAAE,OAAO,CAAC;CAClB;AAED,wBAAgB,WAAW,CAAC,EAAE,KAAK,EAAE,WAAW,EAAE,OAAO,EAAE,IAAI,EAAE,QAAQ,EAAE,MAAa,EAAE,EAAE,EAAE,GAAG,KAAK,EAAE,EAAE,gBAAgB,+BAmBzH"}
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-runtime";
|
|
2
|
+
import { Box, Card, Divider, Stack, Typography } from "@mui/material";
|
|
3
|
+
export function SectionCard({ title, description, actions, icon, children, padded = true, sx, ...props }) {
|
|
4
|
+
const hasHeader = Boolean(title || description || actions);
|
|
5
|
+
return (_jsxs(Card, { variant: "outlined", sx: { borderRadius: 3, transition: "box-shadow 160ms ease", "&:hover": { boxShadow: 2 }, ...sx }, ...props, children: [hasHeader ? (_jsxs(_Fragment, { children: [_jsxs(Stack, { direction: { xs: "column", md: "row" }, spacing: 2, sx: { p: 4, justifyContent: "space-between", alignItems: { md: "flex-start" } }, children: [_jsxs(Box, { children: [title ? _jsxs(Stack, { direction: "row", spacing: 2, sx: { alignItems: "center" }, children: [_jsx(Box, { sx: { color: "text.secondary" }, children: icon }), _jsx(Typography, { variant: "h6", children: title })] }) : null, description ? _jsx(Typography, { variant: "body2", color: "text.secondary", sx: { mt: 1 }, children: description }) : null] }), actions] }), _jsx(Divider, {})] })) : null, _jsx(Box, { sx: padded ? { p: 4 } : undefined, children: children })] }));
|
|
6
|
+
}
|
|
7
|
+
//# sourceMappingURL=section-card.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"section-card.js","sourceRoot":"","sources":["../../src/components/section-card.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,GAAG,EAAE,IAAI,EAAE,OAAO,EAAE,KAAK,EAAE,UAAU,EAAkB,MAAM,eAAe,CAAC;AAWtF,MAAM,UAAU,WAAW,CAAC,EAAE,KAAK,EAAE,WAAW,EAAE,OAAO,EAAE,IAAI,EAAE,QAAQ,EAAE,MAAM,GAAG,IAAI,EAAE,EAAE,EAAE,GAAG,KAAK,EAAoB;IACxH,MAAM,SAAS,GAAG,OAAO,CAAC,KAAK,IAAI,WAAW,IAAI,OAAO,CAAC,CAAC;IAC3D,OAAO,CACL,MAAC,IAAI,IAAC,OAAO,EAAC,UAAU,EAAC,EAAE,E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eleton(
|
|
1
|
+
import { type SkeletonProps } from "@mui/material";
|
|
2
|
+
export declare function Skeleton(props: SkeletonProps): import("react").JSX.Element;
|
|
3
3
|
//# sourceMappingURL=skeleton.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"skeleton.d.ts","sourceRoot":"","sources":["../../src/components/skeleton.tsx"],"names":[],"mappings":"AAAA,OAAO,
|
|
1
|
+
{"version":3,"file":"skeleton.d.ts","sourceRoot":"","sources":["../../src/components/skeleton.tsx"],"names":[],"mappings":"AAAA,OAAO,EAA2B,KAAK,aAAa,EAAE,MAAM,eAAe,CAAC;AAE5E,wBAAgB,QAAQ,CAAC,KAAK,EAAE,aAAa,+BAE5C"}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
2
|
-
import {
|
|
3
|
-
export function Skeleton(
|
|
4
|
-
return
|
|
2
|
+
import { Skeleton as MuiSkeleton } from "@mui/material";
|
|
3
|
+
export function Skeleton(props) {
|
|
4
|
+
return _jsx(MuiSkeleton, { animation: "wave", variant: "rounded", ...props });
|
|
5
5
|
}
|
|
6
6
|
//# sourceMappingURL=skeleton.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"skeleton.js","sourceRoot":"","sources":["../../src/components/skeleton.tsx"],"names":[],"mappings":";
|
|
1
|
+
{"version":3,"file":"skeleton.js","sourceRoot":"","sources":["../../src/components/skeleton.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,QAAQ,IAAI,WAAW,EAAsB,MAAM,eAAe,CAAC;AAE5E,MAAM,UAAU,QAAQ,CAAC,KAAoB;IAC3C,OAAO,KAAC,WAAW,IAAC,SAAS,EAAC,MAAM,EAAC,OAAO,EAAC,SAAS,KAAK,KAAK,GAAI,CAAC;AACvE,CAAC"}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { type BadgeProps } from "./badge";
|
|
2
|
+
export type StatusValue = "active" | "inactive" | "pending" | "success" | "error" | "warning" | "info" | string;
|
|
3
|
+
interface StatusBadgeProps extends Omit<BadgeProps, "children" | "variant"> {
|
|
4
|
+
status: StatusValue;
|
|
5
|
+
variant?: "default" | "success" | "destructive" | "warning" | "info" | "secondary";
|
|
6
|
+
}
|
|
7
|
+
export declare function StatusBadge({ status, variant, className, ...props }: StatusBadgeProps): import("react").JSX.Element;
|
|
8
|
+
export {};
|
|
9
|
+
//# sourceMappingURL=status-badge.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"status-badge.d.ts","sourceRoot":"","sources":["../../src/components/status-badge.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAS,KAAK,UAAU,EAAE,MAAM,SAAS,CAAC;AAEjD,MAAM,MAAM,WAAW,GACnB,QAAQ,GACR,UAAU,GACV,SAAS,GACT,SAAS,GACT,OAAO,GACP,SAAS,GACT,MAAM,GACN,MAAM,CAAC;AAEX,UAAU,gBAAiB,SAAQ,IAAI,CAAC,UAAU,EAAE,UAAU,GAAG,SAAS,CAAC;IACzE,MAAM,EAAE,WAAW,CAAC;IACpB,OAAO,CAAC,EAAE,SAAS,GAAG,SAAS,GAAG,aAAa,GAAG,SAAS,GAAG,MAAM,GAAG,WAAW,CAAC;CACpF;AAiCD,wBAAgB,WAAW,CAAC,EAAE,MAAM,EAAE,OAAO,EAAE,SAAS,EAAE,GAAG,KAAK,EAAE,EAAE,gBAAgB,+BASrF"}
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
|
2
|
+
import { Badge } from "./badge";
|
|
3
|
+
const statusVariantMap = {
|
|
4
|
+
active: "success",
|
|
5
|
+
enabled: "success",
|
|
6
|
+
valid: "success",
|
|
7
|
+
operational: "success",
|
|
8
|
+
completed: "success",
|
|
9
|
+
approved: "success",
|
|
10
|
+
incoming: "info",
|
|
11
|
+
outgoing: "secondary",
|
|
12
|
+
following: "warning",
|
|
13
|
+
related: "default",
|
|
14
|
+
inactive: "default",
|
|
15
|
+
disabled: "default",
|
|
16
|
+
pending: "warning",
|
|
17
|
+
queued: "warning",
|
|
18
|
+
in_progress: "warning",
|
|
19
|
+
waiting: "warning",
|
|
20
|
+
error: "destructive",
|
|
21
|
+
failed: "destructive",
|
|
22
|
+
invalid: "destructive",
|
|
23
|
+
rejected: "destructive",
|
|
24
|
+
warning: "warning",
|
|
25
|
+
info: "info",
|
|
26
|
+
preview: "info",
|
|
27
|
+
draft: "secondary",
|
|
28
|
+
};
|
|
29
|
+
function normalizeStatus(status) {
|
|
30
|
+
return status.toLowerCase().replace(/\s+/g, "_");
|
|
31
|
+
}
|
|
32
|
+
export function StatusBadge({ status, variant, className, ...props }) {
|
|
33
|
+
const normalized = normalizeStatus(status);
|
|
34
|
+
const resolvedVariant = variant ?? statusVariantMap[normalized] ?? "default";
|
|
35
|
+
return (_jsx(Badge, { variant: resolvedVariant, shape: "pill", className: className, ...props, children: status }));
|
|
36
|
+
}
|
|
37
|
+
//# sourceMappingURL=status-badge.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"status-badge.js","sourceRoot":"","sources":["../../src/components/status-badge.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,KAAK,EAAmB,MAAM,SAAS,CAAC;AAiBjD,MAAM,gBAAgB,GAA6F;IACjH,MAAM,EAAE,SAAS;IACjB,OAAO,EAAE,SAAS;IAClB,KAAK,EAAE,SAAS;IAChB,WAAW,EAAE,SAAS;IACtB,SAAS,EAAE,SAAS;IACpB,QAAQ,EAAE,SAAS;IACnB,QAAQ,EAAE,MAAM;IAChB,QAAQ,EAAE,WAAW;IACrB,SAAS,EAAE,SAAS;IACpB,OAAO,EAAE,SAAS;IAClB,QAAQ,EAAE,SAAS;IACnB,QAAQ,EAAE,SAAS;IACnB,OAAO,EAAE,SAAS;IAClB,MAAM,EAAE,SAAS;IACjB,WAAW,EAAE,SAAS;IACtB,OAAO,EAAE,SAAS;IAClB,KAAK,EAAE,aAAa;IACpB,MAAM,EAAE,aAAa;IACrB,OAAO,EAAE,aAAa;IACtB,QAAQ,EAAE,aAAa;IACvB,OAAO,EAAE,SAAS;IAClB,IAAI,EAAE,MAAM;IACZ,OAAO,EAAE,MAAM;IACf,KAAK,EAAE,WAAW;CACnB,CAAC;AAEF,SAAS,eAAe,CAAC,MAAc;IACrC,OAAO,MAAM,CAAC,WAAW,EAAE,CAAC,OAAO,CAAC,MAAM,EAAE,GAAG,CAAC,CAAC;AACnD,CAAC;AAED,MAAM,UAAU,WAAW,CAAC,EAAE,MAAM,EAAE,OAAO,EAAE,SAAS,EAAE,GAAG,KAAK,EAAoB;IACpF,MAAM,UAAU,GAAG,eAAe,CAAC,MAAM,CAAC,CAAC;IAC3C,MAAM,eAAe,GAAG,OAAO,IAAI,gBAAgB,CAAC,UAAU,CAAC,IAAI,SAAS,CAAC;IAE7E,OAAO,CACL,KAAC,KAAK,IAAC,OAAO,EAAE,eAAe,EAAE,KAAK,EAAC,MAAM,EAAC,SAAS,EAAE,SAAS,KAAM,KAAK,YAC1E,MAAM,GACD,CACT,CAAC;AACJ,CAAC"}
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import { type SwitchProps as MuiSwitchProps } from "@mui/material";
|
|
2
|
+
export interface SwitchProps extends MuiSwitchProps {
|
|
3
|
+
label?: string;
|
|
4
|
+
}
|
|
5
|
+
export declare const Switch: import("react").ForwardRefExoticComponent<Omit<SwitchProps, "ref"> & import("react").RefAttributes<HTMLButtonElement>>;
|
|
6
|
+
//# sourceMappingURL=switch.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"switch.d.ts","sourceRoot":"","sources":["../../src/components/switch.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAyC,KAAK,WAAW,IAAI,cAAc,EAAE,MAAM,eAAe,CAAC;AAG1G,MAAM,WAAW,WAAY,SAAQ,cAAc;IAAG,KAAK,CAAC,EAAE,MAAM,CAAA;CAAE;AAEtE,eAAO,MAAM,MAAM,wHAGjB,CAAC"}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
|
2
|
+
import { FormControlLabel, Switch as MuiSwitch } from "@mui/material";
|
|
3
|
+
import { forwardRef } from "react";
|
|
4
|
+
export const Switch = forwardRef(({ label, ...props }, ref) => {
|
|
5
|
+
const control = _jsx(MuiSwitch, { ref: ref, ...props });
|
|
6
|
+
return label ? _jsx(FormControlLabel, { control: control, label: label }) : control;
|
|
7
|
+
});
|
|
8
|
+
Switch.displayName = "Switch";
|
|
9
|
+
//# sourceMappingURL=switch.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"switch.js","sourceRoot":"","sources":["../../src/components/switch.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,gBAAgB,EAAE,MAAM,IAAI,SAAS,EAAsC,MAAM,eAAe,CAAC;AAC1G,OAAO,EAAE,UAAU,EAAE,MAAM,OAAO,CAAC;AAInC,MAAM,CAAC,MAAM,MAAM,GAAG,UAAU,CAAiC,CAAC,EAAE,KAAK,EAAE,GAAG,KAAK,EAAE,EAAE,GAAG,EAAE,EAAE;IAC5F,MAAM,OAAO,GAAG,KAAC,SAAS,IAAC,GAAG,EAAE,GAAG,KAAM,KAAK,GAAI,CAAC;IACnD,OAAO,KAAK,CAAC,CAAC,CAAC,KAAC,gBAAgB,IAAC,OAAO,EAAE,OAAO,EAAE,KAAK,EAAE,KAAK,GAAI,CAAC,CAAC,CAAC,OAAO,CAAC;AAChF,CAAC,CAAC,CAAC;AACH,MAAM,CAAC,WAAW,GAAG,QAAQ,CAAC"}
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import
|
|
2
|
-
export declare const Table:
|
|
3
|
-
export declare const TableHeader:
|
|
4
|
-
export declare const TableBody:
|
|
5
|
-
export declare const TableRow:
|
|
6
|
-
export declare const TableHead:
|
|
7
|
-
export declare const TableCell:
|
|
1
|
+
import { type TableBodyProps, type TableCellProps, type TableHeadProps, type TableProps, type TableRowProps } from "@mui/material";
|
|
2
|
+
export declare const Table: import("react").ForwardRefExoticComponent<Omit<TableProps, "ref"> & import("react").RefAttributes<HTMLTableElement>>;
|
|
3
|
+
export declare const TableHeader: import("react").ForwardRefExoticComponent<Omit<TableHeadProps, "ref"> & import("react").RefAttributes<HTMLTableSectionElement>>;
|
|
4
|
+
export declare const TableBody: import("react").ForwardRefExoticComponent<Omit<TableBodyProps, "ref"> & import("react").RefAttributes<HTMLTableSectionElement>>;
|
|
5
|
+
export declare const TableRow: import("react").ForwardRefExoticComponent<Omit<TableRowProps, "ref"> & import("react").RefAttributes<HTMLTableRowElement>>;
|
|
6
|
+
export declare const TableHead: import("react").ForwardRefExoticComponent<Omit<TableCellProps, "ref"> & import("react").RefAttributes<HTMLTableCellElement>>;
|
|
7
|
+
export declare const TableCell: import("react").ForwardRefExoticComponent<Omit<TableCellProps, "ref"> & import("react").RefAttributes<HTMLTableCellElement>>;
|
|
8
8
|
//# sourceMappingURL=table.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"table.d.ts","sourceRoot":"","sources":["../../src/components/table.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,
|
|
1
|
+
{"version":3,"file":"table.d.ts","sourceRoot":"","sources":["../../src/components/table.tsx"],"names":[],"mappings":"AAAA,OAAO,EAA+I,KAAK,cAAc,EAAE,KAAK,cAAc,EAAE,KAAK,cAAc,EAAE,KAAK,UAAU,EAAE,KAAK,aAAa,EAAE,MAAM,eAAe,CAAC;AAGhR,eAAO,MAAM,KAAK,sHAIhB,CAAC;AAGH,eAAO,MAAM,WAAW,iIAA6G,CAAC;AAEtI,eAAO,MAAM,SAAS,iIAA6G,CAAC;AAEpI,eAAO,MAAM,QAAQ,4HAAgI,CAAC;AAEtJ,eAAO,MAAM,SAAS,8HAAuP,CAAC;AAE9Q,eAAO,MAAM,SAAS,8HAA0G,CAAC"}
|
package/dist/components/table.js
CHANGED
|
@@ -1,16 +1,16 @@
|
|
|
1
1
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
2
|
-
import
|
|
3
|
-
import {
|
|
4
|
-
export const Table =
|
|
2
|
+
import { Table as MuiTable, TableBody as MuiTableBody, TableCell as MuiTableCell, TableContainer, TableHead as MuiTableHead, TableRow as MuiTableRow } from "@mui/material";
|
|
3
|
+
import { forwardRef } from "react";
|
|
4
|
+
export const Table = forwardRef((props, ref) => (_jsx(TableContainer, { sx: { border: 1, borderColor: "divider", borderRadius: 2 }, children: _jsx(MuiTable, { ref: ref, size: "small", ...props }) })));
|
|
5
5
|
Table.displayName = "Table";
|
|
6
|
-
export const TableHeader =
|
|
6
|
+
export const TableHeader = forwardRef((props, ref) => _jsx(MuiTableHead, { ref: ref, ...props }));
|
|
7
7
|
TableHeader.displayName = "TableHeader";
|
|
8
|
-
export const TableBody =
|
|
8
|
+
export const TableBody = forwardRef((props, ref) => _jsx(MuiTableBody, { ref: ref, ...props }));
|
|
9
9
|
TableBody.displayName = "TableBody";
|
|
10
|
-
export const TableRow =
|
|
10
|
+
export const TableRow = forwardRef(({ sx, ...props }, ref) => _jsx(MuiTableRow, { ref: ref, hover: true, sx: sx, ...props }));
|
|
11
11
|
TableRow.displayName = "TableRow";
|
|
12
|
-
export const TableHead =
|
|
12
|
+
export const TableHead = forwardRef(({ sx, ...props }, ref) => _jsx(MuiTableCell, { ref: ref, sx: { bgcolor: "background.default", color: "text.secondary", fontSize: 12, fontWeight: 700, textTransform: "uppercase", ...sx }, ...props }));
|
|
13
13
|
TableHead.displayName = "TableHead";
|
|
14
|
-
export const TableCell =
|
|
14
|
+
export const TableCell = forwardRef((props, ref) => _jsx(MuiTableCell, { ref: ref, ...props }));
|
|
15
15
|
TableCell.displayName = "TableCell";
|
|
16
16
|
//# sourceMappingURL=table.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"table.js","sourceRoot":"","sources":["../../src/components/table.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,EAAE,GAAG,EAAE,KAAK,QAAC,EAAE,EAAE,EAAE,KAAM,KAAK,GAAI,CAAC,CAAC;AACtJ,QAAQ,CAAC,WAAW,GAAG,UAAU,CAAC;AAClC,MAAM,CAAC,MAAM,SAAS,GAAG,UAAU,CAAuC,CAAC,EAAE,EAAE,EAAE,GAAG,KAAK,EAAE,EAAE,GAAG,EAAE,EAAE,CAAC,KAAC,YAAY,IAAC,GAAG,EAAE,GAAG,EAAE,EAAE,EAAE,EAAE,OAAO,EAAE,oBAAoB,EAAE,KAAK,EAAE,gBAAgB,EAAE,QAAQ,EAAE,EAAE,EAAE,UAAU,EAAE,GAAG,EAAE,aAAa,EAAE,WAAW,EAAE,GAAG,EAAE,EAAE,KAAM,KAAK,GAAI,CAAC,CAAC;AAC9Q,SAAS,CAAC,WAAW,GAAG,WAAW,CAAC;AACpC,MAAM,CAAC,MAAM,SAAS,GAAG,UAAU,CAAuC,CAAC,KAAK,EAAE,GAAG,EAAE,EAAE,CAAC,KAAC,YAAY,IAAC,GAAG,EAAE,GAAG,KAAM,KAAK,GAAI,CAAC,CAAC;AACjI,SAAS,CAAC,WAAW,GAAG,WAAW,CAAC"}
|
package/dist/index.d.ts
CHANGED
package/dist/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,cAAc,cAAc,CAAC"}
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,sBAAsB,CAAC;AAE9B,cAAc,cAAc,CAAC;AAC7B,cAAc,SAAS,CAAC"}
|
package/dist/index.js
CHANGED
package/dist/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,cAAc,cAAc,CAAC"}
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,sBAAsB,CAAC;AAE9B,cAAc,cAAc,CAAC;AAC7B,cAAc,SAAS,CAAC"}
|
package/dist/styles.css
CHANGED
|
@@ -1,123 +1,33 @@
|
|
|
1
|
-
@import "tailwindcss";
|
|
2
|
-
|
|
3
|
-
@source "./**/*.{js,jsx,ts,tsx}";
|
|
4
|
-
|
|
5
|
-
@theme {
|
|
6
|
-
--font-sans: "Be Vietnam Pro", "Inter", system-ui, sans-serif;
|
|
7
|
-
--font-brand: "Myriad Pro", "Be Vietnam Pro", sans-serif;
|
|
8
|
-
|
|
9
|
-
--color-primary: #DA2128;
|
|
10
|
-
--color-primary-hover: #E14E53;
|
|
11
|
-
--color-primary-active: #BE1128;
|
|
12
|
-
--color-primary-foreground: #FFFFFF;
|
|
13
|
-
|
|
14
|
-
--color-secondary: #FAA61A;
|
|
15
|
-
--color-secondary-hover: #FFD080;
|
|
16
|
-
--color-secondary-active: #DC8B05;
|
|
17
|
-
--color-secondary-foreground: #333333;
|
|
18
|
-
|
|
19
|
-
--color-background: #F8FAFC;
|
|
20
|
-
--color-surface: #FFFFFF;
|
|
21
|
-
--color-surface-glass: #FFFFFF66;
|
|
22
|
-
--color-surface-elevated: #FFFFFFCC;
|
|
23
|
-
|
|
24
|
-
--color-border: #D2D6DB;
|
|
25
|
-
--color-border-subtle: #E5E7EB;
|
|
26
|
-
--color-border-glass: #E1E2E4;
|
|
27
|
-
|
|
28
|
-
--color-text-primary: #384250;
|
|
29
|
-
--color-text-secondary: #4D5761;
|
|
30
|
-
--color-text-muted: #9DA4AE;
|
|
31
|
-
--color-text-brand-dark: #333333;
|
|
32
|
-
|
|
33
|
-
--color-success: #6BB892;
|
|
34
|
-
--color-success-strong: #73D13D;
|
|
35
|
-
--color-warning: #F56600;
|
|
36
|
-
--color-error: #DA2128;
|
|
37
|
-
--color-error-soft: #FFF1F0;
|
|
38
|
-
--color-info: #40A9FF;
|
|
39
|
-
--color-purple: #8C68CD;
|
|
40
|
-
--color-brand-grey: #58595B;
|
|
41
|
-
|
|
42
|
-
--spacing-xs: 4px;
|
|
43
|
-
--spacing-sm: 8px;
|
|
44
|
-
--spacing-md: 16px;
|
|
45
|
-
--spacing-lg: 24px;
|
|
46
|
-
--spacing-xl: 32px;
|
|
47
|
-
--spacing-2xl: 48px;
|
|
48
|
-
--spacing-header: 84px;
|
|
49
|
-
--spacing-header-visual: 80px;
|
|
50
|
-
--spacing-brand-rule: 4px;
|
|
51
|
-
--spacing-sidebar: 88px;
|
|
52
|
-
--spacing-sidebar-icon: 56px;
|
|
53
|
-
--spacing-control: 40px;
|
|
54
|
-
--spacing-input: 48px;
|
|
55
|
-
--spacing-app-card: 71px;
|
|
56
|
-
|
|
57
|
-
--radius-sm: 4px;
|
|
58
|
-
--radius-md: 8px;
|
|
59
|
-
--radius-lg: 12px;
|
|
60
|
-
|
|
61
|
-
--shadow-card: 0 1px 2px #2525270F, 0 1px 3px #2525271A;
|
|
62
|
-
--shadow-elevated: 0 4px 6px -2px #2525270D, 0 12px 16px -4px #2525271A;
|
|
63
|
-
--shadow-floating: 0 4px 4px -4px #0C0C0D0D, 0 16px 32px -4px #0C0C0D1A;
|
|
64
|
-
}
|
|
65
|
-
|
|
66
1
|
:root {
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
--primary: 218 33 40;
|
|
74
|
-
--primary-foreground: 255 255 255;
|
|
75
|
-
--secondary: 250 166 26;
|
|
76
|
-
--secondary-foreground: 51 51 51;
|
|
77
|
-
--muted: 229 231 235;
|
|
78
|
-
--muted-foreground: 157 164 174;
|
|
79
|
-
--accent: 250 166 26;
|
|
80
|
-
--accent-foreground: 51 51 51;
|
|
81
|
-
--destructive: 218 33 40;
|
|
82
|
-
--destructive-foreground: 255 255 255;
|
|
83
|
-
--border: 210 214 219;
|
|
84
|
-
--input: 210 214 219;
|
|
85
|
-
--ring: 250 166 26;
|
|
86
|
-
--radius: 8px;
|
|
2
|
+
color-scheme: light;
|
|
3
|
+
font-family: "Be Vietnam Pro", "Inter", "Noto Sans", Arial, sans-serif;
|
|
4
|
+
font-synthesis: none;
|
|
5
|
+
text-rendering: optimizeLegibility;
|
|
6
|
+
-webkit-font-smoothing: antialiased;
|
|
7
|
+
-moz-osx-font-smoothing: grayscale;
|
|
87
8
|
}
|
|
88
9
|
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
background: var(--color-background);
|
|
97
|
-
color: var(--color-text-primary);
|
|
98
|
-
}
|
|
99
|
-
|
|
100
|
-
body {
|
|
101
|
-
min-width: 320px;
|
|
102
|
-
min-height: 100vh;
|
|
103
|
-
margin: 0;
|
|
104
|
-
background: var(--color-background);
|
|
105
|
-
color: var(--color-text-primary);
|
|
106
|
-
letter-spacing: 0;
|
|
107
|
-
text-rendering: optimizeLegibility;
|
|
108
|
-
-webkit-font-smoothing: antialiased;
|
|
109
|
-
-moz-osx-font-smoothing: grayscale;
|
|
110
|
-
}
|
|
10
|
+
html,
|
|
11
|
+
body,
|
|
12
|
+
#root {
|
|
13
|
+
min-width: 320px;
|
|
14
|
+
min-height: 100%;
|
|
15
|
+
margin: 0;
|
|
16
|
+
}
|
|
111
17
|
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
}
|
|
18
|
+
*,
|
|
19
|
+
*::before,
|
|
20
|
+
*::after {
|
|
21
|
+
box-sizing: border-box;
|
|
22
|
+
}
|
|
118
23
|
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
24
|
+
@media (prefers-reduced-motion: reduce) {
|
|
25
|
+
*,
|
|
26
|
+
*::before,
|
|
27
|
+
*::after {
|
|
28
|
+
scroll-behavior: auto !important;
|
|
29
|
+
animation-duration: 0.01ms !important;
|
|
30
|
+
animation-iteration-count: 1 !important;
|
|
31
|
+
transition-duration: 0.01ms !important;
|
|
122
32
|
}
|
|
123
33
|
}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import type { PropsWithChildren } from "react";
|
|
2
|
+
export declare const c360ThemeTokens: {
|
|
3
|
+
readonly headerHeight: 84;
|
|
4
|
+
readonly sidebarWidth: 88;
|
|
5
|
+
readonly primaryGradient: string;
|
|
6
|
+
readonly brandGradient: string;
|
|
7
|
+
};
|
|
8
|
+
export declare const c360Theme: import("@mui/material").Theme;
|
|
9
|
+
export declare function C360ThemeProvider({ children }: PropsWithChildren): import("react").JSX.Element;
|
|
10
|
+
//# sourceMappingURL=c360-theme.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"c360-theme.d.ts","sourceRoot":"","sources":["../../src/theme/c360-theme.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,OAAO,CAAC;AAK/C,eAAO,MAAM,eAAe;;;;;CAKlB,CAAC;AAEX,eAAO,MAAM,SAAS,+BA2EpB,CAAC;AAEH,wBAAgB,iBAAiB,CAAC,EAAE,QAAQ,EAAE,EAAE,iBAAiB,+BAEhE"}
|
|
@@ -0,0 +1,90 @@
|
|
|
1
|
+
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
|
+
import { CssBaseline, ThemeProvider, createTheme } from "@mui/material";
|
|
3
|
+
import colorData from "./colorData";
|
|
4
|
+
const primaryGradient = `linear-gradient(90deg, ${colorData.brandRed} 0%, ${colorData.brandYellow} 100%)`;
|
|
5
|
+
export const c360ThemeTokens = {
|
|
6
|
+
headerHeight: 84,
|
|
7
|
+
sidebarWidth: 88,
|
|
8
|
+
primaryGradient,
|
|
9
|
+
brandGradient: primaryGradient,
|
|
10
|
+
};
|
|
11
|
+
export const c360Theme = createTheme({
|
|
12
|
+
spacing: 4,
|
|
13
|
+
palette: {
|
|
14
|
+
mode: "light",
|
|
15
|
+
primary: { main: colorData.uiPrimary, light: colorData.uiPrimaryHover, dark: colorData.uiPrimaryActive, contrastText: colorData.uiPrimaryForeground, gradient: c360ThemeTokens.primaryGradient },
|
|
16
|
+
secondary: { main: colorData.uiSecondary, light: colorData.uiSecondaryHover, dark: colorData.uiSecondaryActive, contrastText: colorData.uiSecondaryForeground },
|
|
17
|
+
success: { main: colorData.green4, light: colorData.green0, dark: colorData.green5 },
|
|
18
|
+
warning: { main: colorData.orange4, light: colorData.orange0, dark: colorData.orange5 },
|
|
19
|
+
error: { main: colorData.red4, light: colorData.red1, dark: colorData.red5 },
|
|
20
|
+
info: { main: colorData.blue4, light: colorData.blue1, dark: colorData.blue5 },
|
|
21
|
+
background: { default: colorData.neutral0, paper: colorData.surface },
|
|
22
|
+
text: { primary: colorData.textPrimary, secondary: colorData.textSecondary, disabled: colorData.textMuted },
|
|
23
|
+
divider: colorData.borderSubtle,
|
|
24
|
+
brand: { red: colorData.brandRed, yellow: colorData.brandYellow, grey: colorData.brandGrey, gradient: c360ThemeTokens.brandGradient },
|
|
25
|
+
surface: { glass: colorData.surfaceGlass, elevated: colorData.surfaceElevated },
|
|
26
|
+
},
|
|
27
|
+
shape: { borderRadius: 8 },
|
|
28
|
+
typography: {
|
|
29
|
+
fontFamily: '"Be Vietnam Pro", "Inter", "Noto Sans", Arial, sans-serif',
|
|
30
|
+
h1: { fontSize: 32, lineHeight: 1.2, fontWeight: 650 },
|
|
31
|
+
h2: { fontSize: 24, lineHeight: 1.25, fontWeight: 650 },
|
|
32
|
+
h3: { fontSize: 20, lineHeight: 1.3, fontWeight: 650 },
|
|
33
|
+
h4: { fontSize: 24, lineHeight: 1.25, fontWeight: 650 },
|
|
34
|
+
h5: { fontSize: 20, lineHeight: 1.3, fontWeight: 650 },
|
|
35
|
+
h6: { fontSize: 16, lineHeight: 1.35, fontWeight: 650 },
|
|
36
|
+
body1: { fontSize: 16, lineHeight: 1.45 },
|
|
37
|
+
body2: { fontSize: 14, lineHeight: 1.45 },
|
|
38
|
+
caption: { fontSize: 12, lineHeight: 1.4 },
|
|
39
|
+
button: { fontSize: 14, lineHeight: 1.35, fontWeight: 650, textTransform: "none" },
|
|
40
|
+
},
|
|
41
|
+
components: {
|
|
42
|
+
MuiCssBaseline: {
|
|
43
|
+
styleOverrides: {
|
|
44
|
+
body: { minWidth: 320, minHeight: "100vh", backgroundColor: colorData.neutral0 },
|
|
45
|
+
"*:focus-visible": { outline: `2px solid ${colorData.uiSecondary}`, outlineOffset: 2 },
|
|
46
|
+
"@media (prefers-reduced-motion: reduce)": { "*, *::before, *::after": { animationDuration: "0.01ms !important", animationIterationCount: "1 !important", transitionDuration: "0.01ms !important" } },
|
|
47
|
+
},
|
|
48
|
+
},
|
|
49
|
+
MuiButton: {
|
|
50
|
+
defaultProps: { disableElevation: true },
|
|
51
|
+
styleOverrides: {
|
|
52
|
+
root: {
|
|
53
|
+
minHeight: 40,
|
|
54
|
+
borderRadius: 8,
|
|
55
|
+
paddingInline: 16,
|
|
56
|
+
"&.MuiButton-contained.MuiButton-colorPrimary": {
|
|
57
|
+
backgroundColor: colorData.brandRed,
|
|
58
|
+
backgroundImage: c360ThemeTokens.primaryGradient,
|
|
59
|
+
color: colorData.uiPrimaryForeground,
|
|
60
|
+
"&:hover": { backgroundImage: c360ThemeTokens.primaryGradient, filter: "brightness(1.04)" },
|
|
61
|
+
"&:active": { filter: "brightness(0.94)" },
|
|
62
|
+
"&.Mui-disabled": { backgroundImage: "none" },
|
|
63
|
+
},
|
|
64
|
+
},
|
|
65
|
+
sizeLarge: { minHeight: 48 },
|
|
66
|
+
},
|
|
67
|
+
},
|
|
68
|
+
MuiCard: { styleOverrides: { root: { backgroundImage: "none", borderColor: colorData.borderGlass } } },
|
|
69
|
+
MuiPaper: { styleOverrides: { rounded: { borderRadius: 12 } } },
|
|
70
|
+
MuiOutlinedInput: { styleOverrides: { root: { minHeight: 48, borderRadius: 8, backgroundColor: colorData.surface }, notchedOutline: { borderColor: colorData.border } } },
|
|
71
|
+
MuiTableCell: { styleOverrides: { root: { borderColor: colorData.borderSubtle, padding: "12px 16px" } } },
|
|
72
|
+
MuiChip: {
|
|
73
|
+
styleOverrides: {
|
|
74
|
+
root: {
|
|
75
|
+
minHeight: 24,
|
|
76
|
+
fontWeight: 650,
|
|
77
|
+
"&.MuiChip-filled.MuiChip-colorPrimary": {
|
|
78
|
+
backgroundColor: colorData.brandRed,
|
|
79
|
+
backgroundImage: c360ThemeTokens.primaryGradient,
|
|
80
|
+
color: colorData.uiPrimaryForeground,
|
|
81
|
+
},
|
|
82
|
+
},
|
|
83
|
+
},
|
|
84
|
+
},
|
|
85
|
+
},
|
|
86
|
+
});
|
|
87
|
+
export function C360ThemeProvider({ children }) {
|
|
88
|
+
return _jsxs(ThemeProvider, { theme: c360Theme, children: [_jsx(CssBaseline, {}), children] });
|
|
89
|
+
}
|
|
90
|
+
//# sourceMappingURL=c360-theme.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"c360-theme.js","sourceRoot":"","sources":["../../src/theme/c360-theme.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,WAAW,EAAE,aAAa,EAAE,WAAW,EAAE,MAAM,eAAe,CAAC;AAExE,OAAO,SAAS,MAAM,aAAa,CAAC;AAEpC,MAAM,eAAe,GAAG,0BAA0B,SAAS,CAAC,QAAQ,QAAQ,SAAS,CAAC,WAAW,QAAQ,CAAC;AAE1G,MAAM,CAAC,MAAM,eAAe,GAAG;IAC7B,YAAY,EAAE,EAAE;IAChB,YAAY,EAAE,EAAE;IAChB,eAAe;IACf,aAAa,EAAE,eAAe;CACtB,CAAC;AAEX,MAAM,CAAC,MAAM,SAAS,GAAG,WAAW,CAAC;IACnC,OAAO,EAAE,CAAC;IACV,OAAO,EAAE;QACP,IAAI,EAAE,OAAO;QACb,OAAO,EAAE,EAAE,IAAI,EAAE,SAAS,CAAC,SAAS,EAAE,KAAK,EAAE,SAAS,CAAC,cAAc,EAAE,IAAI,EAAE,SAAS,CAAC,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