ES2015 first look / babeljs

This commit is contained in:
RainLoop Team 2015-11-15 03:23:16 +03:00
parent 5dcceaaca5
commit 445cd155e5
123 changed files with 3214 additions and 3680 deletions

View file

@ -1,35 +0,0 @@
(function () {
'use strict';
var
$ = require('$'),
sUrl = null,
getUtl = function () {
if (!sUrl)
{
sUrl = 'rainloop/v/' + ($('#rlAppVersion').attr('content') || '0.0.0') + '/static/css/svg/icons.svg';
}
return sUrl;
}
;
module.exports = {
viewModel: {
createViewModel: function(oParams, oComponentInfo) {
var icon = oParams.icon || 'null';
if (oComponentInfo.element && oComponentInfo.element)
{
$(oComponentInfo.element).replaceWith(
'<svg class="svg-icon svg-icon-' + icon + '"><use xlink:href="' + getUtl() + '#svg-icon-' + icon + '"></use></svg>');
}
}
},
'template': '<b></b>'
};
}());