v0.6.0 - Darkmode
This commit is contained in:
@@ -40,18 +40,37 @@
|
||||
@endsection
|
||||
|
||||
@section("scripts")
|
||||
<script>
|
||||
function show($passID, $faID) {
|
||||
var inputPass = document.getElementById($passID);
|
||||
var faEye = document.getElementById($faID);
|
||||
@if(request()->cookie("mode") == "dark")
|
||||
<script>
|
||||
function show($passID, $faID) {
|
||||
var inputPass = document.getElementById($passID);
|
||||
var faEye = document.getElementById($faID);
|
||||
|
||||
if (inputPass.type === "password") {
|
||||
inputPass.type = "text";
|
||||
faEye.style.color = "#000";
|
||||
} else {
|
||||
inputPass.type = "password";
|
||||
faEye.style.color = "#808080";
|
||||
|
||||
if (inputPass.type === "password") {
|
||||
inputPass.type = "text";
|
||||
faEye.style.color = "#333333";
|
||||
} else {
|
||||
inputPass.type = "password";
|
||||
faEye.style.color = "#ffffff";
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
</script>
|
||||
@else
|
||||
<script>
|
||||
function show($passID, $faID) {
|
||||
var inputPass = document.getElementById($passID);
|
||||
var faEye = document.getElementById($faID);
|
||||
|
||||
|
||||
if (inputPass.type === "password") {
|
||||
inputPass.type = "text";
|
||||
faEye.style.color = "#333333";
|
||||
} else {
|
||||
inputPass.type = "password";
|
||||
faEye.style.color = "#808080";
|
||||
}
|
||||
}
|
||||
</script>
|
||||
@endif
|
||||
@endsection
|
||||
|
||||
Reference in New Issue
Block a user