[Web] Minify css and js via PHP

[Web] Use PT Sans
[Web] Update some libs
This commit is contained in:
andryyy
2019-01-30 12:10:26 +01:00
parent 8c433bf0da
commit ad0df77d28
128 changed files with 3698 additions and 631 deletions

View File

@@ -1,23 +0,0 @@
$(document).ready(function() {
// Auto-fill domain quota when adding new domain
auto_fill_quota = function(domain) {
$.get("/api/v1/get/domain/" + domain, function(data){
var result = $.parseJSON(JSON.stringify(data));
max_new_mailbox_quota = ( result.max_new_mailbox_quota / 1048576);
if (max_new_mailbox_quota != '0') {
$("#quotaBadge").html('max. ' + max_new_mailbox_quota + ' MiB');
$('#addInputQuota').attr({"disabled": false, "value": "", "type": "number", "max": max_new_mailbox_quota});
$('#addInputQuota').val(max_new_mailbox_quota);
}
else {
$("#quotaBadge").html('max. ' + max_new_mailbox_quota + ' MiB');
$('#addInputQuota').attr({"disabled": true, "value": "", "type": "text", "value": "n/a"});
$('#addInputQuota').val(max_new_mailbox_quota);
}
});
}
$('#addSelectDomain').on('change', function() {
auto_fill_quota($('#addSelectDomain').val());
});
auto_fill_quota($('#addSelectDomain').val());
});

File diff suppressed because one or more lines are too long

View File

@@ -20,10 +20,9 @@
* Modification:
* Only continue load this library if window.u2f is not already supplied by the browser.
*/
var isFirefox = navigator.userAgent.indexOf('Firefox') !== -1 || navigator.userAgent.indexOf('Gecko/') !== -1;
var browserImplementsU2f = !!((typeof root.u2f !== 'undefined') && root.u2f.register);
if (isFirefox && browserImplementsU2f) {
if (browserImplementsU2f) {
root.u2f.isSupported = true;
return;
}

View File

@@ -8,7 +8,7 @@ $(document).ready(function() {
dataType: 'json',
url: '/api/v1/get/domain/all',
jsonp: false,
async: false,
async: true,
error: function () {
domain_list.push('Cannot read domain list');
},
@@ -28,7 +28,7 @@ $(document).ready(function() {
$form_grp = $('<div/>', {'class': 'form-group'})
.append($('<label/>', {'class': 'sr-only', text: 'Domain'}))
.prependTo(self.$form);
self.$domain = $('<select/>', { 'class': 'form-control' })
self.$domain = $('<select/>', { 'class': 'aform-control' })
.on('change', {self: self}, self._onDomainDropdownChanged)
.append($('<option/>', {text: self.def}))
.appendTo($form_grp);