bnstooltips 1.6.4 → 1.6.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/build/index.es.js +7 -2
- package/build/index.es.js.map +1 -1
- package/build/index.js +7 -2
- package/build/index.js.map +1 -1
- package/package.json +1 -1
package/build/index.es.js
CHANGED
|
@@ -1280,9 +1280,14 @@ function GetCooldownString(cooldownInMs) {
|
|
|
1280
1280
|
}
|
|
1281
1281
|
}
|
|
1282
1282
|
|
|
1283
|
+
function removeDuplicates(stats) {
|
|
1284
|
+
return stats.filter(function (value, index, self) {
|
|
1285
|
+
return index === self.findIndex(function (t) { return t.name === value.name; });
|
|
1286
|
+
});
|
|
1287
|
+
}
|
|
1283
1288
|
function ItemStats(item) {
|
|
1284
1289
|
return (React.createElement("div", { className: "ItemTooltip_stats" },
|
|
1285
|
-
item.stats
|
|
1290
|
+
removeDuplicates(item.stats)
|
|
1286
1291
|
.filter(function (x) { return x.isMainStat; })
|
|
1287
1292
|
.map(function (mainStat, i) {
|
|
1288
1293
|
if (mainStat.name.includes("-min"))
|
|
@@ -1298,7 +1303,7 @@ function ItemStats(item) {
|
|
|
1298
1303
|
"\u00A0",
|
|
1299
1304
|
ReplaceBossAndPvpAp(mainStat.name).replace("Max.", "").trim()));
|
|
1300
1305
|
}),
|
|
1301
|
-
item.stats
|
|
1306
|
+
removeDuplicates(item.stats)
|
|
1302
1307
|
.filter(function (x) { return !x.isMainStat; })
|
|
1303
1308
|
.map(function (subStat, i) {
|
|
1304
1309
|
if (subStat.name.includes("-min"))
|