@platformatic/ui-components 0.6.2 → 0.6.4

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.
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.6.2",
4
+ "version": "0.6.4",
5
5
  "type": "module",
6
6
  "license": "Apache-2.0",
7
7
  "repository": {
@@ -84,7 +84,7 @@ function ButtonOnlyIcon ({
84
84
  return (
85
85
  <button className={`${baseButtonClassName} ${buttonClassName} ${restClassName()}`} disabled={disabled} alt={altLabel} {...rest} onMouseLeave={() => setHover(false)} onMouseOver={() => setHover(true)}>
86
86
  <div className={`${contentClassName} ${backgroundClassName}`}>
87
- {platformaticIcon ? <PlatformaticIcon key='center' iconName={platformaticIcon.iconName} color={platformaticIcon.color} data-testid='button-icon' size={MEDIUM} onClick={null} disabled={disabled} /> : null}
87
+ {platformaticIcon ? <PlatformaticIcon key='center' iconName={platformaticIcon.iconName} color={platformaticIcon.color} data-testid='button-icon' size={platformaticIcon?.size ?? MEDIUM} onClick={null} disabled={disabled} /> : null}
88
88
  </div>
89
89
  </button>
90
90
  )
@@ -136,7 +136,8 @@ ButtonOnlyIcon.propTypes = {
136
136
  */
137
137
  platformaticIcon: PropTypes.shape({
138
138
  iconName: PropTypes.string,
139
- color: PropTypes.string
139
+ color: PropTypes.string,
140
+ size: PropTypes.string
140
141
  }),
141
142
  /**
142
143
  * Selected: default false
@@ -11,17 +11,17 @@
11
11
  }
12
12
 
13
13
  .checkbox--white {
14
- @apply border-main-dark-blue bg-white
14
+ @apply border-white bg-rich-black
15
15
  }
16
16
  .checkbox--white:checked {
17
- @apply bg-main-dark-blue text-white;
17
+ @apply bg-rich-black text-white;
18
18
  }
19
-
20
19
  .checkbox--main-dark-blue:checked:after,
21
20
  .checkbox--white:checked:after {
22
- @apply absolute top-[50%] left-[50%] h-full w-full;
23
- transform: translate(-50%, -50%);
24
- content: url('data:image/svg+xml,%3Csvg%20width=%2213%22%20height=%229%22%20viewBox=%220%200%2013%209%22%20fill=%22none%22%20xmlns=%22http://www.w3.org/2000/svg%22%3E%3Cpath%20d=%22M1%204L5%208L12%201%22%20stroke=%22white%22%20stroke-width=%222%22%20stroke-linecap=%22round%22%20stroke-linejoin=%22round%22/%3E%3C/svg%3E');
21
+ @apply absolute h-full w-full;
22
+ top: -4.5px;
23
+ left: 1.5px;
24
+ content: url('data:image/svg+xml,%3Csvg%20width%3D%2213%22%20height%3D%229%22%20viewBox%3D%220%200%2013%209%22%20fill%3D%22none%22%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%3E%3Cpath%20d%3D%22M1%204L5%208L12%201%22%20stroke%3D%22white%22%20stroke-linecap%3D%22round%22%20stroke-linejoin%3D%22round%22%2F%3E%3C%2Fsvg%3E');
25
25
  }
26
26
 
27
27
  .disabled {
@@ -199,7 +199,8 @@ Select.propTypes = {
199
199
  label: PropTypes.string,
200
200
  value: PropTypes.oneOfType([
201
201
  PropTypes.string,
202
- PropTypes.number
202
+ PropTypes.number,
203
+ PropTypes.func
203
204
  ]),
204
205
  iconName: PropTypes.string,
205
206
  iconSize: PropTypes.string,
@@ -4,8 +4,7 @@ import { WHITE } from '../components/constants'
4
4
  const divStyle = {
5
5
  width: '100%',
6
6
  height: 'auto',
7
- padding: '50px',
8
- backgroundColor: 'white'
7
+ padding: '50px'
9
8
  }
10
9
 
11
10
  export default {