EOX-A / EOxElements

A Web Component collection of geospatial UI elements, crafted by EOX.
https://eox-a.github.io/EOxElements/
MIT License
12 stars 2 forks source link

Integrate eox-map and eox-drawtools for "bounding-box" format #1271

Open silvester-pari opened 1 week ago

silvester-pari commented 1 week ago

Consider the following JSON schema:

        "spatial": {
          "title": "Spatial Extents",
          "type": "object",
          "format": "bounding-boxes",
          "required": [
            "bbox"
          ],
          "properties": {
            "bbox": {
              "type": "array",
              "items": {
                "type": "array",
                "format": "bounding-box",
                "items": {
                  "type": "number"
                },
                "minItems": 4,
                "maxItems": 4
              },
              "minItems": 1
            }
          }
        },

This should render an eox-map with eox-drawtools allowing multiple bounding boxes. Another example could be (with options):

          "properties": {
            "bbox": {
              "type": "array",
              "items": {
                "type": "array",
                "format": "bounding-box",
                "items": {
                  "type": "number"
                },
                "minItems": 4,
                "maxItems": 4,
                "options": {
                  "eox-drawtools": {
                     "allow-modify": true,
                     "multiple-features": false,
                     "show-editor": true,
                     "for": "eox-map#special"
                  }
                }
              }
          }