diff --git a/CHANGELOG.md b/CHANGELOG.md index 9a1646c08..2839475bf 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -3,6 +3,12 @@ All notable changes to this project will be documented in this file. This project adheres to [Semantic Versioning](http://semver.org/). +## [6.1.2] - 2022-06-24 + +- Update meta selector used when setting deprecatedID (#900) +- Preserve geopicker zoom, center map on user location on load, no error clicking pin (#905) +- Don't use removed repeat instance as context for relevance (#909) + ## [6.1.1] - 2022-06-01 - Fix: rendering unexpected geopoint widget for setvalue actions within an input (#896) diff --git a/docs/Geopicker.html b/docs/Geopicker.html index 57fb253e3..edb75e803 100644 --- a/docs/Geopicker.html +++ b/docs/Geopicker.html @@ -411,7 +411,7 @@

propsSource:
@@ -557,7 +557,7 @@

valueSource:
@@ -882,7 +882,7 @@

_addDyn
Source:
@@ -987,7 +987,7 @@

_addPointSource:
@@ -1296,7 +1296,7 @@

_closePo
Source:
@@ -1383,7 +1383,7 @@

Source:
@@ -1649,7 +1649,7 @@

_editPoint<
Source:
@@ -1985,7 +1985,7 @@

_getBas
Source:
@@ -2139,7 +2139,7 @@

_getD
Source:
@@ -2293,7 +2293,7 @@

_g
Source:
@@ -2474,7 +2474,7 @@

_getLayers<
Source:
@@ -2583,7 +2583,7 @@

_
Source:
@@ -2878,7 +2878,7 @@

_getTi
Source:
@@ -3735,7 +3735,7 @@

Source:
@@ -4068,7 +4068,7 @@

_removePo
Source:
@@ -4291,7 +4291,7 @@

_s
Source:
@@ -4510,7 +4510,7 @@

_updateAre
Source:
@@ -4646,7 +4646,7 @@

Source:
@@ -4824,7 +4824,7 @@

_updateI
Source:
@@ -5189,7 +5189,7 @@

_update
Source:
@@ -5276,7 +5276,7 @@

_update
Source:
@@ -5364,7 +5364,7 @@

_updat
Source:
@@ -5560,7 +5560,7 @@

co
Source:
@@ -5761,7 +5761,7 @@

disableSource:
@@ -5853,7 +5853,7 @@

enableSource:
@@ -5945,7 +5945,7 @@

updateSource:
@@ -6037,7 +6037,7 @@

Source:
diff --git a/docs/Nodeset.html b/docs/Nodeset.html index bd619b1cb..25db134ba 100644 --- a/docs/Nodeset.html +++ b/docs/Nodeset.html @@ -342,7 +342,7 @@

convertSource:
@@ -981,7 +981,7 @@

isRequired<
Source:
@@ -1592,7 +1592,7 @@

validateSource:
@@ -1792,7 +1792,7 @@

Source:
@@ -1995,7 +1995,7 @@

valid
Source:
diff --git a/docs/js_form-model.js.html b/docs/js_form-model.js.html index 6a423735a..d1aa29844 100644 --- a/docs/js_form-model.js.html +++ b/docs/js_form-model.js.html @@ -709,7 +709,7 @@

js/form-model.js

'text/xml' ).documentElement; this.xml.adoptNode(deprecatedIdEl); - metaEl = this.xml.querySelector('* > meta'); + metaEl = this.xml.querySelector('instance > * > meta'); metaEl.appendChild(deprecatedIdEl); } } diff --git a/docs/js_nodeset.js.html b/docs/js_nodeset.js.html index 08bb10c04..1718bf0ec 100644 --- a/docs/js_nodeset.js.html +++ b/docs/js_nodeset.js.html @@ -295,6 +295,7 @@

js/nodeset.js

nodes: null, repeatPath, repeatIndex, + removed: true, // Introduced to handle relevance on model nodes with no form controls (calculates) }) ); diff --git a/docs/js_relevant.js.html b/docs/js_relevant.js.html index d5f0b39c8..389776ea3 100644 --- a/docs/js_relevant.js.html +++ b/docs/js_relevant.js.html @@ -252,8 +252,16 @@

