@sb1/ffe-chips-react 1.2.10 → 2.0.1

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/es/Chip.js CHANGED
@@ -20,14 +20,13 @@ var __rest = (this && this.__rest) || function (s, e) {
20
20
  }
21
21
  return t;
22
22
  };
23
- import React from 'react';
24
23
  import classNames from 'classnames';
24
+ import React from 'react';
25
25
  import { fixedForwardRef } from './fixedForwardRef';
26
26
  function ChipWithForwardRef(props, ref) {
27
- var _a = props.as, Comp = _a === void 0 ? 'button' : _a, className = props.className, size = props.size, leftIcon = props.leftIcon, rightIcon = props.rightIcon, children = props.children, onColoredBg = props.onColoredBg, rest = __rest(props, ["as", "className", "size", "leftIcon", "rightIcon", "children", "onColoredBg"]);
27
+ var _a = props.as, Comp = _a === void 0 ? 'button' : _a, className = props.className, size = props.size, leftIcon = props.leftIcon, rightIcon = props.rightIcon, children = props.children, rest = __rest(props, ["as", "className", "size", "leftIcon", "rightIcon", "children"]);
28
28
  var wrappedChildren = (React.createElement("span", { className: classNames('ffe-chip__label', size === 'sm' ? 'ffe-small-text' : 'ffe-body-paragraph') }, children));
29
29
  return (React.createElement(Comp, __assign({ className: classNames('ffe-chip', {
30
- 'ffe-chip--on-colored-bg': onColoredBg,
31
30
  'ffe-chip--sm': size === 'sm',
32
31
  'ffe-chip--md': size === 'md',
33
32
  'ffe-chip--lg': size === 'lg',
package/lib/Chip.js CHANGED
@@ -26,14 +26,13 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
26
26
  };
27
27
  Object.defineProperty(exports, "__esModule", { value: true });
28
28
  exports.Chip = void 0;
29
- var react_1 = __importDefault(require("react"));
30
29
  var classnames_1 = __importDefault(require("classnames"));
30
+ var react_1 = __importDefault(require("react"));
31
31
  var fixedForwardRef_1 = require("./fixedForwardRef");
32
32
  function ChipWithForwardRef(props, ref) {
33
- var _a = props.as, Comp = _a === void 0 ? 'button' : _a, className = props.className, size = props.size, leftIcon = props.leftIcon, rightIcon = props.rightIcon, children = props.children, onColoredBg = props.onColoredBg, rest = __rest(props, ["as", "className", "size", "leftIcon", "rightIcon", "children", "onColoredBg"]);
33
+ var _a = props.as, Comp = _a === void 0 ? 'button' : _a, className = props.className, size = props.size, leftIcon = props.leftIcon, rightIcon = props.rightIcon, children = props.children, rest = __rest(props, ["as", "className", "size", "leftIcon", "rightIcon", "children"]);
34
34
  var wrappedChildren = (react_1.default.createElement("span", { className: (0, classnames_1.default)('ffe-chip__label', size === 'sm' ? 'ffe-small-text' : 'ffe-body-paragraph') }, children));
35
35
  return (react_1.default.createElement(Comp, __assign({ className: (0, classnames_1.default)('ffe-chip', {
36
- 'ffe-chip--on-colored-bg': onColoredBg,
37
36
  'ffe-chip--sm': size === 'sm',
38
37
  'ffe-chip--md': size === 'md',
39
38
  'ffe-chip--lg': size === 'lg',
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@sb1/ffe-chips-react",
3
- "version": "1.2.10",
3
+ "version": "2.0.1",
4
4
  "description": "React implementation of ffe-chips component",
5
5
  "keywords": [
6
6
  "ffe"
@@ -29,9 +29,9 @@
29
29
  "test:watch": "ffe-buildtool jest --watch"
30
30
  },
31
31
  "dependencies": {
32
- "@sb1/ffe-chips": "^1.3.3",
32
+ "@sb1/ffe-chips": "^2.0.0",
33
33
  "@sb1/ffe-core": "^29.5.0",
34
- "@sb1/ffe-icons-react": "^11.0.15"
34
+ "@sb1/ffe-icons-react": "^11.0.16"
35
35
  },
36
36
  "devDependencies": {
37
37
  "@sb1/ffe-buildtool": "^0.9.0",
@@ -44,5 +44,5 @@
44
44
  "publishConfig": {
45
45
  "access": "public"
46
46
  },
47
- "gitHead": "9f3d07c726368b31a79a15acbb545809c58ff413"
47
+ "gitHead": "92f6e9180ae0070960e6900eec4e2dfdd56726ed"
48
48
  }
package/types/Chip.d.ts CHANGED
@@ -14,8 +14,6 @@ type LeftOrRightIcon = LeftIcon | RightIcon;
14
14
  export type ChipProps<As extends ElementType = 'button'> = ComponentAsPropParams<As> & {
15
15
  /** Size of chip*/
16
16
  size: 'sm' | 'md' | 'lg';
17
- /** Adds alternative styling for better contrast on certain backgrounds */
18
- onColoredBg?: boolean;
19
17
  } & LeftOrRightIcon;
20
18
  export declare const Chip: <As extends ElementType>(props: ChipProps<As> & React.RefAttributes<any>) => React.JSX.Element;
21
19
  export {};