VF Page
<apex:page >
<head>
<meta charset="UTF-8"/>
<script src="https://www.polymer-project.org/0.5/components/webcomponentsjs/webcomponents.js"></script>
<meta name="viewport" content="width=device-width, minimum-scale=1.0, initial-scale=1, user-scalable=yes"/>
<link rel="import" href="https://www.polymer-project.org/0.5/components/font-roboto/roboto.html"/>
<link rel="import" href="https://www.polymer-project.org/0.5/components/core-icons/core-icons.html"/>
<link rel="import" href="https://www.polymer-project.org/0.5/components/core-toolbar/core-toolbar.html"/>
<link rel="import" href="https://www.polymer-project.org/0.5/components/core-media-query/core-media-query.html"/>
<link rel="import" href="https://www.polymer-project.org/0.5/components/paper-icon-button/paper-icon-button.html"/>
<style>
body {
font-family: RobotoDraft, 'Helvetica Neue', Helvetica, Arial;
margin: 0;
}
core-toolbar {
color: #f1f1f1;
fill: #f1f1f1;
}
</style>
</head>
<body unresolved="">
<core-toolbar style="background: #4285f4;">
<paper-icon-button icon="menu"></paper-icon-button>
<span flex="">Title</span>
<paper-icon-button icon="refresh"></paper-icon-button>
<paper-icon-button icon="more-vert"></paper-icon-button>
</core-toolbar>
<br/>
<core-toolbar style="background: #3f51b5;">
<paper-icon-button icon="menu"></paper-icon-button>
<span flex="">Title</span>
<paper-icon-button icon="refresh"></paper-icon-button>
<paper-icon-button icon="more-vert"></paper-icon-button>
</core-toolbar>
<br/>
<core-toolbar class="tall" style="background: #0f9d58;">
<paper-icon-button icon="menu"></paper-icon-button>
<span flex="">Title</span>
<paper-icon-button icon="refresh"></paper-icon-button>
<paper-icon-button icon="more-vert"></paper-icon-button>
</core-toolbar>
<br/>
<core-toolbar class="tall" style="background: #ffeb3b; color: #333; fill: #333;">
<paper-icon-button icon="menu" class="bottom"></paper-icon-button>
<span flex="" class="bottom">Title</span>
<paper-icon-button icon="refresh" class="bottom"></paper-icon-button>
<paper-icon-button icon="more-vert" class="bottom"></paper-icon-button>
</core-toolbar>
<br/>
<core-toolbar class="medium-tall" style="background: #ff5722;">
<paper-icon-button icon="menu"></paper-icon-button>
<span flex=""></span>
<paper-icon-button icon="refresh"></paper-icon-button>
<paper-icon-button icon="more-vert"></paper-icon-button>
<span class="bottom indent">Title</span>
</core-toolbar>
<br/>
<core-toolbar class="tall" style="background: #9c27b0;">
<paper-icon-button icon="menu"></paper-icon-button>
<div flex=""></div>
<paper-icon-button icon="refresh"></paper-icon-button>
<paper-icon-button icon="more-vert"></paper-icon-button>
<div flex="" class="middle indent">Title</div>
<div flex="" class="bottom indent" style="font-size: 18px;">Title2</div>
</core-toolbar>
<core-media-query id="mediaQuery" query="max-width: 800px"></core-media-query>
<script>
document.querySelector('#mediaQuery').addEventListener('core-media-change',
function(e) {
document.body.classList.toggle('core-narrow', e.detail.matches);
});
</script>
</body>
</apex:page>
Demo: https://www.polymer-project.org/0.5/components/paper-elements/demo.html#core-toolbar
--------------------------------------------------------------------------------------------------------------------------
<apex:page >
<head>
<meta charset="UTF-8"/>
<script src="https://www.polymer-project.org/0.5/components/webcomponentsjs/webcomponents.js"></script>
<meta name="viewport" content="width=device-width, minimum-scale=1.0, initial-scale=1, user-scalable=yes"/>
<link rel="import" href="https://www.polymer-project.org/0.5/components/font-roboto/roboto.html"/>
<link rel="import" href="https://www.polymer-project.org/0.5/components/core-icons/core-icons.html"/>
<link rel="import" href="https://www.polymer-project.org/0.5/components/core-toolbar/core-toolbar.html"/>
<link rel="import" href="https://www.polymer-project.org/0.5/components/core-media-query/core-media-query.html"/>
<link rel="import" href="https://www.polymer-project.org/0.5/components/paper-icon-button/paper-icon-button.html"/>
<style>
body {
font-family: RobotoDraft, 'Helvetica Neue', Helvetica, Arial;
margin: 0;
}
core-toolbar {
color: #f1f1f1;
fill: #f1f1f1;
}
</style>
</head>
<body unresolved="">
<core-toolbar style="background: #4285f4;">
<paper-icon-button icon="menu"></paper-icon-button>
<span flex="">Title</span>
<paper-icon-button icon="refresh"></paper-icon-button>
<paper-icon-button icon="more-vert"></paper-icon-button>
</core-toolbar>
<br/>
<core-toolbar style="background: #3f51b5;">
<paper-icon-button icon="menu"></paper-icon-button>
<span flex="">Title</span>
<paper-icon-button icon="refresh"></paper-icon-button>
<paper-icon-button icon="more-vert"></paper-icon-button>
</core-toolbar>
<br/>
<core-toolbar class="tall" style="background: #0f9d58;">
<paper-icon-button icon="menu"></paper-icon-button>
<span flex="">Title</span>
<paper-icon-button icon="refresh"></paper-icon-button>
<paper-icon-button icon="more-vert"></paper-icon-button>
</core-toolbar>
<br/>
<core-toolbar class="tall" style="background: #ffeb3b; color: #333; fill: #333;">
<paper-icon-button icon="menu" class="bottom"></paper-icon-button>
<span flex="" class="bottom">Title</span>
<paper-icon-button icon="refresh" class="bottom"></paper-icon-button>
<paper-icon-button icon="more-vert" class="bottom"></paper-icon-button>
</core-toolbar>
<br/>
<core-toolbar class="medium-tall" style="background: #ff5722;">
<paper-icon-button icon="menu"></paper-icon-button>
<span flex=""></span>
<paper-icon-button icon="refresh"></paper-icon-button>
<paper-icon-button icon="more-vert"></paper-icon-button>
<span class="bottom indent">Title</span>
</core-toolbar>
<br/>
<core-toolbar class="tall" style="background: #9c27b0;">
<paper-icon-button icon="menu"></paper-icon-button>
<div flex=""></div>
<paper-icon-button icon="refresh"></paper-icon-button>
<paper-icon-button icon="more-vert"></paper-icon-button>
<div flex="" class="middle indent">Title</div>
<div flex="" class="bottom indent" style="font-size: 18px;">Title2</div>
</core-toolbar>
<core-media-query id="mediaQuery" query="max-width: 800px"></core-media-query>
<script>
document.querySelector('#mediaQuery').addEventListener('core-media-change',
function(e) {
document.body.classList.toggle('core-narrow', e.detail.matches);
});
</script>
</body>
</apex:page>
Demo: https://www.polymer-project.org/0.5/components/paper-elements/demo.html#core-toolbar
--------------------------------------------------------------------------------------------------------------------------
No comments:
Post a Comment