@axinom/mosaic-ui 0.28.0-rc.4 → 0.28.0

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,6 +1,6 @@
1
1
  {
2
2
  "name": "@axinom/mosaic-ui",
3
- "version": "0.28.0-rc.4",
3
+ "version": "0.28.0",
4
4
  "description": "UI components for building Axinom Mosaic applications",
5
5
  "author": "Axinom",
6
6
  "license": "PROPRIETARY",
@@ -32,7 +32,7 @@
32
32
  "build-storybook": "build-storybook -s ./.storybook/static"
33
33
  },
34
34
  "dependencies": {
35
- "@axinom/mosaic-core": "^0.4.1-rc.14",
35
+ "@axinom/mosaic-core": "^0.4.1",
36
36
  "@faker-js/faker": "^7.4.0",
37
37
  "@popperjs/core": "^2.9.2",
38
38
  "clsx": "^1.1.0",
@@ -92,5 +92,5 @@
92
92
  "publishConfig": {
93
93
  "access": "public"
94
94
  },
95
- "gitHead": "03134b934baa215bbae0f024d9dc112d0a3dc661"
95
+ "gitHead": "c64cc582e131b50adfc21b0c8ad940469780f43b"
96
96
  }
@@ -46,7 +46,6 @@ export const SingleLineText: React.FC<SingleLineTextProps> = ({
46
46
  onFocus,
47
47
  className = '',
48
48
  tooltipContent,
49
- ...rest
50
49
  }) => {
51
50
  const errorMsg: string | undefined = error;
52
51
  const [val, setVal] = useState(value ?? '');
@@ -105,7 +104,6 @@ export const SingleLineText: React.FC<SingleLineTextProps> = ({
105
104
  error={errorMsg}
106
105
  tooltipContent={tooltipContent}
107
106
  dataTestFieldType="SingleLineText"
108
- {...rest}
109
107
  >
110
108
  <input
111
109
  className={clsx({ [classes.hasError]: errorMsg !== undefined })}
@@ -41,7 +41,6 @@ export const TextArea: React.FC<TextAreaProps> = ({
41
41
  onFocus,
42
42
  className = '',
43
43
  tooltipContent,
44
- ...rest
45
44
  }) => {
46
45
  const errorMsg: string | undefined = error;
47
46
 
@@ -52,7 +51,6 @@ export const TextArea: React.FC<TextAreaProps> = ({
52
51
  error={errorMsg}
53
52
  tooltipContent={tooltipContent}
54
53
  dataTestFieldType="TextArea"
55
- {...rest}
56
54
  >
57
55
  <textarea
58
56
  className={clsx({ [classes.hasError]: errorMsg !== undefined })}
@@ -1,4 +1,3 @@
1
- import { text } from '@storybook/addon-knobs';
2
1
  import React from 'react';
3
2
  import { MemoryRouter } from 'react-router-dom';
4
3
  import { Story } from '../../helpers/storybook';
@@ -98,20 +97,3 @@ export const Default: Story = () => {
98
97
  </div>
99
98
  );
100
99
  };
101
-
102
- export const knobs: Story = () => {
103
- const item: HubItem = {
104
- groupName: text('Group Name', 'Image Service'),
105
- path: text('Path', '/video/acquisition'),
106
- label: text('Label', 'Transcoding'),
107
- subLabel: text('Sub Label', 'Image Acquisition'),
108
- icon: <DefaultIcon />,
109
- };
110
- return (
111
- <div style={defaultContainer}>
112
- <MemoryRouter>
113
- <Hub items={[item]} />
114
- </MemoryRouter>
115
- </div>
116
- );
117
- };
@@ -56,7 +56,6 @@ export const Hub: React.FC<HubProps> = ({
56
56
  key={itemIndex}
57
57
  path={item.path}
58
58
  label={item.label}
59
- subLabel={item.subLabel}
60
59
  icon={item.icon}
61
60
  disabled={item.disabled}
62
61
  />
@@ -5,8 +5,6 @@ export interface TileProps {
5
5
  path: string;
6
6
  /** Tile label */
7
7
  label: string;
8
- /** Tile sub label */
9
- subLabel?: string;
10
8
  /** Icon location or an react element of svg icon.
11
9
  * if an react element of svg is passed, the correct style for two types ("small" and "large") will be applied accordingly
12
10
  * The styles which don't want to be affected based on the tile type can be passed as inline styles.
@@ -15,7 +15,11 @@
15
15
  &:hover {
16
16
  border: 1px solid var(--hub-tile-border-hover, $hub-tile-border-hover);
17
17
 
18
- box-shadow: 0 0 0 2px var(--hub-tile-border-hover, $hub-tile-border-hover);
18
+ box-shadow: 0 0 0 2px
19
+ var(
20
+ --hub-tile-border-hover,
21
+ $hub-tile-border-hover
22
+ );
19
23
  }
20
24
 
21
25
  &.disabled {
@@ -30,12 +34,14 @@
30
34
  height: 60px;
31
35
  align-self: center;
32
36
  svg * {
33
- stroke: var(--hub-tile-stroke-color, $hub-tile-stroke-color);
37
+ stroke: var(
38
+ --hub-tile-stroke-color,
39
+ $hub-tile-stroke-color,
40
+ );
34
41
  }
35
42
  }
36
43
 
37
44
  .label {
38
- display: grid;
39
45
  text-align: center;
40
46
  align-self: start;
41
47
  font-size: 18px;
@@ -16,13 +16,7 @@ import classes from './Tile.scss';
16
16
  * icon={'/images/default_image.svg'}
17
17
  * />
18
18
  */
19
- export const Tile: React.FC<TileProps> = ({
20
- path,
21
- label,
22
- subLabel,
23
- icon,
24
- disabled,
25
- }) => {
19
+ export const Tile: React.FC<TileProps> = ({ path, label, icon, disabled }) => {
26
20
  return (
27
21
  <Link
28
22
  className={clsx(classes.tile, disabled && classes.disabled)}
@@ -37,10 +31,9 @@ export const Tile: React.FC<TileProps> = ({
37
31
  <img src={icon} alt={`${label} icon`} />
38
32
  )}
39
33
  </div>
40
- <div className={classes.label}>
41
- <span data-test-id="tile-label">{label}</span>
42
- <span>{subLabel}</span>
43
- </div>
34
+ <span className={classes.label} data-test-id="tile-label">
35
+ {label}
36
+ </span>
44
37
  </Link>
45
38
  );
46
39
  };
@@ -26,8 +26,8 @@ const mockItems: LandingPageItem[] = [
26
26
  type: 'small',
27
27
  },
28
28
  {
29
- path: '/localizations',
30
- label: 'Localizations',
29
+ path: '/translations',
30
+ label: 'Translations',
31
31
  icon: '/images/default_image.svg',
32
32
  type: 'small',
33
33
  },
@@ -101,8 +101,8 @@ const smallTiles: LandingPageItem[] = [
101
101
  type: 'small',
102
102
  },
103
103
  {
104
- path: '/localizations',
105
- label: 'Localizations',
104
+ path: '/translations',
105
+ label: 'Translations',
106
106
  icon: <DefaultIcon />,
107
107
  type: 'small',
108
108
  },
package/src/index.ts CHANGED
@@ -4,5 +4,4 @@ export * from './helpers';
4
4
  export * from './hooks';
5
5
  export * from './initialize';
6
6
  export * from './types';
7
- export { ErrorTypeToStationError } from './utils/ErrorTypeToStationError';
8
7
  export * from './validators';