feat(loader): real Natural Earth globe via d3-geo + topojson + world-atlas
Per user — GlobeLoader должен показывать реальные континенты (Asia/Africa/ Australia outline) с rotating orthographic projection, как в прототипе Downloads/Globe loader/Globe Loader.html. Прошлая версия использовала faked ellipses graticule — выглядело как абстрактные кольца, не как глобус. Implementation: - d3-geo.geoOrthographic + d3.geoPath для projection math - topojson-client.feature для распаковки world-atlas land-110m - dynamic import обоих deps + JSON — не блокирует main bundle, lazy chunk - requestAnimationFrame loop пересчитывает d-attr на каждом кадре (8s per revolution per прототип, tilt -15° lean) - LAND_CACHE module-level — повторные mount'ы не re-fetch - CSS .globe-sphere rotation удалена — d3 projection делает работу, CSS transform distort'ила бы land mass (нет projection math) Bundle hit: ~55kb (land-110m.json) + ~15kb gzipped (d3-geo + topojson) — lazy chunk, fetched один раз и cached.
This commit is contained in:
@@ -31,6 +31,7 @@
|
||||
"class-variance-authority": "^0.7.1",
|
||||
"clsx": "^2.1.1",
|
||||
"d3-force": "^3.0.0",
|
||||
"d3-geo": "^3.1.1",
|
||||
"i18next": "^26.0.3",
|
||||
"i18next-browser-languagedetector": "^8.0.2",
|
||||
"leaflet": "^1.9.4",
|
||||
@@ -44,7 +45,9 @@
|
||||
"react-oidc-context": "^3.3.1",
|
||||
"sonner": "^2.0.7",
|
||||
"tailwind-merge": "^3.6.0",
|
||||
"tw-animate-css": "^1.4.0"
|
||||
"topojson-client": "^3.1.0",
|
||||
"tw-animate-css": "^1.4.0",
|
||||
"world-atlas": "^2.0.2"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@semantic-release/changelog": "^6.0.3",
|
||||
@@ -59,9 +62,12 @@
|
||||
"@testing-library/react": "^16.3.2",
|
||||
"@testing-library/user-event": "^14.6.1",
|
||||
"@types/d3-force": "^3.0.10",
|
||||
"@types/d3-geo": "^3.1.0",
|
||||
"@types/geojson": "^7946.0.16",
|
||||
"@types/leaflet": "^1.9.21",
|
||||
"@types/react": "^19.0.0",
|
||||
"@types/react-dom": "^19.0.0",
|
||||
"@types/topojson-client": "^3.1.5",
|
||||
"@vitejs/plugin-react": "^4.3.4",
|
||||
"conventional-changelog-conventionalcommits": "^9.3.1",
|
||||
"jsdom": "^29.1.1",
|
||||
|
||||
Reference in New Issue
Block a user