✨ 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
57 lines
1.5 KiB
TypeScript
57 lines
1.5 KiB
TypeScript
/**
|
||
* Generate secure URL-friendly unique ID. The non-blocking version.
|
||
*
|
||
* By default, the ID will have 21 symbols to have a collision probability
|
||
* similar to UUID v4.
|
||
*
|
||
* ```js
|
||
* import { nanoid } from 'nanoid/async'
|
||
* nanoid().then(id => {
|
||
* model.id = id
|
||
* })
|
||
* ```
|
||
*
|
||
* @param size Size of the ID. The default size is 21.
|
||
* @returns A promise with a random string.
|
||
*/
|
||
export function nanoid(size?: number): Promise<string>
|
||
|
||
/**
|
||
* A low-level function.
|
||
* Generate secure unique ID with custom alphabet. The non-blocking version.
|
||
*
|
||
* Alphabet must contain 256 symbols or less. Otherwise, the generator
|
||
* will not be secure.
|
||
*
|
||
* @param alphabet Alphabet used to generate the ID.
|
||
* @param defaultSize Size of the ID. The default size is 21.
|
||
* @returns A function that returns a promise with a random string.
|
||
*
|
||
* ```js
|
||
* import { customAlphabet } from 'nanoid/async'
|
||
* const nanoid = customAlphabet('0123456789абвгдеё', 5)
|
||
* nanoid().then(id => {
|
||
* model.id = id //=> "8ё56а"
|
||
* })
|
||
* ```
|
||
*/
|
||
export function customAlphabet(
|
||
alphabet: string,
|
||
defaultSize?: number
|
||
): (size?: number) => Promise<string>
|
||
|
||
/**
|
||
* Generate an array of random bytes collected from hardware noise.
|
||
*
|
||
* ```js
|
||
* import { random } from 'nanoid/async'
|
||
* random(5).then(bytes => {
|
||
* bytes //=> [10, 67, 212, 67, 89]
|
||
* })
|
||
* ```
|
||
*
|
||
* @param bytes Size of the array.
|
||
* @returns A promise with a random bytes array.
|
||
*/
|
||
export function random(bytes: number): Promise<Uint8Array>
|