js/relevant.js

*/ let context = p.path; if ( - getChild(node, `.or-repeat-info[data-name="${p.path}"]`) && - !getChild(node, `.or-repeat[name="${p.path}"]`) + (getChild(node, `.or-repeat-info[data-name="${p.path}"]`) && + !getChild(node, `.or-repeat[name="${p.path}"]`)) || + // Special cases below for model nodes with no visible form control: if repeat instance removed or if + // no instances at all (e.g. during load with `jr:count="0"`) + (insideRepeat && + repeatParent == null && + (options.removed || + this.form.view.html.querySelector( + `.or-repeat[name="${CSS.escape(repeatPath)}"]` + ) == null)) ) { context = null; } diff --git a/docs/module-relevant.html b/docs/module-relevant.html index 59eb56f74..80ed72b86 100644 --- a/docs/module-relevant.html +++ b/docs/module-relevant.html @@ -435,7 +435,7 @@

(static) act
Source:
@@ -572,7 +572,7 @@

(static) clear<
Source:
@@ -732,7 +732,7 @@

(static) d
Source:
@@ -869,7 +869,7 @@

(static) disa
Source:
@@ -1096,7 +1096,7 @@

(static) enabl
Source:
@@ -1300,7 +1300,7 @@

(static) eva
Source:
@@ -1504,7 +1504,7 @@

(static) proc
Source:
@@ -1778,7 +1778,7 @@

(static) Source:
@@ -1936,7 +1936,7 @@

(static)
Source:
@@ -2091,7 +2091,7 @@

Source:
@@ -2996,7 +2996,7 @@

RepeatInfo

Source:
@@ -3130,7 +3130,7 @@

ToggleNonRelevantModle
Source:
diff --git a/docs/widget_geo_geopicker.js.html b/docs/widget_geo_geopicker.js.html index af3ebcffb..136652b38 100644 --- a/docs/widget_geo_geopicker.js.html +++ b/docs/widget_geo_geopicker.js.html @@ -89,15 +89,15 @@

widget/geo/geopicker.js

'https://maps.googleapis.com/maps/api/geocode/json?address={address}&sensor=true&key={api_key}'; const googleApiKey = config.googleApiKey || config.google_api_key; const iconSingle = L.divIcon({ - iconSize: 24, + iconSize: [16, 24], className: 'enketo-geopoint-marker', }); const iconMulti = L.divIcon({ - iconSize: 16, + iconSize: [16, 16], className: 'enketo-geopoint-circle-marker', }); const iconMultiActive = L.divIcon({ - iconSize: 16, + iconSize: [16, 16], className: 'enketo-geopoint-circle-marker-active', }); @@ -374,7 +374,7 @@

widget/geo/geopicker.js

this._updateMap([0, 0], 1); if (this.props.detect) { getCurrentPosition() - .then((position) => { + .then(({ position }) => { that._updateMap( [ position.coords.latitude, @@ -822,7 +822,6 @@

widget/geo/geopicker.js

// update last requested map coordinates to be used to initialize map in mobile fullscreen view if (latLng) { this.lastLatLng = latLng; - this.lastZoom = zoom; } // update the map if it is visible @@ -890,6 +889,16 @@

widget/geo/geopicker.js

} }); + this.map.on('load', () => { + this.map.on('zoomend', (event) => { + const zoom = event.target.getZoom(); + + if (zoom != null) { + this.lastZoom = zoom; + } + }); + }); + // watch out, default "Leaflet" link clicks away from page, loosing all data that.map.attributionControl.setPrefix(''); diff --git a/package-lock.json b/package-lock.json index 409e6b639..701df2b0c 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,6 +1,6 @@ { "name": "enketo-core", - "version": "6.1.1", + "version": "6.1.2", "lockfileVersion": 1, "requires": true, "dependencies": { diff --git a/package.json b/package.json index 629bf7e85..534d48454 100644 --- a/package.json +++ b/package.json @@ -2,7 +2,7 @@ "name": "enketo-core", "description": "Extensible Enketo form engine", "homepage": "https://enketo.org", - "version": "6.1.1", + "version": "6.1.2", "license": "Apache-2.0", "os": [ "darwin",