@lotte-innovate/ui-component-test 0.1.23 → 0.1.25

Sign up to get free protection for your applications and to get access to all the features.
@@ -74,8 +74,8 @@ export interface BarChartProps extends VariantProps<typeof barChartVariants> {
74
74
  declare const barChartVariants: (props?: ({
75
75
  scaling?: "90%" | "95%" | "100%" | "105%" | "110%" | null | undefined;
76
76
  } & import("class-variance-authority/dist/types").ClassProp) | undefined) => string;
77
- export declare const BarChart: {
77
+ declare const BarChart: {
78
78
  ({ className, title, datasets, labels, scaling, legend, width, height, indexAxis, appearance, isColorMixed, ...props }: BarChartProps): import("react/jsx-runtime").JSX.Element;
79
79
  displayName: string;
80
80
  };
81
- export {};
81
+ export default BarChart;
@@ -36,7 +36,7 @@ var barChartVariants = cva('', {
36
36
  scaling: '100%',
37
37
  },
38
38
  });
39
- export var BarChart = function (_a) {
39
+ var BarChart = function (_a) {
40
40
  var className = _a.className, title = _a.title, datasets = _a.datasets, labels = _a.labels, scaling = _a.scaling, legend = _a.legend, width = _a.width, height = _a.height, indexAxis = _a.indexAxis, _b = _a.appearance, appearance = _b === void 0 ? 'solid' : _b, _c = _a.isColorMixed, isColorMixed = _c === void 0 ? true : _c, props = __rest(_a, ["className", "title", "datasets", "labels", "scaling", "legend", "width", "height", "indexAxis", "appearance", "isColorMixed"]);
41
41
  datasets.forEach(function (dataset, index) {
42
42
  if (!dataset.backgroundColor) {
@@ -57,3 +57,4 @@ export var BarChart = function (_a) {
57
57
  }, className: cn(barChartVariants({ scaling: scaling }), className), width: width, height: height }, props)));
58
58
  };
59
59
  BarChart.displayName = 'BarChart';
60
+ export default BarChart;
@@ -35,7 +35,7 @@ export var DropdownMenuCheckboxItem = forwardRef(function (_a, ref) {
35
35
  var itemClassName = cn(dropdownMenuItemVariants({
36
36
  radius: radius,
37
37
  size: size,
38
- }), 'pl-7', menuItemAppearanceStyle(appearance, color), className);
38
+ }), menuItemAppearanceStyle(appearance, color), className);
39
39
  return (_jsxs(DropdownMenuPrimitive.CheckboxItem, __assign({ ref: ref, className: itemClassName }, props, { children: [_jsx(DropdownMenuItemIndicator, { forceMount: true, radius: 'medium', size: size, children: checked && _jsx(CheckIcon, {}) }), children] })));
40
40
  });
41
41
  DropdownMenuCheckboxItem.displayName = 'DropdownMenu.CheckboxItem';
@@ -27,7 +27,7 @@ import { cva } from 'class-variance-authority';
27
27
  import { menuItemAppearanceStyle, scalingVariants, radiusVariants, blackText } from '../../../lib/constants';
28
28
  import { DropdownMenuContext } from './DropdownMenuRoot';
29
29
  import { cn } from '../../../lib/utils/utils';
