chore: update Angular cache and TypeScript build info files

This commit is contained in:
2025-10-02 13:46:33 -04:00
parent 20cc6e9215
commit cf4a3b60eb
11 changed files with 210 additions and 157 deletions
@@ -52,7 +52,7 @@ import { SearchOptions } from '../../core/search/search-parser.types';
(keydown.enter)="onEnter()"
(keydown.escape)="onEscape()"
[class]="inputClass"
[style.padding-left]="showSearchIcon ? '2.5rem' : '0.75rem'"
[style.padding-left]="showSearchIcon ? '2.75rem' : '1rem'"
[style.padding-right]="'7rem'"
[attr.aria-label]="placeholder"
autocomplete="off"
@@ -112,7 +112,9 @@ import { SearchOptions } from '../../core/search/search-parser.types';
[context]="context"
[currentQuery]="query"
[anchorElement]="anchorElement"
[showExamples]="showExamples"
(queryChange)="onQueryChange($event)"
(previewChange)="onPreviewChange($event)"
(querySubmit)="onQuerySubmit($event)"
/>
</div>
@@ -131,8 +133,9 @@ import { SearchOptions } from '../../core/search/search-parser.types';
export class SearchBarComponent implements AfterViewInit, OnInit {
@Input() placeholder: string = 'Search in vault...';
@Input() context: string = 'vault';
@Input() showExamples: boolean = true;
@Input() showSearchIcon: boolean = true;
@Input() inputClass: string = 'w-full px-3 py-2 text-sm border border-border dark:border-gray-600 rounded-lg bg-bg-primary dark:bg-gray-800 text-text-main dark:text-gray-100 placeholder-text-muted dark:placeholder-gray-500 focus:ring-2 focus:ring-accent dark:focus:ring-blue-500 transition-all';
@Input() inputClass: string = 'w-full rounded-full border border-border bg-bg-muted/70 py-2.5 pr-4 text-sm text-text-main placeholder:text-text-muted shadow-subtle focus:outline-none focus:ring-2 focus:ring-ring transition-all dark:border-gray-600 dark:bg-gray-800/80 dark:text-gray-100 dark:placeholder-gray-400 dark:focus:ring-blue-500';
@Input() initialQuery: string = '';
@Output() search = new EventEmitter<{ query: string; options: SearchOptions }>();
@@ -157,6 +160,16 @@ export class SearchBarComponent implements AfterViewInit, OnInit {
}
}
/**
* Handle preview changes from assistant: update visible input only.
*/
onPreviewChange(preview: string): void {
this.query = preview;
if (this.searchInputRef) {
this.searchInputRef.nativeElement.value = preview;
}
}
ngAfterViewInit(): void {
this.anchorElement = this.hostElement.nativeElement;
}
@@ -29,7 +29,7 @@ import { SearchHistoryService } from '../../core/search/search-history.service';
<div class="relative">
<svg
*ngIf="showSearchIcon"
class="pointer-events-none absolute left-3 top-1/2 h-5 w-5 -translate-y-1/2 text-text-muted"
class="pointer-events-none absolute left-3 top-1/2 h-5 w-5 -translate-y-1/2 text-text-muted dark:text-gray-400"
xmlns="http://www.w3.org/2000/svg"
fill="none"
viewBox="0 0 24 24"
@@ -47,6 +47,7 @@ import { SearchHistoryService } from '../../core/search/search-history.service';
(blur)="onBlur()"
(keydown.enter)="onEnter()"
[class]="inputClass"
[style.padding-left]="showSearchIcon ? '2.75rem' : '1rem'"
[attr.aria-label]="placeholder"
/>
@@ -67,7 +68,9 @@ import { SearchHistoryService } from '../../core/search/search-history.service';
[context]="context"
[currentQuery]="value"
[anchorElement]="anchorElement"
[showExamples]="showExamples"
(queryChange)="onQueryChange($event)"
(previewChange)="onPreviewChange($event)"
(querySubmit)="onQuerySubmit($event)"
/>
</div>
@@ -83,7 +86,8 @@ export class SearchInputWithAssistantComponent implements AfterViewInit {
@Input() value: string = '';
@Input() context: string = 'default';
@Input() showSearchIcon: boolean = true;
@Input() inputClass: string = 'w-full px-3 py-2 text-sm border border-border rounded-md bg-bg-primary text-text-main placeholder-text-muted focus:outline-none focus:ring-2 focus:ring-accent';
@Input() inputClass: string = 'w-full rounded-full border border-border bg-bg-muted/70 py-2.5 pr-4 text-sm text-text-main placeholder:text-text-muted shadow-subtle focus:outline-none focus:ring-2 focus:ring-ring transition-all dark:border-gray-600 dark:bg-gray-800/80 dark:text-gray-100 dark:placeholder-gray-400 dark:focus:ring-blue-500';
@Input() showExamples: boolean = true;
@Output() valueChange = new EventEmitter<string>();
@Output() submit = new EventEmitter<string>();
@@ -170,6 +174,17 @@ export class SearchInputWithAssistantComponent implements AfterViewInit {
}
}
/**
* Handle preview change from assistant (keyboard navigation):
* only update the visible input value without emitting or recomputing.
*/
onPreviewChange(query: string): void {
this.value = query;
if (this.searchInputRef) {
this.searchInputRef.nativeElement.value = query;
}
}
/**
* Handle query submit from assistant
*/
@@ -33,6 +33,7 @@ import { VaultService } from '../../services/vault.service';
[placeholder]="placeholder"
[context]="context"
[showSearchIcon]="true"
[showExamples]="false"
(search)="onSearch($event)"
(queryChange)="onQueryChange($event)"
/>
@@ -82,7 +82,7 @@ type NavigationItem =
{{ option.description }}
</div>
<span
*ngIf="option.example"
*ngIf="showExamples && option.example"
class="text-[11px] text-text-muted dark:text-gray-500 font-mono ml-2 truncate"
>
{{ option.example }}
@@ -180,8 +180,10 @@ export class SearchQueryAssistantComponent {
@Input() context: string = 'default'; // Search context (vault, graph, etc.)
@Input() currentQuery: string = '';
@Input() anchorElement: HTMLElement | null = null;
@Input() showExamples: boolean = true;
@Output() queryChange = new EventEmitter<string>();
@Output() querySubmit = new EventEmitter<string>();
@Output() previewChange = new EventEmitter<string>();
@ViewChild('popover') popoverRef?: ElementRef;
@@ -482,7 +484,8 @@ export class SearchQueryAssistantComponent {
}
this.currentQuery = previewQuery ?? this.currentQuery;
this.queryChange.emit(this.currentQuery);
// Emit preview change instead of confirmed change to avoid recomputing options in parent
this.previewChange.emit(this.currentQuery);
}
isSelected(type: NavigationItem['type'], index: number): boolean {