Skip to content

Commit

Permalink
update style
Browse files Browse the repository at this point in the history
  • Loading branch information
punkestu committed Oct 4, 2024
1 parent 91e1d39 commit 9bf21ae
Showing 1 changed file with 2 additions and 29 deletions.
31 changes: 2 additions & 29 deletions resources/views/rotasi/denah/index.blade.php
Original file line number Diff line number Diff line change
Expand Up @@ -167,35 +167,6 @@ function openSummaryCabang() {
document.querySelector('#tab-cabang #list').addEventListener('click', openListCabang);
document.querySelector('#tab-cabang #summary').addEventListener('click', openSummaryCabang);
</script>
<script>
var currentPage = 0;
const mapContainer = document.getElementById('map');
const bannerContainer = document.querySelector('#banner-img');
const mapShowBtn = document.getElementById('map-show-btn');
const bannerShowBtn = document.getElementById('banner-show-btn');
mapShowBtn.addEventListener('click', () => {
if (currentPage !== 0) {
mapContainer.classList.remove('w-0');
mapContainer.classList.add('w-full');
bannerContainer.classList.remove('w-full');
bannerContainer.classList.add('w-0');
currentPage = 0;
mapShowBtn.classList.add('bg-[#003285]');
bannerShowBtn.classList.remove('bg-[#003285]');
}
});
bannerShowBtn.addEventListener('click', () => {
if (currentPage !== 1) {
mapContainer.classList.add('w-0');
mapContainer.classList.remove('w-full');
bannerContainer.classList.add('w-full');
bannerContainer.classList.remove('w-0');
currentPage = 1;
mapShowBtn.classList.remove('bg-[#003285]');
bannerShowBtn.classList.add('bg-[#003285]');
}
});
</script>
<script>
// set data to aside cabang's summary
function setCabang(cabang) {
Expand Down Expand Up @@ -226,9 +197,11 @@ function bindCabangItemClick() {
cabangItem.addEventListener('click', () => {
if (activated) {
activated.classList.remove('bg-[#003285]');
activated.classList.remove('text-white');
activated.classList.add('bg-white');
}
cabangItem.classList.add('bg-[#003285]');
cabangItem.classList.add('text-white');
cabangItem.classList.remove('bg-white');
activated = cabangItem;
fetch(`/api/rotasi/cabang-summary/${cabangItem.value}`)
Expand Down

0 comments on commit 9bf21ae

Please sign in to comment.