@opensystemslab/map 1.0.0-alpha.6 → 1.0.0-alpha.8

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.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@opensystemslab/map",
3
- "version": "1.0.0-alpha.6",
3
+ "version": "1.0.0-alpha.8",
4
4
  "license": "MPL-2.0",
5
5
  "private": false,
6
6
  "repository": {
@@ -35,11 +35,11 @@
35
35
  "jspdf": "^3.0.1",
36
36
  "lit": "^3.0.1",
37
37
  "ol": "^10.6.1",
38
- "ol-ext": "^4.0.24",
38
+ "ol-ext": "^4.0.33",
39
39
  "ol-mapbox-style": "^12.6.0",
40
40
  "postcode": "^5.1.0",
41
41
  "proj4": "^2.19.5",
42
- "rambda": "^10.2.0"
42
+ "rambda": "^10.3.2"
43
43
  },
44
44
  "devDependencies": {
45
45
  "@glorious/pitsby": "^1.37.2",
@@ -52,9 +52,9 @@
52
52
  "@vitest/ui": "^3.0.7",
53
53
  "happy-dom": "^9.1.9",
54
54
  "husky": "^8.0.3",
55
- "lint-staged": "^15.2.10",
55
+ "lint-staged": "^15.5.2",
56
56
  "prettier": "^3.6.2",
57
- "rollup-plugin-postcss-lit": "^2.1.0",
57
+ "rollup-plugin-postcss-lit": "^2.2.0",
58
58
  "sass": "^1.89.2",
59
59
  "typescript": "^5.8.3",
60
60
  "vite": "^6.3.4",
@@ -0,0 +1,49 @@
1
+ import { LitElement, TemplateResult } from "lit";
2
+ type ArrowStyleEnum = "default" | "light";
3
+ type LabelStyleEnum = "responsive" | "static";
4
+ export declare class GeocodeAutocomplete extends LitElement {
5
+ static styles: import("lit").CSSResult;
6
+ id: string;
7
+ label: string;
8
+ initialAddress: string;
9
+ osApiKey: string;
10
+ osProxyEndpoint: string;
11
+ arrowStyle: ArrowStyleEnum;
12
+ labelStyle: LabelStyleEnum;
13
+ private _selectedAddress;
14
+ private _addressesMatching;
15
+ private _isLoading;
16
+ private _osError;
17
+ connectedCallback(): void;
18
+ disconnectedCallback(): void;
19
+ _getLightDropdownArrow(): string;
20
+ firstUpdated(): void;
21
+ _fetchData(input: string | undefined, populateResults: (values: string[]) => void): Promise<void>;
22
+ _getLabelClasses(): string;
23
+ /**
24
+ * Render an errorMessage container
25
+ * Must always be visible to ensure that role="status" works for screenreaders
26
+ * @param errorMessage
27
+ * @returns TemplateResult
28
+ */
29
+ _getErrorMessageContainer(errorMessage: string | undefined): TemplateResult;
30
+ /**
31
+ * If not in state of error, return the autocomplete
32
+ * @param errorMessage
33
+ * @returns TemplateResult | null
34
+ */
35
+ _getAutocomplete(errorMessage: string | undefined): TemplateResult | null;
36
+ render(): TemplateResult<1>;
37
+ /**
38
+ * dispatches an event for clients to subscribe to
39
+ * @param eventName
40
+ * @param payload
41
+ */
42
+ private dispatch;
43
+ }
44
+ declare global {
45
+ interface HTMLElementTagNameMap {
46
+ "geocode-autocomplete": GeocodeAutocomplete;
47
+ }
48
+ }
49
+ export {};
@@ -0,0 +1,6 @@
1
+ import type { IWindow } from "happy-dom";
2
+ import "./index";
3
+ declare global {
4
+ interface Window extends IWindow {
5
+ }
6
+ }
package/types/index.d.ts CHANGED
@@ -1,3 +1,4 @@
1
1
  export { MyMap } from "./components/my-map/index";
2
2
  export { AddressAutocomplete } from "./components/address-autocomplete/index";
3
+ export { GeocodeAutocomplete } from "./components/geocode-autocomplete/index";
3
4
  export { PostcodeSearch } from "./components/postcode-search/index";
@@ -1,4 +1,4 @@
1
- type OSServices = "xyz" | "vectorTile" | "vectorTileStyle" | "places" | "features";
1
+ type OSServices = "xyz" | "vectorTile" | "vectorTileStyle" | "places" | "find" | "features";
2
2
  interface ServiceOptions {
3
3
  service: OSServices;
4
4
  apiKey: string;