Author: wesw Date: Mon Dec 1 21:19:57 2008 New Revision: 722375 URL: http://svn.apache.org/viewvc?rev=722375&view=rev Log: moving CSS class declaration to the UL tag to make styling more flexible. Per WW-2655
Modified: struts/struts2/trunk/core/src/main/resources/template/css_xhtml/styles.css struts/struts2/trunk/core/src/main/resources/template/simple/fielderror.ftl struts/struts2/trunk/core/src/main/resources/template/xhtml/styles.css struts/struts2/trunk/core/src/test/resources/org/apache/struts2/views/jsp/ui/fielderror-1.txt struts/struts2/trunk/core/src/test/resources/org/apache/struts2/views/jsp/ui/fielderror-3.txt struts/struts2/trunk/core/src/test/resources/org/apache/struts2/views/jsp/ui/fielderror-4.txt struts/struts2/trunk/core/src/test/resources/org/apache/struts2/views/jsp/ui/fielderror-5.txt struts/struts2/trunk/core/src/test/resources/org/apache/struts2/views/jsp/ui/fielderror-6.txt Modified: struts/struts2/trunk/core/src/main/resources/template/css_xhtml/styles.css URL: http://svn.apache.org/viewvc/struts/struts2/trunk/core/src/main/resources/template/css_xhtml/styles.css?rev=722375&r1=722374&r2=722375&view=diff ============================================================================== --- struts/struts2/trunk/core/src/main/resources/template/css_xhtml/styles.css (original) +++ struts/struts2/trunk/core/src/main/resources/template/css_xhtml/styles.css Mon Dec 1 21:19:57 2008 @@ -26,7 +26,7 @@ width:30% } .errorLabel {font-style:italic; color:red; } -.errorMessage {font-weight:bold; text-align: center; color:red; } +.errorMessage {font-weight:bold; color:red; } .checkboxLabel {} .checkboxErrorLabel {color:red; } .required {color:red;} Modified: struts/struts2/trunk/core/src/main/resources/template/simple/fielderror.ftl URL: http://svn.apache.org/viewvc/struts/struts2/trunk/core/src/main/resources/template/simple/fielderror.ftl?rev=722375&r1=722374&r2=722375&view=diff ============================================================================== --- struts/struts2/trunk/core/src/main/resources/template/simple/fielderror.ftl (original) +++ struts/struts2/trunk/core/src/main/resources/template/simple/fielderror.ftl Mon Dec 1 21:19:57 2008 @@ -33,11 +33,7 @@ <#assign haveMatchedErrorField=true><#t/> <#assign eValue = fieldErrors[fieldErrorFieldName]><#t/> <#if (haveMatchedErrorField && (!doneStartUlTag))><#t/> - <ul> - <#assign doneStartUlTag=true><#t/> - </#if><#t/> - <#list eValue as eEachValue><#t/> - <li><span<#rt/> + <ul<#rt/> <#if parameters.cssClass??> class="${parameters.cssClass?html}"<#rt/> <#else> @@ -46,7 +42,11 @@ <#if parameters.cssStyle??> style="${parameters.cssStyle?html}"<#rt/> </#if> ->${eEachValue}</span></li> +> + <#assign doneStartUlTag=true><#t/> + </#if><#t/> + <#list eValue as eEachValue><#t/> + <li><span>${eEachValue}</span></li> </#list><#t/> </#if><#t/> </#list><#t/> @@ -57,11 +57,7 @@ </#if><#t/> <#else><#t/> <#if (eKeysSize > 0)><#t/> - <ul> - <#list eKeys as eKey><#t/> - <#assign eValue = fieldErrors[eKey]><#t/> - <#list eValue as eEachValue><#t/> - <li><span<#rt/> + <ul<#rt/> <#if parameters.cssClass??> class="${parameters.cssClass?html}"<#rt/> <#else> @@ -70,10 +66,14 @@ <#if parameters.cssStyle??> style="${parameters.cssStyle?html}"<#rt/> </#if> ->${eEachValue}</span></li> +> + <#list eKeys as eKey><#t/> + <#assign eValue = fieldErrors[eKey]><#t/> + <#list eValue as eEachValue><#t/> + <li><span>${eEachValue}</span></li> </#list><#t/> </#list><#t/> </ul> </#if><#t/> </#if><#t/> -</#if><#t/> \ No newline at end of file +</#if><#t/> Modified: struts/struts2/trunk/core/src/main/resources/template/xhtml/styles.css URL: http://svn.apache.org/viewvc/struts/struts2/trunk/core/src/main/resources/template/xhtml/styles.css?rev=722375&r1=722374&r2=722375&view=diff ============================================================================== --- struts/struts2/trunk/core/src/main/resources/template/xhtml/styles.css (original) +++ struts/struts2/trunk/core/src/main/resources/template/xhtml/styles.css Mon Dec 1 21:19:57 2008 @@ -22,7 +22,7 @@ .wwFormTable {} .label {font-style:italic; } .errorLabel {font-style:italic; color:red; } -.errorMessage {font-weight:bold; text-align: center; color:red; } +.errorMessage {font-weight:bold; color:red; } .checkboxLabel {} .checkboxErrorLabel {color:red; } .required {color:red;} Modified: struts/struts2/trunk/core/src/test/resources/org/apache/struts2/views/jsp/ui/fielderror-1.txt URL: http://svn.apache.org/viewvc/struts/struts2/trunk/core/src/test/resources/org/apache/struts2/views/jsp/ui/fielderror-1.txt?rev=722375&r1=722374&r2=722375&view=diff ============================================================================== --- struts/struts2/trunk/core/src/test/resources/org/apache/struts2/views/jsp/ui/fielderror-1.txt (original) +++ struts/struts2/trunk/core/src/test/resources/org/apache/struts2/views/jsp/ui/fielderror-1.txt Mon Dec 1 21:19:57 2008 @@ -1,5 +1,5 @@ -<ul> - <li><span class="errorMessage">field error message number 1</span></li> - <li><span class="errorMessage">field error message number 2</span></li> - <li><span class="errorMessage">field error message number 3</span></li> +<ul class="errorMessage"> + <li><span>field error message number 1</span></li> + <li><span>field error message number 2</span></li> + <li><span>field error message number 3</span></li> </ul> Modified: struts/struts2/trunk/core/src/test/resources/org/apache/struts2/views/jsp/ui/fielderror-3.txt URL: http://svn.apache.org/viewvc/struts/struts2/trunk/core/src/test/resources/org/apache/struts2/views/jsp/ui/fielderror-3.txt?rev=722375&r1=722374&r2=722375&view=diff ============================================================================== --- struts/struts2/trunk/core/src/test/resources/org/apache/struts2/views/jsp/ui/fielderror-3.txt (original) +++ struts/struts2/trunk/core/src/test/resources/org/apache/struts2/views/jsp/ui/fielderror-3.txt Mon Dec 1 21:19:57 2008 @@ -1,4 +1,4 @@ -<ul> - <li><span class="errorMessage">field error message number 1</span></li> - <li><span class="errorMessage">field error message number 3</span></li> +<ul class="errorMessage"> + <li><span>field error message number 1</span></li> + <li><span>field error message number 3</span></li> </ul> Modified: struts/struts2/trunk/core/src/test/resources/org/apache/struts2/views/jsp/ui/fielderror-4.txt URL: http://svn.apache.org/viewvc/struts/struts2/trunk/core/src/test/resources/org/apache/struts2/views/jsp/ui/fielderror-4.txt?rev=722375&r1=722374&r2=722375&view=diff ============================================================================== --- struts/struts2/trunk/core/src/test/resources/org/apache/struts2/views/jsp/ui/fielderror-4.txt (original) +++ struts/struts2/trunk/core/src/test/resources/org/apache/struts2/views/jsp/ui/fielderror-4.txt Mon Dec 1 21:19:57 2008 @@ -1,4 +1,4 @@ -<ul> - <li><span class="errorMessage">field error message number 1</span></li> - <li><span class="errorMessage">field error message number 2</span></li> +<ul class="errorMessage"> + <li><span>field error message number 1</span></li> + <li><span>field error message number 2</span></li> </ul> Modified: struts/struts2/trunk/core/src/test/resources/org/apache/struts2/views/jsp/ui/fielderror-5.txt URL: http://svn.apache.org/viewvc/struts/struts2/trunk/core/src/test/resources/org/apache/struts2/views/jsp/ui/fielderror-5.txt?rev=722375&r1=722374&r2=722375&view=diff ============================================================================== --- struts/struts2/trunk/core/src/test/resources/org/apache/struts2/views/jsp/ui/fielderror-5.txt (original) +++ struts/struts2/trunk/core/src/test/resources/org/apache/struts2/views/jsp/ui/fielderror-5.txt Mon Dec 1 21:19:57 2008 @@ -1,3 +1,3 @@ -<ul> - <li><span class="errorMessage">field error message number 2</span></li> +<ul class="errorMessage"> + <li><span>field error message number 2</span></li> </ul> Modified: struts/struts2/trunk/core/src/test/resources/org/apache/struts2/views/jsp/ui/fielderror-6.txt URL: http://svn.apache.org/viewvc/struts/struts2/trunk/core/src/test/resources/org/apache/struts2/views/jsp/ui/fielderror-6.txt?rev=722375&r1=722374&r2=722375&view=diff ============================================================================== --- struts/struts2/trunk/core/src/test/resources/org/apache/struts2/views/jsp/ui/fielderror-6.txt (original) +++ struts/struts2/trunk/core/src/test/resources/org/apache/struts2/views/jsp/ui/fielderror-6.txt Mon Dec 1 21:19:57 2008 @@ -1,3 +1,3 @@ -<ul> - <li><span class="errorMessage">field error message number 1</span></li> +<ul class="errorMessage"> + <li><span>field error message number 1</span></li> </ul> \ No newline at end of file