1// ******************************************************************** 2// ã¯ãªãã«ãã«ãããã«é¢ããå¦ç 3// ******************************************************************** 4 5$(function () { 6 // 宿°å®£è¨ 7 const DEFAULT_IMG_PATH = "/img/home/floor/floor_all.png"; 8 const FADEOUT_WAIT = 400; 9 10 // è¦ç´ ã®ãã£ãã·ã¥ 11 let $pc_map_img_cont = $("#map_img"); 12 let $sp_map_img_cont = $("#js-modal-img"); 13 let $sp_modal = $("#floor-modal"); 14 15 // ã¢ã¼ãã«ãéããå¦ç 16 function modalClose() { 17 $("#floor-modal").removeClass("-visible"); 18 setTimeout(function () { 19 $sp_map_img_cont.attr("src", ""); 20 }, FADEOUT_WAIT); 21 } 22 23 // ******************************************************************** 24 // PCã®ã¨ã 25 // ******************************************************************** 26 $sp_map_img_cont.attr("src", ""); 27 28 $('map[name="ImageMap"] area').hover( 29 // ãã¦ã¹ãä¹ã£ãæã®å¦ç 30 function () { 31 // ããã¼æã®ç»åããããªãå·®ãæ¿ãã 32 $pc_map_img_cont.attr( 33 "src", 34 "/img/home/floor/room_" + $(this).data("area-name") + ".png" 35 ); 36 }, 37 // ãã¦ã¹ãä¸ããã¨ãã®å¦ç 38 function () { 39 $pc_map_img_cont.attr("src", DEFAULT_IMG_PATH); 40 } 41 ); 42 43 // ******************************************************************** 44 // SPã®æ 45 // ******************************************************************** 46 $('map[name="ImageMap-sp"] area').on("click", function () { 47 if (!$sp_modal.hasClass("-visible")) { 48 const img_path = $(this).attr("data-img-sp"); 49 $sp_map_img_cont.attr("src", img_path); 50 51 // ç»åãèªã¿è¾¼ã¿çµããã®ãå¾ ã¤ 52 $sp_map_img_cont.bind("load", function () { 53 $($sp_modal).addClass("-visible"); 54 }); 55 } 56 }); 57 58 // ã¢ã¼ãã«å¤ãã¿ããããããéãã 59 $($sp_modal).on("click", function () { 60 if ($(this).hasClass("-visible")) { 61 modalClose(); 62 } 63 }); 64 65 // ã¢ã¼ãã«å ãã¿ãããããæã¯éããªã 66 $("#js-modal-panel").on("click", function (e) { 67 e.stopPropagation(); 68 }); 69 70 // éãããã¿ã³ãã¿ããããããéãã 71 $("#js-modal-close").on("click", function () { 72 modalClose(); 73 }); 74});
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.