@mmlogic/components 0.3.0 → 0.3.2
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/loader.cjs.js +1 -1
- package/dist/cjs/mosterdcomponents.cjs.js +1 -1
- package/dist/cjs/mrd-boolean-field_19.cjs.entry.js +103 -33
- package/dist/collection/components/mrd-layout-section/mrd-layout-section.js +12 -7
- package/dist/collection/components/mrd-table/mrd-table.js +111 -36
- package/dist/collection/dev/app.js +2 -9
- package/dist/components/mrd-layout-section.js +1 -1
- package/dist/components/mrd-table2.js +1 -1
- package/dist/esm/loader.js +1 -1
- package/dist/esm/mosterdcomponents.js +1 -1
- package/dist/esm/mrd-boolean-field_19.entry.js +103 -33
- package/dist/mosterdcomponents/mosterdcomponents.esm.js +1 -1
- package/dist/mosterdcomponents/p-2a099635.entry.js +1 -0
- package/dist/types/components/mrd-layout-section/mrd-layout-section.d.ts +3 -4
- package/dist/types/components/mrd-table/mrd-table.d.ts +18 -5
- package/dist/types/components.d.ts +9 -9
- package/dist/types/types/client-layout.d.ts +4 -2
- package/package.json +1 -1
- package/dist/mosterdcomponents/p-f6d0f02b.entry.js +0 -1
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-boolean-field_19.cjs",[[2,"mrd-form",{"layout":[16],"locale":[1],"values":[16],"referenceHref":[1,"reference-href"],"referenceClass":[1,"reference-class"],"showCancel":[4,"show-cancel"],"formValues":[32],"errors":[32],"submitted":[32],"setFieldValue":[64]},null,{"values":[{"valuesChanged":0}]}],[2,"mrd-layout-section",{"items":[16],"data":[16],"views":[16],"links":[16],"locale":[1],"searchQueryMap":[32],"searchResultsMap":[32],"imagePreviewUrl":[32],"imagePreviews":[32],"setSearchResults":[64],"setViewPage":[64],"setViewAggregations":[64],"setImagePreview":[64],"openImagePreview":[64]},null,{"data":[{"dataChanged":0}]}],[2,"mrd-field",{"item":[16],"locale":[1],"value":[16]}],[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"],"activeViewIdx":[32],"loadedPages":[32],"requestedPages":[32],"renderStart":[32],"renderEnd":[32],"colWidths":[32],"sortField":[32],"sortDir":[32],"filterMode":[32],"activeFilters":[32],"openFilterCol":[32],"pendingFilter":[32],"popupPos":[32],"scrollTop":[32],"textblockModal":[32],"jsonModal":[32],"aggregations":[32],"init":[64],"setPage":[64],"setAggregations":[64]},null,{"totalElements":[{"totalElementsChanged":0}],"item":[{"itemChanged":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]}],[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-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"],"fileName":[32],"isDragging":[32],"uploading":[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],"error":[32]}],[2,"mrd-image-field",{"name":[1],"label":[1],"value":[16],"required":[4],"disabled":[4],"locale":[1],"accept":[1],"maxSize":[2,"max-size"],"previewUrl":[32],"fileName":[32],"isDragging":[32],"uploading":[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]}],[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}]}],[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-boolean-field_19.cjs",[[2,"mrd-form",{"layout":[16],"locale":[1],"values":[16],"referenceHref":[1,"reference-href"],"referenceClass":[1,"reference-class"],"showCancel":[4,"show-cancel"],"formValues":[32],"errors":[32],"submitted":[32],"setFieldValue":[64]},null,{"values":[{"valuesChanged":0}]}],[2,"mrd-layout-section",{"items":[16],"data":[16],"views":[16],"links":[16],"locale":[1],"searchQueryMap":[32],"searchResultsMap":[32],"imagePreviewUrl":[32],"imagePreviews":[32],"setSearchResults":[64],"setViewPage":[64],"setViewAggregations":[64],"setImagePreview":[64],"openImagePreview":[64]},null,{"data":[{"dataChanged":0}]}],[2,"mrd-field",{"item":[16],"locale":[1],"value":[16]}],[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"],"activeViewIdx":[32],"loadedPages":[32],"requestedPages":[32],"renderStart":[32],"renderEnd":[32],"colWidths":[32],"sortField":[32],"sortDir":[32],"filterMode":[32],"activeFilters":[32],"openFilterCol":[32],"pendingFilter":[32],"popupPos":[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-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]}],[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-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"],"fileName":[32],"isDragging":[32],"uploading":[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],"error":[32]}],[2,"mrd-image-field",{"name":[1],"label":[1],"value":[16],"required":[4],"disabled":[4],"locale":[1],"accept":[1],"maxSize":[2,"max-size"],"previewUrl":[32],"fileName":[32],"isDragging":[32],"uploading":[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]}],[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}]}],[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-boolean-field_19.cjs",[[2,"mrd-form",{"layout":[16],"locale":[1],"values":[16],"referenceHref":[1,"reference-href"],"referenceClass":[1,"reference-class"],"showCancel":[4,"show-cancel"],"formValues":[32],"errors":[32],"submitted":[32],"setFieldValue":[64]},null,{"values":[{"valuesChanged":0}]}],[2,"mrd-layout-section",{"items":[16],"data":[16],"views":[16],"links":[16],"locale":[1],"searchQueryMap":[32],"searchResultsMap":[32],"imagePreviewUrl":[32],"imagePreviews":[32],"setSearchResults":[64],"setViewPage":[64],"setViewAggregations":[64],"setImagePreview":[64],"openImagePreview":[64]},null,{"data":[{"dataChanged":0}]}],[2,"mrd-field",{"item":[16],"locale":[1],"value":[16]}],[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"],"activeViewIdx":[32],"loadedPages":[32],"requestedPages":[32],"renderStart":[32],"renderEnd":[32],"colWidths":[32],"sortField":[32],"sortDir":[32],"filterMode":[32],"activeFilters":[32],"openFilterCol":[32],"pendingFilter":[32],"popupPos":[32],"scrollTop":[32],"textblockModal":[32],"jsonModal":[32],"aggregations":[32],"init":[64],"setPage":[64],"setAggregations":[64]},null,{"totalElements":[{"totalElementsChanged":0}],"item":[{"itemChanged":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]}],[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-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"],"fileName":[32],"isDragging":[32],"uploading":[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],"error":[32]}],[2,"mrd-image-field",{"name":[1],"label":[1],"value":[16],"required":[4],"disabled":[4],"locale":[1],"accept":[1],"maxSize":[2,"max-size"],"previewUrl":[32],"fileName":[32],"isDragging":[32],"uploading":[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]}],[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}]}],[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-boolean-field_19.cjs",[[2,"mrd-form",{"layout":[16],"locale":[1],"values":[16],"referenceHref":[1,"reference-href"],"referenceClass":[1,"reference-class"],"showCancel":[4,"show-cancel"],"formValues":[32],"errors":[32],"submitted":[32],"setFieldValue":[64]},null,{"values":[{"valuesChanged":0}]}],[2,"mrd-layout-section",{"items":[16],"data":[16],"views":[16],"links":[16],"locale":[1],"searchQueryMap":[32],"searchResultsMap":[32],"imagePreviewUrl":[32],"imagePreviews":[32],"setSearchResults":[64],"setViewPage":[64],"setViewAggregations":[64],"setImagePreview":[64],"openImagePreview":[64]},null,{"data":[{"dataChanged":0}]}],[2,"mrd-field",{"item":[16],"locale":[1],"value":[16]}],[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"],"activeViewIdx":[32],"loadedPages":[32],"requestedPages":[32],"renderStart":[32],"renderEnd":[32],"colWidths":[32],"sortField":[32],"sortDir":[32],"filterMode":[32],"activeFilters":[32],"openFilterCol":[32],"pendingFilter":[32],"popupPos":[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-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]}],[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-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"],"fileName":[32],"isDragging":[32],"uploading":[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],"error":[32]}],[2,"mrd-image-field",{"name":[1],"label":[1],"value":[16],"required":[4],"disabled":[4],"locale":[1],"accept":[1],"maxSize":[2,"max-size"],"previewUrl":[32],"fileName":[32],"isDragging":[32],"uploading":[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]}],[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}]}],[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;
|
|
@@ -1456,15 +1456,16 @@ const MrdLayoutSection = class {
|
|
|
1456
1456
|
/**
|
|
1457
1457
|
* Inject data into an embedded mrd-table for a RELATED_VIEW or VIEW item.
|
|
1458
1458
|
* Pass totalElements to update the pagination total (safe to pass on every page).
|
|
1459
|
+
* Pass hasNext (from _links.next presence) so the table can decide whether to emit aggregations.
|
|
1459
1460
|
*/
|
|
1460
|
-
async setViewPage(name, page, rows, totalElements) {
|
|
1461
|
+
async setViewPage(name, page, rows, totalElements, hasNext) {
|
|
1461
1462
|
const table = this.el.querySelector(`mrd-table[data-view="${name}"]`);
|
|
1462
1463
|
if (!table)
|
|
1463
1464
|
return;
|
|
1464
1465
|
if (totalElements !== undefined) {
|
|
1465
1466
|
table.totalElements = totalElements;
|
|
1466
1467
|
}
|
|
1467
|
-
await table.setPage(page, rows);
|
|
1468
|
+
await table.setPage(page, rows, hasNext);
|
|
1468
1469
|
}
|
|
1469
1470
|
/** Inject aggregation totals into an embedded mrd-table for a VIEW or RELATED_VIEW item. */
|
|
1470
1471
|
async setViewAggregations(name, data) {
|
|
@@ -1661,7 +1662,7 @@ const MrdLayoutSection = class {
|
|
|
1661
1662
|
return (index.h("div", { class: "mrd-layout-section__modal-backdrop", onClick: () => { this.imagePreviewUrl = null; } }, index.h("div", { class: "mrd-layout-section__modal", onClick: (e) => e.stopPropagation() }, index.h("button", { class: "mrd-layout-section__modal-close", onClick: () => { this.imagePreviewUrl = null; } }, "\u2715"), index.h("img", { class: "mrd-layout-section__modal-image", src: this.imagePreviewUrl, alt: "" }))));
|
|
1662
1663
|
}
|
|
1663
1664
|
render() {
|
|
1664
|
-
return (index.h(index.Host, { key: '
|
|
1665
|
+
return (index.h(index.Host, { key: '0a3a58f5c80716bc0a7ba1b9468b721706d2ce4a' }, index.h("div", { key: '7cf63580c584811c1bb84b419e8d13026e432fba', class: "mrd-layout-section" }, this.items.map(item => this.renderItem(item))), this.renderImageModal()));
|
|
1665
1666
|
}
|
|
1666
1667
|
get el() { return index.getElement(this); }
|
|
1667
1668
|
static get watchers() { return {
|
|
@@ -2181,10 +2182,16 @@ const MrdTable = class {
|
|
|
2181
2182
|
this.jsonModal = null;
|
|
2182
2183
|
/** Aggregation totals received from the host via setAggregations(). Null = not yet loaded. */
|
|
2183
2184
|
this.aggregations = null;
|
|
2185
|
+
/** Record count received via setAggregations().total; overrides totalElements for display. */
|
|
2186
|
+
this.aggregationsTotal = null;
|
|
2187
|
+
/** True when a fresh aggregations request is needed (set on init / filter change). */
|
|
2188
|
+
this.aggregationsPending = false;
|
|
2189
|
+
/** Lower bound on total derived from setPage() hasNext info; grows as pages load. */
|
|
2190
|
+
this.minKnownTotal = 0;
|
|
2184
2191
|
this.handleScroll = (e) => {
|
|
2185
2192
|
const scroller = e.currentTarget;
|
|
2186
2193
|
const scrollTop = scroller.scrollTop;
|
|
2187
|
-
const total = this.
|
|
2194
|
+
const total = this.baseTotal;
|
|
2188
2195
|
const visStart = Math.floor(scrollTop / this.rowHeight);
|
|
2189
2196
|
const visEnd = Math.min(visStart + this.visibleCount(), total - 1);
|
|
2190
2197
|
this.scrollTop = scrollTop;
|
|
@@ -2246,7 +2253,9 @@ const MrdTable = class {
|
|
|
2246
2253
|
if (scroller)
|
|
2247
2254
|
scroller.scrollTop = 0;
|
|
2248
2255
|
this.aggregations = null;
|
|
2249
|
-
this.
|
|
2256
|
+
this.aggregationsTotal = null;
|
|
2257
|
+
this.aggregationsPending = true;
|
|
2258
|
+
this.minKnownTotal = 0;
|
|
2250
2259
|
// Always request page 0 — totalElements may be unknown (0) on first load.
|
|
2251
2260
|
this.mrdLoadPage.emit({ page: 0, sort: this.sortParam(), path: this.buildDataPath(), qs: this.buildQueryParams(0) });
|
|
2252
2261
|
this.requestedPages = new Set([0]);
|
|
@@ -2258,20 +2267,41 @@ const MrdTable = class {
|
|
|
2258
2267
|
* When the page contains fewer rows than pageSize it is the last page.
|
|
2259
2268
|
* renderEnd is clamped immediately so no loading-placeholder rows appear
|
|
2260
2269
|
* beyond the actual data — without requiring the host to update totalElements.
|
|
2270
|
+
*
|
|
2271
|
+
* Pass hasNext (from _links.next in the API response) for accurate last-page
|
|
2272
|
+
* detection even when rows.length === pageSize (exact multiple of page size).
|
|
2261
2273
|
*/
|
|
2262
|
-
async setPage(pageNumber, rows) {
|
|
2263
|
-
|
|
2274
|
+
async setPage(pageNumber, rows, hasNext) {
|
|
2275
|
+
const isLastPage = hasNext !== undefined ? !hasNext : rows.length < this.pageSize;
|
|
2276
|
+
if (isLastPage) {
|
|
2264
2277
|
// lastRowIdx is -1 when the page is empty; clamp renderEnd to -1 so the
|
|
2265
2278
|
// render loop does not execute and no shimmer rows appear.
|
|
2266
2279
|
const lastRowIdx = pageNumber * this.pageSize + rows.length - 1;
|
|
2267
2280
|
this.renderEnd = Math.min(this.renderEnd, lastRowIdx);
|
|
2281
|
+
// Exact total is known: update minKnownTotal so the scroll container has the right height.
|
|
2282
|
+
this.minKnownTotal = pageNumber * this.pageSize + rows.length;
|
|
2283
|
+
}
|
|
2284
|
+
else {
|
|
2285
|
+
// There is at least one more page — ensure the scrollbar covers at least that next page.
|
|
2286
|
+
this.minKnownTotal = Math.max(this.minKnownTotal, (pageNumber + 1) * this.pageSize + 1);
|
|
2268
2287
|
}
|
|
2269
2288
|
const next = new Map(this.loadedPages);
|
|
2270
2289
|
next.set(pageNumber, rows);
|
|
2271
2290
|
this.loadedPages = next;
|
|
2291
|
+
if (pageNumber === 0 && this.aggregationsPending) {
|
|
2292
|
+
this.aggregationsPending = false;
|
|
2293
|
+
const hasAggColumns = this.columns.some(c => c.type === 'FIELD' && c.aggregate);
|
|
2294
|
+
if (!isLastPage || hasAggColumns) {
|
|
2295
|
+
this.emitLoadAggregations();
|
|
2296
|
+
}
|
|
2297
|
+
}
|
|
2272
2298
|
}
|
|
2273
2299
|
/** Inject aggregation totals returned by the /aggregations endpoint. */
|
|
2274
2300
|
async setAggregations(data) {
|
|
2301
|
+
var _a;
|
|
2302
|
+
const total = (_a = data.total) !== null && _a !== void 0 ? _a : (typeof data.count === 'number' ? data.count : undefined);
|
|
2303
|
+
if (total != null)
|
|
2304
|
+
this.aggregationsTotal = total;
|
|
2275
2305
|
this.aggregations = data;
|
|
2276
2306
|
}
|
|
2277
2307
|
// ── Lifecycle ──────────────────────────────────────────────────────────────
|
|
@@ -2453,6 +2483,25 @@ const MrdTable = class {
|
|
|
2453
2483
|
return 'RELATION';
|
|
2454
2484
|
return (_a = col.dataType) !== null && _a !== void 0 ? _a : 'TEXT';
|
|
2455
2485
|
}
|
|
2486
|
+
/** True when we have a reliable total: either from the aggregations response or because
|
|
2487
|
+
* a short page told us it was the last page (exact count from row length). */
|
|
2488
|
+
isTotalKnown() {
|
|
2489
|
+
if (this.aggregationsTotal != null)
|
|
2490
|
+
return true;
|
|
2491
|
+
for (const rows of this.loadedPages.values()) {
|
|
2492
|
+
if (rows.length < this.pageSize)
|
|
2493
|
+
return true;
|
|
2494
|
+
}
|
|
2495
|
+
return false;
|
|
2496
|
+
}
|
|
2497
|
+
/** Effective total: aggregations-response > totalElements prop > minKnownTotal from setPage(). */
|
|
2498
|
+
get baseTotal() {
|
|
2499
|
+
if (this.aggregationsTotal != null)
|
|
2500
|
+
return this.aggregationsTotal;
|
|
2501
|
+
if (this.totalElements > 0)
|
|
2502
|
+
return this.totalElements;
|
|
2503
|
+
return this.minKnownTotal;
|
|
2504
|
+
}
|
|
2456
2505
|
// ── Aggregation helpers ────────────────────────────────────────────────────
|
|
2457
2506
|
buildAggregationParams() {
|
|
2458
2507
|
var _a;
|
|
@@ -2473,17 +2522,32 @@ const MrdTable = class {
|
|
|
2473
2522
|
params.count = groups.count;
|
|
2474
2523
|
return Object.keys(params).length > 0 ? params : null;
|
|
2475
2524
|
}
|
|
2525
|
+
buildAggregationQs() {
|
|
2526
|
+
var _a, _b, _c;
|
|
2527
|
+
const p = new URLSearchParams(this.buildQueryParams(0));
|
|
2528
|
+
p.delete('page');
|
|
2529
|
+
p.delete('sort');
|
|
2530
|
+
const groups = this.buildAggregationParams();
|
|
2531
|
+
if ((_a = groups === null || groups === void 0 ? void 0 : groups.sum) === null || _a === void 0 ? void 0 : _a.length)
|
|
2532
|
+
p.set('sum', groups.sum.join(','));
|
|
2533
|
+
if ((_b = groups === null || groups === void 0 ? void 0 : groups.avg) === null || _b === void 0 ? void 0 : _b.length)
|
|
2534
|
+
p.set('avg', groups.avg.join(','));
|
|
2535
|
+
if ((_c = groups === null || groups === void 0 ? void 0 : groups.count) === null || _c === void 0 ? void 0 : _c.length)
|
|
2536
|
+
p.set('count', groups.count.join(','));
|
|
2537
|
+
return p.toString();
|
|
2538
|
+
}
|
|
2476
2539
|
emitLoadAggregations() {
|
|
2477
|
-
|
|
2478
|
-
if (aggParams)
|
|
2479
|
-
this.mrdLoadAggregations.emit(Object.assign(Object.assign({}, aggParams), { path: this.buildDataPath(), qs: this.buildQueryParams(0) }));
|
|
2540
|
+
this.mrdLoadAggregations.emit({ path: this.buildDataPath(), qs: this.buildQueryParams(0), aggQs: this.buildAggregationQs() });
|
|
2480
2541
|
}
|
|
2481
2542
|
renderAggregationValue(col) {
|
|
2482
|
-
var _a
|
|
2543
|
+
var _a;
|
|
2483
2544
|
if (col.type !== 'FIELD' || !col.aggregate || !this.aggregations)
|
|
2484
2545
|
return '';
|
|
2485
2546
|
const fn = col.aggregate.toLowerCase();
|
|
2486
|
-
const
|
|
2547
|
+
const aggData = this.aggregations[fn];
|
|
2548
|
+
const val = typeof aggData === 'object' && aggData !== null
|
|
2549
|
+
? aggData[(_a = col.name) !== null && _a !== void 0 ? _a : '']
|
|
2550
|
+
: undefined;
|
|
2487
2551
|
if (val == null)
|
|
2488
2552
|
return '';
|
|
2489
2553
|
const dt = col.dataType;
|
|
@@ -2508,9 +2572,10 @@ const MrdTable = class {
|
|
|
2508
2572
|
this.colWidths = [];
|
|
2509
2573
|
this.scrollTop = 0;
|
|
2510
2574
|
this.renderStart = 0;
|
|
2511
|
-
|
|
2512
|
-
//
|
|
2513
|
-
|
|
2575
|
+
this.minKnownTotal = 0;
|
|
2576
|
+
// Mirror init(): use visibleCount so the first page is always requested.
|
|
2577
|
+
// setPage() will clamp renderEnd down when the last page is shorter.
|
|
2578
|
+
this.renderEnd = this.visibleCount() - 1;
|
|
2514
2579
|
const scroller = this.el.querySelector('.mrd-table__scroll');
|
|
2515
2580
|
if (scroller)
|
|
2516
2581
|
scroller.scrollTop = 0;
|
|
@@ -2776,8 +2841,9 @@ const MrdTable = class {
|
|
|
2776
2841
|
this.activeFilters = next;
|
|
2777
2842
|
this.closeFilterPopup();
|
|
2778
2843
|
this.aggregations = null;
|
|
2779
|
-
this.
|
|
2780
|
-
|
|
2844
|
+
this.aggregationsTotal = null;
|
|
2845
|
+
this.aggregationsPending = true;
|
|
2846
|
+
if (this.totalElements > 0 || this.minKnownTotal > 0) {
|
|
2781
2847
|
this.resetPages();
|
|
2782
2848
|
this.emitPagesForWindow(this.renderStart, this.renderEnd);
|
|
2783
2849
|
}
|
|
@@ -2790,8 +2856,9 @@ const MrdTable = class {
|
|
|
2790
2856
|
this.activeFilters = next;
|
|
2791
2857
|
this.closeFilterPopup();
|
|
2792
2858
|
this.aggregations = null;
|
|
2793
|
-
this.
|
|
2794
|
-
|
|
2859
|
+
this.aggregationsTotal = null;
|
|
2860
|
+
this.aggregationsPending = true;
|
|
2861
|
+
if (this.totalElements > 0 || this.minKnownTotal > 0) {
|
|
2795
2862
|
this.resetPages();
|
|
2796
2863
|
this.emitPagesForWindow(this.renderStart, this.renderEnd);
|
|
2797
2864
|
}
|
|
@@ -2799,8 +2866,9 @@ const MrdTable = class {
|
|
|
2799
2866
|
clearAllFilters() {
|
|
2800
2867
|
this.activeFilters = new Map();
|
|
2801
2868
|
this.aggregations = null;
|
|
2802
|
-
this.
|
|
2803
|
-
|
|
2869
|
+
this.aggregationsTotal = null;
|
|
2870
|
+
this.aggregationsPending = true;
|
|
2871
|
+
if (this.totalElements > 0 || this.minKnownTotal > 0) {
|
|
2804
2872
|
this.resetPages();
|
|
2805
2873
|
this.emitPagesForWindow(this.renderStart, this.renderEnd);
|
|
2806
2874
|
}
|
|
@@ -2923,10 +2991,9 @@ const MrdTable = class {
|
|
|
2923
2991
|
return (index.h("div", { class: "mrd-table__filter-popup", style: { top: `${this.popupPos.top}px`, left: `${this.popupPos.left}px` }, onClick: (e) => e.stopPropagation() }, index.h("div", { class: "mrd-table__filter-popup-header" }, index.h("span", { class: "mrd-table__filter-popup-title" }, label), index.h("button", { class: "mrd-table__filter-close", onClick: () => this.closeFilterPopup() }, "\u2715")), index.h("div", { class: "mrd-table__filter-section" }, index.h("div", { class: "mrd-table__filter-section-label" }, t('filter_sorting', this.locale)), index.h("div", { class: "mrd-table__filter-sort-buttons" }, index.h("button", { class: `mrd-table__filter-sort-btn${sortActive && this.sortDir === 'asc' ? ' mrd-table__filter-sort-btn--active' : ''}`, onClick: () => this.applySort(col, 'asc') }, "\u25B2 ", t('filter_ascending', this.locale)), index.h("button", { class: `mrd-table__filter-sort-btn${sortActive && this.sortDir === 'desc' ? ' mrd-table__filter-sort-btn--active' : ''}`, onClick: () => this.applySort(col, 'desc') }, "\u25BC ", t('filter_descending', this.locale)))), index.h("div", { class: "mrd-table__filter-divider" }), index.h("div", { class: "mrd-table__filter-section" }, index.h("div", { class: "mrd-table__filter-section-label" }, t('filter_section', this.locale)), this.renderFilterEditor(col)), index.h("div", { class: "mrd-table__filter-popup-footer" }, index.h("button", { class: "mrd-table__filter-btn mrd-table__filter-btn--clear", onClick: () => this.clearFilter() }, t('filter_clear', this.locale)), index.h("button", { class: "mrd-table__filter-btn mrd-table__filter-btn--apply", onClick: () => this.applyFilter() }, t('filter_apply', this.locale)))));
|
|
2924
2992
|
}
|
|
2925
2993
|
// ── Render: footer ────────────────────────────────────────────────────────
|
|
2926
|
-
renderFooter(rowCount, effectiveTotal) {
|
|
2927
|
-
|
|
2928
|
-
|
|
2929
|
-
if (total === 0) {
|
|
2994
|
+
renderFooter(rowCount, effectiveTotal, isTotalKnown = true) {
|
|
2995
|
+
// Non-paginated mode: totalElements=0 and no paginated data loaded yet
|
|
2996
|
+
if (this.totalElements === 0 && this.loadedPages.size === 0) {
|
|
2930
2997
|
const count = rowCount !== null && rowCount !== void 0 ? rowCount : 0;
|
|
2931
2998
|
if (count === 0)
|
|
2932
2999
|
return null;
|
|
@@ -2935,13 +3002,14 @@ const MrdTable = class {
|
|
|
2935
3002
|
// Paginated mode: only show once page 0 has loaded (avoids stale total during filter reset)
|
|
2936
3003
|
if (!this.loadedPages.has(0))
|
|
2937
3004
|
return null;
|
|
2938
|
-
//
|
|
2939
|
-
|
|
2940
|
-
const displayTotal = effectiveTotal !== null && effectiveTotal !== void 0 ? effectiveTotal : total;
|
|
3005
|
+
// effectiveTotal from render(); fall back to baseTotal when not provided.
|
|
3006
|
+
const displayTotal = effectiveTotal !== null && effectiveTotal !== void 0 ? effectiveTotal : this.baseTotal;
|
|
2941
3007
|
// Compute from/to independently so partial rows at top/bottom are included.
|
|
2942
3008
|
const from = Math.min(Math.floor(this.scrollTop / this.rowHeight) + 1, displayTotal);
|
|
2943
3009
|
const to = Math.min(Math.ceil((this.scrollTop + this.tableHeight) / this.rowHeight), displayTotal);
|
|
2944
|
-
|
|
3010
|
+
// Show '…' for the total until we have a reliable count (aggregations or last page loaded).
|
|
3011
|
+
const totalLabel = isTotalKnown ? String(displayTotal) : '…';
|
|
3012
|
+
return (index.h("div", { class: "mrd-table__footer" }, from, "\u2013", to, " ", t('table_of', this.locale), " ", totalLabel));
|
|
2945
3013
|
}
|
|
2946
3014
|
// ── Render: cell ──────────────────────────────────────────────────────────
|
|
2947
3015
|
renderCell(col, row) {
|
|
@@ -3000,7 +3068,9 @@ const MrdTable = class {
|
|
|
3000
3068
|
if (!((_a = this.columns) === null || _a === void 0 ? void 0 : _a.length))
|
|
3001
3069
|
return null;
|
|
3002
3070
|
// ── Non-paginated mode ──────────────────────────────────────────────────
|
|
3003
|
-
|
|
3071
|
+
// Only enter non-paginated mode when totalElements is 0 AND no paginated data
|
|
3072
|
+
// has been loaded yet — prevents the wrong branch when the host omits totalElements.
|
|
3073
|
+
if (this.totalElements === 0 && this.loadedPages.size === 0) {
|
|
3004
3074
|
return (index.h(index.Host, null, this.renderToolbar(), index.h("div", { class: "mrd-table" }, index.h("table", { class: "mrd-table__table" }, index.h("thead", null, index.h("tr", null, this.columns.map(col => {
|
|
3005
3075
|
var _a;
|
|
3006
3076
|
const name = this.colName(col);
|
|
@@ -3017,8 +3087,8 @@ const MrdTable = class {
|
|
|
3017
3087
|
// Derive the authoritative row count from loaded pages:
|
|
3018
3088
|
// if any loaded page is shorter than pageSize it is the last page,
|
|
3019
3089
|
// so the true total cannot exceed (pageNum * pageSize + pageRows.length).
|
|
3020
|
-
//
|
|
3021
|
-
let effectiveTotal = this.
|
|
3090
|
+
// aggregationsTotal (from setAggregations) takes priority over the totalElements prop.
|
|
3091
|
+
let effectiveTotal = this.baseTotal;
|
|
3022
3092
|
for (const [pageNum, pageRows] of this.loadedPages) {
|
|
3023
3093
|
if (pageRows.length < this.pageSize) {
|
|
3024
3094
|
effectiveTotal = Math.min(effectiveTotal, pageNum * this.pageSize + pageRows.length);
|
|
@@ -3055,7 +3125,7 @@ const MrdTable = class {
|
|
|
3055
3125
|
isFiltered ? 'mrd-table__header--filtered' : '',
|
|
3056
3126
|
].filter(Boolean).join(' ');
|
|
3057
3127
|
return (index.h("th", { class: cls, style: this.colWidths[idx] ? { width: `${this.colWidths[idx]}px` } : undefined, onClick: isInteractive ? ((e) => this.filterMode ? this.handleFilterOpen(col, e) : this.handleSortClick(col)) : undefined }, index.h("span", { class: "mrd-table__header-label" }, (_a = col.label) !== null && _a !== void 0 ? _a : ''), isInteractive && isActive && (index.h("span", { class: "mrd-table__sort-icon", "aria-hidden": "true" }, this.sortDir === 'asc' ? '▲' : '▼')), isInteractive && !isActive && !this.filterMode && (index.h("span", { class: "mrd-table__sort-icon", "aria-hidden": "true" }, "\u21C5")), isInteractive && isFiltered && this.renderFilterIcon()));
|
|
3058
|
-
}))), index.h("tbody", null, topSpacerHeight > 0 && (index.h("tr", { class: "mrd-table__spacer", style: { height: `${topSpacerHeight}px` } }, index.h("td", { colSpan: colCount }))), renderedRows, bottomSpacerHeight > 0 && (index.h("tr", { class: "mrd-table__spacer", style: { height: `${bottomSpacerHeight}px` } }, index.h("td", { colSpan: colCount })))), this.renderTotalsRow())), effectiveTotal === 0 && this.loadedPages.has(0) && (index.h("p", { class: "mrd-table__empty" }, t('no_results', this.locale))), effectiveTotal > 0 && this.renderFooter(undefined, effectiveTotal), this.renderFilterPopup(), this.renderTextblockModal()));
|
|
3128
|
+
}))), index.h("tbody", null, topSpacerHeight > 0 && (index.h("tr", { class: "mrd-table__spacer", style: { height: `${topSpacerHeight}px` } }, index.h("td", { colSpan: colCount }))), renderedRows, bottomSpacerHeight > 0 && (index.h("tr", { class: "mrd-table__spacer", style: { height: `${bottomSpacerHeight}px` } }, index.h("td", { colSpan: colCount })))), this.renderTotalsRow())), effectiveTotal === 0 && this.loadedPages.has(0) && (index.h("p", { class: "mrd-table__empty" }, t('no_results', this.locale))), effectiveTotal > 0 && this.renderFooter(undefined, effectiveTotal, this.isTotalKnown()), this.renderFilterPopup(), this.renderTextblockModal()));
|
|
3059
3129
|
}
|
|
3060
3130
|
renderFilterIcon() {
|
|
3061
3131
|
return (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" }))));
|
|
@@ -90,15 +90,16 @@ export class MrdLayoutSection {
|
|
|
90
90
|
/**
|
|
91
91
|
* Inject data into an embedded mrd-table for a RELATED_VIEW or VIEW item.
|
|
92
92
|
* Pass totalElements to update the pagination total (safe to pass on every page).
|
|
93
|
+
* Pass hasNext (from _links.next presence) so the table can decide whether to emit aggregations.
|
|
93
94
|
*/
|
|
94
|
-
async setViewPage(name, page, rows, totalElements) {
|
|
95
|
+
async setViewPage(name, page, rows, totalElements, hasNext) {
|
|
95
96
|
const table = this.el.querySelector(`mrd-table[data-view="${name}"]`);
|
|
96
97
|
if (!table)
|
|
97
98
|
return;
|
|
98
99
|
if (totalElements !== undefined) {
|
|
99
100
|
table.totalElements = totalElements;
|
|
100
101
|
}
|
|
101
|
-
await table.setPage(page, rows);
|
|
102
|
+
await table.setPage(page, rows, hasNext);
|
|
102
103
|
}
|
|
103
104
|
/** Inject aggregation totals into an embedded mrd-table for a VIEW or RELATED_VIEW item. */
|
|
104
105
|
async setViewAggregations(name, data) {
|
|
@@ -295,7 +296,7 @@ export class MrdLayoutSection {
|
|
|
295
296
|
return (h("div", { class: "mrd-layout-section__modal-backdrop", onClick: () => { this.imagePreviewUrl = null; } }, h("div", { class: "mrd-layout-section__modal", onClick: (e) => e.stopPropagation() }, h("button", { class: "mrd-layout-section__modal-close", onClick: () => { this.imagePreviewUrl = null; } }, "\u2715"), h("img", { class: "mrd-layout-section__modal-image", src: this.imagePreviewUrl, alt: "" }))));
|
|
296
297
|
}
|
|
297
298
|
render() {
|
|
298
|
-
return (h(Host, { key: '
|
|
299
|
+
return (h(Host, { key: '0a3a58f5c80716bc0a7ba1b9468b721706d2ce4a' }, h("div", { key: '7cf63580c584811c1bb84b419e8d13026e432fba', class: "mrd-layout-section" }, this.items.map(item => this.renderItem(item))), this.renderImageModal()));
|
|
299
300
|
}
|
|
300
301
|
static get is() { return "mrd-layout-section"; }
|
|
301
302
|
static get encapsulation() { return "scoped"; }
|
|
@@ -550,8 +551,8 @@ export class MrdLayoutSection {
|
|
|
550
551
|
"text": "Re-emitted from an embedded mrd-table's mrdLoadAggregations; host calls setViewAggregations() with the result."
|
|
551
552
|
},
|
|
552
553
|
"complexType": {
|
|
553
|
-
"original": "{ name: string; dataClass: string; path: string; qs: string;
|
|
554
|
-
"resolved": "{ name: string; dataClass: string; path: string; qs: string;
|
|
554
|
+
"original": "{ name: string; dataClass: string; path: string; qs: string; aggQs: string }",
|
|
555
|
+
"resolved": "{ name: string; dataClass: string; path: string; qs: string; aggQs: string; }",
|
|
555
556
|
"references": {}
|
|
556
557
|
}
|
|
557
558
|
}];
|
|
@@ -591,7 +592,7 @@ export class MrdLayoutSection {
|
|
|
591
592
|
},
|
|
592
593
|
"setViewPage": {
|
|
593
594
|
"complexType": {
|
|
594
|
-
"signature": "(name: string, page: number, rows: any[], totalElements?: number) => Promise<void>",
|
|
595
|
+
"signature": "(name: string, page: number, rows: any[], totalElements?: number, hasNext?: boolean) => Promise<void>",
|
|
595
596
|
"parameters": [{
|
|
596
597
|
"name": "name",
|
|
597
598
|
"type": "string",
|
|
@@ -608,6 +609,10 @@ export class MrdLayoutSection {
|
|
|
608
609
|
"name": "totalElements",
|
|
609
610
|
"type": "number | undefined",
|
|
610
611
|
"docs": ""
|
|
612
|
+
}, {
|
|
613
|
+
"name": "hasNext",
|
|
614
|
+
"type": "boolean | undefined",
|
|
615
|
+
"docs": ""
|
|
611
616
|
}],
|
|
612
617
|
"references": {
|
|
613
618
|
"Promise": {
|
|
@@ -618,7 +623,7 @@ export class MrdLayoutSection {
|
|
|
618
623
|
"return": "Promise<void>"
|
|
619
624
|
},
|
|
620
625
|
"docs": {
|
|
621
|
-
"text": "Inject data into an embedded mrd-table for a RELATED_VIEW or VIEW item.\nPass totalElements to update the pagination total (safe to pass on every page).",
|
|
626
|
+
"text": "Inject data into an embedded mrd-table for a RELATED_VIEW or VIEW item.\nPass totalElements to update the pagination total (safe to pass on every page).\nPass hasNext (from _links.next presence) so the table can decide whether to emit aggregations.",
|
|
622
627
|
"tags": []
|
|
623
628
|
}
|
|
624
629
|
},
|