@luscii-healthtech/web-ui 2.49.0 → 2.49.1

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.
@@ -1,5 +1,5 @@
1
1
  import React from "react";
2
- import { DynamicIconProps } from "../Icons/DynamicIcon";
2
+ import { IconProps } from "../Icons/types/IconProps.type";
3
3
  export declare type NotificationBannerColor = "base" | "blue" | "red" | "green" | "amber";
4
4
  export interface NotificationBannerLinkProps {
5
5
  text: string;
@@ -21,7 +21,7 @@ export declare type NotificationBannerProps = (NotificationBannerPropsWithChildr
21
21
  /**
22
22
  * The icon can either be one of our icon components or an image url
23
23
  */
24
- icon?: DynamicIconProps["icon"];
24
+ icon?: string | React.FunctionComponent<IconProps>;
25
25
  className?: string;
26
26
  stretch?: boolean;
27
27
  /**
@@ -3563,22 +3563,6 @@ var TextLink = function TextLink(props) {
3563
3563
  }, props.text);
3564
3564
  };
3565
3565
 
3566
- var DynamicIcon = function DynamicIcon(props) {
3567
- var icon = props.icon,
3568
- className = props.className;
3569
-
3570
- if (typeof icon === "string") {
3571
- return /*#__PURE__*/React__default.createElement("img", {
3572
- src: icon,
3573
- className: className
3574
- });
3575
- }
3576
-
3577
- return /*#__PURE__*/React__default.createElement(icon, {
3578
- className: className
3579
- });
3580
- };
3581
-
3582
3566
  var NotificationBanner = function NotificationBanner(props) {
3583
3567
  var _props$stretch = props.stretch,
3584
3568
  stretch = _props$stretch === void 0 ? true : _props$stretch,
@@ -3610,10 +3594,12 @@ var NotificationBanner = function NotificationBanner(props) {
3610
3594
  })
3611
3595
  }, /*#__PURE__*/React__default.createElement("div", {
3612
3596
  className: classes
3613
- }, props.icon && /*#__PURE__*/React__default.createElement(DynamicIcon, {
3614
- className: "w-6 h-6 mr-3",
3615
- icon: props.icon
3616
- }), /*#__PURE__*/React__default.createElement("div", {
3597
+ }, props.icon && (typeof props.icon === "function" ? /*#__PURE__*/React__default.createElement(props.icon, {
3598
+ className: "w-6 h-6 mr-3"
3599
+ }) : /*#__PURE__*/React__default.createElement("img", {
3600
+ src: props.icon,
3601
+ className: "w-6 h-6 mr-3"
3602
+ })), /*#__PURE__*/React__default.createElement("div", {
3617
3603
  className: "flex flex-col"
3618
3604
  }, props.children, (props.text || props.linkProps) && /*#__PURE__*/React__default.createElement("div", {
3619
3605
  className: "flex flex-row items-center"