@platformatic/ui-components 0.1.53 → 0.1.55

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 (51) hide show
  1. package/package.json +1 -1
  2. package/renovate.json +6 -0
  3. package/src/components/Modal.jsx +1 -1
  4. package/src/components/Sidebar.jsx +12 -5
  5. package/src/components/Sidebar.module.css +1 -1
  6. package/src/components/SimpleMetric.jsx +1 -1
  7. package/src/components/forms/Preview.jsx +1 -1
  8. package/src/components/icons/AlertIcon.jsx +1 -1
  9. package/src/components/icons/ApiEmptyIcon.jsx +140 -106
  10. package/src/components/icons/ApiIconClosed.jsx +51 -18
  11. package/src/components/icons/AppEmptyIcon.jsx +126 -93
  12. package/src/components/icons/AppListIcon.jsx +101 -71
  13. package/src/components/icons/BellIcon.jsx +78 -0
  14. package/src/components/icons/BillingIcon.jsx +98 -0
  15. package/src/components/icons/CircleArrowLeftIcon.jsx +95 -0
  16. package/src/components/icons/CircleArrowRightIcon.jsx +98 -0
  17. package/src/components/icons/CircleCheckMarkIcon.jsx +41 -29
  18. package/src/components/icons/CircleCloseHoverIcon.jsx +62 -36
  19. package/src/components/icons/CircleCloseIcon.jsx +52 -26
  20. package/src/components/icons/CircleExclamationIcon.jsx +87 -24
  21. package/src/components/icons/CircleTwoArrowsDownIcon.jsx +84 -0
  22. package/src/components/icons/CircleTwoArrowsUpIcon.jsx +87 -0
  23. package/src/components/icons/EnlargeIcon.jsx +85 -0
  24. package/src/components/icons/EntryIcon.jsx +82 -0
  25. package/src/components/icons/ExploreDocIcon.jsx +95 -0
  26. package/src/components/icons/GearIcon.jsx +2 -2
  27. package/src/components/icons/GraphQLIcon.jsx +98 -0
  28. package/src/components/icons/Icons.module.css +6 -0
  29. package/src/components/icons/KeyIcon.jsx +85 -0
  30. package/src/components/icons/LayersIcon.jsx +81 -0
  31. package/src/components/icons/LensIcon.jsx +79 -0
  32. package/src/components/icons/LiveIcon.jsx +60 -18
  33. package/src/components/icons/LogOutIcon.jsx +81 -0
  34. package/src/components/icons/MetricsIcon.jsx +80 -47
  35. package/src/components/icons/PlayIcon.jsx +57 -2
  36. package/src/components/icons/PullRequestIcon.jsx +87 -30
  37. package/src/components/icons/SendIcon.jsx +75 -0
  38. package/src/components/icons/SocialDiscordIcon.jsx +79 -0
  39. package/src/components/icons/SocialGitHubIcon.jsx +98 -0
  40. package/src/components/icons/SocialGitLabIcon.jsx +122 -0
  41. package/src/components/icons/SocialLinkedInIcon.jsx +85 -0
  42. package/src/components/icons/SocialNPMIcon.jsx +77 -0
  43. package/src/components/icons/SocialTwitterIcon.jsx +77 -0
  44. package/src/components/icons/StopIcon.jsx +59 -2
  45. package/src/components/icons/TerminalIcon.jsx +62 -2
  46. package/src/components/icons/{Users2Icon.jsx → TwoUsersIcon.jsx} +4 -4
  47. package/src/components/icons/UpgradeIcon.jsx +70 -1
  48. package/src/components/icons/WorkspaceFailIcon.jsx +112 -0
  49. package/src/components/icons/index.js +47 -5
  50. package/src/stories/PlatformaticIcon.stories.jsx +58 -26
  51. package/src/components/icons/CircleBackIcon.jsx +0 -51
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@platformatic/ui-components",
3
3
  "description": "Platformatic UI Components",
4
- "version": "0.1.53",
4
+ "version": "0.1.55",
5
5
  "type": "module",
6
6
  "license": "Apache-2.0",
