@sikka/hawa 0.16.3-next → 0.16.5-next
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/index.css +16 -0
- package/dist/index.d.mts +3 -2
- package/dist/index.d.ts +3 -2
- package/dist/index.js +23 -12
- package/dist/index.mjs +27 -19
- package/package.json +1 -1
package/dist/index.css
CHANGED
|
@@ -2552,6 +2552,10 @@ input[type="number"]::-webkit-inner-spin-button,
|
|
|
2552
2552
|
--tw-text-opacity: 1;
|
|
2553
2553
|
color: rgb(34 197 94 / var(--tw-text-opacity));
|
|
2554
2554
|
}
|
|
2555
|
+
.hawa-text-green-600 {
|
|
2556
|
+
--tw-text-opacity: 1;
|
|
2557
|
+
color: rgb(22 163 74 / var(--tw-text-opacity));
|
|
2558
|
+
}
|
|
2555
2559
|
.hawa-text-helper-color {
|
|
2556
2560
|
color: hsl(var(--helper-text));
|
|
2557
2561
|
}
|
|
@@ -2603,6 +2607,10 @@ input[type="number"]::-webkit-inner-spin-button,
|
|
|
2603
2607
|
--tw-text-opacity: 1;
|
|
2604
2608
|
color: rgb(239 68 68 / var(--tw-text-opacity));
|
|
2605
2609
|
}
|
|
2610
|
+
.hawa-text-red-600 {
|
|
2611
|
+
--tw-text-opacity: 1;
|
|
2612
|
+
color: rgb(220 38 38 / var(--tw-text-opacity));
|
|
2613
|
+
}
|
|
2606
2614
|
.hawa-text-secondary-foreground {
|
|
2607
2615
|
color: hsl(var(--secondary-foreground));
|
|
2608
2616
|
}
|
|
@@ -3659,6 +3667,10 @@ body {
|
|
|
3659
3667
|
--tw-text-opacity: 1;
|
|
3660
3668
|
color: rgb(107 114 128 / var(--tw-text-opacity));
|
|
3661
3669
|
}
|
|
3670
|
+
:is(.hawa-dark .dark\:hawa-text-green-500) {
|
|
3671
|
+
--tw-text-opacity: 1;
|
|
3672
|
+
color: rgb(34 197 94 / var(--tw-text-opacity));
|
|
3673
|
+
}
|
|
3662
3674
|
:is(.hawa-dark .dark\:hawa-text-green-800) {
|
|
3663
3675
|
--tw-text-opacity: 1;
|
|
3664
3676
|
color: rgb(22 101 52 / var(--tw-text-opacity));
|
|
@@ -3678,6 +3690,10 @@ body {
|
|
|
3678
3690
|
--tw-text-opacity: 1;
|
|
3679
3691
|
color: rgb(254 226 226 / var(--tw-text-opacity));
|
|
3680
3692
|
}
|
|
3693
|
+
:is(.hawa-dark .dark\:hawa-text-red-500) {
|
|
3694
|
+
--tw-text-opacity: 1;
|
|
3695
|
+
color: rgb(239 68 68 / var(--tw-text-opacity));
|
|
3696
|
+
}
|
|
3681
3697
|
:is(.hawa-dark .dark\:hawa-text-white) {
|
|
3682
3698
|
--tw-text-opacity: 1;
|
|
3683
3699
|
color: rgb(255 255 255 / var(--tw-text-opacity));
|
package/dist/index.d.mts
CHANGED
|
@@ -940,11 +940,12 @@ declare const StopPropagationWrapper: (props: any) => React__default.JSX.Element
|
|
|
940
940
|
|
|
941
941
|
declare const FileUploader: ({ handleFile, className }: any) => React__default.JSX.Element;
|
|
942
942
|
|
|
943
|
-
|
|
943
|
+
interface StatTypes extends React__default.HTMLAttributes<HTMLDivElement> {
|
|
944
944
|
label?: string;
|
|
945
945
|
color?: string;
|
|
946
946
|
number?: string;
|
|
947
947
|
helperText?: string;
|
|
948
|
+
helperTextColor?: "default" | "positive" | "negative" | "muted";
|
|
948
949
|
chart?: any;
|
|
949
950
|
icon?: any;
|
|
950
951
|
variant?: "default" | "plain" | "contained" | "outlined" | "brutalist" | "dropshadow";
|
|
@@ -952,7 +953,7 @@ type StatTypes = {
|
|
|
952
953
|
isLoading?: boolean;
|
|
953
954
|
handleClick?: (e: React__default.MouseEvent) => void;
|
|
954
955
|
className?: string;
|
|
955
|
-
}
|
|
956
|
+
}
|
|
956
957
|
declare const Stats: FC<StatTypes>;
|
|
957
958
|
|
|
958
959
|
type AppLayoutSidebarItemProps = {
|
package/dist/index.d.ts
CHANGED
|
@@ -940,11 +940,12 @@ declare const StopPropagationWrapper: (props: any) => React__default.JSX.Element
|
|
|
940
940
|
|
|
941
941
|
declare const FileUploader: ({ handleFile, className }: any) => React__default.JSX.Element;
|
|
942
942
|
|
|
943
|
-
|
|
943
|
+
interface StatTypes extends React__default.HTMLAttributes<HTMLDivElement> {
|
|
944
944
|
label?: string;
|
|
945
945
|
color?: string;
|
|
946
946
|
number?: string;
|
|
947
947
|
helperText?: string;
|
|
948
|
+
helperTextColor?: "default" | "positive" | "negative" | "muted";
|
|
948
949
|
chart?: any;
|
|
949
950
|
icon?: any;
|
|
950
951
|
variant?: "default" | "plain" | "contained" | "outlined" | "brutalist" | "dropshadow";
|
|
@@ -952,7 +953,7 @@ type StatTypes = {
|
|
|
952
953
|
isLoading?: boolean;
|
|
953
954
|
handleClick?: (e: React__default.MouseEvent) => void;
|
|
954
955
|
className?: string;
|
|
955
|
-
}
|
|
956
|
+
}
|
|
956
957
|
declare const Stats: FC<StatTypes>;
|
|
957
958
|
|
|
958
959
|
type AppLayoutSidebarItemProps = {
|
package/dist/index.js
CHANGED
|
@@ -7057,28 +7057,39 @@ var NavigationMenu = function(props) {
|
|
|
7057
7057
|
// components/layout/Stats.tsx
|
|
7058
7058
|
var import_react36 = __toESM(require("react"));
|
|
7059
7059
|
var Stats = function(_param) {
|
|
7060
|
-
var _param_variant = _param.variant, variant = _param_variant === void 0 ? "default" : _param_variant, props = _object_without_properties(_param, [
|
|
7060
|
+
var label = _param.label, icon = _param.icon, isLoading = _param.isLoading, number = _param.number, helperText = _param.helperText, _param_helperTextColor = _param.helperTextColor, helperTextColor = _param_helperTextColor === void 0 ? "default" : _param_helperTextColor, chart = _param.chart, _param_variant = _param.variant, variant = _param_variant === void 0 ? "default" : _param_variant, props = _object_without_properties(_param, [
|
|
7061
|
+
"label",
|
|
7062
|
+
"icon",
|
|
7063
|
+
"isLoading",
|
|
7064
|
+
"number",
|
|
7065
|
+
"helperText",
|
|
7066
|
+
"helperTextColor",
|
|
7067
|
+
"chart",
|
|
7061
7068
|
"variant"
|
|
7062
7069
|
]);
|
|
7063
|
-
|
|
7064
|
-
|
|
7065
|
-
|
|
7066
|
-
|
|
7067
|
-
|
|
7070
|
+
var helperTextColorStyles = {
|
|
7071
|
+
default: "",
|
|
7072
|
+
positive: "hawa-text-green-600 dark:hawa-text-green-500",
|
|
7073
|
+
negative: "hawa-text-red-600 dark:hawa-text-red-500",
|
|
7074
|
+
muted: "hawa-text-muted-foreground"
|
|
7075
|
+
};
|
|
7076
|
+
return /* @__PURE__ */ import_react36.default.createElement(Card, _object_spread_props(_object_spread({}, props), {
|
|
7077
|
+
clickable: Boolean(props.onClick)
|
|
7078
|
+
}), /* @__PURE__ */ import_react36.default.createElement("div", {
|
|
7068
7079
|
className: "hawa-flex hawa-flex-row hawa-justify-between hawa-p-4 hawa-items-center"
|
|
7069
7080
|
}, /* @__PURE__ */ import_react36.default.createElement(CardTitle, {
|
|
7070
7081
|
className: "hawa-text-sm hawa-font-medium"
|
|
7071
|
-
},
|
|
7082
|
+
}, label), icon && /* @__PURE__ */ import_react36.default.createElement("span", null, icon)), /* @__PURE__ */ import_react36.default.createElement(CardContent, null, isLoading ? /* @__PURE__ */ import_react36.default.createElement(Skeleton, {
|
|
7072
7083
|
className: "hawa-h-8 hawa-w-3/4"
|
|
7073
7084
|
}) : /* @__PURE__ */ import_react36.default.createElement("div", {
|
|
7074
7085
|
className: "hawa-text-2xl hawa-font-bold"
|
|
7075
|
-
},
|
|
7086
|
+
}, number), isLoading && helperText ? /* @__PURE__ */ import_react36.default.createElement(Skeleton, {
|
|
7076
7087
|
className: "hawa-mt-2 hawa-h-4 hawa-w-1/2"
|
|
7077
7088
|
}) : /* @__PURE__ */ import_react36.default.createElement("p", {
|
|
7078
|
-
className: cn("hawa-my-0 hawa-text-xs
|
|
7079
|
-
},
|
|
7089
|
+
className: cn("hawa-my-0 hawa-text-xs hawa-transition-all hawa-text-start", helperTextColorStyles[helperTextColor], helperText ? "hawa-opacity-100 hawa-h-4" : "hawa-opacity-0 hawa-h-0")
|
|
7090
|
+
}, helperText), isLoading && chart ? /* @__PURE__ */ import_react36.default.createElement(Skeleton, {
|
|
7080
7091
|
className: "hawa-mt-2 hawa-h-4 hawa-w-1/2"
|
|
7081
|
-
}) :
|
|
7092
|
+
}) : chart));
|
|
7082
7093
|
};
|
|
7083
7094
|
// components/layout/Sidebar.tsx
|
|
7084
7095
|
var React62 = __toESM(require("react"));
|
|
@@ -7209,7 +7220,7 @@ var SidebarItem = function(_param) {
|
|
|
7209
7220
|
} else {
|
|
7210
7221
|
return /* @__PURE__ */ React62.createElement("div", {
|
|
7211
7222
|
dir: direction,
|
|
7212
|
-
|
|
7223
|
+
onMouseDown: function(e) {
|
|
7213
7224
|
if (item.onClick) {
|
|
7214
7225
|
item.onClick(e);
|
|
7215
7226
|
}
|
package/dist/index.mjs
CHANGED
|
@@ -6864,26 +6864,34 @@ var NavigationMenu = (props) => {
|
|
|
6864
6864
|
|
|
6865
6865
|
// components/layout/Stats.tsx
|
|
6866
6866
|
import React61 from "react";
|
|
6867
|
-
var Stats = ({
|
|
6868
|
-
|
|
6869
|
-
|
|
6867
|
+
var Stats = ({
|
|
6868
|
+
label,
|
|
6869
|
+
icon,
|
|
6870
|
+
isLoading,
|
|
6871
|
+
number,
|
|
6872
|
+
helperText,
|
|
6873
|
+
helperTextColor = "default",
|
|
6874
|
+
chart,
|
|
6875
|
+
variant = "default",
|
|
6876
|
+
...props
|
|
6877
|
+
}) => {
|
|
6878
|
+
let helperTextColorStyles = {
|
|
6879
|
+
default: "",
|
|
6880
|
+
positive: "hawa-text-green-600 dark:hawa-text-green-500",
|
|
6881
|
+
negative: "hawa-text-red-600 dark:hawa-text-red-500",
|
|
6882
|
+
muted: "hawa-text-muted-foreground"
|
|
6883
|
+
};
|
|
6884
|
+
return /* @__PURE__ */ React61.createElement(Card, { ...props, clickable: Boolean(props.onClick) }, /* @__PURE__ */ React61.createElement("div", { className: "hawa-flex hawa-flex-row hawa-justify-between hawa-p-4 hawa-items-center" }, /* @__PURE__ */ React61.createElement(CardTitle, { className: "hawa-text-sm hawa-font-medium" }, label), icon && /* @__PURE__ */ React61.createElement("span", null, icon)), /* @__PURE__ */ React61.createElement(CardContent, null, isLoading ? /* @__PURE__ */ React61.createElement(Skeleton, { className: "hawa-h-8 hawa-w-3/4" }) : /* @__PURE__ */ React61.createElement("div", { className: "hawa-text-2xl hawa-font-bold" }, number), isLoading && helperText ? /* @__PURE__ */ React61.createElement(Skeleton, { className: "hawa-mt-2 hawa-h-4 hawa-w-1/2" }) : /* @__PURE__ */ React61.createElement(
|
|
6885
|
+
"p",
|
|
6870
6886
|
{
|
|
6871
|
-
|
|
6872
|
-
|
|
6873
|
-
|
|
6887
|
+
className: cn(
|
|
6888
|
+
"hawa-my-0 hawa-text-xs hawa-transition-all hawa-text-start",
|
|
6889
|
+
helperTextColorStyles[helperTextColor],
|
|
6890
|
+
helperText ? "hawa-opacity-100 hawa-h-4" : "hawa-opacity-0 hawa-h-0"
|
|
6891
|
+
)
|
|
6874
6892
|
},
|
|
6875
|
-
|
|
6876
|
-
|
|
6877
|
-
"p",
|
|
6878
|
-
{
|
|
6879
|
-
className: cn(
|
|
6880
|
-
"hawa-my-0 hawa-text-xs hawa-text-helper-color hawa-transition-all hawa-text-start",
|
|
6881
|
-
props.helperText ? "hawa-opacity-100 hawa-h-4" : "hawa-opacity-0 hawa-h-0"
|
|
6882
|
-
)
|
|
6883
|
-
},
|
|
6884
|
-
props.helperText
|
|
6885
|
-
), props.isLoading && props.chart ? /* @__PURE__ */ React61.createElement(Skeleton, { className: "hawa-mt-2 hawa-h-4 hawa-w-1/2" }) : props.chart)
|
|
6886
|
-
);
|
|
6893
|
+
helperText
|
|
6894
|
+
), isLoading && chart ? /* @__PURE__ */ React61.createElement(Skeleton, { className: "hawa-mt-2 hawa-h-4 hawa-w-1/2" }) : chart));
|
|
6887
6895
|
};
|
|
6888
6896
|
|
|
6889
6897
|
// components/layout/Sidebar.tsx
|
|
@@ -7052,7 +7060,7 @@ var SidebarItem = ({
|
|
|
7052
7060
|
"div",
|
|
7053
7061
|
{
|
|
7054
7062
|
dir: direction,
|
|
7055
|
-
|
|
7063
|
+
onMouseDown: (e) => {
|
|
7056
7064
|
if (item.onClick) {
|
|
7057
7065
|
item.onClick(e);
|
|
7058
7066
|
}
|