norma-library 0.6.84 → 0.6.86

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.
Files changed (34) hide show
  1. package/dist/esm/components/Icons.js +6 -7
  2. package/dist/esm/components/Icons.js.map +1 -1
  3. package/dist/esm/components/ProductCard/ProductCard.js +13 -11
  4. package/dist/esm/components/ProductCard/ProductCard.js.map +1 -1
  5. package/dist/esm/components/ProductCard/ProductCard.style.js +2 -2
  6. package/dist/esm/components/ProductCard/ProductCard.style.js.map +1 -1
  7. package/dist/esm/components/ServiceCard/ServiceCard.js +6 -6
  8. package/dist/esm/components/ServiceCard/ServiceCard.js.map +1 -1
  9. package/dist/esm/components/ServiceCard/ServiceCard.style.js +1 -1
  10. package/dist/esm/components/ServiceCard/ServiceCard.style.js.map +1 -1
  11. package/dist/esm/components/Svgs.d.ts +12 -0
  12. package/dist/esm/components/Svgs.js +36 -0
  13. package/dist/esm/components/Svgs.js.map +1 -1
  14. package/dist/esm/interfaces/Icons.d.ts +4 -3
  15. package/dist/esm/interfaces/ProductCard.d.ts +15 -5
  16. package/dist/esm/interfaces/ServiceCard.d.ts +12 -4
  17. package/dist/esm/types/index.d.ts +3 -3
  18. package/dist/esm/types/index.js.map +1 -1
  19. package/package.json +2 -4
  20. package/src/components/Icons.tsx +12 -8
  21. package/src/components/ProductCard/ProductCard.style.ts +5 -2
  22. package/src/components/ProductCard/ProductCard.tsx +27 -27
  23. package/src/components/ServiceCard/ServiceCard.style.ts +0 -1
  24. package/src/components/ServiceCard/ServiceCard.tsx +6 -6
  25. package/src/components/Svgs.tsx +224 -2
  26. package/src/interfaces/Icons.ts +4 -3
  27. package/src/interfaces/ProductCard.ts +29 -20
  28. package/src/interfaces/ServiceCard.ts +19 -10
  29. package/src/stories/NormaChatMessageBalloon.stories.tsx +6 -6
  30. package/src/stories/ProductCard.stories.tsx +48 -3
  31. package/src/stories/ServiceCard.stories.tsx +30 -11
  32. package/src/types/index.ts +4 -3
  33. package/src/components/IconifyIcon.tsx +0 -23
  34. package/src/stories/IconifyIcon.stories.tsx +0 -31
@@ -5,22 +5,20 @@ import { IconCardStyle, ProductCardStyle, TitleContainer } from "./ProductCard.s
5
5
  import React from "react";
6
6
  import { IconButton } from "../IconButton";
7
7
  import GradeIcon from '@mui/icons-material/Grade'
8
- import { IconifyIcon } from "../IconifyIcon";
8
+ import { Icons } from '../Icons'
9
+ import { IconScale, IconType } from "../../types";
9
10
 
10
11
 
