casc-cesium
Version:
Vue 3.x components for CesiumJS.
1 lines • 3.68 kB
Source Map (JSON)
{"version":3,"file":"index.mjs","sources":["../../../../../../packages/components/geometries/polyline-volume/index.ts"],"sourcesContent":["/*\n * @Author: zouyaoji@https://github.com/zouyaoji\n * @Date: 2021-09-16 09:28:13\n * @LastEditTime: 2022-03-30 11:40:36\n * @LastEditors: zouyaoji\n * @Description:\n * @FilePath: \\vue-cesium@next\\packages\\components\\geometries\\polyline-volume\\index.ts\n */\nimport { VcCartesian2Array, VcCartesian3Array, VcComponentInternalInstance, VcComponentPublicInstance, VcReadyObject } from 'casc-cesium-utils/types'\nimport { defineComponent, getCurrentInstance, createCommentVNode } from 'vue'\nimport { useGeometries } from 'casc-cesium-composables'\nimport { kebabCase } from 'casc-cesium-utils/util'\nimport { polylinePositions, shapePositions, ellipsoid, granularity, vertexFormat, cornerType } from 'casc-cesium-utils/cesium-props'\nimport { commonEmits } from 'casc-cesium-utils/emits'\nexport const polylineVolumeGeometryProps = {\n ...polylinePositions,\n ...shapePositions,\n ...ellipsoid,\n ...granularity,\n ...vertexFormat,\n ...cornerType\n}\nexport default defineComponent({\n name: 'VcGeometryPolylineVolume',\n props: polylineVolumeGeometryProps,\n emits: commonEmits,\n setup(props, ctx) {\n // state\n const instance = getCurrentInstance() as VcComponentInternalInstance\n instance.cesiumClass = 'PolylineVolumeGeometry'\n useGeometries(props, ctx, instance)\n\n return () => createCommentVNode(kebabCase(instance.proxy?.$options.name || 'v-if'))\n }\n})\n\nexport type VcGeometryPolylineVolumeProps = {\n /**\n * An array of VcCartesian3Array positions that define the center of the polyline volume.\n */\n polylinePositions: VcCartesian3Array\n /**\n * An array of VcCartesian2Array positions that define the shape to be extruded along the polyline.\n */\n shapePositions: VcCartesian2Array\n /**\n * The ellipsoid to be used as a reference.\n */\n ellipsoid?: Cesium.Ellipsoid\n /**\n * The distance, in radians, between each latitude and longitude. Determines the number of positions in the buffer.\n */\n granularity?: number\n /**\n * The vertex attributes to be computed.\n */\n vertexFormat: Cesium.VertexFormat\n /**\n * Determines the style of the corners.\n */\n cornerType?: number | Cesium.CornerType\n /**\n * Triggers before the VcGeometryPolylineVolume is loaded\n */\n onBeforeLoad?: (instance: VcComponentInternalInstance) => void\n /**\n * Triggers when the VcGeometryPolylineVolume is successfully loaded\n */\n onReady?: (readyObject: VcReadyObject) => void\n /**\n * Triggers when the component load failed.\n */\n onUnready?: (e: any) => void\n /**\n * Triggers when the VcGeometryPolylineVolume is destroyed\n */\n onDestroyed?: (instance: VcComponentInternalInstance) => void\n}\n\nexport type VcGeometryPolylineVolumeRef = VcComponentPublicInstance<VcGeometryPolylineVolumeProps>\n"],"names":[],"mappings":";;;;;;;AAKY,MAAC,2BAA2B,GAAG;AAC3C,EAAE,GAAG,iBAAiB;AACtB,EAAE,GAAG,cAAc;AACnB,EAAE,GAAG,SAAS;AACd,EAAE,GAAG,WAAW;AAChB,EAAE,GAAG,YAAY;AACjB,EAAE,GAAG,UAAU;AACf,EAAE;AACF,6BAAe,eAAe,CAAC;AAC/B,EAAE,IAAI,EAAE,0BAA0B;AAClC,EAAE,KAAK,EAAE,2BAA2B;AACpC,EAAE,KAAK,EAAE,WAAW;AACpB,EAAE,KAAK,CAAC,KAAK,EAAE,GAAG,EAAE;AACpB,IAAI,MAAM,QAAQ,GAAG,kBAAkB,EAAE,CAAC;AAC1C,IAAI,QAAQ,CAAC,WAAW,GAAG,wBAAwB,CAAC;AACpD,IAAI,aAAa,CAAC,KAAK,EAAE,GAAG,EAAE,QAAQ,CAAC,CAAC;AACxC,IAAI,OAAO,MAAM;AACjB,MAAM,IAAI,EAAE,CAAC;AACb,MAAM,OAAO,kBAAkB,CAAC,SAAS,CAAC,CAAC,CAAC,EAAE,GAAG,QAAQ,CAAC,KAAK,KAAK,IAAI,GAAG,KAAK,CAAC,GAAG,EAAE,CAAC,QAAQ,CAAC,IAAI,KAAK,MAAM,CAAC,CAAC,CAAC;AAClH,KAAK,CAAC;AACN,GAAG;AACH,CAAC,CAAC;;;;"}