Commit Graph

354 Commits

Author SHA1 Message Date
gnezim 7ec76486ec Clean up build warnings: MF DTS, autoprefixer color-adjust, dev CORS
Three non-fatal warnings surfaced by the Jenkins build log, fixed in
the config layer:

- module-federation.config.ts: dts: false. The @module-federation/
  dts-plugin fails under our strict tsconfig and logs TYPE-001 every
  build. Remote types are not needed at runtime; consumers generate
  their own via their dev toolchain.

- src/styles/_layout.scss: color-adjust → print-color-adjust. The
  unprefixed color-adjust shorthand is deprecated; the standard name
  is print-color-adjust. Matches the -webkit- prefixed sibling.

- modern.config.ts: tools.devServer.headers explicitly set. MF warns
  when devServer.headers is empty and auto-assigns '*'. Providing an
  explicit allowlist silences the banner in dev builds; production
  behavior is unaffected (real reverse proxy manages CORS).
2026-04-17 18:11:04 +03:00
gnezim bf873bb6f6 Add project .mcp.json to enable Chromium sandbox for Playwright MCP
Playwright MCP v0.0.70 defaults to launching Chrome with --no-sandbox
because its sandbox-inference code in playwright-core mcp/config.js
only sets the default when browser.browserName is explicitly 'chromium';
the MCP leaves it undefined, so the default-to-true branch is skipped
and Playwright core pushes --no-sandbox into chromeArguments.

Chrome surfaces this as a yellow warning bar on every Playwright-driven
tab. Setting PLAYWRIGHT_MCP_SANDBOX=true via the MCP server env forces
chromiumSandbox=true, which skips the --no-sandbox push and removes the
warning. The override is scoped to this project; the plugin's own
.mcp.json is unchanged.
2026-04-17 17:30:02 +03:00
gnezim 2ae59d2074 Propagate Modern.js publicDir assets through sync + Docker build
The config/public/ directory (fonts, images, leaflet icons, favicons) is
Modern.js's publicDir convention — copied into dist/standalone/public/ at
build time. Two pre-existing gaps caused this to break on the deployed
SSR image and any fresh sync:

- scripts/sync-to-flights-front.sh did not copy config/ to the target
  repo, so the flights-front tree was missing /assets/** entirely.
- Dockerfile.react only copied src/, skipping config/; pnpm
  build:standalone ran without a publicDir source.

Result was that every /assets/** URL served the SSR HTML index with
Content-Type: text/html, producing OTS font-parse errors
(sfntVersion 1008821359 == '<!DT') and silently broken images.

Fix mirrors what was applied ad-hoc in Aeroflot.Flights.Front; this makes
future syncs and Docker builds carry the assets automatically.
2026-04-17 17:18:51 +03:00
gnezim 10dfc8609d Revert API_BASE_URL default: keep same-origin proxy for client-side CORS
Commit e20ef94 set the default to https://flights.test.aeroflot.ru/api,
which broke the browser client (no CORS headers on the test env;
scripts/dev-server.mjs is the only layer that can bypass it).

Keep PROD_ORIGIN pointing at the test env for SEO, but restore
API_BASE_URL default to http://localhost:8080/api with a comment
explaining the proxy chain: dev → Express+curl → flights.test.aeroflot.ru.
Production deployments continue to set API_BASE_URL explicitly.
2026-04-17 15:46:34 +03:00
gnezim e20ef940f8 Default API_BASE_URL and PROD_ORIGIN to the test environment
Previously API_BASE_URL defaulted to http://localhost:8080/api, which
only works inside the dev server proxy. For standalone/SSR runs without
the proxy, the default now points to https://flights.test.aeroflot.ru.

Dev continues to use the same-origin proxy because scripts/dev-server.mjs
explicitly injects API_BASE_URL=http://localhost:8080/api into the
Modern.js child process env, keeping browser fetches CORS/WAF safe.
2026-04-17 15:31:03 +03:00
gnezim 896e6bd83d Switch filter time-selector to Angular compact layout 2026-04-17 15:16:49 +03:00
gnezim 373f049e90 Use CityAutocomplete for FlightsMapFilter with geolocate on departure 2026-04-17 15:13:20 +03:00
gnezim b8d5de6ca7 Use CityAutocomplete for OnlineBoardFilter Route tab departure + arrival 2026-04-17 15:11:47 +03:00
gnezim ba302c6b03 Add CityAutocomplete composite with clear and regional-picker trigger 2026-04-17 15:06:46 +03:00
gnezim 419b4b8df1 Add CityPickerPopup with regional tabs and country/city grid 2026-04-17 15:03:39 +03:00
gnezim 6820a11e83 Add buildCountryCityRows helper for regional picker grid 2026-04-17 15:02:04 +03:00
gnezim aa7433b50b Add CityAutocomplete + regional picker implementation plan
Seven TDD tasks: buildCountryCityRows helper, CityPickerPopup with
regional tabs + grid, CityAutocomplete composite with popup trigger,
OnlineBoardFilter Route tab integration, FlightsMapFilter integration
with geolocate, time-selector compact view, final verification.
2026-04-17 14:58:05 +03:00
gnezim 0534b373f0 Add design spec for CityAutocomplete + regional picker parity
Cross-feature Angular-parity component: composite CityAutocomplete
(typeahead + clear + regional-picker trigger button) + CityPickerPopup
(regional tabs + country/city grid + optional GPS) + pure
buildCountryCityRows helper. Consumers: OnlineBoardFilter Route tab
and FlightsMapFilter. Time-selector switches to compact view in both.
2026-04-17 14:25:52 +03:00
gnezim c4ae1ef7aa Invoke useGeolocationDefault on FlightsMapStartPage mount 2026-04-17 12:22:29 +03:00
gnezim 0c65755553 Test FlightsMapFilter Calendar min/max/disabledDates + snap effect 2026-04-17 12:21:13 +03:00
gnezim 78b3e86418 Wire availableDays into FlightsMapFilter Calendar with snap-to-nearest 2026-04-17 12:20:37 +03:00
gnezim 73a3d03469 Add useGeolocationDefault hook for flights-map departure pre-fill 2026-04-17 12:17:11 +03:00
gnezim ef04c19e13 Add calendarRange helpers for flights-map date picker window and snapping 2026-04-17 12:16:22 +03:00
gnezim 5a18e86bec Add Flights Map C.5 implementation plan
Six TDD tasks: calendarRange pure helpers, useGeolocationDefault hook,
FlightsMapFilter Calendar wiring (minDate/maxDate/disabledDates + snap
effect), Calendar prop capture tests, FlightsMapStartPage geolocation
hook call, final verification.
2026-04-17 12:13:50 +03:00
gnezim 9ee9c6b089 Add design spec for Flights Map C.5 (Calendar + Geolocation)
Final C-gap sub-feature: calendarRange pure helpers
(getMinDate/getMaxDate/buildDisabledDates/findNextEnabledDate), snap-to-
nearest-enabled effect in FlightsMapFilter, and useGeolocationDefault
hook that pre-fills departure from browser position on mount when no
dep/arr is already set.
2026-04-17 12:07:48 +03:00
gnezim f4b96b8248 Test FlightsMapStartPage filterRoutes + popups + auto-fallback wiring 2026-04-17 11:06:16 +03:00
gnezim 4e92e79a99 Wire filterRoutes, auto-fallback, and buy-ticket popups into Flights Map
routesToPolylines + intermediateCityIds now normalize airport codes to city
codes via the dictionaries so API responses resolve correctly. The page adds
effectiveConnections state + two effects for Angular-parity fallback
(retry connections=1 on empty direct-route result, then flip the UI toggle),
a filterRoutes memo feeding polylines and intermediateIds, and a popups memo
rendering departure + arrival buy-ticket popups in route mode only.
2026-04-17 11:00:40 +03:00
gnezim 77272423c1 Add buildBuyTicketUrl + escapeHtml helpers for popup content 2026-04-17 10:52:32 +03:00
gnezim 40f170f87a Add filterRoutes pure helper with airport-code normalization 2026-04-17 10:52:27 +03:00
gnezim 5225df0dd1 Add Flights Map C.4 implementation plan
Six TDD tasks covering filterRoutes, buildBuyTicketUrl + escapeHtml,
routesToPolylines airport-code normalization, FlightsMapStartPage wiring
(effectiveConnections + auto-fallback effects, filteredRoutes + popups
memos), integration tests, and final verification.
2026-04-17 10:48:02 +03:00
gnezim 299b0285b0 Add design spec for Flights Map C.4 (Popups + Filtering + Fallback)
Covers the final four Angular-parity gaps: filterRoutes pure helper,
buildBuyTicketUrl + escapeHtml, routesToPolylines/intermediateCityIds
airport→city normalization, and FlightsMapStartPage wiring for the
auto-fallback effect plus departure/arrival buy-ticket popups.
2026-04-17 10:43:24 +03:00
gnezim 76e9270f5e Test FlightsMapStartPage polyline + intermediateIds wiring 2026-04-17 10:14:06 +03:00
gnezim 4e103d8073 Drive polylines and intermediateIds from useFlightsMapSearch routes 2026-04-17 10:12:15 +03:00
gnezim a9ed92466f Draw routes as city-code polylines and force-open intermediate tooltips
- routesToPolylines + intermediateCityIds pure helpers with unit coverage.
- IMapPolyline reshaped from points to cityIds for Angular-parity drawing.
- MapCanvas resolves coords via markerIndex, filters invisible cities on
  every zoom/toggle change, and runs a second tooltip pass that keeps
  intermediate-city tooltips open regardless of zoom/highlight rules.
2026-04-17 10:08:44 +03:00
gnezim 514bae6051 Add Flights Map C.3 implementation plan
Six TDD tasks covering the routes-to-polylines pure helper, IMapPolyline
reshape to cityIds, MapCanvas polyline sync with visibility filtering,
intermediate-tooltip force-open pass, page wiring, and integration tests.
Tasks 1-3 share a commit due to coupling between type and consumer.
2026-04-17 10:00:48 +03:00
gnezim a23513045b Add design spec for Flights Map C.3 (Route + Spider Drawing)
Covers the polyline layer: routesToPolylines pure function, city-code-
based IMapPolyline shape, MapCanvas polyline sync via markerIndexRef
with visibility filtering, intermediate-city tooltip force-open pass.
2026-04-17 09:53:21 +03:00
gnezim a9b47036b5 Test FlightsMapStartPage marker construction from dictionaries 2026-04-17 08:46:43 +03:00
gnezim 1f24ee7159 Populate FlightsMapStartPage markers from dictionaries with zoom tiers 2026-04-17 08:44:40 +03:00
gnezim 725a048315 Add categorized rendering to MapCanvas: zoom-tier layers, highlight layer, tooltip rules 2026-04-17 08:41:42 +03:00
gnezim 855a7c31e6 Fix POPULATION_1KK size in C.2 spec: Angular source has 30 entries, not 29 2026-04-17 08:36:08 +03:00
gnezim 54f9282a99 Extend IMapMarker with zoomLevel, countryType, highlighted fields 2026-04-17 08:35:27 +03:00
gnezim a61457bc90 Port Angular CityCategoryService to feature-local cityCategory module 2026-04-17 08:35:01 +03:00
gnezim 43f251e177 Add Flights Map C.2 implementation plan
Six TDD tasks: cityCategory port, IMapMarker extension, MapCanvas
10-layer rendering + highlight + tooltip rules (with a fresh Leaflet
mock), FlightsMapStartPage marker wiring, integration tests, final
verification.
2026-04-17 08:32:32 +03:00
gnezim 13bb96fdec Add design spec for Flights Map C.2 (Markers + Zoom Tiers)
Captures the markers-from-dictionaries + zoom-visibility scope:
cityCategory.ts port, IMapMarker extension, MapCanvas 10-LayerGroup
bookkeeping, highlighted-layer, domestic/international toggles, and
the Angular-parity tooltip visibility rules.
2026-04-17 08:27:38 +03:00
gnezim 9a7fcba6ff Test FlightsMapStartPage dictionaries loading/error wiring 2026-04-17 03:21:39 +03:00
gnezim cfc6e12dc9 Wire useDictionaries into FlightsMapStartPage loading/error states 2026-04-17 03:20:01 +03:00
gnezim 03a720179c Expose dictionaries module barrel 2026-04-17 03:18:35 +03:00
gnezim 715b09fd18 Add useDictionaries hook wiring api + transform 2026-04-17 03:16:42 +03:00
gnezim e575c1baa1 Add dictionary lookup helpers and findCityByCoord 2026-04-17 03:14:28 +03:00
gnezim 64dd5421e2 Cover enrichment, lookup-map, and region ordering in transform tests 2026-04-17 03:13:46 +03:00
gnezim e5b49acecf Add dictionaries transform with filtering and partitioning rules 2026-04-17 03:13:18 +03:00
gnezim dc373553d2 Add fetchDictionaries parallel-fetch layer 2026-04-17 03:10:26 +03:00
gnezim da605f0576 Add Flights Map dictionaries type module 2026-04-17 03:09:39 +03:00
gnezim 9f8a3a45f0 Add Flights Map C.1 implementation plan and updated spec
Spec: narrows useCityName handling (leave untouched due to active
consumers). Plan: 10 TDD tasks covering types, api, transform rules,
helpers, hook, barrel, page wiring, and regression tests.
2026-04-17 03:07:30 +03:00
gnezim 397dc2a575 Add design spec for Flights Map C.1 (Dictionaries)
Captures the data-layer scope for the flights-map rebuild: useDictionaries
hook, parallel fetch of world_regions/countries/cities/airports, transform
rules matching Angular DictionariesService, and the testing contract.
2026-04-17 02:51:22 +03:00