jQuery(document).ready(function($) {
$('.work-time .closed').hide();
function convertTZ(date, tzString) {
return new Date((typeof date === "string" ? new Date(date) : date).toLocaleString("en-US", {timeZone: tzString}));
}
const date = new Date();
const convertedDate = convertTZ(date, "America/Los_Angeles");
let h = 100 * convertedDate.getHours() + convertedDate.getMinutes();
console.log(h);
let day = date.getDay();
if (day==0 || day==6){
if ((h >= 0 && h 1400 && h = 0 && h 1800 && h <= 2359)) {
$('.work-time .opened').toggle();
$('.work-time .closed').toggle();
console.log("working week");
}
});