@sb1/ffe-symbols-react 3.0.2 → 4.0.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/CHANGELOG.md CHANGED
@@ -3,6 +3,20 @@
3
3
  All notable changes to this project will be documented in this file.
4
4
  See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
5
5
 
6
+ # [4.0.0](https://github.com/SpareBank1/designsystem/compare/@sb1/ffe-symbols-react@3.0.3...@sb1/ffe-symbols-react@4.0.0) (2024-02-26)
7
+
8
+ ### Bug Fixes
9
+
10
+ - **ffe-symbols-react:** fjern weight 400 og størrelsene xs og 2xl ([829570e](https://github.com/SpareBank1/designsystem/commit/829570e71186a08016d80c5294de0579dbff3446))
11
+
12
+ ### BREAKING CHANGES
13
+
14
+ - **ffe-symbols-react:** Fjerner 400 som weight og størrelsene xs og 2xl fra Symbol-komponenten.
15
+
16
+ ## [3.0.3](https://github.com/SpareBank1/designsystem/compare/@sb1/ffe-symbols-react@3.0.2...@sb1/ffe-symbols-react@3.0.3) (2024-02-12)
17
+
18
+ **Note:** Version bump only for package @sb1/ffe-symbols-react
19
+
6
20
  ## [3.0.2](https://github.com/SpareBank1/designsystem/compare/@sb1/ffe-symbols-react@3.0.1...@sb1/ffe-symbols-react@3.0.2) (2023-12-13)
7
21
 
8
22
  ### Bug Fixes
package/es/Symbol.js CHANGED
@@ -23,7 +23,7 @@ var _Symbol = function _Symbol(props) {
23
23
  export { _Symbol as Symbol };
24
24
  _Symbol.defaultProps = {
25
25
  fill: false,
26
- weight: 400
26
+ weight: 300
27
27
  };
28
28
  _Symbol.propTypes = {
29
29
  /** Fills the icon with color */
@@ -31,9 +31,9 @@ _Symbol.propTypes = {
31
31
  /** The name of the icon that should be shown */
32
32
  icon: string.isRequired,
33
33
  /** Size of the icon, default is the closest defined font-size */
34
- size: oneOf(['xs', 'sm', 'md', 'lg', 'xl', '2xl']),
34
+ size: oneOf(['sm', 'md', 'lg', 'xl']),
35
35
  /** Symbols stroke weight. This can affect overall size of symbol, 400 is default */
36
- weight: oneOf([300, 400, 500]),
36
+ weight: oneOf([300, 500]),
37
37
  /** Additional classnames */
38
38
  className: string,
39
39
  /** Aria label text. If null/undefined, aria-hidden is automatically set to true */
package/lib/Symbol.js CHANGED
@@ -29,7 +29,7 @@ var _Symbol = exports.Symbol = function _Symbol(props) {
29
29
  };
30
30
  _Symbol.defaultProps = {
31
31
  fill: false,
32
- weight: 400
32
+ weight: 300
33
33
  };
34
34
  _Symbol.propTypes = {
35
35
  /** Fills the icon with color */
@@ -37,9 +37,9 @@ _Symbol.propTypes = {
37
37
  /** The name of the icon that should be shown */
38
38
  icon: _propTypes.string.isRequired,
39
39
  /** Size of the icon, default is the closest defined font-size */
40
- size: (0, _propTypes.oneOf)(['xs', 'sm', 'md', 'lg', 'xl', '2xl']),
40
+ size: (0, _propTypes.oneOf)(['sm', 'md', 'lg', 'xl']),
41
41
  /** Symbols stroke weight. This can affect overall size of symbol, 400 is default */
42
- weight: (0, _propTypes.oneOf)([300, 400, 500]),
42
+ weight: (0, _propTypes.oneOf)([300, 500]),
43
43
  /** Additional classnames */
44
44
  className: _propTypes.string,
45
45
  /** Aria label text. If null/undefined, aria-hidden is automatically set to true */
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@sb1/ffe-symbols-react",
3
- "version": "3.0.2",
3
+ "version": "4.0.0",
4
4
  "description": "React-komponenter for Material Symbols tilpasset Sb1 sine behov",
5
5
  "main": "lib/index.js",
6
6
  "module": "es/index.js",
@@ -23,17 +23,17 @@
23
23
  },
24
24
  "homepage": "https://github.com/SpareBank1/designsystem#readme",
25
25
  "dependencies": {
26
- "@sb1/ffe-symbols": "^2.1.1",
26
+ "@sb1/ffe-symbols": "^3.0.0",
27
27
  "classnames": "^2.3.2",
28
28
  "prop-types": "^15.8.1",
29
29
  "react": "^18.2.0"
30
30
  },
31
31
  "devDependencies": {
32
- "@sb1/ffe-buildtool": "^0.5.0",
32
+ "@sb1/ffe-buildtool": "^0.5.1",
33
33
  "eslint": "^5.9.0"
34
34
  },
35
35
  "publishConfig": {
36
36
  "access": "public"
37
37
  },
38
- "gitHead": "ccaae661883249ac88e9c9da8c2f4eb00a4ad5ac"
38
+ "gitHead": "d78e3fec5da8d8ce82b4e95c9f2960a3402902ef"
39
39
  }
package/src/Symbol.js CHANGED
@@ -25,7 +25,7 @@ export const Symbol = props => {
25
25
 
26
26
  Symbol.defaultProps = {
27
27
  fill: false,
28
- weight: 400,
28
+ weight: 300,
29
29
  };
30
30
 
31
31
  Symbol.propTypes = {
@@ -34,9 +34,9 @@ Symbol.propTypes = {
34
34
  /** The name of the icon that should be shown */
35
35
  icon: string.isRequired,
36
36
  /** Size of the icon, default is the closest defined font-size */
37
- size: oneOf(['xs', 'sm', 'md', 'lg', 'xl', '2xl']),
37
+ size: oneOf(['sm', 'md', 'lg', 'xl']),
38
38
  /** Symbols stroke weight. This can affect overall size of symbol, 400 is default */
39
- weight: oneOf([300, 400, 500]),
39
+ weight: oneOf([300, 500]),
40
40
  /** Additional classnames */
41
41
  className: string,
42
42
  /** Aria label text. If null/undefined, aria-hidden is automatically set to true */
@@ -11,9 +11,9 @@ describe('<Symbol />', () => {
11
11
  });
12
12
  it('renders filled symbol correctly', () => {
13
13
  const wrapper = getWrapper();
14
- expect(wrapper.hasClass('ffe-symbol--400')).toBe(true);
14
+ expect(wrapper.hasClass('ffe-symbol--300')).toBe(true);
15
15
  const filled = getWrapper({ fill: true });
16
- expect(filled.hasClass('ffe-symbol--filled-400')).toBe(true);
16
+ expect(filled.hasClass('ffe-symbol--filled-300')).toBe(true);
17
17
  });
18
18
  it('set correct symbol weight', () => {
19
19
  const wrapper = getWrapper({ weight: 500 });
package/src/index.d.ts CHANGED
@@ -3,8 +3,8 @@ import { SymbolName } from './symbolNames.ts';
3
3
 
4
4
  export interface SymbolProps {
5
5
  fill?: boolean;
6
- size?: 'xs' | 'sm' | 'md' | 'lg' | 'xl' | '2xl';
7
- weight?: 300 | 400 | 500;
6
+ size?: 'sm' | 'md' | 'lg' | 'xl';
7
+ weight?: 300 | 500;
8
8
  icon: SymbolName;
9
9
  className?: string;
10
10
  ariaLabel?: string;
package/types/index.d.ts CHANGED
@@ -3,8 +3,8 @@ import { SymbolName } from './symbolNames.ts';
3
3
 
4
4
  export interface SymbolProps {
5
5
  fill?: boolean;
6
- size?: 'xs' | 'sm' | 'md' | 'lg' | 'xl' | '2xl';
7
- weight?: 300 | 400 | 500;
6
+ size?: 'sm' | 'md' | 'lg' | 'xl';
7
+ weight?: 300 | 500;
8
8
  icon: SymbolName;
9
9
  className?: string;
10
10
  ariaLabel?: string;