@sproutsocial/seeds-react-message 1.0.0 → 1.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/dist/index.js CHANGED
@@ -28,13 +28,13 @@ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__ge
28
28
  var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
29
29
 
30
30
  // src/index.ts
31
- var src_exports = {};
32
- __export(src_exports, {
31
+ var index_exports = {};
32
+ __export(index_exports, {
33
33
  MESSAGE_DENSITIES: () => MESSAGE_DENSITIES,
34
34
  Message: () => Message_default,
35
- default: () => src_default2
35
+ default: () => index_default2
36
36
  });
37
- module.exports = __toCommonJS(src_exports);
37
+ module.exports = __toCommonJS(index_exports);
38
38
 
39
39
  // src/Message.tsx
40
40
  var React2 = __toESM(require("react"));
@@ -117,8 +117,7 @@ function _isNativeReflectConstruct() {
117
117
 
118
118
  // ../../node_modules/@babel/runtime/helpers/esm/construct.js
119
119
  function _construct(t, e, r) {
120
- if (_isNativeReflectConstruct())
121
- return Reflect.construct.apply(null, arguments);
120
+ if (_isNativeReflectConstruct()) return Reflect.construct.apply(null, arguments);
122
121
  var o = [null];
123
122
  o.push.apply(o, e);
124
123
  var p = new (t.bind.apply(t, o))();
@@ -129,14 +128,12 @@ function _construct(t, e, r) {
129
128
  function _wrapNativeSuper(Class) {
130
129
  var _cache = typeof Map === "function" ? /* @__PURE__ */ new Map() : void 0;
131
130
  _wrapNativeSuper = function _wrapNativeSuper2(Class2) {
132
- if (Class2 === null || !_isNativeFunction(Class2))
133
- return Class2;
131
+ if (Class2 === null || !_isNativeFunction(Class2)) return Class2;
134
132
  if (typeof Class2 !== "function") {
135
133
  throw new TypeError("Super expression must either be null or a function");
136
134
  }
137
135
  if (typeof _cache !== "undefined") {
138
- if (_cache.has(Class2))
139
- return _cache.get(Class2);
136
+ if (_cache.has(Class2)) return _cache.get(Class2);
140
137
  _cache.set(Class2, Wrapper);
141
138
  }
142
139
  function Wrapper() {
@@ -459,8 +456,7 @@ var namedColorMap = {
459
456
  yellowgreen: "9acd32"
460
457
  };
461
458
  function nameToHex(color) {
462
- if (typeof color !== "string")
463
- return color;
459
+ if (typeof color !== "string") return color;
464
460
  var normalizedColorName = color.toLowerCase();
465
461
  return namedColorMap[normalizedColorName] ? "#" + namedColorMap[normalizedColorName] : color;
466
462
  }
@@ -603,8 +599,7 @@ function guard(lowerBoundary, upperBoundary, value) {
603
599
  return Math.max(lowerBoundary, Math.min(upperBoundary, value));
604
600
  }
605
601
  function transparentize(amount, color) {
606
- if (color === "transparent")
607
- return color;
602
+ if (color === "transparent") return color;
608
603
  var parsedColor = parseToRgb(color);
609
604
  var alpha = typeof parsedColor.alpha === "number" ? parsedColor.alpha : 1;
610
605
  var colorWithAlpha = _extends({}, parsedColor, {
@@ -614,7 +609,7 @@ function transparentize(amount, color) {
614
609
  }
615
610
  var curriedTransparentize = /* @__PURE__ */ curry(transparentize);
616
611
 
617
- // ../seeds-react-mixins/src/index.ts
612
+ // ../seeds-react-mixins/dist/esm/index.js
618
613
  var import_styled_components = require("styled-components");
619
614
  var import_seeds_react_theme = require("@sproutsocial/seeds-react-theme");
620
615
  var visuallyHidden = import_styled_components.css`
@@ -679,7 +674,7 @@ var Box = React.forwardRef(
679
674
  );
680
675
  Box.displayName = "Box";
681
676
  var Box_default = Box;
682
- var src_default = Box_default;
677
+ var index_default = Box_default;
683
678
 
684
679
  // src/constants.ts
685
680
  var MESSAGE_DENSITIES = {
@@ -691,7 +686,7 @@ var MESSAGE_DENSITIES = {
691
686
  };
692
687
 
693
688
  // src/styles.ts
694
- var Container2 = (0, import_styled_components3.default)(src_default)`
689
+ var Container2 = (0, import_styled_components3.default)(index_default)`
695
690
  border-radius: ${(props) => props.theme.radii.outer};
696
691
  border-width: ${(props) => props.theme.borderWidths[500]};
697
692
  border-style: solid;
@@ -703,7 +698,7 @@ var Container2 = (0, import_styled_components3.default)(src_default)`
703
698
  }
704
699
  `;
705
700
  Container2.displayName = "Message.Container";
706
- var MessageHeader = (0, import_react.memo)((0, import_styled_components3.default)(src_default)`
701
+ var MessageHeader = (0, import_react.memo)((0, import_styled_components3.default)(index_default)`
707
702
  padding: ${(props) => props.density === MESSAGE_DENSITIES.CONDENSED ? `0 0 0 ${props.theme.space[100]}` : props.theme.space[300]};
708
703
  display: flex;
709
704
  justify-content: space-between;
@@ -746,13 +741,13 @@ var messagePadding = ({
746
741
  }
747
742
  return theme2.space[400];
748
743
  };
749
- var MessageBody = (0, import_styled_components3.default)(src_default)`
744
+ var MessageBody = (0, import_styled_components3.default)(index_default)`
750
745
  padding: ${messagePadding} ${messagePadding} ${messagePadding}
751
746
  ${(props) => getContentPadding(props)};
752
747
  font-family: ${(props) => props.theme.fontFamily};
753
748
  ${(props) => props.density === MESSAGE_DENSITIES.COMPACT || props.density === MESSAGE_DENSITIES.CONDENSED ? props.theme.typography[200] : props.theme.typography[300]};
754
749
  `;
755
- var MessageFooter = (0, import_styled_components3.default)(src_default)`
750
+ var MessageFooter = (0, import_styled_components3.default)(index_default)`
756
751
  padding-bottom: ${(props) => props.density === MESSAGE_DENSITIES.CONDENSED ? 0 : props.theme.space[300]};
757
752
  padding-left: ${(props) => getContentPadding(props)};
758
753
  padding-right: ${(props) => props.density === MESSAGE_DENSITIES.CONDENSED ? 0 : props.theme.space[300]};
@@ -763,7 +758,7 @@ var MessageFooter = (0, import_styled_components3.default)(src_default)`
763
758
  align-items: center;
764
759
  flex-wrap: ${(props) => props.density === MESSAGE_DENSITIES.CONDENSED ? "nowrap" : "wrap"};
765
760
  `;
766
- var MessageMeta = (0, import_styled_components3.default)(src_default)`
761
+ var MessageMeta = (0, import_styled_components3.default)(index_default)`
767
762
  background: none;
768
763
  border-width: 0;
769
764
  border-style: none;
@@ -910,7 +905,7 @@ var Message_default = Message;
910
905
  var React3 = require("react");
911
906
 
912
907
  // src/index.ts
913
- var src_default2 = Message_default;
908
+ var index_default2 = Message_default;
914
909
  // Annotate the CommonJS export names for ESM import in node:
915
910
  0 && (module.exports = {
916
911
  MESSAGE_DENSITIES,