"use strict";var e=require("prop-types"),t=require("@material-ui/core"),r=require("../../../utils/mobileDetect.js"),i=require("../../Attachment/index.js"),a=require("../../UserMention/utils/index.js"),s=require("../../CollapsibleContent.js"),u=require("react/jsx-runtime");function n(e){return e&&"object"==typeof e&&"default"in e?e:{default:e}}var d=n(e),l=t.makeStyles({wrapper:{whiteSpace:"pre-wrap"}}),o=function(e){var n=e.feedItem,d=n.context.post,o=d.body,m=d.attachment,p=void 0===m?{}:m,c=n.mentioned_users,f=l(),h=p.signed_url||p.url||p.file_name;return u.jsxs("div",{className:f.wrapper,children:[o&&u.jsx(s,{children:u.jsx(t.Typography,{"data-testid":"".concat("PostFeedItem","_message"),variant:"body1",gutterBottom:!0,children:a.formatMentionText(o,c,r.isNativeDetected)})}),h&&u.jsx(i,{attachmentUrl:p.signed_url||p.url,fileName:p.file_name,attachmentSize:p.size,size:"medium"})]})};o.propTypes={feedItem:d.default.shape({context:d.default.shape({post:d.default.shape({body:d.default.string.isRequired,attachment:d.default.shape({url:d.default.string,size:d.default.number})}).isRequired}).isRequired,mentioned_users:d.default.arrayOf(d.default.shape({}))}).isRequired},module.exports=o;