30
- export var dropdownMenuItemVariants = cva("flex group relative leading-none select-none outline-none items-center justify-between\n data-[disabled]:text-slate-8 dark:data-[disabled]:text-slateDark-8 hover:data-[disabled]:bg-transparent dark:hover:data-[disabled]:bg-transparent text-slate-12 dark:text-slateDark-12", {
30
+ export var dropdownMenuItemVariants = cva("flex gap-2 group relative leading-none select-none outline-none items-center\n data-[disabled]:text-slate-8 dark:data-[disabled]:text-slateDark-8 hover:data-[disabled]:bg-transparent dark:hover:data-[disabled]:bg-transparent text-slate-12 dark:text-slateDark-12", {
31
31
  variants: {
32
32
  radius: __assign({}, radiusVariants['menu-item']),
33
33
  scaling: __assign({}, scalingVariants),
@@ -49,9 +49,9 @@ export var DropdownMenuItem = forwardRef(function (_a, ref) {
49
49
  radius: radius,
50
50
  size: size,
51
51
  }), className);
52
- var shortcutClassName = 'group-hover:text-slateA-11 dark:group-hover:text-white';
52
+ var shortcutClassName = 'ml-auto group-hover:text-slateA-11 dark:group-hover:text-white';
53
53
  if (appearance === 'solid' && !blackText.includes(color)) {
54
- shortcutClassName = 'group-hover:text-white dark:group-hover:text-white';
54
+ shortcutClassName = 'ml-auto group-hover:text-white dark:group-hover:text-white';
55
55
  }
56
56
  return (_jsxs(DropdownMenuPrimitive.Item, __assign({ ref: ref }, props, { className: itemClassName, children: [children, shortcut && _jsx("span", { className: shortcutClassName, children: shortcut })] })));
57
57
  });
@@ -27,7 +27,7 @@ import { cva } from 'class-variance-authority';
27
27
  import { radiusVariants } from '../../../lib/constants';
28
28
  import { DropdownMenuContext } from './DropdownMenuRoot';
29
29
  import { cn } from '../../../lib/utils/utils';
30
- export var dropdownMenuItemIndicatorVariants = cva("absolute left-0 inline-flex items-center justify-center ml-1 border", {
30
+ export var dropdownMenuItemIndicatorVariants = cva("inline-flex items-center justify-center border", {
31
31
  variants: {
32
32
  radius: __assign({}, radiusVariants['base']),
33
33
  size: {
@@ -35,7 +35,7 @@ export var DropdownMenuRadioItem = forwardRef(function (_a, ref) {
35
35
  var itemClassName = cn(dropdownMenuItemVariants({
36
36
  radius: radius,
37
37
  size: size,
38
- }), 'pl-7', menuItemAppearanceStyle(appearance, color), className);
38
+ }), menuItemAppearanceStyle(appearance, color), className);
39
39
  return (_jsxs(DropdownMenuPrimitive.RadioItem, __assign({ ref: ref, className: itemClassName }, props, { children: [_jsx(DropdownMenuItemIndicator, { forceMount: true, radius: 'full', size: size, children: selectedValue === props.value && _jsx(DotFilledIcon, {}) }), children] })));
40
40
  });
41
41
  DropdownMenuRadioItem.displayName = 'DropdownMenu.RadioItem';
@@ -35,6 +35,6 @@ export var DropdownMenuSubTrigger = forwardRef(function (_a, ref) {
35
35
  ? 'hover:fill-slate-12 dark:hover:fill-slateDark-1'
36
36
  : "hover:fill-white dark:hover:fill-slateDark-12 ");
37
37
  var triggerClassName = cn(dropdownMenuItemVariants({ size: size, radius: radius }), menuItemAppearanceStyle(appearance, color), className);
38
- return (_jsxs(DropdownMenuPrimitive.SubTrigger, __assign({ ref: ref, className: triggerClassName }, props, { children: [children, _jsx("div", { className: "ml-auto pl-5 ", children: _jsx(ChevronRightIcon, { className: iconClassName }) })] })));
38
+ return (_jsxs(DropdownMenuPrimitive.SubTrigger, __assign({ ref: ref, className: triggerClassName }, props, { children: [children, _jsx("div", { className: "ml-auto pl-5", children: _jsx(ChevronRightIcon, { className: iconClassName }) })] })));
39
39
  });
40
40
  DropdownMenuSubTrigger.displayName = 'DropdownMenu.SubTrigger';
@@ -80,8 +80,8 @@ export interface LineChartProps extends VariantProps<typeof lineChartVariants> {
80
80
  declare const lineChartVariants: (props?: ({
81
81
  scaling?: "90%" | "95%" | "100%" | "105%" | "110%" | null | undefined;
82
82
  } & import("class-variance-authority/dist/types").ClassProp) | undefined) => string;
83
- export declare const LineChart: {
83
+ declare const LineChart: {
84
84
  ({ className, title, datasets, labels, scaling, legend, width, height, indexAxis, appearance, scales, isColorMixed, ...props }: LineChartProps): import("react/jsx-runtime").JSX.Element;
85
85
  displayName: string;
86
86
  };
87
- export {};
87
+ export default LineChart;
@@ -36,7 +36,7 @@ var lineChartVariants = cva('', {
36
36
  scaling: '100%',
37
37
  },
38
38
  });
39
- export var LineChart = function (_a) {
39
+ var LineChart = function (_a) {
40
40
  var className = _a.className, title = _a.title, datasets = _a.datasets, labels = _a.labels, scaling = _a.scaling, legend = _a.legend, width = _a.width, height = _a.height, indexAxis = _a.indexAxis, _b = _a.appearance, appearance = _b === void 0 ? 'solid' : _b, scales = _a.scales, _c = _a.isColorMixed, isColorMixed = _c === void 0 ? true : _c, props = __rest(_a, ["className", "title", "datasets", "labels", "scaling", "legend", "width", "height", "indexAxis", "appearance", "scales", "isColorMixed"]);
41
41
  var colorset = isColorMixed ? chartColorList.mixed : chartColorList.sorting;
42
42
  var colorAlphaset = isColorMixed ? chartAlphaColorList.mixed : chartAlphaColorList.sorting;
@@ -56,3 +56,4 @@ export var LineChart = function (_a) {
56
56
  }, className: cn(lineChartVariants({ scaling: scaling }), className), width: width, height: height }, props)));
57
57
  };
58
58
  LineChart.displayName = 'LineChart';
59
+ export default LineChart;
@@ -3,16 +3,13 @@ import * as ToggleGroupPrimitive from '@radix-ui/react-toggle-group';
3
3
  import { VariantProps } from 'class-variance-authority';
4
4
  import { toggleGroupItemVariants } from './ToggleGroupItem';
5
5
  import { IAppearance, IColor } from '../../../lib/types';
6
- export interface ToggleGroupProps<T> extends VariantProps<typeof toggleVariants>, VariantProps<typeof toggleGroupItemVariants> {
7
- type?: 'single' | 'multiple';
6
+ export interface ToggleGroupProps extends VariantProps<typeof toggleVariants>, VariantProps<typeof toggleGroupItemVariants> {
8
7
  appearance?: IAppearance;
9
8
  color?: IColor;
10
- defaultValue?: T;
11
- value?: T;
12
9
  }
13
10
  declare const toggleVariants: (props?: ({
14
11
  scaling?: "90%" | "95%" | "100%" | "105%" | "110%" | null | undefined;
15
12
  } & import("class-variance-authority/dist/types").ClassProp) | undefined) => string;
16
- export declare const ToggleGroupContext: React.Context<ToggleGroupProps<string>>;
17
- export declare const ToggleGroupRoot: React.ForwardRefExoticComponent<(React.ComponentPropsWithoutRef<React.ForwardRefExoticComponent<(ToggleGroupPrimitive.ToggleGroupSingleProps | ToggleGroupPrimitive.ToggleGroupMultipleProps) & React.RefAttributes<HTMLDivElement>>> & ToggleGroupProps<string> & ToggleGroupProps<string[]>) & React.RefAttributes<HTMLDivElement>>;
13
+ export declare const ToggleGroupContext: React.Context<ToggleGroupProps>;
14
+ export declare const ToggleGroupRoot: React.ForwardRefExoticComponent<(React.ComponentPropsWithoutRef<React.ForwardRefExoticComponent<(ToggleGroupPrimitive.ToggleGroupSingleProps | ToggleGroupPrimitive.ToggleGroupMultipleProps) & React.RefAttributes<HTMLDivElement>>> & ToggleGroupProps) & React.RefAttributes<HTMLDivElement>>;
18
15
  export {};
@@ -42,6 +42,6 @@ export var ToggleGroupContext = createContext({
42
42
  export var ToggleGroupRoot = forwardRef(function (_a, ref) {
43
43
  var className = _a.className, children = _a.children, defaultValue = _a.defaultValue, value = _a.value, type = _a.type, onValueChange = _a.onValueChange, scaling = _a.scaling, size = _a.size, color = _a.color, appearance = _a.appearance, props = __rest(_a, ["className", "children", "defaultValue", "value", "type", "onValueChange", "scaling", "size", "color", "appearance"]);
44
44
  var contextValue = { size: size, color: color, appearance: appearance };
45
- return (_jsx(ToggleGroupContext.Provider, { value: contextValue, children: _jsx(ToggleGroupPrimitive.Root, __assign({ ref: ref, type: type, value: value, defaultValue: defaultValue, className: cn(toggleVariants({ scaling: scaling }), className) }, props, { children: children })) }));
45
+ return (_jsx(ToggleGroupContext.Provider, { value: contextValue, children: type === 'single' ? (_jsx(ToggleGroupPrimitive.Root, __assign({ ref: ref, type: type, value: value, defaultValue: defaultValue, className: cn(toggleVariants({ scaling: scaling }), className) }, props, { children: children }))) : (_jsx(ToggleGroupPrimitive.Root, __assign({ ref: ref, type: type, value: value, defaultValue: defaultValue, className: cn(toggleVariants({ scaling: scaling }), className) }, props, { children: children }))) }));
46
46
  });
47
47
  ToggleGroupRoot.displayName = 'ToggleGroup.Root';
@@ -1,6 +1,6 @@
1
1
  /// <reference types="react" />
2
2
  declare const ToggleGroup: {
3
- Root: import("react").ForwardRefExoticComponent<(import("react").ComponentPropsWithoutRef<import("react").ForwardRefExoticComponent<(import("@radix-ui/react-toggle-group").ToggleGroupSingleProps | import("@radix-ui/react-toggle-group").ToggleGroupMultipleProps) & import("react").RefAttributes<HTMLDivElement>>> & import("./ToggleGroupRoot").ToggleGroupProps<string> & import("./ToggleGroupRoot").ToggleGroupProps<string[]>) & import("react").RefAttributes<HTMLDivElement>>;
3
+ Root: import("react").ForwardRefExoticComponent<(import("react").ComponentPropsWithoutRef<import("react").ForwardRefExoticComponent<(import("@radix-ui/react-toggle-group").ToggleGroupSingleProps | import("@radix-ui/react-toggle-group").ToggleGroupMultipleProps) & import("react").RefAttributes<HTMLDivElement>>> & import("./ToggleGroupRoot").ToggleGroupProps) & import("react").RefAttributes<HTMLDivElement>>;
4
4
  Item: import("react").ForwardRefExoticComponent<Omit<import("@radix-ui/react-toggle-group").ToggleGroupItemProps & import("react").RefAttributes<HTMLButtonElement>, "ref"> & import("./ToggleGroupItem").ToggleGroupItemProps & import("react").RefAttributes<HTMLButtonElement>>;
5
5
  };
6
6
  export default ToggleGroup;
@@ -41,7 +41,9 @@ export { default as Toggle } from './Toggle';
41
41
  export { default as ToggleGroup } from './ToggleGroup';
42
42
  export { default as ToggleSwitch } from './ToggleSwitch';
43
43
  export { default as Tooltip } from './Tooltip';
44
+ export { default as BarChart } from './BarChart';
44
45
  export { default as BubbleChart } from './BubbleChart';
45
46
  export { default as RadarChart } from './RadarChart';
47
+ export { default as LineChart } from './LineChart';
46
48
  export { default as PieChart } from './PieChart';
47
49
  export { default as DoughnutChart } from './DoughnutChart';
@@ -43,7 +43,9 @@ export { default as ToggleGroup } from './ToggleGroup';
43
43
  export { default as ToggleSwitch } from './ToggleSwitch';
44
44
  export { default as Tooltip } from './Tooltip';
45
45
  // Chart
46
+ export { default as BarChart } from './BarChart';
46
47
  export { default as BubbleChart } from './BubbleChart';
47
48
  export { default as RadarChart } from './RadarChart';
49
+ export { default as LineChart } from './LineChart';
48
50
  export { default as PieChart } from './PieChart';
49
51
  export { default as DoughnutChart } from './DoughnutChart';
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@lotte-innovate/ui-component-test",
3
3
  "description": "Lotte UI Library",
4
- "version": "0.1.23",
4
+ "version": "0.1.25",
5
5
  "private": false,
6
6
  "type": "module",
7
7
  "files": [