@team-monolith/cds 1.44.1 → 1.44.2

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.
@@ -22,7 +22,7 @@ export interface SquareButtonOwnProps<RootComponentType extends React.ElementTyp
22
22
  /** 로딩 여부 */
23
23
  loading?: boolean;
24
24
  /** 버튼 클릭 시 호출될 콜백 함수 */
25
- onClick?: () => void;
25
+ onClick?: React.MouseEventHandler<HTMLButtonElement>;
26
26
  }
27
27
  export type SquareButtonProps<RootComponentType extends React.ElementType = SquareButtonTypeMap["defaultComponent"]> = PolymorphicProps<SquareButtonTypeMap<RootComponentType>, RootComponentType>;
28
28
  export interface SquareButtonTypeMap<RootComponentType extends React.ElementType = "span"> {
@@ -22,10 +22,10 @@ import { SegmentedControlGroupPropsContext, } from "./SegmentedControlGroupProps
22
22
  export const SegmentedControlSquareButton = React.forwardRef(function SegmentedControlSquareButton(props, ref) {
23
23
  const { onClick, icon } = props, other = __rest(props, ["onClick", "icon"]);
24
24
  const context = useContext(SegmentedControlGroupPropsContext);
25
- const handleClick = () => {
25
+ const handleClick = (e) => {
26
26
  var _a;
27
27
  (_a = context.onClick) === null || _a === void 0 ? void 0 : _a.call(context, props.value);
28
- onClick === null || onClick === void 0 ? void 0 : onClick();
28
+ onClick === null || onClick === void 0 ? void 0 : onClick(e);
29
29
  };
30
30
  const isActive = context.multiSelect
31
31
  ? context.value.includes(props.value)
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@team-monolith/cds",
3
- "version": "1.44.1",
3
+ "version": "1.44.2",
4
4
  "main": "dist/index.js",
5
5
  "types": "dist/index.d.ts",
6
6
  "sideEffects": false,