@mattilsynet/design 2.2.25 → 2.2.26

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.
Files changed (42) hide show
  1. package/mtds/analytics/analytics.js +3 -1
  2. package/mtds/analytics/analytics.js.map +1 -1
  3. package/mtds/atlas/atlas-element.d.ts +1 -0
  4. package/mtds/atlas/atlas-element.js +14 -6
  5. package/mtds/atlas/atlas-element.js.map +1 -1
  6. package/mtds/atlas/atlas-marker.js +9 -5
  7. package/mtds/atlas/atlas-marker.js.map +1 -1
  8. package/mtds/atlas/atlas-matgeo.d.ts +11 -3
  9. package/mtds/atlas/atlas-matgeo.js +38 -16
  10. package/mtds/atlas/atlas-matgeo.js.map +1 -1
  11. package/mtds/atlas/atlas-wms.d.ts +17 -0
  12. package/mtds/atlas/atlas-wms.js +39 -0
  13. package/mtds/atlas/atlas-wms.js.map +1 -0
  14. package/mtds/atlas/atlas.css.js +12 -6
  15. package/mtds/atlas/atlas.css.js.map +1 -1
  16. package/mtds/atlas/atlas.d.ts +10 -1
  17. package/mtds/atlas/atlas.js +5 -0
  18. package/mtds/atlas/atlas.js.map +1 -1
  19. package/mtds/atlas/atlas.stories.d.ts +1 -0
  20. package/mtds/atlas.iife.js +16 -10
  21. package/mtds/atlas.js +3 -1
  22. package/mtds/atlas.js.map +1 -1
  23. package/mtds/external/@turf/boolean-point-in-polygon/dist/esm/index.js +35 -0
  24. package/mtds/external/@turf/boolean-point-in-polygon/dist/esm/index.js.map +1 -0
  25. package/mtds/external/@turf/helpers/dist/esm/index.js +40 -0
  26. package/mtds/external/@turf/helpers/dist/esm/index.js.map +1 -0
  27. package/mtds/external/@turf/invariant/dist/esm/index.js +28 -0
  28. package/mtds/external/@turf/invariant/dist/esm/index.js.map +1 -0
  29. package/mtds/external/point-in-polygon-hao/dist/esm/index.js +56 -0
  30. package/mtds/external/point-in-polygon-hao/dist/esm/index.js.map +1 -0
  31. package/mtds/external/robust-predicates/esm/orient2d.js +168 -0
  32. package/mtds/external/robust-predicates/esm/orient2d.js.map +1 -0
  33. package/mtds/external/robust-predicates/esm/util.js +91 -0
  34. package/mtds/external/robust-predicates/esm/util.js.map +1 -0
  35. package/mtds/index.iife.js +9 -9
  36. package/mtds/package.json.js +1 -1
  37. package/mtds/popover/popover-observer.js +16 -6
  38. package/mtds/popover/popover-observer.js.map +1 -1
  39. package/mtds/react-atlas.js +3 -1
  40. package/mtds/react-atlas.js.map +1 -1
  41. package/mtds/styles.css +62 -62
  42. package/package.json +8 -6
@@ -1,5 +1,5 @@
1
1
  import { CustomReactElementProps } from '../react-types';
2
- import { MTDSAtlasElement, MTDSAtlasMarkerElement, MTDSAtlasMatgeoElement } from './atlas-element';
2
+ import { MTDSAtlasElement, MTDSAtlasMarkerElement, MTDSAtlasMatgeoElement, MTDSAtlasWMSElement } from './atlas-element';
3
3
  export * from './atlas-element';
