Skip to content

Commit

Permalink
chore: 版本依赖
Browse files Browse the repository at this point in the history
  • Loading branch information
象数 committed Jan 9, 2025
1 parent 6c31336 commit 8ed9d03
Show file tree
Hide file tree
Showing 5 changed files with 9 additions and 107 deletions.
4 changes: 3 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -79,6 +79,7 @@
"@commitlint/cli": "^19.2.1",
"@commitlint/config-conventional": "^19.1.0",
"@types/jest": "^29.5.1",
"@types/lodash": "^4.17.14",
"@types/offscreencanvas": "^2019.7.0",
"@types/pixelmatch": "^5.2.5",
"@types/pngjs": "^6.0.3",
Expand All @@ -87,7 +88,7 @@
"babel-plugin-transform-import-css-l7": "^0.0.6",
"case-police": "^0.6.1",
"cross-env": "^7.0.2",
"eslint": "^8.54.0",
"eslint": "^9.17.0",
"eslint-config-prettier": "^9.1.0",
"eslint-plugin-jest": "^27.9.0",
"eslint-plugin-jsx-a11y": "^6.8.0",
Expand Down Expand Up @@ -117,6 +118,7 @@
"stylelint": "^16.3.0",
"stylelint-config-standard": "^36.0.0",
"stylelint-declaration-block-no-ignored-properties": "^2.8.0",
"swr": "^2.2.5",
"terminate": "latest",
"ts-jest": "^29.1.1",
"ts-node": "^10.9.2",
Expand Down
4 changes: 4 additions & 0 deletions packages/core/src/services/asset/FontService.ts
Original file line number Diff line number Diff line change
Expand Up @@ -241,9 +241,11 @@ export default class FontService extends EventEmitter implements IFontService {

// 3. layout characters
if (sdf) {
// @ts-ignore
const tinySDF = new TinySDF(fontSize, buffer, radius, cutoff, fontFamily, fontWeight);
// used to store distance values from tinySDF
// tinySDF.size equals `fontSize + buffer * 2`
// @ts-ignore
const imageData = ctx.getImageData(0, 0, tinySDF.size, tinySDF.size);
for (const char of characterSet) {
if (iconfont) {
Expand All @@ -254,8 +256,10 @@ export default class FontService extends EventEmitter implements IFontService {

const icon = String.fromCharCode(parseInt(char.replace('&#x', '').replace(';', ''), 16));
const iconData = tinySDF.draw(icon);
// @ts-ignore
populateAlphaChannel(iconData, imageData);
} else {
// @ts-ignore
populateAlphaChannel(tinySDF.draw(char), imageData);
}
// populateAlphaChannel(tinySDF.draw(char), imageData);
Expand Down
1 change: 1 addition & 0 deletions packages/utils/src/color.ts
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
// @ts-ignore
import * as d3 from 'd3-color';
import type { Context } from 'vm';
export interface IColorRamp {
Expand Down
106 changes: 0 additions & 106 deletions site/.dumi/theme/plugin.ts

This file was deleted.

1 change: 1 addition & 0 deletions site/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,7 @@
"geojson2svg": "^1.3.3",
"geotiff": "^2.0.7",
"lerc": "^3.0.0",
"swr": "^2.3.0",
"lodash-es": "^4.17.21",
"pbf": "^3.2.1",
"pmtiles": "^2.7.2",
Expand Down

0 comments on commit 8ed9d03

Please sign in to comment.