@mmlogic/components 0.5.13 → 0.5.14
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/{cell-renderer-BBebjBVz.js → cell-renderer-mjS630f1.js} +8 -0
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/cjs/mosterdcomponents.cjs.js +1 -1
- package/dist/cjs/mrd-boolean-field_25.cjs.entry.js +148 -28
- package/dist/cjs/mrd-merge-view.cjs.entry.js +1 -1
- package/dist/collection/components/table/mrd-table/mrd-table.css +36 -0
- package/dist/collection/components/table/mrd-table/mrd-table.js +137 -25
- package/dist/collection/components/table/mrd-table/table-parts.js +6 -2
- package/dist/collection/components/table/mrd-table/table-query.js +6 -0
- package/dist/collection/utils/i18n.js +8 -0
- package/dist/components/i18n.js +1 -1
- package/dist/components/mrd-table2.js +1 -1
- package/dist/esm/{cell-renderer-CC8-MtvQ.js → cell-renderer-BDY8UXkH.js} +8 -0
- package/dist/esm/loader.js +1 -1
- package/dist/esm/mosterdcomponents.js +1 -1
- package/dist/esm/mrd-boolean-field_25.entry.js +148 -28
- package/dist/esm/mrd-merge-view.entry.js +1 -1
- package/dist/mosterdcomponents/cell-renderer-B8u5BCK-.js.map +1 -0
- package/dist/mosterdcomponents/client-layout-Bc42CfJB.js.map +1 -0
- package/dist/mosterdcomponents/document-attachments-BufPmMRv.js.map +1 -0
- package/dist/mosterdcomponents/field-helpers-CNQcI3Hf.js.map +1 -0
- package/dist/mosterdcomponents/file-upload-common-C9wp47CB.js.map +1 -0
- package/dist/mosterdcomponents/format-gcecItcD.js.map +1 -0
- package/dist/mosterdcomponents/i18n-ydNM87-Q.js.map +1 -0
- package/dist/mosterdcomponents/index-1ayBojyN.js.map +1 -0
- package/dist/mosterdcomponents/index-DhffneUF.js.map +1 -0
- package/dist/mosterdcomponents/index.esm.js.map +1 -0
- package/dist/mosterdcomponents/mosterdcomponents.esm.js +1 -1
- package/dist/mosterdcomponents/mosterdcomponents.esm.js.map +1 -0
- package/dist/mosterdcomponents/p-Dkm4WxMy.js +1 -0
- package/dist/mosterdcomponents/{p-07b148b2.entry.js → p-c834951a.entry.js} +2 -2
- package/dist/mosterdcomponents/{p-a7e8f6a3.entry.js → p-e8b0880f.entry.js} +1 -1
- package/dist/mosterdcomponents/purify.es-_duHfPgC.js.map +1 -0
- package/dist/mosterdcomponents/query-params-BZbQoeYF.js.map +1 -0
- package/dist/mosterdcomponents/quill-C9pgw_k-.js.map +1 -0
- package/dist/mosterdcomponents/validation-CjjTt66G.js.map +1 -0
- package/dist/types/components/table/mrd-table/mrd-table.d.ts +48 -1
- package/dist/types/components/table/mrd-table/table-parts.d.ts +15 -0
- package/dist/types/components/table/mrd-table/table-query.d.ts +6 -0
- package/package.json +1 -1
- package/dist/mosterdcomponents/p-D5ZPfX3-.js +0 -1
|
@@ -108,6 +108,7 @@ const translations = {
|
|
|
108
108
|
value_empty: '—',
|
|
109
109
|
// mrd-table toolbar
|
|
110
110
|
table_filter_clear_all: 'Alle filters wissen',
|
|
111
|
+
table_search: 'Zoeken',
|
|
111
112
|
table_new_record: 'Nieuw record',
|
|
112
113
|
table_export_excel: 'Exporteer naar Excel',
|
|
113
114
|
readonly_access: 'Je hebt alleen-leestoegang',
|
|
@@ -212,6 +213,7 @@ const translations = {
|
|
|
212
213
|
value_empty: '—',
|
|
213
214
|
// mrd-table toolbar
|
|
214
215
|
table_filter_clear_all: 'Clear all filters',
|
|
216
|
+
table_search: 'Search',
|
|
215
217
|
table_new_record: 'New record',
|
|
216
218
|
table_export_excel: 'Export to Excel',
|
|
217
219
|
readonly_access: 'You have read-only access',
|
|
@@ -316,6 +318,7 @@ const translations = {
|
|
|
316
318
|
value_empty: '—',
|
|
317
319
|
// mrd-table toolbar
|
|
318
320
|
table_filter_clear_all: 'مسح جميع الفلاتر',
|
|
321
|
+
table_search: 'بحث',
|
|
319
322
|
table_new_record: 'سجل جديد',
|
|
320
323
|
table_export_excel: 'تصدير إلى Excel',
|
|
321
324
|
readonly_access: 'لديك حق الوصول للقراءة فقط',
|
|
@@ -414,6 +417,7 @@ const translations = {
|
|
|
414
417
|
value_empty: '—',
|
|
415
418
|
// mrd-table toolbar
|
|
416
419
|
table_filter_clear_all: 'Effacer tous les filtres',
|
|
420
|
+
table_search: 'Rechercher',
|
|
417
421
|
table_new_record: 'Nouvel enregistrement',
|
|
418
422
|
table_export_excel: 'Exporter vers Excel',
|
|
419
423
|
readonly_access: "Vous disposez d'un accès en lecture seule",
|
|
@@ -512,6 +516,7 @@ const translations = {
|
|
|
512
516
|
value_empty: '—',
|
|
513
517
|
// mrd-table toolbar
|
|
514
518
|
table_filter_clear_all: 'Alle Filter löschen',
|
|
519
|
+
table_search: 'Suchen',
|
|
515
520
|
table_new_record: 'Neuer Eintrag',
|
|
516
521
|
table_export_excel: 'Als Excel exportieren',
|
|
517
522
|
readonly_access: 'Sie haben nur Lesezugriff',
|
|
@@ -610,6 +615,7 @@ const translations = {
|
|
|
610
615
|
value_empty: '—',
|
|
611
616
|
// mrd-table toolbar
|
|
612
617
|
table_filter_clear_all: 'Borrar todos los filtros',
|
|
618
|
+
table_search: 'Buscar',
|
|
613
619
|
table_new_record: 'Nuevo registro',
|
|
614
620
|
table_export_excel: 'Exportar a Excel',
|
|
615
621
|
readonly_access: 'Tienes acceso de solo lectura',
|
|
@@ -708,6 +714,7 @@ const translations = {
|
|
|
708
714
|
value_empty: '—',
|
|
709
715
|
// mrd-table toolbar
|
|
710
716
|
table_filter_clear_all: 'Cancella tutti i filtri',
|
|
717
|
+
table_search: 'Cerca',
|
|
711
718
|
table_new_record: 'Nuovo record',
|
|
712
719
|
table_export_excel: 'Esporta in Excel',
|
|
713
720
|
readonly_access: 'Hai accesso in sola lettura',
|
|
@@ -806,6 +813,7 @@ const translations = {
|
|
|
806
813
|
value_empty: '—',
|
|
807
814
|
// mrd-table toolbar
|
|
808
815
|
table_filter_clear_all: 'Очистити всі фільтри',
|
|
816
|
+
table_search: 'Пошук',
|
|
809
817
|
table_new_record: 'Новий запис',
|
|
810
818
|
table_export_excel: 'Експортувати до Excel',
|
|
811
819
|
readonly_access: 'У вас доступ лише для перегляду',
|
package/dist/cjs/loader.cjs.js
CHANGED
|
@@ -6,7 +6,7 @@ var appGlobals = require('./app-globals-V2Kpy_OQ.js');
|
|
|
6
6
|
const defineCustomElements = async (win, options) => {
|
|
7
7
|
if (typeof window === 'undefined') return undefined;
|
|
8
8
|
await appGlobals.globalScripts();
|
|
9
|
-
return index.bootstrapLazy([["mrd-merge-view.cjs",[[2,"mrd-merge-view",{"locale":[1],"basicType":[1,"basic-type"],"mostSignificantClass":[1,"most-significant-class"],"fields":[16],"currentHref":[1,"current-href"],"currentRecord":[16],"currentLabel":[1,"current-label"],"step":[32],"searchQuery":[32],"searchResults":[32],"isLoading":[32],"candidate":[32],"resolutions":[32],"openHistoryKey":[32],"setSearchResults":[64],"setLoading":[64]}]]],["mrd-boolean-field_25.cjs",[[2,"mrd-form",{"layout":[16],"locale":[1],"values":[16],"referenceHref":[1,"reference-href"],"referenceClass":[1,"reference-class"],"showCancel":[4,"show-cancel"],"me":[16],"formValues":[32],"errors":[32],"submitted":[32],"setFieldValue":[64]},null,{"values":[{"valuesChanged":0}],"me":[{"meChanged":0}]}],[2,"mrd-layout-section",{"items":[16],"data":[16],"views":[16],"links":[16],"locale":[1],"archetypes":[16],"readOnly":[4,"read-only"],"searchQueryMap":[32],"searchResultsMap":[32],"imagePreviewUrl":[32],"imagePreviews":[32],"openHistoryField":[32],"setSearchResults":[64],"setViewPage":[64],"setViewAggregations":[64],"setViewDistinct":[64],"setViewFileReference":[64],"setViewCreatedObject":[64],"setImagePreview":[64],"openImagePreview":[64]},null,{"data":[{"dataChanged":0}]}],[2,"mrd-field",{"item":[16],"locale":[1],"value":[16],"historyEntries":[32],"currentValue":[32]},null,{"value":[{"valueChanged":0}]}],[2,"mrd-document-container",{"item":[16],"archetype":[16],"parentId":[1,"parent-id"],"containerHref":[1,"container-href"],"viewKey":[1,"view-key"],"height":[2],"locale":[1],"readOnly":[4,"read-only"],"mode":[32],"canCreate":[32],"targetLabel":[32]}],[2,"mrd-document-view",{"archetype":[16],"data":[16],"locale":[1]},null,{"data":[{"dataChanged":0}]}],[2,"mrd-email-view",{"archetype":[16],"data":[16],"locale":[1]},null,{"data":[{"dataChanged":0}]}],[262,"mrd-invoice-view",{"archetype":[16],"data":[16],"locale":[1],"statusListItems":[16]},null,{"data":[{"dataChanged":0}]}],[2,"mrd-boolean-field",{"name":[1],"label":[1],"value":[4],"required":[4],"disabled":[4],"locale":[1],"checked":[32]}],[2,"mrd-currency-field",{"name":[1],"label":[1],"value":[16],"required":[4],"disabled":[4],"locale":[1],"amountDisplay":[32],"currency":[32],"error":[32]},null,{"value":[{"valueChanged":0}],"locale":[{"localeChanged":0}]}],[2,"mrd-date-field",{"name":[1],"label":[1],"value":[1],"required":[4],"disabled":[4],"locale":[1],"error":[32]}],[2,"mrd-datetime-field",{"name":[1],"label":[1],"value":[1],"required":[4],"disabled":[4],"locale":[1],"error":[32],"localValue":[32]},null,{"value":[{"valueChanged":0}]}],[2,"mrd-document-list",{"item":[16],"archetype":[16],"parentId":[1,"parent-id"],"containerHref":[1,"container-href"],"locale":[1],"readOnly":[4,"read-only"],"containers":[32],"rootLoading":[32],"singleContainer":[32],"selectedId":[32],"dropTargetId":[32],"uploadingNodeId":[32],"rootDropActive":[32],"setDistinct":[64],"setDocuments":[64],"createFolder":[64],"uploadFile":[64],"setFileReference":[64],"setCreatedHref":[64]}],[2,"mrd-email-field",{"name":[1],"label":[1],"value":[1],"placeholder":[1],"required":[4],"disabled":[4],"locale":[1],"error":[32]}],[2,"mrd-file-field",{"name":[1],"label":[1],"value":[16],"required":[4],"disabled":[4],"locale":[1],"accept":[1],"maxSize":[2,"max-size"],"multiple":[4],"entries":[32],"isDragging":[32],"error":[32]},null,{"value":[{"valueChanged":0}]}],[2,"mrd-hyperlink-field",{"name":[1],"label":[1],"value":[1],"placeholder":[1],"required":[4],"disabled":[4],"locale":[1],"internalHref":[32],"internalName":[32],"error":[32]},null,{"value":[{"valueChanged":0}]}],[2,"mrd-image-field",{"name":[1],"label":[1],"value":[16],"required":[4],"disabled":[4],"locale":[1],"accept":[1],"maxSize":[2,"max-size"],"multiple":[4],"entries":[32],"isDragging":[32],"error":[32]},null,{"value":[{"valueChanged":0}]}],[2,"mrd-list-field",{"name":[1],"label":[1],"value":[1],"required":[4],"disabled":[4],"multiple":[4],"locale":[1],"listItems":[16],"error":[32],"selected":[32]}],[2,"mrd-longtext-field",{"name":[1],"label":[1],"value":[1],"placeholder":[1],"required":[4],"disabled":[4],"locale":[1],"error":[32]}],[2,"mrd-number-field",{"name":[1],"label":[1],"value":[2],"placeholder":[1],"required":[4],"disabled":[4],"locale":[1],"dataType":[1,"data-type"],"decimalPrecision":[2,"decimal-precision"],"displayValue":[32],"error":[32]},null,{"value":[{"valueChanged":0}],"locale":[{"localeChanged":0}]}],[2,"mrd-relation-field",{"name":[1],"label":[1],"required":[4],"disabled":[4],"locale":[1],"relatedClass":[1,"related-class"],"mostSignificantClass":[1,"most-significant-class"],"displayType":[1,"display-type"],"editBehavior":[1,"edit-behavior"],"commonRelation":[1,"common-relation"],"multiple":[4],"dropdownValues":[16],"value":[1],"searchQuery":[32],"searchResults":[32],"allRecords":[32],"isLoading":[32],"selectedItems":[32],"showResults":[32],"error":[32],"highlightedIndex":[32],"setAllRecords":[64],"setSearchResults":[64],"setLoading":[64]},null,{"allRecords":[{"allRecordsChanged":0}],"value":[{"valueChanged":0}]}],[2,"mrd-secret-field",{"name":[1],"label":[1],"value":[1],"placeholder":[1],"required":[4],"disabled":[4],"locale":[1],"error":[32]}],[2,"mrd-table",{"item":[16],"parentId":[1,"parent-id"],"rows":[16],"locale":[1],"totalElements":[2,"total-elements"],"pageSize":[2,"page-size"],"rowHeight":[2,"row-height"],"tableHeight":[2,"table-height"],"requestTimeoutMs":[2,"request-timeout-ms"],"readOnly":[4,"read-only"],"activeViewIdx":[32],"loadedPages":[32],"requestedPages":[32],"failedPages":[32],"renderStart":[32],"renderEnd":[32],"colWidths":[32],"resizingCol":[32],"sortField":[32],"sortDir":[32],"activeFilters":[32],"openFilterCol":[32],"pendingFilter":[32],"popupPos":[32],"createPickerOpen":[32],"viewPopoverOpen":[32],"scrollTop":[32],"textblockModal":[32],"jsonModal":[32],"aggregations":[32],"aggregationsTotal":[32],"minKnownTotal":[32],"init":[64],"setPage":[64],"setAggregations":[64]},null,{"totalElements":[{"totalElementsChanged":0}],"item":[{"itemChanged":0}]}],[2,"mrd-text-field",{"name":[1],"label":[1],"value":[1],"placeholder":[1],"required":[4],"disabled":[4],"locale":[1],"error":[32]}],[2,"mrd-textarea-field",{"name":[1],"label":[1],"value":[1],"placeholder":[1],"required":[4],"disabled":[4],"locale":[1],"error":[32],"editorReady":[32]}],[2,"mrd-time-field",{"name":[1],"label":[1],"value":[1],"required":[4],"disabled":[4],"locale":[1],"error":[32]}]]]], options);
|
|
9
|
+
return index.bootstrapLazy([["mrd-merge-view.cjs",[[2,"mrd-merge-view",{"locale":[1],"basicType":[1,"basic-type"],"mostSignificantClass":[1,"most-significant-class"],"fields":[16],"currentHref":[1,"current-href"],"currentRecord":[16],"currentLabel":[1,"current-label"],"step":[32],"searchQuery":[32],"searchResults":[32],"isLoading":[32],"candidate":[32],"resolutions":[32],"openHistoryKey":[32],"setSearchResults":[64],"setLoading":[64]}]]],["mrd-boolean-field_25.cjs",[[2,"mrd-form",{"layout":[16],"locale":[1],"values":[16],"referenceHref":[1,"reference-href"],"referenceClass":[1,"reference-class"],"showCancel":[4,"show-cancel"],"me":[16],"formValues":[32],"errors":[32],"submitted":[32],"setFieldValue":[64]},null,{"values":[{"valuesChanged":0}],"me":[{"meChanged":0}]}],[2,"mrd-layout-section",{"items":[16],"data":[16],"views":[16],"links":[16],"locale":[1],"archetypes":[16],"readOnly":[4,"read-only"],"searchQueryMap":[32],"searchResultsMap":[32],"imagePreviewUrl":[32],"imagePreviews":[32],"openHistoryField":[32],"setSearchResults":[64],"setViewPage":[64],"setViewAggregations":[64],"setViewDistinct":[64],"setViewFileReference":[64],"setViewCreatedObject":[64],"setImagePreview":[64],"openImagePreview":[64]},null,{"data":[{"dataChanged":0}]}],[2,"mrd-field",{"item":[16],"locale":[1],"value":[16],"historyEntries":[32],"currentValue":[32]},null,{"value":[{"valueChanged":0}]}],[2,"mrd-document-container",{"item":[16],"archetype":[16],"parentId":[1,"parent-id"],"containerHref":[1,"container-href"],"viewKey":[1,"view-key"],"height":[2],"locale":[1],"readOnly":[4,"read-only"],"mode":[32],"canCreate":[32],"targetLabel":[32]}],[2,"mrd-document-view",{"archetype":[16],"data":[16],"locale":[1]},null,{"data":[{"dataChanged":0}]}],[2,"mrd-email-view",{"archetype":[16],"data":[16],"locale":[1]},null,{"data":[{"dataChanged":0}]}],[262,"mrd-invoice-view",{"archetype":[16],"data":[16],"locale":[1],"statusListItems":[16]},null,{"data":[{"dataChanged":0}]}],[2,"mrd-boolean-field",{"name":[1],"label":[1],"value":[4],"required":[4],"disabled":[4],"locale":[1],"checked":[32]}],[2,"mrd-currency-field",{"name":[1],"label":[1],"value":[16],"required":[4],"disabled":[4],"locale":[1],"amountDisplay":[32],"currency":[32],"error":[32]},null,{"value":[{"valueChanged":0}],"locale":[{"localeChanged":0}]}],[2,"mrd-date-field",{"name":[1],"label":[1],"value":[1],"required":[4],"disabled":[4],"locale":[1],"error":[32]}],[2,"mrd-datetime-field",{"name":[1],"label":[1],"value":[1],"required":[4],"disabled":[4],"locale":[1],"error":[32],"localValue":[32]},null,{"value":[{"valueChanged":0}]}],[2,"mrd-document-list",{"item":[16],"archetype":[16],"parentId":[1,"parent-id"],"containerHref":[1,"container-href"],"locale":[1],"readOnly":[4,"read-only"],"containers":[32],"rootLoading":[32],"singleContainer":[32],"selectedId":[32],"dropTargetId":[32],"uploadingNodeId":[32],"rootDropActive":[32],"setDistinct":[64],"setDocuments":[64],"createFolder":[64],"uploadFile":[64],"setFileReference":[64],"setCreatedHref":[64]}],[2,"mrd-email-field",{"name":[1],"label":[1],"value":[1],"placeholder":[1],"required":[4],"disabled":[4],"locale":[1],"error":[32]}],[2,"mrd-file-field",{"name":[1],"label":[1],"value":[16],"required":[4],"disabled":[4],"locale":[1],"accept":[1],"maxSize":[2,"max-size"],"multiple":[4],"entries":[32],"isDragging":[32],"error":[32]},null,{"value":[{"valueChanged":0}]}],[2,"mrd-hyperlink-field",{"name":[1],"label":[1],"value":[1],"placeholder":[1],"required":[4],"disabled":[4],"locale":[1],"internalHref":[32],"internalName":[32],"error":[32]},null,{"value":[{"valueChanged":0}]}],[2,"mrd-image-field",{"name":[1],"label":[1],"value":[16],"required":[4],"disabled":[4],"locale":[1],"accept":[1],"maxSize":[2,"max-size"],"multiple":[4],"entries":[32],"isDragging":[32],"error":[32]},null,{"value":[{"valueChanged":0}]}],[2,"mrd-list-field",{"name":[1],"label":[1],"value":[1],"required":[4],"disabled":[4],"multiple":[4],"locale":[1],"listItems":[16],"error":[32],"selected":[32]}],[2,"mrd-longtext-field",{"name":[1],"label":[1],"value":[1],"placeholder":[1],"required":[4],"disabled":[4],"locale":[1],"error":[32]}],[2,"mrd-number-field",{"name":[1],"label":[1],"value":[2],"placeholder":[1],"required":[4],"disabled":[4],"locale":[1],"dataType":[1,"data-type"],"decimalPrecision":[2,"decimal-precision"],"displayValue":[32],"error":[32]},null,{"value":[{"valueChanged":0}],"locale":[{"localeChanged":0}]}],[2,"mrd-relation-field",{"name":[1],"label":[1],"required":[4],"disabled":[4],"locale":[1],"relatedClass":[1,"related-class"],"mostSignificantClass":[1,"most-significant-class"],"displayType":[1,"display-type"],"editBehavior":[1,"edit-behavior"],"commonRelation":[1,"common-relation"],"multiple":[4],"dropdownValues":[16],"value":[1],"searchQuery":[32],"searchResults":[32],"allRecords":[32],"isLoading":[32],"selectedItems":[32],"showResults":[32],"error":[32],"highlightedIndex":[32],"setAllRecords":[64],"setSearchResults":[64],"setLoading":[64]},null,{"allRecords":[{"allRecordsChanged":0}],"value":[{"valueChanged":0}]}],[2,"mrd-secret-field",{"name":[1],"label":[1],"value":[1],"placeholder":[1],"required":[4],"disabled":[4],"locale":[1],"error":[32]}],[2,"mrd-table",{"item":[16],"parentId":[1,"parent-id"],"rows":[16],"locale":[1],"totalElements":[2,"total-elements"],"pageSize":[2,"page-size"],"rowHeight":[2,"row-height"],"tableHeight":[2,"table-height"],"requestTimeoutMs":[2,"request-timeout-ms"],"readOnly":[4,"read-only"],"activeViewIdx":[32],"loadedPages":[32],"requestedPages":[32],"failedPages":[32],"renderStart":[32],"renderEnd":[32],"colWidths":[32],"resizingCol":[32],"sortField":[32],"sortDir":[32],"activeFilters":[32],"searchOpen":[32],"searchQuery":[32],"openFilterCol":[32],"pendingFilter":[32],"popupPos":[32],"createPickerOpen":[32],"viewPopoverOpen":[32],"scrollTop":[32],"textblockModal":[32],"jsonModal":[32],"aggregations":[32],"aggregationsTotal":[32],"minKnownTotal":[32],"init":[64],"setPage":[64],"setAggregations":[64]},null,{"totalElements":[{"totalElementsChanged":0}],"item":[{"itemChanged":0}]}],[2,"mrd-text-field",{"name":[1],"label":[1],"value":[1],"placeholder":[1],"required":[4],"disabled":[4],"locale":[1],"error":[32]}],[2,"mrd-textarea-field",{"name":[1],"label":[1],"value":[1],"placeholder":[1],"required":[4],"disabled":[4],"locale":[1],"error":[32],"editorReady":[32]}],[2,"mrd-time-field",{"name":[1],"label":[1],"value":[1],"required":[4],"disabled":[4],"locale":[1],"error":[32]}]]]], options);
|
|
10
10
|
};
|
|
11
11
|
|
|
12
12
|
exports.setNonce = index.setNonce;
|
|
@@ -19,7 +19,7 @@ var patchBrowser = () => {
|
|
|
19
19
|
|
|
20
20
|
patchBrowser().then(async (options) => {
|
|
21
21
|
await appGlobals.globalScripts();
|
|
22
|
-
return index.bootstrapLazy([["mrd-merge-view.cjs",[[2,"mrd-merge-view",{"locale":[1],"basicType":[1,"basic-type"],"mostSignificantClass":[1,"most-significant-class"],"fields":[16],"currentHref":[1,"current-href"],"currentRecord":[16],"currentLabel":[1,"current-label"],"step":[32],"searchQuery":[32],"searchResults":[32],"isLoading":[32],"candidate":[32],"resolutions":[32],"openHistoryKey":[32],"setSearchResults":[64],"setLoading":[64]}]]],["mrd-boolean-field_25.cjs",[[2,"mrd-form",{"layout":[16],"locale":[1],"values":[16],"referenceHref":[1,"reference-href"],"referenceClass":[1,"reference-class"],"showCancel":[4,"show-cancel"],"me":[16],"formValues":[32],"errors":[32],"submitted":[32],"setFieldValue":[64]},null,{"values":[{"valuesChanged":0}],"me":[{"meChanged":0}]}],[2,"mrd-layout-section",{"items":[16],"data":[16],"views":[16],"links":[16],"locale":[1],"archetypes":[16],"readOnly":[4,"read-only"],"searchQueryMap":[32],"searchResultsMap":[32],"imagePreviewUrl":[32],"imagePreviews":[32],"openHistoryField":[32],"setSearchResults":[64],"setViewPage":[64],"setViewAggregations":[64],"setViewDistinct":[64],"setViewFileReference":[64],"setViewCreatedObject":[64],"setImagePreview":[64],"openImagePreview":[64]},null,{"data":[{"dataChanged":0}]}],[2,"mrd-field",{"item":[16],"locale":[1],"value":[16],"historyEntries":[32],"currentValue":[32]},null,{"value":[{"valueChanged":0}]}],[2,"mrd-document-container",{"item":[16],"archetype":[16],"parentId":[1,"parent-id"],"containerHref":[1,"container-href"],"viewKey":[1,"view-key"],"height":[2],"locale":[1],"readOnly":[4,"read-only"],"mode":[32],"canCreate":[32],"targetLabel":[32]}],[2,"mrd-document-view",{"archetype":[16],"data":[16],"locale":[1]},null,{"data":[{"dataChanged":0}]}],[2,"mrd-email-view",{"archetype":[16],"data":[16],"locale":[1]},null,{"data":[{"dataChanged":0}]}],[262,"mrd-invoice-view",{"archetype":[16],"data":[16],"locale":[1],"statusListItems":[16]},null,{"data":[{"dataChanged":0}]}],[2,"mrd-boolean-field",{"name":[1],"label":[1],"value":[4],"required":[4],"disabled":[4],"locale":[1],"checked":[32]}],[2,"mrd-currency-field",{"name":[1],"label":[1],"value":[16],"required":[4],"disabled":[4],"locale":[1],"amountDisplay":[32],"currency":[32],"error":[32]},null,{"value":[{"valueChanged":0}],"locale":[{"localeChanged":0}]}],[2,"mrd-date-field",{"name":[1],"label":[1],"value":[1],"required":[4],"disabled":[4],"locale":[1],"error":[32]}],[2,"mrd-datetime-field",{"name":[1],"label":[1],"value":[1],"required":[4],"disabled":[4],"locale":[1],"error":[32],"localValue":[32]},null,{"value":[{"valueChanged":0}]}],[2,"mrd-document-list",{"item":[16],"archetype":[16],"parentId":[1,"parent-id"],"containerHref":[1,"container-href"],"locale":[1],"readOnly":[4,"read-only"],"containers":[32],"rootLoading":[32],"singleContainer":[32],"selectedId":[32],"dropTargetId":[32],"uploadingNodeId":[32],"rootDropActive":[32],"setDistinct":[64],"setDocuments":[64],"createFolder":[64],"uploadFile":[64],"setFileReference":[64],"setCreatedHref":[64]}],[2,"mrd-email-field",{"name":[1],"label":[1],"value":[1],"placeholder":[1],"required":[4],"disabled":[4],"locale":[1],"error":[32]}],[2,"mrd-file-field",{"name":[1],"label":[1],"value":[16],"required":[4],"disabled":[4],"locale":[1],"accept":[1],"maxSize":[2,"max-size"],"multiple":[4],"entries":[32],"isDragging":[32],"error":[32]},null,{"value":[{"valueChanged":0}]}],[2,"mrd-hyperlink-field",{"name":[1],"label":[1],"value":[1],"placeholder":[1],"required":[4],"disabled":[4],"locale":[1],"internalHref":[32],"internalName":[32],"error":[32]},null,{"value":[{"valueChanged":0}]}],[2,"mrd-image-field",{"name":[1],"label":[1],"value":[16],"required":[4],"disabled":[4],"locale":[1],"accept":[1],"maxSize":[2,"max-size"],"multiple":[4],"entries":[32],"isDragging":[32],"error":[32]},null,{"value":[{"valueChanged":0}]}],[2,"mrd-list-field",{"name":[1],"label":[1],"value":[1],"required":[4],"disabled":[4],"multiple":[4],"locale":[1],"listItems":[16],"error":[32],"selected":[32]}],[2,"mrd-longtext-field",{"name":[1],"label":[1],"value":[1],"placeholder":[1],"required":[4],"disabled":[4],"locale":[1],"error":[32]}],[2,"mrd-number-field",{"name":[1],"label":[1],"value":[2],"placeholder":[1],"required":[4],"disabled":[4],"locale":[1],"dataType":[1,"data-type"],"decimalPrecision":[2,"decimal-precision"],"displayValue":[32],"error":[32]},null,{"value":[{"valueChanged":0}],"locale":[{"localeChanged":0}]}],[2,"mrd-relation-field",{"name":[1],"label":[1],"required":[4],"disabled":[4],"locale":[1],"relatedClass":[1,"related-class"],"mostSignificantClass":[1,"most-significant-class"],"displayType":[1,"display-type"],"editBehavior":[1,"edit-behavior"],"commonRelation":[1,"common-relation"],"multiple":[4],"dropdownValues":[16],"value":[1],"searchQuery":[32],"searchResults":[32],"allRecords":[32],"isLoading":[32],"selectedItems":[32],"showResults":[32],"error":[32],"highlightedIndex":[32],"setAllRecords":[64],"setSearchResults":[64],"setLoading":[64]},null,{"allRecords":[{"allRecordsChanged":0}],"value":[{"valueChanged":0}]}],[2,"mrd-secret-field",{"name":[1],"label":[1],"value":[1],"placeholder":[1],"required":[4],"disabled":[4],"locale":[1],"error":[32]}],[2,"mrd-table",{"item":[16],"parentId":[1,"parent-id"],"rows":[16],"locale":[1],"totalElements":[2,"total-elements"],"pageSize":[2,"page-size"],"rowHeight":[2,"row-height"],"tableHeight":[2,"table-height"],"requestTimeoutMs":[2,"request-timeout-ms"],"readOnly":[4,"read-only"],"activeViewIdx":[32],"loadedPages":[32],"requestedPages":[32],"failedPages":[32],"renderStart":[32],"renderEnd":[32],"colWidths":[32],"resizingCol":[32],"sortField":[32],"sortDir":[32],"activeFilters":[32],"openFilterCol":[32],"pendingFilter":[32],"popupPos":[32],"createPickerOpen":[32],"viewPopoverOpen":[32],"scrollTop":[32],"textblockModal":[32],"jsonModal":[32],"aggregations":[32],"aggregationsTotal":[32],"minKnownTotal":[32],"init":[64],"setPage":[64],"setAggregations":[64]},null,{"totalElements":[{"totalElementsChanged":0}],"item":[{"itemChanged":0}]}],[2,"mrd-text-field",{"name":[1],"label":[1],"value":[1],"placeholder":[1],"required":[4],"disabled":[4],"locale":[1],"error":[32]}],[2,"mrd-textarea-field",{"name":[1],"label":[1],"value":[1],"placeholder":[1],"required":[4],"disabled":[4],"locale":[1],"error":[32],"editorReady":[32]}],[2,"mrd-time-field",{"name":[1],"label":[1],"value":[1],"required":[4],"disabled":[4],"locale":[1],"error":[32]}]]]], options);
|
|
22
|
+
return index.bootstrapLazy([["mrd-merge-view.cjs",[[2,"mrd-merge-view",{"locale":[1],"basicType":[1,"basic-type"],"mostSignificantClass":[1,"most-significant-class"],"fields":[16],"currentHref":[1,"current-href"],"currentRecord":[16],"currentLabel":[1,"current-label"],"step":[32],"searchQuery":[32],"searchResults":[32],"isLoading":[32],"candidate":[32],"resolutions":[32],"openHistoryKey":[32],"setSearchResults":[64],"setLoading":[64]}]]],["mrd-boolean-field_25.cjs",[[2,"mrd-form",{"layout":[16],"locale":[1],"values":[16],"referenceHref":[1,"reference-href"],"referenceClass":[1,"reference-class"],"showCancel":[4,"show-cancel"],"me":[16],"formValues":[32],"errors":[32],"submitted":[32],"setFieldValue":[64]},null,{"values":[{"valuesChanged":0}],"me":[{"meChanged":0}]}],[2,"mrd-layout-section",{"items":[16],"data":[16],"views":[16],"links":[16],"locale":[1],"archetypes":[16],"readOnly":[4,"read-only"],"searchQueryMap":[32],"searchResultsMap":[32],"imagePreviewUrl":[32],"imagePreviews":[32],"openHistoryField":[32],"setSearchResults":[64],"setViewPage":[64],"setViewAggregations":[64],"setViewDistinct":[64],"setViewFileReference":[64],"setViewCreatedObject":[64],"setImagePreview":[64],"openImagePreview":[64]},null,{"data":[{"dataChanged":0}]}],[2,"mrd-field",{"item":[16],"locale":[1],"value":[16],"historyEntries":[32],"currentValue":[32]},null,{"value":[{"valueChanged":0}]}],[2,"mrd-document-container",{"item":[16],"archetype":[16],"parentId":[1,"parent-id"],"containerHref":[1,"container-href"],"viewKey":[1,"view-key"],"height":[2],"locale":[1],"readOnly":[4,"read-only"],"mode":[32],"canCreate":[32],"targetLabel":[32]}],[2,"mrd-document-view",{"archetype":[16],"data":[16],"locale":[1]},null,{"data":[{"dataChanged":0}]}],[2,"mrd-email-view",{"archetype":[16],"data":[16],"locale":[1]},null,{"data":[{"dataChanged":0}]}],[262,"mrd-invoice-view",{"archetype":[16],"data":[16],"locale":[1],"statusListItems":[16]},null,{"data":[{"dataChanged":0}]}],[2,"mrd-boolean-field",{"name":[1],"label":[1],"value":[4],"required":[4],"disabled":[4],"locale":[1],"checked":[32]}],[2,"mrd-currency-field",{"name":[1],"label":[1],"value":[16],"required":[4],"disabled":[4],"locale":[1],"amountDisplay":[32],"currency":[32],"error":[32]},null,{"value":[{"valueChanged":0}],"locale":[{"localeChanged":0}]}],[2,"mrd-date-field",{"name":[1],"label":[1],"value":[1],"required":[4],"disabled":[4],"locale":[1],"error":[32]}],[2,"mrd-datetime-field",{"name":[1],"label":[1],"value":[1],"required":[4],"disabled":[4],"locale":[1],"error":[32],"localValue":[32]},null,{"value":[{"valueChanged":0}]}],[2,"mrd-document-list",{"item":[16],"archetype":[16],"parentId":[1,"parent-id"],"containerHref":[1,"container-href"],"locale":[1],"readOnly":[4,"read-only"],"containers":[32],"rootLoading":[32],"singleContainer":[32],"selectedId":[32],"dropTargetId":[32],"uploadingNodeId":[32],"rootDropActive":[32],"setDistinct":[64],"setDocuments":[64],"createFolder":[64],"uploadFile":[64],"setFileReference":[64],"setCreatedHref":[64]}],[2,"mrd-email-field",{"name":[1],"label":[1],"value":[1],"placeholder":[1],"required":[4],"disabled":[4],"locale":[1],"error":[32]}],[2,"mrd-file-field",{"name":[1],"label":[1],"value":[16],"required":[4],"disabled":[4],"locale":[1],"accept":[1],"maxSize":[2,"max-size"],"multiple":[4],"entries":[32],"isDragging":[32],"error":[32]},null,{"value":[{"valueChanged":0}]}],[2,"mrd-hyperlink-field",{"name":[1],"label":[1],"value":[1],"placeholder":[1],"required":[4],"disabled":[4],"locale":[1],"internalHref":[32],"internalName":[32],"error":[32]},null,{"value":[{"valueChanged":0}]}],[2,"mrd-image-field",{"name":[1],"label":[1],"value":[16],"required":[4],"disabled":[4],"locale":[1],"accept":[1],"maxSize":[2,"max-size"],"multiple":[4],"entries":[32],"isDragging":[32],"error":[32]},null,{"value":[{"valueChanged":0}]}],[2,"mrd-list-field",{"name":[1],"label":[1],"value":[1],"required":[4],"disabled":[4],"multiple":[4],"locale":[1],"listItems":[16],"error":[32],"selected":[32]}],[2,"mrd-longtext-field",{"name":[1],"label":[1],"value":[1],"placeholder":[1],"required":[4],"disabled":[4],"locale":[1],"error":[32]}],[2,"mrd-number-field",{"name":[1],"label":[1],"value":[2],"placeholder":[1],"required":[4],"disabled":[4],"locale":[1],"dataType":[1,"data-type"],"decimalPrecision":[2,"decimal-precision"],"displayValue":[32],"error":[32]},null,{"value":[{"valueChanged":0}],"locale":[{"localeChanged":0}]}],[2,"mrd-relation-field",{"name":[1],"label":[1],"required":[4],"disabled":[4],"locale":[1],"relatedClass":[1,"related-class"],"mostSignificantClass":[1,"most-significant-class"],"displayType":[1,"display-type"],"editBehavior":[1,"edit-behavior"],"commonRelation":[1,"common-relation"],"multiple":[4],"dropdownValues":[16],"value":[1],"searchQuery":[32],"searchResults":[32],"allRecords":[32],"isLoading":[32],"selectedItems":[32],"showResults":[32],"error":[32],"highlightedIndex":[32],"setAllRecords":[64],"setSearchResults":[64],"setLoading":[64]},null,{"allRecords":[{"allRecordsChanged":0}],"value":[{"valueChanged":0}]}],[2,"mrd-secret-field",{"name":[1],"label":[1],"value":[1],"placeholder":[1],"required":[4],"disabled":[4],"locale":[1],"error":[32]}],[2,"mrd-table",{"item":[16],"parentId":[1,"parent-id"],"rows":[16],"locale":[1],"totalElements":[2,"total-elements"],"pageSize":[2,"page-size"],"rowHeight":[2,"row-height"],"tableHeight":[2,"table-height"],"requestTimeoutMs":[2,"request-timeout-ms"],"readOnly":[4,"read-only"],"activeViewIdx":[32],"loadedPages":[32],"requestedPages":[32],"failedPages":[32],"renderStart":[32],"renderEnd":[32],"colWidths":[32],"resizingCol":[32],"sortField":[32],"sortDir":[32],"activeFilters":[32],"searchOpen":[32],"searchQuery":[32],"openFilterCol":[32],"pendingFilter":[32],"popupPos":[32],"createPickerOpen":[32],"viewPopoverOpen":[32],"scrollTop":[32],"textblockModal":[32],"jsonModal":[32],"aggregations":[32],"aggregationsTotal":[32],"minKnownTotal":[32],"init":[64],"setPage":[64],"setAggregations":[64]},null,{"totalElements":[{"totalElementsChanged":0}],"item":[{"itemChanged":0}]}],[2,"mrd-text-field",{"name":[1],"label":[1],"value":[1],"placeholder":[1],"required":[4],"disabled":[4],"locale":[1],"error":[32]}],[2,"mrd-textarea-field",{"name":[1],"label":[1],"value":[1],"placeholder":[1],"required":[4],"disabled":[4],"locale":[1],"error":[32],"editorReady":[32]}],[2,"mrd-time-field",{"name":[1],"label":[1],"value":[1],"required":[4],"disabled":[4],"locale":[1],"error":[32]}]]]], options);
|
|
23
23
|
});
|
|
24
24
|
|
|
25
25
|
exports.setNonce = index.setNonce;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
3
|
var index = require('./index-DVbdkYO3.js');
|
|
4
|
-
var cellRenderer = require('./cell-renderer-
|
|
4
|
+
var cellRenderer = require('./cell-renderer-mjS630f1.js');
|
|
5
5
|
var clientLayout = require('./client-layout-CqVuJumR.js');
|
|
6
6
|
|
|
7
7
|
const mrdBooleanFieldCss = () => `.sc-mrd-boolean-field-h{display:block}.mrd-boolean-field.sc-mrd-boolean-field{display:flex;align-items:center;width:100%}.mrd-boolean-field__toggle-label.sc-mrd-boolean-field{display:flex;align-items:center;gap:var(--mrd-space-3);cursor:pointer;user-select:none}.mrd-boolean-field__checkbox.sc-mrd-boolean-field{position:absolute;opacity:0;width:0;height:0;pointer-events:none}.mrd-boolean-field__checkbox.sc-mrd-boolean-field:checked+.mrd-boolean-field__toggle.sc-mrd-boolean-field{background-color:var(--mrd-color-primary)}.mrd-boolean-field__checkbox.sc-mrd-boolean-field:checked+.mrd-boolean-field__toggle.sc-mrd-boolean-field::after{transform:translateX(20px)}.mrd-boolean-field__checkbox.sc-mrd-boolean-field:focus+.mrd-boolean-field__toggle.sc-mrd-boolean-field{box-shadow:var(--mrd-shadow-focus)}.mrd-boolean-field__checkbox.sc-mrd-boolean-field:disabled+.mrd-boolean-field__toggle.sc-mrd-boolean-field{opacity:0.5;cursor:not-allowed}.mrd-boolean-field__toggle.sc-mrd-boolean-field{position:relative;display:inline-block;width:44px;height:24px;background-color:var(--mrd-color-neutral-300);border-radius:var(--mrd-border-radius-full);transition:background-color var(--mrd-transition);flex-shrink:0}.mrd-boolean-field__toggle.sc-mrd-boolean-field::after{content:"";position:absolute;top:2px;left:2px;width:20px;height:20px;background-color:var(--mrd-color-white);border-radius:50%;transition:transform var(--mrd-transition);box-shadow:var(--mrd-shadow-sm)}.mrd-boolean-field__text.sc-mrd-boolean-field{font-family:var(--mrd-font-family);font-size:var(--mrd-font-size-base);color:var(--mrd-color-neutral-800)}.mrd-boolean-field__text--required.sc-mrd-boolean-field::after{content:" *";color:var(--mrd-color-danger)}`;
|
|
@@ -6223,6 +6223,10 @@ const DATE_TYPES = new Set(['DATE', 'DATETIME', 'TIME']);
|
|
|
6223
6223
|
const NO_FILTER_TYPES = new Set(['FILE', 'IMAGE']);
|
|
6224
6224
|
/** Column types that cannot be sorted or filtered (not stored in PostgreSQL). */
|
|
6225
6225
|
const NON_INTERACTIVE_TYPES = new Set(['LONGTEXT', 'JSON', 'FILE', 'IMAGE']);
|
|
6226
|
+
/** Wait this long (ms) after the user stops typing in the free-text search box
|
|
6227
|
+
* before firing the search request — mirrors REQUEST_DEBOUNCE_MS's purpose
|
|
6228
|
+
* (skip intermediate keystrokes) but is tuned for typing, not scrolling. */
|
|
6229
|
+
const SEARCH_DEBOUNCE_MS = 400;
|
|
6226
6230
|
function parseDefaultSort(defaultSort) {
|
|
6227
6231
|
var _a;
|
|
6228
6232
|
if (!defaultSort)
|
|
@@ -6247,6 +6251,8 @@ function buildTableQueryParams(opts) {
|
|
|
6247
6251
|
if (opts.filterClass)
|
|
6248
6252
|
p.set('type', opts.filterClass);
|
|
6249
6253
|
applyViewFilters(p, opts.viewFilters);
|
|
6254
|
+
if (opts.query)
|
|
6255
|
+
p.set('q', opts.query);
|
|
6250
6256
|
for (const f of opts.activeFilters) {
|
|
6251
6257
|
if (f.operator === 'isEmpty') {
|
|
6252
6258
|
p.set(f.field, '');
|
|
@@ -6396,6 +6402,7 @@ function datetimeFilterToDisplay(existing) {
|
|
|
6396
6402
|
* component; these components receive plain values and callbacks.
|
|
6397
6403
|
*/
|
|
6398
6404
|
const FilterIcon = () => (index.h("span", { class: "mrd-table__filter-icon", "aria-hidden": "true" }, index.h("svg", { viewBox: "0 0 24 24", width: "14", height: "14", fill: "currentColor" }, index.h("path", { d: "M10 18h4v-2h-4v2zM3 6v2h18V6H3zm3 7h12v-2H6v2z" }))));
|
|
6405
|
+
const SearchIcon = ({ class: cls }) => (index.h("svg", { class: cls, viewBox: "0 0 24 24", width: "16", height: "16", "aria-hidden": "true" }, index.h("path", { fill: "currentColor", d: "M15.5 14h-.79l-.28-.27a6.5 6.5 0 1 0-.7.7l.27.28v.79l5 4.99L20.49 19zM9.5 14A4.5 4.5 0 1 1 14 9.5 4.5 4.5 0 0 1 9.5 14" })));
|
|
6399
6406
|
const TEXTBLOCK_MAX = 200;
|
|
6400
6407
|
const TableCell = ({ col, row, locale, onDownload, onOpenTextblock, onOpenJson }) => {
|
|
6401
6408
|
var _a, _b, _c;
|
|
@@ -6475,11 +6482,14 @@ const JsonModal = ({ html, locale, onClose }) => {
|
|
|
6475
6482
|
return null;
|
|
6476
6483
|
return (index.h("div", { class: "mrd-table__modal-backdrop", onClick: onClose, role: "dialog", "aria-modal": "true" }, index.h("div", { class: "mrd-table__modal", onClick: (e) => e.stopPropagation() }, index.h("button", { class: "mrd-table__modal-close", onClick: onClose, "aria-label": cellRenderer.t('close', locale) }, "\u2715"), index.h("pre", { class: "mrd-table__modal-json", innerHTML: html }))));
|
|
6477
6484
|
};
|
|
6478
|
-
const Toolbar = ({ locale, filterCount, actions, views, activeViewIdx, viewPopoverOpen, createPickerOpen, createTypes, readOnly, cb }) => {
|
|
6485
|
+
const Toolbar = ({ locale, filterCount, actions, views, activeViewIdx, viewPopoverOpen, createPickerOpen, createTypes, readOnly, searchEnabled, searchOpen, searchQuery, cb }) => {
|
|
6479
6486
|
var _a;
|
|
6480
6487
|
const hasActions = actions.length > 0;
|
|
6481
6488
|
const hasViewSwitcher = views.length > 1;
|
|
6482
|
-
return (index.h("div", { class: "mrd-table__toolbar" }, index.h("div", { class: "mrd-table__toolbar-left" },
|
|
6489
|
+
return (index.h("div", { class: "mrd-table__toolbar" }, index.h("div", { class: "mrd-table__toolbar-left" }, searchEnabled && (searchOpen ? (index.h("span", { class: "mrd-table__search-box" }, index.h(SearchIcon, null), index.h("input", { type: "text", class: "mrd-table__search-input", value: searchQuery !== null && searchQuery !== void 0 ? searchQuery : '', placeholder: cellRenderer.t('search_placeholder', locale), ref: cb.onSearchInputRef, onInput: (e) => cb.onSearchInput(e.target.value), onKeyDown: (e) => {
|
|
6490
|
+
if (e.key === 'Escape')
|
|
6491
|
+
cb.onCloseSearch();
|
|
6492
|
+
} }), index.h("button", { type: "button", class: "mrd-table__search-clear", "aria-label": cellRenderer.t('clear', locale), onClick: cb.onCloseSearch }, "\u2715"))) : (index.h("button", { type: "button", class: "mrd-table__action mrd-table__action--secondary mrd-table__search-toggle", onClick: cb.onToggleSearch }, index.h(SearchIcon, { class: "mrd-table__action-icon" }), index.h("span", { class: "mrd-table__action-tooltip" }, cellRenderer.t('table_search', locale))))), filterCount > 0 && (index.h("button", { class: "mrd-table__action mrd-table__action--secondary mrd-table__filter-clear", onClick: cb.onClearAllFilters }, index.h("svg", { class: "mrd-table__action-icon", viewBox: "0 0 24 24", "aria-hidden": "true" }, index.h("path", { fill: "currentColor", d: "M19 6.41L17.59 5 12 10.59 6.41 5 5 6.41 10.59 12 5 17.59 6.41 19 12 13.41 17.59 19 19 17.59 13.41 12z" })), index.h("span", { class: "mrd-table__filter-clear-label" }, cellRenderer.t('table_filter_clear_all', locale), " (", filterCount, ")")))), hasViewSwitcher && (index.h("div", { class: "mrd-table__toolbar-center" }, index.h("div", { class: "mrd-table__view-switcher" }, index.h("button", { class: "mrd-table__view-arrow", "aria-label": "Previous view", onClick: () => cb.onViewSwitch((activeViewIdx - 1 + views.length) % views.length) }, "\u25C0"), index.h("div", { class: "mrd-table__view-title-wrap" }, index.h("button", { class: "mrd-table__view-title", onClick: (e) => cb.onToggleViewPopover(e) }, (_a = views[activeViewIdx]) === null || _a === void 0 ? void 0 : _a.label), viewPopoverOpen && (index.h("div", { class: "mrd-table__view-popover", onClick: (e) => e.stopPropagation() }, views.map((v, i) => (index.h("button", { key: String(i), class: `mrd-table__view-popover-item${i === activeViewIdx ? ' mrd-table__view-popover-item--active' : ''}`, onClick: () => {
|
|
6483
6493
|
if (i !== activeViewIdx)
|
|
6484
6494
|
cb.onViewSwitch(i);
|
|
6485
6495
|
cb.onCloseViewPopover();
|
|
@@ -6653,7 +6663,7 @@ function getStalePages(requestedAt, now, timeoutMs) {
|
|
|
6653
6663
|
return stale;
|
|
6654
6664
|
}
|
|
6655
6665
|
|
|
6656
|
-
const mrdTableCss = () => `.sc-mrd-table-h{display:block;width:100%}.mrd-table.sc-mrd-table{overflow-x:auto}.mrd-table__scroll.sc-mrd-table{overflow-y:auto;overflow-x:auto;border:1px solid var(--mrd-border-color);border-radius:var(--mrd-border-radius);overflow-anchor:none}.mrd-table__table.sc-mrd-table{width:auto;min-width:100%;border-collapse:collapse;font-size:var(--mrd-font-size-sm);color:var(--mrd-color-neutral-900)}.mrd-table__scroll.sc-mrd-table .mrd-table__table.sc-mrd-table{min-width:max-content}.mrd-table__header.sc-mrd-table{position:sticky;top:0;z-index:1;background:var(--mrd-color-white);text-align:left;padding:var(--mrd-space-2) var(--mrd-space-4);border-bottom:2px solid var(--mrd-border-color);color:var(--mrd-color-neutral-600);font-weight:var(--mrd-font-weight-medium);white-space:nowrap;overflow:hidden;text-overflow:ellipsis;font-size:var(--mrd-font-size-xs);text-transform:uppercase;letter-spacing:0.04em}.mrd-table__header--sortable.sc-mrd-table{cursor:pointer;user-select:none}.mrd-table__header--sortable.sc-mrd-table:hover{background:var(--mrd-color-neutral-50);color:var(--mrd-color-neutral-800)}.mrd-table__header--sorted-asc.sc-mrd-table,.mrd-table__header--sorted-desc.sc-mrd-table{color:var(--mrd-color-primary);border-bottom-color:var(--mrd-color-primary)}.mrd-table__header--filtered.sc-mrd-table{color:var(--mrd-color-primary);border-bottom-color:var(--mrd-color-primary)}.mrd-table__header-label.sc-mrd-table{margin-right:var(--mrd-space-1)}.mrd-table__col-resizer.sc-mrd-table{position:absolute;top:0;right:0;width:9px;height:100%;cursor:col-resize;touch-action:none;user-select:none}.mrd-table__col-resizer.sc-mrd-table::after{content:"";position:absolute;top:25%;right:4px;width:1px;height:50%;background:var(--mrd-border-color)}.mrd-table__col-resizer.sc-mrd-table:hover::after{width:2px;right:3px;background:var(--mrd-color-primary)}.mrd-table__col-resizer--active.sc-mrd-table::after{width:2px;right:3px;height:100%;top:0;background:var(--mrd-color-primary)}.mrd-table--resizing.sc-mrd-table{cursor:col-resize;user-select:none}.mrd-table__sort-icon.sc-mrd-table{font-size:0.85rem;opacity:0.4;vertical-align:middle}.mrd-table__header--sorted-asc.sc-mrd-table .mrd-table__sort-icon.sc-mrd-table,.mrd-table__header--sorted-desc.sc-mrd-table .mrd-table__sort-icon.sc-mrd-table{opacity:1;color:var(--mrd-color-primary)}.mrd-table__filter-icon.sc-mrd-table{display:inline-flex;align-items:center;vertical-align:middle;margin-left:var(--mrd-space-1);color:var(--mrd-color-primary)}.mrd-table__row.sc-mrd-table{border-bottom:1px solid var(--mrd-border-color)}.mrd-table__row.sc-mrd-table:hover{background:var(--mrd-color-neutral-200) !important}.mrd-table__row--clickable.sc-mrd-table{cursor:pointer}.mrd-table__row--loading.sc-mrd-table{background:transparent}.mrd-table__row--failed.sc-mrd-table{background:transparent}.mrd-table__spacer.sc-mrd-table{border:none}.mrd-table__spacer.sc-mrd-table td.sc-mrd-table{padding:0;border:none}.mrd-table__cell.sc-mrd-table{padding:var(--mrd-space-2) var(--mrd-space-4);vertical-align:top;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.mrd-table__cell--numeric.sc-mrd-table{text-align:right;font-variant-numeric:tabular-nums}.mrd-table__cell--placeholder.sc-mrd-table{padding:var(--mrd-space-2) var(--mrd-space-4);border-bottom:1px solid var(--mrd-border-color)}.mrd-table__cell--failed.sc-mrd-table{padding:var(--mrd-space-2) var(--mrd-space-4);border-bottom:1px solid var(--mrd-border-color)}.mrd-table__placeholder-bar.sc-mrd-table{display:block;height:0.75rem;width:55%;border-radius:var(--mrd-border-radius-sm);background:linear-gradient(90deg, var(--mrd-color-neutral-200) 25%, var(--mrd-color-neutral-100) 50%, var(--mrd-color-neutral-200) 75%);background-size:200% 100%;animation:mrd-shimmer 1.4s ease infinite}.mrd-table__retry-button.sc-mrd-table{border:none;background:none;padding:0;color:var(--mrd-color-danger);font-size:inherit;cursor:pointer;text-decoration:underline}.mrd-table__toolbar.sc-mrd-table{display:flex;align-items:center;justify-content:space-between;padding-bottom:var(--mrd-space-2)}.mrd-table__toolbar-left.sc-mrd-table,.mrd-table__toolbar-right.sc-mrd-table{display:flex;gap:var(--mrd-space-2);align-items:center}.mrd-table__toolbar-center.sc-mrd-table{flex:1;display:flex;justify-content:center;align-items:center;gap:var(--mrd-space-1)}.mrd-table__view-switcher.sc-mrd-table{display:flex;align-items:center;gap:var(--mrd-space-1)}.mrd-table__view-arrow.sc-mrd-table{background:none;border:none;cursor:pointer;padding:0 var(--mrd-space-1);color:var(--mrd-color-neutral-500);font-size:var(--mrd-font-size-xs);line-height:1}.mrd-table__view-arrow.sc-mrd-table:hover{color:var(--mrd-color-neutral-800)}.mrd-table__view-title-wrap.sc-mrd-table{position:relative}.mrd-table__view-title.sc-mrd-table{font-size:var(--mrd-font-size-sm);font-weight:600;color:var(--mrd-color-neutral-800);font-family:var(--mrd-font-family);background:none;border:none;outline:none;cursor:pointer;padding:0 var(--mrd-space-1);max-width:220px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.mrd-table__view-title.sc-mrd-table:hover{color:var(--mrd-color-primary)}.mrd-table__view-popover.sc-mrd-table{position:absolute;top:calc(100% + var(--mrd-space-1));left:50%;transform:translateX(-50%);background:var(--mrd-color-white);border:1px solid var(--mrd-color-neutral-200);border-radius:var(--mrd-radius-md);box-shadow:var(--mrd-shadow-md);z-index:100;min-width:160px;padding:var(--mrd-space-1) 0}.mrd-table__view-popover-item.sc-mrd-table{display:block;width:100%;text-align:left;background:none;border:none;cursor:pointer;padding:var(--mrd-space-2) var(--mrd-space-3);font-size:var(--mrd-font-size-sm);font-family:var(--mrd-font-family);color:var(--mrd-color-neutral-700);white-space:nowrap}.mrd-table__view-popover-item.sc-mrd-table:hover{background:var(--mrd-color-neutral-50)}.mrd-table__view-popover-item--active.sc-mrd-table{font-weight:600;color:var(--mrd-color-primary)}.mrd-table__action.sc-mrd-table{position:relative;display:inline-flex;align-items:center;justify-content:center;width:2rem;height:2rem;padding:0;background:transparent;border:1px solid transparent;border-radius:var(--mrd-border-radius);cursor:pointer;color:var(--mrd-color-neutral-400);transition:background-color 0.15s, border-color 0.15s, color 0.15s}.mrd-table__action.sc-mrd-table:hover{background-color:var(--mrd-color-neutral-100);border-color:var(--mrd-color-neutral-300);color:var(--mrd-color-neutral-700)}.mrd-table__action.sc-mrd-table:hover .mrd-table__action-tooltip.sc-mrd-table{display:block}.mrd-table__action.sc-mrd-table:disabled{opacity:0.4;cursor:not-allowed}.mrd-table__action--primary.sc-mrd-table{color:var(--mrd-color-neutral-500)}.mrd-table__action--primary.sc-mrd-table:hover{background:var(--mrd-color-primary);border-color:var(--mrd-color-primary);color:var(--mrd-color-white)}.mrd-table__action--danger.sc-mrd-table{color:var(--mrd-color-error)}.mrd-table__action--danger.sc-mrd-table:hover{background-color:var(--mrd-color-error-light, #fef2f2);border-color:var(--mrd-color-error)}.mrd-table__action-icon.sc-mrd-table{width:1.25rem;height:1.25rem;pointer-events:none;fill:currentColor}.mrd-table__action-tooltip.sc-mrd-table{display:none;position:absolute;bottom:calc(100% + 6px);right:0;padding:var(--mrd-space-1) var(--mrd-space-2);font-size:var(--mrd-font-size-xs);white-space:nowrap;background:var(--mrd-color-tooltip, #fffce1);color:var(--mrd-color-neutral-900);border:1px solid var(--mrd-border-color);border-radius:var(--mrd-border-radius-sm, var(--mrd-border-radius));pointer-events:none;z-index:10}.mrd-table__create-picker-wrap.sc-mrd-table{position:relative}.mrd-table__create-picker.sc-mrd-table{position:absolute;right:0;top:calc(100% + 4px);background:var(--mrd-color-white, #fff);border:1px solid var(--mrd-border-color);border-radius:var(--mrd-border-radius);box-shadow:var(--mrd-shadow-md, 0 4px 12px rgba(0, 0, 0, 0.12));z-index:10;min-width:10rem;padding:var(--mrd-space-1) 0}.mrd-table__create-picker-item.sc-mrd-table{display:block;width:100%;text-align:left;padding:var(--mrd-space-2) var(--mrd-space-3);background:none;border:none;cursor:pointer;font-size:var(--mrd-font-size-sm);font-family:var(--mrd-font-family);color:var(--mrd-color-neutral-800)}.mrd-table__create-picker-item.sc-mrd-table:hover{background:var(--mrd-color-neutral-50);color:var(--mrd-color-neutral-900)}.mrd-table__filter-clear.sc-mrd-table{width:auto;gap:var(--mrd-space-1);padding:0 var(--mrd-space-2);color:var(--mrd-color-primary);border-color:var(--mrd-color-primary)}.mrd-table__filter-clear.sc-mrd-table:hover{color:var(--mrd-color-primary);border-color:var(--mrd-color-primary)}.mrd-table__filter-clear-label.sc-mrd-table{font-size:var(--mrd-font-size-sm);white-space:nowrap}.mrd-table__filter-popup.sc-mrd-table{position:fixed;width:280px;background:var(--mrd-color-white);border:1px solid var(--mrd-border-color);border-radius:var(--mrd-border-radius);box-shadow:var(--mrd-shadow-md, 0 4px 12px rgba(0, 0, 0, 0.12));z-index:var(--mrd-z-dropdown, 200);font-size:var(--mrd-font-size-sm)}.mrd-table__filter-popup-header.sc-mrd-table{display:flex;align-items:center;justify-content:space-between;padding:var(--mrd-space-2) var(--mrd-space-3);border-bottom:1px solid var(--mrd-border-color)}.mrd-table__filter-popup-title.sc-mrd-table{font-weight:var(--mrd-font-weight-medium);color:var(--mrd-color-neutral-800);font-size:var(--mrd-font-size-sm)}.mrd-table__filter-close.sc-mrd-table{background:transparent;border:none;cursor:pointer;color:var(--mrd-color-neutral-500);font-size:0.9rem;padding:2px 4px;border-radius:3px;line-height:1}.mrd-table__filter-close.sc-mrd-table:hover{background:var(--mrd-color-neutral-100);color:var(--mrd-color-neutral-800)}.mrd-table__filter-section.sc-mrd-table{padding:var(--mrd-space-2) var(--mrd-space-3)}.mrd-table__filter-section-label.sc-mrd-table{font-size:var(--mrd-font-size-xs);font-weight:var(--mrd-font-weight-medium);text-transform:uppercase;letter-spacing:0.04em;color:var(--mrd-color-neutral-500);margin-bottom:var(--mrd-space-2)}.mrd-table__filter-sort-buttons.sc-mrd-table{display:flex;gap:var(--mrd-space-2)}.mrd-table__filter-sort-btn.sc-mrd-table{flex:1;padding:var(--mrd-space-1) var(--mrd-space-2);background:transparent;border:1px solid var(--mrd-border-color);border-radius:var(--mrd-border-radius);cursor:pointer;font-size:var(--mrd-font-size-xs);color:var(--mrd-color-neutral-700)}.mrd-table__filter-sort-btn.sc-mrd-table:hover{background:var(--mrd-color-neutral-100)}.mrd-table__filter-sort-btn--active.sc-mrd-table{background:var(--mrd-color-primary);border-color:var(--mrd-color-primary);color:var(--mrd-color-white)}.mrd-table__filter-divider.sc-mrd-table{height:1px;background:var(--mrd-border-color);margin:0}.mrd-table__filter-editor.sc-mrd-table{display:flex;flex-direction:column;gap:var(--mrd-space-2)}.mrd-table__filter-select.sc-mrd-table,.mrd-table__filter-input.sc-mrd-table{width:100%;padding:var(--mrd-space-1) var(--mrd-space-2);border:1px solid var(--mrd-border-color);border-radius:var(--mrd-border-radius);font-size:var(--mrd-font-size-sm);color:var(--mrd-color-neutral-900);background:var(--mrd-color-white);box-sizing:border-box}.mrd-table__filter-select.sc-mrd-table:focus,.mrd-table__filter-input.sc-mrd-table:focus{outline:none;border-color:var(--mrd-color-primary);box-shadow:0 0 0 2px rgba(0, 0, 0, 0.06)}.mrd-table__filter-range.sc-mrd-table{display:flex;align-items:center;gap:var(--mrd-space-1)}.mrd-table__filter-range.sc-mrd-table .mrd-table__filter-input.sc-mrd-table{flex:1;min-width:0}.mrd-table__filter-range--stacked.sc-mrd-table{flex-direction:column;align-items:stretch;gap:var(--mrd-space-2)}.mrd-table__filter-range-sep.sc-mrd-table{color:var(--mrd-color-neutral-400);flex-shrink:0}.mrd-table__filter-range-label.sc-mrd-table{font-size:var(--mrd-font-size-xs);color:var(--mrd-color-neutral-500);margin-bottom:2px}.mrd-table__filter-radio-group.sc-mrd-table{display:flex;flex-direction:column;gap:var(--mrd-space-1)}.mrd-table__filter-radio-group--inline.sc-mrd-table{flex-direction:row;gap:var(--mrd-space-3)}.mrd-table__filter-radio-label.sc-mrd-table{display:flex;align-items:center;gap:var(--mrd-space-1);cursor:pointer;font-size:var(--mrd-font-size-sm);color:var(--mrd-color-neutral-800)}.mrd-table__filter-list.sc-mrd-table{display:flex;flex-direction:column;gap:var(--mrd-space-1);max-height:180px;overflow-y:auto}.mrd-table__filter-list-controls.sc-mrd-table{display:flex;gap:var(--mrd-space-2);margin-bottom:var(--mrd-space-1)}.mrd-table__filter-list-btn.sc-mrd-table{font-size:var(--mrd-font-size-xs);color:var(--mrd-color-primary);background:transparent;border:none;cursor:pointer;padding:0;text-decoration:underline}.mrd-table__filter-checkbox-label.sc-mrd-table{display:flex;align-items:center;gap:var(--mrd-space-1);cursor:pointer;font-size:var(--mrd-font-size-sm);color:var(--mrd-color-neutral-800)}.mrd-table__filter-no-support.sc-mrd-table{font-size:var(--mrd-font-size-sm);color:var(--mrd-color-neutral-500);margin:0;font-style:italic}.mrd-table__filter-popup-footer.sc-mrd-table{display:flex;justify-content:flex-end;gap:var(--mrd-space-2);padding:var(--mrd-space-2) var(--mrd-space-3);border-top:1px solid var(--mrd-border-color)}.mrd-table__filter-btn.sc-mrd-table{padding:var(--mrd-space-1) var(--mrd-space-3);border-radius:var(--mrd-border-radius);border:1px solid var(--mrd-border-color);font-size:var(--mrd-font-size-sm);cursor:pointer}.mrd-table__filter-btn--clear.sc-mrd-table{background:transparent;color:var(--mrd-color-neutral-600)}.mrd-table__filter-btn--clear.sc-mrd-table:hover{background:var(--mrd-color-neutral-100)}.mrd-table__filter-btn--apply.sc-mrd-table{background:var(--mrd-color-primary);border-color:var(--mrd-color-primary);color:var(--mrd-color-white)}.mrd-table__filter-btn--apply.sc-mrd-table:hover{background:var(--mrd-color-primary-dark, var(--mrd-color-primary));border-color:var(--mrd-color-primary-dark, var(--mrd-color-primary))}.mrd-table__totals-row.sc-mrd-table{border-top:2px solid var(--mrd-border-color)}.mrd-table__totals-cell.sc-mrd-table{position:sticky;bottom:0;z-index:2;padding:var(--mrd-space-2) var(--mrd-space-4);background:var(--mrd-color-white);font-weight:var(--mrd-font-weight-medium);font-variant-numeric:tabular-nums;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;border-top:2px solid var(--mrd-border-color)}.mrd-table__totals-cell--numeric.sc-mrd-table{text-align:right}.mrd-table__footer.sc-mrd-table{padding:var(--mrd-space-1) var(--mrd-space-2);font-size:var(--mrd-font-size-xs);color:var(--mrd-color-neutral-500);text-align:right}.mrd-table__empty.sc-mrd-table{padding:var(--mrd-space-4) var(--mrd-space-3);color:var(--mrd-color-neutral-500);font-size:var(--mrd-font-size-sm);text-align:center;margin:0}.mrd-table__file-btn.sc-mrd-table{display:inline-flex;align-items:center;gap:var(--mrd-space-1);background:none;border:none;padding:0;cursor:pointer;color:var(--mrd-color-primary);font-size:var(--mrd-font-size-sm);font-family:inherit;max-width:100%;overflow:hidden}.mrd-table__file-btn.sc-mrd-table:hover{text-decoration:underline;color:var(--mrd-color-primary-dark)}.mrd-table__file-icon.sc-mrd-table{flex-shrink:0;width:1rem;height:1rem}.mrd-table__textblock-btn.sc-mrd-table{display:inline;background:none;border:none;padding:0 0 0 var(--mrd-space-1);cursor:pointer;color:var(--mrd-color-primary);font-size:var(--mrd-font-size-sm);font-family:inherit;line-height:inherit;vertical-align:middle}.mrd-table__textblock-btn.sc-mrd-table:hover{color:var(--mrd-color-primary-dark)}.mrd-table__modal-backdrop.sc-mrd-table{position:fixed;inset:0;background:rgba(0, 0, 0, 0.4);z-index:var(--mrd-z-modal, 300);display:flex;align-items:center;justify-content:center}.mrd-table__modal.sc-mrd-table{background:#fff;border-radius:var(--mrd-radius-md, 0.5rem);padding:var(--mrd-space-6);max-width:min(600px, 90vw);max-height:70vh;overflow-y:auto;position:relative;box-shadow:var(--mrd-shadow-lg)}.mrd-table__modal-close.sc-mrd-table{position:absolute;top:var(--mrd-space-3);right:var(--mrd-space-3);background:none;border:none;cursor:pointer;font-size:1.25rem;line-height:1;color:var(--mrd-color-text-muted, #6b7280);padding:0}.mrd-table__modal-close.sc-mrd-table:hover{color:var(--mrd-color-text, #111827)}.mrd-table__modal-text.sc-mrd-table{margin:0;padding-right:var(--mrd-space-6);white-space:pre-wrap;word-break:break-word;font-size:var(--mrd-font-size-sm);line-height:1.6}.mrd-table__json-preview.sc-mrd-table{font-family:var(--mrd-font-family-mono);font-size:var(--mrd-font-size-xs);overflow:hidden;white-space:nowrap;text-overflow:ellipsis;display:inline-block;max-width:calc(100% - 1.5rem);vertical-align:middle}.mrd-table__modal-json.sc-mrd-table{margin:0;padding-right:var(--mrd-space-6);font-family:var(--mrd-font-family-mono);font-size:var(--mrd-font-size-xs);white-space:pre-wrap;word-break:break-word;line-height:1.6;background:none;border:none}@keyframes mrd-shimmer{0%{background-position:200% 0}100%{background-position:-200% 0}}`;
|
|
6666
|
+
const mrdTableCss = () => `.sc-mrd-table-h{display:block;width:100%}.mrd-table.sc-mrd-table{overflow-x:auto}.mrd-table__scroll.sc-mrd-table{overflow-y:auto;overflow-x:auto;border:1px solid var(--mrd-border-color);border-radius:var(--mrd-border-radius);overflow-anchor:none}.mrd-table__table.sc-mrd-table{width:auto;min-width:100%;border-collapse:collapse;font-size:var(--mrd-font-size-sm);color:var(--mrd-color-neutral-900)}.mrd-table__scroll.sc-mrd-table .mrd-table__table.sc-mrd-table{min-width:max-content}.mrd-table__header.sc-mrd-table{position:sticky;top:0;z-index:1;background:var(--mrd-color-white);text-align:left;padding:var(--mrd-space-2) var(--mrd-space-4);border-bottom:2px solid var(--mrd-border-color);color:var(--mrd-color-neutral-600);font-weight:var(--mrd-font-weight-medium);white-space:nowrap;overflow:hidden;text-overflow:ellipsis;font-size:var(--mrd-font-size-xs);text-transform:uppercase;letter-spacing:0.04em}.mrd-table__header--sortable.sc-mrd-table{cursor:pointer;user-select:none}.mrd-table__header--sortable.sc-mrd-table:hover{background:var(--mrd-color-neutral-50);color:var(--mrd-color-neutral-800)}.mrd-table__header--sorted-asc.sc-mrd-table,.mrd-table__header--sorted-desc.sc-mrd-table{color:var(--mrd-color-primary);border-bottom-color:var(--mrd-color-primary)}.mrd-table__header--filtered.sc-mrd-table{color:var(--mrd-color-primary);border-bottom-color:var(--mrd-color-primary)}.mrd-table__header-label.sc-mrd-table{margin-right:var(--mrd-space-1)}.mrd-table__col-resizer.sc-mrd-table{position:absolute;top:0;right:0;width:9px;height:100%;cursor:col-resize;touch-action:none;user-select:none}.mrd-table__col-resizer.sc-mrd-table::after{content:"";position:absolute;top:25%;right:4px;width:1px;height:50%;background:var(--mrd-border-color)}.mrd-table__col-resizer.sc-mrd-table:hover::after{width:2px;right:3px;background:var(--mrd-color-primary)}.mrd-table__col-resizer--active.sc-mrd-table::after{width:2px;right:3px;height:100%;top:0;background:var(--mrd-color-primary)}.mrd-table--resizing.sc-mrd-table{cursor:col-resize;user-select:none}.mrd-table__sort-icon.sc-mrd-table{font-size:0.85rem;opacity:0.4;vertical-align:middle}.mrd-table__header--sorted-asc.sc-mrd-table .mrd-table__sort-icon.sc-mrd-table,.mrd-table__header--sorted-desc.sc-mrd-table .mrd-table__sort-icon.sc-mrd-table{opacity:1;color:var(--mrd-color-primary)}.mrd-table__filter-icon.sc-mrd-table{display:inline-flex;align-items:center;vertical-align:middle;margin-left:var(--mrd-space-1);color:var(--mrd-color-primary)}.mrd-table__row.sc-mrd-table{border-bottom:1px solid var(--mrd-border-color)}.mrd-table__row.sc-mrd-table:hover{background:var(--mrd-color-neutral-200) !important}.mrd-table__row--clickable.sc-mrd-table{cursor:pointer}.mrd-table__row--loading.sc-mrd-table{background:transparent}.mrd-table__row--failed.sc-mrd-table{background:transparent}.mrd-table__spacer.sc-mrd-table{border:none}.mrd-table__spacer.sc-mrd-table td.sc-mrd-table{padding:0;border:none}.mrd-table__cell.sc-mrd-table{padding:var(--mrd-space-2) var(--mrd-space-4);vertical-align:top;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.mrd-table__cell--numeric.sc-mrd-table{text-align:right;font-variant-numeric:tabular-nums}.mrd-table__cell--placeholder.sc-mrd-table{padding:var(--mrd-space-2) var(--mrd-space-4);border-bottom:1px solid var(--mrd-border-color)}.mrd-table__cell--failed.sc-mrd-table{padding:var(--mrd-space-2) var(--mrd-space-4);border-bottom:1px solid var(--mrd-border-color)}.mrd-table__placeholder-bar.sc-mrd-table{display:block;height:0.75rem;width:55%;border-radius:var(--mrd-border-radius-sm);background:linear-gradient(90deg, var(--mrd-color-neutral-200) 25%, var(--mrd-color-neutral-100) 50%, var(--mrd-color-neutral-200) 75%);background-size:200% 100%;animation:mrd-shimmer 1.4s ease infinite}.mrd-table__retry-button.sc-mrd-table{border:none;background:none;padding:0;color:var(--mrd-color-danger);font-size:inherit;cursor:pointer;text-decoration:underline}.mrd-table__toolbar.sc-mrd-table{display:flex;align-items:center;justify-content:space-between;padding-bottom:var(--mrd-space-2)}.mrd-table__toolbar-left.sc-mrd-table,.mrd-table__toolbar-right.sc-mrd-table{display:flex;gap:var(--mrd-space-2);align-items:center}.mrd-table__toolbar-center.sc-mrd-table{flex:1;display:flex;justify-content:center;align-items:center;gap:var(--mrd-space-1)}.mrd-table__view-switcher.sc-mrd-table{display:flex;align-items:center;gap:var(--mrd-space-1)}.mrd-table__view-arrow.sc-mrd-table{background:none;border:none;cursor:pointer;padding:0 var(--mrd-space-1);color:var(--mrd-color-neutral-500);font-size:var(--mrd-font-size-xs);line-height:1}.mrd-table__view-arrow.sc-mrd-table:hover{color:var(--mrd-color-neutral-800)}.mrd-table__view-title-wrap.sc-mrd-table{position:relative}.mrd-table__view-title.sc-mrd-table{font-size:var(--mrd-font-size-sm);font-weight:600;color:var(--mrd-color-neutral-800);font-family:var(--mrd-font-family);background:none;border:none;outline:none;cursor:pointer;padding:0 var(--mrd-space-1);max-width:220px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.mrd-table__view-title.sc-mrd-table:hover{color:var(--mrd-color-primary)}.mrd-table__view-popover.sc-mrd-table{position:absolute;top:calc(100% + var(--mrd-space-1));left:50%;transform:translateX(-50%);background:var(--mrd-color-white);border:1px solid var(--mrd-color-neutral-200);border-radius:var(--mrd-radius-md);box-shadow:var(--mrd-shadow-md);z-index:100;min-width:160px;padding:var(--mrd-space-1) 0}.mrd-table__view-popover-item.sc-mrd-table{display:block;width:100%;text-align:left;background:none;border:none;cursor:pointer;padding:var(--mrd-space-2) var(--mrd-space-3);font-size:var(--mrd-font-size-sm);font-family:var(--mrd-font-family);color:var(--mrd-color-neutral-700);white-space:nowrap}.mrd-table__view-popover-item.sc-mrd-table:hover{background:var(--mrd-color-neutral-50)}.mrd-table__view-popover-item--active.sc-mrd-table{font-weight:600;color:var(--mrd-color-primary)}.mrd-table__action.sc-mrd-table{position:relative;display:inline-flex;align-items:center;justify-content:center;width:2rem;height:2rem;padding:0;background:transparent;border:1px solid transparent;border-radius:var(--mrd-border-radius);cursor:pointer;color:var(--mrd-color-neutral-400);transition:background-color 0.15s, border-color 0.15s, color 0.15s}.mrd-table__action.sc-mrd-table:hover{background-color:var(--mrd-color-neutral-100);border-color:var(--mrd-color-neutral-300);color:var(--mrd-color-neutral-700)}.mrd-table__action.sc-mrd-table:hover .mrd-table__action-tooltip.sc-mrd-table{display:block}.mrd-table__action.sc-mrd-table:disabled{opacity:0.4;cursor:not-allowed}.mrd-table__action--primary.sc-mrd-table{color:var(--mrd-color-neutral-500)}.mrd-table__action--primary.sc-mrd-table:hover{background:var(--mrd-color-primary);border-color:var(--mrd-color-primary);color:var(--mrd-color-white)}.mrd-table__action--danger.sc-mrd-table{color:var(--mrd-color-error)}.mrd-table__action--danger.sc-mrd-table:hover{background-color:var(--mrd-color-error-light, #fef2f2);border-color:var(--mrd-color-error)}.mrd-table__action-icon.sc-mrd-table{width:1.25rem;height:1.25rem;pointer-events:none;fill:currentColor}.mrd-table__action-tooltip.sc-mrd-table{display:none;position:absolute;bottom:calc(100% + 6px);right:0;padding:var(--mrd-space-1) var(--mrd-space-2);font-size:var(--mrd-font-size-xs);white-space:nowrap;background:var(--mrd-color-tooltip, #fffce1);color:var(--mrd-color-neutral-900);border:1px solid var(--mrd-border-color);border-radius:var(--mrd-border-radius-sm, var(--mrd-border-radius));pointer-events:none;z-index:10}.mrd-table__search-box.sc-mrd-table{display:inline-flex;align-items:center;gap:var(--mrd-space-1);height:2rem;padding:0 var(--mrd-space-2);border:1px solid var(--mrd-border-color-focus, var(--mrd-color-primary));border-radius:var(--mrd-border-radius);background:var(--mrd-color-white, #fff);box-shadow:var(--mrd-shadow-focus, none);color:var(--mrd-color-neutral-400)}.mrd-table__search-input.sc-mrd-table{border:none;outline:none;background:transparent;font-size:var(--mrd-font-size-sm);font-family:var(--mrd-font-family);color:var(--mrd-color-neutral-800);width:12rem}.mrd-table__search-clear.sc-mrd-table{display:inline-flex;align-items:center;justify-content:center;background:none;border:none;padding:0;cursor:pointer;color:var(--mrd-color-neutral-400);font-size:var(--mrd-font-size-xs);line-height:1}.mrd-table__search-clear.sc-mrd-table:hover{color:var(--mrd-color-neutral-700)}.mrd-table__create-picker-wrap.sc-mrd-table{position:relative}.mrd-table__create-picker.sc-mrd-table{position:absolute;right:0;top:calc(100% + 4px);background:var(--mrd-color-white, #fff);border:1px solid var(--mrd-border-color);border-radius:var(--mrd-border-radius);box-shadow:var(--mrd-shadow-md, 0 4px 12px rgba(0, 0, 0, 0.12));z-index:10;min-width:10rem;padding:var(--mrd-space-1) 0}.mrd-table__create-picker-item.sc-mrd-table{display:block;width:100%;text-align:left;padding:var(--mrd-space-2) var(--mrd-space-3);background:none;border:none;cursor:pointer;font-size:var(--mrd-font-size-sm);font-family:var(--mrd-font-family);color:var(--mrd-color-neutral-800)}.mrd-table__create-picker-item.sc-mrd-table:hover{background:var(--mrd-color-neutral-50);color:var(--mrd-color-neutral-900)}.mrd-table__filter-clear.sc-mrd-table{width:auto;gap:var(--mrd-space-1);padding:0 var(--mrd-space-2);color:var(--mrd-color-primary);border-color:var(--mrd-color-primary)}.mrd-table__filter-clear.sc-mrd-table:hover{color:var(--mrd-color-primary);border-color:var(--mrd-color-primary)}.mrd-table__filter-clear-label.sc-mrd-table{font-size:var(--mrd-font-size-sm);white-space:nowrap}.mrd-table__filter-popup.sc-mrd-table{position:fixed;width:280px;background:var(--mrd-color-white);border:1px solid var(--mrd-border-color);border-radius:var(--mrd-border-radius);box-shadow:var(--mrd-shadow-md, 0 4px 12px rgba(0, 0, 0, 0.12));z-index:var(--mrd-z-dropdown, 200);font-size:var(--mrd-font-size-sm)}.mrd-table__filter-popup-header.sc-mrd-table{display:flex;align-items:center;justify-content:space-between;padding:var(--mrd-space-2) var(--mrd-space-3);border-bottom:1px solid var(--mrd-border-color)}.mrd-table__filter-popup-title.sc-mrd-table{font-weight:var(--mrd-font-weight-medium);color:var(--mrd-color-neutral-800);font-size:var(--mrd-font-size-sm)}.mrd-table__filter-close.sc-mrd-table{background:transparent;border:none;cursor:pointer;color:var(--mrd-color-neutral-500);font-size:0.9rem;padding:2px 4px;border-radius:3px;line-height:1}.mrd-table__filter-close.sc-mrd-table:hover{background:var(--mrd-color-neutral-100);color:var(--mrd-color-neutral-800)}.mrd-table__filter-section.sc-mrd-table{padding:var(--mrd-space-2) var(--mrd-space-3)}.mrd-table__filter-section-label.sc-mrd-table{font-size:var(--mrd-font-size-xs);font-weight:var(--mrd-font-weight-medium);text-transform:uppercase;letter-spacing:0.04em;color:var(--mrd-color-neutral-500);margin-bottom:var(--mrd-space-2)}.mrd-table__filter-sort-buttons.sc-mrd-table{display:flex;gap:var(--mrd-space-2)}.mrd-table__filter-sort-btn.sc-mrd-table{flex:1;padding:var(--mrd-space-1) var(--mrd-space-2);background:transparent;border:1px solid var(--mrd-border-color);border-radius:var(--mrd-border-radius);cursor:pointer;font-size:var(--mrd-font-size-xs);color:var(--mrd-color-neutral-700)}.mrd-table__filter-sort-btn.sc-mrd-table:hover{background:var(--mrd-color-neutral-100)}.mrd-table__filter-sort-btn--active.sc-mrd-table{background:var(--mrd-color-primary);border-color:var(--mrd-color-primary);color:var(--mrd-color-white)}.mrd-table__filter-divider.sc-mrd-table{height:1px;background:var(--mrd-border-color);margin:0}.mrd-table__filter-editor.sc-mrd-table{display:flex;flex-direction:column;gap:var(--mrd-space-2)}.mrd-table__filter-select.sc-mrd-table,.mrd-table__filter-input.sc-mrd-table{width:100%;padding:var(--mrd-space-1) var(--mrd-space-2);border:1px solid var(--mrd-border-color);border-radius:var(--mrd-border-radius);font-size:var(--mrd-font-size-sm);color:var(--mrd-color-neutral-900);background:var(--mrd-color-white);box-sizing:border-box}.mrd-table__filter-select.sc-mrd-table:focus,.mrd-table__filter-input.sc-mrd-table:focus{outline:none;border-color:var(--mrd-color-primary);box-shadow:0 0 0 2px rgba(0, 0, 0, 0.06)}.mrd-table__filter-range.sc-mrd-table{display:flex;align-items:center;gap:var(--mrd-space-1)}.mrd-table__filter-range.sc-mrd-table .mrd-table__filter-input.sc-mrd-table{flex:1;min-width:0}.mrd-table__filter-range--stacked.sc-mrd-table{flex-direction:column;align-items:stretch;gap:var(--mrd-space-2)}.mrd-table__filter-range-sep.sc-mrd-table{color:var(--mrd-color-neutral-400);flex-shrink:0}.mrd-table__filter-range-label.sc-mrd-table{font-size:var(--mrd-font-size-xs);color:var(--mrd-color-neutral-500);margin-bottom:2px}.mrd-table__filter-radio-group.sc-mrd-table{display:flex;flex-direction:column;gap:var(--mrd-space-1)}.mrd-table__filter-radio-group--inline.sc-mrd-table{flex-direction:row;gap:var(--mrd-space-3)}.mrd-table__filter-radio-label.sc-mrd-table{display:flex;align-items:center;gap:var(--mrd-space-1);cursor:pointer;font-size:var(--mrd-font-size-sm);color:var(--mrd-color-neutral-800)}.mrd-table__filter-list.sc-mrd-table{display:flex;flex-direction:column;gap:var(--mrd-space-1);max-height:180px;overflow-y:auto}.mrd-table__filter-list-controls.sc-mrd-table{display:flex;gap:var(--mrd-space-2);margin-bottom:var(--mrd-space-1)}.mrd-table__filter-list-btn.sc-mrd-table{font-size:var(--mrd-font-size-xs);color:var(--mrd-color-primary);background:transparent;border:none;cursor:pointer;padding:0;text-decoration:underline}.mrd-table__filter-checkbox-label.sc-mrd-table{display:flex;align-items:center;gap:var(--mrd-space-1);cursor:pointer;font-size:var(--mrd-font-size-sm);color:var(--mrd-color-neutral-800)}.mrd-table__filter-no-support.sc-mrd-table{font-size:var(--mrd-font-size-sm);color:var(--mrd-color-neutral-500);margin:0;font-style:italic}.mrd-table__filter-popup-footer.sc-mrd-table{display:flex;justify-content:flex-end;gap:var(--mrd-space-2);padding:var(--mrd-space-2) var(--mrd-space-3);border-top:1px solid var(--mrd-border-color)}.mrd-table__filter-btn.sc-mrd-table{padding:var(--mrd-space-1) var(--mrd-space-3);border-radius:var(--mrd-border-radius);border:1px solid var(--mrd-border-color);font-size:var(--mrd-font-size-sm);cursor:pointer}.mrd-table__filter-btn--clear.sc-mrd-table{background:transparent;color:var(--mrd-color-neutral-600)}.mrd-table__filter-btn--clear.sc-mrd-table:hover{background:var(--mrd-color-neutral-100)}.mrd-table__filter-btn--apply.sc-mrd-table{background:var(--mrd-color-primary);border-color:var(--mrd-color-primary);color:var(--mrd-color-white)}.mrd-table__filter-btn--apply.sc-mrd-table:hover{background:var(--mrd-color-primary-dark, var(--mrd-color-primary));border-color:var(--mrd-color-primary-dark, var(--mrd-color-primary))}.mrd-table__totals-row.sc-mrd-table{border-top:2px solid var(--mrd-border-color)}.mrd-table__totals-cell.sc-mrd-table{position:sticky;bottom:0;z-index:2;padding:var(--mrd-space-2) var(--mrd-space-4);background:var(--mrd-color-white);font-weight:var(--mrd-font-weight-medium);font-variant-numeric:tabular-nums;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;border-top:2px solid var(--mrd-border-color)}.mrd-table__totals-cell--numeric.sc-mrd-table{text-align:right}.mrd-table__footer.sc-mrd-table{padding:var(--mrd-space-1) var(--mrd-space-2);font-size:var(--mrd-font-size-xs);color:var(--mrd-color-neutral-500);text-align:right}.mrd-table__empty.sc-mrd-table{padding:var(--mrd-space-4) var(--mrd-space-3);color:var(--mrd-color-neutral-500);font-size:var(--mrd-font-size-sm);text-align:center;margin:0}.mrd-table__file-btn.sc-mrd-table{display:inline-flex;align-items:center;gap:var(--mrd-space-1);background:none;border:none;padding:0;cursor:pointer;color:var(--mrd-color-primary);font-size:var(--mrd-font-size-sm);font-family:inherit;max-width:100%;overflow:hidden}.mrd-table__file-btn.sc-mrd-table:hover{text-decoration:underline;color:var(--mrd-color-primary-dark)}.mrd-table__file-icon.sc-mrd-table{flex-shrink:0;width:1rem;height:1rem}.mrd-table__textblock-btn.sc-mrd-table{display:inline;background:none;border:none;padding:0 0 0 var(--mrd-space-1);cursor:pointer;color:var(--mrd-color-primary);font-size:var(--mrd-font-size-sm);font-family:inherit;line-height:inherit;vertical-align:middle}.mrd-table__textblock-btn.sc-mrd-table:hover{color:var(--mrd-color-primary-dark)}.mrd-table__modal-backdrop.sc-mrd-table{position:fixed;inset:0;background:rgba(0, 0, 0, 0.4);z-index:var(--mrd-z-modal, 300);display:flex;align-items:center;justify-content:center}.mrd-table__modal.sc-mrd-table{background:#fff;border-radius:var(--mrd-radius-md, 0.5rem);padding:var(--mrd-space-6);max-width:min(600px, 90vw);max-height:70vh;overflow-y:auto;position:relative;box-shadow:var(--mrd-shadow-lg)}.mrd-table__modal-close.sc-mrd-table{position:absolute;top:var(--mrd-space-3);right:var(--mrd-space-3);background:none;border:none;cursor:pointer;font-size:1.25rem;line-height:1;color:var(--mrd-color-text-muted, #6b7280);padding:0}.mrd-table__modal-close.sc-mrd-table:hover{color:var(--mrd-color-text, #111827)}.mrd-table__modal-text.sc-mrd-table{margin:0;padding-right:var(--mrd-space-6);white-space:pre-wrap;word-break:break-word;font-size:var(--mrd-font-size-sm);line-height:1.6}.mrd-table__json-preview.sc-mrd-table{font-family:var(--mrd-font-family-mono);font-size:var(--mrd-font-size-xs);overflow:hidden;white-space:nowrap;text-overflow:ellipsis;display:inline-block;max-width:calc(100% - 1.5rem);vertical-align:middle}.mrd-table__modal-json.sc-mrd-table{margin:0;padding-right:var(--mrd-space-6);font-family:var(--mrd-font-family-mono);font-size:var(--mrd-font-size-xs);white-space:pre-wrap;word-break:break-word;line-height:1.6;background:none;border:none}@keyframes mrd-shimmer{0%{background-position:200% 0}100%{background-position:-200% 0}}`;
|
|
6657
6667
|
|
|
6658
6668
|
/** How often (ms) to scan outstanding page requests for staleness. */
|
|
6659
6669
|
const STALE_CHECK_INTERVAL_MS = 2000;
|
|
@@ -6684,6 +6694,17 @@ const MrdTable = class {
|
|
|
6684
6694
|
this.keydownHandler = null;
|
|
6685
6695
|
this.createPickerClickHandler = null;
|
|
6686
6696
|
this.viewPopoverClickHandler = null;
|
|
6697
|
+
/** Debounce timer for the free-text search box — separate from debounceTimer
|
|
6698
|
+
* (pending-page requests), since typing and scrolling debounce independently. */
|
|
6699
|
+
this.searchDebounceTimer = null;
|
|
6700
|
+
/** The rendered search <input>, captured so it can be focused the instant it mounts. */
|
|
6701
|
+
this.searchInputEl = null;
|
|
6702
|
+
/** Set by toggleSearch() when the box just expanded; consumed and cleared in componentDidRender(). */
|
|
6703
|
+
this.searchNeedsFocus = false;
|
|
6704
|
+
/** Column filters stashed by stashFiltersForSearch() while the search box is open — the
|
|
6705
|
+
* backend can't combine `q` with column filters. Restored by restoreFiltersAfterSearch()
|
|
6706
|
+
* on close, unless the user applied a fresh filter of their own in the meantime. */
|
|
6707
|
+
this.stashedFilters = null;
|
|
6687
6708
|
/** Watches the host for gaining a box (e.g. its tab pane being shown) — see componentDidLoad. */
|
|
6688
6709
|
this.resizeObserver = null;
|
|
6689
6710
|
/** Guards against scheduling more than one column-width measurement per freeze. */
|
|
@@ -6738,6 +6759,10 @@ const MrdTable = class {
|
|
|
6738
6759
|
this.sortDir = 'asc';
|
|
6739
6760
|
/** Active filters keyed by field name. */
|
|
6740
6761
|
this.activeFilters = new Map();
|
|
6762
|
+
/** True while the toolbar's magnifying glass is expanded into the search input. */
|
|
6763
|
+
this.searchOpen = false;
|
|
6764
|
+
/** Current free-text search query — sent as `q` on every mrdLoadPage/aggregations request. */
|
|
6765
|
+
this.searchQuery = '';
|
|
6741
6766
|
/** Field name of the currently open filter popup (null = closed). */
|
|
6742
6767
|
this.openFilterCol = null;
|
|
6743
6768
|
/** Filter state being edited in the open popup. */
|
|
@@ -6791,6 +6816,11 @@ const MrdTable = class {
|
|
|
6791
6816
|
this.colWidthMeasureScheduled = false;
|
|
6792
6817
|
this.colWidthsUserSet = false;
|
|
6793
6818
|
this.fixedContentMeasured = false;
|
|
6819
|
+
// A new item is a different table (possibly not even a VIEW any more) — a leftover
|
|
6820
|
+
// query from the old one should not silently keep filtering it.
|
|
6821
|
+
this.searchOpen = false;
|
|
6822
|
+
this.searchQuery = '';
|
|
6823
|
+
this.stashedFilters = null;
|
|
6794
6824
|
}
|
|
6795
6825
|
// ── Lifecycle ──────────────────────────────────────────────────────────────
|
|
6796
6826
|
componentWillLoad() {
|
|
@@ -6898,7 +6928,12 @@ const MrdTable = class {
|
|
|
6898
6928
|
if (pageNumber === 0 && this.aggregationsPending) {
|
|
6899
6929
|
this.aggregationsPending = false;
|
|
6900
6930
|
const hasAggColumns = this.columns.some(c => c.type === 'FIELD' && c.aggregate);
|
|
6901
|
-
|
|
6931
|
+
// The aggregations endpoint doesn't support the `q` free-text param, so a request
|
|
6932
|
+
// sent while searching would silently return unfiltered totals. Leave aggregations
|
|
6933
|
+
// (and aggregationsTotal) at null instead — TotalsRow already renders nothing when
|
|
6934
|
+
// aggregations is null, so the totals row just disappears for the duration of the
|
|
6935
|
+
// search rather than showing numbers that don't match the filtered rows.
|
|
6936
|
+
if (!this.searchQuery && (!isLastPage || hasAggColumns)) {
|
|
6902
6937
|
this.emitLoadAggregations();
|
|
6903
6938
|
}
|
|
6904
6939
|
}
|
|
@@ -6937,10 +6972,18 @@ const MrdTable = class {
|
|
|
6937
6972
|
document.removeEventListener('click', this.viewPopoverClickHandler);
|
|
6938
6973
|
this.viewPopoverClickHandler = null;
|
|
6939
6974
|
}
|
|
6975
|
+
if (this.searchDebounceTimer !== null) {
|
|
6976
|
+
clearTimeout(this.searchDebounceTimer);
|
|
6977
|
+
this.searchDebounceTimer = null;
|
|
6978
|
+
}
|
|
6940
6979
|
}
|
|
6941
6980
|
componentDidRender() {
|
|
6942
6981
|
this.freezeColWidths();
|
|
6943
6982
|
this.growToFixedContent();
|
|
6983
|
+
if (this.searchNeedsFocus && this.searchInputEl) {
|
|
6984
|
+
this.searchInputEl.focus();
|
|
6985
|
+
this.searchNeedsFocus = false;
|
|
6986
|
+
}
|
|
6944
6987
|
}
|
|
6945
6988
|
/** Freeze the column widths once the first data page has rendered.
|
|
6946
6989
|
*
|
|
@@ -7259,7 +7302,13 @@ const MrdTable = class {
|
|
|
7259
7302
|
dataClass: v.dataClass,
|
|
7260
7303
|
});
|
|
7261
7304
|
}
|
|
7262
|
-
/** Build query params for a page request from current sort, view filters, filterClass and active column filters.
|
|
7305
|
+
/** Build query params for a page request from current sort, view filters, filterClass and active column filters.
|
|
7306
|
+
*
|
|
7307
|
+
* `q` and column filters are mutually exclusive on the backend — combining them breaks
|
|
7308
|
+
* the search. stashFiltersForSearch() already empties activeFilters for the duration of
|
|
7309
|
+
* a search, but this guard is the actual guarantee: even if a filter is applied through
|
|
7310
|
+
* a column header while the search box is still open (before the query is cleared),
|
|
7311
|
+
* activeFilters is dropped from the request rather than sent alongside `q`. */
|
|
7263
7312
|
buildQueryParams(page) {
|
|
7264
7313
|
var _a;
|
|
7265
7314
|
const v = this.allViews[this.activeViewIdx];
|
|
@@ -7268,7 +7317,8 @@ const MrdTable = class {
|
|
|
7268
7317
|
sort: this.sortParam(),
|
|
7269
7318
|
filterClass: v === null || v === void 0 ? void 0 : v.filterClass,
|
|
7270
7319
|
viewFilters: (_a = v === null || v === void 0 ? void 0 : v.view) === null || _a === void 0 ? void 0 : _a.filter,
|
|
7271
|
-
activeFilters: this.activeFilters.values(),
|
|
7320
|
+
activeFilters: this.searchQuery ? [] : this.activeFilters.values(),
|
|
7321
|
+
query: this.searchQuery,
|
|
7272
7322
|
});
|
|
7273
7323
|
}
|
|
7274
7324
|
/** True when the table is in paginated / virtual-scroll mode rather than driven by the
|
|
@@ -7574,6 +7624,18 @@ const MrdTable = class {
|
|
|
7574
7624
|
const current = (_b = (_a = this.pendingFilter) === null || _a === void 0 ? void 0 : _a.values) !== null && _b !== void 0 ? _b : [];
|
|
7575
7625
|
this.pendingFilter = Object.assign(Object.assign({}, this.pendingFilter), { values: checked ? [...current, key] : current.filter(k => k !== key) });
|
|
7576
7626
|
}
|
|
7627
|
+
/** Common reload after activeFilters or searchQuery changed: drop stale aggregations
|
|
7628
|
+
* (the next setPage(0) re-requests them, guarded against `q` in setPage() itself) and
|
|
7629
|
+
* re-fetch page 0. Shared by the filter popup, clear-all, and free-text search. */
|
|
7630
|
+
reloadAfterQueryChange() {
|
|
7631
|
+
this.aggregations = null;
|
|
7632
|
+
this.aggregationsTotal = null;
|
|
7633
|
+
this.aggregationsPending = true;
|
|
7634
|
+
if (this.isPaginated) {
|
|
7635
|
+
this.resetPages();
|
|
7636
|
+
this.emitPagesForWindow(this.renderStart, this.renderEnd);
|
|
7637
|
+
}
|
|
7638
|
+
}
|
|
7577
7639
|
applyFilter() {
|
|
7578
7640
|
const f = this.pendingFilter;
|
|
7579
7641
|
if (!(f === null || f === void 0 ? void 0 : f.field)) {
|
|
@@ -7590,13 +7652,7 @@ const MrdTable = class {
|
|
|
7590
7652
|
}
|
|
7591
7653
|
this.activeFilters = next;
|
|
7592
7654
|
this.closeFilterPopup();
|
|
7593
|
-
this.
|
|
7594
|
-
this.aggregationsTotal = null;
|
|
7595
|
-
this.aggregationsPending = true;
|
|
7596
|
-
if (this.isPaginated) {
|
|
7597
|
-
this.resetPages();
|
|
7598
|
-
this.emitPagesForWindow(this.renderStart, this.renderEnd);
|
|
7599
|
-
}
|
|
7655
|
+
this.reloadAfterQueryChange();
|
|
7600
7656
|
}
|
|
7601
7657
|
clearFilter() {
|
|
7602
7658
|
const name = this.openFilterCol;
|
|
@@ -7605,24 +7661,81 @@ const MrdTable = class {
|
|
|
7605
7661
|
next.delete(name);
|
|
7606
7662
|
this.activeFilters = next;
|
|
7607
7663
|
this.closeFilterPopup();
|
|
7608
|
-
this.
|
|
7609
|
-
this.aggregationsTotal = null;
|
|
7610
|
-
this.aggregationsPending = true;
|
|
7611
|
-
if (this.isPaginated) {
|
|
7612
|
-
this.resetPages();
|
|
7613
|
-
this.emitPagesForWindow(this.renderStart, this.renderEnd);
|
|
7614
|
-
}
|
|
7664
|
+
this.reloadAfterQueryChange();
|
|
7615
7665
|
}
|
|
7616
7666
|
clearAllFilters() {
|
|
7617
7667
|
this.activeFilters = new Map();
|
|
7618
|
-
this.
|
|
7619
|
-
|
|
7620
|
-
|
|
7621
|
-
|
|
7622
|
-
|
|
7623
|
-
|
|
7668
|
+
this.reloadAfterQueryChange();
|
|
7669
|
+
}
|
|
7670
|
+
// ── Free-text search ───────────────────────────────────────────────────────
|
|
7671
|
+
/** Search is a VIEW-only affordance — a RELATED_VIEW table is already scoped to
|
|
7672
|
+
* its parent record, so a free-text box there would invite confusion about what
|
|
7673
|
+
* it searches across. */
|
|
7674
|
+
get searchEnabled() {
|
|
7675
|
+
var _a;
|
|
7676
|
+
return ((_a = this.item) === null || _a === void 0 ? void 0 : _a.type) === 'VIEW';
|
|
7677
|
+
}
|
|
7678
|
+
toggleSearch() {
|
|
7679
|
+
if (this.searchOpen) {
|
|
7680
|
+
this.closeSearch();
|
|
7681
|
+
}
|
|
7682
|
+
else {
|
|
7683
|
+
this.searchOpen = true;
|
|
7684
|
+
this.searchNeedsFocus = true;
|
|
7685
|
+
this.stashFiltersForSearch();
|
|
7624
7686
|
}
|
|
7625
7687
|
}
|
|
7688
|
+
/** Collapses the box back to the icon. Clearing a non-empty query and restoring any
|
|
7689
|
+
* stashed filters can each independently require a reload — reloadAfterQueryChange()
|
|
7690
|
+
* is called at most once here regardless of how many of the two actually changed. */
|
|
7691
|
+
closeSearch() {
|
|
7692
|
+
this.searchOpen = false;
|
|
7693
|
+
if (this.searchDebounceTimer !== null) {
|
|
7694
|
+
clearTimeout(this.searchDebounceTimer);
|
|
7695
|
+
this.searchDebounceTimer = null;
|
|
7696
|
+
}
|
|
7697
|
+
const hadQuery = this.searchQuery !== '';
|
|
7698
|
+
this.searchQuery = '';
|
|
7699
|
+
const filtersRestored = this.restoreFiltersAfterSearch();
|
|
7700
|
+
if (hadQuery || filtersRestored)
|
|
7701
|
+
this.reloadAfterQueryChange();
|
|
7702
|
+
}
|
|
7703
|
+
handleSearchInput(value) {
|
|
7704
|
+
this.searchQuery = value;
|
|
7705
|
+
if (this.searchDebounceTimer !== null)
|
|
7706
|
+
clearTimeout(this.searchDebounceTimer);
|
|
7707
|
+
this.searchDebounceTimer = setTimeout(() => this.applySearch(), SEARCH_DEBOUNCE_MS);
|
|
7708
|
+
}
|
|
7709
|
+
/** Reloads from page 0 with the current searchQuery, same reset as applyFilter(). */
|
|
7710
|
+
applySearch() {
|
|
7711
|
+
this.searchDebounceTimer = null;
|
|
7712
|
+
this.reloadAfterQueryChange();
|
|
7713
|
+
}
|
|
7714
|
+
/** Column filters and the free-text `q` param are mutually exclusive on the backend —
|
|
7715
|
+
* sending both breaks the search. Opening the search box stashes any active filters
|
|
7716
|
+
* and clears them (the header filter icons and the clear-all button disappear along
|
|
7717
|
+
* with activeFilters, so there is nothing extra to hide) and reloads unfiltered. */
|
|
7718
|
+
stashFiltersForSearch() {
|
|
7719
|
+
if (this.activeFilters.size === 0)
|
|
7720
|
+
return;
|
|
7721
|
+
this.stashedFilters = this.activeFilters;
|
|
7722
|
+
this.activeFilters = new Map();
|
|
7723
|
+
this.reloadAfterQueryChange();
|
|
7724
|
+
}
|
|
7725
|
+
/** Restores filters stashed by stashFiltersForSearch(), unless the user applied a fresh
|
|
7726
|
+
* filter of their own while the search box was open — that explicit choice wins over
|
|
7727
|
+
* reinstating the old one. Returns whether activeFilters actually changed, so the
|
|
7728
|
+
* caller can decide whether a reload is needed. */
|
|
7729
|
+
restoreFiltersAfterSearch() {
|
|
7730
|
+
if (!this.stashedFilters)
|
|
7731
|
+
return false;
|
|
7732
|
+
const stashed = this.stashedFilters;
|
|
7733
|
+
this.stashedFilters = null;
|
|
7734
|
+
if (this.activeFilters.size > 0)
|
|
7735
|
+
return false;
|
|
7736
|
+
this.activeFilters = stashed;
|
|
7737
|
+
return true;
|
|
7738
|
+
}
|
|
7626
7739
|
// ── View switcher ──────────────────────────────────────────────────────────
|
|
7627
7740
|
handleViewSwitch(targetIdx) {
|
|
7628
7741
|
var _a, _b;
|
|
@@ -7632,6 +7745,9 @@ const MrdTable = class {
|
|
|
7632
7745
|
this.activeViewIdx = targetIdx;
|
|
7633
7746
|
this.applyDefaultSort((_b = (_a = target.view) === null || _a === void 0 ? void 0 : _a.defaultSort) !== null && _b !== void 0 ? _b : '');
|
|
7634
7747
|
this.activeFilters = new Map();
|
|
7748
|
+
this.searchOpen = false;
|
|
7749
|
+
this.searchQuery = '';
|
|
7750
|
+
this.stashedFilters = null;
|
|
7635
7751
|
this.init();
|
|
7636
7752
|
}
|
|
7637
7753
|
toggleViewPopover(e) {
|
|
@@ -7654,7 +7770,7 @@ const MrdTable = class {
|
|
|
7654
7770
|
// ── Render: toolbar ────────────────────────────────────────────────────────
|
|
7655
7771
|
renderToolbar() {
|
|
7656
7772
|
var _a;
|
|
7657
|
-
return (index.h(Toolbar, { locale: this.locale, filterCount: this.activeFilters.size, actions: this.tableActions, views: this.allViews, activeViewIdx: this.activeViewIdx, viewPopoverOpen: this.viewPopoverOpen, createPickerOpen: this.createPickerOpen, createTypes: (_a = this.item) === null || _a === void 0 ? void 0 : _a.createTypes, readOnly: this.readOnly, cb: {
|
|
7773
|
+
return (index.h(Toolbar, { locale: this.locale, filterCount: this.activeFilters.size, actions: this.tableActions, views: this.allViews, activeViewIdx: this.activeViewIdx, viewPopoverOpen: this.viewPopoverOpen, createPickerOpen: this.createPickerOpen, createTypes: (_a = this.item) === null || _a === void 0 ? void 0 : _a.createTypes, readOnly: this.readOnly, searchEnabled: this.searchEnabled, searchOpen: this.searchOpen, searchQuery: this.searchQuery, cb: {
|
|
7658
7774
|
onClearAllFilters: () => this.clearAllFilters(),
|
|
7659
7775
|
onViewSwitch: idx => this.handleViewSwitch(idx),
|
|
7660
7776
|
onToggleViewPopover: e => this.toggleViewPopover(e),
|
|
@@ -7665,6 +7781,10 @@ const MrdTable = class {
|
|
|
7665
7781
|
this.closeCreatePicker();
|
|
7666
7782
|
},
|
|
7667
7783
|
onAction: action => this.mrdAction.emit(this.buildActionDetail(action)),
|
|
7784
|
+
onToggleSearch: () => this.toggleSearch(),
|
|
7785
|
+
onSearchInput: value => this.handleSearchInput(value),
|
|
7786
|
+
onCloseSearch: () => this.closeSearch(),
|
|
7787
|
+
onSearchInputRef: el => (this.searchInputEl = el !== null && el !== void 0 ? el : null),
|
|
7668
7788
|
} }));
|
|
7669
7789
|
}
|
|
7670
7790
|
// ── Render: filter popup ───────────────────────────────────────────────────
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
var index = require('./index-DVbdkYO3.js');
|
|
4
4
|
var clientLayout = require('./client-layout-CqVuJumR.js');
|
|
5
|
-
var cellRenderer = require('./cell-renderer-
|
|
5
|
+
var cellRenderer = require('./cell-renderer-mjS630f1.js');
|
|
6
6
|
|
|
7
7
|
/**
|
|
8
8
|
* Whether a layout item can appear in the merge diff at all. m-n relations
|
|
@@ -321,6 +321,42 @@
|
|
|
321
321
|
pointer-events: none;
|
|
322
322
|
z-index: 10;
|
|
323
323
|
}
|
|
324
|
+
.mrd-table__search-box {
|
|
325
|
+
display: inline-flex;
|
|
326
|
+
align-items: center;
|
|
327
|
+
gap: var(--mrd-space-1);
|
|
328
|
+
height: 2rem;
|
|
329
|
+
padding: 0 var(--mrd-space-2);
|
|
330
|
+
border: 1px solid var(--mrd-border-color-focus, var(--mrd-color-primary));
|
|
331
|
+
border-radius: var(--mrd-border-radius);
|
|
332
|
+
background: var(--mrd-color-white, #fff);
|
|
333
|
+
box-shadow: var(--mrd-shadow-focus, none);
|
|
334
|
+
color: var(--mrd-color-neutral-400);
|
|
335
|
+
}
|
|
336
|
+
.mrd-table__search-input {
|
|
337
|
+
border: none;
|
|
338
|
+
outline: none;
|
|
339
|
+
background: transparent;
|
|
340
|
+
font-size: var(--mrd-font-size-sm);
|
|
341
|
+
font-family: var(--mrd-font-family);
|
|
342
|
+
color: var(--mrd-color-neutral-800);
|
|
343
|
+
width: 12rem;
|
|
344
|
+
}
|
|
345
|
+
.mrd-table__search-clear {
|
|
346
|
+
display: inline-flex;
|
|
347
|
+
align-items: center;
|
|
348
|
+
justify-content: center;
|
|
349
|
+
background: none;
|
|
350
|
+
border: none;
|
|
351
|
+
padding: 0;
|
|
352
|
+
cursor: pointer;
|
|
353
|
+
color: var(--mrd-color-neutral-400);
|
|
354
|
+
font-size: var(--mrd-font-size-xs);
|
|
355
|
+
line-height: 1;
|
|
356
|
+
}
|
|
357
|
+
.mrd-table__search-clear:hover {
|
|
358
|
+
color: var(--mrd-color-neutral-700);
|
|
359
|
+
}
|
|
324
360
|
.mrd-table__create-picker-wrap {
|
|
325
361
|
position: relative;
|
|
326
362
|
}
|