4
4
  declare global {
5
5
  namespace React.JSX {
@@ -13,6 +13,9 @@ declare global {
13
13
  "mtds-atlas-marker": CustomReactElementProps<MTDSAtlasMarkerElement> & {
14
14
  "data-latlng": string;
15
15
  };
16
+ "mtds-atlas-wms": CustomReactElementProps<MTDSAtlasWMSElement> & {
17
+ "data-url": string;
18
+ };
16
19
  "mtds-atlas-matgeo": CustomReactElementProps<MTDSAtlasMatgeoElement> & {
17
20
  "data-collection": string;
18
21
  onatlasfeatureclick?: (event: GlobalEventHandlersEventMap["atlasfeatureclick"]) => void;
@@ -22,6 +25,7 @@ declare global {
22
25
  }
23
26
  export type AtlasProps = React.JSX.IntrinsicElements["mtds-atlas"];
24
27
  export type AtlasMarkerProps = React.JSX.IntrinsicElements["mtds-atlas-marker"];
28
+ export type AtlasWMSProps = React.JSX.IntrinsicElements["mtds-atlas-wms"];
25
29
  export type AtlasMatgeoProps = React.JSX.IntrinsicElements["mtds-atlas-matgeo"] & {
26
30
  onFeatureClick?: React.JSX.IntrinsicElements["mtds-atlas-matgeo"]["onatlasfeatureclick"];
27
31
  };
@@ -39,4 +43,9 @@ export declare const Atlas: import('react').ForwardRefExoticComponent<Omit<{
39
43
  "data-latlng": string;
40
44
  }, "ref"> & import('react').RefAttributes<MTDSAtlasMarkerElement>>;
41
45
  Matgeo: import('react').ForwardRefExoticComponent<Omit<AtlasMatgeoProps, "ref"> & import('react').RefAttributes<MTDSAtlasMatgeoElement>>;
46
+ WMS: import('react').ForwardRefExoticComponent<Omit<{
47
+ class?: string;
48
+ } & import('react').ClassAttributes<MTDSAtlasWMSElement> & import('react').HTMLAttributes<MTDSAtlasWMSElement> & {
49
+ "data-url": string;
50
+ }, "ref"> & import('react').RefAttributes<MTDSAtlasWMSElement>>;
42
51
  };
@@ -24,6 +24,11 @@ const Atlas = Object.assign(AtlasComp, {
24
24
  }
25
25
  );
26
26
  }
27
+ ),
28
+ WMS: forwardRef(
29
+ function AtlasWMS(props, ref) {
30
+ return /* @__PURE__ */ jsx("mtds-atlas-wms", { ref, ...toCustomElementProps(props) });
31
+ }
27
32
  )
28
33
  });
