pixelize-design-library 2.2.58 → 2.2.60

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.
@@ -30,4 +30,6 @@ export type ButtonGroupIconProps = {
30
30
  menuItemStyle?: React.CSSProperties;
31
31
  isLoading?: boolean;
32
32
  divider?: boolean;
33
+ leftIconLoading?: boolean;
34
+ RightIconLoading?: boolean;
33
35
  };
@@ -2,4 +2,4 @@ import React from "react";
2
2
  import { ButtonGroupIconProps } from "./ButtonGoupIconProps";
3
3
  export default function ButtonGroupIcon({ leftIcon, rightIcon, onLeftIconClick, onRightIconClick, buttonText, onButtonClick, onButtongroupClick, size, variant, color, buttonGroupStyle, buttonGroupLeftIconStyle, buttonGroupRightIconStyle, buttonStyle, onBlurLeftIcon, onBlurRightIcon, dropdownOptions, // New prop for dropdown options
4
4
  onDropdownOptionClick, // New prop to handle option clicks
5
- rightIconDropdown, menulistStyle, menuItemStyle, isLoading, divider, }: ButtonGroupIconProps): React.JSX.Element;
5
+ rightIconDropdown, menulistStyle, menuItemStyle, isLoading, divider, leftIconLoading, RightIconLoading, }: ButtonGroupIconProps): React.JSX.Element;
@@ -30,7 +30,7 @@ function ButtonGroupIcon(_a) {
30
30
  var _b, _c;
31
31
  var leftIcon = _a.leftIcon, rightIcon = _a.rightIcon, onLeftIconClick = _a.onLeftIconClick, onRightIconClick = _a.onRightIconClick, buttonText = _a.buttonText, onButtonClick = _a.onButtonClick, onButtongroupClick = _a.onButtongroupClick, size = _a.size, variant = _a.variant, color = _a.color, buttonGroupStyle = _a.buttonGroupStyle, buttonGroupLeftIconStyle = _a.buttonGroupLeftIconStyle, buttonGroupRightIconStyle = _a.buttonGroupRightIconStyle, buttonStyle = _a.buttonStyle, onBlurLeftIcon = _a.onBlurLeftIcon, onBlurRightIcon = _a.onBlurRightIcon, dropdownOptions = _a.dropdownOptions, // New prop for dropdown options
32
32
  onDropdownOptionClick = _a.onDropdownOptionClick, // New prop to handle option clicks
33
- rightIconDropdown = _a.rightIconDropdown, menulistStyle = _a.menulistStyle, menuItemStyle = _a.menuItemStyle, isLoading = _a.isLoading, _d = _a.divider, divider = _d === void 0 ? true : _d;
33
+ rightIconDropdown = _a.rightIconDropdown, menulistStyle = _a.menulistStyle, menuItemStyle = _a.menuItemStyle, isLoading = _a.isLoading, _d = _a.divider, divider = _d === void 0 ? true : _d, leftIconLoading = _a.leftIconLoading, RightIconLoading = _a.RightIconLoading;
34
34
  var theme = (0, useCustomTheme_1.useCustomTheme)();
35
35
  var _e = (0, react_1.useState)(false), isDropdownOpen = _e[0], setIsDropdownOpen = _e[1];
36
36
  var textRef = (0, react_1.useRef)(null);
@@ -64,7 +64,7 @@ function ButtonGroupIcon(_a) {
64
64
  }
65
65
  };
66
66
  return (react_1.default.createElement(react_2.ButtonGroup, { size: size, isAttached: true, variant: variant, onClick: onButtongroupClick, colorScheme: color, style: buttonGroupStyle },
67
- leftIcon && (react_1.default.createElement(react_2.IconButton, { "aria-label": "Left icon button", icon: leftIcon, onClick: onLeftIconClick, onBlur: onBlurLeftIcon, style: buttonGroupLeftIconStyle, sx: {
67
+ leftIcon && (react_1.default.createElement(react_2.IconButton, { "aria-label": "Left icon button", icon: leftIcon, isLoading: leftIconLoading, onClick: onLeftIconClick, onBlur: onBlurLeftIcon, style: buttonGroupLeftIconStyle, sx: {
68
68
  backgroundColor: theme.colors.primary[500],
69
69
  "&:hover": {
70
70
  backgroundColor: theme.colors.primary[400],
@@ -79,7 +79,7 @@ function ButtonGroupIcon(_a) {
79
79
  }, borderLeft: "1px solid ".concat((_b = theme.colors) === null || _b === void 0 ? void 0 : _b.gray[300]), borderRight: "1px solid ".concat((_c = theme.colors) === null || _c === void 0 ? void 0 : _c.gray[300]), maxW: "200px" },
80
80
  react_1.default.createElement(react_2.Box, { ref: textRef, as: "span", overflow: "hidden", textOverflow: "ellipsis", whiteSpace: "nowrap", display: "block", width: "100%" }, buttonText))),
81
81
  rightIcon && rightIconDropdown ? (react_1.default.createElement(react_2.Menu, { isOpen: isDropdownOpen, onClose: function () { return setIsDropdownOpen(false); } },
82
- react_1.default.createElement(react_2.MenuButton, { as: react_2.IconButton, "aria-label": "Right icon button", icon: rightIcon, onClick: handleRightIconClick, onBlur: onBlurRightIcon, style: buttonGroupRightIconStyle, sx: {
82
+ react_1.default.createElement(react_2.MenuButton, { as: react_2.IconButton, "aria-label": "Right icon button", icon: rightIcon, isLoading: RightIconLoading, onClick: handleRightIconClick, onBlur: onBlurRightIcon, style: buttonGroupRightIconStyle, sx: {
83
83
  backgroundColor: theme.colors.primary[500],
84
84
  "&:hover": {
85
85
  backgroundColor: theme.colors.primary[400],
@@ -95,7 +95,7 @@ function ButtonGroupIcon(_a) {
95
95
  } }, option === null || option === void 0 ? void 0 :
96
96
  option.image,
97
97
  option.label));
98
- }))))) : (rightIcon && (react_1.default.createElement(react_2.IconButton, { "aria-label": "Right icon button", icon: rightIcon, onClick: onRightIconClick, onBlur: onBlurRightIcon, style: buttonGroupRightIconStyle, sx: {
98
+ }))))) : (rightIcon && (react_1.default.createElement(react_2.IconButton, { "aria-label": "Right icon button", icon: rightIcon, isLoading: RightIconLoading, onClick: onRightIconClick, onBlur: onBlurRightIcon, style: buttonGroupRightIconStyle, sx: {
99
99
  backgroundColor: theme.colors.primary[500],
100
100
  "&:hover": {
101
101
  backgroundColor: theme.colors.primary[400],
@@ -7,7 +7,7 @@ export type ProfilePhotoViewerProps = {
7
7
  imageObjectFit?: "cover" | "contain" | "fill" | "none" | "scale-down";
8
8
  imageBorderRadius?: string;
9
9
  isEditable?: boolean;
10
- editIconSize?: string;
10
+ editIconSize?: "xs" | "sm" | "md" | "lg" | "xl";
11
11
  editIconPositionRight?: string;
12
12
  editIconPositionBottom?: string;
13
13
  isRound?: boolean;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "pixelize-design-library",
3
- "version": "2.2.58",
3
+ "version": "2.2.60",
4
4
  "private": false,
5
5
  "main": "dist/index.js",
6
6
  "module": "dist/index.js",