From acada92d3c5c1bb0e9e887a5246d46feb8636620 Mon Sep 17 00:00:00 2001 From: nex3 Date: Mon, 18 Dec 2006 02:05:46 +0000 Subject: [PATCH] Getting rid of %h1 etc. git-svn-id: svn://hamptoncatlin.com/haml/trunk@232 7063305b-7217-0410-af8c-cdc13e5119b9 --- test/sass/results/basic.css | 6 +- test/sass/results/complex.css | 94 +++++++++++++++--------------- test/sass/templates/basic.sass | 6 +- test/sass/templates/complex.sass | 98 ++++++++++++++++---------------- 4 files changed, 102 insertions(+), 102 deletions(-) diff --git a/test/sass/results/basic.css b/test/sass/results/basic.css index 4d1d4b67..b0d1182f 100644 --- a/test/sass/results/basic.css +++ b/test/sass/results/basic.css @@ -1,8 +1,8 @@ -%body { font: Arial; background: blue; } +body { font: Arial; background: blue; } -#page { width: 700px; height: 100%; } +#page { width: 700px; height: 100; } #page #header { height: 300px; } -#page #header %h1 { font-size: 50px; color: blue; } +#page #header h1 { font-size: 50px; color: blue; } #content.user.show #container.top #column.left { width: 100px; } #content.user.show #container.top #column.right { width: 600px; } diff --git a/test/sass/results/complex.css b/test/sass/results/complex.css index 27b1198d..2cd9a780 100644 --- a/test/sass/results/complex.css +++ b/test/sass/results/complex.css @@ -1,84 +1,84 @@ -%body { margin: 0; font: 0.85em "Lucida Grande", "Trebuchet MS", Verdana, sans-serif; color: #fff; background: url(/images/global_bg.gif); } +body { margin: 0; font: 0.85em "Lucida Grande", "Trebuchet MS", Verdana, sans-serif; color: #fff; background: url(/images/global_bg.gif); } #page { width: 900px; margin: 0 auto; background: #440008; border-top: 5px solid #ff8500; } #header { height: 75px; padding: 0; } -#header %h1 { float: left; width: 274px; height: 75px; margin: 0; background: url(/images/global_logo.gif) no-repeat; text-indent: -9999px; } +#header h1 { float: left; width: 274px; height: 75px; margin: 0; background: url(/images/global_logo.gif) no-repeat; text-indent: -9999px; } #header .status { float: right; padding: .5em .5em 0 .5em; } -#header .status %p { float: left; margin: 0 0.5em 0 0; } -#header .status %ul { float: left; margin: 0; padding: 0; } -#header .status %li { list-style-type: none; display: inline; margin: 0 5px; } -#header .status %a:link, a:visited { color: #ff8500; text-decoration: none; } -#header .status %a:hover { text-decoration: underline; } +#header .status p { float: left; margin: 0 0.5em 0 0; } +#header .status ul { float: left; margin: 0; padding: 0; } +#header .status li { list-style-type: none; display: inline; margin: 0 5px; } +#header .status a:link, a:visited { color: #ff8500; text-decoration: none; } +#header .status a:hover { text-decoration: underline; } #header .search { float: right; clear: right; margin: 12px 0 0 0; } -#header .search %form { margin: 0; } -#header .search %input { margin: 0 3px 0 0; padding:: 2px; border:: none; } +#header .search form { margin: 0; } +#header .search input { margin: 0 3px 0 0; padding:: 2px; border:: none; } #menu { clear: both; text-align: right; height: 20px; border-bottom: 5px solid #006b95; background:: #00a4e4; } -#menu .contests %ul { margin: 0 5px 0 0; padding: 0; } -#menu .contests %ul %li { list-style-type: none; margin: 0 5px; padding: 5px 5px 0 5px; display: inline; font-size: 1.1em; color: #fff; background: #00a4e4; } -#menu .contests %a:link, a:visited { color: #fff; text-decoration: none; font-weight: bold; } -#menu .contests %a:hover { text-decoration: underline; } +#menu .contests ul { margin: 0 5px 0 0; padding: 0; } +#menu .contests ul li { list-style-type: none; margin: 0 5px; padding: 5px 5px 0 5px; display: inline; font-size: 1.1em; color: #fff; background: #00a4e4; } +#menu .contests a:link, a:visited { color: #fff; text-decoration: none; font-weight: bold; } +#menu .contests a:hover { text-decoration: underline; } #content { clear: both; } #content .container { clear: both; } #content .container .column { float: left; } #content .container .column .right { float: right; } -#content %a:link, a:visited { color: #93d700; text-decoration: none; } -#content %a:hover { text-decoration: underline; } +#content a:link, a:visited { color: #93d700; text-decoration: none; } +#content a:hover { text-decoration: underline; } #content .container.video .column.left { width: 200px; } #content .container.video .column.left .box { margin-top: 10px; } -#content .container.video .column.left .box %p { margin: 0 1em auto 1em; } -#content .container.video .column.left .box.participants %img { float: left; margin: 0 1em auto 1em; border: 1px solid #6e000d; } -#content .container.video .column.left .box.participants %h2 { margin: 0 0 10px 0; padding: 0.5em; background: #6e000d url(/images/hdr_participant.gif) 2px 2px no-repeat; text-indent: -9999px; border-top: 5px solid #a20013; } +#content .container.video .column.left .box p { margin: 0 1em auto 1em; } +#content .container.video .column.left .box.participants img { float: left; margin: 0 1em auto 1em; border: 1px solid #6e000d; } +#content .container.video .column.left .box.participants h2 { margin: 0 0 10px 0; padding: 0.5em; background: #6e000d url(/images/hdr_participant.gif) 2px 2px no-repeat; text-indent: -9999px; border-top: 5px solid #a20013; } #content .container.video .column.middle { width: 500px; } #content .container.video .column.right { width: 200px; } #content .container.video .column.right .box { margin-top: 0; } -#content .container.video .column.right .box %p { margin: 0 1em auto 1em; } -#content .container.video .column %p { margin-top: 0; } +#content .container.video .column.right .box p { margin: 0 1em auto 1em; } +#content .container.video .column p { margin-top: 0; } #content.contests .container.information .column.right .box { margin: 1em 0; } #content.contests .container.information .column.right .box.videos .thumbnail img { width: 200px; height: 150px; margin-bottom: 5px; } -#content.contests .container.information .column.right .box.videos %a:link, a:visited { color: #93d700; text-decoration: none; } -#content.contests .container.information .column.right .box.videos %a:hover { text-decoration: underline; } -#content.contests .container.information .column.right .box.votes %a { display: block; width: 200px; height: 60px; margin: 15px 0; background: url(/images/btn_votenow.gif) no-repeat; text-indent: -9999px; outline: none; border: none; } -#content.contests .container.information .column.right .box.votes %h2 { margin: 52px 0 10px 0; padding: 0.5em; background: #6e000d url(/images/hdr_videostats.gif) 2px 2px no-repeat; text-indent: -9999px; border-top: 5px solid #a20013; } +#content.contests .container.information .column.right .box.videos a:link, a:visited { color: #93d700; text-decoration: none; } +#content.contests .container.information .column.right .box.videos a:hover { text-decoration: underline; } +#content.contests .container.information .column.right .box.votes a { display: block; width: 200px; height: 60px; margin: 15px 0; background: url(/images/btn_votenow.gif) no-repeat; text-indent: -9999px; outline: none; border: none; } +#content.contests .container.information .column.right .box.votes h2 { margin: 52px 0 10px 0; padding: 0.5em; background: #6e000d url(/images/hdr_videostats.gif) 2px 2px no-repeat; text-indent: -9999px; border-top: 5px solid #a20013; } -#content.contests .container.video .box.videos %h2 { margin: 0; padding: 0.5em; background: #6e000d url(/images/hdr_newestclips.gif) 2px 2px no-repeat; text-indent: -9999px; border-top: 5px solid #a20013; } -#content.contests .container.video .box.videos %table { width: 100%; } -#content.contests .container.video .box.videos %table %td { padding: 1em; width: 25%; vertical-align: top; } -#content.contests .container.video .box.videos %table %td %p { margin: 0 0 5px 0; } -#content.contests .container.video .box.videos %table %td %a:link, a:visited { color: #93d700; text-decoration: none; } -#content.contests .container.video .box.videos %table %td %a:hover { text-decoration: underline; } +#content.contests .container.video .box.videos h2 { margin: 0; padding: 0.5em; background: #6e000d url(/images/hdr_newestclips.gif) 2px 2px no-repeat; text-indent: -9999px; border-top: 5px solid #a20013; } +#content.contests .container.video .box.videos table { width: 100; } +#content.contests .container.video .box.videos table td { padding: 1em; width: 25; vertical-align: top; } +#content.contests .container.video .box.videos table td p { margin: 0 0 5px 0; } +#content.contests .container.video .box.videos table td a:link, a:visited { color: #93d700; text-decoration: none; } +#content.contests .container.video .box.videos table td a:hover { text-decoration: underline; } #content.contests .container.video .box.videos .thumbnail { float: left; } -#content.contests .container.video .box.videos .thumbnail %img { width: 80px; height: 60px; margin: 0 10px 0 0; border: 1px solid #6e000d; } +#content.contests .container.video .box.videos .thumbnail img { width: 80px; height: 60px; margin: 0 10px 0 0; border: 1px solid #6e000d; } #content .container.comments .column { margin-top: 15px; } #content .container.comments .column.left { width: 600px; } -#content .container.comments .column.left .box %ol { margin: 0; padding: 0; } -#content .container.comments .column.left .box %li { list-style-type: none; padding: 10px; margin: 0 0 1em 0; background: #6e000d; border-top: 5px solid #a20013; } -#content .container.comments .column.left .box %li %div { margin-bottom: 1em; } -#content .container.comments .column.left .box %li %ul { text-align: right; } -#content .container.comments .column.left .box %li %ul %li { display: inline; border: none; padding: 0; }; } +#content .container.comments .column.left .box ol { margin: 0; padding: 0; } +#content .container.comments .column.left .box li { list-style-type: none; padding: 10px; margin: 0 0 1em 0; background: #6e000d; border-top: 5px solid #a20013; } +#content .container.comments .column.left .box li div { margin-bottom: 1em; } +#content .container.comments .column.left .box li ul { text-align: right; } +#content .container.comments .column.left .box li ul li { display: inline; border: none; padding: 0; }; } #content .container.comments .column.right { width: 290px; padding-left: 10px; } -#content .container.comments .column.right %h2 { margin: 0; padding: 0.5em; background: #6e000d url(/images/hdr_addcomment.gif) 2px 2px no-repeat; text-indent: -9999px; border-top: 5px solid #a20013; } -#content .container.comments .column.right .box %textarea { width: 290px; height: 100px; border: none; } +#content .container.comments .column.right h2 { margin: 0; padding: 0.5em; background: #6e000d url(/images/hdr_addcomment.gif) 2px 2px no-repeat; text-indent: -9999px; border-top: 5px solid #a20013; } +#content .container.comments .column.right .box textarea { width: 290px; height: 100px; border: none; } #footer { margin-top: 10px; padding: 1.2em 1.5em; background: #ff8500; } -#footer %ul { margin: 0; padding: 0; list-style-type: none; } -#footer %ul %li { display: inline; margin: 0 0.5em; color: #440008; } -#footer %ul.links { float: left; } -#footer %ul.links %a:link, a:visited { color: #440008; text-decoration: none; } -#footer %ul.links %a:hover { text-decoration: underline; } -#footer %ul.copyright { float: right; } +#footer ul { margin: 0; padding: 0; list-style-type: none; } +#footer ul li { display: inline; margin: 0 0.5em; color: #440008; } +#footer ul.links { float: left; } +#footer ul.links a:link, a:visited { color: #440008; text-decoration: none; } +#footer ul.links a:hover { text-decoration: underline; } +#footer ul.copyright { float: right; } .clear { clear: both; } .centered { text-align: center; } -%img { border: none; } +img { border: none; } -%button.short { width: 60px; height: 22px; padding: 0 0 2px 0; color: #fff; border: none; background: url(/images/btn_short.gif) no-repeat; } +button.short { width: 60px; height: 22px; padding: 0 0 2px 0; color: #fff; border: none; background: url(/images/btn_short.gif) no-repeat; } -%table { border-collapse: collapse; } +table { border-collapse: collapse; } diff --git a/test/sass/templates/basic.sass b/test/sass/templates/basic.sass index 15960445..71117bf5 100644 --- a/test/sass/templates/basic.sass +++ b/test/sass/templates/basic.sass @@ -1,15 +1,15 @@ -%body +body :font Arial :background blue #page :width 700px - :height 100% + :height 100 #header :height 300px - %h1 + h1 :font-size 50px :color blue diff --git a/test/sass/templates/complex.sass b/test/sass/templates/complex.sass index c2546856..33775792 100644 --- a/test/sass/templates/complex.sass +++ b/test/sass/templates/complex.sass @@ -1,4 +1,4 @@ -%body +body :margin 0 :font 0.85em "Lucida Grande", "Trebuchet MS", Verdana, sans-serif :color #fff @@ -13,7 +13,7 @@ #header :height 75px :padding 0 - %h1 + h1 :float left :width 274px :height 75px @@ -23,29 +23,29 @@ .status :float right :padding .5em .5em 0 .5em - %p + p :float left :margin 0 0.5em 0 0 - %ul + ul :float left :margin 0 :padding 0 - %li + li :list-style-type none :display inline :margin 0 5px - %a:link, a:visited + a:link, a:visited :color #ff8500 :text-decoration none - %a:hover + a:hover :text-decoration underline .search :float right :clear right :margin 12px 0 0 0 - %form + form :margin 0 - %input + input :margin 0 3px 0 0 :padding: 2px :border: none @@ -57,10 +57,10 @@ :border-bottom 5px solid #006b95 :background: #00a4e4 .contests - %ul + ul :margin 0 5px 0 0 :padding 0 - %li + li :list-style-type none :margin 0 5px :padding 5px 5px 0 5px @@ -68,11 +68,11 @@ :font-size 1.1em :color #fff :background #00a4e4 - %a:link, a:visited + a:link, a:visited :color #fff :text-decoration none :font-weight bold - %a:hover + a:hover :text-decoration underline //General content information @@ -86,10 +86,10 @@ .middle .right :float right - %a:link, a:visited + a:link, a:visited :color #93d700 :text-decoration none - %a:hover + a:hover :text-decoration underline #content @@ -98,14 +98,14 @@ :width 200px .box :margin-top 10px - %p + p :margin 0 1em auto 1em .box.participants - %img + img :float left :margin 0 1em auto 1em :border 1px solid #6e000d - %h2 + h2 :margin 0 0 10px 0 :padding 0.5em :background #6e000d url(/images/hdr_participant.gif) 2px 2px no-repeat @@ -117,10 +117,10 @@ :width 200px .box :margin-top 0 - %p + p :margin 0 1em auto 1em .column - %p + p :margin-top 0 #content.contests @@ -133,13 +133,13 @@ :width 200px :height 150px :margin-bottom 5px - %a:link, a:visited + a:link, a:visited :color #93d700 :text-decoration none - %a:hover + a:hover :text-decoration underline .box.votes - %a + a :display block :width 200px :height 60px @@ -148,7 +148,7 @@ :text-indent -9999px :outline none :border none - %h2 + h2 :margin 52px 0 10px 0 :padding 0.5em :background #6e000d url(/images/hdr_videostats.gif) 2px 2px no-repeat @@ -158,28 +158,28 @@ #content.contests .container.video .box.videos - %h2 + h2 :margin 0 :padding 0.5em :background #6e000d url(/images/hdr_newestclips.gif) 2px 2px no-repeat :text-indent -9999px :border-top 5px solid #a20013 - %table - :width 100% - %td + table + :width 100 + td :padding 1em - :width 25% + :width 25 :vertical-align top - %p + p :margin 0 0 5px 0 - %a:link, a:visited + a:link, a:visited :color #93d700 :text-decoration none - %a:hover + a:hover :text-decoration underline .thumbnail :float left - %img + img :width 80px :height 60px :margin 0 10px 0 0 @@ -192,32 +192,32 @@ .column.left :width 600px .box - %ol + ol :margin 0 :padding 0 - %li + li :list-style-type none :padding 10px :margin 0 0 1em 0 :background #6e000d :border-top 5px solid #a20013 - %div + div :margin-bottom 1em - %ul + ul :text-align right - %li + li :display inline; border: none; padding: 0; } .column.right :width 290px :padding-left 10px - %h2 + h2 :margin 0 :padding 0.5em :background #6e000d url(/images/hdr_addcomment.gif) 2px 2px no-repeat :text-indent -9999px :border-top 5px solid #a20013 .box - %textarea + textarea :width 290px :height 100px :border none @@ -226,22 +226,22 @@ :margin-top 10px :padding 1.2em 1.5em :background #ff8500 - %ul + ul :margin 0 :padding 0 :list-style-type none - %li + li :display inline :margin 0 0.5em :color #440008 - %ul.links + ul.links :float left - %a:link, a:visited + a:link, a:visited :color #440008 :text-decoration none - %a:hover + a:hover :text-decoration underline - %ul.copyright + ul.copyright :float right @@ -251,10 +251,10 @@ .centered :text-align center -%img +img :border none -%button.short +button.short :width 60px :height 22px :padding 0 0 2px 0 @@ -262,5 +262,5 @@ :border none :background url(/images/btn_short.gif) no-repeat -%table +table :border-collapse collapse