PageSourceSearch

https://montech.com/js/4957.js

js montech.com collected 2026-09-28 11:03:00 UTC 5,567 bytes, 1 lines download raw bytes

1"use strict";(self.webpackChunk=self.webpackChunk||[]).push([[4957],{64957:(t,e,r)=>{r.r(e),r.d(e,{default:()=>f});var a=r(20629);const n={name:"SearchItem",props:{data:Object,category:String,articleNumber:String},computed:{description:function(){return this.data.description?this.data.description.raw.length<=200?this.data.description.raw:this.data.description.raw.slice(0,200)+"...":""}}};var s=r(51900);function i(t){return i="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},i(t)}function o(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(t);e&&(a=a.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),r.push.apply(r,a)}return r}function l(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{};e%2?o(Object(r),!0).forEach((function(e){c(t,e,r[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):o(Object(r)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}))}return t}function c(t,e,r){return(e=function(t){var e=function(t,e){if("object"!==i(t)||null===t)return t;var r=t[Symbol.toPrimitive];if(void 0!==r){var a=r.call(t,e||"default");if("object"!==i(a))return a;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===e?String:Number)(t)}(t,"string");return"symbol"===i(e)?e:String(e)}(e))in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}function u(t,e){var r="undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(!r){if(Array.isArray(t)||(r=function(t,e){if(!t)return;if("string"==typeof t)return m(t,e);var r=Object.prototype.toString.call(t).slice(8,-1);"Object"===r&&t.constructor&&(r=t.constructor.name);if("Map"===r||"Set"===r)return Array.from(t);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return m(t,e)}(t))||e&&t&&"number"==typeof t.length){r&&(t=r);var a=0,n=function(){};return{s:n,n:function(){return a>=t.length?{done:!0}:{done:!1,value:t[a++]}},e:function(t){throw t},f:n}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var s,i=!0,o=!1;return{s:function(){r=r.call(t)},n:function(){var t=r.next();return i=t.done,t},e:function(t){o=!0,s=t},f:function(){try{i||null==r.return||r.return()}finally{if(o)throw s}}}}function m(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,a=new Array(e);r<e;r++)a[r]=t[r];return a}const d={name:"SearchResults",components:{SearchItem:(0,s.Z)(n,(function(){var t=this,e=t._self._c;return e("div",{staticClass:"search-item"},[t.data.url?e("a",{staticClass:"search-item__link",attrs:{href:t.data.url.raw,"aria-label":t.data.title.raw}}):t._e(),t._v(" "),e("div",{staticClass:"d-flex flex-column flex-lg-row position-relative"},[e("div",{staticClass:"d-lg-none search-item__category",domProps:{textContent:t._s(t.category)}}),t._v(" "),e("div",{staticClass:"search-item__image-container align-self-lg-center"},[t.data.image_thumbnail?e("img",{staticClass:"search-item__image",attrs:{src:t.data.image_thumbnail.raw,alt:t.data.title.raw,loading:"lazy"}}):t._e()]),t._v(" "),e("div",{staticClass:"search-item__content"},[e("div",{staticClass:"d-none d-lg-block search-item__category",domProps:{textContent:t._s(t.category)}}),t._v(" "),e("div",{staticClass:"search-item__title",domProps:{innerHTML:t._s(t.data.title.raw)}}),t._v(" "),e("div",{staticClass:"search-item__description",domProps:{innerHTML:t._s(t.description)}}),t._v(" "),t.data.item_number?e("div",{staticClass:"search-item__product-id",domProps:{innerHTML:t._s(t.articleNumber+": "+t.data.item_number.raw)}}):t._e()])])])}),[],!1,null,null,null).exports},props:{labels:Object},data:function(){return{urlParams:{}}},mounted:function(){var t,e=u(new URLSearchParams(window.location.search).entries());try{for(e.s();!(t=e.n()).done;){var r=t.value;
1this.urlParams[r[0]]=r[1]}}catch(t){e.e(t)}finally{e.f()}},computed:l({},(0,a.mapGetters)("appsearch",["api","results","total","hasResults","loaded","loading","term","isLastPage"])),methods:l({},(0,a.mapActions)("appsearch",["search","nextPage","toggleFilter"])),watch:{api:function(){this.urlParams.type&&this.toggleFilter({name:"bucket",value:this.urlParams.type}),this.urlParams.term?this.search(this.urlParams.term):this.search("")}}};const f=(0,s.Z)(d,(function(){var t=this,e=t._self._c;return e("div",{staticClass:"search-results"},[e("search-count",{staticClass:"d-none d-md-block",attrs:{label:t.labels.counter_label,total:t.total}}),t._v(" "),t.loaded?e("div",{staticClass:"search-results__container"},[t._l(t.results,(function(r){return e("div",{staticClass:"search-results__item",on:{click:function(e){return t.console.log("track me")}}},[e("search-item",{attrs:{data:r,category:t.labels[r.bucket.raw+"_label"],"article-number":t.labels.product_number_label}})],1)})),t._v(" "),t.hasResults?t._e():e("div",{staticClass:"search-results__no-results"},[t._v(t._s(t.labels.no_entries_found_label+" ")),e("strong",{domProps:{textContent:t._s(t.term)}})])],2):t._e(),t._v(" "),t.isLastPage?t._e():e("div",{staticClass:"search-results__button"},[e("button",{staticClass:"button button--grey icon",class:{"button--loading":t.loading},on:{click:t.nextPage}},[t._v(t._s(t.labels.show_more_label))])])],1)}),[],!1,null,null,null).exports}}]);

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.