@tak-ps/cloudtak 12.135.0 → 12.136.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import type { Feature } from '../../types.ts';
|
|
2
|
+
import type { COTMutationContext, COTUpdate } from './types.ts';
|
|
3
|
+
import type { Geometry as GeoJSONGeometry } from 'geojson';
|
|
4
|
+
export declare const ELLIPSE_TYPE_PREFIXES: string[];
|
|
5
|
+
export type EllipseShape = {
|
|
6
|
+
major: number;
|
|
7
|
+
minor: number;
|
|
8
|
+
angle: number;
|
|
9
|
+
swapAxis?: boolean;
|
|
10
|
+
};
|
|
11
|
+
export type EllipseDefinition = {
|
|
12
|
+
center: [number, number];
|
|
13
|
+
shape: EllipseShape;
|
|
14
|
+
};
|
|
15
|
+
export declare function isEllipseType(type: unknown): boolean;
|
|
16
|
+
export declare function readEllipseDefinition(properties: Feature['properties']): EllipseDefinition | undefined;
|
|
17
|
+
export declare function createCircleEllipseShape(radiusMeters: number, angle?: number): {
|
|
18
|
+
ellipse: EllipseShape;
|
|
19
|
+
};
|
|
20
|
+
export declare function buildEllipseGeometry(properties: Feature['properties']): GeoJSONGeometry | undefined;
|
|
21
|
+
export declare function hasEllipseMutation(currentProperties: Feature['properties'], nextProperties: Feature['properties']): boolean;
|
|
22
|
+
export declare function setCircleRadius(properties: Feature['properties'], radiusMeters: number): Feature['properties'];
|
|
23
|
+
export declare function applyEllipseMutation(context: COTMutationContext): COTUpdate | undefined;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import type { Feature } from '../../types.ts';
|
|
2
|
+
export type COTUpdate = {
|
|
3
|
+
path?: string;
|
|
4
|
+
properties?: Feature['properties'];
|
|
5
|
+
geometry?: Feature['geometry'];
|
|
6
|
+
};
|
|
7
|
+
export type COTMutationContext = {
|
|
8
|
+
current: Feature;
|
|
9
|
+
update: COTUpdate;
|
|
10
|
+
};
|
|
11
|
+
export type COTMutation = (context: COTMutationContext) => COTUpdate | undefined;
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import type { COTUpdate } from './cot/types.ts';
|
|
1
2
|
import type { Feature, Subscription } from '../types.ts';
|
|
2
3
|
import type { BBox as GeoJSONBBox, Feature as GeoJSONFeature, Geometry as GeoJSONGeometry } from 'geojson';
|
|
3
4
|
export interface Origin {
|
|
@@ -44,11 +45,7 @@ export default class COT {
|
|
|
44
45
|
/**
|
|
45
46
|
* Update the COT and return a boolean as to whether the COT needs to be re-rendered
|
|
46
47
|
*/
|
|
47
|
-
update(update: {
|
|
48
|
-
path?: string;
|
|
49
|
-
properties?: Feature["properties"];
|
|
50
|
-
geometry?: Feature["geometry"];
|
|
51
|
-
}, opts?: {
|
|
48
|
+
update(update: COTUpdate, opts?: {
|
|
52
49
|
skipSave?: boolean;
|
|
53
50
|
}): Promise<boolean>;
|
|
54
51
|
/**
|
|
@@ -21,6 +21,7 @@ declare const __VLS_export: import("vue").DefineComponent<import("vue").ExtractP
|
|
|
21
21
|
};
|
|
22
22
|
}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
|
|
23
23
|
"update:modelValue": (...args: any[]) => void;
|
|
24
|
+
submit: (...args: any[]) => void;
|
|
24
25
|
}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
|
|
25
26
|
label: {
|
|
26
27
|
type: StringConstructor;
|
|
@@ -44,6 +45,7 @@ declare const __VLS_export: import("vue").DefineComponent<import("vue").ExtractP
|
|
|
44
45
|
};
|
|
45
46
|
}>> & Readonly<{
|
|
46
47
|
"onUpdate:modelValue"?: ((...args: any[]) => any) | undefined;
|
|
48
|
+
onSubmit?: ((...args: any[]) => any) | undefined;
|
|
47
49
|
}>, {
|
|
48
50
|
label: string;
|
|
49
51
|
hover: boolean;
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@tak-ps/cloudtak",
|
|
3
3
|
"type": "module",
|
|
4
|
-
"version": "12.
|
|
4
|
+
"version": "12.136.0",
|
|
5
5
|
"types": "dist/types/plugin.d.ts",
|
|
6
6
|
"files": [
|
|
7
7
|
"dist/types"
|
|
@@ -22,7 +22,7 @@
|
|
|
22
22
|
"doc": "typedoc --options typedoc.json",
|
|
23
23
|
"build": "vite build",
|
|
24
24
|
"lint": "eslint --config eslint.config.js ./src/ ./public/ ./plugins/",
|
|
25
|
-
"test": "
|
|
25
|
+
"test": "vitest run"
|
|
26
26
|
},
|
|
27
27
|
"repository": {
|
|
28
28
|
"type": "git",
|