PageSourceSearch

https://www.master-service.ru/local/templates/ms-local/js/script.js?174893177828184

js master-service.ru collected 2026-10-07 21:58:11 UTC 28,184 bytes, 531 lines download raw bytes

1var _alloka = {
2    objects: {
3        'ed3e74480f26b08d': {
4            block_class: 'phone_alloka',
5            format: '<span class="c1">+7 #{XXX}</span> <span class="c2">#{XXX}-#{XX}-#{XX}</span>'
6        }
7    },
8    trackable_source_types: ['typein', 'referrer', 'utm'],
9    last_source: false,
10    roistat_alloka_oid: 'ed3e74480f26b08d'
11};
12
13var default_msg = {
14    'name': 'Напишите ваше имя',
15    'phone': 'Телефон, включая код оператора',
16    'email': 'Электронный адрес'
17};
18
19jQuery(document).ready(function () {
20    jQuery("html").addClass(isBrowser.any().toLowerCase());
21    jQuery("html").addClass(isOS.name.toLowerCase());
22    // console.log(navigator.userAgent);
23    jQuery('.wrap .main .bottom .td.right .social .icon_wrap').mouseenter(function () {
24        jQuery(this).find('.icon').addClass('act');
25    });
26    jQuery('.wrap .main .bottom .td.right .social .icon_wrap').mouseleave(function () {
27        jQuery(this).find('.icon').removeClass('act');
28    });
29    jQuery('.wrap .main .bottom .td.right .social .icon_wrap.vk').click(function () {
30        window.open('http://vk.com/akimenkov_ru');
31    });
32    jQuery('.wrap .main .bottom .td.right .social .icon_wrap.inst').click(function () {
33        window.open('http://instagram.com/akimenkov.ru');
34    });
35    jQuery('.wrap .main .bottom .td.right .social .icon_wrap.houzz').click(function () {
36        window.open('http://www.houzz.com/pro/akimenkov/');
37    });
38    jQuery('.wrap .main .bottom .td.right .social .icon_wrap.pint').click(function () {
39        window.open('https://ru.pinterest.com/akimenkov_ru/');
40    });
41    jQuery('.wrap .main .bottom .td.right .social .icon_wrap.youtube').click(function () {
42        window.open('https://www.youtube.com/channel/UC0Ba5Y5229S9OnaYUfUGi9w');
43    });
44    jQuery('.wrap .main .content.mp .td.left .lmenu .block.bl1 .pic').click(function () {
45        window.location.href = '/gallery/';
46    });
47    jQuery('.wrap .main .content.mp .td.left .lmenu .block.bl2 .pic').click(function () {
48        window.location.href = '/price/price/?SECTION_ID=346';
49    });
50    jQuery('.wrap .main .content.mp .td.left .lmenu .block.bl3 .pic').click(function () {
51        window.location.href = '/design/agreement/';
52    });
53    jQuery('.wrap .main .top .pal .logo img').click(function () {
54        window.location.href = '/';
55    });
56    jQuery('a.n_photo').fancybox({
57        type: 'image',
58        padding: 5,
59        margin: 0,
60        autoSize: true,
61        minWidth: 1,
62        minHeight: 1,
63        scrolling: 'no',
64        loop: false,
65        nextEffect: 'fade',
66        prevEffect: 'fade',
67        closeBtn: false,
68        helpers: {
69            overlay: {
70                locked: false
71            },
72            showEarly: false
73        }
74    });
75    /*jQuery('.pr_list .items .item').mouseenter(function () {
76        jQuery(this).find('.link').fadeToggle(200);
77    });
78    jQuery('.pr_list .items .item').mouseleave(function () {
79        jQuery(this).find('.link').fadeToggle(200);
80    });*/
81    jQuery('#faq_add').click(function () {
82        jQuery.fancybox.open({
83            content: '<div class="_popup">' +
84                '<div class="r header">Спасибо! Ваш вопрос отправлен</div>' +
85                '<div class="r res">Мы постараемся дать ответ на Ваш вопрос как можно скорее. Наши специалисты работают в будни с 10:00 до 20:00, в выходные и праздничные дни &mdash; с 11:00 до 18:00</div>' +
86                '<div class="f header">Задайте свой вопрос</div>' +
87                '<div class="close"></div>' +
88                '<div class="f field"><div class="txt">Как к Вам обращаться?</div><div class="input name"><input type="text" value="' + default_msg['name'] + '" /></div>' +
89                '<div class="txt">Ваши контактные данные</div><div class="input cont"><div class="lt"><input type="text" value="' + default_msg['phone'] + '" /></div><div class="rt"><input type="text" value="' + default_msg['email'] + '" /></div></div>' +
90                '<div class="txt">Ваш вопрос</div><div class="input faq"><textarea cols="1" rows="1"></textarea></div>' +
91                '<div class="f note"><!--Все поля формы обязательны для заполнения--></div></div>' +
92                '<div class="f btn"><input type="button" class="button" value="Отправить" /></div>' +
93                '</div>',
94            padding: 0,
95            margin: 0,
96            autoSize: true,
97            minWidth: 1,
98            minHeight: 1,
99            scrolling: 'no',
100            loop: false,
101            nextEffect: 'fade',
102            prevEffect: 'fade',
103            closeBtn: false,
104            modal: true,
105            helpers: {
106                overlay: {
107                    locked: false
108                },
109                showEarly: false
110            },
111            beforeShow: function () {
112                jQuery('body').delegate('._popup .close', 'click', function () {
113                    jQuery.fancybox.close();
114                });
115                jQuery('body').delegate('._popup .input.name input', 'focus', function () {
116                    if (jQuery.trim(jQuery(this).val()) == default_msg['name']) {
117                        jQuery(this).addClass('active');
118                        jQuery(this).val('');
119                    }
120                });
121                jQuery('body').delegate('._popup .input.name input', 'blur', function () {
122                    if (jQuery.trim(jQuery(this).val()) == '') {
123                        jQuery(this).removeClass('active');
124                        jQuery(this).val(default_msg['name']);
125                    }
126                });
127                jQuery('body').delegate('._popup .input.cont .lt input', 'focus', function () {
128                    if (jQuery.trim(jQuery(this).val()) == default_msg['phone']) {
129                        jQuery(this).addClass('active');
130                        jQuery(this).val('').inputmask('+7 (999) 999-99-99');
131                    }
132                });
133                jQuery('body').delegate('._popup .input.cont .lt input', 'blur', function () {
134                    if (jQuery.trim(jQuery(this).val()) == '') {
135                        jQuery(this).removeClass('active');
136                        jQuery(this).inputmask('remove').val(default_msg['phone']);
137                    }
138                });
139                jQuery('body').delegate('._popup .input.cont .rt input', 'focus', function () {
140                    if (jQuery.trim(jQuery(this).val()) == default_msg['email']) {
141                        jQuery(this).addClass('active');
142                        jQuery(this).val('');
143                    }
144                });
145                jQuery('body').delegate('._popup .input.cont .rt input', 'blur', function () {
146                    if (jQuery.trim(jQuery(this).val()) == '') {
147                        jQuery(this).removeClass('active');
148                        jQuery(this).val(default_msg['email']);
149                    }
150                });
151                jQuery('body').delegate('._popup .btn input', 'click', function () {
152                    var name = jQuery.trim(jQuery('._popup .input.name input').val()),
153                        number = jQuery.trim(jQuery('._popup .input.cont .lt input').val()),
154                        email = jQuery.trim(jQuery('._popup .input.cont .rt input').val()),
155                        question = jQuery.trim(jQuery('._popup .input.faq textarea').val());
156                    if (number == default_msg['phone']) {
157                        number = '';
158                    }
159                    if (email == default_msg['email']) {
160                        email = '';
161                    }
162                    if ((name.length == 0) || ((number.length == 0) && (email.length == 0)) || (question.length == 0)) {
163                        alert('Пожалуйста, заполните все поля формы!');
164                        return false;
165                    }
166                    if ((email.length > 0) && !isEmail(email)) {
167                        alert('Неверный e-mail!');
168                        return false;
169                    }
170                    jQuery.ajax({
171                        type: "POST",
172                        url: "/bitrix/ajax.php",
173                        dataType: "text",
174                        data: ({
175                            session: session,
176                            mode: 6,
177                            name: name,
178                            phone: number,
179                            email: email,
180                            question: question
181                        }),
182                        success: function (data) {
183                            if (data == 0) {
184                                alert('К сожалению, ваш вопрос не удалось отправить!')
185                                return false;
186                            }
187                            //yaCounter15339196.reachGoal('zayavka');
188                            //ga('send', 'event', 'knopka', 'zayavka');
189                            jQuery('._popup .f').hide();
190                            jQuery('._popup .r').fadeIn('fast');
191                        }
192                    });
193                });
194            },
195            afterClose: function () {
196                jQuery('body').undelegate('._popup .close', 'click');
197                jQuery('body').undelegate('._popup .btn input', 'click');
198                jQuery('body').undelegate('._popup .input.name input', 'focus');
199                jQuery('body').undelegate('._popup .input.name input', 'blur');
200                jQuery('body').undelegate('._popup .input.cont .lt input', 'focus');
201                jQuery('body').undelegate('._popup .input.cont .lt input', 'blur');
202                jQuery('body').undelegate('._popup .input.cont .rt input', 'focus');
203                jQuery('body').undelegate('._popup .input.cont .rt input', 'blur');
204            }
205        });
206    });
207    //.wrap .main .top .pal .td.numbers .nrow2 span.lnk.apply
208    jQuery('.wrap .main .content.mp .td.right .action .button input, #addPop').click(function () {
209        jQuery.fancybox.open({
210            content: '<div class="_popup">' +
211                '<div class="r header">Спасибо! Ваша заявка принята</div>' +
212                '<div class="r res">Мы перезвоним Вам на указанный в заявке номер в ближайшее время. Наши специалисты работают в будни с 10:00 до 20:00, в выходные и праздничные дни &mdash; с 11:00 до 18:00</div>' +
213                '<div class="f header">Заявка в студию элитного жилья</div>' +
214                '<div class="close"></div>' +
215                '<div class="f field"><div class="txt">Как к Вам обращаться?</div><div class="input name"><input type="text" value="' + default_msg['name'] + '" /></div>' +
216                '<div class="txt">Ваши контактные данные</div><div class="input cont"><div class="lt"><input type="text" value="' + default_msg['phone'] + '" /></div><div class="rt"><input type="text" value="' + default_msg['email'] + '" /></div></div>' +
217                '<div class="txt details"><div class="lt">Требуемая услуга</div><div class="rt">Тип недвижимости</div></div>' +
218                '<div class="input serv"><div class="lt"><select><option value="" selected="selected">&mdash;&nbsp;выберите</option><option value="A">Архитектурное проектирование</option><option value="D">Дизайн интерьера</option><option value="S">Согласование перепланировки в МВК</option><option value="N">Авторский надзор</option><option value="T">Технический надзор</option><option value="R">Ремонтно-строительные работы</option></select></div>' +
219                '<div class="rt"><select><option value="" selected="selected">&mdash; выберите</option><option value="A">Квартира</option><option value="C">Коттедж</option><option value="O">Офис</option><option value="S">Магазин</option><option value="R">Ресторан</option></select></div></div>' +
220                '<div class="txt">Текст заявки</div><div class="input txt"><textarea cols="1" rows="1"></textarea></div>' +
221                '<div class="f note">Все поля формы обязательны для заполнения</div></div>' +
222                '<div class="f btn"><input type="button" class="button" value="Отправить" onclick="yaCounter15339196.reachGoal(\'otpravka-formi\');ga(\'send\', \'pageview\',\'/otpravka-formi/\');" /></div>' +
223                '</div>',
224            padding: 0,
225            margin: 0,
226            autoSize: true,
227            minWidth: 1,
228            minHeight: 1,
229            scrolling: 'no',
230            loop: false,
231            nextEffect: 'fade',
232            prevEffect: 'fade',
233            closeBtn: false,
234            modal: true,
235            helpers: {
236                overlay: {
237                    locked: false
238                },
239                showEarly: false
240            },
241            beforeShow: function () {
242                jQuery('body').delegate('._popup .close', 'click', function () {
243                    jQuery.fancybox.close();
244                });
245                jQuery('body').delegate('._popup .input.name input', 'focus', function () {
246                    if (jQuery.trim(jQuery(this).val()) == default_msg['name']) {
247                        jQuery(this).addClass('active');
248                        jQuery(this).val('');
249                    }
250                });
251                jQuery('body').delegate('._popup .input.name input', 'blur', function () {
252                    if (jQuery.trim(jQuery(this).val()) == '') {
253                        jQuery(this).removeClass('active');
254                        jQuery(this).val(default_msg['name']);
255                    }
256                });
257                jQuery('body').delegate('._popup .input.cont .lt input', 'focus', function () {
258                    if (jQuery.trim(jQuery(this).val()) == default_msg['phone']) {
259                        jQuery(this).addClass('active');
260                        jQuery(this).val('').inputmask('+7 (999) 999-99-99');
261                    }
262                });
263                jQuery('body').delegate('._popup .input.cont .lt input', 'blur', function () {
264                    if (jQuery.trim(jQuery(this).val()) == '') {
265                        jQuery(this).removeClass('active');
266                        jQuery(this).inputmask('remove').val(default_msg['phone']);
267                    }
268                });
269                jQuery('body').delegate('._popup .input.cont .rt input', 'focus', function () {
270                    if (jQuery.trim(jQuery(this).val()) == default_msg['email']) {
271                        jQuery(this).addClass('active');
272                        jQuery(this).val('');
273                    }
274                });
275                jQuery('body').delegate('._popup .input.cont .rt input', 'blur', function () {
276                    if (jQuery.trim(jQuery(this).val()) == '') {
277                        jQuery(this).removeClass('active');
278                        jQuery(this).val(default_msg['email']);
279                    }
280                });
281                jQuery('body').delegate('._popup .btn input', 'click', function () {
282                    var name = jQuery.trim(jQuery('._popup .input.name input').val()),
283                        number = jQuery.trim(jQuery('._popup .input.cont .lt input').val()),
284                        email = jQuery.trim(jQuery('._popup .input.cont .rt input').val()),
285                        service = jQuery('._popup .input.serv .lt select option:selected').val(),
286                        estate = jQuery('._popup .input.serv .rt select option:selected').val(),
287                        note = jQuery.trim(jQuery('._popup .input.txt textarea').val());
288                    if (number == default_msg['phone']) {
289                        number = '';
290                    }
291                    if (email == default_msg['email']) {
292                        email = '';
293                    }
294                    if ((name.length == 0) || (number.length == 0) || (email.length == 0) || (service.length == 0) || (estate.length == 0) || (note.length == 0)) {
295                        alert('Пожалуйста, заполните все поля формы!');
296                        return false;
297                    }
298                    if (!isEmail(email)) {
299                        alert('Неверный e-mail!');
300                        return false;
301                    }
302                    jQuery.ajax({
303                        type: "POST",
304                        url: "/bitrix/ajax.php",
305                        dataType: "text",
306                        data: ({
307                            session: session,
308                            mode: 3,
309                            name: name,
310                            phone: number,
311                            email: email,
312                            service: jQuery('._popup .input.serv .lt select option:selected').html(),
313                            estate: jQuery('._popup .input.serv .rt select option:selected').html(),
314                            note: note
315                        }),
316                        success: function (data) {
317                            if (data == 0) {
318                                alert('К сожалению, вашу заявку не удалось отправить!')
319                                return false;
320                            }
321                            yaCounter15339196.reachGoal('zayavka');
322                            ga('send', 'event', 'knopka', 'zayavka');
323                            jQuery('._popup .f').hide();
324                            jQuery('._popup .r').fadeIn('fast');
325                        }
326                    });
327                });
328            },
329            afterClose: function () {
330                jQuery('body').undelegate('._popup .close', 'click');
331                jQuery('body').undelegate('._popup .btn input', 'click');
332                jQuery('body').undelegate('._popup .input.name input', 'focus');
333                jQuery('body').undelegate('._popup .input.name input', 'blur');
334                jQuery('body').undelegate('._popup .input.cont .lt input', 'focus');
335                jQuery('body').undelegate('._popup .input.cont .lt input', 'blur');
336                jQuery('body').undelegate('._popup .input.cont .rt input', 'focus');
337                jQuery('body').undelegate('._popup .input.cont .rt input', 'blur');
338            }
339        });
340    });
341
342    jQuery('a[class$="-but"].pretty_button, .animation-but').on("mouseenter", function () {
343        var size = -400 + jQuery(this).outerWidth() + $(this).outerHeight(),
344            bgColor = jQuery(this).css("background-color"),
345            bgImage = jQuery(this).css("background-image");
346
347        jQuery(this).stop().css({ "background": bgColor + " " + bgImage + " " + size + "px 0 no-repeat" });
348    }).on("mouseleave", function () {
349        jQuery(this).stop().removeAttr("style");
350    });
351
352    // show all line table -> block_3
353    jQuery('#open-table').click(function () {
354        if ($(this).attr("data-active") == 0) {
355            $(this).siblings('table').find('tr:nth-child(n+6)').fadeTo("slow", 1);
356            $(this).attr('data-active', "1").html("Свернуть полный перечень");
357        } else {
358            $(this).siblings('table').find('tr:nth-child(n+6)').fadeOut("slow");
359            $(this).attr('data-active', "0").html("Раскрыть полный перечень");
360        }
361    });
362
363    // PopUp New Form
364    var default_msg_new = {
365        'name': 'Имя',
366        'phone': 'Телефон',
367        'text': 'Сообщение'
368    };
369    function openFancyboxForm() {
370        jQuery.fancybox.open({
371            content: '<div class="popup-form-question _new_popup"> ' +
372                '<div class="r title">Спасибо за Вашу заявку!</div>' +
373                '<div class="r text">Наш ведущий специалист свяжется с Вами в ближайшее время.</div>' +
374                '<div class="r close-text">Окно закроется автоматически через 3 секунды</div>' +
375                '<div class="close"></div>' +
376                '<div class="f content-form">' +
377                '<div class="f title">Отправить заявку</div>' +
378                '<div class="f text">Заполните форму, и мы оперативно ответим на интересующий Вас вопрос.</div>' +
379                '<div class="f input cont">' +
380                '<input type="text" name="name" value="" placeholder="' + default_msg_new['name'] + '">' +
381                '<input type="text" name="phone" value="" placeholder="' + default_msg_new['phone'] + '" class="form_phone">' +
382                '</div>' +
383                '<div class="f input txt">' +
384                '<textarea cols="1" rows="1" placeholder="' + default_msg_new['text'] + '"></textarea>' +
385                '</div>' +
386                '<div style="margin-bottom:15px;">Нажимая на кнопку Отправить, вы принимаете <a href="/politics/politika-obrabotki-personalnykh-dannykh/">условия обработки данных.</a></div>' +
387                '<input class="f" type="hidden" name="urlPath" value="' + window.location.pathname + '">' +
388                '<div class="f button-div">
388' +
389                '<input type="button" class="button" value="Отправить">' +
390                '</div>' +
391                '</div>' +
392                '</div>',
393            padding: 0,
394            margin: 0,
395            autoSize: true,
396            minWidth: 1,
397            minHeight: 1,
398            scrolling: 'no',
399            loop: false,
400            nextEffect: 'fade',
401            prevEffect: 'fade',
402            closeBtn: false,
403            modal: true,
404            helpers: {
405                overlay: {
406                    locked: false
407                },
408                showEarly: false
409            },
410            beforeShow: function () {
411                jQuery('._new_popup input[name="phone"]').inputmask('+7 (999) 999-99-99');
412
413                jQuery('body').delegate('._new_popup .close', 'click', function () {
414                    jQuery.fancybox.close();
415                });
416
417                jQuery('body').delegate('._new_popup .button', 'click', function () {
418                    var name = jQuery.trim(jQuery('._new_popup input[name="name"]').val()),
419                        phone = jQuery.trim(jQuery('._new_popup input[name="phone"]').val()),
420                        text = jQuery.trim(jQuery('._new_popup textarea').val()),
421                        urlPath = jQuery.trim(jQuery('._new_popup input[name="urlPath"]').val());
422
423                    if ((name.length == 0) || (phone.length == 0) || (text.length == 0)) {
424                        alert('Пожалуйста, заполните все поля формы!');
425                        return false;
426                    }
427
428                    jQuery.ajax({
429                        type: "POST",
430                        url: "/ajax/make_request_form.php",
431                        dataType: "text",
432                        data: ({
433                            mode: 1,
434                            name: name,
435                            phone: phone,
436                            text: text,
437                            urlPath: urlPath
438                        }),
439                        cache: false,
440                        success: function (response) {
441                            var res = JSON.parse(response);
442                            if (res == 0) {
443                                alert('К сожалению, вашу заявку не удалось отправить!')
444                                return false;
445                            }
446                            //         yaCounter15339196.reachGoal('zayavka');
447                            //         ga('send', 'event', 'knopka', 'zayavka');
448                            jQuery('._new_popup .f').hide();
449                            jQuery('._new_popup .r').fadeIn('fast');
450                            setTimeout(function () {
451                                jQuery('._new_popup .close').click();
452                            }, 3000);
453                        }
454                    });
455                });
456            }
457        });
458    }
459    jQuery('.wrap .main .top .pal .td.numbers .nrow2 span.lnk.apply.new').click(function () {
460        console.log('test');
461        openFancyboxForm();
462    });
463});
464
465// кнопка наверх
466$("#back-top").hide();
467$(function () {
468    $(window).scroll(function () {
469        if ($(this).scrollTop() > 200) {
470            $('#back-top').fadeIn();
471        } else {
472            $('#back-top').fadeOut();
473        }
474    });
475
476    // scroll body to 0px on click
477    $('#back-top').click(function () {
478        $('body,html').animate({
479            scrollTop: 0
480        }, 800);
481        return false;
482    });
483});
484
485function isEmail(str) {
486    var oRegExp = /^[A-Za-z0-9][-\w]*(\.[A-Za-z0-9][-\w]*)*@[A-Za-z0-9][-\w]*(\.[A-Za-z0-9][-\w]*)*\.[a-zA-Z]{2,4}$/
487    return oRegExp.test(str) ? true : false;
488}
489
490$(function () {                                      // Когда страница загрузится
491    $('.mtop a').each(function () {             // получаем все нужные нам ссылки
492        var location = window.location.href; // получаем адрес страницы
493        var link = this.href;                // получаем адрес ссылки
494        if (location == link) {               // при совпадении адреса ссылки и адреса оÐ
494ºÐ½Ð°
495            $(this).addClass('active');  //добавляем класс
496            $(this).parents('.item').addClass('active');  //добавляем класс
497        }
498    });
499});
500// Определяем мобильные
501var isMobile = {
502    Android: function () { return navigator.userAgent.match(/Android/i); },
503    BlackBerry: function () { return navigator.userAgent.match(/BlackBerry/i); },
504    iOS: function () { return navigator.userAgent.match(/iPhone|iPad|iPod/i); },
505    Opera: function () { return navigator.userAgent.match(/Opera Mini/i); },
506    Windows: function () { return navigator.userAgent.match(/IEMobile/i); },
507    any: function () { return (isMobile.Android() || isMobile.BlackBerry() || isMobile.iOS() || isMobile.Opera() || isMobile.Windows()); }
508};
509// Определяем браузер
510var isBrowser = {
511    any: function () {
512        if (navigator.userAgent.toLowerCase().indexOf('chrome') > -1) { return "chrome"; }
513        else if (navigator.userAgent.toLowerCase().indexOf('msie') > -1) { return "msie"; }
514        else if (navigator.userAgent.toLowerCase().indexOf('firefox') > -1) { return "firefox"; }
515        else if (navigator.userAgent.toLowerCase().indexOf("safari") > -1) { return "safari"; }
516        else if (navigator.userAgent.toLowerCase().indexOf("op") > -1) { return "op"; }
517        var nav = navigator.userAgent.toLowerCase();
518        var iDevices = [
519            'ipad',
520            'iphone',
521            'ipod',
522            'android'
523        ]
524        while (iDevices.length) {
525            var device = iDevices.pop();
526            if (nav.indexOf(device) > -1) return device;
527        }
528        return "no-browser";
529    },
530};
531var isOS = { name: (/(win|mac|linux|sunos|solaris|iphone|ipad)/.exec(navigator.platform.toLowerCase()) || [u])[0].replace('sunos', 'solaris') };

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.