User talk:Cat Slayer Calli/SkillCheck

From Guild Wars 2 Wiki
Jump to: navigation, search

Suggestion[edit]

Instead of showing recharge/initiative and skillPoint in the effect list, float them to the right of the skill name. They're not effects, for one thing, but they also look odd in the effect list because their icons are bigger.

75,77c75,77
<             if(data.match(/[\s\|]initiative\s*=\s*([^\|\n]+)/i)){skillinfo.effects.initiative=RegExp.$1.trim();}
<             if(data.match(/[\s\|]recharge\s*=\s*([^\|\n]+)/i)&&RegExp.$1.trim()!=='0'){skillinfo.effects.recharge=RegExp.$1.trim();}
<             if(data.match(/[\s\|]skill-point\s*=\s*([^\|\n]+)/i)){skillinfo.effects.skillPoint=RegExp.$1.trim();}
---
>             if(data.match(/[\s\|]initiative\s*=\s*([^\|\n]+)/i)){skillinfo.initiative=RegExp.$1.trim();}
>             if(data.match(/[\s\|]recharge\s*=\s*([^\|\n]+)/i)&&RegExp.$1.trim()!=='0'){skillinfo.recharge=RegExp.$1.trim();}
>             if(data.match(/[\s\|]skill-point\s*=\s*([^\|\n]+)/i)){skillinfo.skillPoint=RegExp.$1.trim();}
147c147,155
<             t.innerHTML='<div style="padding-bottom:0.2em;text-decoration:underline;font-size:1.2em;white-space:nowrap;">'+(skillinfo.name||skillname).replace(/_/g,' ')+'</div>'+(skillinfo.description||'<em>No description available.</em>');
---
>             t.innerHTML='<div style="padding-bottom:0.2em;text-decoration:underline;font-size:1.2em;white-space:nowrap;">'
>                 +'<div style="float:right">'
>                 +(skillinfo.recharge?'<span style="white-space:nowrap;">'+skillinfo.recharge+' '+(inlineImage(SkillCheck.iconL['recharge']))+'</span>':'')
>                 +(skillinfo.initiative?'<span style="white-space:nowrap;">'+skillinfo.initiative+' '+(inlineImage(SkillCheck.iconL['initiative']))+'</span>':'')
>                 +(skillinfo.skillPoint?'<span style="white-space:nowrap;">'+skillinfo.skillPoint+' '+(inlineImage(SkillCheck.iconL['skillPoint']))+'</span>':'')
>                 +'</div>'
>                 +(skillinfo.name||skillname).replace(/_/g,' ')
>                 +'</div>'
>                 +(skillinfo.description||'<em>No description available.</em>');

Dr Ishmael User Dr ishmael Diablo the chicken.png 15:50, 11 July 2012 (UTC)

Thanks, I like it! Didn't really notice they were bigger until I read this though. ^^ As long as skill names don't get longer then Glyph of Lesser Elementals, I think this will be good. —Cat Slayer Calli User Cat Slayer Calli signature.png 20:02, 11 July 2012 (UTC)
Another minor suggestion: limit it to links within #bodyContent, I just noticed it affects the "page" link in the navigation tabs. —Dr Ishmael User Dr ishmael Diablo the chicken.png 03:03, 2 September 2012 (UTC)