@alfresco/aca-content 7.3.0 → 7.4.0-22991957830
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/assets/i18n/en.json +5 -1
- package/fesm2022/alfresco-aca-content.mjs +537 -436
- package/fesm2022/alfresco-aca-content.mjs.map +1 -1
- package/lib/components/search/search-execution.service.d.ts +20 -0
- package/lib/components/search/search-filter.service.d.ts +25 -0
- package/lib/components/search/search-in-menu/search-in-menu.component.d.ts +59 -0
- package/lib/components/search/search-input/search-input.component.d.ts +17 -44
- package/lib/components/search/search-libraries-results/search-libraries-results.component.d.ts +5 -6
- package/lib/components/search/search-navigation.service.d.ts +4 -0
- package/package.json +1 -1
- package/ui/theme.scss +11 -0
- package/ui/variables/variables.scss +0 -2
- package/lib/components/search/search-input-control/search-input-control.component.d.ts +0 -63
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import { Store } from '@ngrx/store';
|
|
2
|
+
import { AppStore } from '@alfresco/aca-shared/store';
|
|
3
|
+
import { SearchQueryBuilderService } from '@alfresco/adf-content-services';
|
|
4
|
+
import { SearchFilterService } from './search-filter.service';
|
|
5
|
+
import { SearchNavigationService } from './search-navigation.service';
|
|
6
|
+
import { SearchLibrariesQueryBuilderService } from './search-libraries-results/search-libraries-query-builder.service';
|
|
7
|
+
import * as i0 from "@angular/core";
|
|
8
|
+
export declare class SearchExecutionService {
|
|
9
|
+
private readonly store;
|
|
10
|
+
private readonly queryBuilder;
|
|
11
|
+
private readonly queryLibrariesBuilder;
|
|
12
|
+
private readonly filterService;
|
|
13
|
+
private readonly searchNavigationService;
|
|
14
|
+
constructor(store: Store<AppStore>, queryBuilder: SearchQueryBuilderService, queryLibrariesBuilder: SearchLibrariesQueryBuilderService, filterService: SearchFilterService, searchNavigationService: SearchNavigationService);
|
|
15
|
+
execute(searchedWord: string): void;
|
|
16
|
+
private executeLibrariesSearch;
|
|
17
|
+
private executeContentSearch;
|
|
18
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<SearchExecutionService, never>;
|
|
19
|
+
static ɵprov: i0.ɵɵInjectableDeclaration<SearchExecutionService>;
|
|
20
|
+
}
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
import { SearchQueryBuilderService } from '@alfresco/adf-content-services';
|
|
2
|
+
import { SearchOptionModel } from '@alfresco/aca-shared/store';
|
|
3
|
+
import * as i0 from "@angular/core";
|
|
4
|
+
export declare class SearchFilterService {
|
|
5
|
+
private readonly queryBuilder;
|
|
6
|
+
searchInMode: 'content' | 'libraries';
|
|
7
|
+
filesChecked: boolean;
|
|
8
|
+
foldersChecked: boolean;
|
|
9
|
+
searchOptions: SearchOptionModel[];
|
|
10
|
+
constructor(queryBuilder: SearchQueryBuilderService);
|
|
11
|
+
isFilesChecked(): boolean;
|
|
12
|
+
isFoldersChecked(): boolean;
|
|
13
|
+
isLibrariesChecked(): boolean;
|
|
14
|
+
isContentChecked(): boolean;
|
|
15
|
+
getSearchInLabel(): string;
|
|
16
|
+
validateSearchTerm(term: string): string | null;
|
|
17
|
+
syncSearchOptionsFromState(): void;
|
|
18
|
+
applyContentFilters(): void;
|
|
19
|
+
removeContentFilters(): void;
|
|
20
|
+
initForLibrariesRoute(): void;
|
|
21
|
+
private getOptionValue;
|
|
22
|
+
private setContentFilter;
|
|
23
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<SearchFilterService, never>;
|
|
24
|
+
static ɵprov: i0.ɵɵInjectableDeclaration<SearchFilterService>;
|
|
25
|
+
}
|
|
@@ -0,0 +1,59 @@
|
|
|
1
|
+
/*!
|
|
2
|
+
* Copyright © 2005-2025 Hyland Software, Inc. and its affiliates. All rights reserved.
|
|
3
|
+
*
|
|
4
|
+
* Alfresco Example Content Application
|
|
5
|
+
*
|
|
6
|
+
* This file is part of the Alfresco Example Content Application.
|
|
7
|
+
* If the software was purchased under a paid Alfresco license, the terms of
|
|
8
|
+
* the paid license agreement will prevail. Otherwise, the software is
|
|
9
|
+
* provided under the following open source license terms:
|
|
10
|
+
*
|
|
11
|
+
* The Alfresco Example Content Application is free software: you can redistribute it and/or modify
|
|
12
|
+
* it under the terms of the GNU Lesser General Public License as published by
|
|
13
|
+
* the Free Software Foundation, either version 3 of the License, or
|
|
14
|
+
* (at your option) any later version.
|
|
15
|
+
*
|
|
16
|
+
* The Alfresco Example Content Application is distributed in the hope that it will be useful,
|
|
17
|
+
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
18
|
+
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
19
|
+
* GNU Lesser General Public License for more details.
|
|
20
|
+
*
|
|
21
|
+
* You should have received a copy of the GNU Lesser General Public License
|
|
22
|
+
* from Hyland Software. If not, see <http://www.gnu.org/licenses/>.
|
|
23
|
+
*/
|
|
24
|
+
import { ElementRef, EventEmitter, OnInit } from '@angular/core';
|
|
25
|
+
import { SearchOptionIds } from '@alfresco/aca-shared/store';
|
|
26
|
+
import { SearchFilterService } from '../search-filter.service';
|
|
27
|
+
import * as i0 from "@angular/core";
|
|
28
|
+
export declare class SearchInMenuComponent implements OnInit {
|
|
29
|
+
readonly SearchOptionIds: typeof SearchOptionIds;
|
|
30
|
+
readonly filtersApplied: EventEmitter<void>;
|
|
31
|
+
searchInPanel: ElementRef;
|
|
32
|
+
triggerButton: ElementRef;
|
|
33
|
+
isOpen: boolean;
|
|
34
|
+
searchInMode: 'content' | 'libraries';
|
|
35
|
+
filesChecked: boolean;
|
|
36
|
+
foldersChecked: boolean;
|
|
37
|
+
readonly filterService: SearchFilterService;
|
|
38
|
+
private readonly focusTrapFactory;
|
|
39
|
+
private focusTrap;
|
|
40
|
+
private pendingSearchInMode;
|
|
41
|
+
private pendingFilesChecked;
|
|
42
|
+
private pendingFoldersChecked;
|
|
43
|
+
ngOnInit(): void;
|
|
44
|
+
toggle(): void;
|
|
45
|
+
open(): void;
|
|
46
|
+
close(): void;
|
|
47
|
+
onPanelDetached(): void;
|
|
48
|
+
onSearchInModeChange(): void;
|
|
49
|
+
onFilesCheckedChange(): void;
|
|
50
|
+
onFoldersCheckedChange(): void;
|
|
51
|
+
apply(): void;
|
|
52
|
+
reset(): void;
|
|
53
|
+
private destroyFocusTrap;
|
|
54
|
+
private initializeSavedValues;
|
|
55
|
+
private commitToService;
|
|
56
|
+
private focusTrigger;
|
|
57
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<SearchInMenuComponent, never>;
|
|
58
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<SearchInMenuComponent, "aca-search-in-menu", never, {}, { "filtersApplied": "filtersApplied"; }, never, never, true, never>;
|
|
59
|
+
}
|
|
@@ -21,66 +21,39 @@
|
|
|
21
21
|
* You should have received a copy of the GNU Lesser General Public License
|
|
22
22
|
* from Hyland Software. If not, see <http://www.gnu.org/licenses/>.
|
|
23
23
|
*/
|
|
24
|
-
import { AppHookService
|
|
25
|
-
import { AppStore, SearchOptionIds, SearchOptionModel } from '@alfresco/aca-shared/store';
|
|
26
|
-
import { SearchQueryBuilderService } from '@alfresco/adf-content-services';
|
|
24
|
+
import { AppHookService } from '@alfresco/aca-shared';
|
|
27
25
|
import { AppConfigService } from '@alfresco/adf-core';
|
|
28
|
-
import { OnDestroy, OnInit } from '@angular/core';
|
|
29
|
-
import { MatMenuTrigger } from '@angular/material/menu';
|
|
26
|
+
import { ElementRef, OnDestroy, OnInit } from '@angular/core';
|
|
30
27
|
import { ActivatedRoute, Router } from '@angular/router';
|
|
31
|
-
import { Store } from '@ngrx/store';
|
|
32
|
-
import { SearchInputControlComponent } from '../search-input-control/search-input-control.component';
|
|
33
28
|
import { SearchNavigationService } from '../search-navigation.service';
|
|
34
|
-
import {
|
|
29
|
+
import { SearchFilterService } from '../search-filter.service';
|
|
30
|
+
import { SearchExecutionService } from '../search-execution.service';
|
|
31
|
+
import { SearchQueryBuilderService } from '@alfresco/adf-content-services';
|
|
35
32
|
import * as i0 from "@angular/core";
|
|
36
33
|
export declare class SearchInputComponent implements OnInit, OnDestroy {
|
|
37
34
|
private readonly queryBuilder;
|
|
38
|
-
private readonly queryLibrariesBuilder;
|
|
39
35
|
private readonly config;
|
|
40
36
|
private readonly router;
|
|
41
37
|
private readonly route;
|
|
42
|
-
private readonly store;
|
|
43
38
|
private readonly appHookService;
|
|
44
|
-
private readonly
|
|
45
|
-
readonly
|
|
46
|
-
|
|
39
|
+
private readonly filterService;
|
|
40
|
+
private readonly searchExecutionService;
|
|
41
|
+
readonly searchNavigationService: SearchNavigationService;
|
|
47
42
|
has400LibraryError: boolean;
|
|
48
|
-
hasLibrariesConstraint: boolean;
|
|
49
43
|
searchOnChange: boolean;
|
|
50
|
-
isTrimmedWordEmpty: boolean;
|
|
51
|
-
error: string;
|
|
52
44
|
searchedWord: string;
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
trigger: MatMenuTrigger;
|
|
45
|
+
error: string;
|
|
46
|
+
searchInputField: ElementRef<HTMLInputElement>;
|
|
56
47
|
private readonly destroyRef;
|
|
57
|
-
constructor(queryBuilder: SearchQueryBuilderService,
|
|
48
|
+
constructor(queryBuilder: SearchQueryBuilderService, config: AppConfigService, router: Router, route: ActivatedRoute, appHookService: AppHookService, filterService: SearchFilterService, searchExecutionService: SearchExecutionService, searchNavigationService: SearchNavigationService);
|
|
58
49
|
ngOnInit(): void;
|
|
59
|
-
exitSearch(): void;
|
|
60
|
-
showInputValue(): void;
|
|
61
50
|
ngOnDestroy(): void;
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
onSearchSubmit(event: any): void;
|
|
69
|
-
onSearchChange(searchTerm: string): void;
|
|
70
|
-
searchByOption(): void;
|
|
71
|
-
get onLibrariesSearchResults(): boolean;
|
|
72
|
-
get onSearchResults(): boolean;
|
|
73
|
-
isFilesChecked(): boolean;
|
|
74
|
-
isFoldersChecked(): boolean;
|
|
75
|
-
isLibrariesChecked(): boolean;
|
|
76
|
-
isOptionChecked(optionId: string): boolean;
|
|
77
|
-
isContentChecked(): boolean;
|
|
78
|
-
evaluateLibrariesConstraint(): boolean;
|
|
79
|
-
filterContent(option: SearchOptionIds.Folders | SearchOptionIds.Files): void;
|
|
80
|
-
removeContentFilters(): void;
|
|
81
|
-
syncInputValues(): void;
|
|
82
|
-
getUrlSearchTerm(): string;
|
|
83
|
-
isSameSearchTerm(): boolean;
|
|
51
|
+
exitSearch(): void;
|
|
52
|
+
onSearchSubmit(searchTerm: string): void;
|
|
53
|
+
onFiltersApplied(): void;
|
|
54
|
+
executeSearch(): void;
|
|
55
|
+
private subscribeToRouteParams;
|
|
56
|
+
private initSearchState;
|
|
84
57
|
static ɵfac: i0.ɵɵFactoryDeclaration<SearchInputComponent, never>;
|
|
85
58
|
static ɵcmp: i0.ɵɵComponentDeclaration<SearchInputComponent, "aca-search-input", never, {}, {}, never, never, true, never>;
|
|
86
59
|
}
|
package/lib/components/search/search-libraries-results/search-libraries-results.component.d.ts
CHANGED
|
@@ -2,21 +2,20 @@ import { NodePaging, Pagination, SiteEntry } from '@alfresco/js-api';
|
|
|
2
2
|
import { OnInit } from '@angular/core';
|
|
3
3
|
import { ActivatedRoute } from '@angular/router';
|
|
4
4
|
import { SearchLibrariesQueryBuilderService } from './search-libraries-query-builder.service';
|
|
5
|
-
import { AppHookService,
|
|
5
|
+
import { AppHookService, PageComponent } from '@alfresco/aca-shared';
|
|
6
6
|
import { DocumentListPresetRef } from '@alfresco/adf-extensions';
|
|
7
7
|
import * as i0 from "@angular/core";
|
|
8
8
|
export declare class SearchLibrariesResultsComponent extends PageComponent implements OnInit {
|
|
9
|
-
private librariesQueryBuilder;
|
|
10
|
-
private route;
|
|
11
|
-
private appHookService;
|
|
12
|
-
private appService;
|
|
9
|
+
private readonly librariesQueryBuilder;
|
|
10
|
+
private readonly route;
|
|
11
|
+
private readonly appHookService;
|
|
13
12
|
searchedWord: string;
|
|
14
13
|
queryParamName: string;
|
|
15
14
|
data: NodePaging;
|
|
16
15
|
totalResults: number;
|
|
17
16
|
isLoading: boolean;
|
|
18
17
|
columns: DocumentListPresetRef[];
|
|
19
|
-
constructor(librariesQueryBuilder: SearchLibrariesQueryBuilderService, route: ActivatedRoute, appHookService: AppHookService
|
|
18
|
+
constructor(librariesQueryBuilder: SearchLibrariesQueryBuilderService, route: ActivatedRoute, appHookService: AppHookService);
|
|
20
19
|
ngOnInit(): void;
|
|
21
20
|
onSearchResultLoaded(nodePaging: NodePaging): void;
|
|
22
21
|
getNumberOfResults(): number;
|
|
@@ -4,10 +4,14 @@ export declare class SearchNavigationService {
|
|
|
4
4
|
private router;
|
|
5
5
|
private _previousRoute;
|
|
6
6
|
get previousRoute(): string;
|
|
7
|
+
get onLibrariesSearchResults(): boolean;
|
|
8
|
+
get onSearchResults(): boolean;
|
|
7
9
|
constructor(router: Router);
|
|
8
10
|
saveRoute(route: string): void;
|
|
9
11
|
navigateBack(): void;
|
|
10
12
|
navigateToSearch(): void;
|
|
13
|
+
getUrlSearchTerm(): string;
|
|
14
|
+
isSameSearchTerm(searchedWord: string): boolean;
|
|
11
15
|
static ɵfac: i0.ɵɵFactoryDeclaration<SearchNavigationService, never>;
|
|
12
16
|
static ɵprov: i0.ɵɵInjectableDeclaration<SearchNavigationService>;
|
|
13
17
|
}
|
package/package.json
CHANGED
package/ui/theme.scss
CHANGED
|
@@ -30,6 +30,17 @@
|
|
|
30
30
|
subscript-text-size: 12px
|
|
31
31
|
)
|
|
32
32
|
);
|
|
33
|
+
|
|
34
|
+
#{ms.$mat-radio-button} {
|
|
35
|
+
@include mat.radio-overrides(
|
|
36
|
+
(
|
|
37
|
+
selected-icon-color: var(--theme-blue-checkbox-color),
|
|
38
|
+
selected-hover-icon-color: var(--theme-blue-checkbox-color),
|
|
39
|
+
selected-focus-icon-color: var(--theme-blue-checkbox-color),
|
|
40
|
+
selected-pressed-icon-color: var(--theme-blue-checkbox-color)
|
|
41
|
+
)
|
|
42
|
+
);
|
|
43
|
+
}
|
|
33
44
|
}
|
|
34
45
|
|
|
35
46
|
.adf-search-properties-form,
|
|
@@ -59,7 +59,6 @@ $app-blue-folder: #2a7de1;
|
|
|
59
59
|
// CSS Variables
|
|
60
60
|
$defaults: (
|
|
61
61
|
--theme-background-color: $background-color,
|
|
62
|
-
--theme-search-background-color: darken($background-color, 1),
|
|
63
62
|
--theme-text-color: mat.m2-get-color-from-palette($foreground, text, 0.54),
|
|
64
63
|
--theme-sidenav-text-color: mat.m2-get-color-from-palette($foreground, text),
|
|
65
64
|
--theme-sidenav-hovered-text-color: mat.m2-get-color-from-palette($foreground, text),
|
|
@@ -71,7 +70,6 @@ $defaults: (
|
|
|
71
70
|
--theme-foreground-text-color: mat.m2-get-color-from-palette($foreground, text, 0.72),
|
|
72
71
|
--theme-foreground-text-bold-color: mat.m2-get-color-from-palette($foreground, text, 0.87),
|
|
73
72
|
--theme-secondary-text-color: mat.m2-get-color-from-palette($foreground, secondary-text),
|
|
74
|
-
--theme-divider-color: mat.m2-get-color-from-palette($foreground, divider, 0.07),
|
|
75
73
|
--theme-dialog-background-color: mat.m2-get-color-from-palette($background, dialog),
|
|
76
74
|
--theme-header-text-color: mat.m2-get-color-from-palette($foreground, text, 0.87),
|
|
77
75
|
--new-button-font-size: 0.9rem,
|
|
@@ -1,63 +0,0 @@
|
|
|
1
|
-
/*!
|
|
2
|
-
* Copyright © 2005-2025 Hyland Software, Inc. and its affiliates. All rights reserved.
|
|
3
|
-
*
|
|
4
|
-
* Alfresco Example Content Application
|
|
5
|
-
*
|
|
6
|
-
* This file is part of the Alfresco Example Content Application.
|
|
7
|
-
* If the software was purchased under a paid Alfresco license, the terms of
|
|
8
|
-
* the paid license agreement will prevail. Otherwise, the software is
|
|
9
|
-
* provided under the following open source license terms:
|
|
10
|
-
*
|
|
11
|
-
* The Alfresco Example Content Application is free software: you can redistribute it and/or modify
|
|
12
|
-
* it under the terms of the GNU Lesser General Public License as published by
|
|
13
|
-
* the Free Software Foundation, either version 3 of the License, or
|
|
14
|
-
* (at your option) any later version.
|
|
15
|
-
*
|
|
16
|
-
* The Alfresco Example Content Application is distributed in the hope that it will be useful,
|
|
17
|
-
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
18
|
-
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
19
|
-
* GNU Lesser General Public License for more details.
|
|
20
|
-
*
|
|
21
|
-
* You should have received a copy of the GNU Lesser General Public License
|
|
22
|
-
* from Hyland Software. If not, see <http://www.gnu.org/licenses/>.
|
|
23
|
-
*/
|
|
24
|
-
import { EventEmitter, ElementRef, OnInit, OnChanges, SimpleChanges } from '@angular/core';
|
|
25
|
-
import { FormControl } from '@angular/forms';
|
|
26
|
-
import * as i0 from "@angular/core";
|
|
27
|
-
export declare class SearchInputControlComponent implements OnInit, OnChanges {
|
|
28
|
-
private readonly destroyRef;
|
|
29
|
-
private readonly route;
|
|
30
|
-
private readonly router;
|
|
31
|
-
/** Type of the input field to render, e.g. "search" or "text" (default). */
|
|
32
|
-
inputType: string;
|
|
33
|
-
/**
|
|
34
|
-
* Indicates whether the search is constrained by libraries.
|
|
35
|
-
* If true, specific error messaging or validation behavior may be triggered.
|
|
36
|
-
*/
|
|
37
|
-
hasLibrariesConstraint: boolean;
|
|
38
|
-
/** Emitted when the search is submitted pressing ENTER button.
|
|
39
|
-
* The search term is provided as value of the event.
|
|
40
|
-
*/
|
|
41
|
-
submit: EventEmitter<any>;
|
|
42
|
-
/** Emitted when the search term is changed. The search term is provided
|
|
43
|
-
* in the 'value' property of the returned object. If the term is less
|
|
44
|
-
* than three characters in length then the term is truncated to an empty
|
|
45
|
-
* string.
|
|
46
|
-
*/
|
|
47
|
-
searchChange: EventEmitter<string>;
|
|
48
|
-
/** Emitted when the input control has a validation error. */
|
|
49
|
-
validationError: EventEmitter<string>;
|
|
50
|
-
searchInput: ElementRef;
|
|
51
|
-
searchFieldFormControl: FormControl<string>;
|
|
52
|
-
get searchTerm(): string;
|
|
53
|
-
set searchTerm(value: string);
|
|
54
|
-
ngOnInit(): void;
|
|
55
|
-
ngOnChanges(changes: SimpleChanges): void;
|
|
56
|
-
searchSubmit(): void;
|
|
57
|
-
clear(): void;
|
|
58
|
-
onBlur(): void;
|
|
59
|
-
isTermTooShort(): boolean;
|
|
60
|
-
emitValidationError(): void;
|
|
61
|
-
static ɵfac: i0.ɵɵFactoryDeclaration<SearchInputControlComponent, never>;
|
|
62
|
-
static ɵcmp: i0.ɵɵComponentDeclaration<SearchInputControlComponent, "app-search-input-control", never, { "inputType": { "alias": "inputType"; "required": false; }; "hasLibrariesConstraint": { "alias": "hasLibrariesConstraint"; "required": false; }; }, { "submit": "submit"; "searchChange": "searchChange"; "validationError": "validationError"; }, never, never, true, never>;
|
|
63
|
-
}
|