generated from just-the-docs/just-the-docs-template
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #26 from SVUIT/UI
UI
- Loading branch information
Showing
9 changed files
with
120 additions
and
11 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
<nav aria-label="Auxiliary" class="aux-nav"> | ||
<ul class="aux-nav-list"> | ||
{% for link in site.aux_links %} | ||
<li class="aux-nav-list-item"> | ||
<a href="{{ link.last }}" class="site-button" | ||
{% if site.aux_links_new_tab %} | ||
target="_blank" rel="noopener noreferrer" | ||
{% endif %} | ||
> | ||
{{ link.first }} | ||
</a> | ||
</li> | ||
{% endfor %} | ||
|
||
{% include components/switchTheme.html %} | ||
</ul> | ||
</nav> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
<div class="dm-container"> | ||
<input type="checkbox" class="checkbox js-toggle-dark-mode" id="checkbox"> | ||
<label for="checkbox" class="checkbox-label"> | ||
<i class="fa-solid fa-sun"></i> | ||
<i class="fa-solid fa-moon"></i> | ||
<span class="ball"></span> | ||
</label> | ||
</div> | ||
<script> | ||
const toggleDarkMode = document.querySelector('.js-toggle-dark-mode'); | ||
const cbLabel = document.querySelector('.checkbox-label'); | ||
jtd.addEvent(toggleDarkMode, 'click', function(){ | ||
if (jtd.getTheme() === 'dark') { | ||
jtd.setTheme('light'); | ||
cbLabel.style.backgroundColor = '#44434d'; | ||
} else { | ||
cbLabel.style.backgroundColor = '#000000'; | ||
jtd.setTheme('dark'); | ||
} | ||
}); | ||
</script> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
<script src="https://kit.fontawesome.com/cdf299865b.js" crossorigin="anonymous"></script> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,59 @@ | ||
@import url("https://fonts.googleapis.com/css2?family=Montserrat&display=swap"); | ||
|
||
|
||
.dm-container { | ||
font-family: "Montserrat", sans-serif; | ||
display: flex; | ||
justify-content: center; | ||
align-items: center; | ||
flex-direction: column; | ||
text-align: center; | ||
margin: 0; | ||
transition: background 0.2s linear; | ||
} | ||
|
||
.dm-container.dark {background-color: #292c35;} /* #9b59b6 */ | ||
|
||
.dm-container.dark h1, .dm-container.dark .support a {color: #fff;} | ||
|
||
.dm-container .checkbox { | ||
opacity: 0; | ||
position: absolute; | ||
} | ||
|
||
.dm-container .checkbox-label { | ||
background-color: #44434d; | ||
width: 50px; | ||
height: 26px; | ||
border-radius: 50px; | ||
position: relative; | ||
padding: 5px; | ||
cursor: pointer; | ||
display: flex; | ||
justify-content: space-between; | ||
align-items: center; | ||
} | ||
|
||
.dm-container .fa-moon {color: #fff200;font-size: 15px;} | ||
|
||
.dm-container .fa-sun {color: #f39c12;font-size: 15px;} | ||
|
||
.dm-container .checkbox-label .ball { | ||
background-color: #fff; | ||
width: 22px; | ||
height: 22px; | ||
position: absolute; | ||
left: 2px; | ||
top: 2px; | ||
border-radius: 50%; | ||
transition: transform 0.2s linear; | ||
} | ||
|
||
.dm-container .checkbox:checked + .checkbox-label .ball { | ||
transform: translateX(24px); | ||
} | ||
|
||
.aux-nav .aux-nav-list { | ||
margin-right: 20px; | ||
justify-content: space-between; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
$pink-000: #f77ef1; | ||
$pink-100: #f967f1; | ||
$pink-200: #e94ee1; | ||
$pink-300: #dd2cd4; | ||
$darkblue-000: #88a8ff; | ||
$darkblue-100: #608aff; | ||
$darkblue-200: #4577ff; | ||
$darkblue-300: #386dff; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters