Skip to content

Commit 6367523

Browse files
javier-godoypaodb
authored andcommitted
feat(demo): add SourcePositionDemo
1 parent 474e72f commit 6367523

2 files changed

Lines changed: 37 additions & 0 deletions

File tree

src/test/java/com/flowingcode/vaadin/addons/demo/Demo.java

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35,5 +35,6 @@ public Demo() {
3535
addDemo(SampleDemoHighlight.class);
3636
addDemo(AdHocDemo.class);
3737
addDemo(MultiSourceDemo.class);
38+
addDemo(SourcePositionDemo.class);
3839
}
3940
}
Lines changed: 36 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,36 @@
1+
/*-
2+
* #%L
3+
* Commons Demo
4+
* %%
5+
* Copyright (C) 2020 - 2023 Flowing Code
6+
* %%
7+
* Licensed under the Apache License, Version 2.0 (the "License");
8+
* you may not use this file except in compliance with the License.
9+
* You may obtain a copy of the License at
10+
*
11+
* http://www.apache.org/licenses/LICENSE-2.0
12+
*
13+
* Unless required by applicable law or agreed to in writing, software
14+
* distributed under the License is distributed on an "AS IS" BASIS,
15+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
16+
* See the License for the specific language governing permissions and
17+
* limitations under the License.
18+
* #L%
19+
*/
20+
package com.flowingcode.vaadin.addons.demo;
21+
22+
import com.vaadin.flow.component.html.Div;
23+
import com.vaadin.flow.component.html.Span;
24+
import com.vaadin.flow.router.PageTitle;
25+
import com.vaadin.flow.router.Route;
26+
27+
@Route(value = "demo/source-position", layout = Demo.class)
28+
@PageTitle("Reversed orientation")
29+
@DemoSource(sourcePosition = SourcePosition.PRIMARY)
30+
// show-source @DemoSource(sourcePosition = SourcePosition.PRIMARY)
31+
public class SourcePositionDemo extends Div {
32+
33+
public SourcePositionDemo() {
34+
add(new Span("Demo component with source defaulted to primary position"));
35+
}
36+
}

0 commit comments

Comments
 (0)