UNPKG

@public-ui/components

Version:

Contains all web components that belong to KoliBri - The accessible HTML-Standard.

15 lines (14 loc) 680 B
/*! * KoliBri - The accessible HTML-Standard */ import { __rest } from "tslib"; import { h } from "@stencil/core"; import { IconFC } from "../../internal/functional-components/icon/component"; import KolButtonFc from "../Button"; const KolIconButtonFc = (props) => { const { componentName = 'button', label, icon, onClick } = props, other = __rest(props, ["componentName", "label", "icon", "onClick"]); const Component = componentName === 'button' ? KolButtonFc : IconFC; return h(Component, Object.assign({ label: label || '', hideLabel: true, icons: `${icon}`, onClick: onClick }, other)); }; export default KolIconButtonFc; //# sourceMappingURL=IconButton.js.map