Skip to content

Commit 1c22294

Browse files
ci: apply automated fixes
1 parent 3de833f commit 1c22294

33 files changed

Lines changed: 162 additions & 373 deletions

File tree

examples/angular/basic-app-table/AGENTS.md

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
21
You are an expert in TypeScript, Angular, and scalable web application development. You write functional, maintainable, performant, and accessible code following Angular and TypeScript best practices.
32

43
## TypeScript Best Practices

examples/angular/basic-app-table/tsconfig.app.json

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -6,10 +6,6 @@
66
"outDir": "./out-tsc/app",
77
"types": []
88
},
9-
"include": [
10-
"src/**/*.ts"
11-
],
12-
"exclude": [
13-
"src/**/*.spec.ts"
14-
]
9+
"include": ["src/**/*.ts"],
10+
"exclude": ["src/**/*.spec.ts"]
1511
}

examples/angular/basic/src/main.ts

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
1-
import { bootstrapApplication } from '@angular/platform-browser';
2-
import { appConfig } from './app/app.config';
3-
import { App } from './app/app';
1+
import { bootstrapApplication } from '@angular/platform-browser'
2+
import { appConfig } from './app/app.config'
3+
import { App } from './app/app'
44

5-
bootstrapApplication(App, appConfig).catch((err) => console.error(err));
5+
bootstrapApplication(App, appConfig).catch((err) => console.error(err))

examples/angular/basic/tsconfig.app.json

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -6,10 +6,6 @@
66
"outDir": "./out-tsc/app",
77
"types": []
88
},
9-
"include": [
10-
"src/**/*.ts"
11-
],
12-
"exclude": [
13-
"src/**/*.spec.ts"
14-
]
9+
"include": ["src/**/*.ts"],
10+
"exclude": ["src/**/*.spec.ts"]
1511
}

examples/angular/column-ordering/tsconfig.app.json

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -6,10 +6,6 @@
66
"outDir": "./out-tsc/app",
77
"types": []
88
},
9-
"include": [
10-
"src/**/*.ts"
11-
],
12-
"exclude": [
13-
"src/**/*.spec.ts"
14-
]
9+
"include": ["src/**/*.ts"],
10+
"exclude": ["src/**/*.spec.ts"]
1511
}

examples/angular/column-pinning-sticky/src/app/app.html

Lines changed: 7 additions & 29 deletions
Original file line numberDiff line numberDiff line change
@@ -29,9 +29,7 @@
2929

3030
<div class="flex flex-wrap gap-2">
3131
<button (click)="rerender()" class="border p-1">Regenerate</button>
32-
<button (click)="randomizeColumns()" class="border p-1">
33-
Shuffle Columns
34-
</button>
32+
<button (click)="randomizeColumns()" class="border p-1">Shuffle Columns</button>
3533
</div>
3634
<div class="h-4"></div>
3735

