Monday 15 March 2010

jquery - A circle being drawn when hover over div -


I have examined this question, I have received some answers, but in fact I do not need it.

I'm not really experiencing with jquery, but I already made the hover function! When I hover on div, this size will change What do I want to add to this effect: On the same hover, an image will be pulled around.

I have already seen such answers where people add box-radius. But what I see is that you are actually dragging the circle, an example of 0:49 sec (this is a little random but this video shows the effect I have):

I hope this is possible!

My code:

  $ ('li # balk1'). Css ('conversion', 'conversion', 'scale (1.2)');}, function () {$ ("advertising"). Css ('conversion', 'scale (1) ');});   

".ad"

around Check it should be a circle or it is also available as a

use of SVG stroke properties. We animate the SVG line generated from a rand deputy imperfect Bazier curve. I think this should be very close to you.

jQuery and D3 Dependencies

  & lt; Style & gt; Path.ln {stroke-width: 2px; Stroke: # 999; Fill: None; Vector-effect: non-scaling-stroke; Stroke-dashehra: 1000; Stroke-Doss Offset: 1000; Webkit-Animation: Dash 4S Cubic Bezier (0.45,0.3,0.35,0.3); -MOZ-Animation: Dash 4S Cubic Bezier (0.45,0.3,0.35,0.3); -O-Animation: Dash 4c Cubic Bezier (0.45,0.3,0.35,0.3); Animation: Dash 4S cubic Bezier (0.45,0.3,0.35,0.3); } @ Keyframe dash {from {stroke-dashoffset: 0; }} & Lt; / Style & gt; & Lt; Script & gt; Function Path (min_rad_delta, max_rad_delta, el_min, el_max, el_min_delta, el_max_delta) {var d = Math.sqrt (0.5 * 0.5 + 1 * 1), r = 1; // gives the square root of a number var el = (L_man + Math. Random) * (el_max - el_min)) * Math PI / 180; Var path = 'm' + [r * math. (L), R * Math Kos (L)] + 'C' + [D * R * Math. (L + Math.LN2), D * R * Meth Chaos (L. Math.LOG10E)]; For (var i = 0; i <4; i ++) {L + = Math PI / 2 * (1 + L_mina_Dilta + Math.Randum) * (L_Max_Delta - L_Money_Delta)); R * = (1 + min_rad_delta + Math.random () * (max_rad_delta - min_rad_delta)); Path + = '' + (I'S ':' ') + [D * R * Math Sin (L - 0.45), D * R * Math Kos (L - 0.45)]; Path + = '' + [r * math sin (l), r * math kos (l)]; } return path; } Function cx (lambda_man, lambda_max, l_man, l_max) {var el = (L_man + Math.rendum) * (L_MX-L_man)); Rotate 'Rotate' ('+ L +') '+' Scale (1, '+ (Lambda_man + Math Random) * (Lambda_max - Lambda_min))' + 'Rotate' + '(' + (-L) + ' ) '; } & Lt; / Script & gt; & Lt; Svg id = "circle" width = "50%" height = "75%" visible box = '- 1.5 -1.5 3 3' & gt; & Lt; / Svg & gt; & Lt; Script & gt; D3.selectAll ('svg') .append ('path'). Classified ('ln', true) .attr ('d', path (-0.1,0, 0,360, 0,0.2)) .attr ('transform', cx (0.6, 0.8, 0, 360)); SetTimeout (function () {location = ''}, 5000) & lt; / Script & gt;    

No comments:

Post a Comment