Skip to content

Commit d325057

Browse files
chore: Apply Prettier formatting
1 parent e9f10d9 commit d325057

5 files changed

Lines changed: 40 additions & 24 deletions

File tree

projects/website-angular/src/app/content/schema/instance-browser/instance-browser.component.scss

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
h2 {
77
margin: 0;
88
font-size: 1.4rem;
9-
font-family: 'Roboto Mono', monospace;
9+
font-family: "Roboto Mono", monospace;
1010
color: var(--on-surface);
1111
display: flex;
1212
align-items: baseline;
@@ -77,7 +77,7 @@
7777
}
7878

7979
.attr-name {
80-
font-family: 'Roboto Mono', monospace;
80+
font-family: "Roboto Mono", monospace;
8181
font-size: 0.82rem;
8282
color: var(--on-surface);
8383
white-space: nowrap;

projects/website-angular/src/app/content/schema/instance-browser/instance-browser.component.ts

Lines changed: 18 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -64,20 +64,21 @@ export class InstanceBrowserComponent implements OnChanges, OnDestroy {
6464
this.error = false;
6565
this.rows = [];
6666

67-
this.contentDataService.getInstance(this.instanceId).pipe(
68-
takeUntil(this.destroy$)
69-
).subscribe({
70-
next: (instance) => {
71-
this.instance = instance;
72-
this.schemaClass = instance.schemaClass || instance.className || '';
73-
this.dbId = instance.dbId;
74-
this.loadAttributes();
75-
},
76-
error: () => {
77-
this.error = true;
78-
this.loading = false;
79-
},
80-
});
67+
this.contentDataService
68+
.getInstance(this.instanceId)
69+
.pipe(takeUntil(this.destroy$))
70+
.subscribe({
71+
next: (instance) => {
72+
this.instance = instance;
73+
this.schemaClass = instance.schemaClass || instance.className || '';
74+
this.dbId = instance.dbId;
75+
this.loadAttributes();
76+
},
77+
error: () => {
78+
this.error = true;
79+
this.loading = false;
80+
},
81+
});
8182
}
8283

8384
private loadAttributes() {
@@ -147,7 +148,9 @@ export class InstanceBrowserComponent implements OnChanges, OnDestroy {
147148
return [
148149
{
149150
type: 'link',
150-
text: `[${val.schemaClass || val.className || 'Object'}:${val.dbId}] ${val.displayName || ''}`,
151+
text: `[${val.schemaClass || val.className || 'Object'}:${
152+
val.dbId
153+
}] ${val.displayName || ''}`,
151154
dbId: val.dbId,
152155
schemaClass: val.schemaClass || val.className,
153156
},

projects/website-angular/src/app/content/schema/schema.component.scss

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -212,7 +212,7 @@ $sidebar-width: 320px;
212212
margin: 0;
213213
font-size: 1.6rem;
214214
color: var(--on-surface);
215-
font-family: 'Roboto Mono', monospace;
215+
font-family: "Roboto Mono", monospace;
216216
}
217217

218218
.instance-count {
@@ -352,7 +352,7 @@ $sidebar-width: 320px;
352352
}
353353

354354
.attr-name {
355-
font-family: 'Roboto Mono', monospace;
355+
font-family: "Roboto Mono", monospace;
356356
font-size: 0.82rem;
357357
color: var(--on-surface);
358358
}
@@ -369,7 +369,7 @@ $sidebar-width: 320px;
369369
border-radius: 3px;
370370
font-size: 0.75rem;
371371
font-weight: 600;
372-
font-family: 'Roboto Mono', monospace;
372+
font-family: "Roboto Mono", monospace;
373373
background: rgba(0, 0, 0, 0.06);
374374
color: var(--on-surface-variant);
375375

projects/website-angular/src/app/content/schema/schema.component.ts

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -297,7 +297,11 @@ export class SchemaComponent implements OnInit, OnDestroy {
297297
loadEntries() {
298298
this.loadingEntries = true;
299299
this.contentDataService
300-
.getSchemaEntries(this.selectedClass, this.entriesPage, this.entriesPageSize)
300+
.getSchemaEntries(
301+
this.selectedClass,
302+
this.entriesPage,
303+
this.entriesPageSize
304+
)
301305
.subscribe({
302306
next: (entries) => {
303307
this.entries = entries;

projects/website-angular/src/services/content-data.service.ts

Lines changed: 12 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -102,14 +102,23 @@ export class ContentDataService {
102102
}
103103

104104
getSchemaAttributes(className: string): Observable<SchemaAttribute[]> {
105-
return this.http.get<SchemaAttribute[]>(`${this.schemaUrl}/${className}/attributes`);
105+
return this.http.get<SchemaAttribute[]>(
106+
`${this.schemaUrl}/${className}/attributes`
107+
);
106108
}
107109

108110
getSchemaReferrals(className: string): Observable<SchemaAttribute[]> {
109-
return this.http.get<SchemaAttribute[]>(`${this.schemaUrl}/${className}/referrals`);
111+
return this.http.get<SchemaAttribute[]>(
112+
`${this.schemaUrl}/${className}/referrals`
113+
);
110114
}
111115

112-
getSchemaEntries(className: string, page: number, offset: number, species?: string): Observable<SimpleDatabaseObject[]> {
116+
getSchemaEntries(
117+
className: string,
118+
page: number,
119+
offset: number,
120+
species?: string
121+
): Observable<SimpleDatabaseObject[]> {
113122
let url = `${this.schemaUrl}/${className}/min?page=${page}&offset=${offset}`;
114123
if (species) url += `&species=${encodeURIComponent(species)}`;
115124
return this.http.get<SimpleDatabaseObject[]>(url);

0 commit comments

Comments
 (0)