@@ -42,10 +40,7 @@
4240
<tr>
4341
@for (header of headerGroup.headers; track header.id) {
4442
<!-- IMPORTANT: This is where the magic happens! -->
45-
<th
46-
[attr.colSpan]="header.colSpan"
47-
[style]="getCommonPinningStyles(header.column)"
48-
>
43+
<th [attr.colSpan]="header.colSpan" [style]="getCommonPinningStyles(header.column)">
4944
<div class="whitespace-nowrap">
5045
@if (!header.isPlaceholder) {
5146
<ng-container
@@ -59,38 +54,25 @@
5954
</ng-container>
6055
}
6156
<!-- Demo getIndex behavior -->
62-
{{
63-
header.column.getIndex(
64-
header.column.getIsPinned() || 'center'
65-
)
66-
}}
57+
{{ header.column.getIndex(header.column.getIsPinned() || 'center') }}
6758
</div>
6859

6960
@if (!header.isPlaceholder && header.column.getCanPin()) {
7061
<div class="flex gap-1 justify-center">
7162
@if (header.column.getIsPinned() !== 'left') {
72-
<button
73-
class="border rounded px-2"
74-
(click)="header.column.pin('left')"
75-
>
63+
<button class="border rounded px-2" (click)="header.column.pin('left')">
7664
<=
7765
</button>
7866
}
7967

8068
@if (header.column.getIsPinned()) {
81-
<button
82-
class="border rounded px-2"
83-
(click)="header.column.pin(false)"
84-
>
69+
<button class="border rounded px-2" (click)="header.column.pin(false)">
8570
X
8671
</button>
8772
}
8873

8974
@if (header.column.getIsPinned() !== 'right') {
90-
<button
91-
class="border rounded px-2"
92-
(click)="header.column.pin('right')"
93-
>
75+
<button class="border rounded px-2" (click)="header.column.pin('right')">
9476
=>
9577
</button>
9678
}
@@ -116,11 +98,7 @@
11698
@for (cell of row.getVisibleCells(); track cell.id) {
11799
<td [style]="getCommonPinningStyles(cell.column)">
118100
<ng-container
119-
*flexRender="
120-
cell.column.columnDef.cell;
121-
props: cell.getContext();
122-
let cellValue
123-
"
101+
*flexRender="cell.column.columnDef.cell; props: cell.getContext(); let cellValue"
124102
>
125103
{{ cellValue }}
126104
</ng-container>

examples/angular/column-pinning-sticky/tsconfig.app.json

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -6,10 +6,6 @@
66
"outDir": "./out-tsc/app",
77
"types": []
88
},
9-
"include": [
10-
"src/**/*.ts"
11-
],
12-
"exclude": [
13-
"src/**/*.spec.ts"
14-
]
9+
"include": ["src/**/*.ts"],
10+
"exclude": ["src/**/*.spec.ts"]
1511
}

examples/angular/column-pinning/src/app/app.html

Lines changed: 12 additions & 49 deletions
Original file line numberDiff line numberDiff line change
@@ -29,19 +29,12 @@
2929

3030
<div class="flex flex-wrap gap-2">
3131
<button (click)="rerender()" class="border p-1">Regenerate</button>
32-
<button (click)="randomizeColumns()" class="border p-1">
33-
Shuffle Columns
34-
</button>
32+
<button (click)="randomizeColumns()" class="border p-1">Shuffle Columns</button>
3533
</div>
3634
<div class="h-4"></div>
3735
<div>
3836
<label>
39-
<input
40-
type="checkbox"
41-
#input
42-
[checked]="split()"
43-
(change)="split.set(input.checked)"
44-
/>
37+
<input type="checkbox" #input [checked]="split()" (change)="split.set(input.checked)" />
4538
Split mode
4639
</label>
4740
</div>
@@ -51,10 +44,7 @@
5144
@if (split()) {
5245
<table class="border-2 border-black">
5346
<thead>
54-
@for (
55-
headerGroup of table.getLeftHeaderGroups();
56-
track headerGroup.id
57-
) {
47+
@for (headerGroup of table.getLeftHeaderGroups(); track headerGroup.id) {
5848
<tr>
5949
@for (header of headerGroup.headers; track header.id) {
6050
<th [attr.colSpan]="header.colSpan">
@@ -73,10 +63,7 @@
7363
</div>
7464

7565
<ng-container
76-
*ngTemplateOutlet="
77-
headerContentTpl;
78-
context: { $implicit: header }
79-
"
66+
*ngTemplateOutlet="headerContentTpl; context: { $implicit: header }"
8067
/>
8168
</th>
8269
}
@@ -109,10 +96,7 @@
10996
<!-- Center Side -->
11097
<table class="border-2 border-black">
11198
<thead>
112-
@if (
113-
split() ? table.getCenterHeaderGroups() : table.getHeaderGroups();
114-
as headerGroups
115-
) {
99+
@if (split() ? table.getCenterHeaderGroups() : table.getHeaderGroups(); as headerGroups) {
116100
@for (headerGroup of headerGroups; track headerGroup.id) {
117101
<tr>
118102
@for (header of headerGroup.headers; track header.id) {
@@ -131,10 +115,7 @@
131115
}
132116

133117
<ng-container
134-
*ngTemplateOutlet="
135-
headerContentTpl;
136-
context: { $implicit: header }
137-
"
118+
*ngTemplateOutlet="headerContentTpl; context: { $implicit: header }"
138119
/>
139120
</div>
140121
</th>
@@ -145,10 +126,7 @@
145126
</thead>
146127
<tbody>
147128
@for (row of table.getRowModel().rows | slice: 0 : 20; track row.id) {
148-
@if (
149-
split() ? row.getCenterVisibleCells() : row.getVisibleCells();
150-
as cells
151-
) {
129+
@if (split() ? row.getCenterVisibleCells() : row.getVisibleCells(); as cells) {
152130
<tr>
153131
@for (cell of cells; track cell.id) {
154132
<td>
@@ -173,10 +151,7 @@
173151
@if (split()) {
174152
<table class="border-2 border-black">
175153
<thead>
176-
@for (
177-
headerGroup of table.getRightHeaderGroups();
178-
track headerGroup.id
179-
) {
154+
@for (headerGroup of table.getRightHeaderGroups(); track headerGroup.id) {
180155
<tr>
181156
@for (header of headerGroup.headers; track header.id) {
182157
<th [attr.colSpan]="header.colSpan">
@@ -195,10 +170,7 @@
195170
</div>
196171

197172
<ng-container
198-
*ngTemplateOutlet="
199-
headerContentTpl;
200-
context: { $implicit: header }
201-
"
173+
*ngTemplateOutlet="headerContentTpl; context: { $implicit: header }"
202174
/>
203175
</th>
204176
}
@@ -237,24 +209,15 @@
237209
@if (!header.isPlaceholder && header.column.getCanPin()) {
238210
<div class="flex gap-1 justify-center">
239211
@if (header.column.getIsPinned() !== 'left') {
240-
<button class="border rounded px-2" (click)="header.column.pin('left')">
241-
<=
242-
</button>
212+
<button class="border rounded px-2" (click)="header.column.pin('left')"><=</button>
243213
}
244214

245215
@if (header.column.getIsPinned()) {
246-
<button class="border rounded px-2" (click)="header.column.pin(false)">
247-
X
248-
</button>
216+
<button class="border rounded px-2" (click)="header.column.pin(false)">X</button>
249217
}
250218

251219
@if (header.column.getIsPinned() !== 'right') {
252-
<button
253-
class="border rounded px-2"
254-
(click)="header.column.pin('right')"
255-
>
256-
=>
257-
</button>
220+
<button class="border rounded px-2" (click)="header.column.pin('right')">=></button>
258221
}
259222
</div>
260223
}

examples/angular/column-pinning/tsconfig.app.json

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -6,10 +6,6 @@
66
"outDir": "./out-tsc/app",
77
"types": []
88
},
9-
"include": [
10-
"src/**/*.ts"
11-
],
12-
"exclude": [
13-
"src/**/*.spec.ts"
14-
]
9+
"include": ["src/**/*.ts"],
10+
"exclude": ["src/**/*.spec.ts"]
1511
}

examples/angular/column-resizing-performant/tsconfig.app.json

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -6,10 +6,6 @@
66
"outDir": "./out-tsc/app",
77
"types": []
88
},
9-
"include": [
10-
"src/**/*.ts"
11-
],
12-
"exclude": [
13-
"src/**/*.spec.ts"
14-
]
9+
"include": ["src/**/*.ts"],
10+
"exclude": ["src/**/*.spec.ts"]
1511
}

0 commit comments

Comments
 (0)