7
7
  "repository": {
package/renovate.json ADDED
@@ -0,0 +1,6 @@
1
+ {
2
+ "$schema": "https://docs.renovatebot.com/renovate-schema.json",
3
+ "extends": [
4
+ "config:base"
5
+ ]
6
+ }
@@ -47,7 +47,7 @@ export default function Modal (props) {
47
47
  onMouseEnter={() => setIsHoverCloseModal(true)}
48
48
  onMouseLeave={() => setIsHoverCloseModal(false)}
49
49
  >
50
- {isHoverCloseModal ? <CircleCloseHoverIcon /> : <CircleCloseIcon />}
50
+ {isHoverCloseModal ? <CircleCloseHoverIcon color='green' /> : <CircleCloseIcon color='green' />}
51
51
  </div>
52
52
  </div>
53
53
  <p className={styles.titleInvite}>{title}</p>
@@ -29,8 +29,15 @@ function Sidebar (props) {
29
29
  {collapsed
30
30
  ? (
31
31
  <>
32
+ <button type='button' className={styles.buttonCollapse} onClick={() => { setCollapsed(false) }}>
33
+ <PlatformaticIcon
34
+ iconName='CircleArrowRightIcon'
35
+ color='white'
36
+ size='medium'
37
+ />
38
+ </button>
32
39
  <button type='button' className={styles.buttonExpand} onClick={() => { setCollapsed(false) }}>
33
- <Icons.WorkspaceStaticIcon color='white' />
40
+ <Icons.WorkspaceStaticIcon color='white' size='large' />
34
41
  </button>
35
42
  <div className={styles.titleCollapsed} data-testid='lateral-bar-title'>
36
43
  {title}
@@ -38,7 +45,7 @@ function Sidebar (props) {
38
45
  <HorizontalSeparator marginBottom={2} marginTop={2} />
39
46
  <div className={styles.bottom}>
40
47
  <button type='button' className={styles.buttonSettings} onClick={onClickSettings}>
41
- <Icons.GearIcon color='white' />
48
+ <Icons.GearIcon color='white' size='large' />
42
49
  </button>
43
50
  </div>
44
51
  </>
@@ -47,9 +54,9 @@ function Sidebar (props) {
47
54
  <>
48
55
  <button type='button' className={styles.buttonCollapse} onClick={() => { setCollapsed(true) }}>
49
56
  <PlatformaticIcon
50
- iconName='CircleBackIcon'
57
+ iconName='CircleArrowLeftIcon'
51
58
  color='white'
52
- size='normal'
59
+ size='medium'
53
60
  />
54
61
  </button>
55
62
  <div className={styles.title} data-testid='lateral-bar-title'>
@@ -65,7 +72,7 @@ function Sidebar (props) {
65
72
  iconName={item.iconName}
66
73
  color={isSelected ? 'green' : 'white'}
67
74
  tip={item.title}
68
- size='normal'
75
+ size='medium'
69
76
  />)}
70
77
  <div className={`${styles.item} ${isSelected ? styles.itemSelected : ''}`}>
71
78
  <span className={styles.itemSubTitle}>{item.subTitle}</span>
@@ -6,7 +6,7 @@
6
6
  @apply max-w-[96px] text-center;
7
7
  }
8
8
  .buttonExpand {
9
- @apply border rounded-md p-0 border-white;
9
+ @apply border rounded-md p-1 border-white;
10
10
  }
11
11
  .buttonSettings {
12
12
  @apply border rounded-md p-1 border-white;
@@ -15,7 +15,7 @@ export default function SimpleMetric ({ title, pre, color, unit, value, tooltip,
15
15
  <BorderedBox>
16
16
  <div className={styles.header}>
17
17
  <span className={styles.title}>{title}</span>
18
- <Icons.CircleExclamationIcon tip={tooltip} />
18
+ <Icons.CircleExclamationIcon tip={tooltip} size='medium' color='white' />
19
19
  </div>
20
20
  <div>
21
21
  <MetricValue pre={pre} color={color} unit={unit} value={value} />
@@ -12,7 +12,7 @@ function renderParagraph (value, afterValueIcon, afterValueIconColor, onClickAft
12
12
  <>
13
13
  <p className={styles.value}>
14
14
  {value}
15
- {afterValueIcon && (<PlatformaticIcon iconName={afterValueIcon} color={afterValueIconColor} size='normal' classes={styles.afterIcon} onClick={() => onClickAfterValueIcon} />)}
15
+ {afterValueIcon && (<PlatformaticIcon iconName={afterValueIcon} color={afterValueIconColor} size='medium' classes={styles.afterIcon} onClick={() => onClickAfterValueIcon} />)}
16
16
  </p>
17
17
  </>
18
18
  )
@@ -19,7 +19,7 @@ const AlertIcon = ({ color, size }) => {
19
19
  >
20
20
  <path d='M14 14H2L8 2L14 14Z' stroke='none' strokeLinejoin='round' />
21
21
  <path d='M8 6V10.5' stroke='none' strokeLinecap='round' strokeLinejoin='round' />
22
- <circle cx='8' cy='12' r='0.5' fill='none' />
22
+ <circle cx={8} cy={12} r='0.5' fill='none' />
23
23
  </svg>
24
24
  )
25
25
  break
@@ -1,107 +1,141 @@
1
- import React from 'react'
2
- export default function ApiEmptyIcon () {
3
- return (
4
- <svg
5
- width={80}
6
- height={80}
7
- viewBox='0 0 80 80'
8
- fill='none'
9
- xmlns='http://www.w3.org/2000/svg'
10
- >
11
- <path
12
- d='M38.2726 3.83337V5.48055C38.2726 5.79404 38.4831 6.07727 38.8003 6.18727L41.0653 6.98199C41.3737 7.08923 41.7235 7.01498 41.9488 6.78949L43.0369 5.70604C43.3571 5.38705 43.9026 5.3843 44.2257 5.70329L46.8525 8.28268C47.146 8.57142 47.1489 9.01965 46.8613 9.31114L45.462 10.7356C45.2397 10.9611 45.1863 11.2883 45.3256 11.5633L46.2743 13.4607C46.4077 13.7275 46.6983 13.9007 47.0155 13.9007H48.4682C48.9189 13.9007 49.2835 14.2389 49.2835 14.6569V17.8413C49.2835 18.2593 48.9189 18.5975 48.4682 18.5975H46.9414C46.5886 18.5975 46.2743 18.8092 46.1646 19.12L45.3938 21.3116C45.3019 21.5701 45.3671 21.8534 45.5658 22.0541L46.8198 23.3383C47.1252 23.6518 47.0956 24.1385 46.7517 24.4163L43.8611 26.7619C43.529 27.0314 43.025 27.0067 42.7256 26.7069L41.7176 25.7005C41.4982 25.4805 41.1573 25.4007 40.8519 25.4997L38.7469 26.1817C38.4179 26.2889 38.1985 26.5749 38.1985 26.8967V28.3953C38.1985 28.8133 37.8338 29.1516 37.3832 29.1516H33.5409C33.0903 29.1516 32.7256 28.8133 32.7256 28.3953V26.8967C32.7256 26.5749 32.5062 26.2889 32.1772 26.1817L30.0722 25.4997C29.7668 25.4007 29.4259 25.4777 29.2065 25.7005L28.1985 26.7069C27.8991 27.0067 27.3951 27.0314 27.063 26.7619L24.1724 24.4163C23.8285 24.1385 23.7989 23.6518 24.1043 23.3383L25.3583 22.0541C25.554 21.8534 25.6192 21.5701 25.5303 21.3116L24.7595 19.12C24.6498 18.8092 24.3355 18.5975 23.9827 18.5975H22.4588C22.0082 18.5975 21.6436 18.2593 21.6436 17.8413V14.6569C21.6436 14.2389 22.0082 13.9007 22.4588 13.9007H23.9116C24.2288 13.9007 24.5193 13.7302 24.6527 13.4607L25.6014 11.5633C25.7408 11.2856 25.6844 10.9611 25.4651 10.7356L24.0657 9.31114C23.7781 9.01965 23.7811 8.56867 24.0746 8.28268L26.7013 5.70329C27.0245 5.38705 27.57 5.38705 27.8902 5.70604L28.9782 6.78949C29.2036 7.01498 29.5534 7.08923 29.8617 6.98199L32.1268 6.18727C32.444 6.07727 32.6545 5.79404 32.6545 5.48055V3.83337C32.6545 3.41538 33.0191 3.07715 33.4698 3.07715H37.4573C37.9079 3.07715 38.2726 3.41538 38.2726 3.83337Z'
13
- stroke='#21FA90'
14
- strokeWidth={3}
15
- strokeLinecap='round'
16
- strokeLinejoin='round'
17
- />
18
- <path
19
- d='M30.8564 20.46L40.0698 11.7686'
20
- stroke='#21FA90'
21
- strokeWidth={3}
22
- strokeLinecap='round'
23
- strokeLinejoin='round'
24
- />
25
- <path
26
- d='M40.0698 20.46L30.8564 11.7685'
27
- stroke='#21FA90'
28
- strokeWidth={3}
29
- strokeLinecap='round'
30
- strokeLinejoin='round'
31
- />
32
- <path
33
- d='M23.9482 48.0268L30.2728 33.98H33.5161L39.861 48.0268H36.4149L31.2255 35.6255H32.5229L27.3132 48.0268H23.9482ZM27.1105 45.0168L27.9822 42.5485H35.2797L36.1716 45.0168H27.1105Z'
34
- fill='#21FA90'
35
- />
36
- <path
37
- d='M41.3331 48.0268V33.98H47.4752C48.7455 33.98 49.8402 34.1873 50.7591 34.6021C51.6781 35.0034 52.3876 35.5853 52.8876 36.3479C53.3876 37.1104 53.6376 38.0201 53.6376 39.077C53.6376 40.1204 53.3876 41.0235 52.8876 41.786C52.3876 42.5485 51.6781 43.1372 50.7591 43.5519C49.8402 43.9532 48.7455 44.1539 47.4752 44.1539H43.1575L44.617 42.689V48.0268H41.3331ZM44.617 43.0502L43.1575 41.5051H47.2928C48.3063 41.5051 49.0631 41.291 49.5631 40.8629C50.0632 40.4348 50.3132 39.8395 50.3132 39.077C50.3132 38.3011 50.0632 37.699 49.5631 37.271C49.0631 36.8429 48.3063 36.6288 47.2928 36.6288H43.1575L44.617 35.0837V43.0502Z'
38
- fill='#21FA90'
39
- />
40
- <path d='M55.9821 48.0268V33.98H59.266V48.0268H55.9821Z' fill='#21FA90' />
41
- <path
42
- d='M68.3785 43.6372V43.6268M68.3785 43.6268C73.1364 43.4008 76.9245 39.4861 76.9245 34.6885C76.9245 29.7447 72.9027 25.7397 67.946 25.7397C67.8169 25.7397 67.6878 25.7432 67.5588 25.7501C65.5008 21.9502 61.4719 19.3706 56.8361 19.3706C55.6286 19.3706 54.4639 19.5464 53.3639 19.8731M68.3785 43.6268H63.1045M23.1801 43.6372H18.1488V43.6302C11.5702 43.4634 6.28906 38.2068 6.28906 31.5039C6.28906 26.0102 9.95151 21.3689 14.9756 19.8731'
43
- stroke='#21FA90'
44
- strokeWidth={3}
45
- strokeMiterlimit={10}
46
- strokeLinecap='round'
47
- strokeLinejoin='round'
48
- />
49
- <path
50
- d='M22.3412 51.2373V67.8962C22.3412 68.4485 21.8935 68.8962 21.3412 68.8962H14.3145'
51
- stroke='#21FA90'
52
- strokeWidth={3}
53
- strokeLinecap='round'
54
- strokeLinejoin='round'
55
- />
56
- <path
57
- d='M60.8682 51.2373V58.2641C60.8682 58.8163 61.3159 59.2641 61.8682 59.2641H67.2896'
58
- stroke='#21FA90'
59
- strokeWidth={3}
60
- strokeLinecap='round'
61
- strokeLinejoin='round'
62
- />
63
- <path
64
- d='M35.1836 54.4478V67.2906'
65
- stroke='#21FA90'
66
- strokeWidth={3}
67
- strokeLinecap='round'
68
- strokeLinejoin='round'
69
- />
70
- <path
71
- d='M48.0254 54.4478V71.1066C48.0254 71.6589 48.4731 72.1066 49.0254 72.1066H56.0521'
72
- stroke='#21FA90'
73
- strokeWidth={3}
74
- strokeLinecap='round'
75
- strokeLinejoin='round'
76
- />
77
- <circle
78
- cx={7.8932}
79
- cy={68.8966}
80
- r={4.81605}
81
- stroke='#21FA90'
82
- strokeWidth={3}
83
- />
84
- <circle
85
- cx={72.1061}
86
- cy={59.2638}
87
- r={4.81605}
88
- stroke='#21FA90'
89
- strokeWidth={3}
90
- />
91
- <circle
92
- cx={62.4752}
93
- cy={72.1073}
94
- r={4.81605}
95
- stroke='#21FA90'
96
- strokeWidth={3}
97
- />
98
- <circle
99
- cx={35.1823}
100
- cy={72.1073}
101
- r={4.81605}
102
- stroke='#21FA90'
103
- strokeWidth={3}
104
- />
105
- </svg>
106
- )
1
+ import * as React from 'react'
2
+ import PropTypes from 'prop-types'
3
+ import styles from './Icons.module.css'
4
+
5
+ const ApiEmptyIcon = ({ color, size }) => {
6
+ const className = `${styles.noShrinkForFlex} ` + styles[`${color}`] + ' '
7
+ const filledClassName = styles[`filled-${color}`]
8
+ let icon = <></>
9
+
10
+ switch (size) {
11
+ case 'extra-large':
12
+ icon = (
13
+ <svg
14
+ width={80}
15
+ height={80}
16
+ viewBox='0 0 80 80'
17
+ fill='none'
18
+ xmlns='http://www.w3.org/2000/svg'
19
+ className={className}
20
+ >
21
+ <path
22
+ d='M38.2726 3.83337V5.48055C38.2726 5.79404 38.4831 6.07727 38.8003 6.18727L41.0653 6.98199C41.3737 7.08923 41.7235 7.01498 41.9488 6.78949L43.0369 5.70604C43.3571 5.38705 43.9026 5.3843 44.2257 5.70329L46.8525 8.28268C47.146 8.57142 47.1489 9.01965 46.8613 9.31114L45.462 10.7356C45.2397 10.9611 45.1863 11.2883 45.3256 11.5633L46.2743 13.4607C46.4077 13.7275 46.6983 13.9007 47.0155 13.9007H48.4682C48.9189 13.9007 49.2835 14.2389 49.2835 14.6569V17.8413C49.2835 18.2593 48.9189 18.5975 48.4682 18.5975H46.9414C46.5886 18.5975 46.2743 18.8092 46.1646 19.12L45.3938 21.3116C45.3019 21.5701 45.3671 21.8534 45.5658 22.0541L46.8198 23.3383C47.1252 23.6518 47.0956 24.1385 46.7517 24.4163L43.8611 26.7619C43.529 27.0314 43.025 27.0067 42.7256 26.7069L41.7176 25.7005C41.4982 25.4805 41.1573 25.4007 40.8519 25.4997L38.7469 26.1817C38.4179 26.2889 38.1985 26.5749 38.1985 26.8967V28.3953C38.1985 28.8133 37.8338 29.1516 37.3832 29.1516H33.5409C33.0903 29.1516 32.7256 28.8133 32.7256 28.3953V26.8967C32.7256 26.5749 32.5062 26.2889 32.1772 26.1817L30.0722 25.4997C29.7668 25.4007 29.4259 25.4777 29.2065 25.7005L28.1985 26.7069C27.8991 27.0067 27.3951 27.0314 27.063 26.7619L24.1724 24.4163C23.8285 24.1385 23.7989 23.6518 24.1043 23.3383L25.3583 22.0541C25.554 21.8534 25.6192 21.5701 25.5303 21.3116L24.7595 19.12C24.6498 18.8092 24.3355 18.5975 23.9827 18.5975H22.4588C22.0082 18.5975 21.6436 18.2593 21.6436 17.8413V14.6569C21.6436 14.2389 22.0082 13.9007 22.4588 13.9007H23.9116C24.2288 13.9007 24.5193 13.7302 24.6527 13.4607L25.6014 11.5633C25.7408 11.2856 25.6844 10.9611 25.4651 10.7356L24.0657 9.31114C23.7781 9.01965 23.7811 8.56867 24.0746 8.28268L26.7013 5.70329C27.0245 5.38705 27.57 5.38705 27.8902 5.70604L28.9782 6.78949C29.2036 7.01498 29.5534 7.08923 29.8617 6.98199L32.1268 6.18727C32.444 6.07727 32.6545 5.79404 32.6545 5.48055V3.83337C32.6545 3.41538 33.0191 3.07715 33.4698 3.07715H37.4573C37.9079 3.07715 38.2726 3.41538 38.2726 3.83337Z'
23
+ stroke='none'
24
+ strokeWidth={3}
25
+ strokeLinecap='round'
26
+ strokeLinejoin='round'
27
+ />
28
+ <path
29
+ d='M30.8564 20.46L40.0698 11.7686'
30
+ stroke='none'
31
+ strokeWidth={3}
32
+ strokeLinecap='round'
33
+ strokeLinejoin='round'
34
+ />
35
+ <path
36
+ d='M40.0698 20.46L30.8564 11.7685'
37
+ stroke='none'
38
+ strokeWidth={3}
39
+ strokeLinecap='round'
40
+ strokeLinejoin='round'
41
+ />
42
+ <path
43
+ d='M23.9482 48.0268L30.2728 33.98H33.5161L39.861 48.0268H36.4149L31.2255 35.6255H32.5229L27.3132 48.0268H23.9482ZM27.1105 45.0168L27.9822 42.5485H35.2797L36.1716 45.0168H27.1105Z'
44
+ fill='none' className={filledClassName}
45
+ />
46
+ <path
47
+ d='M41.3331 48.0268V33.98H47.4752C48.7455 33.98 49.8402 34.1873 50.7591 34.6021C51.6781 35.0034 52.3876 35.5853 52.8876 36.3479C53.3876 37.1104 53.6376 38.0201 53.6376 39.077C53.6376 40.1204 53.3876 41.0235 52.8876 41.786C52.3876 42.5485 51.6781 43.1372 50.7591 43.5519C49.8402 43.9532 48.7455 44.1539 47.4752 44.1539H43.1575L44.617 42.689V48.0268H41.3331ZM44.617 43.0502L43.1575 41.5051H47.2928C48.3063 41.5051 49.0631 41.291 49.5631 40.8629C50.0632 40.4348 50.3132 39.8395 50.3132 39.077C50.3132 38.3011 50.0632 37.699 49.5631 37.271C49.0631 36.8429 48.3063 36.6288 47.2928 36.6288H43.1575L44.617 35.0837V43.0502Z'
48
+ fill='none' className={filledClassName}
49
+ />
50
+ <path d='M55.9821 48.0268V33.98H59.266V48.0268H55.9821Z' fill='none' className={filledClassName} />
51
+ <path
52
+ d='M68.3785 43.6372V43.6268M68.3785 43.6268C73.1364 43.4008 76.9245 39.4861 76.9245 34.6885C76.9245 29.7447 72.9027 25.7397 67.946 25.7397C67.8169 25.7397 67.6878 25.7432 67.5588 25.7501C65.5008 21.9502 61.4719 19.3706 56.8361 19.3706C55.6286 19.3706 54.4639 19.5464 53.3639 19.8731M68.3785 43.6268H63.1045M23.1801 43.6372H18.1488V43.6302C11.5702 43.4634 6.28906 38.2068 6.28906 31.5039C6.28906 26.0102 9.95151 21.3689 14.9756 19.8731'
53
+ stroke='none'
54
+ strokeWidth={3}
55
+ strokeMiterlimit={10}
56
+ strokeLinecap='round'
57
+ strokeLinejoin='round'
58
+ />
59
+ <path
60
+ d='M22.3412 51.2373V67.8962C22.3412 68.4485 21.8935 68.8962 21.3412 68.8962H14.3145'
61
+ stroke='none'
62
+ strokeWidth={3}
63
+ strokeLinecap='round'
64
+ strokeLinejoin='round'
65
+ />
66
+ <path
67
+ d='M60.8682 51.2373V58.2641C60.8682 58.8163 61.3159 59.2641 61.8682 59.2641H67.2896'
68
+ stroke='none'
69
+ strokeWidth={3}
70
+ strokeLinecap='round'
71
+ strokeLinejoin='round'
72
+ />
73
+ <path
74
+ d='M35.1836 54.4478V67.2906'
75
+ stroke='none'
76
+ strokeWidth={3}
77
+ strokeLinecap='round'
78
+ strokeLinejoin='round'
79
+ />
80
+ <path
81
+ d='M48.0254 54.4478V71.1066C48.0254 71.6589 48.4731 72.1066 49.0254 72.1066H56.0521'
82
+ stroke='none'
83
+ strokeWidth={3}
84
+ strokeLinecap='round'
85
+ strokeLinejoin='round'
86
+ />
87
+ <circle
88
+ cx={7.8932}
89
+ cy={68.8966}
90
+ r={4.81605}
91
+ stroke='none'
92
+ strokeWidth={3}
93
+ />
94
+ <circle
95
+ cx={72.1061}
96
+ cy={59.2638}
97
+ r={4.81605}
98
+ stroke='none'
99
+ strokeWidth={3}
100
+ />
101
+ <circle
102
+ cx={62.4752}
103
+ cy={72.1073}
104
+ r={4.81605}
105
+ stroke='none'
106
+ strokeWidth={3}
107
+ />
108
+ <circle
109
+ cx={35.1823}
110
+ cy={72.1073}
111
+ r={4.81605}
112
+ stroke='none'
113
+ strokeWidth={3}
114
+ />
115
+ </svg>
116
+ )
117
+ break
118
+
119
+ default:
120
+ break
121
+ }
122
+ return icon
107
123
  }
124
+
125
+ ApiEmptyIcon.propTypes = {
126
+ /**
127
+ * color of text, icon and borders
128
+ */
129
+ color: PropTypes.oneOf(['green', 'white', 'main-dark-blue', 'red']),
130
+ /**
131
+ * Size
132
+ */
133
+ size: PropTypes.oneOf(['small', 'medium', 'large', 'extra-large'])
134
+ }
135
+
136
+ ApiEmptyIcon.defaultProps = {
137
+ color: 'main-dark-blue',
138
+ size: 'medium'
139
+ }
140
+
141
+ export default ApiEmptyIcon
@@ -1,19 +1,52 @@
1
- import React from 'react'
2
- export default function ApiIconClosed () {
3
- return (
4
- <svg
5
- width={38}
6
- height={42}
7
- fill='none'
8
- xmlns='http://www.w3.org/2000/svg'
9
- >
10
- <path
11
- d='M8.12 22.358A7.12 7.12 0 0 1 8.118 8.12a7.12 7.12 0 0 1 13.631-2.88c.2-.02.404-.029.61-.029a7.121 7.121 0 0 1 6.864 5.236 6.079 6.079 0 1 1 1.7 11.912M13 11.5v7M13 31v-3m0-3v-3.5M25 13v6m0 15.5V31m0-3v-6M19 15.4v7.1m0 18v-4m0-11v8'
12
- stroke='#fff'
13
- strokeWidth={2}
14
- strokeLinecap='round'
15
- strokeLinejoin='round'
16
- />
17
- </svg>
18
- )
1
+ import * as React from 'react'
2
+ import PropTypes from 'prop-types'
3
+ import styles from './Icons.module.css'
4
+
5
+ const ApiIconClosed = ({ color, size }) => {
6
+ const className = `${styles.noShrinkForFlex} ` + styles[`${color}`]
7
+ let icon = <></>
8
+
9
+ switch (size) {
10
+ case 'extra-large':
11
+ icon = (
12
+ <svg
13
+ width={38}
14
+ height={42}
15
+ fill='none'
16
+ xmlns='http://www.w3.org/2000/svg'
17
+ className={className}
18
+ >
19
+ <path
20
+ d='M8.12 22.358A7.12 7.12 0 0 1 8.118 8.12a7.12 7.12 0 0 1 13.631-2.88c.2-.02.404-.029.61-.029a7.121 7.121 0 0 1 6.864 5.236 6.079 6.079 0 1 1 1.7 11.912M13 11.5v7M13 31v-3m0-3v-3.5M25 13v6m0 15.5V31m0-3v-6M19 15.4v7.1m0 18v-4m0-11v8'
21
+ stroke='#fff'
22
+ strokeWidth={2}
23
+ strokeLinecap='round'
24
+ strokeLinejoin='round'
25
+ />
26
+ </svg>
27
+ )
28
+ break
29
+
30
+ default:
31
+ break
32
+ }
33
+ return icon
19
34
  }
35
+
36
+ ApiIconClosed.propTypes = {
37
+ /**
38
+ * color of text, icon and borders
39
+ */
40
+ color: PropTypes.oneOf(['green', 'white', 'main-dark-blue', 'red']),
41
+ /**
42
+ * Size
43
+ */
44
+ size: PropTypes.oneOf(['small', 'medium', 'large', 'extra-large'])
45
+ }
46
+
47
+ ApiIconClosed.defaultProps = {
48
+ color: 'main-dark-blue',
49
+ size: 'medium'
50
+ }
51
+
52
+ export default ApiIconClosed