@sikka/hawa 0.26.39-next → 0.27.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/accordion/index.js +1 -1
- package/dist/accordion/index.js.map +1 -1
- package/dist/accordion/index.mjs +1 -1
- package/dist/accordion/index.mjs.map +1 -1
- package/dist/appLayout/index.js +4 -1
- package/dist/appLayout/index.js.map +1 -1
- package/dist/appLayout/index.mjs +4 -1
- package/dist/appLayout/index.mjs.map +1 -1
- package/dist/appTopbar/index.js +4 -1
- package/dist/appTopbar/index.js.map +1 -1
- package/dist/appTopbar/index.mjs +4 -1
- package/dist/appTopbar/index.mjs.map +1 -1
- package/dist/blocks/auth/index.d.mts +13 -1
- package/dist/blocks/auth/index.d.ts +13 -1
- package/dist/blocks/auth/index.js +6 -3
- package/dist/blocks/auth/index.mjs +6 -3
- package/dist/blocks/feedback/index.d.mts +2 -2
- package/dist/blocks/feedback/index.d.ts +2 -2
- package/dist/blocks/index.d.mts +5 -1
- package/dist/blocks/index.d.ts +5 -1
- package/dist/blocks/index.js +11 -4
- package/dist/blocks/index.mjs +9 -5
- package/dist/blocks/misc/index.d.mts +3 -3
- package/dist/blocks/misc/index.d.ts +3 -3
- package/dist/blocks/misc/index.js +1 -0
- package/dist/blocks/misc/index.mjs +1 -0
- package/dist/{chunk-D3KUSRHL.mjs → chunk-3MC4JLSW.mjs} +4 -1
- package/dist/{chunk-AXTPTA3S.mjs → chunk-BOVZAUWD.mjs} +1 -1
- package/dist/{chunk-VCCUBQFI.mjs → chunk-U7BFMH2T.mjs} +1 -1
- package/dist/codeBlock/index.d.mts +12 -2
- package/dist/codeBlock/index.d.ts +12 -2
- package/dist/codeBlock/index.js +72 -44
- package/dist/codeBlock/index.js.map +1 -1
- package/dist/codeBlock/index.mjs +73 -49
- package/dist/codeBlock/index.mjs.map +1 -1
- package/dist/combobox/index.js.map +1 -1
- package/dist/combobox/index.mjs.map +1 -1
- package/dist/command/index.d.mts +24 -37
- package/dist/command/index.d.ts +24 -37
- package/dist/command/index.js +3 -1
- package/dist/command/index.js.map +1 -1
- package/dist/command/index.mjs +3 -1
- package/dist/command/index.mjs.map +1 -1
- package/dist/dataTable/index.js +4 -1
- package/dist/dataTable/index.js.map +1 -1
- package/dist/dataTable/index.mjs +4 -1
- package/dist/dataTable/index.mjs.map +1 -1
- package/dist/dropdownMenu/index.js +4 -1
- package/dist/dropdownMenu/index.js.map +1 -1
- package/dist/dropdownMenu/index.mjs +4 -1
- package/dist/dropdownMenu/index.mjs.map +1 -1
- package/dist/elements/index.d.mts +36 -39
- package/dist/elements/index.d.ts +36 -39
- package/dist/elements/index.js +77 -46
- package/dist/elements/index.mjs +80 -56
- package/dist/index.css +30 -11
- package/dist/index.d.mts +40 -39
- package/dist/index.d.ts +40 -39
- package/dist/index.js +84 -49
- package/dist/index.mjs +123 -92
- package/dist/layout/index.js +4 -1
- package/dist/layout/index.mjs +2 -2
- package/dist/splitButton/index.js +4 -1
- package/dist/splitButton/index.js.map +1 -1
- package/dist/splitButton/index.mjs +4 -1
- package/dist/splitButton/index.mjs.map +1 -1
- package/package.json +8 -8
- package/README.md +0 -91
package/dist/elements/index.js
CHANGED
@@ -790,8 +790,11 @@ var DropdownMenu = ({
|
|
790
790
|
className: cn(
|
791
791
|
className,
|
792
792
|
widthStyles[width],
|
793
|
-
"hawa-flex hawa-flex-col hawa-gap-1"
|
793
|
+
"hawa-flex hawa-flex-col hawa-gap-1 hawa-overflow-y-auto"
|
794
794
|
),
|
795
|
+
style: {
|
796
|
+
maxHeight: "var(--radix-dropdown-menu-content-available-height)"
|
797
|
+
},
|
795
798
|
align,
|
796
799
|
alignOffset
|
797
800
|
},
|
@@ -1068,7 +1071,7 @@ var Accordion = React9.forwardRef(
|
|
1068
1071
|
{
|
1069
1072
|
disabled: item.disabled || false,
|
1070
1073
|
className: cn(
|
1071
|
-
"hawa-transition-all",
|
1074
|
+
"hawa-transition-all hawa-text-start",
|
1072
1075
|
design === "separated" ? "hawa-rounded data-[state=open]:hawa-rounded-b-none" : {
|
1073
1076
|
"hawa-rounded-t": index === 0,
|
1074
1077
|
"data-[state=closed]:hawa-rounded-b": index === items.length - 1
|
@@ -6964,13 +6967,30 @@ function useClipboard({ timeout = 2e3 } = {}) {
|
|
6964
6967
|
// elements/codeBlock/CodeBlock.tsx
|
6965
6968
|
(typeof global !== "undefined" ? global : window).Prism = import_prism_react_renderer.Prism;
|
6966
6969
|
require("prismjs/components/prism-bash");
|
6970
|
+
var CopyIcon = () => /* @__PURE__ */ import_react30.default.createElement(
|
6971
|
+
"svg",
|
6972
|
+
{
|
6973
|
+
"aria-label": "Copy",
|
6974
|
+
stroke: "currentColor",
|
6975
|
+
fill: "none",
|
6976
|
+
strokeWidth: "2",
|
6977
|
+
viewBox: "0 0 24 24",
|
6978
|
+
strokeLinecap: "round",
|
6979
|
+
strokeLinejoin: "round",
|
6980
|
+
height: "1em",
|
6981
|
+
width: "1em"
|
6982
|
+
},
|
6983
|
+
/* @__PURE__ */ import_react30.default.createElement("rect", { width: "14", height: "14", x: "8", y: "8", rx: "2", ry: "2" }),
|
6984
|
+
/* @__PURE__ */ import_react30.default.createElement("path", { d: "M4 16c-1.1 0-2-.9-2-2V4c0-1.1.9-2 2-2h10c1.1 0 2 .9 2 2" })
|
6985
|
+
);
|
6967
6986
|
var CodeBlock = ({
|
6968
6987
|
tabs,
|
6969
6988
|
code,
|
6970
6989
|
fileName,
|
6971
|
-
|
6990
|
+
classNames,
|
6972
6991
|
language = "javascript",
|
6973
6992
|
// default to JavaScript if no language is provided
|
6993
|
+
wrapText = false,
|
6974
6994
|
width = "full",
|
6975
6995
|
...props
|
6976
6996
|
}) => {
|
@@ -6988,16 +7008,50 @@ var CodeBlock = ({
|
|
6988
7008
|
{
|
6989
7009
|
className: cn(
|
6990
7010
|
widthStyles[width],
|
6991
|
-
"hawa-w-full hawa-flex-col hawa-items-center hawa-rounded hawa-bg-background hawa-text-left hawa-my-2 hawa-text-white sm:hawa-text-base",
|
6992
|
-
|
7011
|
+
"hawa-w-full hawa-flex-col hawa-relative hawa-items-center hawa-rounded hawa-bg-background hawa-text-left hawa-my-2 hawa-text-white sm:hawa-text-base",
|
7012
|
+
classNames == null ? void 0 : classNames.root
|
6993
7013
|
)
|
6994
7014
|
},
|
7015
|
+
/* @__PURE__ */ import_react30.default.createElement(
|
7016
|
+
"div",
|
7017
|
+
{
|
7018
|
+
className: cn(
|
7019
|
+
"hawa-flex hawa-absolute hawa-w-fit hawa-flex-row hawa-items-center hawa-gap-2 hawa-z-50 hawa-right-3.5",
|
7020
|
+
{
|
7021
|
+
"hawa-top-3.5": !tabs && !fileName,
|
7022
|
+
"hawa-top-[50px]": tabs && !fileName,
|
7023
|
+
"hawa-top-11": !tabs && fileName,
|
7024
|
+
"hawa-top-[80px]": tabs && fileName
|
7025
|
+
}
|
7026
|
+
)
|
7027
|
+
},
|
7028
|
+
/* @__PURE__ */ import_react30.default.createElement(
|
7029
|
+
Tooltip,
|
7030
|
+
{
|
7031
|
+
open: clipboard.copied,
|
7032
|
+
side: "left",
|
7033
|
+
content: /* @__PURE__ */ import_react30.default.createElement("div", null, "Copied!"),
|
7034
|
+
triggerProps: { asChild: true }
|
7035
|
+
},
|
7036
|
+
/* @__PURE__ */ import_react30.default.createElement(
|
7037
|
+
Button,
|
7038
|
+
{
|
7039
|
+
size: "smallIcon",
|
7040
|
+
onClick: () => clipboard.copy(tabs ? tabs[selectedTab].code : code),
|
7041
|
+
variant: "outline",
|
7042
|
+
className: "hawa-text-gray-200 hawa-opacity-50 "
|
7043
|
+
},
|
7044
|
+
/* @__PURE__ */ import_react30.default.createElement(CopyIcon, null)
|
7045
|
+
)
|
7046
|
+
)
|
7047
|
+
),
|
6995
7048
|
fileName && /* @__PURE__ */ import_react30.default.createElement(
|
6996
7049
|
"div",
|
6997
7050
|
{
|
6998
7051
|
className: cn(
|
6999
7052
|
"hawa-flex hawa-flex-row hawa-gap-2 hawa-rounded-t hawa-p-2 hawa-py-0.5 hawa-pb-0 hawa-font-mono hawa-text-foreground",
|
7000
|
-
fileName && tabs ? "hawa-bg-primary/10" : "hawa-bg-primary/15"
|
7053
|
+
fileName && tabs ? "hawa-bg-primary/10" : "hawa-bg-primary/15",
|
7054
|
+
classNames == null ? void 0 : classNames.fileName
|
7001
7055
|
)
|
7002
7056
|
},
|
7003
7057
|
/* @__PURE__ */ import_react30.default.createElement(
|
@@ -7014,9 +7068,9 @@ var CodeBlock = ({
|
|
7014
7068
|
"div",
|
7015
7069
|
{
|
7016
7070
|
className: cn(
|
7017
|
-
// hawa-bg-gray-300 dark:hawa-bg-red-600
|
7018
7071
|
"hawa-flex hawa-flex-row hawa-gap-2 hawa-rounded-t hawa-p-1 hawa-bg-primary/15 hawa-pb-0 hawa-font-mono hawa-text-foreground",
|
7019
|
-
tabs && fileName && "hawa-rounded-t-none"
|
7072
|
+
tabs && fileName && "hawa-rounded-t-none",
|
7073
|
+
classNames == null ? void 0 : classNames.tabs
|
7020
7074
|
)
|
7021
7075
|
},
|
7022
7076
|
tabs.map((tab, i) => /* @__PURE__ */ import_react30.default.createElement(
|
@@ -7024,7 +7078,8 @@ var CodeBlock = ({
|
|
7024
7078
|
{
|
7025
7079
|
key: i,
|
7026
7080
|
className: cn(
|
7027
|
-
selectedTab === i ? " hawa-border-b-2 hawa-border-primary" : "hawa-bg-transparent"
|
7081
|
+
selectedTab === i ? " hawa-border-b-2 hawa-border-primary" : "hawa-bg-transparent",
|
7082
|
+
classNames == null ? void 0 : classNames.tab
|
7028
7083
|
)
|
7029
7084
|
},
|
7030
7085
|
/* @__PURE__ */ import_react30.default.createElement(
|
@@ -7043,8 +7098,10 @@ var CodeBlock = ({
|
|
7043
7098
|
"div",
|
7044
7099
|
{
|
7045
7100
|
className: cn(
|
7046
|
-
"hawa-flex hawa-w-full hawa-flex-row hawa-items-start hawa-justify-between hawa-border hawa-bg-gray-800 hawa-p-0 hawa-text-left hawa-text-sm sm:hawa-text-base
|
7047
|
-
tabs || fileName ? "hawa-rounded-b hawa-rounded-t-none" : "hawa-rounded"
|
7101
|
+
"hawa-flex hawa-w-full hawa-relative hawa-flex-row hawa-items-start hawa-justify-between hawa-border hawa-bg-gray-800 hawa-p-0 hawa-text-left hawa-text-sm sm:hawa-text-base",
|
7102
|
+
tabs || fileName ? "hawa-rounded-b hawa-rounded-t-none" : "hawa-rounded",
|
7103
|
+
classNames == null ? void 0 : classNames.codeBlockContainer,
|
7104
|
+
"hawa-overflow-y-auto"
|
7048
7105
|
)
|
7049
7106
|
},
|
7050
7107
|
/* @__PURE__ */ import_react30.default.createElement(
|
@@ -7054,44 +7111,18 @@ var CodeBlock = ({
|
|
7054
7111
|
code: tabs ? tabs[selectedTab].code : code || "",
|
7055
7112
|
language
|
7056
7113
|
},
|
7057
|
-
({
|
7058
|
-
|
7059
|
-
/* @__PURE__ */ import_react30.default.createElement("div", { className: "hawa-flex hawa-w-fit hawa-flex-row hawa-items-center hawa-gap-2 hawa-p-2" }, /* @__PURE__ */ import_react30.default.createElement(
|
7060
|
-
Tooltip,
|
7061
|
-
{
|
7062
|
-
open: clipboard.copied,
|
7063
|
-
side: "left",
|
7064
|
-
content: /* @__PURE__ */ import_react30.default.createElement("div", null, "Copied!"),
|
7065
|
-
triggerProps: {
|
7066
|
-
asChild: true
|
7067
|
-
}
|
7068
|
-
},
|
7069
|
-
/* @__PURE__ */ import_react30.default.createElement(
|
7070
|
-
Button,
|
7114
|
+
({ tokens, getLineProps, getTokenProps }) => /* @__PURE__ */ import_react30.default.createElement(
|
7115
|
+
"pre",
|
7071
7116
|
{
|
7072
|
-
|
7073
|
-
|
7074
|
-
|
7075
|
-
|
7117
|
+
className: cn(
|
7118
|
+
"hawa-min-h-[37.75px] !hawa-pe-12 hawa-w-full hawa-p-4 hawa-font-mono hawa-text-foreground",
|
7119
|
+
classNames == null ? void 0 : classNames.code,
|
7120
|
+
wrapText && "hawa-text-wrap"
|
7121
|
+
)
|
7076
7122
|
},
|
7077
|
-
/* @__PURE__ */ import_react30.default.createElement(
|
7078
|
-
"svg",
|
7079
|
-
{
|
7080
|
-
"aria-label": "Copy",
|
7081
|
-
stroke: "currentColor",
|
7082
|
-
fill: "none",
|
7083
|
-
strokeWidth: "2",
|
7084
|
-
viewBox: "0 0 24 24",
|
7085
|
-
strokeLinecap: "round",
|
7086
|
-
strokeLinejoin: "round",
|
7087
|
-
height: "1em",
|
7088
|
-
width: "1em"
|
7089
|
-
},
|
7090
|
-
/* @__PURE__ */ import_react30.default.createElement("rect", { width: "14", height: "14", x: "8", y: "8", rx: "2", ry: "2" }),
|
7091
|
-
/* @__PURE__ */ import_react30.default.createElement("path", { d: "M4 16c-1.1 0-2-.9-2-2V4c0-1.1.9-2 2-2h10c1.1 0 2 .9 2 2" })
|
7092
|
-
)
|
7123
|
+
tokens.map((line, i) => /* @__PURE__ */ import_react30.default.createElement("div", { key: i, ...getLineProps({ line }) }, props.lineNumbers && /* @__PURE__ */ import_react30.default.createElement("span", { className: "hawa-mr-4" }, i + 1), line.map((token, key) => /* @__PURE__ */ import_react30.default.createElement("span", { key, ...getTokenProps({ token }) }))))
|
7093
7124
|
)
|
7094
|
-
)
|
7125
|
+
)
|
7095
7126
|
)
|
7096
7127
|
);
|
7097
7128
|
};
|
package/dist/elements/index.mjs
CHANGED
@@ -27,7 +27,7 @@ import {
|
|
27
27
|
TabsTrigger,
|
28
28
|
Textarea,
|
29
29
|
UncheckMark
|
30
|
-
} from "../chunk-
|
30
|
+
} from "../chunk-U7BFMH2T.mjs";
|
31
31
|
import {
|
32
32
|
Sheet,
|
33
33
|
SheetClose,
|
@@ -39,7 +39,7 @@ import {
|
|
39
39
|
SheetPortal,
|
40
40
|
SheetTitle,
|
41
41
|
SheetTrigger
|
42
|
-
} from "../chunk-
|
42
|
+
} from "../chunk-BOVZAUWD.mjs";
|
43
43
|
import {
|
44
44
|
Button,
|
45
45
|
Card,
|
@@ -73,7 +73,7 @@ import {
|
|
73
73
|
buttonVariants,
|
74
74
|
calculateLuminance,
|
75
75
|
cn
|
76
|
-
} from "../chunk-
|
76
|
+
} from "../chunk-3MC4JLSW.mjs";
|
77
77
|
import {
|
78
78
|
__require
|
79
79
|
} from "../chunk-ZFXKCRJC.mjs";
|
@@ -164,7 +164,7 @@ var Accordion = React3.forwardRef(
|
|
164
164
|
{
|
165
165
|
disabled: item.disabled || false,
|
166
166
|
className: cn(
|
167
|
-
"hawa-transition-all",
|
167
|
+
"hawa-transition-all hawa-text-start",
|
168
168
|
design === "separated" ? "hawa-rounded data-[state=open]:hawa-rounded-b-none" : {
|
169
169
|
"hawa-rounded-t": index === 0,
|
170
170
|
"data-[state=closed]:hawa-rounded-b": index === items.length - 1
|
@@ -2640,20 +2640,33 @@ var ScrollIndicator = ({
|
|
2640
2640
|
|
2641
2641
|
// elements/codeBlock/CodeBlock.tsx
|
2642
2642
|
import React27, { useState as useState11 } from "react";
|
2643
|
-
import {
|
2644
|
-
Highlight,
|
2645
|
-
themes,
|
2646
|
-
Prism
|
2647
|
-
} from "prism-react-renderer";
|
2643
|
+
import { Highlight, themes, Prism } from "prism-react-renderer";
|
2648
2644
|
(typeof global !== "undefined" ? global : window).Prism = Prism;
|
2649
2645
|
__require("prismjs/components/prism-bash");
|
2646
|
+
var CopyIcon = () => /* @__PURE__ */ React27.createElement(
|
2647
|
+
"svg",
|
2648
|
+
{
|
2649
|
+
"aria-label": "Copy",
|
2650
|
+
stroke: "currentColor",
|
2651
|
+
fill: "none",
|
2652
|
+
strokeWidth: "2",
|
2653
|
+
viewBox: "0 0 24 24",
|
2654
|
+
strokeLinecap: "round",
|
2655
|
+
strokeLinejoin: "round",
|
2656
|
+
height: "1em",
|
2657
|
+
width: "1em"
|
2658
|
+
},
|
2659
|
+
/* @__PURE__ */ React27.createElement("rect", { width: "14", height: "14", x: "8", y: "8", rx: "2", ry: "2" }),
|
2660
|
+
/* @__PURE__ */ React27.createElement("path", { d: "M4 16c-1.1 0-2-.9-2-2V4c0-1.1.9-2 2-2h10c1.1 0 2 .9 2 2" })
|
2661
|
+
);
|
2650
2662
|
var CodeBlock = ({
|
2651
2663
|
tabs,
|
2652
2664
|
code,
|
2653
2665
|
fileName,
|
2654
|
-
|
2666
|
+
classNames,
|
2655
2667
|
language = "javascript",
|
2656
2668
|
// default to JavaScript if no language is provided
|
2669
|
+
wrapText = false,
|
2657
2670
|
width = "full",
|
2658
2671
|
...props
|
2659
2672
|
}) => {
|
@@ -2671,16 +2684,50 @@ var CodeBlock = ({
|
|
2671
2684
|
{
|
2672
2685
|
className: cn(
|
2673
2686
|
widthStyles[width],
|
2674
|
-
"hawa-w-full hawa-flex-col hawa-items-center hawa-rounded hawa-bg-background hawa-text-left hawa-my-2 hawa-text-white sm:hawa-text-base",
|
2675
|
-
|
2687
|
+
"hawa-w-full hawa-flex-col hawa-relative hawa-items-center hawa-rounded hawa-bg-background hawa-text-left hawa-my-2 hawa-text-white sm:hawa-text-base",
|
2688
|
+
classNames == null ? void 0 : classNames.root
|
2676
2689
|
)
|
2677
2690
|
},
|
2691
|
+
/* @__PURE__ */ React27.createElement(
|
2692
|
+
"div",
|
2693
|
+
{
|
2694
|
+
className: cn(
|
2695
|
+
"hawa-flex hawa-absolute hawa-w-fit hawa-flex-row hawa-items-center hawa-gap-2 hawa-z-50 hawa-right-3.5",
|
2696
|
+
{
|
2697
|
+
"hawa-top-3.5": !tabs && !fileName,
|
2698
|
+
"hawa-top-[50px]": tabs && !fileName,
|
2699
|
+
"hawa-top-11": !tabs && fileName,
|
2700
|
+
"hawa-top-[80px]": tabs && fileName
|
2701
|
+
}
|
2702
|
+
)
|
2703
|
+
},
|
2704
|
+
/* @__PURE__ */ React27.createElement(
|
2705
|
+
Tooltip,
|
2706
|
+
{
|
2707
|
+
open: clipboard.copied,
|
2708
|
+
side: "left",
|
2709
|
+
content: /* @__PURE__ */ React27.createElement("div", null, "Copied!"),
|
2710
|
+
triggerProps: { asChild: true }
|
2711
|
+
},
|
2712
|
+
/* @__PURE__ */ React27.createElement(
|
2713
|
+
Button,
|
2714
|
+
{
|
2715
|
+
size: "smallIcon",
|
2716
|
+
onClick: () => clipboard.copy(tabs ? tabs[selectedTab].code : code),
|
2717
|
+
variant: "outline",
|
2718
|
+
className: "hawa-text-gray-200 hawa-opacity-50 "
|
2719
|
+
},
|
2720
|
+
/* @__PURE__ */ React27.createElement(CopyIcon, null)
|
2721
|
+
)
|
2722
|
+
)
|
2723
|
+
),
|
2678
2724
|
fileName && /* @__PURE__ */ React27.createElement(
|
2679
2725
|
"div",
|
2680
2726
|
{
|
2681
2727
|
className: cn(
|
2682
2728
|
"hawa-flex hawa-flex-row hawa-gap-2 hawa-rounded-t hawa-p-2 hawa-py-0.5 hawa-pb-0 hawa-font-mono hawa-text-foreground",
|
2683
|
-
fileName && tabs ? "hawa-bg-primary/10" : "hawa-bg-primary/15"
|
2729
|
+
fileName && tabs ? "hawa-bg-primary/10" : "hawa-bg-primary/15",
|
2730
|
+
classNames == null ? void 0 : classNames.fileName
|
2684
2731
|
)
|
2685
2732
|
},
|
2686
2733
|
/* @__PURE__ */ React27.createElement(
|
@@ -2697,9 +2744,9 @@ var CodeBlock = ({
|
|
2697
2744
|
"div",
|
2698
2745
|
{
|
2699
2746
|
className: cn(
|
2700
|
-
// hawa-bg-gray-300 dark:hawa-bg-red-600
|
2701
2747
|
"hawa-flex hawa-flex-row hawa-gap-2 hawa-rounded-t hawa-p-1 hawa-bg-primary/15 hawa-pb-0 hawa-font-mono hawa-text-foreground",
|
2702
|
-
tabs && fileName && "hawa-rounded-t-none"
|
2748
|
+
tabs && fileName && "hawa-rounded-t-none",
|
2749
|
+
classNames == null ? void 0 : classNames.tabs
|
2703
2750
|
)
|
2704
2751
|
},
|
2705
2752
|
tabs.map((tab, i) => /* @__PURE__ */ React27.createElement(
|
@@ -2707,7 +2754,8 @@ var CodeBlock = ({
|
|
2707
2754
|
{
|
2708
2755
|
key: i,
|
2709
2756
|
className: cn(
|
2710
|
-
selectedTab === i ? " hawa-border-b-2 hawa-border-primary" : "hawa-bg-transparent"
|
2757
|
+
selectedTab === i ? " hawa-border-b-2 hawa-border-primary" : "hawa-bg-transparent",
|
2758
|
+
classNames == null ? void 0 : classNames.tab
|
2711
2759
|
)
|
2712
2760
|
},
|
2713
2761
|
/* @__PURE__ */ React27.createElement(
|
@@ -2726,8 +2774,10 @@ var CodeBlock = ({
|
|
2726
2774
|
"div",
|
2727
2775
|
{
|
2728
2776
|
className: cn(
|
2729
|
-
"hawa-flex hawa-w-full hawa-flex-row hawa-items-start hawa-justify-between hawa-border hawa-bg-gray-800 hawa-p-0 hawa-text-left hawa-text-sm sm:hawa-text-base
|
2730
|
-
tabs || fileName ? "hawa-rounded-b hawa-rounded-t-none" : "hawa-rounded"
|
2777
|
+
"hawa-flex hawa-w-full hawa-relative hawa-flex-row hawa-items-start hawa-justify-between hawa-border hawa-bg-gray-800 hawa-p-0 hawa-text-left hawa-text-sm sm:hawa-text-base",
|
2778
|
+
tabs || fileName ? "hawa-rounded-b hawa-rounded-t-none" : "hawa-rounded",
|
2779
|
+
classNames == null ? void 0 : classNames.codeBlockContainer,
|
2780
|
+
"hawa-overflow-y-auto"
|
2731
2781
|
)
|
2732
2782
|
},
|
2733
2783
|
/* @__PURE__ */ React27.createElement(
|
@@ -2737,50 +2787,24 @@ var CodeBlock = ({
|
|
2737
2787
|
code: tabs ? tabs[selectedTab].code : code || "",
|
2738
2788
|
language
|
2739
2789
|
},
|
2740
|
-
({
|
2741
|
-
|
2742
|
-
/* @__PURE__ */ React27.createElement("div", { className: "hawa-flex hawa-w-fit hawa-flex-row hawa-items-center hawa-gap-2 hawa-p-2" }, /* @__PURE__ */ React27.createElement(
|
2743
|
-
Tooltip,
|
2744
|
-
{
|
2745
|
-
open: clipboard.copied,
|
2746
|
-
side: "left",
|
2747
|
-
content: /* @__PURE__ */ React27.createElement("div", null, "Copied!"),
|
2748
|
-
triggerProps: {
|
2749
|
-
asChild: true
|
2750
|
-
}
|
2751
|
-
},
|
2752
|
-
/* @__PURE__ */ React27.createElement(
|
2753
|
-
Button,
|
2790
|
+
({ tokens, getLineProps, getTokenProps }) => /* @__PURE__ */ React27.createElement(
|
2791
|
+
"pre",
|
2754
2792
|
{
|
2755
|
-
|
2756
|
-
|
2757
|
-
|
2758
|
-
|
2793
|
+
className: cn(
|
2794
|
+
"hawa-min-h-[37.75px] !hawa-pe-12 hawa-w-full hawa-p-4 hawa-font-mono hawa-text-foreground",
|
2795
|
+
classNames == null ? void 0 : classNames.code,
|
2796
|
+
wrapText && "hawa-text-wrap"
|
2797
|
+
)
|
2759
2798
|
},
|
2760
|
-
/* @__PURE__ */ React27.createElement(
|
2761
|
-
"svg",
|
2762
|
-
{
|
2763
|
-
"aria-label": "Copy",
|
2764
|
-
stroke: "currentColor",
|
2765
|
-
fill: "none",
|
2766
|
-
strokeWidth: "2",
|
2767
|
-
viewBox: "0 0 24 24",
|
2768
|
-
strokeLinecap: "round",
|
2769
|
-
strokeLinejoin: "round",
|
2770
|
-
height: "1em",
|
2771
|
-
width: "1em"
|
2772
|
-
},
|
2773
|
-
/* @__PURE__ */ React27.createElement("rect", { width: "14", height: "14", x: "8", y: "8", rx: "2", ry: "2" }),
|
2774
|
-
/* @__PURE__ */ React27.createElement("path", { d: "M4 16c-1.1 0-2-.9-2-2V4c0-1.1.9-2 2-2h10c1.1 0 2 .9 2 2" })
|
2775
|
-
)
|
2799
|
+
tokens.map((line, i) => /* @__PURE__ */ React27.createElement("div", { key: i, ...getLineProps({ line }) }, props.lineNumbers && /* @__PURE__ */ React27.createElement("span", { className: "hawa-mr-4" }, i + 1), line.map((token, key) => /* @__PURE__ */ React27.createElement("span", { key, ...getTokenProps({ token }) }))))
|
2776
2800
|
)
|
2777
|
-
)
|
2801
|
+
)
|
2778
2802
|
)
|
2779
2803
|
);
|
2780
2804
|
};
|
2781
2805
|
|
2782
2806
|
// elements/carousel/Carousel.tsx
|
2783
|
-
import React28, { useEffect as
|
2807
|
+
import React28, { useEffect as useEffect9, useState as useState12 } from "react";
|
2784
2808
|
import useEmblaCarousel from "embla-carousel-react";
|
2785
2809
|
var Carousel = ({
|
2786
2810
|
items,
|
@@ -2797,7 +2821,7 @@ var Carousel = ({
|
|
2797
2821
|
loop: autoplay ? true : (options == null ? void 0 : options.loop) || false
|
2798
2822
|
});
|
2799
2823
|
const [selectedIndex, setSelectedIndex] = useState12(0);
|
2800
|
-
|
2824
|
+
useEffect9(() => {
|
2801
2825
|
function selectHandler() {
|
2802
2826
|
const index = emblaApi == null ? void 0 : emblaApi.selectedScrollSnap();
|
2803
2827
|
setSelectedIndex(index || 0);
|
@@ -2807,7 +2831,7 @@ var Carousel = ({
|
|
2807
2831
|
emblaApi == null ? void 0 : emblaApi.off("select", selectHandler);
|
2808
2832
|
};
|
2809
2833
|
}, [emblaApi]);
|
2810
|
-
|
2834
|
+
useEffect9(() => {
|
2811
2835
|
let autoplayTimer;
|
2812
2836
|
if (autoplay && emblaApi) {
|
2813
2837
|
autoplayTimer = setInterval(() => {
|
package/dist/index.css
CHANGED
@@ -1028,6 +1028,12 @@ input[type="number"]::-webkit-inner-spin-button,
|
|
1028
1028
|
.hawa-right-2\.5 {
|
1029
1029
|
right: 0.625rem;
|
1030
1030
|
}
|
1031
|
+
.hawa-right-3 {
|
1032
|
+
right: 0.75rem;
|
1033
|
+
}
|
1034
|
+
.hawa-right-3\.5 {
|
1035
|
+
right: 0.875rem;
|
1036
|
+
}
|
1031
1037
|
.hawa-right-4 {
|
1032
1038
|
right: 1rem;
|
1033
1039
|
}
|
@@ -1046,6 +1052,9 @@ input[type="number"]::-webkit-inner-spin-button,
|
|
1046
1052
|
.hawa-top-1\/2 {
|
1047
1053
|
top: 50%;
|
1048
1054
|
}
|
1055
|
+
.hawa-top-11 {
|
1056
|
+
top: 2.75rem;
|
1057
|
+
}
|
1049
1058
|
.hawa-top-14 {
|
1050
1059
|
top: 3.5rem;
|
1051
1060
|
}
|
@@ -1055,6 +1064,12 @@ input[type="number"]::-webkit-inner-spin-button,
|
|
1055
1064
|
.hawa-top-2\.5 {
|
1056
1065
|
top: 0.625rem;
|
1057
1066
|
}
|
1067
|
+
.hawa-top-3 {
|
1068
|
+
top: 0.75rem;
|
1069
|
+
}
|
1070
|
+
.hawa-top-3\.5 {
|
1071
|
+
top: 0.875rem;
|
1072
|
+
}
|
1058
1073
|
.hawa-top-4 {
|
1059
1074
|
top: 1rem;
|
1060
1075
|
}
|
@@ -1070,6 +1085,9 @@ input[type="number"]::-webkit-inner-spin-button,
|
|
1070
1085
|
.hawa-top-\[50\%\] {
|
1071
1086
|
top: 50%;
|
1072
1087
|
}
|
1088
|
+
.hawa-top-\[50px\] {
|
1089
|
+
top: 50px;
|
1090
|
+
}
|
1073
1091
|
.hawa-top-\[60\%\] {
|
1074
1092
|
top: 60%;
|
1075
1093
|
}
|
@@ -1082,6 +1100,9 @@ input[type="number"]::-webkit-inner-spin-button,
|
|
1082
1100
|
.hawa-top-\[72px\] {
|
1083
1101
|
top: 72px;
|
1084
1102
|
}
|
1103
|
+
.hawa-top-\[80px\] {
|
1104
|
+
top: 80px;
|
1105
|
+
}
|
1085
1106
|
.hawa-top-full {
|
1086
1107
|
top: 100%;
|
1087
1108
|
}
|
@@ -1439,6 +1460,9 @@ input[type="number"]::-webkit-inner-spin-button,
|
|
1439
1460
|
.hawa-max-h-screen {
|
1440
1461
|
max-height: 100vh;
|
1441
1462
|
}
|
1463
|
+
.hawa-min-h-20 {
|
1464
|
+
min-height: 5rem;
|
1465
|
+
}
|
1442
1466
|
.hawa-min-h-\[25px\] {
|
1443
1467
|
min-height: 25px;
|
1444
1468
|
}
|
@@ -1936,6 +1960,9 @@ input[type="number"]::-webkit-inner-spin-button,
|
|
1936
1960
|
.hawa-whitespace-nowrap {
|
1937
1961
|
white-space: nowrap;
|
1938
1962
|
}
|
1963
|
+
.hawa-text-wrap {
|
1964
|
+
text-wrap: wrap;
|
1965
|
+
}
|
1939
1966
|
.hawa-rounded {
|
1940
1967
|
border-radius: var(--radius);
|
1941
1968
|
}
|
@@ -2106,9 +2133,6 @@ input[type="number"]::-webkit-inner-spin-button,
|
|
2106
2133
|
.hawa-bg-background {
|
2107
2134
|
background-color: hsl(var(--background));
|
2108
2135
|
}
|
2109
|
-
.hawa-bg-background\/70 {
|
2110
|
-
background-color: hsl(var(--background) / 0.7);
|
2111
|
-
}
|
2112
2136
|
.hawa-bg-background\/80 {
|
2113
2137
|
background-color: hsl(var(--background) / 0.8);
|
2114
2138
|
}
|
@@ -2156,10 +2180,6 @@ input[type="number"]::-webkit-inner-spin-button,
|
|
2156
2180
|
--tw-bg-opacity: 1;
|
2157
2181
|
background-color: rgb(229 231 235 / var(--tw-bg-opacity));
|
2158
2182
|
}
|
2159
|
-
.hawa-bg-gray-300 {
|
2160
|
-
--tw-bg-opacity: 1;
|
2161
|
-
background-color: rgb(209 213 219 / var(--tw-bg-opacity));
|
2162
|
-
}
|
2163
2183
|
.hawa-bg-gray-400 {
|
2164
2184
|
--tw-bg-opacity: 1;
|
2165
2185
|
background-color: rgb(156 163 175 / var(--tw-bg-opacity));
|
@@ -2492,6 +2512,9 @@ input[type="number"]::-webkit-inner-spin-button,
|
|
2492
2512
|
padding-top: 1.5rem;
|
2493
2513
|
padding-bottom: 1.5rem;
|
2494
2514
|
}
|
2515
|
+
.\!hawa-pe-12 {
|
2516
|
+
padding-inline-end: 3rem !important;
|
2517
|
+
}
|
2495
2518
|
.hawa-pb-0 {
|
2496
2519
|
padding-bottom: 0px;
|
2497
2520
|
}
|
@@ -3824,10 +3847,6 @@ body {
|
|
3824
3847
|
--tw-bg-opacity: 1;
|
3825
3848
|
background-color: rgb(248 113 113 / var(--tw-bg-opacity));
|
3826
3849
|
}
|
3827
|
-
:is(.hawa-dark .dark\:hawa-bg-red-600) {
|
3828
|
-
--tw-bg-opacity: 1;
|
3829
|
-
background-color: rgb(220 38 38 / var(--tw-bg-opacity));
|
3830
|
-
}
|
3831
3850
|
:is(.hawa-dark .dark\:hawa-bg-white) {
|
3832
3851
|
--tw-bg-opacity: 1;
|
3833
3852
|
background-color: rgb(255 255 255 / var(--tw-bg-opacity));
|
package/dist/index.d.mts
CHANGED
@@ -11,6 +11,7 @@ import { VariantProps } from 'class-variance-authority';
|
|
11
11
|
import { RowData, ColumnDef } from '@tanstack/react-table';
|
12
12
|
export { ColumnDef } from '@tanstack/react-table';
|
13
13
|
import * as TabsPrimitive from '@radix-ui/react-tabs';
|
14
|
+
import { Command as Command$1 } from 'cmdk';
|
14
15
|
import * as PopoverPrimitive from '@radix-ui/react-popover';
|
15
16
|
import * as SwitchPrimitives from '@radix-ui/react-switch';
|
16
17
|
import * as CheckboxPrimitive from '@radix-ui/react-checkbox';
|
@@ -673,47 +674,33 @@ declare const Input: React__default.ForwardRefExoticComponent<React__default.Inp
|
|
673
674
|
popupContent?: React__default.ReactNode;
|
674
675
|
} & React__default.RefAttributes<HTMLInputElement>>;
|
675
676
|
|
676
|
-
|
677
|
-
children?: React$1.ReactNode;
|
678
|
-
} & React$1.HTMLAttributes<HTMLDivElement> & {
|
679
|
-
label?: string | undefined;
|
680
|
-
shouldFilter?: boolean | undefined;
|
681
|
-
filter?: ((value: string, search: string) => number) | undefined;
|
682
|
-
value?: string | undefined;
|
683
|
-
onValueChange?: ((value: string) => void) | undefined;
|
684
|
-
loop?: boolean | undefined;
|
685
|
-
} & React$1.RefAttributes<HTMLDivElement>, "ref"> & React$1.RefAttributes<HTMLDivElement>>;
|
677
|
+
type CommandProps = React$1.ComponentPropsWithoutRef<typeof Command$1>;
|
686
678
|
interface CommandDialogProps extends DialogProps {
|
687
679
|
}
|
680
|
+
interface CommandInputProps extends React$1.ComponentPropsWithoutRef<typeof Command$1.Input> {
|
681
|
+
}
|
682
|
+
interface CommandListProps extends React$1.ComponentPropsWithoutRef<typeof Command$1.List> {
|
683
|
+
}
|
684
|
+
interface CommandEmptyProps extends React$1.ComponentPropsWithoutRef<typeof Command$1.Empty> {
|
685
|
+
}
|
686
|
+
interface CommandGroupProps extends React$1.ComponentPropsWithoutRef<typeof Command$1.Group> {
|
687
|
+
}
|
688
|
+
interface CommandSeparatorProps extends React$1.ComponentPropsWithoutRef<typeof Command$1.Separator> {
|
689
|
+
}
|
690
|
+
interface CommandItemProps extends React$1.ComponentPropsWithoutRef<typeof Command$1.Item> {
|
691
|
+
}
|
692
|
+
interface CommandShortcutProps extends React$1.HTMLAttributes<HTMLSpanElement> {
|
693
|
+
}
|
694
|
+
declare const Command: React$1.ForwardRefExoticComponent<CommandProps & React$1.RefAttributes<React$1.ElementRef<typeof Command$1>>>;
|
688
695
|
declare const CommandDialog: ({ children, ...props }: CommandDialogProps) => React$1.JSX.Element;
|
689
|
-
declare const CommandInput: React$1.ForwardRefExoticComponent<
|
690
|
-
|
691
|
-
|
692
|
-
|
693
|
-
declare const
|
694
|
-
|
695
|
-
} & React$1.HTMLAttributes<HTMLDivElement> & React$1.RefAttributes<HTMLDivElement>, "ref"> & React$1.RefAttributes<HTMLDivElement>>;
|
696
|
-
declare const CommandEmpty: React$1.ForwardRefExoticComponent<Omit<{
|
697
|
-
children?: React$1.ReactNode;
|
698
|
-
} & React$1.HTMLAttributes<HTMLDivElement> & React$1.RefAttributes<HTMLDivElement>, "ref"> & React$1.RefAttributes<HTMLDivElement>>;
|
699
|
-
declare const CommandGroup: React$1.ForwardRefExoticComponent<Omit<{
|
700
|
-
children?: React$1.ReactNode;
|
701
|
-
} & Omit<React$1.HTMLAttributes<HTMLDivElement>, "heading" | "value"> & {
|
702
|
-
heading?: React$1.ReactNode;
|
703
|
-
value?: string | undefined;
|
704
|
-
} & React$1.RefAttributes<HTMLDivElement>, "ref"> & React$1.RefAttributes<HTMLDivElement>>;
|
705
|
-
declare const CommandSeparator: React$1.ForwardRefExoticComponent<Omit<React$1.HTMLAttributes<HTMLDivElement> & {
|
706
|
-
alwaysRender?: boolean | undefined;
|
707
|
-
} & React$1.RefAttributes<HTMLDivElement>, "ref"> & React$1.RefAttributes<HTMLDivElement>>;
|
708
|
-
declare const CommandItem: React$1.ForwardRefExoticComponent<Omit<{
|
709
|
-
children?: React$1.ReactNode;
|
710
|
-
} & Omit<React$1.HTMLAttributes<HTMLDivElement>, "onSelect" | "disabled" | "value"> & {
|
711
|
-
disabled?: boolean | undefined;
|
712
|
-
onSelect?: ((value: string) => void) | undefined;
|
713
|
-
value?: string | undefined;
|
714
|
-
} & React$1.RefAttributes<HTMLDivElement>, "ref"> & React$1.RefAttributes<HTMLDivElement>>;
|
696
|
+
declare const CommandInput: React$1.ForwardRefExoticComponent<CommandInputProps & React$1.RefAttributes<HTMLInputElement>>;
|
697
|
+
declare const CommandList: React$1.ForwardRefExoticComponent<CommandListProps & React$1.RefAttributes<HTMLDivElement>>;
|
698
|
+
declare const CommandEmpty: React$1.ForwardRefExoticComponent<CommandEmptyProps & React$1.RefAttributes<HTMLDivElement>>;
|
699
|
+
declare const CommandGroup: React$1.ForwardRefExoticComponent<CommandGroupProps & React$1.RefAttributes<HTMLDivElement>>;
|
700
|
+
declare const CommandSeparator: React$1.ForwardRefExoticComponent<CommandSeparatorProps & React$1.RefAttributes<HTMLDivElement>>;
|
701
|
+
declare const CommandItem: React$1.ForwardRefExoticComponent<CommandItemProps & React$1.RefAttributes<HTMLDivElement>>;
|
715
702
|
declare const CommandShortcut: {
|
716
|
-
({ className, ...props }: React$1.HTMLAttributes<HTMLSpanElement>): React$1.JSX.Element;
|
703
|
+
({ className, ...props }: React$1.HTMLAttributes<HTMLSpanElement> & CommandShortcutProps): React$1.JSX.Element;
|
717
704
|
displayName: string;
|
718
705
|
};
|
719
706
|
|
@@ -962,9 +949,19 @@ type CodeBlockTypes = {
|
|
962
949
|
fileName?: string;
|
963
950
|
/** Code content to be displayed within the code block.*/
|
964
951
|
code?: string;
|
952
|
+
/** line numbers for code block */
|
965
953
|
lineNumbers?: boolean;
|
966
|
-
|
967
|
-
|
954
|
+
/** Wrap text in code block */
|
955
|
+
wrapText?: boolean;
|
956
|
+
/** Custom class names for the code block */
|
957
|
+
classNames?: {
|
958
|
+
root?: string;
|
959
|
+
tabs?: string;
|
960
|
+
tab?: string;
|
961
|
+
code?: string;
|
962
|
+
fileName?: string;
|
963
|
+
codeBlockContainer?: string;
|
964
|
+
};
|
968
965
|
};
|
969
966
|
declare const CodeBlock: FC<CodeBlockTypes>;
|
970
967
|
|
@@ -1508,6 +1505,10 @@ type RegisterFormTypes = {
|
|
1508
1505
|
additionalButtons?: any;
|
1509
1506
|
/** To add more custom input fields */
|
1510
1507
|
additionalInputs?: any;
|
1508
|
+
/** To customize the username input field */
|
1509
|
+
usernameOptions: {
|
1510
|
+
label?: LabelProps;
|
1511
|
+
};
|
1511
1512
|
};
|
1512
1513
|
declare const RegisterForm: FC<RegisterFormTypes>;
|
1513
1514
|
|