Difference between revisions of "Template:Pitt"
Line 158: | Line 158: | ||
var padding = parseInt($(this).parent().css("padding-left")) + parseInt($(this).parent().css("padding-right")); | var padding = parseInt($(this).parent().css("padding-left")) + parseInt($(this).parent().css("padding-right")); | ||
var newWidth = parseInt($(this).parent().css("width")) + padding; | var newWidth = parseInt($(this).parent().css("width")) + padding; | ||
− | + | $(this).css("width", newWidth + 'px'); | |
− | + | ||
− | + | ||
− | + | ||
− | + | ||
}); | }); | ||
Line 261: | Line 257: | ||
var c = document.getElementById("bannerCanvas"); | var c = document.getElementById("bannerCanvas"); | ||
+ | c.height = $(window).height(); | ||
+ | c.width = $(window).width(); | ||
var ctx = c.getContext("2d"); | var ctx = c.getContext("2d"); | ||
Line 266: | Line 264: | ||
var radius = 50; | var radius = 50; | ||
radius = radius * 0.90; | radius = radius * 0.90; | ||
− | var grd = ctx.createRadialGradient( | + | var grd = ctx.createRadialGradient(event.clientX - document.body.scrollLeft,event.clientY - document.body.scrollTop,0,event.clientX - document.body.scrollLeft,event.clientY - document.body.scrollTop,radius); |
− | grd.addColorStop(0," | + | grd.addColorStop(0,"yellow"); |
− | grd.addColorStop(1," | + | grd.addColorStop(1,"black"); |
// Fill with gradient | // Fill with gradient | ||
ctx.fillStyle = grd; | ctx.fillStyle = grd; | ||
− | ctx.arc( | + | ctx.arc(event.clientX - document.body.scrollLeft,event.clientY - document.body.scrollTop, radius, 0 , 2*Math.PI); |
ctx.fill(); | ctx.fill(); | ||
Line 392: | Line 390: | ||
font-weight: bold; | font-weight: bold; | ||
font-family: "Trebuchet MS", Helvetica, sans-serif; | font-family: "Trebuchet MS", Helvetica, sans-serif; | ||
− | |||
− | |||
− | |||
− | |||
− | |||
} | } | ||
Line 448: | Line 441: | ||
#bannerCanvas { | #bannerCanvas { | ||
− | position: | + | position: fixed; |
width: 100%; | width: 100%; | ||
z-index:-1; | z-index:-1; | ||
+ | height: 100%; | ||
+ | left: 0; | ||
+ | top: 0; | ||
} | } | ||
Revision as of 15:50, 29 May 2015