Skip to content

Commit

Permalink
fix: Search focus and sidebar menu icons
Browse files Browse the repository at this point in the history
  • Loading branch information
reinhart1010 authored Nov 23, 2022
1 parent 0a2c9f2 commit 50be8ac
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 7 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ gem "minima"
on your `Gemfile` with

```gemspec
gem "jekyll-ham", "~> 0.2.2"
gem "jekyll-ham", "~> 0.2.3"
```

Also don't forget to change the `theme` configuration on your `_config.yml` to `jekyll-ham` instead of `minima`.
Expand Down
4 changes: 2 additions & 2 deletions _includes/navbar.html
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<nav class="navbar">
<div class="navbar-content">
<button class="btn btn-action" type="button" onclick="halfmoon.toggleSidebar(); document.getElementById('search-input').focus()">
<button class="btn btn-action" type="button" onclick="halfmoon.toggleSidebar()">
<i class="bi bi-list ham-menu-button-icon-open" aria-hidden="true"></i>
<i class="bi bi-x-lg ham-menu-button-icon-close" aria-hidden="true"></i>
<span class="sr-only">Toggle sidebar</span>
Expand All @@ -19,7 +19,7 @@
<i class="bi bi-moon-stars" aria-hidden="true"></i>
<span class="sr-only">Toggle Dark Mode</span>
</button>
<a href="#search" class="btn btn-action btn-primary">
<a href="#search" class="btn btn-action btn-primary" onClick="document.getElementById('search-input').focus()">
<i class="bi bi-search" aria-hidden="true"></i>
<span class="sr-only">Search</span>
</a>
Expand Down
6 changes: 3 additions & 3 deletions assets/main.css
Original file line number Diff line number Diff line change
Expand Up @@ -9,14 +9,14 @@ body {
}

/* Custom icon for panel open and close */
.page-wrapper .ham-menu-button-icon-close {
.page-wrapper .ham-menu-button-icon-open {
display: none;
}
.page-wrapper[data-sidebar-hidden="hidden"] .ham-menu-button-icon-open {
display: none;
display: block;
}
.page-wrapper[data-sidebar-hidden="hidden"] .ham-menu-button-icon-close {
display: block;
display: none;
}


Expand Down
2 changes: 1 addition & 1 deletion jekyll-ham.gemspec
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

Gem::Specification.new do |spec|
spec.name = "jekyll-ham"
spec.version = "0.2.2"
spec.version = "0.2.3"
spec.authors = ["Reinhart Previano Koentjoro"]
spec.email = ["[email protected]"]

Expand Down

0 comments on commit 50be8ac

Please sign in to comment.