Skip to content

Instantly share code, notes, and snippets.

@ArtemSyzonenko
Last active August 29, 2015 14:18
Show Gist options
  • Save ArtemSyzonenko/f9bf200503e21220b9ab to your computer and use it in GitHub Desktop.
Save ArtemSyzonenko/f9bf200503e21220b9ab to your computer and use it in GitHub Desktop.
designer
<link rel="import" href="../core-drawer-panel/core-drawer-panel.html">
<polymer-element name="my-element">
<template>
<style>
:host {
position: absolute;
width: 100%;
height: 100%;
box-sizing: border-box;
top: 0px;
left: 0px;
}
#section {
left: 1440px;
top: 710px;
position: absolute;
}
#core_drawer_panel {
position: absolute;
top: 0px;
right: 0px;
bottom: 0px;
left: 0px;
}
#section1 {
height: 100%;
box-sizing: border-box;
background-color: rgb(221, 221, 221);
}
</style>
<core-drawer-panel transition selected="main" narrow id="core_drawer_panel" touch-action="pan-y">
<section id="section" drawer></section>
<section id="section1" main>Polymer includes a declarative layout system built on top of CSS Flexbox. Features in CSS Flexbox are exposed as attributes you include on elements. The layout attributes are implemented in layout.html - a file included whenever you import Polymer in your element. Layout attributes use Shadow DOM’s /deep/ rules and therefore, work across all Shadow DOM boundaries. As long as you’re loading Polymer, feel free to reuse these attributes in your own elements. Horizontal and vertical layout When a container includes the layout attribute, it can become a flex container. You can specify horizontal, vertical to change the orientation: <div horizontal layout> <div>One</div> <div>Two</div> <div>Three</div> </div> One Two Three Flexible children Children of an element using the layout attribute can use flex attributes to control their own sizing. For example: <div horizontal layout> <div>Alpha</div> <div flex>Beta (flex)</div> <div>Gamma</div> </div> Alpha Beta (flex) Gamma The same is true for children of vertical elements: <div vertical layout style="height:250px"> <div>Alpha</div> <div flex>Beta (flex)</div> <div>Gamma</div> </div>Polymer includes a declarative layout system built on top of CSS Flexbox. Features in CSS Flexbox are exposed as attributes you include on elements. The layout attributes are implemented in layout.html - a file included whenever you import Polymer in your element. Layout attributes use Shadow DOM’s /deep/ rules and therefore, work across all Shadow DOM boundaries. As long as you’re loading Polymer, feel free to reuse these attributes in your own elements. Horizontal and vertical layout When a container includes the layout attribute, it can become a flex container. You can specify horizontal, vertical to change the orientation: <div horizontal layout> <div>One</div> <div>Two</div> <div>Three</div> </div> One Two Three Flexible children Children of an element using the layout attribute can use flex attributes to control their own sizing. For example: <div horizontal layout> <div>Alpha</div> <div flex>Beta (flex)</div> <div>Gamma</div> </div> Alpha Beta (flex) Gamma The same is true for children of vertical elements: <div vertical layout style="height:250px"> <div>Alpha</div> <div flex>Beta (flex)</div> <div>Gamma</div> </div>Polymer includes a declarative layout system built on top of CSS Flexbox. Features in CSS Flexbox are exposed as attributes you include on elements. The layout attributes are implemented in layout.html - a file included whenever you import Polymer in your element. Layout attributes use Shadow DOM’s /deep/ rules and therefore, work across all Shadow DOM boundaries. As long as you’re loading Polymer, feel free to reuse these attributes in your own elements. Horizontal and vertical layout When a container includes the layout attribute, it can become a flex container. You can specify horizontal, vertical to change the orientation: <div horizontal layout> <div>One</div> <div>Two</div> <div>Three</div> </div> One Two Three Flexible children Children of an element using the layout attribute can use flex attributes to control their own sizing. For example: <div horizontal layout> <div>Alpha</div> <div flex>Beta (flex)</div> <div>Gamma</div> </div> Alpha Beta (flex) Gamma The same is true for children of vertical elements: <div vertical layout style="height:250px"> <div>Alpha</div> <div flex>Beta (flex)</div> <div>Gamma</div> </div>Polymer includes a declarative layout system built on top of CSS Flexbox. Features in CSS Flexbox are exposed as attributes you include on elements. The layout attributes are implemented in layout.html - a file included whenever you import Polymer in your element. Layout attributes use Shadow DOM’s /deep/ rules and therefore, work across all Shadow DOM boundaries. As long as you’re loading Polymer, feel free to reuse these attributes in your own elements. Horizontal and vertical layout When a container includes the layout attribute, it can become a flex container. You can specify horizontal, vertical to change the orientation: <div horizontal layout> <div>One</div> <div>Two</div> <div>Three</div> </div> One Two Three Flexible children Children of an element using the layout attribute can use flex attributes to control their own sizing. For example: <div horizontal layout> <div>Alpha</div> <div flex>Beta (flex)</div> <div>Gamma</div> </div> Alpha Beta (flex) Gamma The same is true for children of vertical elements: <div vertical layout style="height:250px"> <div>Alpha</div> <div flex>Beta (flex)</div> <div>Gamma</div> </div>Polymer includes a declarative layout system built on top of CSS Flexbox. Features in CSS Flexbox are exposed as attributes you include on elements. The layout attributes are implemented in layout.html - a file included whenever you import Polymer in your element. Layout attributes use Shadow DOM’s /deep/ rules and therefore, work across all Shadow DOM boundaries. As long as you’re loading Polymer, feel free to reuse these attributes in your own elements. Horizontal and vertical layout When a container includes the layout attribute, it can become a flex container. You can specify horizontal, vertical to change the orientation: <div horizontal layout> <div>One</div> <div>Two</div> <div>Three</div> </div> One Two Three Flexible children Children of an element using the layout attribute can use flex attributes to control their own sizing. For example: <div horizontal layout> <div>Alpha</div> <div flex>Beta (flex)</div> <div>Gamma</div> </div> Alpha Beta (flex) Gamma The same is true for children of vertical elements: <div vertical layout style="height:250px"> <div>Alpha</div> <div flex>Beta (flex)</div> <div>Gamma</div> </div>Polymer includes a declarative layout system built on top of CSS Flexbox. Features in CSS Flexbox are exposed as attributes you include on elements. The layout attributes are implemented in layout.html - a file included whenever you import Polymer in your element. Layout attributes use Shadow DOM’s /deep/ rules and therefore, work across all Shadow DOM boundaries. As long as you’re loading Polymer, feel free to reuse these attributes in your own elements. Horizontal and vertical layout When a container includes the layout attribute, it can become a flex container. You can specify horizontal, vertical to change the orientation: <div horizontal layout> <div>One</div> <div>Two</div> <div>Three</div> </div> One Two Three Flexible children Children of an element using the layout attribute can use flex attributes to control their own sizing. For example: <div horizontal layout> <div>Alpha</div> <div flex>Beta (flex)</div> <div>Gamma</div> </div> Alpha Beta (flex) Gamma The same is true for children of vertical elements: <div vertical layout style="height:250px"> <div>Alpha</div> <div flex>Beta (flex)</div> <div>Gamma</div> </div>Polymer includes a declarative layout system built on top of CSS Flexbox. Features in CSS Flexbox are exposed as attributes you include on elements. The layout attributes are implemented in layout.html - a file included whenever you import Polymer in your element. Layout attributes use Shadow DOM’s /deep/ rules and therefore, work across all Shadow DOM boundaries. As long as you’re loading Polymer, feel free to reuse these attributes in your own elements. Horizontal and vertical layout When a container includes the layout attribute, it can become a flex container. You can specify horizontal, vertical to change the orientation: <div horizontal layout> <div>One</div> <div>Two</div> <div>Three</div> </div> One Two Three Flexible children Children of an element using the layout attribute can use flex attributes to control their own sizing. For example: <div horizontal layout> <div>Alpha</div> <div flex>Beta (flex)</div> <div>Gamma</div> </div> Alpha Beta (flex) Gamma The same is true for children of vertical elements: <div vertical layout style="height:250px"> <div>Alpha</div> <div flex>Beta (flex)</div> <div>Gamma</div> </div>Polymer includes a declarative layout system built on top of CSS Flexbox. Features in CSS Flexbox are exposed as attributes you include on elements. The layout attributes are implemented in layout.html - a file included whenever you import Polymer in your element. Layout attributes use Shadow DOM’s /deep/ rules and therefore, work across all Shadow DOM boundaries. As long as you’re loading Polymer, feel free to reuse these attributes in your own elements. Horizontal and vertical layout When a container includes the layout attribute, it can become a flex container. You can specify horizontal, vertical to change the orientation: <div horizontal layout> <div>One</div> <div>Two</div> <div>Three</div> </div> One Two Three Flexible children Children of an element using the layout attribute can use flex attributes to control their own sizing. For example: <div horizontal layout> <div>Alpha</div> <div flex>Beta (flex)</div> <div>Gamma</div> </div> Alpha Beta (flex) Gamma The same is true for children of vertical elements: <div vertical layout style="height:250px"> <div>Alpha</div> <div flex>Beta (flex)</div> <div>Gamma</div> </div>Polymer includes a declarative layout system built on top of CSS Flexbox. Features in CSS Flexbox are exposed as attributes you include on elements. The layout attributes are implemented in layout.html - a file included whenever you import Polymer in your element. Layout attributes use Shadow DOM’s /deep/ rules and therefore, work across all Shadow DOM boundaries. As long as you’re loading Polymer, feel free to reuse these attributes in your own elements. Horizontal and vertical layout When a container includes the layout attribute, it can become a flex container. You can specify horizontal, vertical to change the orientation: <div horizontal layout> <div>One</div> <div>Two</div> <div>Three</div> </div> One Two Three Flexible children Children of an element using the layout attribute can use flex attributes to control their own sizing. For example: <div horizontal layout> <div>Alpha</div> <div flex>Beta (flex)</div> <div>Gamma</div> </div> Alpha Beta (flex) Gamma The same is true for children of vertical elements: <div vertical layout style="height:250px"> <div>Alpha</div> <div flex>Beta (flex)</div> <div>Gamma</div> </div></section>
</core-drawer-panel>
</template>
<script>
Polymer({
});
</script>
</polymer-element>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment