PageSourceSearch

https://tasmania.com/wp-content/themes/tasmania/js/swiftype-autocomplete.min.js?ver=1790271972

js tasmania.com collected 2026-09-24 18:41:01 UTC 7,719 bytes, 1 lines download raw bytes

1!function(e,t){var i=0;window.Swiftype=window.Swiftype||{},Swiftype.root_url=Swiftype.root_url||"https://api.swiftype.com",Swiftype.pingUrl=function(e,t){var i=new Image;return i.onload=i.onerror=t,i.src=e,setTimeout(t,350),!1},Swiftype.pingAutoSelection=function(t,i,s,n){var o={t:(new Date).getTime(),engine_key:t,doc_id:i,prefix:s},r=Swiftype.root_url+"/api/v1/public/analytics/pas?"+e.param(o);Swiftype.pingUrl(r,n)},Swiftype.htmlEscape=Swiftype.htmlEscape||function(e){return String(e).replace(/&/g,"&amp;").replace(/"/g,"&quot;").replace(/'/g,"&#39;").replace(/</g,"&lt;").replace(/>/g,"&gt;")},e.fn.swiftype_custom=function(n){n=e.extend({},e.fn.swiftype_custom.defaults,n);return this.each(function(){var r=e(this),u=e.meta?e.extend({},n,r.data()):n;r.attr("autocomplete","off"),r.data("swiftype-config",u),r.submitted=!1,r.cache=new l(10),r.emptyQueries=[],r.isEmpty=function(t){return e.inArray(s(t),this.emptyQueries)>=0},r.addEmpty=function(e){r.emptyQueries.unshift(s(e))},r.popper=null;var c=u.dropdownStylesFunction(r),d=e('<div class="swiftype-widget" />'),p=e("<div />").addClass(u.suggestionListClass).appendTo(d).css(c);d.appendTo(r.closest(".kd-swiftype-autocomplete"));var f,h=e("<"+u.suggestionListType+" />").appendTo(p);d.hide(),r.data("swiftype-list",h),r.abortCurrent=function(){r.currentRequest&&r.currentRequest.abort()},r.showList=function(){!1===a(u.disableAutocomplete)&&(d.show(),r.popper=new t(r,d,{onCreate:function(e){r.popper.update()},placement:"bottom-end"}))},r.hideList=function(e){function t(){r.popper&&(r.popper.disableEventListeners(),r.popper.destroy()),d.hide()}e?t():setTimeout(function(){t()},10)},r.focused=function(){return r.is(":focus")},r.submitting=function(){r.submitted=!0},r.listResults=function(){return e(u.resultListSelector,h)},r.activeResult=function(){return r.listResults().filter("."+u.activeItemClass).first()},r.prevResult=function(){var e=r.listResults(),t=e.index(r.activeResult())-1,i=e.eq(t);r.listResults().removeClass(u.activeItemClass),t>=0&&i.addClass(u.activeItemClass)},r.nextResult=function(){var e=r.listResults(),t=e.index(r.activeResult())+1,i=e.eq(t);r.listResults().removeClass(u.activeItemClass),t>=0&&i.addClass(u.activeItemClass)},r.selectedCallback=function(e){return function(){var t=r.val();Swiftype.pingAutoSelection(u.engineKey,e.id,t,function(){u.onComplete(e,t)})}},r.registerResult=function(e,t){e.data("swiftype-item",t),e.click(r.selectedCallback(t)).mouseover(function(){r.listResults().removeClass(u.activeItemClass),e.addClass(u.activeItemClass)})},r.getContext=function(){return{config:u,list:h,registerResult:r.registerResult}};var y=!1;r.lastValue="",r.keyup(function(e){y?y=!1:e.which>36&&e.which<41||16==e.which||(u.typingDelay>0?(clearTimeout(f),f=setTimeout(function(){o(r)},u.typingDelay)):o(r))}),r.styleDropdown=function(){p.css(u.dropdownStylesFunction(r))},r.keydown(function(e){r.styleDropdown();var t=r.activeResult();switch(e.which){case 13:0!==t.length&&h.is(":visible")?(e.preventDefault(),r.selectedCallback(t.data("swiftype-item"))()):r.currentRequest&&r.submitting(),r.hideList(),y=!0;break;case 38:e.preventDefault(),0===t.length?r.listResults().last().addClass(u.activeItemClass):r.prevResult();break;case 40:e.preventDefault(),0===t.length?r.listResults().first().addClass(u.activeItemClass):t!=r.listResults().last()&&r.nextResult();break;case 27:r.hideList(),y=!0;break;default:r.submitted=!1}}),r.keypress(function(e){13==e.which&&r.activeResult().length>0&&e.preventDefault()});var v=!1,m=!1;e(document).bind("mousedown.swiftype"+ ++i,function(){v=!0}),e(document).bind("mouseup.swiftype"+i,function(){v=!1,m&&(m=!1,r.hideList())}),r.blur(function(){v?m=!0:r.hideList()}),r.focus(function(){setTimeout(function(){r.select()},10),r.listResults().filter(":not(."+u.noResultsClass+")").length>0&&r.showList()})})};var s=function(t){return e.trim(t).toLowerCase()},n=function(t,i){var n=s(i);if(t.isEmpty(n))return t.data("swiftype-list").empty(),void t.hideList();var o=t.cache.get(n);o?r(t,o,i):function(t,i){t.abortCurrent();var n={},o=t.data("swiftype-config");n.q=i,n.engine_key=o.engineKey,n.search_fields=a(o.searchFields),n.fetch_fields=a(o.fetchFields),n.filters=a(o.filters),n.document_types=a(o.documentTypes),n.functional_boosts=a(o.functionalBoosts),n.sort_field=a(o.sortField),n.sort_direction=a(o.sortDirection),n.per_page=o.resultLimit;var l=Swiftype.root_url+"/api/v1/public/engines/suggest.json";t.currentRequest=e.ajax({type:"GET",dataType:"jsonp",url:l,data:n}).success(function(e){var n=s(i);if(!(e.record_count>0))return t.addEmpty(n),t.data("swiftype-list").empty(),void t.hideList();t.cache.put(n,e.records),r(t,e.records,i)})}(t,i)},o=function(t){var i=t.val();if(i!==t.lastValue){if(t.lastValue=i,""===e.trim(i))return t.data("swiftype-list").empty(),void t.hideList();void 0!==t.data("swiftype-config").engineKey&&n(t,i)}},r=function(e,t,i){var s=e.data("swiftype-list"),n=e.data("swiftype-config");s.empty(),e.hideList(!0),n.resultRenderFunction(e.getContext(),t),(e.listResults().length>0&&e.focused()||void 0!==n.noResultsMessage)&&(e.submitted?e.submitted=!1:e.showList())},a=function(e){if(void 0!==e){var t=e;return"function"==typeof t&&(t=t.call()),t}};function l(e){this.size=0,this.limit=e,this._keymap={}}l.prototype.put=function(e,t){var i={key:e,value:t};if(this._keymap[e]=i,this.tail?(this.tail.newer=i,i.older=this.tail):this.head=i,this.tail=i,this.size===this.limit)return this.shift();this.size++},l.prototype.shift=function(){var e=this.head;return e&&(this.head.newer?(this.head=this.head.newer,this.head.older=void 0):this.head=void 0,e.newer=e.older=void 0,delete this._keymap[e.key]),e},l.prototype.get=function(e,t){var i=this._keymap[e];if(void 0!==i)return i===this.tail?i.value:(i.newer&&(i===this.head&&(this.head=i.newer),i.newer.older=i.older),i.older&&(i.older.newer=i.newer),i.newer=void 0,i.older=this.tail,this.tail&&(this.tail.newer=i),this.tail=i,t?i:i.value)},l.prototype.remove=function(e){var t=this._keymap[e];if(t)return delete this._keymap[t.key],t.newer&&t.older?(t.older.newer=t.newer,t.newer.older=t.older):t.newer?(t.newer.older=void 0,this.head=t.newer):t.older?(t.older.newer=void 0,this.tail=t.older):this.head=this.tail=void 0,this.size--,t.value},l.prototype.clear=function(){this.head=this.tail=void 0,this.size=0,this._keymap={}},"function"==typeof Object.keys?l.prototype.keys=function(){return Object.keys(this._keymap)}:l.prototype.keys=function(){var e=[];for(var t in this._keymap)e.push(t);return e}
1,e.fn.swiftype_custom.defaults={activeItemClass:"active",attachTo:void 0,documentTypes:void 0,filters:void 0,engineKey:void 0,searchFields:void 0,functionalBoosts:void 0,sortField:void 0,sortDirection:void 0,fetchFields:void 0,noResultsClass:"noResults",noResultsMessage:void 0,onComplete:function(e,t){window.location=e.url},resultRenderFunction:function(t,i){var s=t.list,n=t.config;e.each(i,function(i,o){e.each(o,function(o,r){t.registerResult(e("<li>"+n.renderFunction(i,r)+"</li>").appendTo(s),r)})})},renderFunction:function(e,t){return'<p class="title">'+Swiftype.htmlEscape(t.title)+"</p>"},dropdownStylesFunction:function(t){var i=t.data("swiftype-config"),s=i.attachTo?e(i.attachTo):t,n=(s.offset(),{"min-width":s.outerWidth()-2});return i.setWidth&&(n.width=s.outerWidth()-2),n},resultLimit:void 0,suggestionListType:"ul",suggestionListClass:"autocomplete",resultListSelector:"li",setWidth:!0,typingDelay:80,disableAutocomplete:!1}}(jQuery,Popper),function(e){e(".kd-swiftype-autocomplete-search").each(function(){var t=e(this),i={};t.data("post_type")&&(i.posts={object_type:t.data("post_type")}),t.swiftype_custom({engineKey:"g9pZpfr6gxTz2Uuw33ey",resultLimit:10,filters:i,setWidth:!1})})}(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.