PageSourceSearch

https://www.greendiamond.com/_js/share.js

js greendiamond.com collected 2026-10-02 07:44:45 UTC 1,147 bytes, 43 lines download raw bytes

1
2var shareJS = {
3	init: function() {
4		var checkShare = $('.share').length;
5
6		if ( checkShare > 0 ) {
7			gsap.to('.share', 0.4, { opacity: 1 });
8		}
9
10		shareJS.shareLinks();
11	},
12
13	socialWindow: function(url) {
14		var left = (screen.width - 570) / 2;
15		var top = (screen.height - 570) / 2;
16		var params = "menubar=no,toolbar=no,status=no,width=570,height=570,top=" + top + ",left=" + left;
17		window.open(url,'NewWindow',params);
18	},
19
20	shareLinks: function() {
21		var pageUrl = encodeURIComponent(document.URL);
22
23		$('.share__icon--facebook').on('click', function(e) {
24			e.preventDefault();
25			url = 'https://www.facebook.com/sharer.php?u=' + pageUrl;
26			shareJS.socialWindow(url);
27		});
28
29		$('.share__icon--twitter').on('click', function(e) {
30			e.preventDefault();
31			// var tweet = $(this).attr('data-id');
32			url = 'https://twitter.com/intent/tweet?url=' + pageUrl + '&text=Check+out+this+link: ';
33			shareJS.socialWindow(url);
34		});
35
36		$('.share__icon--linkedin').on('click', function(e) {
37			e.preventDefault();
38			url = 'https://www.linkedin.com/shareArticle?mini=true&url=' + pageUrl;
39			shareJS.socialWindow(url);
40		})
41	}
42}
43shareJS.init();

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.