✨ MAJOR FEATURES: • Auto-zoom intelligence với smart bounds fitting • Enhanced 3D GPS markers với pulsing effects • Professional route display với 6-layer rendering • Status-based parking icons với availability indicators • Production-ready build optimizations 🗺️ AUTO-ZOOM FEATURES: • Smart bounds fitting cho GPS + selected parking • Adaptive padding (50px) cho visual balance • Max zoom control (level 16) để tránh quá gần • Dynamic centering khi không có selection 🎨 ENHANCED VISUALS: • 3D GPS marker với multi-layer pulse effects • Advanced parking icons với status colors • Selection highlighting với animation • Dimming system cho non-selected items 🛣️ ROUTE SYSTEM: • OpenRouteService API integration • Multi-layer route rendering (glow, shadow, main, animated) • Real-time distance & duration calculation • Visual route info trong popup 📱 PRODUCTION READY: • SSR safe với dynamic imports • Build errors resolved • Global deployment via Vercel • Optimized performance 🌍 DEPLOYMENT: • Vercel: https://whatever-ctk2auuxr-phong12hexdockworks-projects.vercel.app • Bundle size: 22.8 kB optimized • Global CDN distribution • HTTPS enabled 💾 VERSION CONTROL: • MapView-v2.0.tsx backup created • MAPVIEW_VERSIONS.md documentation • Full version history tracking
69 lines
2.0 KiB
JavaScript
69 lines
2.0 KiB
JavaScript
/**
|
|
* Find the starting index of Uint8Array `b` within Uint8Array `a`.
|
|
*/ "use strict";
|
|
Object.defineProperty(exports, "__esModule", {
|
|
value: true
|
|
});
|
|
0 && (module.exports = {
|
|
indexOfUint8Array: null,
|
|
isEquivalentUint8Arrays: null,
|
|
removeFromUint8Array: null
|
|
});
|
|
function _export(target, all) {
|
|
for(var name in all)Object.defineProperty(target, name, {
|
|
enumerable: true,
|
|
get: all[name]
|
|
});
|
|
}
|
|
_export(exports, {
|
|
indexOfUint8Array: function() {
|
|
return indexOfUint8Array;
|
|
},
|
|
isEquivalentUint8Arrays: function() {
|
|
return isEquivalentUint8Arrays;
|
|
},
|
|
removeFromUint8Array: function() {
|
|
return removeFromUint8Array;
|
|
}
|
|
});
|
|
function indexOfUint8Array(a, b) {
|
|
if (b.length === 0) return 0;
|
|
if (a.length === 0 || b.length > a.length) return -1;
|
|
// start iterating through `a`
|
|
for(let i = 0; i <= a.length - b.length; i++){
|
|
let completeMatch = true;
|
|
// from index `i`, iterate through `b` and check for mismatch
|
|
for(let j = 0; j < b.length; j++){
|
|
// if the values do not match, then this isn't a complete match, exit `b` iteration early and iterate to next index of `a`.
|
|
if (a[i + j] !== b[j]) {
|
|
completeMatch = false;
|
|
break;
|
|
}
|
|
}
|
|
if (completeMatch) {
|
|
return i;
|
|
}
|
|
}
|
|
return -1;
|
|
}
|
|
function isEquivalentUint8Arrays(a, b) {
|
|
if (a.length !== b.length) return false;
|
|
for(let i = 0; i < a.length; i++){
|
|
if (a[i] !== b[i]) return false;
|
|
}
|
|
return true;
|
|
}
|
|
function removeFromUint8Array(a, b) {
|
|
const tagIndex = indexOfUint8Array(a, b);
|
|
if (tagIndex === 0) return a.subarray(b.length);
|
|
if (tagIndex > -1) {
|
|
const removed = new Uint8Array(a.length - b.length);
|
|
removed.set(a.slice(0, tagIndex));
|
|
removed.set(a.slice(tagIndex + b.length), tagIndex);
|
|
return removed;
|
|
} else {
|
|
return a;
|
|
}
|
|
}
|
|
|
|
//# sourceMappingURL=uint8array-helpers.js.map
|