navbar.html 2.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112
  1. <style>
  2. nav-bar {
  3. position: absolute;
  4. height: 160px;
  5. width: 100%;
  6. bottom: 0;
  7. background-color: rgba(0, 0, 0, 0.3);
  8. color: white;
  9. transition: 1s;
  10. align-items: flex-start;
  11. justify-content: space-around;
  12. display: flex;
  13. flex-direction: column;
  14. }
  15. /* Big screens have room for the entire navbar */
  16. @media screen and (min-width: 768px) {
  17. nav-bar {
  18. align-items: center;
  19. flex-direction: row;
  20. justify-content: space-between;
  21. height: 80px;
  22. }
  23. }
  24. div.flex-container {
  25. display: flex;
  26. width: 100%;
  27. }
  28. div.thumbnail {
  29. position: relative;
  30. overflow: hidden;
  31. display: block;
  32. width: 40px;
  33. height: 40px;
  34. background-size: cover;
  35. background-position: center;
  36. border-radius: 20px;
  37. margin: 0 10px;
  38. }
  39. div.title-container {
  40. flex-direction: column;
  41. display: flex;
  42. justify-content: space-between;
  43. }
  44. span.model-title {
  45. font-size: 125%;
  46. }
  47. span.model-subtitle {
  48. font-size: 90%;
  49. }
  50. div.button-container {
  51. align-items: center;
  52. justify-content: flex-end;
  53. }
  54. div.button {
  55. cursor: pointer;
  56. height: 30px;
  57. margin: 0 10px;
  58. }
  59. div.button img {
  60. height: 100%;
  61. }
  62. </style>
  63. {{#if disableOnFullscreen}}
  64. <style>
  65. viewer:fullscreen nav-bar {
  66. display: none;
  67. }
  68. viewer:-moz-full-screen nav-bar {
  69. display: none;
  70. }
  71. viewer:-webkit-full-screen nav-bar {
  72. display: none;
  73. }
  74. </style>
  75. {{/if}}
  76. <div class="flex-container" id="model-metadata">
  77. <!-- holding the description -->
  78. <div class="thumbnail">
  79. <!-- holding the thumbnail
  80. <img src="{{thumbnail}}" alt="{{title}}">-->
  81. </div>
  82. <div class="title-container">
  83. <span class="model-title">{{#if title}}{{title}}{{/if}}</span>
  84. <span class="model-subtitle"> {{#if subtitle}}{{subtitle}} {{/if}}</span>
  85. </div>
  86. </div>
  87. <div class="button-container flex-container">
  88. <!-- holding the buttons -->
  89. {{#each buttons}}
  90. <div id="{{id}}" class="button">
  91. {{#if text}}
  92. <span>{{text}}</span>> {{/if}} {{#if image}}
  93. <img src="{{image}}" alt="{{altText}}"> {{/if}}
  94. </div>
  95. {{/each}}
  96. </div>