[weld-commits] Weld SVN: r5285 - in archetypes/trunk/jsf/jee-minimal/src/main/resources: archetype-resources/src/main/webapp and 5 other directories.

weld-commits at lists.jboss.org weld-commits at lists.jboss.org
Mon Dec 14 14:09:35 EST 2009


Author: dan.j.allen
Date: 2009-12-14 14:09:35 -0500 (Mon, 14 Dec 2009)
New Revision: 5285

Added:
   archetypes/trunk/jsf/jee-minimal/src/main/resources/archetype-resources/src/main/webapp/WEB-INF/tmpl/
   archetypes/trunk/jsf/jee-minimal/src/main/resources/archetype-resources/src/main/webapp/WEB-INF/tmpl/default.xhtml
   archetypes/trunk/jsf/jee-minimal/src/main/resources/archetype-resources/src/main/webapp/resources/
   archetypes/trunk/jsf/jee-minimal/src/main/resources/archetype-resources/src/main/webapp/resources/css/
   archetypes/trunk/jsf/jee-minimal/src/main/resources/archetype-resources/src/main/webapp/resources/css/screen.css
   archetypes/trunk/jsf/jee-minimal/src/main/resources/archetype-resources/src/main/webapp/resources/gfx/
   archetypes/trunk/jsf/jee-minimal/src/main/resources/archetype-resources/src/main/webapp/resources/gfx/banner.png
   archetypes/trunk/jsf/jee-minimal/src/main/resources/archetype-resources/src/main/webapp/resources/gfx/weld.png
Modified:
   archetypes/trunk/jsf/jee-minimal/src/main/resources/META-INF/archetype.xml
   archetypes/trunk/jsf/jee-minimal/src/main/resources/archetype-resources/src/main/webapp/WEB-INF/web.xml
   archetypes/trunk/jsf/jee-minimal/src/main/resources/archetype-resources/src/main/webapp/index.xhtml
Log:
add pretty index page


Modified: archetypes/trunk/jsf/jee-minimal/src/main/resources/META-INF/archetype.xml
===================================================================
--- archetypes/trunk/jsf/jee-minimal/src/main/resources/META-INF/archetype.xml	2009-12-14 19:09:11 UTC (rev 5284)
+++ archetypes/trunk/jsf/jee-minimal/src/main/resources/META-INF/archetype.xml	2009-12-14 19:09:35 UTC (rev 5285)
@@ -2,11 +2,14 @@
 <archetype>
    <id>weld-archetype-jee-minimal-quickstart</id>
    <resources>
+      <resource>src/main/resources/META-INF/beans.xml</resource>
       <resource>src/main/webapp/index.xhtml</resource>
-      <resource>src/main/webapp/index.jsp</resource>
+      <resource>src/main/webapp/resources/css/screen.css</resource>
+      <resource filtered="false">src/main/webapp/resources/gfx/banner.png</resource>
+      <resource filtered="false">src/main/webapp/resources/gfx/weld.png</resource>
       <resource>src/main/webapp/WEB-INF/web.xml</resource>
       <resource>src/main/webapp/WEB-INF/faces-config.xml</resource>
-      <resource>src/main/resources/META-INF/beans.xml</resource>
+      <resource>src/main/webapp/WEB-INF/tmpl/default.xhtml</resource>
       <resource>src/main/webapp/META-INF/context.xml</resource>
    </resources>
    <sources>

