Skip to content

Instantly share code, notes, and snippets.

@danbrown1010
Last active August 29, 2015 14:18
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save danbrown1010/db6182ae865e1e240f9d to your computer and use it in GitHub Desktop.
Save danbrown1010/db6182ae865e1e240f9d to your computer and use it in GitHub Desktop.
designer
<link rel="import" href="../core-scaffold/core-scaffold.html">
<link rel="import" href="../core-header-panel/core-header-panel.html">
<link rel="import" href="../core-menu/core-menu.html">
<link rel="import" href="../core-item/core-item.html">
<link rel="import" href="../core-icon-button/core-icon-button.html">
<link rel="import" href="../core-toolbar/core-toolbar.html">
<link rel="import" href="../core-field/core-field.html">
<link rel="import" href="../core-icon/core-icon.html">
<link rel="import" href="../core-input/core-input.html">
<link rel="import" href="../core-icons/core-icons.html">
<link rel="import" href="../speech-mic/speech-mic.html">
<link rel="import" href="../core-menu/core-submenu.html">
<link rel="import" href="../core-pages/core-pages.html">
<polymer-element name="my-element">
<template>
<style>
:host {
position: absolute;
width: 100%;
height: 100%;
box-sizing: border-box;
}
#core_scaffold {
position: absolute;
top: 0px;
right: 0px;
bottom: 0px;
left: 0px;
width: 100%;
height: 100%;
}
#core_header_panel {
background-color: rgb(255, 255, 255);
}
#core_toolbar {
color: rgb(255, 255, 255);
background-color: rgb(79, 125, 201);
}
#core_menu {
font-size: 16px;
}
#core_field {
left: 18px;
top: 10px;
position: absolute;
width: 210px;
height: 40px;
background-color: rgb(255, 255, 255);
}
#core_card {
position: absolute;
width: 100%;
height: 100%;
border-radius: 2px;
box-shadow: rgba(0, 0, 0, 0.0980392) 0px 2px 4px, rgba(0, 0, 0, 0.0980392) 0px 0px 3px;
left: 0px;
top: 0px;
background-color: rgb(255, 103, 123);
}
#core_pages {
width: 100%;
height: 100%;
border: 1px solid silver;
left: 0px;
top: 0px;
position: absolute;
background-color: rgb(169, 169, 169);
}
</style>
<core-scaffold id="core_scaffold">
<core-header-panel mode="seamed" id="core_header_panel" navigation flex>
<core-toolbar id="core_toolbar">
<core-field id="core_field" icon="search" theme="core-light-theme" center horizontal layout>
<core-icon icon="search" id="core_icon"></core-icon>
<core-input id="core_input" flex></core-input>
<speech-mic transcript="hello welcome" completetranscript="hello welcome" id="speech_mic"></speech-mic>
</core-field>
</core-toolbar>
<core-menu selected="Tanks" valueattr="label" selectedindex="0" id="core_menu" theme="core-light-theme">
<core-item id="ci_tanks" on-tap="{{ showTanks }}" icon="aspect-ratio" label="Tanks" horizontal center layout url="../core-animation/demo.html" active></core-item>
<core-item id="ci_lights" on-tap="{{ showLights }}" icon="visibility" label="Lights" horizontal center layout></core-item>
<core-item id="ci_monitors" on-tap="{{ showMonitors }}" icon="announcement" label="Monitors" horizontal center layout></core-item>
<core-item id="ci_livestock" on-tap="{{ showLivestock }}" icon="group-work" label="Livestock" horizontal center layout></core-item>
<core-item id="ci_room" on-tap="{{ showRoom }}" icon="language" label="Room" horizontal center layout></core-item>
<core-item id="ci_logs" on-tap="{{ showLogs }}" icon="event" label="Reef Log" horizontal center layout></core-item>
<core-item id="ci_analytics" on-tap="{{ showAnalytics }}" icon="assessment" label="Analytics" horizontal center layout></core-item>
<core-item id="ci_controller" on-tap="{{ showController }}" icon="settings-input-composite" label="Controller Config" horizontal center layout></core-item>
<core-item id="ci_remote" on-tap="{{ showRemote }}" icon="settings-remote" label="Remote Control" horizontal center layout></core-item>
</core-menu>
</core-header-panel>
<div id="div" tool>Blacktip v0.2</div>
<core-pages selected="0" selectedindex="0" notap id="core_pages">
<section id="tanks_page" active>Tanks Page</section>
<section id="lights_page">Lights Page</section>
<section id="monitors_page" active>Monitors Page</section>
<section id="livestock_page">Livestock Page</section>
<section id="room_page">Room Page</section>
<section id="analytics_page">Analytics Page</section>
<section id="controller_page">Controller Page</section>
<section id="remote_page">Remote Control Page</section>
</core-pages>
</core-scaffold>
</template>
<script>
Polymer({
showTanks: function () {
this.$.corepages.selected = "0";
//this.$.tanks_page.active = "true";
},
showLights: function () {
this.$.corepages.selected = "1";
// this.$.tanks_page.active = "true";
},
showMonitors: function () {
this.$.corepages.selectedindex = "2";
},
showLivestock: function () {},
showRoom: function () {},
showLogs: function () {},
showAnalytics: function () {},
showController: function () {},
showRemote: function () {}
});
</script>
</polymer-element>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment