Updated SBAdmin Template along with chartjs, boostrap, fontawesome, jquery etc updated numbers to use mono-space, Add buttons are now just a + icon
This commit is contained in:
+51
-27
@@ -1,3 +1,7 @@
|
||||
/*!
|
||||
* Font Awesome Free 5.8.2 by @fontawesome - https://fontawesome.com
|
||||
* License - https://fontawesome.com/license/free (Icons: CC BY 4.0, Fonts: SIL OFL 1.1, Code: MIT License)
|
||||
*/
|
||||
(function () {
|
||||
'use strict';
|
||||
|
||||
@@ -168,6 +172,7 @@
|
||||
var DATA_PREFIX = 'data-prefix';
|
||||
var DATA_ICON = 'data-icon';
|
||||
var HTML_CLASS_I2SVG_BASE_CLASS = 'fontawesome-i2svg';
|
||||
var MUTATION_APPROACH_ASYNC = 'async';
|
||||
var TAGNAMES_TO_SKIP_FOR_PSEUDOELEMENTS = ['HTML', 'HEAD', 'STYLE', 'SCRIPT'];
|
||||
var PRODUCTION = function () {
|
||||
try {
|
||||
@@ -200,7 +205,7 @@
|
||||
var oneToTen = [1, 2, 3, 4, 5, 6, 7, 8, 9, 10];
|
||||
var oneToTwenty = oneToTen.concat([11, 12, 13, 14, 15, 16, 17, 18, 19, 20]);
|
||||
var ATTRIBUTES_WATCHED_FOR_MUTATION = ['class', 'data-prefix', 'data-icon', 'data-fa-transform', 'data-fa-mask'];
|
||||
var RESERVED_CLASSES = ['xs', 'sm', 'lg', 'fw', 'ul', 'li', 'border', 'pull-left', 'pull-right', 'spin', 'pulse', 'rotate-90', 'rotate-180', 'rotate-270', 'flip-horizontal', 'flip-vertical', 'stack', 'stack-1x', 'stack-2x', 'inverse', 'layers', 'layers-text', 'layers-counter'].concat(oneToTen.map(function (n) {
|
||||
var RESERVED_CLASSES = ['xs', 'sm', 'lg', 'fw', 'ul', 'li', 'border', 'pull-left', 'pull-right', 'spin', 'pulse', 'rotate-90', 'rotate-180', 'rotate-270', 'flip-horizontal', 'flip-vertical', 'flip-both', 'stack', 'stack-1x', 'stack-2x', 'inverse', 'layers', 'layers-text', 'layers-counter'].concat(oneToTen.map(function (n) {
|
||||
return "".concat(n, "x");
|
||||
})).concat(oneToTwenty.map(function (n) {
|
||||
return "w-".concat(n);
|
||||
@@ -227,7 +232,7 @@
|
||||
}
|
||||
|
||||
if (DOCUMENT && typeof DOCUMENT.querySelector === 'function') {
|
||||
var attrs = [['data-family-prefix', 'familyPrefix'], ['data-replacement-class', 'replacementClass'], ['data-auto-replace-svg', 'autoReplaceSvg'], ['data-auto-add-css', 'autoAddCss'], ['data-auto-a11y', 'autoA11y'], ['data-search-pseudo-elements', 'searchPseudoElements'], ['data-observe-mutations', 'observeMutations'], ['data-keep-original-source', 'keepOriginalSource'], ['data-measure-performance', 'measurePerformance'], ['data-show-missing-icons', 'showMissingIcons']];
|
||||
var attrs = [['data-family-prefix', 'familyPrefix'], ['data-replacement-class', 'replacementClass'], ['data-auto-replace-svg', 'autoReplaceSvg'], ['data-auto-add-css', 'autoAddCss'], ['data-auto-a11y', 'autoA11y'], ['data-search-pseudo-elements', 'searchPseudoElements'], ['data-observe-mutations', 'observeMutations'], ['data-mutate-approach', 'mutateApproach'], ['data-keep-original-source', 'keepOriginalSource'], ['data-measure-performance', 'measurePerformance'], ['data-show-missing-icons', 'showMissingIcons']];
|
||||
attrs.forEach(function (_ref) {
|
||||
var _ref2 = _slicedToArray(_ref, 2),
|
||||
attr = _ref2[0],
|
||||
@@ -249,6 +254,7 @@
|
||||
autoA11y: true,
|
||||
searchPseudoElements: false,
|
||||
observeMutations: true,
|
||||
mutateApproach: 'async',
|
||||
keepOriginalSource: true,
|
||||
measurePerformance: false,
|
||||
showMissingIcons: true
|
||||
@@ -463,7 +469,7 @@
|
||||
throw new TypeError('Promise resolver ' + resolver + ' is not a function');
|
||||
}
|
||||
|
||||
if (this instanceof Promise === false) {
|
||||
if (this instanceof P === false) {
|
||||
throw new TypeError('Failed to construct \'Promise\': Please use the \'new\' operator, this object constructor cannot be called as a function.');
|
||||
}
|
||||
|
||||
@@ -921,7 +927,7 @@
|
||||
'data-prefix': prefix,
|
||||
'data-icon': iconName,
|
||||
'class': attrClass,
|
||||
'role': 'img',
|
||||
'role': extra.attributes.role || 'img',
|
||||
'xmlns': 'http://www.w3.org/2000/svg',
|
||||
'viewBox': "0 0 ".concat(width, " ").concat(height)
|
||||
})
|
||||
@@ -1062,7 +1068,7 @@
|
||||
mark: noop$1,
|
||||
measure: noop$1
|
||||
};
|
||||
var preamble = "FA \"5.7.0\"";
|
||||
var preamble = "FA \"5.8.2\"";
|
||||
|
||||
var begin = function begin(name) {
|
||||
p.mark("".concat(preamble, " ").concat(name, " begins"));
|
||||
@@ -1129,6 +1135,17 @@
|
||||
return result;
|
||||
};
|
||||
|
||||
function toHex(unicode) {
|
||||
var result = '';
|
||||
|
||||
for (var i = 0; i < unicode.length; i++) {
|
||||
var hex = unicode.charCodeAt(i).toString(16);
|
||||
result += ('000' + hex).slice(-4);
|
||||
}
|
||||
|
||||
return result;
|
||||
}
|
||||
|
||||
function defineIcons(prefix, icons) {
|
||||
var params = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : {};
|
||||
var _params$skipHooks = params.skipHooks,
|
||||
@@ -1211,10 +1228,10 @@
|
||||
};
|
||||
build();
|
||||
function byUnicode(prefix, unicode) {
|
||||
return _byUnicode[prefix][unicode];
|
||||
return (_byUnicode[prefix] || {})[unicode];
|
||||
}
|
||||
function byLigature(prefix, ligature) {
|
||||
return _byLigature[prefix][ligature];
|
||||
return (_byLigature[prefix] || {})[ligature];
|
||||
}
|
||||
function byOldName(name) {
|
||||
return _byOldName[name] || {
|
||||
@@ -1338,15 +1355,22 @@
|
||||
node.innerHTML = newInnerHTML;
|
||||
}
|
||||
};
|
||||
|
||||
function performOperationSync(op) {
|
||||
op();
|
||||
}
|
||||
|
||||
function perform(mutations, callback) {
|
||||
var callbackFunction = typeof callback === 'function' ? callback : noop$2;
|
||||
|
||||
if (mutations.length === 0) {
|
||||
callbackFunction();
|
||||
} else {
|
||||
var frame = WINDOW.requestAnimationFrame || function (op) {
|
||||
return op();
|
||||
};
|
||||
var frame = performOperationSync;
|
||||
|
||||
if (config.mutateApproach === MUTATION_APPROACH_ASYNC) {
|
||||
frame = WINDOW.requestAnimationFrame || performOperationSync;
|
||||
}
|
||||
|
||||
frame(function () {
|
||||
var mutator = getMutator();
|
||||
@@ -1442,17 +1466,6 @@
|
||||
return val;
|
||||
}
|
||||
|
||||
function toHex(unicode) {
|
||||
var result = '';
|
||||
|
||||
for (var i = 0; i < unicode.length; i++) {
|
||||
var hex = unicode.charCodeAt(i).toString(16);
|
||||
result += ('000' + hex).slice(-4);
|
||||
}
|
||||
|
||||
return result;
|
||||
}
|
||||
|
||||
function classParser (node) {
|
||||
var existingPrefix = node.getAttribute('data-prefix');
|
||||
var existingIconName = node.getAttribute('data-icon');
|
||||
@@ -1836,7 +1849,12 @@
|
||||
return;
|
||||
}
|
||||
|
||||
var candidates = toArray(root.querySelectorAll(prefixesDomQuery));
|
||||
var candidates = [];
|
||||
|
||||
try {
|
||||
candidates = toArray(root.querySelectorAll(prefixesDomQuery));
|
||||
} catch (e) {// noop
|
||||
}
|
||||
|
||||
if (candidates.length > 0) {
|
||||
hclAdd('pending');
|
||||
@@ -1870,9 +1888,13 @@
|
||||
hclAdd('complete');
|
||||
hclRemove('pending');
|
||||
if (typeof callback === 'function') callback();
|
||||
mark();
|
||||
resolve();
|
||||
});
|
||||
}).catch(reject).finally(mark);
|
||||
}).catch(function () {
|
||||
mark();
|
||||
reject();
|
||||
});
|
||||
});
|
||||
}
|
||||
function onNode(node) {
|
||||
@@ -1909,11 +1931,13 @@
|
||||
} else if (fontFamily) {
|
||||
var content = styles.getPropertyValue('content');
|
||||
var prefix = ~['Light', 'Regular', 'Solid', 'Brands'].indexOf(fontFamily[1]) ? STYLE_TO_PREFIX[fontFamily[1].toLowerCase()] : FONT_WEIGHT_TO_PREFIX[fontWeight];
|
||||
var iconName = byUnicode(prefix, toHex(content.length === 3 ? content.substr(1, 1) : content)); // Only convert the pseudo element in this :before/:after position into an icon if we haven't
|
||||
var hexValue = toHex(content.length === 3 ? content.substr(1, 1) : content);
|
||||
var iconName = byUnicode(prefix, hexValue);
|
||||
var iconIdentifier = iconName; // Only convert the pseudo element in this :before/:after position into an icon if we haven't
|
||||
// already done so with the same prefix and iconName
|
||||
|
||||
if (!alreadyProcessedPseudoElement || alreadyProcessedPseudoElement.getAttribute(DATA_PREFIX) !== prefix || alreadyProcessedPseudoElement.getAttribute(DATA_ICON) !== iconName) {
|
||||
node.setAttribute(pendingAttribute, iconName);
|
||||
if (iconName && (!alreadyProcessedPseudoElement || alreadyProcessedPseudoElement.getAttribute(DATA_PREFIX) !== prefix || alreadyProcessedPseudoElement.getAttribute(DATA_ICON) !== iconIdentifier)) {
|
||||
node.setAttribute(pendingAttribute, iconIdentifier);
|
||||
|
||||
if (alreadyProcessedPseudoElement) {
|
||||
// Delete the old one, since we're replacing it with a new one
|
||||
@@ -1930,7 +1954,7 @@
|
||||
mask: emptyCanonicalIcon()
|
||||
},
|
||||
prefix: prefix,
|
||||
iconName: iconName,
|
||||
iconName: iconIdentifier,
|
||||
extra: extra,
|
||||
watchable: true
|
||||
}));
|
||||
|
||||
Reference in New Issue
Block a user