/Snippets/js/jqcsssetobj.snippet
# · Unknown · 40 lines · 39 code · 1 blank · 0 comment · 0 complexity · 9f988e2dacdc0b489b3c5100f4b6ea3f MD5 · raw file
- <CodeSnippets xmlns="http://schemas.microsoft.com/VisualStudio/2005/CodeSnippet">
- <CodeSnippet Format="1.1.0">
- <Header>
- <SnippetTypes>
- <SnippetType>Expansion</SnippetType>
- </SnippetTypes>
- <Title>jQuery: Set a key/value object as style properties to all matched elements.</Title>
- <Author>John Sheehan (@johnsheehan)</Author>
- <Shortcut>jqcsssetobj</Shortcut>
- <HelpUrl>http://jquerysnippets.codeplex.com</HelpUrl>
- </Header>
- <Snippet>
- <Declarations>
- <Literal>
- <ID>selector</ID>
- <ToolTip>Elements to set style properties on</ToolTip>
- <Default>selector</Default>
- </Literal>
- <Literal>
- <ID>name</ID>
- <ToolTip>Name of style property</ToolTip>
- <Default>name</Default>
- </Literal>
- <Literal>
- <ID>value</ID>
- <ToolTip>Value to set</ToolTip>
- <Default>value</Default>
- </Literal>
- </Declarations>
- <Code Language="jscript">
- <![CDATA[
- $$($selector$).css({
- $name$: $value$
- $end$
- });]]>
- </Code>
- </Snippet>
- </CodeSnippet>
- </CodeSnippets>