import{d as t,a as i}from"./dataSchema-VwIQYPJL.js";import{l as e}from"./locale-wDcg0qDg.js";const a=`The Filters Manager manages the display, application, and modification of filters. If no filter has been applied, the Filters Manager does not render anything. Otherwise, a counter of applied filters is displayed. Upon clicking on the filters counter, a pop-up that lists such filters is displayed. Each of these can be toggled and un-toggled, removed, or it is possible to emit the request for editing it.

The Filters Manager listens to the request to add a new filter to existing ones, i.e. listens to add-filter events. A component like the Filter Drawer could be the source of such request. Applied filters are converted into a mongo-like query and propagated to other components, requesting to use such query when fetching data from the backend - that is, the query is injected into the payload of a change-query event. A component like the CRUD client listens to the change-query event and fetches data using its payload as query.
`,o=`Il Filters Manager gestisce la visualizzazione, l'applicazione e la modifica dei filtri. Se non ci sono filtri applicati, il Filters Manager non mostra nulla. Altrimenti, visualizza un contatore dei filtri attivi. Cliccando sul contatore, appare un pop-up che elenca i filtri applicati, ognuno dei quali può essere attivato/disattivato, rimosso o modificato.

Il Filters Manager ascolta le richieste di aggiunta di nuovi filtri agli esistenti, tramite eventi add-filter. Componenti come il Filter Drawer possono essere la fonte di queste richieste. I filtri applicati vengono convertiti in una query simile a quella di MongoDB e propagati ad altri componenti. Questi componenti utilizzano la query per recuperare i dati dal backend; in pratica, la query viene inclusa nel payload di un evento change-query. Un componente come il client CRUD ascolta l'evento change-query e utilizza il suo payload come query per recuperare i dati.
`,n={docLink:"https://docs.mia-platform.eu/docs/microfrontend-composer/back-kit/components/filters_manager",type:"layout",description:"Manages the display, application, and modification of filters",descriptionLong:{en:a,it:o},example:JSON.stringify({tag:"bk-filters-manager"}),label:"Filters Manager",definitions:{...t,dataSchema:i},properties:{hide:{type:"boolean",default:!1,__mia_configuration:{label:"Keep Hidden",description:"Prevents the rendered component",priority:"high"}},saveFilters:{type:"boolean",__mia_configuration:{priority:"high",label:"Save Filters",description:"If true, filters are automatically saved to local storage",attribute:"save-filters"},default:!1},bootstrapOnReconnect:{type:"boolean",default:!1,__mia_configuration:{attribute:"bootstrap-on-reconnect",label:"Bootstrap on reconnect",description:"Bootstrap the component when is reconnected to the DOM",priority:"low"}},dataSchema:{$ref:"#/definitions/dataSchema",__mia_configuration:{label:"Data Schema",attribute:!1,"shared-key":"back-kit/data-schema"}},localStorageKey:{type:"string",__mia_configuration:{priority:"low",attribute:"local-storage-key",label:"Local Storage Key",description:"key used to identify filters saved in localStorage. Defaults to a string composed of 'bk-filters-manager-storage-' and the current pathname of the current URL"}},filters:{default:[],__mia_configuration:{priority:"medium",label:"Filters",description:"Initial filters"},type:"array",items:{type:"object"}},customLocale:{__mia_configuration:{attribute:!1,label:"Custom Locale",description:"Custom localized texts shown as component labels",priority:"low"},type:"object",properties:{customFilters:e("Filters Hint"),appliedFilter:e("Applied Filter"),appliedFilters:e("Applied Filters"),toggleFilter:e("Toggle Filter Hint"),untoggleFilter:e("Untoggle Filter Hint"),deleteFilter:e("Delete Filter Hint")}}}};var s=n;export{s as default};
