1
0
mirror of https://github.com/moodle/moodle.git synced 2025-03-31 05:52:51 +02:00
moodle/lib/amd/build/chart_output_base.min.js.map
Andrew Nicols 0a4047ab31 MDL-73915 js: Switch amd minification to terser
Unfortunately the babel minify-mangle plugin seems to be abandoned and
in certain circumstances can be very buggy. The only safe options are to
disable it, or to switch to a different minification library.

Not minifying our javascript is not ideal, so this commit updates the
javascript tasks to use a rollup, combined with babel, and terser.

Babel still converts code from ES/UMD/AMD to AMD modules with the
relevant browser support, whilst terser minifies the code.

The rollup bundler handles tracking and creation of sourcemaps, and
supports better parallelisation of the tasks.

Since the upgrade to Node LTS/Gallium requires an upgrade to @babel/core
and eslint, which change the built files anyway, this seems like the
ideal time to make this change.
2022-02-23 08:55:09 +08:00

1 line
2.4 KiB
Plaintext

{"version":3,"file":"chart_output_base.min.js","sources":["../src/chart_output_base.js"],"sourcesContent":["// This file is part of Moodle - http://moodle.org/\n//\n// Moodle is free software: you can redistribute it and/or modify\n// it under the terms of the GNU General Public License as published by\n// the Free Software Foundation, either version 3 of the License, or\n// (at your option) any later version.\n//\n// Moodle is distributed in the hope that it will be useful,\n// but WITHOUT ANY WARRANTY; without even the implied warranty of\n// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n// GNU General Public License for more details.\n//\n// You should have received a copy of the GNU General Public License\n// along with Moodle. If not, see <http://www.gnu.org/licenses/>.\n\n/**\n * Chart output base.\n *\n * This takes a chart object and draws it.\n *\n * @copyright 2016 Frédéric Massart - FMCorz.net\n * @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later\n * @module core/chart_output_base\n */\ndefine(['jquery'], function($) {\n\n /**\n * Chart output base.\n *\n * The constructor of an output class must instantly generate and display the\n * chart. It is also the responsability of the output module to check that\n * the node received is of the appropriate type, if not a new node can be\n * added within.\n *\n * The output module has total control over the content of the node and can\n * clear it or output anything to it at will. A node should not be shared by\n * two simultaneous output modules.\n *\n * @class\n * @param {Node} node The node to output with/in.\n * @param {Chart} chart A chart object.\n */\n function Base(node, chart) {\n this._node = $(node);\n this._chart = chart;\n }\n\n /**\n * Update method.\n *\n * This is the public method through which an output instance in informed\n * that the chart instance has been updated and they need to update the\n * chart rendering.\n *\n * @abstract\n * @return {Void}\n */\n Base.prototype.update = function() {\n throw new Error('Not supported.');\n };\n\n return Base;\n\n});\n"],"names":["define","$","Base","node","chart","_node","_chart","prototype","update","Error"],"mappings":";;;;;;;;;AAwBAA,gCAAO,CAAC,WAAW,SAASC,YAkBfC,KAAKC,KAAMC,YACXC,MAAQJ,EAAEE,WACVG,OAASF,aAalBF,KAAKK,UAAUC,OAAS,iBACd,IAAIC,MAAM,mBAGbP"}