@myrmidon/cadmus-part-general-pg 18.0.0 → 20.0.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,1542 +1,2987 @@
1
- import * as i0 from '@angular/core';
2
- import { ChangeDetectionStrategy, Component, signal } from '@angular/core';
3
- import { AssertedHistoricalDatesPartComponent, BibliographyPartComponent, CategoriesPartComponent, ChronologyFragmentComponent, ChronotopesPartComponent, CommentEditorComponent, DecoratedCountsPartComponent, DistrictLocationPartComponent, DocReferencesPartComponent, ExternalIdsPartComponent, FlagsPartComponent, HistoricalDatePartComponent, HistoricalEventsPartComponent, IndexKeywordsPartComponent, KeywordsPartComponent, MetadataPartComponent, NamesPartComponent, NotePartComponent, PhysicalMeasurementsPartComponent, PhysicalStatesPartComponent, PinLinksFragmentComponent, PinLinksPartComponent, TextTileComponent, TiledTextPartComponent, TokenTextPartComponent, ASSERTED_HISTORICAL_DATES_PART_TYPEID, BIBLIOGRAPHY_PART_TYPEID, CATEGORIES_PART_TYPEID, COMMENT_PART_TYPEID, CHRONOTOPES_PART_TYPEID, DECORATED_COUNTS_PART_TYPEID, DISTRICT_LOCATION_PART_TYPEID, DOC_REFERENCES_PART_TYPEID, EXTERNAL_IDS_PART_TYPEID, FLAGS_PART_TYPEID, HISTORICAL_DATE_PART_TYPEID, HISTORICAL_EVENTS_PART_TYPEID, KEYWORDS_PART_TYPEID, INDEX_KEYWORDS_PART_TYPEID, METADATA_PART_TYPEID, NAMES_PART_TYPEID, NOTE_PART_TYPEID, PHYSICAL_MEASUREMENTS_PART_TYPEID, PHYSICAL_STATES_PART_TYPEID, PIN_LINKS_PART_TYPEID, TOKEN_TEXT_PART_TYPEID, TILED_TEXT_PART_TYPEID, COMMENT_FRAGMENT_TYPEID, CHRONOLOGY_FRAGMENT_TYPEID, PIN_LINKS_FRAGMENT_TYPEID } from '@myrmidon/cadmus-part-general-ui';
4
- import * as i4 from '@myrmidon/cadmus-state';
5
- import { EditPartFeatureBase, EditFragmentFeatureBase } from '@myrmidon/cadmus-state';
6
- import * as i4$2 from '@myrmidon/cadmus-item-editor';
7
- import { CurrentItemBarComponent, CurrentLayerPartBarComponent } from '@myrmidon/cadmus-item-editor';
8
- import * as i1 from '@angular/router';
9
- import * as i2 from '@angular/material/snack-bar';
10
- import * as i3 from '@myrmidon/cadmus-api';
11
- import { DecoratedTokenTextComponent, LayerHintsComponent } from '@myrmidon/cadmus-ui';
12
- import * as i4$1 from '@myrmidon/cadmus-core';
13
- import { TokenLocation, TokenPoint, pendingChangesGuard } from '@myrmidon/cadmus-core';
14
- import { AsyncPipe } from '@angular/common';
15
- import { map } from 'rxjs';
16
- import { MatCard, MatCardHeader, MatCardAvatar, MatCardTitle, MatCardActions, MatCardContent } from '@angular/material/card';
17
- import { MatIcon } from '@angular/material/icon';
18
- import { MatIconButton, MatButton } from '@angular/material/button';
19
- import { MatTooltip } from '@angular/material/tooltip';
20
- import { MatToolbar } from '@angular/material/toolbar';
21
- import { MatProgressBar } from '@angular/material/progress-bar';
22
- import { MatExpansionPanel, MatExpansionPanelHeader, MatExpansionPanelTitle, MatExpansionPanelDescription } from '@angular/material/expansion';
23
- import * as i5 from '@myrmidon/ngx-mat-tools';
24
-
25
- class AssertedHistoricalDateFeatureComponent extends EditPartFeatureBase {
26
- constructor(router, route, snackbar, itemService, thesaurusService, editorService) {
27
- super(router, route, snackbar, itemService, thesaurusService, editorService);
28
- this.roleIdInThesauri = true;
29
- }
30
- getReqThesauriIds() {
31
- return [
32
- 'asserted-historical-dates-tags',
33
- 'assertion-tags',
34
- 'doc-reference-types',
35
- 'doc-reference-tags',
36
- ];
37
- }
38
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.1", ngImport: i0, type: AssertedHistoricalDateFeatureComponent, deps: [{ token: i1.Router }, { token: i1.ActivatedRoute }, { token: i2.MatSnackBar }, { token: i3.ItemService }, { token: i3.ThesaurusService }, { token: i4.PartEditorService }], target: i0.ɵɵFactoryTarget.Component });
39
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "22.0.1", type: AssertedHistoricalDateFeatureComponent, isStandalone: true, selector: "cadmus-asserted-historical-date-feature", usesInheritance: true, ngImport: i0, template: "<cadmus-current-item-bar />\r\n<cadmus-asserted-historical-dates-part\r\n [identity]=\"identity()\"\r\n [data]=\"$any(data())\"\r\n (dataChange)=\"save($event!.value!)\"\r\n (editorClose)=\"close()\"\r\n (dirtyChange)=\"onDirtyChange($event)\"\r\n/>\r\n", styles: [""], dependencies: [{ kind: "component", type: CurrentItemBarComponent, selector: "cadmus-current-item-bar" }, { kind: "component", type: AssertedHistoricalDatesPartComponent, selector: "cadmus-asserted-historical-dates-part" }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
40
- }
41
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.1", ngImport: i0, type: AssertedHistoricalDateFeatureComponent, decorators: [{
42
- type: Component,
43
- args: [{ selector: 'cadmus-asserted-historical-date-feature', imports: [CurrentItemBarComponent, AssertedHistoricalDatesPartComponent], changeDetection: ChangeDetectionStrategy.OnPush, template: "<cadmus-current-item-bar />\r\n<cadmus-asserted-historical-dates-part\r\n [identity]=\"identity()\"\r\n [data]=\"$any(data())\"\r\n (dataChange)=\"save($event!.value!)\"\r\n (editorClose)=\"close()\"\r\n (dirtyChange)=\"onDirtyChange($event)\"\r\n/>\r\n" }]
44
- }], ctorParameters: () => [{ type: i1.Router }, { type: i1.ActivatedRoute }, { type: i2.MatSnackBar }, { type: i3.ItemService }, { type: i3.ThesaurusService }, { type: i4.PartEditorService }] });
45
-
46
- class BibliographyPartFeatureComponent extends EditPartFeatureBase {
47
- constructor(router, route, snackbar, itemService, thesaurusService, editorService) {
48
- super(router, route, snackbar, itemService, thesaurusService, editorService);
49
- }
50
- getReqThesauriIds() {
51
- return [
52
- 'bibliography-languages',
53
- 'bibliography-types',
54
- 'bibliography-tags',
55
- 'bibliography-author-roles',
56
- ];
57
- }
58
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.1", ngImport: i0, type: BibliographyPartFeatureComponent, deps: [{ token: i1.Router }, { token: i1.ActivatedRoute }, { token: i2.MatSnackBar }, { token: i3.ItemService }, { token: i3.ThesaurusService }, { token: i4.PartEditorService }], target: i0.ɵɵFactoryTarget.Component });
59
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "22.0.1", type: BibliographyPartFeatureComponent, isStandalone: true, selector: "cadmus-bibliography-part-feature", usesInheritance: true, ngImport: i0, template: "<cadmus-current-item-bar/>\r\n<cadmus-bibliography-part\r\n [identity]=\"identity()\"\r\n [data]=\"$any(data())\"\r\n (dataChange)=\"save($event!.value!)\"\r\n (editorClose)=\"close()\"\r\n (dirtyChange)=\"onDirtyChange($event)\"\r\n/>\r\n", styles: [""], dependencies: [{ kind: "component", type: CurrentItemBarComponent, selector: "cadmus-current-item-bar" }, { kind: "component", type: BibliographyPartComponent, selector: "cadmus-bibliography-part" }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
60
- }
61
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.1", ngImport: i0, type: BibliographyPartFeatureComponent, decorators: [{
62
- type: Component,
63
- args: [{ selector: 'cadmus-bibliography-part-feature', imports: [CurrentItemBarComponent, BibliographyPartComponent], changeDetection: ChangeDetectionStrategy.OnPush, template: "<cadmus-current-item-bar/>\r\n<cadmus-bibliography-part\r\n [identity]=\"identity()\"\r\n [data]=\"$any(data())\"\r\n (dataChange)=\"save($event!.value!)\"\r\n (editorClose)=\"close()\"\r\n (dirtyChange)=\"onDirtyChange($event)\"\r\n/>\r\n" }]
64
- }], ctorParameters: () => [{ type: i1.Router }, { type: i1.ActivatedRoute }, { type: i2.MatSnackBar }, { type: i3.ItemService }, { type: i3.ThesaurusService }, { type: i4.PartEditorService }] });
65
-
66
- class CategoriesPartFeatureComponent extends EditPartFeatureBase {
67
- constructor(router, route, snackbar, itemService, thesaurusService, editorService) {
68
- super(router, route, snackbar, itemService, thesaurusService, editorService);
69
- this.roleIdInThesauri = true;
70
- }
71
- getReqThesauriIds() {
72
- return ['categories'];
73
- }
74
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.1", ngImport: i0, type: CategoriesPartFeatureComponent, deps: [{ token: i1.Router }, { token: i1.ActivatedRoute }, { token: i2.MatSnackBar }, { token: i3.ItemService }, { token: i3.ThesaurusService }, { token: i4.PartEditorService }], target: i0.ɵɵFactoryTarget.Component });
75
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "22.0.1", type: CategoriesPartFeatureComponent, isStandalone: true, selector: "cadmus-categories-part-feature", usesInheritance: true, ngImport: i0, template: "<cadmus-current-item-bar/>\r\n<cadmus-categories-part\r\n [identity]=\"identity()\"\r\n [data]=\"$any(data())\"\r\n (dataChange)=\"save($event!.value!)\"\r\n (editorClose)=\"close()\"\r\n (dirtyChange)=\"onDirtyChange($event)\"\r\n/>\r\n", styles: [""], dependencies: [{ kind: "component", type: CurrentItemBarComponent, selector: "cadmus-current-item-bar" }, { kind: "component", type: CategoriesPartComponent, selector: "cadmus-categories-part" }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
76
- }
77
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.1", ngImport: i0, type: CategoriesPartFeatureComponent, decorators: [{
78
- type: Component,
79
- args: [{ selector: 'cadmus-categories-part-feature', imports: [CurrentItemBarComponent, CategoriesPartComponent], changeDetection: ChangeDetectionStrategy.OnPush, template: "<cadmus-current-item-bar/>\r\n<cadmus-categories-part\r\n [identity]=\"identity()\"\r\n [data]=\"$any(data())\"\r\n (dataChange)=\"save($event!.value!)\"\r\n (editorClose)=\"close()\"\r\n (dirtyChange)=\"onDirtyChange($event)\"\r\n/>\r\n" }]
80
- }], ctorParameters: () => [{ type: i1.Router }, { type: i1.ActivatedRoute }, { type: i2.MatSnackBar }, { type: i3.ItemService }, { type: i3.ThesaurusService }, { type: i4.PartEditorService }] });
81
-
82
- class ChronologyFragmentFeatureComponent extends EditFragmentFeatureBase {
83
- constructor(router, route, snackbar, editorService, libraryRouteService) {
84
- super(router, route, snackbar, editorService, libraryRouteService);
85
- }
86
- getReqThesauriIds() {
87
- return ['chronology-tags'];
88
- }
89
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.1", ngImport: i0, type: ChronologyFragmentFeatureComponent, deps: [{ token: i1.Router }, { token: i1.ActivatedRoute }, { token: i2.MatSnackBar }, { token: i4.FragmentEditorService }, { token: i4$1.LibraryRouteService }], target: i0.ɵɵFactoryTarget.Component });
90
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "22.0.1", type: ChronologyFragmentFeatureComponent, isStandalone: true, selector: "cadmus-chronology-fragment-feature", usesInheritance: true, ngImport: i0, template: "<cadmus-current-item-bar/>\r\n@let loc = frLoc();\r\n<div class=\"base-text\">\r\n <cadmus-decorated-token-text\r\n [baseText]=\"data()?.baseText || ''\"\r\n [locations]=\"loc ? [loc] : []\"\r\n />\r\n</div>\r\n<cadmus-chronology-fragment\r\n [data]=\"$any(data())\"\r\n (dataChange)=\"save($event!.value!)\"\r\n (editorClose)=\"close()\"\r\n (dirtyChange)=\"onDirtyChange($event)\"\r\n/>\r\n", styles: [""], dependencies: [{ kind: "component", type: CurrentItemBarComponent, selector: "cadmus-current-item-bar" }, { kind: "component", type: DecoratedTokenTextComponent, selector: "cadmus-decorated-token-text", inputs: ["baseText", "locations", "selectedLocation"] }, { kind: "component", type: ChronologyFragmentComponent, selector: "cadmus-chronology-fragment" }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
91
- }
92
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.1", ngImport: i0, type: ChronologyFragmentFeatureComponent, decorators: [{
93
- type: Component,
94
- args: [{ selector: 'cadmus-chronology-fragment-feature', imports: [
95
- CurrentItemBarComponent,
96
- DecoratedTokenTextComponent,
97
- ChronologyFragmentComponent,
98
- ], changeDetection: ChangeDetectionStrategy.OnPush, template: "<cadmus-current-item-bar/>\r\n@let loc = frLoc();\r\n<div class=\"base-text\">\r\n <cadmus-decorated-token-text\r\n [baseText]=\"data()?.baseText || ''\"\r\n [locations]=\"loc ? [loc] : []\"\r\n />\r\n</div>\r\n<cadmus-chronology-fragment\r\n [data]=\"$any(data())\"\r\n (dataChange)=\"save($event!.value!)\"\r\n (editorClose)=\"close()\"\r\n (dirtyChange)=\"onDirtyChange($event)\"\r\n/>\r\n" }]
99
- }], ctorParameters: () => [{ type: i1.Router }, { type: i1.ActivatedRoute }, { type: i2.MatSnackBar }, { type: i4.FragmentEditorService }, { type: i4$1.LibraryRouteService }] });
100
-
101
- class ChronotopesPartFeatureComponent extends EditPartFeatureBase {
102
- constructor(router, route, snackbar, itemService, thesaurusService, editorService) {
103
- super(router, route, snackbar, itemService, thesaurusService, editorService);
104
- this.roleIdInThesauri = true;
105
- }
106
- getReqThesauriIds() {
107
- return [
108
- 'chronotope-place-tags',
109
- 'chronotope-assertion-tags',
110
- 'doc-reference-types',
111
- 'doc-reference-tags',
112
- ];
113
- }
114
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.1", ngImport: i0, type: ChronotopesPartFeatureComponent, deps: [{ token: i1.Router }, { token: i1.ActivatedRoute }, { token: i2.MatSnackBar }, { token: i3.ItemService }, { token: i3.ThesaurusService }, { token: i4.PartEditorService }], target: i0.ɵɵFactoryTarget.Component });
115
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "22.0.1", type: ChronotopesPartFeatureComponent, isStandalone: true, selector: "cadmus-chronotopes-part-feature", usesInheritance: true, ngImport: i0, template: "<cadmus-current-item-bar/>\n<cadmus-chronotopes-part\n [identity]=\"identity()\"\n [data]=\"$any(data())\"\n (dataChange)=\"save($event!.value!)\"\n (editorClose)=\"close()\"\n (dirtyChange)=\"onDirtyChange($event)\"\n/>\n", styles: [""], dependencies: [{ kind: "component", type: CurrentItemBarComponent, selector: "cadmus-current-item-bar" }, { kind: "component", type: ChronotopesPartComponent, selector: "cadmus-chronotopes-part" }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
116
- }
117
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.1", ngImport: i0, type: ChronotopesPartFeatureComponent, decorators: [{
118
- type: Component,
119
- args: [{ selector: 'cadmus-chronotopes-part-feature', changeDetection: ChangeDetectionStrategy.OnPush, imports: [CurrentItemBarComponent, ChronotopesPartComponent], template: "<cadmus-current-item-bar/>\n<cadmus-chronotopes-part\n [identity]=\"identity()\"\n [data]=\"$any(data())\"\n (dataChange)=\"save($event!.value!)\"\n (editorClose)=\"close()\"\n (dirtyChange)=\"onDirtyChange($event)\"\n/>\n" }]
120
- }], ctorParameters: () => [{ type: i1.Router }, { type: i1.ActivatedRoute }, { type: i2.MatSnackBar }, { type: i3.ItemService }, { type: i3.ThesaurusService }, { type: i4.PartEditorService }] });
121
-
122
- class CommentFragmentFeatureComponent extends EditFragmentFeatureBase {
123
- constructor(router, route, snackbar, editorService, libraryRouteService) {
124
- super(router, route, snackbar, editorService, libraryRouteService);
125
- }
126
- getReqThesauriIds() {
127
- return [
128
- 'comment-tags',
129
- 'doc-reference-tags',
130
- 'doc-reference-types',
131
- 'comment-categories',
132
- 'comment-keyword-languages',
133
- 'comment-keyword-indexes',
134
- 'comment-keyword-tags',
135
- 'comment-id-scopes',
136
- 'comment-id-tags',
137
- 'assertion-tags',
138
- ];
139
- }
140
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.1", ngImport: i0, type: CommentFragmentFeatureComponent, deps: [{ token: i1.Router }, { token: i1.ActivatedRoute }, { token: i2.MatSnackBar }, { token: i4.FragmentEditorService }, { token: i4$1.LibraryRouteService }], target: i0.ɵɵFactoryTarget.Component });
141
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "22.0.1", type: CommentFragmentFeatureComponent, isStandalone: true, selector: "cadmus-comment-fragment-feature", usesInheritance: true, ngImport: i0, template: "<cadmus-current-item-bar />\r\n@let loc = frLoc();\r\n<div class=\"base-text\">\r\n <cadmus-decorated-token-text\r\n [baseText]=\"data()?.baseText || ''\"\r\n [locations]=\"loc ? [loc] : []\"\r\n />\r\n</div>\r\n<cadmus-comment-editor\r\n [data]=\"$any(data())\"\r\n (dataChange)=\"save($any($event!.value!))\"\r\n (editorClose)=\"close()\"\r\n (dirtyChange)=\"onDirtyChange($event)\"\r\n/>\r\n", styles: ["div.base-text{margin:12px;border:1px solid #f0f0f0;border-radius:4px;padding:8px}\n"], dependencies: [{ kind: "component", type: CurrentItemBarComponent, selector: "cadmus-current-item-bar" }, { kind: "component", type: DecoratedTokenTextComponent, selector: "cadmus-decorated-token-text", inputs: ["baseText", "locations", "selectedLocation"] }, { kind: "component", type: CommentEditorComponent, selector: "cadmus-comment-editor" }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
142
- }
143
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.1", ngImport: i0, type: CommentFragmentFeatureComponent, decorators: [{
144
- type: Component,
145
- args: [{ selector: 'cadmus-comment-fragment-feature', changeDetection: ChangeDetectionStrategy.OnPush, imports: [
146
- CurrentItemBarComponent,
147
- DecoratedTokenTextComponent,
148
- CommentEditorComponent,
149
- ], template: "<cadmus-current-item-bar />\r\n@let loc = frLoc();\r\n<div class=\"base-text\">\r\n <cadmus-decorated-token-text\r\n [baseText]=\"data()?.baseText || ''\"\r\n [locations]=\"loc ? [loc] : []\"\r\n />\r\n</div>\r\n<cadmus-comment-editor\r\n [data]=\"$any(data())\"\r\n (dataChange)=\"save($any($event!.value!))\"\r\n (editorClose)=\"close()\"\r\n (dirtyChange)=\"onDirtyChange($event)\"\r\n/>\r\n", styles: ["div.base-text{margin:12px;border:1px solid #f0f0f0;border-radius:4px;padding:8px}\n"] }]
150
- }], ctorParameters: () => [{ type: i1.Router }, { type: i1.ActivatedRoute }, { type: i2.MatSnackBar }, { type: i4.FragmentEditorService }, { type: i4$1.LibraryRouteService }] });
151
-
152
- class CommentPartFeatureComponent extends EditPartFeatureBase {
153
- constructor(router, route, snackbar, itemService, thesaurusService, editorService) {
154
- super(router, route, snackbar, itemService, thesaurusService, editorService);
155
- this.roleIdInThesauri = true;
156
- }
157
- getReqThesauriIds() {
158
- return [
159
- 'comment-tags',
160
- 'doc-reference-tags',
161
- 'doc-reference-types',
162
- 'comment-categories',
163
- 'comment-keyword-languages',
164
- 'comment-keyword-indexes',
165
- 'comment-keyword-tags',
166
- 'comment-id-scopes',
167
- 'comment-id-tags',
168
- 'assertion-tags',
169
- 'asserted-id-features',
170
- ];
171
- }
172
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.1", ngImport: i0, type: CommentPartFeatureComponent, deps: [{ token: i1.Router }, { token: i1.ActivatedRoute }, { token: i2.MatSnackBar }, { token: i3.ItemService }, { token: i3.ThesaurusService }, { token: i4.PartEditorService }], target: i0.ɵɵFactoryTarget.Component });
173
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "22.0.1", type: CommentPartFeatureComponent, isStandalone: true, selector: "cadmus-comment-part-feature", usesInheritance: true, ngImport: i0, template: "<cadmus-current-item-bar/>\r\n<cadmus-comment-editor\r\n [identity]=\"identity()\"\r\n [data]=\"$any(data())\"\r\n (dataChange)=\"save($any($event!.value!))\"\r\n (editorClose)=\"close()\"\r\n (dirtyChange)=\"onDirtyChange($event)\"\r\n/>\r\n", styles: [""], dependencies: [{ kind: "component", type: CurrentItemBarComponent, selector: "cadmus-current-item-bar" }, { kind: "component", type: CommentEditorComponent, selector: "cadmus-comment-editor" }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
174
- }
175
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.1", ngImport: i0, type: CommentPartFeatureComponent, decorators: [{
176
- type: Component,
177
- args: [{ selector: 'cadmus-comment-part-feature', changeDetection: ChangeDetectionStrategy.OnPush, imports: [CurrentItemBarComponent, CommentEditorComponent], template: "<cadmus-current-item-bar/>\r\n<cadmus-comment-editor\r\n [identity]=\"identity()\"\r\n [data]=\"$any(data())\"\r\n (dataChange)=\"save($any($event!.value!))\"\r\n (editorClose)=\"close()\"\r\n (dirtyChange)=\"onDirtyChange($event)\"\r\n/>\r\n" }]
178
- }], ctorParameters: () => [{ type: i1.Router }, { type: i1.ActivatedRoute }, { type: i2.MatSnackBar }, { type: i3.ItemService }, { type: i3.ThesaurusService }, { type: i4.PartEditorService }] });
179
-
180
- class DecoratedCountsPartFeatureComponent extends EditPartFeatureBase {
181
- constructor(router, route, snackbar, itemService, thesaurusService, editorService) {
182
- super(router, route, snackbar, itemService, thesaurusService, editorService);
183
- this.roleIdInThesauri = true;
184
- }
185
- getReqThesauriIds() {
186
- return ['decorated-count-ids', 'decorated-count-tags'];
187
- }
188
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.1", ngImport: i0, type: DecoratedCountsPartFeatureComponent, deps: [{ token: i1.Router }, { token: i1.ActivatedRoute }, { token: i2.MatSnackBar }, { token: i3.ItemService }, { token: i3.ThesaurusService }, { token: i4.PartEditorService }], target: i0.ɵɵFactoryTarget.Component });
189
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "22.0.1", type: DecoratedCountsPartFeatureComponent, isStandalone: true, selector: "cadmus-decorated-counts-part-feature", usesInheritance: true, ngImport: i0, template: "<cadmus-current-item-bar />\r\n<cadmus-decorated-counts-part\r\n [identity]=\"identity()\"\r\n [data]=\"$any(data())\"\r\n (dataChange)=\"save($event!.value!)\"\r\n (editorClose)=\"close()\"\r\n (dirtyChange)=\"onDirtyChange($event)\"\r\n/>\r\n", styles: [""], dependencies: [{ kind: "component", type: CurrentItemBarComponent, selector: "cadmus-current-item-bar" }, { kind: "component", type: DecoratedCountsPartComponent, selector: "cadmus-decorated-counts-part" }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
190
- }
191
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.1", ngImport: i0, type: DecoratedCountsPartFeatureComponent, decorators: [{
192
- type: Component,
193
- args: [{ selector: 'cadmus-decorated-counts-part-feature', changeDetection: ChangeDetectionStrategy.OnPush, imports: [CurrentItemBarComponent, DecoratedCountsPartComponent], template: "<cadmus-current-item-bar />\r\n<cadmus-decorated-counts-part\r\n [identity]=\"identity()\"\r\n [data]=\"$any(data())\"\r\n (dataChange)=\"save($event!.value!)\"\r\n (editorClose)=\"close()\"\r\n (dirtyChange)=\"onDirtyChange($event)\"\r\n/>\r\n" }]
194
- }], ctorParameters: () => [{ type: i1.Router }, { type: i1.ActivatedRoute }, { type: i2.MatSnackBar }, { type: i3.ItemService }, { type: i3.ThesaurusService }, { type: i4.PartEditorService }] });
195
-
196
- class DistrictLocationPartFeatureComponent extends EditPartFeatureBase {
197
- constructor(router, route, snackbar, itemService, thesaurusService, editorService) {
198
- super(router, route, snackbar, itemService, thesaurusService, editorService);
199
- this.roleIdInThesauri = true;
200
- }
201
- getReqThesauriIds() {
202
- return ['district-name-piece-types', 'district-name-lang-entries'];
203
- }
204
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.1", ngImport: i0, type: DistrictLocationPartFeatureComponent, deps: [{ token: i1.Router }, { token: i1.ActivatedRoute }, { token: i2.MatSnackBar }, { token: i3.ItemService }, { token: i3.ThesaurusService }, { token: i4.PartEditorService }], target: i0.ɵɵFactoryTarget.Component });
205
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "22.0.1", type: DistrictLocationPartFeatureComponent, isStandalone: true, selector: "cadmus-district-location-part-feature", usesInheritance: true, ngImport: i0, template: "<cadmus-current-item-bar/>\r\n<cadmus-district-location-part\r\n [identity]=\"identity()\"\r\n [data]=\"$any(data())\"\r\n (dataChange)=\"save($event!.value!)\"\r\n (editorClose)=\"close()\"\r\n (dirtyChange)=\"onDirtyChange($event)\"\r\n/>\r\n", styles: [""], dependencies: [{ kind: "component", type: CurrentItemBarComponent, selector: "cadmus-current-item-bar" }, { kind: "component", type: DistrictLocationPartComponent, selector: "cadmus-district-location-part" }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
206
- }
207
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.1", ngImport: i0, type: DistrictLocationPartFeatureComponent, decorators: [{
208
- type: Component,
209
- args: [{ selector: 'cadmus-district-location-part-feature', changeDetection: ChangeDetectionStrategy.OnPush, imports: [CurrentItemBarComponent, DistrictLocationPartComponent], template: "<cadmus-current-item-bar/>\r\n<cadmus-district-location-part\r\n [identity]=\"identity()\"\r\n [data]=\"$any(data())\"\r\n (dataChange)=\"save($event!.value!)\"\r\n (editorClose)=\"close()\"\r\n (dirtyChange)=\"onDirtyChange($event)\"\r\n/>\r\n" }]
210
- }], ctorParameters: () => [{ type: i1.Router }, { type: i1.ActivatedRoute }, { type: i2.MatSnackBar }, { type: i3.ItemService }, { type: i3.ThesaurusService }, { type: i4.PartEditorService }] });
211
-
212
- class DocReferencesPartFeatureComponent extends EditPartFeatureBase {
213
- constructor(router, route, snackbar, itemService, thesaurusService, editorService) {
214
- super(router, route, snackbar, itemService, thesaurusService, editorService);
215
- this.roleIdInThesauri = true;
216
- }
217
- getReqThesauriIds() {
218
- return ['doc-reference-tags', 'doc-reference-types'];
219
- }
220
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.1", ngImport: i0, type: DocReferencesPartFeatureComponent, deps: [{ token: i1.Router }, { token: i1.ActivatedRoute }, { token: i2.MatSnackBar }, { token: i3.ItemService }, { token: i3.ThesaurusService }, { token: i4.PartEditorService }], target: i0.ɵɵFactoryTarget.Component });
221
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "22.0.1", type: DocReferencesPartFeatureComponent, isStandalone: true, selector: "cadmus-doc-references-part-feature", usesInheritance: true, ngImport: i0, template: "<cadmus-current-item-bar/>\r\n<cadmus-doc-references-part\r\n [identity]=\"identity()\"\r\n [data]=\"$any(data())\"\r\n (dataChange)=\"save($event!.value!)\"\r\n (editorClose)=\"close()\"\r\n (dirtyChange)=\"onDirtyChange($event)\"\r\n/>\r\n", styles: [""], dependencies: [{ kind: "component", type: CurrentItemBarComponent, selector: "cadmus-current-item-bar" }, { kind: "component", type: DocReferencesPartComponent, selector: "cadmus-doc-references-part" }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
222
- }
223
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.1", ngImport: i0, type: DocReferencesPartFeatureComponent, decorators: [{
224
- type: Component,
225
- args: [{ selector: 'cadmus-doc-references-part-feature', changeDetection: ChangeDetectionStrategy.OnPush, imports: [CurrentItemBarComponent, DocReferencesPartComponent], template: "<cadmus-current-item-bar/>\r\n<cadmus-doc-references-part\r\n [identity]=\"identity()\"\r\n [data]=\"$any(data())\"\r\n (dataChange)=\"save($event!.value!)\"\r\n (editorClose)=\"close()\"\r\n (dirtyChange)=\"onDirtyChange($event)\"\r\n/>\r\n" }]
226
- }], ctorParameters: () => [{ type: i1.Router }, { type: i1.ActivatedRoute }, { type: i2.MatSnackBar }, { type: i3.ItemService }, { type: i3.ThesaurusService }, { type: i4.PartEditorService }] });
227
-
228
- class ExternalIdsPartFeatureComponent extends EditPartFeatureBase {
229
- constructor(router, route, snackbar, itemService, thesaurusService, editorService) {
230
- super(router, route, snackbar, itemService, thesaurusService, editorService);
231
- this.roleIdInThesauri = true;
232
- }
233
- getReqThesauriIds() {
234
- return [
235
- 'external-id-scopes',
236
- 'external-id-tags',
237
- 'assertion-tags',
238
- 'doc-reference-types',
239
- 'doc-reference-tags',
240
- ];
241
- }
242
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.1", ngImport: i0, type: ExternalIdsPartFeatureComponent, deps: [{ token: i1.Router }, { token: i1.ActivatedRoute }, { token: i2.MatSnackBar }, { token: i3.ItemService }, { token: i3.ThesaurusService }, { token: i4.PartEditorService }], target: i0.ɵɵFactoryTarget.Component });
243
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "22.0.1", type: ExternalIdsPartFeatureComponent, isStandalone: true, selector: "cadmus-refs-external-ids-part-feature", usesInheritance: true, ngImport: i0, template: "<cadmus-current-item-bar/>\r\n<cadmus-refs-external-ids-part\r\n [identity]=\"identity()\"\r\n [data]=\"$any(data())\"\r\n (dataChange)=\"save($event!.value!)\"\r\n (editorClose)=\"close()\"\r\n (dirtyChange)=\"onDirtyChange($event)\"\r\n/>\r\n", styles: [""], dependencies: [{ kind: "component", type: CurrentItemBarComponent, selector: "cadmus-current-item-bar" }, { kind: "component", type: ExternalIdsPartComponent, selector: "cadmus-refs-external-ids-part" }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
244
- }
245
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.1", ngImport: i0, type: ExternalIdsPartFeatureComponent, decorators: [{
246
- type: Component,
247
- args: [{ selector: 'cadmus-refs-external-ids-part-feature', changeDetection: ChangeDetectionStrategy.OnPush, imports: [CurrentItemBarComponent, ExternalIdsPartComponent], template: "<cadmus-current-item-bar/>\r\n<cadmus-refs-external-ids-part\r\n [identity]=\"identity()\"\r\n [data]=\"$any(data())\"\r\n (dataChange)=\"save($event!.value!)\"\r\n (editorClose)=\"close()\"\r\n (dirtyChange)=\"onDirtyChange($event)\"\r\n/>\r\n" }]
248
- }], ctorParameters: () => [{ type: i1.Router }, { type: i1.ActivatedRoute }, { type: i2.MatSnackBar }, { type: i3.ItemService }, { type: i3.ThesaurusService }, { type: i4.PartEditorService }] });
249
-
250
- class FlagsPartFeatureComponent extends EditPartFeatureBase {
251
- constructor(router, route, snackbar, itemService, thesaurusService, editorService) {
252
- super(router, route, snackbar, itemService, thesaurusService, editorService);
253
- this.roleIdInThesauri = true;
254
- }
255
- getReqThesauriIds() {
256
- return ['flags'];
257
- }
258
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.1", ngImport: i0, type: FlagsPartFeatureComponent, deps: [{ token: i1.Router }, { token: i1.ActivatedRoute }, { token: i2.MatSnackBar }, { token: i3.ItemService }, { token: i3.ThesaurusService }, { token: i4.PartEditorService }], target: i0.ɵɵFactoryTarget.Component });
259
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "22.0.1", type: FlagsPartFeatureComponent, isStandalone: true, selector: "cadmus-flags-part-feature", usesInheritance: true, ngImport: i0, template: "<cadmus-current-item-bar />\r\n<cadmus-flags-part\r\n [identity]=\"identity()\"\r\n [data]=\"$any(data())\"\r\n (dataChange)=\"save($event!.value!)\"\r\n (editorClose)=\"close()\"\r\n (dirtyChange)=\"onDirtyChange($event)\"\r\n/>\r\n", styles: [""], dependencies: [{ kind: "component", type: CurrentItemBarComponent, selector: "cadmus-current-item-bar" }, { kind: "component", type: FlagsPartComponent, selector: "cadmus-flags-part" }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
260
- }
261
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.1", ngImport: i0, type: FlagsPartFeatureComponent, decorators: [{
262
- type: Component,
263
- args: [{ selector: 'cadmus-flags-part-feature', imports: [CurrentItemBarComponent, FlagsPartComponent], changeDetection: ChangeDetectionStrategy.OnPush, template: "<cadmus-current-item-bar />\r\n<cadmus-flags-part\r\n [identity]=\"identity()\"\r\n [data]=\"$any(data())\"\r\n (dataChange)=\"save($event!.value!)\"\r\n (editorClose)=\"close()\"\r\n (dirtyChange)=\"onDirtyChange($event)\"\r\n/>\r\n" }]
264
- }], ctorParameters: () => [{ type: i1.Router }, { type: i1.ActivatedRoute }, { type: i2.MatSnackBar }, { type: i3.ItemService }, { type: i3.ThesaurusService }, { type: i4.PartEditorService }] });
265
-
266
- class HistoricalDatePartFeatureComponent extends EditPartFeatureBase {
267
- constructor(router, route, snackbar, itemService, thesaurusService, editorService) {
268
- super(router, route, snackbar, itemService, thesaurusService, editorService);
269
- this.roleIdInThesauri = true;
270
- }
271
- getReqThesauriIds() {
272
- return ['doc-reference-tags', 'doc-reference-types'];
273
- }
274
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.1", ngImport: i0, type: HistoricalDatePartFeatureComponent, deps: [{ token: i1.Router }, { token: i1.ActivatedRoute }, { token: i2.MatSnackBar }, { token: i3.ItemService }, { token: i3.ThesaurusService }, { token: i4.PartEditorService }], target: i0.ɵɵFactoryTarget.Component });
275
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "22.0.1", type: HistoricalDatePartFeatureComponent, isStandalone: true, selector: "cadmus-historical-date-part-feature", usesInheritance: true, ngImport: i0, template: "<cadmus-current-item-bar/>\r\n<cadmus-historical-date-part\r\n [identity]=\"identity()\"\r\n [data]=\"$any(data())\"\r\n (dataChange)=\"save($event!.value!)\"\r\n (editorClose)=\"close()\"\r\n (dirtyChange)=\"onDirtyChange($event)\"\r\n/>\r\n", styles: [""], dependencies: [{ kind: "component", type: CurrentItemBarComponent, selector: "cadmus-current-item-bar" }, { kind: "component", type: HistoricalDatePartComponent, selector: "cadmus-historical-date-part" }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
276
- }
277
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.1", ngImport: i0, type: HistoricalDatePartFeatureComponent, decorators: [{
278
- type: Component,
279
- args: [{ selector: 'cadmus-historical-date-part-feature', changeDetection: ChangeDetectionStrategy.OnPush, imports: [CurrentItemBarComponent, HistoricalDatePartComponent], template: "<cadmus-current-item-bar/>\r\n<cadmus-historical-date-part\r\n [identity]=\"identity()\"\r\n [data]=\"$any(data())\"\r\n (dataChange)=\"save($event!.value!)\"\r\n (editorClose)=\"close()\"\r\n (dirtyChange)=\"onDirtyChange($event)\"\r\n/>\r\n" }]
280
- }], ctorParameters: () => [{ type: i1.Router }, { type: i1.ActivatedRoute }, { type: i2.MatSnackBar }, { type: i3.ItemService }, { type: i3.ThesaurusService }, { type: i4.PartEditorService }] });
281
-
282
- class HistoricalEventsPartFeatureComponent extends EditPartFeatureBase {
283
- constructor(router, route, snackbar, itemService, thesaurusService, editorService) {
284
- super(router, route, snackbar, itemService, thesaurusService, editorService);
285
- this.roleIdInThesauri = true;
286
- }
287
- getReqThesauriIds() {
288
- return [
289
- 'event-types',
290
- 'event-tags',
291
- 'event-relations',
292
- 'chronotope-tags',
293
- 'asserted-id-scopes',
294
- 'asserted-id-tags',
295
- 'assertion-tags',
296
- 'doc-reference-tags',
297
- 'doc-reference-types',
298
- 'pin-link-scopes',
299
- 'pin-link-tags',
300
- 'asserted-id-features',
301
- ];
302
- }
303
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.1", ngImport: i0, type: HistoricalEventsPartFeatureComponent, deps: [{ token: i1.Router }, { token: i1.ActivatedRoute }, { token: i2.MatSnackBar }, { token: i3.ItemService }, { token: i3.ThesaurusService }, { token: i4.PartEditorService }], target: i0.ɵɵFactoryTarget.Component });
304
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "22.0.1", type: HistoricalEventsPartFeatureComponent, isStandalone: true, selector: "cadmus-historical-events-part-feature", usesInheritance: true, ngImport: i0, template: "<cadmus-current-item-bar/>\n<cadmus-historical-events-part\n [identity]=\"identity()\"\n [data]=\"$any(data())\"\n (dataChange)=\"save($event!.value!)\"\n (editorClose)=\"close()\"\n (dirtyChange)=\"onDirtyChange($event)\"\n/>\n", styles: [""], dependencies: [{ kind: "component", type: CurrentItemBarComponent, selector: "cadmus-current-item-bar" }, { kind: "component", type: HistoricalEventsPartComponent, selector: "cadmus-historical-events-part" }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
305
- }
306
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.1", ngImport: i0, type: HistoricalEventsPartFeatureComponent, decorators: [{
307
- type: Component,
308
- args: [{ selector: 'cadmus-historical-events-part-feature', changeDetection: ChangeDetectionStrategy.OnPush, imports: [CurrentItemBarComponent, HistoricalEventsPartComponent], template: "<cadmus-current-item-bar/>\n<cadmus-historical-events-part\n [identity]=\"identity()\"\n [data]=\"$any(data())\"\n (dataChange)=\"save($event!.value!)\"\n (editorClose)=\"close()\"\n (dirtyChange)=\"onDirtyChange($event)\"\n/>\n" }]
309
- }], ctorParameters: () => [{ type: i1.Router }, { type: i1.ActivatedRoute }, { type: i2.MatSnackBar }, { type: i3.ItemService }, { type: i3.ThesaurusService }, { type: i4.PartEditorService }] });
310
-
311
- class IndexKeywordsPartFeatureComponent extends EditPartFeatureBase {
312
- constructor(router, route, snackbar, itemService, thesaurusService, editorService) {
313
- super(router, route, snackbar, itemService, thesaurusService, editorService);
314
- this.roleIdInThesauri = true;
315
- }
316
- getReqThesauriIds() {
317
- return ['languages', 'keyword-indexes', 'keyword-tags'];
318
- }
319
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.1", ngImport: i0, type: IndexKeywordsPartFeatureComponent, deps: [{ token: i1.Router }, { token: i1.ActivatedRoute }, { token: i2.MatSnackBar }, { token: i3.ItemService }, { token: i3.ThesaurusService }, { token: i4.PartEditorService }], target: i0.ɵɵFactoryTarget.Component });
320
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "22.0.1", type: IndexKeywordsPartFeatureComponent, isStandalone: true, selector: "cadmus-index-keywords-part-feature", usesInheritance: true, ngImport: i0, template: "<cadmus-current-item-bar/>\r\n<cadmus-index-keywords-part\r\n [identity]=\"identity()\"\r\n [data]=\"$any(data())\"\r\n (dataChange)=\"save($event!.value!)\"\r\n (editorClose)=\"close()\"\r\n (dirtyChange)=\"onDirtyChange($event)\"\r\n/>\r\n", styles: [""], dependencies: [{ kind: "component", type: CurrentItemBarComponent, selector: "cadmus-current-item-bar" }, { kind: "component", type: IndexKeywordsPartComponent, selector: "cadmus-index-keywords-part" }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
321
- }
322
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.1", ngImport: i0, type: IndexKeywordsPartFeatureComponent, decorators: [{
323
- type: Component,
324
- args: [{ selector: 'cadmus-index-keywords-part-feature', changeDetection: ChangeDetectionStrategy.OnPush, imports: [CurrentItemBarComponent, IndexKeywordsPartComponent], template: "<cadmus-current-item-bar/>\r\n<cadmus-index-keywords-part\r\n [identity]=\"identity()\"\r\n [data]=\"$any(data())\"\r\n (dataChange)=\"save($event!.value!)\"\r\n (editorClose)=\"close()\"\r\n (dirtyChange)=\"onDirtyChange($event)\"\r\n/>\r\n" }]
325
- }], ctorParameters: () => [{ type: i1.Router }, { type: i1.ActivatedRoute }, { type: i2.MatSnackBar }, { type: i3.ItemService }, { type: i3.ThesaurusService }, { type: i4.PartEditorService }] });
326
-
327
- class KeywordsPartFeatureComponent extends EditPartFeatureBase {
328
- constructor(router, route, snackbar, itemService, thesaurusService, editorService) {
329
- super(router, route, snackbar, itemService, thesaurusService, editorService);
330
- this.roleIdInThesauri = true;
331
- }
332
- getReqThesauriIds() {
333
- return ['languages'];
334
- }
335
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.1", ngImport: i0, type: KeywordsPartFeatureComponent, deps: [{ token: i1.Router }, { token: i1.ActivatedRoute }, { token: i2.MatSnackBar }, { token: i3.ItemService }, { token: i3.ThesaurusService }, { token: i4.PartEditorService }], target: i0.ɵɵFactoryTarget.Component });
336
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "22.0.1", type: KeywordsPartFeatureComponent, isStandalone: true, selector: "cadmus-keywords-part-feature", usesInheritance: true, ngImport: i0, template: "<cadmus-current-item-bar/>\r\n<cadmus-keywords-part\r\n [identity]=\"identity()\"\r\n [data]=\"$any(data())\"\r\n (dataChange)=\"save($event!.value!)\"\r\n (editorClose)=\"close()\"\r\n (dirtyChange)=\"onDirtyChange($event)\"\r\n/>\r\n", styles: [""], dependencies: [{ kind: "component", type: CurrentItemBarComponent, selector: "cadmus-current-item-bar" }, { kind: "component", type: KeywordsPartComponent, selector: "cadmus-keywords-part" }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
337
- }
338
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.1", ngImport: i0, type: KeywordsPartFeatureComponent, decorators: [{
339
- type: Component,
340
- args: [{ selector: 'cadmus-keywords-part-feature', changeDetection: ChangeDetectionStrategy.OnPush, imports: [CurrentItemBarComponent, KeywordsPartComponent], template: "<cadmus-current-item-bar/>\r\n<cadmus-keywords-part\r\n [identity]=\"identity()\"\r\n [data]=\"$any(data())\"\r\n (dataChange)=\"save($event!.value!)\"\r\n (editorClose)=\"close()\"\r\n (dirtyChange)=\"onDirtyChange($event)\"\r\n/>\r\n" }]
341
- }], ctorParameters: () => [{ type: i1.Router }, { type: i1.ActivatedRoute }, { type: i2.MatSnackBar }, { type: i3.ItemService }, { type: i3.ThesaurusService }, { type: i4.PartEditorService }] });
342
-
343
- class MetadataPartFeatureComponent extends EditPartFeatureBase {
344
- constructor(router, route, snackbar, itemService, thesaurusService, editorService) {
345
- super(router, route, snackbar, itemService, thesaurusService, editorService);
346
- }
347
- getReqThesauriIds() {
348
- return ['metadata-types', 'metadata-names'];
349
- }
350
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.1", ngImport: i0, type: MetadataPartFeatureComponent, deps: [{ token: i1.Router }, { token: i1.ActivatedRoute }, { token: i2.MatSnackBar }, { token: i3.ItemService }, { token: i3.ThesaurusService }, { token: i4.PartEditorService }], target: i0.ɵɵFactoryTarget.Component });
351
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "22.0.1", type: MetadataPartFeatureComponent, isStandalone: true, selector: "cadmus-metadata-part-feature", usesInheritance: true, ngImport: i0, template: "<cadmus-current-item-bar/>\n<cadmus-metadata-part\n [identity]=\"identity()\"\n [data]=\"$any(data())\"\n (dataChange)=\"save($event!.value!)\"\n (editorClose)=\"close()\"\n (dirtyChange)=\"onDirtyChange($event)\"\n/>\n", styles: [""], dependencies: [{ kind: "component", type: CurrentItemBarComponent, selector: "cadmus-current-item-bar" }, { kind: "component", type: MetadataPartComponent, selector: "cadmus-metadata-part" }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
352
- }
353
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.1", ngImport: i0, type: MetadataPartFeatureComponent, decorators: [{
354
- type: Component,
355
- args: [{ selector: 'cadmus-metadata-part-feature', changeDetection: ChangeDetectionStrategy.OnPush, imports: [CurrentItemBarComponent, MetadataPartComponent], template: "<cadmus-current-item-bar/>\n<cadmus-metadata-part\n [identity]=\"identity()\"\n [data]=\"$any(data())\"\n (dataChange)=\"save($event!.value!)\"\n (editorClose)=\"close()\"\n (dirtyChange)=\"onDirtyChange($event)\"\n/>\n" }]
356
- }], ctorParameters: () => [{ type: i1.Router }, { type: i1.ActivatedRoute }, { type: i2.MatSnackBar }, { type: i3.ItemService }, { type: i3.ThesaurusService }, { type: i4.PartEditorService }] });
357
-
358
- class NamesPartFeatureComponent extends EditPartFeatureBase {
359
- constructor(router, route, snackbar, itemService, thesaurusService, editorService) {
360
- super(router, route, snackbar, itemService, thesaurusService, editorService);
361
- this.roleIdInThesauri = true;
362
- }
363
- getReqThesauriIds() {
364
- return [
365
- 'name-languages',
366
- 'name-tags',
367
- 'name-piece-types',
368
- 'assertion-tags',
369
- 'doc-reference-types',
370
- 'doc-reference-tags',
371
- ];
372
- }
373
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.1", ngImport: i0, type: NamesPartFeatureComponent, deps: [{ token: i1.Router }, { token: i1.ActivatedRoute }, { token: i2.MatSnackBar }, { token: i3.ItemService }, { token: i3.ThesaurusService }, { token: i4.PartEditorService }], target: i0.ɵɵFactoryTarget.Component });
374
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "22.0.1", type: NamesPartFeatureComponent, isStandalone: true, selector: "cadmus-names-part-feature", usesInheritance: true, ngImport: i0, template: "<cadmus-current-item-bar/>\n<cadmus-names-part\n [identity]=\"identity()\"\n [data]=\"$any(data())\"\n (dataChange)=\"save($event!.value!)\"\n (editorClose)=\"close()\"\n (dirtyChange)=\"onDirtyChange($event)\"\n/>\n", styles: [""], dependencies: [{ kind: "component", type: CurrentItemBarComponent, selector: "cadmus-current-item-bar" }, { kind: "component", type: NamesPartComponent, selector: "cadmus-names-part" }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
375
- }
376
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.1", ngImport: i0, type: NamesPartFeatureComponent, decorators: [{
377
- type: Component,
378
- args: [{ selector: 'cadmus-names-part-feature', changeDetection: ChangeDetectionStrategy.OnPush, imports: [CurrentItemBarComponent, NamesPartComponent], template: "<cadmus-current-item-bar/>\n<cadmus-names-part\n [identity]=\"identity()\"\n [data]=\"$any(data())\"\n (dataChange)=\"save($event!.value!)\"\n (editorClose)=\"close()\"\n (dirtyChange)=\"onDirtyChange($event)\"\n/>\n" }]
379
- }], ctorParameters: () => [{ type: i1.Router }, { type: i1.ActivatedRoute }, { type: i2.MatSnackBar }, { type: i3.ItemService }, { type: i3.ThesaurusService }, { type: i4.PartEditorService }] });
380
-
381
- class NotePartFeatureComponent extends EditPartFeatureBase {
382
- constructor(router, route, snackbar, itemService, thesaurusService, editorService) {
383
- super(router, route, snackbar, itemService, thesaurusService, editorService);
384
- this.roleIdInThesauri = true;
385
- }
386
- getReqThesauriIds() {
387
- return ['note-tags'];
388
- }
389
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.1", ngImport: i0, type: NotePartFeatureComponent, deps: [{ token: i1.Router }, { token: i1.ActivatedRoute }, { token: i2.MatSnackBar }, { token: i3.ItemService }, { token: i3.ThesaurusService }, { token: i4.PartEditorService }], target: i0.ɵɵFactoryTarget.Component });
390
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "22.0.1", type: NotePartFeatureComponent, isStandalone: true, selector: "cadmus-note-part-feature", usesInheritance: true, ngImport: i0, template: "<cadmus-current-item-bar/>\r\n<cadmus-note-part\r\n [identity]=\"identity()\"\r\n [data]=\"$any(data())\"\r\n (dataChange)=\"save($event!.value!)\"\r\n (editorClose)=\"close()\"\r\n (dirtyChange)=\"onDirtyChange($event)\"\r\n/>\r\n", styles: [""], dependencies: [{ kind: "component", type: CurrentItemBarComponent, selector: "cadmus-current-item-bar" }, { kind: "component", type: NotePartComponent, selector: "cadmus-note-part" }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
391
- }
392
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.1", ngImport: i0, type: NotePartFeatureComponent, decorators: [{
393
- type: Component,
394
- args: [{ selector: 'cadmus-note-part-feature', changeDetection: ChangeDetectionStrategy.OnPush, imports: [CurrentItemBarComponent, NotePartComponent], template: "<cadmus-current-item-bar/>\r\n<cadmus-note-part\r\n [identity]=\"identity()\"\r\n [data]=\"$any(data())\"\r\n (dataChange)=\"save($event!.value!)\"\r\n (editorClose)=\"close()\"\r\n (dirtyChange)=\"onDirtyChange($event)\"\r\n/>\r\n" }]
395
- }], ctorParameters: () => [{ type: i1.Router }, { type: i1.ActivatedRoute }, { type: i2.MatSnackBar }, { type: i3.ItemService }, { type: i3.ThesaurusService }, { type: i4.PartEditorService }] });
396
-
397
- class PhysicalMeasurementsPartFeatureComponent extends EditPartFeatureBase {
398
- constructor(router, route, snackbar, itemService, thesaurusService, editorService) {
399
- super(router, route, snackbar, itemService, thesaurusService, editorService);
400
- this.roleIdInThesauri = true;
401
- }
402
- getReqThesauriIds() {
403
- return [
404
- 'physical-size-units',
405
- 'physical-size-dim-tags',
406
- 'physical-size-set-names',
407
- ];
408
- }
409
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.1", ngImport: i0, type: PhysicalMeasurementsPartFeatureComponent, deps: [{ token: i1.Router }, { token: i1.ActivatedRoute }, { token: i2.MatSnackBar }, { token: i3.ItemService }, { token: i3.ThesaurusService }, { token: i4.PartEditorService }], target: i0.ɵɵFactoryTarget.Component });
410
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "22.0.1", type: PhysicalMeasurementsPartFeatureComponent, isStandalone: true, selector: "cadmus-physical-measurements-part-feature", usesInheritance: true, ngImport: i0, template: "<cadmus-current-item-bar/>\r\n<cadmus-physical-measurements-part\r\n [identity]=\"identity()\"\r\n [data]=\"$any(data())\"\r\n (dataChange)=\"save($event!.value!)\"\r\n (editorClose)=\"close()\"\r\n (dirtyChange)=\"onDirtyChange($event)\"\r\n/>\r\n", styles: [""], dependencies: [{ kind: "component", type: CurrentItemBarComponent, selector: "cadmus-current-item-bar" }, { kind: "component", type: PhysicalMeasurementsPartComponent, selector: "cadmus-physical-measurements-part" }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
411
- }
412
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.1", ngImport: i0, type: PhysicalMeasurementsPartFeatureComponent, decorators: [{
413
- type: Component,
414
- args: [{ selector: 'cadmus-physical-measurements-part-feature', changeDetection: ChangeDetectionStrategy.OnPush, imports: [CurrentItemBarComponent, PhysicalMeasurementsPartComponent], template: "<cadmus-current-item-bar/>\r\n<cadmus-physical-measurements-part\r\n [identity]=\"identity()\"\r\n [data]=\"$any(data())\"\r\n (dataChange)=\"save($event!.value!)\"\r\n (editorClose)=\"close()\"\r\n (dirtyChange)=\"onDirtyChange($event)\"\r\n/>\r\n" }]
415
- }], ctorParameters: () => [{ type: i1.Router }, { type: i1.ActivatedRoute }, { type: i2.MatSnackBar }, { type: i3.ItemService }, { type: i3.ThesaurusService }, { type: i4.PartEditorService }] });
416
-
417
- class PhysicalStatesPartFeatureComponent extends EditPartFeatureBase {
418
- constructor(router, route, snackbar, itemService, thesaurusService, editorService) {
419
- super(router, route, snackbar, itemService, thesaurusService, editorService);
420
- }
421
- getReqThesauriIds() {
422
- return [
423
- 'physical-states',
424
- 'physical-state-features',
425
- 'physical-state-reporters',
426
- ];
427
- }
428
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.1", ngImport: i0, type: PhysicalStatesPartFeatureComponent, deps: [{ token: i1.Router }, { token: i1.ActivatedRoute }, { token: i2.MatSnackBar }, { token: i3.ItemService }, { token: i3.ThesaurusService }, { token: i4.PartEditorService }], target: i0.ɵɵFactoryTarget.Component });
429
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "22.0.1", type: PhysicalStatesPartFeatureComponent, isStandalone: true, selector: "cadmus-physical-states-part-feature", usesInheritance: true, ngImport: i0, template: "<cadmus-current-item-bar/>\r\n<cadmus-physical-states-part\r\n [identity]=\"identity()\"\r\n [data]=\"$any(data())\"\r\n (dataChange)=\"save($event!.value!)\"\r\n (editorClose)=\"close()\"\r\n (dirtyChange)=\"onDirtyChange($event)\"\r\n/>\r\n", styles: [""], dependencies: [{ kind: "component", type: CurrentItemBarComponent, selector: "cadmus-current-item-bar" }, { kind: "component", type: PhysicalStatesPartComponent, selector: "cadmus-physical-states-part" }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
430
- }
431
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.1", ngImport: i0, type: PhysicalStatesPartFeatureComponent, decorators: [{
432
- type: Component,
433
- args: [{ selector: 'cadmus-physical-states-part-feature', changeDetection: ChangeDetectionStrategy.OnPush, imports: [CurrentItemBarComponent, PhysicalStatesPartComponent], template: "<cadmus-current-item-bar/>\r\n<cadmus-physical-states-part\r\n [identity]=\"identity()\"\r\n [data]=\"$any(data())\"\r\n (dataChange)=\"save($event!.value!)\"\r\n (editorClose)=\"close()\"\r\n (dirtyChange)=\"onDirtyChange($event)\"\r\n/>\r\n" }]
434
- }], ctorParameters: () => [{ type: i1.Router }, { type: i1.ActivatedRoute }, { type: i2.MatSnackBar }, { type: i3.ItemService }, { type: i3.ThesaurusService }, { type: i4.PartEditorService }] });
435
-
436
- class PinLinksFragmentFeatureComponent extends EditFragmentFeatureBase {
437
- constructor(router, route, snackbar, editorService, libraryRouteService) {
438
- super(router, route, snackbar, editorService, libraryRouteService);
439
- }
440
- getReqThesauriIds() {
441
- return [
442
- 'pin-link-scopes',
443
- 'pin-link-tags',
444
- 'pin-link-assertion-tags',
445
- 'pin-link-docref-types',
446
- 'pin-link-docref-tags',
447
- 'asserted-id-features',
448
- ];
449
- }
450
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.1", ngImport: i0, type: PinLinksFragmentFeatureComponent, deps: [{ token: i1.Router }, { token: i1.ActivatedRoute }, { token: i2.MatSnackBar }, { token: i4.FragmentEditorService }, { token: i4$1.LibraryRouteService }], target: i0.ɵɵFactoryTarget.Component });
451
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "22.0.1", type: PinLinksFragmentFeatureComponent, isStandalone: true, selector: "cadmus-pin-links-fragment-feature", usesInheritance: true, ngImport: i0, template: "<cadmus-current-item-bar/>\n@let loc = frLoc();\n<div class=\"base-text\">\n <cadmus-decorated-token-text\n [baseText]=\"data()?.baseText || ''\"\n [locations]=\"loc ? [loc] : []\"\n />\n</div>\n<cadmus-pin-links-fragment\n [identity]=\"identity()\"\n [data]=\"$any(data())\"\n (dataChange)=\"save($event!.value!)\"\n (editorClose)=\"close()\"\n (dirtyChange)=\"onDirtyChange($event)\"\n/>\n", styles: [""], dependencies: [{ kind: "component", type: CurrentItemBarComponent, selector: "cadmus-current-item-bar" }, { kind: "component", type: DecoratedTokenTextComponent, selector: "cadmus-decorated-token-text", inputs: ["baseText", "locations", "selectedLocation"] }, { kind: "component", type: PinLinksFragmentComponent, selector: "cadmus-pin-links-fragment" }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
452
- }
453
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.1", ngImport: i0, type: PinLinksFragmentFeatureComponent, decorators: [{
454
- type: Component,
455
- args: [{ selector: 'cadmus-pin-links-fragment-feature', changeDetection: ChangeDetectionStrategy.OnPush, imports: [
456
- CurrentItemBarComponent,
457
- DecoratedTokenTextComponent,
458
- PinLinksFragmentComponent,
459
- ], template: "<cadmus-current-item-bar/>\n@let loc = frLoc();\n<div class=\"base-text\">\n <cadmus-decorated-token-text\n [baseText]=\"data()?.baseText || ''\"\n [locations]=\"loc ? [loc] : []\"\n />\n</div>\n<cadmus-pin-links-fragment\n [identity]=\"identity()\"\n [data]=\"$any(data())\"\n (dataChange)=\"save($event!.value!)\"\n (editorClose)=\"close()\"\n (dirtyChange)=\"onDirtyChange($event)\"\n/>\n" }]
460
- }], ctorParameters: () => [{ type: i1.Router }, { type: i1.ActivatedRoute }, { type: i2.MatSnackBar }, { type: i4.FragmentEditorService }, { type: i4$1.LibraryRouteService }] });
461
-
462
- class PinLinksPartFeatureComponent extends EditPartFeatureBase {
463
- constructor(router, route, snackbar, itemService, thesaurusService, editorService) {
464
- super(router, route, snackbar, itemService, thesaurusService, editorService);
465
- this.roleIdInThesauri = true;
466
- }
467
- getReqThesauriIds() {
468
- return [
469
- 'pin-link-scopes',
470
- 'pin-link-tags',
471
- 'pin-link-assertion-tags',
472
- 'pin-link-docref-types',
473
- 'pin-link-docref-tags',
474
- 'asserted-id-features',
475
- ];
476
- }
477
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.1", ngImport: i0, type: PinLinksPartFeatureComponent, deps: [{ token: i1.Router }, { token: i1.ActivatedRoute }, { token: i2.MatSnackBar }, { token: i3.ItemService }, { token: i3.ThesaurusService }, { token: i4.PartEditorService }], target: i0.ɵɵFactoryTarget.Component });
478
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "22.0.1", type: PinLinksPartFeatureComponent, isStandalone: true, selector: "cadmus-pin-links-part-feature", usesInheritance: true, ngImport: i0, template: "<cadmus-current-item-bar/>\n<cadmus-pin-links-part\n [identity]=\"identity()\"\n [data]=\"$any(data())\"\n (dataChange)=\"save($event!.value!)\"\n (editorClose)=\"close()\"\n (dirtyChange)=\"onDirtyChange($event)\"\n/>\n", styles: [""], dependencies: [{ kind: "component", type: CurrentItemBarComponent, selector: "cadmus-current-item-bar" }, { kind: "component", type: PinLinksPartComponent, selector: "cadmus-pin-links-part" }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
479
- }
480
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.1", ngImport: i0, type: PinLinksPartFeatureComponent, decorators: [{
481
- type: Component,
482
- args: [{ selector: 'cadmus-pin-links-part-feature', changeDetection: ChangeDetectionStrategy.OnPush, imports: [CurrentItemBarComponent, PinLinksPartComponent], template: "<cadmus-current-item-bar/>\n<cadmus-pin-links-part\n [identity]=\"identity()\"\n [data]=\"$any(data())\"\n (dataChange)=\"save($event!.value!)\"\n (editorClose)=\"close()\"\n (dirtyChange)=\"onDirtyChange($event)\"\n/>\n" }]
483
- }], ctorParameters: () => [{ type: i1.Router }, { type: i1.ActivatedRoute }, { type: i2.MatSnackBar }, { type: i3.ItemService }, { type: i3.ThesaurusService }, { type: i4.PartEditorService }] });
484
-
485
- /**
486
- * The layer view model for a tiled text.
487
- */
488
- class TiledTextLayerView {
489
- _rows;
490
- /**
491
- * Create a new view from the specified tiled text.
492
- * @param rows The tiled text rows.
493
- */
494
- constructor(rows) {
495
- // setup rows to reflect the text
496
- this._rows = [];
497
- if (rows) {
498
- // for each row
499
- for (let i = 0; i < rows.length; i++) {
500
- this._rows[i] = {
501
- tiles: [],
502
- };
503
- // for each tile in row
504
- for (let j = 0; j < (rows[i].tiles ? rows[i].tiles.length : 0); j++) {
505
- this._rows[i].tiles[j] = {
506
- checked: false,
507
- frIndex: -1,
508
- model: rows[i].tiles[j],
509
- };
510
- }
511
- }
512
- }
513
- }
514
- /**
515
- * The internal rows view models.
516
- */
517
- get rows() {
518
- return this._rows;
519
- }
520
- /**
521
- * Get the tile at the specified coordinates.
522
- *
523
- * @param y The tile's y coordinate.
524
- * @param x The tile's x coordinate.
525
- */
526
- getTileAt(y, x) {
527
- return this._rows[y - 1].tiles[x - 1];
528
- }
529
- /**
530
- * Set the view state of all the tiles.
531
- *
532
- * @param state The state values to set in each tile's state.
533
- * @param setChecked True to set the checked property of states.
534
- * @param setFrIndex True to set the frIndex property of states.
535
- */
536
- setAllTilesViewState(state) {
537
- const hasChecked = state.hasOwnProperty('checked');
538
- const hasFrIndex = state.hasOwnProperty('frIndex');
539
- if (!hasChecked && !hasFrIndex) {
540
- return;
541
- }
542
- // for each row
543
- for (let i = 0; i < this._rows.length; i++) {
544
- const row = this._rows[i];
545
- // for each tile in row
546
- for (let j = 0; j < row.tiles.length; j++) {
547
- const tile = row.tiles[j];
548
- row.tiles[j] = {
549
- checked: (hasChecked ? state.checked : tile.checked) ? true : false,
550
- frIndex: hasFrIndex ? state.frIndex || -1 : tile.frIndex,
551
- model: tile.model,
552
- };
553
- }
554
- }
555
- }
556
- /**
557
- * Set the fragment index of each tile in this view. This is equal to the
558
- * index to the fragment including the tile, when the tile is inside that
559
- * fragment, or to -1, when the tile is outside any fragment. Fragment indexes
560
- * refer to their locations, as received by this function.
561
- *
562
- * @param locations Fragments locations.
563
- */
564
- setFragmentLocations(locations) {
565
- // reset all the tiles fragment indexes
566
- this.setAllTilesViewState({ frIndex: -1 });
567
- // for each fragment's location
568
- for (let i = 0; i < locations.length; i++) {
569
- const loc = locations[i];
570
- if (loc.secondary) {
571
- // range
572
- for (let y = loc.primary.y; y <= loc.secondary.y; y++) {
573
- const row = this._rows[y - 1];
574
- for (let x = y === loc.primary.y ? loc.primary.x : 1; y === loc.secondary.y
575
- ? x <= loc.secondary.x
576
- : x <= row.tiles.length; x++) {
577
- const tile = row.tiles[x - 1];
578
- row.tiles[x - 1] = {
579
- checked: tile.checked,
580
- frIndex: i,
581
- model: tile.model,
582
- };
583
- }
584
- }
585
- }
586
- else {
587
- // point
588
- const tile = this.getTileAt(loc.primary.y, loc.primary.x);
589
- if (tile) {
590
- this._rows[loc.primary.y - 1].tiles[loc.primary.x - 1] = {
591
- checked: tile.checked,
592
- frIndex: i,
593
- model: tile.model,
594
- };
595
- }
596
- }
597
- }
598
- }
599
- /**
600
- * Find the coordinates of the first tile having the specified checked state,
601
- * starting from the specified coordinates.
602
- *
603
- * @param y The y coordinates to start from.
604
- * @param x The x coordinates to start from.
605
- * @param checked True to find checked tiles, false to find unchecked tiles.
606
- * @param reverse True to find in reverse direction.
607
- * @returns The coordinates, or null if not found.
608
- */
609
- findFirstCheckedCoords(y, x, checked, reverse = false) {
610
- if (reverse) {
611
- let xstart = x;
612
- while (true) {
613
- for (let xi = xstart; xi >= 1; xi--) {
614
- if (this.getTileAt(y, xi).checked === checked) {
615
- return {
616
- y,
617
- x: xi,
618
- };
619
- }
620
- }
621
- if (--y > 0) {
622
- xstart = this._rows[y - 1].tiles.length;
623
- }
624
- else {
625
- break;
626
- }
627
- }
628
- }
629
- else {
630
- let xstart = x;
631
- while (true) {
632
- for (let xi = xstart; xi <= this._rows[y - 1].tiles.length; xi++) {
633
- if (this.getTileAt(y, xi).checked === checked) {
634
- return {
635
- y,
636
- x: xi,
637
- };
638
- }
639
- }
640
- if (++y <= this._rows.length) {
641
- xstart = 1;
642
- }
643
- else {
644
- break;
645
- }
646
- }
647
- }
648
- return null;
649
- }
650
- /**
651
- * "Linearly" set the checked state in the specified range of checked tiles.
652
- *
653
- * @param y1 The start y coordinate.
654
- * @param x1 The start x coordinate.
655
- * @param y2 The end y coordinate (included).
656
- * @param x2 The end x coordinate (included).
657
- * @param checked The state to be set.
658
- */
659
- linearSetCheck(y1, x1, y2, x2, checked) {
660
- for (let y = y1; y <= y2; y++) {
661
- const row = this._rows[y - 1];
662
- for (let x = y === y1 ? x1 : 1; y === y2 ? x <= x2 : x <= row.tiles.length; x++) {
663
- const tile = row.tiles[x - 1];
664
- row.tiles[x - 1] = {
665
- frIndex: tile.frIndex,
666
- checked,
667
- model: tile.model,
668
- };
669
- }
670
- }
671
- }
672
- /**
673
- * Get the coordinates of the next tile starting from the specified origin
674
- * tile. The next tile is the tile to the right of the origin tile in the
675
- * same row, or the first tile of the next row (if any) when the origin is
676
- * the last tile in its row.
677
- *
678
- * @param y The y coordinate of the origin tile.
679
- * @param x The x coordinate of the origin tile.
680
- * @returns The coordinates, or null if no other tiles after origin.
681
- */
682
- getNextTileCoords(y, x) {
683
- if (x < this._rows[y - 1].tiles.length) {
684
- return {
685
- y,
686
- x: x + 1,
687
- };
688
- }
689
- y++;
690
- while (y <= this._rows.length) {
691
- if (this._rows[y - 1].tiles.length > 0) {
692
- return {
693
- y,
694
- x: 1,
695
- };
696
- }
697
- y++;
698
- }
699
- return null;
700
- }
701
- /**
702
- * Get the coordinates of the previous tile starting from the specified origin
703
- * tile. The previous tile is the tile to the left of the origin tile in the
704
- * same row, or the last tile of the previous row (if any) when the origin is
705
- * the first tile in its row.
706
- *
707
- * @param y The y coordinate of the origin tile.
708
- * @param x The x coordinate of the origin tile.
709
- * @returns The coordinates, or null if no other tiles before origin.
710
- */
711
- getPrevTileCoords(y, x) {
712
- if (x > 1) {
713
- return {
714
- y,
715
- x: x - 1,
716
- };
717
- }
718
- y--;
719
- while (y > 0) {
720
- if (this._rows[y - 1].tiles.length > 0) {
721
- return {
722
- y,
723
- x: this._rows[y - 1].tiles.length,
724
- };
725
- }
726
- y--;
727
- }
728
- return null;
729
- }
730
- /**
731
- * "Linearly" toggle the tiles according to the specified toggle action
732
- * in the specified set of tiles rows. When users toggle a tile from unchecked
733
- * to checked, and any other tile was checked, the checked state must be
734
- * extended so that all the tiles between the newly checked tile and the old
735
- * one(s) are checked, so that they form a continuous "line", eventually
736
- * spanning rows. The same inversely applies when un-checking tiles. This
737
- * ensures that users can select a single range of tiles by toggling at any
738
- * of its ends.
739
- *
740
- * @param y The y coordinate of the tile which was toggled.
741
- * @param x The x coordinate of the tile which was toggled.
742
- * @param checked The new checked state after toggling the tile.
743
- */
744
- toggleLinearTileCheck(y, x, checked) {
745
- // if it was checked, it was toggled from unchecked
746
- if (checked) {
747
- // find 1st next checked:
748
- let yx = this.findFirstCheckedCoords(y, x, true);
749
- // found: extend from it to y,x
750
- if (yx) {
751
- this.linearSetCheck(yx.y, yx.x, y, x, true);
752
- return;
753
- }
754
- // not found: find 1st prev checked:
755
- yx = this.findFirstCheckedCoords(y, x, true, true);
756
- // found: extend from it to y,x
757
- if (yx) {
758
- this.linearSetCheck(yx.y, yx.x, y, x, true);
759
- return;
760
- }
761
- // not found: check y,x
762
- const tile = this.getTileAt(y, x);
763
- this._rows[y - 1].tiles[x - 1] = {
764
- checked: true,
765
- frIndex: tile.frIndex,
766
- model: tile.model,
767
- };
768
- }
769
- else {
770
- // it was toggled from checked:
771
- // find 1st prev non-checked and set origin (y1,x1) equal to 1 if not found,
772
- // else to the tile next to the one found. Then uncheck all from origin
773
- // to y,x.
774
- let y1;
775
- let x1;
776
- const yx = this.findFirstCheckedCoords(y, x, false, true);
777
- if (yx) {
778
- const next = this.getNextTileCoords(yx.y, yx.x);
779
- if (!next) {
780
- y1 = y;
781
- x1 = x;
782
- }
783
- else {
784
- y1 = next.y;
785
- x1 = next.x;
786
- }
787
- this.linearSetCheck(y1, x1, yx.y, yx.x, false);
788
- }
789
- else {
790
- y1 = 1;
791
- x1 = 1;
792
- }
793
- }
794
- }
795
- /**
796
- * Get the location of the checked tiles, if any. As tiles are checked
797
- * only as an uninterrupted sequence, there can be only 0 or 1 location
798
- * in a set.
799
- *
800
- * @returns The location, or null if no tiles are checked.
801
- */
802
- getCheckedLocation() {
803
- const start = this.findFirstCheckedCoords(1, 1, true);
804
- if (!start) {
805
- return null;
806
- }
807
- const end = this.findFirstCheckedCoords(start.y, start.x, false);
808
- if (!end || (end.y === start.y && end.x === start.x)) {
809
- return null;
810
- }
811
- const last = this.getPrevTileCoords(end.y, end.x);
812
- return !last || (last.y === start.y && last.x === start.x)
813
- ? new TokenLocation(new TokenPoint(start.y, start.x))
814
- : new TokenLocation(new TokenPoint(start.y, start.x), new TokenPoint(last.y, last.x));
815
- }
816
- /**
817
- * Get the location of the checked tiles, together with the index to the
818
- * fragment including them (or a part of them). Should the tiles be included
819
- * in more than 1 fragment, no fragment will be returned.
820
- *
821
- * @returns Object with fragment=fragment index or -1, and location=location
822
- * of checked tiles; or null if no checked tile.
823
- */
824
- getCheckedLocationAndFragment() {
825
- const loc = this.getCheckedLocation();
826
- if (!loc) {
827
- return null;
828
- }
829
- let y2;
830
- let x2;
831
- if (loc.secondary) {
832
- y2 = loc.secondary.y;
833
- x2 = loc.secondary.x;
834
- }
835
- else {
836
- y2 = loc.primary.y;
837
- x2 = loc.primary.x;
838
- }
839
- let fr = -1;
840
- for (let y = loc.primary.y; y <= y2; y++) {
841
- const row = this._rows[y - 1];
842
- for (let x = y === loc.primary.y ? loc.primary.x : 1; x <= (y === y2 ? x2 : row.tiles.length); x++) {
843
- if (row.tiles[x - 1].frIndex > -1) {
844
- if (fr > -1) {
845
- if (fr !== row.tiles[x - 1].frIndex) {
846
- return {
847
- fragment: -1,
848
- location: loc,
849
- };
850
- }
851
- }
852
- else {
853
- fr = row.tiles[x - 1].frIndex;
854
- }
855
- }
856
- }
857
- }
858
- return {
859
- fragment: fr,
860
- location: loc,
861
- };
862
- }
863
- }
864
-
865
- /**
866
- * Tiled text layer part editor.
867
- * This editor allows picking any layer and see all the text tiles included
868
- * in a fragment with a color highlight. Users can check any number of tiles
869
- * not belonging to any fragment in the selected layer, and add a new fragment
870
- * in the selected layer; or check any number of tiles belonging to a fragment
871
- * of the selected layer, and edit or delete it.
872
- * Tiles are thus colorized by the UI to render the fragments extent; and freely
873
- * checked by users to select the fragments to operate with.
874
- * All the checked tiles must follow each other, in one or more rows. Users can
875
- * just check the first and the last of a sequence to get the whole sequence
876
- * checked.
877
- */
878
- class TiledTextLayerPartFeatureComponent {
879
- _router;
880
- _repository;
881
- _libraryRouteService;
882
- _editedItemRepository;
883
- _dialogService;
884
- _sub;
885
- view = signal(undefined, /* @ts-ignore */
886
- ...(ngDevMode ? [{ debugName: "view" }] : /* istanbul ignore next */ []));
887
- selectedTile;
888
- itemId;
889
- partId;
890
- roleId;
891
- loading$;
892
- saving$;
893
- baseText$;
894
- locations$;
895
- rows$;
896
- breakChance$;
897
- layerHints$;
898
- pickedLocation;
899
- userLevel;
900
- constructor(route, _router, _repository, _libraryRouteService, _editedItemRepository, _dialogService, userLevelService) {
901
- this._router = _router;
902
- this._repository = _repository;
903
- this._libraryRouteService = _libraryRouteService;
904
- this._editedItemRepository = _editedItemRepository;
905
- this._dialogService = _dialogService;
906
- this.itemId = route.snapshot.params['iid'];
907
- this.partId = route.snapshot.params['pid'];
908
- if (this.partId === 'new') {
909
- this.partId = undefined;
910
- }
911
- this.roleId = route.snapshot.queryParams['rid'];
912
- if (this.roleId === 'default') {
913
- this.roleId = undefined;
914
- }
915
- this.userLevel = userLevelService.getCurrentUserLevel();
916
- // layers part
917
- this.loading$ = this._repository.loading$;
918
- this.saving$ = this._repository.saving$;
919
- this.baseText$ = this._repository.baseText$;
920
- this.locations$ = this._repository.locations$;
921
- this.breakChance$ = this._repository.breakChance$;
922
- this.layerHints$ = this._repository.layerHints$;
923
- // base text: connect rows to the base text part
924
- this.rows$ = this._repository.baseTextPart$.pipe(map((part) => part?.rows));
925
- }
926
- canDeactivate() {
927
- return true;
928
- }
929
- ngOnInit() {
930
- // when the base text changes, load all the fragments locations
931
- // and setup their UI state
932
- this._sub = this.rows$.subscribe((rows) => {
933
- const v = rows ? new TiledTextLayerView(rows) : undefined;
934
- v?.setFragmentLocations(this._repository.getLocations());
935
- this.view.set(v);
936
- });
937
- // ensure that the container item is loaded
938
- this._editedItemRepository.ensureItemLoaded(this.itemId);
939
- // load the layer part
940
- this._repository.reset();
941
- if (this.partId) {
942
- this._repository.load(this.itemId, this.partId);
943
- }
944
- }
945
- ngOnDestroy() {
946
- this._sub?.unsubscribe();
947
- }
948
- refreshBreakChance() {
949
- this._repository.refreshBreakChance();
950
- }
951
- onTileChecked(y, x, checked) {
952
- const v = this.view();
953
- if (v) {
954
- v.toggleLinearTileCheck(y, x, checked);
955
- }
956
- }
957
- getSelectedTileCoords() {
958
- const v = this.view();
959
- if (!this.selectedTile || !v) {
960
- return null;
961
- }
962
- for (let i = 0; i < v.rows.length; i++) {
963
- const j = v.rows[i].tiles.indexOf(this.selectedTile);
964
- if (j > -1) {
965
- return { y: i + 1, x: j + 1 };
966
- }
967
- }
968
- return null;
969
- }
970
- selectPrevTile() {
971
- const v = this.view();
972
- if (!v) {
973
- return;
974
- }
975
- let yx = this.getSelectedTileCoords();
976
- if (yx) {
977
- yx = v.getPrevTileCoords(yx.y, yx.x);
978
- if (yx) {
979
- this.selectedTile = v.rows[yx.y - 1].tiles[yx.x - 1];
980
- }
981
- }
982
- }
983
- selectNextTile() {
984
- const v = this.view();
985
- if (!v) {
986
- return;
987
- }
988
- let yx = this.getSelectedTileCoords();
989
- if (yx) {
990
- yx = v.getNextTileCoords(yx.y, yx.x);
991
- if (yx) {
992
- this.selectedTile = v.rows[yx.y - 1].tiles[yx.x - 1];
993
- }
994
- }
995
- }
996
- deleteFragment() {
997
- const v = this.view();
998
- if (!v) {
999
- return;
1000
- }
1001
- const lf = v.getCheckedLocationAndFragment();
1002
- if (!lf || lf.fragment === -1) {
1003
- return;
1004
- }
1005
- const locations = this._repository.getLocations();
1006
- const loc = locations[lf.fragment];
1007
- this._dialogService
1008
- .confirm('Delete Fragment', `Delete the fragment at ${loc}?`)
1009
- .subscribe((ok) => {
1010
- if (ok) {
1011
- // find the fragment and remove it from the part
1012
- const i = this._repository.getPart()?.fragments.findIndex((p) => {
1013
- return TokenLocation.parse(p.location)?.overlaps(loc);
1014
- });
1015
- if (i === -1) {
1016
- return;
1017
- }
1018
- this._repository.deleteFragment(loc);
1019
- }
1020
- });
1021
- }
1022
- deleteFragmentFromHint(hint) {
1023
- const loc = TokenLocation.parse(hint.location);
1024
- if (loc) {
1025
- this._repository.deleteFragment(loc);
1026
- }
1027
- }
1028
- navigateToFragmentEditor(loc) {
1029
- const part = this._repository.getPart();
1030
- if (!part) {
1031
- return;
1032
- }
1033
- const { route, rid } = this._libraryRouteService.buildFragmentEditorRoute(this._editedItemRepository.getFacet().partDefinitions, part.itemId, part.id, part.typeId, part.roleId, loc);
1034
- // navigate to the editor
1035
- this._router.navigate([route], rid
1036
- ? {
1037
- queryParams: {
1038
- rid: part.roleId,
1039
- },
1040
- }
1041
- : {});
1042
- }
1043
- editFragment() {
1044
- const v = this.view();
1045
- if (!v) {
1046
- return;
1047
- }
1048
- const lf = v.getCheckedLocationAndFragment();
1049
- if (!lf || lf.fragment === -1) {
1050
- return;
1051
- }
1052
- const locations = this._repository.getLocations();
1053
- this.navigateToFragmentEditor(locations[lf.fragment].toString());
1054
- }
1055
- editFragmentFromHint(hint) {
1056
- this.navigateToFragmentEditor(hint.location);
1057
- }
1058
- moveFragmentFromHint(hint) {
1059
- if (!this.pickedLocation ||
1060
- this.pickedLocation === hint.location ||
1061
- !this.partId) {
1062
- return;
1063
- }
1064
- this._repository.applyLayerPatches(this.partId, [
1065
- `mov ${hint.location} ${this.pickedLocation}`,
1066
- ]);
1067
- }
1068
- addFragment() {
1069
- const v = this.view();
1070
- if (!v) {
1071
- return;
1072
- }
1073
- const lf = v.getCheckedLocationAndFragment();
1074
- if (!lf || lf.fragment > -1) {
1075
- return;
1076
- }
1077
- this.navigateToFragmentEditor(lf.location.toString());
1078
- }
1079
- pickLocation() {
1080
- const v = this.view();
1081
- if (!v) {
1082
- return;
1083
- }
1084
- const lf = v.getCheckedLocationAndFragment();
1085
- if (!lf) {
1086
- return;
1087
- }
1088
- const locations = this._repository.getLocations();
1089
- this.pickedLocation = (lf.fragment === -1 ? lf.location : locations[lf.fragment]).toString();
1090
- }
1091
- clearTileChecks() {
1092
- const v = this.view();
1093
- if (!v) {
1094
- return;
1095
- }
1096
- v.setAllTilesViewState({ checked: false });
1097
- this.pickedLocation = undefined;
1098
- }
1099
- applyLayerPatches(patches) {
1100
- if (this.partId) {
1101
- this._repository.applyLayerPatches(this.partId, patches);
1102
- }
1103
- }
1104
- close() {
1105
- this._router.navigate(['/items', this.itemId]);
1106
- }
1107
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.1", ngImport: i0, type: TiledTextLayerPartFeatureComponent, deps: [{ token: i1.ActivatedRoute }, { token: i1.Router }, { token: i4.EditedLayerRepository }, { token: i4$1.LibraryRouteService }, { token: i4$2.EditedItemRepository }, { token: i5.DialogService }, { token: i3.UserLevelService }], target: i0.ɵɵFactoryTarget.Component });
1108
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.0.1", type: TiledTextLayerPartFeatureComponent, isStandalone: true, selector: "cadmus-tiled-text-layer-part-feature", ngImport: i0, template: "<cadmus-current-item-bar></cadmus-current-item-bar>\n<mat-card appearance=\"outlined\">\n <mat-card-header>\n <div mat-card-avatar>\n <mat-icon>view_headline</mat-icon>\n </div>\n <mat-card-title>\n Tiles-Based Text Layers\n <button type=\"button\" mat-icon-button (click)=\"refreshBreakChance()\">\n @switch (breakChance$ | async) { @case (-1) {\n <mat-icon matTooltip=\"Checking...\">refresh</mat-icon>\n } @case (0) {\n <mat-icon matTooltip=\"Valid\">check_circle</mat-icon>\n } @case (1) {\n <mat-icon matTooltip=\"Potentially broken\" class=\"mat-warn\"\n >warning</mat-icon\n >\n } @case (2) {\n <mat-icon matTooltip=\"Broken\" class=\"mat-warn\">error</mat-icon>\n } }\n </button>\n </mat-card-title>\n <cadmus-current-layer-part-bar />\n </mat-card-header>\n @if (!(loading$ | async) && !(saving$ | async)) {\n <mat-card-actions>\n <mat-toolbar>\n <button\n mat-icon-button\n type=\"button\"\n (click)=\"editFragment()\"\n matTooltip=\"Edit the selected fragment\"\n >\n <mat-icon>edit</mat-icon>\n </button>\n <button\n mat-icon-button\n type=\"button\"\n (click)=\"deleteFragment()\"\n matTooltip=\"Delete the selected fragment\"\n >\n <mat-icon class=\"mat-warn\">delete</mat-icon>\n </button>\n <button\n mat-icon-button\n type=\"button\"\n (click)=\"pickLocation()\"\n matTooltip=\"Pick the selection location for a new fragment\"\n >\n <mat-icon>info</mat-icon>\n </button>\n <button\n mat-icon-button\n type=\"button\"\n (click)=\"clearTileChecks()\"\n matTooltip=\"Clear any selection\"\n >\n <mat-icon class=\"mat-warn\">clear</mat-icon>\n </button>\n <button\n mat-icon-button\n type=\"button\"\n (click)=\"addFragment()\"\n matTooltip=\"Add a new fragment at selection\"\n >\n <mat-icon class=\"mat-primary\">add_circle</mat-icon>\n </button>\n <span>{{ pickedLocation }}</span>\n </mat-toolbar>\n </mat-card-actions>\n }\n\n <mat-card-content>\n @if (loading$ | async) {\n <mat-progress-bar mode=\"indeterminate\" />\n }\n\n <!-- rows -->\n @if (view()) {\n <div>\n @for (row of view()!.rows; track row; let iy = $index) {\n <div class=\"tile-row\" style=\"display: flex; flex-flow: row wrap\">\n <span class=\"row-nr\">{{ iy + 1 }}</span>\n <!-- tile -->\n @for (tile of row.tiles || []; track tile; let ix = $index) {\n <cadmus-text-tile\n [tile]=\"tile.model\"\n [readonly]=\"true\"\n [selected]=\"tile === selectedTile\"\n [checkable]=\"true\"\n [checked]=\"tile.checked\"\n [color]=\"tile.frIndex > -1 ? 'yellow' : 'transparent'\"\n style=\"flex: 0 0 auto\"\n (click)=\"selectedTile = tile\"\n (checkedChange)=\"onTileChecked(iy + 1, ix + 1, $event)\"\n (keydown.control.arrowleft)=\"selectPrevTile()\"\n (keydown.control.arrowright)=\"selectNextTile()\"\n />\n }\n </div>\n }\n </div>\n }\n </mat-card-content>\n\n <div>\n <button\n type=\"button\"\n mat-flat-button\n class=\"mat-warn\"\n matTooltip=\"Close this editor\"\n (click)=\"close()\"\n >\n <mat-icon>cancel</mat-icon>\n close\n </button>\n </div>\n @if (layerHints$ | async; as layerHints) {\n <mat-expansion-panel>\n <mat-expansion-panel-header>\n <mat-panel-title>Layer hints</mat-panel-title>\n <mat-panel-description>{{ layerHints.length }}</mat-panel-description>\n </mat-expansion-panel-header>\n <cadmus-layer-hints\n [hints]=\"layerHints\"\n [disabled]=\"(loading$ | async) || (saving$ | async) ? true : false\"\n [readonly]=\"userLevel < 2\"\n [targetLocation]=\"pickedLocation\"\n (requestEdit)=\"editFragmentFromHint($event)\"\n (requestDelete)=\"deleteFragmentFromHint($event)\"\n (requestMove)=\"moveFragmentFromHint($event)\"\n (requestPatch)=\"applyLayerPatches($event)\"\n />\n </mat-expansion-panel>\n }\n</mat-card>\n", styles: ["div.tile-row{margin-bottom:6px}span.row-nr{color:var(--mat-sys-on-surface-variant);font-weight:700}\n"], dependencies: [{ kind: "component", type: MatCard, selector: "mat-card", inputs: ["appearance"], exportAs: ["matCard"] }, { kind: "component", type: MatCardHeader, selector: "mat-card-header" }, { kind: "directive", type: MatCardAvatar, selector: "[mat-card-avatar], [matCardAvatar]" }, { kind: "component", type: MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { kind: "directive", type: MatCardTitle, selector: "mat-card-title, [mat-card-title], [matCardTitle]" }, { kind: "component", type: MatIconButton, selector: "button[mat-icon-button], a[mat-icon-button], button[matIconButton], a[matIconButton]", exportAs: ["matButton", "matAnchor"] }, { kind: "directive", type: MatTooltip, selector: "[matTooltip]", inputs: ["matTooltipPosition", "matTooltipPositionAtOrigin", "matTooltipDisabled", "matTooltipShowDelay", "matTooltipHideDelay", "matTooltipTouchGestures", "matTooltip", "matTooltipClass"], exportAs: ["matTooltip"] }, { kind: "directive", type: MatCardActions, selector: "mat-card-actions", inputs: ["align"], exportAs: ["matCardActions"] }, { kind: "component", type: MatToolbar, selector: "mat-toolbar", inputs: ["color"], exportAs: ["matToolbar"] }, { kind: "directive", type: MatCardContent, selector: "mat-card-content" }, { kind: "component", type: MatProgressBar, selector: "mat-progress-bar", inputs: ["color", "value", "bufferValue", "mode"], outputs: ["animationEnd"], exportAs: ["matProgressBar"] }, { kind: "component", type: MatButton, selector: " button[matButton], a[matButton], button[mat-button], button[mat-raised-button], button[mat-flat-button], button[mat-stroked-button], a[mat-button], a[mat-raised-button], a[mat-flat-button], a[mat-stroked-button] ", inputs: ["matButton"], exportAs: ["matButton", "matAnchor"] }, { kind: "component", type: MatExpansionPanel, selector: "mat-expansion-panel", inputs: ["hideToggle", "togglePosition"], outputs: ["afterExpand", "afterCollapse"], exportAs: ["matExpansionPanel"] }, { kind: "component", type: MatExpansionPanelHeader, selector: "mat-expansion-panel-header", inputs: ["expandedHeight", "collapsedHeight", "tabIndex"] }, { kind: "directive", type: MatExpansionPanelTitle, selector: "mat-panel-title" }, { kind: "directive", type: MatExpansionPanelDescription, selector: "mat-panel-description" }, { kind: "component", type: CurrentItemBarComponent, selector: "cadmus-current-item-bar" }, { kind: "component", type: CurrentLayerPartBarComponent, selector: "cadmus-current-layer-part-bar" }, { kind: "component", type: LayerHintsComponent, selector: "cadmus-layer-hints", inputs: ["hints", "targetLocation", "disabled", "readonly"], outputs: ["requestEdit", "requestDelete", "requestMove", "requestPatch"] }, { kind: "component", type: TextTileComponent, selector: "cadmus-text-tile", inputs: ["selected", "checkable", "readonly", "color", "checked", "tile"], outputs: ["checkedChange", "tileChange", "editData"] }, { kind: "pipe", type: AsyncPipe, name: "async" }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
1109
- }
1110
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.1", ngImport: i0, type: TiledTextLayerPartFeatureComponent, decorators: [{
1111
- type: Component,
1112
- args: [{ selector: 'cadmus-tiled-text-layer-part-feature', changeDetection: ChangeDetectionStrategy.OnPush, imports: [
1113
- MatCard,
1114
- MatCardHeader,
1115
- MatCardAvatar,
1116
- MatIcon,
1117
- MatCardTitle,
1118
- MatIconButton,
1119
- MatTooltip,
1120
- MatCardActions,
1121
- MatToolbar,
1122
- MatCardContent,
1123
- MatProgressBar,
1124
- MatButton,
1125
- MatExpansionPanel,
1126
- MatExpansionPanelHeader,
1127
- MatExpansionPanelTitle,
1128
- MatExpansionPanelDescription,
1129
- AsyncPipe,
1130
- CurrentItemBarComponent,
1131
- CurrentLayerPartBarComponent,
1132
- LayerHintsComponent,
1133
- TextTileComponent,
1134
- ], template: "<cadmus-current-item-bar></cadmus-current-item-bar>\n<mat-card appearance=\"outlined\">\n <mat-card-header>\n <div mat-card-avatar>\n <mat-icon>view_headline</mat-icon>\n </div>\n <mat-card-title>\n Tiles-Based Text Layers\n <button type=\"button\" mat-icon-button (click)=\"refreshBreakChance()\">\n @switch (breakChance$ | async) { @case (-1) {\n <mat-icon matTooltip=\"Checking...\">refresh</mat-icon>\n } @case (0) {\n <mat-icon matTooltip=\"Valid\">check_circle</mat-icon>\n } @case (1) {\n <mat-icon matTooltip=\"Potentially broken\" class=\"mat-warn\"\n >warning</mat-icon\n >\n } @case (2) {\n <mat-icon matTooltip=\"Broken\" class=\"mat-warn\">error</mat-icon>\n } }\n </button>\n </mat-card-title>\n <cadmus-current-layer-part-bar />\n </mat-card-header>\n @if (!(loading$ | async) && !(saving$ | async)) {\n <mat-card-actions>\n <mat-toolbar>\n <button\n mat-icon-button\n type=\"button\"\n (click)=\"editFragment()\"\n matTooltip=\"Edit the selected fragment\"\n >\n <mat-icon>edit</mat-icon>\n </button>\n <button\n mat-icon-button\n type=\"button\"\n (click)=\"deleteFragment()\"\n matTooltip=\"Delete the selected fragment\"\n >\n <mat-icon class=\"mat-warn\">delete</mat-icon>\n </button>\n <button\n mat-icon-button\n type=\"button\"\n (click)=\"pickLocation()\"\n matTooltip=\"Pick the selection location for a new fragment\"\n >\n <mat-icon>info</mat-icon>\n </button>\n <button\n mat-icon-button\n type=\"button\"\n (click)=\"clearTileChecks()\"\n matTooltip=\"Clear any selection\"\n >\n <mat-icon class=\"mat-warn\">clear</mat-icon>\n </button>\n <button\n mat-icon-button\n type=\"button\"\n (click)=\"addFragment()\"\n matTooltip=\"Add a new fragment at selection\"\n >\n <mat-icon class=\"mat-primary\">add_circle</mat-icon>\n </button>\n <span>{{ pickedLocation }}</span>\n </mat-toolbar>\n </mat-card-actions>\n }\n\n <mat-card-content>\n @if (loading$ | async) {\n <mat-progress-bar mode=\"indeterminate\" />\n }\n\n <!-- rows -->\n @if (view()) {\n <div>\n @for (row of view()!.rows; track row; let iy = $index) {\n <div class=\"tile-row\" style=\"display: flex; flex-flow: row wrap\">\n <span class=\"row-nr\">{{ iy + 1 }}</span>\n <!-- tile -->\n @for (tile of row.tiles || []; track tile; let ix = $index) {\n <cadmus-text-tile\n [tile]=\"tile.model\"\n [readonly]=\"true\"\n [selected]=\"tile === selectedTile\"\n [checkable]=\"true\"\n [checked]=\"tile.checked\"\n [color]=\"tile.frIndex > -1 ? 'yellow' : 'transparent'\"\n style=\"flex: 0 0 auto\"\n (click)=\"selectedTile = tile\"\n (checkedChange)=\"onTileChecked(iy + 1, ix + 1, $event)\"\n (keydown.control.arrowleft)=\"selectPrevTile()\"\n (keydown.control.arrowright)=\"selectNextTile()\"\n />\n }\n </div>\n }\n </div>\n }\n </mat-card-content>\n\n <div>\n <button\n type=\"button\"\n mat-flat-button\n class=\"mat-warn\"\n matTooltip=\"Close this editor\"\n (click)=\"close()\"\n >\n <mat-icon>cancel</mat-icon>\n close\n </button>\n </div>\n @if (layerHints$ | async; as layerHints) {\n <mat-expansion-panel>\n <mat-expansion-panel-header>\n <mat-panel-title>Layer hints</mat-panel-title>\n <mat-panel-description>{{ layerHints.length }}</mat-panel-description>\n </mat-expansion-panel-header>\n <cadmus-layer-hints\n [hints]=\"layerHints\"\n [disabled]=\"(loading$ | async) || (saving$ | async) ? true : false\"\n [readonly]=\"userLevel < 2\"\n [targetLocation]=\"pickedLocation\"\n (requestEdit)=\"editFragmentFromHint($event)\"\n (requestDelete)=\"deleteFragmentFromHint($event)\"\n (requestMove)=\"moveFragmentFromHint($event)\"\n (requestPatch)=\"applyLayerPatches($event)\"\n />\n </mat-expansion-panel>\n }\n</mat-card>\n", styles: ["div.tile-row{margin-bottom:6px}span.row-nr{color:var(--mat-sys-on-surface-variant);font-weight:700}\n"] }]
1135
- }], ctorParameters: () => [{ type: i1.ActivatedRoute }, { type: i1.Router }, { type: i4.EditedLayerRepository }, { type: i4$1.LibraryRouteService }, { type: i4$2.EditedItemRepository }, { type: i5.DialogService }, { type: i3.UserLevelService }] });
1136
-
1137
- class TiledTextPartFeatureComponent extends EditPartFeatureBase {
1138
- constructor(router, route, snackbar, itemService, thesaurusService, editorService) {
1139
- super(router, route, snackbar, itemService, thesaurusService, editorService);
1140
- }
1141
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.1", ngImport: i0, type: TiledTextPartFeatureComponent, deps: [{ token: i1.Router }, { token: i1.ActivatedRoute }, { token: i2.MatSnackBar }, { token: i3.ItemService }, { token: i3.ThesaurusService }, { token: i4.PartEditorService }], target: i0.ɵɵFactoryTarget.Component });
1142
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "22.0.1", type: TiledTextPartFeatureComponent, isStandalone: true, selector: "cadmus-tiled-text-part-feature", usesInheritance: true, ngImport: i0, template: "<cadmus-current-item-bar/>\r\n<cadmus-tiled-text-part\r\n [identity]=\"identity()\"\r\n [data]=\"$any(data())\"\r\n (dataChange)=\"save($event!.value!)\"\r\n (editorClose)=\"close()\"\r\n (dirtyChange)=\"onDirtyChange($event)\"\r\n/>\r\n", styles: [""], dependencies: [{ kind: "component", type: CurrentItemBarComponent, selector: "cadmus-current-item-bar" }, { kind: "component", type: TiledTextPartComponent, selector: "cadmus-tiled-text-part" }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
1143
- }
1144
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.1", ngImport: i0, type: TiledTextPartFeatureComponent, decorators: [{
1145
- type: Component,
1146
- args: [{ selector: 'cadmus-tiled-text-part-feature', changeDetection: ChangeDetectionStrategy.OnPush, imports: [CurrentItemBarComponent, TiledTextPartComponent], template: "<cadmus-current-item-bar/>\r\n<cadmus-tiled-text-part\r\n [identity]=\"identity()\"\r\n [data]=\"$any(data())\"\r\n (dataChange)=\"save($event!.value!)\"\r\n (editorClose)=\"close()\"\r\n (dirtyChange)=\"onDirtyChange($event)\"\r\n/>\r\n" }]
1147
- }], ctorParameters: () => [{ type: i1.Router }, { type: i1.ActivatedRoute }, { type: i2.MatSnackBar }, { type: i3.ItemService }, { type: i3.ThesaurusService }, { type: i4.PartEditorService }] });
1148
-
1149
- /**
1150
- * Token-based text layer part feature editor. This is a special type of editor,
1151
- * rather than being a simple wrapper like the others; it is used for editing
1152
- * any text layer (using token-based coordinates), whatever the type of its
1153
- * fragments. Being a sort of portal for accessing a fragments editor, it has
1154
- * no save capability: the single fragments are edited and saved as needed.
1155
- */
1156
- class TokenTextLayerPartFeatureComponent {
1157
- _router;
1158
- _repository;
1159
- _textLayerService;
1160
- _libraryRouteService;
1161
- _editedItemRepository;
1162
- _dialogService;
1163
- itemId;
1164
- partId;
1165
- roleId;
1166
- loading$;
1167
- saving$;
1168
- baseText$;
1169
- locations$;
1170
- breakChance$;
1171
- layerHints$;
1172
- pickedLocation;
1173
- userLevel;
1174
- textSize;
1175
- constructor(route, _router, _repository, _textLayerService, _libraryRouteService, _editedItemRepository, _dialogService, userLevelService) {
1176
- this._router = _router;
1177
- this._repository = _repository;
1178
- this._textLayerService = _textLayerService;
1179
- this._libraryRouteService = _libraryRouteService;
1180
- this._editedItemRepository = _editedItemRepository;
1181
- this._dialogService = _dialogService;
1182
- this.textSize = 14;
1183
- this.itemId = route.snapshot.params['iid'];
1184
- this.partId = route.snapshot.params['pid'];
1185
- if (this.partId === 'new') {
1186
- this.partId = undefined;
1187
- }
1188
- this.roleId = route.snapshot.queryParams['rid'];
1189
- if (this.roleId === 'default') {
1190
- this.roleId = undefined;
1191
- }
1192
- this.userLevel = userLevelService.getCurrentUserLevel();
1193
- this.loading$ = this._repository.loading$;
1194
- this.saving$ = this._repository.saving$;
1195
- this.baseText$ = this._repository.baseText$;
1196
- this.locations$ = this._repository.locations$;
1197
- this.breakChance$ = this._repository.breakChance$;
1198
- this.layerHints$ = this._repository.layerHints$;
1199
- }
1200
- canDeactivate() {
1201
- return true;
1202
- }
1203
- makeLarger() {
1204
- const size = this.textSize + 2;
1205
- if (size > 24) {
1206
- return;
1207
- }
1208
- this.textSize = size;
1209
- }
1210
- makeSmaller() {
1211
- const size = this.textSize - 2;
1212
- if (size < 12) {
1213
- return;
1214
- }
1215
- this.textSize = size;
1216
- }
1217
- ngOnInit() {
1218
- // ensure the container item is loaded
1219
- this._editedItemRepository.ensureItemLoaded(this.itemId);
1220
- // load the layer part data
1221
- this._repository.reset();
1222
- if (this.partId) {
1223
- this._repository.load(this.itemId, this.partId);
1224
- }
1225
- }
1226
- deleteFragment() {
1227
- const range = this._textLayerService.getSelectedRange();
1228
- if (!range) {
1229
- return;
1230
- }
1231
- const location = this._textLayerService.getSelectedLocationForEdit(range);
1232
- if (!location) {
1233
- return;
1234
- }
1235
- this._dialogService
1236
- .confirm('Delete Fragment', `Delete the fragment at ${location}?`)
1237
- .subscribe((ok) => {
1238
- if (ok) {
1239
- // find the fragment and remove it from the part
1240
- const i = this._repository.getPart()?.fragments.findIndex((p) => {
1241
- return TokenLocation.parse(p.location)?.overlaps(location);
1242
- });
1243
- if (i === -1) {
1244
- return;
1245
- }
1246
- this._repository.deleteFragment(location);
1247
- }
1248
- });
1249
- }
1250
- deleteFragmentFromHint(hint) {
1251
- const loc = TokenLocation.parse(hint.location);
1252
- if (loc) {
1253
- this._repository.deleteFragment(loc);
1254
- }
1255
- }
1256
- refreshBreakChance() {
1257
- this._repository.refreshBreakChance();
1258
- }
1259
- navigateToFragmentEditor(loc) {
1260
- const part = this._repository.getPart();
1261
- if (!part) {
1262
- return;
1263
- }
1264
- const { route, rid } = this._libraryRouteService.buildFragmentEditorRoute(this._editedItemRepository.getFacet().partDefinitions, part.itemId, part.id, part.typeId, part.roleId, loc);
1265
- // navigate to the editor
1266
- this._router.navigate([route], rid
1267
- ? {
1268
- queryParams: {
1269
- rid: part.roleId,
1270
- },
1271
- }
1272
- : {});
1273
- }
1274
- editFragment() {
1275
- const range = this._textLayerService.getSelectedRange();
1276
- if (!range) {
1277
- return;
1278
- }
1279
- const location = this._textLayerService.getSelectedLocationForEdit(range);
1280
- if (location) {
1281
- this.navigateToFragmentEditor(location.toString());
1282
- }
1283
- }
1284
- editFragmentFromHint(hint) {
1285
- this.navigateToFragmentEditor(hint.location);
1286
- }
1287
- addFragment() {
1288
- const range = this._textLayerService.getSelectedRange();
1289
- if (!range) {
1290
- return;
1291
- }
1292
- const location = this._textLayerService.getSelectedLocationForNew(range, this._repository.getBaseText() || '');
1293
- if (location) {
1294
- this.navigateToFragmentEditor(location.toString());
1295
- }
1296
- }
1297
- moveFragmentFromHint(hint) {
1298
- if (!this.pickedLocation ||
1299
- this.pickedLocation === hint.location ||
1300
- !this.partId) {
1301
- return;
1302
- }
1303
- this._repository.applyLayerPatches(this.partId, [
1304
- `mov ${hint.location} ${this.pickedLocation}`,
1305
- ]);
1306
- }
1307
- applyLayerPatches(patches) {
1308
- if (this.partId) {
1309
- this._repository.applyLayerPatches(this.partId, patches);
1310
- }
1311
- }
1312
- pickLocation() {
1313
- const range = this._textLayerService.getSelectedRange();
1314
- if (!range) {
1315
- return;
1316
- }
1317
- const location = this._textLayerService.getSelectedLocationForNew(range, this._repository.getBaseText() || '');
1318
- if (location) {
1319
- this.pickedLocation = location.toString();
1320
- }
1321
- }
1322
- close() {
1323
- this._router.navigate(['/items', this.itemId]);
1324
- }
1325
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.1", ngImport: i0, type: TokenTextLayerPartFeatureComponent, deps: [{ token: i1.ActivatedRoute }, { token: i1.Router }, { token: i4.EditedLayerRepository }, { token: i4$1.TextLayerService }, { token: i4$1.LibraryRouteService }, { token: i4$2.EditedItemRepository }, { token: i5.DialogService }, { token: i3.UserLevelService }], target: i0.ɵɵFactoryTarget.Component });
1326
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.0.1", type: TokenTextLayerPartFeatureComponent, isStandalone: true, selector: "cadmus-token-text-layer-part-feature", ngImport: i0, template: "<cadmus-current-item-bar></cadmus-current-item-bar>\n<mat-card appearance=\"outlined\">\n <mat-card-header>\n <div mat-card-avatar>\n <mat-icon>view_headline</mat-icon>\n </div>\n <mat-card-title>\n Token-Based Text Layers\n <button type=\"button\" mat-icon-button (click)=\"refreshBreakChance()\">\n @switch (breakChance$ | async) { @case (-1) {\n <mat-icon matTooltip=\"Checking...\">refresh</mat-icon>\n } @case (0) {\n <mat-icon matTooltip=\"Valid\">check_circle</mat-icon>\n } @case (1) {\n <mat-icon matTooltip=\"Potentially broken\" class=\"mat-warn\"\n >warning</mat-icon\n >\n } @case (2) {\n <mat-icon matTooltip=\"Broken\" class=\"mat-warn\">error</mat-icon>\n } }\n </button>\n </mat-card-title>\n <cadmus-current-layer-part-bar/>\n </mat-card-header>\n @if (!(loading$ | async)) {\n <mat-card-actions>\n <mat-toolbar>\n <button\n mat-icon-button\n type=\"button\"\n (click)=\"editFragment()\"\n matTooltip=\"Edit the selected fragment\"\n >\n <mat-icon>edit</mat-icon>\n </button>\n <button\n mat-icon-button\n type=\"button\"\n (click)=\"deleteFragment()\"\n matTooltip=\"Delete the selected fragment\"\n >\n <mat-icon class=\"mat-warn\">delete</mat-icon>\n </button>\n <button\n mat-icon-button\n type=\"button\"\n matTooltip=\"Larger text\"\n (click)=\"makeLarger()\"\n [disabled]=\"textSize >= 24\"\n >\n <mat-icon>format_size</mat-icon>\n </button>\n <button\n mat-icon-button\n type=\"button\"\n matTooltip=\"Smaller text\"\n (click)=\"makeSmaller()\"\n [disabled]=\"textSize <= 12\"\n >\n <mat-icon>text_fields</mat-icon>\n </button>\n <button\n mat-icon-button\n type=\"button\"\n (click)=\"pickLocation()\"\n matTooltip=\"Pick the selection location for a new fragment\"\n >\n <mat-icon>info</mat-icon>\n </button>\n <button\n mat-icon-button\n type=\"button\"\n (click)=\"addFragment()\"\n matTooltip=\"Add a new fragment at selection\"\n >\n <mat-icon class=\"mat-primary\">add_circle</mat-icon>\n </button>\n <span>{{ pickedLocation }}</span>\n </mat-toolbar>\n </mat-card-actions>\n }\n <mat-card-content fxLayout=\"row\">\n @if (loading$ | async) {\n <mat-progress-bar mode=\"indeterminate\"/>\n }\n\n <div [style.font-size]=\"textSize + 'px'\">\n @if (baseText$ | async; as baseText) {\n <cadmus-decorated-token-text\n [baseText]=\"baseText\"\n [locations]=\"(locations$ | async) || []\"\n />\n }\n </div>\n </mat-card-content>\n <div>\n <button\n type=\"button\"\n mat-flat-button\n class=\"mat-warn\"\n matTooltip=\"Close this editor\"\n (click)=\"close()\"\n >\n <mat-icon>cancel</mat-icon>\n close\n </button>\n </div>\n @if (layerHints$ | async; as layerHints) {\n <mat-expansion-panel>\n <mat-expansion-panel-header>\n <mat-panel-title>Layer hints</mat-panel-title>\n <mat-panel-description>{{ layerHints.length }}</mat-panel-description>\n </mat-expansion-panel-header>\n <cadmus-layer-hints\n [hints]=\"layerHints\"\n [disabled]=\"(loading$ | async) || (saving$ | async) ? true : false\"\n [readonly]=\"userLevel < 2\"\n [targetLocation]=\"pickedLocation\"\n (requestEdit)=\"editFragmentFromHint($event)\"\n (requestDelete)=\"deleteFragmentFromHint($event)\"\n (requestMove)=\"moveFragmentFromHint($event)\"\n (requestPatch)=\"applyLayerPatches($event)\"\n />\n </mat-expansion-panel>\n }\n</mat-card>\n", styles: [""], dependencies: [{ kind: "component", type: MatCard, selector: "mat-card", inputs: ["appearance"], exportAs: ["matCard"] }, { kind: "component", type: MatCardHeader, selector: "mat-card-header" }, { kind: "directive", type: MatCardAvatar, selector: "[mat-card-avatar], [matCardAvatar]" }, { kind: "component", type: MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { kind: "directive", type: MatCardTitle, selector: "mat-card-title, [mat-card-title], [matCardTitle]" }, { kind: "component", type: MatIconButton, selector: "button[mat-icon-button], a[mat-icon-button], button[matIconButton], a[matIconButton]", exportAs: ["matButton", "matAnchor"] }, { kind: "directive", type: MatTooltip, selector: "[matTooltip]", inputs: ["matTooltipPosition", "matTooltipPositionAtOrigin", "matTooltipDisabled", "matTooltipShowDelay", "matTooltipHideDelay", "matTooltipTouchGestures", "matTooltip", "matTooltipClass"], exportAs: ["matTooltip"] }, { kind: "directive", type: MatCardActions, selector: "mat-card-actions", inputs: ["align"], exportAs: ["matCardActions"] }, { kind: "component", type: MatToolbar, selector: "mat-toolbar", inputs: ["color"], exportAs: ["matToolbar"] }, { kind: "directive", type: MatCardContent, selector: "mat-card-content" }, { kind: "component", type: MatProgressBar, selector: "mat-progress-bar", inputs: ["color", "value", "bufferValue", "mode"], outputs: ["animationEnd"], exportAs: ["matProgressBar"] }, { kind: "component", type: MatButton, selector: " button[matButton], a[matButton], button[mat-button], button[mat-raised-button], button[mat-flat-button], button[mat-stroked-button], a[mat-button], a[mat-raised-button], a[mat-flat-button], a[mat-stroked-button] ", inputs: ["matButton"], exportAs: ["matButton", "matAnchor"] }, { kind: "component", type: MatExpansionPanel, selector: "mat-expansion-panel", inputs: ["hideToggle", "togglePosition"], outputs: ["afterExpand", "afterCollapse"], exportAs: ["matExpansionPanel"] }, { kind: "component", type: MatExpansionPanelHeader, selector: "mat-expansion-panel-header", inputs: ["expandedHeight", "collapsedHeight", "tabIndex"] }, { kind: "directive", type: MatExpansionPanelTitle, selector: "mat-panel-title" }, { kind: "directive", type: MatExpansionPanelDescription, selector: "mat-panel-description" }, { kind: "component", type: LayerHintsComponent, selector: "cadmus-layer-hints", inputs: ["hints", "targetLocation", "disabled", "readonly"], outputs: ["requestEdit", "requestDelete", "requestMove", "requestPatch"] }, { kind: "component", type: CurrentItemBarComponent, selector: "cadmus-current-item-bar" }, { kind: "component", type: CurrentLayerPartBarComponent, selector: "cadmus-current-layer-part-bar" }, { kind: "component", type: DecoratedTokenTextComponent, selector: "cadmus-decorated-token-text", inputs: ["baseText", "locations", "selectedLocation"] }, { kind: "pipe", type: AsyncPipe, name: "async" }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
1327
- }
1328
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.1", ngImport: i0, type: TokenTextLayerPartFeatureComponent, decorators: [{
1329
- type: Component,
1330
- args: [{ selector: 'cadmus-token-text-layer-part-feature', changeDetection: ChangeDetectionStrategy.OnPush, imports: [
1331
- MatCard,
1332
- MatCardHeader,
1333
- MatCardAvatar,
1334
- MatIcon,
1335
- MatCardTitle,
1336
- MatIconButton,
1337
- MatTooltip,
1338
- MatCardActions,
1339
- MatToolbar,
1340
- MatCardContent,
1341
- MatProgressBar,
1342
- MatButton,
1343
- MatExpansionPanel,
1344
- MatExpansionPanelHeader,
1345
- MatExpansionPanelTitle,
1346
- MatExpansionPanelDescription,
1347
- AsyncPipe,
1348
- LayerHintsComponent,
1349
- CurrentItemBarComponent,
1350
- CurrentLayerPartBarComponent,
1351
- DecoratedTokenTextComponent,
1352
- ], template: "<cadmus-current-item-bar></cadmus-current-item-bar>\n<mat-card appearance=\"outlined\">\n <mat-card-header>\n <div mat-card-avatar>\n <mat-icon>view_headline</mat-icon>\n </div>\n <mat-card-title>\n Token-Based Text Layers\n <button type=\"button\" mat-icon-button (click)=\"refreshBreakChance()\">\n @switch (breakChance$ | async) { @case (-1) {\n <mat-icon matTooltip=\"Checking...\">refresh</mat-icon>\n } @case (0) {\n <mat-icon matTooltip=\"Valid\">check_circle</mat-icon>\n } @case (1) {\n <mat-icon matTooltip=\"Potentially broken\" class=\"mat-warn\"\n >warning</mat-icon\n >\n } @case (2) {\n <mat-icon matTooltip=\"Broken\" class=\"mat-warn\">error</mat-icon>\n } }\n </button>\n </mat-card-title>\n <cadmus-current-layer-part-bar/>\n </mat-card-header>\n @if (!(loading$ | async)) {\n <mat-card-actions>\n <mat-toolbar>\n <button\n mat-icon-button\n type=\"button\"\n (click)=\"editFragment()\"\n matTooltip=\"Edit the selected fragment\"\n >\n <mat-icon>edit</mat-icon>\n </button>\n <button\n mat-icon-button\n type=\"button\"\n (click)=\"deleteFragment()\"\n matTooltip=\"Delete the selected fragment\"\n >\n <mat-icon class=\"mat-warn\">delete</mat-icon>\n </button>\n <button\n mat-icon-button\n type=\"button\"\n matTooltip=\"Larger text\"\n (click)=\"makeLarger()\"\n [disabled]=\"textSize >= 24\"\n >\n <mat-icon>format_size</mat-icon>\n </button>\n <button\n mat-icon-button\n type=\"button\"\n matTooltip=\"Smaller text\"\n (click)=\"makeSmaller()\"\n [disabled]=\"textSize <= 12\"\n >\n <mat-icon>text_fields</mat-icon>\n </button>\n <button\n mat-icon-button\n type=\"button\"\n (click)=\"pickLocation()\"\n matTooltip=\"Pick the selection location for a new fragment\"\n >\n <mat-icon>info</mat-icon>\n </button>\n <button\n mat-icon-button\n type=\"button\"\n (click)=\"addFragment()\"\n matTooltip=\"Add a new fragment at selection\"\n >\n <mat-icon class=\"mat-primary\">add_circle</mat-icon>\n </button>\n <span>{{ pickedLocation }}</span>\n </mat-toolbar>\n </mat-card-actions>\n }\n <mat-card-content fxLayout=\"row\">\n @if (loading$ | async) {\n <mat-progress-bar mode=\"indeterminate\"/>\n }\n\n <div [style.font-size]=\"textSize + 'px'\">\n @if (baseText$ | async; as baseText) {\n <cadmus-decorated-token-text\n [baseText]=\"baseText\"\n [locations]=\"(locations$ | async) || []\"\n />\n }\n </div>\n </mat-card-content>\n <div>\n <button\n type=\"button\"\n mat-flat-button\n class=\"mat-warn\"\n matTooltip=\"Close this editor\"\n (click)=\"close()\"\n >\n <mat-icon>cancel</mat-icon>\n close\n </button>\n </div>\n @if (layerHints$ | async; as layerHints) {\n <mat-expansion-panel>\n <mat-expansion-panel-header>\n <mat-panel-title>Layer hints</mat-panel-title>\n <mat-panel-description>{{ layerHints.length }}</mat-panel-description>\n </mat-expansion-panel-header>\n <cadmus-layer-hints\n [hints]=\"layerHints\"\n [disabled]=\"(loading$ | async) || (saving$ | async) ? true : false\"\n [readonly]=\"userLevel < 2\"\n [targetLocation]=\"pickedLocation\"\n (requestEdit)=\"editFragmentFromHint($event)\"\n (requestDelete)=\"deleteFragmentFromHint($event)\"\n (requestMove)=\"moveFragmentFromHint($event)\"\n (requestPatch)=\"applyLayerPatches($event)\"\n />\n </mat-expansion-panel>\n }\n</mat-card>\n" }]
1353
- }], ctorParameters: () => [{ type: i1.ActivatedRoute }, { type: i1.Router }, { type: i4.EditedLayerRepository }, { type: i4$1.TextLayerService }, { type: i4$1.LibraryRouteService }, { type: i4$2.EditedItemRepository }, { type: i5.DialogService }, { type: i3.UserLevelService }] });
1354
-
1355
- class TokenTextPartFeatureComponent extends EditPartFeatureBase {
1356
- constructor(router, route, snackbar, itemService, thesaurusService, editorService) {
1357
- super(router, route, snackbar, itemService, thesaurusService, editorService);
1358
- }
1359
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.1", ngImport: i0, type: TokenTextPartFeatureComponent, deps: [{ token: i1.Router }, { token: i1.ActivatedRoute }, { token: i2.MatSnackBar }, { token: i3.ItemService }, { token: i3.ThesaurusService }, { token: i4.PartEditorService }], target: i0.ɵɵFactoryTarget.Component });
1360
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "22.0.1", type: TokenTextPartFeatureComponent, isStandalone: true, selector: "cadmus-token-text-part-feature", usesInheritance: true, ngImport: i0, template: "<cadmus-current-item-bar/>\r\n<cadmus-token-text-part\r\n [identity]=\"identity()\"\r\n [data]=\"$any(data())\"\r\n (dataChange)=\"save($event!.value!)\"\r\n (editorClose)=\"close()\"\r\n (dirtyChange)=\"onDirtyChange($event)\"\r\n/>\r\n", styles: [""], dependencies: [{ kind: "component", type: CurrentItemBarComponent, selector: "cadmus-current-item-bar" }, { kind: "component", type: TokenTextPartComponent, selector: "cadmus-token-text-part" }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
1361
- }
1362
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.1", ngImport: i0, type: TokenTextPartFeatureComponent, decorators: [{
1363
- type: Component,
1364
- args: [{ selector: 'cadmus-token-text-part-feature', changeDetection: ChangeDetectionStrategy.OnPush, imports: [CurrentItemBarComponent, TokenTextPartComponent], template: "<cadmus-current-item-bar/>\r\n<cadmus-token-text-part\r\n [identity]=\"identity()\"\r\n [data]=\"$any(data())\"\r\n (dataChange)=\"save($event!.value!)\"\r\n (editorClose)=\"close()\"\r\n (dirtyChange)=\"onDirtyChange($event)\"\r\n/>\r\n" }]
1365
- }], ctorParameters: () => [{ type: i1.Router }, { type: i1.ActivatedRoute }, { type: i2.MatSnackBar }, { type: i3.ItemService }, { type: i3.ThesaurusService }, { type: i4.PartEditorService }] });
1366
-
1367
- // https://github.com/ng-packagr/ng-packagr/issues/778
1
+ import * as i0 from "@angular/core";
2
+ import { ChangeDetectionStrategy, Component, signal } from "@angular/core";
3
+ import { ASSERTED_HISTORICAL_DATES_PART_TYPEID, AssertedHistoricalDatesPartComponent, BIBLIOGRAPHY_PART_TYPEID, BibliographyPartComponent, CATEGORIES_PART_TYPEID, CHRONOLOGY_FRAGMENT_TYPEID, CHRONOTOPES_PART_TYPEID, COMMENT_FRAGMENT_TYPEID, COMMENT_PART_TYPEID, CategoriesPartComponent, ChronologyFragmentComponent, ChronotopesPartComponent, CommentEditorComponent, DECORATED_COUNTS_PART_TYPEID, DISTRICT_LOCATION_PART_TYPEID, DOC_REFERENCES_PART_TYPEID, DecoratedCountsPartComponent, DistrictLocationPartComponent, DocReferencesPartComponent, EXTERNAL_IDS_PART_TYPEID, ExternalIdsPartComponent, FLAGS_PART_TYPEID, FlagsPartComponent, HISTORICAL_DATE_PART_TYPEID, HISTORICAL_EVENTS_PART_TYPEID, HistoricalDatePartComponent, HistoricalEventsPartComponent, INDEX_KEYWORDS_PART_TYPEID, IndexKeywordsPartComponent, KEYWORDS_PART_TYPEID, KeywordsPartComponent, METADATA_PART_TYPEID, MetadataPartComponent, NAMES_PART_TYPEID, NOTE_PART_TYPEID, NamesPartComponent, NotePartComponent, PHYSICAL_MEASUREMENTS_PART_TYPEID, PHYSICAL_STATES_PART_TYPEID, PIN_LINKS_FRAGMENT_TYPEID, PIN_LINKS_PART_TYPEID, PhysicalMeasurementsPartComponent, PhysicalStatesPartComponent, PinLinksFragmentComponent, PinLinksPartComponent, TILED_TEXT_PART_TYPEID, TOKEN_TEXT_PART_TYPEID, TextTileComponent, TiledTextPartComponent, TokenTextPartComponent } from "@myrmidon/cadmus-part-general-ui";
4
+ import * as i4$2 from "@myrmidon/cadmus-state";
5
+ import { EditFragmentFeatureBase, EditPartFeatureBase } from "@myrmidon/cadmus-state";
6
+ import * as i4 from "@myrmidon/cadmus-item-editor";
7
+ import { CurrentItemBarComponent, CurrentLayerPartBarComponent } from "@myrmidon/cadmus-item-editor";
8
+ import * as i1 from "@angular/router";
9
+ import * as i2 from "@angular/material/snack-bar";
10
+ import * as i3 from "@myrmidon/cadmus-api";
11
+ import { DecoratedTokenTextComponent, LayerHintsComponent } from "@myrmidon/cadmus-ui";
12
+ import * as i4$1 from "@myrmidon/cadmus-core";
13
+ import { TokenLocation, TokenPoint, pendingChangesGuard } from "@myrmidon/cadmus-core";
14
+ import { AsyncPipe } from "@angular/common";
15
+ import { map } from "rxjs";
16
+ import { MatCard, MatCardActions, MatCardAvatar, MatCardContent, MatCardHeader, MatCardTitle } from "@angular/material/card";
17
+ import { MatIcon } from "@angular/material/icon";
18
+ import { MatButton, MatIconButton } from "@angular/material/button";
19
+ import { MatTooltip } from "@angular/material/tooltip";
20
+ import { MatToolbar } from "@angular/material/toolbar";
21
+ import { MatProgressBar } from "@angular/material/progress-bar";
22
+ import { MatExpansionPanel, MatExpansionPanelDescription, MatExpansionPanelHeader, MatExpansionPanelTitle } from "@angular/material/expansion";
23
+ import * as i5 from "@myrmidon/ngx-mat-tools";
24
+ var AssertedHistoricalDateFeatureComponent = class AssertedHistoricalDateFeatureComponent extends EditPartFeatureBase {
25
+ constructor(router, route, snackbar, itemService, thesaurusService, editorService) {
26
+ super(router, route, snackbar, itemService, thesaurusService, editorService);
27
+ this.roleIdInThesauri = true;
28
+ }
29
+ getReqThesauriIds() {
30
+ return [
31
+ "asserted-historical-dates-tags",
32
+ "assertion-tags",
33
+ "doc-reference-types",
34
+ "doc-reference-tags"
35
+ ];
36
+ }
37
+ static ɵfac = i0.ɵɵngDeclareFactory({
38
+ minVersion: "12.0.0",
39
+ version: "22.2.0",
40
+ ngImport: i0,
41
+ type: AssertedHistoricalDateFeatureComponent,
42
+ deps: [
43
+ { token: i1.Router },
44
+ { token: i1.ActivatedRoute },
45
+ { token: i2.MatSnackBar },
46
+ { token: i3.ItemService },
47
+ { token: i3.ThesaurusService },
48
+ { token: i4$2.PartEditorService }
49
+ ],
50
+ target: i0.ɵɵFactoryTarget.Component
51
+ });
52
+ static ɵcmp = i0.ɵɵngDeclareComponent({
53
+ minVersion: "14.0.0",
54
+ version: "22.2.0",
55
+ type: AssertedHistoricalDateFeatureComponent,
56
+ isStandalone: true,
57
+ selector: "cadmus-asserted-historical-date-feature",
58
+ usesInheritance: true,
59
+ ngImport: i0,
60
+ template: "<cadmus-current-item-bar />\r\n<cadmus-asserted-historical-dates-part\r\n [identity]=\"identity()\"\r\n [data]=\"$any(data())\"\r\n (dataChange)=\"save($event!.value!)\"\r\n (editorClose)=\"close()\"\r\n (dirtyChange)=\"onDirtyChange($event)\"\r\n/>\r\n",
61
+ styles: [""],
62
+ dependencies: [{
63
+ kind: "component",
64
+ type: CurrentItemBarComponent,
65
+ selector: "cadmus-current-item-bar"
66
+ }, {
67
+ kind: "component",
68
+ type: AssertedHistoricalDatesPartComponent,
69
+ selector: "cadmus-asserted-historical-dates-part"
70
+ }],
71
+ changeDetection: i0.ChangeDetectionStrategy.OnPush
72
+ });
73
+ };
74
+ i0.ɵɵngDeclareClassMetadata({
75
+ minVersion: "12.0.0",
76
+ version: "22.2.0",
77
+ ngImport: i0,
78
+ type: AssertedHistoricalDateFeatureComponent,
79
+ decorators: [{
80
+ type: Component,
81
+ args: [{
82
+ selector: "cadmus-asserted-historical-date-feature",
83
+ imports: [CurrentItemBarComponent, AssertedHistoricalDatesPartComponent],
84
+ changeDetection: ChangeDetectionStrategy.OnPush,
85
+ template: "<cadmus-current-item-bar />\r\n<cadmus-asserted-historical-dates-part\r\n [identity]=\"identity()\"\r\n [data]=\"$any(data())\"\r\n (dataChange)=\"save($event!.value!)\"\r\n (editorClose)=\"close()\"\r\n (dirtyChange)=\"onDirtyChange($event)\"\r\n/>\r\n"
86
+ }]
87
+ }],
88
+ ctorParameters: () => [
89
+ { type: i1.Router },
90
+ { type: i1.ActivatedRoute },
91
+ { type: i2.MatSnackBar },
92
+ { type: i3.ItemService },
93
+ { type: i3.ThesaurusService },
94
+ { type: i4$2.PartEditorService }
95
+ ]
96
+ });
97
+ var BibliographyPartFeatureComponent = class BibliographyPartFeatureComponent extends EditPartFeatureBase {
98
+ constructor(router, route, snackbar, itemService, thesaurusService, editorService) {
99
+ super(router, route, snackbar, itemService, thesaurusService, editorService);
100
+ }
101
+ getReqThesauriIds() {
102
+ return [
103
+ "bibliography-languages",
104
+ "bibliography-types",
105
+ "bibliography-tags",
106
+ "bibliography-author-roles"
107
+ ];
108
+ }
109
+ static ɵfac = i0.ɵɵngDeclareFactory({
110
+ minVersion: "12.0.0",
111
+ version: "22.2.0",
112
+ ngImport: i0,
113
+ type: BibliographyPartFeatureComponent,
114
+ deps: [
115
+ { token: i1.Router },
116
+ { token: i1.ActivatedRoute },
117
+ { token: i2.MatSnackBar },
118
+ { token: i3.ItemService },
119
+ { token: i3.ThesaurusService },
120
+ { token: i4$2.PartEditorService }
121
+ ],
122
+ target: i0.ɵɵFactoryTarget.Component
123
+ });
124
+ static ɵcmp = i0.ɵɵngDeclareComponent({
125
+ minVersion: "14.0.0",
126
+ version: "22.2.0",
127
+ type: BibliographyPartFeatureComponent,
128
+ isStandalone: true,
129
+ selector: "cadmus-bibliography-part-feature",
130
+ usesInheritance: true,
131
+ ngImport: i0,
132
+ template: "<cadmus-current-item-bar/>\r\n<cadmus-bibliography-part\r\n [identity]=\"identity()\"\r\n [data]=\"$any(data())\"\r\n (dataChange)=\"save($event!.value!)\"\r\n (editorClose)=\"close()\"\r\n (dirtyChange)=\"onDirtyChange($event)\"\r\n/>\r\n",
133
+ styles: [""],
134
+ dependencies: [{
135
+ kind: "component",
136
+ type: CurrentItemBarComponent,
137
+ selector: "cadmus-current-item-bar"
138
+ }, {
139
+ kind: "component",
140
+ type: BibliographyPartComponent,
141
+ selector: "cadmus-bibliography-part"
142
+ }],
143
+ changeDetection: i0.ChangeDetectionStrategy.OnPush
144
+ });
145
+ };
146
+ i0.ɵɵngDeclareClassMetadata({
147
+ minVersion: "12.0.0",
148
+ version: "22.2.0",
149
+ ngImport: i0,
150
+ type: BibliographyPartFeatureComponent,
151
+ decorators: [{
152
+ type: Component,
153
+ args: [{
154
+ selector: "cadmus-bibliography-part-feature",
155
+ imports: [CurrentItemBarComponent, BibliographyPartComponent],
156
+ changeDetection: ChangeDetectionStrategy.OnPush,
157
+ template: "<cadmus-current-item-bar/>\r\n<cadmus-bibliography-part\r\n [identity]=\"identity()\"\r\n [data]=\"$any(data())\"\r\n (dataChange)=\"save($event!.value!)\"\r\n (editorClose)=\"close()\"\r\n (dirtyChange)=\"onDirtyChange($event)\"\r\n/>\r\n"
158
+ }]
159
+ }],
160
+ ctorParameters: () => [
161
+ { type: i1.Router },
162
+ { type: i1.ActivatedRoute },
163
+ { type: i2.MatSnackBar },
164
+ { type: i3.ItemService },
165
+ { type: i3.ThesaurusService },
166
+ { type: i4$2.PartEditorService }
167
+ ]
168
+ });
169
+ var CategoriesPartFeatureComponent = class CategoriesPartFeatureComponent extends EditPartFeatureBase {
170
+ constructor(router, route, snackbar, itemService, thesaurusService, editorService) {
171
+ super(router, route, snackbar, itemService, thesaurusService, editorService);
172
+ this.roleIdInThesauri = true;
173
+ }
174
+ getReqThesauriIds() {
175
+ return ["categories"];
176
+ }
177
+ static ɵfac = i0.ɵɵngDeclareFactory({
178
+ minVersion: "12.0.0",
179
+ version: "22.2.0",
180
+ ngImport: i0,
181
+ type: CategoriesPartFeatureComponent,
182
+ deps: [
183
+ { token: i1.Router },
184
+ { token: i1.ActivatedRoute },
185
+ { token: i2.MatSnackBar },
186
+ { token: i3.ItemService },
187
+ { token: i3.ThesaurusService },
188
+ { token: i4$2.PartEditorService }
189
+ ],
190
+ target: i0.ɵɵFactoryTarget.Component
191
+ });
192
+ static ɵcmp = i0.ɵɵngDeclareComponent({
193
+ minVersion: "14.0.0",
194
+ version: "22.2.0",
195
+ type: CategoriesPartFeatureComponent,
196
+ isStandalone: true,
197
+ selector: "cadmus-categories-part-feature",
198
+ usesInheritance: true,
199
+ ngImport: i0,
200
+ template: "<cadmus-current-item-bar/>\r\n<cadmus-categories-part\r\n [identity]=\"identity()\"\r\n [data]=\"$any(data())\"\r\n (dataChange)=\"save($event!.value!)\"\r\n (editorClose)=\"close()\"\r\n (dirtyChange)=\"onDirtyChange($event)\"\r\n/>\r\n",
201
+ styles: [""],
202
+ dependencies: [{
203
+ kind: "component",
204
+ type: CurrentItemBarComponent,
205
+ selector: "cadmus-current-item-bar"
206
+ }, {
207
+ kind: "component",
208
+ type: CategoriesPartComponent,
209
+ selector: "cadmus-categories-part"
210
+ }],
211
+ changeDetection: i0.ChangeDetectionStrategy.OnPush
212
+ });
213
+ };
214
+ i0.ɵɵngDeclareClassMetadata({
215
+ minVersion: "12.0.0",
216
+ version: "22.2.0",
217
+ ngImport: i0,
218
+ type: CategoriesPartFeatureComponent,
219
+ decorators: [{
220
+ type: Component,
221
+ args: [{
222
+ selector: "cadmus-categories-part-feature",
223
+ imports: [CurrentItemBarComponent, CategoriesPartComponent],
224
+ changeDetection: ChangeDetectionStrategy.OnPush,
225
+ template: "<cadmus-current-item-bar/>\r\n<cadmus-categories-part\r\n [identity]=\"identity()\"\r\n [data]=\"$any(data())\"\r\n (dataChange)=\"save($event!.value!)\"\r\n (editorClose)=\"close()\"\r\n (dirtyChange)=\"onDirtyChange($event)\"\r\n/>\r\n"
226
+ }]
227
+ }],
228
+ ctorParameters: () => [
229
+ { type: i1.Router },
230
+ { type: i1.ActivatedRoute },
231
+ { type: i2.MatSnackBar },
232
+ { type: i3.ItemService },
233
+ { type: i3.ThesaurusService },
234
+ { type: i4$2.PartEditorService }
235
+ ]
236
+ });
237
+ var ChronologyFragmentFeatureComponent = class ChronologyFragmentFeatureComponent extends EditFragmentFeatureBase {
238
+ constructor(router, route, snackbar, editorService, libraryRouteService) {
239
+ super(router, route, snackbar, editorService, libraryRouteService);
240
+ }
241
+ getReqThesauriIds() {
242
+ return ["chronology-tags"];
243
+ }
244
+ static ɵfac = i0.ɵɵngDeclareFactory({
245
+ minVersion: "12.0.0",
246
+ version: "22.2.0",
247
+ ngImport: i0,
248
+ type: ChronologyFragmentFeatureComponent,
249
+ deps: [
250
+ { token: i1.Router },
251
+ { token: i1.ActivatedRoute },
252
+ { token: i2.MatSnackBar },
253
+ { token: i4$2.FragmentEditorService },
254
+ { token: i4$1.LibraryRouteService }
255
+ ],
256
+ target: i0.ɵɵFactoryTarget.Component
257
+ });
258
+ static ɵcmp = i0.ɵɵngDeclareComponent({
259
+ minVersion: "14.0.0",
260
+ version: "22.2.0",
261
+ type: ChronologyFragmentFeatureComponent,
262
+ isStandalone: true,
263
+ selector: "cadmus-chronology-fragment-feature",
264
+ usesInheritance: true,
265
+ ngImport: i0,
266
+ template: "<cadmus-current-item-bar/>\r\n@let loc = frLoc();\r\n<div class=\"base-text\">\r\n <cadmus-decorated-token-text\r\n [baseText]=\"data()?.baseText || ''\"\r\n [locations]=\"loc ? [loc] : []\"\r\n />\r\n</div>\r\n<!-- identity was missing here: ModelEditorComponentBase's modelName() falls\r\n back to the layer part's own name (wrong title) without it -->\r\n<cadmus-chronology-fragment\r\n [identity]=\"identity()\"\r\n [data]=\"$any(data())\"\r\n (dataChange)=\"save($event!.value!)\"\r\n (editorClose)=\"close()\"\r\n (dirtyChange)=\"onDirtyChange($event)\"\r\n/>\r\n",
267
+ styles: [""],
268
+ dependencies: [
269
+ {
270
+ kind: "component",
271
+ type: CurrentItemBarComponent,
272
+ selector: "cadmus-current-item-bar"
273
+ },
274
+ {
275
+ kind: "component",
276
+ type: DecoratedTokenTextComponent,
277
+ selector: "cadmus-decorated-token-text",
278
+ inputs: [
279
+ "baseText",
280
+ "locations",
281
+ "selectedLocation"
282
+ ]
283
+ },
284
+ {
285
+ kind: "component",
286
+ type: ChronologyFragmentComponent,
287
+ selector: "cadmus-chronology-fragment"
288
+ }
289
+ ],
290
+ changeDetection: i0.ChangeDetectionStrategy.OnPush
291
+ });
292
+ };
293
+ i0.ɵɵngDeclareClassMetadata({
294
+ minVersion: "12.0.0",
295
+ version: "22.2.0",
296
+ ngImport: i0,
297
+ type: ChronologyFragmentFeatureComponent,
298
+ decorators: [{
299
+ type: Component,
300
+ args: [{
301
+ selector: "cadmus-chronology-fragment-feature",
302
+ imports: [
303
+ CurrentItemBarComponent,
304
+ DecoratedTokenTextComponent,
305
+ ChronologyFragmentComponent
306
+ ],
307
+ changeDetection: ChangeDetectionStrategy.OnPush,
308
+ template: "<cadmus-current-item-bar/>\r\n@let loc = frLoc();\r\n<div class=\"base-text\">\r\n <cadmus-decorated-token-text\r\n [baseText]=\"data()?.baseText || ''\"\r\n [locations]=\"loc ? [loc] : []\"\r\n />\r\n</div>\r\n<!-- identity was missing here: ModelEditorComponentBase's modelName() falls\r\n back to the layer part's own name (wrong title) without it -->\r\n<cadmus-chronology-fragment\r\n [identity]=\"identity()\"\r\n [data]=\"$any(data())\"\r\n (dataChange)=\"save($event!.value!)\"\r\n (editorClose)=\"close()\"\r\n (dirtyChange)=\"onDirtyChange($event)\"\r\n/>\r\n"
309
+ }]
310
+ }],
311
+ ctorParameters: () => [
312
+ { type: i1.Router },
313
+ { type: i1.ActivatedRoute },
314
+ { type: i2.MatSnackBar },
315
+ { type: i4$2.FragmentEditorService },
316
+ { type: i4$1.LibraryRouteService }
317
+ ]
318
+ });
319
+ var ChronotopesPartFeatureComponent = class ChronotopesPartFeatureComponent extends EditPartFeatureBase {
320
+ constructor(router, route, snackbar, itemService, thesaurusService, editorService) {
321
+ super(router, route, snackbar, itemService, thesaurusService, editorService);
322
+ this.roleIdInThesauri = true;
323
+ }
324
+ getReqThesauriIds() {
325
+ return [
326
+ "chronotope-place-tags",
327
+ "chronotope-assertion-tags",
328
+ "doc-reference-types",
329
+ "doc-reference-tags"
330
+ ];
331
+ }
332
+ static ɵfac = i0.ɵɵngDeclareFactory({
333
+ minVersion: "12.0.0",
334
+ version: "22.2.0",
335
+ ngImport: i0,
336
+ type: ChronotopesPartFeatureComponent,
337
+ deps: [
338
+ { token: i1.Router },
339
+ { token: i1.ActivatedRoute },
340
+ { token: i2.MatSnackBar },
341
+ { token: i3.ItemService },
342
+ { token: i3.ThesaurusService },
343
+ { token: i4$2.PartEditorService }
344
+ ],
345
+ target: i0.ɵɵFactoryTarget.Component
346
+ });
347
+ static ɵcmp = i0.ɵɵngDeclareComponent({
348
+ minVersion: "14.0.0",
349
+ version: "22.2.0",
350
+ type: ChronotopesPartFeatureComponent,
351
+ isStandalone: true,
352
+ selector: "cadmus-chronotopes-part-feature",
353
+ usesInheritance: true,
354
+ ngImport: i0,
355
+ template: "<cadmus-current-item-bar/>\n<cadmus-chronotopes-part\n [identity]=\"identity()\"\n [data]=\"$any(data())\"\n (dataChange)=\"save($event!.value!)\"\n (editorClose)=\"close()\"\n (dirtyChange)=\"onDirtyChange($event)\"\n/>\n",
356
+ styles: [""],
357
+ dependencies: [{
358
+ kind: "component",
359
+ type: CurrentItemBarComponent,
360
+ selector: "cadmus-current-item-bar"
361
+ }, {
362
+ kind: "component",
363
+ type: ChronotopesPartComponent,
364
+ selector: "cadmus-chronotopes-part"
365
+ }],
366
+ changeDetection: i0.ChangeDetectionStrategy.OnPush
367
+ });
368
+ };
369
+ i0.ɵɵngDeclareClassMetadata({
370
+ minVersion: "12.0.0",
371
+ version: "22.2.0",
372
+ ngImport: i0,
373
+ type: ChronotopesPartFeatureComponent,
374
+ decorators: [{
375
+ type: Component,
376
+ args: [{
377
+ selector: "cadmus-chronotopes-part-feature",
378
+ changeDetection: ChangeDetectionStrategy.OnPush,
379
+ imports: [CurrentItemBarComponent, ChronotopesPartComponent],
380
+ template: "<cadmus-current-item-bar/>\n<cadmus-chronotopes-part\n [identity]=\"identity()\"\n [data]=\"$any(data())\"\n (dataChange)=\"save($event!.value!)\"\n (editorClose)=\"close()\"\n (dirtyChange)=\"onDirtyChange($event)\"\n/>\n"
381
+ }]
382
+ }],
383
+ ctorParameters: () => [
384
+ { type: i1.Router },
385
+ { type: i1.ActivatedRoute },
386
+ { type: i2.MatSnackBar },
387
+ { type: i3.ItemService },
388
+ { type: i3.ThesaurusService },
389
+ { type: i4$2.PartEditorService }
390
+ ]
391
+ });
392
+ var CommentFragmentFeatureComponent = class CommentFragmentFeatureComponent extends EditFragmentFeatureBase {
393
+ constructor(router, route, snackbar, editorService, libraryRouteService) {
394
+ super(router, route, snackbar, editorService, libraryRouteService);
395
+ }
396
+ getReqThesauriIds() {
397
+ return [
398
+ "comment-tags",
399
+ "doc-reference-tags",
400
+ "doc-reference-types",
401
+ "comment-categories",
402
+ "comment-keyword-languages",
403
+ "comment-keyword-indexes",
404
+ "comment-keyword-tags",
405
+ "comment-id-scopes",
406
+ "comment-id-tags",
407
+ "assertion-tags"
408
+ ];
409
+ }
410
+ static ɵfac = i0.ɵɵngDeclareFactory({
411
+ minVersion: "12.0.0",
412
+ version: "22.2.0",
413
+ ngImport: i0,
414
+ type: CommentFragmentFeatureComponent,
415
+ deps: [
416
+ { token: i1.Router },
417
+ { token: i1.ActivatedRoute },
418
+ { token: i2.MatSnackBar },
419
+ { token: i4$2.FragmentEditorService },
420
+ { token: i4$1.LibraryRouteService }
421
+ ],
422
+ target: i0.ɵɵFactoryTarget.Component
423
+ });
424
+ static ɵcmp = i0.ɵɵngDeclareComponent({
425
+ minVersion: "14.0.0",
426
+ version: "22.2.0",
427
+ type: CommentFragmentFeatureComponent,
428
+ isStandalone: true,
429
+ selector: "cadmus-comment-fragment-feature",
430
+ usesInheritance: true,
431
+ ngImport: i0,
432
+ template: "<cadmus-current-item-bar />\r\n@let loc = frLoc();\r\n<div class=\"base-text\">\r\n <cadmus-decorated-token-text\r\n [baseText]=\"data()?.baseText || ''\"\r\n [locations]=\"loc ? [loc] : []\"\r\n />\r\n</div>\r\n<!-- identity was missing here: CommentEditorComponent's initSettings() call\r\n needs it to load lookupProviderOptions settings (else lookups never\r\n get configured) -->\r\n<cadmus-comment-editor\r\n [identity]=\"identity()\"\r\n [data]=\"$any(data())\"\r\n (dataChange)=\"save($any($event!.value!))\"\r\n (editorClose)=\"close()\"\r\n (dirtyChange)=\"onDirtyChange($event)\"\r\n/>\r\n",
433
+ styles: ["div.base-text{margin:12px;border:1px solid #f0f0f0;border-radius:4px;padding:8px}\n"],
434
+ dependencies: [
435
+ {
436
+ kind: "component",
437
+ type: CurrentItemBarComponent,
438
+ selector: "cadmus-current-item-bar"
439
+ },
440
+ {
441
+ kind: "component",
442
+ type: DecoratedTokenTextComponent,
443
+ selector: "cadmus-decorated-token-text",
444
+ inputs: [
445
+ "baseText",
446
+ "locations",
447
+ "selectedLocation"
448
+ ]
449
+ },
450
+ {
451
+ kind: "component",
452
+ type: CommentEditorComponent,
453
+ selector: "cadmus-comment-editor"
454
+ }
455
+ ],
456
+ changeDetection: i0.ChangeDetectionStrategy.OnPush
457
+ });
458
+ };
459
+ i0.ɵɵngDeclareClassMetadata({
460
+ minVersion: "12.0.0",
461
+ version: "22.2.0",
462
+ ngImport: i0,
463
+ type: CommentFragmentFeatureComponent,
464
+ decorators: [{
465
+ type: Component,
466
+ args: [{
467
+ selector: "cadmus-comment-fragment-feature",
468
+ changeDetection: ChangeDetectionStrategy.OnPush,
469
+ imports: [
470
+ CurrentItemBarComponent,
471
+ DecoratedTokenTextComponent,
472
+ CommentEditorComponent
473
+ ],
474
+ template: "<cadmus-current-item-bar />\r\n@let loc = frLoc();\r\n<div class=\"base-text\">\r\n <cadmus-decorated-token-text\r\n [baseText]=\"data()?.baseText || ''\"\r\n [locations]=\"loc ? [loc] : []\"\r\n />\r\n</div>\r\n<!-- identity was missing here: CommentEditorComponent's initSettings() call\r\n needs it to load lookupProviderOptions settings (else lookups never\r\n get configured) -->\r\n<cadmus-comment-editor\r\n [identity]=\"identity()\"\r\n [data]=\"$any(data())\"\r\n (dataChange)=\"save($any($event!.value!))\"\r\n (editorClose)=\"close()\"\r\n (dirtyChange)=\"onDirtyChange($event)\"\r\n/>\r\n",
475
+ styles: ["div.base-text{margin:12px;border:1px solid #f0f0f0;border-radius:4px;padding:8px}\n"]
476
+ }]
477
+ }],
478
+ ctorParameters: () => [
479
+ { type: i1.Router },
480
+ { type: i1.ActivatedRoute },
481
+ { type: i2.MatSnackBar },
482
+ { type: i4$2.FragmentEditorService },
483
+ { type: i4$1.LibraryRouteService }
484
+ ]
485
+ });
486
+ var CommentPartFeatureComponent = class CommentPartFeatureComponent extends EditPartFeatureBase {
487
+ constructor(router, route, snackbar, itemService, thesaurusService, editorService) {
488
+ super(router, route, snackbar, itemService, thesaurusService, editorService);
489
+ this.roleIdInThesauri = true;
490
+ }
491
+ getReqThesauriIds() {
492
+ return [
493
+ "comment-tags",
494
+ "doc-reference-tags",
495
+ "doc-reference-types",
496
+ "comment-categories",
497
+ "comment-keyword-languages",
498
+ "comment-keyword-indexes",
499
+ "comment-keyword-tags",
500
+ "comment-id-scopes",
501
+ "comment-id-tags",
502
+ "assertion-tags",
503
+ "asserted-id-features"
504
+ ];
505
+ }
506
+ static ɵfac = i0.ɵɵngDeclareFactory({
507
+ minVersion: "12.0.0",
508
+ version: "22.2.0",
509
+ ngImport: i0,
510
+ type: CommentPartFeatureComponent,
511
+ deps: [
512
+ { token: i1.Router },
513
+ { token: i1.ActivatedRoute },
514
+ { token: i2.MatSnackBar },
515
+ { token: i3.ItemService },
516
+ { token: i3.ThesaurusService },
517
+ { token: i4$2.PartEditorService }
518
+ ],
519
+ target: i0.ɵɵFactoryTarget.Component
520
+ });
521
+ static ɵcmp = i0.ɵɵngDeclareComponent({
522
+ minVersion: "14.0.0",
523
+ version: "22.2.0",
524
+ type: CommentPartFeatureComponent,
525
+ isStandalone: true,
526
+ selector: "cadmus-comment-part-feature",
527
+ usesInheritance: true,
528
+ ngImport: i0,
529
+ template: "<cadmus-current-item-bar/>\r\n<cadmus-comment-editor\r\n [identity]=\"identity()\"\r\n [data]=\"$any(data())\"\r\n (dataChange)=\"save($any($event!.value!))\"\r\n (editorClose)=\"close()\"\r\n (dirtyChange)=\"onDirtyChange($event)\"\r\n/>\r\n",
530
+ styles: [""],
531
+ dependencies: [{
532
+ kind: "component",
533
+ type: CurrentItemBarComponent,
534
+ selector: "cadmus-current-item-bar"
535
+ }, {
536
+ kind: "component",
537
+ type: CommentEditorComponent,
538
+ selector: "cadmus-comment-editor"
539
+ }],
540
+ changeDetection: i0.ChangeDetectionStrategy.OnPush
541
+ });
542
+ };
543
+ i0.ɵɵngDeclareClassMetadata({
544
+ minVersion: "12.0.0",
545
+ version: "22.2.0",
546
+ ngImport: i0,
547
+ type: CommentPartFeatureComponent,
548
+ decorators: [{
549
+ type: Component,
550
+ args: [{
551
+ selector: "cadmus-comment-part-feature",
552
+ changeDetection: ChangeDetectionStrategy.OnPush,
553
+ imports: [CurrentItemBarComponent, CommentEditorComponent],
554
+ template: "<cadmus-current-item-bar/>\r\n<cadmus-comment-editor\r\n [identity]=\"identity()\"\r\n [data]=\"$any(data())\"\r\n (dataChange)=\"save($any($event!.value!))\"\r\n (editorClose)=\"close()\"\r\n (dirtyChange)=\"onDirtyChange($event)\"\r\n/>\r\n"
555
+ }]
556
+ }],
557
+ ctorParameters: () => [
558
+ { type: i1.Router },
559
+ { type: i1.ActivatedRoute },
560
+ { type: i2.MatSnackBar },
561
+ { type: i3.ItemService },
562
+ { type: i3.ThesaurusService },
563
+ { type: i4$2.PartEditorService }
564
+ ]
565
+ });
566
+ var DecoratedCountsPartFeatureComponent = class DecoratedCountsPartFeatureComponent extends EditPartFeatureBase {
567
+ constructor(router, route, snackbar, itemService, thesaurusService, editorService) {
568
+ super(router, route, snackbar, itemService, thesaurusService, editorService);
569
+ this.roleIdInThesauri = true;
570
+ }
571
+ getReqThesauriIds() {
572
+ return ["decorated-count-ids", "decorated-count-tags"];
573
+ }
574
+ static ɵfac = i0.ɵɵngDeclareFactory({
575
+ minVersion: "12.0.0",
576
+ version: "22.2.0",
577
+ ngImport: i0,
578
+ type: DecoratedCountsPartFeatureComponent,
579
+ deps: [
580
+ { token: i1.Router },
581
+ { token: i1.ActivatedRoute },
582
+ { token: i2.MatSnackBar },
583
+ { token: i3.ItemService },
584
+ { token: i3.ThesaurusService },
585
+ { token: i4$2.PartEditorService }
586
+ ],
587
+ target: i0.ɵɵFactoryTarget.Component
588
+ });
589
+ static ɵcmp = i0.ɵɵngDeclareComponent({
590
+ minVersion: "14.0.0",
591
+ version: "22.2.0",
592
+ type: DecoratedCountsPartFeatureComponent,
593
+ isStandalone: true,
594
+ selector: "cadmus-decorated-counts-part-feature",
595
+ usesInheritance: true,
596
+ ngImport: i0,
597
+ template: "<cadmus-current-item-bar />\r\n<cadmus-decorated-counts-part\r\n [identity]=\"identity()\"\r\n [data]=\"$any(data())\"\r\n (dataChange)=\"save($event!.value!)\"\r\n (editorClose)=\"close()\"\r\n (dirtyChange)=\"onDirtyChange($event)\"\r\n/>\r\n",
598
+ styles: [""],
599
+ dependencies: [{
600
+ kind: "component",
601
+ type: CurrentItemBarComponent,
602
+ selector: "cadmus-current-item-bar"
603
+ }, {
604
+ kind: "component",
605
+ type: DecoratedCountsPartComponent,
606
+ selector: "cadmus-decorated-counts-part"
607
+ }],
608
+ changeDetection: i0.ChangeDetectionStrategy.OnPush
609
+ });
610
+ };
611
+ i0.ɵɵngDeclareClassMetadata({
612
+ minVersion: "12.0.0",
613
+ version: "22.2.0",
614
+ ngImport: i0,
615
+ type: DecoratedCountsPartFeatureComponent,
616
+ decorators: [{
617
+ type: Component,
618
+ args: [{
619
+ selector: "cadmus-decorated-counts-part-feature",
620
+ changeDetection: ChangeDetectionStrategy.OnPush,
621
+ imports: [CurrentItemBarComponent, DecoratedCountsPartComponent],
622
+ template: "<cadmus-current-item-bar />\r\n<cadmus-decorated-counts-part\r\n [identity]=\"identity()\"\r\n [data]=\"$any(data())\"\r\n (dataChange)=\"save($event!.value!)\"\r\n (editorClose)=\"close()\"\r\n (dirtyChange)=\"onDirtyChange($event)\"\r\n/>\r\n"
623
+ }]
624
+ }],
625
+ ctorParameters: () => [
626
+ { type: i1.Router },
627
+ { type: i1.ActivatedRoute },
628
+ { type: i2.MatSnackBar },
629
+ { type: i3.ItemService },
630
+ { type: i3.ThesaurusService },
631
+ { type: i4$2.PartEditorService }
632
+ ]
633
+ });
634
+ var DistrictLocationPartFeatureComponent = class DistrictLocationPartFeatureComponent extends EditPartFeatureBase {
635
+ constructor(router, route, snackbar, itemService, thesaurusService, editorService) {
636
+ super(router, route, snackbar, itemService, thesaurusService, editorService);
637
+ this.roleIdInThesauri = true;
638
+ }
639
+ getReqThesauriIds() {
640
+ return ["district-name-piece-types", "district-name-lang-entries"];
641
+ }
642
+ static ɵfac = i0.ɵɵngDeclareFactory({
643
+ minVersion: "12.0.0",
644
+ version: "22.2.0",
645
+ ngImport: i0,
646
+ type: DistrictLocationPartFeatureComponent,
647
+ deps: [
648
+ { token: i1.Router },
649
+ { token: i1.ActivatedRoute },
650
+ { token: i2.MatSnackBar },
651
+ { token: i3.ItemService },
652
+ { token: i3.ThesaurusService },
653
+ { token: i4$2.PartEditorService }
654
+ ],
655
+ target: i0.ɵɵFactoryTarget.Component
656
+ });
657
+ static ɵcmp = i0.ɵɵngDeclareComponent({
658
+ minVersion: "14.0.0",
659
+ version: "22.2.0",
660
+ type: DistrictLocationPartFeatureComponent,
661
+ isStandalone: true,
662
+ selector: "cadmus-district-location-part-feature",
663
+ usesInheritance: true,
664
+ ngImport: i0,
665
+ template: "<cadmus-current-item-bar/>\r\n<cadmus-district-location-part\r\n [identity]=\"identity()\"\r\n [data]=\"$any(data())\"\r\n (dataChange)=\"save($event!.value!)\"\r\n (editorClose)=\"close()\"\r\n (dirtyChange)=\"onDirtyChange($event)\"\r\n/>\r\n",
666
+ styles: [""],
667
+ dependencies: [{
668
+ kind: "component",
669
+ type: CurrentItemBarComponent,
670
+ selector: "cadmus-current-item-bar"
671
+ }, {
672
+ kind: "component",
673
+ type: DistrictLocationPartComponent,
674
+ selector: "cadmus-district-location-part"
675
+ }],
676
+ changeDetection: i0.ChangeDetectionStrategy.OnPush
677
+ });
678
+ };
679
+ i0.ɵɵngDeclareClassMetadata({
680
+ minVersion: "12.0.0",
681
+ version: "22.2.0",
682
+ ngImport: i0,
683
+ type: DistrictLocationPartFeatureComponent,
684
+ decorators: [{
685
+ type: Component,
686
+ args: [{
687
+ selector: "cadmus-district-location-part-feature",
688
+ changeDetection: ChangeDetectionStrategy.OnPush,
689
+ imports: [CurrentItemBarComponent, DistrictLocationPartComponent],
690
+ template: "<cadmus-current-item-bar/>\r\n<cadmus-district-location-part\r\n [identity]=\"identity()\"\r\n [data]=\"$any(data())\"\r\n (dataChange)=\"save($event!.value!)\"\r\n (editorClose)=\"close()\"\r\n (dirtyChange)=\"onDirtyChange($event)\"\r\n/>\r\n"
691
+ }]
692
+ }],
693
+ ctorParameters: () => [
694
+ { type: i1.Router },
695
+ { type: i1.ActivatedRoute },
696
+ { type: i2.MatSnackBar },
697
+ { type: i3.ItemService },
698
+ { type: i3.ThesaurusService },
699
+ { type: i4$2.PartEditorService }
700
+ ]
701
+ });
702
+ var DocReferencesPartFeatureComponent = class DocReferencesPartFeatureComponent extends EditPartFeatureBase {
703
+ constructor(router, route, snackbar, itemService, thesaurusService, editorService) {
704
+ super(router, route, snackbar, itemService, thesaurusService, editorService);
705
+ this.roleIdInThesauri = true;
706
+ }
707
+ getReqThesauriIds() {
708
+ return ["doc-reference-tags", "doc-reference-types"];
709
+ }
710
+ static ɵfac = i0.ɵɵngDeclareFactory({
711
+ minVersion: "12.0.0",
712
+ version: "22.2.0",
713
+ ngImport: i0,
714
+ type: DocReferencesPartFeatureComponent,
715
+ deps: [
716
+ { token: i1.Router },
717
+ { token: i1.ActivatedRoute },
718
+ { token: i2.MatSnackBar },
719
+ { token: i3.ItemService },
720
+ { token: i3.ThesaurusService },
721
+ { token: i4$2.PartEditorService }
722
+ ],
723
+ target: i0.ɵɵFactoryTarget.Component
724
+ });
725
+ static ɵcmp = i0.ɵɵngDeclareComponent({
726
+ minVersion: "14.0.0",
727
+ version: "22.2.0",
728
+ type: DocReferencesPartFeatureComponent,
729
+ isStandalone: true,
730
+ selector: "cadmus-doc-references-part-feature",
731
+ usesInheritance: true,
732
+ ngImport: i0,
733
+ template: "<cadmus-current-item-bar/>\r\n<cadmus-doc-references-part\r\n [identity]=\"identity()\"\r\n [data]=\"$any(data())\"\r\n (dataChange)=\"save($event!.value!)\"\r\n (editorClose)=\"close()\"\r\n (dirtyChange)=\"onDirtyChange($event)\"\r\n/>\r\n",
734
+ styles: [""],
735
+ dependencies: [{
736
+ kind: "component",
737
+ type: CurrentItemBarComponent,
738
+ selector: "cadmus-current-item-bar"
739
+ }, {
740
+ kind: "component",
741
+ type: DocReferencesPartComponent,
742
+ selector: "cadmus-doc-references-part"
743
+ }],
744
+ changeDetection: i0.ChangeDetectionStrategy.OnPush
745
+ });
746
+ };
747
+ i0.ɵɵngDeclareClassMetadata({
748
+ minVersion: "12.0.0",
749
+ version: "22.2.0",
750
+ ngImport: i0,
751
+ type: DocReferencesPartFeatureComponent,
752
+ decorators: [{
753
+ type: Component,
754
+ args: [{
755
+ selector: "cadmus-doc-references-part-feature",
756
+ changeDetection: ChangeDetectionStrategy.OnPush,
757
+ imports: [CurrentItemBarComponent, DocReferencesPartComponent],
758
+ template: "<cadmus-current-item-bar/>\r\n<cadmus-doc-references-part\r\n [identity]=\"identity()\"\r\n [data]=\"$any(data())\"\r\n (dataChange)=\"save($event!.value!)\"\r\n (editorClose)=\"close()\"\r\n (dirtyChange)=\"onDirtyChange($event)\"\r\n/>\r\n"
759
+ }]
760
+ }],
761
+ ctorParameters: () => [
762
+ { type: i1.Router },
763
+ { type: i1.ActivatedRoute },
764
+ { type: i2.MatSnackBar },
765
+ { type: i3.ItemService },
766
+ { type: i3.ThesaurusService },
767
+ { type: i4$2.PartEditorService }
768
+ ]
769
+ });
770
+ var ExternalIdsPartFeatureComponent = class ExternalIdsPartFeatureComponent extends EditPartFeatureBase {
771
+ constructor(router, route, snackbar, itemService, thesaurusService, editorService) {
772
+ super(router, route, snackbar, itemService, thesaurusService, editorService);
773
+ this.roleIdInThesauri = true;
774
+ }
775
+ getReqThesauriIds() {
776
+ return [
777
+ "external-id-scopes",
778
+ "external-id-tags",
779
+ "assertion-tags",
780
+ "doc-reference-types",
781
+ "doc-reference-tags"
782
+ ];
783
+ }
784
+ static ɵfac = i0.ɵɵngDeclareFactory({
785
+ minVersion: "12.0.0",
786
+ version: "22.2.0",
787
+ ngImport: i0,
788
+ type: ExternalIdsPartFeatureComponent,
789
+ deps: [
790
+ { token: i1.Router },
791
+ { token: i1.ActivatedRoute },
792
+ { token: i2.MatSnackBar },
793
+ { token: i3.ItemService },
794
+ { token: i3.ThesaurusService },
795
+ { token: i4$2.PartEditorService }
796
+ ],
797
+ target: i0.ɵɵFactoryTarget.Component
798
+ });
799
+ static ɵcmp = i0.ɵɵngDeclareComponent({
800
+ minVersion: "14.0.0",
801
+ version: "22.2.0",
802
+ type: ExternalIdsPartFeatureComponent,
803
+ isStandalone: true,
804
+ selector: "cadmus-refs-external-ids-part-feature",
805
+ usesInheritance: true,
806
+ ngImport: i0,
807
+ template: "<cadmus-current-item-bar/>\r\n<cadmus-refs-external-ids-part\r\n [identity]=\"identity()\"\r\n [data]=\"$any(data())\"\r\n (dataChange)=\"save($event!.value!)\"\r\n (editorClose)=\"close()\"\r\n (dirtyChange)=\"onDirtyChange($event)\"\r\n/>\r\n",
808
+ styles: [""],
809
+ dependencies: [{
810
+ kind: "component",
811
+ type: CurrentItemBarComponent,
812
+ selector: "cadmus-current-item-bar"
813
+ }, {
814
+ kind: "component",
815
+ type: ExternalIdsPartComponent,
816
+ selector: "cadmus-refs-external-ids-part"
817
+ }],
818
+ changeDetection: i0.ChangeDetectionStrategy.OnPush
819
+ });
820
+ };
821
+ i0.ɵɵngDeclareClassMetadata({
822
+ minVersion: "12.0.0",
823
+ version: "22.2.0",
824
+ ngImport: i0,
825
+ type: ExternalIdsPartFeatureComponent,
826
+ decorators: [{
827
+ type: Component,
828
+ args: [{
829
+ selector: "cadmus-refs-external-ids-part-feature",
830
+ changeDetection: ChangeDetectionStrategy.OnPush,
831
+ imports: [CurrentItemBarComponent, ExternalIdsPartComponent],
832
+ template: "<cadmus-current-item-bar/>\r\n<cadmus-refs-external-ids-part\r\n [identity]=\"identity()\"\r\n [data]=\"$any(data())\"\r\n (dataChange)=\"save($event!.value!)\"\r\n (editorClose)=\"close()\"\r\n (dirtyChange)=\"onDirtyChange($event)\"\r\n/>\r\n"
833
+ }]
834
+ }],
835
+ ctorParameters: () => [
836
+ { type: i1.Router },
837
+ { type: i1.ActivatedRoute },
838
+ { type: i2.MatSnackBar },
839
+ { type: i3.ItemService },
840
+ { type: i3.ThesaurusService },
841
+ { type: i4$2.PartEditorService }
842
+ ]
843
+ });
844
+ var FlagsPartFeatureComponent = class FlagsPartFeatureComponent extends EditPartFeatureBase {
845
+ constructor(router, route, snackbar, itemService, thesaurusService, editorService) {
846
+ super(router, route, snackbar, itemService, thesaurusService, editorService);
847
+ this.roleIdInThesauri = true;
848
+ }
849
+ getReqThesauriIds() {
850
+ return ["flags"];
851
+ }
852
+ static ɵfac = i0.ɵɵngDeclareFactory({
853
+ minVersion: "12.0.0",
854
+ version: "22.2.0",
855
+ ngImport: i0,
856
+ type: FlagsPartFeatureComponent,
857
+ deps: [
858
+ { token: i1.Router },
859
+ { token: i1.ActivatedRoute },
860
+ { token: i2.MatSnackBar },
861
+ { token: i3.ItemService },
862
+ { token: i3.ThesaurusService },
863
+ { token: i4$2.PartEditorService }
864
+ ],
865
+ target: i0.ɵɵFactoryTarget.Component
866
+ });
867
+ static ɵcmp = i0.ɵɵngDeclareComponent({
868
+ minVersion: "14.0.0",
869
+ version: "22.2.0",
870
+ type: FlagsPartFeatureComponent,
871
+ isStandalone: true,
872
+ selector: "cadmus-flags-part-feature",
873
+ usesInheritance: true,
874
+ ngImport: i0,
875
+ template: "<cadmus-current-item-bar />\r\n<cadmus-flags-part\r\n [identity]=\"identity()\"\r\n [data]=\"$any(data())\"\r\n (dataChange)=\"save($event!.value!)\"\r\n (editorClose)=\"close()\"\r\n (dirtyChange)=\"onDirtyChange($event)\"\r\n/>\r\n",
876
+ styles: [""],
877
+ dependencies: [{
878
+ kind: "component",
879
+ type: CurrentItemBarComponent,
880
+ selector: "cadmus-current-item-bar"
881
+ }, {
882
+ kind: "component",
883
+ type: FlagsPartComponent,
884
+ selector: "cadmus-flags-part"
885
+ }],
886
+ changeDetection: i0.ChangeDetectionStrategy.OnPush
887
+ });
888
+ };
889
+ i0.ɵɵngDeclareClassMetadata({
890
+ minVersion: "12.0.0",
891
+ version: "22.2.0",
892
+ ngImport: i0,
893
+ type: FlagsPartFeatureComponent,
894
+ decorators: [{
895
+ type: Component,
896
+ args: [{
897
+ selector: "cadmus-flags-part-feature",
898
+ imports: [CurrentItemBarComponent, FlagsPartComponent],
899
+ changeDetection: ChangeDetectionStrategy.OnPush,
900
+ template: "<cadmus-current-item-bar />\r\n<cadmus-flags-part\r\n [identity]=\"identity()\"\r\n [data]=\"$any(data())\"\r\n (dataChange)=\"save($event!.value!)\"\r\n (editorClose)=\"close()\"\r\n (dirtyChange)=\"onDirtyChange($event)\"\r\n/>\r\n"
901
+ }]
902
+ }],
903
+ ctorParameters: () => [
904
+ { type: i1.Router },
905
+ { type: i1.ActivatedRoute },
906
+ { type: i2.MatSnackBar },
907
+ { type: i3.ItemService },
908
+ { type: i3.ThesaurusService },
909
+ { type: i4$2.PartEditorService }
910
+ ]
911
+ });
912
+ var HistoricalDatePartFeatureComponent = class HistoricalDatePartFeatureComponent extends EditPartFeatureBase {
913
+ constructor(router, route, snackbar, itemService, thesaurusService, editorService) {
914
+ super(router, route, snackbar, itemService, thesaurusService, editorService);
915
+ this.roleIdInThesauri = true;
916
+ }
917
+ getReqThesauriIds() {
918
+ return ["doc-reference-tags", "doc-reference-types"];
919
+ }
920
+ static ɵfac = i0.ɵɵngDeclareFactory({
921
+ minVersion: "12.0.0",
922
+ version: "22.2.0",
923
+ ngImport: i0,
924
+ type: HistoricalDatePartFeatureComponent,
925
+ deps: [
926
+ { token: i1.Router },
927
+ { token: i1.ActivatedRoute },
928
+ { token: i2.MatSnackBar },
929
+ { token: i3.ItemService },
930
+ { token: i3.ThesaurusService },
931
+ { token: i4$2.PartEditorService }
932
+ ],
933
+ target: i0.ɵɵFactoryTarget.Component
934
+ });
935
+ static ɵcmp = i0.ɵɵngDeclareComponent({
936
+ minVersion: "14.0.0",
937
+ version: "22.2.0",
938
+ type: HistoricalDatePartFeatureComponent,
939
+ isStandalone: true,
940
+ selector: "cadmus-historical-date-part-feature",
941
+ usesInheritance: true,
942
+ ngImport: i0,
943
+ template: "<cadmus-current-item-bar/>\r\n<cadmus-historical-date-part\r\n [identity]=\"identity()\"\r\n [data]=\"$any(data())\"\r\n (dataChange)=\"save($event!.value!)\"\r\n (editorClose)=\"close()\"\r\n (dirtyChange)=\"onDirtyChange($event)\"\r\n/>\r\n",
944
+ styles: [""],
945
+ dependencies: [{
946
+ kind: "component",
947
+ type: CurrentItemBarComponent,
948
+ selector: "cadmus-current-item-bar"
949
+ }, {
950
+ kind: "component",
951
+ type: HistoricalDatePartComponent,
952
+ selector: "cadmus-historical-date-part"
953
+ }],
954
+ changeDetection: i0.ChangeDetectionStrategy.OnPush
955
+ });
956
+ };
957
+ i0.ɵɵngDeclareClassMetadata({
958
+ minVersion: "12.0.0",
959
+ version: "22.2.0",
960
+ ngImport: i0,
961
+ type: HistoricalDatePartFeatureComponent,
962
+ decorators: [{
963
+ type: Component,
964
+ args: [{
965
+ selector: "cadmus-historical-date-part-feature",
966
+ changeDetection: ChangeDetectionStrategy.OnPush,
967
+ imports: [CurrentItemBarComponent, HistoricalDatePartComponent],
968
+ template: "<cadmus-current-item-bar/>\r\n<cadmus-historical-date-part\r\n [identity]=\"identity()\"\r\n [data]=\"$any(data())\"\r\n (dataChange)=\"save($event!.value!)\"\r\n (editorClose)=\"close()\"\r\n (dirtyChange)=\"onDirtyChange($event)\"\r\n/>\r\n"
969
+ }]
970
+ }],
971
+ ctorParameters: () => [
972
+ { type: i1.Router },
973
+ { type: i1.ActivatedRoute },
974
+ { type: i2.MatSnackBar },
975
+ { type: i3.ItemService },
976
+ { type: i3.ThesaurusService },
977
+ { type: i4$2.PartEditorService }
978
+ ]
979
+ });
980
+ var HistoricalEventsPartFeatureComponent = class HistoricalEventsPartFeatureComponent extends EditPartFeatureBase {
981
+ constructor(router, route, snackbar, itemService, thesaurusService, editorService) {
982
+ super(router, route, snackbar, itemService, thesaurusService, editorService);
983
+ this.roleIdInThesauri = true;
984
+ }
985
+ getReqThesauriIds() {
986
+ return [
987
+ "event-types",
988
+ "event-tags",
989
+ "event-relations",
990
+ "chronotope-tags",
991
+ "asserted-id-scopes",
992
+ "asserted-id-tags",
993
+ "assertion-tags",
994
+ "doc-reference-tags",
995
+ "doc-reference-types",
996
+ "pin-link-scopes",
997
+ "pin-link-tags",
998
+ "asserted-id-features"
999
+ ];
1000
+ }
1001
+ static ɵfac = i0.ɵɵngDeclareFactory({
1002
+ minVersion: "12.0.0",
1003
+ version: "22.2.0",
1004
+ ngImport: i0,
1005
+ type: HistoricalEventsPartFeatureComponent,
1006
+ deps: [
1007
+ { token: i1.Router },
1008
+ { token: i1.ActivatedRoute },
1009
+ { token: i2.MatSnackBar },
1010
+ { token: i3.ItemService },
1011
+ { token: i3.ThesaurusService },
1012
+ { token: i4$2.PartEditorService }
1013
+ ],
1014
+ target: i0.ɵɵFactoryTarget.Component
1015
+ });
1016
+ static ɵcmp = i0.ɵɵngDeclareComponent({
1017
+ minVersion: "14.0.0",
1018
+ version: "22.2.0",
1019
+ type: HistoricalEventsPartFeatureComponent,
1020
+ isStandalone: true,
1021
+ selector: "cadmus-historical-events-part-feature",
1022
+ usesInheritance: true,
1023
+ ngImport: i0,
1024
+ template: "<cadmus-current-item-bar/>\n<cadmus-historical-events-part\n [identity]=\"identity()\"\n [data]=\"$any(data())\"\n (dataChange)=\"save($event!.value!)\"\n (editorClose)=\"close()\"\n (dirtyChange)=\"onDirtyChange($event)\"\n/>\n",
1025
+ styles: [""],
1026
+ dependencies: [{
1027
+ kind: "component",
1028
+ type: CurrentItemBarComponent,
1029
+ selector: "cadmus-current-item-bar"
1030
+ }, {
1031
+ kind: "component",
1032
+ type: HistoricalEventsPartComponent,
1033
+ selector: "cadmus-historical-events-part"
1034
+ }],
1035
+ changeDetection: i0.ChangeDetectionStrategy.OnPush
1036
+ });
1037
+ };
1038
+ i0.ɵɵngDeclareClassMetadata({
1039
+ minVersion: "12.0.0",
1040
+ version: "22.2.0",
1041
+ ngImport: i0,
1042
+ type: HistoricalEventsPartFeatureComponent,
1043
+ decorators: [{
1044
+ type: Component,
1045
+ args: [{
1046
+ selector: "cadmus-historical-events-part-feature",
1047
+ changeDetection: ChangeDetectionStrategy.OnPush,
1048
+ imports: [CurrentItemBarComponent, HistoricalEventsPartComponent],
1049
+ template: "<cadmus-current-item-bar/>\n<cadmus-historical-events-part\n [identity]=\"identity()\"\n [data]=\"$any(data())\"\n (dataChange)=\"save($event!.value!)\"\n (editorClose)=\"close()\"\n (dirtyChange)=\"onDirtyChange($event)\"\n/>\n"
1050
+ }]
1051
+ }],
1052
+ ctorParameters: () => [
1053
+ { type: i1.Router },
1054
+ { type: i1.ActivatedRoute },
1055
+ { type: i2.MatSnackBar },
1056
+ { type: i3.ItemService },
1057
+ { type: i3.ThesaurusService },
1058
+ { type: i4$2.PartEditorService }
1059
+ ]
1060
+ });
1061
+ var IndexKeywordsPartFeatureComponent = class IndexKeywordsPartFeatureComponent extends EditPartFeatureBase {
1062
+ constructor(router, route, snackbar, itemService, thesaurusService, editorService) {
1063
+ super(router, route, snackbar, itemService, thesaurusService, editorService);
1064
+ this.roleIdInThesauri = true;
1065
+ }
1066
+ getReqThesauriIds() {
1067
+ return [
1068
+ "languages",
1069
+ "keyword-indexes",
1070
+ "keyword-tags"
1071
+ ];
1072
+ }
1073
+ static ɵfac = i0.ɵɵngDeclareFactory({
1074
+ minVersion: "12.0.0",
1075
+ version: "22.2.0",
1076
+ ngImport: i0,
1077
+ type: IndexKeywordsPartFeatureComponent,
1078
+ deps: [
1079
+ { token: i1.Router },
1080
+ { token: i1.ActivatedRoute },
1081
+ { token: i2.MatSnackBar },
1082
+ { token: i3.ItemService },
1083
+ { token: i3.ThesaurusService },
1084
+ { token: i4$2.PartEditorService }
1085
+ ],
1086
+ target: i0.ɵɵFactoryTarget.Component
1087
+ });
1088
+ static ɵcmp = i0.ɵɵngDeclareComponent({
1089
+ minVersion: "14.0.0",
1090
+ version: "22.2.0",
1091
+ type: IndexKeywordsPartFeatureComponent,
1092
+ isStandalone: true,
1093
+ selector: "cadmus-index-keywords-part-feature",
1094
+ usesInheritance: true,
1095
+ ngImport: i0,
1096
+ template: "<cadmus-current-item-bar/>\r\n<cadmus-index-keywords-part\r\n [identity]=\"identity()\"\r\n [data]=\"$any(data())\"\r\n (dataChange)=\"save($event!.value!)\"\r\n (editorClose)=\"close()\"\r\n (dirtyChange)=\"onDirtyChange($event)\"\r\n/>\r\n",
1097
+ styles: [""],
1098
+ dependencies: [{
1099
+ kind: "component",
1100
+ type: CurrentItemBarComponent,
1101
+ selector: "cadmus-current-item-bar"
1102
+ }, {
1103
+ kind: "component",
1104
+ type: IndexKeywordsPartComponent,
1105
+ selector: "cadmus-index-keywords-part"
1106
+ }],
1107
+ changeDetection: i0.ChangeDetectionStrategy.OnPush
1108
+ });
1109
+ };
1110
+ i0.ɵɵngDeclareClassMetadata({
1111
+ minVersion: "12.0.0",
1112
+ version: "22.2.0",
1113
+ ngImport: i0,
1114
+ type: IndexKeywordsPartFeatureComponent,
1115
+ decorators: [{
1116
+ type: Component,
1117
+ args: [{
1118
+ selector: "cadmus-index-keywords-part-feature",
1119
+ changeDetection: ChangeDetectionStrategy.OnPush,
1120
+ imports: [CurrentItemBarComponent, IndexKeywordsPartComponent],
1121
+ template: "<cadmus-current-item-bar/>\r\n<cadmus-index-keywords-part\r\n [identity]=\"identity()\"\r\n [data]=\"$any(data())\"\r\n (dataChange)=\"save($event!.value!)\"\r\n (editorClose)=\"close()\"\r\n (dirtyChange)=\"onDirtyChange($event)\"\r\n/>\r\n"
1122
+ }]
1123
+ }],
1124
+ ctorParameters: () => [
1125
+ { type: i1.Router },
1126
+ { type: i1.ActivatedRoute },
1127
+ { type: i2.MatSnackBar },
1128
+ { type: i3.ItemService },
1129
+ { type: i3.ThesaurusService },
1130
+ { type: i4$2.PartEditorService }
1131
+ ]
1132
+ });
1133
+ var KeywordsPartFeatureComponent = class KeywordsPartFeatureComponent extends EditPartFeatureBase {
1134
+ constructor(router, route, snackbar, itemService, thesaurusService, editorService) {
1135
+ super(router, route, snackbar, itemService, thesaurusService, editorService);
1136
+ this.roleIdInThesauri = true;
1137
+ }
1138
+ getReqThesauriIds() {
1139
+ return ["languages"];
1140
+ }
1141
+ static ɵfac = i0.ɵɵngDeclareFactory({
1142
+ minVersion: "12.0.0",
1143
+ version: "22.2.0",
1144
+ ngImport: i0,
1145
+ type: KeywordsPartFeatureComponent,
1146
+ deps: [
1147
+ { token: i1.Router },
1148
+ { token: i1.ActivatedRoute },
1149
+ { token: i2.MatSnackBar },
1150
+ { token: i3.ItemService },
1151
+ { token: i3.ThesaurusService },
1152
+ { token: i4$2.PartEditorService }
1153
+ ],
1154
+ target: i0.ɵɵFactoryTarget.Component
1155
+ });
1156
+ static ɵcmp = i0.ɵɵngDeclareComponent({
1157
+ minVersion: "14.0.0",
1158
+ version: "22.2.0",
1159
+ type: KeywordsPartFeatureComponent,
1160
+ isStandalone: true,
1161
+ selector: "cadmus-keywords-part-feature",
1162
+ usesInheritance: true,
1163
+ ngImport: i0,
1164
+ template: "<cadmus-current-item-bar/>\r\n<cadmus-keywords-part\r\n [identity]=\"identity()\"\r\n [data]=\"$any(data())\"\r\n (dataChange)=\"save($event!.value!)\"\r\n (editorClose)=\"close()\"\r\n (dirtyChange)=\"onDirtyChange($event)\"\r\n/>\r\n",
1165
+ styles: [""],
1166
+ dependencies: [{
1167
+ kind: "component",
1168
+ type: CurrentItemBarComponent,
1169
+ selector: "cadmus-current-item-bar"
1170
+ }, {
1171
+ kind: "component",
1172
+ type: KeywordsPartComponent,
1173
+ selector: "cadmus-keywords-part"
1174
+ }],
1175
+ changeDetection: i0.ChangeDetectionStrategy.OnPush
1176
+ });
1177
+ };
1178
+ i0.ɵɵngDeclareClassMetadata({
1179
+ minVersion: "12.0.0",
1180
+ version: "22.2.0",
1181
+ ngImport: i0,
1182
+ type: KeywordsPartFeatureComponent,
1183
+ decorators: [{
1184
+ type: Component,
1185
+ args: [{
1186
+ selector: "cadmus-keywords-part-feature",
1187
+ changeDetection: ChangeDetectionStrategy.OnPush,
1188
+ imports: [CurrentItemBarComponent, KeywordsPartComponent],
1189
+ template: "<cadmus-current-item-bar/>\r\n<cadmus-keywords-part\r\n [identity]=\"identity()\"\r\n [data]=\"$any(data())\"\r\n (dataChange)=\"save($event!.value!)\"\r\n (editorClose)=\"close()\"\r\n (dirtyChange)=\"onDirtyChange($event)\"\r\n/>\r\n"
1190
+ }]
1191
+ }],
1192
+ ctorParameters: () => [
1193
+ { type: i1.Router },
1194
+ { type: i1.ActivatedRoute },
1195
+ { type: i2.MatSnackBar },
1196
+ { type: i3.ItemService },
1197
+ { type: i3.ThesaurusService },
1198
+ { type: i4$2.PartEditorService }
1199
+ ]
1200
+ });
1201
+ var MetadataPartFeatureComponent = class MetadataPartFeatureComponent extends EditPartFeatureBase {
1202
+ constructor(router, route, snackbar, itemService, thesaurusService, editorService) {
1203
+ super(router, route, snackbar, itemService, thesaurusService, editorService);
1204
+ }
1205
+ getReqThesauriIds() {
1206
+ return ["metadata-types", "metadata-names"];
1207
+ }
1208
+ static ɵfac = i0.ɵɵngDeclareFactory({
1209
+ minVersion: "12.0.0",
1210
+ version: "22.2.0",
1211
+ ngImport: i0,
1212
+ type: MetadataPartFeatureComponent,
1213
+ deps: [
1214
+ { token: i1.Router },
1215
+ { token: i1.ActivatedRoute },
1216
+ { token: i2.MatSnackBar },
1217
+ { token: i3.ItemService },
1218
+ { token: i3.ThesaurusService },
1219
+ { token: i4$2.PartEditorService }
1220
+ ],
1221
+ target: i0.ɵɵFactoryTarget.Component
1222
+ });
1223
+ static ɵcmp = i0.ɵɵngDeclareComponent({
1224
+ minVersion: "14.0.0",
1225
+ version: "22.2.0",
1226
+ type: MetadataPartFeatureComponent,
1227
+ isStandalone: true,
1228
+ selector: "cadmus-metadata-part-feature",
1229
+ usesInheritance: true,
1230
+ ngImport: i0,
1231
+ template: "<cadmus-current-item-bar/>\n<cadmus-metadata-part\n [identity]=\"identity()\"\n [data]=\"$any(data())\"\n (dataChange)=\"save($event!.value!)\"\n (editorClose)=\"close()\"\n (dirtyChange)=\"onDirtyChange($event)\"\n/>\n",
1232
+ styles: [""],
1233
+ dependencies: [{
1234
+ kind: "component",
1235
+ type: CurrentItemBarComponent,
1236
+ selector: "cadmus-current-item-bar"
1237
+ }, {
1238
+ kind: "component",
1239
+ type: MetadataPartComponent,
1240
+ selector: "cadmus-metadata-part"
1241
+ }],
1242
+ changeDetection: i0.ChangeDetectionStrategy.OnPush
1243
+ });
1244
+ };
1245
+ i0.ɵɵngDeclareClassMetadata({
1246
+ minVersion: "12.0.0",
1247
+ version: "22.2.0",
1248
+ ngImport: i0,
1249
+ type: MetadataPartFeatureComponent,
1250
+ decorators: [{
1251
+ type: Component,
1252
+ args: [{
1253
+ selector: "cadmus-metadata-part-feature",
1254
+ changeDetection: ChangeDetectionStrategy.OnPush,
1255
+ imports: [CurrentItemBarComponent, MetadataPartComponent],
1256
+ template: "<cadmus-current-item-bar/>\n<cadmus-metadata-part\n [identity]=\"identity()\"\n [data]=\"$any(data())\"\n (dataChange)=\"save($event!.value!)\"\n (editorClose)=\"close()\"\n (dirtyChange)=\"onDirtyChange($event)\"\n/>\n"
1257
+ }]
1258
+ }],
1259
+ ctorParameters: () => [
1260
+ { type: i1.Router },
1261
+ { type: i1.ActivatedRoute },
1262
+ { type: i2.MatSnackBar },
1263
+ { type: i3.ItemService },
1264
+ { type: i3.ThesaurusService },
1265
+ { type: i4$2.PartEditorService }
1266
+ ]
1267
+ });
1268
+ var NamesPartFeatureComponent = class NamesPartFeatureComponent extends EditPartFeatureBase {
1269
+ constructor(router, route, snackbar, itemService, thesaurusService, editorService) {
1270
+ super(router, route, snackbar, itemService, thesaurusService, editorService);
1271
+ this.roleIdInThesauri = true;
1272
+ }
1273
+ getReqThesauriIds() {
1274
+ return [
1275
+ "name-languages",
1276
+ "name-tags",
1277
+ "name-piece-types",
1278
+ "assertion-tags",
1279
+ "doc-reference-types",
1280
+ "doc-reference-tags"
1281
+ ];
1282
+ }
1283
+ static ɵfac = i0.ɵɵngDeclareFactory({
1284
+ minVersion: "12.0.0",
1285
+ version: "22.2.0",
1286
+ ngImport: i0,
1287
+ type: NamesPartFeatureComponent,
1288
+ deps: [
1289
+ { token: i1.Router },
1290
+ { token: i1.ActivatedRoute },
1291
+ { token: i2.MatSnackBar },
1292
+ { token: i3.ItemService },
1293
+ { token: i3.ThesaurusService },
1294
+ { token: i4$2.PartEditorService }
1295
+ ],
1296
+ target: i0.ɵɵFactoryTarget.Component
1297
+ });
1298
+ static ɵcmp = i0.ɵɵngDeclareComponent({
1299
+ minVersion: "14.0.0",
1300
+ version: "22.2.0",
1301
+ type: NamesPartFeatureComponent,
1302
+ isStandalone: true,
1303
+ selector: "cadmus-names-part-feature",
1304
+ usesInheritance: true,
1305
+ ngImport: i0,
1306
+ template: "<cadmus-current-item-bar/>\n<cadmus-names-part\n [identity]=\"identity()\"\n [data]=\"$any(data())\"\n (dataChange)=\"save($event!.value!)\"\n (editorClose)=\"close()\"\n (dirtyChange)=\"onDirtyChange($event)\"\n/>\n",
1307
+ styles: [""],
1308
+ dependencies: [{
1309
+ kind: "component",
1310
+ type: CurrentItemBarComponent,
1311
+ selector: "cadmus-current-item-bar"
1312
+ }, {
1313
+ kind: "component",
1314
+ type: NamesPartComponent,
1315
+ selector: "cadmus-names-part"
1316
+ }],
1317
+ changeDetection: i0.ChangeDetectionStrategy.OnPush
1318
+ });
1319
+ };
1320
+ i0.ɵɵngDeclareClassMetadata({
1321
+ minVersion: "12.0.0",
1322
+ version: "22.2.0",
1323
+ ngImport: i0,
1324
+ type: NamesPartFeatureComponent,
1325
+ decorators: [{
1326
+ type: Component,
1327
+ args: [{
1328
+ selector: "cadmus-names-part-feature",
1329
+ changeDetection: ChangeDetectionStrategy.OnPush,
1330
+ imports: [CurrentItemBarComponent, NamesPartComponent],
1331
+ template: "<cadmus-current-item-bar/>\n<cadmus-names-part\n [identity]=\"identity()\"\n [data]=\"$any(data())\"\n (dataChange)=\"save($event!.value!)\"\n (editorClose)=\"close()\"\n (dirtyChange)=\"onDirtyChange($event)\"\n/>\n"
1332
+ }]
1333
+ }],
1334
+ ctorParameters: () => [
1335
+ { type: i1.Router },
1336
+ { type: i1.ActivatedRoute },
1337
+ { type: i2.MatSnackBar },
1338
+ { type: i3.ItemService },
1339
+ { type: i3.ThesaurusService },
1340
+ { type: i4$2.PartEditorService }
1341
+ ]
1342
+ });
1343
+ var NotePartFeatureComponent = class NotePartFeatureComponent extends EditPartFeatureBase {
1344
+ constructor(router, route, snackbar, itemService, thesaurusService, editorService) {
1345
+ super(router, route, snackbar, itemService, thesaurusService, editorService);
1346
+ this.roleIdInThesauri = true;
1347
+ }
1348
+ getReqThesauriIds() {
1349
+ return ["note-tags"];
1350
+ }
1351
+ static ɵfac = i0.ɵɵngDeclareFactory({
1352
+ minVersion: "12.0.0",
1353
+ version: "22.2.0",
1354
+ ngImport: i0,
1355
+ type: NotePartFeatureComponent,
1356
+ deps: [
1357
+ { token: i1.Router },
1358
+ { token: i1.ActivatedRoute },
1359
+ { token: i2.MatSnackBar },
1360
+ { token: i3.ItemService },
1361
+ { token: i3.ThesaurusService },
1362
+ { token: i4$2.PartEditorService }
1363
+ ],
1364
+ target: i0.ɵɵFactoryTarget.Component
1365
+ });
1366
+ static ɵcmp = i0.ɵɵngDeclareComponent({
1367
+ minVersion: "14.0.0",
1368
+ version: "22.2.0",
1369
+ type: NotePartFeatureComponent,
1370
+ isStandalone: true,
1371
+ selector: "cadmus-note-part-feature",
1372
+ usesInheritance: true,
1373
+ ngImport: i0,
1374
+ template: "<cadmus-current-item-bar/>\r\n<cadmus-note-part\r\n [identity]=\"identity()\"\r\n [data]=\"$any(data())\"\r\n (dataChange)=\"save($event!.value!)\"\r\n (editorClose)=\"close()\"\r\n (dirtyChange)=\"onDirtyChange($event)\"\r\n/>\r\n",
1375
+ styles: [""],
1376
+ dependencies: [{
1377
+ kind: "component",
1378
+ type: CurrentItemBarComponent,
1379
+ selector: "cadmus-current-item-bar"
1380
+ }, {
1381
+ kind: "component",
1382
+ type: NotePartComponent,
1383
+ selector: "cadmus-note-part"
1384
+ }],
1385
+ changeDetection: i0.ChangeDetectionStrategy.OnPush
1386
+ });
1387
+ };
1388
+ i0.ɵɵngDeclareClassMetadata({
1389
+ minVersion: "12.0.0",
1390
+ version: "22.2.0",
1391
+ ngImport: i0,
1392
+ type: NotePartFeatureComponent,
1393
+ decorators: [{
1394
+ type: Component,
1395
+ args: [{
1396
+ selector: "cadmus-note-part-feature",
1397
+ changeDetection: ChangeDetectionStrategy.OnPush,
1398
+ imports: [CurrentItemBarComponent, NotePartComponent],
1399
+ template: "<cadmus-current-item-bar/>\r\n<cadmus-note-part\r\n [identity]=\"identity()\"\r\n [data]=\"$any(data())\"\r\n (dataChange)=\"save($event!.value!)\"\r\n (editorClose)=\"close()\"\r\n (dirtyChange)=\"onDirtyChange($event)\"\r\n/>\r\n"
1400
+ }]
1401
+ }],
1402
+ ctorParameters: () => [
1403
+ { type: i1.Router },
1404
+ { type: i1.ActivatedRoute },
1405
+ { type: i2.MatSnackBar },
1406
+ { type: i3.ItemService },
1407
+ { type: i3.ThesaurusService },
1408
+ { type: i4$2.PartEditorService }
1409
+ ]
1410
+ });
1411
+ var PhysicalMeasurementsPartFeatureComponent = class PhysicalMeasurementsPartFeatureComponent extends EditPartFeatureBase {
1412
+ constructor(router, route, snackbar, itemService, thesaurusService, editorService) {
1413
+ super(router, route, snackbar, itemService, thesaurusService, editorService);
1414
+ this.roleIdInThesauri = true;
1415
+ }
1416
+ getReqThesauriIds() {
1417
+ return [
1418
+ "physical-size-units",
1419
+ "physical-size-dim-tags",
1420
+ "physical-size-set-names"
1421
+ ];
1422
+ }
1423
+ static ɵfac = i0.ɵɵngDeclareFactory({
1424
+ minVersion: "12.0.0",
1425
+ version: "22.2.0",
1426
+ ngImport: i0,
1427
+ type: PhysicalMeasurementsPartFeatureComponent,
1428
+ deps: [
1429
+ { token: i1.Router },
1430
+ { token: i1.ActivatedRoute },
1431
+ { token: i2.MatSnackBar },
1432
+ { token: i3.ItemService },
1433
+ { token: i3.ThesaurusService },
1434
+ { token: i4$2.PartEditorService }
1435
+ ],
1436
+ target: i0.ɵɵFactoryTarget.Component
1437
+ });
1438
+ static ɵcmp = i0.ɵɵngDeclareComponent({
1439
+ minVersion: "14.0.0",
1440
+ version: "22.2.0",
1441
+ type: PhysicalMeasurementsPartFeatureComponent,
1442
+ isStandalone: true,
1443
+ selector: "cadmus-physical-measurements-part-feature",
1444
+ usesInheritance: true,
1445
+ ngImport: i0,
1446
+ template: "<cadmus-current-item-bar/>\r\n<cadmus-physical-measurements-part\r\n [identity]=\"identity()\"\r\n [data]=\"$any(data())\"\r\n (dataChange)=\"save($event!.value!)\"\r\n (editorClose)=\"close()\"\r\n (dirtyChange)=\"onDirtyChange($event)\"\r\n/>\r\n",
1447
+ styles: [""],
1448
+ dependencies: [{
1449
+ kind: "component",
1450
+ type: CurrentItemBarComponent,
1451
+ selector: "cadmus-current-item-bar"
1452
+ }, {
1453
+ kind: "component",
1454
+ type: PhysicalMeasurementsPartComponent,
1455
+ selector: "cadmus-physical-measurements-part"
1456
+ }],
1457
+ changeDetection: i0.ChangeDetectionStrategy.OnPush
1458
+ });
1459
+ };
1460
+ i0.ɵɵngDeclareClassMetadata({
1461
+ minVersion: "12.0.0",
1462
+ version: "22.2.0",
1463
+ ngImport: i0,
1464
+ type: PhysicalMeasurementsPartFeatureComponent,
1465
+ decorators: [{
1466
+ type: Component,
1467
+ args: [{
1468
+ selector: "cadmus-physical-measurements-part-feature",
1469
+ changeDetection: ChangeDetectionStrategy.OnPush,
1470
+ imports: [CurrentItemBarComponent, PhysicalMeasurementsPartComponent],
1471
+ template: "<cadmus-current-item-bar/>\r\n<cadmus-physical-measurements-part\r\n [identity]=\"identity()\"\r\n [data]=\"$any(data())\"\r\n (dataChange)=\"save($event!.value!)\"\r\n (editorClose)=\"close()\"\r\n (dirtyChange)=\"onDirtyChange($event)\"\r\n/>\r\n"
1472
+ }]
1473
+ }],
1474
+ ctorParameters: () => [
1475
+ { type: i1.Router },
1476
+ { type: i1.ActivatedRoute },
1477
+ { type: i2.MatSnackBar },
1478
+ { type: i3.ItemService },
1479
+ { type: i3.ThesaurusService },
1480
+ { type: i4$2.PartEditorService }
1481
+ ]
1482
+ });
1483
+ var PhysicalStatesPartFeatureComponent = class PhysicalStatesPartFeatureComponent extends EditPartFeatureBase {
1484
+ constructor(router, route, snackbar, itemService, thesaurusService, editorService) {
1485
+ super(router, route, snackbar, itemService, thesaurusService, editorService);
1486
+ }
1487
+ getReqThesauriIds() {
1488
+ return [
1489
+ "physical-states",
1490
+ "physical-state-features",
1491
+ "physical-state-reporters"
1492
+ ];
1493
+ }
1494
+ static ɵfac = i0.ɵɵngDeclareFactory({
1495
+ minVersion: "12.0.0",
1496
+ version: "22.2.0",
1497
+ ngImport: i0,
1498
+ type: PhysicalStatesPartFeatureComponent,
1499
+ deps: [
1500
+ { token: i1.Router },
1501
+ { token: i1.ActivatedRoute },
1502
+ { token: i2.MatSnackBar },
1503
+ { token: i3.ItemService },
1504
+ { token: i3.ThesaurusService },
1505
+ { token: i4$2.PartEditorService }
1506
+ ],
1507
+ target: i0.ɵɵFactoryTarget.Component
1508
+ });
1509
+ static ɵcmp = i0.ɵɵngDeclareComponent({
1510
+ minVersion: "14.0.0",
1511
+ version: "22.2.0",
1512
+ type: PhysicalStatesPartFeatureComponent,
1513
+ isStandalone: true,
1514
+ selector: "cadmus-physical-states-part-feature",
1515
+ usesInheritance: true,
1516
+ ngImport: i0,
1517
+ template: "<cadmus-current-item-bar/>\r\n<cadmus-physical-states-part\r\n [identity]=\"identity()\"\r\n [data]=\"$any(data())\"\r\n (dataChange)=\"save($event!.value!)\"\r\n (editorClose)=\"close()\"\r\n (dirtyChange)=\"onDirtyChange($event)\"\r\n/>\r\n",
1518
+ styles: [""],
1519
+ dependencies: [{
1520
+ kind: "component",
1521
+ type: CurrentItemBarComponent,
1522
+ selector: "cadmus-current-item-bar"
1523
+ }, {
1524
+ kind: "component",
1525
+ type: PhysicalStatesPartComponent,
1526
+ selector: "cadmus-physical-states-part"
1527
+ }],
1528
+ changeDetection: i0.ChangeDetectionStrategy.OnPush
1529
+ });
1530
+ };
1531
+ i0.ɵɵngDeclareClassMetadata({
1532
+ minVersion: "12.0.0",
1533
+ version: "22.2.0",
1534
+ ngImport: i0,
1535
+ type: PhysicalStatesPartFeatureComponent,
1536
+ decorators: [{
1537
+ type: Component,
1538
+ args: [{
1539
+ selector: "cadmus-physical-states-part-feature",
1540
+ changeDetection: ChangeDetectionStrategy.OnPush,
1541
+ imports: [CurrentItemBarComponent, PhysicalStatesPartComponent],
1542
+ template: "<cadmus-current-item-bar/>\r\n<cadmus-physical-states-part\r\n [identity]=\"identity()\"\r\n [data]=\"$any(data())\"\r\n (dataChange)=\"save($event!.value!)\"\r\n (editorClose)=\"close()\"\r\n (dirtyChange)=\"onDirtyChange($event)\"\r\n/>\r\n"
1543
+ }]
1544
+ }],
1545
+ ctorParameters: () => [
1546
+ { type: i1.Router },
1547
+ { type: i1.ActivatedRoute },
1548
+ { type: i2.MatSnackBar },
1549
+ { type: i3.ItemService },
1550
+ { type: i3.ThesaurusService },
1551
+ { type: i4$2.PartEditorService }
1552
+ ]
1553
+ });
1554
+ var PinLinksFragmentFeatureComponent = class PinLinksFragmentFeatureComponent extends EditFragmentFeatureBase {
1555
+ constructor(router, route, snackbar, editorService, libraryRouteService) {
1556
+ super(router, route, snackbar, editorService, libraryRouteService);
1557
+ }
1558
+ getReqThesauriIds() {
1559
+ return [
1560
+ "pin-link-scopes",
1561
+ "pin-link-tags",
1562
+ "pin-link-assertion-tags",
1563
+ "pin-link-docref-types",
1564
+ "pin-link-docref-tags",
1565
+ "asserted-id-features"
1566
+ ];
1567
+ }
1568
+ static ɵfac = i0.ɵɵngDeclareFactory({
1569
+ minVersion: "12.0.0",
1570
+ version: "22.2.0",
1571
+ ngImport: i0,
1572
+ type: PinLinksFragmentFeatureComponent,
1573
+ deps: [
1574
+ { token: i1.Router },
1575
+ { token: i1.ActivatedRoute },
1576
+ { token: i2.MatSnackBar },
1577
+ { token: i4$2.FragmentEditorService },
1578
+ { token: i4$1.LibraryRouteService }
1579
+ ],
1580
+ target: i0.ɵɵFactoryTarget.Component
1581
+ });
1582
+ static ɵcmp = i0.ɵɵngDeclareComponent({
1583
+ minVersion: "14.0.0",
1584
+ version: "22.2.0",
1585
+ type: PinLinksFragmentFeatureComponent,
1586
+ isStandalone: true,
1587
+ selector: "cadmus-pin-links-fragment-feature",
1588
+ usesInheritance: true,
1589
+ ngImport: i0,
1590
+ template: "<cadmus-current-item-bar/>\n@let loc = frLoc();\n<div class=\"base-text\">\n <cadmus-decorated-token-text\n [baseText]=\"data()?.baseText || ''\"\n [locations]=\"loc ? [loc] : []\"\n />\n</div>\n<cadmus-pin-links-fragment\n [identity]=\"identity()\"\n [data]=\"$any(data())\"\n (dataChange)=\"save($event!.value!)\"\n (editorClose)=\"close()\"\n (dirtyChange)=\"onDirtyChange($event)\"\n/>\n",
1591
+ styles: [""],
1592
+ dependencies: [
1593
+ {
1594
+ kind: "component",
1595
+ type: CurrentItemBarComponent,
1596
+ selector: "cadmus-current-item-bar"
1597
+ },
1598
+ {
1599
+ kind: "component",
1600
+ type: DecoratedTokenTextComponent,
1601
+ selector: "cadmus-decorated-token-text",
1602
+ inputs: [
1603
+ "baseText",
1604
+ "locations",
1605
+ "selectedLocation"
1606
+ ]
1607
+ },
1608
+ {
1609
+ kind: "component",
1610
+ type: PinLinksFragmentComponent,
1611
+ selector: "cadmus-pin-links-fragment"
1612
+ }
1613
+ ],
1614
+ changeDetection: i0.ChangeDetectionStrategy.OnPush
1615
+ });
1616
+ };
1617
+ i0.ɵɵngDeclareClassMetadata({
1618
+ minVersion: "12.0.0",
1619
+ version: "22.2.0",
1620
+ ngImport: i0,
1621
+ type: PinLinksFragmentFeatureComponent,
1622
+ decorators: [{
1623
+ type: Component,
1624
+ args: [{
1625
+ selector: "cadmus-pin-links-fragment-feature",
1626
+ changeDetection: ChangeDetectionStrategy.OnPush,
1627
+ imports: [
1628
+ CurrentItemBarComponent,
1629
+ DecoratedTokenTextComponent,
1630
+ PinLinksFragmentComponent
1631
+ ],
1632
+ template: "<cadmus-current-item-bar/>\n@let loc = frLoc();\n<div class=\"base-text\">\n <cadmus-decorated-token-text\n [baseText]=\"data()?.baseText || ''\"\n [locations]=\"loc ? [loc] : []\"\n />\n</div>\n<cadmus-pin-links-fragment\n [identity]=\"identity()\"\n [data]=\"$any(data())\"\n (dataChange)=\"save($event!.value!)\"\n (editorClose)=\"close()\"\n (dirtyChange)=\"onDirtyChange($event)\"\n/>\n"
1633
+ }]
1634
+ }],
1635
+ ctorParameters: () => [
1636
+ { type: i1.Router },
1637
+ { type: i1.ActivatedRoute },
1638
+ { type: i2.MatSnackBar },
1639
+ { type: i4$2.FragmentEditorService },
1640
+ { type: i4$1.LibraryRouteService }
1641
+ ]
1642
+ });
1643
+ var PinLinksPartFeatureComponent = class PinLinksPartFeatureComponent extends EditPartFeatureBase {
1644
+ constructor(router, route, snackbar, itemService, thesaurusService, editorService) {
1645
+ super(router, route, snackbar, itemService, thesaurusService, editorService);
1646
+ this.roleIdInThesauri = true;
1647
+ }
1648
+ getReqThesauriIds() {
1649
+ return [
1650
+ "pin-link-scopes",
1651
+ "pin-link-tags",
1652
+ "pin-link-assertion-tags",
1653
+ "pin-link-docref-types",
1654
+ "pin-link-docref-tags",
1655
+ "asserted-id-features"
1656
+ ];
1657
+ }
1658
+ static ɵfac = i0.ɵɵngDeclareFactory({
1659
+ minVersion: "12.0.0",
1660
+ version: "22.2.0",
1661
+ ngImport: i0,
1662
+ type: PinLinksPartFeatureComponent,
1663
+ deps: [
1664
+ { token: i1.Router },
1665
+ { token: i1.ActivatedRoute },
1666
+ { token: i2.MatSnackBar },
1667
+ { token: i3.ItemService },
1668
+ { token: i3.ThesaurusService },
1669
+ { token: i4$2.PartEditorService }
1670
+ ],
1671
+ target: i0.ɵɵFactoryTarget.Component
1672
+ });
1673
+ static ɵcmp = i0.ɵɵngDeclareComponent({
1674
+ minVersion: "14.0.0",
1675
+ version: "22.2.0",
1676
+ type: PinLinksPartFeatureComponent,
1677
+ isStandalone: true,
1678
+ selector: "cadmus-pin-links-part-feature",
1679
+ usesInheritance: true,
1680
+ ngImport: i0,
1681
+ template: "<cadmus-current-item-bar/>\n<cadmus-pin-links-part\n [identity]=\"identity()\"\n [data]=\"$any(data())\"\n (dataChange)=\"save($event!.value!)\"\n (editorClose)=\"close()\"\n (dirtyChange)=\"onDirtyChange($event)\"\n/>\n",
1682
+ styles: [""],
1683
+ dependencies: [{
1684
+ kind: "component",
1685
+ type: CurrentItemBarComponent,
1686
+ selector: "cadmus-current-item-bar"
1687
+ }, {
1688
+ kind: "component",
1689
+ type: PinLinksPartComponent,
1690
+ selector: "cadmus-pin-links-part"
1691
+ }],
1692
+ changeDetection: i0.ChangeDetectionStrategy.OnPush
1693
+ });
1694
+ };
1695
+ i0.ɵɵngDeclareClassMetadata({
1696
+ minVersion: "12.0.0",
1697
+ version: "22.2.0",
1698
+ ngImport: i0,
1699
+ type: PinLinksPartFeatureComponent,
1700
+ decorators: [{
1701
+ type: Component,
1702
+ args: [{
1703
+ selector: "cadmus-pin-links-part-feature",
1704
+ changeDetection: ChangeDetectionStrategy.OnPush,
1705
+ imports: [CurrentItemBarComponent, PinLinksPartComponent],
1706
+ template: "<cadmus-current-item-bar/>\n<cadmus-pin-links-part\n [identity]=\"identity()\"\n [data]=\"$any(data())\"\n (dataChange)=\"save($event!.value!)\"\n (editorClose)=\"close()\"\n (dirtyChange)=\"onDirtyChange($event)\"\n/>\n"
1707
+ }]
1708
+ }],
1709
+ ctorParameters: () => [
1710
+ { type: i1.Router },
1711
+ { type: i1.ActivatedRoute },
1712
+ { type: i2.MatSnackBar },
1713
+ { type: i3.ItemService },
1714
+ { type: i3.ThesaurusService },
1715
+ { type: i4$2.PartEditorService }
1716
+ ]
1717
+ });
1718
+ var TiledTextLayerView = class {
1719
+ _rows;
1720
+ constructor(rows) {
1721
+ this._rows = [];
1722
+ if (rows) for (let i = 0; i < rows.length; i++) {
1723
+ this._rows[i] = { tiles: [] };
1724
+ for (let j = 0; j < (rows[i].tiles ? rows[i].tiles.length : 0); j++) this._rows[i].tiles[j] = {
1725
+ checked: false,
1726
+ frIndex: -1,
1727
+ model: rows[i].tiles[j]
1728
+ };
1729
+ }
1730
+ }
1731
+ get rows() {
1732
+ return this._rows;
1733
+ }
1734
+ getTileAt(y, x) {
1735
+ return this._rows[y - 1].tiles[x - 1];
1736
+ }
1737
+ setAllTilesViewState(state) {
1738
+ const hasChecked = state.hasOwnProperty("checked");
1739
+ const hasFrIndex = state.hasOwnProperty("frIndex");
1740
+ if (!hasChecked && !hasFrIndex) return;
1741
+ for (let i = 0; i < this._rows.length; i++) {
1742
+ const row = this._rows[i];
1743
+ for (let j = 0; j < row.tiles.length; j++) {
1744
+ const tile = row.tiles[j];
1745
+ row.tiles[j] = {
1746
+ checked: (hasChecked ? state.checked : tile.checked) ? true : false,
1747
+ frIndex: hasFrIndex ? state.frIndex || -1 : tile.frIndex,
1748
+ model: tile.model
1749
+ };
1750
+ }
1751
+ }
1752
+ }
1753
+ setFragmentLocations(locations) {
1754
+ this.setAllTilesViewState({ frIndex: -1 });
1755
+ for (let i = 0; i < locations.length; i++) {
1756
+ const loc = locations[i];
1757
+ if (loc.secondary) for (let y = loc.primary.y; y <= loc.secondary.y; y++) {
1758
+ const row = this._rows[y - 1];
1759
+ for (let x = y === loc.primary.y ? loc.primary.x : 1; y === loc.secondary.y ? x <= loc.secondary.x : x <= row.tiles.length; x++) {
1760
+ const tile = row.tiles[x - 1];
1761
+ row.tiles[x - 1] = {
1762
+ checked: tile.checked,
1763
+ frIndex: i,
1764
+ model: tile.model
1765
+ };
1766
+ }
1767
+ }
1768
+ else {
1769
+ const tile = this.getTileAt(loc.primary.y, loc.primary.x);
1770
+ if (tile) this._rows[loc.primary.y - 1].tiles[loc.primary.x - 1] = {
1771
+ checked: tile.checked,
1772
+ frIndex: i,
1773
+ model: tile.model
1774
+ };
1775
+ }
1776
+ }
1777
+ }
1778
+ findFirstCheckedCoords(y, x, checked, reverse = false) {
1779
+ if (reverse) {
1780
+ let xstart = x;
1781
+ while (true) {
1782
+ for (let xi = xstart; xi >= 1; xi--) if (this.getTileAt(y, xi).checked === checked) return {
1783
+ y,
1784
+ x: xi
1785
+ };
1786
+ if (--y > 0) xstart = this._rows[y - 1].tiles.length;
1787
+ else break;
1788
+ }
1789
+ } else {
1790
+ let xstart = x;
1791
+ while (true) {
1792
+ for (let xi = xstart; xi <= this._rows[y - 1].tiles.length; xi++) if (this.getTileAt(y, xi).checked === checked) return {
1793
+ y,
1794
+ x: xi
1795
+ };
1796
+ if (++y <= this._rows.length) xstart = 1;
1797
+ else break;
1798
+ }
1799
+ }
1800
+ return null;
1801
+ }
1802
+ linearSetCheck(y1, x1, y2, x2, checked) {
1803
+ for (let y = y1; y <= y2; y++) {
1804
+ const row = this._rows[y - 1];
1805
+ for (let x = y === y1 ? x1 : 1; y === y2 ? x <= x2 : x <= row.tiles.length; x++) {
1806
+ const tile = row.tiles[x - 1];
1807
+ row.tiles[x - 1] = {
1808
+ frIndex: tile.frIndex,
1809
+ checked,
1810
+ model: tile.model
1811
+ };
1812
+ }
1813
+ }
1814
+ }
1815
+ getNextTileCoords(y, x) {
1816
+ if (x < this._rows[y - 1].tiles.length) return {
1817
+ y,
1818
+ x: x + 1
1819
+ };
1820
+ y++;
1821
+ while (y <= this._rows.length) {
1822
+ if (this._rows[y - 1].tiles.length > 0) return {
1823
+ y,
1824
+ x: 1
1825
+ };
1826
+ y++;
1827
+ }
1828
+ return null;
1829
+ }
1830
+ getPrevTileCoords(y, x) {
1831
+ if (x > 1) return {
1832
+ y,
1833
+ x: x - 1
1834
+ };
1835
+ y--;
1836
+ while (y > 0) {
1837
+ if (this._rows[y - 1].tiles.length > 0) return {
1838
+ y,
1839
+ x: this._rows[y - 1].tiles.length
1840
+ };
1841
+ y--;
1842
+ }
1843
+ return null;
1844
+ }
1845
+ toggleLinearTileCheck(y, x, checked) {
1846
+ if (checked) {
1847
+ let yx = this.findFirstCheckedCoords(y, x, true);
1848
+ if (yx) {
1849
+ this.linearSetCheck(yx.y, yx.x, y, x, true);
1850
+ return;
1851
+ }
1852
+ yx = this.findFirstCheckedCoords(y, x, true, true);
1853
+ if (yx) {
1854
+ this.linearSetCheck(yx.y, yx.x, y, x, true);
1855
+ return;
1856
+ }
1857
+ const tile = this.getTileAt(y, x);
1858
+ this._rows[y - 1].tiles[x - 1] = {
1859
+ checked: true,
1860
+ frIndex: tile.frIndex,
1861
+ model: tile.model
1862
+ };
1863
+ } else {
1864
+ let y1;
1865
+ let x1;
1866
+ const yx = this.findFirstCheckedCoords(y, x, false, true);
1867
+ if (yx) {
1868
+ const next = this.getNextTileCoords(yx.y, yx.x);
1869
+ if (!next) {
1870
+ y1 = y;
1871
+ x1 = x;
1872
+ } else {
1873
+ y1 = next.y;
1874
+ x1 = next.x;
1875
+ }
1876
+ this.linearSetCheck(y1, x1, yx.y, yx.x, false);
1877
+ } else {
1878
+ y1 = 1;
1879
+ x1 = 1;
1880
+ }
1881
+ }
1882
+ }
1883
+ getCheckedLocation() {
1884
+ const start = this.findFirstCheckedCoords(1, 1, true);
1885
+ if (!start) return null;
1886
+ const end = this.findFirstCheckedCoords(start.y, start.x, false);
1887
+ if (!end || end.y === start.y && end.x === start.x) return null;
1888
+ const last = this.getPrevTileCoords(end.y, end.x);
1889
+ return !last || last.y === start.y && last.x === start.x ? new TokenLocation(new TokenPoint(start.y, start.x)) : new TokenLocation(new TokenPoint(start.y, start.x), new TokenPoint(last.y, last.x));
1890
+ }
1891
+ getCheckedLocationAndFragment() {
1892
+ const loc = this.getCheckedLocation();
1893
+ if (!loc) return null;
1894
+ let y2;
1895
+ let x2;
1896
+ if (loc.secondary) {
1897
+ y2 = loc.secondary.y;
1898
+ x2 = loc.secondary.x;
1899
+ } else {
1900
+ y2 = loc.primary.y;
1901
+ x2 = loc.primary.x;
1902
+ }
1903
+ let fr = -1;
1904
+ for (let y = loc.primary.y; y <= y2; y++) {
1905
+ const row = this._rows[y - 1];
1906
+ for (let x = y === loc.primary.y ? loc.primary.x : 1; x <= (y === y2 ? x2 : row.tiles.length); x++) if (row.tiles[x - 1].frIndex > -1) {
1907
+ if (fr > -1) {
1908
+ if (fr !== row.tiles[x - 1].frIndex) return {
1909
+ fragment: -1,
1910
+ location: loc
1911
+ };
1912
+ } else fr = row.tiles[x - 1].frIndex;
1913
+ }
1914
+ }
1915
+ return {
1916
+ fragment: fr,
1917
+ location: loc
1918
+ };
1919
+ }
1920
+ };
1921
+ var TiledTextLayerPartFeatureComponent = class TiledTextLayerPartFeatureComponent {
1922
+ _router;
1923
+ _repository;
1924
+ _libraryRouteService;
1925
+ _editedItemRepository;
1926
+ _dialogService;
1927
+ _sub;
1928
+ view = signal(void 0, ...ngDevMode ? [{ debugName: "view" }] : /* istanbul ignore next */ []);
1929
+ selectedTile;
1930
+ itemId;
1931
+ partId;
1932
+ roleId;
1933
+ loading$;
1934
+ saving$;
1935
+ baseText$;
1936
+ locations$;
1937
+ rows$;
1938
+ breakChance$;
1939
+ layerHints$;
1940
+ pickedLocation;
1941
+ userLevel;
1942
+ constructor(route, _router, _repository, _libraryRouteService, _editedItemRepository, _dialogService, userLevelService) {
1943
+ this._router = _router;
1944
+ this._repository = _repository;
1945
+ this._libraryRouteService = _libraryRouteService;
1946
+ this._editedItemRepository = _editedItemRepository;
1947
+ this._dialogService = _dialogService;
1948
+ this.itemId = route.snapshot.params["iid"];
1949
+ this.partId = route.snapshot.params["pid"];
1950
+ if (this.partId === "new") this.partId = void 0;
1951
+ this.roleId = route.snapshot.queryParams["rid"];
1952
+ if (this.roleId === "default") this.roleId = void 0;
1953
+ this.userLevel = userLevelService.getCurrentUserLevel();
1954
+ this.loading$ = this._repository.loading$;
1955
+ this.saving$ = this._repository.saving$;
1956
+ this.baseText$ = this._repository.baseText$;
1957
+ this.locations$ = this._repository.locations$;
1958
+ this.breakChance$ = this._repository.breakChance$;
1959
+ this.layerHints$ = this._repository.layerHints$;
1960
+ this.rows$ = this._repository.baseTextPart$.pipe(map((part) => part?.rows));
1961
+ }
1962
+ canDeactivate() {
1963
+ return true;
1964
+ }
1965
+ ngOnInit() {
1966
+ this._sub = this.rows$.subscribe((rows) => {
1967
+ const v = rows ? new TiledTextLayerView(rows) : void 0;
1968
+ v?.setFragmentLocations(this._repository.getLocations());
1969
+ this.view.set(v);
1970
+ });
1971
+ this._editedItemRepository.ensureItemLoaded(this.itemId);
1972
+ this._repository.reset();
1973
+ if (this.partId) this._repository.load(this.itemId, this.partId);
1974
+ }
1975
+ ngOnDestroy() {
1976
+ this._sub?.unsubscribe();
1977
+ }
1978
+ refreshBreakChance() {
1979
+ this._repository.refreshBreakChance();
1980
+ }
1981
+ onTileChecked(y, x, checked) {
1982
+ const v = this.view();
1983
+ if (v) v.toggleLinearTileCheck(y, x, checked);
1984
+ }
1985
+ getSelectedTileCoords() {
1986
+ const v = this.view();
1987
+ if (!this.selectedTile || !v) return null;
1988
+ for (let i = 0; i < v.rows.length; i++) {
1989
+ const j = v.rows[i].tiles.indexOf(this.selectedTile);
1990
+ if (j > -1) return {
1991
+ y: i + 1,
1992
+ x: j + 1
1993
+ };
1994
+ }
1995
+ return null;
1996
+ }
1997
+ selectPrevTile() {
1998
+ const v = this.view();
1999
+ if (!v) return;
2000
+ let yx = this.getSelectedTileCoords();
2001
+ if (yx) {
2002
+ yx = v.getPrevTileCoords(yx.y, yx.x);
2003
+ if (yx) this.selectedTile = v.rows[yx.y - 1].tiles[yx.x - 1];
2004
+ }
2005
+ }
2006
+ selectNextTile() {
2007
+ const v = this.view();
2008
+ if (!v) return;
2009
+ let yx = this.getSelectedTileCoords();
2010
+ if (yx) {
2011
+ yx = v.getNextTileCoords(yx.y, yx.x);
2012
+ if (yx) this.selectedTile = v.rows[yx.y - 1].tiles[yx.x - 1];
2013
+ }
2014
+ }
2015
+ deleteFragment() {
2016
+ const v = this.view();
2017
+ if (!v) return;
2018
+ const lf = v.getCheckedLocationAndFragment();
2019
+ if (!lf || lf.fragment === -1) return;
2020
+ const loc = this._repository.getLocations()[lf.fragment];
2021
+ this._dialogService.confirm("Delete Fragment", `Delete the fragment at ${loc}?`).subscribe((ok) => {
2022
+ if (ok) {
2023
+ if (this._repository.getPart()?.fragments.findIndex((p) => {
2024
+ return TokenLocation.parse(p.location)?.overlaps(loc);
2025
+ }) === -1) return;
2026
+ this._repository.deleteFragment(loc);
2027
+ }
2028
+ });
2029
+ }
2030
+ deleteFragmentFromHint(hint) {
2031
+ const loc = TokenLocation.parse(hint.location);
2032
+ if (loc) this._repository.deleteFragment(loc);
2033
+ }
2034
+ navigateToFragmentEditor(loc) {
2035
+ const part = this._repository.getPart();
2036
+ if (!part) return;
2037
+ const { route, rid } = this._libraryRouteService.buildFragmentEditorRoute(this._editedItemRepository.getFacet().partDefinitions, part.itemId, part.id, part.typeId, part.roleId, loc);
2038
+ this._router.navigate([route], rid ? { queryParams: { rid: part.roleId } } : {});
2039
+ }
2040
+ editFragment() {
2041
+ const v = this.view();
2042
+ if (!v) return;
2043
+ const lf = v.getCheckedLocationAndFragment();
2044
+ if (!lf || lf.fragment === -1) return;
2045
+ const locations = this._repository.getLocations();
2046
+ this.navigateToFragmentEditor(locations[lf.fragment].toString());
2047
+ }
2048
+ editFragmentFromHint(hint) {
2049
+ this.navigateToFragmentEditor(hint.location);
2050
+ }
2051
+ moveFragmentFromHint(hint) {
2052
+ if (!this.pickedLocation || this.pickedLocation === hint.location || !this.partId) return;
2053
+ this._repository.applyLayerPatches(this.partId, [`mov ${hint.location} ${this.pickedLocation}`]);
2054
+ }
2055
+ addFragment() {
2056
+ const v = this.view();
2057
+ if (!v) return;
2058
+ const lf = v.getCheckedLocationAndFragment();
2059
+ if (!lf || lf.fragment > -1) return;
2060
+ this.navigateToFragmentEditor(lf.location.toString());
2061
+ }
2062
+ pickLocation() {
2063
+ const v = this.view();
2064
+ if (!v) return;
2065
+ const lf = v.getCheckedLocationAndFragment();
2066
+ if (!lf) return;
2067
+ const locations = this._repository.getLocations();
2068
+ this.pickedLocation = (lf.fragment === -1 ? lf.location : locations[lf.fragment]).toString();
2069
+ }
2070
+ clearTileChecks() {
2071
+ const v = this.view();
2072
+ if (!v) return;
2073
+ v.setAllTilesViewState({ checked: false });
2074
+ this.pickedLocation = void 0;
2075
+ }
2076
+ applyLayerPatches(patches) {
2077
+ if (this.partId) this._repository.applyLayerPatches(this.partId, patches);
2078
+ }
2079
+ close() {
2080
+ this._router.navigate(["/items", this.itemId]);
2081
+ }
2082
+ static ɵfac = i0.ɵɵngDeclareFactory({
2083
+ minVersion: "12.0.0",
2084
+ version: "22.2.0",
2085
+ ngImport: i0,
2086
+ type: TiledTextLayerPartFeatureComponent,
2087
+ deps: [
2088
+ { token: i1.ActivatedRoute },
2089
+ { token: i1.Router },
2090
+ { token: i4$2.EditedLayerRepository },
2091
+ { token: i4$1.LibraryRouteService },
2092
+ { token: i4.EditedItemRepository },
2093
+ { token: i5.DialogService },
2094
+ { token: i3.UserLevelService }
2095
+ ],
2096
+ target: i0.ɵɵFactoryTarget.Component
2097
+ });
2098
+ static ɵcmp = i0.ɵɵngDeclareComponent({
2099
+ minVersion: "17.0.0",
2100
+ version: "22.2.0",
2101
+ type: TiledTextLayerPartFeatureComponent,
2102
+ isStandalone: true,
2103
+ selector: "cadmus-tiled-text-layer-part-feature",
2104
+ ngImport: i0,
2105
+ template: "<cadmus-current-item-bar></cadmus-current-item-bar>\n<mat-card appearance=\"outlined\">\n <mat-card-header>\n <div mat-card-avatar>\n <mat-icon>view_headline</mat-icon>\n </div>\n <mat-card-title>\n Tiles-Based Text Layers\n <button type=\"button\" mat-icon-button (click)=\"refreshBreakChance()\">\n @switch (breakChance$ | async) { @case (-1) {\n <mat-icon matTooltip=\"Checking...\">refresh</mat-icon>\n } @case (0) {\n <mat-icon matTooltip=\"Valid\">check_circle</mat-icon>\n } @case (1) {\n <mat-icon matTooltip=\"Potentially broken\" class=\"mat-warn\"\n >warning</mat-icon\n >\n } @case (2) {\n <mat-icon matTooltip=\"Broken\" class=\"mat-warn\">error</mat-icon>\n } }\n </button>\n </mat-card-title>\n <cadmus-current-layer-part-bar />\n </mat-card-header>\n @if (!(loading$ | async) && !(saving$ | async)) {\n <mat-card-actions>\n <mat-toolbar>\n <button\n mat-icon-button\n type=\"button\"\n (click)=\"editFragment()\"\n matTooltip=\"Edit the selected fragment\"\n >\n <mat-icon>edit</mat-icon>\n </button>\n <button\n mat-icon-button\n type=\"button\"\n (click)=\"deleteFragment()\"\n matTooltip=\"Delete the selected fragment\"\n >\n <mat-icon class=\"mat-warn\">delete</mat-icon>\n </button>\n <button\n mat-icon-button\n type=\"button\"\n (click)=\"pickLocation()\"\n matTooltip=\"Pick the selection location for a new fragment\"\n >\n <mat-icon>info</mat-icon>\n </button>\n <button\n mat-icon-button\n type=\"button\"\n (click)=\"clearTileChecks()\"\n matTooltip=\"Clear any selection\"\n >\n <mat-icon class=\"mat-warn\">clear</mat-icon>\n </button>\n <button\n mat-icon-button\n type=\"button\"\n (click)=\"addFragment()\"\n matTooltip=\"Add a new fragment at selection\"\n >\n <mat-icon class=\"mat-primary\">add_circle</mat-icon>\n </button>\n <span>{{ pickedLocation }}</span>\n </mat-toolbar>\n </mat-card-actions>\n }\n\n <mat-card-content>\n @if (loading$ | async) {\n <mat-progress-bar mode=\"indeterminate\" />\n }\n\n <!-- rows -->\n @if (view()) {\n <div>\n @for (row of view()!.rows; track row; let iy = $index) {\n <div class=\"tile-row\" style=\"display: flex; flex-flow: row wrap\">\n <span class=\"row-nr\">{{ iy + 1 }}</span>\n <!-- tile -->\n @for (tile of row.tiles || []; track tile; let ix = $index) {\n <cadmus-text-tile\n [tile]=\"tile.model\"\n [readonly]=\"true\"\n [selected]=\"tile === selectedTile\"\n [checkable]=\"true\"\n [checked]=\"tile.checked\"\n [color]=\"tile.frIndex > -1 ? 'yellow' : 'transparent'\"\n style=\"flex: 0 0 auto\"\n (click)=\"selectedTile = tile\"\n (checkedChange)=\"onTileChecked(iy + 1, ix + 1, $event)\"\n (keydown.control.arrowleft)=\"selectPrevTile()\"\n (keydown.control.arrowright)=\"selectNextTile()\"\n />\n }\n </div>\n }\n </div>\n }\n </mat-card-content>\n\n <div>\n <button\n type=\"button\"\n mat-flat-button\n class=\"mat-warn\"\n matTooltip=\"Close this editor\"\n (click)=\"close()\"\n >\n <mat-icon>cancel</mat-icon>\n close\n </button>\n </div>\n @if (layerHints$ | async; as layerHints) {\n <mat-expansion-panel>\n <mat-expansion-panel-header>\n <mat-panel-title>Layer hints</mat-panel-title>\n <mat-panel-description>{{ layerHints.length }}</mat-panel-description>\n </mat-expansion-panel-header>\n <cadmus-layer-hints\n [hints]=\"layerHints\"\n [disabled]=\"(loading$ | async) || (saving$ | async) ? true : false\"\n [readonly]=\"userLevel < 2\"\n [targetLocation]=\"pickedLocation\"\n (requestEdit)=\"editFragmentFromHint($event)\"\n (requestDelete)=\"deleteFragmentFromHint($event)\"\n (requestMove)=\"moveFragmentFromHint($event)\"\n (requestPatch)=\"applyLayerPatches($event)\"\n />\n </mat-expansion-panel>\n }\n</mat-card>\n",
2106
+ styles: ["div.tile-row{margin-bottom:6px}span.row-nr{color:var(--mat-sys-on-surface-variant);font-weight:700}\n"],
2107
+ dependencies: [
2108
+ {
2109
+ kind: "component",
2110
+ type: MatCard,
2111
+ selector: "mat-card",
2112
+ inputs: ["appearance"],
2113
+ exportAs: ["matCard"]
2114
+ },
2115
+ {
2116
+ kind: "component",
2117
+ type: MatCardHeader,
2118
+ selector: "mat-card-header"
2119
+ },
2120
+ {
2121
+ kind: "directive",
2122
+ type: MatCardAvatar,
2123
+ selector: "[mat-card-avatar], [matCardAvatar]"
2124
+ },
2125
+ {
2126
+ kind: "component",
2127
+ type: MatIcon,
2128
+ selector: "mat-icon",
2129
+ inputs: [
2130
+ "color",
2131
+ "inline",
2132
+ "svgIcon",
2133
+ "fontSet",
2134
+ "fontIcon"
2135
+ ],
2136
+ exportAs: ["matIcon"]
2137
+ },
2138
+ {
2139
+ kind: "directive",
2140
+ type: MatCardTitle,
2141
+ selector: "mat-card-title, [mat-card-title], [matCardTitle]"
2142
+ },
2143
+ {
2144
+ kind: "component",
2145
+ type: MatIconButton,
2146
+ selector: "button[mat-icon-button], a[mat-icon-button], button[matIconButton], a[matIconButton]",
2147
+ exportAs: ["matButton", "matAnchor"]
2148
+ },
2149
+ {
2150
+ kind: "directive",
2151
+ type: MatTooltip,
2152
+ selector: "[matTooltip]",
2153
+ inputs: [
2154
+ "matTooltipPosition",
2155
+ "matTooltipPositionAtOrigin",
2156
+ "matTooltipDisabled",
2157
+ "matTooltipShowDelay",
2158
+ "matTooltipHideDelay",
2159
+ "matTooltipTouchGestures",
2160
+ "matTooltip",
2161
+ "matTooltipClass"
2162
+ ],
2163
+ exportAs: ["matTooltip"]
2164
+ },
2165
+ {
2166
+ kind: "directive",
2167
+ type: MatCardActions,
2168
+ selector: "mat-card-actions",
2169
+ inputs: ["align"],
2170
+ exportAs: ["matCardActions"]
2171
+ },
2172
+ {
2173
+ kind: "component",
2174
+ type: MatToolbar,
2175
+ selector: "mat-toolbar",
2176
+ inputs: ["color"],
2177
+ exportAs: ["matToolbar"]
2178
+ },
2179
+ {
2180
+ kind: "directive",
2181
+ type: MatCardContent,
2182
+ selector: "mat-card-content"
2183
+ },
2184
+ {
2185
+ kind: "component",
2186
+ type: MatProgressBar,
2187
+ selector: "mat-progress-bar",
2188
+ inputs: [
2189
+ "color",
2190
+ "value",
2191
+ "bufferValue",
2192
+ "mode"
2193
+ ],
2194
+ outputs: ["animationEnd"],
2195
+ exportAs: ["matProgressBar"]
2196
+ },
2197
+ {
2198
+ kind: "component",
2199
+ type: MatButton,
2200
+ selector: " button[matButton], a[matButton], button[mat-button], button[mat-raised-button], button[mat-flat-button], button[mat-stroked-button], a[mat-button], a[mat-raised-button], a[mat-flat-button], a[mat-stroked-button] ",
2201
+ inputs: ["matButton"],
2202
+ exportAs: ["matButton", "matAnchor"]
2203
+ },
2204
+ {
2205
+ kind: "component",
2206
+ type: MatExpansionPanel,
2207
+ selector: "mat-expansion-panel",
2208
+ inputs: ["hideToggle", "togglePosition"],
2209
+ outputs: ["afterExpand", "afterCollapse"],
2210
+ exportAs: ["matExpansionPanel"]
2211
+ },
2212
+ {
2213
+ kind: "component",
2214
+ type: MatExpansionPanelHeader,
2215
+ selector: "mat-expansion-panel-header",
2216
+ inputs: [
2217
+ "expandedHeight",
2218
+ "collapsedHeight",
2219
+ "tabIndex"
2220
+ ]
2221
+ },
2222
+ {
2223
+ kind: "directive",
2224
+ type: MatExpansionPanelTitle,
2225
+ selector: "mat-panel-title"
2226
+ },
2227
+ {
2228
+ kind: "directive",
2229
+ type: MatExpansionPanelDescription,
2230
+ selector: "mat-panel-description"
2231
+ },
2232
+ {
2233
+ kind: "component",
2234
+ type: CurrentItemBarComponent,
2235
+ selector: "cadmus-current-item-bar"
2236
+ },
2237
+ {
2238
+ kind: "component",
2239
+ type: CurrentLayerPartBarComponent,
2240
+ selector: "cadmus-current-layer-part-bar"
2241
+ },
2242
+ {
2243
+ kind: "component",
2244
+ type: LayerHintsComponent,
2245
+ selector: "cadmus-layer-hints",
2246
+ inputs: [
2247
+ "hints",
2248
+ "targetLocation",
2249
+ "disabled",
2250
+ "readonly"
2251
+ ],
2252
+ outputs: [
2253
+ "requestEdit",
2254
+ "requestDelete",
2255
+ "requestMove",
2256
+ "requestPatch"
2257
+ ]
2258
+ },
2259
+ {
2260
+ kind: "component",
2261
+ type: TextTileComponent,
2262
+ selector: "cadmus-text-tile",
2263
+ inputs: [
2264
+ "selected",
2265
+ "checkable",
2266
+ "readonly",
2267
+ "color",
2268
+ "checked",
2269
+ "tile"
2270
+ ],
2271
+ outputs: [
2272
+ "checkedChange",
2273
+ "tileChange",
2274
+ "editData"
2275
+ ]
2276
+ },
2277
+ {
2278
+ kind: "pipe",
2279
+ type: AsyncPipe,
2280
+ name: "async"
2281
+ }
2282
+ ],
2283
+ changeDetection: i0.ChangeDetectionStrategy.OnPush
2284
+ });
2285
+ };
2286
+ i0.ɵɵngDeclareClassMetadata({
2287
+ minVersion: "12.0.0",
2288
+ version: "22.2.0",
2289
+ ngImport: i0,
2290
+ type: TiledTextLayerPartFeatureComponent,
2291
+ decorators: [{
2292
+ type: Component,
2293
+ args: [{
2294
+ selector: "cadmus-tiled-text-layer-part-feature",
2295
+ changeDetection: ChangeDetectionStrategy.OnPush,
2296
+ imports: [
2297
+ MatCard,
2298
+ MatCardHeader,
2299
+ MatCardAvatar,
2300
+ MatIcon,
2301
+ MatCardTitle,
2302
+ MatIconButton,
2303
+ MatTooltip,
2304
+ MatCardActions,
2305
+ MatToolbar,
2306
+ MatCardContent,
2307
+ MatProgressBar,
2308
+ MatButton,
2309
+ MatExpansionPanel,
2310
+ MatExpansionPanelHeader,
2311
+ MatExpansionPanelTitle,
2312
+ MatExpansionPanelDescription,
2313
+ AsyncPipe,
2314
+ CurrentItemBarComponent,
2315
+ CurrentLayerPartBarComponent,
2316
+ LayerHintsComponent,
2317
+ TextTileComponent
2318
+ ],
2319
+ template: "<cadmus-current-item-bar></cadmus-current-item-bar>\n<mat-card appearance=\"outlined\">\n <mat-card-header>\n <div mat-card-avatar>\n <mat-icon>view_headline</mat-icon>\n </div>\n <mat-card-title>\n Tiles-Based Text Layers\n <button type=\"button\" mat-icon-button (click)=\"refreshBreakChance()\">\n @switch (breakChance$ | async) { @case (-1) {\n <mat-icon matTooltip=\"Checking...\">refresh</mat-icon>\n } @case (0) {\n <mat-icon matTooltip=\"Valid\">check_circle</mat-icon>\n } @case (1) {\n <mat-icon matTooltip=\"Potentially broken\" class=\"mat-warn\"\n >warning</mat-icon\n >\n } @case (2) {\n <mat-icon matTooltip=\"Broken\" class=\"mat-warn\">error</mat-icon>\n } }\n </button>\n </mat-card-title>\n <cadmus-current-layer-part-bar />\n </mat-card-header>\n @if (!(loading$ | async) && !(saving$ | async)) {\n <mat-card-actions>\n <mat-toolbar>\n <button\n mat-icon-button\n type=\"button\"\n (click)=\"editFragment()\"\n matTooltip=\"Edit the selected fragment\"\n >\n <mat-icon>edit</mat-icon>\n </button>\n <button\n mat-icon-button\n type=\"button\"\n (click)=\"deleteFragment()\"\n matTooltip=\"Delete the selected fragment\"\n >\n <mat-icon class=\"mat-warn\">delete</mat-icon>\n </button>\n <button\n mat-icon-button\n type=\"button\"\n (click)=\"pickLocation()\"\n matTooltip=\"Pick the selection location for a new fragment\"\n >\n <mat-icon>info</mat-icon>\n </button>\n <button\n mat-icon-button\n type=\"button\"\n (click)=\"clearTileChecks()\"\n matTooltip=\"Clear any selection\"\n >\n <mat-icon class=\"mat-warn\">clear</mat-icon>\n </button>\n <button\n mat-icon-button\n type=\"button\"\n (click)=\"addFragment()\"\n matTooltip=\"Add a new fragment at selection\"\n >\n <mat-icon class=\"mat-primary\">add_circle</mat-icon>\n </button>\n <span>{{ pickedLocation }}</span>\n </mat-toolbar>\n </mat-card-actions>\n }\n\n <mat-card-content>\n @if (loading$ | async) {\n <mat-progress-bar mode=\"indeterminate\" />\n }\n\n <!-- rows -->\n @if (view()) {\n <div>\n @for (row of view()!.rows; track row; let iy = $index) {\n <div class=\"tile-row\" style=\"display: flex; flex-flow: row wrap\">\n <span class=\"row-nr\">{{ iy + 1 }}</span>\n <!-- tile -->\n @for (tile of row.tiles || []; track tile; let ix = $index) {\n <cadmus-text-tile\n [tile]=\"tile.model\"\n [readonly]=\"true\"\n [selected]=\"tile === selectedTile\"\n [checkable]=\"true\"\n [checked]=\"tile.checked\"\n [color]=\"tile.frIndex > -1 ? 'yellow' : 'transparent'\"\n style=\"flex: 0 0 auto\"\n (click)=\"selectedTile = tile\"\n (checkedChange)=\"onTileChecked(iy + 1, ix + 1, $event)\"\n (keydown.control.arrowleft)=\"selectPrevTile()\"\n (keydown.control.arrowright)=\"selectNextTile()\"\n />\n }\n </div>\n }\n </div>\n }\n </mat-card-content>\n\n <div>\n <button\n type=\"button\"\n mat-flat-button\n class=\"mat-warn\"\n matTooltip=\"Close this editor\"\n (click)=\"close()\"\n >\n <mat-icon>cancel</mat-icon>\n close\n </button>\n </div>\n @if (layerHints$ | async; as layerHints) {\n <mat-expansion-panel>\n <mat-expansion-panel-header>\n <mat-panel-title>Layer hints</mat-panel-title>\n <mat-panel-description>{{ layerHints.length }}</mat-panel-description>\n </mat-expansion-panel-header>\n <cadmus-layer-hints\n [hints]=\"layerHints\"\n [disabled]=\"(loading$ | async) || (saving$ | async) ? true : false\"\n [readonly]=\"userLevel < 2\"\n [targetLocation]=\"pickedLocation\"\n (requestEdit)=\"editFragmentFromHint($event)\"\n (requestDelete)=\"deleteFragmentFromHint($event)\"\n (requestMove)=\"moveFragmentFromHint($event)\"\n (requestPatch)=\"applyLayerPatches($event)\"\n />\n </mat-expansion-panel>\n }\n</mat-card>\n",
2320
+ styles: ["div.tile-row{margin-bottom:6px}span.row-nr{color:var(--mat-sys-on-surface-variant);font-weight:700}\n"]
2321
+ }]
2322
+ }],
2323
+ ctorParameters: () => [
2324
+ { type: i1.ActivatedRoute },
2325
+ { type: i1.Router },
2326
+ { type: i4$2.EditedLayerRepository },
2327
+ { type: i4$1.LibraryRouteService },
2328
+ { type: i4.EditedItemRepository },
2329
+ { type: i5.DialogService },
2330
+ { type: i3.UserLevelService }
2331
+ ]
2332
+ });
2333
+ var TiledTextPartFeatureComponent = class TiledTextPartFeatureComponent extends EditPartFeatureBase {
2334
+ constructor(router, route, snackbar, itemService, thesaurusService, editorService) {
2335
+ super(router, route, snackbar, itemService, thesaurusService, editorService);
2336
+ }
2337
+ static ɵfac = i0.ɵɵngDeclareFactory({
2338
+ minVersion: "12.0.0",
2339
+ version: "22.2.0",
2340
+ ngImport: i0,
2341
+ type: TiledTextPartFeatureComponent,
2342
+ deps: [
2343
+ { token: i1.Router },
2344
+ { token: i1.ActivatedRoute },
2345
+ { token: i2.MatSnackBar },
2346
+ { token: i3.ItemService },
2347
+ { token: i3.ThesaurusService },
2348
+ { token: i4$2.PartEditorService }
2349
+ ],
2350
+ target: i0.ɵɵFactoryTarget.Component
2351
+ });
2352
+ static ɵcmp = i0.ɵɵngDeclareComponent({
2353
+ minVersion: "14.0.0",
2354
+ version: "22.2.0",
2355
+ type: TiledTextPartFeatureComponent,
2356
+ isStandalone: true,
2357
+ selector: "cadmus-tiled-text-part-feature",
2358
+ usesInheritance: true,
2359
+ ngImport: i0,
2360
+ template: "<cadmus-current-item-bar/>\r\n<cadmus-tiled-text-part\r\n [identity]=\"identity()\"\r\n [data]=\"$any(data())\"\r\n (dataChange)=\"save($event!.value!)\"\r\n (editorClose)=\"close()\"\r\n (dirtyChange)=\"onDirtyChange($event)\"\r\n/>\r\n",
2361
+ styles: [""],
2362
+ dependencies: [{
2363
+ kind: "component",
2364
+ type: CurrentItemBarComponent,
2365
+ selector: "cadmus-current-item-bar"
2366
+ }, {
2367
+ kind: "component",
2368
+ type: TiledTextPartComponent,
2369
+ selector: "cadmus-tiled-text-part"
2370
+ }],
2371
+ changeDetection: i0.ChangeDetectionStrategy.OnPush
2372
+ });
2373
+ };
2374
+ i0.ɵɵngDeclareClassMetadata({
2375
+ minVersion: "12.0.0",
2376
+ version: "22.2.0",
2377
+ ngImport: i0,
2378
+ type: TiledTextPartFeatureComponent,
2379
+ decorators: [{
2380
+ type: Component,
2381
+ args: [{
2382
+ selector: "cadmus-tiled-text-part-feature",
2383
+ changeDetection: ChangeDetectionStrategy.OnPush,
2384
+ imports: [CurrentItemBarComponent, TiledTextPartComponent],
2385
+ template: "<cadmus-current-item-bar/>\r\n<cadmus-tiled-text-part\r\n [identity]=\"identity()\"\r\n [data]=\"$any(data())\"\r\n (dataChange)=\"save($event!.value!)\"\r\n (editorClose)=\"close()\"\r\n (dirtyChange)=\"onDirtyChange($event)\"\r\n/>\r\n"
2386
+ }]
2387
+ }],
2388
+ ctorParameters: () => [
2389
+ { type: i1.Router },
2390
+ { type: i1.ActivatedRoute },
2391
+ { type: i2.MatSnackBar },
2392
+ { type: i3.ItemService },
2393
+ { type: i3.ThesaurusService },
2394
+ { type: i4$2.PartEditorService }
2395
+ ]
2396
+ });
2397
+ var TokenTextLayerPartFeatureComponent = class TokenTextLayerPartFeatureComponent {
2398
+ _router;
2399
+ _repository;
2400
+ _textLayerService;
2401
+ _libraryRouteService;
2402
+ _editedItemRepository;
2403
+ _dialogService;
2404
+ itemId;
2405
+ partId;
2406
+ roleId;
2407
+ loading$;
2408
+ saving$;
2409
+ baseText$;
2410
+ locations$;
2411
+ breakChance$;
2412
+ layerHints$;
2413
+ pickedLocation;
2414
+ userLevel;
2415
+ textSize;
2416
+ constructor(route, _router, _repository, _textLayerService, _libraryRouteService, _editedItemRepository, _dialogService, userLevelService) {
2417
+ this._router = _router;
2418
+ this._repository = _repository;
2419
+ this._textLayerService = _textLayerService;
2420
+ this._libraryRouteService = _libraryRouteService;
2421
+ this._editedItemRepository = _editedItemRepository;
2422
+ this._dialogService = _dialogService;
2423
+ this.textSize = 14;
2424
+ this.itemId = route.snapshot.params["iid"];
2425
+ this.partId = route.snapshot.params["pid"];
2426
+ if (this.partId === "new") this.partId = void 0;
2427
+ this.roleId = route.snapshot.queryParams["rid"];
2428
+ if (this.roleId === "default") this.roleId = void 0;
2429
+ this.userLevel = userLevelService.getCurrentUserLevel();
2430
+ this.loading$ = this._repository.loading$;
2431
+ this.saving$ = this._repository.saving$;
2432
+ this.baseText$ = this._repository.baseText$;
2433
+ this.locations$ = this._repository.locations$;
2434
+ this.breakChance$ = this._repository.breakChance$;
2435
+ this.layerHints$ = this._repository.layerHints$;
2436
+ }
2437
+ canDeactivate() {
2438
+ return true;
2439
+ }
2440
+ makeLarger() {
2441
+ const size = this.textSize + 2;
2442
+ if (size > 24) return;
2443
+ this.textSize = size;
2444
+ }
2445
+ makeSmaller() {
2446
+ const size = this.textSize - 2;
2447
+ if (size < 12) return;
2448
+ this.textSize = size;
2449
+ }
2450
+ ngOnInit() {
2451
+ this._editedItemRepository.ensureItemLoaded(this.itemId);
2452
+ this._repository.reset();
2453
+ if (this.partId) this._repository.load(this.itemId, this.partId);
2454
+ }
2455
+ deleteFragment() {
2456
+ const range = this._textLayerService.getSelectedRange();
2457
+ if (!range) return;
2458
+ const location = this._textLayerService.getSelectedLocationForEdit(range);
2459
+ if (!location) return;
2460
+ this._dialogService.confirm("Delete Fragment", `Delete the fragment at ${location}?`).subscribe((ok) => {
2461
+ if (ok) {
2462
+ if (this._repository.getPart()?.fragments.findIndex((p) => {
2463
+ return TokenLocation.parse(p.location)?.overlaps(location);
2464
+ }) === -1) return;
2465
+ this._repository.deleteFragment(location);
2466
+ }
2467
+ });
2468
+ }
2469
+ deleteFragmentFromHint(hint) {
2470
+ const loc = TokenLocation.parse(hint.location);
2471
+ if (loc) this._repository.deleteFragment(loc);
2472
+ }
2473
+ refreshBreakChance() {
2474
+ this._repository.refreshBreakChance();
2475
+ }
2476
+ navigateToFragmentEditor(loc) {
2477
+ const part = this._repository.getPart();
2478
+ if (!part) return;
2479
+ const { route, rid } = this._libraryRouteService.buildFragmentEditorRoute(this._editedItemRepository.getFacet().partDefinitions, part.itemId, part.id, part.typeId, part.roleId, loc);
2480
+ this._router.navigate([route], rid ? { queryParams: { rid: part.roleId } } : {});
2481
+ }
2482
+ editFragment() {
2483
+ const range = this._textLayerService.getSelectedRange();
2484
+ if (!range) return;
2485
+ const location = this._textLayerService.getSelectedLocationForEdit(range);
2486
+ if (location) this.navigateToFragmentEditor(location.toString());
2487
+ }
2488
+ editFragmentFromHint(hint) {
2489
+ this.navigateToFragmentEditor(hint.location);
2490
+ }
2491
+ addFragment() {
2492
+ const range = this._textLayerService.getSelectedRange();
2493
+ if (!range) return;
2494
+ const location = this._textLayerService.getSelectedLocationForNew(range, this._repository.getBaseText() || "");
2495
+ if (location) this.navigateToFragmentEditor(location.toString());
2496
+ }
2497
+ moveFragmentFromHint(hint) {
2498
+ if (!this.pickedLocation || this.pickedLocation === hint.location || !this.partId) return;
2499
+ this._repository.applyLayerPatches(this.partId, [`mov ${hint.location} ${this.pickedLocation}`]);
2500
+ }
2501
+ applyLayerPatches(patches) {
2502
+ if (this.partId) this._repository.applyLayerPatches(this.partId, patches);
2503
+ }
2504
+ pickLocation() {
2505
+ const range = this._textLayerService.getSelectedRange();
2506
+ if (!range) return;
2507
+ const location = this._textLayerService.getSelectedLocationForNew(range, this._repository.getBaseText() || "");
2508
+ if (location) this.pickedLocation = location.toString();
2509
+ }
2510
+ close() {
2511
+ this._router.navigate(["/items", this.itemId]);
2512
+ }
2513
+ static ɵfac = i0.ɵɵngDeclareFactory({
2514
+ minVersion: "12.0.0",
2515
+ version: "22.2.0",
2516
+ ngImport: i0,
2517
+ type: TokenTextLayerPartFeatureComponent,
2518
+ deps: [
2519
+ { token: i1.ActivatedRoute },
2520
+ { token: i1.Router },
2521
+ { token: i4$2.EditedLayerRepository },
2522
+ { token: i4$1.TextLayerService },
2523
+ { token: i4$1.LibraryRouteService },
2524
+ { token: i4.EditedItemRepository },
2525
+ { token: i5.DialogService },
2526
+ { token: i3.UserLevelService }
2527
+ ],
2528
+ target: i0.ɵɵFactoryTarget.Component
2529
+ });
2530
+ static ɵcmp = i0.ɵɵngDeclareComponent({
2531
+ minVersion: "17.0.0",
2532
+ version: "22.2.0",
2533
+ type: TokenTextLayerPartFeatureComponent,
2534
+ isStandalone: true,
2535
+ selector: "cadmus-token-text-layer-part-feature",
2536
+ ngImport: i0,
2537
+ template: "<cadmus-current-item-bar></cadmus-current-item-bar>\n<mat-card appearance=\"outlined\">\n <mat-card-header>\n <div mat-card-avatar>\n <mat-icon>view_headline</mat-icon>\n </div>\n <mat-card-title>\n Token-Based Text Layers\n <button type=\"button\" mat-icon-button (click)=\"refreshBreakChance()\">\n @switch (breakChance$ | async) { @case (-1) {\n <mat-icon matTooltip=\"Checking...\">refresh</mat-icon>\n } @case (0) {\n <mat-icon matTooltip=\"Valid\">check_circle</mat-icon>\n } @case (1) {\n <mat-icon matTooltip=\"Potentially broken\" class=\"mat-warn\"\n >warning</mat-icon\n >\n } @case (2) {\n <mat-icon matTooltip=\"Broken\" class=\"mat-warn\">error</mat-icon>\n } }\n </button>\n </mat-card-title>\n <cadmus-current-layer-part-bar/>\n </mat-card-header>\n @if (!(loading$ | async)) {\n <mat-card-actions>\n <mat-toolbar>\n <button\n mat-icon-button\n type=\"button\"\n (click)=\"editFragment()\"\n matTooltip=\"Edit the selected fragment\"\n >\n <mat-icon>edit</mat-icon>\n </button>\n <button\n mat-icon-button\n type=\"button\"\n (click)=\"deleteFragment()\"\n matTooltip=\"Delete the selected fragment\"\n >\n <mat-icon class=\"mat-warn\">delete</mat-icon>\n </button>\n <button\n mat-icon-button\n type=\"button\"\n matTooltip=\"Larger text\"\n (click)=\"makeLarger()\"\n [disabled]=\"textSize >= 24\"\n >\n <mat-icon>format_size</mat-icon>\n </button>\n <button\n mat-icon-button\n type=\"button\"\n matTooltip=\"Smaller text\"\n (click)=\"makeSmaller()\"\n [disabled]=\"textSize <= 12\"\n >\n <mat-icon>text_fields</mat-icon>\n </button>\n <button\n mat-icon-button\n type=\"button\"\n (click)=\"pickLocation()\"\n matTooltip=\"Pick the selection location for a new fragment\"\n >\n <mat-icon>info</mat-icon>\n </button>\n <button\n mat-icon-button\n type=\"button\"\n (click)=\"addFragment()\"\n matTooltip=\"Add a new fragment at selection\"\n >\n <mat-icon class=\"mat-primary\">add_circle</mat-icon>\n </button>\n <span>{{ pickedLocation }}</span>\n </mat-toolbar>\n </mat-card-actions>\n }\n <mat-card-content fxLayout=\"row\">\n @if (loading$ | async) {\n <mat-progress-bar mode=\"indeterminate\"/>\n }\n\n <div [style.font-size]=\"textSize + 'px'\">\n @if (baseText$ | async; as baseText) {\n <cadmus-decorated-token-text\n [baseText]=\"baseText\"\n [locations]=\"(locations$ | async) || []\"\n />\n }\n </div>\n </mat-card-content>\n <div>\n <button\n type=\"button\"\n mat-flat-button\n class=\"mat-warn\"\n matTooltip=\"Close this editor\"\n (click)=\"close()\"\n >\n <mat-icon>cancel</mat-icon>\n close\n </button>\n </div>\n @if (layerHints$ | async; as layerHints) {\n <mat-expansion-panel>\n <mat-expansion-panel-header>\n <mat-panel-title>Layer hints</mat-panel-title>\n <mat-panel-description>{{ layerHints.length }}</mat-panel-description>\n </mat-expansion-panel-header>\n <cadmus-layer-hints\n [hints]=\"layerHints\"\n [disabled]=\"(loading$ | async) || (saving$ | async) ? true : false\"\n [readonly]=\"userLevel < 2\"\n [targetLocation]=\"pickedLocation\"\n (requestEdit)=\"editFragmentFromHint($event)\"\n (requestDelete)=\"deleteFragmentFromHint($event)\"\n (requestMove)=\"moveFragmentFromHint($event)\"\n (requestPatch)=\"applyLayerPatches($event)\"\n />\n </mat-expansion-panel>\n }\n</mat-card>\n",
2538
+ styles: [""],
2539
+ dependencies: [
2540
+ {
2541
+ kind: "component",
2542
+ type: MatCard,
2543
+ selector: "mat-card",
2544
+ inputs: ["appearance"],
2545
+ exportAs: ["matCard"]
2546
+ },
2547
+ {
2548
+ kind: "component",
2549
+ type: MatCardHeader,
2550
+ selector: "mat-card-header"
2551
+ },
2552
+ {
2553
+ kind: "directive",
2554
+ type: MatCardAvatar,
2555
+ selector: "[mat-card-avatar], [matCardAvatar]"
2556
+ },
2557
+ {
2558
+ kind: "component",
2559
+ type: MatIcon,
2560
+ selector: "mat-icon",
2561
+ inputs: [
2562
+ "color",
2563
+ "inline",
2564
+ "svgIcon",
2565
+ "fontSet",
2566
+ "fontIcon"
2567
+ ],
2568
+ exportAs: ["matIcon"]
2569
+ },
2570
+ {
2571
+ kind: "directive",
2572
+ type: MatCardTitle,
2573
+ selector: "mat-card-title, [mat-card-title], [matCardTitle]"
2574
+ },
2575
+ {
2576
+ kind: "component",
2577
+ type: MatIconButton,
2578
+ selector: "button[mat-icon-button], a[mat-icon-button], button[matIconButton], a[matIconButton]",
2579
+ exportAs: ["matButton", "matAnchor"]
2580
+ },
2581
+ {
2582
+ kind: "directive",
2583
+ type: MatTooltip,
2584
+ selector: "[matTooltip]",
2585
+ inputs: [
2586
+ "matTooltipPosition",
2587
+ "matTooltipPositionAtOrigin",
2588
+ "matTooltipDisabled",
2589
+ "matTooltipShowDelay",
2590
+ "matTooltipHideDelay",
2591
+ "matTooltipTouchGestures",
2592
+ "matTooltip",
2593
+ "matTooltipClass"
2594
+ ],
2595
+ exportAs: ["matTooltip"]
2596
+ },
2597
+ {
2598
+ kind: "directive",
2599
+ type: MatCardActions,
2600
+ selector: "mat-card-actions",
2601
+ inputs: ["align"],
2602
+ exportAs: ["matCardActions"]
2603
+ },
2604
+ {
2605
+ kind: "component",
2606
+ type: MatToolbar,
2607
+ selector: "mat-toolbar",
2608
+ inputs: ["color"],
2609
+ exportAs: ["matToolbar"]
2610
+ },
2611
+ {
2612
+ kind: "directive",
2613
+ type: MatCardContent,
2614
+ selector: "mat-card-content"
2615
+ },
2616
+ {
2617
+ kind: "component",
2618
+ type: MatProgressBar,
2619
+ selector: "mat-progress-bar",
2620
+ inputs: [
2621
+ "color",
2622
+ "value",
2623
+ "bufferValue",
2624
+ "mode"
2625
+ ],
2626
+ outputs: ["animationEnd"],
2627
+ exportAs: ["matProgressBar"]
2628
+ },
2629
+ {
2630
+ kind: "component",
2631
+ type: MatButton,
2632
+ selector: " button[matButton], a[matButton], button[mat-button], button[mat-raised-button], button[mat-flat-button], button[mat-stroked-button], a[mat-button], a[mat-raised-button], a[mat-flat-button], a[mat-stroked-button] ",
2633
+ inputs: ["matButton"],
2634
+ exportAs: ["matButton", "matAnchor"]
2635
+ },
2636
+ {
2637
+ kind: "component",
2638
+ type: MatExpansionPanel,
2639
+ selector: "mat-expansion-panel",
2640
+ inputs: ["hideToggle", "togglePosition"],
2641
+ outputs: ["afterExpand", "afterCollapse"],
2642
+ exportAs: ["matExpansionPanel"]
2643
+ },
2644
+ {
2645
+ kind: "component",
2646
+ type: MatExpansionPanelHeader,
2647
+ selector: "mat-expansion-panel-header",
2648
+ inputs: [
2649
+ "expandedHeight",
2650
+ "collapsedHeight",
2651
+ "tabIndex"
2652
+ ]
2653
+ },
2654
+ {
2655
+ kind: "directive",
2656
+ type: MatExpansionPanelTitle,
2657
+ selector: "mat-panel-title"
2658
+ },
2659
+ {
2660
+ kind: "directive",
2661
+ type: MatExpansionPanelDescription,
2662
+ selector: "mat-panel-description"
2663
+ },
2664
+ {
2665
+ kind: "component",
2666
+ type: LayerHintsComponent,
2667
+ selector: "cadmus-layer-hints",
2668
+ inputs: [
2669
+ "hints",
2670
+ "targetLocation",
2671
+ "disabled",
2672
+ "readonly"
2673
+ ],
2674
+ outputs: [
2675
+ "requestEdit",
2676
+ "requestDelete",
2677
+ "requestMove",
2678
+ "requestPatch"
2679
+ ]
2680
+ },
2681
+ {
2682
+ kind: "component",
2683
+ type: CurrentItemBarComponent,
2684
+ selector: "cadmus-current-item-bar"
2685
+ },
2686
+ {
2687
+ kind: "component",
2688
+ type: CurrentLayerPartBarComponent,
2689
+ selector: "cadmus-current-layer-part-bar"
2690
+ },
2691
+ {
2692
+ kind: "component",
2693
+ type: DecoratedTokenTextComponent,
2694
+ selector: "cadmus-decorated-token-text",
2695
+ inputs: [
2696
+ "baseText",
2697
+ "locations",
2698
+ "selectedLocation"
2699
+ ]
2700
+ },
2701
+ {
2702
+ kind: "pipe",
2703
+ type: AsyncPipe,
2704
+ name: "async"
2705
+ }
2706
+ ],
2707
+ changeDetection: i0.ChangeDetectionStrategy.OnPush
2708
+ });
2709
+ };
2710
+ i0.ɵɵngDeclareClassMetadata({
2711
+ minVersion: "12.0.0",
2712
+ version: "22.2.0",
2713
+ ngImport: i0,
2714
+ type: TokenTextLayerPartFeatureComponent,
2715
+ decorators: [{
2716
+ type: Component,
2717
+ args: [{
2718
+ selector: "cadmus-token-text-layer-part-feature",
2719
+ changeDetection: ChangeDetectionStrategy.OnPush,
2720
+ imports: [
2721
+ MatCard,
2722
+ MatCardHeader,
2723
+ MatCardAvatar,
2724
+ MatIcon,
2725
+ MatCardTitle,
2726
+ MatIconButton,
2727
+ MatTooltip,
2728
+ MatCardActions,
2729
+ MatToolbar,
2730
+ MatCardContent,
2731
+ MatProgressBar,
2732
+ MatButton,
2733
+ MatExpansionPanel,
2734
+ MatExpansionPanelHeader,
2735
+ MatExpansionPanelTitle,
2736
+ MatExpansionPanelDescription,
2737
+ AsyncPipe,
2738
+ LayerHintsComponent,
2739
+ CurrentItemBarComponent,
2740
+ CurrentLayerPartBarComponent,
2741
+ DecoratedTokenTextComponent
2742
+ ],
2743
+ template: "<cadmus-current-item-bar></cadmus-current-item-bar>\n<mat-card appearance=\"outlined\">\n <mat-card-header>\n <div mat-card-avatar>\n <mat-icon>view_headline</mat-icon>\n </div>\n <mat-card-title>\n Token-Based Text Layers\n <button type=\"button\" mat-icon-button (click)=\"refreshBreakChance()\">\n @switch (breakChance$ | async) { @case (-1) {\n <mat-icon matTooltip=\"Checking...\">refresh</mat-icon>\n } @case (0) {\n <mat-icon matTooltip=\"Valid\">check_circle</mat-icon>\n } @case (1) {\n <mat-icon matTooltip=\"Potentially broken\" class=\"mat-warn\"\n >warning</mat-icon\n >\n } @case (2) {\n <mat-icon matTooltip=\"Broken\" class=\"mat-warn\">error</mat-icon>\n } }\n </button>\n </mat-card-title>\n <cadmus-current-layer-part-bar/>\n </mat-card-header>\n @if (!(loading$ | async)) {\n <mat-card-actions>\n <mat-toolbar>\n <button\n mat-icon-button\n type=\"button\"\n (click)=\"editFragment()\"\n matTooltip=\"Edit the selected fragment\"\n >\n <mat-icon>edit</mat-icon>\n </button>\n <button\n mat-icon-button\n type=\"button\"\n (click)=\"deleteFragment()\"\n matTooltip=\"Delete the selected fragment\"\n >\n <mat-icon class=\"mat-warn\">delete</mat-icon>\n </button>\n <button\n mat-icon-button\n type=\"button\"\n matTooltip=\"Larger text\"\n (click)=\"makeLarger()\"\n [disabled]=\"textSize >= 24\"\n >\n <mat-icon>format_size</mat-icon>\n </button>\n <button\n mat-icon-button\n type=\"button\"\n matTooltip=\"Smaller text\"\n (click)=\"makeSmaller()\"\n [disabled]=\"textSize <= 12\"\n >\n <mat-icon>text_fields</mat-icon>\n </button>\n <button\n mat-icon-button\n type=\"button\"\n (click)=\"pickLocation()\"\n matTooltip=\"Pick the selection location for a new fragment\"\n >\n <mat-icon>info</mat-icon>\n </button>\n <button\n mat-icon-button\n type=\"button\"\n (click)=\"addFragment()\"\n matTooltip=\"Add a new fragment at selection\"\n >\n <mat-icon class=\"mat-primary\">add_circle</mat-icon>\n </button>\n <span>{{ pickedLocation }}</span>\n </mat-toolbar>\n </mat-card-actions>\n }\n <mat-card-content fxLayout=\"row\">\n @if (loading$ | async) {\n <mat-progress-bar mode=\"indeterminate\"/>\n }\n\n <div [style.font-size]=\"textSize + 'px'\">\n @if (baseText$ | async; as baseText) {\n <cadmus-decorated-token-text\n [baseText]=\"baseText\"\n [locations]=\"(locations$ | async) || []\"\n />\n }\n </div>\n </mat-card-content>\n <div>\n <button\n type=\"button\"\n mat-flat-button\n class=\"mat-warn\"\n matTooltip=\"Close this editor\"\n (click)=\"close()\"\n >\n <mat-icon>cancel</mat-icon>\n close\n </button>\n </div>\n @if (layerHints$ | async; as layerHints) {\n <mat-expansion-panel>\n <mat-expansion-panel-header>\n <mat-panel-title>Layer hints</mat-panel-title>\n <mat-panel-description>{{ layerHints.length }}</mat-panel-description>\n </mat-expansion-panel-header>\n <cadmus-layer-hints\n [hints]=\"layerHints\"\n [disabled]=\"(loading$ | async) || (saving$ | async) ? true : false\"\n [readonly]=\"userLevel < 2\"\n [targetLocation]=\"pickedLocation\"\n (requestEdit)=\"editFragmentFromHint($event)\"\n (requestDelete)=\"deleteFragmentFromHint($event)\"\n (requestMove)=\"moveFragmentFromHint($event)\"\n (requestPatch)=\"applyLayerPatches($event)\"\n />\n </mat-expansion-panel>\n }\n</mat-card>\n"
2744
+ }]
2745
+ }],
2746
+ ctorParameters: () => [
2747
+ { type: i1.ActivatedRoute },
2748
+ { type: i1.Router },
2749
+ { type: i4$2.EditedLayerRepository },
2750
+ { type: i4$1.TextLayerService },
2751
+ { type: i4$1.LibraryRouteService },
2752
+ { type: i4.EditedItemRepository },
2753
+ { type: i5.DialogService },
2754
+ { type: i3.UserLevelService }
2755
+ ]
2756
+ });
2757
+ var TokenTextPartFeatureComponent = class TokenTextPartFeatureComponent extends EditPartFeatureBase {
2758
+ constructor(router, route, snackbar, itemService, thesaurusService, editorService) {
2759
+ super(router, route, snackbar, itemService, thesaurusService, editorService);
2760
+ }
2761
+ static ɵfac = i0.ɵɵngDeclareFactory({
2762
+ minVersion: "12.0.0",
2763
+ version: "22.2.0",
2764
+ ngImport: i0,
2765
+ type: TokenTextPartFeatureComponent,
2766
+ deps: [
2767
+ { token: i1.Router },
2768
+ { token: i1.ActivatedRoute },
2769
+ { token: i2.MatSnackBar },
2770
+ { token: i3.ItemService },
2771
+ { token: i3.ThesaurusService },
2772
+ { token: i4$2.PartEditorService }
2773
+ ],
2774
+ target: i0.ɵɵFactoryTarget.Component
2775
+ });
2776
+ static ɵcmp = i0.ɵɵngDeclareComponent({
2777
+ minVersion: "14.0.0",
2778
+ version: "22.2.0",
2779
+ type: TokenTextPartFeatureComponent,
2780
+ isStandalone: true,
2781
+ selector: "cadmus-token-text-part-feature",
2782
+ usesInheritance: true,
2783
+ ngImport: i0,
2784
+ template: "<cadmus-current-item-bar/>\r\n<cadmus-token-text-part\r\n [identity]=\"identity()\"\r\n [data]=\"$any(data())\"\r\n (dataChange)=\"save($event!.value!)\"\r\n (editorClose)=\"close()\"\r\n (dirtyChange)=\"onDirtyChange($event)\"\r\n/>\r\n",
2785
+ styles: [""],
2786
+ dependencies: [{
2787
+ kind: "component",
2788
+ type: CurrentItemBarComponent,
2789
+ selector: "cadmus-current-item-bar"
2790
+ }, {
2791
+ kind: "component",
2792
+ type: TokenTextPartComponent,
2793
+ selector: "cadmus-token-text-part"
2794
+ }],
2795
+ changeDetection: i0.ChangeDetectionStrategy.OnPush
2796
+ });
2797
+ };
2798
+ i0.ɵɵngDeclareClassMetadata({
2799
+ minVersion: "12.0.0",
2800
+ version: "22.2.0",
2801
+ ngImport: i0,
2802
+ type: TokenTextPartFeatureComponent,
2803
+ decorators: [{
2804
+ type: Component,
2805
+ args: [{
2806
+ selector: "cadmus-token-text-part-feature",
2807
+ changeDetection: ChangeDetectionStrategy.OnPush,
2808
+ imports: [CurrentItemBarComponent, TokenTextPartComponent],
2809
+ template: "<cadmus-current-item-bar/>\r\n<cadmus-token-text-part\r\n [identity]=\"identity()\"\r\n [data]=\"$any(data())\"\r\n (dataChange)=\"save($event!.value!)\"\r\n (editorClose)=\"close()\"\r\n (dirtyChange)=\"onDirtyChange($event)\"\r\n/>\r\n"
2810
+ }]
2811
+ }],
2812
+ ctorParameters: () => [
2813
+ { type: i1.Router },
2814
+ { type: i1.ActivatedRoute },
2815
+ { type: i2.MatSnackBar },
2816
+ { type: i3.ItemService },
2817
+ { type: i3.ThesaurusService },
2818
+ { type: i4$2.PartEditorService }
2819
+ ]
2820
+ });
1368
2821
  const CADMUS_PART_GENERAL_PG_ROUTES = [
1369
- {
1370
- path: `${ASSERTED_HISTORICAL_DATES_PART_TYPEID}/:pid`,
1371
- pathMatch: 'full',
1372
- component: AssertedHistoricalDateFeatureComponent,
1373
- canDeactivate: [pendingChangesGuard],
1374
- },
1375
- {
1376
- path: `${BIBLIOGRAPHY_PART_TYPEID}/:pid`,
1377
- pathMatch: 'full',
1378
- component: BibliographyPartFeatureComponent,
1379
- canDeactivate: [pendingChangesGuard],
1380
- },
1381
- {
1382
- path: `${CATEGORIES_PART_TYPEID}/:pid`,
1383
- pathMatch: 'full',
1384
- component: CategoriesPartFeatureComponent,
1385
- canDeactivate: [pendingChangesGuard],
1386
- },
1387
- {
1388
- path: `${COMMENT_PART_TYPEID}/:pid`,
1389
- pathMatch: 'full',
1390
- component: CommentPartFeatureComponent,
1391
- canDeactivate: [pendingChangesGuard],
1392
- },
1393
- {
1394
- path: `${CHRONOTOPES_PART_TYPEID}/:pid`,
1395
- pathMatch: 'full',
1396
- component: ChronotopesPartFeatureComponent,
1397
- canDeactivate: [pendingChangesGuard],
1398
- },
1399
- {
1400
- path: `${DECORATED_COUNTS_PART_TYPEID}/:pid`,
1401
- pathMatch: 'full',
1402
- component: DecoratedCountsPartFeatureComponent,
1403
- canDeactivate: [pendingChangesGuard],
1404
- },
1405
- {
1406
- path: `${DISTRICT_LOCATION_PART_TYPEID}/:pid`,
1407
- pathMatch: 'full',
1408
- component: DistrictLocationPartFeatureComponent,
1409
- canDeactivate: [pendingChangesGuard],
1410
- },
1411
- {
1412
- path: `${DOC_REFERENCES_PART_TYPEID}/:pid`,
1413
- pathMatch: 'full',
1414
- component: DocReferencesPartFeatureComponent,
1415
- canDeactivate: [pendingChangesGuard],
1416
- },
1417
- {
1418
- path: `${EXTERNAL_IDS_PART_TYPEID}/:pid`,
1419
- pathMatch: 'full',
1420
- component: ExternalIdsPartFeatureComponent,
1421
- canDeactivate: [pendingChangesGuard],
1422
- },
1423
- {
1424
- path: `${FLAGS_PART_TYPEID}/:pid`,
1425
- pathMatch: 'full',
1426
- component: FlagsPartFeatureComponent,
1427
- canDeactivate: [pendingChangesGuard],
1428
- },
1429
- {
1430
- path: `${HISTORICAL_DATE_PART_TYPEID}/:pid`,
1431
- pathMatch: 'full',
1432
- component: HistoricalDatePartFeatureComponent,
1433
- canDeactivate: [pendingChangesGuard],
1434
- },
1435
- {
1436
- path: `${HISTORICAL_EVENTS_PART_TYPEID}/:pid`,
1437
- pathMatch: 'full',
1438
- component: HistoricalEventsPartFeatureComponent,
1439
- canDeactivate: [pendingChangesGuard],
1440
- },
1441
- {
1442
- path: `${KEYWORDS_PART_TYPEID}/:pid`,
1443
- pathMatch: 'full',
1444
- component: KeywordsPartFeatureComponent,
1445
- canDeactivate: [pendingChangesGuard],
1446
- },
1447
- {
1448
- path: `${INDEX_KEYWORDS_PART_TYPEID}/:pid`,
1449
- pathMatch: 'full',
1450
- component: IndexKeywordsPartFeatureComponent,
1451
- canDeactivate: [pendingChangesGuard],
1452
- },
1453
- {
1454
- path: `${METADATA_PART_TYPEID}/:pid`,
1455
- pathMatch: 'full',
1456
- component: MetadataPartFeatureComponent,
1457
- canDeactivate: [pendingChangesGuard],
1458
- },
1459
- {
1460
- path: `${NAMES_PART_TYPEID}/:pid`,
1461
- pathMatch: 'full',
1462
- component: NamesPartFeatureComponent,
1463
- canDeactivate: [pendingChangesGuard],
1464
- },
1465
- {
1466
- path: `${NOTE_PART_TYPEID}/:pid`,
1467
- pathMatch: 'full',
1468
- component: NotePartFeatureComponent,
1469
- canDeactivate: [pendingChangesGuard],
1470
- },
1471
- {
1472
- path: `${PHYSICAL_MEASUREMENTS_PART_TYPEID}/:pid`,
1473
- pathMatch: 'full',
1474
- component: PhysicalMeasurementsPartFeatureComponent,
1475
- canDeactivate: [pendingChangesGuard],
1476
- },
1477
- {
1478
- path: `${PHYSICAL_STATES_PART_TYPEID}/:pid`,
1479
- pathMatch: 'full',
1480
- component: PhysicalStatesPartFeatureComponent,
1481
- canDeactivate: [pendingChangesGuard],
1482
- },
1483
- {
1484
- path: `${PIN_LINKS_PART_TYPEID}/:pid`,
1485
- pathMatch: 'full',
1486
- component: PinLinksPartFeatureComponent,
1487
- canDeactivate: [pendingChangesGuard],
1488
- },
1489
- {
1490
- path: `${TOKEN_TEXT_PART_TYPEID}/:pid`,
1491
- pathMatch: 'full',
1492
- component: TokenTextPartFeatureComponent,
1493
- canDeactivate: [pendingChangesGuard],
1494
- },
1495
- {
1496
- path: `${TILED_TEXT_PART_TYPEID}/:pid`,
1497
- pathMatch: 'full',
1498
- component: TiledTextPartFeatureComponent,
1499
- canDeactivate: [pendingChangesGuard],
1500
- },
1501
- {
1502
- path: 'it.vedph.token-text-layer/:pid',
1503
- pathMatch: 'full',
1504
- component: TokenTextLayerPartFeatureComponent,
1505
- canDeactivate: [pendingChangesGuard],
1506
- },
1507
- {
1508
- path: 'it.vedph.tiled-text-layer/:pid',
1509
- pathMatch: 'full',
1510
- component: TiledTextLayerPartFeatureComponent,
1511
- canDeactivate: [pendingChangesGuard],
1512
- },
1513
- {
1514
- path: `fragment/:pid/${COMMENT_FRAGMENT_TYPEID}/:loc`,
1515
- pathMatch: 'full',
1516
- component: CommentFragmentFeatureComponent,
1517
- canDeactivate: [pendingChangesGuard],
1518
- },
1519
- {
1520
- path: `fragment/:pid/${CHRONOLOGY_FRAGMENT_TYPEID}/:loc`,
1521
- pathMatch: 'full',
1522
- component: ChronologyFragmentFeatureComponent,
1523
- canDeactivate: [pendingChangesGuard],
1524
- },
1525
- {
1526
- path: `fragment/:pid/${PIN_LINKS_FRAGMENT_TYPEID}/:loc`,
1527
- pathMatch: 'full',
1528
- component: PinLinksFragmentFeatureComponent,
1529
- canDeactivate: [pendingChangesGuard],
1530
- },
2822
+ {
2823
+ path: `${ASSERTED_HISTORICAL_DATES_PART_TYPEID}/:pid`,
2824
+ pathMatch: "full",
2825
+ component: AssertedHistoricalDateFeatureComponent,
2826
+ canDeactivate: [pendingChangesGuard]
2827
+ },
2828
+ {
2829
+ path: `${BIBLIOGRAPHY_PART_TYPEID}/:pid`,
2830
+ pathMatch: "full",
2831
+ component: BibliographyPartFeatureComponent,
2832
+ canDeactivate: [pendingChangesGuard]
2833
+ },
2834
+ {
2835
+ path: `${CATEGORIES_PART_TYPEID}/:pid`,
2836
+ pathMatch: "full",
2837
+ component: CategoriesPartFeatureComponent,
2838
+ canDeactivate: [pendingChangesGuard]
2839
+ },
2840
+ {
2841
+ path: `${COMMENT_PART_TYPEID}/:pid`,
2842
+ pathMatch: "full",
2843
+ component: CommentPartFeatureComponent,
2844
+ canDeactivate: [pendingChangesGuard]
2845
+ },
2846
+ {
2847
+ path: `${CHRONOTOPES_PART_TYPEID}/:pid`,
2848
+ pathMatch: "full",
2849
+ component: ChronotopesPartFeatureComponent,
2850
+ canDeactivate: [pendingChangesGuard]
2851
+ },
2852
+ {
2853
+ path: `${DECORATED_COUNTS_PART_TYPEID}/:pid`,
2854
+ pathMatch: "full",
2855
+ component: DecoratedCountsPartFeatureComponent,
2856
+ canDeactivate: [pendingChangesGuard]
2857
+ },
2858
+ {
2859
+ path: `${DISTRICT_LOCATION_PART_TYPEID}/:pid`,
2860
+ pathMatch: "full",
2861
+ component: DistrictLocationPartFeatureComponent,
2862
+ canDeactivate: [pendingChangesGuard]
2863
+ },
2864
+ {
2865
+ path: `${DOC_REFERENCES_PART_TYPEID}/:pid`,
2866
+ pathMatch: "full",
2867
+ component: DocReferencesPartFeatureComponent,
2868
+ canDeactivate: [pendingChangesGuard]
2869
+ },
2870
+ {
2871
+ path: `${EXTERNAL_IDS_PART_TYPEID}/:pid`,
2872
+ pathMatch: "full",
2873
+ component: ExternalIdsPartFeatureComponent,
2874
+ canDeactivate: [pendingChangesGuard]
2875
+ },
2876
+ {
2877
+ path: `${FLAGS_PART_TYPEID}/:pid`,
2878
+ pathMatch: "full",
2879
+ component: FlagsPartFeatureComponent,
2880
+ canDeactivate: [pendingChangesGuard]
2881
+ },
2882
+ {
2883
+ path: `${HISTORICAL_DATE_PART_TYPEID}/:pid`,
2884
+ pathMatch: "full",
2885
+ component: HistoricalDatePartFeatureComponent,
2886
+ canDeactivate: [pendingChangesGuard]
2887
+ },
2888
+ {
2889
+ path: `${HISTORICAL_EVENTS_PART_TYPEID}/:pid`,
2890
+ pathMatch: "full",
2891
+ component: HistoricalEventsPartFeatureComponent,
2892
+ canDeactivate: [pendingChangesGuard]
2893
+ },
2894
+ {
2895
+ path: `${KEYWORDS_PART_TYPEID}/:pid`,
2896
+ pathMatch: "full",
2897
+ component: KeywordsPartFeatureComponent,
2898
+ canDeactivate: [pendingChangesGuard]
2899
+ },
2900
+ {
2901
+ path: `${INDEX_KEYWORDS_PART_TYPEID}/:pid`,
2902
+ pathMatch: "full",
2903
+ component: IndexKeywordsPartFeatureComponent,
2904
+ canDeactivate: [pendingChangesGuard]
2905
+ },
2906
+ {
2907
+ path: `${METADATA_PART_TYPEID}/:pid`,
2908
+ pathMatch: "full",
2909
+ component: MetadataPartFeatureComponent,
2910
+ canDeactivate: [pendingChangesGuard]
2911
+ },
2912
+ {
2913
+ path: `${NAMES_PART_TYPEID}/:pid`,
2914
+ pathMatch: "full",
2915
+ component: NamesPartFeatureComponent,
2916
+ canDeactivate: [pendingChangesGuard]
2917
+ },
2918
+ {
2919
+ path: `${NOTE_PART_TYPEID}/:pid`,
2920
+ pathMatch: "full",
2921
+ component: NotePartFeatureComponent,
2922
+ canDeactivate: [pendingChangesGuard]
2923
+ },
2924
+ {
2925
+ path: `${PHYSICAL_MEASUREMENTS_PART_TYPEID}/:pid`,
2926
+ pathMatch: "full",
2927
+ component: PhysicalMeasurementsPartFeatureComponent,
2928
+ canDeactivate: [pendingChangesGuard]
2929
+ },
2930
+ {
2931
+ path: `${PHYSICAL_STATES_PART_TYPEID}/:pid`,
2932
+ pathMatch: "full",
2933
+ component: PhysicalStatesPartFeatureComponent,
2934
+ canDeactivate: [pendingChangesGuard]
2935
+ },
2936
+ {
2937
+ path: `${PIN_LINKS_PART_TYPEID}/:pid`,
2938
+ pathMatch: "full",
2939
+ component: PinLinksPartFeatureComponent,
2940
+ canDeactivate: [pendingChangesGuard]
2941
+ },
2942
+ {
2943
+ path: `${TOKEN_TEXT_PART_TYPEID}/:pid`,
2944
+ pathMatch: "full",
2945
+ component: TokenTextPartFeatureComponent,
2946
+ canDeactivate: [pendingChangesGuard]
2947
+ },
2948
+ {
2949
+ path: `${TILED_TEXT_PART_TYPEID}/:pid`,
2950
+ pathMatch: "full",
2951
+ component: TiledTextPartFeatureComponent,
2952
+ canDeactivate: [pendingChangesGuard]
2953
+ },
2954
+ {
2955
+ path: "it.vedph.token-text-layer/:pid",
2956
+ pathMatch: "full",
2957
+ component: TokenTextLayerPartFeatureComponent,
2958
+ canDeactivate: [pendingChangesGuard]
2959
+ },
2960
+ {
2961
+ path: "it.vedph.tiled-text-layer/:pid",
2962
+ pathMatch: "full",
2963
+ component: TiledTextLayerPartFeatureComponent,
2964
+ canDeactivate: [pendingChangesGuard]
2965
+ },
2966
+ {
2967
+ path: `fragment/:pid/${COMMENT_FRAGMENT_TYPEID}/:loc`,
2968
+ pathMatch: "full",
2969
+ component: CommentFragmentFeatureComponent,
2970
+ canDeactivate: [pendingChangesGuard]
2971
+ },
2972
+ {
2973
+ path: `fragment/:pid/${CHRONOLOGY_FRAGMENT_TYPEID}/:loc`,
2974
+ pathMatch: "full",
2975
+ component: ChronologyFragmentFeatureComponent,
2976
+ canDeactivate: [pendingChangesGuard]
2977
+ },
2978
+ {
2979
+ path: `fragment/:pid/${PIN_LINKS_FRAGMENT_TYPEID}/:loc`,
2980
+ pathMatch: "full",
2981
+ component: PinLinksFragmentFeatureComponent,
2982
+ canDeactivate: [pendingChangesGuard]
2983
+ }
1531
2984
  ];
