geonetwork-ui 2.5.0-dev.f8f8616a0 → 2.6.0-dev.01d2b5fc0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/esm2022/libs/api/metadata-converter/src/lib/gn4/gn4.field.mapper.mjs +2 -2
- package/esm2022/libs/api/metadata-converter/src/lib/iso19139/write-parts.mjs +4 -2
- package/esm2022/libs/api/repository/src/lib/gn4/gn4-repository.mjs +4 -8
- package/esm2022/libs/api/repository/src/lib/gn4/platform/gn4-platform.service.mjs +14 -13
- package/esm2022/libs/feature/editor/src/lib/components/constraint-card/constraint-card.component.mjs +2 -2
- package/esm2022/libs/feature/editor/src/lib/components/generic-keywords/generic-keywords.component.mjs +2 -2
- package/esm2022/libs/feature/editor/src/lib/components/import-record/import-record.component.mjs +5 -5
- package/esm2022/libs/feature/editor/src/lib/components/online-service-resource-input/online-service-resource-input.component.mjs +5 -3
- package/esm2022/libs/feature/editor/src/lib/components/record-form/form-field/form-field-contacts/form-field-contacts.component.mjs +2 -2
- package/esm2022/libs/feature/editor/src/lib/components/record-form/form-field/form-field-contacts-for-resource/form-field-contacts-for-resource.component.mjs +9 -12
- package/esm2022/libs/feature/editor/src/lib/components/record-form/form-field/form-field-online-link-resources/form-field-online-link-resources.component.mjs +2 -2
- package/esm2022/libs/feature/editor/src/lib/components/record-form/form-field/form-field-online-resources/form-field-online-resources.component.mjs +2 -2
- package/esm2022/libs/feature/editor/src/lib/components/record-form/form-field/form-field-overviews/form-field-overviews.component.mjs +3 -3
- package/esm2022/libs/feature/map/src/lib/add-layer-from-catalog/add-layer-from-catalog.component.mjs +1 -1
- package/esm2022/libs/feature/search/src/lib/fuzzy-search/fuzzy-search.component.mjs +12 -3
- package/esm2022/libs/ui/dataviz/src/lib/data-table/data-table.component.mjs +3 -3
- package/esm2022/libs/ui/elements/src/lib/image-input/image-input.component.mjs +50 -35
- package/esm2022/libs/ui/elements/src/lib/metadata-quality/metadata-quality.component.mjs +23 -3
- package/esm2022/libs/ui/inputs/src/lib/autocomplete/autocomplete.component.mjs +53 -7
- package/esm2022/libs/ui/inputs/src/lib/file-input/file-input.component.mjs +2 -2
- package/esm2022/libs/ui/inputs/src/lib/url-input/url-input.component.mjs +10 -3
- package/esm2022/libs/ui/search/src/lib/record-preview-row/record-preview-row.component.mjs +3 -3
- package/esm2022/libs/ui/widgets/src/lib/progress-bar/progress-bar.component.mjs +10 -3
- package/esm2022/translations/de.json +1 -1
- package/esm2022/translations/en.json +1 -1
- package/esm2022/translations/fr.json +1 -1
- package/esm2022/translations/it.json +1 -1
- package/fesm2022/geonetwork-ui.mjs +202 -105
- package/fesm2022/geonetwork-ui.mjs.map +1 -1
- package/libs/api/metadata-converter/src/lib/iso19139/write-parts.d.ts.map +1 -1
- package/libs/api/repository/src/lib/gn4/gn4-repository.d.ts.map +1 -1
- package/libs/api/repository/src/lib/gn4/platform/gn4-platform.service.d.ts.map +1 -1
- package/libs/feature/editor/src/lib/components/online-service-resource-input/online-service-resource-input.component.d.ts +1 -0
- package/libs/feature/editor/src/lib/components/online-service-resource-input/online-service-resource-input.component.d.ts.map +1 -1
- package/libs/feature/editor/src/lib/components/record-form/form-field/form-field-contacts-for-resource/form-field-contacts-for-resource.component.d.ts +1 -0
- package/libs/feature/editor/src/lib/components/record-form/form-field/form-field-contacts-for-resource/form-field-contacts-for-resource.component.d.ts.map +1 -1
- package/libs/feature/search/src/lib/fuzzy-search/fuzzy-search.component.d.ts +4 -1
- package/libs/feature/search/src/lib/fuzzy-search/fuzzy-search.component.d.ts.map +1 -1
- package/libs/ui/elements/src/lib/image-input/image-input.component.d.ts +11 -9
- package/libs/ui/elements/src/lib/image-input/image-input.component.d.ts.map +1 -1
- package/libs/ui/elements/src/lib/metadata-quality/metadata-quality.component.d.ts.map +1 -1
- package/libs/ui/inputs/src/lib/autocomplete/autocomplete.component.d.ts +8 -1
- package/libs/ui/inputs/src/lib/autocomplete/autocomplete.component.d.ts.map +1 -1
- package/libs/ui/inputs/src/lib/url-input/url-input.component.d.ts +5 -3
- package/libs/ui/inputs/src/lib/url-input/url-input.component.d.ts.map +1 -1
- package/libs/ui/widgets/src/lib/progress-bar/progress-bar.component.d.ts +1 -1
- package/libs/ui/widgets/src/lib/progress-bar/progress-bar.component.d.ts.map +1 -1
- package/package.json +1 -1
- package/src/libs/api/metadata-converter/src/lib/gn4/gn4.field.mapper.ts +1 -1
- package/src/libs/api/metadata-converter/src/lib/iso19139/write-parts.ts +19 -17
- package/src/libs/api/repository/src/lib/gn4/gn4-repository.ts +3 -11
- package/src/libs/api/repository/src/lib/gn4/platform/gn4-platform.service.ts +24 -26
- package/src/libs/common/fixtures/src/lib/records.fixtures.ts +90 -0
- package/src/libs/feature/editor/src/lib/components/import-record/import-record.component.ts +3 -3
- package/src/libs/feature/editor/src/lib/components/online-service-resource-input/online-service-resource-input.component.html +1 -0
- package/src/libs/feature/editor/src/lib/components/online-service-resource-input/online-service-resource-input.component.ts +2 -0
- package/src/libs/feature/editor/src/lib/components/record-form/form-field/form-field-contacts-for-resource/form-field-contacts-for-resource.component.html +1 -0
- package/src/libs/feature/editor/src/lib/components/record-form/form-field/form-field-contacts-for-resource/form-field-contacts-for-resource.component.ts +10 -11
- package/src/libs/feature/editor/src/lib/components/record-form/form-field/form-field-overviews/form-field-overviews.component.ts +1 -1
- package/src/libs/feature/search/src/lib/fuzzy-search/fuzzy-search.component.html +2 -0
- package/src/libs/feature/search/src/lib/fuzzy-search/fuzzy-search.component.ts +6 -0
- package/src/libs/ui/dataviz/src/lib/data-table/data-table.component.html +3 -1
- package/src/libs/ui/elements/src/lib/image-input/image-input.component.html +20 -15
- package/src/libs/ui/elements/src/lib/image-input/image-input.component.ts +49 -35
- package/src/libs/ui/elements/src/lib/metadata-quality/metadata-quality.component.html +21 -9
- package/src/libs/ui/elements/src/lib/metadata-quality/metadata-quality.component.ts +13 -0
- package/src/libs/ui/inputs/src/lib/autocomplete/autocomplete.component.html +36 -19
- package/src/libs/ui/inputs/src/lib/autocomplete/autocomplete.component.ts +43 -2
- package/src/libs/ui/inputs/src/lib/url-input/url-input.component.ts +8 -1
- package/src/libs/ui/search/src/lib/record-preview-row/record-preview-row.component.html +1 -1
- package/src/libs/ui/widgets/src/lib/progress-bar/progress-bar.component.html +36 -11
- package/src/libs/ui/widgets/src/lib/progress-bar/progress-bar.component.ts +9 -1
- package/translations/de.json +1 -1
- package/translations/en.json +1 -1
- package/translations/fr.json +1 -1
- package/translations/it.json +1 -1
|
@@ -16,7 +16,7 @@ import { TranslateMessageFormatCompiler } from 'ngx-translate-messageformat-comp
|
|
|
16
16
|
import { TranslateHttpLoader } from '@ngx-translate/http-loader';
|
|
17
17
|
import { map as map$1, catchError, tap as tap$1, shareReplay, filter, startWith, withLatestFrom, switchMap as switchMap$1, take, mergeMap, throttleTime, distinctUntilChanged, debounceTime, finalize, first as first$1, share, pairwise, delay, defaultIfEmpty, toArray } from 'rxjs/operators';
|
|
18
18
|
import * as i1$2 from '@angular/common';
|
|
19
|
-
import { CommonModule, NgOptimizedImage, DatePipe, NgIf } from '@angular/common';
|
|
19
|
+
import { CommonModule, NgSwitch, NgSwitchCase, NgSwitchDefault, NgOptimizedImage, DatePipe, NgIf } from '@angular/common';
|
|
20
20
|
import { of, map as map$2, lastValueFrom, Subject, switchMap, combineLatest, from, exhaustMap, throwError, forkJoin, takeLast, firstValueFrom, merge, BehaviorSubject, fromEvent, animationFrameScheduler, ReplaySubject, Subscription, first, distinctUntilChanged as distinctUntilChanged$1, filter as filter$1, tap as tap$2, Observable, buffer, debounceTime as debounceTime$1, combineLatestWith, catchError as catchError$1, timer, takeUntil, EMPTY, mergeMap as mergeMap$1, startWith as startWith$1, withLatestFrom as withLatestFrom$1, shareReplay as shareReplay$1, pairwise as pairwise$1 } from 'rxjs';
|
|
21
21
|
import { lt, valid, coerce, satisfies, ltr } from 'semver';
|
|
22
22
|
import chroma from 'chroma-js';
|
|
@@ -26,7 +26,7 @@ import { createAction, props, createReducer, on, createFeatureSelector, createSe
|
|
|
26
26
|
import EmblaCarousel from 'embla-carousel';
|
|
27
27
|
import * as i2$2 from '@ng-icons/core';
|
|
28
28
|
import { provideIcons, NgIcon, NgIconComponent, provideNgIconsConfig, NgIconsModule } from '@ng-icons/core';
|
|
29
|
-
import { iconoirNavArrowRight, iconoirNavArrowLeft, iconoirNavArrowDown, iconoirNavArrowUp, iconoirSearch, iconoirCalendar, iconoirLink, iconoirArrowUp, iconoirCloudUpload, iconoirFramePlusIn, iconoirMediaImage, iconoirMediaImageXmark, iconoirBin, iconoirPlus, iconoirUser, iconoirLock, iconoirImport, iconoirLightBulbOn, iconoirArrowLeft, iconoirAttachment, iconoirRefresh } from '@ng-icons/iconoir';
|
|
29
|
+
import { iconoirNavArrowRight, iconoirNavArrowLeft, iconoirNavArrowDown, iconoirNavArrowUp, iconoirSearch, iconoirLongArrowDownLeft, iconoirCalendar, iconoirLink, iconoirArrowUp, iconoirCloudUpload, iconoirFramePlusIn, iconoirMediaImage, iconoirMediaImageXmark, iconoirBin, iconoirPlus, iconoirUser, iconoirLock, iconoirImport, iconoirLightBulbOn, iconoirArrowLeft, iconoirAttachment, iconoirRefresh } from '@ng-icons/iconoir';
|
|
30
30
|
import { matExpandMore, matExpandLess, matAdd, matRemove, matClose, matContentCopy, matSearch, matStar, matStarBorder, matChevronLeft, matChevronRight, matArrowForward, matArrowBack, matCheck, matWarningAmber, matMoreHoriz, matFace, matQuestionMark, matMoodBad, matZoomOutMap, matOpenInNew, matMailOutline, matPersonOutline, matCheckCircleOutline, matWarning, matMoreVert, matCorporateFare } from '@ng-icons/material-icons/baseline';
|
|
31
31
|
import * as i1$4 from '@angular/material/tooltip';
|
|
32
32
|
import { MatTooltipModule } from '@angular/material/tooltip';
|
|
@@ -41,7 +41,7 @@ import { TagInputModule } from 'ngx-chips';
|
|
|
41
41
|
import * as i1$5 from '@angular/material/progress-spinner';
|
|
42
42
|
import { MatProgressSpinnerModule } from '@angular/material/progress-spinner';
|
|
43
43
|
import tippy from 'tippy.js';
|
|
44
|
-
import { matErrorOutlineOutline, matCloudDownloadOutline, matComputerOutline, matCallOutline, matLocationOnOutline, matMailOutline as matMailOutline$1, matWarningAmberOutline,
|
|
44
|
+
import { matErrorOutlineOutline, matInfoOutline, matCloudDownloadOutline, matComputerOutline, matCallOutline, matLocationOnOutline, matMailOutline as matMailOutline$1, matWarningAmberOutline, matCloseOutline, matSendOutline, matMapOutline, matHomeWorkOutline, matSwipeOutline, matLayersOutline, matAddCircleOutlineOutline } from '@ng-icons/material-icons/outline';
|
|
45
45
|
import * as i2 from '@angular/material/core';
|
|
46
46
|
import { MatNativeDateModule, MAT_DATE_LOCALE, DateAdapter, MAT_DATE_FORMATS } from '@angular/material/core';
|
|
47
47
|
import * as i1$7 from '@angular/material/checkbox';
|
|
@@ -1842,7 +1842,9 @@ function writeSpatialRepresentation$1(record, rootEl) {
|
|
|
1842
1842
|
pipe(findOrCreateIdentification(), findNestedChildOrCreate('gmd:spatialRepresentationType', 'gmd:MD_SpatialRepresentationTypeCode'), writeAttribute('codeList', 'http://standards.iso.org/iso/19139/resources/gmxCodelists.xml#MD_SpatialRepresentationTypeCode'), writeAttribute('codeListValue', record.spatialRepresentation))(rootEl);
|
|
1843
1843
|
}
|
|
1844
1844
|
function writeGraphicOverviews(record, rootEl) {
|
|
1845
|
-
pipe(findOrCreateIdentification(), removeChildrenByName('gmd:graphicOverview'), appendChildren(...record.overviews
|
|
1845
|
+
pipe(findOrCreateIdentification(), removeChildrenByName('gmd:graphicOverview'), appendChildren(...record.overviews
|
|
1846
|
+
.filter((overview) => overview.url)
|
|
1847
|
+
.map((overview) => pipe(createNestedElement('gmd:graphicOverview', 'gmd:MD_BrowseGraphic'), appendChildren(pipe(createElement('gmd:fileName'), writeCharacterString(overview.url.toString()))), 'description' in overview
|
|
1846
1848
|
? appendChildren(pipe(createElement('gmd:fileDescription'), writeCharacterString(overview.description)))
|
|
1847
1849
|
: noop))))(rootEl);
|
|
1848
1850
|
}
|
|
@@ -19072,7 +19074,7 @@ var de = {
|
|
|
19072
19074
|
"search.error.receivedError": "Ein Fehler ist aufgetreten",
|
|
19073
19075
|
"search.error.recordHasnolink": "",
|
|
19074
19076
|
"search.error.recordNotFound": "Der Datensatz mit der Kennung \"{ id }\" konnte nicht gefunden werden.",
|
|
19075
|
-
"search.field.any.placeholder": "Suche
|
|
19077
|
+
"search.field.any.placeholder": "Suche im katalog ...",
|
|
19076
19078
|
"search.field.sortBy": "Sortieren nach:",
|
|
19077
19079
|
"search.filters.availableServices.download": "",
|
|
19078
19080
|
"search.filters.availableServices.view": "",
|
|
@@ -19617,7 +19619,7 @@ var en = {
|
|
|
19617
19619
|
"search.error.receivedError": "An error was received",
|
|
19618
19620
|
"search.error.recordHasnolink": "This dataset currently has no link yet, please come back later.",
|
|
19619
19621
|
"search.error.recordNotFound": "The dataset with identifier \"{ id }\" could not be found.",
|
|
19620
|
-
"search.field.any.placeholder": "Search
|
|
19622
|
+
"search.field.any.placeholder": "Search in the catalog ...",
|
|
19621
19623
|
"search.field.sortBy": "Sort by:",
|
|
19622
19624
|
"search.filters.availableServices.download": "",
|
|
19623
19625
|
"search.filters.availableServices.view": "",
|
|
@@ -20707,7 +20709,7 @@ var fr = {
|
|
|
20707
20709
|
"search.error.receivedError": "Erreur retournée",
|
|
20708
20710
|
"search.error.recordHasnolink": "Ce jeu de données n'a pas encore de lien, réessayez plus tard s'il vous plaît.",
|
|
20709
20711
|
"search.error.recordNotFound": "Cette donnée n'a pu être trouvée.",
|
|
20710
|
-
"search.field.any.placeholder": "Rechercher
|
|
20712
|
+
"search.field.any.placeholder": "Rechercher dans le catalogue...",
|
|
20711
20713
|
"search.field.sortBy": "Trier par :",
|
|
20712
20714
|
"search.filters.availableServices.download": "",
|
|
20713
20715
|
"search.filters.availableServices.view": "",
|
|
@@ -21252,7 +21254,7 @@ var it = {
|
|
|
21252
21254
|
"search.error.receivedError": "Errore restituito",
|
|
21253
21255
|
"search.error.recordHasnolink": "Questo dataset non ha ancora alcun collegamento, riprova più tardi.",
|
|
21254
21256
|
"search.error.recordNotFound": "Impossibile trovare questi dati.",
|
|
21255
|
-
"search.field.any.placeholder": "Cerca
|
|
21257
|
+
"search.field.any.placeholder": "Cerca del catalogo...",
|
|
21256
21258
|
"search.field.sortBy": "Ordina per:",
|
|
21257
21259
|
"search.filters.availableServices.download": "",
|
|
21258
21260
|
"search.filters.availableServices.view": "",
|
|
@@ -22592,7 +22594,7 @@ class Gn4FieldMapper {
|
|
|
22592
22594
|
featureTypes: selectField(source, 'featureTypes'),
|
|
22593
22595
|
}, output),
|
|
22594
22596
|
related: (output, source) => {
|
|
22595
|
-
const fcatSource = selectField(getFirstValue(selectField(selectField(source, 'related'), 'fcats')), '_source');
|
|
22597
|
+
const fcatSource = selectField(getFirstValue(selectField(selectField(source, 'related'), 'fcats')) ?? {}, '_source');
|
|
22596
22598
|
const featureCatalogIdentifier = selectField(fcatSource, 'uuid');
|
|
22597
22599
|
return featureCatalogIdentifier
|
|
22598
22600
|
? this.addExtra({ featureCatalogIdentifier }, output)
|
|
@@ -23544,14 +23546,10 @@ class Gn4Repository {
|
|
|
23544
23546
|
return this.getExternalRecordAsXml(recordDownloadUrl).pipe(exhaustMap(async (fetchedRecordAsXml) => {
|
|
23545
23547
|
const converter = findConverterForDocument(fetchedRecordAsXml);
|
|
23546
23548
|
const record = await converter.readRecord(fetchedRecordAsXml);
|
|
23547
|
-
const tempId = this.generateTemporaryId();
|
|
23548
23549
|
record.title = `${record.title} (Copy)`;
|
|
23549
|
-
record
|
|
23550
|
-
|
|
23551
|
-
|
|
23552
|
-
this._draftsChanged.next();
|
|
23553
|
-
return tempId;
|
|
23554
|
-
}), catchError((error) => {
|
|
23550
|
+
await converter.writeRecord(record, fetchedRecordAsXml);
|
|
23551
|
+
return this.saveRecord(record, '', false);
|
|
23552
|
+
}), exhaustMap((uuidObservable) => uuidObservable), catchError((error) => {
|
|
23555
23553
|
return throwError(() => error);
|
|
23556
23554
|
}));
|
|
23557
23555
|
}
|
|
@@ -25202,18 +25200,19 @@ class Gn4PlatformService {
|
|
|
25202
25200
|
return combineLatest([
|
|
25203
25201
|
this.recordsApiService.getAssociatedResources(record.uniqueIdentifier),
|
|
25204
25202
|
this.recordsApiService.getAllResources(record.uniqueIdentifier),
|
|
25205
|
-
]).pipe(map$1(([
|
|
25206
|
-
|
|
25207
|
-
|
|
25208
|
-
|
|
25209
|
-
...(
|
|
25210
|
-
|
|
25211
|
-
|
|
25212
|
-
|
|
25213
|
-
.map((
|
|
25214
|
-
|
|
25215
|
-
|
|
25216
|
-
|
|
25203
|
+
]).pipe(map$1(([associated, attachments]) => {
|
|
25204
|
+
const { onlines = [], thumbnails = [] } = associated;
|
|
25205
|
+
const urlsToKeep = [
|
|
25206
|
+
...(Array.isArray(onlines) ? onlines : []),
|
|
25207
|
+
...(Array.isArray(thumbnails) ? thumbnails : []),
|
|
25208
|
+
].map((resource) => Object.values(resource.url)[0]);
|
|
25209
|
+
const fileToDelete = attachments
|
|
25210
|
+
.filter((attachment) => !urlsToKeep.includes(attachment.url))
|
|
25211
|
+
.map((attachment) => attachment.filename);
|
|
25212
|
+
return fileToDelete;
|
|
25213
|
+
}), mergeMap((filesToDelete) => filesToDelete.length
|
|
25214
|
+
? forkJoin(filesToDelete.map((filename) => this.recordsApiService.delResource(record.uniqueIdentifier, filename))).pipe(map$1(() => undefined))
|
|
25215
|
+
: of(undefined)), catchError((error) => {
|
|
25217
25216
|
console.error('Error while cleaning attachments:', error);
|
|
25218
25217
|
throw error;
|
|
25219
25218
|
}));
|
|
@@ -25916,14 +25915,20 @@ class ProgressBarComponent {
|
|
|
25916
25915
|
innerBar: 'bg-secondary-lighter',
|
|
25917
25916
|
text: 'text-white',
|
|
25918
25917
|
};
|
|
25918
|
+
case 'light':
|
|
25919
|
+
return {
|
|
25920
|
+
outerBar: 'bg-primary-white',
|
|
25921
|
+
innerBar: 'bg-primary',
|
|
25922
|
+
text: 'text-main',
|
|
25923
|
+
};
|
|
25919
25924
|
}
|
|
25920
25925
|
}
|
|
25921
25926
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: ProgressBarComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
25922
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.2.13", type: ProgressBarComponent, isStandalone: true, selector: "gn-ui-progress-bar", inputs: { value: "value", type: "type" }, ngImport: i0, template: "<div class=\"flex h-full {{ color.outerBar }} rounded-t-lg rounded-b-lg\">\n
|
|
25927
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.2.13", type: ProgressBarComponent, isStandalone: true, selector: "gn-ui-progress-bar", inputs: { value: "value", type: "type" }, ngImport: i0, template: "<ng-container [ngSwitch]=\"type\">\n <!-- Light Theme -->\n <ng-container *ngSwitchCase=\"'light'\">\n <div class=\"flex items-center relative\">\n <div\n class=\"flex-shrink-0 {{ color.text }} text-xs font-medium mr-2\n text-opacity-100 !text-slate-800\"\n >\n {{ progress }}%\n </div>\n <div class=\"flex-grow h-[6px] w-full {{ color.outerBar }} rounded-full\">\n <div\n [style.width.%]=\"progress\"\n class=\"{{ color.innerBar }} transition-width duration-500\n ease-in-out rounded-full shadow-sm h-full\"\n ></div>\n </div>\n </div>\n </ng-container>\n\n <!-- Default / Primary / Secondary Themes -->\n <ng-container *ngSwitchDefault>\n <div class=\"flex h-full {{ color.outerBar }} rounded-t-lg rounded-b-lg\">\n <div\n [style.width.%]=\"progress\"\n class=\"flex {{ color.innerBar }} my-1 mx-1 transition-width\n duration-500 ease-in-out rounded-t-md rounded-b-md shadow-xl\"\n >\n <div\n class=\"flex items-center pl-2 py-1 {{ color.text }} font-bold text-4\"\n >\n {{ progress }}%\n </div>\n </div>\n </div>\n </ng-container>\n</ng-container>\n", styles: [".font-bold{font-weight:var(--progress-bar-font-weight, \"bold\")}\n"], dependencies: [{ kind: "directive", type: NgSwitch, selector: "[ngSwitch]", inputs: ["ngSwitch"] }, { kind: "directive", type: NgSwitchCase, selector: "[ngSwitchCase]", inputs: ["ngSwitchCase"] }, { kind: "directive", type: NgSwitchDefault, selector: "[ngSwitchDefault]" }] }); }
|
|
25923
25928
|
}
|
|
25924
25929
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: ProgressBarComponent, decorators: [{
|
|
25925
25930
|
type: Component,
|
|
25926
|
-
args: [{ selector: 'gn-ui-progress-bar', standalone: true, template: "<div class=\"flex h-full {{ color.outerBar }} rounded-t-lg rounded-b-lg\">\n
|
|
25931
|
+
args: [{ selector: 'gn-ui-progress-bar', standalone: true, imports: [NgSwitch, NgSwitchCase, NgSwitchDefault], template: "<ng-container [ngSwitch]=\"type\">\n <!-- Light Theme -->\n <ng-container *ngSwitchCase=\"'light'\">\n <div class=\"flex items-center relative\">\n <div\n class=\"flex-shrink-0 {{ color.text }} text-xs font-medium mr-2\n text-opacity-100 !text-slate-800\"\n >\n {{ progress }}%\n </div>\n <div class=\"flex-grow h-[6px] w-full {{ color.outerBar }} rounded-full\">\n <div\n [style.width.%]=\"progress\"\n class=\"{{ color.innerBar }} transition-width duration-500\n ease-in-out rounded-full shadow-sm h-full\"\n ></div>\n </div>\n </div>\n </ng-container>\n\n <!-- Default / Primary / Secondary Themes -->\n <ng-container *ngSwitchDefault>\n <div class=\"flex h-full {{ color.outerBar }} rounded-t-lg rounded-b-lg\">\n <div\n [style.width.%]=\"progress\"\n class=\"flex {{ color.innerBar }} my-1 mx-1 transition-width\n duration-500 ease-in-out rounded-t-md rounded-b-md shadow-xl\"\n >\n <div\n class=\"flex items-center pl-2 py-1 {{ color.text }} font-bold text-4\"\n >\n {{ progress }}%\n </div>\n </div>\n </div>\n </ng-container>\n</ng-container>\n", styles: [".font-bold{font-weight:var(--progress-bar-font-weight, \"bold\")}\n"] }]
|
|
25927
25932
|
}], propDecorators: { value: [{
|
|
25928
25933
|
type: Input
|
|
25929
25934
|
}], type: [{
|
|
@@ -26120,8 +26125,28 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImpo
|
|
|
26120
26125
|
}] } });
|
|
26121
26126
|
|
|
26122
26127
|
class AutocompleteComponent {
|
|
26128
|
+
get displayEnterBtn() {
|
|
26129
|
+
return this.enterButton && this.allowSubmit && !this.searchActive;
|
|
26130
|
+
}
|
|
26131
|
+
getExtraClass() {
|
|
26132
|
+
if (this.allowSubmit) {
|
|
26133
|
+
if (this.enterButton) {
|
|
26134
|
+
return 'border rounded-lg absolute w-8 h-8 right-[calc(var(--icon-width)+var(--icon-padding))] inset-y-[--icon-padding]';
|
|
26135
|
+
}
|
|
26136
|
+
else {
|
|
26137
|
+
return 'border rounded-lg absolute w-8 h-8 right-[calc(var(--icon-width)+0.25*var(--icon-width))] inset-y-[calc(0.25*var(--icon-width))]';
|
|
26138
|
+
}
|
|
26139
|
+
}
|
|
26140
|
+
else {
|
|
26141
|
+
if (!this.enterButton) {
|
|
26142
|
+
return 'border rounded-lg absolute w-8 h-8 right-2 inset-y-2';
|
|
26143
|
+
}
|
|
26144
|
+
}
|
|
26145
|
+
return 'border rounded-lg absolute w-8 h-8';
|
|
26146
|
+
}
|
|
26123
26147
|
constructor(cdRef) {
|
|
26124
26148
|
this.cdRef = cdRef;
|
|
26149
|
+
this.enterButton = false;
|
|
26125
26150
|
this.clearOnSelection = false;
|
|
26126
26151
|
this.preventCompleteOnSelection = false;
|
|
26127
26152
|
this.autoFocus = false;
|
|
@@ -26132,6 +26157,7 @@ class AutocompleteComponent {
|
|
|
26132
26157
|
this.itemSelected = new EventEmitter();
|
|
26133
26158
|
this.inputSubmitted = new EventEmitter();
|
|
26134
26159
|
this.inputCleared = new EventEmitter();
|
|
26160
|
+
this.isSearchActive = new EventEmitter();
|
|
26135
26161
|
this.control = new UntypedFormControl();
|
|
26136
26162
|
this.cancelEnter = true;
|
|
26137
26163
|
this.selectionSubject = new ReplaySubject(1);
|
|
@@ -26139,6 +26165,8 @@ class AutocompleteComponent {
|
|
|
26139
26165
|
this.error = null;
|
|
26140
26166
|
this.subscription = new Subscription();
|
|
26141
26167
|
this.lastPosition = null;
|
|
26168
|
+
this.enterBtnPosition = 0;
|
|
26169
|
+
this.searchActive = false;
|
|
26142
26170
|
this.displayWithFn = (item) => item.toString();
|
|
26143
26171
|
this.displayWithFnInternal = (item) => {
|
|
26144
26172
|
if (item === null || item === undefined)
|
|
@@ -26169,6 +26197,14 @@ class AutocompleteComponent {
|
|
|
26169
26197
|
const previousTextValue = this.displayWithFnInternal(value.previousValue);
|
|
26170
26198
|
const currentTextValue = this.displayWithFnInternal(value.currentValue);
|
|
26171
26199
|
if (previousTextValue !== currentTextValue) {
|
|
26200
|
+
if (currentTextValue) {
|
|
26201
|
+
this.searchActive = true;
|
|
26202
|
+
this.isSearchActive.emit(true);
|
|
26203
|
+
}
|
|
26204
|
+
else {
|
|
26205
|
+
this.searchActive = false;
|
|
26206
|
+
this.isSearchActive.emit(false);
|
|
26207
|
+
}
|
|
26172
26208
|
this.updateInputValue(value.currentValue);
|
|
26173
26209
|
}
|
|
26174
26210
|
}
|
|
@@ -26241,6 +26277,8 @@ class AutocompleteComponent {
|
|
|
26241
26277
|
}
|
|
26242
26278
|
clear() {
|
|
26243
26279
|
this.inputRef.nativeElement.value = '';
|
|
26280
|
+
this.searchActive = false;
|
|
26281
|
+
this.isSearchActive.emit(false);
|
|
26244
26282
|
this.inputCleared.emit();
|
|
26245
26283
|
this.selectionSubject
|
|
26246
26284
|
.pipe(take(1))
|
|
@@ -26249,6 +26287,8 @@ class AutocompleteComponent {
|
|
|
26249
26287
|
}
|
|
26250
26288
|
handleEnter(any) {
|
|
26251
26289
|
if (!this.cancelEnter && this.allowSubmit) {
|
|
26290
|
+
this.isSearchActive.emit(true);
|
|
26291
|
+
this.searchActive = true;
|
|
26252
26292
|
this.inputSubmitted.emit(any);
|
|
26253
26293
|
}
|
|
26254
26294
|
}
|
|
@@ -26276,16 +26316,22 @@ class AutocompleteComponent {
|
|
|
26276
26316
|
this.control.setValue('');
|
|
26277
26317
|
}
|
|
26278
26318
|
}
|
|
26319
|
+
handleInput(event) {
|
|
26320
|
+
this.searchActive = false;
|
|
26321
|
+
this.isSearchActive.emit(false);
|
|
26322
|
+
this.enterBtnPosition = event.target['value'].length * 8 + 80;
|
|
26323
|
+
}
|
|
26279
26324
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: AutocompleteComponent, deps: [{ token: i0.ChangeDetectorRef }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
26280
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.2.13", type: AutocompleteComponent, isStandalone: true, selector: "gn-ui-autocomplete", inputs: { placeholder: "placeholder", action: "action", value: "value", clearOnSelection: "clearOnSelection", preventCompleteOnSelection: "preventCompleteOnSelection", autoFocus: "autoFocus", minCharacterCount: "minCharacterCount", allowSubmit: "allowSubmit", forceTrackPosition: "forceTrackPosition", displayWithFn: "displayWithFn" }, outputs: { itemSelected: "itemSelected", inputSubmitted: "inputSubmitted", inputCleared: "inputCleared" }, providers: [
|
|
26325
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.2.13", type: AutocompleteComponent, isStandalone: true, selector: "gn-ui-autocomplete", inputs: { placeholder: "placeholder", enterButton: "enterButton", action: "action", value: "value", clearOnSelection: "clearOnSelection", preventCompleteOnSelection: "preventCompleteOnSelection", autoFocus: "autoFocus", minCharacterCount: "minCharacterCount", allowSubmit: "allowSubmit", forceTrackPosition: "forceTrackPosition", displayWithFn: "displayWithFn" }, outputs: { itemSelected: "itemSelected", inputSubmitted: "inputSubmitted", inputCleared: "inputCleared", isSearchActive: "isSearchActive" }, providers: [
|
|
26281
26326
|
provideIcons({
|
|
26282
26327
|
iconoirSearch,
|
|
26283
26328
|
matClose,
|
|
26329
|
+
iconoirLongArrowDownLeft,
|
|
26284
26330
|
}),
|
|
26285
26331
|
provideNgIconsConfig({
|
|
26286
|
-
size: '1.
|
|
26332
|
+
size: '1.75rem',
|
|
26287
26333
|
}),
|
|
26288
|
-
], viewQueries: [{ propertyName: "triggerRef", first: true, predicate: MatAutocompleteTrigger, descendants: true }, { propertyName: "autocomplete", first: true, predicate: MatAutocomplete, descendants: true }, { propertyName: "inputRef", first: true, predicate: ["searchInput"], descendants: true }], usesOnChanges: true, ngImport: i0, template: "<span class=\"w-full inline-block relative\">\n <div\n class=\"absolute inset-y-[--icon-padding] left-[--icon-padding] w-[--icon-width] pointer-events-none\"\n *ngIf=\"!allowSubmit\"\n >\n <ng-icon name=\"iconoirSearch\" class=\"text-primary search\"></ng-icon>\n </div>\n <input\n
|
|
26334
|
+
], viewQueries: [{ propertyName: "triggerRef", first: true, predicate: MatAutocompleteTrigger, descendants: true }, { propertyName: "autocomplete", first: true, predicate: MatAutocomplete, descendants: true }, { propertyName: "inputRef", first: true, predicate: ["searchInput"], descendants: true }], usesOnChanges: true, ngImport: i0, template: "<span class=\"w-full inline-block relative\">\n <div\n class=\"absolute inset-y-[--icon-padding] left-[--icon-padding] w-[--icon-width] pointer-events-none\"\n *ngIf=\"!allowSubmit\"\n >\n <ng-icon name=\"iconoirSearch\" class=\"text-primary search\"></ng-icon>\n </div>\n <div class=\"flex flex-row\">\n <input\n #searchInput\n type=\"text\"\n class=\"gn-ui-text-input\"\n (input)=\"handleInput($event)\"\n [placeholder]=\"placeholder\"\n [formControl]=\"control\"\n [matAutocomplete]=\"auto\"\n (keyup.enter)=\"handleEnter(searchInput.value)\"\n [ngClass]=\"{\n 'text-primary': searchActive && enterButton,\n 'text-gray-900': !searchActive,\n 'px-[--icon-width]': !allowSubmit,\n }\"\n />\n <gn-ui-button\n type=\"gray\"\n *ngIf=\"searchInput.value && displayEnterBtn\"\n extraClass=\"w-32 h-8 !opacity-100\"\n [ngStyle]=\"{ left: enterBtnPosition + 'px' }\"\n class=\"absolute\"\n disabled=\"true\"\n >\n <ng-icon\n name=\"iconoirLongArrowDownLeft\"\n class=\"!w-4 text-gray-900 font-bold\"\n ></ng-icon>\n <span translate class=\"text-bold text-gray-900 font-bold\">\n Enter to search\n </span>\n </gn-ui-button>\n </div>\n <gn-ui-button\n type=\"primary\"\n [extraClass]=\"getExtraClass()\"\n data-test=\"clear-btn\"\n *ngIf=\"searchInput.value\"\n aria-label=\"Clear\"\n (buttonClick)=\"clear()\"\n >\n <ng-icon class=\"text-white\" name=\"matClose\"></ng-icon>\n </gn-ui-button>\n <gn-ui-button\n type=\"light\"\n extraClass=\"border-0 border-l-[1px] border-gray-300 hover:border-gray-500 text-primary hover:text-primary-darkest focus:text-primary-darkest absolute inset-y-[--icon-padding] right-[--icon-padding]\"\n aria-label=\"Trigger search\"\n *ngIf=\"allowSubmit\"\n data-test=\"autocomplete-submit-btn\"\n (buttonClick)=\"handleClickSearch()\"\n >\n <ng-icon name=\"iconoirSearch\"></ng-icon>\n </gn-ui-button>\n\n <gn-ui-popup-alert\n *ngIf=\"error\"\n class=\"absolute mt-2 w-full top-[100%] left-0\"\n icon=\"matErrorOutlineOutline\"\n position=\"top\"\n type=\"warning\"\n >\n <span translate>search.autocomplete.error</span>\n {{ error }}\n </gn-ui-popup-alert>\n</span>\n\n<mat-autocomplete\n #auto=\"matAutocomplete\"\n (optionSelected)=\"handleSelection($event)\"\n [displayWith]=\"displayWithFnInternal\"\n>\n <mat-option\n *ngFor=\"let suggestion of suggestions$ | async\"\n [value]=\"suggestion\"\n class=\"p-2 suggestion\"\n >\n {{ displayWithFnInternal(suggestion) }}\n </mat-option>\n</mat-autocomplete>\n", styles: ["span{--icon-padding: var(--gn-ui-text-input-border-size, 2px);--icon-width: calc(var(--gn-ui-text-input-padding, .6em) * 2 + 1.25em)}span>*:not(gn-ui-popup-alert){font-size:var(--gn-ui-text-input-font-size, 1em)}input:placeholder-shown{text-overflow:ellipsis}gn-ui-button{--gn-ui-button-rounded: 0;--gn-ui-button-width: var(--icon-width);--gn-ui-button-padding: 0;font-size:1em}ng-icon.search{margin-top:.6rem;margin-left:.6rem}gn-ui-button:last-of-type{--gn-ui-button-rounded: 0 var(--gn-ui-text-input-rounded, .25em) var(--gn-ui-text-input-rounded, .25em) 0}.mat-mdc-option.suggestion.mat-mdc-option-active{background-color:var(--color-primary-lightest)}\n"], dependencies: [{ kind: "component", type: PopupAlertComponent, selector: "gn-ui-popup-alert", inputs: ["icon", "type", "position"] }, { kind: "ngmodule", type: MatAutocompleteModule }, { kind: "component", type: i1$6.MatAutocomplete, selector: "mat-autocomplete", inputs: ["aria-label", "aria-labelledby", "displayWith", "autoActiveFirstOption", "autoSelectActiveOption", "requireSelection", "panelWidth", "disableRipple", "class", "hideSingleSelectionIndicator"], outputs: ["optionSelected", "opened", "closed", "optionActivated"], exportAs: ["matAutocomplete"] }, { kind: "component", type: i2.MatOption, selector: "mat-option", inputs: ["value", "id", "disabled"], outputs: ["onSelectionChange"], exportAs: ["matOption"] }, { kind: "directive", type: i1$6.MatAutocompleteTrigger, selector: "input[matAutocomplete], textarea[matAutocomplete]", inputs: ["matAutocomplete", "matAutocompletePosition", "matAutocompleteConnectedTo", "autocomplete", "matAutocompleteDisabled"], exportAs: ["matAutocompleteTrigger"] }, { kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1$2.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i1$2.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i1$2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i1$2.NgStyle, selector: "[ngStyle]", inputs: ["ngStyle"] }, { kind: "pipe", type: i1$2.AsyncPipe, name: "async" }, { kind: "ngmodule", type: TranslateModule }, { kind: "directive", type: i1$1.TranslateDirective, selector: "[translate],[ngx-translate]", inputs: ["translate", "translateParams"] }, { kind: "ngmodule", type: ReactiveFormsModule }, { kind: "directive", type: i2$1.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i2$1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2$1.FormControlDirective, selector: "[formControl]", inputs: ["formControl", "disabled", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }, { kind: "component", type: ButtonComponent, selector: "gn-ui-button", inputs: ["type", "disabled", "extraClass"], outputs: ["buttonClick"] }, { kind: "component", type: NgIconComponent, selector: "ng-icon", inputs: ["name", "svg", "size", "strokeWidth", "color"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
26289
26335
|
}
|
|
26290
26336
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: AutocompleteComponent, decorators: [{
|
|
26291
26337
|
type: Component,
|
|
@@ -26301,13 +26347,16 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImpo
|
|
|
26301
26347
|
provideIcons({
|
|
26302
26348
|
iconoirSearch,
|
|
26303
26349
|
matClose,
|
|
26350
|
+
iconoirLongArrowDownLeft,
|
|
26304
26351
|
}),
|
|
26305
26352
|
provideNgIconsConfig({
|
|
26306
|
-
size: '1.
|
|
26353
|
+
size: '1.75rem',
|
|
26307
26354
|
}),
|
|
26308
|
-
], template: "<span class=\"w-full inline-block relative\">\n <div\n class=\"absolute inset-y-[--icon-padding] left-[--icon-padding] w-[--icon-width] pointer-events-none\"\n *ngIf=\"!allowSubmit\"\n >\n <ng-icon name=\"iconoirSearch\" class=\"text-primary search\"></ng-icon>\n </div>\n <input\n
|
|
26355
|
+
], template: "<span class=\"w-full inline-block relative\">\n <div\n class=\"absolute inset-y-[--icon-padding] left-[--icon-padding] w-[--icon-width] pointer-events-none\"\n *ngIf=\"!allowSubmit\"\n >\n <ng-icon name=\"iconoirSearch\" class=\"text-primary search\"></ng-icon>\n </div>\n <div class=\"flex flex-row\">\n <input\n #searchInput\n type=\"text\"\n class=\"gn-ui-text-input\"\n (input)=\"handleInput($event)\"\n [placeholder]=\"placeholder\"\n [formControl]=\"control\"\n [matAutocomplete]=\"auto\"\n (keyup.enter)=\"handleEnter(searchInput.value)\"\n [ngClass]=\"{\n 'text-primary': searchActive && enterButton,\n 'text-gray-900': !searchActive,\n 'px-[--icon-width]': !allowSubmit,\n }\"\n />\n <gn-ui-button\n type=\"gray\"\n *ngIf=\"searchInput.value && displayEnterBtn\"\n extraClass=\"w-32 h-8 !opacity-100\"\n [ngStyle]=\"{ left: enterBtnPosition + 'px' }\"\n class=\"absolute\"\n disabled=\"true\"\n >\n <ng-icon\n name=\"iconoirLongArrowDownLeft\"\n class=\"!w-4 text-gray-900 font-bold\"\n ></ng-icon>\n <span translate class=\"text-bold text-gray-900 font-bold\">\n Enter to search\n </span>\n </gn-ui-button>\n </div>\n <gn-ui-button\n type=\"primary\"\n [extraClass]=\"getExtraClass()\"\n data-test=\"clear-btn\"\n *ngIf=\"searchInput.value\"\n aria-label=\"Clear\"\n (buttonClick)=\"clear()\"\n >\n <ng-icon class=\"text-white\" name=\"matClose\"></ng-icon>\n </gn-ui-button>\n <gn-ui-button\n type=\"light\"\n extraClass=\"border-0 border-l-[1px] border-gray-300 hover:border-gray-500 text-primary hover:text-primary-darkest focus:text-primary-darkest absolute inset-y-[--icon-padding] right-[--icon-padding]\"\n aria-label=\"Trigger search\"\n *ngIf=\"allowSubmit\"\n data-test=\"autocomplete-submit-btn\"\n (buttonClick)=\"handleClickSearch()\"\n >\n <ng-icon name=\"iconoirSearch\"></ng-icon>\n </gn-ui-button>\n\n <gn-ui-popup-alert\n *ngIf=\"error\"\n class=\"absolute mt-2 w-full top-[100%] left-0\"\n icon=\"matErrorOutlineOutline\"\n position=\"top\"\n type=\"warning\"\n >\n <span translate>search.autocomplete.error</span>\n {{ error }}\n </gn-ui-popup-alert>\n</span>\n\n<mat-autocomplete\n #auto=\"matAutocomplete\"\n (optionSelected)=\"handleSelection($event)\"\n [displayWith]=\"displayWithFnInternal\"\n>\n <mat-option\n *ngFor=\"let suggestion of suggestions$ | async\"\n [value]=\"suggestion\"\n class=\"p-2 suggestion\"\n >\n {{ displayWithFnInternal(suggestion) }}\n </mat-option>\n</mat-autocomplete>\n", styles: ["span{--icon-padding: var(--gn-ui-text-input-border-size, 2px);--icon-width: calc(var(--gn-ui-text-input-padding, .6em) * 2 + 1.25em)}span>*:not(gn-ui-popup-alert){font-size:var(--gn-ui-text-input-font-size, 1em)}input:placeholder-shown{text-overflow:ellipsis}gn-ui-button{--gn-ui-button-rounded: 0;--gn-ui-button-width: var(--icon-width);--gn-ui-button-padding: 0;font-size:1em}ng-icon.search{margin-top:.6rem;margin-left:.6rem}gn-ui-button:last-of-type{--gn-ui-button-rounded: 0 var(--gn-ui-text-input-rounded, .25em) var(--gn-ui-text-input-rounded, .25em) 0}.mat-mdc-option.suggestion.mat-mdc-option-active{background-color:var(--color-primary-lightest)}\n"] }]
|
|
26309
26356
|
}], ctorParameters: () => [{ type: i0.ChangeDetectorRef }], propDecorators: { placeholder: [{
|
|
26310
26357
|
type: Input
|
|
26358
|
+
}], enterButton: [{
|
|
26359
|
+
type: Input
|
|
26311
26360
|
}], action: [{
|
|
26312
26361
|
type: Input
|
|
26313
26362
|
}], value: [{
|
|
@@ -26330,6 +26379,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImpo
|
|
|
26330
26379
|
type: Output
|
|
26331
26380
|
}], inputCleared: [{
|
|
26332
26381
|
type: Output
|
|
26382
|
+
}], isSearchActive: [{
|
|
26383
|
+
type: Output
|
|
26333
26384
|
}], triggerRef: [{
|
|
26334
26385
|
type: ViewChild,
|
|
26335
26386
|
args: [MatAutocompleteTrigger]
|
|
@@ -27113,6 +27164,11 @@ class UrlInputComponent {
|
|
|
27113
27164
|
this.uploadClick = new EventEmitter();
|
|
27114
27165
|
this.inputValue = '';
|
|
27115
27166
|
}
|
|
27167
|
+
ngOnChanges(changes) {
|
|
27168
|
+
if (changes['resetUrlOnChange']) {
|
|
27169
|
+
this.inputValue = '';
|
|
27170
|
+
}
|
|
27171
|
+
}
|
|
27116
27172
|
handleInput(event) {
|
|
27117
27173
|
const value = event.target.value;
|
|
27118
27174
|
this.inputValue = value;
|
|
@@ -27139,12 +27195,12 @@ class UrlInputComponent {
|
|
|
27139
27195
|
}
|
|
27140
27196
|
}
|
|
27141
27197
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: UrlInputComponent, deps: [{ token: i0.ChangeDetectorRef }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
27142
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.2.13", type: UrlInputComponent, isStandalone: true, selector: "gn-ui-url-input", inputs: { value: "value", extraClass: "extraClass", placeholder: "placeholder", disabled: "disabled", showValidateButton: "showValidateButton" }, outputs: { valueChange: "valueChange", uploadClick: "uploadClick" }, providers: [
|
|
27198
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.2.13", type: UrlInputComponent, isStandalone: true, selector: "gn-ui-url-input", inputs: { value: "value", extraClass: "extraClass", placeholder: "placeholder", disabled: "disabled", showValidateButton: "showValidateButton", resetUrlOnChange: "resetUrlOnChange" }, outputs: { valueChange: "valueChange", uploadClick: "uploadClick" }, providers: [
|
|
27143
27199
|
provideIcons({ iconoirLink, iconoirArrowUp }),
|
|
27144
27200
|
provideNgIconsConfig({
|
|
27145
27201
|
size: '1.5em',
|
|
27146
27202
|
}),
|
|
27147
|
-
], ngImport: i0, template: "<span class=\"w-full inline-block relative\">\n <input\n #input\n class=\"gn-ui-text-input gn-ui-url-input px-[var(--text-padding)]\"\n [ngClass]=\"extraClass\"\n type=\"url\"\n [value]=\"inputValue\"\n (input)=\"handleInput($event)\"\n (keydown.enter)=\"handleUpload(input)\"\n [placeholder]=\"placeholder\"\n [attr.aria-label]=\"placeholder\"\n [disabled]=\"disabled\"\n />\n <div\n class=\"absolute inset-y-[var(--side-padding)] left-[var(--2x-side-padding)] grid justify-center items-center pointer-events-none\"\n [ngClass]=\"{\n 'text-primary': !disabled,\n 'text-primary-lightest': disabled,\n }\"\n >\n <ng-icon name=\"iconoirLink\"></ng-icon>\n </div>\n <gn-ui-button\n *ngIf=\"showValidateButton\"\n extraClass=\"absolute inset-y-[var(--side-padding)] right-[var(--side-padding)]\"\n type=\"primary\"\n [disabled]=\"disabled || input.value === '' || !isValidUrl(input.value)\"\n (buttonClick)=\"handleUpload(input)\"\n >\n <ng-content>\n <ng-icon name=\"iconoirArrowUp\"></ng-icon>\n </ng-content>\n </gn-ui-button>\n</span>\n", styles: [":host{--gn-ui-button-rounded: 8px;--gn-ui-button-width: 32px;--gn-ui-button-padding: 0;--side-padding: calc(var(--gn-ui-text-input-padding, .6rem) - 6px);--2x-side-padding: calc(var(--side-padding) * 2);--text-padding: calc(var(--side-padding) + 40px)}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1$2.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i1$2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: ButtonComponent, selector: "gn-ui-button", inputs: ["type", "disabled", "extraClass"], outputs: ["buttonClick"] }, { kind: "component", type: NgIconComponent, selector: "ng-icon", inputs: ["name", "svg", "size", "strokeWidth", "color"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
27203
|
+
], usesOnChanges: true, ngImport: i0, template: "<span class=\"w-full inline-block relative\">\n <input\n #input\n class=\"gn-ui-text-input gn-ui-url-input px-[var(--text-padding)]\"\n [ngClass]=\"extraClass\"\n type=\"url\"\n [value]=\"inputValue\"\n (input)=\"handleInput($event)\"\n (keydown.enter)=\"handleUpload(input)\"\n [placeholder]=\"placeholder\"\n [attr.aria-label]=\"placeholder\"\n [disabled]=\"disabled\"\n />\n <div\n class=\"absolute inset-y-[var(--side-padding)] left-[var(--2x-side-padding)] grid justify-center items-center pointer-events-none\"\n [ngClass]=\"{\n 'text-primary': !disabled,\n 'text-primary-lightest': disabled,\n }\"\n >\n <ng-icon name=\"iconoirLink\"></ng-icon>\n </div>\n <gn-ui-button\n *ngIf=\"showValidateButton\"\n extraClass=\"absolute inset-y-[var(--side-padding)] right-[var(--side-padding)]\"\n type=\"primary\"\n [disabled]=\"disabled || input.value === '' || !isValidUrl(input.value)\"\n (buttonClick)=\"handleUpload(input)\"\n >\n <ng-content>\n <ng-icon name=\"iconoirArrowUp\"></ng-icon>\n </ng-content>\n </gn-ui-button>\n</span>\n", styles: [":host{--gn-ui-button-rounded: 8px;--gn-ui-button-width: 32px;--gn-ui-button-padding: 0;--side-padding: calc(var(--gn-ui-text-input-padding, .6rem) - 6px);--2x-side-padding: calc(var(--side-padding) * 2);--text-padding: calc(var(--side-padding) + 40px)}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1$2.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i1$2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: ButtonComponent, selector: "gn-ui-button", inputs: ["type", "disabled", "extraClass"], outputs: ["buttonClick"] }, { kind: "component", type: NgIconComponent, selector: "ng-icon", inputs: ["name", "svg", "size", "strokeWidth", "color"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
27148
27204
|
}
|
|
27149
27205
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: UrlInputComponent, decorators: [{
|
|
27150
27206
|
type: Component,
|
|
@@ -27164,6 +27220,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImpo
|
|
|
27164
27220
|
type: Input
|
|
27165
27221
|
}], showValidateButton: [{
|
|
27166
27222
|
type: Input
|
|
27223
|
+
}], resetUrlOnChange: [{
|
|
27224
|
+
type: Input
|
|
27167
27225
|
}], valueChange: [{
|
|
27168
27226
|
type: Output
|
|
27169
27227
|
}], uploadClick: [{
|
|
@@ -27229,7 +27287,7 @@ class FileInputComponent {
|
|
|
27229
27287
|
provideNgIconsConfig({
|
|
27230
27288
|
size: '1.5em',
|
|
27231
27289
|
}),
|
|
27232
|
-
], ngImport: i0, template: "<div class=\"w-full flex flex-col gap-[16px]\">\n <label\n gnUiFilesDrop\n class=\"flex-1 border-2 border-dashed rounded-lg p-6 flex flex-col items-center justify-center gap-4 transition-colors duration-100\"\n [ngClass]=\"{\n 'border-primary-lighter bg-primary-white': dragFilesOver,\n 'border-gray-300': !dragFilesOver,\n 'cursor-pointer hover:border-gray-500': !isUploadInProgress && !disabled,\n 'cursor-not-allowed': disabled,\n }\"\n [attr.tabindex]=\"isUploadInProgress || disabled ? null : 0\"\n (dragFilesOver)=\"handleDragFilesOver($event)\"\n (dropFiles)=\"handleDropFiles($event)\"\n (keydown.enter)=\"fileInput.click()\"\n >\n <input\n #fileInput\n type=\"file\"\n class=\"hidden\"\n (change)=\"handleFileInput($event)\"\n [disabled]=\"isUploadInProgress || disabled\"\n />\n\n <div\n class=\"w-14 h-14 rounded-md bg-gray-50 grid\"\n *ngIf=\"!isUploadInProgress\"\n >\n <ng-icon\n *ngIf=\"!dragFilesOver\"\n class=\"place-self-center text-primary\"\n name=\"iconoirCloudUpload\"\n ></ng-icon>\n <ng-icon\n *ngIf=\"dragFilesOver\"\n class=\"place-self-center text-primary\"\n name=\"iconoirFramePlusIn\"\n ></ng-icon>\n </div>\n <div\n *ngIf=\"isUploadInProgress\"\n class=\"w-14 h-14 grid items-center justify-center relative\"\n >\n <div class=\"text-gray-100 absolute\">\n <mat-progress-spinner\n class=\"place-self-center\"\n [diameter]=\"56\"\n mode=\"determinate\"\n [value]=\"100\"\n ></mat-progress-spinner>\n </div>\n <div class=\"text-primary absolute\">\n <mat-progress-spinner\n class=\"place-self-center\"\n [diameter]=\"56\"\n mode=\"determinate\"\n [value]=\"uploadProgress\"\n ></mat-progress-spinner>\n </div>\n <span class=\"text-sm text-main font-bold\">{{ uploadProgress }}%</span>\n </div>\n <div class=\"flex flex-col items-center gap-1\">\n <p class=\"font-medium\">\n {{ getPrimaryText() | translate: { sizeMB: maxSizeMB.toFixed(0) } }}\n </p>\n <p\n class=\"text-sm\"\n [class]=\"\n isUploadInProgress\n ? 'font-bold text-primary cursor-pointer'\n : 'font-medium text-gray-500'\n \"\n (click)=\"handleSecondaryTextClick($event)\"\n >\n {{ getSecondaryText() | translate }}\n </p>\n </div>\n <p class=\"w-full flex flex-row items-center justify-stretch gap-[16px]\">\n <span class=\"border-b border-gray-300 grow\"></span>\n <span class=\"text-sm font-medium text-gray-500 or-input-url\" translate>\n input.file.orInputUrl</span\n >\n <span class=\"border-b border-gray-300 grow\"></span>\n </p>\n <gn-ui-url-input\n class=\"w-full\"\n [disabled]=\"isUploadInProgress || disabled\"\n (uploadClick)=\"handleUrlChange($event)\"\n ></gn-ui-url-input>\n </label>\n</div>\n", styles: [":host{--gn-ui-button-padding: 8px 8px;--gn-ui-button-rounded: 8px}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1$2.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i1$2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: FilesDropDirective, selector: "[gnUiFilesDrop]", outputs: ["dragFilesOver", "dropFiles"] }, { kind: "ngmodule", type: MatProgressSpinnerModule }, { kind: "component", type: i1$5.MatProgressSpinner, selector: "mat-progress-spinner, mat-spinner", inputs: ["color", "mode", "value", "diameter", "strokeWidth"], exportAs: ["matProgressSpinner"] }, { kind: "ngmodule", type: TranslateModule }, { kind: "pipe", type: i1$1.TranslatePipe, name: "translate" }, { kind: "directive", type: i1$1.TranslateDirective, selector: "[translate],[ngx-translate]", inputs: ["translate", "translateParams"] }, { kind: "component", type: UrlInputComponent, selector: "gn-ui-url-input", inputs: ["value", "extraClass", "placeholder", "disabled", "showValidateButton"], outputs: ["valueChange", "uploadClick"] }, { kind: "component", type: NgIconComponent, selector: "ng-icon", inputs: ["name", "svg", "size", "strokeWidth", "color"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
27290
|
+
], ngImport: i0, template: "<div class=\"w-full flex flex-col gap-[16px]\">\n <label\n gnUiFilesDrop\n class=\"flex-1 border-2 border-dashed rounded-lg p-6 flex flex-col items-center justify-center gap-4 transition-colors duration-100\"\n [ngClass]=\"{\n 'border-primary-lighter bg-primary-white': dragFilesOver,\n 'border-gray-300': !dragFilesOver,\n 'cursor-pointer hover:border-gray-500': !isUploadInProgress && !disabled,\n 'cursor-not-allowed': disabled,\n }\"\n [attr.tabindex]=\"isUploadInProgress || disabled ? null : 0\"\n (dragFilesOver)=\"handleDragFilesOver($event)\"\n (dropFiles)=\"handleDropFiles($event)\"\n (keydown.enter)=\"fileInput.click()\"\n >\n <input\n #fileInput\n type=\"file\"\n class=\"hidden\"\n (change)=\"handleFileInput($event)\"\n [disabled]=\"isUploadInProgress || disabled\"\n />\n\n <div\n class=\"w-14 h-14 rounded-md bg-gray-50 grid\"\n *ngIf=\"!isUploadInProgress\"\n >\n <ng-icon\n *ngIf=\"!dragFilesOver\"\n class=\"place-self-center text-primary\"\n name=\"iconoirCloudUpload\"\n ></ng-icon>\n <ng-icon\n *ngIf=\"dragFilesOver\"\n class=\"place-self-center text-primary\"\n name=\"iconoirFramePlusIn\"\n ></ng-icon>\n </div>\n <div\n *ngIf=\"isUploadInProgress\"\n class=\"w-14 h-14 grid items-center justify-center relative\"\n >\n <div class=\"text-gray-100 absolute\">\n <mat-progress-spinner\n class=\"place-self-center\"\n [diameter]=\"56\"\n mode=\"determinate\"\n [value]=\"100\"\n ></mat-progress-spinner>\n </div>\n <div class=\"text-primary absolute\">\n <mat-progress-spinner\n class=\"place-self-center\"\n [diameter]=\"56\"\n mode=\"determinate\"\n [value]=\"uploadProgress\"\n ></mat-progress-spinner>\n </div>\n <span class=\"text-sm text-main font-bold\">{{ uploadProgress }}%</span>\n </div>\n <div class=\"flex flex-col items-center gap-1\">\n <p class=\"font-medium\">\n {{ getPrimaryText() | translate: { sizeMB: maxSizeMB.toFixed(0) } }}\n </p>\n <p\n class=\"text-sm\"\n [class]=\"\n isUploadInProgress\n ? 'font-bold text-primary cursor-pointer'\n : 'font-medium text-gray-500'\n \"\n (click)=\"handleSecondaryTextClick($event)\"\n >\n {{ getSecondaryText() | translate }}\n </p>\n </div>\n <p class=\"w-full flex flex-row items-center justify-stretch gap-[16px]\">\n <span class=\"border-b border-gray-300 grow\"></span>\n <span class=\"text-sm font-medium text-gray-500 or-input-url\" translate>\n input.file.orInputUrl</span\n >\n <span class=\"border-b border-gray-300 grow\"></span>\n </p>\n <gn-ui-url-input\n class=\"w-full\"\n [disabled]=\"isUploadInProgress || disabled\"\n (uploadClick)=\"handleUrlChange($event)\"\n ></gn-ui-url-input>\n </label>\n</div>\n", styles: [":host{--gn-ui-button-padding: 8px 8px;--gn-ui-button-rounded: 8px}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1$2.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i1$2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: FilesDropDirective, selector: "[gnUiFilesDrop]", outputs: ["dragFilesOver", "dropFiles"] }, { kind: "ngmodule", type: MatProgressSpinnerModule }, { kind: "component", type: i1$5.MatProgressSpinner, selector: "mat-progress-spinner, mat-spinner", inputs: ["color", "mode", "value", "diameter", "strokeWidth"], exportAs: ["matProgressSpinner"] }, { kind: "ngmodule", type: TranslateModule }, { kind: "pipe", type: i1$1.TranslatePipe, name: "translate" }, { kind: "directive", type: i1$1.TranslateDirective, selector: "[translate],[ngx-translate]", inputs: ["translate", "translateParams"] }, { kind: "component", type: UrlInputComponent, selector: "gn-ui-url-input", inputs: ["value", "extraClass", "placeholder", "disabled", "showValidateButton", "resetUrlOnChange"], outputs: ["valueChange", "uploadClick"] }, { kind: "component", type: NgIconComponent, selector: "ng-icon", inputs: ["name", "svg", "size", "strokeWidth", "color"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
27233
27291
|
}
|
|
27234
27292
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: FileInputComponent, decorators: [{
|
|
27235
27293
|
type: Component,
|
|
@@ -28378,7 +28436,15 @@ class MetadataQualityComponent {
|
|
|
28378
28436
|
}
|
|
28379
28437
|
}
|
|
28380
28438
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: MetadataQualityComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
28381
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.2.13", type: MetadataQualityComponent, isStandalone: true, selector: "gn-ui-metadata-quality", inputs: { metadata: "metadata", smaller: "smaller", metadataQualityDisplay: "metadataQualityDisplay" },
|
|
28439
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.2.13", type: MetadataQualityComponent, isStandalone: true, selector: "gn-ui-metadata-quality", inputs: { metadata: "metadata", smaller: "smaller", metadataQualityDisplay: "metadataQualityDisplay" }, providers: [
|
|
28440
|
+
provideIcons({
|
|
28441
|
+
matInfoOutline,
|
|
28442
|
+
}),
|
|
28443
|
+
provideNgIconsConfig({
|
|
28444
|
+
size: '1.2em',
|
|
28445
|
+
strokeWidth: '1.5px',
|
|
28446
|
+
}),
|
|
28447
|
+
], usesOnChanges: true, ngImport: i0, template: "<div *ngIf=\"metadataQualityDisplay\" class=\"mb-6 metadata-quality\">\n <div\n class=\"flex items-center\"\n [class]=\"smaller ? 'leading-[8px] min-w-[120px]' : 'min-w-[200px]'\"\n >\n <gn-ui-progress-bar\n tabindex=\"0\"\n [value]=\"qualityScore\"\n [type]=\"'light'\"\n class=\"flex-grow\"\n ></gn-ui-progress-bar>\n <gn-ui-popover\n [content]=\"popoverItems\"\n theme=\"light-border\"\n [class]=\"smaller ? 'ml-2' : 'ml-2 mt-1'\"\n >\n <ng-icon\n name=\"matInfoOutline\"\n class=\"flex-shrink-0 text-gray-600\"\n ></ng-icon>\n </gn-ui-popover>\n </div>\n</div>\n<ng-template #popoverItems>\n <div class=\"p-2 py-4\">\n <div class=\"mb-4 font-bold\" translate>record.metadata.quality.details</div>\n <gn-ui-metadata-quality-item\n *ngFor=\"let e of items\"\n [name]=\"e.name\"\n [value]=\"e.value\"\n ></gn-ui-metadata-quality-item>\n </div>\n</ng-template>\n", styles: [":host gn-ui-progress-bar{--progress-bar-font-weight: \"normal\"}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1$2.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i1$2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: PopoverComponent, selector: "gn-ui-popover", inputs: ["content", "theme"] }, { kind: "component", type: ProgressBarComponent, selector: "gn-ui-progress-bar", inputs: ["value", "type"] }, { kind: "component", type: MetadataQualityItemComponent, selector: "gn-ui-metadata-quality-item", inputs: ["name", "value"] }, { kind: "ngmodule", type: TranslateModule }, { kind: "directive", type: i1$1.TranslateDirective, selector: "[translate],[ngx-translate]", inputs: ["translate", "translateParams"] }, { kind: "component", type: NgIcon, selector: "ng-icon", inputs: ["name", "svg", "size", "strokeWidth", "color"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
28382
28448
|
}
|
|
28383
28449
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: MetadataQualityComponent, decorators: [{
|
|
28384
28450
|
type: Component,
|
|
@@ -28388,7 +28454,16 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImpo
|
|
|
28388
28454
|
ProgressBarComponent,
|
|
28389
28455
|
MetadataQualityItemComponent,
|
|
28390
28456
|
TranslateModule,
|
|
28391
|
-
|
|
28457
|
+
NgIcon,
|
|
28458
|
+
], providers: [
|
|
28459
|
+
provideIcons({
|
|
28460
|
+
matInfoOutline,
|
|
28461
|
+
}),
|
|
28462
|
+
provideNgIconsConfig({
|
|
28463
|
+
size: '1.2em',
|
|
28464
|
+
strokeWidth: '1.5px',
|
|
28465
|
+
}),
|
|
28466
|
+
], template: "<div *ngIf=\"metadataQualityDisplay\" class=\"mb-6 metadata-quality\">\n <div\n class=\"flex items-center\"\n [class]=\"smaller ? 'leading-[8px] min-w-[120px]' : 'min-w-[200px]'\"\n >\n <gn-ui-progress-bar\n tabindex=\"0\"\n [value]=\"qualityScore\"\n [type]=\"'light'\"\n class=\"flex-grow\"\n ></gn-ui-progress-bar>\n <gn-ui-popover\n [content]=\"popoverItems\"\n theme=\"light-border\"\n [class]=\"smaller ? 'ml-2' : 'ml-2 mt-1'\"\n >\n <ng-icon\n name=\"matInfoOutline\"\n class=\"flex-shrink-0 text-gray-600\"\n ></ng-icon>\n </gn-ui-popover>\n </div>\n</div>\n<ng-template #popoverItems>\n <div class=\"p-2 py-4\">\n <div class=\"mb-4 font-bold\" translate>record.metadata.quality.details</div>\n <gn-ui-metadata-quality-item\n *ngFor=\"let e of items\"\n [name]=\"e.name\"\n [value]=\"e.value\"\n ></gn-ui-metadata-quality-item>\n </div>\n</ng-template>\n", styles: [":host gn-ui-progress-bar{--progress-bar-font-weight: \"normal\"}\n"] }]
|
|
28392
28467
|
}], propDecorators: { metadata: [{
|
|
28393
28468
|
type: Input
|
|
28394
28469
|
}], smaller: [{
|
|
@@ -28403,11 +28478,11 @@ class RecordPreviewRowComponent extends RecordPreviewComponent {
|
|
|
28403
28478
|
this.elementRef = elementRef;
|
|
28404
28479
|
}
|
|
28405
28480
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: RecordPreviewRowComponent, deps: [{ token: i0.ElementRef }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
28406
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.2.13", type: RecordPreviewRowComponent, selector: "gn-ui-record-preview-row", usesInheritance: true, ngImport: i0, template: "<a\n class=\"group container-lg mx-auto flex cursor-pointer flex-wrap sm:flex-nowrap\"\n [title]=\"record.title\"\n [attr.href]=\"linkHref\"\n>\n <div class=\"shrink-0 w-full sm:w-52\">\n <div\n class=\"overflow-hidden bg-gray-100 rounded-lg w-full border border-gray-300 h-36\"\n >\n <gn-ui-thumbnail\n class=\"relative h-full w-full object-cover object-left-top\"\n [thumbnailUrl]=\"[\n record.overviews?.[0]?.url?.toString(),\n organization?.logoUrl?.toString(),\n ]\"\n [fit]=\"['cover', 'contain']\"\n ></gn-ui-thumbnail>\n </div>\n </div>\n <div\n class=\"content grid grow relative sm:pl-6 sm:pr-12\"\n style=\"grid-template-columns: auto 70px\"\n >\n <div class=\"mb-3 mt-5 sm:mt-2\">\n <div\n class=\"font-title text-21 text-title line-clamp-2 col-start-1 col-span-2 sm:line-clamp-1 group-hover:text-primary transition-colors\"\n data-cy=\"recordTitle\"\n >\n {{ record.title }}\n </div>\n </div>\n <div\n class=\"abstract mt-4 mb-5 h-36 line-clamp-6 col-start-1 col-span-2 row-start-3 sm:mb-2 sm:h-[4.5rem] sm:line-clamp-3 sm:row-start-2 sm:mt-0\"\n data-cy=\"recordAbstract\"\n >\n <gn-ui-markdown-parser\n [textContent]=\"abstract\"\n whitoutStyles=\"true\"\n ></gn-ui-markdown-parser>\n </div>\n <div\n class=\"text-primary opacity-45 uppercase col-start-1 col-span-2 row-start-2 sm:truncate sm:row-start-3 sm:col-span-1\"\n data-cy=\"recordOrg\"\n [class]=\"metadataQualityDisplay ? 'limit-organisation-with-quality' : ''\"\n >\n {{ organization?.name }}\n </div>\n <div\n class=\"icons flex flex-row col-start-1 row-start-4 sm:col-start-2 sm:row-start-3 sm:absolute sm:right-[0.4em]\"\n >\n <ng-icon\n *ngIf=\"isDownloadable\"\n class=\"text-primary opacity-45 mx-1\"\n name=\"matCloudDownloadOutline\"\n ></ng-icon>\n <ng-icon\n *ngIf=\"isViewable\"\n class=\"text-primary opacity-45 mx-1\"\n name=\"matMapOutline\"\n ></ng-icon>\n </div>\n <div\n *ngIf=\"metadataQualityDisplay\"\n class=\"col-start-2 row-start-4 sm:row-start-3 absolute right-[4em] sm:right-[5em]\"\n >\n <gn-ui-metadata-quality\n smaller=\"true\"\n [metadata]=\"record\"\n [metadataQualityDisplay]=\"metadataQualityDisplay\"\n ></gn-ui-metadata-quality>\n </div>\n <div\n class=\"text-right col-start-3 row-start-4 sm:absolute sm:col-start-2 sm:row-start-1 sm:top-[-1.125em] sm:right-[0.4em]\"\n data-cy=\"recordFav\"\n >\n <ng-container\n [ngTemplateOutlet]=\"favoriteTemplate\"\n [ngTemplateOutletContext]=\"{ $implicit: record }\"\n ></ng-container>\n </div>\n </div>\n</a>\n", styles: [".limit-organisation-with-quality{max-width:calc(100% - 170px)}\n"], dependencies: [{ kind: "directive", type: i1$2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i1$2.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "component", type: ThumbnailComponent, selector: "gn-ui-thumbnail", inputs: ["thumbnailUrl", "fit"], outputs: ["placeholderShown"] }, { kind: "component", type: MarkdownParserComponent, selector: "gn-ui-markdown-parser", inputs: ["textContent", "whitoutStyles"] }, { kind: "component", type: i2$2.NgIcon, selector: "ng-icon", inputs: ["name", "svg", "size", "strokeWidth", "color"] }, { kind: "component", type: MetadataQualityComponent, selector: "gn-ui-metadata-quality", inputs: ["metadata", "smaller", "metadataQualityDisplay"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
28481
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.2.13", type: RecordPreviewRowComponent, selector: "gn-ui-record-preview-row", usesInheritance: true, ngImport: i0, template: "<a\n class=\"group container-lg mx-auto flex cursor-pointer flex-wrap sm:flex-nowrap\"\n [title]=\"record.title\"\n [attr.href]=\"linkHref\"\n>\n <div class=\"shrink-0 w-full sm:w-52\">\n <div\n class=\"overflow-hidden bg-gray-100 rounded-lg w-full border border-gray-300 h-36\"\n >\n <gn-ui-thumbnail\n class=\"relative h-full w-full object-cover object-left-top\"\n [thumbnailUrl]=\"[\n record.overviews?.[0]?.url?.toString(),\n organization?.logoUrl?.toString(),\n ]\"\n [fit]=\"['cover', 'contain']\"\n ></gn-ui-thumbnail>\n </div>\n </div>\n <div\n class=\"content grid grow relative sm:pl-6 sm:pr-12\"\n style=\"grid-template-columns: auto 70px\"\n >\n <div class=\"mb-3 mt-5 sm:mt-2\">\n <div\n class=\"font-title text-21 text-title line-clamp-2 col-start-1 col-span-2 sm:line-clamp-1 group-hover:text-primary transition-colors\"\n data-cy=\"recordTitle\"\n >\n {{ record.title }}\n </div>\n </div>\n <div\n class=\"abstract mt-4 mb-5 h-36 line-clamp-6 col-start-1 col-span-2 row-start-3 sm:mb-2 sm:h-[4.5rem] sm:line-clamp-3 sm:row-start-2 sm:mt-0\"\n data-cy=\"recordAbstract\"\n >\n <gn-ui-markdown-parser\n [textContent]=\"abstract\"\n whitoutStyles=\"true\"\n ></gn-ui-markdown-parser>\n </div>\n <div\n class=\"text-primary opacity-45 uppercase col-start-1 col-span-2 row-start-2 sm:truncate sm:row-start-3 sm:col-span-1\"\n data-cy=\"recordOrg\"\n [class]=\"metadataQualityDisplay ? 'limit-organisation-with-quality' : ''\"\n >\n {{ organization?.name }}\n </div>\n <div\n class=\"icons flex flex-row col-start-1 row-start-4 sm:col-start-2 sm:row-start-3 sm:absolute sm:right-[0.4em]\"\n >\n <ng-icon\n *ngIf=\"isDownloadable\"\n class=\"text-primary opacity-45 mx-1\"\n name=\"matCloudDownloadOutline\"\n ></ng-icon>\n <ng-icon\n *ngIf=\"isViewable\"\n class=\"text-primary opacity-45 mx-1\"\n name=\"matMapOutline\"\n ></ng-icon>\n </div>\n <div\n *ngIf=\"metadataQualityDisplay\"\n class=\"col-start-2 row-start-4 sm:row-start-3 absolute right-[4em] sm:right-[5em]\"\n >\n <gn-ui-metadata-quality\n [smaller]=\"true\"\n [metadata]=\"record\"\n [metadataQualityDisplay]=\"metadataQualityDisplay\"\n ></gn-ui-metadata-quality>\n </div>\n <div\n class=\"text-right col-start-3 row-start-4 sm:absolute sm:col-start-2 sm:row-start-1 sm:top-[-1.125em] sm:right-[0.4em]\"\n data-cy=\"recordFav\"\n >\n <ng-container\n [ngTemplateOutlet]=\"favoriteTemplate\"\n [ngTemplateOutletContext]=\"{ $implicit: record }\"\n ></ng-container>\n </div>\n </div>\n</a>\n", styles: [".limit-organisation-with-quality{max-width:calc(100% - 170px)}\n"], dependencies: [{ kind: "directive", type: i1$2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i1$2.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "component", type: ThumbnailComponent, selector: "gn-ui-thumbnail", inputs: ["thumbnailUrl", "fit"], outputs: ["placeholderShown"] }, { kind: "component", type: MarkdownParserComponent, selector: "gn-ui-markdown-parser", inputs: ["textContent", "whitoutStyles"] }, { kind: "component", type: i2$2.NgIcon, selector: "ng-icon", inputs: ["name", "svg", "size", "strokeWidth", "color"] }, { kind: "component", type: MetadataQualityComponent, selector: "gn-ui-metadata-quality", inputs: ["metadata", "smaller", "metadataQualityDisplay"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
28407
28482
|
}
|
|
28408
28483
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: RecordPreviewRowComponent, decorators: [{
|
|
28409
28484
|
type: Component,
|
|
28410
|
-
args: [{ selector: 'gn-ui-record-preview-row', changeDetection: ChangeDetectionStrategy.OnPush, template: "<a\n class=\"group container-lg mx-auto flex cursor-pointer flex-wrap sm:flex-nowrap\"\n [title]=\"record.title\"\n [attr.href]=\"linkHref\"\n>\n <div class=\"shrink-0 w-full sm:w-52\">\n <div\n class=\"overflow-hidden bg-gray-100 rounded-lg w-full border border-gray-300 h-36\"\n >\n <gn-ui-thumbnail\n class=\"relative h-full w-full object-cover object-left-top\"\n [thumbnailUrl]=\"[\n record.overviews?.[0]?.url?.toString(),\n organization?.logoUrl?.toString(),\n ]\"\n [fit]=\"['cover', 'contain']\"\n ></gn-ui-thumbnail>\n </div>\n </div>\n <div\n class=\"content grid grow relative sm:pl-6 sm:pr-12\"\n style=\"grid-template-columns: auto 70px\"\n >\n <div class=\"mb-3 mt-5 sm:mt-2\">\n <div\n class=\"font-title text-21 text-title line-clamp-2 col-start-1 col-span-2 sm:line-clamp-1 group-hover:text-primary transition-colors\"\n data-cy=\"recordTitle\"\n >\n {{ record.title }}\n </div>\n </div>\n <div\n class=\"abstract mt-4 mb-5 h-36 line-clamp-6 col-start-1 col-span-2 row-start-3 sm:mb-2 sm:h-[4.5rem] sm:line-clamp-3 sm:row-start-2 sm:mt-0\"\n data-cy=\"recordAbstract\"\n >\n <gn-ui-markdown-parser\n [textContent]=\"abstract\"\n whitoutStyles=\"true\"\n ></gn-ui-markdown-parser>\n </div>\n <div\n class=\"text-primary opacity-45 uppercase col-start-1 col-span-2 row-start-2 sm:truncate sm:row-start-3 sm:col-span-1\"\n data-cy=\"recordOrg\"\n [class]=\"metadataQualityDisplay ? 'limit-organisation-with-quality' : ''\"\n >\n {{ organization?.name }}\n </div>\n <div\n class=\"icons flex flex-row col-start-1 row-start-4 sm:col-start-2 sm:row-start-3 sm:absolute sm:right-[0.4em]\"\n >\n <ng-icon\n *ngIf=\"isDownloadable\"\n class=\"text-primary opacity-45 mx-1\"\n name=\"matCloudDownloadOutline\"\n ></ng-icon>\n <ng-icon\n *ngIf=\"isViewable\"\n class=\"text-primary opacity-45 mx-1\"\n name=\"matMapOutline\"\n ></ng-icon>\n </div>\n <div\n *ngIf=\"metadataQualityDisplay\"\n class=\"col-start-2 row-start-4 sm:row-start-3 absolute right-[4em] sm:right-[5em]\"\n >\n <gn-ui-metadata-quality\n smaller=\"true\"\n [metadata]=\"record\"\n [metadataQualityDisplay]=\"metadataQualityDisplay\"\n ></gn-ui-metadata-quality>\n </div>\n <div\n class=\"text-right col-start-3 row-start-4 sm:absolute sm:col-start-2 sm:row-start-1 sm:top-[-1.125em] sm:right-[0.4em]\"\n data-cy=\"recordFav\"\n >\n <ng-container\n [ngTemplateOutlet]=\"favoriteTemplate\"\n [ngTemplateOutletContext]=\"{ $implicit: record }\"\n ></ng-container>\n </div>\n </div>\n</a>\n", styles: [".limit-organisation-with-quality{max-width:calc(100% - 170px)}\n"] }]
|
|
28485
|
+
args: [{ selector: 'gn-ui-record-preview-row', changeDetection: ChangeDetectionStrategy.OnPush, template: "<a\n class=\"group container-lg mx-auto flex cursor-pointer flex-wrap sm:flex-nowrap\"\n [title]=\"record.title\"\n [attr.href]=\"linkHref\"\n>\n <div class=\"shrink-0 w-full sm:w-52\">\n <div\n class=\"overflow-hidden bg-gray-100 rounded-lg w-full border border-gray-300 h-36\"\n >\n <gn-ui-thumbnail\n class=\"relative h-full w-full object-cover object-left-top\"\n [thumbnailUrl]=\"[\n record.overviews?.[0]?.url?.toString(),\n organization?.logoUrl?.toString(),\n ]\"\n [fit]=\"['cover', 'contain']\"\n ></gn-ui-thumbnail>\n </div>\n </div>\n <div\n class=\"content grid grow relative sm:pl-6 sm:pr-12\"\n style=\"grid-template-columns: auto 70px\"\n >\n <div class=\"mb-3 mt-5 sm:mt-2\">\n <div\n class=\"font-title text-21 text-title line-clamp-2 col-start-1 col-span-2 sm:line-clamp-1 group-hover:text-primary transition-colors\"\n data-cy=\"recordTitle\"\n >\n {{ record.title }}\n </div>\n </div>\n <div\n class=\"abstract mt-4 mb-5 h-36 line-clamp-6 col-start-1 col-span-2 row-start-3 sm:mb-2 sm:h-[4.5rem] sm:line-clamp-3 sm:row-start-2 sm:mt-0\"\n data-cy=\"recordAbstract\"\n >\n <gn-ui-markdown-parser\n [textContent]=\"abstract\"\n whitoutStyles=\"true\"\n ></gn-ui-markdown-parser>\n </div>\n <div\n class=\"text-primary opacity-45 uppercase col-start-1 col-span-2 row-start-2 sm:truncate sm:row-start-3 sm:col-span-1\"\n data-cy=\"recordOrg\"\n [class]=\"metadataQualityDisplay ? 'limit-organisation-with-quality' : ''\"\n >\n {{ organization?.name }}\n </div>\n <div\n class=\"icons flex flex-row col-start-1 row-start-4 sm:col-start-2 sm:row-start-3 sm:absolute sm:right-[0.4em]\"\n >\n <ng-icon\n *ngIf=\"isDownloadable\"\n class=\"text-primary opacity-45 mx-1\"\n name=\"matCloudDownloadOutline\"\n ></ng-icon>\n <ng-icon\n *ngIf=\"isViewable\"\n class=\"text-primary opacity-45 mx-1\"\n name=\"matMapOutline\"\n ></ng-icon>\n </div>\n <div\n *ngIf=\"metadataQualityDisplay\"\n class=\"col-start-2 row-start-4 sm:row-start-3 absolute right-[4em] sm:right-[5em]\"\n >\n <gn-ui-metadata-quality\n [smaller]=\"true\"\n [metadata]=\"record\"\n [metadataQualityDisplay]=\"metadataQualityDisplay\"\n ></gn-ui-metadata-quality>\n </div>\n <div\n class=\"text-right col-start-3 row-start-4 sm:absolute sm:col-start-2 sm:row-start-1 sm:top-[-1.125em] sm:right-[0.4em]\"\n data-cy=\"recordFav\"\n >\n <ng-container\n [ngTemplateOutlet]=\"favoriteTemplate\"\n [ngTemplateOutletContext]=\"{ $implicit: record }\"\n ></ng-container>\n </div>\n </div>\n</a>\n", styles: [".limit-organisation-with-quality{max-width:calc(100% - 170px)}\n"] }]
|
|
28411
28486
|
}], ctorParameters: () => [{ type: i0.ElementRef }] });
|
|
28412
28487
|
|
|
28413
28488
|
class RecordPreviewTextComponent extends RecordPreviewComponent {
|
|
@@ -28866,6 +28941,16 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImpo
|
|
|
28866
28941
|
}] } });
|
|
28867
28942
|
|
|
28868
28943
|
class ImageInputComponent {
|
|
28944
|
+
get altText() {
|
|
28945
|
+
return this._altText;
|
|
28946
|
+
}
|
|
28947
|
+
set altText(value) {
|
|
28948
|
+
if (value !== 'KO' && this._altText === 'KO') {
|
|
28949
|
+
//This is a dataset rollback after upload error
|
|
28950
|
+
this.resetErrors();
|
|
28951
|
+
}
|
|
28952
|
+
this._altText = value;
|
|
28953
|
+
}
|
|
28869
28954
|
get isUploadInProgress() {
|
|
28870
28955
|
return this.uploadProgress !== undefined;
|
|
28871
28956
|
}
|
|
@@ -28880,11 +28965,14 @@ class ImageInputComponent {
|
|
|
28880
28965
|
this.altTextChange = new EventEmitter();
|
|
28881
28966
|
this.dragFilesOver = false;
|
|
28882
28967
|
this.showUrlInput = false;
|
|
28883
|
-
this.
|
|
28968
|
+
this.imageFileError = this.uploadError;
|
|
28884
28969
|
this.showAltTextInput = false;
|
|
28885
28970
|
}
|
|
28971
|
+
getIsActionBlocked() {
|
|
28972
|
+
return this.isUploadInProgress || this.disabled;
|
|
28973
|
+
}
|
|
28886
28974
|
getPrimaryText() {
|
|
28887
|
-
if (this.
|
|
28975
|
+
if (this.imageFileError) {
|
|
28888
28976
|
return marker('input.image.uploadErrorLabel');
|
|
28889
28977
|
}
|
|
28890
28978
|
if (this.uploadProgress) {
|
|
@@ -28893,8 +28981,8 @@ class ImageInputComponent {
|
|
|
28893
28981
|
return marker('input.image.selectFileLabel');
|
|
28894
28982
|
}
|
|
28895
28983
|
getSecondaryText() {
|
|
28896
|
-
if (this.
|
|
28897
|
-
return
|
|
28984
|
+
if (this.imageFileError) {
|
|
28985
|
+
return '\u00A0'; // (only to keep same spacing, next step is to handle "Retry")
|
|
28898
28986
|
}
|
|
28899
28987
|
if (this.uploadProgress) {
|
|
28900
28988
|
return marker('input.image.uploadProgressCancel');
|
|
@@ -28908,26 +28996,35 @@ class ImageInputComponent {
|
|
|
28908
28996
|
}
|
|
28909
28997
|
}
|
|
28910
28998
|
handleDropFiles(files) {
|
|
28911
|
-
|
|
28912
|
-
|
|
28913
|
-
|
|
28914
|
-
|
|
28915
|
-
|
|
28999
|
+
this.resetErrors();
|
|
29000
|
+
const validFiles = this.filterTypeImage(files);
|
|
29001
|
+
if (validFiles.length > 0) {
|
|
29002
|
+
this.showUrlInput = false;
|
|
29003
|
+
this.resizeAndEmit(validFiles[0]);
|
|
29004
|
+
}
|
|
29005
|
+
else {
|
|
29006
|
+
this.imageFileError = true;
|
|
29007
|
+
this.handleAltTextChange('KO');
|
|
28916
29008
|
}
|
|
28917
29009
|
}
|
|
28918
29010
|
handleFileInput(event) {
|
|
29011
|
+
this.resetErrors();
|
|
28919
29012
|
const inputFiles = Array.from(event.target.files);
|
|
28920
29013
|
const validFiles = this.filterTypeImage(inputFiles);
|
|
28921
29014
|
if (validFiles.length > 0) {
|
|
28922
29015
|
this.resizeAndEmit(validFiles[0]);
|
|
28923
29016
|
}
|
|
29017
|
+
else {
|
|
29018
|
+
this.imageFileError = true;
|
|
29019
|
+
this.handleAltTextChange('KO');
|
|
29020
|
+
}
|
|
28924
29021
|
}
|
|
28925
29022
|
displayUrlInput() {
|
|
28926
29023
|
this.uploadCancel.emit();
|
|
28927
29024
|
this.showUrlInput = true;
|
|
28928
29025
|
}
|
|
28929
29026
|
async downloadUrl(url) {
|
|
28930
|
-
this.
|
|
29027
|
+
this.resetErrors();
|
|
28931
29028
|
const name = url.split('/').pop();
|
|
28932
29029
|
try {
|
|
28933
29030
|
const response = await firstValueFrom(this.http.head(url, { observe: 'response' }));
|
|
@@ -28941,7 +29038,8 @@ class ImageInputComponent {
|
|
|
28941
29038
|
this.fileChange.emit(file);
|
|
28942
29039
|
},
|
|
28943
29040
|
error: () => {
|
|
28944
|
-
this.
|
|
29041
|
+
this.imageFileError = true;
|
|
29042
|
+
this.handleAltTextChange('KO');
|
|
28945
29043
|
this.cd.markForCheck();
|
|
28946
29044
|
this.urlChange.emit(url);
|
|
28947
29045
|
},
|
|
@@ -28949,36 +29047,28 @@ class ImageInputComponent {
|
|
|
28949
29047
|
}
|
|
28950
29048
|
}
|
|
28951
29049
|
catch {
|
|
28952
|
-
this.
|
|
29050
|
+
this.imageFileError = true;
|
|
29051
|
+
this.handleAltTextChange('KO');
|
|
28953
29052
|
this.cd.markForCheck();
|
|
28954
29053
|
return;
|
|
28955
29054
|
}
|
|
28956
29055
|
}
|
|
28957
29056
|
handleSecondaryTextClick(event) {
|
|
28958
|
-
if (this.
|
|
28959
|
-
this.
|
|
28960
|
-
}
|
|
28961
|
-
else if (this.uploadProgress) {
|
|
28962
|
-
this.handleCancel();
|
|
29057
|
+
if (this.uploadProgress) {
|
|
29058
|
+
this.handleCancelUpload();
|
|
28963
29059
|
event.preventDefault();
|
|
28964
29060
|
}
|
|
28965
29061
|
}
|
|
28966
|
-
|
|
29062
|
+
handleCancelUpload() {
|
|
28967
29063
|
this.uploadCancel.emit();
|
|
28968
29064
|
}
|
|
28969
|
-
handleRetry() {
|
|
28970
|
-
switch (this.lastUploadType) {
|
|
28971
|
-
case 'file':
|
|
28972
|
-
this.fileChange.emit(this.lastUploadContent);
|
|
28973
|
-
break;
|
|
28974
|
-
case 'url':
|
|
28975
|
-
this.urlChange.emit(this.lastUploadContent);
|
|
28976
|
-
break;
|
|
28977
|
-
}
|
|
28978
|
-
}
|
|
28979
29065
|
handleDelete() {
|
|
28980
29066
|
this.delete.emit();
|
|
28981
29067
|
}
|
|
29068
|
+
resetErrors() {
|
|
29069
|
+
this.imageFileError = false;
|
|
29070
|
+
this.uploadError = false;
|
|
29071
|
+
}
|
|
28982
29072
|
toggleAltTextInput() {
|
|
28983
29073
|
this.showAltTextInput = !this.showAltTextInput;
|
|
28984
29074
|
}
|
|
@@ -28998,7 +29088,7 @@ class ImageInputComponent {
|
|
|
28998
29088
|
});
|
|
28999
29089
|
}
|
|
29000
29090
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: ImageInputComponent, deps: [{ token: i1.HttpClient }, { token: i0.ChangeDetectorRef }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
29001
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.2.13", type: ImageInputComponent, isStandalone: true, selector: "gn-ui-image-input", inputs: {
|
|
29091
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.2.13", type: ImageInputComponent, isStandalone: true, selector: "gn-ui-image-input", inputs: { previewUrl: "previewUrl", altText: "altText", maxSizeMB: "maxSizeMB", uploadProgress: "uploadProgress", uploadError: "uploadError", disabled: "disabled" }, outputs: { fileChange: "fileChange", urlChange: "urlChange", uploadCancel: "uploadCancel", delete: "delete", altTextChange: "altTextChange" }, providers: [
|
|
29002
29092
|
provideIcons({
|
|
29003
29093
|
iconoirMediaImage,
|
|
29004
29094
|
iconoirFramePlusIn,
|
|
@@ -29010,7 +29100,7 @@ class ImageInputComponent {
|
|
|
29010
29100
|
provideNgIconsConfig({
|
|
29011
29101
|
size: '1.5rem',
|
|
29012
29102
|
}),
|
|
29013
|
-
], ngImport: i0, template: "<ng-container *ngIf=\"previewUrl; then withImage; else withoutImage\">\n</ng-container>\n\n<ng-template #withImage>\n <div class=\"w-80 h-full flex flex-col gap-2\">\n <gn-ui-image-overlay-preview class=\"h-48\" [imageUrl]=\"previewUrl\">\n </gn-ui-image-overlay-preview>\n <gn-ui-text-input\n *ngIf=\"showAltTextInput\"\n [placeholder]=\"'input.image.altTextPlaceholder' | translate\"\n [value]=\"altText ?? ''\"\n (valueChange)=\"handleAltTextChange($event)\"\n extraClass=\"gn-ui-editor-textarea\"\n
|
|
29103
|
+
], ngImport: i0, template: "<ng-container *ngIf=\"previewUrl; then withImage; else withoutImage\">\n</ng-container>\n\n<ng-template #withImage>\n <div class=\"w-80 h-full flex flex-col gap-2\">\n <gn-ui-image-overlay-preview class=\"h-48\" [imageUrl]=\"previewUrl\">\n </gn-ui-image-overlay-preview>\n <gn-ui-text-input\n *ngIf=\"showAltTextInput\"\n [placeholder]=\"'input.image.altTextPlaceholder' | translate\"\n [value]=\"altText ?? ''\"\n (valueChange)=\"handleAltTextChange($event)\"\n extraClass=\"gn-ui-editor-textarea\"\n ></gn-ui-text-input>\n <div class=\"flex flex-row gap-2 mt-2\">\n <gn-ui-button\n type=\"gray\"\n (buttonClick)=\"handleDelete()\"\n data-cy=\"delete-image\"\n >\n <ng-icon class=\"me-1 text-primary\" name=\"iconoirBin\"></ng-icon>\n {{ 'input.image.delete' | translate }}\n </gn-ui-button>\n <gn-ui-button\n *ngIf=\"!showAltTextInput\"\n type=\"gray\"\n (buttonClick)=\"toggleAltTextInput()\"\n >\n <ng-icon name=\"iconoirPlus\" class=\"me-1 text-primary\"></ng-icon>\n {{ 'input.image.displayAltTextInput' | translate }}\n </gn-ui-button>\n </div>\n </div>\n</ng-template>\n\n<ng-template #withoutImage>\n <div class=\"w-full h-full flex flex-col gap-2\">\n <label\n gnUiFilesDrop\n class=\"flex-1 border-2 border-dashed rounded-lg p-6 flex flex-col items-center justify-center gap-4 transition-colors duration-100\"\n [ngClass]=\"{\n 'border-primary-lighter bg-primary-white': dragFilesOver,\n 'border-gray-300': !dragFilesOver,\n 'cursor-pointer hover:border-gray-500': !getIsActionBlocked(),\n 'cursor-not-allowed': disabled,\n }\"\n [attr.tabindex]=\"getIsActionBlocked() ? null : 0\"\n (keydown.enter)=\"fileInput.click()\"\n (dragFilesOver)=\"handleDragFilesOver($event)\"\n (dropFiles)=\"handleDropFiles($event)\"\n >\n <div\n class=\"w-14 h-14 rounded-md bg-gray-50 grid\"\n *ngIf=\"!isUploadInProgress && !imageFileError\"\n >\n <ng-icon\n *ngIf=\"!dragFilesOver\"\n class=\"place-self-center text-primary\"\n name=\"iconoirMediaImage\"\n ></ng-icon>\n <ng-icon\n *ngIf=\"dragFilesOver\"\n class=\"place-self-center text-primary\"\n name=\"iconoirFramePlusIn\"\n ></ng-icon>\n </div>\n\n <div\n *ngIf=\"isUploadInProgress && !imageFileError\"\n class=\"w-14 h-14 grid items-center justify-center relative\"\n >\n <div class=\"text-gray-100 absolute\">\n <mat-progress-spinner\n class=\"place-self-center\"\n [diameter]=\"56\"\n mode=\"determinate\"\n [value]=\"100\"\n ></mat-progress-spinner>\n </div>\n <div class=\"text-primary absolute\">\n <mat-progress-spinner\n class=\"place-self-center\"\n [diameter]=\"56\"\n mode=\"determinate\"\n [value]=\"uploadProgress\"\n ></mat-progress-spinner>\n </div>\n <span class=\"text-sm text-main font-bold\">{{ uploadProgress }}%</span>\n </div>\n\n <div class=\"w-14 h-14 rounded-md bg-gray-50 grid\" *ngIf=\"imageFileError\">\n <ng-icon\n name=\"iconoirMediaImageXmark\"\n class=\"place-self-center text-rose-500\"\n data-cy=\"imgErrorIcon\"\n ></ng-icon>\n </div>\n\n <div class=\"flex flex-col items-center gap-1\">\n <p class=\"font-medium\" data-cy=\"imgInputMsgPrimary\">\n {{ getPrimaryText() | translate }}\n </p>\n <p\n class=\"text-sm\"\n data-cy=\"imgInputMsgSecondary\"\n [class]=\"\n isUploadInProgress\n ? 'font-bold text-blue-500 cursor-pointer'\n : 'font-medium text-gray-500'\n \"\n (click)=\"handleSecondaryTextClick($event)\"\n >\n {{ getSecondaryText() | translate }}\n </p>\n </div>\n <input\n #fileInput\n accept=\"image/*\"\n type=\"file\"\n class=\"hidden\"\n (change)=\"handleFileInput($event)\"\n [disabled]=\"isUploadInProgress || disabled\"\n />\n </label>\n\n <div *ngIf=\"!showUrlInput\" class=\"flex-none mt-2\">\n <gn-ui-button\n data-cy=\"imgUrlBtn\"\n (buttonClick)=\"displayUrlInput()\"\n type=\"gray\"\n [disabled]=\"disabled\"\n [extraClass]=\"disabled && 'cursor-not-allowed'\"\n >\n <ng-icon class=\"me-1 text-primary\" name=\"iconoirLink\"></ng-icon>\n {{ 'input.image.displayUrlInput' | translate }}\n </gn-ui-button>\n </div>\n\n <gn-ui-url-input\n *ngIf=\"showUrlInput\"\n class=\"mt-3.5\"\n data-cy=\"imgUrlInput\"\n (uploadClick)=\"downloadUrl($event)\"\n [disabled]=\"isUploadInProgress || disabled\"\n >\n </gn-ui-url-input>\n </div>\n</ng-template>\n", styles: [":host{--gn-ui-button-padding: 8px 8px;--gn-ui-button-rounded: 8px}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1$2.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i1$2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: ButtonComponent, selector: "gn-ui-button", inputs: ["type", "disabled", "extraClass"], outputs: ["buttonClick"] }, { kind: "directive", type: FilesDropDirective, selector: "[gnUiFilesDrop]", outputs: ["dragFilesOver", "dropFiles"] }, { kind: "ngmodule", type: MatProgressSpinnerModule }, { kind: "component", type: i1$5.MatProgressSpinner, selector: "mat-progress-spinner, mat-spinner", inputs: ["color", "mode", "value", "diameter", "strokeWidth"], exportAs: ["matProgressSpinner"] }, { kind: "ngmodule", type: TranslateModule }, { kind: "pipe", type: i1$1.TranslatePipe, name: "translate" }, { kind: "component", type: UrlInputComponent, selector: "gn-ui-url-input", inputs: ["value", "extraClass", "placeholder", "disabled", "showValidateButton", "resetUrlOnChange"], outputs: ["valueChange", "uploadClick"] }, { kind: "component", type: TextInputComponent, selector: "gn-ui-text-input", inputs: ["value", "extraClass", "placeholder", "required", "disabled"], outputs: ["valueChange"] }, { kind: "component", type: NgIconComponent, selector: "ng-icon", inputs: ["name", "svg", "size", "strokeWidth", "color"] }, { kind: "component", type: ImageOverlayPreviewComponent, selector: "gn-ui-image-overlay-preview", inputs: ["imageUrl"], outputs: ["isPlaceholderShown"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
29014
29104
|
}
|
|
29015
29105
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: ImageInputComponent, decorators: [{
|
|
29016
29106
|
type: Component,
|
|
@@ -29036,13 +29126,13 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImpo
|
|
|
29036
29126
|
provideNgIconsConfig({
|
|
29037
29127
|
size: '1.5rem',
|
|
29038
29128
|
}),
|
|
29039
|
-
], template: "<ng-container *ngIf=\"previewUrl; then withImage; else withoutImage\">\n</ng-container>\n\n<ng-template #withImage>\n <div class=\"w-80 h-full flex flex-col gap-2\">\n <gn-ui-image-overlay-preview class=\"h-48\" [imageUrl]=\"previewUrl\">\n </gn-ui-image-overlay-preview>\n <gn-ui-text-input\n *ngIf=\"showAltTextInput\"\n [placeholder]=\"'input.image.altTextPlaceholder' | translate\"\n [value]=\"altText ?? ''\"\n (valueChange)=\"handleAltTextChange($event)\"\n extraClass=\"gn-ui-editor-textarea\"\n
|
|
29040
|
-
}], ctorParameters: () => [{ type: i1.HttpClient }, { type: i0.ChangeDetectorRef }], propDecorators: {
|
|
29041
|
-
type: Input
|
|
29042
|
-
}], previewUrl: [{
|
|
29129
|
+
], template: "<ng-container *ngIf=\"previewUrl; then withImage; else withoutImage\">\n</ng-container>\n\n<ng-template #withImage>\n <div class=\"w-80 h-full flex flex-col gap-2\">\n <gn-ui-image-overlay-preview class=\"h-48\" [imageUrl]=\"previewUrl\">\n </gn-ui-image-overlay-preview>\n <gn-ui-text-input\n *ngIf=\"showAltTextInput\"\n [placeholder]=\"'input.image.altTextPlaceholder' | translate\"\n [value]=\"altText ?? ''\"\n (valueChange)=\"handleAltTextChange($event)\"\n extraClass=\"gn-ui-editor-textarea\"\n ></gn-ui-text-input>\n <div class=\"flex flex-row gap-2 mt-2\">\n <gn-ui-button\n type=\"gray\"\n (buttonClick)=\"handleDelete()\"\n data-cy=\"delete-image\"\n >\n <ng-icon class=\"me-1 text-primary\" name=\"iconoirBin\"></ng-icon>\n {{ 'input.image.delete' | translate }}\n </gn-ui-button>\n <gn-ui-button\n *ngIf=\"!showAltTextInput\"\n type=\"gray\"\n (buttonClick)=\"toggleAltTextInput()\"\n >\n <ng-icon name=\"iconoirPlus\" class=\"me-1 text-primary\"></ng-icon>\n {{ 'input.image.displayAltTextInput' | translate }}\n </gn-ui-button>\n </div>\n </div>\n</ng-template>\n\n<ng-template #withoutImage>\n <div class=\"w-full h-full flex flex-col gap-2\">\n <label\n gnUiFilesDrop\n class=\"flex-1 border-2 border-dashed rounded-lg p-6 flex flex-col items-center justify-center gap-4 transition-colors duration-100\"\n [ngClass]=\"{\n 'border-primary-lighter bg-primary-white': dragFilesOver,\n 'border-gray-300': !dragFilesOver,\n 'cursor-pointer hover:border-gray-500': !getIsActionBlocked(),\n 'cursor-not-allowed': disabled,\n }\"\n [attr.tabindex]=\"getIsActionBlocked() ? null : 0\"\n (keydown.enter)=\"fileInput.click()\"\n (dragFilesOver)=\"handleDragFilesOver($event)\"\n (dropFiles)=\"handleDropFiles($event)\"\n >\n <div\n class=\"w-14 h-14 rounded-md bg-gray-50 grid\"\n *ngIf=\"!isUploadInProgress && !imageFileError\"\n >\n <ng-icon\n *ngIf=\"!dragFilesOver\"\n class=\"place-self-center text-primary\"\n name=\"iconoirMediaImage\"\n ></ng-icon>\n <ng-icon\n *ngIf=\"dragFilesOver\"\n class=\"place-self-center text-primary\"\n name=\"iconoirFramePlusIn\"\n ></ng-icon>\n </div>\n\n <div\n *ngIf=\"isUploadInProgress && !imageFileError\"\n class=\"w-14 h-14 grid items-center justify-center relative\"\n >\n <div class=\"text-gray-100 absolute\">\n <mat-progress-spinner\n class=\"place-self-center\"\n [diameter]=\"56\"\n mode=\"determinate\"\n [value]=\"100\"\n ></mat-progress-spinner>\n </div>\n <div class=\"text-primary absolute\">\n <mat-progress-spinner\n class=\"place-self-center\"\n [diameter]=\"56\"\n mode=\"determinate\"\n [value]=\"uploadProgress\"\n ></mat-progress-spinner>\n </div>\n <span class=\"text-sm text-main font-bold\">{{ uploadProgress }}%</span>\n </div>\n\n <div class=\"w-14 h-14 rounded-md bg-gray-50 grid\" *ngIf=\"imageFileError\">\n <ng-icon\n name=\"iconoirMediaImageXmark\"\n class=\"place-self-center text-rose-500\"\n data-cy=\"imgErrorIcon\"\n ></ng-icon>\n </div>\n\n <div class=\"flex flex-col items-center gap-1\">\n <p class=\"font-medium\" data-cy=\"imgInputMsgPrimary\">\n {{ getPrimaryText() | translate }}\n </p>\n <p\n class=\"text-sm\"\n data-cy=\"imgInputMsgSecondary\"\n [class]=\"\n isUploadInProgress\n ? 'font-bold text-blue-500 cursor-pointer'\n : 'font-medium text-gray-500'\n \"\n (click)=\"handleSecondaryTextClick($event)\"\n >\n {{ getSecondaryText() | translate }}\n </p>\n </div>\n <input\n #fileInput\n accept=\"image/*\"\n type=\"file\"\n class=\"hidden\"\n (change)=\"handleFileInput($event)\"\n [disabled]=\"isUploadInProgress || disabled\"\n />\n </label>\n\n <div *ngIf=\"!showUrlInput\" class=\"flex-none mt-2\">\n <gn-ui-button\n data-cy=\"imgUrlBtn\"\n (buttonClick)=\"displayUrlInput()\"\n type=\"gray\"\n [disabled]=\"disabled\"\n [extraClass]=\"disabled && 'cursor-not-allowed'\"\n >\n <ng-icon class=\"me-1 text-primary\" name=\"iconoirLink\"></ng-icon>\n {{ 'input.image.displayUrlInput' | translate }}\n </gn-ui-button>\n </div>\n\n <gn-ui-url-input\n *ngIf=\"showUrlInput\"\n class=\"mt-3.5\"\n data-cy=\"imgUrlInput\"\n (uploadClick)=\"downloadUrl($event)\"\n [disabled]=\"isUploadInProgress || disabled\"\n >\n </gn-ui-url-input>\n </div>\n</ng-template>\n", styles: [":host{--gn-ui-button-padding: 8px 8px;--gn-ui-button-rounded: 8px}\n"] }]
|
|
29130
|
+
}], ctorParameters: () => [{ type: i1.HttpClient }, { type: i0.ChangeDetectorRef }], propDecorators: { previewUrl: [{
|
|
29043
29131
|
type: Input
|
|
29044
29132
|
}], altText: [{
|
|
29045
29133
|
type: Input
|
|
29134
|
+
}], maxSizeMB: [{
|
|
29135
|
+
type: Input
|
|
29046
29136
|
}], uploadProgress: [{
|
|
29047
29137
|
type: Input
|
|
29048
29138
|
}], uploadError: [{
|
|
@@ -31254,8 +31344,10 @@ class FuzzySearchComponent {
|
|
|
31254
31344
|
this.recordsRepository = recordsRepository;
|
|
31255
31345
|
this.autoFocus = false;
|
|
31256
31346
|
this.forceTrackPosition = false;
|
|
31347
|
+
this.enterButton = false;
|
|
31257
31348
|
this.itemSelected = new EventEmitter();
|
|
31258
31349
|
this.inputSubmitted = new EventEmitter();
|
|
31350
|
+
this.isSearchActive = new EventEmitter();
|
|
31259
31351
|
this.displayWithFn = (record) => record.title;
|
|
31260
31352
|
this.autoCompleteAction = (query) => this.recordsRepository
|
|
31261
31353
|
.fuzzySearch(query)
|
|
@@ -31295,12 +31387,15 @@ class FuzzySearchComponent {
|
|
|
31295
31387
|
this.searchService.updateFilters({ any: '' });
|
|
31296
31388
|
}
|
|
31297
31389
|
}
|
|
31390
|
+
handleSearchActive(event) {
|
|
31391
|
+
this.isSearchActive.emit(event);
|
|
31392
|
+
}
|
|
31298
31393
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: FuzzySearchComponent, deps: [{ token: SearchFacade }, { token: SearchService }, { token: RecordsRepositoryInterface }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
31299
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.2.13", type: FuzzySearchComponent, selector: "gn-ui-fuzzy-search", inputs: { autoFocus: "autoFocus", forceTrackPosition: "forceTrackPosition" }, outputs: { itemSelected: "itemSelected", inputSubmitted: "inputSubmitted" }, viewQueries: [{ propertyName: "autocomplete", first: true, predicate: AutocompleteComponent, descendants: true }], ngImport: i0, template: "<gn-ui-autocomplete\n [placeholder]=\"'search.field.any.placeholder' | translate\"\n [displayWithFn]=\"displayWithFn\"\n [action]=\"autoCompleteAction\"\n (itemSelected)=\"handleItemSelection($event)\"\n (inputSubmitted)=\"handleInputSubmission($event)\"\n (inputCleared)=\"handleInputCleared()\"\n [value]=\"searchInputValue$ | async\"\n [preventCompleteOnSelection]=\"true\"\n [autoFocus]=\"autoFocus\"\n [allowSubmit]=\"true\"\n [forceTrackPosition]=\"forceTrackPosition\"\n></gn-ui-autocomplete>\n", styles: [""], dependencies: [{ kind: "component", type: AutocompleteComponent, selector: "gn-ui-autocomplete", inputs: ["placeholder", "action", "value", "clearOnSelection", "preventCompleteOnSelection", "autoFocus", "minCharacterCount", "allowSubmit", "forceTrackPosition", "displayWithFn"], outputs: ["itemSelected", "inputSubmitted", "inputCleared"] }, { kind: "pipe", type: i1$2.AsyncPipe, name: "async" }, { kind: "pipe", type: i1$1.TranslatePipe, name: "translate" }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
31394
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.2.13", type: FuzzySearchComponent, selector: "gn-ui-fuzzy-search", inputs: { autoFocus: "autoFocus", forceTrackPosition: "forceTrackPosition", enterButton: "enterButton" }, outputs: { itemSelected: "itemSelected", inputSubmitted: "inputSubmitted", isSearchActive: "isSearchActive" }, viewQueries: [{ propertyName: "autocomplete", first: true, predicate: AutocompleteComponent, descendants: true }], ngImport: i0, template: "<gn-ui-autocomplete\n [placeholder]=\"'search.field.any.placeholder' | translate\"\n [displayWithFn]=\"displayWithFn\"\n [action]=\"autoCompleteAction\"\n (itemSelected)=\"handleItemSelection($event)\"\n (inputSubmitted)=\"handleInputSubmission($event)\"\n (inputCleared)=\"handleInputCleared()\"\n (isSearchActive)=\"handleSearchActive($event)\"\n [value]=\"searchInputValue$ | async\"\n [preventCompleteOnSelection]=\"true\"\n [autoFocus]=\"autoFocus\"\n [allowSubmit]=\"true\"\n [forceTrackPosition]=\"forceTrackPosition\"\n [enterButton]=\"enterButton\"\n></gn-ui-autocomplete>\n", styles: [""], dependencies: [{ kind: "component", type: AutocompleteComponent, selector: "gn-ui-autocomplete", inputs: ["placeholder", "enterButton", "action", "value", "clearOnSelection", "preventCompleteOnSelection", "autoFocus", "minCharacterCount", "allowSubmit", "forceTrackPosition", "displayWithFn"], outputs: ["itemSelected", "inputSubmitted", "inputCleared", "isSearchActive"] }, { kind: "pipe", type: i1$2.AsyncPipe, name: "async" }, { kind: "pipe", type: i1$1.TranslatePipe, name: "translate" }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
31300
31395
|
}
|
|
31301
31396
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: FuzzySearchComponent, decorators: [{
|
|
31302
31397
|
type: Component,
|
|
31303
|
-
args: [{ selector: 'gn-ui-fuzzy-search', changeDetection: ChangeDetectionStrategy.OnPush, template: "<gn-ui-autocomplete\n [placeholder]=\"'search.field.any.placeholder' | translate\"\n [displayWithFn]=\"displayWithFn\"\n [action]=\"autoCompleteAction\"\n (itemSelected)=\"handleItemSelection($event)\"\n (inputSubmitted)=\"handleInputSubmission($event)\"\n (inputCleared)=\"handleInputCleared()\"\n [value]=\"searchInputValue$ | async\"\n [preventCompleteOnSelection]=\"true\"\n [autoFocus]=\"autoFocus\"\n [allowSubmit]=\"true\"\n [forceTrackPosition]=\"forceTrackPosition\"\n></gn-ui-autocomplete>\n" }]
|
|
31398
|
+
args: [{ selector: 'gn-ui-fuzzy-search', changeDetection: ChangeDetectionStrategy.OnPush, template: "<gn-ui-autocomplete\n [placeholder]=\"'search.field.any.placeholder' | translate\"\n [displayWithFn]=\"displayWithFn\"\n [action]=\"autoCompleteAction\"\n (itemSelected)=\"handleItemSelection($event)\"\n (inputSubmitted)=\"handleInputSubmission($event)\"\n (inputCleared)=\"handleInputCleared()\"\n (isSearchActive)=\"handleSearchActive($event)\"\n [value]=\"searchInputValue$ | async\"\n [preventCompleteOnSelection]=\"true\"\n [autoFocus]=\"autoFocus\"\n [allowSubmit]=\"true\"\n [forceTrackPosition]=\"forceTrackPosition\"\n [enterButton]=\"enterButton\"\n></gn-ui-autocomplete>\n" }]
|
|
31304
31399
|
}], ctorParameters: () => [{ type: SearchFacade }, { type: SearchService }, { type: RecordsRepositoryInterface }], propDecorators: { autocomplete: [{
|
|
31305
31400
|
type: ViewChild,
|
|
31306
31401
|
args: [AutocompleteComponent]
|
|
@@ -31308,10 +31403,14 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImpo
|
|
|
31308
31403
|
type: Input
|
|
31309
31404
|
}], forceTrackPosition: [{
|
|
31310
31405
|
type: Input
|
|
31406
|
+
}], enterButton: [{
|
|
31407
|
+
type: Input
|
|
31311
31408
|
}], itemSelected: [{
|
|
31312
31409
|
type: Output
|
|
31313
31410
|
}], inputSubmitted: [{
|
|
31314
31411
|
type: Output
|
|
31412
|
+
}], isSearchActive: [{
|
|
31413
|
+
type: Output
|
|
31315
31414
|
}] } });
|
|
31316
31415
|
|
|
31317
31416
|
class RecordsMetricsComponent {
|
|
@@ -34370,7 +34469,7 @@ class AddLayerFromCatalogComponent {
|
|
|
34370
34469
|
ADDLAYER: new ResultsLayoutConfigItem(AddLayerRecordPreviewComponent, 'py-2', '', 'flex flex-col divide-y divide-y-grey-50'),
|
|
34371
34470
|
},
|
|
34372
34471
|
},
|
|
34373
|
-
], ngImport: i0, template: "<div class=\"h-full text-sm\">\n <gn-ui-fuzzy-search></gn-ui-fuzzy-search>\n <gn-ui-results-list-container\n layout=\"ADDLAYER\"\n ></gn-ui-results-list-container>\n</div>\n", styles: ["::ng-deep .mat-tab-body-wrapper{flex-grow:1}\n"], dependencies: [{ kind: "ngmodule", type: FeatureSearchModule }, { kind: "component", type: FuzzySearchComponent, selector: "gn-ui-fuzzy-search", inputs: ["autoFocus", "forceTrackPosition"], outputs: ["itemSelected", "inputSubmitted"] }, { kind: "component", type: ResultsListContainerComponent, selector: "gn-ui-results-list-container", inputs: ["metadataQualityDisplay", "layout", "showMore"], outputs: ["mdSelect"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
34472
|
+
], ngImport: i0, template: "<div class=\"h-full text-sm\">\n <gn-ui-fuzzy-search></gn-ui-fuzzy-search>\n <gn-ui-results-list-container\n layout=\"ADDLAYER\"\n ></gn-ui-results-list-container>\n</div>\n", styles: ["::ng-deep .mat-tab-body-wrapper{flex-grow:1}\n"], dependencies: [{ kind: "ngmodule", type: FeatureSearchModule }, { kind: "component", type: FuzzySearchComponent, selector: "gn-ui-fuzzy-search", inputs: ["autoFocus", "forceTrackPosition", "enterButton"], outputs: ["itemSelected", "inputSubmitted", "isSearchActive"] }, { kind: "component", type: ResultsListContainerComponent, selector: "gn-ui-results-list-container", inputs: ["metadataQualityDisplay", "layout", "showMore"], outputs: ["mdSelect"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
34374
34473
|
}
|
|
34375
34474
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: AddLayerFromCatalogComponent, decorators: [{
|
|
34376
34475
|
type: Component,
|
|
@@ -36151,7 +36250,7 @@ class DataTableComponent {
|
|
|
36151
36250
|
}
|
|
36152
36251
|
}
|
|
36153
36252
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: DataTableComponent, deps: [{ token: i0.ElementRef }, { token: i0.ChangeDetectorRef }, { token: i1$1.TranslateService }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
36154
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.2.13", type: DataTableComponent, isStandalone: true, selector: "gn-ui-data-table", inputs: { dataset: "dataset", activeId: "activeId" }, outputs: { selected: "selected" }, providers: [{ provide: MatPaginatorIntl, useClass: CustomMatPaginatorIntl }], viewQueries: [{ propertyName: "sort", first: true, predicate: MatSort, descendants: true }, { propertyName: "paginator", first: true, predicate: MatPaginator, descendants: true }], usesOnChanges: true, ngImport: i0, template: "<div class=\"flex flex-col border border-gray-300 rounded-lg bg-white h-full\">\n <div class=\"flex-1 overflow-y-hidden overflow-x-auto rounded-lg relative\">\n <table\n mat-table\n [dataSource]=\"dataSource\"\n matSort\n (matSortChange)=\"setSort($event)\"\n [matSortDisableClear]=\"true\"\n *ngrxLet=\"properties$ as properties\"\n >\n <ng-container *ngFor=\"let prop of properties\" [matColumnDef]=\"prop\">\n <th\n mat-header-cell\n *matHeaderCellDef\n mat-sort-header\n class=\"text-sm text-black bg-white\"\n >\n {{ prop }}\n </th>\n <td\n mat-cell\n *matCellDef=\"let element\"\n class=\"whitespace-nowrap pr-1 truncate\"\n >\n {{ element[prop] }}\n </td>\n </ng-container>\n\n <tr mat-header-row *matHeaderRowDef=\"properties; sticky: true\"></tr>\n <tr\n [id]=\"getRowEltId(row.id)\"\n mat-row\n *matRowDef=\"let row; columns: properties\"\n (click)=\"selected.emit(row)\"\n [class.active]=\"row.id === activeId\"\n ></tr>\n </table>\n <gn-ui-loading-mask\n *ngIf=\"loading$ | async\"\n class=\"sticky inset-0\"\n [message]=\"'table.loading.data' | translate\"\n ></gn-ui-loading-mask>\n <gn-ui-popup-alert\n *ngIf=\"error\"\n type=\"warning\"\n icon=\"matErrorOutlineOutline\"\n class=\"absolute m-2 inset-0 z-[100]\"\n >\n <span translate>{{ error }}</span>\n </gn-ui-popup-alert>\n </div>\n <div class=\"flex justify-between items-center overflow-hidden\">\n <div class=\"text-gray-900 px-4 py-2 text-sm\">\n <span class=\"count font-extrabold text-primary\">{{ count }}</span\n > <span translate>table.object.count</span>.\n </div>\n\n <mat-paginator\n class=\"my-[-16px]\"\n (page)=\"setPagination()\"\n [length]=\"count\"\n [pageSize]=\"10\"\n [showFirstLastButtons]=\"true\"\n [hidePageSize]=\"true\"\n ></mat-paginator>\n </div>\n</div>\n", styles: ["table{width:100%;background:#fff}th.mat-mdc-header-cell,td.mat-mdc-cell,td.mat-mdc-footer-cell{padding-right:20px}tr.mat-mdc-row,tr.mat-mdc-footer-row{height:36px}tr:hover{background:#f5f5f5}tr.mat-mdc-header-row{height:48px}[mat-header-cell]{color:#0000008a;font-size:12px;font-weight:500}tr{cursor:pointer}.active .mat-mdc-cell{color:var(--color-primary)}.mat-mdc-paginator{background:none}\n"], dependencies: [{ kind: "ngmodule", type: MatTableModule }, { kind: "component", type: i2$4.MatTable, selector: "mat-table, table[mat-table]", exportAs: ["matTable"] }, { kind: "directive", type: i2$4.MatHeaderCellDef, selector: "[matHeaderCellDef]" }, { kind: "directive", type: i2$4.MatHeaderRowDef, selector: "[matHeaderRowDef]", inputs: ["matHeaderRowDef", "matHeaderRowDefSticky"] }, { kind: "directive", type: i2$4.MatColumnDef, selector: "[matColumnDef]", inputs: ["matColumnDef"] }, { kind: "directive", type: i2$4.MatCellDef, selector: "[matCellDef]" }, { kind: "directive", type: i2$4.MatRowDef, selector: "[matRowDef]", inputs: ["matRowDefColumns", "matRowDefWhen"] }, { kind: "directive", type: i2$4.MatHeaderCell, selector: "mat-header-cell, th[mat-header-cell]" }, { kind: "directive", type: i2$4.MatCell, selector: "mat-cell, td[mat-cell]" }, { kind: "component", type: i2$4.MatHeaderRow, selector: "mat-header-row, tr[mat-header-row]", exportAs: ["matHeaderRow"] }, { kind: "component", type: i2$4.MatRow, selector: "mat-row, tr[mat-row]", exportAs: ["matRow"] }, { kind: "ngmodule", type: MatSortModule }, { kind: "directive", type: i3$1.MatSort, selector: "[matSort]", inputs: ["matSortActive", "matSortStart", "matSortDirection", "matSortDisableClear", "matSortDisabled"], outputs: ["matSortChange"], exportAs: ["matSort"] }, { kind: "component", type: i3$1.MatSortHeader, selector: "[mat-sort-header]", inputs: ["mat-sort-header", "arrowPosition", "start", "disabled", "sortActionDescription", "disableClear"], exportAs: ["matSortHeader"] }, { kind: "ngmodule", type: MatPaginatorModule }, { kind: "component", type: i4.MatPaginator, selector: "mat-paginator", inputs: ["color", "pageIndex", "length", "pageSize", "pageSizeOptions", "hidePageSize", "showFirstLastButtons", "selectConfig", "disabled"], outputs: ["page"], exportAs: ["matPaginator"] }, { kind: "ngmodule", type: ScrollingModule }, { kind: "ngmodule", type: TranslateModule }, { kind: "pipe", type: i1$1.TranslatePipe, name: "translate" }, { kind: "directive", type: i1$1.TranslateDirective, selector: "[translate],[ngx-translate]", inputs: ["translate", "translateParams"] }, { kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1$2.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i1$2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "pipe", type: i1$2.AsyncPipe, name: "async" }, { kind: "component", type: LoadingMaskComponent, selector: "gn-ui-loading-mask", inputs: ["message"] }, { kind: "component", type: PopupAlertComponent, selector: "gn-ui-popup-alert", inputs: ["icon", "type", "position"] }, { kind: "directive", type: LetDirective, selector: "[ngrxLet]", inputs: ["ngrxLet", "ngrxLetSuspenseTpl"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
36253
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.2.13", type: DataTableComponent, isStandalone: true, selector: "gn-ui-data-table", inputs: { dataset: "dataset", activeId: "activeId" }, outputs: { selected: "selected" }, providers: [{ provide: MatPaginatorIntl, useClass: CustomMatPaginatorIntl }], viewQueries: [{ propertyName: "sort", first: true, predicate: MatSort, descendants: true }, { propertyName: "paginator", first: true, predicate: MatPaginator, descendants: true }], usesOnChanges: true, ngImport: i0, template: "<div class=\"flex flex-col border border-gray-300 rounded-lg bg-white h-full\">\n <div class=\"flex-1 overflow-y-hidden overflow-x-auto rounded-lg relative\">\n <table\n mat-table\n [dataSource]=\"dataSource\"\n matSort\n (matSortChange)=\"setSort($event)\"\n [matSortDisableClear]=\"true\"\n *ngrxLet=\"properties$ as properties\"\n >\n <ng-container *ngFor=\"let prop of properties\" [matColumnDef]=\"prop\">\n <th\n mat-header-cell\n *matHeaderCellDef\n mat-sort-header\n class=\"text-sm text-black bg-white\"\n >\n {{ prop }}\n </th>\n <td\n mat-cell\n *matCellDef=\"let element\"\n class=\"whitespace-nowrap pr-1 truncate\"\n >\n {{ element[prop] }}\n </td>\n </ng-container>\n\n <tr mat-header-row *matHeaderRowDef=\"properties; sticky: true\"></tr>\n <tr\n [id]=\"getRowEltId(row.id)\"\n mat-row\n *matRowDef=\"let row; columns: properties\"\n (click)=\"selected.emit(row)\"\n [class.active]=\"\n activeId !== undefined && activeId !== null && row.id === activeId\n \"\n ></tr>\n </table>\n <gn-ui-loading-mask\n *ngIf=\"loading$ | async\"\n class=\"sticky inset-0\"\n [message]=\"'table.loading.data' | translate\"\n ></gn-ui-loading-mask>\n <gn-ui-popup-alert\n *ngIf=\"error\"\n type=\"warning\"\n icon=\"matErrorOutlineOutline\"\n class=\"absolute m-2 inset-0 z-[100]\"\n >\n <span translate>{{ error }}</span>\n </gn-ui-popup-alert>\n </div>\n <div class=\"flex justify-between items-center overflow-hidden\">\n <div class=\"text-gray-900 px-4 py-2 text-sm\">\n <span class=\"count font-extrabold text-primary\">{{ count }}</span\n > <span translate>table.object.count</span>.\n </div>\n\n <mat-paginator\n class=\"my-[-16px]\"\n (page)=\"setPagination()\"\n [length]=\"count\"\n [pageSize]=\"10\"\n [showFirstLastButtons]=\"true\"\n [hidePageSize]=\"true\"\n ></mat-paginator>\n </div>\n</div>\n", styles: ["table{width:100%;background:#fff}th.mat-mdc-header-cell,td.mat-mdc-cell,td.mat-mdc-footer-cell{padding-right:20px}tr.mat-mdc-row,tr.mat-mdc-footer-row{height:36px}tr:hover{background:#f5f5f5}tr.mat-mdc-header-row{height:48px}[mat-header-cell]{color:#0000008a;font-size:12px;font-weight:500}tr{cursor:pointer}.active .mat-mdc-cell{color:var(--color-primary)}.mat-mdc-paginator{background:none}\n"], dependencies: [{ kind: "ngmodule", type: MatTableModule }, { kind: "component", type: i2$4.MatTable, selector: "mat-table, table[mat-table]", exportAs: ["matTable"] }, { kind: "directive", type: i2$4.MatHeaderCellDef, selector: "[matHeaderCellDef]" }, { kind: "directive", type: i2$4.MatHeaderRowDef, selector: "[matHeaderRowDef]", inputs: ["matHeaderRowDef", "matHeaderRowDefSticky"] }, { kind: "directive", type: i2$4.MatColumnDef, selector: "[matColumnDef]", inputs: ["matColumnDef"] }, { kind: "directive", type: i2$4.MatCellDef, selector: "[matCellDef]" }, { kind: "directive", type: i2$4.MatRowDef, selector: "[matRowDef]", inputs: ["matRowDefColumns", "matRowDefWhen"] }, { kind: "directive", type: i2$4.MatHeaderCell, selector: "mat-header-cell, th[mat-header-cell]" }, { kind: "directive", type: i2$4.MatCell, selector: "mat-cell, td[mat-cell]" }, { kind: "component", type: i2$4.MatHeaderRow, selector: "mat-header-row, tr[mat-header-row]", exportAs: ["matHeaderRow"] }, { kind: "component", type: i2$4.MatRow, selector: "mat-row, tr[mat-row]", exportAs: ["matRow"] }, { kind: "ngmodule", type: MatSortModule }, { kind: "directive", type: i3$1.MatSort, selector: "[matSort]", inputs: ["matSortActive", "matSortStart", "matSortDirection", "matSortDisableClear", "matSortDisabled"], outputs: ["matSortChange"], exportAs: ["matSort"] }, { kind: "component", type: i3$1.MatSortHeader, selector: "[mat-sort-header]", inputs: ["mat-sort-header", "arrowPosition", "start", "disabled", "sortActionDescription", "disableClear"], exportAs: ["matSortHeader"] }, { kind: "ngmodule", type: MatPaginatorModule }, { kind: "component", type: i4.MatPaginator, selector: "mat-paginator", inputs: ["color", "pageIndex", "length", "pageSize", "pageSizeOptions", "hidePageSize", "showFirstLastButtons", "selectConfig", "disabled"], outputs: ["page"], exportAs: ["matPaginator"] }, { kind: "ngmodule", type: ScrollingModule }, { kind: "ngmodule", type: TranslateModule }, { kind: "pipe", type: i1$1.TranslatePipe, name: "translate" }, { kind: "directive", type: i1$1.TranslateDirective, selector: "[translate],[ngx-translate]", inputs: ["translate", "translateParams"] }, { kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1$2.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i1$2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "pipe", type: i1$2.AsyncPipe, name: "async" }, { kind: "component", type: LoadingMaskComponent, selector: "gn-ui-loading-mask", inputs: ["message"] }, { kind: "component", type: PopupAlertComponent, selector: "gn-ui-popup-alert", inputs: ["icon", "type", "position"] }, { kind: "directive", type: LetDirective, selector: "[ngrxLet]", inputs: ["ngrxLet", "ngrxLetSuspenseTpl"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
36155
36254
|
}
|
|
36156
36255
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: DataTableComponent, decorators: [{
|
|
36157
36256
|
type: Component,
|
|
@@ -36165,7 +36264,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImpo
|
|
|
36165
36264
|
LoadingMaskComponent,
|
|
36166
36265
|
PopupAlertComponent,
|
|
36167
36266
|
LetDirective,
|
|
36168
|
-
], providers: [{ provide: MatPaginatorIntl, useClass: CustomMatPaginatorIntl }], selector: 'gn-ui-data-table', changeDetection: ChangeDetectionStrategy.OnPush, template: "<div class=\"flex flex-col border border-gray-300 rounded-lg bg-white h-full\">\n <div class=\"flex-1 overflow-y-hidden overflow-x-auto rounded-lg relative\">\n <table\n mat-table\n [dataSource]=\"dataSource\"\n matSort\n (matSortChange)=\"setSort($event)\"\n [matSortDisableClear]=\"true\"\n *ngrxLet=\"properties$ as properties\"\n >\n <ng-container *ngFor=\"let prop of properties\" [matColumnDef]=\"prop\">\n <th\n mat-header-cell\n *matHeaderCellDef\n mat-sort-header\n class=\"text-sm text-black bg-white\"\n >\n {{ prop }}\n </th>\n <td\n mat-cell\n *matCellDef=\"let element\"\n class=\"whitespace-nowrap pr-1 truncate\"\n >\n {{ element[prop] }}\n </td>\n </ng-container>\n\n <tr mat-header-row *matHeaderRowDef=\"properties; sticky: true\"></tr>\n <tr\n [id]=\"getRowEltId(row.id)\"\n mat-row\n *matRowDef=\"let row; columns: properties\"\n (click)=\"selected.emit(row)\"\n [class.active]=\"row.id === activeId\"\n ></tr>\n </table>\n <gn-ui-loading-mask\n *ngIf=\"loading$ | async\"\n class=\"sticky inset-0\"\n [message]=\"'table.loading.data' | translate\"\n ></gn-ui-loading-mask>\n <gn-ui-popup-alert\n *ngIf=\"error\"\n type=\"warning\"\n icon=\"matErrorOutlineOutline\"\n class=\"absolute m-2 inset-0 z-[100]\"\n >\n <span translate>{{ error }}</span>\n </gn-ui-popup-alert>\n </div>\n <div class=\"flex justify-between items-center overflow-hidden\">\n <div class=\"text-gray-900 px-4 py-2 text-sm\">\n <span class=\"count font-extrabold text-primary\">{{ count }}</span\n > <span translate>table.object.count</span>.\n </div>\n\n <mat-paginator\n class=\"my-[-16px]\"\n (page)=\"setPagination()\"\n [length]=\"count\"\n [pageSize]=\"10\"\n [showFirstLastButtons]=\"true\"\n [hidePageSize]=\"true\"\n ></mat-paginator>\n </div>\n</div>\n", styles: ["table{width:100%;background:#fff}th.mat-mdc-header-cell,td.mat-mdc-cell,td.mat-mdc-footer-cell{padding-right:20px}tr.mat-mdc-row,tr.mat-mdc-footer-row{height:36px}tr:hover{background:#f5f5f5}tr.mat-mdc-header-row{height:48px}[mat-header-cell]{color:#0000008a;font-size:12px;font-weight:500}tr{cursor:pointer}.active .mat-mdc-cell{color:var(--color-primary)}.mat-mdc-paginator{background:none}\n"] }]
|
|
36267
|
+
], providers: [{ provide: MatPaginatorIntl, useClass: CustomMatPaginatorIntl }], selector: 'gn-ui-data-table', changeDetection: ChangeDetectionStrategy.OnPush, template: "<div class=\"flex flex-col border border-gray-300 rounded-lg bg-white h-full\">\n <div class=\"flex-1 overflow-y-hidden overflow-x-auto rounded-lg relative\">\n <table\n mat-table\n [dataSource]=\"dataSource\"\n matSort\n (matSortChange)=\"setSort($event)\"\n [matSortDisableClear]=\"true\"\n *ngrxLet=\"properties$ as properties\"\n >\n <ng-container *ngFor=\"let prop of properties\" [matColumnDef]=\"prop\">\n <th\n mat-header-cell\n *matHeaderCellDef\n mat-sort-header\n class=\"text-sm text-black bg-white\"\n >\n {{ prop }}\n </th>\n <td\n mat-cell\n *matCellDef=\"let element\"\n class=\"whitespace-nowrap pr-1 truncate\"\n >\n {{ element[prop] }}\n </td>\n </ng-container>\n\n <tr mat-header-row *matHeaderRowDef=\"properties; sticky: true\"></tr>\n <tr\n [id]=\"getRowEltId(row.id)\"\n mat-row\n *matRowDef=\"let row; columns: properties\"\n (click)=\"selected.emit(row)\"\n [class.active]=\"\n activeId !== undefined && activeId !== null && row.id === activeId\n \"\n ></tr>\n </table>\n <gn-ui-loading-mask\n *ngIf=\"loading$ | async\"\n class=\"sticky inset-0\"\n [message]=\"'table.loading.data' | translate\"\n ></gn-ui-loading-mask>\n <gn-ui-popup-alert\n *ngIf=\"error\"\n type=\"warning\"\n icon=\"matErrorOutlineOutline\"\n class=\"absolute m-2 inset-0 z-[100]\"\n >\n <span translate>{{ error }}</span>\n </gn-ui-popup-alert>\n </div>\n <div class=\"flex justify-between items-center overflow-hidden\">\n <div class=\"text-gray-900 px-4 py-2 text-sm\">\n <span class=\"count font-extrabold text-primary\">{{ count }}</span\n > <span translate>table.object.count</span>.\n </div>\n\n <mat-paginator\n class=\"my-[-16px]\"\n (page)=\"setPagination()\"\n [length]=\"count\"\n [pageSize]=\"10\"\n [showFirstLastButtons]=\"true\"\n [hidePageSize]=\"true\"\n ></mat-paginator>\n </div>\n</div>\n", styles: ["table{width:100%;background:#fff}th.mat-mdc-header-cell,td.mat-mdc-cell,td.mat-mdc-footer-cell{padding-right:20px}tr.mat-mdc-row,tr.mat-mdc-footer-row{height:36px}tr:hover{background:#f5f5f5}tr.mat-mdc-header-row{height:48px}[mat-header-cell]{color:#0000008a;font-size:12px;font-weight:500}tr{cursor:pointer}.active .mat-mdc-cell{color:var(--color-primary)}.mat-mdc-paginator{background:none}\n"] }]
|
|
36169
36268
|
}], ctorParameters: () => [{ type: i0.ElementRef }, { type: i0.ChangeDetectorRef }, { type: i1$1.TranslateService }], propDecorators: { dataset: [{
|
|
36170
36269
|
type: Input
|
|
36171
36270
|
}], activeId: [{
|
|
@@ -39015,15 +39114,15 @@ class ImportRecordComponent {
|
|
|
39015
39114
|
importRecord(url) {
|
|
39016
39115
|
this.isRecordImportInProgress = true;
|
|
39017
39116
|
this.recordsRepository.duplicateExternalRecord(url).subscribe({
|
|
39018
|
-
next: (
|
|
39019
|
-
if (
|
|
39117
|
+
next: (uuid) => {
|
|
39118
|
+
if (uuid) {
|
|
39020
39119
|
this.notificationsService.showNotification({
|
|
39021
39120
|
type: 'success',
|
|
39022
39121
|
title: this.translateService.instant('editor.record.importFromExternalFile.success.title'),
|
|
39023
39122
|
text: `${this.translateService.instant('editor.record.importFromExternalFile.success.body')}`,
|
|
39024
39123
|
}, 2500);
|
|
39025
39124
|
this.router
|
|
39026
|
-
.navigate(['/edit',
|
|
39125
|
+
.navigate(['/edit', uuid])
|
|
39027
39126
|
.catch((err) => console.error(err));
|
|
39028
39127
|
}
|
|
39029
39128
|
this.closeImportMenu.next();
|
|
@@ -39049,7 +39148,7 @@ class ImportRecordComponent {
|
|
|
39049
39148
|
provideNgIconsConfig({
|
|
39050
39149
|
size: '1.5em',
|
|
39051
39150
|
}),
|
|
39052
|
-
], ngImport: i0, template: "<ng-container [ngSwitch]=\"sectionDisplayed\">\n <ng-container *ngSwitchCase=\"'mainMenu'\">\n <div\n data-test=\"importMenuMainSection\"\n class=\"mt-2 border border-gray-100 p-2 flex items-center bg-white shadow-2xl rounded-2xl\"\n >\n <ul class=\"flex flex-col gap-2 w-full\">\n <li *ngFor=\"let menuItem of importMenuItems\">\n <gn-ui-button\n [attr.data-test]=\"menuItem.dataTest\"\n type=\"light\"\n extraClass=\"flex flex-row items-center gap-2 w-full justify-start\"\n (buttonClick)=\"menuItem.action()\"\n [disabled]=\"menuItem.disabled\"\n [title]=\"\n (menuItem.disabled ? 'editor.temporary.disabled' : '') | translate\n \"\n ><ng-icon [name]=\"menuItem.icon\"></ng-icon\n ><span>{{ menuItem.label }}</span></gn-ui-button\n >\n </li>\n </ul>\n </div>\n </ng-container>\n <ng-container *ngSwitchCase=\"'importExternalFile'\">\n <div\n data-test=\"importMenuImportExternalFileSection\"\n class=\"p-6 flex flex-col gap-2 mt-2 border border-gray-100 bg-white shadow-2xl rounded-2xl\"\n >\n <div class=\"flex flex-row items-center gap-2\">\n <gn-ui-button\n data-test=\"importMenuImportExternalFileSectionBackButton\"\n type=\"light\"\n (buttonClick)=\"displayMainMenu()\"\n >\n <ng-icon name=\"iconoirArrowLeft\"></ng-icon>\n </gn-ui-button>\n <span class=\"font-bold\" translate\n >dashboard.importRecord.importExternal.title</span\n >\n <span translate>dashboard.importRecord.importExternal.subtitle</span>\n </div>\n <gn-ui-url-input\n (uploadClick)=\"importRecord($event)\"\n [disabled]=\"isRecordImportInProgress\"\n ></gn-ui-url-input>\n </div>\n </ng-container>\n</ng-container>\n", styles: [""], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1$2.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i1$2.NgSwitch, selector: "[ngSwitch]", inputs: ["ngSwitch"] }, { kind: "directive", type: i1$2.NgSwitchCase, selector: "[ngSwitchCase]", inputs: ["ngSwitchCase"] }, { kind: "component", type: ButtonComponent, selector: "gn-ui-button", inputs: ["type", "disabled", "extraClass"], outputs: ["buttonClick"] }, { kind: "component", type: UrlInputComponent, selector: "gn-ui-url-input", inputs: ["value", "extraClass", "placeholder", "disabled", "showValidateButton"], outputs: ["valueChange", "uploadClick"] }, { kind: "ngmodule", type: TranslateModule }, { kind: "pipe", type: i1$1.TranslatePipe, name: "translate" }, { kind: "directive", type: i1$1.TranslateDirective, selector: "[translate],[ngx-translate]", inputs: ["translate", "translateParams"] }, { kind: "component", type: NgIconComponent, selector: "ng-icon", inputs: ["name", "svg", "size", "strokeWidth", "color"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
39151
|
+
], ngImport: i0, template: "<ng-container [ngSwitch]=\"sectionDisplayed\">\n <ng-container *ngSwitchCase=\"'mainMenu'\">\n <div\n data-test=\"importMenuMainSection\"\n class=\"mt-2 border border-gray-100 p-2 flex items-center bg-white shadow-2xl rounded-2xl\"\n >\n <ul class=\"flex flex-col gap-2 w-full\">\n <li *ngFor=\"let menuItem of importMenuItems\">\n <gn-ui-button\n [attr.data-test]=\"menuItem.dataTest\"\n type=\"light\"\n extraClass=\"flex flex-row items-center gap-2 w-full justify-start\"\n (buttonClick)=\"menuItem.action()\"\n [disabled]=\"menuItem.disabled\"\n [title]=\"\n (menuItem.disabled ? 'editor.temporary.disabled' : '') | translate\n \"\n ><ng-icon [name]=\"menuItem.icon\"></ng-icon\n ><span>{{ menuItem.label }}</span></gn-ui-button\n >\n </li>\n </ul>\n </div>\n </ng-container>\n <ng-container *ngSwitchCase=\"'importExternalFile'\">\n <div\n data-test=\"importMenuImportExternalFileSection\"\n class=\"p-6 flex flex-col gap-2 mt-2 border border-gray-100 bg-white shadow-2xl rounded-2xl\"\n >\n <div class=\"flex flex-row items-center gap-2\">\n <gn-ui-button\n data-test=\"importMenuImportExternalFileSectionBackButton\"\n type=\"light\"\n (buttonClick)=\"displayMainMenu()\"\n >\n <ng-icon name=\"iconoirArrowLeft\"></ng-icon>\n </gn-ui-button>\n <span class=\"font-bold\" translate\n >dashboard.importRecord.importExternal.title</span\n >\n <span translate>dashboard.importRecord.importExternal.subtitle</span>\n </div>\n <gn-ui-url-input\n (uploadClick)=\"importRecord($event)\"\n [disabled]=\"isRecordImportInProgress\"\n ></gn-ui-url-input>\n </div>\n </ng-container>\n</ng-container>\n", styles: [""], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1$2.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i1$2.NgSwitch, selector: "[ngSwitch]", inputs: ["ngSwitch"] }, { kind: "directive", type: i1$2.NgSwitchCase, selector: "[ngSwitchCase]", inputs: ["ngSwitchCase"] }, { kind: "component", type: ButtonComponent, selector: "gn-ui-button", inputs: ["type", "disabled", "extraClass"], outputs: ["buttonClick"] }, { kind: "component", type: UrlInputComponent, selector: "gn-ui-url-input", inputs: ["value", "extraClass", "placeholder", "disabled", "showValidateButton", "resetUrlOnChange"], outputs: ["valueChange", "uploadClick"] }, { kind: "ngmodule", type: TranslateModule }, { kind: "pipe", type: i1$1.TranslatePipe, name: "translate" }, { kind: "directive", type: i1$1.TranslateDirective, selector: "[translate],[ngx-translate]", inputs: ["translate", "translateParams"] }, { kind: "component", type: NgIconComponent, selector: "ng-icon", inputs: ["name", "svg", "size", "strokeWidth", "color"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
39053
39152
|
}
|
|
39054
39153
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: ImportRecordComponent, decorators: [{
|
|
39055
39154
|
type: Component,
|
|
@@ -39115,7 +39214,7 @@ class GenericKeywordsComponent {
|
|
|
39115
39214
|
provideIcons({
|
|
39116
39215
|
matWarningAmberOutline,
|
|
39117
39216
|
}),
|
|
39118
|
-
], ngImport: i0, template: "<div class=\"flex flex-col gap-4\">\n <gn-ui-autocomplete\n [placeholder]=\"placeholder\"\n [displayWithFn]=\"displayWithFn\"\n [action]=\"autoCompleteAction\"\n (itemSelected)=\"handleItemSelection($event)\"\n [preventCompleteOnSelection]=\"false\"\n [minCharacterCount]=\"1\"\n [allowSubmit]=\"false\"\n [clearOnSelection]=\"true\"\n ></gn-ui-autocomplete>\n <div class=\"flex gap-2 flex-wrap\">\n <gn-ui-badge\n *ngFor=\"let keyword of keywords\"\n [removable]=\"true\"\n (badgeRemoveClicked)=\"removeKeyword(keyword)\"\n >{{ keyword.label }}\n\n <ng-icon\n *ngIf=\"isPlaceWithoutExtent(keyword)\"\n [title]=\"'editor.record.form.keywords.place.withoutExtent' | translate\"\n class=\"badge-warning\"\n name=\"matWarningAmberOutline\"\n ></ng-icon>\n </gn-ui-badge>\n </div>\n</div>\n", styles: [".badge-warning{font-size:1.4em}\n"], dependencies: [{ kind: "ngmodule", type: UiInputsModule }, { kind: "component", type: BadgeComponent, selector: "gn-ui-badge", inputs: ["clickable", "removable"], outputs: ["badgeRemoveClicked"] }, { kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1$2.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i1$2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "ngmodule", type: UiWidgetsModule }, { kind: "component", type: AutocompleteComponent, selector: "gn-ui-autocomplete", inputs: ["placeholder", "action", "value", "clearOnSelection", "preventCompleteOnSelection", "autoFocus", "minCharacterCount", "allowSubmit", "forceTrackPosition", "displayWithFn"], outputs: ["itemSelected", "inputSubmitted", "inputCleared"] }, { kind: "ngmodule", type: TranslateModule }, { kind: "pipe", type: i1$1.TranslatePipe, name: "translate" }, { kind: "component", type: NgIconComponent, selector: "ng-icon", inputs: ["name", "svg", "size", "strokeWidth", "color"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
39217
|
+
], ngImport: i0, template: "<div class=\"flex flex-col gap-4\">\n <gn-ui-autocomplete\n [placeholder]=\"placeholder\"\n [displayWithFn]=\"displayWithFn\"\n [action]=\"autoCompleteAction\"\n (itemSelected)=\"handleItemSelection($event)\"\n [preventCompleteOnSelection]=\"false\"\n [minCharacterCount]=\"1\"\n [allowSubmit]=\"false\"\n [clearOnSelection]=\"true\"\n ></gn-ui-autocomplete>\n <div class=\"flex gap-2 flex-wrap\">\n <gn-ui-badge\n *ngFor=\"let keyword of keywords\"\n [removable]=\"true\"\n (badgeRemoveClicked)=\"removeKeyword(keyword)\"\n >{{ keyword.label }}\n\n <ng-icon\n *ngIf=\"isPlaceWithoutExtent(keyword)\"\n [title]=\"'editor.record.form.keywords.place.withoutExtent' | translate\"\n class=\"badge-warning\"\n name=\"matWarningAmberOutline\"\n ></ng-icon>\n </gn-ui-badge>\n </div>\n</div>\n", styles: [".badge-warning{font-size:1.4em}\n"], dependencies: [{ kind: "ngmodule", type: UiInputsModule }, { kind: "component", type: BadgeComponent, selector: "gn-ui-badge", inputs: ["clickable", "removable"], outputs: ["badgeRemoveClicked"] }, { kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1$2.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i1$2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "ngmodule", type: UiWidgetsModule }, { kind: "component", type: AutocompleteComponent, selector: "gn-ui-autocomplete", inputs: ["placeholder", "enterButton", "action", "value", "clearOnSelection", "preventCompleteOnSelection", "autoFocus", "minCharacterCount", "allowSubmit", "forceTrackPosition", "displayWithFn"], outputs: ["itemSelected", "inputSubmitted", "inputCleared", "isSearchActive"] }, { kind: "ngmodule", type: TranslateModule }, { kind: "pipe", type: i1$1.TranslatePipe, name: "translate" }, { kind: "component", type: NgIconComponent, selector: "ng-icon", inputs: ["name", "svg", "size", "strokeWidth", "color"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
39119
39218
|
}
|
|
39120
39219
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: GenericKeywordsComponent, decorators: [{
|
|
39121
39220
|
type: Component,
|
|
@@ -39628,20 +39727,16 @@ class FormFieldContactsForResourceComponent {
|
|
|
39628
39727
|
this.organizationsServiceInterface = organizationsServiceInterface;
|
|
39629
39728
|
this.valueChange = new EventEmitter();
|
|
39630
39729
|
this.contactsForRessourceByRole = new Map();
|
|
39631
|
-
this.
|
|
39632
|
-
|
|
39633
|
-
'custodian',
|
|
39634
|
-
'owner',
|
|
39635
|
-
'point_of_contact',
|
|
39636
|
-
'author',
|
|
39637
|
-
'publisher',
|
|
39638
|
-
];
|
|
39730
|
+
this.roleValues = RoleValues;
|
|
39731
|
+
this.rolesToPick = this.roleValues.filter((role) => role !== 'other' && role !== 'unspecified');
|
|
39639
39732
|
this.roleSectionsToDisplay = [];
|
|
39640
39733
|
this.allOrganizations = new Map();
|
|
39641
39734
|
/**
|
|
39642
39735
|
* gn-ui-autocomplete
|
|
39643
39736
|
*/
|
|
39644
|
-
this.displayWithFn = (user) =>
|
|
39737
|
+
this.displayWithFn = (user) => user.name
|
|
39738
|
+
? `${user.name} ${user.surname} ${user.organisation ? `(${user.organisation})` : ''}`
|
|
39739
|
+
: ``;
|
|
39645
39740
|
/**
|
|
39646
39741
|
* gn-ui-autocomplete
|
|
39647
39742
|
*/
|
|
@@ -39733,7 +39828,7 @@ class FormFieldContactsForResourceComponent {
|
|
|
39733
39828
|
provideNgIconsConfig({
|
|
39734
39829
|
size: '1.5rem',
|
|
39735
39830
|
}),
|
|
39736
|
-
], usesOnChanges: true, ngImport: i0, template: "<div class=\"flex flex-col gap-3\">\n <div class=\"flex flex-row flex-wrap gap-2\" data-test=\"rolesToPick\">\n <ng-container *ngFor=\"let role of rolesToPick\">\n <gn-ui-button type=\"gray\" (buttonClick)=\"addRoleToDisplay(role)\">\n <ng-icon name=\"iconoirPlus\" class=\"text-primary\"></ng-icon>\n \n <span translate>{{ roleToLabel(role) }}</span>\n </gn-ui-button>\n </ng-container>\n </div>\n <div\n class=\"mt-8\"\n *ngIf=\"\n roleSectionsToDisplay && roleSectionsToDisplay.length > 0;\n else noContact\n \"\n data-test=\"displayedRoles\"\n >\n <div\n *ngFor=\"\n let role of roleSectionsToDisplay;\n let index = index;\n let isLast = last\n \"\n class=\"flex flex-col gap-4\"\n >\n <div class=\"flex flex-row justify-between\">\n <span class=\"font-bold text-base\" translate>{{\n roleToLabel(role)\n }}</span>\n </div>\n\n <gn-ui-autocomplete\n [placeholder]=\"\n 'editor.record.form.field.contactsForResource.placeholder' | translate\n \"\n [action]=\"autoCompleteAction\"\n (itemSelected)=\"addContact($event, role)\"\n [displayWithFn]=\"displayWithFn\"\n [minCharacterCount]=\"1\"\n [clearOnSelection]=\"true\"\n [allowSubmit]=\"false\"\n >\n </gn-ui-autocomplete>\n\n <ng-container *ngIf=\"contactsForRessourceByRole.get(role) as contacts\">\n <gn-ui-sortable-list\n [items]=\"contacts\"\n (itemsOrderChange)=\"handleContactsChanged($event, role)\"\n [elementTemplate]=\"contactTemplate\"\n ></gn-ui-sortable-list>\n <ng-template #contactTemplate let-contact>\n <gn-ui-contact-card [contact]=\"contact\"></gn-ui-contact-card>\n </ng-template>\n </ng-container>\n\n <hr class=\"border-t-[#D6D3D1] mt-4 mb-6\" *ngIf=\"!isLast\" />\n </div>\n </div>\n <ng-template #noContact>\n <div\n class=\"p-4 border border-primary bg-primary-lightest rounded-lg\"\n translate\n >\n editor.record.form.field.contactsForResource.noContact\n </div>\n </ng-template>\n</div>\n", styles: [":host{--gn-ui-button-padding: 8px 8px;--gn-ui-button-rounded: 8px}\n"], dependencies: [{ kind: "ngmodule", type: UiInputsModule }, { kind: "component", type: ButtonComponent, selector: "gn-ui-button", inputs: ["type", "disabled", "extraClass"], outputs: ["buttonClick"] }, { kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1$2.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i1$2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "ngmodule", type: UiWidgetsModule }, { kind: "component", type: AutocompleteComponent, selector: "gn-ui-autocomplete", inputs: ["placeholder", "action", "value", "clearOnSelection", "preventCompleteOnSelection", "autoFocus", "minCharacterCount", "allowSubmit", "forceTrackPosition", "displayWithFn"], outputs: ["itemSelected", "inputSubmitted", "inputCleared"] }, { kind: "ngmodule", type: TranslateModule }, { kind: "pipe", type: i1$1.TranslatePipe, name: "translate" }, { kind: "directive", type: i1$1.TranslateDirective, selector: "[translate],[ngx-translate]", inputs: ["translate", "translateParams"] }, { kind: "component", type: ContactCardComponent, selector: "gn-ui-contact-card", inputs: ["contact"] }, { kind: "component", type: SortableListComponent, selector: "gn-ui-sortable-list", inputs: ["elementTemplate", "items"], outputs: ["itemsOrderChange"] }, { kind: "component", type: NgIconComponent, selector: "ng-icon", inputs: ["name", "svg", "size", "strokeWidth", "color"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
39831
|
+
], usesOnChanges: true, ngImport: i0, template: "<div class=\"flex flex-col gap-3\">\n <div class=\"flex flex-row flex-wrap gap-2\" data-test=\"rolesToPick\">\n <ng-container *ngFor=\"let role of rolesToPick\">\n <gn-ui-button type=\"gray\" (buttonClick)=\"addRoleToDisplay(role)\">\n <ng-icon name=\"iconoirPlus\" class=\"text-primary\"></ng-icon>\n \n <span translate>{{ roleToLabel(role) }}</span>\n </gn-ui-button>\n </ng-container>\n </div>\n <div\n class=\"mt-8\"\n *ngIf=\"\n roleSectionsToDisplay && roleSectionsToDisplay.length > 0;\n else noContact\n \"\n data-test=\"displayedRoles\"\n >\n <div\n *ngFor=\"\n let role of roleSectionsToDisplay;\n let index = index;\n let isLast = last\n \"\n class=\"flex flex-col gap-4\"\n >\n <div class=\"flex flex-row justify-between\">\n <span class=\"font-bold text-base\" translate>{{\n roleToLabel(role)\n }}</span>\n </div>\n\n <gn-ui-autocomplete\n *ngIf=\"role !== 'unspecified' && role !== 'other'\"\n [placeholder]=\"\n 'editor.record.form.field.contactsForResource.placeholder' | translate\n \"\n [action]=\"autoCompleteAction\"\n (itemSelected)=\"addContact($event, role)\"\n [displayWithFn]=\"displayWithFn\"\n [minCharacterCount]=\"1\"\n [clearOnSelection]=\"true\"\n [allowSubmit]=\"false\"\n >\n </gn-ui-autocomplete>\n\n <ng-container *ngIf=\"contactsForRessourceByRole.get(role) as contacts\">\n <gn-ui-sortable-list\n [items]=\"contacts\"\n (itemsOrderChange)=\"handleContactsChanged($event, role)\"\n [elementTemplate]=\"contactTemplate\"\n ></gn-ui-sortable-list>\n <ng-template #contactTemplate let-contact>\n <gn-ui-contact-card [contact]=\"contact\"></gn-ui-contact-card>\n </ng-template>\n </ng-container>\n\n <hr class=\"border-t-[#D6D3D1] mt-4 mb-6\" *ngIf=\"!isLast\" />\n </div>\n </div>\n <ng-template #noContact>\n <div\n class=\"p-4 border border-primary bg-primary-lightest rounded-lg\"\n translate\n >\n editor.record.form.field.contactsForResource.noContact\n </div>\n </ng-template>\n</div>\n", styles: [":host{--gn-ui-button-padding: 8px 8px;--gn-ui-button-rounded: 8px}\n"], dependencies: [{ kind: "ngmodule", type: UiInputsModule }, { kind: "component", type: ButtonComponent, selector: "gn-ui-button", inputs: ["type", "disabled", "extraClass"], outputs: ["buttonClick"] }, { kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1$2.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i1$2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "ngmodule", type: UiWidgetsModule }, { kind: "component", type: AutocompleteComponent, selector: "gn-ui-autocomplete", inputs: ["placeholder", "enterButton", "action", "value", "clearOnSelection", "preventCompleteOnSelection", "autoFocus", "minCharacterCount", "allowSubmit", "forceTrackPosition", "displayWithFn"], outputs: ["itemSelected", "inputSubmitted", "inputCleared", "isSearchActive"] }, { kind: "ngmodule", type: TranslateModule }, { kind: "pipe", type: i1$1.TranslatePipe, name: "translate" }, { kind: "directive", type: i1$1.TranslateDirective, selector: "[translate],[ngx-translate]", inputs: ["translate", "translateParams"] }, { kind: "component", type: ContactCardComponent, selector: "gn-ui-contact-card", inputs: ["contact"] }, { kind: "component", type: SortableListComponent, selector: "gn-ui-sortable-list", inputs: ["elementTemplate", "items"], outputs: ["itemsOrderChange"] }, { kind: "component", type: NgIconComponent, selector: "ng-icon", inputs: ["name", "svg", "size", "strokeWidth", "color"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
39737
39832
|
}
|
|
39738
39833
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: FormFieldContactsForResourceComponent, decorators: [{
|
|
39739
39834
|
type: Component,
|
|
@@ -39752,7 +39847,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImpo
|
|
|
39752
39847
|
provideNgIconsConfig({
|
|
39753
39848
|
size: '1.5rem',
|
|
39754
39849
|
}),
|
|
39755
|
-
], template: "<div class=\"flex flex-col gap-3\">\n <div class=\"flex flex-row flex-wrap gap-2\" data-test=\"rolesToPick\">\n <ng-container *ngFor=\"let role of rolesToPick\">\n <gn-ui-button type=\"gray\" (buttonClick)=\"addRoleToDisplay(role)\">\n <ng-icon name=\"iconoirPlus\" class=\"text-primary\"></ng-icon>\n \n <span translate>{{ roleToLabel(role) }}</span>\n </gn-ui-button>\n </ng-container>\n </div>\n <div\n class=\"mt-8\"\n *ngIf=\"\n roleSectionsToDisplay && roleSectionsToDisplay.length > 0;\n else noContact\n \"\n data-test=\"displayedRoles\"\n >\n <div\n *ngFor=\"\n let role of roleSectionsToDisplay;\n let index = index;\n let isLast = last\n \"\n class=\"flex flex-col gap-4\"\n >\n <div class=\"flex flex-row justify-between\">\n <span class=\"font-bold text-base\" translate>{{\n roleToLabel(role)\n }}</span>\n </div>\n\n <gn-ui-autocomplete\n [placeholder]=\"\n 'editor.record.form.field.contactsForResource.placeholder' | translate\n \"\n [action]=\"autoCompleteAction\"\n (itemSelected)=\"addContact($event, role)\"\n [displayWithFn]=\"displayWithFn\"\n [minCharacterCount]=\"1\"\n [clearOnSelection]=\"true\"\n [allowSubmit]=\"false\"\n >\n </gn-ui-autocomplete>\n\n <ng-container *ngIf=\"contactsForRessourceByRole.get(role) as contacts\">\n <gn-ui-sortable-list\n [items]=\"contacts\"\n (itemsOrderChange)=\"handleContactsChanged($event, role)\"\n [elementTemplate]=\"contactTemplate\"\n ></gn-ui-sortable-list>\n <ng-template #contactTemplate let-contact>\n <gn-ui-contact-card [contact]=\"contact\"></gn-ui-contact-card>\n </ng-template>\n </ng-container>\n\n <hr class=\"border-t-[#D6D3D1] mt-4 mb-6\" *ngIf=\"!isLast\" />\n </div>\n </div>\n <ng-template #noContact>\n <div\n class=\"p-4 border border-primary bg-primary-lightest rounded-lg\"\n translate\n >\n editor.record.form.field.contactsForResource.noContact\n </div>\n </ng-template>\n</div>\n", styles: [":host{--gn-ui-button-padding: 8px 8px;--gn-ui-button-rounded: 8px}\n"] }]
|
|
39850
|
+
], template: "<div class=\"flex flex-col gap-3\">\n <div class=\"flex flex-row flex-wrap gap-2\" data-test=\"rolesToPick\">\n <ng-container *ngFor=\"let role of rolesToPick\">\n <gn-ui-button type=\"gray\" (buttonClick)=\"addRoleToDisplay(role)\">\n <ng-icon name=\"iconoirPlus\" class=\"text-primary\"></ng-icon>\n \n <span translate>{{ roleToLabel(role) }}</span>\n </gn-ui-button>\n </ng-container>\n </div>\n <div\n class=\"mt-8\"\n *ngIf=\"\n roleSectionsToDisplay && roleSectionsToDisplay.length > 0;\n else noContact\n \"\n data-test=\"displayedRoles\"\n >\n <div\n *ngFor=\"\n let role of roleSectionsToDisplay;\n let index = index;\n let isLast = last\n \"\n class=\"flex flex-col gap-4\"\n >\n <div class=\"flex flex-row justify-between\">\n <span class=\"font-bold text-base\" translate>{{\n roleToLabel(role)\n }}</span>\n </div>\n\n <gn-ui-autocomplete\n *ngIf=\"role !== 'unspecified' && role !== 'other'\"\n [placeholder]=\"\n 'editor.record.form.field.contactsForResource.placeholder' | translate\n \"\n [action]=\"autoCompleteAction\"\n (itemSelected)=\"addContact($event, role)\"\n [displayWithFn]=\"displayWithFn\"\n [minCharacterCount]=\"1\"\n [clearOnSelection]=\"true\"\n [allowSubmit]=\"false\"\n >\n </gn-ui-autocomplete>\n\n <ng-container *ngIf=\"contactsForRessourceByRole.get(role) as contacts\">\n <gn-ui-sortable-list\n [items]=\"contacts\"\n (itemsOrderChange)=\"handleContactsChanged($event, role)\"\n [elementTemplate]=\"contactTemplate\"\n ></gn-ui-sortable-list>\n <ng-template #contactTemplate let-contact>\n <gn-ui-contact-card [contact]=\"contact\"></gn-ui-contact-card>\n </ng-template>\n </ng-container>\n\n <hr class=\"border-t-[#D6D3D1] mt-4 mb-6\" *ngIf=\"!isLast\" />\n </div>\n </div>\n <ng-template #noContact>\n <div\n class=\"p-4 border border-primary bg-primary-lightest rounded-lg\"\n translate\n >\n editor.record.form.field.contactsForResource.noContact\n </div>\n </ng-template>\n</div>\n", styles: [":host{--gn-ui-button-padding: 8px 8px;--gn-ui-button-rounded: 8px}\n"] }]
|
|
39756
39851
|
}], ctorParameters: () => [{ type: PlatformServiceInterface }, { type: OrganizationsServiceInterface }], propDecorators: { value: [{
|
|
39757
39852
|
type: Input
|
|
39758
39853
|
}], valueChange: [{
|
|
@@ -39831,7 +39926,7 @@ class FormFieldContactsComponent {
|
|
|
39831
39926
|
this.subscription.unsubscribe();
|
|
39832
39927
|
}
|
|
39833
39928
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: FormFieldContactsComponent, deps: [{ token: PlatformServiceInterface }, { token: OrganizationsServiceInterface }, { token: i0.ChangeDetectorRef }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
39834
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.2.13", type: FormFieldContactsComponent, isStandalone: true, selector: "gn-ui-form-field-contacts", inputs: { value: "value" }, outputs: { valueChange: "valueChange" }, usesOnChanges: true, ngImport: i0, template: "<div class=\"flex flex-col gap-3\">\n <gn-ui-autocomplete\n [placeholder]=\"'editor.record.form.field.contacts.placeholder' | translate\"\n [action]=\"autoCompleteAction\"\n (itemSelected)=\"addContact($event)\"\n [displayWithFn]=\"displayWithFn\"\n [minCharacterCount]=\"1\"\n [clearOnSelection]=\"true\"\n >\n </gn-ui-autocomplete>\n\n <ng-container *ngIf=\"contacts.length > 0; else noContact\">\n <ng-container *ngIf=\"contacts.length === 1\">\n <ng-container *ngFor=\"let contact of contacts; let index = index\">\n <gn-ui-contact-card\n [contact]=\"contact\"\n ></gn-ui-contact-card> </ng-container\n ></ng-container>\n\n <ng-container *ngIf=\"contacts.length > 1\">\n <gn-ui-sortable-list\n [items]=\"contacts\"\n (itemsOrderChange)=\"handleContactsChanged($event)\"\n [elementTemplate]=\"contactTemplate\"\n ></gn-ui-sortable-list>\n <ng-template #contactTemplate let-contact>\n <gn-ui-contact-card [contact]=\"contact\"></gn-ui-contact-card>\n </ng-template>\n </ng-container>\n </ng-container>\n</div>\n\n<ng-template #noContact>\n <div\n class=\"p-4 text-sm border border-primary bg-primary-lightest rounded-lg\"\n translate\n >\n editor.record.form.field.contacts.noContact\n </div>\n</ng-template>\n", styles: [""], dependencies: [{ kind: "ngmodule", type: UiInputsModule }, { kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1$2.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i1$2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "ngmodule", type: UiWidgetsModule }, { kind: "component", type: AutocompleteComponent, selector: "gn-ui-autocomplete", inputs: ["placeholder", "action", "value", "clearOnSelection", "preventCompleteOnSelection", "autoFocus", "minCharacterCount", "allowSubmit", "forceTrackPosition", "displayWithFn"], outputs: ["itemSelected", "inputSubmitted", "inputCleared"] }, { kind: "ngmodule", type: TranslateModule }, { kind: "pipe", type: i1$1.TranslatePipe, name: "translate" }, { kind: "directive", type: i1$1.TranslateDirective, selector: "[translate],[ngx-translate]", inputs: ["translate", "translateParams"] }, { kind: "component", type: ContactCardComponent, selector: "gn-ui-contact-card", inputs: ["contact"] }, { kind: "component", type: SortableListComponent, selector: "gn-ui-sortable-list", inputs: ["elementTemplate", "items"], outputs: ["itemsOrderChange"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
39929
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.2.13", type: FormFieldContactsComponent, isStandalone: true, selector: "gn-ui-form-field-contacts", inputs: { value: "value" }, outputs: { valueChange: "valueChange" }, usesOnChanges: true, ngImport: i0, template: "<div class=\"flex flex-col gap-3\">\n <gn-ui-autocomplete\n [placeholder]=\"'editor.record.form.field.contacts.placeholder' | translate\"\n [action]=\"autoCompleteAction\"\n (itemSelected)=\"addContact($event)\"\n [displayWithFn]=\"displayWithFn\"\n [minCharacterCount]=\"1\"\n [clearOnSelection]=\"true\"\n >\n </gn-ui-autocomplete>\n\n <ng-container *ngIf=\"contacts.length > 0; else noContact\">\n <ng-container *ngIf=\"contacts.length === 1\">\n <ng-container *ngFor=\"let contact of contacts; let index = index\">\n <gn-ui-contact-card\n [contact]=\"contact\"\n ></gn-ui-contact-card> </ng-container\n ></ng-container>\n\n <ng-container *ngIf=\"contacts.length > 1\">\n <gn-ui-sortable-list\n [items]=\"contacts\"\n (itemsOrderChange)=\"handleContactsChanged($event)\"\n [elementTemplate]=\"contactTemplate\"\n ></gn-ui-sortable-list>\n <ng-template #contactTemplate let-contact>\n <gn-ui-contact-card [contact]=\"contact\"></gn-ui-contact-card>\n </ng-template>\n </ng-container>\n </ng-container>\n</div>\n\n<ng-template #noContact>\n <div\n class=\"p-4 text-sm border border-primary bg-primary-lightest rounded-lg\"\n translate\n >\n editor.record.form.field.contacts.noContact\n </div>\n</ng-template>\n", styles: [""], dependencies: [{ kind: "ngmodule", type: UiInputsModule }, { kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1$2.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i1$2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "ngmodule", type: UiWidgetsModule }, { kind: "component", type: AutocompleteComponent, selector: "gn-ui-autocomplete", inputs: ["placeholder", "enterButton", "action", "value", "clearOnSelection", "preventCompleteOnSelection", "autoFocus", "minCharacterCount", "allowSubmit", "forceTrackPosition", "displayWithFn"], outputs: ["itemSelected", "inputSubmitted", "inputCleared", "isSearchActive"] }, { kind: "ngmodule", type: TranslateModule }, { kind: "pipe", type: i1$1.TranslatePipe, name: "translate" }, { kind: "directive", type: i1$1.TranslateDirective, selector: "[translate],[ngx-translate]", inputs: ["translate", "translateParams"] }, { kind: "component", type: ContactCardComponent, selector: "gn-ui-contact-card", inputs: ["contact"] }, { kind: "component", type: SortableListComponent, selector: "gn-ui-sortable-list", inputs: ["elementTemplate", "items"], outputs: ["itemsOrderChange"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
39835
39930
|
}
|
|
39836
39931
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: FormFieldContactsComponent, decorators: [{
|
|
39837
39932
|
type: Component,
|
|
@@ -40036,7 +40131,7 @@ class FormFieldOnlineLinkResourcesComponent {
|
|
|
40036
40131
|
});
|
|
40037
40132
|
}
|
|
40038
40133
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: FormFieldOnlineLinkResourcesComponent, deps: [{ token: NotificationsService }, { token: i1$1.TranslateService }, { token: PlatformServiceInterface }, { token: i0.ChangeDetectorRef }, { token: i1$b.MatDialog }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
40039
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.2.13", type: FormFieldOnlineLinkResourcesComponent, isStandalone: true, selector: "gn-ui-form-field-online-link-resources", inputs: { metadataUuid: "metadataUuid", value: "value" }, outputs: { valueChange: "valueChange" }, viewQueries: [{ propertyName: "dialogTemplate", first: true, predicate: ["dialogTemplate"], descendants: true }], ngImport: i0, template: "<div class=\"flex flex-col\">\n <gn-ui-file-input\n [maxSizeMB]=\"MAX_UPLOAD_SIZE_MB\"\n (fileChange)=\"handleFileChange($event)\"\n (uploadCancel)=\"handleUploadCancel()\"\n [uploadProgress]=\"uploadProgress\"\n (urlChange)=\"handleUrlChange($event)\"\n ></gn-ui-file-input>\n <div class=\"h-[8px]\"></div>\n <gn-ui-sortable-list\n [items]=\"linkResources\"\n (itemsOrderChange)=\"handleResourcesChange($event)\"\n [elementTemplate]=\"template\"\n >\n </gn-ui-sortable-list>\n <ng-template #template let-onlineResource let-index=\"index\">\n <gn-ui-online-resource-card\n [onlineResource]=\"onlineResource\"\n (modifyClick)=\"handleResourceModify(onlineResource, index)\"\n ></gn-ui-online-resource-card>\n </ng-template>\n\n <ng-template #dialogTemplate let-onlineResource>\n <div class=\"flex flex-col gap-[16px]\">\n <div>\n <h3 class=\"text-[16px] font-bold text-main mb-[12px]\" translate>\n editor.record.form.field.onlineResource.edit.title\n </h3>\n <gn-ui-text-input [(value)]=\"onlineResource.name\"></gn-ui-text-input>\n </div>\n <div>\n <h3 class=\"text-[16px] font-bold text-main mb-[12px]\" translate>\n editor.record.form.field.onlineResource.edit.description\n </h3>\n <gn-ui-text-area\n [(value)]=\"onlineResource.description\"\n ></gn-ui-text-area>\n </div>\n <span class=\"w-full border-b border-gray-300\"></span>\n <gn-ui-url-input\n class=\"w-full\"\n [disabled]=\"true\"\n [value]=\"onlineResource.url\"\n [showValidateButton]=\"false\"\n ></gn-ui-url-input>\n </div>\n </ng-template>\n</div>\n", styles: [""], dependencies: [{ kind: "component", type: FileInputComponent, selector: "gn-ui-file-input", inputs: ["maxSizeMB", "uploadProgress", "disabled"], outputs: ["fileChange", "urlChange", "uploadCancel"] }, { kind: "ngmodule", type: CommonModule }, { kind: "component", type: SortableListComponent, selector: "gn-ui-sortable-list", inputs: ["elementTemplate", "items"], outputs: ["itemsOrderChange"] }, { kind: "component", type: OnlineResourceCardComponent, selector: "gn-ui-online-resource-card", inputs: ["onlineResource"], outputs: ["modifyClick"] }, { kind: "component", type: TextInputComponent, selector: "gn-ui-text-input", inputs: ["value", "extraClass", "placeholder", "required", "disabled"], outputs: ["valueChange"] }, { kind: "component", type: TextAreaComponent, selector: "gn-ui-text-area", inputs: ["value", "disabled", "extraClass", "placeholder", "required"], outputs: ["valueChange"] }, { kind: "component", type: UrlInputComponent, selector: "gn-ui-url-input", inputs: ["value", "extraClass", "placeholder", "disabled", "showValidateButton"], outputs: ["valueChange", "uploadClick"] }, { kind: "ngmodule", type: TranslateModule }, { kind: "directive", type: i1$1.TranslateDirective, selector: "[translate],[ngx-translate]", inputs: ["translate", "translateParams"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
40134
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.2.13", type: FormFieldOnlineLinkResourcesComponent, isStandalone: true, selector: "gn-ui-form-field-online-link-resources", inputs: { metadataUuid: "metadataUuid", value: "value" }, outputs: { valueChange: "valueChange" }, viewQueries: [{ propertyName: "dialogTemplate", first: true, predicate: ["dialogTemplate"], descendants: true }], ngImport: i0, template: "<div class=\"flex flex-col\">\n <gn-ui-file-input\n [maxSizeMB]=\"MAX_UPLOAD_SIZE_MB\"\n (fileChange)=\"handleFileChange($event)\"\n (uploadCancel)=\"handleUploadCancel()\"\n [uploadProgress]=\"uploadProgress\"\n (urlChange)=\"handleUrlChange($event)\"\n ></gn-ui-file-input>\n <div class=\"h-[8px]\"></div>\n <gn-ui-sortable-list\n [items]=\"linkResources\"\n (itemsOrderChange)=\"handleResourcesChange($event)\"\n [elementTemplate]=\"template\"\n >\n </gn-ui-sortable-list>\n <ng-template #template let-onlineResource let-index=\"index\">\n <gn-ui-online-resource-card\n [onlineResource]=\"onlineResource\"\n (modifyClick)=\"handleResourceModify(onlineResource, index)\"\n ></gn-ui-online-resource-card>\n </ng-template>\n\n <ng-template #dialogTemplate let-onlineResource>\n <div class=\"flex flex-col gap-[16px]\">\n <div>\n <h3 class=\"text-[16px] font-bold text-main mb-[12px]\" translate>\n editor.record.form.field.onlineResource.edit.title\n </h3>\n <gn-ui-text-input [(value)]=\"onlineResource.name\"></gn-ui-text-input>\n </div>\n <div>\n <h3 class=\"text-[16px] font-bold text-main mb-[12px]\" translate>\n editor.record.form.field.onlineResource.edit.description\n </h3>\n <gn-ui-text-area\n [(value)]=\"onlineResource.description\"\n ></gn-ui-text-area>\n </div>\n <span class=\"w-full border-b border-gray-300\"></span>\n <gn-ui-url-input\n class=\"w-full\"\n [disabled]=\"true\"\n [value]=\"onlineResource.url\"\n [showValidateButton]=\"false\"\n ></gn-ui-url-input>\n </div>\n </ng-template>\n</div>\n", styles: [""], dependencies: [{ kind: "component", type: FileInputComponent, selector: "gn-ui-file-input", inputs: ["maxSizeMB", "uploadProgress", "disabled"], outputs: ["fileChange", "urlChange", "uploadCancel"] }, { kind: "ngmodule", type: CommonModule }, { kind: "component", type: SortableListComponent, selector: "gn-ui-sortable-list", inputs: ["elementTemplate", "items"], outputs: ["itemsOrderChange"] }, { kind: "component", type: OnlineResourceCardComponent, selector: "gn-ui-online-resource-card", inputs: ["onlineResource"], outputs: ["modifyClick"] }, { kind: "component", type: TextInputComponent, selector: "gn-ui-text-input", inputs: ["value", "extraClass", "placeholder", "required", "disabled"], outputs: ["valueChange"] }, { kind: "component", type: TextAreaComponent, selector: "gn-ui-text-area", inputs: ["value", "disabled", "extraClass", "placeholder", "required"], outputs: ["valueChange"] }, { kind: "component", type: UrlInputComponent, selector: "gn-ui-url-input", inputs: ["value", "extraClass", "placeholder", "disabled", "showValidateButton", "resetUrlOnChange"], outputs: ["valueChange", "uploadClick"] }, { kind: "ngmodule", type: TranslateModule }, { kind: "directive", type: i1$1.TranslateDirective, selector: "[translate],[ngx-translate]", inputs: ["translate", "translateParams"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
40040
40135
|
}
|
|
40041
40136
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: FormFieldOnlineLinkResourcesComponent, decorators: [{
|
|
40042
40137
|
type: Component,
|
|
@@ -40073,6 +40168,7 @@ class OnlineServiceResourceInputComponent {
|
|
|
40073
40168
|
this.modifyMode = false;
|
|
40074
40169
|
this.serviceChange = new EventEmitter();
|
|
40075
40170
|
this.errorMessage = false;
|
|
40171
|
+
this.resetUrlOnChange = Math.random();
|
|
40076
40172
|
this.layersSubject = new BehaviorSubject([]);
|
|
40077
40173
|
this.layers$ = this.layersSubject.asObservable();
|
|
40078
40174
|
this.protocolOptions = [
|
|
@@ -40137,6 +40233,7 @@ class OnlineServiceResourceInputComponent {
|
|
|
40137
40233
|
this.cdr.detectChanges();
|
|
40138
40234
|
}
|
|
40139
40235
|
resetAllFormFields() {
|
|
40236
|
+
this.resetUrlOnChange = Math.random();
|
|
40140
40237
|
this._service.url = null;
|
|
40141
40238
|
this.resetLayersSuggestion();
|
|
40142
40239
|
}
|
|
@@ -40180,7 +40277,7 @@ class OnlineServiceResourceInputComponent {
|
|
|
40180
40277
|
provideNgIconsConfig({
|
|
40181
40278
|
size: '1.5em',
|
|
40182
40279
|
}),
|
|
40183
|
-
], ngImport: i0, template: "<div class=\"flex flex-row justify-between\">\n <h3 class=\"text-[16px] font-bold text-main mb-[12px]\" translate>\n editor.record.form.field.onlineResource.edit.protocol\n </h3>\n <span\n *ngIf=\"protocolHint\"\n class=\"material-symbols-outlined m-2 gn-ui-icon-small\"\n [matTooltip]=\"protocolHint\"\n matTooltipPosition=\"above\"\n >\n help\n </span>\n</div>\n<div class=\"flex flex-row items-center gap-4 h-[48px]\">\n <mat-radio-group\n aria-labelledby=\"example-radio-group-label\"\n class=\"flex flex-row gap-[8px]\"\n [(ngModel)]=\"_service.accessServiceProtocol\"\n [disabled]=\"disabled\"\n (change)=\"resetAllFormFields()\"\n >\n <mat-radio-button\n *ngFor=\"let protocolOption of protocolOptions\"\n [value]=\"protocolOption.value\"\n >\n {{ protocolOption.label | translate }}\n </mat-radio-button>\n </mat-radio-group>\n</div>\n\n<div class=\"flex flex-col gap-4\">\n <gn-ui-url-input\n class=\"w-full\"\n (uploadClick)=\"handleUploadClick($event)\"\n (valueChange)=\"handleUrlValueChange($event)\"\n [disabled]=\"disabled\"\n [value]=\"_service.url?.toString()\"\n [showValidateButton]=\"activeLayerSuggestion\"\n >\n <ng-content *ngIf=\"activeLayerSuggestion\">\n <ng-icon name=\"iconoirRefresh\"></ng-icon>\n </ng-content>\n </gn-ui-url-input>\n\n <p class=\"text-sm text-red-500 pl-4\" *ngIf=\"errorMessage\" translate>\n editor.record.form.field.onlineResource.edit.identifier.error\n </p>\n\n <gn-ui-text-input\n class=\"grow border-b border-gray-300 pb-4\"\n [(value)]=\"_service.identifierInService\"\n [placeholder]=\"getIdentifierPlaceholder() | translate\"\n data-cy=\"identifier-in-service\"\n [disabled]=\"disabled\"\n *ngIf=\"\n !activeLayerSuggestion ||\n (_service.url && errorMessage) ||\n (modifyMode && (layers$ | async).length === 0)\n \"\n ></gn-ui-text-input>\n <gn-ui-autocomplete\n class=\"border-b border-gray-300 pb-4\"\n [placeholder]=\"\n 'editor.record.form.field.onlineResource.edit.identifier.select.label'\n | translate\n \"\n [action]=\"autoCompleteAction\"\n (itemSelected)=\"handleSelectValue($event)\"\n [displayWithFn]=\"displayWithFn\"\n [minCharacterCount]=\"0\"\n [clearOnSelection]=\"false\"\n *ngIf=\"activeLayerSuggestion && (layers$ | async)?.length > 0\"\n >\n </gn-ui-autocomplete>\n <gn-ui-button\n (buttonClick)=\"submit()\"\n [disabled]=\"disabled || !_service.identifierInService\"\n type=\"primary\"\n *ngIf=\"\n !modifyMode &&\n ((activeLayerSuggestion && (layers$ | async)) ||\n !activeLayerSuggestion ||\n (_service.url && errorMessage))\n \"\n >\n <span class=\"text-white font-bold\" translate>\n editor.record.form.field.onlineResource.edit.identifier.submit</span\n >\n </gn-ui-button>\n</div>\n", styles: [""], dependencies: [{ kind: "component", type: AutocompleteComponent, selector: "gn-ui-autocomplete", inputs: ["placeholder", "action", "value", "clearOnSelection", "preventCompleteOnSelection", "autoFocus", "minCharacterCount", "allowSubmit", "forceTrackPosition", "displayWithFn"], outputs: ["itemSelected", "inputSubmitted", "inputCleared"] }, { kind: "component", type: ButtonComponent, selector: "gn-ui-button", inputs: ["type", "disabled", "extraClass"], outputs: ["buttonClick"] }, { kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1$2.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i1$2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "pipe", type: i1$2.AsyncPipe, name: "async" }, { kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i2$1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2$1.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "ngmodule", type: MatTooltipModule }, { kind: "directive", type: i1$4.MatTooltip, selector: "[matTooltip]", inputs: ["matTooltipPosition", "matTooltipPositionAtOrigin", "matTooltipDisabled", "matTooltipShowDelay", "matTooltipHideDelay", "matTooltipTouchGestures", "matTooltip", "matTooltipClass"], exportAs: ["matTooltip"] }, { kind: "ngmodule", type: MatRadioModule }, { kind: "directive", type: i4$1.MatRadioGroup, selector: "mat-radio-group", inputs: ["color", "name", "labelPosition", "value", "selected", "disabled", "required", "disabledInteractive"], outputs: ["change"], exportAs: ["matRadioGroup"] }, { kind: "component", type: i4$1.MatRadioButton, selector: "mat-radio-button", inputs: ["id", "name", "aria-label", "aria-labelledby", "aria-describedby", "disableRipple", "tabIndex", "checked", "value", "labelPosition", "disabled", "required", "color", "disabledInteractive"], outputs: ["change"], exportAs: ["matRadioButton"] }, { kind: "component", type: NgIconComponent, selector: "ng-icon", inputs: ["name", "svg", "size", "strokeWidth", "color"] }, { kind: "component", type: TextInputComponent, selector: "gn-ui-text-input", inputs: ["value", "extraClass", "placeholder", "required", "disabled"], outputs: ["valueChange"] }, { kind: "ngmodule", type: TranslateModule }, { kind: "pipe", type: i1$1.TranslatePipe, name: "translate" }, { kind: "directive", type: i1$1.TranslateDirective, selector: "[translate],[ngx-translate]", inputs: ["translate", "translateParams"] }, { kind: "component", type: UrlInputComponent, selector: "gn-ui-url-input", inputs: ["value", "extraClass", "placeholder", "disabled", "showValidateButton"], outputs: ["valueChange", "uploadClick"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
40280
|
+
], ngImport: i0, template: "<div class=\"flex flex-row justify-between\">\n <h3 class=\"text-[16px] font-bold text-main mb-[12px]\" translate>\n editor.record.form.field.onlineResource.edit.protocol\n </h3>\n <span\n *ngIf=\"protocolHint\"\n class=\"material-symbols-outlined m-2 gn-ui-icon-small\"\n [matTooltip]=\"protocolHint\"\n matTooltipPosition=\"above\"\n >\n help\n </span>\n</div>\n<div class=\"flex flex-row items-center gap-4 h-[48px]\">\n <mat-radio-group\n aria-labelledby=\"example-radio-group-label\"\n class=\"flex flex-row gap-[8px]\"\n [(ngModel)]=\"_service.accessServiceProtocol\"\n [disabled]=\"disabled\"\n (change)=\"resetAllFormFields()\"\n >\n <mat-radio-button\n *ngFor=\"let protocolOption of protocolOptions\"\n [value]=\"protocolOption.value\"\n >\n {{ protocolOption.label | translate }}\n </mat-radio-button>\n </mat-radio-group>\n</div>\n\n<div class=\"flex flex-col gap-4\">\n <gn-ui-url-input\n class=\"w-full\"\n (uploadClick)=\"handleUploadClick($event)\"\n (valueChange)=\"handleUrlValueChange($event)\"\n [disabled]=\"disabled\"\n [value]=\"_service.url?.toString()\"\n [showValidateButton]=\"activeLayerSuggestion\"\n [resetUrlOnChange]=\"resetUrlOnChange\"\n >\n <ng-content *ngIf=\"activeLayerSuggestion\">\n <ng-icon name=\"iconoirRefresh\"></ng-icon>\n </ng-content>\n </gn-ui-url-input>\n\n <p class=\"text-sm text-red-500 pl-4\" *ngIf=\"errorMessage\" translate>\n editor.record.form.field.onlineResource.edit.identifier.error\n </p>\n\n <gn-ui-text-input\n class=\"grow border-b border-gray-300 pb-4\"\n [(value)]=\"_service.identifierInService\"\n [placeholder]=\"getIdentifierPlaceholder() | translate\"\n data-cy=\"identifier-in-service\"\n [disabled]=\"disabled\"\n *ngIf=\"\n !activeLayerSuggestion ||\n (_service.url && errorMessage) ||\n (modifyMode && (layers$ | async).length === 0)\n \"\n ></gn-ui-text-input>\n <gn-ui-autocomplete\n class=\"border-b border-gray-300 pb-4\"\n [placeholder]=\"\n 'editor.record.form.field.onlineResource.edit.identifier.select.label'\n | translate\n \"\n [action]=\"autoCompleteAction\"\n (itemSelected)=\"handleSelectValue($event)\"\n [displayWithFn]=\"displayWithFn\"\n [minCharacterCount]=\"0\"\n [clearOnSelection]=\"false\"\n *ngIf=\"activeLayerSuggestion && (layers$ | async)?.length > 0\"\n >\n </gn-ui-autocomplete>\n <gn-ui-button\n (buttonClick)=\"submit()\"\n [disabled]=\"disabled || !_service.identifierInService\"\n type=\"primary\"\n *ngIf=\"\n !modifyMode &&\n ((activeLayerSuggestion && (layers$ | async)) ||\n !activeLayerSuggestion ||\n (_service.url && errorMessage))\n \"\n >\n <span class=\"text-white font-bold\" translate>\n editor.record.form.field.onlineResource.edit.identifier.submit</span\n >\n </gn-ui-button>\n</div>\n", styles: [""], dependencies: [{ kind: "component", type: AutocompleteComponent, selector: "gn-ui-autocomplete", inputs: ["placeholder", "enterButton", "action", "value", "clearOnSelection", "preventCompleteOnSelection", "autoFocus", "minCharacterCount", "allowSubmit", "forceTrackPosition", "displayWithFn"], outputs: ["itemSelected", "inputSubmitted", "inputCleared", "isSearchActive"] }, { kind: "component", type: ButtonComponent, selector: "gn-ui-button", inputs: ["type", "disabled", "extraClass"], outputs: ["buttonClick"] }, { kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1$2.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i1$2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "pipe", type: i1$2.AsyncPipe, name: "async" }, { kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i2$1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2$1.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "ngmodule", type: MatTooltipModule }, { kind: "directive", type: i1$4.MatTooltip, selector: "[matTooltip]", inputs: ["matTooltipPosition", "matTooltipPositionAtOrigin", "matTooltipDisabled", "matTooltipShowDelay", "matTooltipHideDelay", "matTooltipTouchGestures", "matTooltip", "matTooltipClass"], exportAs: ["matTooltip"] }, { kind: "ngmodule", type: MatRadioModule }, { kind: "directive", type: i4$1.MatRadioGroup, selector: "mat-radio-group", inputs: ["color", "name", "labelPosition", "value", "selected", "disabled", "required", "disabledInteractive"], outputs: ["change"], exportAs: ["matRadioGroup"] }, { kind: "component", type: i4$1.MatRadioButton, selector: "mat-radio-button", inputs: ["id", "name", "aria-label", "aria-labelledby", "aria-describedby", "disableRipple", "tabIndex", "checked", "value", "labelPosition", "disabled", "required", "color", "disabledInteractive"], outputs: ["change"], exportAs: ["matRadioButton"] }, { kind: "component", type: NgIconComponent, selector: "ng-icon", inputs: ["name", "svg", "size", "strokeWidth", "color"] }, { kind: "component", type: TextInputComponent, selector: "gn-ui-text-input", inputs: ["value", "extraClass", "placeholder", "required", "disabled"], outputs: ["valueChange"] }, { kind: "ngmodule", type: TranslateModule }, { kind: "pipe", type: i1$1.TranslatePipe, name: "translate" }, { kind: "directive", type: i1$1.TranslateDirective, selector: "[translate],[ngx-translate]", inputs: ["translate", "translateParams"] }, { kind: "component", type: UrlInputComponent, selector: "gn-ui-url-input", inputs: ["value", "extraClass", "placeholder", "disabled", "showValidateButton", "resetUrlOnChange"], outputs: ["valueChange", "uploadClick"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
40184
40281
|
}
|
|
40185
40282
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: OnlineServiceResourceInputComponent, decorators: [{
|
|
40186
40283
|
type: Component,
|
|
@@ -40200,7 +40297,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImpo
|
|
|
40200
40297
|
provideNgIconsConfig({
|
|
40201
40298
|
size: '1.5em',
|
|
40202
40299
|
}),
|
|
40203
|
-
], template: "<div class=\"flex flex-row justify-between\">\n <h3 class=\"text-[16px] font-bold text-main mb-[12px]\" translate>\n editor.record.form.field.onlineResource.edit.protocol\n </h3>\n <span\n *ngIf=\"protocolHint\"\n class=\"material-symbols-outlined m-2 gn-ui-icon-small\"\n [matTooltip]=\"protocolHint\"\n matTooltipPosition=\"above\"\n >\n help\n </span>\n</div>\n<div class=\"flex flex-row items-center gap-4 h-[48px]\">\n <mat-radio-group\n aria-labelledby=\"example-radio-group-label\"\n class=\"flex flex-row gap-[8px]\"\n [(ngModel)]=\"_service.accessServiceProtocol\"\n [disabled]=\"disabled\"\n (change)=\"resetAllFormFields()\"\n >\n <mat-radio-button\n *ngFor=\"let protocolOption of protocolOptions\"\n [value]=\"protocolOption.value\"\n >\n {{ protocolOption.label | translate }}\n </mat-radio-button>\n </mat-radio-group>\n</div>\n\n<div class=\"flex flex-col gap-4\">\n <gn-ui-url-input\n class=\"w-full\"\n (uploadClick)=\"handleUploadClick($event)\"\n (valueChange)=\"handleUrlValueChange($event)\"\n [disabled]=\"disabled\"\n [value]=\"_service.url?.toString()\"\n [showValidateButton]=\"activeLayerSuggestion\"\n >\n <ng-content *ngIf=\"activeLayerSuggestion\">\n <ng-icon name=\"iconoirRefresh\"></ng-icon>\n </ng-content>\n </gn-ui-url-input>\n\n <p class=\"text-sm text-red-500 pl-4\" *ngIf=\"errorMessage\" translate>\n editor.record.form.field.onlineResource.edit.identifier.error\n </p>\n\n <gn-ui-text-input\n class=\"grow border-b border-gray-300 pb-4\"\n [(value)]=\"_service.identifierInService\"\n [placeholder]=\"getIdentifierPlaceholder() | translate\"\n data-cy=\"identifier-in-service\"\n [disabled]=\"disabled\"\n *ngIf=\"\n !activeLayerSuggestion ||\n (_service.url && errorMessage) ||\n (modifyMode && (layers$ | async).length === 0)\n \"\n ></gn-ui-text-input>\n <gn-ui-autocomplete\n class=\"border-b border-gray-300 pb-4\"\n [placeholder]=\"\n 'editor.record.form.field.onlineResource.edit.identifier.select.label'\n | translate\n \"\n [action]=\"autoCompleteAction\"\n (itemSelected)=\"handleSelectValue($event)\"\n [displayWithFn]=\"displayWithFn\"\n [minCharacterCount]=\"0\"\n [clearOnSelection]=\"false\"\n *ngIf=\"activeLayerSuggestion && (layers$ | async)?.length > 0\"\n >\n </gn-ui-autocomplete>\n <gn-ui-button\n (buttonClick)=\"submit()\"\n [disabled]=\"disabled || !_service.identifierInService\"\n type=\"primary\"\n *ngIf=\"\n !modifyMode &&\n ((activeLayerSuggestion && (layers$ | async)) ||\n !activeLayerSuggestion ||\n (_service.url && errorMessage))\n \"\n >\n <span class=\"text-white font-bold\" translate>\n editor.record.form.field.onlineResource.edit.identifier.submit</span\n >\n </gn-ui-button>\n</div>\n" }]
|
|
40300
|
+
], template: "<div class=\"flex flex-row justify-between\">\n <h3 class=\"text-[16px] font-bold text-main mb-[12px]\" translate>\n editor.record.form.field.onlineResource.edit.protocol\n </h3>\n <span\n *ngIf=\"protocolHint\"\n class=\"material-symbols-outlined m-2 gn-ui-icon-small\"\n [matTooltip]=\"protocolHint\"\n matTooltipPosition=\"above\"\n >\n help\n </span>\n</div>\n<div class=\"flex flex-row items-center gap-4 h-[48px]\">\n <mat-radio-group\n aria-labelledby=\"example-radio-group-label\"\n class=\"flex flex-row gap-[8px]\"\n [(ngModel)]=\"_service.accessServiceProtocol\"\n [disabled]=\"disabled\"\n (change)=\"resetAllFormFields()\"\n >\n <mat-radio-button\n *ngFor=\"let protocolOption of protocolOptions\"\n [value]=\"protocolOption.value\"\n >\n {{ protocolOption.label | translate }}\n </mat-radio-button>\n </mat-radio-group>\n</div>\n\n<div class=\"flex flex-col gap-4\">\n <gn-ui-url-input\n class=\"w-full\"\n (uploadClick)=\"handleUploadClick($event)\"\n (valueChange)=\"handleUrlValueChange($event)\"\n [disabled]=\"disabled\"\n [value]=\"_service.url?.toString()\"\n [showValidateButton]=\"activeLayerSuggestion\"\n [resetUrlOnChange]=\"resetUrlOnChange\"\n >\n <ng-content *ngIf=\"activeLayerSuggestion\">\n <ng-icon name=\"iconoirRefresh\"></ng-icon>\n </ng-content>\n </gn-ui-url-input>\n\n <p class=\"text-sm text-red-500 pl-4\" *ngIf=\"errorMessage\" translate>\n editor.record.form.field.onlineResource.edit.identifier.error\n </p>\n\n <gn-ui-text-input\n class=\"grow border-b border-gray-300 pb-4\"\n [(value)]=\"_service.identifierInService\"\n [placeholder]=\"getIdentifierPlaceholder() | translate\"\n data-cy=\"identifier-in-service\"\n [disabled]=\"disabled\"\n *ngIf=\"\n !activeLayerSuggestion ||\n (_service.url && errorMessage) ||\n (modifyMode && (layers$ | async).length === 0)\n \"\n ></gn-ui-text-input>\n <gn-ui-autocomplete\n class=\"border-b border-gray-300 pb-4\"\n [placeholder]=\"\n 'editor.record.form.field.onlineResource.edit.identifier.select.label'\n | translate\n \"\n [action]=\"autoCompleteAction\"\n (itemSelected)=\"handleSelectValue($event)\"\n [displayWithFn]=\"displayWithFn\"\n [minCharacterCount]=\"0\"\n [clearOnSelection]=\"false\"\n *ngIf=\"activeLayerSuggestion && (layers$ | async)?.length > 0\"\n >\n </gn-ui-autocomplete>\n <gn-ui-button\n (buttonClick)=\"submit()\"\n [disabled]=\"disabled || !_service.identifierInService\"\n type=\"primary\"\n *ngIf=\"\n !modifyMode &&\n ((activeLayerSuggestion && (layers$ | async)) ||\n !activeLayerSuggestion ||\n (_service.url && errorMessage))\n \"\n >\n <span class=\"text-white font-bold\" translate>\n editor.record.form.field.onlineResource.edit.identifier.submit</span\n >\n </gn-ui-button>\n</div>\n" }]
|
|
40204
40301
|
}], ctorParameters: () => [{ type: i0.ChangeDetectorRef }], propDecorators: { service: [{
|
|
40205
40302
|
type: Input
|
|
40206
40303
|
}], protocolHint: [{
|
|
@@ -40349,7 +40446,7 @@ class FormFieldOnlineResourcesComponent {
|
|
|
40349
40446
|
});
|
|
40350
40447
|
}
|
|
40351
40448
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: FormFieldOnlineResourcesComponent, deps: [{ token: NotificationsService }, { token: i1$1.TranslateService }, { token: PlatformServiceInterface }, { token: i0.ChangeDetectorRef }, { token: i1$b.MatDialog }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
40352
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.2.13", type: FormFieldOnlineResourcesComponent, isStandalone: true, selector: "gn-ui-form-field-online-resources", inputs: { metadataUuid: "metadataUuid", value: "value" }, outputs: { valueChange: "valueChange" }, viewQueries: [{ propertyName: "dialogTemplate", first: true, predicate: ["dialogTemplate"], descendants: true }], ngImport: i0, template: "<div class=\"flex flex-col\">\n <gn-ui-switch-toggle\n [options]=\"typeOptions\"\n (selectedValue)=\"onSelectedTypeChange($event.value)\"\n extraClasses=\"grow text-sm\"\n data-cy=\"online-resources-type\"\n ></gn-ui-switch-toggle>\n <div class=\"h-[8px]\"></div>\n <gn-ui-file-input\n *ngIf=\"selectedType === 'download'\"\n [maxSizeMB]=\"MAX_UPLOAD_SIZE_MB\"\n (fileChange)=\"handleFileChange($event)\"\n (uploadCancel)=\"handleUploadCancel()\"\n [uploadProgress]=\"uploadProgress\"\n (urlChange)=\"handleDownloadUrlChange($event)\"\n ></gn-ui-file-input>\n <div\n *ngIf=\"selectedType === 'service'\"\n class=\"w-full border-2 border-dashed rounded-lg p-6 flex flex-col gap-[16px]\"\n >\n <gn-ui-online-service-resource-input\n [service]=\"newService\"\n (serviceChange)=\"handleServiceChange($event)\"\n ></gn-ui-online-service-resource-input>\n </div>\n <div class=\"h-[8px]\"></div>\n <gn-ui-sortable-list\n [items]=\"notLinkResources\"\n (itemsOrderChange)=\"handleResourcesChange($event)\"\n [elementTemplate]=\"template\"\n >\n </gn-ui-sortable-list>\n <ng-template #template let-onlineResource let-index=\"index\">\n <gn-ui-online-resource-card\n [onlineResource]=\"onlineResource\"\n (modifyClick)=\"handleResourceModify(onlineResource, index)\"\n ></gn-ui-online-resource-card>\n </ng-template>\n\n <ng-template #dialogTemplate let-onlineResource>\n <div class=\"flex flex-col gap-[16px]\">\n <ng-container *ngIf=\"onlineResource.type === 'service'; else urlInput\">\n <gn-ui-online-service-resource-input\n [service]=\"onlineResource\"\n [modifyMode]=\"true\"\n [disabled]=\"true\"\n ></gn-ui-online-service-resource-input>\n <div>\n <h3 class=\"text-[16px] font-bold text-main mb-[12px]\" translate>\n editor.record.form.field.onlineResource.edit.description\n </h3>\n <gn-ui-text-area\n [(value)]=\"onlineResource.description\"\n ></gn-ui-text-area>\n </div>\n </ng-container>\n <ng-template #urlInput>\n <div>\n <h3 class=\"text-[16px] font-bold text-main mb-[12px]\" translate>\n editor.record.form.field.onlineResource.edit.title\n </h3>\n <gn-ui-text-input [(value)]=\"onlineResource.name\"></gn-ui-text-input>\n </div>\n <div>\n <h3 class=\"text-[16px] font-bold text-main mb-[12px]\" translate>\n editor.record.form.field.onlineResource.edit.description\n </h3>\n <gn-ui-text-area\n [(value)]=\"onlineResource.description\"\n ></gn-ui-text-area>\n </div>\n <span class=\"w-full border-b border-gray-300\"></span>\n <gn-ui-url-input\n class=\"w-full\"\n [disabled]=\"true\"\n [value]=\"onlineResource.url\"\n [showValidateButton]=\"false\"\n ></gn-ui-url-input>\n </ng-template>\n </div>\n </ng-template>\n</div>\n", styles: [""], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1$2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: SwitchToggleComponent, selector: "gn-ui-switch-toggle", inputs: ["options", "ariaLabel", "extraClasses", "disabled"], outputs: ["selectedValue"] }, { kind: "component", type: FileInputComponent, selector: "gn-ui-file-input", inputs: ["maxSizeMB", "uploadProgress", "disabled"], outputs: ["fileChange", "urlChange", "uploadCancel"] }, { kind: "component", type: OnlineServiceResourceInputComponent, selector: "gn-ui-online-service-resource-input", inputs: ["service", "protocolHint", "disabled", "modifyMode"], outputs: ["serviceChange"] }, { kind: "component", type: UrlInputComponent, selector: "gn-ui-url-input", inputs: ["value", "extraClass", "placeholder", "disabled", "showValidateButton"], outputs: ["valueChange", "uploadClick"] }, { kind: "component", type: SortableListComponent, selector: "gn-ui-sortable-list", inputs: ["elementTemplate", "items"], outputs: ["itemsOrderChange"] }, { kind: "component", type: OnlineResourceCardComponent, selector: "gn-ui-online-resource-card", inputs: ["onlineResource"], outputs: ["modifyClick"] }, { kind: "component", type: TextInputComponent, selector: "gn-ui-text-input", inputs: ["value", "extraClass", "placeholder", "required", "disabled"], outputs: ["valueChange"] }, { kind: "component", type: TextAreaComponent, selector: "gn-ui-text-area", inputs: ["value", "disabled", "extraClass", "placeholder", "required"], outputs: ["valueChange"] }, { kind: "ngmodule", type: TranslateModule }, { kind: "directive", type: i1$1.TranslateDirective, selector: "[translate],[ngx-translate]", inputs: ["translate", "translateParams"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
40449
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.2.13", type: FormFieldOnlineResourcesComponent, isStandalone: true, selector: "gn-ui-form-field-online-resources", inputs: { metadataUuid: "metadataUuid", value: "value" }, outputs: { valueChange: "valueChange" }, viewQueries: [{ propertyName: "dialogTemplate", first: true, predicate: ["dialogTemplate"], descendants: true }], ngImport: i0, template: "<div class=\"flex flex-col\">\n <gn-ui-switch-toggle\n [options]=\"typeOptions\"\n (selectedValue)=\"onSelectedTypeChange($event.value)\"\n extraClasses=\"grow text-sm\"\n data-cy=\"online-resources-type\"\n ></gn-ui-switch-toggle>\n <div class=\"h-[8px]\"></div>\n <gn-ui-file-input\n *ngIf=\"selectedType === 'download'\"\n [maxSizeMB]=\"MAX_UPLOAD_SIZE_MB\"\n (fileChange)=\"handleFileChange($event)\"\n (uploadCancel)=\"handleUploadCancel()\"\n [uploadProgress]=\"uploadProgress\"\n (urlChange)=\"handleDownloadUrlChange($event)\"\n ></gn-ui-file-input>\n <div\n *ngIf=\"selectedType === 'service'\"\n class=\"w-full border-2 border-dashed rounded-lg p-6 flex flex-col gap-[16px]\"\n >\n <gn-ui-online-service-resource-input\n [service]=\"newService\"\n (serviceChange)=\"handleServiceChange($event)\"\n ></gn-ui-online-service-resource-input>\n </div>\n <div class=\"h-[8px]\"></div>\n <gn-ui-sortable-list\n [items]=\"notLinkResources\"\n (itemsOrderChange)=\"handleResourcesChange($event)\"\n [elementTemplate]=\"template\"\n >\n </gn-ui-sortable-list>\n <ng-template #template let-onlineResource let-index=\"index\">\n <gn-ui-online-resource-card\n [onlineResource]=\"onlineResource\"\n (modifyClick)=\"handleResourceModify(onlineResource, index)\"\n ></gn-ui-online-resource-card>\n </ng-template>\n\n <ng-template #dialogTemplate let-onlineResource>\n <div class=\"flex flex-col gap-[16px]\">\n <ng-container *ngIf=\"onlineResource.type === 'service'; else urlInput\">\n <gn-ui-online-service-resource-input\n [service]=\"onlineResource\"\n [modifyMode]=\"true\"\n [disabled]=\"true\"\n ></gn-ui-online-service-resource-input>\n <div>\n <h3 class=\"text-[16px] font-bold text-main mb-[12px]\" translate>\n editor.record.form.field.onlineResource.edit.description\n </h3>\n <gn-ui-text-area\n [(value)]=\"onlineResource.description\"\n ></gn-ui-text-area>\n </div>\n </ng-container>\n <ng-template #urlInput>\n <div>\n <h3 class=\"text-[16px] font-bold text-main mb-[12px]\" translate>\n editor.record.form.field.onlineResource.edit.title\n </h3>\n <gn-ui-text-input [(value)]=\"onlineResource.name\"></gn-ui-text-input>\n </div>\n <div>\n <h3 class=\"text-[16px] font-bold text-main mb-[12px]\" translate>\n editor.record.form.field.onlineResource.edit.description\n </h3>\n <gn-ui-text-area\n [(value)]=\"onlineResource.description\"\n ></gn-ui-text-area>\n </div>\n <span class=\"w-full border-b border-gray-300\"></span>\n <gn-ui-url-input\n class=\"w-full\"\n [disabled]=\"true\"\n [value]=\"onlineResource.url\"\n [showValidateButton]=\"false\"\n ></gn-ui-url-input>\n </ng-template>\n </div>\n </ng-template>\n</div>\n", styles: [""], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1$2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: SwitchToggleComponent, selector: "gn-ui-switch-toggle", inputs: ["options", "ariaLabel", "extraClasses", "disabled"], outputs: ["selectedValue"] }, { kind: "component", type: FileInputComponent, selector: "gn-ui-file-input", inputs: ["maxSizeMB", "uploadProgress", "disabled"], outputs: ["fileChange", "urlChange", "uploadCancel"] }, { kind: "component", type: OnlineServiceResourceInputComponent, selector: "gn-ui-online-service-resource-input", inputs: ["service", "protocolHint", "disabled", "modifyMode"], outputs: ["serviceChange"] }, { kind: "component", type: UrlInputComponent, selector: "gn-ui-url-input", inputs: ["value", "extraClass", "placeholder", "disabled", "showValidateButton", "resetUrlOnChange"], outputs: ["valueChange", "uploadClick"] }, { kind: "component", type: SortableListComponent, selector: "gn-ui-sortable-list", inputs: ["elementTemplate", "items"], outputs: ["itemsOrderChange"] }, { kind: "component", type: OnlineResourceCardComponent, selector: "gn-ui-online-resource-card", inputs: ["onlineResource"], outputs: ["modifyClick"] }, { kind: "component", type: TextInputComponent, selector: "gn-ui-text-input", inputs: ["value", "extraClass", "placeholder", "required", "disabled"], outputs: ["valueChange"] }, { kind: "component", type: TextAreaComponent, selector: "gn-ui-text-area", inputs: ["value", "disabled", "extraClass", "placeholder", "required"], outputs: ["valueChange"] }, { kind: "ngmodule", type: TranslateModule }, { kind: "directive", type: i1$1.TranslateDirective, selector: "[translate],[ngx-translate]", inputs: ["translate", "translateParams"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
40353
40450
|
}
|
|
40354
40451
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: FormFieldOnlineResourcesComponent, decorators: [{
|
|
40355
40452
|
type: Component,
|
|
@@ -40456,7 +40553,7 @@ class FormFieldOverviewsComponent {
|
|
|
40456
40553
|
this.cd.detectChanges();
|
|
40457
40554
|
this.emitOverview({
|
|
40458
40555
|
url: event.attachment.url,
|
|
40459
|
-
description: event.attachment.fileName,
|
|
40556
|
+
description: event.attachment.fileName.replace(/\.[^/.]+$/, ''),
|
|
40460
40557
|
});
|
|
40461
40558
|
}
|
|
40462
40559
|
},
|
|
@@ -40494,7 +40591,7 @@ class FormFieldOverviewsComponent {
|
|
|
40494
40591
|
this.valueChange.emit(overView ? [overView] : []);
|
|
40495
40592
|
}
|
|
40496
40593
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: FormFieldOverviewsComponent, deps: [{ token: PlatformServiceInterface }, { token: NotificationsService }, { token: i1$1.TranslateService }, { token: i0.ChangeDetectorRef }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
40497
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.2.13", type: FormFieldOverviewsComponent, isStandalone: true, selector: "gn-ui-form-field-overviews", inputs: { metadataUuid: "metadataUuid", value: "value" }, outputs: { valueChange: "valueChange" }, ngImport: i0, template: "<div class=\"flex flex-col gap-2\">\n <gn-ui-image-input\n [maxSizeMB]=\"MAX_UPLOAD_SIZE_MB\"\n [previewUrl]=\"firstOverview.url\"\n [altText]=\"firstOverview.description\"\n (fileChange)=\"handleFileChange($event)\"\n (urlChange)=\"handleUrlChange($event)\"\n (altTextChange)=\"handleAltTextChange($event)\"\n (delete)=\"handleDelete()\"\n [uploadProgress]=\"uploadProgress\"\n (uploadCancel)=\"handleUploadCancel()\"\n ></gn-ui-image-input>\n</div>\n", styles: [""], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "component", type: ImageInputComponent, selector: "gn-ui-image-input", inputs: ["
|
|
40594
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.2.13", type: FormFieldOverviewsComponent, isStandalone: true, selector: "gn-ui-form-field-overviews", inputs: { metadataUuid: "metadataUuid", value: "value" }, outputs: { valueChange: "valueChange" }, ngImport: i0, template: "<div class=\"flex flex-col gap-2\">\n <gn-ui-image-input\n [maxSizeMB]=\"MAX_UPLOAD_SIZE_MB\"\n [previewUrl]=\"firstOverview.url\"\n [altText]=\"firstOverview.description\"\n (fileChange)=\"handleFileChange($event)\"\n (urlChange)=\"handleUrlChange($event)\"\n (altTextChange)=\"handleAltTextChange($event)\"\n (delete)=\"handleDelete()\"\n [uploadProgress]=\"uploadProgress\"\n (uploadCancel)=\"handleUploadCancel()\"\n ></gn-ui-image-input>\n</div>\n", styles: [""], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "component", type: ImageInputComponent, selector: "gn-ui-image-input", inputs: ["previewUrl", "altText", "maxSizeMB", "uploadProgress", "uploadError", "disabled"], outputs: ["fileChange", "urlChange", "uploadCancel", "delete", "altTextChange"] }, { kind: "ngmodule", type: TranslateModule }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
40498
40595
|
}
|
|
40499
40596
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: FormFieldOverviewsComponent, decorators: [{
|
|
40500
40597
|
type: Component,
|
|
@@ -40775,7 +40872,7 @@ class ConstraintCardComponent {
|
|
|
40775
40872
|
provideNgIconsConfig({
|
|
40776
40873
|
size: '1.5rem',
|
|
40777
40874
|
}),
|
|
40778
|
-
], ngImport: i0, template: "<div class=\"flex flex-col gap-1 border rounded-lg p-4\">\n <gn-ui-form-field-rich\n class=\"mt-[-8px]\"\n [label]=\"label\"\n [placeholder]=\"hint | translate\"\n [value]=\"constraint_.text ?? ''\"\n (valueChange)=\"handleConstraintTextChange($event)\"\n ></gn-ui-form-field-rich>\n\n <div *ngIf=\"!showUrl\" class=\"flex-none mt-1\">\n <gn-ui-button\n (buttonClick)=\"showUrl = true\"\n type=\"gray\"\n data-cy=\"add-url-btn\"\n >\n <ng-icon name=\"iconoirPlus\" class=\"text-primary\"></ng-icon> \n <span translate>input.image.displayUrlInput</span>\n </gn-ui-button>\n </div>\n <gn-ui-url-input\n *ngIf=\"showUrl\"\n class=\"mt-3.5\"\n [value]=\"constraint_.url?.toString()\"\n (valueChange)=\"handleURLChange($event)\"\n [showValidateButton]=\"false\"\n >\n </gn-ui-url-input>\n</div>\n", styles: [":host{--gn-ui-button-padding: 8px 8px;--gn-ui-button-rounded: 8px}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1$2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: FormFieldRichComponent, selector: "gn-ui-form-field-rich", inputs: ["label", "hint", "placeholder", "value"], outputs: ["valueChange"] }, { kind: "component", type: UrlInputComponent, selector: "gn-ui-url-input", inputs: ["value", "extraClass", "placeholder", "disabled", "showValidateButton"], outputs: ["valueChange", "uploadClick"] }, { kind: "component", type: ButtonComponent, selector: "gn-ui-button", inputs: ["type", "disabled", "extraClass"], outputs: ["buttonClick"] }, { kind: "ngmodule", type: MatIconModule }, { kind: "ngmodule", type: TranslateModule }, { kind: "pipe", type: i1$1.TranslatePipe, name: "translate" }, { kind: "directive", type: i1$1.TranslateDirective, selector: "[translate],[ngx-translate]", inputs: ["translate", "translateParams"] }, { kind: "component", type: NgIconComponent, selector: "ng-icon", inputs: ["name", "svg", "size", "strokeWidth", "color"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
40875
|
+
], ngImport: i0, template: "<div class=\"flex flex-col gap-1 border rounded-lg p-4\">\n <gn-ui-form-field-rich\n class=\"mt-[-8px]\"\n [label]=\"label\"\n [placeholder]=\"hint | translate\"\n [value]=\"constraint_.text ?? ''\"\n (valueChange)=\"handleConstraintTextChange($event)\"\n ></gn-ui-form-field-rich>\n\n <div *ngIf=\"!showUrl\" class=\"flex-none mt-1\">\n <gn-ui-button\n (buttonClick)=\"showUrl = true\"\n type=\"gray\"\n data-cy=\"add-url-btn\"\n >\n <ng-icon name=\"iconoirPlus\" class=\"text-primary\"></ng-icon> \n <span translate>input.image.displayUrlInput</span>\n </gn-ui-button>\n </div>\n <gn-ui-url-input\n *ngIf=\"showUrl\"\n class=\"mt-3.5\"\n [value]=\"constraint_.url?.toString()\"\n (valueChange)=\"handleURLChange($event)\"\n [showValidateButton]=\"false\"\n >\n </gn-ui-url-input>\n</div>\n", styles: [":host{--gn-ui-button-padding: 8px 8px;--gn-ui-button-rounded: 8px}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1$2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: FormFieldRichComponent, selector: "gn-ui-form-field-rich", inputs: ["label", "hint", "placeholder", "value"], outputs: ["valueChange"] }, { kind: "component", type: UrlInputComponent, selector: "gn-ui-url-input", inputs: ["value", "extraClass", "placeholder", "disabled", "showValidateButton", "resetUrlOnChange"], outputs: ["valueChange", "uploadClick"] }, { kind: "component", type: ButtonComponent, selector: "gn-ui-button", inputs: ["type", "disabled", "extraClass"], outputs: ["buttonClick"] }, { kind: "ngmodule", type: MatIconModule }, { kind: "ngmodule", type: TranslateModule }, { kind: "pipe", type: i1$1.TranslatePipe, name: "translate" }, { kind: "directive", type: i1$1.TranslateDirective, selector: "[translate],[ngx-translate]", inputs: ["translate", "translateParams"] }, { kind: "component", type: NgIconComponent, selector: "ng-icon", inputs: ["name", "svg", "size", "strokeWidth", "color"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
40779
40876
|
}
|
|
40780
40877
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: ConstraintCardComponent, decorators: [{
|
|
40781
40878
|
type: Component,
|