@mappedin/viewer 0.15.6-ebcd108.0 → 0.16.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.
@@ -2,7 +2,7 @@
2
2
  import './lib/i18n';
3
3
  import './fonts.css';
4
4
  import { TStartViewerOptions, TStartViewerWithLocalDataOptions } from './lib/types/options';
5
- import '@mappedin/maker-sdk/lib/index.css';
5
+ import '@mappedin/mappedin-js/lib/index.css';
6
6
  declare const App: ((options: TStartViewerOptions | TStartViewerWithLocalDataOptions) => import("react").JSX.Element) & {
7
7
  displayName: string;
8
8
  };
@@ -3,8 +3,8 @@ type TDetailsSectionProps = {
3
3
  name: string;
4
4
  description?: string;
5
5
  links?: {
6
+ name: string;
6
7
  url: string;
7
- displayName: string;
8
8
  }[];
9
9
  collapsible?: boolean;
10
10
  };
@@ -3,7 +3,10 @@ import DetailsSection from './details-section';
3
3
  export type TMetadataCardProps = {
4
4
  name: ComponentProps<typeof DetailsSection>['name'];
5
5
  description?: ComponentProps<typeof DetailsSection>['description'];
6
- links?: ComponentProps<typeof DetailsSection>['links'];
6
+ links?: {
7
+ url: string;
8
+ name?: string;
9
+ }[];
7
10
  imageURLs?: string[];
8
11
  onRequestClose?: () => void;
9
12
  onDirectionsClick?: () => void;
@@ -1,7 +1,7 @@
1
1
  /// <reference types="react" />
2
2
  type TLinkItemProps = {
3
3
  url: string;
4
- displayName: string;
4
+ name: string;
5
5
  };
6
6
  declare const LinkItem: React.FC<TLinkItemProps>;
7
7
  export default LinkItem;
@@ -1,4 +1,4 @@
1
- import { MapData, Space, MapObject, PointOfInterest, Connection, Annotation, Coordinate, Door } from '@mappedin/maker-sdk';
1
+ import { MapData, Space, MapObject, PointOfInterest, Connection, Annotation, Coordinate, Door } from '@mappedin/mappedin-js';
2
2
  export declare const loadData: (mapId: string, url?: string) => Promise<MapData>;
3
3
  export declare const loadAnnotationAsset: (annotation: Annotation) => string | undefined;
4
4
  export declare const isOneOf: <T extends typeof Space | typeof PointOfInterest | typeof Connection | typeof MapObject | typeof Door | typeof Coordinate>(types: T[], object: object) => object is InstanceType<T>;
@@ -8,4 +8,4 @@ export type Place = InstanceType<PlaceType>;
8
8
  export declare const GEOMETRY_TYPES: (typeof Space | typeof MapObject)[];
9
9
  export type GeometryType = (typeof GEOMETRY_TYPES)[number];
10
10
  export type Geometry = InstanceType<GeometryType>;
11
- export * from '@mappedin/maker-sdk';
11
+ export * from '@mappedin/mappedin-js';
@@ -1,4 +1,4 @@
1
- /// <reference types="@mappedin/maker-sdk" />
1
+ /// <reference types="@mappedin/mappedin-js" />
2
2
  import type RootStore from '../../root-store';
3
3
  import type MapStore from '..';
4
4
  declare class DirectionsController {
@@ -11,21 +11,20 @@ declare class DirectionsController {
11
11
  });
12
12
  private updateJourney;
13
13
  get floorsInDirections(): ({
14
- "__#36@#private": any;
14
+ "__#16@#private": any;
15
15
  readonly __type: "floor";
16
16
  readonly name: string;
17
17
  readonly elevation: number;
18
18
  readonly spaces: {
19
- "__#35@#private": any;
19
+ "__#15@#private": any;
20
20
  readonly __type: "space";
21
21
  readonly name: string;
22
- readonly type: string;
22
+ readonly type: import("@mappedin/mappedin-js/maker/src/map-data-objects/space").TSpaceType;
23
23
  readonly description: string;
24
- readonly links: Hyperlink[];
25
24
  readonly images: Image[];
26
25
  readonly floor: any;
27
26
  readonly center: {
28
- "__#39@#private": any;
27
+ "__#19@#private": any;
29
28
  readonly __type: "coordinate";
30
29
  id: string;
31
30
  readonly latitude: number;
@@ -42,7 +41,7 @@ declare class DirectionsController {
42
41
  toJSON(): {
43
42
  id: string;
44
43
  name: string;
45
- type: string;
44
+ type: import("@mappedin/mappedin-js/maker/src/map-data-objects/space").TSpaceType;
46
45
  floor: string;
47
46
  center: {
48
47
  latitude: number;
@@ -52,18 +51,29 @@ declare class DirectionsController {
52
51
  };
53
52
  destroy(): void;
54
53
  readonly id: string;
54
+ links: {
55
+ "__#22@#private": any;
56
+ readonly url: string;
57
+ readonly name: string | undefined;
58
+ toJSON(): {
59
+ id: string;
60
+ url: string;
61
+ name: string | undefined;
62
+ };
63
+ destroy(): void;
64
+ readonly id: string;
65
+ }[];
55
66
  }[];
56
- readonly objects: import("@mappedin/maker-sdk/maker/src/map-data-objects/object").MapObject[];
67
+ readonly objects: import("@mappedin/mappedin-js/maker/src/map-data-objects/object").MapObject[];
57
68
  readonly connections: {
58
- "__#37@#private": any;
69
+ "__#17@#private": any;
59
70
  readonly __type: "connection";
60
71
  readonly name: string;
61
72
  readonly description: string;
62
- readonly links: Hyperlink[];
63
73
  readonly images: Image[];
64
74
  readonly type: string;
65
75
  readonly coordinates: {
66
- "__#39@#private": any;
76
+ "__#19@#private": any;
67
77
  readonly __type: "coordinate";
68
78
  id: string;
69
79
  readonly latitude: number;
@@ -91,17 +101,28 @@ declare class DirectionsController {
91
101
  };
92
102
  destroy(): void;
93
103
  readonly id: string;
104
+ links: {
105
+ "__#22@#private": any;
106
+ readonly url: string;
107
+ readonly name: string | undefined;
108
+ toJSON(): {
109
+ id: string;
110
+ url: string;
111
+ name: string | undefined;
112
+ };
113
+ destroy(): void;
114
+ readonly id: string;
115
+ }[];
94
116
  }[];
95
117
  readonly doors: {
96
- "__#34@#private": any;
118
+ "__#14@#private": any;
97
119
  readonly __type: "door";
98
120
  readonly name: string;
99
121
  readonly description: string;
100
- readonly links: Hyperlink[];
101
122
  readonly images: Image[];
102
123
  readonly floor: any;
103
124
  readonly center: {
104
- "__#39@#private": any;
125
+ "__#19@#private": any;
105
126
  readonly __type: "coordinate";
106
127
  id: string;
107
128
  readonly latitude: number;
@@ -115,44 +136,6 @@ declare class DirectionsController {
115
136
  };
116
137
  destroy(): void;
117
138
  };
118
- readonly adjacentSpaces: {
119
- "__#35@#private": any;
120
- readonly __type: "space";
121
- readonly name: string;
122
- readonly type: string;
123
- readonly description: string;
124
- readonly links: Hyperlink[];
125
- readonly images: Image[];
126
- readonly floor: any;
127
- readonly center: {
128
- "__#39@#private": any;
129
- readonly __type: "coordinate";
130
- id: string;
131
- readonly latitude: number;
132
- readonly longitude: number;
133
- isEqual(coordinate: any): boolean;
134
- readonly floor: any | undefined;
135
- toJSON(): {
136
- latitude: number;
137
- longitude: number;
138
- floor: string | undefined;
139
- };
140
- destroy(): void;
141
- };
142
- toJSON(): {
143
- id: string;
144
- name: string;
145
- type: string;
146
- floor: string;
147
- center: {
148
- latitude: number;
149
- longitude: number;
150
- floor: string | undefined;
151
- };
152
- };
153
- destroy(): void;
154
- readonly id: string;
155
- }[];
156
139
  readonly isExterior: boolean;
157
140
  toJSON(): {
158
141
  id: string;
@@ -163,18 +146,29 @@ declare class DirectionsController {
163
146
  longitude: number;
164
147
  floor: string | undefined;
165
148
  };
166
- adjacentSpaces: string[];
167
149
  };
168
150
  destroy(): void;
169
151
  readonly id: string;
152
+ links: {
153
+ "__#22@#private": any;
154
+ readonly url: string;
155
+ readonly name: string | undefined;
156
+ toJSON(): {
157
+ id: string;
158
+ url: string;
159
+ name: string | undefined;
160
+ };
161
+ destroy(): void;
162
+ readonly id: string;
163
+ }[];
170
164
  }[];
171
165
  readonly annotations: {
172
- "__#41@#private": any;
166
+ "__#21@#private": any;
173
167
  readonly __type: "annotation";
174
168
  readonly group: string;
175
169
  readonly type: string;
176
170
  readonly coordinate: {
177
- "__#39@#private": any;
171
+ "__#19@#private": any;
178
172
  readonly __type: "coordinate";
179
173
  id: string;
180
174
  readonly latitude: number;
@@ -201,17 +195,39 @@ declare class DirectionsController {
201
195
  };
202
196
  destroy(): void;
203
197
  readonly id: string;
198
+ links: {
199
+ "__#22@#private": any;
200
+ readonly url: string;
201
+ readonly name: string | undefined;
202
+ toJSON(): {
203
+ id: string;
204
+ url: string;
205
+ name: string | undefined;
206
+ };
207
+ destroy(): void;
208
+ readonly id: string;
209
+ }[];
204
210
  }[];
205
211
  readonly pois: {
206
- "__#40@#private": any;
212
+ "__#20@#private": any;
207
213
  readonly __type: "point-of-interest";
208
214
  readonly name: string;
209
215
  readonly description: string;
210
- readonly links: Hyperlink[];
211
- readonly images: Image[];
216
+ readonly images: {
217
+ "__#23@#private": any;
218
+ readonly url: string | undefined;
219
+ readonly name: string | undefined;
220
+ toJSON(): {
221
+ id: string;
222
+ url: string | undefined;
223
+ name: string | undefined;
224
+ };
225
+ destroy(): void;
226
+ readonly id: string;
227
+ }[];
212
228
  readonly floor: any;
213
229
  readonly coordinate: {
214
- "__#39@#private": any;
230
+ "__#19@#private": any;
215
231
  readonly __type: "coordinate";
216
232
  id: string;
217
233
  readonly latitude: number;
@@ -237,6 +253,18 @@ declare class DirectionsController {
237
253
  };
238
254
  destroy(): void;
239
255
  readonly id: string;
256
+ links: {
257
+ "__#22@#private": any;
258
+ readonly url: string;
259
+ readonly name: string | undefined;
260
+ toJSON(): {
261
+ id: string;
262
+ url: string;
263
+ name: string | undefined;
264
+ };
265
+ destroy(): void;
266
+ readonly id: string;
267
+ }[];
240
268
  }[];
241
269
  toJSON(): {
242
270
  id: string;
@@ -251,8 +279,20 @@ declare class DirectionsController {
251
279
  };
252
280
  destroy(): void;
253
281
  readonly id: string;
282
+ links: {
283
+ "__#22@#private": any;
284
+ readonly url: string;
285
+ readonly name: string | undefined;
286
+ toJSON(): {
287
+ id: string;
288
+ url: string;
289
+ name: string | undefined;
290
+ };
291
+ destroy(): void;
292
+ readonly id: string;
293
+ }[];
254
294
  } | undefined)[];
255
- get directions(): import("@mappedin/maker-sdk/maker/src/map-view-objects/directions").Directions | undefined;
295
+ get directions(): import("@mappedin/mappedin-js/maker/src/map-view-objects/directions").Directions | undefined;
256
296
  cleanup(): void;
257
297
  }
258
298
  export default DirectionsController;
@@ -43,38 +43,13 @@ declare class RootStore {
43
43
  get places(): Place[];
44
44
  get geometries(): Geometry[];
45
45
  get exteriorDoors(): {
46
- "__#34@#private": any;
46
+ "__#14@#private": any;
47
47
  readonly __type: "door";
48
48
  readonly name: string;
49
49
  readonly description: string;
50
- readonly links: Hyperlink[];
51
50
  readonly images: Image[];
52
51
  readonly floor: Floor;
53
52
  readonly center: Coordinate;
54
- readonly adjacentSpaces: {
55
- "__#35@#private": any;
56
- readonly __type: "space";
57
- readonly name: string;
58
- readonly type: string;
59
- readonly description: string;
60
- readonly links: Hyperlink[];
61
- readonly images: Image[];
62
- readonly floor: Floor;
63
- readonly center: Coordinate;
64
- toJSON(): {
65
- id: string;
66
- name: string;
67
- type: string;
68
- floor: string;
69
- center: {
70
- latitude: number;
71
- longitude: number;
72
- floor: string | undefined;
73
- };
74
- };
75
- destroy(): void;
76
- readonly id: string;
77
- }[];
78
53
  readonly isExterior: boolean;
79
54
  toJSON(): {
80
55
  id: string;
@@ -85,10 +60,21 @@ declare class RootStore {
85
60
  longitude: number;
86
61
  floor: string | undefined;
87
62
  };
88
- adjacentSpaces: string[];
89
63
  };
90
64
  destroy(): void;
91
65
  readonly id: string;
66
+ links: {
67
+ "__#22@#private": any;
68
+ readonly url: string;
69
+ readonly name: string | undefined;
70
+ toJSON(): {
71
+ id: string;
72
+ url: string;
73
+ name: string | undefined;
74
+ };
75
+ destroy(): void;
76
+ readonly id: string;
77
+ }[];
92
78
  }[];
93
79
  /**
94
80
  * Floors in order from highest to lowest elevation.
@@ -1,10 +1,10 @@
1
- /// <reference types="@mappedin/maker-sdk" />
1
+ /// <reference types="@mappedin/mappedin-js" />
2
2
  import RootStore from '../stores/root-store';
3
3
  import { ParsedMVF } from '@mappedin/mvf';
4
4
  import { MapData } from '../lib/sdk';
5
5
  export declare const testWithMap: (venueFileName?: string) => Promise<{
6
6
  rootStore: RootStore;
7
- mapView: import("@mappedin/maker-sdk/maker/src/map-view").MapView;
7
+ mapView: import("@mappedin/mappedin-js/maker/src/map-view").MapView;
8
8
  mapEl: HTMLDivElement;
9
9
  data: MapData;
10
10
  mvf: ParsedMVF;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@mappedin/viewer",
3
- "version": "0.15.6-ebcd108.0",
3
+ "version": "0.16.0",
4
4
  "type": "module",
5
5
  "browser": "./dist/index.js",
6
6
  "license": "UNLICENSED",
@@ -19,7 +19,7 @@
19
19
  "devDependencies": {
20
20
  "@ladle/react": "^2.17.2",
21
21
  "@mappedin/maker-icons": "1.0.0-fe4ca2f",
22
- "@mappedin/maker-sdk": "6.1.1-v6-internal-release.27.301b490d.3320",
22
+ "@mappedin/mappedin-js": "6.0.1-alpha.5-canary-V5.a7f66727",
23
23
  "@mappedin/mvf": "2.0.1-c7526c3.0",
24
24
  "@testing-library/react-hooks": "^8.0.1",
25
25
  "@types/react": "^18.2.15",