forked from vaadin/web-components
-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.html
34 lines (31 loc) · 1.02 KB
/
index.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
<!DOCTYPE html>
<html lang="en">
<head>
<title>Vaadin web components</title>
<meta charset="utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
</head>
<body>
<style>
iron-component-page {
--app-drawer-width: 320px;
}
</style>
<iron-component-page></iron-component-page>
<script type="module">
import '@polymer/iron-component-page/iron-component-page.js';
requestAnimationFrame(() => {
setTimeout(() => {
const page = document.querySelector('iron-component-page');
const nav = page.shadowRoot.querySelector('iron-doc-nav');
const repeat = nav.shadowRoot.querySelector('dom-repeat');
// hide mixins section from the navigation
repeat.addEventListener('dom-change', () => {
const sections = nav.shadowRoot.querySelectorAll('section');
sections[sections.length - 2].setAttribute('hidden', '');
});
});
});
</script>
</body>
</html>