11
12
  export const ProductCard: React.FC<ProductCardProps> = ({
12
13
  // product = 'analytics'
13
14
  color,
14
- iconColor,
15
- iconSize,
15
+ icon,
16
16
  onClick,
17
17
  hasBorder = true,
18
18
  disabled = false,
19
19
  title,
20
20
  description,
21
- iconName,
22
- flaggable = false,
23
- flagged = false
21
+ favorite,
24
22
  }) => {
25
23
 
26
24
  /* const colors: { [key: string]: string } = {
@@ -31,38 +29,40 @@ export const ProductCard: React.FC<ProductCardProps> = ({
31
29
  }
32
30
  */
33
31
  return (
34
- <ProductCardStyle disabled={disabled} $bColor={iconColor} hasBorder={hasBorder}>
32
+ <ProductCardStyle disabled={disabled} $bColor={icon?.iconColor} hasBorder={hasBorder}>
35
33
  <Card
36
34
  variant="outlined"
37
35
  onClick={() => onClick && onClick()}
38
36
  >
39
- {flaggable && (
40
- <Grid container justifyContent={'flex-end'} alignItems={'flex-start'}>
41
- <Grid item>
42
- <IconButton
43
- sx={{ padding: 0 }}
44
- aria-label="favorite"
45
- onClick={(event) => {
46
- event.preventDefault()
47
- event.stopPropagation()
48
- }}
49
- color={flagged ? 'primary' : 'inherit'}
50
- cursor="pointer"
51
- >
52
- <GradeIcon />
53
- </IconButton>
54
- </Grid>
55
- </Grid>
37
+ {favorite?.flagged && (
38
+ <Grid container justifyContent={'flex-end'} alignItems={'flex-start'} position={'relative'}>
39
+ <Grid item>
40
+ <IconButton
41
+ sx={{
42
+ padding: 0,
43
+ position: 'absolute',
44
+ top: '10px',
45
+ right: '5px',
46
+ }}
47
+ aria-label="favorite"
48
+ onClick={favorite.onFlag}
49
+ color={favorite.flagged ? 'primary' : 'inherit'}
50
+ cursor="pointer"
51
+ >
52
+ <GradeIcon />
53
+ </IconButton>
54
+ </Grid>
55
+ </Grid>
56
56
  )}
57
57
 
58
58
  <TitleContainer>
59
59
  <IconCardStyle
60
- $iColor={iconColor}
60
+ $iColor={icon?.iconColor || ""}
61
61
  $bColor={color}
62
62
  >
63
- <IconifyIcon iconName={iconName} color={iconColor} size={iconSize || '2em'} />
63
+ <Icons icon={icon?.iconName as IconType} color={icon?.iconColor} scale={icon?.scale as IconScale} width={icon?.iconWidth} height={icon?.iconHeight} />
64
64
  </IconCardStyle>
65
- <p>{title}</p>
65
+ <p className="title">{title}</p>
66
66
  </TitleContainer>
67
67
 
68
68
  <p className="description">
@@ -31,7 +31,6 @@ export const IconCardStyle = styled.div<{ $bColor?: string; $iColor: string }>`
31
31
  box-sizing: border-box;
32
32
 
33
33
  svg {
34
- max-height: 24px;
35
34
 
36
35
  path.stroke {
37
36
  stroke: ${(props) => props.$iColor};
@@ -2,13 +2,13 @@ import React from "react";
2
2
  import { ServiceCardProps } from "../../interfaces/ServiceCard";
3
3
  import { IconCardStyle, ServiceCardStyle, TitleContainer } from "./ServiceCard.style";
4
4
  import { Card } from "../Card";
5
- import { IconifyIcon } from "../IconifyIcon";
5
+ import { Icons } from "../Icons";
6
+ import { IconType, IconScale } from "../../types";
6
7
 
7
- export const ServiceCard: React.FC<ServiceCardProps> = ({iconName, onClick, disabled = false, color, iconColor, iconSize, description, title }) => {
8
+ export const ServiceCard: React.FC<ServiceCardProps> = ({ icon, onClick, disabled = false, description, title}) => {
8
9
  return (
9
- <ServiceCardStyle disabled={disabled} $bColor={iconColor}>
10
+ <ServiceCardStyle disabled={disabled} $bColor={icon?.iconColor || ""}>
10
11
  <Card
11
- border={true}
12
12
  variant="outlined"
13
13
  onClick={() => {
14
14
  if (disabled) return;
@@ -16,8 +16,8 @@ export const ServiceCard: React.FC<ServiceCardProps> = ({iconName, onClick, disa
16
16
  }}
17
17
  >
18
18
  <TitleContainer>
19
- <IconCardStyle $iColor={iconColor || ""} $bColor={color || ""}>
20
- <IconifyIcon iconName={iconName || ""} color={iconColor} size={iconSize || "100%"}/>
19
+ <IconCardStyle $iColor={icon?.iconColor || ""} $bColor={icon?.bgColor || ""}>
20
+ <Icons icon={icon?.iconName as IconType} color={icon?.iconColor} scale={icon?.scale as IconScale} width={icon?.iconWidth} height={icon?.iconHeight} />
21
21
  </IconCardStyle>
22
22
  <div className="text">
23
23
  <p className="title">{title}</p>
@@ -498,9 +498,231 @@ export const iconsSVG = {
498
498
  warning: (
499
499
  <>
500
500
  <g id="warning">
501
- <path strokeWidth="0" d="M27.5 55C12.34 55 0 42.66 0 27.5S12.34 0 27.5 0 55 12.34 55 27.5 42.66 55 27.5 55Zm0-48.89c-11.79 0-21.39 9.6-21.39 21.39s9.6 21.39 21.39 21.39 21.39-9.6 21.39-21.39S39.29 6.11 27.5 6.11Z"/>
502
- <path strokeWidth="0" d="M27.5 29.89a3.06 3.06 0 0 1-3.06-3.06v-8.71a3.06 3.06 0 1 1 6.12 0v8.71a3.06 3.06 0 0 1-3.06 3.06ZM27.5 40.32c-.81 0-1.59-.33-2.16-.9-.57-.57-.9-1.34-.9-2.16s.33-1.59.9-2.16c1.12-1.14 3.18-1.14 4.32 0 .57.57.9 1.37.9 2.16s-.33 1.59-.9 2.16-1.37.9-2.16.9Z"/>
501
+ <path strokeWidth="0" d="M27.5 55C12.34 55 0 42.66 0 27.5S12.34 0 27.5 0 55 12.34 55 27.5 42.66 55 27.5 55Zm0-48.89c-11.79 0-21.39 9.6-21.39 21.39s9.6 21.39 21.39 21.39 21.39-9.6 21.39-21.39S39.29 6.11 27.5 6.11Z" />
502
+ <path strokeWidth="0" d="M27.5 29.89a3.06 3.06 0 0 1-3.06-3.06v-8.71a3.06 3.06 0 1 1 6.12 0v8.71a3.06 3.06 0 0 1-3.06 3.06ZM27.5 40.32c-.81 0-1.59-.33-2.16-.9-.57-.57-.9-1.34-.9-2.16s.33-1.59.9-2.16c1.12-1.14 3.18-1.14 4.32 0 .57.57.9 1.37.9 2.16s-.33 1.59-.9 2.16-1.37.9-2.16.9Z" />
503
503
  </g>
504
504
  </>
505
505
  ),
506
+ olosAcademy: (
507
+ <svg xmlns="http://www.w3.org/2000/svg" width="" height="" viewBox="0 0 32.902 19.741">
508
+ <path
509
+ id="Icon_awesome-graduation-cap"
510
+ data-name="Icon awesome-graduation-cap"
511
+ d="M31.994,9.086,17.654,4.68a4.107,4.107,0,0,0-2.405,0L.908,9.086a1.21,1.21,0,0,0,0,2.344l2.5.768a4.051,4.051,0,0,0-.919,2.411,1.586,1.586,0,0,0-.131,2.726L1.045,23.24a.822.822,0,0,0,.8,1H4.732a.823.823,0,0,0,.8-1L4.223,17.334a1.582,1.582,0,0,0-.093-2.7,2.425,2.425,0,0,1,1.064-1.888l10.054,3.089a4.111,4.111,0,0,0,2.405,0L31.994,11.43a1.211,1.211,0,0,0,0-2.344ZM18.137,17.408a5.755,5.755,0,0,1-3.372,0L7.31,15.118l-.729,5.833c0,1.817,4.419,3.29,9.871,3.29s9.871-1.473,9.871-3.29l-.729-5.833-7.456,2.291Z"
512
+ transform="translate(0 -4.5)"
513
+ />
514
+ </svg>
515
+ ),
516
+ olosFinancial: (
517
+ <svg xmlns="http://www.w3.org/2000/svg" width="" height="" viewBox="0 0 13.457 23.782">
518
+ <path
519
+ id="Icon_metro-money"
520
+ data-name="Icon metro-money"
521
+ d="M17.935,16.865c-3-.78-3.964-1.579-3.964-2.834,0-1.44,1.328-2.451,3.567-2.451,2.352,0,3.224,1.123,3.3,2.775h2.92A5.26,5.26,0,0,0,19.52,9.32V6.427H15.556V9.281c-2.563.562-4.624,2.213-4.624,4.77,0,3.052,2.53,4.571,6.21,5.457,3.31.793,3.964,1.949,3.964,3.191,0,.905-.641,2.358-3.567,2.358-2.722,0-3.8-1.222-3.937-2.775H10.688c.165,2.894,2.325,4.512,4.869,5.06v2.867H19.52V27.368c2.57-.5,4.624-1.982,4.624-4.7,0-3.739-3.211-5.021-6.21-5.807Z"
522
+ transform="translate(-10.688 -6.427)"
523
+ fill=""
524
+ />
525
+ </svg>
526
+ ),
527
+ olosSupport: (
528
+ <svg xmlns="http://www.w3.org/2000/svg" width="" height="" viewBox="0 0 27.599 27.599">
529
+ <g id="Icon_feather-help-circle" data-name="Icon feather-help-circle" transform="translate(-1.5 -1.5)">
530
+ <path
531
+ id="Caminho_2020"
532
+ data-name="Caminho 2020"
533
+ d="M27.6,15.3A12.3,12.3,0,1,1,15.3,3,12.3,12.3,0,0,1,27.6,15.3Z"
534
+ transform="translate(0 0)"
535
+ fill="none"
536
+ stroke=""
537
+ strokeLinecap="round"
538
+ strokeLinejoin="round"
539
+ strokeWidth="3"
540
+ />
541
+ <path
542
+ id="Caminho_2021"
543
+ data-name="Caminho 2021"
544
+ d="M13.635,12.959a3.69,3.69,0,0,1,7.171,1.23c0,2.46-3.69,3.69-3.69,3.69"
545
+ transform="translate(-1.915 -1.349)"
546
+ fill="none"
547
+ stroke=""
548
+ strokeLinecap="round"
549
+ strokeLinejoin="round"
550
+ strokeWidth="3"
551
+ />
552
+ <path
553
+ id="Caminho_2022"
554
+ data-name="Caminho 2022"
555
+ d="M18,25.5h0"
556
+ transform="translate(-2.701 -4.051)"
557
+ fill="none"
558
+ stroke=""
559
+ strokeLinecap="round"
560
+ strokeLinejoin="round"
561
+ strokeWidth="3"
562
+ />
563
+ </g>
564
+ </svg>
565
+ ),
566
+ olosSettings: (
567
+ <svg xmlns="http://www.w3.org/2000/svg" width="" height="" viewBox="0 0 23.536 23.536">
568
+ <g id="Icon_feather-settings" data-name="Icon feather-settings" transform="translate(-0.5 -0.5)">
569
+ <path
570
+ id="Caminho_2023"
571
+ data-name="Caminho 2023"
572
+ d="M19.373,16.437A2.937,2.937,0,1,1,16.437,13.5,2.937,2.937,0,0,1,19.373,16.437Z"
573
+ transform="translate(-4.169 -4.169)"
574
+ fill="none"
575
+ stroke=""
576
+ strokeLinecap="round"
577
+ strokeLinejoin="round"
578
+ strokeWidth="2"
579
+ />
580
+ <path
581
+ id="Caminho_2024"
582
+ data-name="Caminho 2024"
583
+ d="M19.512,15.2a1.615,1.615,0,0,0,.323,1.782l.059.059a1.959,1.959,0,1,1-2.77,2.77l-.059-.059A1.628,1.628,0,0,0,14.3,20.912v.166a1.958,1.958,0,1,1-3.916,0V20.99a1.615,1.615,0,0,0-1.057-1.478,1.615,1.615,0,0,0-1.782.323l-.059.059a1.959,1.959,0,1,1-2.77-2.77l.059-.059A1.628,1.628,0,0,0,3.624,14.3H3.458a1.958,1.958,0,1,1,0-3.916h.088A1.615,1.615,0,0,0,5.024,9.331,1.615,1.615,0,0,0,4.7,7.55l-.059-.059a1.959,1.959,0,1,1,2.77-2.77l.059.059A1.615,1.615,0,0,0,9.253,5.1h.078a1.615,1.615,0,0,0,.979-1.478V3.458a1.958,1.958,0,1,1,3.916,0v.088A1.628,1.628,0,0,0,16.986,4.7l.059-.059a1.959,1.959,0,1,1,2.77,2.77l-.059.059a1.615,1.615,0,0,0-.323,1.782v.078a1.615,1.615,0,0,0,1.478.979h.166a1.958,1.958,0,1,1,0,3.916H20.99a1.615,1.615,0,0,0-1.478.979Z"
584
+ transform="translate(0 0)"
585
+ fill="none"
586
+ stroke=""
587
+ strokeLinecap="round"
588
+ strokeLinejoin="round"
589
+ strokeWidth="2"
590
+ />
591
+ </g>
592
+ </svg>
593
+ ),
594
+ olosConsumption: (
595
+ <svg xmlns="http://www.w3.org/2000/svg" width="" height="" viewBox="0 0 31.138 23.47">
596
+ <path
597
+ id="Icon_feather-cloud"
598
+ data-name="Icon feather-cloud"
599
+ d="M23.232,13.67H21.621a10.227,10.227,0,1,0-9.9,12.784H23.232a6.392,6.392,0,1,0,0-12.784Z"
600
+ transform="translate(0.014 -4.485)"
601
+ fill="none"
602
+ stroke=""
603
+ strokeLinecap="round"
604
+ strokeLinejoin="round"
605
+ strokeWidth="3"
606
+ />
607
+ </svg>
608
+ ),
609
+ olosMarketing: (
610
+ <svg xmlns="http://www.w3.org/2000/svg" width="" height="" viewBox="0 0 24.76 22.856">
611
+ <path
612
+ id="Icon_ionic-md-business"
613
+ data-name="Icon ionic-md-business"
614
+ d="M16.053,9.577V4.5H3.375V27.356h24.76V9.577ZM8.446,24.814H5.911V22.273H8.446Zm0-5.077H5.911V17.2H8.446Zm0-5.077H5.911V12.119H8.446Zm0-5.083H5.911V7.036H8.446Zm5.071,15.237H10.982V22.273h2.536Zm0-5.077H10.982V17.2h2.536Zm0-5.077H10.982V12.119h2.536Zm0-5.083H10.982V7.036h2.536ZM25.6,24.814H16.053V22.273h2.536V19.737H16.053V17.2h2.536V14.654H16.053V12.119H25.6ZM23.362,14.66H20.826V17.2h2.536Zm0,5.077H20.826v2.541h2.536Z"
615
+ transform="translate(-3.375 -4.5)"
616
+ fill=""
617
+ />
618
+ </svg>
619
+ ),
620
+ olosDownload: (
621
+ <>
622
+ <svg xmlns="http://www.w3.org/2000/svg" width="" height="" viewBox="0 0 21.592 21.592">
623
+ <g id="Icon_feather-download" data-name="Icon feather-download" transform="translate(-3 -3)">
624
+ <path
625
+ id="Caminho_2025"
626
+ data-name="Caminho 2025"
627
+ d="M23.092,22.5v4.132A2.066,2.066,0,0,1,21.026,28.7H6.566A2.066,2.066,0,0,1,4.5,26.632V22.5"
628
+ transform="translate(0 -5.605)"
629
+ fill="none"
630
+ stroke=""
631
+ strokeLinecap="round"
632
+ strokeLinejoin="round"
633
+ strokeWidth="3"
634
+ />
635
+ <path
636
+ id="Caminho_2026"
637
+ data-name="Caminho 2026"
638
+ d="M10.5,15l5.165,5.165L20.829,15"
639
+ transform="translate(-1.868 -3.27)"
640
+ fill="none"
641
+ stroke=""
642
+ strokeLinecap="round"
643
+ strokeLinejoin="round"
644
+ strokeWidth="3"
645
+ />
646
+ <path
647
+ id="Caminho_2027"
648
+ data-name="Caminho 2027"
649
+ d="M18,16.895V4.5"
650
+ transform="translate(-4.204)"
651
+ fill="none"
652
+ stroke=""
653
+ strokeLinecap="round"
654
+ strokeLinejoin="round"
655
+ strokeWidth="3"
656
+ />
657
+ </g>
658
+ </svg>
659
+ </>
660
+ ),
661
+ olosPartners: (
662
+ <svg xmlns="http://www.w3.org/2000/svg" width="" height="" viewBox="0 0 27.924 16.76">
663
+ <path
664
+ id="Icon_awesome-handshake"
665
+ data-name="Icon awesome-handshake"
666
+ d="M18.966,4.5H15.218a1.4,1.4,0,0,0-.942.367L9.987,8.793s-.009.013-.013.017a1.736,1.736,0,0,0-.092,2.443,1.82,1.82,0,0,0,2.448.118s.013,0,.017-.009l3.486-3.194a.7.7,0,0,1,.942,1.03l-1.139,1.043L21.99,15.4a3.144,3.144,0,0,1,.345.336V7.292L19.952,4.91a1.386,1.386,0,0,0-.986-.41Zm4.769,2.8V17.07a1.4,1.4,0,0,0,1.4,1.4h2.792V7.3ZM25.83,17.07a.7.7,0,1,1,.7-.7A.7.7,0,0,1,25.83,17.07ZM0,18.462H2.792a1.4,1.4,0,0,0,1.4-1.4V7.3H0Zm2.094-2.788a.7.7,0,1,1-.7.7A.7.7,0,0,1,2.094,15.674Zm19.019.812L14.6,11.2,13.29,12.4A3.141,3.141,0,0,1,9.045,7.768L12.614,4.5H8.957a1.394,1.394,0,0,0-.986.41L5.585,7.292v9.769h.8l3.949,3.573a2.792,2.792,0,0,0,3.927-.406l.009-.009.781.676a1.621,1.621,0,0,0,2.282-.236l1.37-1.684.236.192a1.394,1.394,0,0,0,1.963-.205l.414-.51a1.4,1.4,0,0,0-.2-1.968Z"
667
+ transform="translate(0 -4.5)"
668
+ fill=""
669
+ />
670
+ </svg>
671
+ ),
672
+ olosAnalytics: (
673
+ <svg xmlns="http://www.w3.org/2000/svg" width="" height="" viewBox="0 0 29.538 24">
674
+ <path
675
+ id="Icon_metro-chart-bars"
676
+ data-name="Icon metro-chart-bars"
677
+ d="M2.571,26.092H32.109v3.692H2.571Zm3.692-7.385H9.955v5.538H6.263ZM11.8,11.323h3.692V24.246H11.8Zm5.538,5.538h3.692v7.385H17.34ZM22.878,5.784h3.692V24.246H22.878Z"
678
+ transform="translate(-2.571 -5.784)"
679
+ fill=""
680
+ />
681
+ </svg>
682
+ ),
683
+ olosJourneyX: (
684
+ <>
685
+ <svg xmlns="http://www.w3.org/2000/svg" width="26.052" height="22.796" viewBox="0 0 26.052 22.796">
686
+ <path
687
+ id="Icon_metro-table"
688
+ data-name="Icon metro-table"
689
+ d="M2.571,3.856v22.8H28.623V3.856H2.571Zm9.77,14.654V13.626h6.513v4.885Zm6.513,1.628v4.885H12.34V20.139Zm0-13.026V12H12.34V7.113h6.513Zm-8.141,0V12H4.2V7.113h6.513ZM4.2,13.626h6.513v4.885H4.2V13.626Zm16.283,0h6.513v4.885H20.482V13.626Zm0-1.628V7.113h6.513V12ZM4.2,20.139h6.513v4.885H4.2V20.139Zm16.283,4.885V20.139h6.513v4.885Z"
690
+ transform="translate(-2.571 -3.856)"
691
+ fill=""
692
+ />
693
+ </svg>
694
+ </>
695
+ ),
696
+ olosAnywhere: (
697
+ <svg xmlns="http://www.w3.org/2000/svg" width="" height="" viewBox="0 0 21.917 30.298">
698
+ <g id="Grupo_2083" data-name="Grupo 2083" transform="translate(-3.363 -1.039)">
699
+ <path
700
+ id="Icon_material-phonelink-erase"
701
+ data-name="Icon material-phonelink-erase"
702
+ d="M27.026,1.5H13.254A2.762,2.762,0,0,0,10.5,4.254V8.386h2.754V5.631H27.026V27.666H13.254V24.912H10.5v4.131A2.762,2.762,0,0,0,13.254,31.8H27.026a2.762,2.762,0,0,0,2.754-2.754V4.254A2.762,2.762,0,0,0,27.026,1.5Z"
703
+ transform="translate(-4.5 -0.461)"
704
+ fill=""
705
+ />
706
+ <path
707
+ id="Icon_awesome-map-marker-alt"
708
+ data-name="Icon awesome-map-marker-alt"
709
+ d="M3.828,11.147C.6,6.467,0,5.986,0,4.266a4.266,4.266,0,0,1,8.532,0c0,1.72-.6,2.2-3.828,6.881a.533.533,0,0,1-.877,0Zm.438-5.1A1.778,1.778,0,1,0,2.489,4.266,1.778,1.778,0,0,0,4.266,6.044Z"
710
+ transform="translate(3.363 10.5)"
711
+ fill=""
712
+ />
713
+ </g>
714
+ </svg>
715
+ ),
716
+ olosVm5: (
717
+ <svg xmlns="http://www.w3.org/2000/svg" width="" height="" viewBox="0 0 27.95 24.456">
718
+ <path
719
+ id="Icon_awesome-headphones-alt"
720
+ data-name="Icon awesome-headphones-alt"
721
+ d="M8.734,16.225H7.861a3.5,3.5,0,0,0-3.494,3.5v3.481a3.5,3.5,0,0,0,3.494,3.5h.873a1.749,1.749,0,0,0,1.747-1.75V17.975A1.748,1.748,0,0,0,8.734,16.225Zm11.355,0h-.873a1.748,1.748,0,0,0-1.747,1.75v6.981a1.749,1.749,0,0,0,1.747,1.75h.873a3.5,3.5,0,0,0,3.494-3.5V19.725a3.5,3.5,0,0,0-3.494-3.5ZM13.975,2.25C6.164,2.25.249,8.753,0,16.225v6.114a.873.873,0,0,0,.873.873h.873a.873.873,0,0,0,.873-.873V16.225a11.355,11.355,0,0,1,22.709,0v6.114a.873.873,0,0,0,.873.873h.873a.873.873,0,0,0,.873-.873V16.225C27.7,8.753,21.786,2.25,13.975,2.25Z"
722
+ transform="translate(0 -2.25)"
723
+ fill=""
724
+ />
725
+ </svg>
726
+ )
727
+
506
728
  } as const;
@@ -1,15 +1,16 @@
1
1
  import { ComponentProps } from 'react';
2
2
  import { IconScale, IconColors, IconType } from '../types';
3
3
  import { Svg } from '../components/Icons';
4
+ import { SvgIconComponent } from '@mui/icons-material';
4
5
 
5
6
  export interface IconsProps extends ComponentProps<typeof Svg> {
6
7
  useSymbol?: boolean;
7
8
  scale?: IconScale;
8
9
  color?: IconColors;
9
- width?: number;
10
- height?: number;
10
+ width?: number | string;
11
+ height?: number | string;
11
12
  fill?: string;
12
- icon: IconType;
13
+ icon: SvgIconComponent | IconType;
13
14
  }
14
15
 
15
16
  export interface SvgProps {
@@ -1,25 +1,34 @@
1
+ import { iconsSVG } from '../components/Svgs'
2
+ import { IconScale } from '../types'
3
+ import { SvgIconComponent } from '@mui/icons-material'
1
4
  import { ReactNode } from 'react'
2
5
 
3
6
  export interface ProductCardProps {
4
- // product?: string
5
- onClick?: () => void
6
- disabled?: boolean
7
- color: string
8
- iconColor: string
9
- iconSize: string
10
- iconName: string
11
- title: string
12
- description: string
13
- hasBorder?: boolean
14
- flaggable?: boolean
15
- flagged?: boolean
7
+ // product?: string
8
+ onClick?: () => void
9
+ disabled?: boolean
10
+ color: string
11
+ title: string
12
+ description: string
13
+ hasBorder?: boolean
14
+ favorite?: {
15
+ flagged: boolean
16
+ onFlag: () => any
16
17
  }
17
-
18
-
18
+ icon?: {
19
+ bgColor?: string;
20
+ iconColor?: string;
21
+ iconName?: keyof typeof iconsSVG | SvgIconComponent;
22
+ iconWidth?: string | number;
23
+ iconHeight?: string | number;
24
+ scale?: IconScale;
25
+ }
26
+ }
27
+
28
+
19
29
  export interface BgIconProps {
20
- $bColor: string
21
- children?: ReactNode
22
- className?: string
23
- color: string
24
- }
25
-
30
+ $bColor: string
31
+ children?: ReactNode
32
+ className?: string
33
+ color: string
34
+ }
@@ -1,12 +1,21 @@
1
+ import { SvgIconComponent } from "@mui/icons-material";
2
+ import { iconsSVG } from "../components/Svgs";
3
+ import { IconColors, IconScale } from "../types";
4
+
1
5
  export interface ServiceCardProps {
2
- // service: string;
3
- title?: string;
4
- description: string;
5
- onClick?: () => void;
6
- disabled?: boolean;
7
- color?: string;
6
+ // service: string;
7
+ title?: string;
8
+ description: string;
9
+ onClick?: () => void;
10
+ disabled?: boolean;
11
+ icon?: {
12
+ bgColor?: string;
8
13
  iconColor?: string;
9
- iconName?: string;
10
- borderColor?: string;
11
- iconSize?: string;
12
- }
14
+ iconName?: keyof typeof iconsSVG | SvgIconComponent;
15
+ iconWidth?: string | number;
16
+ iconHeight?: string | number;
17
+ scale?: IconScale;
18
+ }
19
+ borderColor?: string;
20
+ color?: IconColors | string;
21
+ }
@@ -1,9 +1,9 @@
1
1
  import React from 'react';
2
2
  import type { Meta } from '@storybook/react';
3
- import { IconButton, NormaChatMessageBalloon } from '../components';
3
+ import { IconButton, Icons, NormaChatMessageBalloon } from '../components';
4
4
  import { useChatMessageBalloon } from '../components/NormaChatMessageBalloon/hook';
5
5
  import { Avatar, Box, Typography } from '@mui/material';
6
- import { IconifyIcon } from '../components/IconifyIcon';
6
+ import { SentimentDissatisfiedOutlined, TagFacesOutlined } from '@mui/icons-material';
7
7
 
8
8
  const messageArr = [
9
9
  {
@@ -153,10 +153,10 @@ const TemplateWithChildren = () => {
153
153
  {/* Children located here */}
154
154
  <NormaChatMessageBalloon.Row direction={message.direction}>
155
155
  <IconButton>
156
- <IconifyIcon iconName="bx:bx-smile" size='2rem' color='#E18B50' />
156
+ <Icons icon={TagFacesOutlined} scale='medium' color='black' />
157
157
  </IconButton>
158
158
  <IconButton>
159
- <IconifyIcon iconName="uil:atom" size='2rem' color='#E18B50' />
159
+ <Icons icon={SentimentDissatisfiedOutlined} scale='medium' color='black' />
160
160
  </IconButton>
161
161
  <p>...children</p>
162
162
  </NormaChatMessageBalloon.Row>
@@ -194,10 +194,10 @@ const SimplifiedTemplate = () => {
194
194
  children={
195
195
  <>
196
196
  <IconButton>
197
- <IconifyIcon iconName="bx:bx-smile" size='2rem' color='#E18B50' />
197
+ <Icons icon={TagFacesOutlined} scale='medium' color='black' />
198
198
  </IconButton>
199
199
  <IconButton>
200
- <IconifyIcon iconName="uil:atom" size='2rem' color='#E18B50' />
200
+ <Icons icon={TagFacesOutlined} scale='medium' color='primary' />
201
201
  </IconButton>
202
202
  <p>...children</p>
203
203
  </>
@@ -14,9 +14,54 @@ const meta = {
14
14
 
15
15
  export default meta;
16
16
 
17
- export const BasicProductCard = () => <ProductCard flaggable title="Financeiro e Jurídico" description="Novas possibilidades de análise de desempenho operacional, elasticidade e segurança." iconColor="#247010" color="#F3FCEA" iconName="lucide:briefcase-medical" />;
17
+ export const BasicProductCard = () => <ProductCard flaggable title="Financeiro e Jurídico" description="Novas possibilidades de análise de desempenho operacional, elasticidade e segurança." color="#FDF6E3"
18
+ icon={{
19
+ iconName: 'olosAnalytics',
20
+ iconColor: "#B16E4B",
21
+ bgColor: "#F6F07F",
22
+ scale: "medium",
23
+ iconWidth: "36px",
24
+ iconHeight: "36px"
25
+ }}
26
+ />;
18
27
  BasicProductCard.storyName = 'Basic Product Card';
19
28
 
20
- export const DisabledProductCard = () => <ProductCard title="Suporte" description="Novo mundo de possibilidades em jornada omnicanal, design de Data Lake, Data Blocks e Segurança." iconColor="#6a491d" color="#FDF6E3" iconName="lucide:bookmark" disabled />;
29
+ export const DisabledProductCard = () => <ProductCard flaggable title="Financeiro e Jurídico" description="Novas possibilidades de análise de desempenho operacional, elasticidade e segurança." color="#FDF6E3"
30
+ icon={{
31
+ iconName: 'olosCloud',
32
+ iconColor: "#B16E4B",
33
+ bgColor: "#F6F07F",
34
+ scale: "medium",
35
+ iconWidth: "36px",
36
+ iconHeight: "36px"
37
+ }}
38
+ disabled
39
+ />;
40
+ DisabledProductCard.storyName = 'Disabled Product Card';
41
+
42
+ export const FlaggedProductCard = () => <ProductCard flaggable flagged title="Financeiro e Jurídico" description="Novas possibilidades de análise de desempenho operacional, elasticidade e segurança." color="#FDF6E3"
43
+ icon={{
44
+ iconName: 'olosAnywhere',
45
+ iconColor: "#B16E4B",
46
+ bgColor: "#F6F07F",
47
+ scale: "medium",
48
+ iconWidth: "36px",
49
+ iconHeight: "36px"
50
+ }}
51
+ />;
52
+
53
+ FlaggedProductCard.storyName = 'Flagged Product Card';
54
+
55
+ export const NoBorderProductCard = () => <ProductCard flaggable title="Financeiro e Jurídico" description="Novas possibilidades de análise de desempenho operacional, elasticidade e segurança." color="#FDF6E3"
56
+ icon={{
57
+ iconName: 'olosAnalytics',
58
+ iconColor: "#B16E4B",
59
+ bgColor: "#F6F07F",
60
+ scale: "medium",
61
+ iconWidth: "36px",
62
+ iconHeight: "36px"
63
+ }}
64
+ hasBorder={false}
65
+ />;
66
+ NoBorderProductCard.storyName = 'No Border Product Card';
21
67
 
22
- export const NoBorderProductCard = () => <ProductCard flaggable title="Teste" description="Lorem ipsum dolor sit amet, consectetur adipiscing elit. Morbi eleifend, ex sit amet sagittis interdum, est ante placerat velit, sed consectetur arcu sem id nisi. Integer vitae mauris et lectus vulputate maximus" iconColor="#6a491d" color="#FDF6E3" iconName="lucide:user" hasBorder={false} />;
@@ -1,20 +1,39 @@
1
1
  import { Meta } from "@storybook/react";
2
- import {ServiceCard} from "../components/ServiceCard/ServiceCard";
2
+ import { ServiceCard } from "../components/ServiceCard/ServiceCard";
3
3
  import React from "react";
4
+ import { Home } from "@mui/icons-material";
4
5
 
5
6
  const meta = {
6
- title: 'Layout/ServiceCard',
7
- component: ServiceCard,
8
- parameters: {
9
- layout: 'centered',
10
- },
11
- tags: ['autodocs'],
12
- argTypes: {},
13
- } satisfies Meta<typeof ServiceCard>;
7
+ title: 'Layout/ServiceCard',
8
+ component: ServiceCard,
9
+ parameters: {
10
+ layout: 'centered',
11
+ },
12
+ tags: ['autodocs'],
13
+ argTypes: {},
14
+ } satisfies Meta<typeof ServiceCard>;
14
15
 
15
16
  export default meta;
16
17
 
17
- export const BasicServiceCard = () => <ServiceCard title="Financeiro e Jurídico" description="Dados financeiros e legais sobre seus produtos." iconName="ic:baseline-account-balance" iconColor="#247010" color="#F3FCEA"/>;
18
+ export const BasicServiceCard = () => <ServiceCard title="Financeiro e Jurídico" description="Dados financeiros e legais sobre seus produtos." icon={
19
+ {
20
+ iconName: Home,
21
+ bgColor: "#F6F07F",
22
+ iconColor: "#B16E4B",
23
+ scale: "medium",
24
+ iconWidth: "36px",
25
+ iconHeight: "36px"
26
+ }
27
+ } />;
18
28
  BasicServiceCard.storyName = 'Basic Service Card';
19
29
 
20
- export const DisabledServiceCard = () => <ServiceCard title="Suporte" description="Suporte técnico para seus produtos." iconColor="#6a491d" iconName="ic:baseline-add-photo-alternate" color="#FDF6E3" disabled/>;
30
+ export const DisabledServiceCard = () => <ServiceCard title="Financeiro e Jurídico" description="Dados financeiros e legais sobre seus produtos." icon={
31
+ {
32
+ iconName: 'olosFinancial',
33
+ bgColor: "#F6F07F",
34
+ iconColor: "#B16E4B",
35
+ scale: "medium",
36
+ iconWidth: "36px",
37
+ iconHeight: "36px"
38
+ }
39
+ } disabled />;
@@ -120,7 +120,7 @@ export type MuiBadgeBaseProps = Omit<
120
120
  'sx' | 'color' | 'children' | 'invisible' | 'variant' | 'className' | 'badgeContent'
121
121
  >;
122
122
 
123
- export type IconScale = 'xsmall' | 'small' | 'medium' | 'large' | 'xlarge' | '2xlarge' | '3xlarge';
123
+ export type IconScale = 'xsmall' | 'small' | 'medium' | 'large' | 'xlarge' | '2xlarge' | '3xlarge' | 'custom';
124
124
 
125
125
  export type IconColors =
126
126
  | 'inherit'
@@ -131,9 +131,10 @@ export type IconColors =
131
131
  | 'success'
132
132
  | 'warning'
133
133
  | 'white'
134
- | 'black';
134
+ | 'black'
135
+ | string;
135
136
 
136
- export const scaleSize: Record<IconScale, number> = {
137
+ export const scaleSize: Partial<Record<IconScale, number>> = {
137
138
  xsmall: 14,
138
139
  small: 20,
139
140
  medium: 24,