editor-rtl.min.css000064400000002677147206524620010151 0ustar00.block-library-query-toolbar__popover .components-popover__content{min-width:230px}.block-library-query-toolbar__popover .components-popover__content .block-library-query-toolbar__popover-number-control{margin-bottom:8px}.wp-block-query__create-new-link{padding:0 52px 16px 16px}.block-library-query__pattern-selection-content .block-editor-block-patterns-list{display:grid;grid-template-columns:1fr 1fr 1fr;grid-gap:8px}.block-library-query__pattern-selection-content .block-editor-block-patterns-list .block-editor-block-patterns-list__list-item{margin-bottom:0}.block-library-query__pattern-selection-content .block-editor-block-patterns-list .block-editor-block-patterns-list__list-item .block-editor-block-preview__container{max-height:250px}.block-library-query-pattern__selection-modal .block-editor-block-patterns-list{column-count:2;column-gap:24px}@media (min-width:1280px){.block-library-query-pattern__selection-modal .block-editor-block-patterns-list{column-count:3}}.block-library-query-pattern__selection-modal .block-editor-block-patterns-list .block-editor-block-patterns-list__list-item{break-inside:avoid-column}.block-library-query-pattern__selection-modal .block-library-query-pattern__selection-search{background:#fff;margin-bottom:-4px;padding:16px 0;position:sticky;top:0;transform:translateY(-4px);z-index:2}@media (min-width:600px){.wp-block-query__enhanced-pagination-modal{max-width:480px}}.wp-block-query__enhanced-pagination-notice{margin:0}view.asset.php000064400000000124147206524620007352 0ustar00 array(), 'version' => 'ee101e08820687c9c07f'); view.js000064400000011305147206524620006064 0ustar00import * as __WEBPACK_EXTERNAL_MODULE__wordpress_interactivity_8e89b257__ from "@wordpress/interactivity"; /******/ var __webpack_modules__ = ({ /***/ 438: /***/ ((module) => { module.exports = import("@wordpress/interactivity-router");; /***/ }) /******/ }); /************************************************************************/ /******/ // The module cache /******/ var __webpack_module_cache__ = {}; /******/ /******/ // The require function /******/ function __webpack_require__(moduleId) { /******/ // Check if module is in cache /******/ var cachedModule = __webpack_module_cache__[moduleId]; /******/ if (cachedModule !== undefined) { /******/ return cachedModule.exports; /******/ } /******/ // Create a new module (and put it into the cache) /******/ var module = __webpack_module_cache__[moduleId] = { /******/ // no module.id needed /******/ // no module.loaded needed /******/ exports: {} /******/ }; /******/ /******/ // Execute the module function /******/ __webpack_modules__[moduleId](module, module.exports, __webpack_require__); /******/ /******/ // Return the exports of the module /******/ return module.exports; /******/ } /******/ /************************************************************************/ /******/ /* webpack/runtime/define property getters */ /******/ (() => { /******/ // define getter functions for harmony exports /******/ __webpack_require__.d = (exports, definition) => { /******/ for(var key in definition) { /******/ if(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) { /******/ Object.defineProperty(exports, key, { enumerable: true, get: definition[key] }); /******/ } /******/ } /******/ }; /******/ })(); /******/ /******/ /* webpack/runtime/hasOwnProperty shorthand */ /******/ (() => { /******/ __webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop)) /******/ })(); /******/ /************************************************************************/ var __webpack_exports__ = {}; // This entry need to be wrapped in an IIFE because it need to be isolated against other modules in the chunk. (() => { ;// CONCATENATED MODULE: external "@wordpress/interactivity" var x = (y) => { var x = {}; __webpack_require__.d(x, y); return x } var y = (x) => (() => (x)) const interactivity_namespaceObject = x({ ["getContext"]: () => (__WEBPACK_EXTERNAL_MODULE__wordpress_interactivity_8e89b257__.getContext), ["getElement"]: () => (__WEBPACK_EXTERNAL_MODULE__wordpress_interactivity_8e89b257__.getElement), ["store"]: () => (__WEBPACK_EXTERNAL_MODULE__wordpress_interactivity_8e89b257__.store) }); ;// CONCATENATED MODULE: ./node_modules/@wordpress/block-library/build-module/query/view.js /** * WordPress dependencies */ const isValidLink = ref => ref && ref instanceof window.HTMLAnchorElement && ref.href && (!ref.target || ref.target === '_self') && ref.origin === window.location.origin; const isValidEvent = event => event.button === 0 && // Left clicks only. !event.metaKey && // Open in new tab (Mac). !event.ctrlKey && // Open in new tab (Windows). !event.altKey && // Download. !event.shiftKey && !event.defaultPrevented; (0,interactivity_namespaceObject.store)('core/query', { actions: { *navigate(event) { const ctx = (0,interactivity_namespaceObject.getContext)(); const { ref } = (0,interactivity_namespaceObject.getElement)(); const queryRef = ref.closest('.wp-block-query[data-wp-router-region]'); if (isValidLink(ref) && isValidEvent(event)) { event.preventDefault(); const { actions } = yield Promise.resolve(/* import() */).then(__webpack_require__.bind(__webpack_require__, 438)); yield actions.navigate(ref.href); ctx.url = ref.href; // Focus the first anchor of the Query block. const firstAnchor = `.wp-block-post-template a[href]`; queryRef.querySelector(firstAnchor)?.focus(); } }, *prefetch() { const { ref } = (0,interactivity_namespaceObject.getElement)(); if (isValidLink(ref)) { const { actions } = yield Promise.resolve(/* import() */).then(__webpack_require__.bind(__webpack_require__, 438)); yield actions.prefetch(ref.href); } } }, callbacks: { *prefetch() { const { url } = (0,interactivity_namespaceObject.getContext)(); const { ref } = (0,interactivity_namespaceObject.getElement)(); if (url && isValidLink(ref)) { const { actions } = yield Promise.resolve(/* import() */).then(__webpack_require__.bind(__webpack_require__, 438)); yield actions.prefetch(ref.href); } } } }, { lock: true }); })(); view.min.asset.php000064400000000124147206524620010134 0ustar00 array(), 'version' => '490915f92cc794ea16e1'); view.min.js000064400000002614147206524620006651 0ustar00import*as e from"@wordpress/interactivity";var t={438:e=>{e.exports=import("@wordpress/interactivity-router")}},r={};function o(e){var n=r[e];if(void 0!==n)return n.exports;var i=r[e]={exports:{}};return t[e](i,i.exports,o),i.exports}o.d=(e,t)=>{for(var r in t)o.o(t,r)&&!o.o(e,r)&&Object.defineProperty(e,r,{enumerable:!0,get:t[r]})},o.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),(()=>{const t=(e=>{var t={};return o.d(t,e),t})({getContext:()=>e.getContext,getElement:()=>e.getElement,store:()=>e.store}),r=e=>e&&e instanceof window.HTMLAnchorElement&&e.href&&(!e.target||"_self"===e.target)&&e.origin===window.location.origin;(0,t.store)("core/query",{actions:{*navigate(e){const n=(0,t.getContext)(),{ref:i}=(0,t.getElement)(),s=i.closest(".wp-block-query[data-wp-router-region]");if(r(i)&&(e=>!(0!==e.button||e.metaKey||e.ctrlKey||e.altKey||e.shiftKey||e.defaultPrevented))(e)){e.preventDefault();const{actions:t}=yield Promise.resolve().then(o.bind(o,438));yield t.navigate(i.href),n.url=i.href;const r=".wp-block-post-template a[href]";s.querySelector(r)?.focus()}},*prefetch(){const{ref:e}=(0,t.getElement)();if(r(e)){const{actions:t}=yield Promise.resolve().then(o.bind(o,438));yield t.prefetch(e.href)}}},callbacks:{*prefetch(){const{url:e}=(0,t.getContext)(),{ref:n}=(0,t.getElement)();if(e&&r(n)){const{actions:e}=yield Promise.resolve().then(o.bind(o,438));yield e.prefetch(n.href)}}}},{lock:!0})})();editor-rtl.css000064400000003066147206524620007360 0ustar00.block-library-query-toolbar__popover .components-popover__content{ min-width:230px; } .block-library-query-toolbar__popover .components-popover__content .block-library-query-toolbar__popover-number-control{ margin-bottom:8px; } .wp-block-query__create-new-link{ padding:0 52px 16px 16px; } .block-library-query__pattern-selection-content .block-editor-block-patterns-list{ display:grid; grid-template-columns:1fr 1fr 1fr; grid-gap:8px; } .block-library-query__pattern-selection-content .block-editor-block-patterns-list .block-editor-block-patterns-list__list-item{ margin-bottom:0; } .block-library-query__pattern-selection-content .block-editor-block-patterns-list .block-editor-block-patterns-list__list-item .block-editor-block-preview__container{ max-height:250px; } .block-library-query-pattern__selection-modal .block-editor-block-patterns-list{ column-count:2; column-gap:24px; } @media (min-width:1280px){ .block-library-query-pattern__selection-modal .block-editor-block-patterns-list{ column-count:3; } } .block-library-query-pattern__selection-modal .block-editor-block-patterns-list .block-editor-block-patterns-list__list-item{ break-inside:avoid-column; } .block-library-query-pattern__selection-modal .block-library-query-pattern__selection-search{ background:#fff; margin-bottom:-4px; padding:16px 0; position:sticky; top:0; transform:translateY(-4px); z-index:2; } @media (min-width:600px){ .wp-block-query__enhanced-pagination-modal{ max-width:480px; } } .wp-block-query__enhanced-pagination-notice{ margin:0; }editor.min.css000064400000002677147206524620007352 0ustar00.block-library-query-toolbar__popover .components-popover__content{min-width:230px}.block-library-query-toolbar__popover .components-popover__content .block-library-query-toolbar__popover-number-control{margin-bottom:8px}.wp-block-query__create-new-link{padding:0 16px 16px 52px}.block-library-query__pattern-selection-content .block-editor-block-patterns-list{display:grid;grid-template-columns:1fr 1fr 1fr;grid-gap:8px}.block-library-query__pattern-selection-content .block-editor-block-patterns-list .block-editor-block-patterns-list__list-item{margin-bottom:0}.block-library-query__pattern-selection-content .block-editor-block-patterns-list .block-editor-block-patterns-list__list-item .block-editor-block-preview__container{max-height:250px}.block-library-query-pattern__selection-modal .block-editor-block-patterns-list{column-count:2;column-gap:24px}@media (min-width:1280px){.block-library-query-pattern__selection-modal .block-editor-block-patterns-list{column-count:3}}.block-library-query-pattern__selection-modal .block-editor-block-patterns-list .block-editor-block-patterns-list__list-item{break-inside:avoid-column}.block-library-query-pattern__selection-modal .block-library-query-pattern__selection-search{background:#fff;margin-bottom:-4px;padding:16px 0;position:sticky;top:0;transform:translateY(-4px);z-index:2}@media (min-width:600px){.wp-block-query__enhanced-pagination-modal{max-width:480px}}.wp-block-query__enhanced-pagination-notice{margin:0}editor.css000064400000003066147206524620006561 0ustar00.block-library-query-toolbar__popover .components-popover__content{ min-width:230px; } .block-library-query-toolbar__popover .components-popover__content .block-library-query-toolbar__popover-number-control{ margin-bottom:8px; } .wp-block-query__create-new-link{ padding:0 16px 16px 52px; } .block-library-query__pattern-selection-content .block-editor-block-patterns-list{ display:grid; grid-template-columns:1fr 1fr 1fr; grid-gap:8px; } .block-library-query__pattern-selection-content .block-editor-block-patterns-list .block-editor-block-patterns-list__list-item{ margin-bottom:0; } .block-library-query__pattern-selection-content .block-editor-block-patterns-list .block-editor-block-patterns-list__list-item .block-editor-block-preview__container{ max-height:250px; } .block-library-query-pattern__selection-modal .block-editor-block-patterns-list{ column-count:2; column-gap:24px; } @media (min-width:1280px){ .block-library-query-pattern__selection-modal .block-editor-block-patterns-list{ column-count:3; } } .block-library-query-pattern__selection-modal .block-editor-block-patterns-list .block-editor-block-patterns-list__list-item{ break-inside:avoid-column; } .block-library-query-pattern__selection-modal .block-library-query-pattern__selection-search{ background:#fff; margin-bottom:-4px; padding:16px 0; position:sticky; top:0; transform:translateY(-4px); z-index:2; } @media (min-width:600px){ .wp-block-query__enhanced-pagination-modal{ max-width:480px; } } .wp-block-query__enhanced-pagination-notice{ margin:0; }block.json000064400000002270147206524620006542 0ustar00{ "$schema": "https://schemas.wp.org/trunk/block.json", "apiVersion": 3, "name": "core/query", "title": "Query Loop", "category": "theme", "description": "An advanced block that allows displaying post types based on different query parameters and visual configurations.", "textdomain": "default", "attributes": { "queryId": { "type": "number" }, "query": { "type": "object", "default": { "perPage": null, "pages": 0, "offset": 0, "postType": "post", "order": "desc", "orderBy": "date", "author": "", "search": "", "exclude": [], "sticky": "", "inherit": true, "taxQuery": null, "parents": [], "format": [] } }, "tagName": { "type": "string", "default": "div" }, "namespace": { "type": "string" }, "enhancedPagination": { "type": "boolean", "default": false } }, "usesContext": [ "postType" ], "providesContext": { "queryId": "queryId", "query": "query", "displayLayout": "displayLayout", "enhancedPagination": "enhancedPagination" }, "supports": { "align": [ "wide", "full" ], "html": false, "layout": true, "interactivity": true }, "editorStyle": "wp-block-query-editor" }