1532
-
1533
- /*
1534
- * Public API Surface of cadmus-part-general-pg
1535
- */
1536
-
1537
- /**
1538
- * Generated bundle index. Do not edit.
1539
- */
1540
-
1541
2985
  export { AssertedHistoricalDateFeatureComponent, BibliographyPartFeatureComponent, CADMUS_PART_GENERAL_PG_ROUTES, CategoriesPartFeatureComponent, ChronologyFragmentFeatureComponent, ChronotopesPartFeatureComponent, CommentFragmentFeatureComponent, CommentPartFeatureComponent, DecoratedCountsPartFeatureComponent, DistrictLocationPartFeatureComponent, DocReferencesPartFeatureComponent, ExternalIdsPartFeatureComponent, FlagsPartFeatureComponent, HistoricalDatePartFeatureComponent, HistoricalEventsPartFeatureComponent, IndexKeywordsPartFeatureComponent, KeywordsPartFeatureComponent, MetadataPartFeatureComponent, NamesPartFeatureComponent, NotePartFeatureComponent, PhysicalMeasurementsPartFeatureComponent, PhysicalStatesPartFeatureComponent, PinLinksFragmentFeatureComponent, PinLinksPartFeatureComponent, TiledTextLayerPartFeatureComponent, TiledTextPartFeatureComponent, TokenTextLayerPartFeatureComponent, TokenTextPartFeatureComponent };
1542
- //# sourceMappingURL=myrmidon-cadmus-part-general-pg.mjs.map
2986
+
2987
+ //# sourceMappingURL=myrmidon-cadmus-part-general-pg.mjs.map