@loja-integrada/admin-components 0.13.0 → 0.14.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.
@@ -0,0 +1,2 @@
1
+ /// <reference types="react" />
2
+ export declare const User: () => JSX.Element;
@@ -55,4 +55,5 @@ export declare const icons: {
55
55
  usdCircle: () => JSX.Element;
56
56
  questionCircle: () => JSX.Element;
57
57
  sync: () => JSX.Element;
58
+ user: () => JSX.Element;
58
59
  };
@@ -6,7 +6,7 @@ declare const alertTypes: Record<alertTypesOptions, {
6
6
  icon: IconProps['icon'];
7
7
  iconClass: string;
8
8
  }>;
9
- export declare const Alert: React.MemoExoticComponent<({ type, isOpen, title, subtitle, actions, showClose, onClose, hideIcon, }: AlertProps) => JSX.Element | null>;
9
+ export declare const Alert: React.MemoExoticComponent<({ type, isOpen, title, subtitle, actions, showClose, onClose, hideIcon, customIcon, }: AlertProps) => JSX.Element | null>;
10
10
  export interface AlertProps {
11
11
  /** Alert color
12
12
  * @default info
@@ -36,6 +36,10 @@ export interface AlertProps {
36
36
  * @default false
37
37
  */
38
38
  hideIcon?: boolean;
39
+ /**
40
+ * Custom icon
41
+ */
42
+ customIcon?: IconProps['icon'];
39
43
  /**
40
44
  * Action for the alert, like button and hiperlinks
41
45
  * */
@@ -537,6 +537,14 @@ var AngleWidth = function AngleWidth() {
537
537
  }));
538
538
  };
539
539
 
540
+ var User = function User() {
541
+ return React__default.createElement("path", {
542
+ fillRule: "evenodd",
543
+ d: "M10.707 0H7.293C5.803 0 4.644 1.295 4.809 2.776L5.253 6.776C5.394 8.042 6.464 9 7.737 9H10.263C11.536 9 12.606 8.042 12.747 6.776L13.191 2.776C13.356 1.295 12.196 0 10.707 0M10.707 1.5C11.096 1.5 11.341 1.709 11.452 1.833C11.563 1.958 11.743 2.224 11.701 2.61L11.256 6.61C11.2 7.118 10.772 7.5 10.263 7.5H7.737C7.228 7.5 6.8 7.118 6.743 6.61L6.299 2.61C6.256 2.224 6.436 1.958 6.548 1.833C6.659 1.709 6.904 1.5 7.293 1.5H10.707M14.012 11.5H3.988C1.658 11.5 0 13.228 0 15.807C0 17.578 0.783 18 2.02 18H15.979C17.43 18 18 17.152 18 15.807C18 13.231 16.342 11.5 14.012 11.5M14.012 13C14.716 13 15.367 13.285 15.846 13.801C16.324 14.318 16.504 14.84 16.504 15.692C16.504 16.158 16.384 16.5 15.979 16.5H2.02C1.723 16.5 1.496 16.267 1.496 15.692C1.496 14.974 1.675 14.318 2.154 13.801C2.633 13.285 3.284 13 3.988 13H14.012",
544
+ clipRule: "evenodd"
545
+ });
546
+ };
547
+
540
548
  var icons = {
541
549
  angleLeft: AngleLeft,
542
550
  angleRight: AngleRight,
@@ -592,7 +600,8 @@ var icons = {
592
600
  truck: Truck,
593
601
  usdCircle: UsdCircle,
594
602
  questionCircle: QuestionCircle,
595
- sync: Sync
603
+ sync: Sync,
604
+ user: User
596
605
  };
597
606
 
598
607
  var iconSizes = {
@@ -2314,7 +2323,8 @@ var AlertComponent = function AlertComponent(_ref) {
2314
2323
  showClose = _ref$showClose === void 0 ? false : _ref$showClose,
2315
2324
  onClose = _ref.onClose,
2316
2325
  _ref$hideIcon = _ref.hideIcon,
2317
- hideIcon = _ref$hideIcon === void 0 ? false : _ref$hideIcon;
2326
+ hideIcon = _ref$hideIcon === void 0 ? false : _ref$hideIcon,
2327
+ customIcon = _ref.customIcon;
2318
2328
 
2319
2329
  var _useState = React.useState(isOpen),
2320
2330
  alertIsOpen = _useState[0],
@@ -2335,7 +2345,7 @@ var AlertComponent = function AlertComponent(_ref) {
2335
2345
  }, !hideIcon && React__default.createElement("div", {
2336
2346
  className: "alert-icon hidden sm:block flex-shrink-0 mr-3 " + alertTypes[type].iconClass
2337
2347
  }, React__default.createElement(Icon, {
2338
- icon: alertTypes[type].icon,
2348
+ icon: customIcon ? customIcon : alertTypes[type].icon,
2339
2349
  size: 6
2340
2350
  })), React__default.createElement("div", {
2341
2351
  className: "flex-grow flex flex-col sm:flex-row items-start sm:items-center justify-between min-w-0"