// npm package
@antv/g-mobile-canvas
A renderer implemented with Canvas2D API in mobile environment
versions
223
maintainers
51
license
MIT
first publish
2022-04-15
publisher
wang1212
tarball
493,319 B
AUTO-PUBLISHED·1 version indexed·latest published 2025-12-24
// publisher campaignby wang1212
9 caught packages from this accountThis is not an isolated catch. The same publisher has shipped 8 other packages that our pipeline flagged — the shape of a coordinated campaign, not a one-off. Each link below opens that sibling's analysis.
// offending code· @1.1.1· 1 file flagged
llm: benign · 0.85→ No suspicious destination, no remote-exec shape — 2 known-vendor host(s), 1 other host(s).
- @1.1.1··AUTO-PUBLISHED·publisher: wang1212heuristic 75/100static flags 1llm benign (0.85) via ollamamature-packageosv-flagged:MAL-2026-3925public-github-push
→ No suspicious destination, no remote-exec shape — 2 known-vendor host(s), 1 other host(s).
// offending code· 1 file flaggedpatterns: 1
--- package/package.json (excerpt) --- { "name": "@antv/g-mobile-canvas", "version": "1.1.1", "description": "A renderer implemented with Canvas2D API in mobile environment", "keywords": [ "antv", "g" ], "homepage": "https://github.com/antvis/g#readme", "bugs": { "url": "https://github.com/antvis/g/issues" }, "repository": { "type": "git", "url": "git+https://github.com/antvis/g.git" }, "license": "MIT", "author": "https://github.com/orgs/antvis/people", "exports": { "types": "./types/index.d.ts", "import": "./dist/index.esm.js", "default": "./dist/index.js" }, "main": "dist/index.js", "unpkg": "dist/index.umd.min.js", "module": "dist/index.esm.js", "types": "types/index.d.ts", "files": [ "package.json", "dist", "types", "LICENSE", "README.md" ], "dependencies": { "@antv/util": "^3.3.5", "@babel/runtime": "^7.25.6", "eventemitter3": "^5.0.1", "tslib": "^2.5.3", "@antv/g-canvas": "2.2.0", "@antv/g-lite": "2.7.0", "@antv/g-plugin-dragndrop": "2.1.1", "@antv/g-plugin-gesture": "2.1.1" }, "devDependencies": { "@types/gl-matrix": "^2.4.5" }, "publishConfig": { "access": "public" }, "scripts": { "build:js": "rimraf dist && rollup -c", "build:types": "rimraf types && tsc --emitDeclarationOnly --noCheck", "build": "npm run build:js && npm run build:types", "sync": "tnpm sync", "watch": "rollup -c -w" } } --- package.json (entry) --- { "name": "@antv/g-mobile-canvas", "version": "1.1.1", "description": "A renderer implemented with Canvas2D API in mobile environment", "keywords": [ "antv", "g" ], "homepage": "https://github.com/antvis/g#readme", "bugs": { "url": "https://github.com/antvis/g/issues" }, "repository": { "type": "git", "url": "git+https://github.com/antvis/g.git" }, "license": "MIT", "author": "https://github.com/orgs/antvis/people", "exports": { "types": "./types/index.d.ts", "import": "./dist/index.esm.js", "default": "./dist/index.js" }, "main": "dist/index.js", "unpkg": "dist/index.umd.min.js", "module": "dist/index.esm.js", "types": "types/index.d.ts", "files": [ "package.json", "dist", "types", "LICENSE", "README.md" ], "dependencies": { "@antv/util": "^3.3.5", "@babel/runtime": "^7.25.6", "eventemitter3": "^5.0.1", "tslib": "^2.5.3", "@antv/g-canvas": "2.2.0", "@antv/g-lite": "2.7.0", "@antv/g-plugin-dragndrop": "2.1.1", "@antv/g-plugin-gesture": "2.1.1" }, "devDependencies": { "@types/gl-matrix": "^2.4.5" }, "publishConfig": { "access": "public" }, --- index.js (entry) --- /*! * @antv/g-mobile-canvas * @description A renderer implemented with Canvas2D API in mobile environment * @version 1.1.1 * @date 12/24/2025, 11:57:27 AM * @author AntVis * @docs https://g.antv.antgroup.com/ */ 'use strict'; var _createClass = require('@babel/runtime/helpers/createClass'); var _classCallCheck = require('@babel/runtime/helpers/classCallCheck'); var _callSuper = require('@babel/runtime/helpers/callSuper'); var _inherits = require('@babel/runtime/helpers/inherits'); var gLite = require('@antv/g-lite'); var gCanvas = require('@antv/g-canvas'); var DragDropEvent = require('@antv/g-plugin-dragndrop'); var GesturePlugin = require('@antv/g-plugin-gesture'); var util = require('@antv/util'); var _regeneratorRuntime = require('@babel/runtime/helpers/regeneratorRuntime'); var _asyncToGenerator = require('@babel/runtime/helpers/asyncToGenerator'); var EventEmitter = require('eventemitter3'); function _interopNamespaceDefault(e) { var n = Object.create(null); if (e) { Object.keys(e).forEach(function (k) { if (k !== 'default') { var d = Object.getOwnPropertyDescriptor(e, k); Object.defineProperty(n, k, d.get ? d : { enumerable: t --- bundled output (OSV-MAL flagged — LLM scope expansion) --- --- dist/index.esm.js (bundled) --- /*! * @antv/g-mobile-canvas * @description A renderer implemented with Canvas2D API in mobile environment * @version 1.1.1 * @date 12/24/2025, 11:57:27 AM * @author AntVis * @docs https://g.antv.antgroup.com/ */ import _createClass from '@babel/runtime/helpers/createClass'; import _classCallCheck from '@babel/runtime/helpers/classCallCheck'; import _callSuper from '@babel/runtime/helpers/callSuper'; import _inherits from '@babel/runtime/helpers/inherits'; import { AbstractRendererPlugin, AbstractRenderer, ImageLoader, MobileInteraction } from '@antv/g-lite'; import { CanvasPathGenerator, CanvasRenderer, CanvasPicker } from '@antv/g-canvas'; export { CanvasPicker, CanvasRenderer } from '@antv/g-canvas'; import * as DragDropEvent from '@antv/g-plugin-dragndrop'; import * as GesturePlugin from '@antv/g-plugin-gesture'; import { isNil } from '@antv/util'; import _regeneratorRuntime from '@babel/runtime/helpers/regeneratorRuntime'; import _asyncToGenerator from '@babel/runtime/helpers/asyncToGenerator'; import EventEmitter from 'eventemitter3'; function isCanvasElement(el) { if (!el || typeof el !== 'object') return false; if (el.nodeType === 1 && el.nodeName) { // HTMLCanvasElement return true; } // CanvasElement return !!el.isCanvasElement; } var Canvas2DContextService = /*#__PURE__*/function () { function Canvas2DContextService(context) { _classCallCheck(this, Canvas2DContextService); this.canvasConfig = context.config; } return _createClass(Canvas2DContextService, [{ key: "init", value: function () { var _init = _asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee() { var _this$canvasConfig, canvas, devicePixelRatio, dpr; return _regeneratorRuntime().wrap(function (_context) { while (1) switch (_context.prev = _context.next) { case 0: _this$canvasConfig = this.canvasConfig, canvas = _this$canvasConfig.canvas, devicePixelRatio = _this$canvas --- dist/index.js (bundled) --- /*! * @antv/g-mobile-canvas * @description A renderer implemented with Canvas2D API in mobile environment * @version 1.1.1 * @date 12/24/2025, 11:57:27 AM * @author AntVis * @docs https://g.antv.antgroup.com/ */ 'use strict'; var _createClass = require('@babel/runtime/helpers/createClass'); var _classCallCheck = require('@babel/runtime/helpers/classCallCheck'); var _callSuper = require('@babel/runtime/helpers/callSuper'); var _inherits = require('@babel/runtime/helpers/inherits'); var gLite = require('@antv/g-lite'); var gCanvas = require('@antv/g-canvas'); var DragDropEvent = require('@antv/g-plugin-dragndrop'); var GesturePlugin = require('@antv/g-plugin-gesture'); var util = require('@antv/util'); var _regeneratorRuntime = require('@babel/runtime/helpers/regeneratorRuntime'); var _asyncToGenerator = require('@babel/runtime/helpers/asyncToGenerator'); var EventEmitter = require('eventemitter3'); function _interopNamespaceDefault(e) { var n = Object.create(null); if (e) { Object.keys(e).forEach(function (k) { if (k !== 'default') { var d = Object.getOwnPropertyDescriptor(e, k); Object.defineProperty(n, k, d.get ? d : { enumerable: true, get: function () { return e[k]; } }); } }); } n.default = e; return Object.freeze(n); } var DragDropEvent__namespace = /*#__PURE__*/_interopNamespaceDefault(DragDropEvent); var GesturePlugin__namespace = /*#__PURE__*/_interopNamespaceDefault(GesturePlugin); function isCanvasElement(el) { if (!el || typeof el !== 'object') return false; if (el.nodeType === 1 && el.nodeName) { // HTMLCanvasElement return true; } // CanvasElement return !!el.isCanvasElement; } var Canvas2DContextService = /*#__PURE__*/function () { function Canvas2DContextService(context) { _classCallCheck(this, Canvas2DContextService); this.canvasConfig = context.config; } return _createClass(Canvas2DContextService, [{ key: "init", value: funct --- dist/index.umd.min.js (bundled) --- /*! * @antv/g-mobile-canvas * @description A renderer implemented with Canvas2D API in mobile environment * @version 1.1.1 * @date 12/24/2025, 11:57:27 AM * @author AntVis * @docs https://g.antv.antgroup.com/ */ !function(e,t){"object"==typeof exports&&"undefined"!=typeof module?t(exports,require("@antv/g-lite")):"function"==typeof define&&define.amd?define(["exports","@antv/g-lite"],t):t(((e="undefined"!=typeof globalThis?globalThis:e||self).G=e.G||{},e.G.MobileCanvas2D={}),e.window.G)}(this,function(e,t){"use strict";function r(e){return r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},r(e)}function n(e){var t=function(e,t){if("object"!=r(e)||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var i=n.call(e,t||"default");if("object"!=r(i))return i;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==r(t)?t:t+""}function i(e,t){for(var r=0;t.length>r;r++){var i=t[r];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(e,n(i.key),i)}}function o(e,t,r){return t&&i(e.prototype,t),r&&i(e,r),Object.defineProperty(e,"prototype",{writable:!1}),e}function a(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function s(e){return s=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},s(e)}function l(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch(e){}return(l=function(){return!!e})()}function c(e,t){if(t&&("object"==r(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been ca
