@grandbazar/ui-baza 1.1.3 → 1.1.5
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.cjs +65 -30
- package/dist/index.d.ts +23 -4
- package/dist/index.js +65 -30
- package/dist/style.css +51 -0
- package/package.json +1 -1
package/dist/index.cjs
CHANGED
|
@@ -27,38 +27,38 @@ function createRange(start, length) {
|
|
|
27
27
|
const badge = "_badge_p5h5n_2";
|
|
28
28
|
const primary$3 = "_primary_p5h5n_9";
|
|
29
29
|
const secondary$4 = "_secondary_p5h5n_13";
|
|
30
|
-
const accent$
|
|
30
|
+
const accent$3 = "_accent_p5h5n_18";
|
|
31
31
|
const violet = "_violet_p5h5n_23";
|
|
32
32
|
const pink = "_pink_p5h5n_28";
|
|
33
33
|
const red$1 = "_red_p5h5n_33";
|
|
34
34
|
const orange = "_orange_p5h5n_38";
|
|
35
35
|
const green = "_green_p5h5n_43";
|
|
36
|
-
const neutral$
|
|
37
|
-
const lg$
|
|
38
|
-
const md$
|
|
39
|
-
const styles$
|
|
36
|
+
const neutral$3 = "_neutral_p5h5n_48";
|
|
37
|
+
const lg$6 = "_lg_p5h5n_53";
|
|
38
|
+
const md$9 = "_md_p5h5n_60";
|
|
39
|
+
const styles$u = {
|
|
40
40
|
badge: badge,
|
|
41
41
|
primary: primary$3,
|
|
42
42
|
secondary: secondary$4,
|
|
43
|
-
accent: accent$
|
|
43
|
+
accent: accent$3,
|
|
44
44
|
violet: violet,
|
|
45
45
|
pink: pink,
|
|
46
46
|
red: red$1,
|
|
47
47
|
orange: orange,
|
|
48
48
|
green: green,
|
|
49
|
-
neutral: neutral$
|
|
50
|
-
lg: lg$
|
|
51
|
-
md: md$
|
|
49
|
+
neutral: neutral$3,
|
|
50
|
+
lg: lg$6,
|
|
51
|
+
md: md$9
|
|
52
52
|
};
|
|
53
53
|
|
|
54
54
|
function Badge({ children, className, size = "lg", color = "accent", mode = "primary", ...props }) {
|
|
55
|
-
return /* @__PURE__ */ jsxRuntime.jsx("div", { className: classNames(styles$
|
|
55
|
+
return /* @__PURE__ */ jsxRuntime.jsx("div", { className: classNames(styles$u.badge, styles$u[size], styles$u[color], styles$u[mode], className), ...props, children });
|
|
56
56
|
}
|
|
57
57
|
|
|
58
58
|
const badgeTabsItem = "_badgeTabsItem_10lit_2";
|
|
59
59
|
const primary$2 = "_primary_10lit_18";
|
|
60
60
|
const secondary$3 = "_secondary_10lit_36";
|
|
61
|
-
const styles$
|
|
61
|
+
const styles$t = {
|
|
62
62
|
badgeTabsItem: badgeTabsItem,
|
|
63
63
|
primary: primary$2,
|
|
64
64
|
secondary: secondary$3
|
|
@@ -71,7 +71,7 @@ function BadgeTabsItem({ className, children, isActive, mode = "primary", ...pro
|
|
|
71
71
|
type: "button",
|
|
72
72
|
role: "tab",
|
|
73
73
|
"aria-selected": Boolean(isActive),
|
|
74
|
-
className: classNames(styles$
|
|
74
|
+
className: classNames(styles$t.badgeTabsItem, styles$t[mode], className),
|
|
75
75
|
...props,
|
|
76
76
|
children
|
|
77
77
|
}
|
|
@@ -79,12 +79,12 @@ function BadgeTabsItem({ className, children, isActive, mode = "primary", ...pro
|
|
|
79
79
|
}
|
|
80
80
|
|
|
81
81
|
const badgeTabsRoot = "_badgeTabsRoot_1qkat_2";
|
|
82
|
-
const styles$
|
|
82
|
+
const styles$s = {
|
|
83
83
|
badgeTabsRoot: badgeTabsRoot
|
|
84
84
|
};
|
|
85
85
|
|
|
86
86
|
function BadgeTabsRoot({ className, children, ...props }) {
|
|
87
|
-
return /* @__PURE__ */ jsxRuntime.jsx("div", { role: "tablist", className: classNames(styles$
|
|
87
|
+
return /* @__PURE__ */ jsxRuntime.jsx("div", { role: "tablist", className: classNames(styles$s.badgeTabsRoot, className), ...props, children });
|
|
88
88
|
}
|
|
89
89
|
|
|
90
90
|
function BadgeTabs(props) {
|
|
@@ -598,7 +598,7 @@ function IconYandex(props) {
|
|
|
598
598
|
const breadcrumbs = "_breadcrumbs_1bfmb_2";
|
|
599
599
|
const breadcrumbsItem = "_breadcrumbsItem_1bfmb_8";
|
|
600
600
|
const defaultSeparator = "_defaultSeparator_1bfmb_14";
|
|
601
|
-
const styles$
|
|
601
|
+
const styles$r = {
|
|
602
602
|
breadcrumbs: breadcrumbs,
|
|
603
603
|
breadcrumbsItem: breadcrumbsItem,
|
|
604
604
|
defaultSeparator: defaultSeparator
|
|
@@ -629,7 +629,7 @@ function Slot({
|
|
|
629
629
|
}
|
|
630
630
|
|
|
631
631
|
const breadcrumbItem = "_breadcrumbItem_cua4v_2";
|
|
632
|
-
const styles$
|
|
632
|
+
const styles$q = {
|
|
633
633
|
breadcrumbItem: breadcrumbItem
|
|
634
634
|
};
|
|
635
635
|
|
|
@@ -640,7 +640,7 @@ function BreadcrumbItem({ children, className, isActive, asChild, ...props }) {
|
|
|
640
640
|
{
|
|
641
641
|
"data-active": isActive,
|
|
642
642
|
"data-disabled": props.disabled,
|
|
643
|
-
className: classNames(styles$
|
|
643
|
+
className: classNames(styles$q.breadcrumbItem, className),
|
|
644
644
|
...isActive && { "aria-current": "page" },
|
|
645
645
|
...!asChild && { type: "button" },
|
|
646
646
|
...props,
|
|
@@ -652,40 +652,74 @@ function BreadcrumbItem({ children, className, isActive, asChild, ...props }) {
|
|
|
652
652
|
function Breadcrumbs({
|
|
653
653
|
className,
|
|
654
654
|
children,
|
|
655
|
-
separator = /* @__PURE__ */ jsxRuntime.jsx(IconChevron, { className: styles$
|
|
655
|
+
separator = /* @__PURE__ */ jsxRuntime.jsx(IconChevron, { className: styles$r.defaultSeparator })
|
|
656
656
|
}) {
|
|
657
657
|
const childrenArray = Array.isArray(children) ? children : [children];
|
|
658
658
|
const lastIndex = childrenArray.length - 1;
|
|
659
|
-
return /* @__PURE__ */ jsxRuntime.jsx("nav", { "aria-label": "breadcrumb", className, children: /* @__PURE__ */ jsxRuntime.jsx("ol", { className: styles$
|
|
660
|
-
/* @__PURE__ */ jsxRuntime.jsx("li", { className: styles$
|
|
661
|
-
index < lastIndex && /* @__PURE__ */ jsxRuntime.jsx("li", { className: styles$
|
|
659
|
+
return /* @__PURE__ */ jsxRuntime.jsx("nav", { "aria-label": "breadcrumb", className, children: /* @__PURE__ */ jsxRuntime.jsx("ol", { className: styles$r.breadcrumbs, children: childrenArray.map((item, index) => /* @__PURE__ */ jsxRuntime.jsxs(React.Fragment, { children: [
|
|
660
|
+
/* @__PURE__ */ jsxRuntime.jsx("li", { className: styles$r.breadcrumbsItem, children: item }),
|
|
661
|
+
index < lastIndex && /* @__PURE__ */ jsxRuntime.jsx("li", { className: styles$r.breadcrumbsItem, "aria-hidden": "true", children: separator })
|
|
662
662
|
] }, index)) }) });
|
|
663
663
|
}
|
|
664
664
|
Breadcrumbs.Item = BreadcrumbItem;
|
|
665
665
|
|
|
666
666
|
const button = "_button_cmbkj_2";
|
|
667
|
-
const accent$
|
|
667
|
+
const accent$2 = "_accent_cmbkj_11";
|
|
668
668
|
const primary$1 = "_primary_cmbkj_12";
|
|
669
669
|
const secondary$2 = "_secondary_cmbkj_30";
|
|
670
670
|
const tertiary = "_tertiary_cmbkj_48";
|
|
671
671
|
const line = "_line_cmbkj_49";
|
|
672
|
-
const neutral$
|
|
673
|
-
const lg$
|
|
674
|
-
const md$
|
|
672
|
+
const neutral$2 = "_neutral_cmbkj_78";
|
|
673
|
+
const lg$5 = "_lg_cmbkj_145";
|
|
674
|
+
const md$8 = "_md_cmbkj_153";
|
|
675
675
|
const sm$3 = "_sm_cmbkj_161";
|
|
676
|
-
const styles$
|
|
676
|
+
const styles$p = {
|
|
677
677
|
button: button,
|
|
678
|
-
accent: accent$
|
|
678
|
+
accent: accent$2,
|
|
679
679
|
primary: primary$1,
|
|
680
680
|
secondary: secondary$2,
|
|
681
681
|
tertiary: tertiary,
|
|
682
682
|
line: line,
|
|
683
|
+
neutral: neutral$2,
|
|
684
|
+
lg: lg$5,
|
|
685
|
+
md: md$8,
|
|
686
|
+
sm: sm$3
|
|
687
|
+
};
|
|
688
|
+
|
|
689
|
+
const buttonFunction = "_buttonFunction_o8iku_2";
|
|
690
|
+
const accent$1 = "_accent_o8iku_10";
|
|
691
|
+
const neutral$1 = "_neutral_o8iku_22";
|
|
692
|
+
const lg$4 = "_lg_o8iku_41";
|
|
693
|
+
const md$7 = "_md_o8iku_46";
|
|
694
|
+
const styles$o = {
|
|
695
|
+
buttonFunction: buttonFunction,
|
|
696
|
+
accent: accent$1,
|
|
683
697
|
neutral: neutral$1,
|
|
684
698
|
lg: lg$4,
|
|
685
|
-
md: md$7
|
|
686
|
-
sm: sm$3
|
|
699
|
+
md: md$7
|
|
687
700
|
};
|
|
688
701
|
|
|
702
|
+
function ButtonFunction({
|
|
703
|
+
children,
|
|
704
|
+
className,
|
|
705
|
+
color = "accent",
|
|
706
|
+
size = "lg",
|
|
707
|
+
asChild,
|
|
708
|
+
...props
|
|
709
|
+
}) {
|
|
710
|
+
const Component = asChild ? Slot : "button";
|
|
711
|
+
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
712
|
+
Component,
|
|
713
|
+
{
|
|
714
|
+
className: classNames(styles$o.buttonFunction, styles$o[color], styles$o[size], className),
|
|
715
|
+
...props.disabled && { "data-disabled": true },
|
|
716
|
+
...!asChild && { type: "button" },
|
|
717
|
+
...props,
|
|
718
|
+
children
|
|
719
|
+
}
|
|
720
|
+
);
|
|
721
|
+
}
|
|
722
|
+
|
|
689
723
|
function Button({
|
|
690
724
|
children,
|
|
691
725
|
className,
|
|
@@ -695,9 +729,10 @@ function Button({
|
|
|
695
729
|
as = "button",
|
|
696
730
|
...props
|
|
697
731
|
}) {
|
|
698
|
-
const commonClassNames = classNames(styles$
|
|
732
|
+
const commonClassNames = classNames(styles$p.button, styles$p[color], styles$p[size], styles$p[mode], className);
|
|
699
733
|
return as === "button" ? /* @__PURE__ */ jsxRuntime.jsx("button", { className: commonClassNames, type: "button", ...props, children }) : /* @__PURE__ */ jsxRuntime.jsx("a", { className: commonClassNames, ...props, children });
|
|
700
734
|
}
|
|
735
|
+
Button.Function = ButtonFunction;
|
|
701
736
|
|
|
702
737
|
const checkboxWrapper = "_checkboxWrapper_k1shg_2";
|
|
703
738
|
const icon$2 = "_icon_k1shg_23";
|
package/dist/index.d.ts
CHANGED
|
@@ -83,12 +83,20 @@ export declare function Button(props: TButtonAsButtonProps): React.JSX.Element;
|
|
|
83
83
|
|
|
84
84
|
export declare function Button(props: TButtonAsAnchorProps): React.JSX.Element;
|
|
85
85
|
|
|
86
|
+
export declare namespace Button {
|
|
87
|
+
var Function: typeof ButtonFunction;
|
|
88
|
+
}
|
|
89
|
+
|
|
86
90
|
declare const BUTTON_COLORS: readonly ["accent", "neutral"];
|
|
87
91
|
|
|
92
|
+
declare const BUTTON_FUNCTION_SIZES: readonly ["lg", "md"];
|
|
93
|
+
|
|
88
94
|
declare const BUTTON_MODES: readonly ["primary", "secondary", "line", "tertiary"];
|
|
89
95
|
|
|
90
96
|
declare const BUTTON_SIZES: readonly ["lg", "md", "sm"];
|
|
91
97
|
|
|
98
|
+
declare function ButtonFunction({ children, className, color, size, asChild, ...props }: TButtonFunctionProps): JSX.Element;
|
|
99
|
+
|
|
92
100
|
/**
|
|
93
101
|
* Checkbox renders a checkbox input with label and state indicators.
|
|
94
102
|
* Supports checked, unchecked, and indeterminate states with visual feedback.
|
|
@@ -515,6 +523,13 @@ declare type TButtonCommonProps = {
|
|
|
515
523
|
mode?: TArrayElement<typeof BUTTON_MODES>;
|
|
516
524
|
};
|
|
517
525
|
|
|
526
|
+
declare type TButtonFunctionProps = TAsChildProps<React.ButtonHTMLAttributes<HTMLButtonElement>> & {
|
|
527
|
+
color?: TArrayElement<typeof BUTTON_COLORS>;
|
|
528
|
+
size?: TArrayElement<typeof BUTTON_FUNCTION_SIZES>;
|
|
529
|
+
className?: string;
|
|
530
|
+
disabled?: boolean;
|
|
531
|
+
};
|
|
532
|
+
|
|
518
533
|
export declare type TButtonProps = TButtonAsButtonProps | TButtonAsAnchorProps;
|
|
519
534
|
|
|
520
535
|
export declare type TCalendarDay = {
|
|
@@ -717,16 +732,16 @@ declare type TTagProps = React.HTMLAttributes<HTMLDivElement> & {
|
|
|
717
732
|
disabled?: boolean;
|
|
718
733
|
};
|
|
719
734
|
|
|
720
|
-
declare type TTextFieldAreaProps = React.TextareaHTMLAttributes<HTMLTextAreaElement> & {
|
|
735
|
+
declare type TTextFieldAreaProps = TWithRef<React.TextareaHTMLAttributes<HTMLTextAreaElement> & {
|
|
721
736
|
isInvalid?: boolean;
|
|
722
737
|
floatingLabel?: string;
|
|
723
738
|
floatingLabelSuffix?: string;
|
|
724
|
-
}
|
|
739
|
+
}, HTMLTextAreaElement>;
|
|
725
740
|
|
|
726
|
-
declare type TTextFieldInputProps = React.InputHTMLAttributes<HTMLInputElement> & {
|
|
741
|
+
declare type TTextFieldInputProps = TWithRef<React.InputHTMLAttributes<HTMLInputElement> & {
|
|
727
742
|
isInvalid?: boolean;
|
|
728
743
|
floatingLabel?: string;
|
|
729
|
-
}
|
|
744
|
+
}, HTMLInputElement>;
|
|
730
745
|
|
|
731
746
|
declare type TTextFieldLabelProps = React.LabelHTMLAttributes<HTMLLabelElement> & {
|
|
732
747
|
isRequired?: boolean;
|
|
@@ -736,6 +751,10 @@ declare type TTextFieldRootProps = React.HTMLAttributes<HTMLDivElement> & {
|
|
|
736
751
|
size?: TArrayElement<typeof TEXT_FIELD_SIZES>;
|
|
737
752
|
};
|
|
738
753
|
|
|
754
|
+
declare type TWithRef<TProps, TElement = HTMLElement> = TProps & {
|
|
755
|
+
ref?: React.Ref<TElement>;
|
|
756
|
+
};
|
|
757
|
+
|
|
739
758
|
/**
|
|
740
759
|
* Manages month and year navigation state for DatePicker.
|
|
741
760
|
* Provides navigation handlers and current month/year values.
|
package/dist/index.js
CHANGED
|
@@ -23,38 +23,38 @@ function createRange(start, length) {
|
|
|
23
23
|
const badge = "_badge_p5h5n_2";
|
|
24
24
|
const primary$3 = "_primary_p5h5n_9";
|
|
25
25
|
const secondary$4 = "_secondary_p5h5n_13";
|
|
26
|
-
const accent$
|
|
26
|
+
const accent$3 = "_accent_p5h5n_18";
|
|
27
27
|
const violet = "_violet_p5h5n_23";
|
|
28
28
|
const pink = "_pink_p5h5n_28";
|
|
29
29
|
const red$1 = "_red_p5h5n_33";
|
|
30
30
|
const orange = "_orange_p5h5n_38";
|
|
31
31
|
const green = "_green_p5h5n_43";
|
|
32
|
-
const neutral$
|
|
33
|
-
const lg$
|
|
34
|
-
const md$
|
|
35
|
-
const styles$
|
|
32
|
+
const neutral$3 = "_neutral_p5h5n_48";
|
|
33
|
+
const lg$6 = "_lg_p5h5n_53";
|
|
34
|
+
const md$9 = "_md_p5h5n_60";
|
|
35
|
+
const styles$u = {
|
|
36
36
|
badge: badge,
|
|
37
37
|
primary: primary$3,
|
|
38
38
|
secondary: secondary$4,
|
|
39
|
-
accent: accent$
|
|
39
|
+
accent: accent$3,
|
|
40
40
|
violet: violet,
|
|
41
41
|
pink: pink,
|
|
42
42
|
red: red$1,
|
|
43
43
|
orange: orange,
|
|
44
44
|
green: green,
|
|
45
|
-
neutral: neutral$
|
|
46
|
-
lg: lg$
|
|
47
|
-
md: md$
|
|
45
|
+
neutral: neutral$3,
|
|
46
|
+
lg: lg$6,
|
|
47
|
+
md: md$9
|
|
48
48
|
};
|
|
49
49
|
|
|
50
50
|
function Badge({ children, className, size = "lg", color = "accent", mode = "primary", ...props }) {
|
|
51
|
-
return /* @__PURE__ */ jsx("div", { className: classNames(styles$
|
|
51
|
+
return /* @__PURE__ */ jsx("div", { className: classNames(styles$u.badge, styles$u[size], styles$u[color], styles$u[mode], className), ...props, children });
|
|
52
52
|
}
|
|
53
53
|
|
|
54
54
|
const badgeTabsItem = "_badgeTabsItem_10lit_2";
|
|
55
55
|
const primary$2 = "_primary_10lit_18";
|
|
56
56
|
const secondary$3 = "_secondary_10lit_36";
|
|
57
|
-
const styles$
|
|
57
|
+
const styles$t = {
|
|
58
58
|
badgeTabsItem: badgeTabsItem,
|
|
59
59
|
primary: primary$2,
|
|
60
60
|
secondary: secondary$3
|
|
@@ -67,7 +67,7 @@ function BadgeTabsItem({ className, children, isActive, mode = "primary", ...pro
|
|
|
67
67
|
type: "button",
|
|
68
68
|
role: "tab",
|
|
69
69
|
"aria-selected": Boolean(isActive),
|
|
70
|
-
className: classNames(styles$
|
|
70
|
+
className: classNames(styles$t.badgeTabsItem, styles$t[mode], className),
|
|
71
71
|
...props,
|
|
72
72
|
children
|
|
73
73
|
}
|
|
@@ -75,12 +75,12 @@ function BadgeTabsItem({ className, children, isActive, mode = "primary", ...pro
|
|
|
75
75
|
}
|
|
76
76
|
|
|
77
77
|
const badgeTabsRoot = "_badgeTabsRoot_1qkat_2";
|
|
78
|
-
const styles$
|
|
78
|
+
const styles$s = {
|
|
79
79
|
badgeTabsRoot: badgeTabsRoot
|
|
80
80
|
};
|
|
81
81
|
|
|
82
82
|
function BadgeTabsRoot({ className, children, ...props }) {
|
|
83
|
-
return /* @__PURE__ */ jsx("div", { role: "tablist", className: classNames(styles$
|
|
83
|
+
return /* @__PURE__ */ jsx("div", { role: "tablist", className: classNames(styles$s.badgeTabsRoot, className), ...props, children });
|
|
84
84
|
}
|
|
85
85
|
|
|
86
86
|
function BadgeTabs(props) {
|
|
@@ -594,7 +594,7 @@ function IconYandex(props) {
|
|
|
594
594
|
const breadcrumbs = "_breadcrumbs_1bfmb_2";
|
|
595
595
|
const breadcrumbsItem = "_breadcrumbsItem_1bfmb_8";
|
|
596
596
|
const defaultSeparator = "_defaultSeparator_1bfmb_14";
|
|
597
|
-
const styles$
|
|
597
|
+
const styles$r = {
|
|
598
598
|
breadcrumbs: breadcrumbs,
|
|
599
599
|
breadcrumbsItem: breadcrumbsItem,
|
|
600
600
|
defaultSeparator: defaultSeparator
|
|
@@ -625,7 +625,7 @@ function Slot({
|
|
|
625
625
|
}
|
|
626
626
|
|
|
627
627
|
const breadcrumbItem = "_breadcrumbItem_cua4v_2";
|
|
628
|
-
const styles$
|
|
628
|
+
const styles$q = {
|
|
629
629
|
breadcrumbItem: breadcrumbItem
|
|
630
630
|
};
|
|
631
631
|
|
|
@@ -636,7 +636,7 @@ function BreadcrumbItem({ children, className, isActive, asChild, ...props }) {
|
|
|
636
636
|
{
|
|
637
637
|
"data-active": isActive,
|
|
638
638
|
"data-disabled": props.disabled,
|
|
639
|
-
className: classNames(styles$
|
|
639
|
+
className: classNames(styles$q.breadcrumbItem, className),
|
|
640
640
|
...isActive && { "aria-current": "page" },
|
|
641
641
|
...!asChild && { type: "button" },
|
|
642
642
|
...props,
|
|
@@ -648,40 +648,74 @@ function BreadcrumbItem({ children, className, isActive, asChild, ...props }) {
|
|
|
648
648
|
function Breadcrumbs({
|
|
649
649
|
className,
|
|
650
650
|
children,
|
|
651
|
-
separator = /* @__PURE__ */ jsx(IconChevron, { className: styles$
|
|
651
|
+
separator = /* @__PURE__ */ jsx(IconChevron, { className: styles$r.defaultSeparator })
|
|
652
652
|
}) {
|
|
653
653
|
const childrenArray = Array.isArray(children) ? children : [children];
|
|
654
654
|
const lastIndex = childrenArray.length - 1;
|
|
655
|
-
return /* @__PURE__ */ jsx("nav", { "aria-label": "breadcrumb", className, children: /* @__PURE__ */ jsx("ol", { className: styles$
|
|
656
|
-
/* @__PURE__ */ jsx("li", { className: styles$
|
|
657
|
-
index < lastIndex && /* @__PURE__ */ jsx("li", { className: styles$
|
|
655
|
+
return /* @__PURE__ */ jsx("nav", { "aria-label": "breadcrumb", className, children: /* @__PURE__ */ jsx("ol", { className: styles$r.breadcrumbs, children: childrenArray.map((item, index) => /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
656
|
+
/* @__PURE__ */ jsx("li", { className: styles$r.breadcrumbsItem, children: item }),
|
|
657
|
+
index < lastIndex && /* @__PURE__ */ jsx("li", { className: styles$r.breadcrumbsItem, "aria-hidden": "true", children: separator })
|
|
658
658
|
] }, index)) }) });
|
|
659
659
|
}
|
|
660
660
|
Breadcrumbs.Item = BreadcrumbItem;
|
|
661
661
|
|
|
662
662
|
const button = "_button_cmbkj_2";
|
|
663
|
-
const accent$
|
|
663
|
+
const accent$2 = "_accent_cmbkj_11";
|
|
664
664
|
const primary$1 = "_primary_cmbkj_12";
|
|
665
665
|
const secondary$2 = "_secondary_cmbkj_30";
|
|
666
666
|
const tertiary = "_tertiary_cmbkj_48";
|
|
667
667
|
const line = "_line_cmbkj_49";
|
|
668
|
-
const neutral$
|
|
669
|
-
const lg$
|
|
670
|
-
const md$
|
|
668
|
+
const neutral$2 = "_neutral_cmbkj_78";
|
|
669
|
+
const lg$5 = "_lg_cmbkj_145";
|
|
670
|
+
const md$8 = "_md_cmbkj_153";
|
|
671
671
|
const sm$3 = "_sm_cmbkj_161";
|
|
672
|
-
const styles$
|
|
672
|
+
const styles$p = {
|
|
673
673
|
button: button,
|
|
674
|
-
accent: accent$
|
|
674
|
+
accent: accent$2,
|
|
675
675
|
primary: primary$1,
|
|
676
676
|
secondary: secondary$2,
|
|
677
677
|
tertiary: tertiary,
|
|
678
678
|
line: line,
|
|
679
|
+
neutral: neutral$2,
|
|
680
|
+
lg: lg$5,
|
|
681
|
+
md: md$8,
|
|
682
|
+
sm: sm$3
|
|
683
|
+
};
|
|
684
|
+
|
|
685
|
+
const buttonFunction = "_buttonFunction_o8iku_2";
|
|
686
|
+
const accent$1 = "_accent_o8iku_10";
|
|
687
|
+
const neutral$1 = "_neutral_o8iku_22";
|
|
688
|
+
const lg$4 = "_lg_o8iku_41";
|
|
689
|
+
const md$7 = "_md_o8iku_46";
|
|
690
|
+
const styles$o = {
|
|
691
|
+
buttonFunction: buttonFunction,
|
|
692
|
+
accent: accent$1,
|
|
679
693
|
neutral: neutral$1,
|
|
680
694
|
lg: lg$4,
|
|
681
|
-
md: md$7
|
|
682
|
-
sm: sm$3
|
|
695
|
+
md: md$7
|
|
683
696
|
};
|
|
684
697
|
|
|
698
|
+
function ButtonFunction({
|
|
699
|
+
children,
|
|
700
|
+
className,
|
|
701
|
+
color = "accent",
|
|
702
|
+
size = "lg",
|
|
703
|
+
asChild,
|
|
704
|
+
...props
|
|
705
|
+
}) {
|
|
706
|
+
const Component = asChild ? Slot : "button";
|
|
707
|
+
return /* @__PURE__ */ jsx(
|
|
708
|
+
Component,
|
|
709
|
+
{
|
|
710
|
+
className: classNames(styles$o.buttonFunction, styles$o[color], styles$o[size], className),
|
|
711
|
+
...props.disabled && { "data-disabled": true },
|
|
712
|
+
...!asChild && { type: "button" },
|
|
713
|
+
...props,
|
|
714
|
+
children
|
|
715
|
+
}
|
|
716
|
+
);
|
|
717
|
+
}
|
|
718
|
+
|
|
685
719
|
function Button({
|
|
686
720
|
children,
|
|
687
721
|
className,
|
|
@@ -691,9 +725,10 @@ function Button({
|
|
|
691
725
|
as = "button",
|
|
692
726
|
...props
|
|
693
727
|
}) {
|
|
694
|
-
const commonClassNames = classNames(styles$
|
|
728
|
+
const commonClassNames = classNames(styles$p.button, styles$p[color], styles$p[size], styles$p[mode], className);
|
|
695
729
|
return as === "button" ? /* @__PURE__ */ jsx("button", { className: commonClassNames, type: "button", ...props, children }) : /* @__PURE__ */ jsx("a", { className: commonClassNames, ...props, children });
|
|
696
730
|
}
|
|
731
|
+
Button.Function = ButtonFunction;
|
|
697
732
|
|
|
698
733
|
const checkboxWrapper = "_checkboxWrapper_k1shg_2";
|
|
699
734
|
const icon$2 = "_icon_k1shg_23";
|
package/dist/style.css
CHANGED
|
@@ -702,6 +702,57 @@ textarea {
|
|
|
702
702
|
}
|
|
703
703
|
}
|
|
704
704
|
}
|
|
705
|
+
@layer ui_baza_components {
|
|
706
|
+
._buttonFunction_o8iku_2 {
|
|
707
|
+
display: flex;
|
|
708
|
+
align-items: center;
|
|
709
|
+
gap: var(--space-md);
|
|
710
|
+
font-weight: var(--font-weight-bold);
|
|
711
|
+
cursor: pointer;
|
|
712
|
+
transition: color var(--transition-duration-default) ease-in-out;
|
|
713
|
+
|
|
714
|
+
&._accent_o8iku_10 {
|
|
715
|
+
color: var(--color-accent);
|
|
716
|
+
|
|
717
|
+
&:hover {
|
|
718
|
+
color: var(--color-accent-900);
|
|
719
|
+
}
|
|
720
|
+
|
|
721
|
+
&:active {
|
|
722
|
+
color: var(--color-accent-800);
|
|
723
|
+
}
|
|
724
|
+
}
|
|
725
|
+
|
|
726
|
+
&._neutral_o8iku_22 {
|
|
727
|
+
color: var(--color-neutral);
|
|
728
|
+
|
|
729
|
+
&:hover {
|
|
730
|
+
color: var(--color-neutral-920);
|
|
731
|
+
}
|
|
732
|
+
|
|
733
|
+
&:active {
|
|
734
|
+
color: var(--color-neutral-880);
|
|
735
|
+
}
|
|
736
|
+
}
|
|
737
|
+
|
|
738
|
+
&:disabled,
|
|
739
|
+
&[data-disabled='true'] {
|
|
740
|
+
color: var(--color-neutral-340);
|
|
741
|
+
cursor: default;
|
|
742
|
+
pointer-events: none;
|
|
743
|
+
}
|
|
744
|
+
|
|
745
|
+
&._lg_o8iku_41 {
|
|
746
|
+
font-size: var(--size-md);
|
|
747
|
+
line-height: var(--line-height-lg);
|
|
748
|
+
}
|
|
749
|
+
|
|
750
|
+
&._md_o8iku_46 {
|
|
751
|
+
font-size: var(--size-sm);
|
|
752
|
+
line-height: var(--line-height-md);
|
|
753
|
+
}
|
|
754
|
+
}
|
|
755
|
+
}
|
|
705
756
|
@layer ui_baza_components {
|
|
706
757
|
._checkboxWrapper_k1shg_2 {
|
|
707
758
|
--checkbox-size: 24px;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@grandbazar/ui-baza",
|
|
3
|
-
"version": "1.1.
|
|
3
|
+
"version": "1.1.5",
|
|
4
4
|
"description": "A lightweight and modular UI kit for building modern, accessible web interfaces. Designed for flexibility, scalability, and developer happiness.",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|