29
34
  export {
@@ -1 +1 @@
1
- {"version":3,"file":"atlas.js","sources":["../../designsystem/atlas/atlas.tsx"],"sourcesContent":["import { forwardRef } from \"react\";\nimport type { CustomReactElementProps } from \"../react-types\";\nimport { toCustomElementProps } from \"../utils\";\nimport type {\n\tMTDSAtlasElement,\n\tMTDSAtlasMarkerElement,\n\tMTDSAtlasMatgeoElement,\n} from \"./atlas-element\";\n\nexport * from \"./atlas-element\"; // Expose { L } for Leaflet import\n\ndeclare global {\n\tnamespace React.JSX {\n\t\tinterface IntrinsicElements {\n\t\t\t\"mtds-atlas\": CustomReactElementProps<MTDSAtlasElement> & {\n\t\t\t\t\"data-cluster\"?: number | `${number}` | boolean | \"true\" | \"false\";\n\t\t\t\t\"data-scrollzoom\"?: boolean | \"true\" | \"false\";\n\t\t\t\t\"data-tiles\"?: \"color\" | \"gray\";\n\t\t\t\t\"data-view\"?: string | number[];\n\t\t\t};\n\t\t\t\"mtds-atlas-marker\": CustomReactElementProps<MTDSAtlasMarkerElement> & {\n\t\t\t\t\"data-latlng\": string;\n\t\t\t};\n\t\t\t\"mtds-atlas-matgeo\": CustomReactElementProps<MTDSAtlasMatgeoElement> & {\n\t\t\t\t\"data-collection\": string;\n\t\t\t\tonatlasfeatureclick?: (\n\t\t\t\t\tevent: GlobalEventHandlersEventMap[\"atlasfeatureclick\"],\n\t\t\t\t) => void;\n\t\t\t};\n\t\t}\n\t}\n}\n\nexport type AtlasProps = React.JSX.IntrinsicElements[\"mtds-atlas\"];\nexport type AtlasMarkerProps = React.JSX.IntrinsicElements[\"mtds-atlas-marker\"];\nexport type AtlasMatgeoProps =\n\tReact.JSX.IntrinsicElements[\"mtds-atlas-matgeo\"] & {\n\t\tonFeatureClick?: React.JSX.IntrinsicElements[\"mtds-atlas-matgeo\"][\"onatlasfeatureclick\"];\n\t};\n\nconst AtlasComp = forwardRef<MTDSAtlasElement, AtlasProps>(\n\tfunction Atlas(props, ref) {\n\t\treturn <mtds-atlas ref={ref} {...toCustomElementProps(props)} />;\n\t},\n);\n\nexport const Atlas = Object.assign(AtlasComp, {\n\tMarker: forwardRef<MTDSAtlasMarkerElement, AtlasMarkerProps>(\n\t\tfunction AtlasMarker(props, ref) {\n\t\t\treturn <mtds-atlas-marker ref={ref} {...toCustomElementProps(props)} />;\n\t\t},\n\t),\n\tMatgeo: forwardRef<MTDSAtlasMatgeoElement, AtlasMatgeoProps>(\n\t\tfunction AtlasMatgeo({ onFeatureClick, ...rest }, ref) {\n\t\t\treturn (\n\t\t\t\t<mtds-atlas-matgeo\n\t\t\t\t\tref={ref}\n\t\t\t\t\tonatlasfeatureclick={onFeatureClick}\n\t\t\t\t\t{...toCustomElementProps(rest)}\n\t\t\t\t/>\n\t\t\t);\n\t\t},\n\t),\n});\n"],"names":["Atlas"],"mappings":";;;;AAwCA,MAAM,YAAY;AAAA,EACjB,SAASA,OAAM,OAAO,KAAK;AAC1B,+BAAQ,cAAA,EAAW,KAAW,GAAG,qBAAqB,KAAK,GAAG;AAAA,EAC/D;AACD;AAEO,MAAM,QAAQ,OAAO,OAAO,WAAW;AAAA,EAC7C,QAAQ;AAAA,IACP,SAAS,YAAY,OAAO,KAAK;AAChC,iCAAQ,qBAAA,EAAkB,KAAW,GAAG,qBAAqB,KAAK,GAAG;AAAA,IACtE;AAAA,EAAA;AAAA,EAED,QAAQ;AAAA,IACP,SAAS,YAAY,EAAE,gBAAgB,GAAG,KAAA,GAAQ,KAAK;AACtD,aACC;AAAA,QAAC;AAAA,QAAA;AAAA,UACA;AAAA,UACA,qBAAqB;AAAA,UACpB,GAAG,qBAAqB,IAAI;AAAA,QAAA;AAAA,MAAA;AAAA,IAGhC;AAAA,EAAA;AAEF,CAAC;"}
1
+ {"version":3,"file":"atlas.js","sources":["../../designsystem/atlas/atlas.tsx"],"sourcesContent":["import { forwardRef } from \"react\";\nimport type { CustomReactElementProps } from \"../react-types\";\nimport { toCustomElementProps } from \"../utils\";\nimport type {\n\tMTDSAtlasElement,\n\tMTDSAtlasMarkerElement,\n\tMTDSAtlasMatgeoElement,\n\tMTDSAtlasWMSElement,\n} from \"./atlas-element\";\n\nexport * from \"./atlas-element\"; // Expose { L } for Leaflet import\n\ndeclare global {\n\tnamespace React.JSX {\n\t\tinterface IntrinsicElements {\n\t\t\t\"mtds-atlas\": CustomReactElementProps<MTDSAtlasElement> & {\n\t\t\t\t\"data-cluster\"?: number | `${number}` | boolean | \"true\" | \"false\";\n\t\t\t\t\"data-scrollzoom\"?: boolean | \"true\" | \"false\";\n\t\t\t\t\"data-tiles\"?: \"color\" | \"gray\";\n\t\t\t\t\"data-view\"?: string | number[];\n\t\t\t};\n\t\t\t\"mtds-atlas-marker\": CustomReactElementProps<MTDSAtlasMarkerElement> & {\n\t\t\t\t\"data-latlng\": string;\n\t\t\t};\n\t\t\t\"mtds-atlas-wms\": CustomReactElementProps<MTDSAtlasWMSElement> & {\n\t\t\t\t\"data-url\": string;\n\t\t\t};\n\t\t\t\"mtds-atlas-matgeo\": CustomReactElementProps<MTDSAtlasMatgeoElement> & {\n\t\t\t\t\"data-collection\": string;\n\t\t\t\tonatlasfeatureclick?: (\n\t\t\t\t\tevent: GlobalEventHandlersEventMap[\"atlasfeatureclick\"],\n\t\t\t\t) => void;\n\t\t\t};\n\t\t}\n\t}\n}\n\nexport type AtlasProps = React.JSX.IntrinsicElements[\"mtds-atlas\"];\nexport type AtlasMarkerProps = React.JSX.IntrinsicElements[\"mtds-atlas-marker\"];\nexport type AtlasWMSProps = React.JSX.IntrinsicElements[\"mtds-atlas-wms\"];\nexport type AtlasMatgeoProps =\n\tReact.JSX.IntrinsicElements[\"mtds-atlas-matgeo\"] & {\n\t\tonFeatureClick?: React.JSX.IntrinsicElements[\"mtds-atlas-matgeo\"][\"onatlasfeatureclick\"];\n\t};\n\nconst AtlasComp = forwardRef<MTDSAtlasElement, AtlasProps>(\n\tfunction Atlas(props, ref) {\n\t\treturn <mtds-atlas ref={ref} {...toCustomElementProps(props)} />;\n\t},\n);\n\nexport const Atlas = Object.assign(AtlasComp, {\n\tMarker: forwardRef<MTDSAtlasMarkerElement, AtlasMarkerProps>(\n\t\tfunction AtlasMarker(props, ref) {\n\t\t\treturn <mtds-atlas-marker ref={ref} {...toCustomElementProps(props)} />;\n\t\t},\n\t),\n\tMatgeo: forwardRef<MTDSAtlasMatgeoElement, AtlasMatgeoProps>(\n\t\tfunction AtlasMatgeo({ onFeatureClick, ...rest }, ref) {\n\t\t\treturn (\n\t\t\t\t<mtds-atlas-matgeo\n\t\t\t\t\tref={ref}\n\t\t\t\t\tonatlasfeatureclick={onFeatureClick}\n\t\t\t\t\t{...toCustomElementProps(rest)}\n\t\t\t\t/>\n\t\t\t);\n\t\t},\n\t),\n\tWMS: forwardRef<MTDSAtlasWMSElement, AtlasWMSProps>(\n\t\tfunction AtlasWMS(props, ref) {\n\t\t\treturn <mtds-atlas-wms ref={ref} {...toCustomElementProps(props)} />;\n\t\t},\n\t),\n});\n"],"names":["Atlas"],"mappings":";;;;AA6CA,MAAM,YAAY;AAAA,EACjB,SAASA,OAAM,OAAO,KAAK;AAC1B,+BAAQ,cAAA,EAAW,KAAW,GAAG,qBAAqB,KAAK,GAAG;AAAA,EAC/D;AACD;AAEO,MAAM,QAAQ,OAAO,OAAO,WAAW;AAAA,EAC7C,QAAQ;AAAA,IACP,SAAS,YAAY,OAAO,KAAK;AAChC,iCAAQ,qBAAA,EAAkB,KAAW,GAAG,qBAAqB,KAAK,GAAG;AAAA,IACtE;AAAA,EAAA;AAAA,EAED,QAAQ;AAAA,IACP,SAAS,YAAY,EAAE,gBAAgB,GAAG,KAAA,GAAQ,KAAK;AACtD,aACC;AAAA,QAAC;AAAA,QAAA;AAAA,UACA;AAAA,UACA,qBAAqB;AAAA,UACpB,GAAG,qBAAqB,IAAI;AAAA,QAAA;AAAA,MAAA;AAAA,IAGhC;AAAA,EAAA;AAAA,EAED,KAAK;AAAA,IACJ,SAAS,SAAS,OAAO,KAAK;AAC7B,iCAAQ,kBAAA,EAAe,KAAW,GAAG,qBAAqB,KAAK,GAAG;AAAA,IACnE;AAAA,EAAA;AAEF,CAAC;"}
@@ -19,6 +19,7 @@ export declare const WithClustering: Story;
19
19
  export declare const WithPopover: Story;
20
20
  export declare const WithPopoverDynamic: Story;
21
21
  export declare const WithMatgeo: Story;
22
+ export declare const WithWMS: Story;
22
23
  export declare const WithTooltip: Story;
23
24
  export declare const WithClickToAddMarker: Story;
24
25
  export declare const WithoutScrollZoom: Story;