UNPKG

casc-cesium

Version:

Vue 3.x components for CesiumJS.

1 lines 2.09 kB
{"version":3,"file":"render.mjs","sources":["../../../../../packages/utils/private/render.ts"],"sourcesContent":["import { h, withDirectives } from 'vue'\n\nexport function hSlot(slot, otherwise?) {\n return slot !== void 0 ? slot() : otherwise\n}\n\nexport function hUniqueSlot(slot, otherwise) {\n return slot !== void 0 ? slot().slice() : otherwise\n}\n\n/**\n * Source definitely exists,\n * so it's merged with the possible slot\n */\nexport function hMergeSlot(slot, source) {\n return slot !== void 0 ? source.concat(slot()) : source\n}\n\n/**\n * Merge with possible slot,\n * even if source might not exist\n */\nexport function hMergeSlotSafely(slot, source) {\n if (slot === void 0) {\n return source\n }\n\n return source !== void 0 ? source.concat(slot()) : slot()\n}\n\n/*\n * (String) key - unique vnode key\n * (Boolean) condition - should change ONLY when adding/removing directive\n */\nexport function hDir(tag, data, children?, key?, condition?, getDirsFn?) {\n data.key = key + condition\n\n const vnode = h(tag, data, children)\n\n return condition === true ? withDirectives(vnode, getDirsFn()) : vnode\n}\n"],"names":[],"mappings":";;AACO,SAAS,KAAK,CAAC,IAAI,EAAE,SAAS,EAAE;AACvC,EAAE,OAAO,IAAI,KAAK,KAAK,CAAC,GAAG,IAAI,EAAE,GAAG,SAAS,CAAC;AAC9C,CAAC;AACM,SAAS,WAAW,CAAC,IAAI,EAAE,SAAS,EAAE;AAC7C,EAAE,OAAO,IAAI,KAAK,KAAK,CAAC,GAAG,IAAI,EAAE,CAAC,KAAK,EAAE,GAAG,SAAS,CAAC;AACtD,CAAC;AACM,SAAS,UAAU,CAAC,IAAI,EAAE,MAAM,EAAE;AACzC,EAAE,OAAO,IAAI,KAAK,KAAK,CAAC,GAAG,MAAM,CAAC,MAAM,CAAC,IAAI,EAAE,CAAC,GAAG,MAAM,CAAC;AAC1D,CAAC;AACM,SAAS,gBAAgB,CAAC,IAAI,EAAE,MAAM,EAAE;AAC/C,EAAE,IAAI,IAAI,KAAK,KAAK,CAAC,EAAE;AACvB,IAAI,OAAO,MAAM,CAAC;AAClB,GAAG;AACH,EAAE,OAAO,MAAM,KAAK,KAAK,CAAC,GAAG,MAAM,CAAC,MAAM,CAAC,IAAI,EAAE,CAAC,GAAG,IAAI,EAAE,CAAC;AAC5D,CAAC;AACM,SAAS,IAAI,CAAC,GAAG,EAAE,IAAI,EAAE,QAAQ,EAAE,GAAG,EAAE,SAAS,EAAE,SAAS,EAAE;AACrE,EAAE,IAAI,CAAC,GAAG,GAAG,GAAG,GAAG,SAAS,CAAC;AAC7B,EAAE,MAAM,KAAK,GAAG,CAAC,CAAC,GAAG,EAAE,IAAI,EAAE,QAAQ,CAAC,CAAC;AACvC,EAAE,OAAO,SAAS,KAAK,IAAI,GAAG,cAAc,CAAC,KAAK,EAAE,SAAS,EAAE,CAAC,GAAG,KAAK,CAAC;AACzE;;;;"}