PageSourceSearch

https://garlyn.ru/build/assets/Index-74946881.js

js garlyn.ru collected 2026-09-24 10:48:20 UTC 4,769 bytes, 1 lines download raw bytes

1import{d as k,C as A,A as V,D as B,O as f,b8 as H,l as n,g as _,w as v,F as u,o as c,i as e,f as I,m as x,u as N,B as $,G as z,t as g,n as D,x as q,y as L}from"./vue.m-7107e1b8.js";import{_ as T}from"./DefaultLayout-0b897676.js";import{P as F}from"./PageTitle-d47bb4ca.js";import{P as G}from"./ProductItem-151bb144.js";import{S as M}from"./swiper-core-8744896b.js";import{_ as O}from"./AppHead-e8c1b82c.js";import{_ as R}from"./_plugin-vue_export-helper-c27b6911.js";import"./helpers-819aca0c.js";import"./ErrorText-e9d01f32.js";import"./TextInput-5e5969c8.js";import"./Timer-7effad79.js";import"./PublicOfferLinkIndividual-f018425c.js";/* empty css                                                              */import"./navigationScripts-6034ab1f.js";/* empty css                                                                  */import"./AddToCartButton-da0bef9d.js";import"./Price-28e3dade.js";/* empty css                                                              *//* empty css                                                                    */import"./AddToFavorite-a91bdbe5.js";const h=l=>(q("data-v-b9c4da03"),l=l(),L(),l),j=h(()=>e("meta",{name:"robots",content:"noindex, nofollow, noarchive"},null,-1)),U={class:"page"},J={class:"container"},K={class:"tabs"},Q=["onClick"],W={class:"item__name"},X={class:"item__count"},Y={class:"compare-table"},Z={class:"swiper main-slider"},ee=h(()=>e("div",{class:"arrows"},[e("div",{class:"arrow arrow-prev"}),e("div",{class:"arrow arrow-next"})],-1)),te={class:"swiper-wrapper"},oe=["data-index"],se={class:"property-name"},ae={class:"property-value"},re={key:1,class:"empty-compare"},ie=h(()=>e("h2",null,"Сравнивать пока нечего",-1)),ne=h(()=>e("p",null,"Добавляйте сюда товары, чтобы сравнить характеристики. На странице товара нажмите кнопку",-1)),ce=h(()=>e("img",{src:"/images/page-compare/example.png",alt:"В сравнение"},null,-1)),le={__name:"Index",props:["products","categories"],setup(l){const p=l,m=k(p.categories.length?p.categories[0].code:null);A(()=>p.categories,()=>{m.value=p.categories.length?p.categories[0].code:null},{deep:!0});function d(r){const a=document.querySelectorAll(r);if(Array.from(a).some(t=>t.hasAttribute("data-index"))){const t={};a.forEach(s=>{s.style.height="auto";const i=s.getAttribute("data-index");t[i]||(t[i]=[]),t[i].push(s)}),Object.values(t).forEach(s=>{let i=0;s.forEach(w=>{const E=w.offsetHeight;E>i&&(i=E)}),s.forEach(w=>{w.style.height=`${i}px`})})}else{let t=0;a.forEach(s=>{s.style.height="auto";const i=s.offsetHeight;i>t&&(t=i)}),a.forEach(s=>{s.style.height=`${t}px`})}}const b=()=>{d(".compare-table-cell"),d(".compare-table .item")},y=()=>{new M(".main-slider",{spaceBetween:0,observer:!0,slidesPerView:1,slideActiveClass:"table-row-active",freeMode:!0,navigation:{nextEl:".arrow-next",prevEl:".arrow-prev"},disabledClass:"nav-disabled",breakpoints:{320:{slidesPerView:2},994:{slidesPerView:4}},on:{init:function(){f(()=>{d(".compare-table-cell"),d(".compare-table .item")})}}}),f(()=>d(".compare-table .item"))};function P(r){m.value=r,y(),f(()=>d(".compare-table .item"))}const C=V(()=>{const r=new Set;return p.products.filter(a=>a.categoryRoot.code===m.value).forEach(a=>{a.properties.forEach(o=>{r.add(o.name)})}),Array.from(r)}),S=(r,a)=>{const o=a.properties.find(t=>t.name===r);return o?o.value:null};return B(()=>{y(),window.addEventListener("resize",b),f(()=>d(".compare-table .item"))}),H(()=>{window.removeEventListener("resize",b)}),(r,a)=>(c(),n(u,null,[_(O,{title:"Сравнение товаров"},{default:v(()=>[j]),_:1}),_(T,null,{default:v(()=>[e("div",U,[_(F,null,{default:v(()=>[I("Сравнение товаров")]),_:1}),e("div",J,[l.categories.length?(c(),n(u,{key:0},[e("div",K,[(c(!0),n(u,null,x(l.categories,o=>(c(),n("div",{class:z(["tab-item",{active:o.code===m.value}]),onClick:t=>P(o.code)},[e("span",W,g(o.name),1),e("span",X,g(o.count),1)],10,Q))),256))]),e("div",Y,[e("div",Z,[ee,e("div",te,[(c(!0),n(u,null,x(l.products,o=>(c(),n(u,null,[!m.value||m.value===o.categoryRoot.code?(c(),n("div",{key:0,class:"swiper-slide",ref_for:!0,ref:"swiperSlides"},[_(G,{product:o},null,8,["product"]),e("div",{class:"d-flex flex-column mb-5",ref_for:!0,ref:"wrapper"},[(c(!0),n(u,null,x(C.value,(t,s)=>(c(),n("div",{class:"compare-table-cell",ref_for:!0,ref:"cell","data-index":s},[e("span",se,g(t),1),e("span",ae,g(S(t,o)||"-"),1)],8,oe))),256))],512)],512)):D("",!0)],64))),256))])])])],64)):(c(),n("div",re,[ie,ne,ce,_(N($),{href:r.route("catalog.index")},{default:v(()=>[I("Перейти в каталог")]),_:1},8,["href"])]))])])]),_:1})],64))}},Ve=R(le,[["__scopeId","data-v-b9c4da03"]]);export{Ve as default};

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.