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 lines
2.2 KiB
1 lines
2.2 KiB
{"ast":null,"code":"import { defineComponent, provide, h, renderSlot } from 'vue';\nimport { useNamespace } from '../../../hooks/use-namespace/index.mjs';\nconst Timeline = defineComponent({\n name: \"ElTimeline\",\n setup(_, {\n slots\n }) {\n const ns = useNamespace(\"timeline\");\n provide(\"timeline\", slots);\n return () => {\n return h(\"ul\", {\n class: [ns.b()]\n }, [renderSlot(slots, \"default\")]);\n };\n }\n});\nexport { Timeline as default };","map":{"version":3,"names":["Timeline","defineComponent","name","setup","_","slots","ns","useNamespace","provide","h","class","b","renderSlot"],"sources":["../../../../../../packages/components/timeline/src/timeline.ts"],"sourcesContent":["import { defineComponent, h, provide, renderSlot } from 'vue'\nimport { useNamespace } from '@element-plus/hooks'\n\nconst Timeline = defineComponent({\n name: 'ElTimeline',\n setup(_, { slots }) {\n const ns = useNamespace('timeline')\n\n provide('timeline', slots)\n\n /**\n * Maybe ,this component will not support prop 'reverse', why ?\n *\n * Example 1:\n * <component-a>\n * <div>1</div>\n * <div>2</div>\n * </component-a>\n *\n * Example 2:\n * <component-a>\n * <div v-for=\"i in 2\" :key=\"i\">{{ i }}</div>\n * </component-a>\n *\n * 'slots.default()' value in example 1 just like [Vnode, Vnode]\n * 'slots.default()' value in example 2 just like [Vnode]\n *\n * so i can't reverse the slots, when i use 'v-for' directive.\n */\n\n return () => {\n return h('ul', { class: [ns.b()] }, [renderSlot(slots, 'default')])\n }\n },\n})\n\nexport default Timeline\nexport type TimelineInstance = InstanceType<typeof Timeline>\n"],"mappings":";;AAEK,MAACA,QAAQ,GAAGC,eAAe,CAAC;EAC/BC,IAAI,EAAE,YAAY;EAClBC,KAAKA,CAACC,CAAC,EAAE;IAAEC;EAAK,CAAE,EAAE;IAClB,MAAMC,EAAE,GAAGC,YAAY,CAAC,UAAU,CAAC;IACnCC,OAAO,CAAC,UAAU,EAAEH,KAAK,CAAC;IAC1B,OAAO,MAAM;MACX,OAAOI,CAAC,CAAC,IAAI,EAAE;QAAEC,KAAK,EAAE,CAACJ,EAAE,CAACK,CAAC,EAAE;MAAC,CAAE,EAAE,CAACC,UAAU,CAACP,KAAK,EAAE,SAAS,CAAC,CAAC,CAAC;IACzE,CAAK;EACL;AACA,CAAC","ignoreList":[]},"metadata":{},"sourceType":"module","externalDependencies":[]}
|