|
@@ -0,0 +1,35 @@
|
|
1
|
+
|
|
2
|
+<template id="card-subtitle">
|
|
3
|
+ <style>
|
|
4
|
+ :host {
|
|
5
|
+ height: 18px;
|
|
6
|
+ margin: 0;
|
|
7
|
+ font-family: inherit;
|
|
8
|
+ font-size: 10pt;
|
|
9
|
+ font-style: italic;
|
|
10
|
+ }
|
|
11
|
+ </style>
|
|
12
|
+
|
|
13
|
+ <content>
|
|
14
|
+ </content>
|
|
15
|
+
|
|
16
|
+</template>
|
|
17
|
+
|
|
18
|
+<script>
|
|
19
|
+ (function(window, document) {
|
|
20
|
+ var elemName = 'card-subtitle';
|
|
21
|
+ var mainDoc = document;
|
|
22
|
+ var importDoc = document.currentScript.ownerDocument;
|
|
23
|
+
|
|
24
|
+ var proto = Object.create(HTMLElement.prototype);
|
|
25
|
+ proto.createdCallback = function () {
|
|
26
|
+ var template = importDoc.getElementById(elemName);
|
|
27
|
+ var clone = mainDoc.importNode(template.content, true);
|
|
28
|
+ var root = this.createShadowRoot();
|
|
29
|
+ root.appendChild(clone);
|
|
30
|
+ }
|
|
31
|
+
|
|
32
|
+ mainDoc.registerElement(elemName, { prototype: proto });
|
|
33
|
+
|
|
34
|
+ })(window, document);
|
|
35
|
+</script>
|