orcs-design-system 2.0.64 → 2.0.65

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.
@@ -72,9 +72,13 @@ export var fullWidth = function fullWidth() {
72
72
  };
73
73
  fullWidth.storyName = "Full width";
74
74
  export var disabled = function disabled() {
75
- return /*#__PURE__*/React.createElement(Button, {
75
+ return /*#__PURE__*/React.createElement(Spacer, {
76
+ my: "r"
77
+ }, /*#__PURE__*/React.createElement(Button, {
76
78
  disabled: true
77
- }, "Disabled button");
79
+ }, "Disabled button"), /*#__PURE__*/React.createElement(Button, {
80
+ variant: "disabled"
81
+ }, "Alternate way of making button disabled"));
78
82
  };
79
83
  disabled.storyName = "Disabled state";
80
84
  export var loading = function loading() {
@@ -14,7 +14,8 @@ var StyledButton = styled("button").withConfig({
14
14
  shouldForwardProp: shouldForwardProp
15
15
  }).attrs(function (props) {
16
16
  return {
17
- "data-testid": props.dataTestId ? props.dataTestId : props["data-testid"] ? props["data-testid"] : null
17
+ "data-testid": props.dataTestId ? props.dataTestId : props["data-testid"] ? props["data-testid"] : null,
18
+ disabled: props.disabled ? true : props.variant == "disabled" ? true : false
18
19
  };
19
20
  }).withConfig({
20
21
  displayName: "Button__StyledButton",
@@ -113,6 +114,16 @@ var StyledButton = styled("button").withConfig({
113
114
  boxShadow: themeGet("shadows.thinOutline")(props) + " " + themeGet("colors.danger30")(props)
114
115
  }
115
116
  },
117
+ disabled: {
118
+ bg: "greyLighter",
119
+ color: "grey",
120
+ borderColor: "greyLighter",
121
+ "&:hover": {
122
+ bg: "greyLighter",
123
+ color: "grey",
124
+ borderColor: "greyLighter"
125
+ }
126
+ },
116
127
  ghost: {
117
128
  bg: "primaryLightest",
118
129
  color: "primary",
@@ -228,6 +239,9 @@ Button.__docgenInfo = {
228
239
  }, {
229
240
  "value": "\"ghost\"",
230
241
  "computed": false
242
+ }, {
243
+ "value": "\"disabled\"",
244
+ "computed": false
231
245
  }, {
232
246
  "value": "\"default\"",
233
247
  "computed": false
@@ -331,7 +345,7 @@ Button.propTypes = {
331
345
  small: PropTypes.bool,
332
346
 
333
347
  /** Specifies alternate button colours/styles. */
334
- variant: PropTypes.oneOf(["success", "danger", "ghost", "default"]),
348
+ variant: PropTypes.oneOf(["success", "danger", "ghost", "disabled", "default"]),
335
349
 
336
350
  /** Full width button that takes up all available space of parent */
337
351
  fullWidth: PropTypes.bool,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "orcs-design-system",
3
- "version": "2.0.64",
3
+ "version": "2.0.65",
4
4
  "description": "Orchestrated's Design System, aka: ORCS",
5
5
  "keywords": [
6
6
  "design",