@smartsoft001-mobilems/objects-shell-angular 2.121.0 → 2.123.0
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.
|
@@ -1,12 +1,14 @@
|
|
|
1
1
|
import * as i0 from '@angular/core';
|
|
2
|
-
import { Injectable, inject, contentChild, ChangeDetectionStrategy, Component, NgModule, Directive, signal, effect } from '@angular/core';
|
|
3
|
-
import { FILE_SERVICE_CONFIG } from '@smartsoft001/angular';
|
|
2
|
+
import { Injectable, inject, contentChild, ChangeDetectionStrategy, Component, NgModule, Directive, signal, effect, PLATFORM_ID, viewChild, computed, untracked } from '@angular/core';
|
|
3
|
+
import { FILE_SERVICE_CONFIG, PaginationMode, ListMode } from '@smartsoft001/angular';
|
|
4
4
|
import { CrudFacade, initialState as initialState$1, getReducer as getReducer$1, CrudService, CrudConfig, CrudFullConfig, CrudCoreModule, CrudModule, CrudListPageBaseComponent, CrudItemPageBaseComponent } from '@smartsoft001/crud-shell-angular';
|
|
5
|
-
import { CrudBaseService, FiltersBaseComponent, provideInheritedSharedConfig, SharedModule, SeoService, TranslationService } from '@smartsoft001-mobilems/angular';
|
|
6
|
-
import { NgTemplateOutlet, CommonModule } from '@angular/common';
|
|
5
|
+
import { CrudBaseService, FiltersBaseComponent, provideInheritedSharedConfig, SharedModule, SeoService, TranslationService, MuseumSeoService, WcagChangesService, createSafeTimeouts, MasonryGridComponent, createCatalog, createCatalogLoadMore } from '@smartsoft001-mobilems/angular';
|
|
6
|
+
import { NgTemplateOutlet, CommonModule, isPlatformBrowser } from '@angular/common';
|
|
7
7
|
import { createFeatureSelector } from '@ngrx/store';
|
|
8
8
|
import { toSignal } from '@angular/core/rxjs-interop';
|
|
9
9
|
import { ActivatedRoute } from '@angular/router';
|
|
10
|
+
import { TranslateService } from '@ngx-translate/core';
|
|
11
|
+
import { capitalize } from '@smartsoft001/utils';
|
|
10
12
|
|
|
11
13
|
class ObjectsService extends CrudBaseService {
|
|
12
14
|
getUrlNameForDetails() {
|
|
@@ -297,9 +299,274 @@ const MULTIMEDIA_DICTIONARY = [
|
|
|
297
299
|
},
|
|
298
300
|
];
|
|
299
301
|
|
|
302
|
+
/**
|
|
303
|
+
* Filter defaults of the objects list (Muzeum Podlasia): 20 objects per page,
|
|
304
|
+
* newest first. **The key order is part of the contract** — the first read
|
|
305
|
+
* spreads this object first, so it shapes the facade filter, the persisted
|
|
306
|
+
* `MUSEUM_OBJECTS_FILTER` value and the `#base64` hash.
|
|
307
|
+
*/
|
|
308
|
+
const OBJECTS_CATALOG_DEFAULTS = {
|
|
309
|
+
paginationMode: PaginationMode.singlePage,
|
|
310
|
+
sortBy: 'publication-date',
|
|
311
|
+
sortDesc: true,
|
|
312
|
+
offset: 0,
|
|
313
|
+
limit: 20,
|
|
314
|
+
};
|
|
315
|
+
const OBJECTS_CATALOG_SEO = {
|
|
316
|
+
titleKey: 'PAGE_TITLES.objects',
|
|
317
|
+
descriptionKey: 'HOME.collectionsDescription',
|
|
318
|
+
siteNameKey: 'MODEL.mainTitle',
|
|
319
|
+
url: '/obiekty',
|
|
320
|
+
};
|
|
321
|
+
const OBJECTS_CATALOG_ITEM_SELECTOR = '[data-testid="objects-grid-item-link"], [data-testid="objects-list-item"]';
|
|
322
|
+
const OBJECTS_CATALOG_LOADED_MORE_KEY = 'OBJECTS.loadedMore';
|
|
323
|
+
/**
|
|
324
|
+
* Base of an objects list page on the shared catalog engine
|
|
325
|
+
* (`createCatalog`): first read (also in SSR when the route carries the
|
|
326
|
+
* filter), persistence, page, search, the read guard, the mobile list mode,
|
|
327
|
+
* „więcej ↓”, the masonry lifecycle and the list SEO. The page keeps its
|
|
328
|
+
* template.
|
|
329
|
+
*
|
|
330
|
+
* ```ts
|
|
331
|
+
* export class ListComponent extends ObjectsCatalogBaseComponent {
|
|
332
|
+
* constructor() {
|
|
333
|
+
* super();
|
|
334
|
+
* }
|
|
335
|
+
* }
|
|
336
|
+
* ```
|
|
337
|
+
*
|
|
338
|
+
* The template holds a `#listContainer` element (scrolled to after a page
|
|
339
|
+
* change from the bottom pagination; it holds the cards focused by load
|
|
340
|
+
* more) and a `smart-mobilems-masonry-grid` in the grid mode.
|
|
341
|
+
*/
|
|
342
|
+
class ObjectsCatalogBaseComponent extends ObjectsListComponent {
|
|
343
|
+
constructor(options = {}) {
|
|
344
|
+
super();
|
|
345
|
+
this.ListMode = ListMode;
|
|
346
|
+
/** Screen reader message after cards were appended. */
|
|
347
|
+
this.loadMoreStatus = signal('', /* @ts-ignore */
|
|
348
|
+
...(ngDevMode ? [{ debugName: "loadMoreStatus" }] : /* istanbul ignore next */ []));
|
|
349
|
+
this.objectsCatalogTranslate = inject(TranslateService);
|
|
350
|
+
this.objectsCatalogSeoService = inject(MuseumSeoService);
|
|
351
|
+
this.objectsCatalogWcag = inject(WcagChangesService);
|
|
352
|
+
this.objectsCatalogBrowser = isPlatformBrowser(inject(PLATFORM_ID));
|
|
353
|
+
this.objectsCatalogTimeouts = createSafeTimeouts();
|
|
354
|
+
this.objectsCatalogMasonry = viewChild(MasonryGridComponent, /* @ts-ignore */
|
|
355
|
+
...(ngDevMode ? [{ debugName: "objectsCatalogMasonry" }] : /* istanbul ignore next */ []));
|
|
356
|
+
this.objectsCatalogListContainer = viewChild('listContainer', /* @ts-ignore */
|
|
357
|
+
...(ngDevMode ? [{ debugName: "objectsCatalogListContainer" }] : /* istanbul ignore next */ []));
|
|
358
|
+
this.objectsCatalogViewReady = false;
|
|
359
|
+
this.objectsCatalogScrollAfterLoad = false;
|
|
360
|
+
this.objectsCatalogQueryParams = toSignal(inject(ActivatedRoute).queryParams);
|
|
361
|
+
const { seo = OBJECTS_CATALOG_SEO, loadMore = {}, ...catalogOptions } = options;
|
|
362
|
+
const defaults = catalogOptions.defaults ?? OBJECTS_CATALOG_DEFAULTS;
|
|
363
|
+
this.catalog = createCatalog({
|
|
364
|
+
persistKey: 'MUSEUM_OBJECTS_FILTER',
|
|
365
|
+
listPath: '/obiekty',
|
|
366
|
+
searchTab: 'obiekty',
|
|
367
|
+
listModeKey: 'MUSEUM_OBJECTS_LIST_MODE',
|
|
368
|
+
ssrRead: 'route',
|
|
369
|
+
// Mobile mockup (2300:51189) has the grid only — the view toggle is
|
|
370
|
+
// hidden below md, so a stored list view does not apply there.
|
|
371
|
+
mobileListModeBelow: 768,
|
|
372
|
+
...catalogOptions,
|
|
373
|
+
defaults,
|
|
374
|
+
facade: this.facade,
|
|
375
|
+
});
|
|
376
|
+
this.isBrowser = this.catalog.isBrowser;
|
|
377
|
+
this.routeList = this.catalog.routeList;
|
|
378
|
+
this.listMode = this.catalog.listMode;
|
|
379
|
+
this.searchEnabled = this.catalog.searchEnabled;
|
|
380
|
+
this.barPhrase = this.catalog.barPhrase;
|
|
381
|
+
this.isLoading = this.catalog.isLoading;
|
|
382
|
+
this.hasError = this.catalog.hasError;
|
|
383
|
+
this.totalCount = this.catalog.totalCount;
|
|
384
|
+
this.sortKey = this.catalog.sortKey;
|
|
385
|
+
this.selectedPage = this.catalog.selectedPage;
|
|
386
|
+
this.isNewType = computed(() => this.objectsCatalogQueryParams()?.['type'] === 'new', /* @ts-ignore */
|
|
387
|
+
...(ngDevMode ? [{ debugName: "isNewType" }] : /* istanbul ignore next */ []));
|
|
388
|
+
// „więcej ↓” (mobile mockup 2300:51213); the focus moves to the first
|
|
389
|
+
// appended card, without scrolling — the new cards sit right below.
|
|
390
|
+
this.objectsCatalogLoadMore = createCatalogLoadMore({
|
|
391
|
+
list: this.list,
|
|
392
|
+
filter: this.facade.filter,
|
|
393
|
+
totalCount: this.totalCount,
|
|
394
|
+
loading: this.isLoading,
|
|
395
|
+
read: (filter) => this.facade.read(filter),
|
|
396
|
+
defaultLimit: defaults.limit || 20,
|
|
397
|
+
onAppended: (added, firstIndex) => {
|
|
398
|
+
this.loadMoreStatus.set(this.objectsCatalogTranslate.instant(loadMore.loadedMoreKey ?? OBJECTS_CATALOG_LOADED_MORE_KEY, { count: added }));
|
|
399
|
+
if (!added || !this.objectsCatalogBrowser)
|
|
400
|
+
return;
|
|
401
|
+
this.objectsCatalogTimeouts.later(() => this.listContainerElement
|
|
402
|
+
?.querySelectorAll(loadMore.itemSelector ?? OBJECTS_CATALOG_ITEM_SELECTOR)[firstIndex]?.focus({ preventScroll: true }), 0);
|
|
403
|
+
},
|
|
404
|
+
});
|
|
405
|
+
this.items = this.objectsCatalogLoadMore.items;
|
|
406
|
+
this.hasMore = this.objectsCatalogLoadMore.hasMore;
|
|
407
|
+
this.isAppending = this.objectsCatalogLoadMore.isAppending;
|
|
408
|
+
// Every loaded card (appended pages included) goes to the page, e.g. for
|
|
409
|
+
// „select all” (MOB-1661). Untracked: the hook's own reads do not re-run it.
|
|
410
|
+
effect(() => {
|
|
411
|
+
const items = this.items();
|
|
412
|
+
untracked(() => this.onCatalogItems(items));
|
|
413
|
+
});
|
|
414
|
+
// After a page change from the bottom pagination scroll to the list top
|
|
415
|
+
// once the data has loaded.
|
|
416
|
+
effect(() => {
|
|
417
|
+
const loading = this.isLoading();
|
|
418
|
+
if (!loading &&
|
|
419
|
+
this.objectsCatalogScrollAfterLoad &&
|
|
420
|
+
this.objectsCatalogBrowser) {
|
|
421
|
+
this.objectsCatalogScrollAfterLoad = false;
|
|
422
|
+
this.objectsCatalogTimeouts.later(() => this.listContainerElement?.scrollIntoView({
|
|
423
|
+
behavior: 'smooth',
|
|
424
|
+
block: 'start',
|
|
425
|
+
}), 0);
|
|
426
|
+
}
|
|
427
|
+
});
|
|
428
|
+
// Re-layout masonry on WCAG/contrast changes.
|
|
429
|
+
effect(() => {
|
|
430
|
+
this.objectsCatalogWcag.wcagSettingsChanged();
|
|
431
|
+
if (!this.objectsCatalogViewReady) {
|
|
432
|
+
return;
|
|
433
|
+
}
|
|
434
|
+
this.objectsCatalogDestroyMasonry();
|
|
435
|
+
this.objectsCatalogInitMasonry();
|
|
436
|
+
});
|
|
437
|
+
// Re-layout masonry when the list changes.
|
|
438
|
+
effect(() => {
|
|
439
|
+
const items = this.items();
|
|
440
|
+
const mode = this.listMode();
|
|
441
|
+
if (items && mode === ListMode.masonryGrid) {
|
|
442
|
+
this.objectsCatalogDestroyMasonry();
|
|
443
|
+
this.objectsCatalogTimeouts.later(() => this.objectsCatalogInitMasonry(), 150);
|
|
444
|
+
}
|
|
445
|
+
});
|
|
446
|
+
// Initialise masonry once the grid component is present.
|
|
447
|
+
effect(() => {
|
|
448
|
+
const masonry = this.objectsCatalogMasonry();
|
|
449
|
+
const mode = this.listMode();
|
|
450
|
+
const items = this.items();
|
|
451
|
+
if (masonry && mode === ListMode.masonryGrid && items?.length) {
|
|
452
|
+
this.objectsCatalogTimeouts.later(() => this.objectsCatalogInitMasonry(), 250);
|
|
453
|
+
}
|
|
454
|
+
});
|
|
455
|
+
if (seo)
|
|
456
|
+
this.applyListSeo(seo);
|
|
457
|
+
}
|
|
458
|
+
/** The list root element (`#listContainer`). */
|
|
459
|
+
get listContainerElement() {
|
|
460
|
+
return this.objectsCatalogListContainer()?.nativeElement;
|
|
461
|
+
}
|
|
462
|
+
/**
|
|
463
|
+
* „więcej ↓” — reads the next page and appends it under the current cards
|
|
464
|
+
* (no scrolling, no loader in place of the list).
|
|
465
|
+
*/
|
|
466
|
+
loadMore() {
|
|
467
|
+
if (this.isLoading() || !this.hasMore()) {
|
|
468
|
+
return;
|
|
469
|
+
}
|
|
470
|
+
// Cleared first, so the live region changes — and is announced — even
|
|
471
|
+
// when the next page brings the same number of cards.
|
|
472
|
+
this.loadMoreStatus.set('');
|
|
473
|
+
this.objectsCatalogLoadMore.loadMore();
|
|
474
|
+
}
|
|
475
|
+
retryLoad() {
|
|
476
|
+
this.catalog.retry();
|
|
477
|
+
}
|
|
478
|
+
pageChange(page) {
|
|
479
|
+
this.catalog.setPage(page);
|
|
480
|
+
}
|
|
481
|
+
/** Page change from the bottom pagination — scrolls to the list once loaded. */
|
|
482
|
+
bottomPageChange(page) {
|
|
483
|
+
this.objectsCatalogScrollAfterLoad = true;
|
|
484
|
+
this.pageChange(page);
|
|
485
|
+
}
|
|
486
|
+
/**
|
|
487
|
+
* In the catalog it reads with the phrase from the first page. In a search
|
|
488
|
+
* tab the address is the only source of the phrase (MOB-1818): a new one
|
|
489
|
+
* opens `/wyszukaj/:text/obiekty`, a blank one `/obiekty` with the other
|
|
490
|
+
* filters.
|
|
491
|
+
*/
|
|
492
|
+
search(phrase) {
|
|
493
|
+
this.catalog.search(phrase);
|
|
494
|
+
}
|
|
495
|
+
/**
|
|
496
|
+
* A filter change in a search tab (MOB-1818) opens `/obiekty` with the whole
|
|
497
|
+
* filter, the phrase (`filter[phrase]`), the sort and the page size instead
|
|
498
|
+
* of narrowing the results in place.
|
|
499
|
+
*/
|
|
500
|
+
openInCatalog(filter) {
|
|
501
|
+
this.catalog.openInList(filter);
|
|
502
|
+
}
|
|
503
|
+
onListMode(value) {
|
|
504
|
+
const newMode = value === ListMode.masonryGrid ? ListMode.masonryGrid : ListMode.desktop;
|
|
505
|
+
this.catalog.setListMode(newMode);
|
|
506
|
+
// Below the mobile breakpoint the mode is forced and the toggle ignored.
|
|
507
|
+
if (this.listMode() !== newMode)
|
|
508
|
+
return;
|
|
509
|
+
if (newMode !== ListMode.masonryGrid) {
|
|
510
|
+
this.objectsCatalogDestroyMasonry();
|
|
511
|
+
}
|
|
512
|
+
else {
|
|
513
|
+
this.objectsCatalogTimeouts.later(() => this.objectsCatalogInitMasonry(), 100);
|
|
514
|
+
}
|
|
515
|
+
}
|
|
516
|
+
ngAfterViewInit() {
|
|
517
|
+
this.objectsCatalogInitMasonry();
|
|
518
|
+
this.objectsCatalogViewReady = true;
|
|
519
|
+
}
|
|
520
|
+
ngOnDestroy() {
|
|
521
|
+
super.ngOnDestroy();
|
|
522
|
+
this.objectsCatalogDestroyMasonry();
|
|
523
|
+
}
|
|
524
|
+
/**
|
|
525
|
+
* Called with every loaded card (appended „więcej ↓” pages included) each
|
|
526
|
+
* time they change, untracked. No-op; e.g. Podlasie feeds its
|
|
527
|
+
* `SelectionStore` here.
|
|
528
|
+
*/
|
|
529
|
+
onCatalogItems(items) {
|
|
530
|
+
void items;
|
|
531
|
+
}
|
|
532
|
+
/**
|
|
533
|
+
* Full list meta (title, description, canonical, og), not in a search tab —
|
|
534
|
+
* there the search page sets them, and the canonical of the list must not
|
|
535
|
+
* point at a phrase url (MOB-1064). The description goes out as translated.
|
|
536
|
+
*/
|
|
537
|
+
applyListSeo(seo) {
|
|
538
|
+
if (this.catalog.searchEnabled())
|
|
539
|
+
return;
|
|
540
|
+
const t = (key) => this.objectsCatalogTranslate.instant(key);
|
|
541
|
+
this.objectsCatalogSeoService.apply({
|
|
542
|
+
title: `${capitalize(t(seo.titleKey))} - ${capitalize(t(seo.siteNameKey ?? 'MODEL.mainTitle'))}`,
|
|
543
|
+
description: t(seo.descriptionKey),
|
|
544
|
+
type: 'website',
|
|
545
|
+
url: seo.url,
|
|
546
|
+
});
|
|
547
|
+
}
|
|
548
|
+
objectsCatalogInitMasonry() {
|
|
549
|
+
if (this.listMode() !== ListMode.masonryGrid ||
|
|
550
|
+
!this.objectsCatalogBrowser) {
|
|
551
|
+
return;
|
|
552
|
+
}
|
|
553
|
+
// The MasonryGridComponent owns the masonry library and the image-load
|
|
554
|
+
// handling; it packs the projected `.masonry-item` cards.
|
|
555
|
+
this.objectsCatalogMasonry()?.initMasonry();
|
|
556
|
+
}
|
|
557
|
+
objectsCatalogDestroyMasonry() {
|
|
558
|
+
this.objectsCatalogMasonry()?.destroyMasonry();
|
|
559
|
+
}
|
|
560
|
+
/** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.3", ngImport: i0, type: ObjectsCatalogBaseComponent, deps: "invalid", target: i0.ɵɵFactoryTarget.Directive }); }
|
|
561
|
+
/** @nocollapse */ static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.2.0", version: "22.1.3", type: ObjectsCatalogBaseComponent, isStandalone: true, viewQueries: [{ propertyName: "objectsCatalogMasonry", first: true, predicate: MasonryGridComponent, descendants: true, isSignal: true }, { propertyName: "objectsCatalogListContainer", first: true, predicate: ["listContainer"], descendants: true, isSignal: true }], usesInheritance: true, ngImport: i0 }); }
|
|
562
|
+
}
|
|
563
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.3", ngImport: i0, type: ObjectsCatalogBaseComponent, decorators: [{
|
|
564
|
+
type: Directive
|
|
565
|
+
}], ctorParameters: () => [{ type: undefined }], propDecorators: { objectsCatalogMasonry: [{ type: i0.ViewChild, args: [i0.forwardRef(() => MasonryGridComponent), { isSignal: true }] }], objectsCatalogListContainer: [{ type: i0.ViewChild, args: ['listContainer', { isSignal: true }] }] } });
|
|
566
|
+
|
|
300
567
|
/**
|
|
301
568
|
* Generated bundle index. Do not edit.
|
|
302
569
|
*/
|
|
303
570
|
|
|
304
|
-
export { AdvancedFilterType, ComponentsModule, FiltersComponent, FormFeatureType, ListComponent, MULTIMEDIA_DICTIONARY, ObjectsFacade, ObjectsItemComponent, ObjectsListComponent, ObjectsModule, ObjectsService, ObjectsSharedModule, SERVICES, getObjectsState, getReducer, initialState };
|
|
571
|
+
export { AdvancedFilterType, ComponentsModule, FiltersComponent, FormFeatureType, ListComponent, MULTIMEDIA_DICTIONARY, OBJECTS_CATALOG_DEFAULTS, OBJECTS_CATALOG_SEO, ObjectsCatalogBaseComponent, ObjectsFacade, ObjectsItemComponent, ObjectsListComponent, ObjectsModule, ObjectsService, ObjectsSharedModule, SERVICES, getObjectsState, getReducer, initialState };
|
|
305
572
|
//# sourceMappingURL=smartsoft001-mobilems-objects-shell-angular.mjs.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"smartsoft001-mobilems-objects-shell-angular.mjs","sources":["../../../../../../packages/objects/shell/angular/src/lib/services/objects/objects.service.ts","../../../../../../packages/objects/shell/angular/src/lib/+state/objects.facade.ts","../../../../../../packages/objects/shell/angular/src/lib/+state/objects.reducer.ts","../../../../../../packages/objects/shell/angular/src/lib/components/list/list.component.ts","../../../../../../packages/objects/shell/angular/src/lib/components/list/list.component.html","../../../../../../packages/objects/shell/angular/src/lib/components/filters/filters.component.ts","../../../../../../packages/objects/shell/angular/src/lib/components/filters/filters.component.html","../../../../../../packages/objects/shell/angular/src/lib/components/components.module.ts","../../../../../../packages/objects/shell/angular/src/lib/services/index.ts","../../../../../../packages/objects/shell/angular/src/lib/objects.module.ts","../../../../../../packages/objects/shell/angular/src/lib/objects-shared.module.ts","../../../../../../packages/objects/shell/angular/src/lib/+state/objects.selectors.ts","../../../../../../packages/objects/shell/angular/src/lib/pages/list/list.component.ts","../../../../../../packages/objects/shell/angular/src/lib/pages/item/item.component.ts","../../../../../../packages/objects/shell/angular/src/lib/models/objects-filters.model.ts","../../../../../../packages/objects/shell/angular/src/smartsoft001-mobilems-objects-shell-angular.ts"],"sourcesContent":["import { Injectable } from '@angular/core';\n\nimport { CrudBaseService } from '@smartsoft001-mobilems/angular';\nimport { MsObject } from '@smartsoft001-mobilems/objects-domain';\n\n@Injectable()\nexport class ObjectsService extends CrudBaseService<MsObject> {\n getUrlNameForDetails(): string {\n return 'object';\n }\n\n getUrlNameForList(): string {\n return 'Object';\n }\n}\n","import { inject, Injectable } from '@angular/core';\nimport { CrudFacade } from '@smartsoft001/crud-shell-angular';\n\nimport { MsObject } from '@smartsoft001-mobilems/objects-domain';\n\nimport { ObjectsService } from '../services/objects/objects.service';\n\n@Injectable()\nexport class ObjectsFacade extends CrudFacade<MsObject> {\n protected service = inject(ObjectsService);\n\n async downloadPdf(item: { title: string; id: string }): Promise<void> {\n await this.service.downloadPdf(item.title, item.id);\n }\n}\n","import { Action } from '@ngrx/store';\nimport {\n State as SmartState,\n initialState as smartInitialState,\n getReducer as smartGetReducer,\n} from '@smartsoft001/crud-shell-angular';\n\nimport { MsObject } from '@smartsoft001-mobilems/objects-domain';\n\n// import {objectsFacade} from \"./objects.facade\";\n\nexport type State = SmartState<MsObject>;\n\nexport const initialState = {\n ...smartInitialState,\n};\n\nconst objectsReducer = (state = initialState, action: any) => {\n switch (action.type) {\n //case objectsFacade.name + ' test':\n // return {\n // ...state,\n // loaded: false,\n // }\n\n default:\n return smartGetReducer('objects')(state, action);\n }\n};\n\nexport function getReducer() {\n return (state: any, action: Action) => {\n return objectsReducer(state, action);\n };\n}\n","import { NgTemplateOutlet } from '@angular/common';\nimport {\n Component,\n TemplateRef,\n contentChild,\n inject,\n ChangeDetectionStrategy,\n} from '@angular/core';\n\nimport { ObjectsFacade } from '../../+state/objects.facade';\n\n@Component({\n selector: 'smart-mobilems-objects-list',\n templateUrl: './list.component.html',\n changeDetection: ChangeDetectionStrategy.Eager,\n imports: [NgTemplateOutlet],\n})\nexport class ListComponent {\n private facade = inject(ObjectsFacade);\n\n list = this.facade.list;\n loading = this.facade.loading;\n\n itemTpl = contentChild<TemplateRef<any>>('itemTpl');\n loadingTpl = contentChild<TemplateRef<any>>('loadingTpl');\n}\n","@if (list(); as listData) {\n @if (listData && itemTpl()) {\n @for (item of listData; track item) {\n <ng-container\n *ngTemplateOutlet=\"itemTpl(); context: { $implicit: item }\"\n ></ng-container>\n }\n }\n}\n\n@if (loading()) {\n @if (loadingTpl()) {\n <ng-container *ngTemplateOutlet=\"loadingTpl()\"></ng-container>\n }\n}\n","import { NgTemplateOutlet } from '@angular/common';\nimport { Component, ChangeDetectionStrategy } from '@angular/core';\n\nimport { FiltersBaseComponent } from '@smartsoft001-mobilems/angular';\nimport { MsObject } from '@smartsoft001-mobilems/objects-domain';\n\n@Component({\n selector: 'smart-mobilems-objects-filters',\n templateUrl: './filters.component.html',\n changeDetection: ChangeDetectionStrategy.Eager,\n imports: [NgTemplateOutlet],\n})\nexport class FiltersComponent extends FiltersBaseComponent<MsObject> {}\n","<ng-container\n *ngTemplateOutlet=\"contentTpl(); context: { $implicit: context }\"\n></ng-container>\n","import { CommonModule } from '@angular/common';\nimport { NgModule } from '@angular/core';\n\nimport { FiltersComponent } from './filters/filters.component';\nimport { ListComponent } from './list/list.component';\n\nconst COMPONENTS = [FiltersComponent, ListComponent];\n\n@NgModule({\n imports: [CommonModule, COMPONENTS],\n exports: [...COMPONENTS],\n})\nexport class ComponentsModule {}\n","import { CrudService } from '@smartsoft001/crud-shell-angular';\n\nimport { ObjectsService } from './objects/objects.service';\n\nexport * from './objects/objects.service';\n\nexport const SERVICES = [\n ObjectsService,\n {\n provide: CrudService,\n useClass: ObjectsService,\n },\n];\n","import { ModuleWithProviders, NgModule } from '@angular/core';\nimport { FILE_SERVICE_CONFIG, IFileServiceConfig } from '@smartsoft001/angular';\nimport {\n CrudConfig,\n CrudCoreModule,\n CrudFullConfig,\n ICrudModuleOptionsWithoutRoutng,\n} from '@smartsoft001/crud-shell-angular';\nimport { IEntity } from '@smartsoft001/domain-core';\n\nimport {\n provideInheritedSharedConfig,\n SharedModule,\n} from '@smartsoft001-mobilems/angular';\n\nimport { ObjectsFacade } from './+state/objects.facade';\nimport { getReducer } from './+state/objects.reducer';\nimport { ComponentsModule } from './components';\nimport { SERVICES } from './services';\n\n@NgModule({\n declarations: [],\n providers: [...SERVICES, ObjectsFacade],\n imports: [SharedModule, ComponentsModule, CrudCoreModule],\n exports: [ComponentsModule],\n})\nexport class ObjectsModule {\n static forFeature<T extends IEntity<string>>(\n options: ICrudModuleOptionsWithoutRoutng<T>,\n ): ModuleWithProviders<ObjectsModule> {\n if (!options.config.reducerFactory)\n options.config.reducerFactory = getReducer;\n return {\n ngModule: ObjectsModule,\n providers: [\n provideInheritedSharedConfig(options.config.apiUrl),\n { provide: CrudConfig, useValue: options.config },\n { provide: CrudFullConfig, useValue: options.config },\n {\n provide: FILE_SERVICE_CONFIG,\n useValue: { apiUrl: options.config.apiUrl } as IFileServiceConfig,\n },\n ],\n };\n }\n}\n","import { ModuleWithProviders, NgModule } from '@angular/core';\nimport { FILE_SERVICE_CONFIG, IFileServiceConfig } from '@smartsoft001/angular';\nimport {\n CrudConfig,\n CrudFullConfig,\n CrudModule,\n ICrudModuleOptionsWithoutRoutng,\n} from '@smartsoft001/crud-shell-angular';\nimport { IEntity } from '@smartsoft001/domain-core';\n\nimport {\n provideInheritedSharedConfig,\n SharedModule,\n} from '@smartsoft001-mobilems/angular';\n\nimport { ObjectsFacade } from './+state/objects.facade';\nimport { getReducer } from './+state/objects.reducer';\nimport { ComponentsModule } from './components';\nimport { SERVICES } from './services';\n\n@NgModule({\n declarations: [],\n providers: [...SERVICES, ObjectsFacade],\n imports: [SharedModule, ComponentsModule, CrudModule],\n exports: [ComponentsModule, CrudModule],\n})\nexport class ObjectsSharedModule {\n static forFeature<T extends IEntity<string>>(\n options: ICrudModuleOptionsWithoutRoutng<T>,\n ): ModuleWithProviders<ObjectsSharedModule> {\n if (!options.config.reducerFactory)\n options.config.reducerFactory = getReducer;\n return {\n ngModule: ObjectsSharedModule,\n providers: [\n provideInheritedSharedConfig(options.config.apiUrl),\n { provide: CrudConfig, useValue: options.config },\n { provide: CrudFullConfig, useValue: options.config },\n {\n provide: FILE_SERVICE_CONFIG,\n useValue: { apiUrl: options.config.apiUrl } as IFileServiceConfig,\n },\n ],\n };\n }\n}\n","import {\n createFeatureSelector,\n //createSelector\n} from '@ngrx/store';\n\nimport { State } from './objects.reducer';\n\nexport const getObjectsState = createFeatureSelector<State>('objects');\n\n//export const getobjectsTest = createSelector(\n// getobjectsState,\n// (state) => state.test\n//);\n","import { Directive, inject, Signal } from '@angular/core';\nimport { CrudListPageBaseComponent } from '@smartsoft001/crud-shell-angular';\n\nimport { MsObject } from '@smartsoft001-mobilems/objects-domain';\n\nimport { ObjectsFacade } from '../../+state';\n\n@Directive()\nexport abstract class ObjectsListComponent extends CrudListPageBaseComponent<MsObject> {\n protected readonly facade = inject(ObjectsFacade);\n\n list = this.facade.list as Signal<MsObject[]>;\n loading = this.facade.loading;\n filter = this.facade.filter;\n}\n","import { Directive, effect, inject, signal } from '@angular/core';\nimport { toSignal } from '@angular/core/rxjs-interop';\nimport { ActivatedRoute } from '@angular/router';\nimport { CrudItemPageBaseComponent } from '@smartsoft001/crud-shell-angular';\n\nimport { SeoService, TranslationService } from '@smartsoft001-mobilems/angular';\nimport { MsObject } from '@smartsoft001-mobilems/objects-domain';\n\nimport { ObjectsFacade } from '../../+state';\n\n@Directive()\nexport abstract class ObjectsItemComponent extends CrudItemPageBaseComponent<MsObject> {\n protected readonly route = inject(ActivatedRoute);\n protected readonly seoService = inject(SeoService);\n protected readonly translationService = inject(TranslationService);\n protected readonly params = toSignal(this.route.params);\n\n override facade = inject(ObjectsFacade);\n\n readonly loading = this.facade.loading;\n readonly item = this.facade.selected;\n readonly isPdfDownloading = signal(false);\n\n protected constructor() {\n super();\n\n effect(() => {\n const params = this.params();\n\n const id = params['id'];\n if (id) {\n this.facade.select(id);\n }\n });\n }\n\n async onDownload(): Promise<void> {\n this.isPdfDownloading.set(true);\n try {\n await this.facade.downloadPdf({\n id: this.item()?.id.toString() || '',\n title: this.item()?.title as string,\n });\n } catch (error) {\n console.error('PDF download failed:', error);\n } finally {\n this.isPdfDownloading.set(false);\n }\n }\n}\n","import { MsFile } from '@smartsoft001-mobilems/models';\nimport { MsObject } from '@smartsoft001-mobilems/objects-domain';\n\nexport type SortType =\n 'random' | 'date-asc' | 'date-desc' | 'name-asc' | 'name-desc';\n\nexport type IKeyValue = {\n key: string;\n value?: string;\n};\n\nexport enum AdvancedFilterType {\n CREATORS = 'creators',\n AUTHORS = 'authors',\n MATERIALS = 'materials',\n TECHNIQUES = 'techniques',\n CREATE_PLACES = 'createPlaces',\n KEYWORDS = 'keywords',\n}\n\nexport enum FormFeatureType {\n MODEL_3D = 1,\n PHOTO_360 = 2,\n IMAGES = 3,\n AUDIO = 7,\n AUDIO_DESKRYPCJA = 8,\n VIDEO = 9,\n ORTHOGRAPHY = 11,\n OTHER = 13,\n IMAGES_HD = 14,\n VIRTUAL_WALK = 15,\n ANIMATION = 20,\n}\n\nexport interface IMultimediaDictionaryItem {\n id: FormFeatureType;\n translationKey: string;\n}\n\n/**\n * Dictionary of multimedia types with their translation keys.\n * Use with TranslateService to get localized names.\n */\nexport const MULTIMEDIA_DICTIONARY: IMultimediaDictionaryItem[] = [\n {\n id: FormFeatureType.IMAGES,\n translationKey: 'OBJECTS.filters.multimedia.images',\n },\n {\n id: FormFeatureType.IMAGES_HD,\n translationKey: 'OBJECTS.filters.multimedia.galleryHD',\n },\n {\n id: FormFeatureType.MODEL_3D,\n translationKey: 'OBJECTS.filters.multimedia.model3D',\n },\n {\n id: FormFeatureType.AUDIO,\n translationKey: 'OBJECTS.filters.multimedia.audio',\n },\n {\n id: FormFeatureType.AUDIO_DESKRYPCJA,\n translationKey: 'OBJECTS.filters.multimedia.audioDescription',\n },\n {\n id: FormFeatureType.VIDEO,\n translationKey: 'OBJECTS.filters.multimedia.video',\n },\n {\n id: FormFeatureType.ANIMATION,\n translationKey: 'OBJECTS.filters.multimedia.animation',\n },\n {\n id: FormFeatureType.VIRTUAL_WALK,\n translationKey: 'OBJECTS.filters.multimedia.virtualWalk',\n },\n {\n id: FormFeatureType.OTHER,\n translationKey: 'OBJECTS.filters.multimedia.other',\n },\n];\n\nexport type FileType = Omit<MsFile, 'formFeature'> & {\n formFeature: FormFeatureType;\n};\n\ninterface Model3DFile {\n id: number;\n filePath: string;\n extension: string;\n altText: string | null;\n fileName: string;\n}\n\nexport interface IModel3DObject {\n formFeature: FormFeatureType;\n files: Model3DFile[];\n description: string | null;\n iframeSource: string | null;\n iframeHtml: string | null;\n isRemote: boolean;\n originalDimensions: string | null;\n id: number;\n position: number;\n filePath: string;\n extension: string;\n altText: string | null;\n altTextEn: string | null;\n vimeoUrl: string | null;\n}\n\nexport interface IAnimationObject {\n formFeature: FormFeatureType;\n files: MsFile[];\n description: string | null;\n iframeSource: string | null;\n iframeHtml: string | null;\n isRemote: boolean;\n originalDimensions: string | null;\n id: number;\n position: number;\n filePath: string;\n extension: string;\n altText: string | null;\n altTextEn: string | null;\n vimeoUrl: string | null;\n}\n\n// Leci z API, nie jest udokumentowane\nexport interface ISpecificObject extends MsObject {\n dimensionTextWithDuration?: string;\n specificDimensionDescription?: string;\n publicationDate?: string;\n authors?: Array<{\n id: number;\n name: string;\n role?: string;\n additionalRoles?: string[];\n comment?: string;\n }>;\n createPlaces?: Array<{\n id: number;\n name: string;\n comment?: string;\n }>;\n materials?: Array<{\n id: number;\n name: string;\n comment?: string;\n }>;\n techniques?: Array<{\n id: number;\n name: string;\n comment?: string;\n }>;\n createdAt?: string | Date;\n createDates?: Array<{\n id: number;\n name: string;\n comment?: string;\n }>;\n visited?: number;\n objectCardDownloadCount?: number;\n shareMuseumObjectMultimediaEnabled?: boolean;\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":["smartInitialState","smartGetReducer"],"mappings":";;;;;;;;;;AAMM,MAAO,cAAe,SAAQ,eAAyB,CAAA;IAC3D,oBAAoB,GAAA;AAClB,QAAA,OAAO,QAAQ;IACjB;IAEA,iBAAiB,GAAA;AACf,QAAA,OAAO,QAAQ;IACjB;iIAPW,cAAc,EAAA,IAAA,EAAA,IAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,UAAA,EAAA,CAAA,CAAA;qIAAd,cAAc,EAAA,CAAA,CAAA;;2FAAd,cAAc,EAAA,UAAA,EAAA,CAAA;kBAD1B;;;ACGK,MAAO,aAAc,SAAQ,UAAoB,CAAA;AADvD,IAAA,WAAA,GAAA;;AAEY,QAAA,IAAA,CAAA,OAAO,GAAG,MAAM,CAAC,cAAc,CAAC;AAK3C,IAAA;IAHC,MAAM,WAAW,CAAC,IAAmC,EAAA;AACnD,QAAA,MAAM,IAAI,CAAC,OAAO,CAAC,WAAW,CAAC,IAAI,CAAC,KAAK,EAAE,IAAI,CAAC,EAAE,CAAC;IACrD;iIALW,aAAa,EAAA,IAAA,EAAA,IAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,UAAA,EAAA,CAAA,CAAA;qIAAb,aAAa,EAAA,CAAA,CAAA;;2FAAb,aAAa,EAAA,UAAA,EAAA,CAA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AA,cAAc,EAAE,wCAAwC;AACzD,KAAA;AACD,IAAA;QACE,EAAE,EAAE,eAAe,CAAC,KAAK;AACzB,QAAA,cAAc,EAAE,kCAAkC;AACnD,KAAA;;;AC/EH;;AAEG;;;;"}
|
|
1
|
+
{"version":3,"file":"smartsoft001-mobilems-objects-shell-angular.mjs","sources":["../../../../../../packages/objects/shell/angular/src/lib/services/objects/objects.service.ts","../../../../../../packages/objects/shell/angular/src/lib/+state/objects.facade.ts","../../../../../../packages/objects/shell/angular/src/lib/+state/objects.reducer.ts","../../../../../../packages/objects/shell/angular/src/lib/components/list/list.component.ts","../../../../../../packages/objects/shell/angular/src/lib/components/list/list.component.html","../../../../../../packages/objects/shell/angular/src/lib/components/filters/filters.component.ts","../../../../../../packages/objects/shell/angular/src/lib/components/filters/filters.component.html","../../../../../../packages/objects/shell/angular/src/lib/components/components.module.ts","../../../../../../packages/objects/shell/angular/src/lib/services/index.ts","../../../../../../packages/objects/shell/angular/src/lib/objects.module.ts","../../../../../../packages/objects/shell/angular/src/lib/objects-shared.module.ts","../../../../../../packages/objects/shell/angular/src/lib/+state/objects.selectors.ts","../../../../../../packages/objects/shell/angular/src/lib/pages/list/list.component.ts","../../../../../../packages/objects/shell/angular/src/lib/pages/item/item.component.ts","../../../../../../packages/objects/shell/angular/src/lib/models/objects-filters.model.ts","../../../../../../packages/objects/shell/angular/src/lib/catalog/objects-catalog-base.component.ts","../../../../../../packages/objects/shell/angular/src/smartsoft001-mobilems-objects-shell-angular.ts"],"sourcesContent":["import { Injectable } from '@angular/core';\n\nimport { CrudBaseService } from '@smartsoft001-mobilems/angular';\nimport { MsObject } from '@smartsoft001-mobilems/objects-domain';\n\n@Injectable()\nexport class ObjectsService extends CrudBaseService<MsObject> {\n getUrlNameForDetails(): string {\n return 'object';\n }\n\n getUrlNameForList(): string {\n return 'Object';\n }\n}\n","import { inject, Injectable } from '@angular/core';\nimport { CrudFacade } from '@smartsoft001/crud-shell-angular';\n\nimport { MsObject } from '@smartsoft001-mobilems/objects-domain';\n\nimport { ObjectsService } from '../services/objects/objects.service';\n\n@Injectable()\nexport class ObjectsFacade extends CrudFacade<MsObject> {\n protected service = inject(ObjectsService);\n\n async downloadPdf(item: { title: string; id: string }): Promise<void> {\n await this.service.downloadPdf(item.title, item.id);\n }\n}\n","import { Action } from '@ngrx/store';\nimport {\n State as SmartState,\n initialState as smartInitialState,\n getReducer as smartGetReducer,\n} from '@smartsoft001/crud-shell-angular';\n\nimport { MsObject } from '@smartsoft001-mobilems/objects-domain';\n\n// import {objectsFacade} from \"./objects.facade\";\n\nexport type State = SmartState<MsObject>;\n\nexport const initialState = {\n ...smartInitialState,\n};\n\nconst objectsReducer = (state = initialState, action: any) => {\n switch (action.type) {\n //case objectsFacade.name + ' test':\n // return {\n // ...state,\n // loaded: false,\n // }\n\n default:\n return smartGetReducer('objects')(state, action);\n }\n};\n\nexport function getReducer() {\n return (state: any, action: Action) => {\n return objectsReducer(state, action);\n };\n}\n","import { NgTemplateOutlet } from '@angular/common';\nimport {\n Component,\n TemplateRef,\n contentChild,\n inject,\n ChangeDetectionStrategy,\n} from '@angular/core';\n\nimport { ObjectsFacade } from '../../+state/objects.facade';\n\n@Component({\n selector: 'smart-mobilems-objects-list',\n templateUrl: './list.component.html',\n changeDetection: ChangeDetectionStrategy.Eager,\n imports: [NgTemplateOutlet],\n})\nexport class ListComponent {\n private facade = inject(ObjectsFacade);\n\n list = this.facade.list;\n loading = this.facade.loading;\n\n itemTpl = contentChild<TemplateRef<any>>('itemTpl');\n loadingTpl = contentChild<TemplateRef<any>>('loadingTpl');\n}\n","@if (list(); as listData) {\n @if (listData && itemTpl()) {\n @for (item of listData; track item) {\n <ng-container\n *ngTemplateOutlet=\"itemTpl(); context: { $implicit: item }\"\n ></ng-container>\n }\n }\n}\n\n@if (loading()) {\n @if (loadingTpl()) {\n <ng-container *ngTemplateOutlet=\"loadingTpl()\"></ng-container>\n }\n}\n","import { NgTemplateOutlet } from '@angular/common';\nimport { Component, ChangeDetectionStrategy } from '@angular/core';\n\nimport { FiltersBaseComponent } from '@smartsoft001-mobilems/angular';\nimport { MsObject } from '@smartsoft001-mobilems/objects-domain';\n\n@Component({\n selector: 'smart-mobilems-objects-filters',\n templateUrl: './filters.component.html',\n changeDetection: ChangeDetectionStrategy.Eager,\n imports: [NgTemplateOutlet],\n})\nexport class FiltersComponent extends FiltersBaseComponent<MsObject> {}\n","<ng-container\n *ngTemplateOutlet=\"contentTpl(); context: { $implicit: context }\"\n></ng-container>\n","import { CommonModule } from '@angular/common';\nimport { NgModule } from '@angular/core';\n\nimport { FiltersComponent } from './filters/filters.component';\nimport { ListComponent } from './list/list.component';\n\nconst COMPONENTS = [FiltersComponent, ListComponent];\n\n@NgModule({\n imports: [CommonModule, COMPONENTS],\n exports: [...COMPONENTS],\n})\nexport class ComponentsModule {}\n","import { CrudService } from '@smartsoft001/crud-shell-angular';\n\nimport { ObjectsService } from './objects/objects.service';\n\nexport * from './objects/objects.service';\n\nexport const SERVICES = [\n ObjectsService,\n {\n provide: CrudService,\n useClass: ObjectsService,\n },\n];\n","import { ModuleWithProviders, NgModule } from '@angular/core';\nimport { FILE_SERVICE_CONFIG, IFileServiceConfig } from '@smartsoft001/angular';\nimport {\n CrudConfig,\n CrudCoreModule,\n CrudFullConfig,\n ICrudModuleOptionsWithoutRoutng,\n} from '@smartsoft001/crud-shell-angular';\nimport { IEntity } from '@smartsoft001/domain-core';\n\nimport {\n provideInheritedSharedConfig,\n SharedModule,\n} from '@smartsoft001-mobilems/angular';\n\nimport { ObjectsFacade } from './+state/objects.facade';\nimport { getReducer } from './+state/objects.reducer';\nimport { ComponentsModule } from './components';\nimport { SERVICES } from './services';\n\n@NgModule({\n declarations: [],\n providers: [...SERVICES, ObjectsFacade],\n imports: [SharedModule, ComponentsModule, CrudCoreModule],\n exports: [ComponentsModule],\n})\nexport class ObjectsModule {\n static forFeature<T extends IEntity<string>>(\n options: ICrudModuleOptionsWithoutRoutng<T>,\n ): ModuleWithProviders<ObjectsModule> {\n if (!options.config.reducerFactory)\n options.config.reducerFactory = getReducer;\n return {\n ngModule: ObjectsModule,\n providers: [\n provideInheritedSharedConfig(options.config.apiUrl),\n { provide: CrudConfig, useValue: options.config },\n { provide: CrudFullConfig, useValue: options.config },\n {\n provide: FILE_SERVICE_CONFIG,\n useValue: { apiUrl: options.config.apiUrl } as IFileServiceConfig,\n },\n ],\n };\n }\n}\n","import { ModuleWithProviders, NgModule } from '@angular/core';\nimport { FILE_SERVICE_CONFIG, IFileServiceConfig } from '@smartsoft001/angular';\nimport {\n CrudConfig,\n CrudFullConfig,\n CrudModule,\n ICrudModuleOptionsWithoutRoutng,\n} from '@smartsoft001/crud-shell-angular';\nimport { IEntity } from '@smartsoft001/domain-core';\n\nimport {\n provideInheritedSharedConfig,\n SharedModule,\n} from '@smartsoft001-mobilems/angular';\n\nimport { ObjectsFacade } from './+state/objects.facade';\nimport { getReducer } from './+state/objects.reducer';\nimport { ComponentsModule } from './components';\nimport { SERVICES } from './services';\n\n@NgModule({\n declarations: [],\n providers: [...SERVICES, ObjectsFacade],\n imports: [SharedModule, ComponentsModule, CrudModule],\n exports: [ComponentsModule, CrudModule],\n})\nexport class ObjectsSharedModule {\n static forFeature<T extends IEntity<string>>(\n options: ICrudModuleOptionsWithoutRoutng<T>,\n ): ModuleWithProviders<ObjectsSharedModule> {\n if (!options.config.reducerFactory)\n options.config.reducerFactory = getReducer;\n return {\n ngModule: ObjectsSharedModule,\n providers: [\n provideInheritedSharedConfig(options.config.apiUrl),\n { provide: CrudConfig, useValue: options.config },\n { provide: CrudFullConfig, useValue: options.config },\n {\n provide: FILE_SERVICE_CONFIG,\n useValue: { apiUrl: options.config.apiUrl } as IFileServiceConfig,\n },\n ],\n };\n }\n}\n","import {\n createFeatureSelector,\n //createSelector\n} from '@ngrx/store';\n\nimport { State } from './objects.reducer';\n\nexport const getObjectsState = createFeatureSelector<State>('objects');\n\n//export const getobjectsTest = createSelector(\n// getobjectsState,\n// (state) => state.test\n//);\n","import { Directive, inject, Signal } from '@angular/core';\nimport { CrudListPageBaseComponent } from '@smartsoft001/crud-shell-angular';\n\nimport { MsObject } from '@smartsoft001-mobilems/objects-domain';\n\nimport { ObjectsFacade } from '../../+state';\n\n@Directive()\nexport abstract class ObjectsListComponent extends CrudListPageBaseComponent<MsObject> {\n protected readonly facade = inject(ObjectsFacade);\n\n list = this.facade.list as Signal<MsObject[]>;\n loading = this.facade.loading;\n filter = this.facade.filter;\n}\n","import { Directive, effect, inject, signal } from '@angular/core';\nimport { toSignal } from '@angular/core/rxjs-interop';\nimport { ActivatedRoute } from '@angular/router';\nimport { CrudItemPageBaseComponent } from '@smartsoft001/crud-shell-angular';\n\nimport { SeoService, TranslationService } from '@smartsoft001-mobilems/angular';\nimport { MsObject } from '@smartsoft001-mobilems/objects-domain';\n\nimport { ObjectsFacade } from '../../+state';\n\n@Directive()\nexport abstract class ObjectsItemComponent extends CrudItemPageBaseComponent<MsObject> {\n protected readonly route = inject(ActivatedRoute);\n protected readonly seoService = inject(SeoService);\n protected readonly translationService = inject(TranslationService);\n protected readonly params = toSignal(this.route.params);\n\n override facade = inject(ObjectsFacade);\n\n readonly loading = this.facade.loading;\n readonly item = this.facade.selected;\n readonly isPdfDownloading = signal(false);\n\n protected constructor() {\n super();\n\n effect(() => {\n const params = this.params();\n\n const id = params['id'];\n if (id) {\n this.facade.select(id);\n }\n });\n }\n\n async onDownload(): Promise<void> {\n this.isPdfDownloading.set(true);\n try {\n await this.facade.downloadPdf({\n id: this.item()?.id.toString() || '',\n title: this.item()?.title as string,\n });\n } catch (error) {\n console.error('PDF download failed:', error);\n } finally {\n this.isPdfDownloading.set(false);\n }\n }\n}\n","import { MsFile } from '@smartsoft001-mobilems/models';\nimport { MsObject } from '@smartsoft001-mobilems/objects-domain';\n\nexport type SortType =\n 'random' | 'date-asc' | 'date-desc' | 'name-asc' | 'name-desc';\n\nexport type IKeyValue = {\n key: string;\n value?: string;\n};\n\nexport enum AdvancedFilterType {\n CREATORS = 'creators',\n AUTHORS = 'authors',\n MATERIALS = 'materials',\n TECHNIQUES = 'techniques',\n CREATE_PLACES = 'createPlaces',\n KEYWORDS = 'keywords',\n}\n\nexport enum FormFeatureType {\n MODEL_3D = 1,\n PHOTO_360 = 2,\n IMAGES = 3,\n AUDIO = 7,\n AUDIO_DESKRYPCJA = 8,\n VIDEO = 9,\n ORTHOGRAPHY = 11,\n OTHER = 13,\n IMAGES_HD = 14,\n VIRTUAL_WALK = 15,\n ANIMATION = 20,\n}\n\nexport interface IMultimediaDictionaryItem {\n id: FormFeatureType;\n translationKey: string;\n}\n\n/**\n * Dictionary of multimedia types with their translation keys.\n * Use with TranslateService to get localized names.\n */\nexport const MULTIMEDIA_DICTIONARY: IMultimediaDictionaryItem[] = [\n {\n id: FormFeatureType.IMAGES,\n translationKey: 'OBJECTS.filters.multimedia.images',\n },\n {\n id: FormFeatureType.IMAGES_HD,\n translationKey: 'OBJECTS.filters.multimedia.galleryHD',\n },\n {\n id: FormFeatureType.MODEL_3D,\n translationKey: 'OBJECTS.filters.multimedia.model3D',\n },\n {\n id: FormFeatureType.AUDIO,\n translationKey: 'OBJECTS.filters.multimedia.audio',\n },\n {\n id: FormFeatureType.AUDIO_DESKRYPCJA,\n translationKey: 'OBJECTS.filters.multimedia.audioDescription',\n },\n {\n id: FormFeatureType.VIDEO,\n translationKey: 'OBJECTS.filters.multimedia.video',\n },\n {\n id: FormFeatureType.ANIMATION,\n translationKey: 'OBJECTS.filters.multimedia.animation',\n },\n {\n id: FormFeatureType.VIRTUAL_WALK,\n translationKey: 'OBJECTS.filters.multimedia.virtualWalk',\n },\n {\n id: FormFeatureType.OTHER,\n translationKey: 'OBJECTS.filters.multimedia.other',\n },\n];\n\nexport type FileType = Omit<MsFile, 'formFeature'> & {\n formFeature: FormFeatureType;\n};\n\ninterface Model3DFile {\n id: number;\n filePath: string;\n extension: string;\n altText: string | null;\n fileName: string;\n}\n\nexport interface IModel3DObject {\n formFeature: FormFeatureType;\n files: Model3DFile[];\n description: string | null;\n iframeSource: string | null;\n iframeHtml: string | null;\n isRemote: boolean;\n originalDimensions: string | null;\n id: number;\n position: number;\n filePath: string;\n extension: string;\n altText: string | null;\n altTextEn: string | null;\n vimeoUrl: string | null;\n}\n\nexport interface IAnimationObject {\n formFeature: FormFeatureType;\n files: MsFile[];\n description: string | null;\n iframeSource: string | null;\n iframeHtml: string | null;\n isRemote: boolean;\n originalDimensions: string | null;\n id: number;\n position: number;\n filePath: string;\n extension: string;\n altText: string | null;\n altTextEn: string | null;\n vimeoUrl: string | null;\n}\n\n// Leci z API, nie jest udokumentowane\nexport interface ISpecificObject extends MsObject {\n dimensionTextWithDuration?: string;\n specificDimensionDescription?: string;\n publicationDate?: string;\n authors?: Array<{\n id: number;\n name: string;\n role?: string;\n additionalRoles?: string[];\n comment?: string;\n }>;\n createPlaces?: Array<{\n id: number;\n name: string;\n comment?: string;\n }>;\n materials?: Array<{\n id: number;\n name: string;\n comment?: string;\n }>;\n techniques?: Array<{\n id: number;\n name: string;\n comment?: string;\n }>;\n createdAt?: string | Date;\n createDates?: Array<{\n id: number;\n name: string;\n comment?: string;\n }>;\n visited?: number;\n objectCardDownloadCount?: number;\n shareMuseumObjectMultimediaEnabled?: boolean;\n}\n","import { isPlatformBrowser } from '@angular/common';\nimport {\n AfterViewInit,\n computed,\n Directive,\n effect,\n ElementRef,\n inject,\n PLATFORM_ID,\n Signal,\n signal,\n untracked,\n viewChild,\n WritableSignal,\n} from '@angular/core';\nimport { toSignal } from '@angular/core/rxjs-interop';\nimport { ActivatedRoute } from '@angular/router';\nimport { TranslateService } from '@ngx-translate/core';\nimport { ListMode, PaginationMode } from '@smartsoft001/angular';\nimport { ICrudFilter } from '@smartsoft001/crud-shell-angular';\nimport { capitalize } from '@smartsoft001/utils';\n\nimport {\n createCatalog,\n createCatalogLoadMore,\n createSafeTimeouts,\n ICatalog,\n ICatalogLoadMore,\n ICatalogOptions,\n MasonryGridComponent,\n MuseumSeoService,\n WcagChangesService,\n} from '@smartsoft001-mobilems/angular';\nimport { MsObject } from '@smartsoft001-mobilems/objects-domain';\n\nimport { ObjectsListComponent } from '../pages/list/list.component';\n\n/**\n * Filter defaults of the objects list (Muzeum Podlasia): 20 objects per page,\n * newest first. **The key order is part of the contract** — the first read\n * spreads this object first, so it shapes the facade filter, the persisted\n * `MUSEUM_OBJECTS_FILTER` value and the `#base64` hash.\n */\nexport const OBJECTS_CATALOG_DEFAULTS: ICrudFilter = {\n paginationMode: PaginationMode.singlePage,\n sortBy: 'publication-date',\n sortDesc: true,\n offset: 0,\n limit: 20,\n};\n\n/** List SEO: `<title> - <site>`, a raw description and the canonical url. */\nexport interface IObjectsCatalogSeo {\n /** Translation key of the page title, e.g. `PAGE_TITLES.objects`. */\n titleKey: string;\n /** Translation key of the description — not capitalised. */\n descriptionKey: string;\n /** Translation key of the site name. Default `MODEL.mainTitle`. */\n siteNameKey?: string;\n /** Canonical url of the list, e.g. `/obiekty`. */\n url: string;\n}\n\nexport const OBJECTS_CATALOG_SEO: IObjectsCatalogSeo = {\n titleKey: 'PAGE_TITLES.objects',\n descriptionKey: 'HOME.collectionsDescription',\n siteNameKey: 'MODEL.mainTitle',\n url: '/obiekty',\n};\n\n/** Focus target and live-region message of „więcej ↓” (load more). */\nexport interface IObjectsCatalogLoadMore {\n /** Cards inside `#listContainer`; the first appended one gets the focus. */\n itemSelector?: string;\n /** Translation key announced after a page is appended (`{ count }`). */\n loadedMoreKey?: string;\n}\n\nconst OBJECTS_CATALOG_ITEM_SELECTOR =\n '[data-testid=\"objects-grid-item-link\"], [data-testid=\"objects-list-item\"]';\nconst OBJECTS_CATALOG_LOADED_MORE_KEY = 'OBJECTS.loadedMore';\n\nexport interface IObjectsCatalogOptions extends Partial<\n Omit<ICatalogOptions, 'facade'>\n> {\n /** Applied on creation, skipped in a search tab; `null` — no SEO. */\n seo?: IObjectsCatalogSeo | null;\n loadMore?: IObjectsCatalogLoadMore;\n}\n\n/**\n * Base of an objects list page on the shared catalog engine\n * (`createCatalog`): first read (also in SSR when the route carries the\n * filter), persistence, page, search, the read guard, the mobile list mode,\n * „więcej ↓”, the masonry lifecycle and the list SEO. The page keeps its\n * template.\n *\n * ```ts\n * export class ListComponent extends ObjectsCatalogBaseComponent {\n * constructor() {\n * super();\n * }\n * }\n * ```\n *\n * The template holds a `#listContainer` element (scrolled to after a page\n * change from the bottom pagination; it holds the cards focused by load\n * more) and a `smart-mobilems-masonry-grid` in the grid mode.\n */\n@Directive()\nexport abstract class ObjectsCatalogBaseComponent\n extends ObjectsListComponent\n implements AfterViewInit\n{\n readonly ListMode = ListMode;\n protected readonly catalog: ICatalog;\n\n readonly isBrowser: Signal<boolean>;\n /** The route set the filter, so the list is read and rendered in SSR too. */\n readonly routeList: Signal<boolean>;\n readonly listMode: Signal<ListMode>;\n readonly searchEnabled: Signal<boolean | undefined>;\n readonly barPhrase: Signal<string>;\n readonly isLoading: Signal<boolean>;\n readonly hasError: Signal<unknown>;\n readonly totalCount: Signal<number>;\n /** `publication-date-desc` style key for the toolbar. */\n readonly sortKey: Signal<string | undefined>;\n readonly selectedPage: Signal<number>;\n /** `?type=new` — the page offers the newest-first sort options. */\n readonly isNewType: Signal<boolean>;\n\n /** Cards on the list — with „więcej ↓” previous pages + the current one. */\n readonly items: Signal<MsObject[]>;\n /** There are results after the current page. */\n readonly hasMore: Signal<boolean>;\n /** The next page is loading — the list stays, only the button shows it. */\n readonly isAppending: Signal<boolean>;\n /** Screen reader message after cards were appended. */\n readonly loadMoreStatus: WritableSignal<string> = signal('');\n\n private readonly objectsCatalogTranslate = inject(TranslateService);\n private readonly objectsCatalogSeoService = inject(MuseumSeoService);\n private readonly objectsCatalogWcag = inject(WcagChangesService);\n private readonly objectsCatalogBrowser = isPlatformBrowser(\n inject(PLATFORM_ID),\n );\n private readonly objectsCatalogTimeouts = createSafeTimeouts();\n private readonly objectsCatalogMasonry = viewChild(MasonryGridComponent);\n private readonly objectsCatalogListContainer =\n viewChild<ElementRef<HTMLElement>>('listContainer');\n private readonly objectsCatalogLoadMore: ICatalogLoadMore<MsObject>;\n private objectsCatalogViewReady = false;\n private objectsCatalogScrollAfterLoad = false;\n private readonly objectsCatalogQueryParams = toSignal(\n inject(ActivatedRoute).queryParams,\n );\n\n protected constructor(options: IObjectsCatalogOptions = {}) {\n super();\n const {\n seo = OBJECTS_CATALOG_SEO,\n loadMore = {},\n ...catalogOptions\n } = options;\n const defaults = catalogOptions.defaults ?? OBJECTS_CATALOG_DEFAULTS;\n\n this.catalog = createCatalog({\n persistKey: 'MUSEUM_OBJECTS_FILTER',\n listPath: '/obiekty',\n searchTab: 'obiekty',\n listModeKey: 'MUSEUM_OBJECTS_LIST_MODE',\n ssrRead: 'route',\n // Mobile mockup (2300:51189) has the grid only — the view toggle is\n // hidden below md, so a stored list view does not apply there.\n mobileListModeBelow: 768,\n ...catalogOptions,\n defaults,\n facade: this.facade,\n });\n\n this.isBrowser = this.catalog.isBrowser;\n this.routeList = this.catalog.routeList;\n this.listMode = this.catalog.listMode;\n this.searchEnabled = this.catalog.searchEnabled;\n this.barPhrase = this.catalog.barPhrase;\n this.isLoading = this.catalog.isLoading;\n this.hasError = this.catalog.hasError;\n this.totalCount = this.catalog.totalCount;\n this.sortKey = this.catalog.sortKey;\n this.selectedPage = this.catalog.selectedPage;\n this.isNewType = computed(\n () => this.objectsCatalogQueryParams()?.['type'] === 'new',\n );\n\n // „więcej ↓” (mobile mockup 2300:51213); the focus moves to the first\n // appended card, without scrolling — the new cards sit right below.\n this.objectsCatalogLoadMore = createCatalogLoadMore<MsObject>({\n list: this.list,\n filter: this.facade.filter,\n totalCount: this.totalCount,\n loading: this.isLoading,\n read: (filter) => this.facade.read(filter),\n defaultLimit: defaults.limit || 20,\n onAppended: (added, firstIndex) => {\n this.loadMoreStatus.set(\n this.objectsCatalogTranslate.instant(\n loadMore.loadedMoreKey ?? OBJECTS_CATALOG_LOADED_MORE_KEY,\n { count: added },\n ),\n );\n if (!added || !this.objectsCatalogBrowser) return;\n this.objectsCatalogTimeouts.later(\n () =>\n this.listContainerElement\n ?.querySelectorAll<HTMLElement>(\n loadMore.itemSelector ?? OBJECTS_CATALOG_ITEM_SELECTOR,\n )\n [firstIndex]?.focus({ preventScroll: true }),\n 0,\n );\n },\n });\n this.items = this.objectsCatalogLoadMore.items;\n this.hasMore = this.objectsCatalogLoadMore.hasMore;\n this.isAppending = this.objectsCatalogLoadMore.isAppending;\n\n // Every loaded card (appended pages included) goes to the page, e.g. for\n // „select all” (MOB-1661). Untracked: the hook's own reads do not re-run it.\n effect(() => {\n const items = this.items();\n untracked(() => this.onCatalogItems(items));\n });\n\n // After a page change from the bottom pagination scroll to the list top\n // once the data has loaded.\n effect(() => {\n const loading = this.isLoading();\n if (\n !loading &&\n this.objectsCatalogScrollAfterLoad &&\n this.objectsCatalogBrowser\n ) {\n this.objectsCatalogScrollAfterLoad = false;\n this.objectsCatalogTimeouts.later(\n () =>\n this.listContainerElement?.scrollIntoView({\n behavior: 'smooth',\n block: 'start',\n }),\n 0,\n );\n }\n });\n\n // Re-layout masonry on WCAG/contrast changes.\n effect(() => {\n this.objectsCatalogWcag.wcagSettingsChanged();\n\n if (!this.objectsCatalogViewReady) {\n return;\n }\n\n this.objectsCatalogDestroyMasonry();\n this.objectsCatalogInitMasonry();\n });\n\n // Re-layout masonry when the list changes.\n effect(() => {\n const items = this.items();\n const mode = this.listMode();\n\n if (items && mode === ListMode.masonryGrid) {\n this.objectsCatalogDestroyMasonry();\n this.objectsCatalogTimeouts.later(\n () => this.objectsCatalogInitMasonry(),\n 150,\n );\n }\n });\n\n // Initialise masonry once the grid component is present.\n effect(() => {\n const masonry = this.objectsCatalogMasonry();\n const mode = this.listMode();\n const items = this.items();\n\n if (masonry && mode === ListMode.masonryGrid && items?.length) {\n this.objectsCatalogTimeouts.later(\n () => this.objectsCatalogInitMasonry(),\n 250,\n );\n }\n });\n\n if (seo) this.applyListSeo(seo);\n }\n\n /** The list root element (`#listContainer`). */\n protected get listContainerElement(): HTMLElement | undefined {\n return this.objectsCatalogListContainer()?.nativeElement;\n }\n\n /**\n * „więcej ↓” — reads the next page and appends it under the current cards\n * (no scrolling, no loader in place of the list).\n */\n loadMore(): void {\n if (this.isLoading() || !this.hasMore()) {\n return;\n }\n // Cleared first, so the live region changes — and is announced — even\n // when the next page brings the same number of cards.\n this.loadMoreStatus.set('');\n this.objectsCatalogLoadMore.loadMore();\n }\n\n retryLoad(): void {\n this.catalog.retry();\n }\n\n pageChange(page: number): void {\n this.catalog.setPage(page);\n }\n\n /** Page change from the bottom pagination — scrolls to the list once loaded. */\n bottomPageChange(page: number): void {\n this.objectsCatalogScrollAfterLoad = true;\n this.pageChange(page);\n }\n\n /**\n * In the catalog it reads with the phrase from the first page. In a search\n * tab the address is the only source of the phrase (MOB-1818): a new one\n * opens `/wyszukaj/:text/obiekty`, a blank one `/obiekty` with the other\n * filters.\n */\n search(phrase: string): void {\n this.catalog.search(phrase);\n }\n\n /**\n * A filter change in a search tab (MOB-1818) opens `/obiekty` with the whole\n * filter, the phrase (`filter[phrase]`), the sort and the page size instead\n * of narrowing the results in place.\n */\n openInCatalog(filter: ICrudFilter): void {\n this.catalog.openInList(filter);\n }\n\n onListMode(value: ListMode): void {\n const newMode =\n value === ListMode.masonryGrid ? ListMode.masonryGrid : ListMode.desktop;\n\n this.catalog.setListMode(newMode);\n // Below the mobile breakpoint the mode is forced and the toggle ignored.\n if (this.listMode() !== newMode) return;\n\n if (newMode !== ListMode.masonryGrid) {\n this.objectsCatalogDestroyMasonry();\n } else {\n this.objectsCatalogTimeouts.later(\n () => this.objectsCatalogInitMasonry(),\n 100,\n );\n }\n }\n\n ngAfterViewInit(): void {\n this.objectsCatalogInitMasonry();\n this.objectsCatalogViewReady = true;\n }\n\n override ngOnDestroy(): void {\n super.ngOnDestroy();\n this.objectsCatalogDestroyMasonry();\n }\n\n /**\n * Called with every loaded card (appended „więcej ↓” pages included) each\n * time they change, untracked. No-op; e.g. Podlasie feeds its\n * `SelectionStore` here.\n */\n protected onCatalogItems(items: MsObject[]): void {\n void items;\n }\n\n /**\n * Full list meta (title, description, canonical, og), not in a search tab —\n * there the search page sets them, and the canonical of the list must not\n * point at a phrase url (MOB-1064). The description goes out as translated.\n */\n protected applyListSeo(seo: IObjectsCatalogSeo): void {\n if (this.catalog.searchEnabled()) return;\n\n const t = (key: string): string =>\n this.objectsCatalogTranslate.instant(key);\n this.objectsCatalogSeoService.apply({\n title: `${capitalize(t(seo.titleKey))} - ${capitalize(t(seo.siteNameKey ?? 'MODEL.mainTitle'))}`,\n description: t(seo.descriptionKey),\n type: 'website',\n url: seo.url,\n });\n }\n\n private objectsCatalogInitMasonry(): void {\n if (\n this.listMode() !== ListMode.masonryGrid ||\n !this.objectsCatalogBrowser\n ) {\n return;\n }\n // The MasonryGridComponent owns the masonry library and the image-load\n // handling; it packs the projected `.masonry-item` cards.\n this.objectsCatalogMasonry()?.initMasonry();\n }\n\n private objectsCatalogDestroyMasonry(): void {\n this.objectsCatalogMasonry()?.destroyMasonry();\n }\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":["smartInitialState","smartGetReducer"],"mappings":";;;;;;;;;;;;AAMM,MAAO,cAAe,SAAQ,eAAyB,CAAA;IAC3D,oBAAoB,GAAA;AAClB,QAAA,OAAO,QAAQ;IACjB;IAEA,iBAAiB,GAAA;AACf,QAAA,OAAO,QAAQ;IACjB;iIAPW,cAAc,EAAA,IAAA,EAAA,IAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,UAAA,EAAA,CAAA,CAAA;qIAAd,cAAc,EAAA,CAAA,CAAA;;2FAAd,cAAc,EAAA,UAAA,EAAA,CAAA;kBAD1B;;;ACGK,MAAO,aAAc,SAAQ,UAAoB,CAAA;AADvD,IAAA,WAAA,GAAA;;AAEY,QAAA,IAAA,CAAA,OAAO,GAAG,MAAM,CAAC,cAAc,CAAC;AAK3C,IAAA;IAHC,MAAM,WAAW,CAAC,IAAmC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AAA,EAAA,CAAA,eAAA,CAAA,EAAA,WAAA,EAAA,IAAA,EAAA,QAAA,EAAA,IAAA,EAAA,CAAA,EAAA,eAAA,EAAA,IAAA,EAAA,QAAA,EAAA,EAAA,EAAA,CAAA,CAAA;;2FAtCnD,2BAA2B,EAAA,UAAA,EAAA,CAAA;kBADhD;AAuCoD,SAAA,CAAA,EAAA,cAAA,EAAA,MAAA,CAAA,EAAA,IAAA,EAAA,SAAA,EAAA,CAAA,EAAA,cAAA,EAAA,EAAA,qBAAA,EAAA,CAAA,EAAA,IAAA,EAAA,EAAA,CAAA,SAAA,EAAA,IAAA,EAAA,CAAA,EAAA,CAAA,UAAA,CAAA,MAAA,oBAAoB,sFAElC,eAAe,EAAA,EAAA,QAAA,EAAA,IAAA,EAAA,CAAA,EAAA,CAAA,EAAA,EAAA,CAAA;;ACtJtD;;AAEG;;;;"}
|
package/package.json
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import * as i0 from '@angular/core';
|
|
2
|
-
import { TemplateRef, ModuleWithProviders, Signal } from '@angular/core';
|
|
2
|
+
import { TemplateRef, ModuleWithProviders, Signal, AfterViewInit, WritableSignal } from '@angular/core';
|
|
3
3
|
import * as _smartsoft001_crud_shell_angular from '@smartsoft001/crud-shell-angular';
|
|
4
|
-
import { ICrudModuleOptionsWithoutRoutng, CrudFacade, State as State$1, CrudListPageBaseComponent, CrudItemPageBaseComponent, CrudService } from '@smartsoft001/crud-shell-angular';
|
|
4
|
+
import { ICrudModuleOptionsWithoutRoutng, CrudFacade, State as State$1, CrudListPageBaseComponent, CrudItemPageBaseComponent, CrudService, ICrudFilter } from '@smartsoft001/crud-shell-angular';
|
|
5
5
|
import { IEntity } from '@smartsoft001/domain-core';
|
|
6
6
|
import * as i1$1 from '@smartsoft001-mobilems/angular';
|
|
7
|
-
import { FiltersBaseComponent, CrudBaseService, SeoService, TranslationService } from '@smartsoft001-mobilems/angular';
|
|
7
|
+
import { FiltersBaseComponent, CrudBaseService, SeoService, TranslationService, ICatalogOptions, ICatalog } from '@smartsoft001-mobilems/angular';
|
|
8
8
|
import * as i1 from '@angular/common';
|
|
9
9
|
import { MsObject } from '@smartsoft001-mobilems/objects-domain';
|
|
10
10
|
import * as dist_packages_objects_domain_src from 'dist/packages/objects/domain/src';
|
|
@@ -13,6 +13,7 @@ import { ActivatedRoute } from '@angular/router';
|
|
|
13
13
|
import * as _ngrx_store from '@ngrx/store';
|
|
14
14
|
import { Action } from '@ngrx/store';
|
|
15
15
|
import { MsFile } from '@smartsoft001-mobilems/models';
|
|
16
|
+
import { ListMode } from '@smartsoft001/angular';
|
|
16
17
|
|
|
17
18
|
declare class FiltersComponent extends FiltersBaseComponent<MsObject> {
|
|
18
19
|
static ɵfac: i0.ɵɵFactoryDeclaration<FiltersComponent, never>;
|
|
@@ -251,5 +252,137 @@ interface ISpecificObject extends MsObject {
|
|
|
251
252
|
shareMuseumObjectMultimediaEnabled?: boolean;
|
|
252
253
|
}
|
|
253
254
|
|
|
254
|
-
|
|
255
|
-
|
|
255
|
+
/**
|
|
256
|
+
* Filter defaults of the objects list (Muzeum Podlasia): 20 objects per page,
|
|
257
|
+
* newest first. **The key order is part of the contract** — the first read
|
|
258
|
+
* spreads this object first, so it shapes the facade filter, the persisted
|
|
259
|
+
* `MUSEUM_OBJECTS_FILTER` value and the `#base64` hash.
|
|
260
|
+
*/
|
|
261
|
+
declare const OBJECTS_CATALOG_DEFAULTS: ICrudFilter;
|
|
262
|
+
/** List SEO: `<title> - <site>`, a raw description and the canonical url. */
|
|
263
|
+
interface IObjectsCatalogSeo {
|
|
264
|
+
/** Translation key of the page title, e.g. `PAGE_TITLES.objects`. */
|
|
265
|
+
titleKey: string;
|
|
266
|
+
/** Translation key of the description — not capitalised. */
|
|
267
|
+
descriptionKey: string;
|
|
268
|
+
/** Translation key of the site name. Default `MODEL.mainTitle`. */
|
|
269
|
+
siteNameKey?: string;
|
|
270
|
+
/** Canonical url of the list, e.g. `/obiekty`. */
|
|
271
|
+
url: string;
|
|
272
|
+
}
|
|
273
|
+
declare const OBJECTS_CATALOG_SEO: IObjectsCatalogSeo;
|
|
274
|
+
/** Focus target and live-region message of „więcej ↓” (load more). */
|
|
275
|
+
interface IObjectsCatalogLoadMore {
|
|
276
|
+
/** Cards inside `#listContainer`; the first appended one gets the focus. */
|
|
277
|
+
itemSelector?: string;
|
|
278
|
+
/** Translation key announced after a page is appended (`{ count }`). */
|
|
279
|
+
loadedMoreKey?: string;
|
|
280
|
+
}
|
|
281
|
+
interface IObjectsCatalogOptions extends Partial<Omit<ICatalogOptions, 'facade'>> {
|
|
282
|
+
/** Applied on creation, skipped in a search tab; `null` — no SEO. */
|
|
283
|
+
seo?: IObjectsCatalogSeo | null;
|
|
284
|
+
loadMore?: IObjectsCatalogLoadMore;
|
|
285
|
+
}
|
|
286
|
+
/**
|
|
287
|
+
* Base of an objects list page on the shared catalog engine
|
|
288
|
+
* (`createCatalog`): first read (also in SSR when the route carries the
|
|
289
|
+
* filter), persistence, page, search, the read guard, the mobile list mode,
|
|
290
|
+
* „więcej ↓”, the masonry lifecycle and the list SEO. The page keeps its
|
|
291
|
+
* template.
|
|
292
|
+
*
|
|
293
|
+
* ```ts
|
|
294
|
+
* export class ListComponent extends ObjectsCatalogBaseComponent {
|
|
295
|
+
* constructor() {
|
|
296
|
+
* super();
|
|
297
|
+
* }
|
|
298
|
+
* }
|
|
299
|
+
* ```
|
|
300
|
+
*
|
|
301
|
+
* The template holds a `#listContainer` element (scrolled to after a page
|
|
302
|
+
* change from the bottom pagination; it holds the cards focused by load
|
|
303
|
+
* more) and a `smart-mobilems-masonry-grid` in the grid mode.
|
|
304
|
+
*/
|
|
305
|
+
declare abstract class ObjectsCatalogBaseComponent extends ObjectsListComponent implements AfterViewInit {
|
|
306
|
+
readonly ListMode: typeof ListMode;
|
|
307
|
+
protected readonly catalog: ICatalog;
|
|
308
|
+
readonly isBrowser: Signal<boolean>;
|
|
309
|
+
/** The route set the filter, so the list is read and rendered in SSR too. */
|
|
310
|
+
readonly routeList: Signal<boolean>;
|
|
311
|
+
readonly listMode: Signal<ListMode>;
|
|
312
|
+
readonly searchEnabled: Signal<boolean | undefined>;
|
|
313
|
+
readonly barPhrase: Signal<string>;
|
|
314
|
+
readonly isLoading: Signal<boolean>;
|
|
315
|
+
readonly hasError: Signal<unknown>;
|
|
316
|
+
readonly totalCount: Signal<number>;
|
|
317
|
+
/** `publication-date-desc` style key for the toolbar. */
|
|
318
|
+
readonly sortKey: Signal<string | undefined>;
|
|
319
|
+
readonly selectedPage: Signal<number>;
|
|
320
|
+
/** `?type=new` — the page offers the newest-first sort options. */
|
|
321
|
+
readonly isNewType: Signal<boolean>;
|
|
322
|
+
/** Cards on the list — with „więcej ↓” previous pages + the current one. */
|
|
323
|
+
readonly items: Signal<MsObject[]>;
|
|
324
|
+
/** There are results after the current page. */
|
|
325
|
+
readonly hasMore: Signal<boolean>;
|
|
326
|
+
/** The next page is loading — the list stays, only the button shows it. */
|
|
327
|
+
readonly isAppending: Signal<boolean>;
|
|
328
|
+
/** Screen reader message after cards were appended. */
|
|
329
|
+
readonly loadMoreStatus: WritableSignal<string>;
|
|
330
|
+
private readonly objectsCatalogTranslate;
|
|
331
|
+
private readonly objectsCatalogSeoService;
|
|
332
|
+
private readonly objectsCatalogWcag;
|
|
333
|
+
private readonly objectsCatalogBrowser;
|
|
334
|
+
private readonly objectsCatalogTimeouts;
|
|
335
|
+
private readonly objectsCatalogMasonry;
|
|
336
|
+
private readonly objectsCatalogListContainer;
|
|
337
|
+
private readonly objectsCatalogLoadMore;
|
|
338
|
+
private objectsCatalogViewReady;
|
|
339
|
+
private objectsCatalogScrollAfterLoad;
|
|
340
|
+
private readonly objectsCatalogQueryParams;
|
|
341
|
+
protected constructor(options?: IObjectsCatalogOptions);
|
|
342
|
+
/** The list root element (`#listContainer`). */
|
|
343
|
+
protected get listContainerElement(): HTMLElement | undefined;
|
|
344
|
+
/**
|
|
345
|
+
* „więcej ↓” — reads the next page and appends it under the current cards
|
|
346
|
+
* (no scrolling, no loader in place of the list).
|
|
347
|
+
*/
|
|
348
|
+
loadMore(): void;
|
|
349
|
+
retryLoad(): void;
|
|
350
|
+
pageChange(page: number): void;
|
|
351
|
+
/** Page change from the bottom pagination — scrolls to the list once loaded. */
|
|
352
|
+
bottomPageChange(page: number): void;
|
|
353
|
+
/**
|
|
354
|
+
* In the catalog it reads with the phrase from the first page. In a search
|
|
355
|
+
* tab the address is the only source of the phrase (MOB-1818): a new one
|
|
356
|
+
* opens `/wyszukaj/:text/obiekty`, a blank one `/obiekty` with the other
|
|
357
|
+
* filters.
|
|
358
|
+
*/
|
|
359
|
+
search(phrase: string): void;
|
|
360
|
+
/**
|
|
361
|
+
* A filter change in a search tab (MOB-1818) opens `/obiekty` with the whole
|
|
362
|
+
* filter, the phrase (`filter[phrase]`), the sort and the page size instead
|
|
363
|
+
* of narrowing the results in place.
|
|
364
|
+
*/
|
|
365
|
+
openInCatalog(filter: ICrudFilter): void;
|
|
366
|
+
onListMode(value: ListMode): void;
|
|
367
|
+
ngAfterViewInit(): void;
|
|
368
|
+
ngOnDestroy(): void;
|
|
369
|
+
/**
|
|
370
|
+
* Called with every loaded card (appended „więcej ↓” pages included) each
|
|
371
|
+
* time they change, untracked. No-op; e.g. Podlasie feeds its
|
|
372
|
+
* `SelectionStore` here.
|
|
373
|
+
*/
|
|
374
|
+
protected onCatalogItems(items: MsObject[]): void;
|
|
375
|
+
/**
|
|
376
|
+
* Full list meta (title, description, canonical, og), not in a search tab —
|
|
377
|
+
* there the search page sets them, and the canonical of the list must not
|
|
378
|
+
* point at a phrase url (MOB-1064). The description goes out as translated.
|
|
379
|
+
*/
|
|
380
|
+
protected applyListSeo(seo: IObjectsCatalogSeo): void;
|
|
381
|
+
private objectsCatalogInitMasonry;
|
|
382
|
+
private objectsCatalogDestroyMasonry;
|
|
383
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<ObjectsCatalogBaseComponent, never>;
|
|
384
|
+
static ɵdir: i0.ɵɵDirectiveDeclaration<ObjectsCatalogBaseComponent, never, never, {}, {}, never, never, true, never>;
|
|
385
|
+
}
|
|
386
|
+
|
|
387
|
+
export { AdvancedFilterType, ComponentsModule, FiltersComponent, FormFeatureType, ListComponent, MULTIMEDIA_DICTIONARY, OBJECTS_CATALOG_DEFAULTS, OBJECTS_CATALOG_SEO, ObjectsCatalogBaseComponent, ObjectsFacade, ObjectsItemComponent, ObjectsListComponent, ObjectsModule, ObjectsService, ObjectsSharedModule, SERVICES, getObjectsState, getReducer, initialState };
|
|
388
|
+
export type { FileType, IAnimationObject, IKeyValue, IModel3DObject, IMultimediaDictionaryItem, IObjectsCatalogLoadMore, IObjectsCatalogOptions, IObjectsCatalogSeo, ISpecificObject, SortType, State };
|