Added: archetypes/trunk/jsf/jee-minimal/src/main/resources/archetype-resources/src/main/webapp/WEB-INF/tmpl/default.xhtml
===================================================================
--- archetypes/trunk/jsf/jee-minimal/src/main/resources/archetype-resources/src/main/webapp/WEB-INF/tmpl/default.xhtml	                        (rev 0)
+++ archetypes/trunk/jsf/jee-minimal/src/main/resources/archetype-resources/src/main/webapp/WEB-INF/tmpl/default.xhtml	2009-12-14 19:09:35 UTC (rev 5285)
@@ -0,0 +1,43 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
+   "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+   xmlns:h="http://java.sun.com/jsf/html"
+   xmlns:ui="http://java.sun.com/jsf/facelets">
+   <h:head>
+      <title>Java EE 6 Starter Application</title>
+      <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
+      <h:outputStylesheet name="css/screen.css"/>
+   </h:head>
+   <h:body>
+      <div id="container">
+         <div id="content">
+            <div id="sidebar">
+               <h3>Learn more</h3>
+               <p>
+                  Learn more about Java EE 6 and the extensions provided by Weld and Seam.
+               </p>
+               <ul>
+                  <li><a href="http://seamframework.org/Weld/JSR299AndWeldOverview">Overview</a></li>
+                  <li><a href="http://seamframework.org">Project website</a></li>
+                  <li><a href="http://seamframework.org/Documentation/SeamDocumentation#H-WeldReferenceDocumentation">Documentation</a></li>
+                  <li><a href="http://seamframework.org/Community/Forums">User forums</a></li>
+                  <li><a href="http://seamframework.org/Community/MailingLists">Mailing lists</a></li>
+                  <li><a href="https://jira.jboss.org/jira/browse/WELD">Issue tracker</a></li>
+               </ul>
+               <p>
+                  If you have an add-on, please <a href="http://seamframework.org/Community/Forums">let us know</a> and
+                  consider <a href="http://seamframework.org/Community/Contribute">contributing</a> it back to the
+                  community!
+               </p>
+            </div>
+            <ui:insert name="content">
+               [Template content will be inserted here]
+            </ui:insert>
+         </div>
+         <div id="footer">
+            <h:graphicImage value="/resources/gfx/weld.png" alt="Weld logo"/>
+            <p>Weld is an open source (Apache License, Version 2.0) implementation of CDI.</p>
+         </div>
+      </div>
+   </h:body>
+</html>

Modified: archetypes/trunk/jsf/jee-minimal/src/main/resources/archetype-resources/src/main/webapp/WEB-INF/web.xml
===================================================================
--- archetypes/trunk/jsf/jee-minimal/src/main/resources/archetype-resources/src/main/webapp/WEB-INF/web.xml	2009-12-14 19:09:11 UTC (rev 5284)
+++ archetypes/trunk/jsf/jee-minimal/src/main/resources/archetype-resources/src/main/webapp/WEB-INF/web.xml	2009-12-14 19:09:35 UTC (rev 5285)
@@ -33,7 +33,7 @@
       <param-value>true</param-value>
    </context-param>
 
-   <!-- Optional.  Sets default document name.   -->
+   <!-- Optional. Sets default document name. -->
    <welcome-file-list>
       <welcome-file>index.jsf</welcome-file>
    </welcome-file-list>

Modified: archetypes/trunk/jsf/jee-minimal/src/main/resources/archetype-resources/src/main/webapp/index.xhtml
===================================================================
--- archetypes/trunk/jsf/jee-minimal/src/main/resources/archetype-resources/src/main/webapp/index.xhtml	2009-12-14 19:09:11 UTC (rev 5284)
+++ archetypes/trunk/jsf/jee-minimal/src/main/resources/archetype-resources/src/main/webapp/index.xhtml	2009-12-14 19:09:35 UTC (rev 5285)
@@ -1,16 +1,14 @@
 <?xml version="1.0" encoding="UTF-8"?>
-<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "DTD/xhtml1-strict.dtd">
-<html xmlns="http://www.w3.org/1999/xhtml"
+<ui:composition xmlns="http://www.w3.org/1999/xhtml"
+   xmlns:ui="http://java.sun.com/jsf/facelets"
    xmlns:f="http://java.sun.com/jsf/core"
-   xmlns:h="http://java.sun.com/jsf/html">
-   <h:head>
-      <title>Java EE 6 Starter Application</title>
-   </h:head>
-   <h:body>
+   xmlns:h="http://java.sun.com/jsf/html"
+   template="/WEB-INF/tmpl/default.xhtml">
+   <ui:define name="content">
       <h1>Hello World!</h1>
-      <p>My CDI bean says <span style="color: blue;">#{helloWorld.text}</span> using the Unified EL.</p>
+      <p>Your CDI bean <code>HelloWorld</code> says <span style="color: blue;">#{helloWorld.text}</span> using the Unified EL.</p>
 
