update
This commit is contained in:
parent
8844afcfe6
commit
9513a50631
4 changed files with 7 additions and 8 deletions
|
|
@ -546,7 +546,7 @@ divIdToTag('idTagList', 'getId')
|
|||
fuAds('', 'ads2', '');
|
||||
</script>
|
||||
|
||||
<script async src="/projects/17-insert-icon/script.js" onload="insertIcon('insertIcon', 'strict')"></script>
|
||||
<script async src="/projects/17-insert-icon/script.js" onload="insertIcon('insertIcon', '')"></script>
|
||||
|
||||
|
||||
<script>
|
||||
|
|
|
|||
|
|
@ -213,7 +213,7 @@
|
|||
fuAds('', 'ads2', '');
|
||||
</script>
|
||||
|
||||
<script async src="/projects/17-insert-icon/script.js" onload="insertIcon('insertIcon', 'strict')"></script>
|
||||
<script async src="/projects/17-insert-icon/script.js" onload="insertIcon('insertIcon', '')"></script>
|
||||
|
||||
</body>
|
||||
</html>
|
||||
|
|
|
|||
|
|
@ -226,7 +226,7 @@
|
|||
fuAds('', 'ads2', '');
|
||||
</script>
|
||||
|
||||
<script async src="/projects/17-insert-icon/script.js" onload="insertIcon('insertIcon', 'strict')"></script>
|
||||
<script async src="/projects/17-insert-icon/script.js" onload="insertIcon('insertIcon', '')"></script>
|
||||
|
||||
</body>
|
||||
</html>
|
||||
|
|
|
|||
|
|
@ -1,6 +1,5 @@
|
|||
// v.2.1.6
|
||||
// About: insert icon using class name. Current js using: google fonts, costum text name and insert image or symbol, and inster by url favicon site
|
||||
// icons fonts in header
|
||||
// v.2.1.7
|
||||
// About: insert icon using class name. Current js using: google fonts icon, costum <div>sbymol</div> or code with image, or insert by url favicon site
|
||||
|
||||
|
||||
async function insertIcon(classNameForInsert, mode){
|
||||
|
|
@ -132,7 +131,7 @@ let icon = String(icons[item]).toLowerCase();
|
|||
//counter == 0 - only one icon insert
|
||||
|
||||
|
||||
if(mode != 'strict'/*&&counter == 0*/){
|
||||
if(mode != 'strict'&&counter == 0){
|
||||
// main, not strict
|
||||
|
||||
//https://stackoverflow.com/questions/412123764/how-to-remove-numbers-from-a-string
|
||||
|
|
@ -144,7 +143,7 @@ icArr.push(icon+' ');
|
|||
check = 'exit';
|
||||
counter++;
|
||||
}
|
||||
}else if(check != 'exit'/*&&counter == 0*/){
|
||||
}else if(check != 'exit'&&counter == 0){
|
||||
// main, strict word
|
||||
if(
|
||||
(' '+linkText.replace(/\d+/g, '').toLowerCase()).indexOf((' '+textIcon.replace(/\d+/g, '')+'')) >= 0
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue