From 1cb82728dbe565559f167c2f0834efc2cbc38b17 Mon Sep 17 00:00:00 2001 From: jimi Date: Fri, 23 Jul 2010 09:31:58 -0500 Subject: [PATCH] Update html snippets - use of XPT vars - smarter meta tags - include javascript tags - rework of div and list tags - addition of nav menu, using ul tag --- ftplugin/html/html.xpt.vim | 97 ++++++++++++++++++++++++++++---------- 1 file changed, 71 insertions(+), 26 deletions(-) diff --git a/ftplugin/html/html.xpt.vim b/ftplugin/html/html.xpt.vim index 0a10e02..75ef5c2 100644 --- a/ftplugin/html/html.xpt.vim +++ b/ftplugin/html/html.xpt.vim @@ -2,21 +2,30 @@ " XPTemplate priority=personal -XPTvar $blank ' ' +let s:f = g:XPTfuncs() + +XPTvar $blank ' ' +XPTvar $js_dir 'scripts' +XPTvar $css_dir 'styles' +XPTvar $jq_ver '1.4.2.min' +XPTvar $empty '' XPT copy_comment hidden -XPT aut abbr alias=meta " + +XPT author alias=meta " `:title:^ `:contenttype:^` - `more^ ^ + `more^.^ `cursor^ @@ -35,35 +44,71 @@ XPT skel abbr synonym=html|xhtml " xhtml skeleton `:copy_comment:^ XPT link " - +XSET dir=$css_dir/ +XSET src=base.css + + +XPT reset synonym=fonts|base|grids|layout +XSET name=$_xSnipName.css +`:link( { 'src' : 'name' } ):^ + +XPT jquery abbr synonym=jq " -XPT jquery " jquery script link -XSET dir=ChooseStr( 'scripts/', 'javascripts/' ) - +XPT script " -XPT di abbr wrap=content "
.
-XSET val=$blank -XSET content=$blank -`content^ +XPT jplug abbr synonym=jfile|jp|jf alias=script -XPT div abbr wrap=content "
\n\n
\n -XPT ol abbr -` +XPT list " +XSET type=ul +<`type^` `att?^>` `...{{^ -
  • `^
  • ` +`^` `...^`}}^ - + XPT ul abbr alias=_tagAttr -XPT diva " tips -`:div( { 'content' : ':a:' } ):^ +XPT ol abbr alias=_tagAttr + +XPT li abbr +XSET content=Echo('') +
  • `content^
  • ` +`...{{^ +
  • `content^
  • ` +`...^`}}^ + +XPT lia abbr +XSET href=# +`:li( { 'content' : ':a:' } ):^ + +XPT nav synonym=menu " +XSET nav=$_xSnipName + + `:lia:^ + +