Skip to content

Commit 962fcdb

Browse files
authored
Merge pull request #311 from TaloDev/develop
Release 0.39.0
2 parents d530592 + c5695e8 commit 962fcdb

File tree

10 files changed

+169
-58
lines changed

10 files changed

+169
-58
lines changed

.github/workflows/ci.yml

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -20,11 +20,7 @@ jobs:
2020
- name: Install deps
2121
run: npm ci --prefer-offline
2222

23-
- run: npm test -- --silent --coverage
24-
25-
- uses: codecov/codecov-action@v4
26-
with:
27-
token: ${{ secrets.CODECOV_TOKEN }}
23+
- run: npm test -- --silent
2824

2925
e2e-tests:
3026
runs-on: ubuntu-latest

package-lock.json

Lines changed: 51 additions & 39 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -78,7 +78,7 @@
7878
"lint-staged": {
7979
"*.{ts,js,tsx,jsx}": "eslint --fix"
8080
},
81-
"version": "0.38.1",
81+
"version": "0.39.0",
8282
"engines": {
8383
"node": "20.x"
8484
},

src/__mocks__/playerAliasMock.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@ export default function playerAliasMock(extra: Partial<PlayerAlias> = {}): Playe
77
service: PlayerAliasService.STEAM,
88
identifier: 'yxre12',
99
player: playerMock(),
10+
lastSeenAt: new Date().toISOString(),
1011
createdAt: new Date().toISOString(),
1112
updatedAt: new Date().toISOString(),
1213
...extra

src/api/updateGame.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ import makeValidatedRequest from './makeValidatedRequest'
55
import { Prop } from '../entities/prop'
66

77
const updateGame = makeValidatedRequest(
8-
(gameId: number, data: { props: Prop[] }) => api.patch(`/games/${gameId}`, data),
8+
(gameId: number, data: { name?: string, props?: Prop[] }) => api.patch(`/games/${gameId}`, data),
99
z.object({
1010
game: gameSchema
1111
})

src/components/PlayerAliases.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ type PlayerAliasesProps = {
1313
export default function PlayerAliases({
1414
aliases
1515
}: PlayerAliasesProps) {
16-
const sortedAliases = useSortedItems(aliases, 'createdAt')
16+
const sortedAliases = useSortedItems(aliases, 'lastSeenAt')
1717

1818
const getIcon = useCallback((alias: PlayerAlias) => {
1919
/* v8ignore next */

src/components/__tests__/PlayerAliases.test.tsx

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -16,9 +16,9 @@ describe('<PlayerAliases />', () => {
1616

1717
it('should render the latest alias and an indicator for how many more', () => {
1818
const aliases: PlayerAlias[] = [
19-
playerAliasMock({ service: PlayerAliasService.STEAM, identifier: 'yxre12', createdAt: '2024-10-28 10:00:00' }),
20-
playerAliasMock({ service: PlayerAliasService.USERNAME, identifier: 'ryet12', createdAt: '2024-10-27 10:00:00' }),
21-
playerAliasMock({ service: PlayerAliasService.EPIC, identifier: 'epic_23rd', createdAt: '2024-10-26 10:00:00' })
19+
playerAliasMock({ service: PlayerAliasService.STEAM, identifier: 'yxre12', lastSeenAt: '2024-10-28 10:00:00' }),
20+
playerAliasMock({ service: PlayerAliasService.USERNAME, identifier: 'ryet12', lastSeenAt: '2024-10-27 10:00:00' }),
21+
playerAliasMock({ service: PlayerAliasService.EPIC, identifier: 'epic_23rd', lastSeenAt: '2024-10-26 10:00:00' })
2222
]
2323

2424
render(<PlayerAliases aliases={aliases} />)

src/entities/playerAlias.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@ export const playerAliasSchema = z.object({
1515
service: z.string(),
1616
identifier: z.string(),
1717
player: z.lazy(() => basePlayerSchema),
18+
lastSeenAt: z.string().datetime(),
1819
createdAt: z.string().datetime(),
1920
updatedAt: z.string().datetime()
2021
})

0 commit comments

Comments
 (0)