]> source.dussan.org Git - vaadin-framework.git/commitdiff
Use "vaadin-" as default prefix for Design (#18957)
authorHenri Sara <hesara@vaadin.com>
Wed, 23 Sep 2015 13:28:28 +0000 (16:28 +0300)
committerVaadin Code Review <review@vaadin.com>
Mon, 28 Sep 2015 07:16:02 +0000 (07:16 +0000)
Change-Id: Ic9e0650e5c8e305258cbce033c4ef3f33307bf0f

83 files changed:
server/src/com/vaadin/server/Constants.java
server/src/com/vaadin/ui/declarative/Design.java
server/src/com/vaadin/ui/declarative/DesignContext.java
server/tests/src/com/vaadin/tests/components/draganddropwrapper/DragAndDropWrapperDeclarativeTest.java
server/tests/src/com/vaadin/tests/components/menubar/MenuBarDeclarativeTest.java
server/tests/src/com/vaadin/tests/design/AbstractComponentSetResponsiveTest.java
server/tests/src/com/vaadin/tests/design/ComponentFactoryTest.java
server/tests/src/com/vaadin/tests/design/DesignContextLocalIdTest.java
server/tests/src/com/vaadin/tests/design/DesignReadInConstructor.html
server/tests/src/com/vaadin/tests/design/InvalidTagNames.java
server/tests/src/com/vaadin/tests/design/LocaleTest.java
server/tests/src/com/vaadin/tests/design/ParseLayoutTest.java
server/tests/src/com/vaadin/tests/design/ParseLegacyPrefixTest.java [new file with mode: 0644]
server/tests/src/com/vaadin/tests/design/ParseMixedLegacyAndNewPrefixTest.java [new file with mode: 0644]
server/tests/src/com/vaadin/tests/design/WriteLegacyDesignTest.java [new file with mode: 0644]
server/tests/src/com/vaadin/tests/design/all-components-legacy.html [new file with mode: 0644]
server/tests/src/com/vaadin/tests/design/all-components.html
server/tests/src/com/vaadin/tests/design/designroot/DesignWithEmptyAnnotation.html
server/tests/src/com/vaadin/tests/design/duplicate-ids.html
server/tests/src/com/vaadin/tests/design/duplicate-local-ids.html
server/tests/src/com/vaadin/tests/design/local-ids.html
server/tests/src/com/vaadin/tests/design/nested/WriteNestedTemplatesTest.java
server/tests/src/com/vaadin/tests/design/nested/mychilddesign.html
server/tests/src/com/vaadin/tests/design/nested/mydesignroot.html
server/tests/src/com/vaadin/tests/design/testFile-legacy.html [new file with mode: 0644]
server/tests/src/com/vaadin/tests/design/testFile.html
server/tests/src/com/vaadin/tests/design/verticallayout-one-child.html
server/tests/src/com/vaadin/tests/design/verticallayout-two-children.html
server/tests/src/com/vaadin/tests/server/component/absolutelayout/AbsoluteLayoutDeclarativeTest.java
server/tests/src/com/vaadin/tests/server/component/abstractcomponent/AbstractComponentDeclarativeTest.java
server/tests/src/com/vaadin/tests/server/component/abstractfield/AbstractFieldDeclarativeTest.java
server/tests/src/com/vaadin/tests/server/component/abstractorderedlayout/AbstractOrderedLayoutDeclarativeTest.java
server/tests/src/com/vaadin/tests/server/component/abstractselect/AbstractSelectDeclarativeTest.java
server/tests/src/com/vaadin/tests/server/component/abstractselect/OptionGroupDeclarativeTests.java
server/tests/src/com/vaadin/tests/server/component/abstractsplitpanel/AbstractSplitPanelDeclarativeTest.java
server/tests/src/com/vaadin/tests/server/component/abstracttextfield/AbstractTextFieldDeclarativeTest.java
server/tests/src/com/vaadin/tests/server/component/audio/AudioDeclarativeTest.java
server/tests/src/com/vaadin/tests/server/component/audio/VideoDeclarativeTest.java
server/tests/src/com/vaadin/tests/server/component/browserframe/BrowserFrameDeclarativeTest.java
server/tests/src/com/vaadin/tests/server/component/button/ButtonDeclarativeTest.java
server/tests/src/com/vaadin/tests/server/component/calendar/CalendarDeclarativeTest.java
server/tests/src/com/vaadin/tests/server/component/checkbox/CheckboxDeclarativeTest.java
server/tests/src/com/vaadin/tests/server/component/colorpicker/AbstractColorPickerDeclarativeTest.java
server/tests/src/com/vaadin/tests/server/component/combobox/ComboBoxDeclarativeTest.java
server/tests/src/com/vaadin/tests/server/component/csslayout/CssLayoutDeclarativeTest.java
server/tests/src/com/vaadin/tests/server/component/customlayout/CustomLayoutDeclarativeTest.java
server/tests/src/com/vaadin/tests/server/component/datefield/DateFieldDeclarativeTest.java
server/tests/src/com/vaadin/tests/server/component/datefield/PopupDateFieldDeclarativeTest.java
server/tests/src/com/vaadin/tests/server/component/flash/FlashDeclarativeTest.java
server/tests/src/com/vaadin/tests/server/component/grid/declarative/GridColumnDeclarativeTest.java
server/tests/src/com/vaadin/tests/server/component/grid/declarative/GridDeclarativeAttributeTest.java
server/tests/src/com/vaadin/tests/server/component/grid/declarative/GridHeaderFooterDeclarativeTest.java
server/tests/src/com/vaadin/tests/server/component/grid/declarative/GridInlineDataDeclarativeTest.java
server/tests/src/com/vaadin/tests/server/component/grid/declarative/GridStructureDeclarativeTest.java
server/tests/src/com/vaadin/tests/server/component/gridlayout/GridLayoutDeclarativeTest.java
server/tests/src/com/vaadin/tests/server/component/image/ImageDeclarativeTest.java
server/tests/src/com/vaadin/tests/server/component/label/LabelDeclarativeTest.java
server/tests/src/com/vaadin/tests/server/component/link/LinkDeclarativeTest.java
server/tests/src/com/vaadin/tests/server/component/listselect/ListSelectDeclarativeTest.java
server/tests/src/com/vaadin/tests/server/component/nativeselect/NativeSelectDeclarativeTest.java
server/tests/src/com/vaadin/tests/server/component/panel/PanelDeclarativeTest.java
server/tests/src/com/vaadin/tests/server/component/passwordfield/PasswordFieldDeclarativeTest.java
server/tests/src/com/vaadin/tests/server/component/popupview/PopupViewDeclarativeTest.java
server/tests/src/com/vaadin/tests/server/component/progressbar/ProgressBarDeclarativeTest.java
server/tests/src/com/vaadin/tests/server/component/richtextarea/RichTextAreaDeclarativeTest.java
server/tests/src/com/vaadin/tests/server/component/slider/SliderDeclarativeTest.java
server/tests/src/com/vaadin/tests/server/component/table/TableDeclarativeTestBase.java
server/tests/src/com/vaadin/tests/server/component/tabsheet/TabSheetDeclarativeTest.java
server/tests/src/com/vaadin/tests/server/component/textarea/TextAreaDeclarativeTest.java
server/tests/src/com/vaadin/tests/server/component/textfield/TextFieldDeclarativeTest.java
server/tests/src/com/vaadin/tests/server/component/tree/TreeDeclarativeTest.java
server/tests/src/com/vaadin/tests/server/component/treetable/TreeTableDeclarativeTest.java
server/tests/src/com/vaadin/tests/server/component/twincolselect/TwinColSelectDeclarativeTest.java
server/tests/src/com/vaadin/tests/server/component/upload/UploadDeclarativeTest.java
server/tests/src/com/vaadin/tests/server/component/window/WindowDeclarativeTest.java
server/tests/src/com/vaadin/ui/declarative/DesignTest.java
uitest/src/com/vaadin/tests/components/grid/declarative/GridBasicFeatures.html
uitest/src/com/vaadin/tests/components/grid/declarative/GridItemEditor.html
uitest/src/com/vaadin/tests/components/grid/declarative/GridMultiSelect.html
uitest/src/com/vaadin/tests/declarative/DeclarativeEditorInitial.html
uitest/src/com/vaadin/tests/declarative/PotusCrud.html
uitest/src/com/vaadin/tests/declarative/PotusForm.html
uitest/src/com/vaadin/tests/integration/LabelFromDesign.html

index 77a1a3134ed6cea797323d8aca59dfd6e9989db8..857f2481d5a521ec4486247b9629aea793af4a69 100644 (file)
@@ -138,6 +138,7 @@ public interface Constants {
     static final String SERVLET_PARAMETER_SYNC_ID_CHECK = "syncIdCheck";
     static final String SERVLET_PARAMETER_SENDURLSASPARAMETERS = "sendUrlsAsParameters";
     static final String SERVLET_PARAMETER_PUSH_SUSPEND_TIMEOUT_LONGPOLLING = "pushLongPollingSuspendTimeout";
+    static final String SERVLET_PARAMETER_LEGACY_DESIGN_PREFIX = "legacyDesignPrefix";
 
     // Configurable parameter names
     static final String PARAMETER_VAADIN_RESOURCES = "Resources";
index 63a263842360f5fb58d25c4f94cbbbb5e49c745b..8405160661203d6a2445f3b25b20051c983d0326 100644 (file)
@@ -193,7 +193,7 @@ public class Design implements Serializable {
                 ComponentFactory componentFactory, DesignContext context) {
             // Extract the package and class names.
             // Otherwise, get the full class name using the prefix to package
-            // mapping. Example: "v-vertical-layout" ->
+            // mapping. Example: "vaadin-vertical-layout" ->
             // "com.vaadin.ui.VerticalLayout"
             String[] parts = tagName.split("-", 2);
             if (parts.length < 2) {
@@ -211,8 +211,8 @@ public class Design implements Serializable {
                 // Split will ignore trailing and multiple dashes but that
                 // should be
                 // ok
-                // <v-button--> will be resolved to <v-button>
-                // <v--button> will be resolved to <v-button>
+                // <vaadin-button--> will be resolved to <vaadin-button>
+                // <vaadin--button> will be resolved to <vaadin-button>
                 className += SharedUtil.capitalize(classNamePart);
             }
             String qualifiedClassName = packageName + "." + className;
index 0d68c22ea0c8b12b45b97e0bd33dad0688aba58a..39a30de534b0c177e4b8c3418365f73d30be0823 100644 (file)
@@ -30,6 +30,9 @@ import org.jsoup.nodes.Element;
 import org.jsoup.nodes.Node;
 
 import com.vaadin.annotations.DesignRoot;
+import com.vaadin.server.Constants;
+import com.vaadin.server.DeploymentConfiguration;
+import com.vaadin.server.VaadinService;
 import com.vaadin.ui.Component;
 import com.vaadin.ui.HasComponents;
 import com.vaadin.ui.declarative.Design.ComponentFactory;
@@ -39,13 +42,25 @@ import com.vaadin.ui.declarative.Design.ComponentMapper;
  * This class contains contextual information that is collected when a component
  * tree is constructed based on HTML design template. This information includes
  * mappings from local ids, global ids and captions to components , as well as a
- * mapping between prefixes and package names (such as "v" -> "com.vaadin.ui").
+ * mapping between prefixes and package names (such as "vaadin" ->
+ * "com.vaadin.ui").
+ * 
+ * Versions prior to 7.6 use "v" as the default prefix. Versions starting with
+ * 7.6 support reading designs with either "v" or "vaadin" as the prefix, but
+ * only write "vaadin" by default. Writing with the legacy prefix can be
+ * activated with the property or context parameter
+ * {@link Constants#SERVLET_PARAMETER_LEGACY_DESIGN_PREFIX}.
  * 
  * @since 7.4
  * @author Vaadin Ltd
  */
 public class DesignContext implements Serializable {
 
+    private static final String LEGACY_PREFIX = "v";
+    private static final String VAADIN_PREFIX = "vaadin";
+
+    private static final String VAADIN_UI_PACKAGE = "com.vaadin.ui";
+
     // cache for object instances
     private static Map<Class<?>, Component> instanceCache = new ConcurrentHashMap<Class<?>, Component>();
 
@@ -67,23 +82,24 @@ public class DesignContext implements Serializable {
     // namespace mappings
     private Map<String, String> packageToPrefix = new HashMap<String, String>();
     private Map<String, String> prefixToPackage = new HashMap<String, String>();
-    // prefix names for which no package-mapping element will be created in the
-    // html tree (this includes at least "v" which is always taken to refer
-    // to "com.vaadin.ui".
-    private Map<String, String> defaultPrefixes = new HashMap<String, String>();
 
     // component creation listeners
     private List<ComponentCreationListener> listeners = new ArrayList<ComponentCreationListener>();
 
     private ShouldWriteDataDelegate shouldWriteDataDelegate = ShouldWriteDataDelegate.DEFAULT;
 
+    // this cannot be static because of testability issues
+    private Boolean legacyDesignPrefix = null;
+
     public DesignContext(Document doc) {
         this.doc = doc;
         // Initialize the mapping between prefixes and package names.
-        defaultPrefixes.put("v", "com.vaadin.ui");
-        for (String prefix : defaultPrefixes.keySet()) {
-            String packageName = defaultPrefixes.get(prefix);
-            addPackagePrefix(prefix, packageName);
+        if (isLegacyPrefixEnabled()) {
+            addPackagePrefix(LEGACY_PREFIX, VAADIN_UI_PACKAGE);
+            prefixToPackage.put(VAADIN_PREFIX, VAADIN_UI_PACKAGE);
+        } else {
+            addPackagePrefix(VAADIN_PREFIX, VAADIN_UI_PACKAGE);
+            prefixToPackage.put(LEGACY_PREFIX, VAADIN_UI_PACKAGE);
         }
     }
 
@@ -259,9 +275,14 @@ public class DesignContext implements Serializable {
     /**
      * Creates a two-way mapping between a prefix and a package name.
      * 
+     * Note that modifying the mapping for {@value #VAADIN_UI_PACKAGE} may
+     * invalidate the backwards compatibility mechanism supporting reading such
+     * components with either {@value #LEGACY_PREFIX} or {@value #VAADIN_PREFIX}
+     * as prefix.
+     * 
      * @param prefix
-     *            the prefix name without an ending dash (for instance, "v" is
-     *            by default used for "com.vaadin.ui")
+     *            the prefix name without an ending dash (for instance, "vaadin"
+     *            is by default used for "com.vaadin.ui")
      * @param packageName
      *            the name of the package corresponding to prefix
      * 
@@ -288,7 +309,11 @@ public class DesignContext implements Serializable {
      *         registered
      */
     public String getPackagePrefix(String packageName) {
-        return packageToPrefix.get(packageName);
+        if (VAADIN_UI_PACKAGE.equals(packageName)) {
+            return isLegacyPrefixEnabled() ? LEGACY_PREFIX : VAADIN_PREFIX;
+        } else {
+            return packageToPrefix.get(packageName);
+        }
     }
 
     /**
@@ -395,8 +420,8 @@ public class DesignContext implements Serializable {
         Element head = doc.head();
         for (String prefix : getPackagePrefixes()) {
             // Only store the prefix-name mapping if it is not a default mapping
-            // (such as "v" -> "com.vaadin.ui")
-            if (defaultPrefixes.get(prefix) == null) {
+            // (such as "vaadin" -> "com.vaadin.ui")
+            if (!VAADIN_PREFIX.equals(prefix) && !LEGACY_PREFIX.equals(prefix)) {
                 Node newNode = doc.createElement("meta");
                 newNode.attr("name", "package-mapping");
                 String prefixToPackageName = prefix + ":" + getPackage(prefix);
@@ -406,6 +431,31 @@ public class DesignContext implements Serializable {
         }
     }
 
+    /**
+     * Check whether the legacy prefix "v" or the default prefix "vaadin" should
+     * be used when writing designs. The property or context parameter
+     * {@link Constants#SERVLET_PARAMETER_LEGACY_DESIGN_PREFIX} can be used to
+     * switch to the legacy prefix.
+     * 
+     * @since
+     * @return true to use the legacy prefix, false by default
+     */
+    protected boolean isLegacyPrefixEnabled() {
+        if (legacyDesignPrefix != null) {
+            return legacyDesignPrefix.booleanValue();
+        }
+        if (VaadinService.getCurrent() == null) {
+            // This will happen at least in JUnit tests.
+            return false;
+        }
+        DeploymentConfiguration configuration = VaadinService.getCurrent()
+                .getDeploymentConfiguration();
+        legacyDesignPrefix = configuration.getApplicationOrSystemProperty(
+                Constants.SERVLET_PARAMETER_LEGACY_DESIGN_PREFIX, "false")
+                .equals("true");
+        return legacyDesignPrefix.booleanValue();
+    }
+
     /**
      * Creates an html tree node corresponding to the given element. Also
      * initializes its attributes by calling writeDesign. As a result of the
@@ -511,11 +561,21 @@ public class DesignContext implements Serializable {
         Component component = componentMapper.tagToComponent(tag,
                 Design.getComponentFactory(), this);
 
-        assert tag.equals(componentMapper.componentToTag(component, this));
+        assert tagEquals(tag, componentMapper.componentToTag(component, this));
 
         return component;
     }
 
+    private boolean tagEquals(String tag1, String tag2) {
+        return tag1.equals(tag2)
+                || (hasVaadinPrefix(tag1) && hasVaadinPrefix(tag2));
+    }
+
+    private boolean hasVaadinPrefix(String tag) {
+        return tag.startsWith(LEGACY_PREFIX + "-")
+                || tag.startsWith(VAADIN_PREFIX + "-");
+    }
+
     /**
      * Instantiates given class via ComponentFactory.
      * 
index 735216c474fd01f298e04b8af24537231f4a83af..71373857faae6577b6b44c3d5a81df1c06d2220e 100644 (file)
@@ -29,9 +29,9 @@ public class DragAndDropWrapperDeclarativeTest extends
     @Test
     public void testDefaultDnDWrapper() {
         Button okButton = new Button("OK");
-        String input = "<v-drag-and-drop-wrapper>"
+        String input = "<vaadin-drag-and-drop-wrapper>"
                 + new DesignContext().createElement(okButton)
-                + "</v-drag-and-drop-wrapper>";
+                + "</vaadin-drag-and-drop-wrapper>";
         DragAndDropWrapper wrapper = new DragAndDropWrapper(okButton);
         testWrite(input, wrapper);
         testRead(input, wrapper);
@@ -40,9 +40,9 @@ public class DragAndDropWrapperDeclarativeTest extends
     @Test
     public void testNoDragImage() {
         Button okButton = new Button("OK");
-        String input = "<v-drag-and-drop-wrapper drag-start-mode='wrapper'>"
+        String input = "<vaadin-drag-and-drop-wrapper drag-start-mode='wrapper'>"
                 + new DesignContext().createElement(okButton)
-                + "</v-drag-and-drop-wrapper>";
+                + "</vaadin-drag-and-drop-wrapper>";
         DragAndDropWrapper wrapper = new DragAndDropWrapper(okButton);
         wrapper.setDragStartMode(DragStartMode.WRAPPER);
         testWrite(input, wrapper);
@@ -53,10 +53,10 @@ public class DragAndDropWrapperDeclarativeTest extends
     public void testWithDragImage() {
         Button dragImage = new Button("Cancel");
         Button okButton = new Button("OK");
-        String input = "<v-drag-and-drop-wrapper drag-start-mode='component_other'>"
+        String input = "<vaadin-drag-and-drop-wrapper drag-start-mode='component_other'>"
                 + new DesignContext().createElement(okButton)
                 + new DesignContext().createElement(dragImage).attr(
-                        ":drag-image", "") + "</v-drag-and-drop-wrapper>";
+                        ":drag-image", "") + "</vaadin-drag-and-drop-wrapper>";
         DragAndDropWrapper wrapper = new DragAndDropWrapper(okButton);
         wrapper.setDragStartMode(DragStartMode.COMPONENT_OTHER);
         wrapper.setDragImageComponent(dragImage);
index d058ae1dcdb0bef325132052ccf1becedc71806b..b131c5a21dab85eeb435d6b1f557a77280cb1afb 100644 (file)
@@ -38,14 +38,14 @@ public class MenuBarDeclarativeTest extends DeclarativeTestBase<MenuBar> {
     @Test
     // #16328
     public void testReadWrite() throws IOException {
-        String design = "<v-menu-bar auto-open='' tabindex=5>"
+        String design = "<vaadin-menu-bar auto-open='' tabindex=5>"
                 + "<menu checkable=''>Save</menu>"
                 + "<menu description='Open a file'>Open</menu>"
                 + "<menu disabled=''>Close</menu>"
                 + "<menu icon='http://foo.bar/ico.png'>Help</menu>"
                 + "<menu visible='false'>About</menu>"
                 + "<menu>Sub<menu>Item</menu></menu>"
-                + "<menu more>WTF?!</menu>" + "</v-menu-bar>";
+                + "<menu more>WTF?!</menu>" + "</vaadin-menu-bar>";
         MenuBar bar = new MenuBar();
         bar.setAutoOpen(true);
         bar.setHtmlContentAllowed(true);
@@ -69,7 +69,7 @@ public class MenuBarDeclarativeTest extends DeclarativeTestBase<MenuBar> {
     @Test
     // #16328
     public void testTicketSpec1() throws IOException {
-        String design = "<v-menu-bar auto-open='' plain-text tabindex=5> "
+        String design = "<vaadin-menu-bar auto-open='' plain-text tabindex=5> "
                 + "<menu>File"
                 + "<menu>Save</menu>"
                 + "<menu icon=\"theme://../runo/icons/16/folder.png\">Open</menu>"
@@ -85,7 +85,7 @@ public class MenuBarDeclarativeTest extends DeclarativeTestBase<MenuBar> {
                 + "</menu>" //
                 + "</menu>" //
                 + "<menu more icon=\"theme://icon.png\">foo</menu>"
-                + "</v-menu-bar>";
+                + "</vaadin-menu-bar>";
         // for one reason or another, no component has a correct .equals
         // implementation, which makes tests a bit annoying
         MenuBar menuBar = new MenuBar();
@@ -120,12 +120,12 @@ public class MenuBarDeclarativeTest extends DeclarativeTestBase<MenuBar> {
     @Test
     // #16328
     public void testTicketSpec2() throws IOException {
-        String design = "<v-menu-bar>"
+        String design = "<vaadin-menu-bar>"
                 + "<menu><b>File</b>"
                 + "<menu><font style=\"color: red\">Save</font></menu>"
                 + "<menu icon=\"theme://../runo/icons/16/folder.png\">Open</menu>"
                 + "<menu separator='' />" + "<menu disabled=''>Exit</menu>" //
-                + "</menu></v-menu-bar>";
+                + "</menu></vaadin-menu-bar>";
         MenuBar menuBar = new MenuBar();
         menuBar.setHtmlContentAllowed(true);
         MenuItem fileMenu = menuBar.addItem("<b>File</b>", null);
index 1119301c55a243ff13c7612647c6efb9b437be9b..b68f56218d27355d2c67bb0d07c6093b0fb09b58 100644 (file)
@@ -29,7 +29,7 @@ public class AbstractComponentSetResponsiveTest extends
         label.setContentMode(ContentMode.HTML);
         label.setResponsive(true);
 
-        String design = "<v-label responsive='' />";
+        String design = "<vaadin-label responsive='' />";
 
         testWrite(design, label);
         testRead(design, label);
index 85efa22c40d38d315da436c1e2b6f1545be74d19..472c079e420af3191501c5a4039a43fdf17da689 100644 (file)
@@ -74,7 +74,7 @@ public class ComponentFactoryTest {
             }
         });
 
-        Design.read(new ByteArrayInputStream("<v-label />".getBytes()));
+        Design.read(new ByteArrayInputStream("<vaadin-label />".getBytes()));
 
         Assert.assertEquals("There should be one message logged", 1,
                 messages.size());
@@ -93,7 +93,7 @@ public class ComponentFactoryTest {
             }
         });
 
-        Design.read(new ByteArrayInputStream("<v-label />".getBytes()));
+        Design.read(new ByteArrayInputStream("<vaadin-label />".getBytes()));
     }
 
     @Test(expected = DesignException.class)
@@ -108,7 +108,7 @@ public class ComponentFactoryTest {
             }
         });
 
-        Design.read(new ByteArrayInputStream("<v-label />".getBytes()));
+        Design.read(new ByteArrayInputStream("<vaadin-label />".getBytes()));
     }
 
     @Test
index 6cedb174099aa001a5337f0c03c7dc59408d40c8..f8fb1249b95569b7461d3706c491b879373a0161 100644 (file)
@@ -101,7 +101,7 @@ public class DesignContextLocalIdTest {
             Element e = ctx.createElement(ctr);
             assertEquals("Unexpected child local id for "
                     + ctr.getClass().getSimpleName(), "button-id", e
-                    .getElementsByTag("v-button").first().attr("_id"));
+                    .getElementsByTag("vaadin-button").first().attr("_id"));
         }
 
         SingleComponentContainer[] sctrs = { new Window(), new Panel() };
@@ -111,7 +111,7 @@ public class DesignContextLocalIdTest {
             Element e = ctx.createElement(ctr);
             assertEquals("Unexpected child local id for "
                     + ctr.getClass().getSimpleName(), "button-id", e
-                    .getElementsByTag("v-button").first().attr("_id"));
+                    .getElementsByTag("vaadin-button").first().attr("_id"));
         }
     }
 
index 86c9c2a2dae475c06427f29bbb6a7131c5c28453..72f65d744a6d297ee8b1a3ae06e1ff608be82c4e 100644 (file)
@@ -1,5 +1,5 @@
-<v-vertical-layout>
-    <v-text-field caption="First name" />
-    <v-text-field caption="Last name" />
-    <v-button>OK!</v-button>
-</v-vertical-layout>
\ No newline at end of file
+<vaadin-vertical-layout>
+    <vaadin-text-field caption="First name" />
+    <vaadin-text-field caption="Last name" />
+    <vaadin-button>OK!</vaadin-button>
+</vaadin-vertical-layout>
\ No newline at end of file
index 0b6ccf8cb1a4a3b84c3f7daca49770a163c36e6a..9f405f4e56c8a6189e9c01e3c1c57ad6dcad10c7 100644 (file)
@@ -42,7 +42,7 @@ public class InvalidTagNames {
 
     @Test(expected = DesignException.class)
     public void onlyPrefix() {
-        readDesign("<v->foo</v->");
+        readDesign("<vaadin->foo</vaadin->");
     }
 
     @Test
@@ -55,7 +55,7 @@ public class InvalidTagNames {
 
     @Test(expected = DesignException.class)
     public void unknownClass() {
-        readDesign("<v-unknownbutton>foo</v-unknownbutton>");
+        readDesign("<vaadin-unknownbutton>foo</vaadin-unknownbutton>");
     }
 
     @Test(expected = DesignException.class)
@@ -65,31 +65,31 @@ public class InvalidTagNames {
 
     // @Test(expected = DesignException.class)
     // This is a side effect of not actively checking for invalid input. Will be
-    // parsed currently as <v-button> (this should not be considered API)
+    // parsed currently as <vaadin-button> (this should not be considered API)
     public void tagEndsInDash() {
-        Component c = readDesign("<v-button-></v-button->");
+        Component c = readDesign("<vaadin-button-></vaadin-button->");
         Assert.assertTrue(c.getClass() == Button.class);
     }
 
     // @Test(expected = DesignException.class)
     // This is a side effect of not actively checking for invalid input. Will be
-    // parsed currently as <v-button> (this should not be considered API)
+    // parsed currently as <vaadin-button> (this should not be considered API)
     public void tagEndsInTwoDashes() {
-        Component c = readDesign("<v-button--></v-button-->");
+        Component c = readDesign("<vaadin-button--></vaadin-button-->");
         Assert.assertTrue(c.getClass() == Button.class);
     }
 
     // @Test(expected = DesignException.class)
     // This is a side effect of not actively checking for invalid input. Will be
-    // parsed currently as <v-button> (this should not be considered API)
+    // parsed currently as <vaadin-button> (this should not be considered API)
     public void tagWithTwoDashes() {
-        Component c = readDesign("<v--button></v--button>");
+        Component c = readDesign("<vaadin--button></vaadin--button>");
         Assert.assertTrue(c.getClass() == Button.class);
     }
 
     @Test(expected = DesignException.class)
     public void specialCharacters() {
-        readDesign("<v-button-&!#></v-button-&!#>");
+        readDesign("<vaadin-button-&!#></vaadin-button-&!#>");
     }
 
     private Component readDesign(String string) {
index 8f0ef4d13e0097fb33746fcef792d196b9980e27..6cb288db237a4c0c040f8135c1dac11214fd8537 100644 (file)
@@ -145,18 +145,18 @@ public class LocaleTest {
         html.appendChild(doc.createElement("head"));
         Element body = doc.createElement("body");
         html.appendChild(body);
-        Element evLayout = doc.createElement("v-vertical-layout");
+        Element evLayout = doc.createElement("vaadin-vertical-layout");
         evLayout.attr("locale", "en_US");
         body.appendChild(evLayout);
-        Element ehLayout = doc.createElement("v-horizontal-layout");
+        Element ehLayout = doc.createElement("vaadin-horizontal-layout");
         evLayout.appendChild(ehLayout);
-        Element eb1 = doc.createElement("v-button");
+        Element eb1 = doc.createElement("vaadin-button");
         eb1.attr("locale", "en_US");
         ehLayout.appendChild(eb1);
-        Element eb2 = doc.createElement("v-button");
+        Element eb2 = doc.createElement("vaadin-button");
         eb2.attr("locale", "en_GB");
         ehLayout.appendChild(eb2);
-        Element eb3 = doc.createElement("v-button");
+        Element eb3 = doc.createElement("vaadin-button");
         ehLayout.appendChild(eb3);
 
         // parse the created document and check the constructed component
index 50ab2611952abedb5d200ed845d3240ebf1ce42d..20903512d12493a8e769c7988ef39138f8a803ac 100644 (file)
  */
 package com.vaadin.tests.design;
 
+import static org.hamcrest.CoreMatchers.is;
+import static org.hamcrest.CoreMatchers.not;
+import static org.hamcrest.CoreMatchers.nullValue;
+import static org.junit.Assert.assertEquals;
+import static org.junit.Assert.assertNotNull;
+import static org.junit.Assert.assertThat;
+
 import java.io.ByteArrayInputStream;
 import java.io.ByteArrayOutputStream;
 import java.io.FileInputStream;
-import java.io.FileNotFoundException;
 import java.io.IOException;
 import java.io.InputStream;
 
@@ -37,12 +43,6 @@ import com.vaadin.ui.VerticalLayout;
 import com.vaadin.ui.declarative.Design;
 import com.vaadin.ui.declarative.DesignContext;
 import com.vaadin.ui.declarative.DesignException;
-import org.junit.rules.ExpectedException;
-
-import static org.hamcrest.CoreMatchers.is;
-import static org.hamcrest.CoreMatchers.not;
-import static org.hamcrest.CoreMatchers.nullValue;
-import static org.junit.Assert.*;
 
 /**
  * A test for checking that parsing a layout preserves the IDs and the mapping
diff --git a/server/tests/src/com/vaadin/tests/design/ParseLegacyPrefixTest.java b/server/tests/src/com/vaadin/tests/design/ParseLegacyPrefixTest.java
new file mode 100644 (file)
index 0000000..feaf73a
--- /dev/null
@@ -0,0 +1,46 @@
+/*
+ * Copyright 2000-2014 Vaadin Ltd.
+ * 
+ * Licensed under the Apache License, Version 2.0 (the "License"); you may not
+ * use this file except in compliance with the License. You may obtain a copy of
+ * the License at
+ * 
+ * http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
+ * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
+ * License for the specific language governing permissions and limitations under
+ * the License.
+ */
+package com.vaadin.tests.design;
+
+import static org.hamcrest.CoreMatchers.is;
+import static org.hamcrest.CoreMatchers.not;
+import static org.hamcrest.CoreMatchers.nullValue;
+import static org.hamcrest.MatcherAssert.assertThat;
+
+import java.io.FileInputStream;
+import java.io.FileNotFoundException;
+
+import org.junit.Test;
+
+import com.vaadin.ui.declarative.Design;
+import com.vaadin.ui.declarative.DesignContext;
+
+/**
+ * Test reading a design with all components using the legacy prefix.
+ */
+public class ParseLegacyPrefixTest {
+
+    @Test
+    public void allComponentsAreParsed() throws FileNotFoundException {
+        DesignContext ctx = Design
+                .read(new FileInputStream(
+                        "server/tests/src/com/vaadin/tests/design/all-components-legacy.html"),
+                        null);
+
+        assertThat(ctx, is(not(nullValue())));
+        assertThat(ctx.getRootComponent(), is(not(nullValue())));
+    }
+}
diff --git a/server/tests/src/com/vaadin/tests/design/ParseMixedLegacyAndNewPrefixTest.java b/server/tests/src/com/vaadin/tests/design/ParseMixedLegacyAndNewPrefixTest.java
new file mode 100644 (file)
index 0000000..2996cb2
--- /dev/null
@@ -0,0 +1,35 @@
+/*
+ * Copyright 2000-2014 Vaadin Ltd.
+ * 
+ * Licensed under the Apache License, Version 2.0 (the "License"); you may not
+ * use this file except in compliance with the License. You may obtain a copy of
+ * the License at
+ * 
+ * http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
+ * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
+ * License for the specific language governing permissions and limitations under
+ * the License.
+ */
+package com.vaadin.tests.design;
+
+import java.io.ByteArrayInputStream;
+
+import org.junit.Test;
+
+import com.vaadin.ui.declarative.Design;
+
+/**
+ * Parse mixed content with legacy and new prefixes (not a required feature but
+ * works).
+ */
+public class ParseMixedLegacyAndNewPrefixTest {
+    @Test
+    public void parseMixedContent() {
+        Design.read(new ByteArrayInputStream(
+                "<v-vertical-layout><vaadin-label /></v-vertical-layout>"
+                        .getBytes()));
+    }
+}
diff --git a/server/tests/src/com/vaadin/tests/design/WriteLegacyDesignTest.java b/server/tests/src/com/vaadin/tests/design/WriteLegacyDesignTest.java
new file mode 100644 (file)
index 0000000..e57a03c
--- /dev/null
@@ -0,0 +1,102 @@
+/*
+ * Copyright 2000-2014 Vaadin Ltd.
+ * 
+ * Licensed under the Apache License, Version 2.0 (the "License"); you may not
+ * use this file except in compliance with the License. You may obtain a copy of
+ * the License at
+ * 
+ * http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
+ * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
+ * License for the specific language governing permissions and limitations under
+ * the License.
+ */
+package com.vaadin.tests.design;
+
+import static org.junit.Assert.assertTrue;
+
+import java.io.ByteArrayOutputStream;
+import java.io.FileInputStream;
+import java.io.IOException;
+import java.util.Properties;
+
+import org.jsoup.Jsoup;
+import org.jsoup.nodes.Document;
+import org.jsoup.nodes.Element;
+import org.jsoup.nodes.Node;
+import org.junit.After;
+import org.junit.Before;
+import org.junit.Test;
+
+import com.vaadin.server.Constants;
+import com.vaadin.server.DefaultDeploymentConfiguration;
+import com.vaadin.server.DeploymentConfiguration;
+import com.vaadin.server.VaadinService;
+import com.vaadin.server.VaadinServletService;
+import com.vaadin.ui.declarative.Design;
+import com.vaadin.ui.declarative.DesignContext;
+import com.vaadin.util.CurrentInstance;
+
+/**
+ * Parse and write a legacy design (using the "v-" prefix).
+ */
+public class WriteLegacyDesignTest {
+
+    // The context is used for accessing the created component hierarchy.
+    private DesignContext ctx;
+
+    @Before
+    public void setUp() throws Exception {
+        Properties properties = new Properties();
+        properties
+                .put(Constants.SERVLET_PARAMETER_LEGACY_DESIGN_PREFIX, "true");
+        final DeploymentConfiguration configuration = new DefaultDeploymentConfiguration(
+                WriteLegacyDesignTest.class, properties);
+
+        VaadinService service = new VaadinServletService(null, configuration);
+
+        CurrentInstance.set(VaadinService.class, service);
+
+        ctx = Design
+                .read(new FileInputStream(
+                        "server/tests/src/com/vaadin/tests/design/testFile-legacy.html"),
+                        null);
+    }
+
+    @After
+    public void tearDown() {
+        CurrentInstance.set(VaadinService.class, null);
+    }
+
+    private ByteArrayOutputStream serializeDesign(DesignContext context)
+            throws IOException {
+        ByteArrayOutputStream out = new ByteArrayOutputStream();
+        Design.write(context, out);
+
+        return out;
+    }
+
+    @Test
+    public void designIsSerializedWithCorrectPrefixesAndPackageNames()
+            throws IOException {
+        ByteArrayOutputStream out = serializeDesign(ctx);
+
+        Document doc = Jsoup.parse(out.toString("UTF-8"));
+        for (Node child : doc.body().childNodes()) {
+            checkNode(child);
+        }
+    }
+
+    private void checkNode(Node node) {
+        if (node instanceof Element) {
+            assertTrue("Wrong design element prefix", node.nodeName()
+                    .startsWith("v-"));
+            for (Node child : node.childNodes()) {
+                checkNode(child);
+            }
+        }
+    }
+
+}
diff --git a/server/tests/src/com/vaadin/tests/design/all-components-legacy.html b/server/tests/src/com/vaadin/tests/design/all-components-legacy.html
new file mode 100644 (file)
index 0000000..39aecb6
--- /dev/null
@@ -0,0 +1,122 @@
+<!DOCTYPE html>
+<html>
+ <head>
+  <meta name="package-mapping" content="my:com.addon.mypackage"/>
+ </head>
+ <body>
+  <v-vertical-layout>
+      <!-- abstract component -->
+         <v-button primary-style-name="button" id="foo" style-name="red" caption="Some caption" icon="vaadin://themes/runo/icons/16/ok.png" description="My tooltip" error="Something went wrong" locale="en_US"></v-button>
+
+      <!-- absolute layout -->
+      <v-absolute-layout>
+               <v-button :top="100px" :left="0px" :z-index=21>OK</v-button>
+               <v-button :bottom="0px" :right="0px">Cancel</v-button>
+         </v-absolute-layout>
+         
+         <!--  vertical layout -->
+      <v-vertical-layout spacing margin>
+               <v-button :top>OK</v-button>
+               <v-table size-full :expand=1 />      
+      </v-vertical-layout>
+      
+         <!--  horizontal layout -->
+      <v-horizontal-layout spacing margin>
+               <v-button :top>OK</v-button>
+               <v-table size-full :expand=1 />      
+      </v-horizontal-layout>
+      
+         <!--  form layout -->
+      <v-form-layout spacing margin>
+               <v-button :top>OK</v-button>
+               <v-table size-full :expand=1 />      
+      </v-form-layout>
+
+         <!--  css layout -->
+      <v-css-layout>
+               <v-button>OK</v-button>
+               <v-table size-full />
+      </v-css-layout>
+      
+      <!--  panel  -->
+      <v-panel caption="Hello world" tabindex=2 scroll-left="10" scroll-top="10">
+        <v-table size-full />
+      </v-panel>
+      
+      <!--  abstract field -->
+         <v-text-field buffered validation-visible=false invalid-committed invalid-allowed=false required required-error="This is a required field" conversion-error="Input {0} cannot be parsed" tabindex=3 readonly />
+      <!--  abstract text field, text field -->
+      <v-text-field null-representation="" null-setting-allowed maxlength=10 columns=5 input-prompt="Please enter a value" text-change-event-mode="eager" text-change-timeout=2 value="foo" />
+         <!--  password field -->      
+      <v-password-field null-representation="" null-setting-allowed maxlength=10 columns=5 input-prompt="Please enter a value" text-change-event-mode="eager" text-change-timeout=2 value="foo" />
+      <!--  text area -->
+      <v-text-area rows=5 wordwrap=false >test value</v-text-area>
+      <!--  button -->
+      <v-button click-shortcut="ctrl-shift-o" disable-on-click tabindex=1 icon="http://vaadin.com/image.png" icon-alt="ok" plain-text>OK</v-button>
+      <!--  native button -->
+      <v-button click-shortcut="ctrl-shift-o" disable-on-click tabindex=1 icon="http://vaadin.com/image.png" icon-alt="ok" plain-text>OK</v-button>
+      
+      <!-- tabsheet -->
+         <v-tab-sheet tabindex=5>
+                 <tab visible=false closable caption="My first tab">
+                       <v-vertical-layout>
+                               <v-text-field/>
+                   </v-vertical-layout>
+                 </tab>
+                 <tab enabled=false caption="Disabled second tab">
+                       <v-button>In disabled tab - can’t be shown by default</v-button>
+             </tab>
+                 <tab icon="theme://../runo/icons/16/ok.png" icon-alt="Ok png from Runo - very helpful" description="Click to show a text field" style-name="red" id="uniqueDomId">
+                       <v-text-field input-prompt="Icon only in tab" />
+             </tab>
+          </v-tab-sheet>
+
+      <!-- accordion -->
+         <v-accordion tabindex=5>
+                 <tab visible=false closable caption="My first tab">
+                       <v-vertical-layout>
+                               <v-text-field/>
+                   </v-vertical-layout>
+                 </tab>
+                 <tab enabled=false caption="Disabled second tab">
+                       <v-button>In disabled tab - can’t be shown by default</v-button>
+             </tab>
+                 <tab icon="theme://../runo/icons/16/ok.png" icon-alt="Ok png from Runo - very helpful" description="Click to show a text field" style-name="red" id="uniqueDomId">
+                       <v-text-field input-prompt="Icon only in tab" />
+             </tab>
+          </v-accordion>
+
+      <!--  abstract split panel -->
+      <v-horizontal-split-panel split-position="20px" min-split-position="0px" max-split-position="50px" locked>
+        <v-button>First slot</v-button>
+      </v-horizontal-split-panel>      
+      <v-vertical-split-panel split-position="25%" reversed>
+        <v-button :second>Second slot</v-button>
+      </v-vertical-split-panel>
+      <v-horizontal-split-panel split-position="25%" reversed>
+        <v-button>First slot</v-button>
+        <v-button>Second slot</v-button>
+      </v-horizontal-split-panel>
+     
+     <!--  label -->
+     <v-label>Hello world!</v-label>
+        <v-label>This is <b><u>Rich</u></b> content!</v-label>
+        <v-label plain-text>This is only <b>text</b> and will contain visible tags</v-label>
+        
+        <!-- checkbox -->
+        <v-check-box checked/>  
+
+     <!-- abstract select -->
+     <v-list-select new-items-allowed multi-select
+       item-caption-mode="index"
+       null-selection-allowed=false>
+     </v-list-select>
+
+     <v-combo-box>
+       <option icon="http://something/my-icon.png">First value</option>
+       <option>Second value</option>
+     </v-combo-box>
+
+  </v-vertical-layout>
+ </body>
+</html>
index 39aecb6db19778338b3d7223e0b5bcb3bc97e4d0..6507188cd74bb2fe87c0358d2aa411c7c56a2561 100644 (file)
   <meta name="package-mapping" content="my:com.addon.mypackage"/>
  </head>
  <body>
-  <v-vertical-layout>
+  <vaadin-vertical-layout>
       <!-- abstract component -->
-         <v-button primary-style-name="button" id="foo" style-name="red" caption="Some caption" icon="vaadin://themes/runo/icons/16/ok.png" description="My tooltip" error="Something went wrong" locale="en_US"></v-button>
+         <vaadin-button primary-style-name="button" id="foo" style-name="red" caption="Some caption" icon="vaadin://themes/runo/icons/16/ok.png" description="My tooltip" error="Something went wrong" locale="en_US"></vaadin-button>
 
       <!-- absolute layout -->
-      <v-absolute-layout>
-               <v-button :top="100px" :left="0px" :z-index=21>OK</v-button>
-               <v-button :bottom="0px" :right="0px">Cancel</v-button>
-         </v-absolute-layout>
+      <vaadin-absolute-layout>
+               <vaadin-button :top="100px" :left="0px" :z-index=21>OK</vaadin-button>
+               <vaadin-button :bottom="0px" :right="0px">Cancel</vaadin-button>
+         </vaadin-absolute-layout>
          
          <!--  vertical layout -->
-      <v-vertical-layout spacing margin>
-               <v-button :top>OK</v-button>
-               <v-table size-full :expand=1 />      
-      </v-vertical-layout>
+      <vaadin-vertical-layout spacing margin>
+               <vaadin-button :top>OK</vaadin-button>
+               <vaadin-table size-full :expand=1 />      
+      </vaadin-vertical-layout>
       
          <!--  horizontal layout -->
-      <v-horizontal-layout spacing margin>
-               <v-button :top>OK</v-button>
-               <v-table size-full :expand=1 />      
-      </v-horizontal-layout>
+      <vaadin-horizontal-layout spacing margin>
+               <vaadin-button :top>OK</vaadin-button>
+               <vaadin-table size-full :expand=1 />      
+      </vaadin-horizontal-layout>
       
          <!--  form layout -->
-      <v-form-layout spacing margin>
-               <v-button :top>OK</v-button>
-               <v-table size-full :expand=1 />      
-      </v-form-layout>
+      <vaadin-form-layout spacing margin>
+               <vaadin-button :top>OK</vaadin-button>
+               <vaadin-table size-full :expand=1 />      
+      </vaadin-form-layout>
 
          <!--  css layout -->
-      <v-css-layout>
-               <v-button>OK</v-button>
-               <v-table size-full />
-      </v-css-layout>
+      <vaadin-css-layout>
+               <vaadin-button>OK</vaadin-button>
+               <vaadin-table size-full />
+      </vaadin-css-layout>
       
       <!--  panel  -->
-      <v-panel caption="Hello world" tabindex=2 scroll-left="10" scroll-top="10">
-        <v-table size-full />
-      </v-panel>
+      <vaadin-panel caption="Hello world" tabindex=2 scroll-left="10" scroll-top="10">
+        <vaadin-table size-full />
+      </vaadin-panel>
       
       <!--  abstract field -->
-         <v-text-field buffered validation-visible=false invalid-committed invalid-allowed=false required required-error="This is a required field" conversion-error="Input {0} cannot be parsed" tabindex=3 readonly />
+         <vaadin-text-field buffered validation-visible=false invalid-committed invalid-allowed=false required required-error="This is a required field" conversion-error="Input {0} cannot be parsed" tabindex=3 readonly />
       <!--  abstract text field, text field -->
-      <v-text-field null-representation="" null-setting-allowed maxlength=10 columns=5 input-prompt="Please enter a value" text-change-event-mode="eager" text-change-timeout=2 value="foo" />
+      <vaadin-text-field null-representation="" null-setting-allowed maxlength=10 columns=5 input-prompt="Please enter a value" text-change-event-mode="eager" text-change-timeout=2 value="foo" />
          <!--  password field -->      
-      <v-password-field null-representation="" null-setting-allowed maxlength=10 columns=5 input-prompt="Please enter a value" text-change-event-mode="eager" text-change-timeout=2 value="foo" />
+      <vaadin-password-field null-representation="" null-setting-allowed maxlength=10 columns=5 input-prompt="Please enter a value" text-change-event-mode="eager" text-change-timeout=2 value="foo" />
       <!--  text area -->
-      <v-text-area rows=5 wordwrap=false >test value</v-text-area>
+      <vaadin-text-area rows=5 wordwrap=false >test value</vaadin-text-area>
       <!--  button -->
-      <v-button click-shortcut="ctrl-shift-o" disable-on-click tabindex=1 icon="http://vaadin.com/image.png" icon-alt="ok" plain-text>OK</v-button>
+      <vaadin-button click-shortcut="ctrl-shift-o" disable-on-click tabindex=1 icon="http://vaadin.com/image.png" icon-alt="ok" plain-text>OK</vaadin-button>
       <!--  native button -->
-      <v-button click-shortcut="ctrl-shift-o" disable-on-click tabindex=1 icon="http://vaadin.com/image.png" icon-alt="ok" plain-text>OK</v-button>
+      <vaadin-button click-shortcut="ctrl-shift-o" disable-on-click tabindex=1 icon="http://vaadin.com/image.png" icon-alt="ok" plain-text>OK</vaadin-button>
       
       <!-- tabsheet -->
-         <v-tab-sheet tabindex=5>
+         <vaadin-tab-sheet tabindex=5>
                  <tab visible=false closable caption="My first tab">
-                       <v-vertical-layout>
-                               <v-text-field/>
-                   </v-vertical-layout>
+                       <vaadin-vertical-layout>
+                               <vaadin-text-field/>
+                   </vaadin-vertical-layout>
                  </tab>
                  <tab enabled=false caption="Disabled second tab">
-                       <v-button>In disabled tab - can’t be shown by default</v-button>
+                       <vaadin-button>In disabled tab - can’t be shown by default</vaadin-button>
              </tab>
                  <tab icon="theme://../runo/icons/16/ok.png" icon-alt="Ok png from Runo - very helpful" description="Click to show a text field" style-name="red" id="uniqueDomId">
-                       <v-text-field input-prompt="Icon only in tab" />
+                       <vaadin-text-field input-prompt="Icon only in tab" />
              </tab>
-          </v-tab-sheet>
+          </vaadin-tab-sheet>
 
       <!-- accordion -->
-         <v-accordion tabindex=5>
+         <vaadin-accordion tabindex=5>
                  <tab visible=false closable caption="My first tab">
-                       <v-vertical-layout>
-                               <v-text-field/>
-                   </v-vertical-layout>
+                       <vaadin-vertical-layout>
+                               <vaadin-text-field/>
+                   </vaadin-vertical-layout>
                  </tab>
                  <tab enabled=false caption="Disabled second tab">
-                       <v-button>In disabled tab - can’t be shown by default</v-button>
+                       <vaadin-button>In disabled tab - can’t be shown by default</vaadin-button>
              </tab>
                  <tab icon="theme://../runo/icons/16/ok.png" icon-alt="Ok png from Runo - very helpful" description="Click to show a text field" style-name="red" id="uniqueDomId">
-                       <v-text-field input-prompt="Icon only in tab" />
+                       <vaadin-text-field input-prompt="Icon only in tab" />
              </tab>
-          </v-accordion>
+          </vaadin-accordion>
 
       <!--  abstract split panel -->
-      <v-horizontal-split-panel split-position="20px" min-split-position="0px" max-split-position="50px" locked>
-        <v-button>First slot</v-button>
-      </v-horizontal-split-panel>      
-      <v-vertical-split-panel split-position="25%" reversed>
-        <v-button :second>Second slot</v-button>
-      </v-vertical-split-panel>
-      <v-horizontal-split-panel split-position="25%" reversed>
-        <v-button>First slot</v-button>
-        <v-button>Second slot</v-button>
-      </v-horizontal-split-panel>
+      <vaadin-horizontal-split-panel split-position="20px" min-split-position="0px" max-split-position="50px" locked>
+        <vaadin-button>First slot</vaadin-button>
+      </vaadin-horizontal-split-panel>      
+      <vaadin-vertical-split-panel split-position="25%" reversed>
+        <vaadin-button :second>Second slot</vaadin-button>
+      </vaadin-vertical-split-panel>
+      <vaadin-horizontal-split-panel split-position="25%" reversed>
+        <vaadin-button>First slot</vaadin-button>
+        <vaadin-button>Second slot</vaadin-button>
+      </vaadin-horizontal-split-panel>
      
      <!--  label -->
-     <v-label>Hello world!</v-label>
-        <v-label>This is <b><u>Rich</u></b> content!</v-label>
-        <v-label plain-text>This is only <b>text</b> and will contain visible tags</v-label>
+     <vaadin-label>Hello world!</vaadin-label>
+        <vaadin-label>This is <b><u>Rich</u></b> content!</vaadin-label>
+        <vaadin-label plain-text>This is only <b>text</b> and will contain visible tags</vaadin-label>
         
         <!-- checkbox -->
-        <v-check-box checked/>  
+        <vaadin-check-box checked/>     
 
      <!-- abstract select -->
-     <v-list-select new-items-allowed multi-select
+     <vaadin-list-select new-items-allowed multi-select
        item-caption-mode="index"
        null-selection-allowed=false>
-     </v-list-select>
+     </vaadin-list-select>
 
-     <v-combo-box>
+     <vaadin-combo-box>
        <option icon="http://something/my-icon.png">First value</option>
        <option>Second value</option>
-     </v-combo-box>
+     </vaadin-combo-box>
 
-  </v-vertical-layout>
+  </vaadin-vertical-layout>
  </body>
 </html>
index 66e9202ca7a15d24af32a5c568f6fb8598aebe3f..3e7977f568f3a326c3b94a47b3125cb867af969b 100644 (file)
@@ -1,5 +1,5 @@
-<v-vertical-layout>
-    <v-button>OK</v-button>
-    <v-button>Cancel</v-button>
-    <v-label caption="preInitializedField">a Label that should not override pre initalized field<v-label/>
-</v-vertical-layout>
\ No newline at end of file
+<vaadin-vertical-layout>
+    <vaadin-button>OK</vaadin-button>
+    <vaadin-button>Cancel</vaadin-button>
+    <vaadin-label caption="preInitializedField">a Label that should not override pre initalized field<vaadin-label/>
+</vaadin-vertical-layout>
\ No newline at end of file
index ef845d46d5eca6c360cee60751eb5deb7f008400..984bb1e04774b5ca699c1d3c25e7aaf6213684b9 100644 (file)
@@ -1,4 +1,4 @@
-<v-vertical-layout>
-       <v-label id="foo"/>
-       <v-label id="foo"/>
-</v-vertical-layout>
\ No newline at end of file
+<vaadin-vertical-layout>
+       <vaadin-label id="foo"/>
+       <vaadin-label id="foo"/>
+</vaadin-vertical-layout>
\ No newline at end of file
index 5a506ad00cced423bf0e2d454e9dc99764af14f4..e8a698a39f8c46ea48a261bf2a8152758879e8bf 100644 (file)
@@ -1,4 +1,4 @@
-<v-vertical-layout>
-       <v-label _id="foo"/>
-       <v-label _id="foo"/>
-</v-vertical-layout>
\ No newline at end of file
+<vaadin-vertical-layout>
+       <vaadin-label _id="foo"/>
+       <vaadin-label _id="foo"/>
+</vaadin-vertical-layout>
\ No newline at end of file
index 638d004124ee80290d2d31e14fcf887d443d6b69..76ff642ee000bd7a6b1499125f26dbac2e360a25 100644 (file)
@@ -1,4 +1,4 @@
-<v-vertical-layout>
-    <v-text-field caption="Enter your name" _id="foo"/>
-    <v-button _id="bar">Say hello</v-button>
-</v-vertical-layout>
+<vaadin-vertical-layout>
+    <vaadin-text-field caption="Enter your name" _id="foo"/>
+    <vaadin-button _id="bar">Say hello</vaadin-button>
+</vaadin-vertical-layout>
index 344cd94ac281c2fb3ab6a859e30c1f3d3b594f2f..5c78802472b7bda732ac69b4356b6e703a47b20b 100644 (file)
  */
 package com.vaadin.tests.design.nested;
 
-import com.vaadin.ui.declarative.DesignContext;
+import static org.hamcrest.CoreMatchers.is;
+import static org.junit.Assert.assertEquals;
+import static org.junit.Assert.assertFalse;
+import static org.junit.Assert.assertThat;
+import static org.junit.Assert.assertTrue;
+
 import org.jsoup.nodes.Attributes;
 import org.jsoup.nodes.Element;
 import org.jsoup.parser.Tag;
 import org.junit.Before;
 import org.junit.Test;
 
-import static org.hamcrest.CoreMatchers.is;
-import static org.junit.Assert.*;
+import com.vaadin.ui.declarative.DesignContext;
 
 /**
  * 
@@ -43,7 +47,7 @@ public class WriteNestedTemplatesTest {
     }
 
     private Element createDesign() {
-        Element design = new Element(Tag.valueOf("v-vertical-layout"), "",
+        Element design = new Element(Tag.valueOf("vaadin-vertical-layout"), "",
                 new Attributes());
 
         DesignContext designContext = new DesignContext();
index c636033d2d429ddb81f4bb7a90b3b151e7712afc..0d2613539bee0ba2a3012cd846d3d3259507fc03 100644 (file)
@@ -4,9 +4,9 @@
   <meta name="package-mapping" content="x:com.vaadin.tests.design.nested"/>
  </head>
  <body>
-       <v-horizontal-layout caption="Default caption for child design">
-               <v-label _id="childLabel">test content</v-label>
+       <vaadin-horizontal-layout caption="Default caption for child design">
+               <vaadin-label _id="childLabel">test content</vaadin-label>
                <!--  Test some custom component in child template -->
                <x-my-child-design-custom-component _id="childCustomComponent">custom content</x-my-child-design-custom-component>
-       </v-horizontal-layout>
+       </vaadin-horizontal-layout>
 </body>
\ No newline at end of file
index 55ac27c194463bbebc2a5f403d24c53a7af17df0..6bf38db8f6d1a9212440472226e4006e50cc3a49 100644 (file)
@@ -4,7 +4,7 @@
   <meta name="package-mapping" content="x:com.vaadin.tests.design.nested"/>
  </head>
  <body>
-       <v-vertical-layout caption="root caption">
+       <vaadin-vertical-layout caption="root caption">
                <x-my-extended-child-design _id="childDesign" caption="child caption"/>
-       </v-vertical-layout>
+       </vaadin-vertical-layout>
  </body>
\ No newline at end of file
diff --git a/server/tests/src/com/vaadin/tests/design/testFile-legacy.html b/server/tests/src/com/vaadin/tests/design/testFile-legacy.html
new file mode 100644 (file)
index 0000000..79ae1e9
--- /dev/null
@@ -0,0 +1,19 @@
+<!DOCTYPE html>
+<html>
+ <head>
+  <meta name="package-mapping" content="my:com.addon.mypackage"/>
+ </head>
+ <body>
+  <v-vertical-layout width="500px">
+   <v-horizontal-layout>
+    <v-label plain-text caption="FooBar"></v-label>
+    <v-native-button _id=firstButton>Native click me</v-native-button>
+       <v-native-button id = secondButton _id="localID">Another button</v-native-button>
+       <v-native-button>Yet another button</v-native-button>
+    <v-button plain-text width = "150px">Click me</v-button>
+   </v-horizontal-layout>
+   <v-text-field caption = "Text input"/>
+   <v-text-area caption = "Text area" height="200px" width="300px"/>
+  </v-vertical-layout>
+ </body>
+</html>
\ No newline at end of file
index 79ae1e9eaf40395442345395117cc6390ac77f2d..ab23d1d1b2c45739d0bbe52131b3a99e5751bf92 100644 (file)
@@ -4,16 +4,16 @@
   <meta name="package-mapping" content="my:com.addon.mypackage"/>
  </head>
  <body>
-  <v-vertical-layout width="500px">
-   <v-horizontal-layout>
-    <v-label plain-text caption="FooBar"></v-label>
-    <v-native-button _id=firstButton>Native click me</v-native-button>
-       <v-native-button id = secondButton _id="localID">Another button</v-native-button>
-       <v-native-button>Yet another button</v-native-button>
-    <v-button plain-text width = "150px">Click me</v-button>
-   </v-horizontal-layout>
-   <v-text-field caption = "Text input"/>
-   <v-text-area caption = "Text area" height="200px" width="300px"/>
-  </v-vertical-layout>
+  <vaadin-vertical-layout width="500px">
+   <vaadin-horizontal-layout>
+    <vaadin-label plain-text caption="FooBar"></vaadin-label>
+    <vaadin-native-button _id=firstButton>Native click me</vaadin-native-button>
+       <vaadin-native-button id = secondButton _id="localID">Another button</vaadin-native-button>
+       <vaadin-native-button>Yet another button</vaadin-native-button>
+    <vaadin-button plain-text width = "150px">Click me</vaadin-button>
+   </vaadin-horizontal-layout>
+   <vaadin-text-field caption = "Text input"/>
+   <vaadin-text-area caption = "Text area" height="200px" width="300px"/>
+  </vaadin-vertical-layout>
  </body>
 </html>
\ No newline at end of file
index 4b0123b9edab9929cb2c20fc08c0ec702c752778..cf3dc65e4821b4567d7446bc3b2919fecc10634c 100644 (file)
@@ -1,3 +1,3 @@
-<v-vertical-layout>
-    <v-button>OK</v-button>
-</v-vertical-layout>
+<vaadin-vertical-layout>
+    <vaadin-button>OK</vaadin-button>
+</vaadin-vertical-layout>
index 87ae9eee8ee59094de6a4f59f9e5f40920344c05..dcf71a190bc6b809f9eeda7747c718d4896a1884 100644 (file)
@@ -1,4 +1,4 @@
-<v-vertical-layout>
-    <v-text-field caption="Enter your name" />
-    <v-button>Say hello</v-button>
-</v-vertical-layout>
+<vaadin-vertical-layout>
+    <vaadin-text-field caption="Enter your name" />
+    <vaadin-button>Say hello</vaadin-button>
+</vaadin-vertical-layout>
index 80ca95733c5cf99ccee6e5d0df3e427a125d83ed..f00eb91c5010336da71c42d2a907abea7d149153 100644 (file)
@@ -32,10 +32,10 @@ public class AbsoluteLayoutDeclarativeTest extends
 
     @Test
     public void testAbsoluteLayoutFeatures() {
-        String design = "<v-absolute-layout caption=\"test-layout\">"
-                + "<v-button :top='100px' :left='0px' :z-index=21>OK</v-button>"
-                + "<v-button :bottom='0px' :right='0px'>Cancel</v-button>"
-                + "</v-absolute-layout>";
+        String design = "<vaadin-absolute-layout caption=\"test-layout\">"
+                + "<vaadin-button :top='100px' :left='0px' :z-index=21>OK</vaadin-button>"
+                + "<vaadin-button :bottom='0px' :right='0px'>Cancel</vaadin-button>"
+                + "</vaadin-absolute-layout>";
         AbsoluteLayout layout = new AbsoluteLayout();
         layout.setCaption("test-layout");
         Button b1 = new Button("OK");
@@ -51,7 +51,7 @@ public class AbsoluteLayoutDeclarativeTest extends
 
     @Test
     public void testEmpty() {
-        String design = "<v-absolute-layout/>";
+        String design = "<vaadin-absolute-layout/>";
         AbsoluteLayout layout = new AbsoluteLayout();
         testRead(design, layout);
         testWrite(design, layout);
index 71021a06e1f6f0a860638e7575f129d0b98c9555..15a667eb28f360c85f0f07e85e7955326357439d 100644 (file)
@@ -62,14 +62,14 @@ public class AbstractComponentDeclarativeTest extends
 
     @Test
     public void testEmptyDesign() {
-        String design = "<v-label>";
+        String design = "<vaadin-label>";
         testRead(design, component);
         testWrite(design, component);
     }
 
     @Test
     public void testProperties() {
-        String design = "<v-label id=\"testId\" primary-style-name=\"test-style\" "
+        String design = "<vaadin-label id=\"testId\" primary-style-name=\"test-style\" "
                 + "caption=\"test-caption\" locale=\"fi_FI\" description=\"test-description\" "
                 + "error=\"<div>test-error</div>\" immediate=\"\"/>";
         component.setId("testId");
@@ -89,8 +89,8 @@ public class AbstractComponentDeclarativeTest extends
     public void testReadImmediate() {
         // Additional tests for the immediate property, including
         // explicit immediate values
-        String[] design = { "<v-label/>", "<v-label immediate=\"false\"/>",
-                "<v-label immediate=\"true\"/>", "<v-label immediate=\"\"/>" };
+        String[] design = { "<vaadin-label/>", "<vaadin-label immediate=\"false\"/>",
+                "<vaadin-label immediate=\"true\"/>", "<vaadin-label immediate=\"\"/>" };
         Boolean[] explicitImmediate = { null, Boolean.FALSE, Boolean.TRUE,
                 Boolean.TRUE };
         boolean[] immediate = { false, false, true, true };
@@ -105,7 +105,7 @@ public class AbstractComponentDeclarativeTest extends
 
     @Test
     public void testExternalIcon() {
-        String design = "<v-label icon=\"http://example.com/example.gif\"/>";
+        String design = "<vaadin-label icon=\"http://example.com/example.gif\"/>";
         component
                 .setIcon(new ExternalResource("http://example.com/example.gif"));
         testRead(design, component);
@@ -114,7 +114,7 @@ public class AbstractComponentDeclarativeTest extends
 
     @Test
     public void testThemeIcon() {
-        String design = "<v-label icon=\"theme://example.gif\"/>";
+        String design = "<vaadin-label icon=\"theme://example.gif\"/>";
         component.setIcon(new ThemeResource("example.gif"));
         testRead(design, component);
         testWrite(design, component);
@@ -122,7 +122,7 @@ public class AbstractComponentDeclarativeTest extends
 
     @Test
     public void testFileResourceIcon() {
-        String design = "<v-label icon=\"img/example.gif\"/>";
+        String design = "<vaadin-label icon=\"img/example.gif\"/>";
         component.setIcon(new FileResource(new File("img/example.gif")));
         testRead(design, component);
         testWrite(design, component);
@@ -130,7 +130,7 @@ public class AbstractComponentDeclarativeTest extends
 
     @Test
     public void testWidthAndHeight() {
-        String design = "<v-label width=\"70%\" height=\"12px\"/>";
+        String design = "<vaadin-label width=\"70%\" height=\"12px\"/>";
         component.setWidth("70%");
         component.setHeight("12px");
         testRead(design, component);
@@ -139,7 +139,7 @@ public class AbstractComponentDeclarativeTest extends
 
     @Test
     public void testSizeFull() {
-        String design = "<v-label size-full=\"\"/>";
+        String design = "<vaadin-label size-full=\"\"/>";
         component.setSizeFull();
         testRead(design, component);
         testWrite(design, component);
@@ -147,7 +147,7 @@ public class AbstractComponentDeclarativeTest extends
 
     @Test
     public void testSizeAuto() {
-        String design = "<v-label size-auto=\"\"/>";
+        String design = "<vaadin-label size-auto=\"\"/>";
         component.setSizeUndefined();
         testRead(design, component);
         testWrite(design, component);
@@ -155,7 +155,7 @@ public class AbstractComponentDeclarativeTest extends
 
     @Test
     public void testHeightFull() {
-        String design = "<v-label height-full=\"\"/ width=\"20px\"/>";
+        String design = "<vaadin-label height-full=\"\"/ width=\"20px\"/>";
         component.setHeight("100%");
         component.setWidth("20px");
         testRead(design, component);
@@ -164,7 +164,7 @@ public class AbstractComponentDeclarativeTest extends
 
     @Test
     public void testHeightAuto() {
-        String design = "<v-horizontal-split-panel height-auto=\"\"/ width=\"20px\" >";
+        String design = "<vaadin-horizontal-split-panel height-auto=\"\"/ width=\"20px\" >";
         // we need to have default height of 100% -> use split panel
         AbstractComponent component = new HorizontalSplitPanel();
         component.setHeight(null);
@@ -175,7 +175,7 @@ public class AbstractComponentDeclarativeTest extends
 
     @Test
     public void testWidthFull() {
-        String design = "<v-button width-full=\"\"/ height=\"20px\">Foo</button>";
+        String design = "<vaadin-button width-full=\"\"/ height=\"20px\">Foo</button>";
         AbstractComponent component = new Button();
         component.setCaptionAsHtml(true);
         component.setCaption("Foo");
@@ -187,7 +187,7 @@ public class AbstractComponentDeclarativeTest extends
 
     @Test
     public void testWidthAuto() {
-        String design = "<v-label height=\"20px\"/ width-auto=\"\"/>";
+        String design = "<vaadin-label height=\"20px\"/ width-auto=\"\"/>";
         component.setCaptionAsHtml(false);
         component.setHeight("20px");
         component.setWidth(null);
@@ -197,7 +197,7 @@ public class AbstractComponentDeclarativeTest extends
 
     @Test
     public void testResponsive() {
-        String design = "<v-label responsive =\"\"/>";
+        String design = "<vaadin-label responsive =\"\"/>";
         Responsive.makeResponsive(component);
         testRead(design, component);
         testWrite(design, component);
@@ -205,7 +205,7 @@ public class AbstractComponentDeclarativeTest extends
 
     @Test
     public void testResponsiveFalse() {
-        String design = "<v-label responsive =\"false\"/>";
+        String design = "<vaadin-label responsive =\"false\"/>";
         // Only test read as the attribute responsive=false would not be written
         testRead(design, component);
     }
@@ -223,7 +223,7 @@ public class AbstractComponentDeclarativeTest extends
     private Element createDesign(String key, String value) {
         Attributes attributes = new Attributes();
         attributes.put(key, value);
-        Element node = new Element(Tag.valueOf("v-label"), "", attributes);
+        Element node = new Element(Tag.valueOf("vaadin-label"), "", attributes);
         return node;
     }
 
index b4afde592394cdaf8c2991d64b0d9d1fe4f0f1b8..a4ed0d364f37e5a969857fb75b974bd3feebfaa9 100644 (file)
@@ -33,7 +33,7 @@ public class AbstractFieldDeclarativeTest extends
 
     @Test
     public void testPlainText() {
-        String design = "<v-text-field buffered='' validation-visible='false' invalid-committed=''"
+        String design = "<vaadin-text-field buffered='' validation-visible='false' invalid-committed=''"
                 + " invalid-allowed='false' required='' required-error='This is a required field'"
                 + " conversion-error='Input {0} cannot be parsed' tabindex=3 readonly=''/>";
         AbstractField tf = new TextField();
@@ -61,7 +61,7 @@ public class AbstractFieldDeclarativeTest extends
     public void testModelReadOnly() {
         // Test that read only value coming from property data source is not
         // written to design.
-        String design = "<v-text-field value=test></v-text-field>";
+        String design = "<vaadin-text-field value=test></vaadin-text-field>";
         AbstractField component = new TextField();
         ObjectProperty<String> property = new ObjectProperty<String>("test");
         property.setReadOnly(true);
index 28ccfa407c37c02b8995ae879d1da2d4e319e612..b23083ab05cae89b63d04bee54ce7ff679a155e0 100644 (file)
@@ -42,7 +42,7 @@ public class AbstractOrderedLayoutDeclarativeTest extends
 
     @Test
     public void testMargins() {
-        testMargins("v-vertical-layout");
+        testMargins("vaadin-vertical-layout");
     }
 
     @Test
@@ -74,8 +74,8 @@ public class AbstractOrderedLayoutDeclarativeTest extends
     }
 
     private String getDesign(float expandRatio, String... alignments) {
-        String result = "<v-vertical-layout caption=test-layout>";
-        result += "<v-label caption=test-label ";
+        String result = "<vaadin-vertical-layout caption=test-layout>";
+        result += "<vaadin-label caption=test-label ";
         String ratioString = expandRatio == 1.0f ? "\"\"" : String
                 .valueOf(expandRatio);
         if (expandRatio != 0) {
@@ -86,7 +86,7 @@ public class AbstractOrderedLayoutDeclarativeTest extends
                 result += " " + alignment + "=\"\"";
             }
         }
-        result += "></v-label><v-button ";
+        result += "></vaadin-label><vaadin-button ";
         if (expandRatio != 0) {
             result += ":expand=" + ratioString;
         }
@@ -95,7 +95,7 @@ public class AbstractOrderedLayoutDeclarativeTest extends
                 result += " " + alignment + "=\"\"";
             }
         }
-        result += "></v-button></v-vertical-layout>";
+        result += "></vaadin-button></vaadin-vertical-layout>";
         return result;
     }
 
index 4f971412b8f53496e1b3ad6bd4219fd7f7a84e01..b93bcc0ae8f3724f216a56780ce6c49062a9873a 100644 (file)
@@ -43,7 +43,7 @@ public class AbstractSelectDeclarativeTest extends
         DeclarativeTestBase<AbstractSelect> {
 
     public String getDesignSingleSelectNewItemsAllowed() {
-        return "<v-combo-box new-items-allowed='' item-caption-mode='icon_only'"
+        return "<vaadin-combo-box new-items-allowed='' item-caption-mode='icon_only'"
                 + " null-selection-item-id='nullIid'/>";
 
     }
@@ -58,7 +58,7 @@ public class AbstractSelectDeclarativeTest extends
     }
 
     public String getDesignMultiSelect() {
-        return "<v-list-select multi-select='' null-selection-allowed='false' new-items-allowed='' item-caption-mode='property' />";
+        return "<vaadin-list-select multi-select='' null-selection-allowed='false' new-items-allowed='' item-caption-mode='property' />";
     }
 
     public AbstractSelect getExpectedMultiSelect() {
@@ -99,8 +99,8 @@ public class AbstractSelectDeclarativeTest extends
 
     @Test(expected = DesignException.class)
     public void testReadMultipleValuesForSingleSelect() {
-        testRead("<v-list-select>" + "<option selected>1</option>"
-                + "<option selected>2</option>" + "</v-list-select>", null);
+        testRead("<vaadin-list-select>" + "<option selected>1</option>"
+                + "<option selected>2</option>" + "</vaadin-list-select>", null);
     }
 
     @Test
@@ -111,8 +111,9 @@ public class AbstractSelectDeclarativeTest extends
         ls.addItem("2");
         ls.select("1");
         ls.select("2");
-        testRead("<v-list-select multi-select>" + "<option selected>1</option>"
-                + "<option selected>2</option>" + "</v-list-select>", ls);
+        testRead("<vaadin-list-select multi-select>"
+                + "<option selected>1</option>" + "<option selected>2</option>"
+                + "</vaadin-list-select>", ls);
     }
 
     @Test
@@ -122,8 +123,9 @@ public class AbstractSelectDeclarativeTest extends
         ls.addItem("1");
         ls.addItem("2");
         ls.select("1");
-        testRead("<v-list-select multi-select>" + "<option selected>1</option>"
-                + "<option>2</option>" + "</v-list-select>", ls);
+        testRead("<vaadin-list-select multi-select>"
+                + "<option selected>1</option>" + "<option>2</option>"
+                + "</vaadin-list-select>", ls);
     }
 
     @Test
@@ -133,8 +135,8 @@ public class AbstractSelectDeclarativeTest extends
         ls.addItem("1");
         ls.addItem("2");
         ls.select("1");
-        testRead("<v-list-select>" + "<option selected>1</option>"
-                + "<option>2</option>" + "</v-list-select>", ls);
+        testRead("<vaadin-list-select>" + "<option selected>1</option>"
+                + "<option>2</option>" + "</vaadin-list-select>", ls);
     }
 
     @Test
@@ -151,10 +153,10 @@ public class AbstractSelectDeclarativeTest extends
     }
 
     private String getDesignForInlineData() {
-        return "<v-list-select>\n"
+        return "<vaadin-list-select>\n"
                 + "        <option icon='http://some.url/icon.png'>Value 1</option>\n" //
                 + "        <option selected>Value 2</option>\n"//
-                + "</v-list-select>";
+                + "</vaadin-list-select>";
     }
 
     private AbstractSelect getExpectedComponentForInlineData() {
@@ -213,7 +215,7 @@ public class AbstractSelectDeclarativeTest extends
         attributes.put("item-icon-property-id", "icon");
         attributes.put("null-selection-allowed", "");
         attributes.put("null-selection-item-id", "No items selected");
-        return new Element(Tag.valueOf("v-combo-box"), "", attributes);
+        return new Element(Tag.valueOf("vaadin-combo-box"), "", attributes);
     }
 
     private Element createDesignWithAttributesMultiSelect() {
@@ -221,13 +223,13 @@ public class AbstractSelectDeclarativeTest extends
         attributes.put("multi-select", "");
         attributes.put("item-caption-mode", "EXPLICIT");
         attributes.put("null-selection-allowed", "false");
-        return new Element(Tag.valueOf("v-list-select"), "", attributes);
+        return new Element(Tag.valueOf("vaadin-list-select"), "", attributes);
     }
 
     @Test
     public void testWriteAttributesSingleSelect() {
         ComboBox cb = createSingleSelectWithOnlyAttributes();
-        Element e = new Element(Tag.valueOf("v-combo-box"), "");
+        Element e = new Element(Tag.valueOf("vaadin-combo-box"), "");
         cb.writeDesign(e, new DesignContext());
         assertEquals("Wrong caption for the combo box.", "A combo box",
                 e.attr("caption"));
@@ -248,7 +250,7 @@ public class AbstractSelectDeclarativeTest extends
     @Test
     public void testWriteMultiListSelect() {
         ListSelect ls = createMultiSelect();
-        Element e = new Element(Tag.valueOf("v-list-select"), "");
+        Element e = new Element(Tag.valueOf("vaadin-list-select"), "");
         ls.writeDesign(e, new DesignContext());
         assertEquals("Null selection should not be allowed.", "false",
                 e.attr("null-selection-allowed"));
@@ -260,9 +262,9 @@ public class AbstractSelectDeclarativeTest extends
 
     @Test
     public void testHtmlEntities() {
-        String design = "<v-combo-box>"
+        String design = "<vaadin-combo-box>"
                 + "  <option item-id=\"one\">&gt; One</option>"
-                + "  <option>&gt; Two</option>" + "</v-combo-box>";
+                + "  <option>&gt; Two</option>" + "</vaadin-combo-box>";
         AbstractSelect read = read(design);
 
         Assert.assertEquals("> One", read.getItemCaption("one"));
@@ -270,7 +272,7 @@ public class AbstractSelectDeclarativeTest extends
         AbstractSelect underTest = new ComboBox();
         underTest.addItem("> One");
 
-        Element root = new Element(Tag.valueOf("v-combo-box"), "");
+        Element root = new Element(Tag.valueOf("vaadin-combo-box"), "");
         DesignContext dc = new DesignContext();
         dc.setShouldWriteDataDelegate(DeclarativeTestBaseBase.ALWAYS_WRITE_DATA);
         underTest.writeDesign(root, dc);
index 3e6a7a15cb72e9c4eade05ba7f980d1fb3290b3e..92a8c12a9aaacbf50dce4f8f7001e7817da90a66 100644 (file)
@@ -35,7 +35,7 @@ public class OptionGroupDeclarativeTests extends
     @Test
     public void testBasicSyntax() {
 
-        String expected = "<v-option-group />";
+        String expected = "<vaadin-option-group />";
         testReadWrite(expected);
 
     }
@@ -47,12 +47,12 @@ public class OptionGroupDeclarativeTests extends
 
         //@formatter:off
         String expected = 
-                "<v-option-group>"
+                "<vaadin-option-group>"
                 + "<option>foo</option>"
                 + "<option>bar</option>"
                 + "<option>baz</option>"
                 + "<option>bang</option>"
-                + "</v-option-group>";
+                + "</vaadin-option-group>";
         //@formatter:on
 
         testReadWrite(expected);
@@ -67,12 +67,12 @@ public class OptionGroupDeclarativeTests extends
 
         //@formatter:off
         String expected = 
-                "<v-option-group>"
+                "<vaadin-option-group>"
                 + "<option>foo</option>"
                 + "<option>bar</option>"
                 + "<option disabled>baz</option>"
                 + "<option>bang</option>"
-                + "</v-option-group>";
+                + "</vaadin-option-group>";
         //@formatter:on
 
         testReadWrite(expected);
@@ -87,12 +87,12 @@ public class OptionGroupDeclarativeTests extends
 
         //@formatter:off
         String expected = 
-                "<v-option-group>"
+                "<vaadin-option-group>"
                 + "<option>foo</option>"
                 + "<option icon='theme://foobar.png'>bar</option>"
                 + "<option>baz</option>"
                 + "<option>bang</option>"
-                + "</v-option-group>";
+                + "</vaadin-option-group>";
         //@formatter:on
 
         testReadWrite(expected);
@@ -111,12 +111,12 @@ public class OptionGroupDeclarativeTests extends
 
         //@formatter:off
         String expected = 
-                "<v-option-group html-content-allowed=''>"
+                "<vaadin-option-group html-content-allowed=''>"
                 + "<option item-id=\"foo\"><b>True</b></option>"
                 + "<option item-id=\"bar\"><font color='red'>False</font></option>"
                 + "<option>baz</option>"
                 + "<option>bang</option>"
-                + "</v-option-group>";
+                + "</vaadin-option-group>";
         //@formatter:on
 
         testReadWrite(expected);
@@ -131,13 +131,13 @@ public class OptionGroupDeclarativeTests extends
         og.setItemCaption("bar", "<font color=\"red\">False</font>");
 
         //@formatter:off
-        String expected = 
-                "<v-option-group>"
+        String expected =
+                "<vaadin-option-group>"
                 + "<option item-id=\"foo\">&lt;b&gt;True&lt;/b&gt;</option>"
                 + "<option item-id=\"bar\">&lt;font color=\"red\"&gt;False&lt;/font&gt;</option>"
                 + "<option>baz</option>"
                 + "<option>bang</option>"
-                + "</v-option-group>";
+                + "</vaadin-option-group>";
         //@formatter:on
 
         testReadWrite(expected);
index 11d97d191bca1072548af72bc4b8ad1b680908db..3ac8416762a9f9ffa55253203f25b91c4c9b3cc1 100644 (file)
@@ -37,10 +37,10 @@ public class AbstractSplitPanelDeclarativeTest extends
 
     @Test
     public void testWithBothChildren() {
-        String design = "<v-horizontal-split-panel split-position=20.5% "
+        String design = "<vaadin-horizontal-split-panel split-position=20.5% "
                 + "min-split-position=20% max-split-position=50px locked='' "
-                + "reversed=\"\"> <v-table /> <v-vertical-layout />"
-                + "</v-horizontal-split-panel>";
+                + "reversed=\"\"> <vaadin-table /> <vaadin-vertical-layout />"
+                + "</vaadin-horizontal-split-panel>";
         AbstractSplitPanel sp = new HorizontalSplitPanel();
         sp.setSplitPosition(20.5f, Unit.PERCENTAGE, true);
         sp.setMinSplitPosition(20, Unit.PERCENTAGE);
@@ -54,8 +54,8 @@ public class AbstractSplitPanelDeclarativeTest extends
 
     @Test
     public void testWithFirstChild() {
-        String design = "<v-vertical-split-panel><v-table caption=\"First slot\"/>"
-                + "</v-vertical-split-panel>";
+        String design = "<vaadin-vertical-split-panel><vaadin-table caption=\"First slot\"/>"
+                + "</vaadin-vertical-split-panel>";
         AbstractSplitPanel sp = new VerticalSplitPanel();
         Table t = new Table();
         t.setCaption("First slot");
@@ -66,8 +66,8 @@ public class AbstractSplitPanelDeclarativeTest extends
 
     @Test
     public void testWithSecondChild() {
-        String design = "<v-horizontal-split-panel><v-button :second>Second slot</v-button>"
-                + "</v-vertical-split-panel>";
+        String design = "<vaadin-horizontal-split-panel><vaadin-button :second>Second slot</vaadin-button>"
+                + "</vaadin-vertical-split-panel>";
         AbstractSplitPanel sp = new HorizontalSplitPanel();
         Button b = new Button("Second slot");
         b.setCaptionAsHtml(true);
@@ -78,7 +78,7 @@ public class AbstractSplitPanelDeclarativeTest extends
 
     @Test
     public void testEmpty() {
-        String design = "<v-horizontal-split-panel/>";
+        String design = "<vaadin-horizontal-split-panel/>";
         AbstractSplitPanel sp = new HorizontalSplitPanel();
         testRead(design, sp);
         testWrite(design, sp);
index b8e570bc89bf30fad30e44b526ddf702b0dffb3a..4d6411845e37dda7860a2bd9583f4398136e5f96 100644 (file)
@@ -33,7 +33,7 @@ public class AbstractTextFieldDeclarativeTest extends
 
     @Test
     public void testAttributes() {
-        String design = "<v-text-field null-representation=this-is-null "
+        String design = "<vaadin-text-field null-representation=this-is-null "
                 + "null-setting-allowed='' maxlength=5 columns=3 "
                 + "input-prompt=input text-change-event-mode=eager "
                 + "text-change-timeout=100 />";
index ec2b5241f3f8a809b22c06e23a21513796a8b71a..d1143ff0c10929db291d2cf1cf70fcd5b5dcd0d8 100644 (file)
@@ -35,7 +35,7 @@ public class AudioDeclarativeTest extends DeclarativeTestBase<Audio> {
 
     @Test
     public void testEmptyAudio() {
-        String design = "<v-audio />";
+        String design = "<vaadin-audio />";
         Audio audio = new Audio();
         testRead(design, audio);
         testWrite(design, audio);
@@ -43,12 +43,12 @@ public class AudioDeclarativeTest extends DeclarativeTestBase<Audio> {
 
     @Test
     public void testAudioMultipleSources() {
-        String design = "<v-audio muted='' show-controls='false'>"
+        String design = "<vaadin-audio muted='' show-controls='false'>"
                 + "some <b>text</b>" //
                 + "<source href='http://foo.pl' />"
                 + "<source href='https://bar.pl' />" //
                 + "<source href='ohai' />" //
-                + "</v-audio>";
+                + "</vaadin-audio>";
         Audio audio = new Audio();
         audio.setAltText("some <b>text</b>");
         audio.setAutoplay(false);
index 5be70bd2db04495590e9bafbac0238f5a28527a1..f904c146a766acc3f4fc047202d597badb7c11ca 100644 (file)
@@ -28,7 +28,7 @@ public class VideoDeclarativeTest extends DeclarativeTestBase<Video> {
 
     @Test
     public void testEmptyVideo() {
-        String design = "<v-video />";
+        String design = "<vaadin-video />";
         Video audio = new Video();
         testRead(design, audio);
         testWrite(design, audio);
@@ -36,13 +36,13 @@ public class VideoDeclarativeTest extends DeclarativeTestBase<Video> {
 
     @Test
     public void testVideoMultipleSources() {
-        String design = "<v-video muted='' show-controls='false'>"
+        String design = "<vaadin-video muted='' show-controls='false'>"
                 + "some <b>text</b>" //
                 + "<source href='http://foo.pl' />"
                 + "<source href='https://bar.pl' />" //
                 + "<source href='ohai' />" //
                 + "<poster href='http://foo.pl/poster' />" //
-                + "</v-video>";
+                + "</vaadin-video>";
         Video video = new Video();
         video.setAltText("some <b>text</b>");
         video.setAutoplay(false);
index f4f50560b4600436feddca633d3bbbb694d14976..b62499a28e82303e202d8a011cc0e871a00f99c3 100644 (file)
@@ -31,7 +31,7 @@ public class BrowserFrameDeclarativeTest extends
         DeclarativeTestBase<BrowserFrame> {
 
     protected String getDesign() {
-        return "<v-browser-frame source='http://foo.bar/some.html' />";
+        return "<vaadin-browser-frame source='http://foo.bar/some.html' />";
     }
 
     protected BrowserFrame getExpectedResult() {
@@ -52,6 +52,6 @@ public class BrowserFrameDeclarativeTest extends
 
     @Test
     public void testEmpty() {
-        testRead("<v-browser-frame/>", new BrowserFrame());
+        testRead("<vaadin-browser-frame/>", new BrowserFrame());
     }
 }
index e299b5ecf768f66f28fb1b0244def0b9df9230ad..a1ce2ed1b38619fa24b75577adb3e750561b5941 100644 (file)
@@ -38,73 +38,74 @@ public class ButtonDeclarativeTest extends DeclarativeTestBase<Button> {
 
     @Test
     public void testEmptyPlainText() {
-        String design = "<v-button plain-text=''></v-button>";
+        String design = "<vaadin-button plain-text=''></vaadin-button>";
         testButtonAndNativeButton(design, false, "");
     }
 
     @Test
     public void testPlainTextCaption() {
-        String design = "<v-button plain-text=''>Click</v-button>";
+        String design = "<vaadin-button plain-text=''>Click</vaadin-button>";
         testButtonAndNativeButton(design, false, "Click");
     }
 
     @Test
     public void testEmptyHtml() {
-        String design = "<v-button />";
+        String design = "<vaadin-button />";
         testButtonAndNativeButton(design, true, "");
     }
 
     @Test
     public void testHtmlCaption() {
-        String design = "<v-button><b>Click</b></v-button>";
+        String design = "<vaadin-button><b>Click</b></vaadin-button>";
         testButtonAndNativeButton(design, true, "<b>Click</b>");
     }
 
     @Test
     public void testWithCaptionAttribute() {
         // The caption attribute should be ignored
-        String design = "<v-button caption=Caption>Click</v-button>";
-        String expectedWritten = "<v-button>Click</v-button>";
+        String design = "<vaadin-button caption=Caption>Click</vaadin-button>";
+        String expectedWritten = "<vaadin-button>Click</vaadin-button>";
         testButtonAndNativeButton(design, true, "Click", expectedWritten);
     }
 
     @Test
     public void testWithOnlyCaptionAttribute() {
-        String design = "<v-button caption=Click/>";
-        String expectedWritten = "<v-button/>";
+        String design = "<vaadin-button caption=Click/>";
+        String expectedWritten = "<vaadin-button/>";
         testButtonAndNativeButton(design, true, "", expectedWritten);
     }
 
     @Test
     public void testHtmlEntitiesInCaption() {
-        String designPlainText = "<v-button plain-text=\"true\">&gt; One</v-button>";
+        String designPlainText = "<vaadin-button plain-text=\"true\">&gt; One</vaadin-button>";
         String expectedCaptionPlainText = "> One";
 
         Button read = read(designPlainText);
         Assert.assertEquals(expectedCaptionPlainText, read.getCaption());
 
-        designPlainText = designPlainText
-                .replace("v-button", "v-native-button");
+        designPlainText = designPlainText.replace("vaadin-button",
+                "vaadin-native-button");
         Button nativeButton = read(designPlainText);
         Assert.assertEquals(expectedCaptionPlainText, nativeButton.getCaption());
 
-        String designHtml = "<v-button>&gt; One</v-button>";
+        String designHtml = "<vaadin-button>&gt; One</vaadin-button>";
         String expectedCaptionHtml = "&gt; One";
         read = read(designHtml);
         Assert.assertEquals(expectedCaptionHtml, read.getCaption());
 
-        designHtml = designHtml.replace("v-button", "v-native-button");
+        designHtml = designHtml
+                .replace("vaadin-button", "vaadin-native-button");
         nativeButton = read(designHtml);
         Assert.assertEquals(expectedCaptionHtml, nativeButton.getCaption());
 
         read = new Button("&amp; Test");
         read.setHtmlContentAllowed(true);
-        Element root = new Element(Tag.valueOf("v-button"), "");
+        Element root = new Element(Tag.valueOf("vaadin-button"), "");
         read.writeDesign(root, new DesignContext());
         assertEquals("&amp; Test", root.html());
 
         read.setHtmlContentAllowed(false);
-        root = new Element(Tag.valueOf("v-button"), "");
+        root = new Element(Tag.valueOf("vaadin-button"), "");
         read.writeDesign(root, new DesignContext());
         assertEquals("&amp;amp; Test", root.html());
 
@@ -124,9 +125,9 @@ public class ButtonDeclarativeTest extends DeclarativeTestBase<Button> {
         testRead(expectedWritten, b);
         testWrite(expectedWritten, b);
         // Test NativeButton
-        design = design.replace("v-button", "v-native-button");
-        expectedWritten = expectedWritten
-                .replace("v-button", "v-native-button");
+        design = design.replace("vaadin-button", "vaadin-native-button");
+        expectedWritten = expectedWritten.replace("vaadin-button",
+                "vaadin-native-button");
         NativeButton nb = new NativeButton();
         nb.setCaptionAsHtml(html);
         nb.setCaption(caption);
@@ -136,8 +137,8 @@ public class ButtonDeclarativeTest extends DeclarativeTestBase<Button> {
 
     @Test
     public void testAttributes() {
-        String design = "<v-button tabindex=3 plain-text='' icon-alt=OK "
-                + "click-shortcut=shift-ctrl-o></v-button>";
+        String design = "<vaadin-button tabindex=3 plain-text='' icon-alt=OK "
+                + "click-shortcut=shift-ctrl-o></vaadin-button>";
         Button b = new Button("");
         b.setTabIndex(3);
         b.setIconAlternateText("OK");
index d866878fc7504994a5752fd6cae4a06225cad665..f0ee8f72985eba010a21e4babb8054f3771693b7 100644 (file)
@@ -30,12 +30,12 @@ public class CalendarDeclarativeTest extends DeclarativeTestBase<Calendar> {
 
     @Test
     public void testEmpty() {
-        verifyDeclarativeDesign("<v-calendar></v-calendar>", new Calendar());
+        verifyDeclarativeDesign("<vaadin-calendar></vaadin-calendar>", new Calendar());
     }
 
     @Test
     public void testCalendarAllFeatures() throws ParseException {
-        String design = "<v-calendar start-date='2014-11-17' end-date='2014-11-23' "
+        String design = "<vaadin-calendar start-date='2014-11-17' end-date='2014-11-23' "
                 + "first-visible-day-of-week=2 last-visible-day-of-week=5 "
                 + "time-zone='EST' time-format='12h' first-visible-hour-of-day=8 "
                 + "last-visible-hour-of-day=18 weekly-caption-format='mmm MM/dd' />";
index 6206617cd83c4c549528caa4d25b73138df5592e..ec68f7ccbb866d43df415cf9d60662a75eae5a8d 100644 (file)
@@ -30,7 +30,7 @@ public class CheckboxDeclarativeTest extends DeclarativeTestBase<CheckBox> {
 
     @Test
     public void testChecked() {
-        String design = "<v-check-box />";
+        String design = "<vaadin-check-box />";
         CheckBox checkBox = new CheckBox();
         testRead(design, checkBox);
         testWrite(design, checkBox);
@@ -38,7 +38,7 @@ public class CheckboxDeclarativeTest extends DeclarativeTestBase<CheckBox> {
 
     @Test
     public void testUnchecked() {
-        String design = "<v-check-box checked='' />";
+        String design = "<vaadin-check-box checked='' />";
         CheckBox checkBox = new CheckBox();
         checkBox.setValue(true);
         testRead(design, checkBox);
@@ -47,7 +47,7 @@ public class CheckboxDeclarativeTest extends DeclarativeTestBase<CheckBox> {
 
     @Test
     public void testReadOnlyValue() {
-        String design = "<v-check-box readonly checked='' />";
+        String design = "<vaadin-check-box readonly checked='' />";
         CheckBox checkBox = new CheckBox();
         checkBox.setValue(true);
         checkBox.setReadOnly(true);
index 33521d3af261aaa29b5d4cfa1bd1883a71e8687a..a075a974c9792c7cee565a63e15a07bfd47f1af7 100644 (file)
@@ -29,7 +29,7 @@ public class AbstractColorPickerDeclarativeTest extends
 
     @Test
     public void testAllAbstractColorPickerFeatures() {
-        String design = "<v-color-picker color='#fafafa' default-caption-enabled='' position='100,100'"
+        String design = "<vaadin-color-picker color='#fafafa' default-caption-enabled='' position='100,100'"
                 + " popup-style='simple' rgb-visibility='false' hsv-visibility='false'"
                 + " history-visibility=false textfield-visibility=false />";
         ColorPicker colorPicker = new ColorPicker();
@@ -50,7 +50,7 @@ public class AbstractColorPickerDeclarativeTest extends
 
     @Test
     public void testEmptyColorPicker() {
-        String design = "<v-color-picker />";
+        String design = "<vaadin-color-picker />";
         ColorPicker colorPicker = new ColorPicker();
         testRead(design, colorPicker);
         testWrite(design, colorPicker);
@@ -58,7 +58,7 @@ public class AbstractColorPickerDeclarativeTest extends
 
     @Test
     public void testAllAbstractColorPickerAreaFeatures() {
-        String design = "<v-color-picker-area color='#fafafa' default-caption-enabled='' position='100,100'"
+        String design = "<vaadin-color-picker-area color='#fafafa' default-caption-enabled='' position='100,100'"
                 + " popup-style='simple' rgb-visibility='false' hsv-visibility='false'"
                 + " history-visibility=false textfield-visibility=false />";
         AbstractColorPicker colorPicker = new ColorPickerArea();
@@ -79,7 +79,7 @@ public class AbstractColorPickerDeclarativeTest extends
 
     @Test
     public void testEmptyColorPickerArea() {
-        String design = "<v-color-picker-area />";
+        String design = "<vaadin-color-picker-area />";
         AbstractColorPicker colorPicker = new ColorPickerArea();
         testRead(design, colorPicker);
         testWrite(design, colorPicker);
index d49d2b79e235cadb41aed02d1a1f0879a9923cf2..fcc7eb97a13113d6d1654f830548dd86f4079ede 100644 (file)
@@ -38,7 +38,7 @@ public class ComboBoxDeclarativeTest extends DeclarativeTestBase<ComboBox> {
     }
 
     private String getReadOnlyWithOptionsDesign() {
-        return "<v-combo-box text-input-allowed='false'><option>Hello</option><option>World</option></v-combo-box>";
+        return "<vaadin-combo-box text-input-allowed='false'><option>Hello</option><option>World</option></vaadin-combo-box>";
     }
 
     @Test
@@ -59,7 +59,7 @@ public class ComboBoxDeclarativeTest extends DeclarativeTestBase<ComboBox> {
 
     @Test
     public void testReadOnlyValue() {
-        String design = "<v-combo-box readonly value='foo'><option selected>foo</option></v-combo-box>";
+        String design = "<vaadin-combo-box readonly value='foo'><option selected>foo</option></vaadin-combo-box>";
 
         ComboBox comboBox = new ComboBox();
         comboBox.addItems("foo", "bar");
@@ -69,12 +69,12 @@ public class ComboBoxDeclarativeTest extends DeclarativeTestBase<ComboBox> {
         testRead(design, comboBox);
 
         // Selects items are not written out by default
-        String design2 = "<v-combo-box readonly></v-combo-box>";
+        String design2 = "<vaadin-combo-box readonly></vaadin-combo-box>";
         testWrite(design2, comboBox);
     }
 
     private String getBasicDesign() {
-        return "<v-combo-box input-prompt=\"Select something\" filtering-mode=\"off\" scroll-to-selected-item='false'>";
+        return "<vaadin-combo-box input-prompt=\"Select something\" filtering-mode=\"off\" scroll-to-selected-item='false'>";
     }
 
     private ComboBox getBasicExpected() {
index 07822953101a5693787f86fd4ae0db868f9d8ea2..31ee1a05f59715982808810036865d50878d16df 100644 (file)
@@ -33,11 +33,11 @@ public class CssLayoutDeclarativeTest extends DeclarativeTestBase<CssLayout> {
 
     @Test
     public void testNoChildren() {
-        String design = "<v-css-layout />";
+        String design = "<vaadin-css-layout />";
         CssLayout layout = new CssLayout();
         testRead(design, layout);
         testWrite(design, layout);
-        design = "<v-css-layout caption=\"A caption\"/>";
+        design = "<vaadin-css-layout caption=\"A caption\"/>";
         layout = new CssLayout();
         layout.setCaption("A caption");
         testRead(design, layout);
@@ -46,8 +46,8 @@ public class CssLayoutDeclarativeTest extends DeclarativeTestBase<CssLayout> {
 
     @Test
     public void testFeatures() {
-        String design = "<v-css-layout caption=test-layout><v-label caption=test-label />"
-                + "<v-button>test-button</v-button></v-css-layout>";
+        String design = "<vaadin-css-layout caption=test-layout><vaadin-label caption=test-label />"
+                + "<vaadin-button>test-button</vaadin-button></vaadin-css-layout>";
         CssLayout layout = new CssLayout();
         layout.setCaption("test-layout");
         Label l = new Label();
index 44261a61dcadca438b2f5c3925fd90f776ce08e4..6ee3490c05b7f481ce38b61773e50bedd276ef8b 100644 (file)
@@ -33,17 +33,17 @@ public class CustomLayoutDeclarativeTest extends
 
     @Test
     public void testEmpty() {
-        String design = "<v-custom-layout>";
+        String design = "<vaadin-custom-layout>";
         CustomLayout expected = new CustomLayout();
         test(design, expected);
     }
 
     @Test
     public void testWithChildren() {
-        String design = "<v-custom-layout>" + //
-                "<v-button plain-text :location='b'></v-button>" + //
-                "<v-label plain-text :location='l'></v-label>" + //
-                "</v-custom-layout>";
+        String design = "<vaadin-custom-layout>" + //
+                "<vaadin-button plain-text :location='b'></vaadin-button>" + //
+                "<vaadin-label plain-text :location='l'></vaadin-label>" + //
+                "</vaadin-custom-layout>";
 
         CustomLayout expected = new CustomLayout();
         expected.addComponent(new Button(), "b");
@@ -54,7 +54,7 @@ public class CustomLayoutDeclarativeTest extends
 
     @Test
     public void testWithOneChild() {
-        String design = "<v-custom-layout><v-button plain-text></v-button></v-custom-layout>";
+        String design = "<vaadin-custom-layout><vaadin-button plain-text></vaadin-button></vaadin-custom-layout>";
 
         CustomLayout expected = new CustomLayout();
         expected.addComponent(new Button());
@@ -64,17 +64,17 @@ public class CustomLayoutDeclarativeTest extends
 
     @Test
     public void testWithTemplate() {
-        String design = "<v-custom-layout template-name='template.html'></v-custom-layout>";
+        String design = "<vaadin-custom-layout template-name='template.html'></vaadin-custom-layout>";
         CustomLayout expected = new CustomLayout("template.html");
         test(design, expected);
     }
 
     @Test
     public void testWithDuplicateLocations() {
-        String design = "<v-custom-layout>" + //
-                "<v-button plain-text :location='foo'></v-button>" + //
-                "<v-label plain-text :location='foo'></v-label>" + //
-                "</v-custom-layout>";
+        String design = "<vaadin-custom-layout>" + //
+                "<vaadin-button plain-text :location='foo'></vaadin-button>" + //
+                "<vaadin-label plain-text :location='foo'></vaadin-label>" + //
+                "</vaadin-custom-layout>";
 
         CustomLayout expected = new CustomLayout();
         expected.addComponent(new Button(), "foo");
@@ -82,9 +82,9 @@ public class CustomLayoutDeclarativeTest extends
 
         testRead(design, expected);
 
-        String written = "<v-custom-layout>" + //
-                "<v-label plain-text :location='foo'></v-label>" + //
-                "</v-custom-layout>";
+        String written = "<vaadin-custom-layout>" + //
+                "<vaadin-label plain-text :location='foo'></vaadin-label>" + //
+                "</vaadin-custom-layout>";
 
         testWrite(written, expected);
     }
index f5ae6871a2bbe1b56860af658ef1ebeaa59b1d87..e245adcba8c72b0d14dd19ad7f9ccd2582a674ef 100644 (file)
@@ -33,7 +33,7 @@ import com.vaadin.ui.DateField;
 public class DateFieldDeclarativeTest extends DeclarativeTestBase<DateField> {
 
     private String getYearResolutionDesign() {
-        return "<v-date-field resolution='year' value='2020'/>";
+        return "<vaadin-date-field resolution='year' value='2020'/>";
     }
 
     private DateField getYearResolutionExpected() {
@@ -44,7 +44,7 @@ public class DateFieldDeclarativeTest extends DeclarativeTestBase<DateField> {
     }
 
     private String getTimezoneDesign() {
-        return "<v-date-field range-start=\"2014-05-05 00:00:00+0300\" range-end=\"2014-06-05 00:00:00+0300\" date-out-of-range-message=\"Please select a sensible date\" date-format=\"yyyy-MM-dd\" lenient='' show-iso-week-numbers='' parse-error-message=\"You are doing it wrong\" time-zone=\"GMT+05:00\" value=\"2014-05-15 00:00:00+0300\"/>";
+        return "<vaadin-date-field range-start=\"2014-05-05 00:00:00+0300\" range-end=\"2014-06-05 00:00:00+0300\" date-out-of-range-message=\"Please select a sensible date\" date-format=\"yyyy-MM-dd\" lenient='' show-iso-week-numbers='' parse-error-message=\"You are doing it wrong\" time-zone=\"GMT+05:00\" value=\"2014-05-15 00:00:00+0300\"/>";
     }
 
     private DateField getTimezoneExpected() {
@@ -90,7 +90,7 @@ public class DateFieldDeclarativeTest extends DeclarativeTestBase<DateField> {
 
     @Test
     public void testReadOnlyValue() {
-        String design = "<v-date-field readonly resolution='year' value='2020-01-01 00:00:00+0200'/>";
+        String design = "<vaadin-date-field readonly resolution='year' value='2020-01-01 00:00:00+0200'/>";
         DateField df = new DateField();
         df.setResolution(Resolution.YEAR);
         df.setValue(new Date(2020 - 1900, 1 - 1, 1));
index 708c800300a0b11dee39040c072f68713446bc73..b637d10c9e0f11fb6f0e95d0530295b46663a472 100644 (file)
@@ -34,7 +34,7 @@ public class PopupDateFieldDeclarativeTest extends
         DeclarativeTestBase<PopupDateField> {
 
     private String getBasicDesign() {
-        return "<v-popup-date-field assistive-text='at' text-field-enabled='false' show-iso-week-numbers resolution=\"MINUTE\" range-end=\"2019-01-15\" input-prompt=\"Pick a day\" value=\"2003-02-27 07:15\"></v-popup-date-field>";
+        return "<vaadin-popup-date-field assistive-text='at' text-field-enabled='false' show-iso-week-numbers resolution=\"MINUTE\" range-end=\"2019-01-15\" input-prompt=\"Pick a day\" value=\"2003-02-27 07:15\"></vaadin-popup-date-field>";
     }
 
     private PopupDateField getBasicExpected() {
index f16184d8b1240ed4073e46d6f94e4b401133c540..0c2deaaf0aac2d2028176c262288d3aaaa625cd6 100644 (file)
@@ -43,10 +43,10 @@ public class FlashDeclarativeTest extends DeclarativeTestBase<Flash> {
     };
 
     protected String getDesign() {
-        return "<v-flash standby='Please wait' archive='arch' codebase='foo' codetype='bar' >"
+        return "<vaadin-flash standby='Please wait' archive='arch' codebase='foo' codetype='bar' >"
                 + "  <parameter name='baz' value='foo' />\n" //
                 + "  <parameter name='foo' value='bar' />\n" //
-                + "</v-flash>"; //
+                + "</vaadin-flash>"; //
     }
 
     @Test
@@ -61,7 +61,7 @@ public class FlashDeclarativeTest extends DeclarativeTestBase<Flash> {
 
     @Test
     public void testEmpty() {
-        testRead("<v-flash />", new Flash());
+        testRead("<vaadin-flash />", new Flash());
     }
 
 }
index aa9a4994698d44476ce17e3bf770dc7c7cf575f5..94d611a98b982d316f9655f03025d4f61588487e 100644 (file)
@@ -23,7 +23,7 @@ public class GridColumnDeclarativeTest extends GridDeclarativeTestBase {
 
     @Test
     public void testSimpleGridColumns() {
-        String design = "<v-grid><table>"//
+        String design = "<vaadin-grid><table>"//
                 + "<colgroup>"
                 + "   <col sortable='' width='100' property-id='Column1'>"
                 + "   <col sortable=false max-width='200' expand='2' property-id='Column2'>"
@@ -32,7 +32,7 @@ public class GridColumnDeclarativeTest extends GridDeclarativeTestBase {
                 + "   <col sortable='' hidden='' property-id='Column5'>"
                 + "</colgroup>" //
                 + "<thead />" //
-                + "</table></v-grid>";
+                + "</table></vaadin-grid>";
         Grid grid = new Grid();
         grid.addColumn("Column1", String.class).setWidth(100);
         grid.addColumn("Column2", String.class).setMaximumWidth(200)
@@ -53,14 +53,14 @@ public class GridColumnDeclarativeTest extends GridDeclarativeTestBase {
 
     @Test
     public void testReadColumnsWithoutPropertyId() {
-        String design = "<v-grid><table>"//
+        String design = "<vaadin-grid><table>"//
                 + "<colgroup>"
                 + "   <col sortable=true width='100' property-id='Column1'>"
                 + "   <col sortable=true max-width='200' expand='2'>" // property-id="property-1"
                 + "   <col sortable=true min-width='15' expand='1' property-id='Column3'>"
                 + "   <col sortable=true hidden=true hidable=true hiding-toggle-caption='col 4'>" // property-id="property-3"
                 + "</colgroup>" //
-                + "</table></v-grid>";
+                + "</table></vaadin-grid>";
         Grid grid = new Grid();
         grid.addColumn("Column1", String.class).setWidth(100);
         grid.addColumn("property-1", String.class).setMaximumWidth(200)
@@ -75,11 +75,11 @@ public class GridColumnDeclarativeTest extends GridDeclarativeTestBase {
 
     @Test
     public void testReadEmptyExpand() {
-        String design = "<v-grid><table>"//
+        String design = "<vaadin-grid><table>"//
                 + "<colgroup>"
                 + "   <col sortable=true expand />"
                 + "</colgroup>" //
-                + "</table></v-grid>";
+                + "</table></vaadin-grid>";
 
         Grid grid = new Grid();
         grid.addColumn("property-0", String.class).setExpandRatio(1);
@@ -89,11 +89,11 @@ public class GridColumnDeclarativeTest extends GridDeclarativeTestBase {
 
     @Test
     public void testReadColumnWithNoAttributes() {
-        String design = "<v-grid><table>"//
+        String design = "<vaadin-grid><table>"//
                 + "<colgroup>" //
                 + "   <col />" //
                 + "</colgroup>" //
-                + "</table></v-grid>";
+                + "</table></vaadin-grid>";
 
         Grid grid = new Grid();
         grid.addColumn("property-0", String.class);
index 43f394eafc6797c9a26b10404dda72c8701bb757..7fa6c24df4cc9fb34408817fd3c202ca94fd595b 100644 (file)
@@ -37,7 +37,7 @@ public class GridDeclarativeAttributeTest extends DeclarativeTestBase<Grid> {
     @Test
     public void testBasicAttributes() {
 
-        String design = "<v-grid editable='' rows=20 frozen-columns=-1 "
+        String design = "<vaadin-grid editable='' rows=20 frozen-columns=-1 "
                 + "editor-save-caption='Tallenna' editor-cancel-caption='Peruuta' column-reordering-allowed=''>";
 
         Grid grid = new Grid();
@@ -55,8 +55,8 @@ public class GridDeclarativeAttributeTest extends DeclarativeTestBase<Grid> {
 
     @Test
     public void testFrozenColumnsAttributes() {
-        String design = "<v-grid frozen-columns='2'><table>" //
-                + "<colgroup><col><col><col></colgroup></table></v-grid>";
+        String design = "<vaadin-grid frozen-columns='2'><table>" //
+                + "<colgroup><col><col><col></colgroup></table></vaadin-grid>";
 
         Grid grid = new Grid();
         grid.addColumn("property-0", String.class);
@@ -69,15 +69,15 @@ public class GridDeclarativeAttributeTest extends DeclarativeTestBase<Grid> {
 
     @Test
     public void testSelectionMode() {
-        String design = "<v-grid selection-mode='none'>";
+        String design = "<vaadin-grid selection-mode='none'>";
         assertSame(NoSelectionModel.class, read(design).getSelectionModel()
                 .getClass());
 
-        design = "<v-grid selection-mode='single'>";
+        design = "<vaadin-grid selection-mode='single'>";
         assertSame(SingleSelectionModel.class, read(design).getSelectionModel()
                 .getClass());
 
-        design = "<v-grid selection-mode='multi'>";
+        design = "<vaadin-grid selection-mode='multi'>";
         assertSame(MultiSelectionModel.class, read(design).getSelectionModel()
                 .getClass());
     }
index 630c81fb3023a2ab5f32db728e9e393b7edcaf64..98ebe677521d0186ff389f1ea24e63afa3d82b3a 100644 (file)
@@ -33,7 +33,7 @@ public class GridHeaderFooterDeclarativeTest extends GridDeclarativeTestBase {
     @Test
     public void testSingleDefaultHeader() {
         //@formatter:off
-        String design = "<v-grid><table>"
+        String design = "<vaadin-grid><table>"
                 + "<colgroup>"
                 + "   <col sortable='' property-id='Column1'>"
                 + "   <col sortable='' property-id='Column2'>"
@@ -45,7 +45,7 @@ public class GridHeaderFooterDeclarativeTest extends GridDeclarativeTestBase {
                 + "     <th plain-text=''>Column2</th>"
                 + "     <th plain-text=''>Column3</tr>"
                 + "</thead>"
-                + "</table></v-grid>";
+                + "</table></vaadin-grid>";
         //@formatter:on
         Grid grid = new Grid();
         grid.addColumn("Column1", String.class);
@@ -59,7 +59,7 @@ public class GridHeaderFooterDeclarativeTest extends GridDeclarativeTestBase {
     @Test
     public void testSingleDefaultHTMLHeader() {
         //@formatter:off
-        String design = "<v-grid><table>"
+        String design = "<vaadin-grid><table>"
                 + "<colgroup>"
                 + "   <col sortable='' property-id='Column1'>"
                 + "   <col sortable='' property-id='Column2'>"
@@ -68,7 +68,7 @@ public class GridHeaderFooterDeclarativeTest extends GridDeclarativeTestBase {
                 + "<thead>"
                 + "   <tr default=''><th>Column1<th>Column2<th>Column3</tr>"
                 + "</thead>"
-                + "</table></v-grid>";
+                + "</table></vaadin-grid>";
         //@formatter:on
         Grid grid = new Grid();
         grid.addColumn("Column1", String.class);
@@ -87,13 +87,14 @@ public class GridHeaderFooterDeclarativeTest extends GridDeclarativeTestBase {
     @Test
     public void testNoHeaderRows() {
         //@formatter:off
-        String design = "<v-grid><table>"
+        String design = "<vaadin-grid><table>"
                 + "<colgroup>"
                 + "   <col sortable='' property-id='Column1'>"
                 + "</colgroup>" 
                 + "<thead />" 
-                + "</table></v-grid>";
+                + "</table></vaadin-grid>";
         //@formatter:on
+
         Grid grid = new Grid();
         grid.addColumn("Column1", String.class);
         grid.removeHeaderRow(grid.getDefaultHeaderRow());
@@ -105,7 +106,7 @@ public class GridHeaderFooterDeclarativeTest extends GridDeclarativeTestBase {
     @Test
     public void testMultipleHeadersWithColSpans() {
         //@formatter:off
-        String design = "<v-grid><table>"
+        String design = "<vaadin-grid><table>"
                 + "<colgroup>"
                 + "   <col sortable='' property-id='Column1'>"
                 + "   <col sortable='' property-id='Column2'>"
@@ -116,8 +117,9 @@ public class GridHeaderFooterDeclarativeTest extends GridDeclarativeTestBase {
                 + "   <tr default=''><th>Column1<th>Column2<th>Column3</tr>" 
                 + "   <tr><th>Foo<th colspan=2>Bar</tr>" 
                 + "</thead>" 
-                + "</table></v-grid>";
+                + "</table></vaadin-grid>";
         //@formatter:on
+
         Grid grid = new Grid();
         grid.addColumn("Column1", String.class);
         grid.addColumn("Column2", String.class);
@@ -141,7 +143,7 @@ public class GridHeaderFooterDeclarativeTest extends GridDeclarativeTestBase {
     @Test
     public void testSingleDefaultFooter() {
         //@formatter:off
-        String design = "<v-grid><table>"
+        String design = "<vaadin-grid><table>"
                 + "<colgroup>"
                 + "   <col sortable='' property-id='Column1'>"
                 + "   <col sortable='' property-id='Column2'>"
@@ -151,8 +153,9 @@ public class GridHeaderFooterDeclarativeTest extends GridDeclarativeTestBase {
                 + "<tfoot>" 
                 + "   <tr><td plain-text=''>Column1<td plain-text=''>Column2<td plain-text=''>Column3</tr>" 
                 + "</tfoot>" 
-                + "</table></v-grid>";
+                + "</table></vaadin-grid>";
         //@formatter:on
+
         Grid grid = new Grid();
         grid.addColumn("Column1", String.class);
         grid.addColumn("Column2", String.class);
@@ -172,7 +175,7 @@ public class GridHeaderFooterDeclarativeTest extends GridDeclarativeTestBase {
     @Test
     public void testSingleDefaultHTMLFooter() {
         //@formatter:off
-        String design = "<v-grid><table>"
+        String design = "<vaadin-grid><table>"
                 + "<colgroup>"
                 + "   <col sortable='' property-id='Column1'>"
                 + "   <col sortable='' property-id='Column2'>"
@@ -182,8 +185,9 @@ public class GridHeaderFooterDeclarativeTest extends GridDeclarativeTestBase {
                 + "<tfoot>" 
                 + "   <tr><td>Column1<td>Column2<td>Column3</tr>" 
                 + "</tfoot>" 
-                + "</table></v-grid>";
+                + "</table></vaadin-grid>";
         //@formatter:on
+
         Grid grid = new Grid();
         grid.addColumn("Column1", String.class);
         grid.addColumn("Column2", String.class);
@@ -203,7 +207,7 @@ public class GridHeaderFooterDeclarativeTest extends GridDeclarativeTestBase {
     @Test
     public void testMultipleFootersWithColSpans() {
         //@formatter:off
-        String design = "<v-grid><table>"
+        String design = "<vaadin-grid><table>"
                 + "<colgroup>"
                 + "   <col sortable='' property-id='Column1'>"
                 + "   <col sortable='' property-id='Column2'>"
@@ -215,8 +219,9 @@ public class GridHeaderFooterDeclarativeTest extends GridDeclarativeTestBase {
                 + "   <tr><td>Column1<td>Column2<td>Column3</tr>" 
                 + "   <tr><td>Foo<td colspan=2>Bar</tr>" 
                 + "</tfoot>" 
-                + "</table></v-grid>";
+                + "</table></vaadin-grid>";
         //@formatter:on
+
         Grid grid = new Grid();
         grid.addColumn("Column1", String.class);
         grid.addColumn("Column2", String.class);
@@ -242,15 +247,16 @@ public class GridHeaderFooterDeclarativeTest extends GridDeclarativeTestBase {
     @Test
     public void testComponentInGridHeader() {
         //@formatter:off
-        String design = "<v-grid><table>"
+        String design = "<vaadin-grid><table>"
                 + "<colgroup>"
                 + "   <col sortable='' property-id='Column1'>"
                 + "</colgroup>" 
                 + "<thead>" 
-                + "<tr default=''><th><v-label><b>Foo</b></v-label></tr>"
+                + "<tr default=''><th><vaadin-label><b>Foo</b></vaadin-label></tr>"
                 + "</thead>"
-                + "</table></v-grid>";
+                + "</table></vaadin-grid>";
       //@formatter:on
+
         Label component = new Label("<b>Foo</b>");
         component.setContentMode(ContentMode.HTML);
 
@@ -265,16 +271,17 @@ public class GridHeaderFooterDeclarativeTest extends GridDeclarativeTestBase {
     @Test
     public void testComponentInGridFooter() {
         //@formatter:off
-        String design = "<v-grid><table>"
+        String design = "<vaadin-grid><table>"
                 + "<colgroup>"
                 + "   <col sortable='' property-id='Column1'>"
                 + "</colgroup>" 
                 + "<thead />" // No headers read or written
                 + "<tfoot>" 
-                + "<tr><td><v-label><b>Foo</b></v-label></tr>"
+                + "<tr><td><vaadin-label><b>Foo</b></vaadin-label></tr>"
                 + "</tfoot>" 
-                + "</table></v-grid>";
+                + "</table></vaadin-grid>";
         //@formatter:on
+
         Label component = new Label("<b>Foo</b>");
         component.setContentMode(ContentMode.HTML);
 
@@ -289,15 +296,21 @@ public class GridHeaderFooterDeclarativeTest extends GridDeclarativeTestBase {
 
     @Test
     public void testHtmlEntitiesinGridHeaderFooter() {
-        // @formatter off
-        String design = "<v-grid><table>" + "<colgroup>"
+        //@formatter:off
+        String design = "<vaadin-grid><table>"
+                + "<colgroup>"
                 + "  <col sortable=\"true\" property-id=\"> test\">"
-                + "</colgroup>" + "<thead>"
+                + "</colgroup>"
+                + "<thead>"
                 + "  <tr><th plain-text=\"true\">&gt; Test</th></tr>"
-                + "</thead>" + "<tfoot>"
+                + "</thead>"
+                + "<tfoot>"
                 + "  <tr><td plain-text=\"true\">&gt; Test</td></tr>"
-                + "</tfoot>" + "<tbody />" + "</table></v-grid>";
-        // @formatter off
+                + "</tfoot>"
+                + "<tbody />"
+                + "</table></vaadin-grid>";
+        //@formatter:on
+
         Grid grid = read(design);
         String actualHeader = grid.getHeaderRow(0).getCell("> test").getText();
         String actualFooter = grid.getFooterRow(0).getCell("> test").getText();
@@ -325,7 +338,7 @@ public class GridHeaderFooterDeclarativeTest extends GridDeclarativeTestBase {
         header.getCell("test").setText("&amp; Test");
         footer.getCell("test").setText("&amp; Test");
 
-        Element root = new Element(Tag.valueOf("v-grid"), "");
+        Element root = new Element(Tag.valueOf("vaadin-grid"), "");
         grid.writeDesign(root, new DesignContext());
 
         Assert.assertEquals("&amp;amp; Test", root.getElementsByTag("th")
@@ -340,7 +353,7 @@ public class GridHeaderFooterDeclarativeTest extends GridDeclarativeTestBase {
         header.getCell("test").setHtml("&amp; Test");
         footer.getCell("test").setHtml("&amp; Test");
 
-        root = new Element(Tag.valueOf("v-grid"), "");
+        root = new Element(Tag.valueOf("vaadin-grid"), "");
         grid.writeDesign(root, new DesignContext());
 
         Assert.assertEquals("&amp; Test", root.getElementsByTag("th").get(0)
index 04f92b0190701ca2745eea96e6c4b8fd5e80ec27..b4cb33560e84d5952bffa75c2ca4fbecfa64f4d7 100644 (file)
@@ -25,7 +25,7 @@ public class GridInlineDataDeclarativeTest extends GridDeclarativeTestBase {
 
     @Test
     public void testSimpleInlineData() {
-        String design = "<v-grid><table>"//
+        String design = "<vaadin-grid><table>"//
                 + "<colgroup>"
                 + "   <col sortable='' property-id='Col1' />"
                 + "</colgroup>" //
@@ -34,8 +34,8 @@ public class GridInlineDataDeclarativeTest extends GridDeclarativeTestBase {
                 + "<tr><td>Foo</tr>" //
                 + "<tr><td>Bar</tr>" //
                 + "<tr><td>Baz</tr>" //
-                + "</tbody>"
-                + "</table></v-grid>";
+                + "</tbody>" //
+                + "</table></vaadin-grid>";
 
         Grid grid = new Grid();
         grid.addColumn("Col1", String.class);
@@ -52,7 +52,7 @@ public class GridInlineDataDeclarativeTest extends GridDeclarativeTestBase {
 
     @Test
     public void testMultipleColumnsInlineData() {
-        String design = "<v-grid><table>"//
+        String design = "<vaadin-grid><table>"//
                 + "<colgroup>"
                 + "   <col sortable='' property-id='Col1' />"
                 + "   <col sortable='' property-id='Col2' />"
@@ -62,8 +62,8 @@ public class GridInlineDataDeclarativeTest extends GridDeclarativeTestBase {
                 + "<tbody>" //
                 + "<tr><td>Foo<td>Bar<td>Baz</tr>" //
                 + "<tr><td>My<td>Summer<td>Car</tr>" //
-                + "</tbody>"
-                + "</table></v-grid>";
+                + "</tbody>" //
+                + "</table></vaadin-grid>";
 
         Grid grid = new Grid();
         grid.addColumn("Col1", String.class);
@@ -81,7 +81,7 @@ public class GridInlineDataDeclarativeTest extends GridDeclarativeTestBase {
 
     @Test
     public void testMultipleColumnsInlineDataReordered() {
-        String design = "<v-grid><table>"//
+        String design = "<vaadin-grid><table>"//
                 + "<colgroup>"
                 + "   <col sortable='' property-id='Col2' />"
                 + "   <col sortable='' property-id='Col3' />"
@@ -91,8 +91,8 @@ public class GridInlineDataDeclarativeTest extends GridDeclarativeTestBase {
                 + "<tbody>" //
                 + "<tr><td>Bar<td>Baz<td>Foo</tr>" //
                 + "<tr><td>Summer<td>Car<td>My</tr>" //
-                + "</tbody>"
-                + "</table></v-grid>";
+                + "</tbody>" //
+                + "</table></vaadin-grid>";
 
         Grid grid = new Grid();
         grid.addColumn("Col1", String.class);
@@ -108,19 +108,19 @@ public class GridInlineDataDeclarativeTest extends GridDeclarativeTestBase {
         testWrite(design, grid, true);
         testRead(design, grid, true, true);
     }
-    
+
     @Test
     public void testHtmlEntities() {
-        String design = "<v-grid><table>"//
+        String design = "<vaadin-grid><table>"//
                 + "<colgroup>"
                 + "   <col property-id='test' />"
                 + "</colgroup>" //
                 + "<thead />" // No headers read or written
-                + "<tbody>"
+                + "<tbody>" //
                 + "  <tr><td>&amp;Test</tr></td>"
                 + "</tbody>"
-                + "</table></v-grid>";
-        
+                + "</table></vaadin-grid>";
+
         Grid read = read(design);
         Container cds = read.getContainerDataSource();
         Assert.assertEquals("&amp;Test",
index dc74f46d4d57b801a08a5bc995b75ff1f5c44b57..d60df4c23beb14ba9a51a7f0662cf25176bd6bb2 100644 (file)
@@ -24,13 +24,13 @@ public class GridStructureDeclarativeTest extends GridDeclarativeTestBase {
 
     @Test
     public void testReadEmptyGrid() {
-        String design = "<v-grid />";
+        String design = "<vaadin-grid />";
         testRead(design, new Grid(), false);
     }
 
     @Test
     public void testEmptyGrid() {
-        String design = "<v-grid></v-grid>";
+        String design = "<vaadin-grid></vaadin-grid>";
         Grid expected = new Grid();
         testWrite(design, expected);
         testRead(design, expected, true);
@@ -38,13 +38,13 @@ public class GridStructureDeclarativeTest extends GridDeclarativeTestBase {
 
     @Test(expected = DesignException.class)
     public void testMalformedGrid() {
-        String design = "<v-grid><v-label /></v-grid>";
+        String design = "<vaadin-grid><vaadin-label /></vaadin-grid>";
         testRead(design, new Grid());
     }
 
     @Test(expected = DesignException.class)
     public void testGridWithNoColGroup() {
-        String design = "<v-grid><table><thead><tr><th>Foo</tr></thead></table></v-grid>";
+        String design = "<vaadin-grid><table><thead><tr><th>Foo</tr></thead></table></vaadin-grid>";
         testRead(design, new Grid());
     }
 }
index fe2d1c4a2381b0ee65ecb2bf0b8b2443df567aed..4e217da477e48c76ee65b3e3e099e9df237a01a3 100644 (file)
@@ -34,7 +34,7 @@ public class GridLayoutDeclarativeTest extends
 
     @Test
     public void testMargins() {
-        testMargins("v-grid-layout");
+        testMargins("vaadin-grid-layout");
     }
 
     @Test
@@ -47,13 +47,13 @@ public class GridLayoutDeclarativeTest extends
         b2.setCaptionAsHtml(true);
         b3.setCaptionAsHtml(true);
         b4.setCaptionAsHtml(true);
-        String design = "<v-grid-layout><row>" //
+        String design = "<vaadin-grid-layout><row>" //
                 + "<column expand=1>" + writeChild(b1) + "</column>" //
                 + "<column expand=3>" + writeChild(b2) + "</column>" //
                 + "</row><row>" //
                 + "<column>" + writeChild(b3) + "</column>" //
                 + "<column>" + writeChild(b4) + "</column>" //
-                + "</row></v-grid-layout>";
+                + "</row></vaadin-grid-layout>";
         GridLayout gl = new GridLayout(2, 2);
         gl.addComponent(b1);
         gl.addComponent(b2);
@@ -69,10 +69,10 @@ public class GridLayoutDeclarativeTest extends
     public void testOneBigComponentGridLayout() {
         Button b1 = new Button("Button 0,0 -> 1,1");
         b1.setCaptionAsHtml(true);
-        String design = "<v-grid-layout><row>" //
+        String design = "<vaadin-grid-layout><row>" //
                 + "<column colspan=2 rowspan=2>" + writeChild(b1) + "</column>" //
                 + "</row><row expand=2>" //
-                + "</row></v-grid-layout>";
+                + "</row></vaadin-grid-layout>";
         GridLayout gl = new GridLayout(2, 2);
         gl.addComponent(b1, 0, 0, 1, 1);
         gl.setRowExpandRatio(1, 2);
@@ -121,7 +121,7 @@ public class GridLayoutDeclarativeTest extends
         // 4 4 - 2 6
         // - - 7 7 6
 
-        String design = "<v-grid-layout><row>" //
+        String design = "<vaadin-grid-layout><row>" //
                 + "<column colspan=3>" + writeChild(b1) + "</column>" //
                 + "<column rowspan=4>" + writeChild(b2) + "</column>" //
                 + "<column rowspan=2>" + writeChild(b3) + "</column>" //
@@ -135,7 +135,7 @@ public class GridLayoutDeclarativeTest extends
                 + "</row><row>" //
                 + "<column colspan=2 />" // Empty placeholder
                 + "<column colspan=2>" + writeChild(b7) + "</column>" //
-                + "</row></v-grid-layout>";
+                + "</row></vaadin-grid-layout>";
         testWrite(design, gl);
         testRead(design, gl);
     }
@@ -148,14 +148,14 @@ public class GridLayoutDeclarativeTest extends
         gl.addComponent(b1, 4, 0, 4, 4);
         gl.setColumnExpandRatio(2, 2.0f);
 
-        String design = "<v-grid-layout><row>" //
+        String design = "<vaadin-grid-layout><row>" //
                 + "<column colspan=4 rowspan=5 expand='0,0,2,0' />" //
                 + "<column rowspan=5>" + writeChild(b1) + "</column>" //
                 + "</row><row>" //
                 + "</row><row>" //
                 + "</row><row>" //
                 + "</row><row>" //
-                + "</row></v-grid-layout>";
+                + "</row></vaadin-grid-layout>";
         testWrite(design, gl);
         testRead(design, gl);
     }
@@ -168,14 +168,14 @@ public class GridLayoutDeclarativeTest extends
         gl.addComponent(b1, 0, 0, 0, 4);
         gl.setColumnExpandRatio(4, 2.0f);
 
-        String design = "<v-grid-layout><row>" //
+        String design = "<vaadin-grid-layout><row>" //
                 + "<column rowspan=5>" + writeChild(b1) + "</column>" //
                 + "<column colspan=4 rowspan=5 expand='0,0,0,2' />" //
                 + "</row><row>" //
                 + "</row><row>" //
                 + "</row><row>" //
                 + "</row><row>" //
-                + "</row></v-grid-layout>";
+                + "</row></vaadin-grid-layout>";
         testWrite(design, gl);
         testRead(design, gl);
     }
@@ -183,7 +183,7 @@ public class GridLayoutDeclarativeTest extends
     @Test
     public void testEmptyGridLayout() {
         GridLayout gl = new GridLayout();
-        String design = "<v-grid-layout />";
+        String design = "<vaadin-grid-layout />";
         testWrite(design, gl);
         testRead(design, gl);
     }
@@ -214,21 +214,21 @@ public class GridLayoutDeclarativeTest extends
         String design = "<!DOCTYPE html>" + //
                 "<html>" + //
                 " <body> " + //
-                "  <v-grid-layout> " + //
+                "  <vaadin-grid-layout> " + //
                 "   <row> " + //
                 "    <column> " + //
-                "     <v-grid-layout> " + //
+                "     <vaadin-grid-layout> " + //
                 "      <row> " + //
                 "       <column> " + //
-                "        <v-button>" + //
+                "        <vaadin-button>" + //
                 "          Button " + //
-                "        </v-button> " + //
+                "        </vaadin-button> " + //
                 "       </column> " + //
                 "      </row> " + //
-                "     </v-grid-layout> " + //
+                "     </vaadin-grid-layout> " + //
                 "    </column> " + //
                 "   </row> " + //
-                "  </v-grid-layout>  " + //
+                "  </vaadin-grid-layout>  " + //
                 " </body>" + //
                 "</html>";
         GridLayout outer = new GridLayout();
index 670b3beb3d1da065b405d083a2fb5bdd0349a761..562c629209aef4e54009c10d361b85e168988ac3 100644 (file)
@@ -30,7 +30,7 @@ import com.vaadin.ui.Image;
 public class ImageDeclarativeTest extends DeclarativeTestBase<Image> {
 
     protected String getDesign() {
-        return "<v-image source='http://foo.bar/img.png' alt='Some random image from the theme'></v-image>";
+        return "<vaadin-image source='http://foo.bar/img.png' alt='Some random image from the theme'></vaadin-image>";
     }
 
     protected Image getExpectedResult() {
@@ -52,7 +52,7 @@ public class ImageDeclarativeTest extends DeclarativeTestBase<Image> {
 
     @Test
     public void testEmpty() {
-        testRead("<v-image />", new Image());
+        testRead("<vaadin-image />", new Image());
     }
 
 }
index 6749776397a004789e4f061ff8b6e5eeea55d7f9..f911aab77903184be3db75c90d8f9853defe38e2 100644 (file)
@@ -36,7 +36,7 @@ public class LabelDeclarativeTest extends DeclarativeTestBase<Label> {
 
     @Test
     public void testEmpty() {
-        String design = "<v-label />";
+        String design = "<vaadin-label />";
         Label l = new Label();
         l.setContentMode(ContentMode.HTML);
         testRead(design, l);
@@ -45,7 +45,7 @@ public class LabelDeclarativeTest extends DeclarativeTestBase<Label> {
 
     @Test
     public void testDefault() {
-        String design = "<v-label>Hello world!</v-label>";
+        String design = "<vaadin-label>Hello world!</vaadin-label>";
         Label l = createLabel("Hello world!", null, true);
         testRead(design, l);
         testWrite(design, l);
@@ -53,7 +53,7 @@ public class LabelDeclarativeTest extends DeclarativeTestBase<Label> {
 
     @Test
     public void testRich() {
-        String design = "<v-label>This is <b><u>Rich</u></b> content!</v-label>";
+        String design = "<vaadin-label>This is <b><u>Rich</u></b> content!</vaadin-label>";
         Label l = createLabel("This is \n<b><u>Rich</u></b> content!", null,
                 true);
         testRead(design, l);
@@ -62,8 +62,8 @@ public class LabelDeclarativeTest extends DeclarativeTestBase<Label> {
 
     @Test
     public void testPlainText() {
-        String design = "<v-label plain-text>This is only &lt;b&gt;text&lt;/b&gt;"
-                + " and will contain visible tags</v-label>";
+        String design = "<vaadin-label plain-text>This is only &lt;b&gt;text&lt;/b&gt;"
+                + " and will contain visible tags</vaadin-label>";
         Label l = createLabel(
                 "This is only <b>text</b> and will contain visible tags", null,
                 false);
@@ -73,8 +73,8 @@ public class LabelDeclarativeTest extends DeclarativeTestBase<Label> {
 
     @Test
     public void testContentAndCaption() {
-        String design = "<v-label caption='This is a label'>This is <b><u>Rich</u></b> "
-                + "content!</v-label>";
+        String design = "<vaadin-label caption='This is a label'>This is <b><u>Rich</u></b> "
+                + "content!</vaadin-label>";
         Label l = createLabel("This is \n<b><u>Rich</u></b> content!",
                 "This is a label", true);
         testRead(design, l);
@@ -83,7 +83,7 @@ public class LabelDeclarativeTest extends DeclarativeTestBase<Label> {
 
     @Test
     public void testCaption() {
-        String design = "<v-label caption='This is a label' />";
+        String design = "<vaadin-label caption='This is a label' />";
         Label l = createLabel(null, "This is a label", true);
         testRead(design, l);
         testWrite(design, l);
@@ -91,7 +91,7 @@ public class LabelDeclarativeTest extends DeclarativeTestBase<Label> {
 
     @Test
     public void testHtmlEntities() {
-        String design = "<v-label plain-text=\"true\">&gt; Test</v-label>";
+        String design = "<vaadin-label plain-text=\"true\">&gt; Test</vaadin-label>";
         Label read = read(design);
         Assert.assertEquals("> Test", read.getValue());
 
@@ -102,12 +102,12 @@ public class LabelDeclarativeTest extends DeclarativeTestBase<Label> {
         Label label = new Label("&amp; Test");
         label.setContentMode(ContentMode.TEXT);
 
-        Element root = new Element(Tag.valueOf("v-label"), "");
+        Element root = new Element(Tag.valueOf("vaadin-label"), "");
         label.writeDesign(root, new DesignContext());
         Assert.assertEquals("&amp;amp; Test", root.html());
 
         label.setContentMode(ContentMode.HTML);
-        root = new Element(Tag.valueOf("v-label"), "");
+        root = new Element(Tag.valueOf("vaadin-label"), "");
         label.writeDesign(root, new DesignContext());
         Assert.assertEquals("&amp; Test", root.html());
     }
index 17fea291683a55e7287811c2e102d3a0152dcd14..da7227224da77b0935ad36743f5b4e7001ae64ac 100644 (file)
@@ -29,7 +29,7 @@ import com.vaadin.ui.Link;
  */
 public class LinkDeclarativeTest extends DeclarativeTestBase<Link> {
     private String getBasicDesign() {
-        return "<v-link href='http://vaadin.com' target='vaadin-window' target-height=500"
+        return "<vaadin-link href='http://vaadin.com' target='vaadin-window' target-height=500"
                 + " target-width=800 target-border='none' />";
     }
 
@@ -55,12 +55,12 @@ public class LinkDeclarativeTest extends DeclarativeTestBase<Link> {
 
     @Test
     public void testReadEmpty() {
-        testRead("<v-link />", new Link());
+        testRead("<vaadin-link />", new Link());
     }
 
     @Test
     public void testWriteEmpty() {
-        testWrite("<v-link />", new Link());
+        testWrite("<vaadin-link />", new Link());
     }
 
 }
\ No newline at end of file
index fcff6cd4a5f08cddbff307b31d9b7554a39e5dcc..d0fa400d31fdc0d779492caf55975b62bc7f44fa 100644 (file)
@@ -31,8 +31,8 @@ public class ListSelectDeclarativeTest extends DeclarativeTestBase<ListSelect> {
     }
 
     private String getWithOptionsDesign() {
-        return "<v-list-select rows=10>\n" + "        <option>Male</option>\n"
-                + "        <option>Female</option>\n" + "</v-list-select>\n"
+        return "<vaadin-list-select rows=10>\n" + "        <option>Male</option>\n"
+                + "        <option>Female</option>\n" + "</vaadin-list-select>\n"
                 + "";
     }
 
@@ -54,7 +54,7 @@ public class ListSelectDeclarativeTest extends DeclarativeTestBase<ListSelect> {
     }
 
     private String getBasicDesign() {
-        return "<v-list-select caption='Hello' />";
+        return "<vaadin-list-select caption='Hello' />";
     }
 
     @Test
index 140335e1363d6f94bfe9e8db8b41fc8d8c995ad7..511f411a93bcf48554a5874a9bc23fbcd4629ba9 100644 (file)
@@ -29,7 +29,7 @@ public class NativeSelectDeclarativeTest extends
         DeclarativeTestBase<NativeSelect> {
 
     public String getBasicDesign() {
-        return "<v-native-select><option>foo</option><option>bar</option></v-native-select>";
+        return "<vaadin-native-select><option>foo</option><option>bar</option></vaadin-native-select>";
 
     }
 
@@ -52,7 +52,7 @@ public class NativeSelectDeclarativeTest extends
 
     @Test
     public void testReadOnlyValue() {
-        String design = "<v-native-select readonly><option selected>foo</option><option>bar</option></v-native-select>";
+        String design = "<vaadin-native-select readonly><option selected>foo</option><option>bar</option></vaadin-native-select>";
 
         NativeSelect ns = new NativeSelect();
         ns.addItems("foo", "bar");
@@ -62,8 +62,8 @@ public class NativeSelectDeclarativeTest extends
         testRead(design, ns);
 
         // Selects items are not written out by default
-        String design2 = "<v-native-select readonly></v-native-select>";
+        String design2 = "<vaadin-native-select readonly></vaadin-native-select>";
         testWrite(design2, ns);
     }
 
-}
\ No newline at end of file
+}
index 103d427df9a8ed4c372411028ae09e7b5899e783..39191f066585e1df5380c8a151855ba94d94905e 100644 (file)
@@ -32,10 +32,10 @@ public class PanelDeclarativeTest extends DeclarativeTestBase<Panel> {
 
     @Test
     public void testFeatures() {
-        String design = "<v-panel id=panelId caption=\"A panel\" tabindex=2 scroll-left=10 "
+        String design = "<vaadin-panel id=panelId caption=\"A panel\" tabindex=2 scroll-left=10 "
                 + "scroll-top=20 width=200px height=150px> "
-                + "<v-vertical-layout width=300px height=400px /> "
-                + "</v-panel>";
+                + "<vaadin-vertical-layout width=300px height=400px /> "
+                + "</vaadin-panel>";
         Panel p = new Panel();
         p.setId("panelId");
         p.setCaption("A panel");
@@ -56,7 +56,7 @@ public class PanelDeclarativeTest extends DeclarativeTestBase<Panel> {
     public void testWithMoreThanOneChild() {
         // Check that attempting to have two components in a panel causes a
         // DesignException.
-        String design = "<v-panel> <v-vertical-layout/> <v-horizontal-layout/> </v-panel>";
+        String design = "<vaadin-panel> <vaadin-vertical-layout/> <vaadin-horizontal-layout/> </vaadin-panel>";
         testRead(design, null);
     }
 }
index 6934d2011cba485b9c29744e272d1fde5847d78e..5936f033819dea851b720515a944b5bacf2f1ed7 100644 (file)
@@ -30,7 +30,7 @@ public class PasswordFieldDeclarativeTest extends
 
     @Test
     public void testReadOnlyValue() {
-        String design = "<v-password-field readonly=\"\" value=\"test value\"/>";
+        String design = "<vaadin-password-field readonly=\"\" value=\"test value\"/>";
         PasswordField tf = new PasswordField();
         tf.setValue("test value");
         tf.setReadOnly(true);
index 1b50a517ae69ecca40467f1384114862ac7628ea..649c38a1915b639bba33bb04e4d23d0a8bcaf089 100644 (file)
@@ -30,9 +30,9 @@ public class PopupViewDeclarativeTest extends DeclarativeTestBase<PopupView> {
     public void testEmptyPopupView() {
         PopupView component = new PopupView();
         Component popup = component.getContent().getPopupComponent();
-        String design = "<v-popup-view><popup-content>"
+        String design = "<vaadin-popup-view><popup-content>"
                 + new DesignContext().createElement(popup)
-                + "</popup-content></v-popup-view>";
+                + "</popup-content></vaadin-popup-view>";
         testWrite(design, component);
         testRead(design, component);
     }
@@ -48,12 +48,12 @@ public class PopupViewDeclarativeTest extends DeclarativeTestBase<PopupView> {
         component.setHideOnMouseOut(true);
         component.setPopupVisible(true);
         // hide-on-mouse-out is true by default. not seen in design
-        String design = "<v-popup-view popup-visible=''>" //
+        String design = "<vaadin-popup-view popup-visible=''>" //
                 + "Click <u>here</u> to open"
                 + "<popup-content>"
                 + new DesignContext().createElement(verticalLayout)
                 + "</popup-content>" //
-                + "</v-popup-view>";
+                + "</vaadin-popup-view>";
         testWrite(design, component);
         testRead(design, component);
     }
@@ -63,11 +63,11 @@ public class PopupViewDeclarativeTest extends DeclarativeTestBase<PopupView> {
         final Label label = new Label("Foo");
         PopupView component = new PopupView("Click Me!", label);
         component.setHideOnMouseOut(false);
-        String design = "<v-popup-view hide-on-mouse-out='false'>" //
+        String design = "<vaadin-popup-view hide-on-mouse-out='false'>" //
                 + "Click Me!"
                 + "<popup-content>"
                 + new DesignContext().createElement(label) + "</popup-content>" //
-                + "</v-popup-view>";
+                + "</vaadin-popup-view>";
         testWrite(design, component);
         testRead(design, component);
     }
index 82b8acd8ab25d0ea0218d4059c131742fc4b486b..64a97edf1d7b4015789776d8b0898b719dcb69ab 100644 (file)
@@ -29,7 +29,7 @@ public class ProgressBarDeclarativeTest extends
         DeclarativeTestBase<ProgressBar> {
 
     public String getBasicDesign() {
-        return "<v-progress-bar value=0.5 indeterminate=''>";
+        return "<vaadin-progress-bar value=0.5 indeterminate=''>";
 
     }
 
@@ -52,17 +52,17 @@ public class ProgressBarDeclarativeTest extends
 
     @Test
     public void testReadEmpty() {
-        testRead("<v-progress-bar>", new ProgressBar());
+        testRead("<vaadin-progress-bar>", new ProgressBar());
     }
 
     @Test
     public void testWriteEmpty() {
-        testWrite("<v-progress-bar>", new ProgressBar());
+        testWrite("<vaadin-progress-bar>", new ProgressBar());
     }
 
     @Test
     public void testReadOnlyValue() {
-        String design = "<v-progress-bar readonly value=0.5 indeterminate=''>";
+        String design = "<vaadin-progress-bar readonly value=0.5 indeterminate=''>";
         ProgressBar progressBar = new ProgressBar();
         progressBar.setIndeterminate(true);
         progressBar.setValue(0.5f);
@@ -72,4 +72,4 @@ public class ProgressBarDeclarativeTest extends
         testWrite(design, progressBar);
     }
 
-}
\ No newline at end of file
+}
index 315a5be6b6b9ef77d526822a18ecff453fbce211..4ec75119007a65ae7f261d2eeb48d9f68a63996a 100644 (file)
@@ -24,9 +24,9 @@ public class RichTextAreaDeclarativeTest extends
         DeclarativeTestBase<RichTextArea> {
 
     private String getBasicDesign() {
-        return "<v-rich-text-area null-representation='' null-setting-allowed=''>\n"
+        return "<vaadin-rich-text-area null-representation='' null-setting-allowed=''>\n"
                 + "\n      <b>Header</b> <br/>Some text\n      "
-                + "</v-rich-text-area>";
+                + "</vaadin-rich-text-area>";
     }
 
     private RichTextArea getBasicExpected() {
@@ -49,17 +49,17 @@ public class RichTextAreaDeclarativeTest extends
 
     @Test
     public void testReadEmpty() {
-        testRead("<v-rich-text-area />", new RichTextArea());
+        testRead("<vaadin-rich-text-area />", new RichTextArea());
     }
 
     @Test
     public void testWriteEmpty() {
-        testWrite("<v-rich-text-area />", new RichTextArea());
+        testWrite("<vaadin-rich-text-area />", new RichTextArea());
     }
 
     @Test
     public void testReadOnlyValue() {
-        String design = "<v-rich-text-area readonly style-name='v-richtextarea-readonly'>Hello World!</v-text-area>";
+        String design = "<vaadin-rich-text-area readonly style-name='v-richtextarea-readonly'>Hello World!</vaadin-text-area>";
         RichTextArea ta = new RichTextArea();
         ta.setValue("Hello World!");
         ta.setReadOnly(true);
index 0c2ac6bed9b5cf794a0a31f3db338e24b56a4ac9..dcfb41581027eb4ee2d6bf9832f6f0824b7f3786 100644 (file)
@@ -31,7 +31,7 @@ public class SliderDeclarativeTest extends DeclarativeTestBase<Slider> {
 
     @Test
     public void testDefault() {
-        String design = "<v-slider>";
+        String design = "<vaadin-slider>";
 
         Slider expected = new Slider();
 
@@ -41,7 +41,7 @@ public class SliderDeclarativeTest extends DeclarativeTestBase<Slider> {
 
     @Test
     public void testHorizontal() {
-        String design = "<v-slider min=10 max=20 resolution=1 value=12.3>";
+        String design = "<vaadin-slider min=10 max=20 resolution=1 value=12.3>";
 
         Slider expected = new Slider();
         expected.setMin(10.0);
@@ -55,7 +55,7 @@ public class SliderDeclarativeTest extends DeclarativeTestBase<Slider> {
 
     @Test
     public void testVertical() {
-        String design = "<v-slider vertical>";
+        String design = "<vaadin-slider vertical>";
 
         Slider expected = new Slider();
         expected.setOrientation(SliderOrientation.VERTICAL);
@@ -66,7 +66,7 @@ public class SliderDeclarativeTest extends DeclarativeTestBase<Slider> {
 
     @Test
     public void testReadOnlyValue() {
-        String design = "<v-slider readonly min=10 max=20 resolution=1 value=12.3>";
+        String design = "<vaadin-slider readonly min=10 max=20 resolution=1 value=12.3>";
 
         Slider expected = new Slider();
         expected.setMin(10.0);
index d909d98a36c5a52e5e0a65707ea4f8de5ac626e1..1f0b3d924c4ab4be1b5cf0b0d476d7e35b08b013 100644 (file)
@@ -36,7 +36,7 @@ public abstract class TableDeclarativeTestBase extends
     }
 
     protected String getTag() {
-        return "v-table";
+        return "vaadin-table";
     }
 
     protected void compareBody(Table read, Table expected) {
index c218f93a023253358a8f509a708fc1ae99b58149..a68487782af7c5fd2b5ac6eb50fec5ce27dfebc2 100644 (file)
@@ -35,10 +35,10 @@ public class TabSheetDeclarativeTest extends DeclarativeTestBase<TabSheet> {
 
     @Test
     public void testFeatures() {
-        String design = "<v-tab-sheet tabindex=5><tab caption=test-caption "
+        String design = "<vaadin-tab-sheet tabindex=5><tab caption=test-caption "
                 + "visible=false closable='' enabled=false icon=http://www.vaadin.com/test.png"
                 + " icon-alt=OK description=test-desc style-name=test-style "
-                + "id=test-id><v-text-field/></tab></v-tab-sheet>";
+                + "id=test-id><vaadin-text-field/></tab></vaadin-tab-sheet>";
         TabSheet ts = new TabSheet();
         ts.setTabIndex(5);
         TextField tf = new TextField();
@@ -59,7 +59,7 @@ public class TabSheetDeclarativeTest extends DeclarativeTestBase<TabSheet> {
 
     @Test
     public void testSelected() {
-        String design = "<v-tab-sheet><tab selected=''><v-text-field/></tab></v-tab-sheet>";
+        String design = "<vaadin-tab-sheet><tab selected=''><vaadin-text-field/></tab></vaadin-tab-sheet>";
         TabSheet ts = new TabSheet();
         TextField tf = new TextField();
         ts.addTab(tf);
@@ -70,10 +70,10 @@ public class TabSheetDeclarativeTest extends DeclarativeTestBase<TabSheet> {
 
     @Test
     public void tabsNotShown() {
-        String design = "<v-tab-sheet tabs-visible=\"false\">\n"
+        String design = "<vaadin-tab-sheet tabs-visible=\"false\">\n"
                 + "  <tab caption=\"My Tab\" selected=\"\">\n"
-                + "    <v-label>My Content</v-label>\n" + "  </tab>\n"
-                + "</v-tab-sheet>\n";
+                + "    <vaadin-label>My Content</vaadin-label>\n" + "  </tab>\n"
+                + "</vaadin-tab-sheet>\n";
         TabSheet ts = new TabSheet();
         ts.setTabsVisible(false);
         Label l = new Label("My Content", ContentMode.HTML);
index f70f1fde98bc474d2485fac8e741f86446152d30..fdf2599370601df144c50640f3fea08c46a089c5 100644 (file)
@@ -36,7 +36,7 @@ public class TextAreaDeclarativeTest extends DeclarativeTestBase<TextArea> {
 
     @Test
     public void testTextArea() {
-        String design = "<v-text-area rows=6 wordwrap=false>Hello World!</v-text-area>";
+        String design = "<vaadin-text-area rows=6 wordwrap=false>Hello World!</vaadin-text-area>";
         TextArea ta = new TextArea();
         ta.setRows(6);
         ta.setWordwrap(false);
@@ -47,14 +47,14 @@ public class TextAreaDeclarativeTest extends DeclarativeTestBase<TextArea> {
 
     @Test
     public void testHtmlEntities() throws IOException {
-        String design = "<v-text-area>&amp; Test</v-text-area>";
+        String design = "<vaadin-text-area>&amp; Test</vaadin-text-area>";
         TextArea read = read(design);
         Assert.assertEquals("& Test", read.getValue());
 
         read.setValue("&amp; Test");
 
         DesignContext dc = new DesignContext();
-        Element root = new Element(Tag.valueOf("v-text-area"), "");
+        Element root = new Element(Tag.valueOf("vaadin-text-area"), "");
         read.writeDesign(root, dc);
 
         Assert.assertEquals("&amp;amp; Test", root.html());
@@ -62,7 +62,7 @@ public class TextAreaDeclarativeTest extends DeclarativeTestBase<TextArea> {
 
     @Test
     public void testReadOnlyValue() {
-        String design = "<v-text-area readonly rows=6 wordwrap=false>Hello World!</v-text-area>";
+        String design = "<vaadin-text-area readonly rows=6 wordwrap=false>Hello World!</vaadin-text-area>";
         TextArea ta = new TextArea();
         ta.setRows(6);
         ta.setWordwrap(false);
index d545ee5a1a6dd3c50eea954a63b03f24a2cca0da..3f2935bb450cb1878f13bcb59607ffa80406ad84 100644 (file)
@@ -30,7 +30,7 @@ public class TextFieldDeclarativeTest extends DeclarativeTestBase<TextField> {
 
     @Test
     public void testEmpty() {
-        String design = "<v-text-field/>";
+        String design = "<vaadin-text-field/>";
         TextField tf = new TextField();
         testRead(design, tf);
         testWrite(design, tf);
@@ -38,7 +38,7 @@ public class TextFieldDeclarativeTest extends DeclarativeTestBase<TextField> {
 
     @Test
     public void testValue() {
-        String design = "<v-text-field value=\"test value\"/>";
+        String design = "<vaadin-text-field value=\"test value\"/>";
         TextField tf = new TextField();
         tf.setValue("test value");
         testRead(design, tf);
@@ -47,7 +47,7 @@ public class TextFieldDeclarativeTest extends DeclarativeTestBase<TextField> {
 
     @Test
     public void testReadOnlyValue() {
-        String design = "<v-text-field readonly=\"\" value=\"test value\"/>";
+        String design = "<vaadin-text-field readonly=\"\" value=\"test value\"/>";
         TextField tf = new TextField();
         tf.setValue("test value");
         tf.setReadOnly(true);
index 3fb69a92573f04d8d38611f83dfec3a1270ae652..8577ed1af805696bce2efa30f2dd9d547f6f6f2d 100644 (file)
@@ -32,7 +32,7 @@ public class TreeDeclarativeTest extends DeclarativeTestBase<Tree> {
 
     @Test
     public void testDragMode() {
-        String design = "<v-tree drag-mode='node' />";
+        String design = "<vaadin-tree drag-mode='node' />";
 
         Tree tree = new Tree();
         tree.setDragMode(TreeDragMode.NODE);
@@ -43,13 +43,13 @@ public class TreeDeclarativeTest extends DeclarativeTestBase<Tree> {
 
     @Test
     public void testEmpty() {
-        testRead("<v-tree />", new Tree());
-        testWrite("<v-tree />", new Tree());
+        testRead("<vaadin-tree />", new Tree());
+        testWrite("<vaadin-tree />", new Tree());
     }
 
     @Test
     public void testNodes() {
-        String design = "<v-tree>" //
+        String design = "<vaadin-tree>" //
                 + "  <node text='Node'/>" //
                 + "  <node text='Parent'>" //
                 + "    <node text='Child'>" //
@@ -57,7 +57,7 @@ public class TreeDeclarativeTest extends DeclarativeTestBase<Tree> {
                 + "    </node>" //
                 + "  </node>" //
                 + "  <node text='With icon' icon='http://example.com/icon.png'/>" //
-                + "</v-tree>";
+                + "</vaadin-tree>";
 
         Tree tree = new Tree();
 
index a30ca2a3efb7bd914f82b5cafb7e41b004d06e8f..0e79c906d63f0d7dab6337f9b32b05b2c0cb17db 100644 (file)
@@ -33,7 +33,7 @@ public class TreeTableDeclarativeTest extends TableDeclarativeTest {
 
     @Test
     public void testAttributes() {
-        String design = "<v-tree-table animations-enabled=''>";
+        String design = "<vaadin-tree-table animations-enabled=''>";
         TreeTable table = getTable();
         table.setAnimationsEnabled(true);
 
@@ -43,7 +43,7 @@ public class TreeTableDeclarativeTest extends TableDeclarativeTest {
 
     @Test
     public void testHierarchy() {
-        String design = "<v-tree-table>" //
+        String design = "<vaadin-tree-table>" //
                 + "<table>" //
                 + "<colgroup><col property-id=''></colgroup>" //
                 + "<tbody>" //
@@ -57,7 +57,7 @@ public class TreeTableDeclarativeTest extends TableDeclarativeTest {
                 + "    <tr depth=1 item-id='2.1'><td></tr>" //
                 + "</tbody>" //
                 + "</table>" //
-                + "</v-tree-table>";
+                + "</vaadin-tree-table>";
 
         TreeTable table = getTable();
         table.addContainerProperty("", String.class, "");
@@ -83,7 +83,7 @@ public class TreeTableDeclarativeTest extends TableDeclarativeTest {
 
     @Test
     public void testCollapsed() {
-        String design = "<v-tree-table>" //
+        String design = "<vaadin-tree-table>" //
                 + "  <table>" //
                 + "    <colgroup><col property-id=''></colgroup>" //
                 + "    <tbody>" //
@@ -92,7 +92,7 @@ public class TreeTableDeclarativeTest extends TableDeclarativeTest {
                 + "          <tr depth=2 item-id='1.1.1'><td></tr>" //
                 + "    </tbody>" //
                 + "  </table>" //
-                + "</v-tree-table>";
+                + "</vaadin-tree-table>";
 
         TreeTable table = getTable();
         table.addContainerProperty("", String.class, "");
@@ -116,12 +116,12 @@ public class TreeTableDeclarativeTest extends TableDeclarativeTest {
     }
 
     protected void assertMalformed(String hierarchy) {
-        String design = "<v-tree-table>" //
+        String design = "<vaadin-tree-table>" //
                 + "  <table>" //
                 + "    <colgroup><col property-id=''></colgroup>" //
                 + "    <tbody>" + hierarchy + "</tbody>" //
                 + "  </table>" //
-                + "</v-tree-table>";
+                + "</vaadin-tree-table>";
 
         try {
             read(design);
@@ -151,6 +151,6 @@ public class TreeTableDeclarativeTest extends TableDeclarativeTest {
 
     @Override
     protected String getTag() {
-        return "v-tree-table";
+        return "vaadin-tree-table";
     }
 }
index 569080223b7b1e80d6445281f26dcec378e95d3d..146d1f1ad186dd9a571c48f8b5727f1fc989d9a1 100644 (file)
@@ -31,11 +31,11 @@ public class TwinColSelectDeclarativeTest extends
         DeclarativeTestBase<TwinColSelect> {
 
     public String getBasicDesign() {
-        return "<v-twin-col-select rows=5 right-column-caption='Selected values' left-column-caption='Unselected values'>\n"
+        return "<vaadin-twin-col-select rows=5 right-column-caption='Selected values' left-column-caption='Unselected values'>\n"
                 + "        <option>First item</option>\n"
                 + "        <option selected>Second item</option>\n"
                 + "        <option selected>Third item</option>\n"
-                + "</v-twin-col-select>";
+                + "</vaadin-twin-col-select>";
 
     }
 
@@ -63,12 +63,12 @@ public class TwinColSelectDeclarativeTest extends
 
     @Test
     public void testReadEmpty() {
-        testRead("<v-twin-col-select />", new TwinColSelect());
+        testRead("<vaadin-twin-col-select />", new TwinColSelect());
     }
 
     @Test
     public void testWriteEmpty() {
-        testWrite("<v-twin-col-select />", new TwinColSelect());
+        testWrite("<vaadin-twin-col-select />", new TwinColSelect());
     }
 
 }
\ No newline at end of file
index e08980002de59816dc213bc74c3e0c5f8e43b7d2..12f319c6ada8f91d5a6bb8ff7f62192ea680400d 100644 (file)
@@ -39,7 +39,7 @@ public class UploadDeclarativeTest extends DeclarativeTestBase<Upload> {
     }
 
     private String getBasicDesign() {
-        return "<v-upload button-caption='Send the file' tabindex=5 />";
+        return "<vaadin-upload button-caption='Send the file' tabindex=5 />";
     }
 
     private Upload getBasicExpected() {
@@ -51,11 +51,11 @@ public class UploadDeclarativeTest extends DeclarativeTestBase<Upload> {
 
     @Test
     public void testReadEmpty() {
-        testRead("<v-upload />", new Upload());
+        testRead("<vaadin-upload />", new Upload());
     }
 
     @Test
     public void testWriteEmpty() {
-        testWrite("<v-upload />", new Upload());
+        testWrite("<vaadin-upload />", new Upload());
     }
 }
index 607fb471b9d12629fcc8a4942f82cd94c1c9b4ca..47e9184a1c9fb4036b000a2fb8ae18a632f30e5e 100644 (file)
@@ -38,7 +38,7 @@ public class WindowDeclarativeTest extends DeclarativeTestBase<Window> {
 
     @Test
     public void testDefault() {
-        String design = "<v-window>";
+        String design = "<vaadin-window>";
 
         Window expected = new Window();
 
@@ -49,14 +49,14 @@ public class WindowDeclarativeTest extends DeclarativeTestBase<Window> {
     @Test
     public void testFeatures() {
 
-        String design = "<v-window position='100,100' window-mode='maximized' "
+        String design = "<vaadin-window position='100,100' window-mode='maximized' "
                 + "center modal='' resizable=false resize-lazy='' closable=false draggable=false "
                 + "close-shortcut='ctrl-alt-escape' "
                 + "assistive-prefix='Hello' assistive-postfix='World' assistive-role='alertdialog' "
                 + "tab-stop-enabled='' "
                 + "tab-stop-top-assistive-text='Do not move above the window' "
                 + "tab-stop-bottom-assistive-text='End of window'>"
-                + "</v-window>";
+                + "</vaadin-window>";
 
         Window expected = new Window();
 
@@ -106,7 +106,7 @@ public class WindowDeclarativeTest extends DeclarativeTestBase<Window> {
         expected.addCloseShortcut(KeyCode.ARROW_RIGHT, ModifierKey.CTRL);
 
         // Test validity
-        String design = "<v-window close-shortcut='escape spacebar ctrl-alt-left ctrl-right' />";
+        String design = "<vaadin-window close-shortcut='escape spacebar ctrl-alt-left ctrl-right' />";
         testRead(design, expected);
         testWrite(design, expected);
 
@@ -114,7 +114,7 @@ public class WindowDeclarativeTest extends DeclarativeTestBase<Window> {
         expected.removeCloseShortcut(KeyCode.SPACEBAR);
 
         // Test again
-        design = "<v-window close-shortcut='escape ctrl-alt-left ctrl-right' />";
+        design = "<vaadin-window close-shortcut='escape ctrl-alt-left ctrl-right' />";
         testRead(design, expected);
         testWrite(design, expected);
 
@@ -133,7 +133,7 @@ public class WindowDeclarativeTest extends DeclarativeTestBase<Window> {
 
     protected void assertInvalidPosition(String position) {
         try {
-            read("<v-window position='" + position + "'>");
+            read("<vaadin-window position='" + position + "'>");
             Assert.fail("Invalid position '" + position + "' should throw");
         } catch (Exception e) {
             // expected
@@ -143,8 +143,8 @@ public class WindowDeclarativeTest extends DeclarativeTestBase<Window> {
     @Test
     public void testChildContent() {
 
-        String design = "<v-window>" + createElement(new Button("OK"))
-                + "</v-window>";
+        String design = "<vaadin-window>" + createElement(new Button("OK"))
+                + "</vaadin-window>";
 
         Window expected = new Window();
         expected.setContent(new Button("OK"));
@@ -156,8 +156,8 @@ public class WindowDeclarativeTest extends DeclarativeTestBase<Window> {
     @Test(expected = DesignException.class)
     public void testMultipleContentChildren() {
 
-        String design = "<v-window>" + createElement(new Label("Hello"))
-                + createElement(new Button("OK")) + "</v-window>";
+        String design = "<vaadin-window>" + createElement(new Label("Hello"))
+                + createElement(new Button("OK")) + "</vaadin-window>";
 
         read(design);
     }
@@ -168,7 +168,7 @@ public class WindowDeclarativeTest extends DeclarativeTestBase<Window> {
         Label assistive1 = new Label("Assistive text");
         Label assistive2 = new Label("More assistive text");
 
-        String design = "<v-window>"
+        String design = "<vaadin-window>"
                 + createElement(assistive1).attr(":assistive-description", "")
                 + createElement(new Button("OK"))
                 + createElement(assistive2).attr(":assistive-description", "");
@@ -179,7 +179,7 @@ public class WindowDeclarativeTest extends DeclarativeTestBase<Window> {
 
         testRead(design, expected);
 
-        String written = "<v-window>" + createElement(new Button("OK"))
+        String written = "<vaadin-window>" + createElement(new Button("OK"))
                 + createElement(assistive1).attr(":assistive-description", "")
                 + createElement(assistive2).attr(":assistive-description", "");
 
index 556adb3daed5b9b5ef05a6d59b686dab3202a111..f1d6982992283a8ebe436219829492d23542e593 100644 (file)
@@ -90,7 +90,7 @@ public class DesignTest {
 
     private String getHtmlLabelValue(String html) {
         Document document = Jsoup.parse(html);
-        Element label = document.select("v-label").get(0);
+        Element label = document.select("vaadin-label").get(0);
 
         StringBuilder builder = new StringBuilder();
         for (Node child : label.childNodes()) {
index c2de666641b971fb49f9e65f89bf7199e1812347..e99025abfb2c27a169b96f0b2a7653b429a91ac4 100644 (file)
@@ -1,4 +1,4 @@
-<v-grid        
+<vaadin-grid   
        editor-save-caption='Save'
        editor-cancel-caption='Cancel'
        frozen-columns=1
@@ -37,7 +37,7 @@
                </tr>
                <tr>
                        <th>
-                       <v-text-field width='100%' input-prompt='Filter'></v-textfield>
+                       <vaadin-text-field width='100%' input-prompt='Filter'></vaadin-textfield>
                        <!-- 
                        -->
                        </th>
                </tr>
        </tfoot>
 </table>
-</v-grid>
\ No newline at end of file
+</vaadin-grid>
\ No newline at end of file
index b1532d282a015c6835809b60cd05c563af7affcf..0f9bb49da2197e8d5d90e73f9790cdb909dbc92d 100644 (file)
@@ -1,4 +1,4 @@
-<v-grid caption="Double click to edit" width="100%" height="100%"
+<vaadin-grid caption="Double click to edit" width="100%" height="100%"
        editable selection-mode="none">
 <table>
        <colgroup>
@@ -78,4 +78,4 @@
                </tr>
        </tbody>
 </table>
-</v-grid>
\ No newline at end of file
+</vaadin-grid>
\ No newline at end of file
index b7b1fdaf6075b7940bb40b0cd5a43fbb0e0b77e0..a27ff84e7269ceff43188fa9cdfa9ad2140fc2a2 100644 (file)
@@ -1,4 +1,4 @@
-<v-grid width='100%' height='100%' selection-mode='multi' editable='false'>
+<vaadin-grid width='100%' height='100%' selection-mode='multi' editable='false'>
 <table>
        <colgroup>
                <col />
                </tr>
        </tbody>
 </table>
-</v-grid>
+</vaadin-grid>
index 17f7d6aa59fa31e56bafe79fc0cf81903920d501..b38cb597300bfa83516551f1e54d97ff66cc5341 100644 (file)
@@ -1,23 +1,23 @@
-<v-vertical-layout size-full margin spacing>
-    <v-horizontal-layout spacing margin width-full>   
-        <v-label size-auto>POTUS Database</v-label>
-        <v-button :expand>Add new</v-button>
-    </v-horizontal-layout>
-    <v-table _id="potusList" :expand selectable size-full />
-    <v-vertical-layout _id="form" spacing margin>
-        <v-horizontal-layout spacing>   
-            <v-text-field caption="First Name" width="300px" />
-            <v-text-field caption="Last Name" width="300px" />
-        </v-horizontal-layout>
-        <v-horizontal-layout spacing>   
-            <v-combo-box caption="Party" width="300px" />
-            <v-popup-date-field caption="Took Office" />
-            <v-popup-date-field caption="Left Office" />
-        </v-horizontal-layout>
-        <v-horizontal-layout spacing width-full>  
-            <v-button style-name="primary">Save</v-button>
-            <v-button>Revert</v-button>
-            <v-button :expand :right>Delete</v-button>
-        </v-horizontal-layout>
-    </v-vertical-layout>
-</v-vertical-layout>
\ No newline at end of file
+<vaadin-vertical-layout size-full margin spacing>
+    <vaadin-horizontal-layout spacing margin width-full>   
+        <vaadin-label size-auto>POTUS Database</vaadin-label>
+        <vaadin-button :expand>Add new</vaadin-button>
+    </vaadin-horizontal-layout>
+    <vaadin-table _id="potusList" :expand selectable size-full />
+    <vaadin-vertical-layout _id="form" spacing margin>
+        <vaadin-horizontal-layout spacing>   
+            <vaadin-text-field caption="First Name" width="300px" />
+            <vaadin-text-field caption="Last Name" width="300px" />
+        </vaadin-horizontal-layout>
+        <vaadin-horizontal-layout spacing>   
+            <vaadin-combo-box caption="Party" width="300px" />
+            <vaadin-popup-date-field caption="Took Office" />
+            <vaadin-popup-date-field caption="Left Office" />
+        </vaadin-horizontal-layout>
+        <vaadin-horizontal-layout spacing width-full>  
+            <vaadin-button style-name="primary">Save</vaadin-button>
+            <vaadin-button>Revert</vaadin-button>
+            <vaadin-button :expand :right>Delete</vaadin-button>
+        </vaadin-horizontal-layout>
+    </vaadin-vertical-layout>
+</vaadin-vertical-layout>
\ No newline at end of file
index 05acee96796fa002a7a7ca6c2f023edb917de6d6..dde60652e5b6fa4e8ad49d5efdd95b1f1531f613 100644 (file)
@@ -2,13 +2,13 @@
   <meta name="package-mapping" content="x:com.vaadin.tests.declarative"/>
 </head>
 <body>
-       <v-vertical-layout size-full margin="true" spacing>
-           <v-horizontal-layout spacing margin width-full>   
-               <v-label size-auto>POTUS Database</v-label>
-               <v-button :expand _id="addNew">Add new</v-button>
-           </v-horizontal-layout>
-           <v-table _id="potusList" :expand selectable size-full/>
+       <vaadin-vertical-layout size-full margin="true" spacing>
+           <vaadin-horizontal-layout spacing margin width-full>   
+               <vaadin-label size-auto>POTUS Database</vaadin-label>
+               <vaadin-button :expand _id="addNew">Add new</vaadin-button>
+           </vaadin-horizontal-layout>
+           <vaadin-table _id="potusList" :expand selectable size-full/>
            <x-potus-form _id="potusForm" />
-       </v-vertical-layout>
+       </vaadin-vertical-layout>
 </body>
 
index 0542e1ee5289d26f0af739eca1c22132bf578aa7..4eb6c84e4afb6c46437abdbb0287513bce8d1ff1 100644 (file)
@@ -1,16 +1,16 @@
-<v-vertical-layout _id="form" spacing margin>
-    <v-horizontal-layout spacing>   
-        <v-text-field _id="firstName" caption="First Name" null-representation="" width="300px" />
-        <v-text-field _id="lastName" caption="Last Name" null-representation="" width="300px" />
-    </v-horizontal-layout>
-    <v-horizontal-layout spacing>   
-        <v-combo-box _id="party" caption="Party" width="300px" />
-        <v-popup-date-field _id="tookOffice" caption="Took Office" />
-        <v-popup-date-field _id="leftOffice" caption="Left Office" />
-    </v-horizontal-layout>
-    <v-horizontal-layout spacing width-full>  
-        <v-button _id="save" style-name="primary">Save</v-button>
-        <v-button _id="revert">Revert</v-button>
-        <v-button _id="delete" style-name="danger" :expand :right>Delete</v-button>
-    </v-horizontal-layout>
-</v-vertical-layout>
\ No newline at end of file
+<vaadin-vertical-layout _id="form" spacing margin>
+    <vaadin-horizontal-layout spacing>   
+        <vaadin-text-field _id="firstName" caption="First Name" null-representation="" width="300px" />
+        <vaadin-text-field _id="lastName" caption="Last Name" null-representation="" width="300px" />
+    </vaadin-horizontal-layout>
+    <vaadin-horizontal-layout spacing>   
+        <vaadin-combo-box _id="party" caption="Party" width="300px" />
+        <vaadin-popup-date-field _id="tookOffice" caption="Took Office" />
+        <vaadin-popup-date-field _id="leftOffice" caption="Left Office" />
+    </vaadin-horizontal-layout>
+    <vaadin-horizontal-layout spacing width-full>  
+        <vaadin-button _id="save" style-name="primary">Save</vaadin-button>
+        <vaadin-button _id="revert">Revert</vaadin-button>
+        <vaadin-button _id="delete" style-name="danger" :expand :right>Delete</vaadin-button>
+    </vaadin-horizontal-layout>
+</vaadin-vertical-layout>
\ No newline at end of file
index 370a03e9900d372d5cc0cfd293cfa2696743a899..9aaf3d3d77751b35e1823d802382d846a0ba914b 100644 (file)
@@ -1 +1 @@
-<v-label />
\ No newline at end of file
+<vaadin-label />
\ No newline at end of file