This applies the same approach to generating minified js as is already
used in theme/javascript.php and other scripts. When we need to do the
minification, we load the full Moodle environment, so we can use the
libraries.
The reason this was required was because now the minifier uses
autoloaded classes, which are not autoloaded when doing
ABORT_AFTER_CONFIG.
Fred persuaded me that it's probably safer to keep it that way, rather
than alllow ABORT_AFTER_CONFIG scripts from autoloading the world and
their dog (especially for resource serving scripts, they are intended to
be lightweight when serving from cache).
The previously used minification libraries were:
a) Unmaintained
b) Had some silly licensing issues (MDL-36457)
The new library is smaller, maintained, active and GPL-compatible.
The markup has changed so we now need to target .sr-only rather
than just .accesshide. I did keep the latter in case it's still used
somewhere, in a custom form field for instance.
The ideal solution was to tell QuickForm to display the labels of
those elements in the group. That works for Boost, but that did not
work for Clean. The rendering mechanics of QuickForm decides to not
print the label, unless it's set as hidden... the CSS hack remains.
1) It seems the maxmind database is getting relatively frequent updates
which are causing differences in exact coordinates
2) GeoIP location lookups are not an exact science, I tried to pick some
ips which I thought would remain fairly static, but these things are
just guesses.
3) Moving to 2 decimal places should give us good enough results for
this test, according to:
http://gis.stackexchange.com/questions/8650/measuring-accuracy-of-latitude-and-longitude
"The second decimal place is worth up to 1.1 km: it can separate one
village from the next."
"The third decimal place is worth up to 110 m: it can identify a
large agricultural field or institutional campus."
* Disable tool "Select content" button if selected preconfigured tool
does not support Content-Item, and if the selected option is set to
"Automatic, based on launch URL".
* Disable tool configuration form fields if selected preconfigured tool
does not support Content-Item, but enable these fields if the selected
option is set to "Automatic, based on launch URL".
* Behat tests also updated to check disabling/enabling of launch url field.
1) Bump eslint verson in npm
2) Enable tabs rule introduced in 3.2.0
3) With rules deprecated in 3.3.0 to their replacements
http://eslint.org/blog/2016/08/eslint-v3.3.0-released
4) Deprecate the use of M.str (fixes MDLSITE-3646) with new
no-restricted-properties introduced in 3.5.0
5) Fixup no-unused-vars - remove argsIgnorePattern which shouldn't have allowed
partial matches and turns out to be uncesssary
(detected because of https://github.com/eslint/eslint/issues/7250 in 3.6.0)