PageSourceSearch

https://kyoto-map.com/wp-content/themes/javo-directory/assets/js/javo-footer.js

js kyoto-map.com collected 2026-10-08 07:19:38 UTC 6,492 bytes, 216 lines download raw bytes

1;(function($){
2	jQuery('.javo-vc-row').each(function(){
3		var $this = $(this);
4		$this
5			.css('background-attachment', 'fixed')
6			.css('position', 'absolute');
7		if( typeof($this.data('background') ) != 'undefined') {
8			if( $this.data('background') != '' ){
9				$this.css({
10					'background-image':'url(' + $this.data('background') + ')'
11					, 'background-size':'cover'
12				});
13			};
14		};
15		if( typeof($this.data('background-color') ) != 'undefined') {
16			if( $this.data('background-color') != ''){
17				$this.css('background-color', $this.data('background-color'));
18			};
19		};
20		if( $this.data('background-type') != 'parallax') {
21			$this
22				.css('background-position', '0px 0px')
23				.css('background-attachment', '')
24		};
25
26		if(
27			typeof($this.data('box-shadow') ) != 'undefined' ||
28			typeof($this.data('box-shadow-color') ) != 'undefined'
29		) {
30			if( $this.data('box-shadow') == 'use' ){
31				$this.css('box-shadow', '0px 2px 5px '+ $this.data('box-shadow-color'));
32			};
33		};
34
35
36		var javo_row_resize = function (){
37			var w, h;
38			var $hWnd = $(window);
39			var content_wrap = {};
40			w = $hWnd.width();
41			$this
42				.css('min-width', w + 'px')
43				.css('width', w +'px')
44				.css('top', 0)
45				.css('left', -$this.closest('.vc_row-fluid').offset().left + 'px' )
46				.css('min-height', $this.closest('.vc_row-fluid').outerHeight() + 'px');
47			if( typeof( $this.data('target') ) != 'undefined' ){
48				if(
49					!(
50						$( $this.data('target') ).hasClass('single-item-intro') ||
51						$( $this.data('target') ).hasClass('single-item-navi')
52					) && $( $this.data('target') ).hasClass('javo-single-section')
53				){
54					content_wrap.minHeight = $(window).height() + 'px';
55					/*
56					$( $this.data('target') )
57						.find('.wpb_wrapper')
58						.css('min-height', $(window).height() + 'px');
59					*/
60				};
61			};
62			if( $this.data('content-full-width') == "yes" ){
63				content_wrap.position		= 'relative';
64				content_wrap.minWidth		= w + 'px';
65				content_wrap.width			= w + 'px';
66				content_wrap.top			= 0;
67				content_wrap.left			= -$this.closest('.vc_row-fluid').offset().left + 'px';
68				$this.parent().find('.wpb_column').css('padding', 0);
69
70
71
72				/*
73				$this.parent().find('.wpb_wrapper')
74					.css('position', 'relative')
75					.css('min-width', w + 'px')
76					.css('width', w +'px')
77					.css('top', 0)
78					.css('left', -$this.closest('.vc_row-fluid').offset().left + 'px');
79				*/
80			}
81			$this.parent().find('.vc_column_container > .wpb_wrapper').css(content_wrap);
82		};
83		$('.wpb_row').css({ position: 'relative' });
84		$('.upb_row_bg').css({
85			width:'100%'
86			, height:'100%'
87			, height:'100%'
88			, top: 0
89			, bottom: 0
90			, right: 0
91			, left: 0
92			, overflow: 'hidden'
93		});
94		javo_row_resize();
95		jQuery(window).resize(function(){
96			javo_row_resize();
97		});
98	});
99
100	// Wordpress media upload button command.
101	// Required: library/enqueue.php:  wp_media_enqueue();
102	$("body").on("click", ".javo-fileupload", function(e){
103		e.preventDefault();
104		var $this = $(this);
105		var file_frame;
106		if(file_frame){ file_frame.open(); return; }
107		file_frame = wp.media.frames.file_frame = wp.media({
108			title: $this.data('title'),
109			multiple: $this.data('multiple')
110		});
111		file_frame.on( 'select', function(){
112			var attachment;
113			if( $this.data('multiple') ){
114				var selection = file_frame.state().get( 'selection' );
115				selection.map(
116					function(attachment) {
117						var output = "";
118						attachment = attachment.toJSON();
119						output += "<div class='col-md-4 javo_dim_div'>";
120						output += "		<div class='col-md-12' style='overflow:hidden;'><img src='" + attachment.url + "' style='height:150px;'></div>";
121						output += "		<div class='row'><div class='col-md-12' align='center'>";
122						output += "			<input type='hidden' name='javo_dim_detail[]' value='" + attachment.id + "'>";
123						output += "			<input type='button' value='Delete' class='btn btn-danger btn-xs javo_detail_image_del'>";
124						output += "		</div>";
125						output += "</div>";
126						$( $this.data('preview') ).append( output );
127					}
128				);
129
130			}else{
131				attachment = file_frame.state().get('selection').first().toJSON();
132				$( $this.data('input')).val(attachment.id);
133				$( $this.data('preview') ).prop("src", attachment.url );
134			};
135		});
136		file_frame.open();
137		// Upload field reset button
138	}).on('click', '.javo-fileupload-cancel', function(){
139		$($(this).data('preview')).prop('src', '');
140		$($(this).data('input')).prop('value', '');
141	}).on("click", ".javo_detail_image_del", function(){
142		var tar = $(this).data("id");
143		$(this).parents(".javo_dim_div").remove();
144		$("input[name^='javo_dim_detail'][value='" + tar + "']").remove();
145	});
146	jQuery('.javo-color-picker').each(function(i, v){
147		$(this).spectrum({
148			clickoutFiresChange:true
149			, showInitial: true
150			, preferredFormat:'hex'
151			, showInput: true
152			, chooseText: 'Select'
153		});
154	});
155
156	var sns_con = { setTitle: "", setUrl: "",
157		getLink: function(d){
158			var url ="";
159			switch(d){
160				case "twitter":
161					url = "http://twitter.com/share?url=" + this.setUrl + "&text=" + this.setTitle; break;
162				case "facebook":
163					url = "http://www.facebook.com/sharer.php?u=" + this.setUrl + "&t=" + this.setTitle; break;
164				case "google":
165					url = "https://plus.google.com/share?url=" + this.setUrl;break;
166				default:
167					alert("Error");
168					return false;
169			};
170			window.open(url);
171		}
172	};
173	$("body").on("click", "i.sns-facebook", function(){
174		sns_con.setTitle = $(this).data("title");
175		sns_con.setUrl = $(this).data("url");
176		sns_con.getLink("facebook");
177	});
178	$("body").on("click", "i.sns-twitter", function(){
179		sns_con.setTitle = $(this).data("title");
180		sns_con.setUrl = $(this).data("url");
181		sns_con.getLink("twitter");
182	});
183	$("body").on("click", "i.sns-google", function(){
184		sns_con.setTitle = $(this).data("title");
185		sns_con.setUrl = $(this).data("url");
186		sns_con.getLink("google");
187	});
188	$('.javo-tooltip').each(function(i, e){
189		var options = {};
190		if( typeof( $(this).data('direction') ) != 'undefined' ){
191			options.placement = $(this).data('direction');
192		};
193		$(this).tooltip(options);
194	});
195
196	$(window).scroll(function () {
197		if ($(this).scrollTop() > 50) {
198			$('#back-to-top').fadeIn();
199		} else {
200			$('#back-to-top').fadeOut();
201		}
202		});
203		// scroll body to 0px on click
204		$('#back-to-top').click(function () {
205			$('#back-to-top').tooltip('hide');
206			$('body,html').animate({
207			scrollTop: 0
208		}, 800);
209		return false;
210	});
211
212
213	$(window).load(function(){
214		$(this).trigger('resize');
215	});
216})(jQuery);

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.