Advertisement
Guest User

Untitled

a guest
May 24th, 2015
213
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 3.38 KB | None | 0 0
  1. <link rel="import" href="../core-scaffold/core-scaffold.html">
  2. <link rel="import" href="../core-header-panel/core-header-panel.html">
  3. <link rel="import" href="../core-menu/core-menu.html">
  4. <link rel="import" href="../core-item/core-item.html">
  5. <link rel="import" href="../core-icon-button/core-icon-button.html">
  6. <link rel="import" href="../core-toolbar/core-toolbar.html">
  7. <link rel="import" href="../core-field/core-field.html">
  8. <link rel="import" href="../core-icon/core-icon.html">
  9. <link rel="import" href="../core-input/core-input.html">
  10. <link rel="import" href="../core-icons/core-icons.html">
  11. <link rel="import" href="../core-menu/core-submenu.html">
  12. <link rel="import" href="../google-map/google-map.html">
  13. <link rel="import" href="../google-map/google-map-search.html">
  14.  
  15. <polymer-element name="my-element">
  16.  
  17. <template>
  18. <style>
  19. :host {
  20. position: absolute;
  21. width: 100%;
  22. height: 100%;
  23. box-sizing: border-box;
  24. }
  25. #core_scaffold {
  26. position: absolute;
  27. top: 0px;
  28. right: 0px;
  29. bottom: 0px;
  30. left: 0px;
  31. width: 100%;
  32. height: 100%;
  33. }
  34. #core_header_panel {
  35. background-color: rgb(255, 255, 255);
  36. }
  37. #core_toolbar {
  38. color: rgb(255, 255, 255);
  39. background-color: rgb(79, 125, 201);
  40. }
  41. #core_menu {
  42. font-size: 16px;
  43. }
  44. #google_map {
  45. width: 100%;
  46. height: 100%;
  47. display: block;
  48. left: 0px;
  49. top: 0px;
  50. position: absolute;
  51. }
  52. #core_field {
  53. left: 18px;
  54. top: 10px;
  55. position: absolute;
  56. width: 200px;
  57. height: 40px;
  58. background-color: rgb(255, 255, 255);
  59. }
  60. #google_map_search {
  61. left: 910px;
  62. top: 580px;
  63. position: absolute;
  64. }
  65. #input {
  66. padding: 15px;
  67. }
  68. #google_map_search1 {
  69. left: 1790px;
  70. top: 810px;
  71. }
  72. </style>
  73. <core-scaffold id="core_scaffold">
  74. <core-header-panel mode="seamed" id="core_header_panel" navigation flex>
  75. <core-toolbar id="core_toolbar">
  76. <core-field id="core_field" icon="search" theme="core-light-theme" center horizontal layout>
  77. <core-icon icon="search" id="core_icon"></core-icon>
  78. <input id="core-input" placeholder="type something..." is="core-input">
  79. </core-field>
  80. </core-toolbar>
  81. <core-menu selected="Roadmap" valueattr="label" selectedindex="0" id="core_menu" theme="core-light-theme">
  82. <core-item id="core_item" icon="settings" on-tap="{{ showRoad }}" label="Roadmap" horizontal center layout active></core-item>
  83. <core-item id="core_item1" icon="settings" on-tap="{{ showSat }}" label="Satellite" horizontal center layout></core-item>
  84. </core-menu>
  85. </core-header-panel>
  86. <div id="div" tool>Title</div>
  87. <google-map latitude="{{ $.google_map_search.result.latitude }}" longitude="{{ $.google_map_search.result.longitude }}" zoom="11" id="google_map"></google-map>
  88. <google-map-search map="{{ $.google_map.map }}" query="{{ }}" id="google_map_search"></google-map-search>
  89. </core-scaffold>
  90. </template>
  91.  
  92. <script>
  93.  
  94. Polymer({
  95. showRoad: function (){
  96. this.$.google_map.mapType = 'roadmap';
  97. },
  98. showSat: function (){
  99. this.$.google_map.mapType = 'satellite';
  100. }
  101. });
  102.  
  103. </script>
  104.  
  105. </polymer-element>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement