"use strict";

import React from 'react';
import { LastRoomMessageContainer, LastRoomMessageName, LastRoomMessageText } from './StyledRoomComponents';
import styled from 'styled-components/native';
import { PlayIcon } from '../../../assets/icons';
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
const PlayButton = styled.View`
  width: 20px;
  height: 20px;
  border-radius: 10px;
  display: flex;
  justify-content: center;
  align-items: center;
  background-color: #d8ecff;
  margin-top: 1px;
`;
const AudioRow = styled.View`
  flex-direction: row;
  align-items: center;
  gap: 6px;
`;
const LastAudioMessage = ({
  user,
  body
}) => {
  return /*#__PURE__*/_jsxs(LastRoomMessageContainer, {
    children: [/*#__PURE__*/_jsx(LastRoomMessageName, {
      numberOfLines: 1,
      children: user?.name ?? ''
    }), /*#__PURE__*/_jsxs(AudioRow, {
      children: [/*#__PURE__*/_jsx(PlayButton, {
        children: /*#__PURE__*/_jsx(PlayIcon, {
          width: 10,
          height: 10,
          color: "#1F2937"
        })
      }), /*#__PURE__*/_jsx(LastRoomMessageText, {
        numberOfLines: 1,
        children: body?.trim() ? body : 'audio'
      })]
    })]
  });
};
export default LastAudioMessage;
//# sourceMappingURL=LastAudioMessage.js.map