Skip to content

Commit

Permalink
Add files via upload
Browse files Browse the repository at this point in the history
  • Loading branch information
H21web authored Jun 24, 2024
1 parent 72a1fae commit f50ad2d
Show file tree
Hide file tree
Showing 11 changed files with 1,490 additions and 0 deletions.
14 changes: 14 additions & 0 deletions assets/js/apexcharts.js

Large diffs are not rendered by default.

7 changes: 7 additions & 0 deletions assets/js/bootstrap.bundle.min.js

Large diffs are not rendered by default.

51 changes: 51 additions & 0 deletions assets/js/custom-chart.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,51 @@
var options = {
series: [
{
name: "series1",
data: [31, 40, 28, 51, 42, 109, 100],
},
],

chart: {
foreColor: "#fff",
height: 350,
type: "area",
toolbar: {
show: false,
},
xaxis: {
foreColor: "#848485",
},
},
responsive: [{
breakpoint: 460,
options: {
chart: {
height: 200,
},
},
}],
dataLabels: {
enabled: false,
},
stroke: {
curve: "smooth",
colors: ["#205DEE"],
},
grid: {
show: false,
},

xaxis: {
type: "Months",
categories: ["Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sap", "Oct", "Nov", "Dec"],
},
tooltip: {
x: {
format: "dd/MM/yy HH:mm",
},
},
};

var chart = new ApexCharts(document.querySelector("#chart"), options);
chart.render();
7 changes: 7 additions & 0 deletions assets/js/custom-pikaday.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
var picker = new Pikaday({
field: document.getElementById("datepicker"),
firstDay: 1,
minDate: new Date(),
maxDate: new Date(2020, 12, 31),
yearRange: [2000, 2020],
});
32 changes: 32 additions & 0 deletions assets/js/custom-swiper.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
var sliderThree = new Swiper(".myswiper", {
slidesPerView: 3,
spaceBetween: 12,
loop: false,
pagination: {
el: ".swiper-pagination",
clickable: true,
},
});

var sliderTwo = new Swiper(".slider-2", {
slidesPerView: 2.3,
spaceBetween: 12,
loop: true,
pagination: {
el: ".swiper-pagination",
clickable: true,
},
});

var sliderOne = new Swiper(".slider-1", {
slidesPerView: 1,
pagination: {
el: ".swiper-pagination",
clickable: true,
},

navigation: {
nextEl: ".swiper-button-next",
prevEl: ".swiper-button-prev",
},
});
21 changes: 21 additions & 0 deletions assets/js/homescreen-popup.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
/*==========================
add to home screen popup js
==========================*/
let deferredPrompt;

window.addEventListener('beforeinstallprompt', (e) => {
deferredPrompt = e;
});

const installApp = document.getElementById('installApp');

installApp.addEventListener('click', async () => {
if (deferredPrompt !== null) {
deferredPrompt.prompt();
const { outcome } = await deferredPrompt.userChoice;
if (outcome === 'accepted') {
deferredPrompt = null;
}
}
});

8 changes: 8 additions & 0 deletions assets/js/offcanvas-popup.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
/*==========================
offcanvas js
==========================*/
window.addEventListener("load", (event) => {
var myOffcanvas = document.getElementById('offcanvas')
var bsOffcanvas = new bootstrap.Offcanvas(myOffcanvas)
bsOffcanvas.show()
});
29 changes: 29 additions & 0 deletions assets/js/otp.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
function getCodeBoxElement(index) {
return document.getElementById("five" + index);
}

function onKeyUpEvent(index, event) {
const eventCode = event.which || event.keyCode;
if (getCodeBoxElement(index).value.length === 1) {
if (index !== 5) {
getCodeBoxElement(index + 1).focus();
} else {
getCodeBoxElement(index).blur();
// Submit code
console.log("submit code ");
}
}
if (eventCode === 9 && index !== 1) {
getCodeBoxElement(index - 1).focus();
}
}

function onFocusEvent(index) {
for (item = 1; item < index; item++) {
const currentElement = getCodeBoxElement(item);
if (!currentElement.value) {
currentElement.focus();
break;
}
}
}
Loading

0 comments on commit f50ad2d

Please sign in to comment.