Sébastien Grosjean - ZenCocoon
2008-May-21 13:13 UTC
Extend Element.setStyle to support CSS class name as parameter
Hi, I would like to know if it would be coherent to allow Element.setStyle to support CSS class name as parameter. This feature would require a function like String.parseStyle, script.aculo.us already have one made in effects.js : http://github.com/madrobby/scriptaculous/tree/master/src/effects.js#L1042 Such feature would be resulting in a negligent speed change in Element.setStyle and would allow to set the style of a DOM element based on CSS classes. If this feature can be interesting I can provide a patch through GIT including tests on FF 2, FF 3, Safari 3, Opera 9.25, IE 6, IE7. Hope this can help improving Prototype, -- Sebastien Grosjean - ZenCocoon --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Spinoffs" group. To post to this group, send email to rubyonrails-spinoffs-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-spinoffs-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-spinoffs?hl=en -~----------~----~----~----~------~----~------~--~---
Sébastien Grosjean - ZenCocoon
2008-May-21 13:17 UTC
Re: Extend Element.setStyle to support CSS class name as parameter
Oups, wrong place for this post. If you like to contribute to this discussion please do it on : http://groups.google.com/group/prototype-core/browse_thread/thread/fd9b45059758bc28 -- Sebastien Grosjean - ZenCocoon On May 21, 4:13 pm, Sébastien Grosjean - ZenCocoon <pub...-pF6qlRHTujOaMJb+Lgu22Q@public.gmane.org> wrote:> Hi, > > I would like to know if it would be coherent to allow Element.setStyle > to support CSS class name as parameter. > > This feature would require a function like String.parseStyle, > script.aculo.us already have one made in effects.js :http://github.com/madrobby/scriptaculous/tree/master/src/effects.js#L... > > Such feature would be resulting in a negligent speed change in > Element.setStyle and would allow to set the style of a DOM element > based on CSS classes. > > If this feature can be interesting I can provide a patch through GIT > including tests on FF 2, FF 3, Safari 3, Opera 9.25, IE 6, IE7. > > Hope this can help improving Prototype, > -- > Sebastien Grosjean - ZenCocoon--~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Spinoffs" group. To post to this group, send email to rubyonrails-spinoffs-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-spinoffs-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-spinoffs?hl=en -~----------~----~----~----~------~----~------~--~---