@rocket.chat/fuselage 0.36.0 → 0.37.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.
@@ -2354,7 +2354,7 @@ var react_1 = __importStar(__webpack_require__(/*! react */ "react"));
2354
2354
  var Box_1 = __importDefault(__webpack_require__(/*! ../Box */ "./src/components/Box/index.tsx"));
2355
2355
  var Icon_1 = __webpack_require__(/*! ../Icon */ "./src/components/Icon/index.ts");
2356
2356
  exports.Button = (0, react_1.forwardRef)(function Button(_a, ref) {
2357
- var primary = _a.primary, secondary = _a.secondary, danger = _a.danger, warning = _a.warning, success = _a.success, external = _a.external, icon = _a.icon, _b = _a.is, is = _b === void 0 ? 'button' : _b, _rel = _a.rel, tiny = _a.tiny, mini = _a.mini, small = _a.small, medium = _a.medium, large = _a.large, square = _a.square, children = _a.children, props = __rest(_a, ["primary", "secondary", "danger", "warning", "success", "external", "icon", "is", "rel", "tiny", "mini", "small", "medium", "large", "square", "children"]);
2357
+ var primary = _a.primary, secondary = _a.secondary, danger = _a.danger, warning = _a.warning, success = _a.success, external = _a.external, icon = _a.icon, _b = _a.is, is = _b === void 0 ? 'button' : _b, _rel = _a.rel, tiny = _a.tiny, mini = _a.mini, small = _a.small, medium = _a.medium, large = _a.large, square = _a.square, loading = _a.loading, disabled = _a.disabled, children = _a.children, props = __rest(_a, ["primary", "secondary", "danger", "warning", "success", "external", "icon", "is", "rel", "tiny", "mini", "small", "medium", "large", "square", "loading", "disabled", "children"]);
2358
2358
  var extraProps = (is === 'a' && {
2359
2359
  rel: external ? 'noopener noreferrer' : undefined,
2360
2360
  target: external ? '_blank' : undefined,
@@ -2380,9 +2380,10 @@ exports.Button = (0, react_1.forwardRef)(function Button(_a, ref) {
2380
2380
  }
2381
2381
  return {};
2382
2382
  }, [primary, secondary, danger, warning, success]);
2383
- return (react_1.default.createElement(Box_1.default, __assign({ is: is, type: 'button', "rcx-button": true }, kindAndVariantProps, { "rcx-button--small": small, "rcx-button--medium": medium, "rcx-button--large": large, "rcx-button--square": square, "rcx-button--tiny-square": tiny && square, "rcx-button--mini-square": mini && square, "rcx-button--small-square": small && square, "rcx-button--medium-square": medium && square, "rcx-button--large-square": large && square, ref: ref }, extraProps, props),
2383
+ return (react_1.default.createElement(Box_1.default, __assign({ is: is, type: 'button', "rcx-button": true }, kindAndVariantProps, { "rcx-button--small": small, "rcx-button--medium": medium, "rcx-button--large": large, "rcx-button--square": square, "rcx-button--tiny-square": tiny && square, "rcx-button--mini-square": mini && square, "rcx-button--small-square": small && square, "rcx-button--medium-square": medium && square, "rcx-button--large-square": large && square, "rcx-button--loading": loading, disabled: disabled || loading, ref: ref }, extraProps, props),
2384
2384
  react_1.default.createElement("span", { className: 'rcx-button--content' },
2385
- icon && react_1.default.createElement(Icon_1.Icon, { size: 'x16', name: icon, mie: 4 }),
2385
+ icon && !loading && react_1.default.createElement(Icon_1.Icon, { size: 'x16', name: icon, mie: 4 }),
2386
+ loading && react_1.default.createElement(Icon_1.Icon, { size: 'x16', name: 'loading', mie: 4 }),
2386
2387
  children)));
2387
2388
  });
2388
2389
  exports["default"] = exports.Button;
@@ -2661,9 +2662,7 @@ var Callout = function (_a) {
2661
2662
  (type === 'warning' && 'warning') ||
2662
2663
  (type === 'danger' && 'ban') ||
2663
2664
  'info-circled';
2664
- return (react_1.default.createElement(Box_1.default, __assign({ is: 'section', className: [
2665
- "rcx-callout ".concat(type && "rcx-callout--".concat(type), " ").concat(className || ''),
2666
- ]
2665
+ return (react_1.default.createElement(Box_1.default, __assign({ is: 'section', className: ['rcx-callout', type && "rcx-callout--".concat(type), className]
2667
2666
  .filter(Boolean)
2668
2667
  .join(' ') }, props),
2669
2668
  react_1.default.createElement(Icon_1.Icon, { className: 'rcx-callout__icon', name: icon || defaultIcon, size: 'x20' }),