'use strict';

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

var headerText = require('./headerText-2eeecf55.js');
var paragraphText = require('./paragraphText-6f209f78.js');
var normalText = require('./normalText-7b937f11.js');
var vue = require('vue');

var script = {
    components: {
        TsHeaderText: headerText.script,
        TsParagraphText: paragraphText.script,
        TsNormalText: normalText.script,
    },
    props: {
        data: {
            type: Array,
            required: true,
        },
    },
    name: "TsTransactionHistory",
};

const _hoisted_1 = { class: "flex flex-col w-full col-span-full space-y-2" };
const _hoisted_2 = { class: "mdlg:!px-3 mdlg:!py-3 px-2 py-2 border-[1px] mdlg:!space-y-0 space-y-1 border-gray-200 rounded flex mdlg:!flex-row flex-col mdlg:!items-center items-start" };
const _hoisted_3 = { class: "mdlg:!w-[20%] w-full flex mdlg:!flex-row flex-row justify-between" };
const _hoisted_4 = /*#__PURE__*/vue.createTextVNode(" Date ");
const _hoisted_5 = /*#__PURE__*/vue.createTextVNode(" Amount ");
const _hoisted_6 = { class: "mdlg:!w-[65%] w-full flex mdlg:!flex-row flex-col mdlg:!justify-between items-start mdlg:!space-y-0 space-y-1" };
const _hoisted_7 = /*#__PURE__*/vue.createTextVNode(" Details ");
const _hoisted_8 = { class: "mdlg:!w-[15%] w-[50%] flex-row justify-end mdlg:!flex hidden" };
const _hoisted_9 = /*#__PURE__*/vue.createTextVNode(" Amount ");
const _hoisted_10 = { class: "mdlg:!w-[20%] w-full flex mdlg:!flex-row flex-row mdlg:!justify-start justify-between" };
const _hoisted_11 = { class: "mdlg:!w-[65%] w-full flex flex-row space-x-2 items-center" };
const _hoisted_12 = /*#__PURE__*/vue.createElementVNode("span", {
  class: /*#__PURE__*/vue.normalizeClass(`h-[4px] mr-2 w-[4px] bg-paragraphTextLight rounded-full`)
}, null, -1 /* HOISTED */);
const _hoisted_13 = { class: "mdlg:!w-[15%] w-[10%] mdlg:!flex hidden flex-row justify-end" };

function render(_ctx, _cache, $props, $setup, $data, $options) {
  const _component_ts_header_text = vue.resolveComponent("ts-header-text");
  const _component_ts_paragraph_text = vue.resolveComponent("ts-paragraph-text");
  const _component_ts_normal_text = vue.resolveComponent("ts-normal-text");

  return (vue.openBlock(), vue.createElementBlock("div", _hoisted_1, [
    vue.createElementVNode("div", _hoisted_2, [
      vue.createElementVNode("div", _hoisted_3, [
        vue.createVNode(_component_ts_header_text, { size: 'base' }, {
          default: vue.withCtx(() => [
            _hoisted_4
          ]),
          _: 1 /* STABLE */
        }),
        vue.createVNode(_component_ts_header_text, {
          size: 'base',
          customClass: 'inline mdlg:!hidden'
        }, {
          default: vue.withCtx(() => [
            _hoisted_5
          ]),
          _: 1 /* STABLE */
        })
      ]),
      vue.createElementVNode("div", _hoisted_6, [
        vue.createVNode(_component_ts_header_text, { size: 'base' }, {
          default: vue.withCtx(() => [
            _hoisted_7
          ]),
          _: 1 /* STABLE */
        })
      ]),
      vue.createElementVNode("div", _hoisted_8, [
        vue.createVNode(_component_ts_header_text, { size: 'base' }, {
          default: vue.withCtx(() => [
            _hoisted_9
          ]),
          _: 1 /* STABLE */
        })
      ])
    ]),
    (vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList($props.data, (transaction, index) => {
      return (vue.openBlock(), vue.createElementBlock("div", {
        class: "mdlg:!px-3 mdlg:!py-3 px-2 py-2 border-[1px] border-gray-200 rounded flex mdlg:!flex-row mdlg:!space-y-0 space-y-1 flex-col mdlg:!items-center items-start",
        key: index
      }, [
        vue.createElementVNode("div", _hoisted_10, [
          vue.createVNode(_component_ts_paragraph_text, { faded: true }, {
            default: vue.withCtx(() => [
              vue.createTextVNode(vue.toDisplayString(transaction.date), 1 /* TEXT */)
            ]),
            _: 2 /* DYNAMIC */
          }, 1024 /* DYNAMIC_SLOTS */),
          vue.createVNode(_component_ts_normal_text, {
            customClass: 'inline-block mdlg:!hidden',
            color: `${
            transaction.type == 'credit' ? 'text-primaryGreen' : 'text-errorColor'
          }`
          }, {
            default: vue.withCtx(() => [
              vue.createTextVNode(vue.toDisplayString(transaction.amount), 1 /* TEXT */)
            ]),
            _: 2 /* DYNAMIC */
          }, 1032 /* PROPS, DYNAMIC_SLOTS */, ["color"])
        ]),
        vue.createElementVNode("div", _hoisted_11, [
          (vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList(transaction.content, (name, index) => {
            return (vue.openBlock(), vue.createBlock(_component_ts_normal_text, {
              key: index,
              color: 'text-paragraphTextLight'
            }, {
              default: vue.withCtx(() => [
                (index == 0)
                  ? (vue.openBlock(), vue.createElementBlock(vue.Fragment, { key: 0 }, [
                      vue.createTextVNode(vue.toDisplayString(name), 1 /* TEXT */)
                    ], 64 /* STABLE_FRAGMENT */))
                  : (vue.openBlock(), vue.createElementBlock(vue.Fragment, { key: 1 }, [
                      _hoisted_12,
                      vue.createTextVNode(" " + vue.toDisplayString(name), 1 /* TEXT */)
                    ], 64 /* STABLE_FRAGMENT */))
              ]),
              _: 2 /* DYNAMIC */
            }, 1024 /* DYNAMIC_SLOTS */))
          }), 128 /* KEYED_FRAGMENT */))
        ]),
        vue.createElementVNode("div", _hoisted_13, [
          vue.createVNode(_component_ts_normal_text, {
            color: `${
            transaction.type == 'credit' ? 'text-primaryGreen' : 'text-errorColor'
          }`
          }, {
            default: vue.withCtx(() => [
              vue.createTextVNode(vue.toDisplayString(transaction.amount), 1 /* TEXT */)
            ]),
            _: 2 /* DYNAMIC */
          }, 1032 /* PROPS, DYNAMIC_SLOTS */, ["color"])
        ])
      ]))
    }), 128 /* KEYED_FRAGMENT */))
  ]))
}

script.render = render;
script.__file = "src/components/TsTransactionHistory/index.vue";

exports["default"] = script;
