(()=>{var e,t,o,r={4528:(e,t,o)=>{"use strict";o.r(t);const r=window.wp.blocks,l=window.wc.wcSettings;var n=o(1609),c=o(5573);const i=(0,n.createElement)(c.SVG,{width:"24",height:"24",viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg"},(0,n.createElement)(c.Path,{fillRule:"evenodd",clipRule:"evenodd",d:"M6 10C7.10457 10 8 9.10457 8 8C8 6.89543 7.10457 6 6 6C4.89543 6 4 6.89543 4 8C4 9.10457 4.89543 10 6 10ZM20 8.75H11.1111V7.25L20 7.25V8.75ZM20 15.75L11.1111 15.75V14.25L20 14.25V15.75ZM8 15C8 16.1046 7.10457 17 6 17C4.89543 17 4 16.1046 4 15C4 13.8954 4.89543 13 6 13C7.10457 13 8 13.8954 8 15Z",fill:"currentColor"})),a=JSON.parse('{"$schema":"https://schemas.wp.org/trunk/block.json","name":"woocommerce/product-filter-active","version":"1.0.0","title":"Filter Options","description":"Display the currently active filters.","category":"woocommerce","keywords":["WooCommerce"],"textdomain":"woocommerce","apiVersion":2,"ancestor":["woocommerce/product-filter"],"supports":{"interactivity":true,"inserter":false,"color":{"text":true,"background":false}},"usesContext":["queryId"],"attributes":{"displayStyle":{"type":"string","default":"list"}}}'),s=window.wp.blockEditor;var m=o(7723),p=o(851);const u=window.wp.components,d=({attributes:e,setAttributes:t})=>{const{displayStyle:o}=e;return(0,n.createElement)(s.InspectorControls,null,(0,n.createElement)(u.PanelBody,{title:(0,m.__)("Display Settings","woocommerce")},(0,n.createElement)(u.__experimentalToggleGroupControl,{label:(0,m.__)("Display Style","woocommerce"),value:o,onChange:e=>t({displayStyle:e})},(0,n.createElement)(u.__experimentalToggleGroupControlOption,{value:"list",label:(0,m.__)("List","woocommerce")}),(0,n.createElement)(u.__experimentalToggleGroupControlOption,{value:"chips",label:(0,m.__)("Chips","woocommerce")}))))},w=window.wc.blocksComponents;var f=o(7104),b=o(8098);const y=({type:e,name:t,prefix:o="",removeCallback:r=(()=>null),showLabel:l=!0,displayStyle:c})=>{const i=o?(0,n.createElement)(n.Fragment,null,o," ",t):t,a=(0,m.sprintf)(/* translators: %s attribute value used in the filter. For example: yellow, green, small, large. */ /* translators: %s attribute value used in the filter. For example: yellow, green, small, large. */
(0,m.__)("Remove %s filter","woocommerce"),t);return(0,n.createElement)("li",{className:"list-item",key:`${e}: ${t}`},l&&(0,n.createElement)("span",{className:"list-item-type"},`${e}: `),"chips"===c?(0,n.createElement)(w.RemovableChip,{element:"span",text:i,onRemove:r,radius:"large",ariaLabel:a}):(0,n.createElement)("span",{className:"list-item-name"},(0,n.createElement)("button",{className:"list-item-remove",onClick:r},(0,n.createElement)(f.A,{className:"wc-block-components-chip__remove-icon",icon:b.A,size:16}),(0,n.createElement)(w.Label,{screenReaderLabel:a})),i))};o(3111),(()=>{const{experimentalBlocksEnabled:e}=(0,l.getSetting)("wcBlocksConfig",{experimentalBlocksEnabled:!1});return e})()&&(0,r.registerBlockType)(a,{icon:i,edit:e=>{const{displayStyle:t}=e.attributes,o=(0,s.useBlockProps)({className:"wc-block-active-filters"});return(0,n.createElement)("div",{...o},(0,n.createElement)(d,{...e}),(0,n.createElement)(u.Disabled,null,(0,n.createElement)("ul",{className:(0,p.A)("filter-list",{"list-chips":"chips"===t})},(0,n.createElement)(y,{type:(0,m.__)("Size","woocommerce"),name:(0,m.__)("Small","woocommerce"),displayStyle:t}),(0,n.createElement)(y,{type:(0,m.__)("Color","woocommerce"),name:(0,m.__)("Blue","woocommerce"),displayStyle:t}))))}})},3111:()=>{},1609:e=>{"use strict";e.exports=window.React},6087:e=>{"use strict";e.exports=window.wp.element},7723:e=>{"use strict";e.exports=window.wp.i18n},5573:e=>{"use strict";e.exports=window.wp.primitives}},l={};function n(e){var t=l[e];if(void 0!==t)return t.exports;var o=l[e]={exports:{}};return r[e].call(o.exports,o,o.exports,n),o.exports}n.m=r,e=[],n.O=(t,o,r,l)=>{if(!o){var c=1/0;for(m=0;m<e.length;m++){for(var[o,r,l]=e[m],i=!0,a=0;a<o.length;a++)(!1&l||c>=l)&&Object.keys(n.O).every((e=>n.O[e](o[a])))?o.splice(a--,1):(i=!1,l<c&&(c=l));if(i){e.splice(m--,1);var s=r();void 0!==s&&(t=s)}}return t}l=l||0;for(var m=e.length;m>0&&e[m-1][2]>l;m--)e[m]=e[m-1];e[m]=[o,r,l]},n.n=e=>{var t=e&&e.__esModule?()=>e.default:()=>e;return n.d(t,{a:t}),t},o=Object.getPrototypeOf?e=>Object.getPrototypeOf(e):e=>e.__proto__,n.t=function(e,r){if(1&r&&(e=this(e)),8&r)return e;if("object"==typeof e&&e){if(4&r&&e.__esModule)return e;if(16&r&&"function"==typeof e.then)return e}var l=Object.create(null);n.r(l);var c={};t=t||[null,o({}),o([]),o(o)];for(var i=2&r&&e;"object"==typeof i&&!~t.indexOf(i);i=o(i))Object.getOwnPropertyNames(i).forEach((t=>c[t]=()=>e[t]));return c.default=()=>e,n.d(l,c),l},n.d=(e,t)=>{for(var o in t)n.o(t,o)&&!n.o(e,o)&&Object.defineProperty(e,o,{enumerable:!0,get:t[o]})},n.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),n.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},n.j=7598,(()=>{var e={7598:0};n.O.j=t=>0===e[t];var t=(t,o)=>{var r,l,[c,i,a]=o,s=0;if(c.some((t=>0!==e[t]))){for(r in i)n.o(i,r)&&(n.m[r]=i[r]);if(a)var m=a(n)}for(t&&t(o);s<c.length;s++)l=c[s],n.o(e,l)&&e[l]&&e[l][0](),e[l]=0;return n.O(m)},o=self.webpackChunkwebpackWcBlocksMainJsonp=self.webpackChunkwebpackWcBlocksMainJsonp||[];o.forEach(t.bind(null,0)),o.push=t.bind(null,o.push.bind(o))})();var c=n.O(void 0,[94],(()=>n(4528)));c=n.O(c),((this.wc=this.wc||{}).blocks=this.wc.blocks||{})["product-filter-active"]=c})();