Refactor home page layout (#6307)

* Refactor home page layout

Signed-off-by: Fanit Kolchina <kolchfa@amazon.com>

* Remove hover from last link

Signed-off-by: Fanit Kolchina <kolchfa@amazon.com>

---------

Signed-off-by: Fanit Kolchina <kolchfa@amazon.com>
This commit is contained in:
kolchfa-aws 2024-01-31 11:54:59 -05:00 committed by GitHub
parent acd5ba5ed1
commit 72c0ed10af
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
6 changed files with 14 additions and 13 deletions

View File

@ -5,7 +5,7 @@
<p class="banner-text-description">Learn to use OpenSearch, the highly scalable and extensible open-source software suite for search, analytics, observability, and other data-intensive applications.</p> <p class="banner-text-description">Learn to use OpenSearch, the highly scalable and extensible open-source software suite for search, analytics, observability, and other data-intensive applications.</p>
</div> </div>
<div> <div>
<button class="btn-contribute"><span>Contribute<svg width="20" viewBox="0 0 24 24"><use xlink:href="#svg-arrow-right"></use></svg></span></button> <button id="contribute" class="btn-contribute"><span>Contribute<svg width="20" viewBox="0 0 24 24"><use xlink:href="#svg-arrow-right"></use></svg></span></button>
</div> </div>
</header> </header>
</section> </section>

View File

@ -5,7 +5,7 @@
<a href="{{site.url}}{{site.baseurl}}/about/" class='card-link'></a> <a href="{{site.url}}{{site.baseurl}}/about/" class='card-link'></a>
<p class="heading">OpenSearch and OpenSearch Dashboards</p> <p class="heading">OpenSearch and OpenSearch Dashboards</p>
<p class="description">Learn how to power up your search</p> <p class="description">Learn how to power up your search</p>
<button class="last-link">Documentation &#x2192;</button> <p class="last-link">Documentation &#x2192;</p>
</div> </div>
@ -13,14 +13,14 @@
<a href="{{site.url}}/docs/latest/data-prepper/" class='card-link'></a> <a href="{{site.url}}/docs/latest/data-prepper/" class='card-link'></a>
<p class="heading">Data Prepper</p> <p class="heading">Data Prepper</p>
<p class="description">Prepare your data for OpenSearch</p> <p class="description">Prepare your data for OpenSearch</p>
<button class="last-link" >Documentation &#x2192;</button> <p class="last-link" >Documentation &#x2192;</p>
</div> </div>
<div class="card"> <div class="card">
<a href="{{site.url}}/docs/latest/clients/" class='card-link'></a> <a href="{{site.url}}/docs/latest/clients/" class='card-link'></a>
<p class="heading">Clients</p> <p class="heading">Clients</p>
<p class="description">OpenSearch in your programming language</p> <p class="description">OpenSearch in your programming language</p>
<button class="last-link">Documentation &#x2192;</button> <p class="last-link">Documentation &#x2192;</p>
</div> </div>
@ -28,7 +28,7 @@
<a href="{{site.url}}/docs/latest/benchmark/" class='card-link'></a> <a href="{{site.url}}/docs/latest/benchmark/" class='card-link'></a>
<p class="heading">Benchmark</p> <p class="heading">Benchmark</p>
<p class="description">Track OpenSearch performance</p> <p class="description">Track OpenSearch performance</p>
<button class="last-link">Documentation &#x2192;</button> <p class="last-link">Documentation &#x2192;</p>
</div> </div>
</div> </div>

View File

@ -31,6 +31,6 @@ layout: table_wrappers
{% include footer.html %} {% include footer.html %}
<script src="{{ '/assets/js/search.js' | relative_url }}"></script> <script src="{{ '/assets/js/search.js' | relative_url }}"></script>
<script src="{{ '/assets/js/listener.js' | relative_url }}"></script> <script src="{{ '/assets/js/home-listener.js' | relative_url }}"></script>
</body> </body>
</html> </html>

View File

@ -61,7 +61,6 @@
color: $blue-vibrant-300; color: $blue-vibrant-300;
} }
> .last-link { > .last-link {
transform: translateY(-1px);
text-decoration: underline; text-decoration: underline;
text-underline-offset: 3px; text-underline-offset: 3px;
} }
@ -145,7 +144,7 @@
} }
.banner-text-header { .banner-text-header {
font-size: 2.3rem; font-size: 2.1rem;
font-family: "Open Sans"; font-family: "Open Sans";
font-weight: 300; font-weight: 300;
@include mq(md) { @include mq(md) {
@ -154,12 +153,12 @@
} }
.banner-text-description { .banner-text-description {
font-size: 1.3rem; font-size: 1rem;
font-weight: 700; font-weight: 700;
font-style: normal; font-style: normal;
line-height: 2.25rem; line-height: 2.25rem;
@include mq(md) { @include mq(md) {
font-size: 1rem; font-size: 1.3rem;
} }
} }

View File

@ -0,0 +1,5 @@
const contributeButton = document.getElementById('contribute');
contributeButton.addEventListener('click', function(event) {
window.open('https://github.com/opensearch-project', '_blank');
});

View File

@ -28,9 +28,6 @@ document.addEventListener('click', function(event) {
else if (target.matches('.copy-button')) { else if (target.matches('.copy-button')) {
window.navigator.clipboard.writeText(target.getAttribute('data-text')); window.navigator.clipboard.writeText(target.getAttribute('data-text'));
} }
else if (target.matches('.btn-contribute')) {
window.open('https://github.com/opensearch-project', '_blank');
}
}); });
nav.addEventListener('scroll',(e)=>{ nav.addEventListener('scroll',(e)=>{