File indexing completed on 2024-05-19 06:00:18

0001 /* Load this script using conditional IE comments if you need to support IE 7 and IE 6. */
0002 
0003 window.onload = function() {
0004         function addIcon(el, entity) {
0005                 var html = el.innerHTML;
0006                 el.innerHTML = '<span style="font-family: \'Flat-UI-Icons\'">' + entity + '</span>' + html;
0007         }
0008         var icons = {
0009                         'fui-arrow-right' : '&#xe02c;',
0010                         'fui-arrow-left' : '&#xe02d;',
0011                         'fui-cmd' : '&#xe02f;',
0012                         'fui-check-inverted' : '&#xe006;',
0013                         'fui-heart' : '&#xe007;',
0014                         'fui-location' : '&#xe008;',
0015                         'fui-plus' : '&#xe009;',
0016                         'fui-check' : '&#xe00a;',
0017                         'fui-cross' : '&#xe00b;',
0018                         'fui-list' : '&#xe00c;',
0019                         'fui-new' : '&#xe00d;',
0020                         'fui-video' : '&#xe00e;',
0021                         'fui-photo' : '&#xe00f;',
0022                         'fui-volume' : '&#xe010;',
0023                         'fui-time' : '&#xe011;',
0024                         'fui-eye' : '&#xe012;',
0025                         'fui-chat' : '&#xe013;',
0026                         'fui-search' : '&#xe01c;',
0027                         'fui-user' : '&#xe01d;',
0028                         'fui-mail' : '&#xe01e;',
0029                         'fui-lock' : '&#xe01f;',
0030                         'fui-gear' : '&#xe024;',
0031                         'fui-radio-unchecked' : '&#xe02b;',
0032                         'fui-radio-checked' : '&#xe032;',
0033                         'fui-checkbox-unchecked' : '&#xe033;',
0034                         'fui-checkbox-checked' : '&#xe034;',
0035                         'fui-calendar-solid' : '&#xe022;',
0036                         'fui-pause' : '&#xe03b;',
0037                         'fui-play' : '&#xe03c;',
0038                         'fui-check-inverted-2' : '&#xe000;'
0039                 },
0040                 els = document.getElementsByTagName('*'),
0041                 i, attr, html, c, el;
0042         for (i = 0; ; i += 1) {
0043                 el = els[i];
0044                 if(!el) {
0045                         break;
0046                 }
0047                 attr = el.getAttribute('data-icon');
0048                 if (attr) {
0049                         addIcon(el, attr);
0050                 }
0051                 c = el.className;
0052                 c = c.match(/fui-[^\s'"]+/);
0053                 if (c && icons[c[0]]) {
0054                         addIcon(el, icons[c[0]]);
0055                 }
0056         }
0057 };