1
0
Форкнуть 0

updated dependencies, vulnerabilities patched (#47)

* updatet dependencies, vulnerabilities patched

* removed pointer.ts
This commit is contained in:
Alexey 2021-01-19 12:56:47 +03:00 коммит произвёл GitHub
Родитель 6dc35f256a
Коммит 5328ee9449
Не найден ключ, соответствующий данной подписи
Идентификатор ключа GPG: 4AEE18F83AFDEB23
4 изменённых файлов: 1082 добавлений и 1123 удалений

Просмотреть файл

@ -1,3 +1,7 @@
## 2.3.1
* Packages update
* Vulnerabilities fixes
## 2.3.0
* Packages update
* Vulnerabilities fixes

2103
package-lock.json сгенерированный

Разница между файлами не показана из-за своего большого размера Загрузить разницу

Просмотреть файл

@ -1,6 +1,6 @@
{
"name": "powerbi-visuals-utils-svgutils",
"version": "2.3.0",
"version": "2.3.1",
"description": "powerbi-visuals-utils-svgutils",
"main": "lib/index.js",
"module": "lib/index.js",
@ -31,42 +31,42 @@
"lint": "tslint -r \"node_modules/tslint-microsoft-contrib\" \"+(src|test)/**/*.ts\""
},
"devDependencies": {
"@types/d3": "5.7.2",
"@types/jasmine": "3.5.11",
"@types/d3": "^6.2.0",
"@types/jasmine": "3.6.2",
"@types/jasmine-jquery": "1.5.33",
"@types/jquery": "3.5.0",
"@types/karma": "5.0.0",
"@types/node": "14.0.14",
"@types/webpack": "4.41.18",
"@types/jquery": "3.5.5",
"@types/karma": "5.0.1",
"@types/node": "14.14.21",
"@types/webpack": "4.41.26",
"coveralls": "3.1.0",
"istanbul-instrumenter-loader": "3.0.1",
"jasmine": "3.5.0",
"jasmine": "3.6.3",
"jasmine-jquery": "2.1.1",
"jquery": "^3.5.1",
"karma": "^5.1.0",
"karma": "^5.2.3",
"karma-chrome-launcher": "3.1.0",
"karma-coverage": "2.0.2",
"karma-coverage": "2.0.3",
"karma-coverage-istanbul-reporter": "3.0.3",
"karma-jasmine": "3.3.1",
"karma-jasmine": "4.0.1",
"karma-remap-istanbul": "0.6.0",
"karma-sourcemap-loader": "0.3.7",
"karma-typescript": "5.0.3",
"karma-sourcemap-loader": "0.3.8",
"karma-typescript": "5.2.0",
"karma-typescript-preprocessor": "0.4.0",
"karma-webpack": "4.0.2",
"powerbi-visuals-api": "3.2.0",
"powerbi-visuals-utils-testutils": "2.3.1",
"puppeteer": "5.0.0",
"powerbi-visuals-api": "3.5.1",
"powerbi-visuals-utils-testutils": "2.3.4",
"puppeteer": "5.5.0",
"script-loader": "0.7.2",
"ts-loader": "7.0.5",
"ts-node": "8.10.2",
"tslint": "6.1.2",
"ts-loader": "8.0.14",
"ts-node": "9.1.1",
"tslint": "6.1.3",
"tslint-microsoft-contrib": "6.2.0",
"typescript": "3.9.6",
"typescript": "^3.9.6",
"webpack": "4.43.0",
"webpack-node-externals": "1.7.2"
},
"dependencies": {
"d3": "5.16.0",
"powerbi-visuals-utils-typeutils": "2.3.0"
"d3": "6.3.1",
"powerbi-visuals-utils-typeutils": "^2.3.1"
}
}

Просмотреть файл

@ -1,54 +0,0 @@
/*
* Power BI Visualizations
*
* Copyright (c) Microsoft Corporation
* All rights reserved.
* MIT License
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the ""Software""), to deal
* in the Software without restriction, including without limitation the rights
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
* copies of the Software, and to permit persons to whom the Software is
* furnished to do so, subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in
* all copies or substantial portions of the Software.
*
* THE SOFTWARE IS PROVIDED *AS IS*, WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
* THE SOFTWARE.
*/
import { touches } from "d3-selection";
export function getCoordinates(rootNode: HTMLElement, isPointerEvent: boolean): number[] {
let coordinates: number[];
if (isPointerEvent) {
// DO NOT USE - WebKit bug in getScreenCTM with nested SVG results in slight negative coordinate shift
// Also, IE will incorporate transform scale but WebKit does not, forcing us to detect browser and adjust appropriately.
// Just use non-scaled coordinates for all browsers, and adjust for the transform scale later (see lineChart.findIndex)
// coordinates = d3.mouse(rootNode);
// copied from d3_eventSource (which is not exposed)
let e = <MouseEvent>require("d3-selection").event;
let s;
while (s = (<d3.BaseEvent>e).sourceEvent) {
e = s;
}
let rect = rootNode.getBoundingClientRect();
coordinates = [e.clientX - rect.left - rootNode.clientLeft, e.clientY - rect.top - rootNode.clientTop];
}
else {
let touchCoordinates = touches(rootNode);
if (touchCoordinates && touchCoordinates.length > 0) {
coordinates = touchCoordinates[0];
}
}
return coordinates;
}