-      <h:form>
+      <h:form id="bv">
          <h2>Bean Validation examples</h2>
          <p>Enforces annotation-based constraints defined on the model class.</p>
          <table>
@@ -20,16 +18,16 @@
                </th>
                <td>
                   <h:inputText id="letters" value="#{helloWorld.letters}"/>
-                  <h:message for="letters" style="color: red;"/>
+                  <h:message for="letters" errorClass="invalid"/>
                </td>
             </tr>
             <tr>
                <th style="text-align: right;">
-                  <h:outputLabel for="numbers" value="Numbers (max two digits):"/>
+                  <h:outputLabel for="numbers" value="Numbers:"/>
                </th>
                <td>
                   <h:inputText id="numbers" value="#{helloWorld.numbers}"/>
-                  <h:message for="numbers" style="color: red;"/>
+                  <h:message for="numbers" errorClass="invalid"/>
                </td>
             </tr>
             <tr>
@@ -38,14 +36,14 @@
                </th>
                <td>
                   <h:inputText id="email" value="#{helloWorld.email}"/>
-                  <h:message for="email" style="color: red;"/>
+                  <h:message for="email" errorClass="invalid"/>
                </td>
             </tr>
          </table>
          <p>
-            <h:commandButton action="check" value="Check"/>
+            <h:commandButton id="check" action="check" value="Check values"/>
             <h:outputText value=" All clear!" rendered="#{facesContext.postback and empty facesContext.messageList}" style="color: green;"/>
          </p>
       </h:form>
-   </h:body>
-</html>
+   </ui:define>
+</ui:composition>

Added: archetypes/trunk/jsf/jee-minimal/src/main/resources/archetype-resources/src/main/webapp/resources/css/screen.css
===================================================================
--- archetypes/trunk/jsf/jee-minimal/src/main/resources/archetype-resources/src/main/webapp/resources/css/screen.css	                        (rev 0)
+++ archetypes/trunk/jsf/jee-minimal/src/main/resources/archetype-resources/src/main/webapp/resources/css/screen.css	2009-12-14 19:09:35 UTC (rev 5285)
@@ -0,0 +1,39 @@
+body {
+   margin: 0;
+   padding: 0;
+   background-color: #EAECEE;
+   font-family: Verdana, sans-serif;
+   font-size: 0.9em;
+}
+#container {
+   margin: 0 auto;
+   padding: 0 20px 10px 20px;
+   border: 1px solid #666666;
+   width: 865px; /* subtract 40px from banner width for padding */
+   background: #FFFFFF url(#{request.contextPath}/resources/gfx/banner.png) no-repeat;
+   padding-top: 110px;
+}
+#sidebar {
+   font-size: 0.9em;
+   width: 225px;
+   float: right;
+   border: 1px solid #666666;
+   background: #EAECEE;
+   padding: 0 15px 5px 15px;
+}
+#sidebar ul {
+   padding-left: 30px;
+}
+#footer {
+   clear: both;
+   text-align: center;
+   color: #666666;
+   font-size: 0.85em;
+}
+code {
+   font-size: 1.1em;
+}
+span.invalid {
+   padding-left: 3px;
+   color: red;
+}
\ No newline at end of file

Added: archetypes/trunk/jsf/jee-minimal/src/main/resources/archetype-resources/src/main/webapp/resources/gfx/banner.png
===================================================================
(Binary files differ)


Property changes on: archetypes/trunk/jsf/jee-minimal/src/main/resources/archetype-resources/src/main/webapp/resources/gfx/banner.png
___________________________________________________________________
Name: svn:mime-type
   + application/octet-stream

Added: archetypes/trunk/jsf/jee-minimal/src/main/resources/archetype-resources/src/main/webapp/resources/gfx/weld.png
===================================================================
(Binary files differ)


Property changes on: archetypes/trunk/jsf/jee-minimal/src/main/resources/archetype-resources/src/main/webapp/resources/gfx/weld.png
___________________________________________________________________
Name: svn:mime-type
   + application/octet-stream



More information about the weld-commits mailing list