You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

1 line
4.2 KiB

{"ast":null,"code":"import { defineComponent, inject, unref, openBlock, createElementBlock, Fragment, createElementVNode, renderList, createBlock, createVNode } from 'vue';\nimport ElDescriptionsCell from './descriptions-cell.mjs';\nimport { descriptionsKey } from './token.mjs';\nimport { descriptionsRowProps } from './descriptions-row.mjs';\nimport _export_sfc from '../../../_virtual/plugin-vue_export-helper.mjs';\nconst __default__ = defineComponent({\n name: \"ElDescriptionsRow\"\n});\nconst _sfc_main = /* @__PURE__ */defineComponent({\n ...__default__,\n props: descriptionsRowProps,\n setup(__props) {\n const descriptions = inject(descriptionsKey, {});\n return (_ctx, _cache) => {\n return unref(descriptions).direction === \"vertical\" ? (openBlock(), createElementBlock(Fragment, {\n key: 0\n }, [createElementVNode(\"tr\", null, [(openBlock(true), createElementBlock(Fragment, null, renderList(_ctx.row, (cell, _index) => {\n return openBlock(), createBlock(unref(ElDescriptionsCell), {\n key: `tr1-${_index}`,\n cell,\n tag: \"th\",\n type: \"label\"\n }, null, 8, [\"cell\"]);\n }), 128))]), createElementVNode(\"tr\", null, [(openBlock(true), createElementBlock(Fragment, null, renderList(_ctx.row, (cell, _index) => {\n return openBlock(), createBlock(unref(ElDescriptionsCell), {\n key: `tr2-${_index}`,\n cell,\n tag: \"td\",\n type: \"content\"\n }, null, 8, [\"cell\"]);\n }), 128))])], 64)) : (openBlock(), createElementBlock(\"tr\", {\n key: 1\n }, [(openBlock(true), createElementBlock(Fragment, null, renderList(_ctx.row, (cell, _index) => {\n return openBlock(), createElementBlock(Fragment, {\n key: `tr3-${_index}`\n }, [unref(descriptions).border ? (openBlock(), createElementBlock(Fragment, {\n key: 0\n }, [createVNode(unref(ElDescriptionsCell), {\n cell,\n tag: \"td\",\n type: \"label\"\n }, null, 8, [\"cell\"]), createVNode(unref(ElDescriptionsCell), {\n cell,\n tag: \"td\",\n type: \"content\"\n }, null, 8, [\"cell\"])], 64)) : (openBlock(), createBlock(unref(ElDescriptionsCell), {\n key: 1,\n cell,\n tag: \"td\",\n type: \"both\"\n }, null, 8, [\"cell\"]))], 64);\n }), 128))]));\n };\n }\n});\nvar ElDescriptionsRow = /* @__PURE__ */_export_sfc(_sfc_main, [[\"__file\", \"descriptions-row.vue\"]]);\nexport { ElDescriptionsRow as default };","map":{"version":3,"names":["name","descriptions","inject","descriptionsKey"],"sources":["../../../../../../packages/components/descriptions/src/descriptions-row.vue"],"sourcesContent":["<template>\n <template v-if=\"descriptions.direction === 'vertical'\">\n <tr>\n <template v-for=\"(cell, _index) in row\" :key=\"`tr1-${_index}`\">\n <el-descriptions-cell :cell=\"cell\" tag=\"th\" type=\"label\" />\n </template>\n </tr>\n <tr>\n <template v-for=\"(cell, _index) in row\" :key=\"`tr2-${_index}`\">\n <el-descriptions-cell :cell=\"cell\" tag=\"td\" type=\"content\" />\n </template>\n </tr>\n </template>\n <tr v-else>\n <template v-for=\"(cell, _index) in row\" :key=\"`tr3-${_index}`\">\n <template v-if=\"descriptions.border\">\n <el-descriptions-cell :cell=\"cell\" tag=\"td\" type=\"label\" />\n <el-descriptions-cell :cell=\"cell\" tag=\"td\" type=\"content\" />\n </template>\n <el-descriptions-cell v-else :cell=\"cell\" tag=\"td\" type=\"both\" />\n </template>\n </tr>\n</template>\n\n<script lang=\"ts\" setup>\nimport { inject } from 'vue'\n\nimport ElDescriptionsCell from './descriptions-cell'\nimport { descriptionsKey } from './token'\nimport { descriptionsRowProps } from './descriptions-row'\n\nimport type { IDescriptionsInject } from './descriptions.type'\n\ndefineOptions({\n name: 'ElDescriptionsRow',\n})\n\ndefineProps(descriptionsRowProps)\n\nconst descriptions = inject(descriptionsKey, {} as IDescriptionsInject)\n</script>\n"],"mappings":";;;;;mCAiCc;EACZA,IAAM;AACR;;;;;IAIA,MAAMC,YAAe,GAAAC,MAAA,CAAOC,eAAiB,IAAyB","ignoreList":[]},"metadata":{},"sourceType":"module","externalDependencies":[]}