Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Backport 2.2] Refactor home page layout #6311

Merged
merged 1 commit into from
Jan 31, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion _includes/banner.html
Original file line number Diff line number Diff line change
Expand Up @@ -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>
</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>
</header>
</section>
8 changes: 4 additions & 4 deletions _includes/cards.html
Original file line number Diff line number Diff line change
Expand Up @@ -5,30 +5,30 @@
<a href="{{site.url}}{{site.baseurl}}/about/" class='card-link'></a>
<p class="heading">OpenSearch and OpenSearch Dashboards</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 class="card">
<a href="http://opensearch.org/docs/latest/data-prepper/" class='card-link'></a>
<p class="heading">Data Prepper</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 class="card">
<a href="http://opensearch.org/docs/latest/clients/" class='card-link'></a>
<p class="heading">Clients</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 class="card">
<a href="http://opensearch.org/docs/latest/benchmark/" class='card-link'></a>
<p class="heading">Benchmark</p>
<p class="description">Track OpenSearch performance</p>
<button class="last-link">Documentation &#x2192;</button>
<p class="last-link">Documentation &#x2192;</p>
</div>
</div>

Expand Down
2 changes: 1 addition & 1 deletion _layouts/home.html
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,6 @@

{% include footer.html %}
<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>
</html>
7 changes: 3 additions & 4 deletions _sass/_home.scss
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,6 @@
color: $blue-vibrant-300;
}
> .last-link {
transform: translateY(-1px);
text-decoration: underline;
text-underline-offset: 3px;
}
Expand Down Expand Up @@ -145,7 +144,7 @@
}

.banner-text-header {
font-size: 2.3rem;
font-size: 2.1rem;
font-family: "Open Sans";
font-weight: 300;
@include mq(md) {
Expand All @@ -154,12 +153,12 @@
}

.banner-text-description {
font-size: 1.3rem;
font-size: 1rem;
font-weight: 700;
font-style: normal;
line-height: 2.25rem;
@include mq(md) {
font-size: 1rem;
font-size: 1.3rem;
}
}

Expand Down
5 changes: 5 additions & 0 deletions assets/js/home-listener.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
const contributeButton = document.getElementById('contribute');

contributeButton.addEventListener('click', function(event) {
window.open('https://github.com/opensearch-project', '_blank');
});
3 changes: 0 additions & 3 deletions assets/js/listener.js
Original file line number Diff line number Diff line change
Expand Up @@ -28,9 +28,6 @@ document.addEventListener('click', function(event) {
else if (target.matches('.copy-button')) {
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)=>{
Expand Down
Loading