Skip to content

Commit 0947e07

Browse files
authored
Add files via upload
1 parent 317c62b commit 0947e07

File tree

1 file changed

+61
-0
lines changed

1 file changed

+61
-0
lines changed

index.htm

+61
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,61 @@
1+
<!DOCTYPE html>
2+
<html lang="en">
3+
<head>
4+
<script type="text/javascript" src="https://cdnjs.cloudflare.com/ajax/libs/webcomponentsjs/1.0.22/webcomponents-lite.js"></script>
5+
<script type="text/javascript" src="source/smart.element.js"></script>
6+
<script>
7+
Smart('smart-test', class TestElement extends Smart.BaseElement {
8+
// properties.
9+
static get properties() {
10+
return {
11+
'content': {
12+
type: 'string'
13+
}
14+
};
15+
}
16+
17+
/** Element's template. */
18+
template() {
19+
return '<div inner-h-t-m-l=\'[[content]]\'></div>';
20+
}
21+
22+
ready() {
23+
super.ready();
24+
}
25+
26+
propertyChangedHandler(propertyName, oldValue, newValue) {
27+
super.propertyChangedHandler(propertyName, oldValue, newValue);
28+
}
29+
});
30+
</script>
31+
<style>
32+
.smart-container {
33+
box-sizing: border-box;
34+
font-family: inherit;
35+
font-size: inherit;
36+
display: block;
37+
width: 100%;
38+
height: 100%;
39+
outline: none;
40+
margin: 0;
41+
padding: 0;
42+
}
43+
44+
.smart-container * {
45+
box-sizing: border-box;
46+
}
47+
smart-test {
48+
background: #ddd;
49+
color: #333;
50+
display: inline-block;
51+
border-radius: 5px;
52+
border: 1px solid #aaa;
53+
width: 100px;
54+
text-align: center;
55+
}
56+
</style>
57+
</head>
58+
<body>
59+
<smart-test content="Test Element"></smart-test>
60+
</body>
61+
</html>

0 commit comments

Comments
 (0)