@igloo-ui/icon-button
Advanced tools
Comparing version 1.1.7 to 1.2.0
@@ -1,7 +0,7 @@ | ||
import * as React from 'react'; | ||
import { ButtonOwnProps } from '@igloo-ui/button'; | ||
import './icon-button.scss'; | ||
export type Size = 'xsmall' | 'small' | 'medium' | 'large'; | ||
import * as React from "react"; | ||
import { type ButtonOwnProps } from "@igloo-ui/button"; | ||
import "./icon-button.scss"; | ||
export type Size = "xsmall" | "small" | "medium" | "large"; | ||
export type Ref = HTMLButtonElement; | ||
export interface IconButtonProps extends Omit<ButtonOwnProps, 'size'> { | ||
export interface IconButtonProps extends Omit<ButtonOwnProps, "size"> { | ||
/** Add class names to the surrounding DOM container */ | ||
@@ -12,6 +12,6 @@ className?: string; | ||
/** Callback function that will be called | ||
* when the user clicks on the button */ | ||
* when the user clicks on the button */ | ||
onClick?: () => void; | ||
/** True if the control is disabled and shows a disabled state. | ||
* The user cannot click on the button */ | ||
* The user cannot click on the button */ | ||
disabled?: boolean; | ||
@@ -18,0 +18,0 @@ /** Button size */ |
@@ -237,5 +237,5 @@ import './icon-button.css'; | ||
const IconButton = React.forwardRef((_a, ref) => { | ||
var { className, icon, onClick, disabled = false, size = 'medium', rounded = false, dataTest } = _a, rest = __rest$1(_a, ["className", "icon", "onClick", "disabled", "size", "rounded", "dataTest"]); | ||
const classes = cx$1('ids-icon-btn', `ids-icon-btn--${size}`, className, { | ||
'ids-icon-btn--round': rounded, | ||
var { className, icon, onClick, disabled = false, size = "medium", rounded = false, dataTest } = _a, rest = __rest$1(_a, ["className", "icon", "onClick", "disabled", "size", "rounded", "dataTest"]); | ||
const classes = cx$1("ids-icon-btn", `ids-icon-btn--${size}`, className, { | ||
"ids-icon-btn--round": rounded | ||
}); | ||
@@ -242,0 +242,0 @@ return (React.createElement(Button, Object.assign({ ref: ref, className: classes, onClick: onClick, disabled: disabled, "data-test": dataTest }, rest), icon)); |
{ | ||
"name": "@igloo-ui/icon-button", | ||
"version": "1.1.7", | ||
"version": "1.2.0", | ||
"main": "dist/IconButton.js", | ||
@@ -28,3 +28,3 @@ "module": "dist/IconButton.js", | ||
"@hopper-ui/tokens": "^3.1.3", | ||
"@igloo-ui/button": "^0.7.7", | ||
"@igloo-ui/button": "^0.8.0", | ||
"@igloo-ui/tokens": "^2.0.0", | ||
@@ -41,3 +41,3 @@ "classnames": "^2.3.2" | ||
], | ||
"gitHead": "a033a477c36bc021d5658beb20e58143a9557eaa" | ||
"gitHead": "d63d952ccfa759ba7fa5c62355ce9eea3ad8a3fa" | ||
} |
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
45081
+ Added@hopper-ui/tokens@4.4.1(transitive)
+ Added@igloo-ui/button@0.8.7(transitive)
- Removed@igloo-ui/button@0.7.7(transitive)
Updated@igloo-ui/button@^0.8.0