From 16b83d0b5404a32384d02fd2664093b44e34951f Mon Sep 17 00:00:00 2001 From: Hubert Walczak Date: Thu, 23 May 2024 13:14:53 +0200 Subject: [PATCH] Updated gsi package --- package-lock.json | 17 +++++++++-------- package.json | 2 +- src/App.tsx | 6 +++--- yarn.lock | 7 ++++--- 4 files changed, 17 insertions(+), 15 deletions(-) diff --git a/package-lock.json b/package-lock.json index 14bd5a9..f9e1a34 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,12 +1,12 @@ { "name": "lexogrine_dota2_hud", - "version": "1.3.0", + "version": "1.3.1", "lockfileVersion": 2, "requires": true, "packages": { "": { "name": "lexogrine_dota2_hud", - "version": "1.3.0", + "version": "1.3.1", "license": "GPL-3.0", "dependencies": { "@craco/craco": "^5.7.0", @@ -15,7 +15,7 @@ "@types/react": "18.0.35", "@types/react-dom": "18.0.11", "buffer": "^6.0.3", - "dotagsi": "github:Macronic/dota2gsi", + "dotagsi": "^1.4.3", "query-string": "^6.12.1", "react": "^18.2.0", "react-dom": "^18.2.0", @@ -6795,9 +6795,9 @@ } }, "node_modules/dotagsi": { - "version": "1.3.2", - "resolved": "git+ssh://git@github.com/Macronic/dota2gsi.git#df17e53279c67c54b02e583c1ba57eb185197d83", - "license": "MIT" + "version": "1.4.3", + "resolved": "https://registry.npmjs.org/dotagsi/-/dotagsi-1.4.3.tgz", + "integrity": "sha512-6yksHABW4InBVJ+IOgKXwN3UtTiRdPLsIHVJeswDco6rWUZxMWYXS4YZlpcdMbBX539rdmLiNzGq08ZW64lKqg==" }, "node_modules/dotenv": { "version": "10.0.0", @@ -23037,8 +23037,9 @@ } }, "dotagsi": { - "version": "git+ssh://git@github.com/Macronic/dota2gsi.git#df17e53279c67c54b02e583c1ba57eb185197d83", - "from": "dotagsi@github:Macronic/dota2gsi" + "version": "1.4.3", + "resolved": "https://registry.npmjs.org/dotagsi/-/dotagsi-1.4.3.tgz", + "integrity": "sha512-6yksHABW4InBVJ+IOgKXwN3UtTiRdPLsIHVJeswDco6rWUZxMWYXS4YZlpcdMbBX539rdmLiNzGq08ZW64lKqg==" }, "dotenv": { "version": "10.0.0", diff --git a/package.json b/package.json index 7519c55..a58bada 100644 --- a/package.json +++ b/package.json @@ -9,7 +9,7 @@ "@types/node": "18.15.11", "@types/react": "18.0.35", "@types/react-dom": "18.0.11", - "dotagsi": "github:Macronic/dota2gsi", + "dotagsi": "^1.4.3", "buffer": "^6.0.3", "query-string": "^6.12.1", "react": "^18.2.0", diff --git a/src/App.tsx b/src/App.tsx index 931010d..d41885b 100644 --- a/src/App.tsx +++ b/src/App.tsx @@ -2,7 +2,7 @@ import React from 'react'; import Layout from './HUD/Layout/Layout'; import api, { port, isDev } from './api/api'; import ActionManager, { ConfigManager } from './api/actionManager'; -import { Dota2, DOTA2GSI, PlayerExtension } from 'dotagsi'; +import { Dota2, DOTA2GSI, PlayerExtension, TeamExtension } from 'dotagsi'; import io from "socket.io-client"; import { loadAvatarURL } from './api/avatars'; import { Match } from './api/interfaces'; @@ -181,7 +181,7 @@ class App extends React.Component { - const gsiTeamData = { id: left._id, name: left.name, country: left.country, logo: left.logo, map_score: match.left.wins, extra: left.extra }; + const gsiTeamData: TeamExtension = { id: left._id, name: left.name, short_name: left.shortName, country: left.country, logo: left.logo, map_score: match.left.wins, extra: left.extra, }; if (!isReversed) { DOTA2.teams.radiant = gsiTeamData; } @@ -190,7 +190,7 @@ class App extends React.Component { - const gsiTeamData = { id: right._id, name: right.name, country: right.country, logo: right.logo, map_score: match.right.wins, extra: right.extra }; + const gsiTeamData: TeamExtension = { id: right._id, name: right.name, short_name: right.shortName, country: right.country, logo: right.logo, map_score: match.right.wins, extra: right.extra }; if (!isReversed) DOTA2.teams.dire = gsiTeamData; else DOTA2.teams.radiant = gsiTeamData; diff --git a/yarn.lock b/yarn.lock index 8186607..324472e 100644 --- a/yarn.lock +++ b/yarn.lock @@ -3926,9 +3926,10 @@ dot-case@^3.0.4: no-case "^3.0.4" tslib "^2.0.3" -"dotagsi@github:Macronic/dota2gsi": - version "1.3.2" - resolved "git+ssh://git@github.com/Macronic/dota2gsi.git#df17e53279c67c54b02e583c1ba57eb185197d83" +dotagsi@^1.4.3: + version "1.4.3" + resolved "https://registry.npmjs.org/dotagsi/-/dotagsi-1.4.3.tgz" + integrity sha512-6yksHABW4InBVJ+IOgKXwN3UtTiRdPLsIHVJeswDco6rWUZxMWYXS4YZlpcdMbBX539rdmLiNzGq08ZW64lKqg== dotenv-expand@^5.1.0: version "5.1.0"