@noldova/git.window 0.0.9 → 0.0.11
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/package.json +10 -6
- package/src/api/index.d.ts +6 -1
- package/src/app/components/git-accounts/git-accounts.component.js +2 -2
- package/src/app/components/git-accounts/git-accounts.component.js.map +1 -1
- package/src/app/components/git-agents/git-agents.component.js +4 -5
- package/src/app/components/git-agents/git-agents.component.js.map +1 -1
- package/src/app/components/git-branch-card/git-branch-card.component.js +2 -2
- package/src/app/components/git-branch-card/git-branch-card.component.js.map +1 -1
- package/src/app/components/git-clone-dialog/git-clone-dialog.component.js +210 -0
- package/src/app/components/git-clone-dialog/git-clone-dialog.component.js.map +1 -0
- package/src/app/components/git-command-log/git-command-log.component.js +2 -2
- package/src/app/components/git-commit-card/git-commit-card.component.js +5 -15
- package/src/app/components/git-commit-card/git-commit-card.component.js.map +1 -1
- package/src/app/components/git-conflicts/git-conflicts.component.js +2 -2
- package/src/app/components/git-conflicts/git-conflicts.component.js.map +1 -1
- package/src/app/components/git-diff-files/git-diff-files.component.js +3 -3
- package/src/app/components/git-diff-files/git-diff-files.component.js.map +1 -1
- package/src/app/components/git-file-group/git-file-group.component.js +4 -3
- package/src/app/components/git-file-group/git-file-group.component.js.map +1 -1
- package/src/app/components/git-history/git-history.component.js +49 -9
- package/src/app/components/git-history/git-history.component.js.map +1 -1
- package/src/app/components/git-pull-request-files/git-pull-request-files.component.js +4 -3
- package/src/app/components/git-pull-request-files/git-pull-request-files.component.js.map +1 -1
- package/src/app/components/git-pull-request-threads/git-pull-request-threads.component.js +4 -3
- package/src/app/components/git-pull-request-threads/git-pull-request-threads.component.js.map +1 -1
- package/src/app/components/git-pull-requests/git-pull-requests.component.js +4 -6
- package/src/app/components/git-pull-requests/git-pull-requests.component.js.map +1 -1
- package/src/app/components/git-repository/git-repository.component.js +6 -4
- package/src/app/components/git-repository/git-repository.component.js.map +1 -1
- package/src/app/components/git-undo-menu/git-undo-menu.component.js +20 -4
- package/src/app/components/git-undo-menu/git-undo-menu.component.js.map +1 -1
- package/src/app/components/git-view/git-view.component.js +18 -3
- package/src/app/components/git-view/git-view.component.js.map +1 -1
- package/src/app/components/git-workspace/git-workspace.component.js +52 -4
- package/src/app/components/git-workspace/git-workspace.component.js.map +1 -1
- package/src/app/components/git-workspaces/git-workspaces.component.js +3 -3
- package/src/app/components/git-workspaces/git-workspaces.component.js.map +1 -1
- package/src/app/enums/git-add-kind.js +14 -0
- package/src/app/enums/git-add-kind.js.map +1 -0
- package/src/app/enums/git-host-feature.js +1 -0
- package/src/app/enums/git-host-feature.js.map +1 -1
- package/src/app/models/git-clone-source.js +29 -0
- package/src/app/models/git-clone-source.js.map +1 -0
- package/src/app/models/git-folder-look.js +6 -0
- package/src/app/models/git-folder-look.js.map +1 -1
- package/src/app/services/git-add-requests.js +20 -0
- package/src/app/services/git-add-requests.js.map +1 -0
- package/src/app/services/git-clone-folders.js +37 -0
- package/src/app/services/git-clone-folders.js.map +1 -0
- package/src/app/services/git-clone-sources.js +20 -0
- package/src/app/services/git-clone-sources.js.map +1 -0
- package/src/app/services/git-folder-keys.js +27 -0
- package/src/app/services/git-folder-keys.js.map +1 -0
- package/src/app/services/git-folder-looks.js +30 -1
- package/src/app/services/git-folder-looks.js.map +1 -1
- package/src/app/services/git-folder-watch.js +50 -0
- package/src/app/services/git-folder-watch.js.map +1 -0
- package/src/app/services/git-history-asks.js +2 -1
- package/src/app/services/git-history-asks.js.map +1 -1
- package/src/app/services/git-repository-scans.js +8 -3
- package/src/app/services/git-repository-scans.js.map +1 -1
- package/src/app/services/git-runtime-client.js +25 -1
- package/src/app/services/git-runtime-client.js.map +1 -1
- package/src/app/services/git-view-commands.js +46 -0
- package/src/app/services/git-view-commands.js.map +1 -0
- package/src/app/services/git-view-state.service.js +54 -2
- package/src/app/services/git-view-state.service.js.map +1 -1
- package/src/app/services/git-viewing.js +2 -1
- package/src/app/services/git-viewing.js.map +1 -1
- package/src/app/services/git-window-part.js +16 -2
- package/src/app/services/git-window-part.js.map +1 -1
- package/src/app/services/git-workspace-pages.js +14 -2
- package/src/app/services/git-workspace-pages.js.map +1 -1
- package/src/resources.js +91 -4
- package/src/resources.js.map +1 -1
|
@@ -0,0 +1,210 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license
|
|
3
|
+
* Copyright (c) Noldova.
|
|
4
|
+
*
|
|
5
|
+
* This source code is licensed under the license found in the
|
|
6
|
+
* LICENSE file in the root directory of this source tree.
|
|
7
|
+
*/
|
|
8
|
+
import { afterNextRender, Component, computed, ElementRef, inject, Injector, linkedSignal, output, signal } from "@angular/core";
|
|
9
|
+
import { FormsModule } from "@angular/forms";
|
|
10
|
+
import "@noldova/context.core";
|
|
11
|
+
import { FailureCode as DesktopCode } from "@noldova/desktop.protocol";
|
|
12
|
+
import { RuntimeRequestException, TimeFormatService, WindowPartTokens } from "@noldova/desktop.window";
|
|
13
|
+
import { HostRepositoryList } from "@noldova/git.hosting.protocol";
|
|
14
|
+
import { ButtonComponent, ButtonVariant, ChoicePillsComponent, DialogComponent, DialogSize, ProgressComponent, SelectOption, TextFieldComponent } from "@noldova/ui.components.angular";
|
|
15
|
+
import { Resources } from "../../../resources.js";
|
|
16
|
+
import { GitHostFailure } from "../../models/git-host-failure.js";
|
|
17
|
+
import { GitCloneFolders } from "../../services/git-clone-folders.js";
|
|
18
|
+
import { GitCloneSources } from "../../services/git-clone-sources.js";
|
|
19
|
+
import { GitHostAccounts } from "../../services/git-host-accounts.js";
|
|
20
|
+
import { GitRuntimeClient } from "../../services/git-runtime-client.js";
|
|
21
|
+
import { GitViewStateService } from "../../services/git-view-state.service.js";
|
|
22
|
+
import * as i0 from "@angular/core";
|
|
23
|
+
import * as i1 from "@angular/forms";
|
|
24
|
+
export class GitCloneDialogComponent {
|
|
25
|
+
static lists = 0;
|
|
26
|
+
answered = output();
|
|
27
|
+
context = inject(WindowPartTokens.context);
|
|
28
|
+
dates = inject(TimeFormatService);
|
|
29
|
+
host = inject(ElementRef).nativeElement;
|
|
30
|
+
injector = inject(Injector);
|
|
31
|
+
client = new GitRuntimeClient(this.context);
|
|
32
|
+
lists = signal(new Map(), /* @ts-ignore */
|
|
33
|
+
...(ngDevMode ? [{ debugName: "lists" }] : /* istanbul ignore next */ []));
|
|
34
|
+
list = computed(() => this.lists().get(this.chosen()) ?? null, /* @ts-ignore */
|
|
35
|
+
...(ngDevMode ? [{ debugName: "list" }] : /* istanbul ignore next */ []));
|
|
36
|
+
isClosed = false;
|
|
37
|
+
resources = Resources;
|
|
38
|
+
listId = Resources.formatCloneListId(++GitCloneDialogComponent.lists);
|
|
39
|
+
secondary = ButtonVariant.Secondary;
|
|
40
|
+
size = DialogSize.Medium;
|
|
41
|
+
cloning = signal(null, /* @ts-ignore */
|
|
42
|
+
...(ngDevMode ? [{ debugName: "cloning" }] : /* istanbul ignore next */ []));
|
|
43
|
+
sources = computed(() => GitCloneSources.of(GitHostAccounts.accounts()), /* @ts-ignore */
|
|
44
|
+
...(ngDevMode ? [{ debugName: "sources" }] : /* istanbul ignore next */ []));
|
|
45
|
+
options = computed(() => {
|
|
46
|
+
const isCloning = !Object.isNull(this.cloning());
|
|
47
|
+
return [new SelectOption(Resources.cloneUrlSource, Resources.cloneUrlTitle, null, isCloning), ...this.sources().map(t => new SelectOption(t.key, t.label, null, isCloning))];
|
|
48
|
+
}, /* @ts-ignore */
|
|
49
|
+
...(ngDevMode ? [{ debugName: "options" }] : /* istanbul ignore next */ []));
|
|
50
|
+
chosen = signal(Resources.cloneUrlSource, /* @ts-ignore */
|
|
51
|
+
...(ngDevMode ? [{ debugName: "chosen" }] : /* istanbul ignore next */ []));
|
|
52
|
+
source = computed(() => this.sources().find(t => t.key === this.chosen()) ?? null, /* @ts-ignore */
|
|
53
|
+
...(ngDevMode ? [{ debugName: "source" }] : /* istanbul ignore next */ []));
|
|
54
|
+
typed = signal("", /* @ts-ignore */
|
|
55
|
+
...(ngDevMode ? [{ debugName: "typed" }] : /* istanbul ignore next */ []));
|
|
56
|
+
filter = signal("", /* @ts-ignore */
|
|
57
|
+
...(ngDevMode ? [{ debugName: "filter" }] : /* istanbul ignore next */ []));
|
|
58
|
+
picked = signal(null, /* @ts-ignore */
|
|
59
|
+
...(ngDevMode ? [{ debugName: "picked" }] : /* istanbul ignore next */ []));
|
|
60
|
+
rows = computed(() => {
|
|
61
|
+
const list = this.list();
|
|
62
|
+
const text = this.filter().trim().toLowerCase();
|
|
63
|
+
return list instanceof HostRepositoryList ? list.rows.filter(t => t.name.toLowerCase().includes(text)) : [];
|
|
64
|
+
}, /* @ts-ignore */
|
|
65
|
+
...(ngDevMode ? [{ debugName: "rows" }] : /* istanbul ignore next */ []));
|
|
66
|
+
activeId = computed(() => {
|
|
67
|
+
const index = this.rows().findIndex(t => t === this.picked());
|
|
68
|
+
return index < 0 ? null : Resources.formatCloneOptionId(this.listId, index);
|
|
69
|
+
}, /* @ts-ignore */
|
|
70
|
+
...(ngDevMode ? [{ debugName: "activeId" }] : /* istanbul ignore next */ []));
|
|
71
|
+
status = computed(() => {
|
|
72
|
+
const list = this.list();
|
|
73
|
+
if (Object.isNull(list))
|
|
74
|
+
return Resources.cloneListReading;
|
|
75
|
+
if (Object.isString(list))
|
|
76
|
+
return list;
|
|
77
|
+
if (!list.isSignedIn)
|
|
78
|
+
return Resources.cloneListSignedOut;
|
|
79
|
+
if (list.rows.length === 0)
|
|
80
|
+
return Resources.cloneListEmpty;
|
|
81
|
+
if (this.rows().length === 0)
|
|
82
|
+
return list.hasMore ? Resources.formatCloneListNoMatchesMore(list.rows.length) : Resources.cloneListNoMatches;
|
|
83
|
+
return list.hasMore ? Resources.formatCloneListMore(list.rows.length) : null;
|
|
84
|
+
}, /* @ts-ignore */
|
|
85
|
+
...(ngDevMode ? [{ debugName: "status" }] : /* istanbul ignore next */ []));
|
|
86
|
+
url = computed(() => Object.isNull(this.source()) ? this.typed().trim() : this.picked()?.url ?? "", /* @ts-ignore */
|
|
87
|
+
...(ngDevMode ? [{ debugName: "url" }] : /* istanbul ignore next */ []));
|
|
88
|
+
name = linkedSignal(() => GitCloneFolders.nameOf(this.url()), /* @ts-ignore */
|
|
89
|
+
...(ngDevMode ? [{ debugName: "name" }] : /* istanbul ignore next */ []));
|
|
90
|
+
parent = GitCloneFolders.parent;
|
|
91
|
+
isName = computed(() => GitCloneFolders.isName(this.name()), /* @ts-ignore */
|
|
92
|
+
...(ngDevMode ? [{ debugName: "isName" }] : /* istanbul ignore next */ []));
|
|
93
|
+
folder = computed(() => {
|
|
94
|
+
const parent = this.parent();
|
|
95
|
+
return Object.isNull(parent) || this.name().length === 0 || !this.isName() ? null : GitCloneFolders.join(parent, this.name());
|
|
96
|
+
}, /* @ts-ignore */
|
|
97
|
+
...(ngDevMode ? [{ debugName: "folder" }] : /* istanbul ignore next */ []));
|
|
98
|
+
progress = signal(null, /* @ts-ignore */
|
|
99
|
+
...(ngDevMode ? [{ debugName: "progress" }] : /* istanbul ignore next */ []));
|
|
100
|
+
progressText = computed(() => {
|
|
101
|
+
const progress = this.progress();
|
|
102
|
+
return Object.isNull(progress) ? Resources.cloneStarting : Resources.formatClonePhase(progress.phase, progress.percent);
|
|
103
|
+
}, /* @ts-ignore */
|
|
104
|
+
...(ngDevMode ? [{ debugName: "progressText" }] : /* istanbul ignore next */ []));
|
|
105
|
+
failure = signal(null, /* @ts-ignore */
|
|
106
|
+
...(ngDevMode ? [{ debugName: "failure" }] : /* istanbul ignore next */ []));
|
|
107
|
+
canClone = computed(() => this.url().length > 0 && !Object.isNull(this.folder()) && Object.isNull(this.cloning()), /* @ts-ignore */
|
|
108
|
+
...(ngDevMode ? [{ debugName: "canClone" }] : /* istanbul ignore next */ []));
|
|
109
|
+
choose(key) {
|
|
110
|
+
this.chosen.set(key);
|
|
111
|
+
this.picked.set(null);
|
|
112
|
+
this.failure.set(null);
|
|
113
|
+
const source = this.source();
|
|
114
|
+
if (!Object.isNull(source) && !this.lists().has(source.key))
|
|
115
|
+
void this.readAsync(source);
|
|
116
|
+
}
|
|
117
|
+
pick(repository) {
|
|
118
|
+
if (!Object.isNull(this.cloning()))
|
|
119
|
+
return;
|
|
120
|
+
this.picked.set(repository);
|
|
121
|
+
this.failure.set(null);
|
|
122
|
+
}
|
|
123
|
+
onKey(event) {
|
|
124
|
+
if (event.key === "Enter") {
|
|
125
|
+
event.preventDefault();
|
|
126
|
+
void this.cloneAsync();
|
|
127
|
+
return;
|
|
128
|
+
}
|
|
129
|
+
if (event.key !== "ArrowDown" && event.key !== "ArrowUp")
|
|
130
|
+
return;
|
|
131
|
+
event.preventDefault();
|
|
132
|
+
const rows = this.rows();
|
|
133
|
+
const index = rows.findIndex(t => t === this.picked());
|
|
134
|
+
const next = event.key === "ArrowUp" && index < 0 ? rows.at(-1) : rows[(index + (event.key === "ArrowDown" ? 1 : rows.length - 1)) % rows.length];
|
|
135
|
+
if (Object.isUndefined(next))
|
|
136
|
+
return;
|
|
137
|
+
this.pick(next);
|
|
138
|
+
const id = Resources.formatCloneOptionId(this.listId, rows.indexOf(next));
|
|
139
|
+
afterNextRender(() => this.host.querySelector(`#${id}`)?.scrollIntoView({ block: "nearest" }), { injector: this.injector });
|
|
140
|
+
}
|
|
141
|
+
async chooseParentAsync() {
|
|
142
|
+
const parent = await this.context.chooseFolderAsync();
|
|
143
|
+
if (!Object.isNull(parent))
|
|
144
|
+
GitCloneFolders.remember(parent);
|
|
145
|
+
}
|
|
146
|
+
async cloneAsync() {
|
|
147
|
+
const folder = this.folder();
|
|
148
|
+
if (!this.canClone() || Object.isNull(folder))
|
|
149
|
+
return;
|
|
150
|
+
const id = crypto.randomUUID();
|
|
151
|
+
this.cloning.set(id);
|
|
152
|
+
this.progress.set(null);
|
|
153
|
+
this.failure.set(null);
|
|
154
|
+
const stop = this.client.onCloneProgress(t => {
|
|
155
|
+
if (t.progress === id)
|
|
156
|
+
this.progress.set(t);
|
|
157
|
+
});
|
|
158
|
+
try {
|
|
159
|
+
await this.client.cloneAsync(this.url(), folder, id);
|
|
160
|
+
if (!this.isClosed)
|
|
161
|
+
this.answered.emit(folder);
|
|
162
|
+
}
|
|
163
|
+
catch (error) {
|
|
164
|
+
if (!GitCloneDialogComponent.isCancelled(error))
|
|
165
|
+
this.failure.set(GitViewStateService.messageOf(error));
|
|
166
|
+
}
|
|
167
|
+
finally {
|
|
168
|
+
stop();
|
|
169
|
+
this.cloning.set(null);
|
|
170
|
+
}
|
|
171
|
+
}
|
|
172
|
+
cancel() {
|
|
173
|
+
const id = this.cloning();
|
|
174
|
+
if (Object.isNull(id)) {
|
|
175
|
+
this.close();
|
|
176
|
+
return;
|
|
177
|
+
}
|
|
178
|
+
this.client.cancelCloneAsync(id).catch((error) => this.context.log(Resources.formatCloneCancelFailed(GitViewStateService.messageOf(error))));
|
|
179
|
+
}
|
|
180
|
+
dismiss() {
|
|
181
|
+
const id = this.cloning();
|
|
182
|
+
if (!Object.isNull(id))
|
|
183
|
+
this.client.cancelCloneAsync(id).catch((error) => this.context.log(Resources.formatCloneCancelFailed(GitViewStateService.messageOf(error))));
|
|
184
|
+
this.close();
|
|
185
|
+
}
|
|
186
|
+
close() {
|
|
187
|
+
this.isClosed = true;
|
|
188
|
+
this.answered.emit(null);
|
|
189
|
+
}
|
|
190
|
+
async readAsync(source) {
|
|
191
|
+
let answer;
|
|
192
|
+
try {
|
|
193
|
+
answer = await source.readAsync();
|
|
194
|
+
}
|
|
195
|
+
catch (error) {
|
|
196
|
+
answer = GitHostFailure.of(error, Resources.cloneListFailed).textOf(source.host, this.dates);
|
|
197
|
+
}
|
|
198
|
+
this.lists.update(t => new Map([...t, [source.key, answer]]));
|
|
199
|
+
}
|
|
200
|
+
static isCancelled(error) {
|
|
201
|
+
return error instanceof RuntimeRequestException && error.code === DesktopCode.Cancelled;
|
|
202
|
+
}
|
|
203
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.3.0", ngImport: i0, type: GitCloneDialogComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
204
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.3.0", type: GitCloneDialogComponent, isStandalone: true, selector: "nol-git-clone-dialog", outputs: { answered: "answered" }, ngImport: i0, template: "<!--\n@license\nCopyright (c) Noldova.\n\nThis source code is licensed under the license found in the\nLICENSE file in the root directory of this source tree.\n-->\n\n<nol-dialog [title]=\"resources.cloneTitle\" [size]=\"size\" (dismissed)=\"dismiss()\">\n @if (options().length > 1) {\n <nol-choice-pills class=\"sources\" [options]=\"options()\" [value]=\"source()?.key ?? resources.cloneUrlSource\" [label]=\"resources.cloneSourceLabel\"\n (valueChange)=\"choose($event)\" />\n }\n @if (source(); as current) {\n <input nol-text-field class=\"filter\" type=\"search\" role=\"combobox\" aria-autocomplete=\"list\" aria-expanded=\"true\" [attr.aria-controls]=\"listId\"\n [attr.aria-activedescendant]=\"activeId()\" [attr.aria-label]=\"resources.filterRepositoriesLabel\" [placeholder]=\"resources.filterRepositoriesLabel\"\n [disabled]=\"cloning() !== null\" [ngModel]=\"filter()\" (ngModelChange)=\"filter.set($event)\" (keydown)=\"onKey($event)\" />\n <div class=\"repositories\" role=\"listbox\" tabindex=\"-1\" [id]=\"listId\" [attr.aria-label]=\"current.label\">\n @for (repository of rows(); track repository.url; let index = $index) {\n <div role=\"option\" class=\"repository\" [id]=\"resources.formatCloneOptionId(listId, index)\" [class.picked]=\"picked() === repository\"\n [attr.aria-selected]=\"picked() === repository\" [attr.aria-disabled]=\"cloning() !== null\" [title]=\"repository.url\" (pointerdown)=\"$event.preventDefault()\"\n (click)=\"pick(repository)\">\n <span class=\"name\">{{ repository.name }}</span>\n @if (repository.isPrivate) {\n <span class=\"small muted private\">{{ resources.privateLabel }}</span>\n }\n </div>\n }\n </div>\n @if (status(); as text) {\n <p class=\"small muted status\">{{ text }}</p>\n }\n } @else {\n <input nol-text-field class=\"url\" type=\"text\" name=\"url\" [attr.aria-label]=\"resources.cloneUrlLabel\" [placeholder]=\"resources.cloneUrlLabel\"\n [disabled]=\"cloning() !== null\" [ngModel]=\"typed()\" (ngModelChange)=\"typed.set($event); failure.set(null)\" (keydown.enter)=\"cloneAsync()\" />\n <p class=\"small muted hint\">{{ resources.cloneUrlHint }}</p>\n }\n <div class=\"destination\">\n <span class=\"small label\">{{ resources.cloneParentLabel }}</span>\n <span class=\"parent\" [class.muted]=\"parent() === null\" [title]=\"parent() ?? ''\">{{ parent() ?? resources.cloneParentNone }}</span>\n <button nol-button type=\"button\" class=\"choose\" [variant]=\"secondary\" [disabled]=\"cloning() !== null\" (click)=\"chooseParentAsync()\">{{ resources.chooseLabel }}</button>\n <label class=\"small label\" for=\"git-clone-name\">{{ resources.cloneNameLabel }}</label>\n <input nol-text-field id=\"git-clone-name\" class=\"name-field\" type=\"text\" name=\"name\" [attr.aria-invalid]=\"!isName()\" [disabled]=\"cloning() !== null\"\n [ngModel]=\"name()\" (ngModelChange)=\"name.set($event)\" (keydown.enter)=\"cloneAsync()\" />\n </div>\n @if (!isName()) {\n <p class=\"small refused\" role=\"alert\">{{ resources.cloneNameRefused }}</p>\n }\n @if (cloning() !== null) {\n <nol-progress class=\"progress\" [label]=\"progressText()\" [value]=\"progress() === null ? null : (progress()?.percent ?? 0) / 100\" />\n <p class=\"small muted progress-text\" aria-live=\"polite\">{{ progressText() }}</p>\n }\n @if (failure(); as text) {\n <p class=\"small refused failure\" role=\"alert\">{{ text }}</p>\n }\n <button nol-button nolDialogAction type=\"button\" class=\"clone\" [disabled]=\"!canClone()\" (click)=\"cloneAsync()\">{{ resources.cloneLabel }}</button>\n <button nol-button nolDialogAction type=\"button\" class=\"cancel\" [variant]=\"secondary\" (click)=\"cancel()\">{{ resources.cancelLabel }}</button>\n</nol-dialog>\n", styles: ["/**\n * @license\n * Copyright (c) Noldova.\n *\n * This source code is licensed under the license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n.sources {\n margin-bottom: 0.75rem;\n}\n\n.filter,\n.url {\n width: 100%;\n}\n\n.repositories {\n --rows: 8;\n display: grid;\n align-content: start;\n height: clamp(calc(3 * 1.75rem), calc(100dvh - 23.5rem), calc(var(--rows) * 1.75rem));\n margin-top: 0.5rem;\n overflow-y: auto;\n border: var(--nol-border-width) solid var(--nol-widget-border);\n border-radius: var(--nol-radius-medium);\n}\n\n.repository {\n display: flex;\n gap: 0.5rem;\n align-items: center;\n min-width: 0;\n height: 1.75rem;\n padding: 0 0.5rem;\n cursor: pointer;\n}\n\n.repository:hover:not([aria-disabled=\"true\"]) {\n background: var(--nol-hover);\n}\n\n.repository.picked {\n background: var(--nol-selected);\n}\n\n.name {\n overflow: hidden;\n white-space: nowrap;\n text-overflow: ellipsis;\n}\n\n.private {\n flex: none;\n margin-inline-start: auto;\n}\n\n.status,\n.hint {\n margin: 0.25rem 0 0;\n}\n\n.destination {\n display: grid;\n grid-template-columns: auto minmax(0, 1fr) auto;\n gap: 0.5rem;\n align-items: center;\n margin-top: 0.75rem;\n}\n\n.parent {\n overflow: hidden;\n white-space: nowrap;\n text-overflow: ellipsis;\n}\n\n.name-field {\n grid-column: 2 / -1;\n width: 100%;\n}\n\n.refused {\n margin: 0.25rem 0 0;\n color: var(--nol-error);\n}\n\n.progress {\n margin-top: 0.75rem;\n}\n\n.progress-text {\n margin: 0.25rem 0 0;\n}\n"], dependencies: [{ kind: "component", type: ButtonComponent, selector: "button[nol-button], a[nol-button]", inputs: ["variant", "overlay", "backdrop", "danger", "size", "busy"] }, { kind: "component", type: ChoicePillsComponent, selector: "nol-choice-pills", inputs: ["options", "value", "label", "describedBy", "iconOnly"], outputs: ["valueChange"] }, { kind: "component", type: DialogComponent, selector: "nol-dialog", inputs: ["title", "size"], outputs: ["dismissed"] }, { kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i1.DefaultValueAccessor, selector: "input:not([type=checkbox]):not([ngNoCva])[formControlName],textarea:not([ngNoCva])[formControlName],input:not([type=checkbox]):not([ngNoCva])[formControl],textarea:not([ngNoCva])[formControl],input:not([type=checkbox]):not([ngNoCva])[ngModel],textarea:not([ngNoCva])[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "component", type: ProgressComponent, selector: "nol-progress", inputs: ["label", "value"] }, { kind: "component", type: TextFieldComponent, selector: "input[nol-text-field], textarea[nol-text-field]", inputs: ["quiet"] }] });
|
|
205
|
+
}
|
|
206
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.3.0", ngImport: i0, type: GitCloneDialogComponent, decorators: [{
|
|
207
|
+
type: Component,
|
|
208
|
+
args: [{ selector: "nol-git-clone-dialog", imports: [ButtonComponent, ChoicePillsComponent, DialogComponent, FormsModule, ProgressComponent, TextFieldComponent], template: "<!--\n@license\nCopyright (c) Noldova.\n\nThis source code is licensed under the license found in the\nLICENSE file in the root directory of this source tree.\n-->\n\n<nol-dialog [title]=\"resources.cloneTitle\" [size]=\"size\" (dismissed)=\"dismiss()\">\n @if (options().length > 1) {\n <nol-choice-pills class=\"sources\" [options]=\"options()\" [value]=\"source()?.key ?? resources.cloneUrlSource\" [label]=\"resources.cloneSourceLabel\"\n (valueChange)=\"choose($event)\" />\n }\n @if (source(); as current) {\n <input nol-text-field class=\"filter\" type=\"search\" role=\"combobox\" aria-autocomplete=\"list\" aria-expanded=\"true\" [attr.aria-controls]=\"listId\"\n [attr.aria-activedescendant]=\"activeId()\" [attr.aria-label]=\"resources.filterRepositoriesLabel\" [placeholder]=\"resources.filterRepositoriesLabel\"\n [disabled]=\"cloning() !== null\" [ngModel]=\"filter()\" (ngModelChange)=\"filter.set($event)\" (keydown)=\"onKey($event)\" />\n <div class=\"repositories\" role=\"listbox\" tabindex=\"-1\" [id]=\"listId\" [attr.aria-label]=\"current.label\">\n @for (repository of rows(); track repository.url; let index = $index) {\n <div role=\"option\" class=\"repository\" [id]=\"resources.formatCloneOptionId(listId, index)\" [class.picked]=\"picked() === repository\"\n [attr.aria-selected]=\"picked() === repository\" [attr.aria-disabled]=\"cloning() !== null\" [title]=\"repository.url\" (pointerdown)=\"$event.preventDefault()\"\n (click)=\"pick(repository)\">\n <span class=\"name\">{{ repository.name }}</span>\n @if (repository.isPrivate) {\n <span class=\"small muted private\">{{ resources.privateLabel }}</span>\n }\n </div>\n }\n </div>\n @if (status(); as text) {\n <p class=\"small muted status\">{{ text }}</p>\n }\n } @else {\n <input nol-text-field class=\"url\" type=\"text\" name=\"url\" [attr.aria-label]=\"resources.cloneUrlLabel\" [placeholder]=\"resources.cloneUrlLabel\"\n [disabled]=\"cloning() !== null\" [ngModel]=\"typed()\" (ngModelChange)=\"typed.set($event); failure.set(null)\" (keydown.enter)=\"cloneAsync()\" />\n <p class=\"small muted hint\">{{ resources.cloneUrlHint }}</p>\n }\n <div class=\"destination\">\n <span class=\"small label\">{{ resources.cloneParentLabel }}</span>\n <span class=\"parent\" [class.muted]=\"parent() === null\" [title]=\"parent() ?? ''\">{{ parent() ?? resources.cloneParentNone }}</span>\n <button nol-button type=\"button\" class=\"choose\" [variant]=\"secondary\" [disabled]=\"cloning() !== null\" (click)=\"chooseParentAsync()\">{{ resources.chooseLabel }}</button>\n <label class=\"small label\" for=\"git-clone-name\">{{ resources.cloneNameLabel }}</label>\n <input nol-text-field id=\"git-clone-name\" class=\"name-field\" type=\"text\" name=\"name\" [attr.aria-invalid]=\"!isName()\" [disabled]=\"cloning() !== null\"\n [ngModel]=\"name()\" (ngModelChange)=\"name.set($event)\" (keydown.enter)=\"cloneAsync()\" />\n </div>\n @if (!isName()) {\n <p class=\"small refused\" role=\"alert\">{{ resources.cloneNameRefused }}</p>\n }\n @if (cloning() !== null) {\n <nol-progress class=\"progress\" [label]=\"progressText()\" [value]=\"progress() === null ? null : (progress()?.percent ?? 0) / 100\" />\n <p class=\"small muted progress-text\" aria-live=\"polite\">{{ progressText() }}</p>\n }\n @if (failure(); as text) {\n <p class=\"small refused failure\" role=\"alert\">{{ text }}</p>\n }\n <button nol-button nolDialogAction type=\"button\" class=\"clone\" [disabled]=\"!canClone()\" (click)=\"cloneAsync()\">{{ resources.cloneLabel }}</button>\n <button nol-button nolDialogAction type=\"button\" class=\"cancel\" [variant]=\"secondary\" (click)=\"cancel()\">{{ resources.cancelLabel }}</button>\n</nol-dialog>\n", styles: ["/**\n * @license\n * Copyright (c) Noldova.\n *\n * This source code is licensed under the license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n.sources {\n margin-bottom: 0.75rem;\n}\n\n.filter,\n.url {\n width: 100%;\n}\n\n.repositories {\n --rows: 8;\n display: grid;\n align-content: start;\n height: clamp(calc(3 * 1.75rem), calc(100dvh - 23.5rem), calc(var(--rows) * 1.75rem));\n margin-top: 0.5rem;\n overflow-y: auto;\n border: var(--nol-border-width) solid var(--nol-widget-border);\n border-radius: var(--nol-radius-medium);\n}\n\n.repository {\n display: flex;\n gap: 0.5rem;\n align-items: center;\n min-width: 0;\n height: 1.75rem;\n padding: 0 0.5rem;\n cursor: pointer;\n}\n\n.repository:hover:not([aria-disabled=\"true\"]) {\n background: var(--nol-hover);\n}\n\n.repository.picked {\n background: var(--nol-selected);\n}\n\n.name {\n overflow: hidden;\n white-space: nowrap;\n text-overflow: ellipsis;\n}\n\n.private {\n flex: none;\n margin-inline-start: auto;\n}\n\n.status,\n.hint {\n margin: 0.25rem 0 0;\n}\n\n.destination {\n display: grid;\n grid-template-columns: auto minmax(0, 1fr) auto;\n gap: 0.5rem;\n align-items: center;\n margin-top: 0.75rem;\n}\n\n.parent {\n overflow: hidden;\n white-space: nowrap;\n text-overflow: ellipsis;\n}\n\n.name-field {\n grid-column: 2 / -1;\n width: 100%;\n}\n\n.refused {\n margin: 0.25rem 0 0;\n color: var(--nol-error);\n}\n\n.progress {\n margin-top: 0.75rem;\n}\n\n.progress-text {\n margin: 0.25rem 0 0;\n}\n"] }]
|
|
209
|
+
}], propDecorators: { answered: [{ type: i0.Output, args: ["answered"] }] } });
|
|
210
|
+
//# sourceMappingURL=git-clone-dialog.component.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"git-clone-dialog.component.js","sourceRoot":"","sources":["../../../../../../../../src/noldova.git.window/src/app/components/git-clone-dialog/git-clone-dialog.component.ts","../../../../../../../../src/noldova.git.window/src/app/components/git-clone-dialog/git-clone-dialog.component.html"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH,OAAO,EACL,eAAe,EAAE,SAAS,EAAE,QAAQ,EAAE,UAAU,EAAE,MAAM,EAAE,QAAQ,EAAE,YAAY,EAAE,MAAM,EAAyB,MAAM,EACxH,MAAM,eAAe,CAAC;AACvB,OAAO,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAC;AAC7C,OAAO,uBAAuB,CAAC;AAC/B,OAAO,EAAE,WAAW,IAAI,WAAW,EAAE,MAAM,2BAA2B,CAAC;AACvE,OAAO,EAA2B,uBAAuB,EAAE,iBAAiB,EAAE,gBAAgB,EAAE,MAAM,yBAAyB,CAAC;AAChI,OAAO,EAAuB,kBAAkB,EAAE,MAAM,+BAA+B,CAAC;AAExF,OAAO,EAAE,eAAe,EAAE,aAAa,EAAE,oBAAoB,EAAE,eAAe,EAAE,UAAU,EAAE,iBAAiB,EAAE,YAAY,EACzH,kBAAkB,EAAE,MAAM,gCAAgC,CAAC;AAE7D,OAAO,EAAE,SAAS,EAAE,MAAM,uBAAuB,CAAC;AAClD,OAAO,EAAE,cAAc,EAAE,MAAM,kCAAkC,CAAC;AAElE,OAAO,EAAE,eAAe,EAAE,MAAM,qCAAqC,CAAC;AACtE,OAAO,EAAE,eAAe,EAAE,MAAM,qCAAqC,CAAC;AACtE,OAAO,EAAE,eAAe,EAAE,MAAM,qCAAqC,CAAC;AACtE,OAAO,EAAE,gBAAgB,EAAE,MAAM,sCAAsC,CAAC;AACxE,OAAO,EAAE,mB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AC,EAAE,CAAC,MAAM,CAAC,GAAG,EAAE,MAAM,CAAC,CAAC,CAAC,CAAC,CAAC;IAChE,CAAC;IAEO,MAAM,CAAC,WAAW,CAAC,KAAc;QACvC,OAAO,KAAK,YAAY,uBAAuB,IAAI,KAAK,CAAC,IAAI,KAAK,WAAW,CAAC,SAAS,CAAC;IAC1F,CAAC;uGA1KU,uBAAuB;2FAAvB,uBAAuB,mHCnCpC,syHA0DA,2kDD3BY,eAAe,oJAAE,oBAAoB,yJAAE,eAAe,yGAAE,WAAW,ysBAAE,iBAAiB,qFAAE,kBAAkB;;2FAIzG,uBAAuB;kBANnC,SAAS;+BACE,sBAAsB,WACvB,CAAC,eAAe,EAAE,oBAAoB,EAAE,eAAe,EAAE,WAAW,EAAE,iBAAiB,EAAE,kBAAkB,CAAC"}
|
|
@@ -115,10 +115,10 @@ export class GitCommandLogComponent {
|
|
|
115
115
|
}
|
|
116
116
|
}
|
|
117
117
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.3.0", ngImport: i0, type: GitCommandLogComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
118
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.3.0", type: GitCommandLogComponent, isStandalone: true, selector: "nol-git-command-log", inputs: { instance: { classPropertyName: "instance", publicName: "instance", isSignal: true, isRequired: true, transformFunction: null } }, viewQueries: [{ propertyName: "list", first: true, predicate: ["list"], descendants: true, isSignal: true }], ngImport: i0, template: "<!--\n@license\nCopyright (c) Noldova.\n\nThis source code is licensed under the license found in the\nLICENSE file in the root directory of this source tree.\n-->\n\n<main class=\"panel\" [attr.aria-label]=\"resources.commandLogLabel\">\n @if (readFailure(); as failure) {\n <p class=\"note failure\" role=\"alert\">{{ failure }}</p>\n } @else if (log() !== null && commands().length === 0) {\n <p class=\"note muted\" role=\"note\">{{ resources.commandLogEmpty }}</p>\n } @else {\n <ol #list class=\"commands\">\n @for (command of commands(); track command.id) {\n <li class=\"command\">\n <span class=\"time muted\">{{ timeOf(command) }}</span>\n <span class=\"line mono\" [title]=\"command.line\">{{ command.line }}</span>\n <span class=\"exit\" [class]=\"'exit ' + toneOf(command)\" [title]=\"resources.formatCommandExit(command.exitCode)\">\n <span class=\"exit-icon material-symbols-rounded\" aria-hidden=\"true\">{{ iconOf(command) }}</span>\n <span class=\"exit-text\">{{ resources.formatCommandExit(command.exitCode) }}</span>\n </span>\n <span class=\"duration muted\">{{ resources.formatCommandDuration(command.milliseconds) }}</span>\n </li>\n }\n </ol>\n }\n</main>\n", styles: ["/**\n * @license\n * Copyright (c) Noldova.\n *\n * This source code is licensed under the license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n:host {\n display: flex;\n box-sizing: border-box;\n height: 100%;\n min-height: 0;\n color: var(--nol-text);\n font-family: var(--nol-font-sans);\n font-size: var(--nol-text-panel);\n line-height: var(--nol-line-panel);\n}\n\n.panel {\n display: flex;\n flex: 1 1 auto;\n flex-direction: column;\n min-width: 0;\n min-height: 0;\n overflow: hidden;\n}\n\n.exit-icon {\n flex: none;\n font-size: var(--nol-icon);\n}\n\n.note {\n margin: 0;\n}\n\n.time,\n.duration {\n font-size: 0.75rem;\n}\n\n.note {\n padding:
|
|
118
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.3.0", type: GitCommandLogComponent, isStandalone: true, selector: "nol-git-command-log", inputs: { instance: { classPropertyName: "instance", publicName: "instance", isSignal: true, isRequired: true, transformFunction: null } }, viewQueries: [{ propertyName: "list", first: true, predicate: ["list"], descendants: true, isSignal: true }], ngImport: i0, template: "<!--\n@license\nCopyright (c) Noldova.\n\nThis source code is licensed under the license found in the\nLICENSE file in the root directory of this source tree.\n-->\n\n<main class=\"panel\" [attr.aria-label]=\"resources.commandLogLabel\">\n @if (readFailure(); as failure) {\n <p class=\"note failure\" role=\"alert\">{{ failure }}</p>\n } @else if (log() !== null && commands().length === 0) {\n <p class=\"note muted\" role=\"note\">{{ resources.commandLogEmpty }}</p>\n } @else {\n <ol #list class=\"commands\">\n @for (command of commands(); track command.id) {\n <li class=\"command\">\n <span class=\"time muted\">{{ timeOf(command) }}</span>\n <span class=\"line mono\" [title]=\"command.line\">{{ command.line }}</span>\n <span class=\"exit\" [class]=\"'exit ' + toneOf(command)\" [title]=\"resources.formatCommandExit(command.exitCode)\">\n <span class=\"exit-icon material-symbols-rounded\" aria-hidden=\"true\">{{ iconOf(command) }}</span>\n <span class=\"exit-text\">{{ resources.formatCommandExit(command.exitCode) }}</span>\n </span>\n <span class=\"duration muted\">{{ resources.formatCommandDuration(command.milliseconds) }}</span>\n </li>\n }\n </ol>\n }\n</main>\n", styles: ["/**\n * @license\n * Copyright (c) Noldova.\n *\n * This source code is licensed under the license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n:host {\n display: flex;\n box-sizing: border-box;\n height: 100%;\n min-height: 0;\n padding-block: var(--nol-view-padding-block);\n color: var(--nol-text);\n font-family: var(--nol-font-sans);\n font-size: var(--nol-text-panel);\n line-height: var(--nol-line-panel);\n}\n\n.panel {\n display: flex;\n flex: 1 1 auto;\n flex-direction: column;\n min-width: 0;\n min-height: 0;\n overflow: hidden;\n}\n\n.exit-icon {\n flex: none;\n font-size: var(--nol-icon);\n}\n\n.note {\n margin: 0;\n}\n\n.time,\n.duration {\n font-size: 0.75rem;\n}\n\n.note {\n padding: var(--nol-view-padding-block) var(--nol-content-padding-inline);\n}\n\n.commands {\n flex: 1 1 auto;\n min-height: 0;\n margin: 0;\n padding: 0 var(--nol-content-padding-inline);\n overflow: auto;\n list-style: none;\n}\n\n.command {\n display: grid;\n grid-template-columns: 5.5rem minmax(0, 1fr) 8rem 4rem;\n gap: 0.75rem;\n align-items: center;\n min-height: 1.75rem;\n}\n\n.line {\n overflow: hidden;\n white-space: nowrap;\n text-overflow: ellipsis;\n user-select: text;\n}\n\n.exit {\n display: flex;\n gap: 0.25rem;\n align-items: center;\n min-width: 0;\n}\n\n.exit-text {\n overflow: hidden;\n white-space: nowrap;\n text-overflow: ellipsis;\n}\n\n.duration {\n text-align: end;\n}\n\n.mono {\n font-family: var(--nol-font-mono);\n}\n\n.failure {\n color: var(--nol-status-failed);\n}\n\n.ok {\n color: var(--nol-status-ok);\n}\n\n.muted {\n color: var(--nol-text-muted);\n}\n"] });
|
|
119
119
|
}
|
|
120
120
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.3.0", ngImport: i0, type: GitCommandLogComponent, decorators: [{
|
|
121
121
|
type: Component,
|
|
122
|
-
args: [{ selector: "nol-git-command-log", template: "<!--\n@license\nCopyright (c) Noldova.\n\nThis source code is licensed under the license found in the\nLICENSE file in the root directory of this source tree.\n-->\n\n<main class=\"panel\" [attr.aria-label]=\"resources.commandLogLabel\">\n @if (readFailure(); as failure) {\n <p class=\"note failure\" role=\"alert\">{{ failure }}</p>\n } @else if (log() !== null && commands().length === 0) {\n <p class=\"note muted\" role=\"note\">{{ resources.commandLogEmpty }}</p>\n } @else {\n <ol #list class=\"commands\">\n @for (command of commands(); track command.id) {\n <li class=\"command\">\n <span class=\"time muted\">{{ timeOf(command) }}</span>\n <span class=\"line mono\" [title]=\"command.line\">{{ command.line }}</span>\n <span class=\"exit\" [class]=\"'exit ' + toneOf(command)\" [title]=\"resources.formatCommandExit(command.exitCode)\">\n <span class=\"exit-icon material-symbols-rounded\" aria-hidden=\"true\">{{ iconOf(command) }}</span>\n <span class=\"exit-text\">{{ resources.formatCommandExit(command.exitCode) }}</span>\n </span>\n <span class=\"duration muted\">{{ resources.formatCommandDuration(command.milliseconds) }}</span>\n </li>\n }\n </ol>\n }\n</main>\n", styles: ["/**\n * @license\n * Copyright (c) Noldova.\n *\n * This source code is licensed under the license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n:host {\n display: flex;\n box-sizing: border-box;\n height: 100%;\n min-height: 0;\n color: var(--nol-text);\n font-family: var(--nol-font-sans);\n font-size: var(--nol-text-panel);\n line-height: var(--nol-line-panel);\n}\n\n.panel {\n display: flex;\n flex: 1 1 auto;\n flex-direction: column;\n min-width: 0;\n min-height: 0;\n overflow: hidden;\n}\n\n.exit-icon {\n flex: none;\n font-size: var(--nol-icon);\n}\n\n.note {\n margin: 0;\n}\n\n.time,\n.duration {\n font-size: 0.75rem;\n}\n\n.note {\n padding:
|
|
122
|
+
args: [{ selector: "nol-git-command-log", template: "<!--\n@license\nCopyright (c) Noldova.\n\nThis source code is licensed under the license found in the\nLICENSE file in the root directory of this source tree.\n-->\n\n<main class=\"panel\" [attr.aria-label]=\"resources.commandLogLabel\">\n @if (readFailure(); as failure) {\n <p class=\"note failure\" role=\"alert\">{{ failure }}</p>\n } @else if (log() !== null && commands().length === 0) {\n <p class=\"note muted\" role=\"note\">{{ resources.commandLogEmpty }}</p>\n } @else {\n <ol #list class=\"commands\">\n @for (command of commands(); track command.id) {\n <li class=\"command\">\n <span class=\"time muted\">{{ timeOf(command) }}</span>\n <span class=\"line mono\" [title]=\"command.line\">{{ command.line }}</span>\n <span class=\"exit\" [class]=\"'exit ' + toneOf(command)\" [title]=\"resources.formatCommandExit(command.exitCode)\">\n <span class=\"exit-icon material-symbols-rounded\" aria-hidden=\"true\">{{ iconOf(command) }}</span>\n <span class=\"exit-text\">{{ resources.formatCommandExit(command.exitCode) }}</span>\n </span>\n <span class=\"duration muted\">{{ resources.formatCommandDuration(command.milliseconds) }}</span>\n </li>\n }\n </ol>\n }\n</main>\n", styles: ["/**\n * @license\n * Copyright (c) Noldova.\n *\n * This source code is licensed under the license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n:host {\n display: flex;\n box-sizing: border-box;\n height: 100%;\n min-height: 0;\n padding-block: var(--nol-view-padding-block);\n color: var(--nol-text);\n font-family: var(--nol-font-sans);\n font-size: var(--nol-text-panel);\n line-height: var(--nol-line-panel);\n}\n\n.panel {\n display: flex;\n flex: 1 1 auto;\n flex-direction: column;\n min-width: 0;\n min-height: 0;\n overflow: hidden;\n}\n\n.exit-icon {\n flex: none;\n font-size: var(--nol-icon);\n}\n\n.note {\n margin: 0;\n}\n\n.time,\n.duration {\n font-size: 0.75rem;\n}\n\n.note {\n padding: var(--nol-view-padding-block) var(--nol-content-padding-inline);\n}\n\n.commands {\n flex: 1 1 auto;\n min-height: 0;\n margin: 0;\n padding: 0 var(--nol-content-padding-inline);\n overflow: auto;\n list-style: none;\n}\n\n.command {\n display: grid;\n grid-template-columns: 5.5rem minmax(0, 1fr) 8rem 4rem;\n gap: 0.75rem;\n align-items: center;\n min-height: 1.75rem;\n}\n\n.line {\n overflow: hidden;\n white-space: nowrap;\n text-overflow: ellipsis;\n user-select: text;\n}\n\n.exit {\n display: flex;\n gap: 0.25rem;\n align-items: center;\n min-width: 0;\n}\n\n.exit-text {\n overflow: hidden;\n white-space: nowrap;\n text-overflow: ellipsis;\n}\n\n.duration {\n text-align: end;\n}\n\n.mono {\n font-family: var(--nol-font-mono);\n}\n\n.failure {\n color: var(--nol-status-failed);\n}\n\n.ok {\n color: var(--nol-status-ok);\n}\n\n.muted {\n color: var(--nol-text-muted);\n}\n"] }]
|
|
123
123
|
}], ctorParameters: () => [], propDecorators: { list: [{ type: i0.ViewChild, args: ["list", { isSignal: true }] }], instance: [{ type: i0.Input, args: [{ isSignal: true, alias: "instance", required: true }] }] } });
|
|
124
124
|
//# sourceMappingURL=git-command-log.component.js.map
|
|
@@ -21,11 +21,7 @@ export class GitCommitCardComponent {
|
|
|
21
21
|
state = inject(GitViewStateService);
|
|
22
22
|
placeholder = computed(() => this.status().operation?.message ?? Resources.messagePlaceholder, /* @ts-ignore */
|
|
23
23
|
...(ngDevMode ? [{ debugName: "placeholder" }] : /* istanbul ignore next */ []));
|
|
24
|
-
canAmend =
|
|
25
|
-
const status = this.status();
|
|
26
|
-
return !Object.isNull(status.head) && Object.isNull(status.operation) && !(!Object.isNull(status.upstream) && !status.upstream.gone && status.upstream.ahead === 0);
|
|
27
|
-
}, /* @ts-ignore */
|
|
28
|
-
...(ngDevMode ? [{ debugName: "canAmend" }] : /* istanbul ignore next */ []));
|
|
24
|
+
canAmend = this.state.canAmend;
|
|
29
25
|
amendTitle = computed(() => this.canAmend() || this.state.amending() ? Resources.amendTitle : Resources.amendPushedTitle, /* @ts-ignore */
|
|
30
26
|
...(ngDevMode ? [{ debugName: "amendTitle" }] : /* istanbul ignore next */ []));
|
|
31
27
|
label = computed(() => {
|
|
@@ -42,14 +38,8 @@ export class GitCommitCardComponent {
|
|
|
42
38
|
return !Object.isNull(operation) && this.state.conflicts() > 0 ? Resources.formatConflictHint(this.state.conflicts(), operation.kind) : null;
|
|
43
39
|
}, /* @ts-ignore */
|
|
44
40
|
...(ngDevMode ? [{ debugName: "hint" }] : /* istanbul ignore next */ []));
|
|
45
|
-
message =
|
|
46
|
-
|
|
47
|
-
return typed.length > 0 ? typed : this.status().operation?.message ?? "";
|
|
48
|
-
}, /* @ts-ignore */
|
|
49
|
-
...(ngDevMode ? [{ debugName: "message" }] : /* istanbul ignore next */ []));
|
|
50
|
-
canCommit = computed(() => !this.state.busy() && this.state.conflicts() === 0 && this.message().length > 0
|
|
51
|
-
&& (this.state.amending() ? this.canAmend() : this.state.staged() > 0 || !Object.isNull(this.status().operation)), /* @ts-ignore */
|
|
52
|
-
...(ngDevMode ? [{ debugName: "canCommit" }] : /* istanbul ignore next */ []));
|
|
41
|
+
message = this.state.commitMessage;
|
|
42
|
+
canCommit = this.state.canCommit;
|
|
53
43
|
canPush = computed(() => !this.state.amending() && Object.isNull(this.status().operation) && !Object.isNull(this.status().upstream), /* @ts-ignore */
|
|
54
44
|
...(ngDevMode ? [{ debugName: "canPush" }] : /* istanbul ignore next */ []));
|
|
55
45
|
signingNote = computed(() => {
|
|
@@ -69,10 +59,10 @@ export class GitCommitCardComponent {
|
|
|
69
59
|
void this.state.commitAndPushAsync(this.message());
|
|
70
60
|
}
|
|
71
61
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.3.0", ngImport: i0, type: GitCommitCardComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
72
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.3.0", type: GitCommitCardComponent, isStandalone: true, selector: "nol-git-commit-card", inputs: { status: { classPropertyName: "status", publicName: "status", isSignal: true, isRequired: true, transformFunction: null } }, ngImport: i0, template: "<!--\n@license\nCopyright (c) Noldova.\n\nThis source code is licensed under the license found in the\nLICENSE file in the root directory of this source tree.\n-->\n\n<div class=\"heading\">\n <span class=\"heading-text\">{{ resources.messageLabel }}</span>\n @if (showsAiFeatures()) {\n <button type=\"button\" class=\"tb suggest\" disabled [title]=\"resources.notBuiltYet\">\n <span class=\"material-symbols-rounded\" aria-hidden=\"true\">{{ resources.suggestIcon }}</span>{{ resources.suggestLabel }}\n </button>\n }\n</div>\n<textarea nol-text-field class=\"field\" rows=\"3\" [attr.aria-label]=\"resources.messageLabel\" [placeholder]=\"placeholder()\" [ngModel]=\"state.message()\"\n (ngModelChange)=\"state.message.set($event)\"></textarea>\n<div class=\"amend-row\">\n <label class=\"amend\" [title]=\"amendTitle()\">\n <input #amendBox type=\"checkbox\" [disabled]=\"!canAmend() && !state.amending()\" [checked]=\"state.amending()\" (change)=\"toggleAmend(amendBox.checked)\" />\n <span class=\"amend-text\">{{ resources.amendLabel }}</span>\n </label>\n @if (signingNote(); as note) {\n <span class=\"signing\">{{ note }}</span>\n }\n</div>\n<div class=\"actions\">\n @if (canPush()) {\n <button nol-button type=\"button\" class=\"commit-push\" [variant]=\"secondary\" [disabled]=\"!canCommit()\" (click)=\"commitAndPush()\">{{ resources.commitAndPushLabel }}</button>\n }\n <button nol-button type=\"button\" class=\"commit\" [disabled]=\"!canCommit()\" (click)=\"commit()\">{{ label() }}</button>\n</div>\n@if (hint(); as hint) {\n <span class=\"hint\">{{ hint }}</span>\n}\n", styles: ["/**\n * @license\n * Copyright (c) Noldova.\n *\n * This source code is licensed under the license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n:host {\n display: grid;\n gap: 0.5rem;\n min-width: 0;\n}\n\n.heading,\n.amend-row,\n.amend,\n.actions {\n display: flex;\n gap: 0.5rem;\n align-items: center;\n min-width: 0;\n}\n\n.heading-text,\n.amend-text {\n flex: 1 1 auto;\n min-width: 0;\n}\n\n.heading-text {\n color: var(--nol-text-strong);\n font-weight: var(--nol-weight-emphasis);\n}\n\n.tb {\n display: inline-flex;\n gap: 0.25rem;\n align-items: center;\n height: 1.5rem;\n padding: 0
|
|
62
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.3.0", type: GitCommitCardComponent, isStandalone: true, selector: "nol-git-commit-card", inputs: { status: { classPropertyName: "status", publicName: "status", isSignal: true, isRequired: true, transformFunction: null } }, ngImport: i0, template: "<!--\n@license\nCopyright (c) Noldova.\n\nThis source code is licensed under the license found in the\nLICENSE file in the root directory of this source tree.\n-->\n\n<div class=\"heading\">\n <span class=\"heading-text\">{{ resources.messageLabel }}</span>\n @if (showsAiFeatures()) {\n <button type=\"button\" class=\"tb suggest\" disabled [title]=\"resources.notBuiltYet\">\n <span class=\"material-symbols-rounded\" aria-hidden=\"true\">{{ resources.suggestIcon }}</span>{{ resources.suggestLabel }}\n </button>\n }\n</div>\n<textarea nol-text-field class=\"field\" rows=\"3\" [attr.aria-label]=\"resources.messageLabel\" [placeholder]=\"placeholder()\" [ngModel]=\"state.message()\"\n (ngModelChange)=\"state.message.set($event)\"></textarea>\n<div class=\"amend-row\">\n <label class=\"amend\" [title]=\"amendTitle()\">\n <input #amendBox type=\"checkbox\" [disabled]=\"!canAmend() && !state.amending()\" [checked]=\"state.amending()\" (change)=\"toggleAmend(amendBox.checked)\" />\n <span class=\"amend-text\">{{ resources.amendLabel }}</span>\n </label>\n @if (signingNote(); as note) {\n <span class=\"signing\">{{ note }}</span>\n }\n</div>\n<div class=\"actions\">\n @if (canPush()) {\n <button nol-button type=\"button\" class=\"commit-push\" [variant]=\"secondary\" [disabled]=\"!canCommit()\" (click)=\"commitAndPush()\">{{ resources.commitAndPushLabel }}</button>\n }\n <button nol-button type=\"button\" class=\"commit\" [disabled]=\"!canCommit()\" (click)=\"commit()\">{{ label() }}</button>\n</div>\n@if (hint(); as hint) {\n <span class=\"hint\">{{ hint }}</span>\n}\n", styles: ["/**\n * @license\n * Copyright (c) Noldova.\n *\n * This source code is licensed under the license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n:host {\n display: grid;\n gap: 0.5rem;\n min-width: 0;\n}\n\n.heading,\n.amend-row,\n.amend,\n.actions {\n display: flex;\n gap: 0.5rem;\n align-items: center;\n min-width: 0;\n}\n\n.heading-text,\n.amend-text {\n flex: 1 1 auto;\n min-width: 0;\n}\n\n.heading-text {\n color: var(--nol-text-strong);\n font-weight: var(--nol-weight-emphasis);\n}\n\n.tb {\n display: inline-flex;\n gap: 0.25rem;\n align-items: center;\n height: 1.5rem;\n padding: 0 var(--nol-pill-padding);\n border: 0;\n border-radius: 0.25rem;\n background: transparent;\n color: var(--nol-text);\n font: inherit;\n font-size: 0.75rem;\n white-space: nowrap;\n}\n\n.suggest {\n margin-inline-end: calc(-1 * var(--nol-pill-padding));\n}\n\n.tb:disabled {\n opacity: 0.5;\n}\n\n.tb .material-symbols-rounded {\n font-size: 1rem;\n}\n\n.field {\n box-sizing: border-box;\n width: 100%;\n min-height: 4.5rem;\n}\n\n.amend {\n flex: 1 1 auto;\n color: var(--nol-text);\n}\n\n.amend input {\n width: 1.125rem;\n height: 1.125rem;\n margin: 0;\n}\n\n.actions {\n justify-content: flex-end;\n}\n\n.signing,\n.hint {\n color: var(--nol-text-muted);\n font-size: var(--nol-text-label);\n}\n\n.signing {\n flex: none;\n white-space: nowrap;\n}\n"], dependencies: [{ kind: "component", type: ButtonComponent, selector: "button[nol-button], a[nol-button]", inputs: ["variant", "overlay", "backdrop", "danger", "size", "busy"] }, { kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i1.DefaultValueAccessor, selector: "input:not([type=checkbox]):not([ngNoCva])[formControlName],textarea:not([ngNoCva])[formControlName],input:not([type=checkbox]):not([ngNoCva])[formControl],textarea:not([ngNoCva])[formControl],input:not([type=checkbox]):not([ngNoCva])[ngModel],textarea:not([ngNoCva])[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "component", type: TextFieldComponent, selector: "input[nol-text-field], textarea[nol-text-field]", inputs: ["quiet"] }] });
|
|
73
63
|
}
|
|
74
64
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.3.0", ngImport: i0, type: GitCommitCardComponent, decorators: [{
|
|
75
65
|
type: Component,
|
|
76
|
-
args: [{ selector: "nol-git-commit-card", imports: [ButtonComponent, FormsModule, TextFieldComponent], template: "<!--\n@license\nCopyright (c) Noldova.\n\nThis source code is licensed under the license found in the\nLICENSE file in the root directory of this source tree.\n-->\n\n<div class=\"heading\">\n <span class=\"heading-text\">{{ resources.messageLabel }}</span>\n @if (showsAiFeatures()) {\n <button type=\"button\" class=\"tb suggest\" disabled [title]=\"resources.notBuiltYet\">\n <span class=\"material-symbols-rounded\" aria-hidden=\"true\">{{ resources.suggestIcon }}</span>{{ resources.suggestLabel }}\n </button>\n }\n</div>\n<textarea nol-text-field class=\"field\" rows=\"3\" [attr.aria-label]=\"resources.messageLabel\" [placeholder]=\"placeholder()\" [ngModel]=\"state.message()\"\n (ngModelChange)=\"state.message.set($event)\"></textarea>\n<div class=\"amend-row\">\n <label class=\"amend\" [title]=\"amendTitle()\">\n <input #amendBox type=\"checkbox\" [disabled]=\"!canAmend() && !state.amending()\" [checked]=\"state.amending()\" (change)=\"toggleAmend(amendBox.checked)\" />\n <span class=\"amend-text\">{{ resources.amendLabel }}</span>\n </label>\n @if (signingNote(); as note) {\n <span class=\"signing\">{{ note }}</span>\n }\n</div>\n<div class=\"actions\">\n @if (canPush()) {\n <button nol-button type=\"button\" class=\"commit-push\" [variant]=\"secondary\" [disabled]=\"!canCommit()\" (click)=\"commitAndPush()\">{{ resources.commitAndPushLabel }}</button>\n }\n <button nol-button type=\"button\" class=\"commit\" [disabled]=\"!canCommit()\" (click)=\"commit()\">{{ label() }}</button>\n</div>\n@if (hint(); as hint) {\n <span class=\"hint\">{{ hint }}</span>\n}\n", styles: ["/**\n * @license\n * Copyright (c) Noldova.\n *\n * This source code is licensed under the license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n:host {\n display: grid;\n gap: 0.5rem;\n min-width: 0;\n}\n\n.heading,\n.amend-row,\n.amend,\n.actions {\n display: flex;\n gap: 0.5rem;\n align-items: center;\n min-width: 0;\n}\n\n.heading-text,\n.amend-text {\n flex: 1 1 auto;\n min-width: 0;\n}\n\n.heading-text {\n color: var(--nol-text-strong);\n font-weight: var(--nol-weight-emphasis);\n}\n\n.tb {\n display: inline-flex;\n gap: 0.25rem;\n align-items: center;\n height: 1.5rem;\n padding: 0
|
|
66
|
+
args: [{ selector: "nol-git-commit-card", imports: [ButtonComponent, FormsModule, TextFieldComponent], template: "<!--\n@license\nCopyright (c) Noldova.\n\nThis source code is licensed under the license found in the\nLICENSE file in the root directory of this source tree.\n-->\n\n<div class=\"heading\">\n <span class=\"heading-text\">{{ resources.messageLabel }}</span>\n @if (showsAiFeatures()) {\n <button type=\"button\" class=\"tb suggest\" disabled [title]=\"resources.notBuiltYet\">\n <span class=\"material-symbols-rounded\" aria-hidden=\"true\">{{ resources.suggestIcon }}</span>{{ resources.suggestLabel }}\n </button>\n }\n</div>\n<textarea nol-text-field class=\"field\" rows=\"3\" [attr.aria-label]=\"resources.messageLabel\" [placeholder]=\"placeholder()\" [ngModel]=\"state.message()\"\n (ngModelChange)=\"state.message.set($event)\"></textarea>\n<div class=\"amend-row\">\n <label class=\"amend\" [title]=\"amendTitle()\">\n <input #amendBox type=\"checkbox\" [disabled]=\"!canAmend() && !state.amending()\" [checked]=\"state.amending()\" (change)=\"toggleAmend(amendBox.checked)\" />\n <span class=\"amend-text\">{{ resources.amendLabel }}</span>\n </label>\n @if (signingNote(); as note) {\n <span class=\"signing\">{{ note }}</span>\n }\n</div>\n<div class=\"actions\">\n @if (canPush()) {\n <button nol-button type=\"button\" class=\"commit-push\" [variant]=\"secondary\" [disabled]=\"!canCommit()\" (click)=\"commitAndPush()\">{{ resources.commitAndPushLabel }}</button>\n }\n <button nol-button type=\"button\" class=\"commit\" [disabled]=\"!canCommit()\" (click)=\"commit()\">{{ label() }}</button>\n</div>\n@if (hint(); as hint) {\n <span class=\"hint\">{{ hint }}</span>\n}\n", styles: ["/**\n * @license\n * Copyright (c) Noldova.\n *\n * This source code is licensed under the license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n:host {\n display: grid;\n gap: 0.5rem;\n min-width: 0;\n}\n\n.heading,\n.amend-row,\n.amend,\n.actions {\n display: flex;\n gap: 0.5rem;\n align-items: center;\n min-width: 0;\n}\n\n.heading-text,\n.amend-text {\n flex: 1 1 auto;\n min-width: 0;\n}\n\n.heading-text {\n color: var(--nol-text-strong);\n font-weight: var(--nol-weight-emphasis);\n}\n\n.tb {\n display: inline-flex;\n gap: 0.25rem;\n align-items: center;\n height: 1.5rem;\n padding: 0 var(--nol-pill-padding);\n border: 0;\n border-radius: 0.25rem;\n background: transparent;\n color: var(--nol-text);\n font: inherit;\n font-size: 0.75rem;\n white-space: nowrap;\n}\n\n.suggest {\n margin-inline-end: calc(-1 * var(--nol-pill-padding));\n}\n\n.tb:disabled {\n opacity: 0.5;\n}\n\n.tb .material-symbols-rounded {\n font-size: 1rem;\n}\n\n.field {\n box-sizing: border-box;\n width: 100%;\n min-height: 4.5rem;\n}\n\n.amend {\n flex: 1 1 auto;\n color: var(--nol-text);\n}\n\n.amend input {\n width: 1.125rem;\n height: 1.125rem;\n margin: 0;\n}\n\n.actions {\n justify-content: flex-end;\n}\n\n.signing,\n.hint {\n color: var(--nol-text-muted);\n font-size: var(--nol-text-label);\n}\n\n.signing {\n flex: none;\n white-space: nowrap;\n}\n"] }]
|
|
77
67
|
}], propDecorators: { status: [{ type: i0.Input, args: [{ isSignal: true, alias: "status", required: true }] }] } });
|
|
78
68
|
//# sourceMappingURL=git-commit-card.component.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"git-commit-card.component.js","sourceRoot":"","sources":["../../../../../../../../src/noldova.git.window/src/app/components/git-commit-card/git-commit-card.component.ts","../../../../../../../../src/noldova.git.window/src/app/components/git-commit-card/git-commit-card.component.html"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH,OAAO,EAAE,SAAS,EAAE,QAAQ,EAAE,MAAM,EAAE,KAAK,EAAiC,MAAM,eAAe,CAAC;AAClG,OAAO,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAC;AAC7C,OAAO,uBAAuB,CAAC;AAE/B,OAAO,EAAE,eAAe,EAAE,aAAa,EAAE,kBAAkB,EAAE,MAAM,gCAAgC,CAAC;AAEpG,OAAO,EAAE,SAAS,EAAE,MAAM,uBAAuB,CAAC;AAClD,OAAO,EAAE,cAAc,EAAE,MAAM,oCAAoC,CAAC;AACpE,OAAO,EAAE,mBAAmB,EAAE,MAAM,0CAA0C,CAAC;;;AAQ/E,MAAM,OAAO,sBAAsB;IACd,SAAS,GAAqB,SAAS,CAAC;IACxC,eAAe,GAAoB,cAAc,CAAC,eAAe,CAAC;IAClE,SAAS,GAAkB,aAAa,CAAC,SAAS,CAAC;IACnD,KAAK,GAAwB,MAAM,CAAC,mBAAmB,CAAC,CAAC;IACzD,WAAW,GAAmB,QAAQ,CAAC,GAAG,EAAE,CAAC,IAAI,CAAC,MAAM,EAAE,CAAC,SAAS,EAAE,OAAO,IAAI,SAAS,CAAC,kBAAkB;oFAAC,CAAC;IAC/G,QAAQ,GAAoB,
|
|
1
|
+
{"version":3,"file":"git-commit-card.component.js","sourceRoot":"","sources":["../../../../../../../../src/noldova.git.window/src/app/components/git-commit-card/git-commit-card.component.ts","../../../../../../../../src/noldova.git.window/src/app/components/git-commit-card/git-commit-card.component.html"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH,OAAO,EAAE,SAAS,EAAE,QAAQ,EAAE,MAAM,EAAE,KAAK,EAAiC,MAAM,eAAe,CAAC;AAClG,OAAO,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAC;AAC7C,OAAO,uBAAuB,CAAC;AAE/B,OAAO,EAAE,eAAe,EAAE,aAAa,EAAE,kBAAkB,EAAE,MAAM,gCAAgC,CAAC;AAEpG,OAAO,EAAE,SAAS,EAAE,MAAM,uBAAuB,CAAC;AAClD,OAAO,EAAE,cAAc,EAAE,MAAM,oCAAoC,CAAC;AACpE,OAAO,EAAE,mBAAmB,EAAE,MAAM,0CAA0C,CAAC;;;AAQ/E,MAAM,OAAO,sBAAsB;IACd,SAAS,GAAqB,SAAS,CAAC;IACxC,eAAe,GAAoB,cAAc,CAAC,eAAe,CAAC;IAClE,SAAS,GAAkB,aAAa,CAAC,SAAS,CAAC;IACnD,KAAK,GAAwB,MAAM,CAAC,mBAAmB,CAAC,CAAC;IACzD,WAAW,GAAmB,QAAQ,CAAC,GAAG,EAAE,CAAC,IAAI,CAAC,MAAM,EAAE,CAAC,SAAS,EAAE,OAAO,IAAI,SAAS,CAAC,kBAAkB;oFAAC,CAAC;IAC/G,QAAQ,GAAoB,IAAI,CAAC,KAAK,CAAC,QAAQ,CAAC;IAChD,UAAU,GAAmB,QAAQ,CAAC,GAAG,EAAE,CAAC,IAAI,CAAC,QAAQ,EAAE,IAAI,IAAI,CAAC,KAAK,CAAC,QAAQ,EAAE,CAAC,CAAC,CAAC,SAAS,CAAC,UAAU,CAAC,CAAC,CAAC,SAAS,CAAC,gBAAgB;mFAAC,CAAC;IAC1I,KAAK,GAAmB,QAAQ,CAAC,GAAG,EAAE;QACvD,MAAM,SAAS,GAAwB,IAAI,CAAC,MAAM,EAAE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