mirror of
https://github.com/moodle/moodle.git
synced 2025-08-05 00:46:50 +02:00

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.
14 lines
No EOL
1.7 KiB
JavaScript
14 lines
No EOL
1.7 KiB
JavaScript
/**
|
|
* A javascript module to store calendar drag and drop data.
|
|
*
|
|
* This module is unfortunately required because of the limitations
|
|
* of the HTML5 drag and drop API and it's ability to provide data
|
|
* between the different stages of the drag/drop lifecycle.
|
|
*
|
|
* @module core_calendar/drag_drop_data_store
|
|
* @copyright 2017 Ryan Wyllie <ryan@moodle.com>
|
|
* @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
|
|
*/
|
|
define("core_calendar/drag_drop_data_store",[],(function(){var eventId=null,durationDays=null,minTimestart=null,maxTimestart=null,minError=null,maxError=null,setEventId=function(id){eventId=id},setDurationDays=function(days){durationDays=days},setMinTimestart=function(timestamp){minTimestart=timestamp},setMaxTimestart=function(timestamp){maxTimestart=timestamp},setMinError=function(message){minError=message},setMaxError=function(message){maxError=message};return{setEventId:setEventId,getEventId:function(){return eventId},hasEventId:function(){return null!==eventId},setDurationDays:setDurationDays,getDurationDays:function(){return durationDays},setMinTimestart:setMinTimestart,getMinTimestart:function(){return minTimestart},hasMinTimestart:function(){return null!==minTimestart},setMaxTimestart:setMaxTimestart,getMaxTimestart:function(){return maxTimestart},hasMaxTimestart:function(){return null!==maxTimestart},setMinError:setMinError,getMinError:function(){return minError},setMaxError:setMaxError,getMaxError:function(){return maxError},clearAll:function(){setEventId(null),setDurationDays(null),setMinTimestart(null),setMaxTimestart(null),setMinError(null),setMaxError(null)}}}));
|
|
|
|
//# sourceMappingURL=drag_drop_data_store.min.js.map
|