'use strict';

Object.defineProperty(exports, '__esModule', { value: true });

var clsx = require('clsx');
var Body = require('../body/Body.js');
var jsxRuntime = require('react/jsx-runtime');

const LegacyListItem = ({
  media,
  action,
  className,
  title,
  value,
  isContainerAligned,
  as = 'li',
  ...rest
}) => {
  const Element = as;
  return /*#__PURE__*/jsxRuntime.jsxs(Element, {
    className: clsx.clsx('np-list-item d-flex align-items-center p-y-2', className, {
      'p-x-2': !isContainerAligned
    }),
    ...rest,
    children: [media, /*#__PURE__*/jsxRuntime.jsxs("div", {
      className: clsx.clsx('d-flex flex-column', {
        'p-l-2': !!media,
        'p-r-2': !!action
      }),
      children: [/*#__PURE__*/jsxRuntime.jsx(Body.default, {
        type: "body-default",
        className: "text-secondary m-b-0",
        children: title
      }), value && /*#__PURE__*/jsxRuntime.jsx(Body.default, {
        type: "body-large",
        className: "text-primary text-overflow-wrap m-b-0",
        children: value
      })]
    }), action ? /*#__PURE__*/jsxRuntime.jsx("div", {
      className: "np-list-item__action m-l-auto",
      children: action
    }) : null]
  });
};

exports.default = LegacyListItem;
//# sourceMappingURL=LegacyListItem.js.map
