Commit 5a27c534 authored by Corentin Mors's avatar Corentin Mors
Browse files

Add moon logo to project

parent 51af204a
$("#darkButton").click(function(){$("body").hasClass("dark")?$("body").removeClass("dark"):$("body").addClass("dark")}),$(document).ready(function(){var a=new Date;$("#live-hour").html("<i class='far fa-clock'></i> "+a);var o=a.getHours();(o>17||o<8)&&$("body").addClass("dark")}),$(document).ready(function(){$("#sidebar").mCustomScrollbar({theme:"minimal"}),$("#sidebarCollapse").on("click",function(){$("#sidebar, #content").toggleClass("active"),$(".collapse.in").toggleClass("in"),$("a[aria-expanded=true]").attr("aria-expanded","false")})}),$(document).ready(function(){var a,o,e;if("geolocation"in navigator){navigator.geolocation.getCurrentPosition(function(t){a=t.coords.latitude,o=t.coords.longitude,e="https://api.openweathermap.org/data/2.5/weather?lat="+a+"&lon="+o+"&units=metric&appid=b231606340553d9174136f7f083904b3",$.ajax({url:e,method:"GET",success:function(a){var o=a.main.temp,e=a.name;a.weather.description;$("#live-weather").html(o+"°C in "+e)}})})}else console.log("Your browser doesn't support geolocation. Sorry.")});
\ No newline at end of file
$("#darkButton").click(function(){$("body").hasClass("dark")?($("body").removeClass("dark"),$("#xcockpit_logo").attr("src","/assets/img/Logo_X-Cockpit_earth.svg")):($("body").addClass("dark"),$("#xcockpit_logo").attr("src","/assets/img/Logo_X-Cockpit_moon.svg"))}),$(document).ready(function(){var o=new Date;$("#live-hour").html("<i class='far fa-clock'></i> "+o);var a=o.getHours();(a>17||a<8)&&($("body").addClass("dark"),$("#xcockpit_logo").attr("src","/assets/img/Logo_X-Cockpit_moon.svg"))}),$(document).ready(function(){$("#sidebar").mCustomScrollbar({theme:"minimal"}),$("#sidebarCollapse").on("click",function(){$("#sidebar, #content").toggleClass("active"),$(".collapse.in").toggleClass("in"),$("a[aria-expanded=true]").attr("aria-expanded","false")})}),$(document).ready(function(){var o,a,t;if("geolocation"in navigator){navigator.geolocation.getCurrentPosition(function(e){o=e.coords.latitude,a=e.coords.longitude,t="https://api.openweathermap.org/data/2.5/weather?lat="+o+"&lon="+a+"&units=metric&appid=b231606340553d9174136f7f083904b3",$.ajax({url:t,method:"GET",success:function(o){var a=o.main.temp,t=o.name;o.weather.description;$("#live-weather").html(a+"°C in "+t)}})})}else console.log("Your browser doesn't support geolocation. Sorry.")});
\ No newline at end of file
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 479.44 472"><defs><style>.cls-1{isolation:isolate;}.cls-2{fill:#fafbfb;}.cls-3{fill:#e0e0e0;}.cls-4{fill:#bdbdbd;}.cls-5{fill:#f5f5f5;}.cls-6{fill:#212121;opacity:0.1;mix-blend-mode:multiply;}.cls-7{fill:#707070;}</style></defs><title>Logo_X-Cockpit_moon</title><g class="cls-1"><g id="Logo"><g id="Lune"><circle class="cls-2" cx="212" cy="260" r="212"/><circle class="cls-3" cx="78.61" cy="184.11" r="33.37"/><path class="cls-4" d="M108.37,251a33.36,33.36,0,0,1,55.5-25,33.37,33.37,0,1,0-47.1,47.1A33.24,33.24,0,0,1,108.37,251Z" transform="translate(-60.28 -64)"/><path class="cls-5" d="M140.2,214.73l-.66,0a33.37,33.37,0,1,1-34,34c0,.22,0,.44,0,.66a34.69,34.69,0,1,0,34.69-34.69Z" transform="translate(-60.28 -64)"/><circle class="cls-3" cx="300.25" cy="125.64" r="16.69"/><path class="cls-4" d="M345.27,191.06A16.68,16.68,0,0,1,373,178.58a16.68,16.68,0,1,0-23.55,23.55A16.62,16.62,0,0,1,345.27,191.06Z" transform="translate(-60.28 -64)"/><path class="cls-5" d="M361.19,173h-.33a16.68,16.68,0,1,1-17,17c0,.11,0,.22,0,.33A17.34,17.34,0,1,0,361.19,173Z" transform="translate(-60.28 -64)"/><circle class="cls-3" cx="358.65" cy="294.87" r="41.64"/><path class="cls-4" d="M380.85,362.43a41.63,41.63,0,0,1,69.24-31.16A41.63,41.63,0,1,0,391.32,390,41.47,41.47,0,0,1,380.85,362.43Z" transform="translate(-60.28 -64)"/><path class="cls-5" d="M420.57,317.23l-.82,0a41.63,41.63,0,1,1-42.44,42.44c0,.27,0,.55,0,.82a43.28,43.28,0,1,0,43.28-43.28Z" transform="translate(-60.28 -64)"/><circle class="cls-3" cx="247.38" cy="392.15" r="41.64"/><path class="cls-4" d="M269.58,459.71a41.63,41.63,0,0,1,69.24-31.16,41.63,41.63,0,1,0-58.77,58.77A41.47,41.47,0,0,1,269.58,459.71Z" transform="translate(-60.28 -64)"/><path class="cls-5" d="M309.3,414.51l-.82,0A41.63,41.63,0,1,1,266,457c0,.27,0,.55,0,.82a43.28,43.28,0,1,0,43.28-43.28Z" transform="translate(-60.28 -64)"/><circle class="cls-3" cx="164.95" cy="366.85" r="23.45"/><path class="cls-4" d="M203.78,432.86a23.44,23.44,0,0,1,39-17.55,23.44,23.44,0,1,0-33.09,33.09A23.35,23.35,0,0,1,203.78,432.86Z" transform="translate(-60.28 -64)"/><path class="cls-5" d="M226.15,407.4h-.46a23.44,23.44,0,1,1-23.9,23.9c0,.15,0,.31,0,.46a24.37,24.37,0,1,0,24.37-24.37Z" transform="translate(-60.28 -64)"/><circle class="cls-3" cx="208.56" cy="334.42" r="14.19"/><path class="cls-4" d="M255.86,399.64A14.19,14.19,0,0,1,279.46,389a14.19,14.19,0,1,0-20,20A14.14,14.14,0,0,1,255.86,399.64Z" transform="translate(-60.28 -64)"/><path class="cls-5" d="M269.4,384.23h-.28a14.19,14.19,0,1,1-14.47,14.47c0,.09,0,.19,0,.28a14.75,14.75,0,1,0,14.75-14.75Z" transform="translate(-60.28 -64)"/><circle class="cls-3" cx="397.1" cy="236.05" r="16.05"/><path class="cls-4" d="M442.7,301.42a16,16,0,0,1,26.69-12,16,16,0,1,0-22.66,22.66A16,16,0,0,1,442.7,301.42Z" transform="translate(-60.28 -64)"/><path class="cls-5" d="M458,284h-.32a16.05,16.05,0,1,1-16.36,16.36c0,.11,0,.21,0,.32A16.69,16.69,0,1,0,458,284Z" transform="translate(-60.28 -64)"/><circle class="cls-3" cx="99.99" cy="255.91" r="21.16"/><path class="cls-4" d="M140.91,321.72a21.16,21.16,0,0,1,35.19-15.84,21.16,21.16,0,1,0-29.87,29.87A21.08,21.08,0,0,1,140.91,321.72Z" transform="translate(-60.28 -64)"/><path class="cls-5" d="M161.1,298.75h-.42a21.16,21.16,0,1,1-21.57,21.57c0,.14,0,.28,0,.42a22,22,0,1,0,22-22Z" transform="translate(-60.28 -64)"/><circle class="cls-3" cx="148.14" cy="178.71" r="17.73"/><path class="cls-4" d="M192.21,244.23A17.73,17.73,0,0,1,221.69,231a17.73,17.73,0,1,0-25,25A17.66,17.66,0,0,1,192.21,244.23Z" transform="translate(-60.28 -64)"/><path class="cls-5" d="M209.12,225h-.35a17.73,17.73,0,1,1-18.07,18.07c0,.12,0,.23,0,.35A18.43,18.43,0,1,0,209.12,225Z" transform="translate(-60.28 -64)"/><circle class="cls-3" cx="116.19" cy="379.25" r="11.96"/><path class="cls-4" d="M165.53,444.27a12,12,0,0,1,19.88-8.95,12,12,0,1,0-16.88,16.88A11.91,11.91,0,0,1,165.53,444.27Z" transform="translate(-60.28 -64)"/><path class="cls-5" d="M176.94,431.29h-.24a12,12,0,1,1-12.19,12.19c0,.08,0,.16,0,.24a12.43,12.43,0,1,0,12.43-12.43Z" transform="translate(-60.28 -64)"/><path class="cls-6" d="M272.28,445.59C177.43,445.59,96,388.06,61,306c-.5,5.94-.77,11.94-.77,18,0,117.08,94.92,212,212,212s212-94.92,212-212c0-6.07-.27-12.07-.77-18C448.53,388.06,367.13,445.59,272.28,445.59Z" transform="translate(-60.28 -64)"/><path class="cls-6" d="M272.28,493.84A236.24,236.24,0,0,1,65.92,372.75C87.94,466.33,172,536,272.28,536s184.33-69.67,206.36-163.25A236.24,236.24,0,0,1,272.28,493.84Z" transform="translate(-60.28 -64)"/></g><path id="X" class="cls-7" d="M494.09,140.06H425.63l-49.77,61.25L288.73,64H220.28l117,184.65L227.88,383.44h68.45l71.12-87.53L471.27,459.5h68.45L406.06,248.79Z" transform="translate(-60.28 -64)"/></g></g></svg>
\ No newline at end of file
......@@ -5,10 +5,14 @@
/** Enable dark theme */
$("#darkButton").click(function(){
if ($("body").hasClass("dark"))
$("body").removeClass("dark")
else
$("body").addClass("dark")
if ($("body").hasClass("dark")){
$("body").removeClass("dark");
$("#xcockpit_logo").attr("src","/assets/img/Logo_X-Cockpit_earth.svg");
}
else{
$("body").addClass("dark");
$("#xcockpit_logo").attr("src","/assets/img/Logo_X-Cockpit_moon.svg");
}
});
$(document).ready(function () {
......@@ -17,7 +21,8 @@ $(document).ready(function () {
var n = d.getHours();
if(n > 17 || n < 8){
$("body").addClass("dark")
$("body").addClass("dark");
$("#xcockpit_logo").attr("src","/assets/img/Logo_X-Cockpit_moon.svg");
}
});
......
......@@ -30,6 +30,7 @@
<nav id="sidebar">
<div class="sidebar-header">
<img
id="xcockpit_logo"
src="/assets/img/Logo_X-Cockpit_earth.svg"
alt="Logo X-Cockpit"
height="100px"
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment