Skip to content

Commit

Permalink
Juju ecosystem docs refresh (#565)
Browse files Browse the repository at this point in the history
* create juju ecosystem docs page

* fix logo section

* add footer

* add missing footer links

* render docs page

* fix python lint

* add selected item in navigation

* add shallow section

* remove shallow strip

* add juju.is redirects

* change Observe link

* add search functionality

* fix requirements.txt

* fix hr on smaller screens

* allow async events in flask

* fix python linting

* fix async search event loop

* fix python linting

* replace async search with threadpool

* move Juju tutorial CTA

* add logging for debugging

* clean up logging logic

* add pagination and load more results button

* add spacing to search results

* add redirect for empty search and fix container styling

* combine api request for hosted docs

* fix formatting on mobile

* change link on search page to juju.is/docs
  • Loading branch information
abbiesims authored Feb 5, 2025
1 parent 9a70ca0 commit 9551e18
Show file tree
Hide file tree
Showing 13 changed files with 1,424 additions and 356 deletions.
535 changes: 535 additions & 0 deletions redirects.yaml

Large diffs are not rendered by default.

1 change: 1 addition & 0 deletions requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -11,3 +11,4 @@ requests==2.31.0
semver==3.0.2
cachetools==5.3.3
flask-cors==4.0.0
scikit-learn==1.6.1
29 changes: 28 additions & 1 deletion static/sass/styles.scss
Original file line number Diff line number Diff line change
Expand Up @@ -329,4 +329,31 @@ html {

strong {
font-weight: bold !important;
}
}

.p-image-container, [class^=p-image-container--] {
aspect-ratio: auto !important;
height: auto !important;
}

.p-image-container__image {
display: block;
}

@media (620px <= width < 1036px) {
.any-application-container img {
object-fit: cover;
object-position: center;
width: 100%;
height: 230px;
}
}

@media (width < 620px) {
.any-application-container img {
object-fit: cover;
object-position: center;
width: 100%;
height: 200px;
}
}
5 changes: 4 additions & 1 deletion templates/base.html
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,10 @@

{% block content %}{% endblock %}

{% include "footer.html" %}
{% block footer %}
{% include "footer.html" %}
{% endblock footer %}

{% endblock body %}

<div class="u-hide" id="contact-form-container" data-form-location="/get-in-touch" data-form-id="1337" data-lp-id="2313" data-return-url="http://juju.is/thank-you" data-lp-url=""></div>
Expand Down
25 changes: 22 additions & 3 deletions templates/docs/base.html
Original file line number Diff line number Diff line change
Expand Up @@ -13,9 +13,28 @@
<div class="l-docs__main">
<div class="row">
<form class="p-search-box u-no-margin--bottom" action="/docs/search">
<input type="search" class="p-search-box__input" name="q" {% if query %}value="{{ query }}"{% endif %} placeholder="Search documentation" required/>
<button type="button" class="p-search-box__reset" alt="reset" onclick="this.previousElementSibling.value = '';this.previousElementSibling.focus()"><i class="p-icon--close">Reset</i></button>
<button type="submit" class="p-search-box__button"><i class="p-icon--search">Search</i></button>
<input
type="search"
class="p-search-box__input"
name="q"
{% if query %}value="{{ query }}"{% endif %}
placeholder="Search documentation"
required
/>
<button
type="button"
class="p-search-box__reset"
alt="reset"
onclick="this.previousElementSibling.value = '';this.previousElementSibling.focus()"
>
<i class="p-icon--close">Reset</i>
</button>
<button
type="submit"
class="p-search-box__button"
>
<i class="p-icon--search">Search</i>
</button>
</form>
</div>
</div>
Expand Down
151 changes: 0 additions & 151 deletions templates/docs/document.html

This file was deleted.

Loading

0 comments on commit 9551e18

Please sign in to comment.