Skip to content

Commit

Permalink
chore(deps): update dependency typescript to v5 (#7994)
Browse files Browse the repository at this point in the history
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: jamil314 <[email protected]>
  • Loading branch information
3 people authored Nov 19, 2024
1 parent 5334759 commit d9bd090
Show file tree
Hide file tree
Showing 101 changed files with 1,655 additions and 1,465 deletions.
6 changes: 3 additions & 3 deletions packages/auth/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -54,14 +54,14 @@
"eslint-config-prettier": "^9.0.0",
"eslint-plugin-import": "^2.17.3",
"eslint-plugin-prettier": "^4.0.0",
"jest": "27.5.1",
"jest": "29.7.0",
"jest-fetch-mock": "^2.1.2",
"nodemon": "^3.0.0",
"prettier": "2.8.8",
"redis-mock": "^0.56.0",
"ts-jest": "27.1.4",
"ts-jest": "29.2.5",
"ts-node": "^6.1.1",
"typescript": "4.9.5"
"typescript": "5.6.3"
},
"lint-staged": {
"src/**/*.ts": [
Expand Down
24 changes: 5 additions & 19 deletions packages/auth/tsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,7 @@
"compilerOptions": {
"baseUrl": "./src",
"paths": {
"@auth/*": [
"./*"
]
"@auth/*": ["./*"]
},
"target": "es6",
"module": "commonjs",
Expand All @@ -14,33 +12,21 @@
"sourceMap": true,
"moduleResolution": "node",
"rootDir": ".",
"lib": [
"esnext.asynciterable",
"es6",
"es2017"
],
"lib": ["esnext.asynciterable", "es6", "es2017"],
"forceConsistentCasingInFileNames": true,
"noImplicitReturns": true,
"noImplicitThis": true,
"noImplicitAny": true,
"strictNullChecks": true,
"suppressImplicitAnyIndexErrors": true,
"noUnusedLocals": true,
"types": [
"fhir",
"jest"
]
"types": ["fhir", "jest"]
},
"include": [
"resources/**/*.ts",
"src/**/*.ts",
"typings"
],
"include": ["resources/**/*.ts", "src/**/*.ts", "typings"],
"exclude": [
"node_modules",
"build",
"scripts",
"acceptance-tests",
"src/setupTests.ts"
]
}
}
7 changes: 4 additions & 3 deletions packages/client/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -69,8 +69,9 @@
"history": "^4.7.2",
"html-to-pdfmake": "^2.5.13",
"iframe-resizer-react": "^1.1.0",
"jsdom": "16.7.0",
"jsdom-worker": "^0.3.0",
"jwt-decode": "^2.2.0",
"jwt-decode": "^3.0.0",
"localforage": "^1.7.2",
"lodash": "^4.17.10",
"patch-package": "^6.1.2",
Expand Down Expand Up @@ -142,7 +143,7 @@
"eslint-config-prettier": "^9.0.0",
"eslint-config-react-app": "^6.0.0",
"eslint-plugin-flowtype": "^5.2.0",
"eslint-plugin-formatjs": "2.21.0",
"eslint-plugin-formatjs": "4.10.0",
"eslint-plugin-import": "^2.17.3",
"eslint-plugin-jsx-a11y": "^6.3.1",
"eslint-plugin-prettier": "^4.0.0",
Expand All @@ -161,7 +162,7 @@
"stylelint-processor-styled-components": "^1.10.0",
"traverse": "^0.6.6",
"ts-node": "^7.0.1",
"typescript": "4.9.5",
"typescript": "5.6.3",
"vite-plugin-pwa": "^0.20.0",
"vitest": "0.25.5",
"vitest-fetch-mock": "^0.2.1"
Expand Down
8 changes: 4 additions & 4 deletions packages/commons/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -35,12 +35,12 @@
"@types/uuid": "^9.0.3",
"date-fns": "^2.28.0",
"elastic-apm-node": "^3.29.0",
"jest": "27.5.1",
"jwt-decode": "^2.2.0",
"jest": "29.7.0",
"jwt-decode": "^3.0.0",
"lodash": "^4.17.10",
"node-fetch": "^2.6.7",
"pkg-up": "^3.1.0",
"typescript": "4.9.5",
"typescript": "5.6.3",
"uuid": "^9.0.0",
"pino": "^7.0.0"
},
Expand All @@ -53,7 +53,7 @@
"eslint-plugin-prettier": "^4.0.0",
"jest-fetch-mock": "^2.1.2",
"pino-pretty": "^11.0.0",
"ts-jest": "27.1.4"
"ts-jest": "29.2.5"
},
"lint-staged": {
"src/**/*.ts": [
Expand Down
66 changes: 44 additions & 22 deletions packages/commons/src/assignment.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,8 @@ it('finds assignment from the latest task', () => {
]
},
focus: {
reference: 'Composition/c5811d36-934d-40f9-94b4-15194d562e45'
reference:
'Composition/c5811d36-934d-40f9-94b4-15194d562e45' as `Composition/${UUID}`
},
extension: [
{
Expand Down Expand Up @@ -122,7 +123,8 @@ it("finds assignment when it's in TaskHistory and status HAS NOT changed", () =>
]
},
focus: {
reference: 'Composition/c5811d36-934d-40f9-94b4-15194d562e45'
reference:
'Composition/c5811d36-934d-40f9-94b4-15194d562e45' as `Composition/${UUID}`
},
identifier: [
{
Expand All @@ -137,13 +139,15 @@ it("finds assignment when it's in TaskHistory and status HAS NOT changed", () =>
{
url: 'http://opencrvs.org/specs/extension/regLastUser',
valueReference: {
reference: 'Practitioner/00000000-0000-4000-8000-000000000001'
reference:
'Practitioner/00000000-0000-4000-8000-000000000001' as `Practitioner/${UUID}`
}
},
{
url: 'http://opencrvs.org/specs/extension/regLastOffice',
valueReference: {
reference: 'Location/00000000-0000-4000-8000-000000000010'
reference:
'Location/00000000-0000-4000-8000-000000000010' as `Location/${UUID}`
}
}
],
Expand Down Expand Up @@ -268,7 +272,8 @@ it("does not find assignment when it's in TaskHistory and status HAS changed", (
]
},
focus: {
reference: 'Composition/c5811d36-934d-40f9-94b4-15194d562e45'
reference:
'Composition/c5811d36-934d-40f9-94b4-15194d562e45' as `Composition/${UUID}`
},
identifier: [
{
Expand All @@ -283,13 +288,15 @@ it("does not find assignment when it's in TaskHistory and status HAS changed", (
{
url: 'http://opencrvs.org/specs/extension/regLastUser',
valueReference: {
reference: 'Practitioner/00000000-0000-4000-8000-000000000001'
reference:
'Practitioner/00000000-0000-4000-8000-000000000001' as `Practitioner/${UUID}`
}
},
{
url: 'http://opencrvs.org/specs/extension/regLastOffice',
valueReference: {
reference: 'Location/00000000-0000-4000-8000-000000000010'
reference:
'Location/00000000-0000-4000-8000-000000000010' as `Location/${UUID}`
}
}
],
Expand Down Expand Up @@ -317,7 +324,8 @@ it("does not find assignment when it's in TaskHistory and status HAS changed", (
]
},
focus: {
reference: 'Composition/c5811d36-934d-40f9-94b4-15194d562e45'
reference:
'Composition/c5811d36-934d-40f9-94b4-15194d562e45' as `Composition/${UUID}`
},
identifier: [
{
Expand All @@ -332,13 +340,15 @@ it("does not find assignment when it's in TaskHistory and status HAS changed", (
{
url: 'http://opencrvs.org/specs/extension/regLastUser',
valueReference: {
reference: 'Practitioner/00000000-0000-4000-8000-000000000002'
reference:
'Practitioner/00000000-0000-4000-8000-000000000002' as `Practitioner/${UUID}`
}
},
{
url: 'http://opencrvs.org/specs/extension/regLastOffice',
valueReference: {
reference: 'Location/00000000-0000-4000-8000-000000000010'
reference:
'Location/00000000-0000-4000-8000-000000000010' as `Location/${UUID}`
}
}
],
Expand Down Expand Up @@ -366,7 +376,8 @@ it("does not find assignment when it's in TaskHistory and status HAS changed", (
]
},
focus: {
reference: 'Composition/c5811d36-934d-40f9-94b4-15194d562e45'
reference:
'Composition/c5811d36-934d-40f9-94b4-15194d562e45' as `Composition/${UUID}`
},
identifier: [
{
Expand All @@ -381,13 +392,15 @@ it("does not find assignment when it's in TaskHistory and status HAS changed", (
{
url: 'http://opencrvs.org/specs/extension/regLastUser',
valueReference: {
reference: 'Practitioner/93e34962-cef1-446a-985f-ad0e46732939'
reference:
'Practitioner/93e34962-cef1-446a-985f-ad0e46732939' as `Practitioner/${UUID}`
}
},
{
url: 'http://opencrvs.org/specs/extension/regLastOffice',
valueReference: {
reference: 'Location/347ef736-2359-48cc-a513-5b9fae487fb7'
reference:
'Location/347ef736-2359-48cc-a513-5b9fae487fb7' as `Location/${UUID}`
}
}
],
Expand Down Expand Up @@ -443,7 +456,8 @@ it("does not find assignment when it's in TaskHistory and status has afterwards
]
},
focus: {
reference: 'Composition/c5811d36-934d-40f9-94b4-15194d562e45'
reference:
'Composition/c5811d36-934d-40f9-94b4-15194d562e45' as `Composition/${UUID}`
},
identifier: [
{
Expand All @@ -459,13 +473,15 @@ it("does not find assignment when it's in TaskHistory and status has afterwards
{
url: 'http://opencrvs.org/specs/extension/regLastUser',
valueReference: {
reference: 'Practitioner/00000000-0000-4000-8000-000000000001'
reference:
'Practitioner/00000000-0000-4000-8000-000000000001' as `Practitioner/${UUID}`
}
},
{
url: 'http://opencrvs.org/specs/extension/regLastOffice',
valueReference: {
reference: 'Location/00000000-0000-4000-8000-000000000010'
reference:
'Location/00000000-0000-4000-8000-000000000010' as `Location/${UUID}`
}
}
],
Expand All @@ -492,7 +508,8 @@ it("does not find assignment when it's in TaskHistory and status has afterwards
]
},
focus: {
reference: 'Composition/c5811d36-934d-40f9-94b4-15194d562e45'
reference:
'Composition/c5811d36-934d-40f9-94b4-15194d562e45' as `Composition/${UUID}`
},
identifier: [
{
Expand All @@ -508,13 +525,15 @@ it("does not find assignment when it's in TaskHistory and status has afterwards
{
url: 'http://opencrvs.org/specs/extension/regLastUser',
valueReference: {
reference: 'Practitioner/00000000-0000-4000-8000-000000000002'
reference:
'Practitioner/00000000-0000-4000-8000-000000000002' as `Practitioner/${UUID}`
}
},
{
url: 'http://opencrvs.org/specs/extension/regLastOffice',
valueReference: {
reference: 'Location/00000000-0000-4000-8000-000000000010'
reference:
'Location/00000000-0000-4000-8000-000000000010' as `Location/${UUID}`
}
}
],
Expand Down Expand Up @@ -542,7 +561,8 @@ it("does not find assignment when it's in TaskHistory and status has afterwards
]
},
focus: {
reference: 'Composition/c5811d36-934d-40f9-94b4-15194d562e45'
reference:
'Composition/c5811d36-934d-40f9-94b4-15194d562e45' as `Composition/${UUID}`
},
identifier: [
{
Expand All @@ -557,13 +577,15 @@ it("does not find assignment when it's in TaskHistory and status has afterwards
{
url: 'http://opencrvs.org/specs/extension/regLastUser',
valueReference: {
reference: 'Practitioner/93e34962-cef1-446a-985f-ad0e46732939'
reference:
'Practitioner/93e34962-cef1-446a-985f-ad0e46732939' as `Practitioner/${UUID}`
}
},
{
url: 'http://opencrvs.org/specs/extension/regLastOffice',
valueReference: {
reference: 'Location/347ef736-2359-48cc-a513-5b9fae487fb7'
reference:
'Location/347ef736-2359-48cc-a513-5b9fae487fb7' as `Location/${UUID}`
}
}
],
Expand Down
2 changes: 1 addition & 1 deletion packages/commons/src/authentication.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
*/

import { IAuthHeader } from './http'
import * as decode from 'jwt-decode'
import decode from 'jwt-decode'

/** All the scopes user can be assigned to */
export const userScopes = {
Expand Down
2 changes: 1 addition & 1 deletion packages/commons/src/fhir/composition.ts
Original file line number Diff line number Diff line change
Expand Up @@ -171,7 +171,7 @@ type ReferenceType =

export type CompositionSectionCode = ReferenceType['code']

type ReferenceTypeByCode<U extends CompositionSectionCode> = Extract<
export type ReferenceTypeByCode<U extends CompositionSectionCode> = Extract<
ReferenceType,
{ code: U }
>
Expand Down
8 changes: 4 additions & 4 deletions packages/commons/src/fhir/transformers/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,7 @@ import {
CompositionSectionTitleByCode,
EVENT_TYPE
} from '..'
import { getUUID } from '../..'
import { getUUID, UUID } from '../..'
import { replaceFromBundle } from '../../record'
import {
AddressInput,
Expand Down Expand Up @@ -508,7 +508,7 @@ function createAddressBuilder<T extends CompositionSectionCode>(
{
url: 'http://opencrvs.org/specs/extension/part-of',
valueReference: {
reference: `Location/${fieldValue}`
reference: `Location/${fieldValue as UUID}`
}
}
],
Expand Down Expand Up @@ -642,7 +642,7 @@ function createLocationAddressBuilder(
context
)

location.partOf = { reference: `Location/${fieldValue}` }
location.partOf = { reference: `Location/${fieldValue as UUID}` }
}
}
}
Expand Down Expand Up @@ -2090,7 +2090,7 @@ const builders: IFieldBuilders = {
{
url: 'http://opencrvs.org/specs/extension/part-of',
valueReference: {
reference: `Location/${fieldValue}`
reference: `Location/${fieldValue as UUID}`
}
}
],
Expand Down
Loading

0 comments on commit d9bd090

Please sign in to comment.