{"id":25562594,"url":"https://github.com/nobkd/replace-maps","last_synced_at":"2025-04-12T07:37:39.118Z","repository":{"id":163439086,"uuid":"616618927","full_name":"nobkd/replace-maps","owner":"nobkd","description":"Replace Google Maps iFrames with OpenStreetMap","archived":false,"fork":false,"pushed_at":"2025-04-12T01:01:55.000Z","size":1678,"stargazers_count":3,"open_issues_count":4,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-04-12T01:28:18.315Z","etag":null,"topics":["browser-extension","firefox","google-maps","leaflet-map","openstreetmap","typescript","web-ext"],"latest_commit_sha":null,"homepage":"https://addons.mozilla.org/addon/replace-maps/","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mpl-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/nobkd.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2023-03-20T18:37:25.000Z","updated_at":"2025-03-28T23:16:15.000Z","dependencies_parsed_at":"2023-11-19T04:27:39.250Z","dependency_job_id":"b32db364-aebc-4088-aa62-2a01cbd197cd","html_url":"https://github.com/nobkd/replace-maps","commit_stats":null,"previous_names":[],"tags_count":8,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nobkd%2Freplace-maps","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nobkd%2Freplace-maps/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nobkd%2Freplace-maps/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nobkd%2Freplace-maps/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/nobkd","download_url":"https://codeload.github.com/nobkd/replace-maps/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248536095,"owners_count":21120681,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["browser-extension","firefox","google-maps","leaflet-map","openstreetmap","typescript","web-ext"],"created_at":"2025-02-20T19:42:59.333Z","updated_at":"2025-04-12T07:37:39.095Z","avatar_url":"https://github.com/nobkd.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Replace Maps\n\n[\u003cimg alt=\"Light blue icon with white border. Shape is a pin for the current position on a map.\" src=\"icons/icon.svg\" width=\"128\" align=\"right\" /\u003e][link-latest-release]\n\n[![CI GitHub Workflow Status][badge-status-ci]][link-workflow-ci]\n[![MPL-2.0 License][badge-license]][link-license]\n[![Mozilla Add-on Version][badge-amo]][link-amo]\n\n**Replace Google Maps iFrames with OpenStreetMap**\n\n[!['Get Firefox Add-On'-Badge][icon-amo]][link-amo]\n\n## Capabilities\n\n- replace Google Maps embeds with Leaflet map. Using API calls to:\n  - [Nominatim Search](https://nominatim.org/release-docs/develop/api/Search/)\n  - [OSM Tiles](https://www.openstreetmap.org/)\n  - [ArcGIS World Imagery Tiles](https://server.arcgisonline.com/ArcGIS/rest/services/World_Imagery/MapServer/)\n- disable extension for hostnames\n\n## How it Works\n\nThis browser extension intercepts web requests from frames in a page.\nIf the request URL matches the syntax to a Google Maps map, the response will be replaced.\nThe search parameters of the request are decoded and converted to compatible syntax.\nAs a result, the response is an extension page that contains a [Leaflet](https://leafletjs.com/) + [OSM](https://www.openstreetmap.org/) + [ArgGIS](https://server.arcgisonline.com/ArcGIS/rest/services/World_Imagery/MapServer/) map.\n\nYou can turn the extension off for every hostname by using the browser action button or by using the settings page.\n\n### Extension Flowchart\n\n```mermaid\nflowchart TD\n\nsubgraph action [Browser Action]\nactionclick(Action Icon) --\u003e|add / remove| storage[(Disabled Hostnames)]\nsettings(Settings Page) --\u003e|add / remove| storage\nend\n\n\nsubgraph reqres [Request-Response Sytem]\n    req([Frame Request]) --\u003e url{Matches\\nGoogle Maps\\nURL?}\n    url --\u003e|no| nomatch([Continue Original Request])\n\n    url --\u003e|yes| match{Hostname\\nDisabled?}\n    storage --\u003e|provide hostnames| match\n    match --\u003e|no| res([Redirect to extension map page])\n    match --\u003e|yes| nomatch\n\nend\n\nres --\u003e|use params| params\n\nsubgraph dec [Search-Param Decoding]\n    params(Search Params) --\u003e|has q| q([readQ])\n    q --\u003e|with title| pos[Marker/s]\n    params --\u003e|has z| zoom[Zoom]\n\n    params --\u003e|has pb| pb([readPB])\n    pb --\u003e|has| minfo[Marker Info]\n    pb --\u003e|has| marea[Map Area]\n\n    minfo --\u003e|has\\nsearch string| q\n    minfo --\u003e|has\\n0x...:0x...| cid[CID]\n    cid -.-\u003e|unknown usage| pos\n    minfo --\u003e|has\\nDMS coords| dms([parseDMS])\n    dms --\u003e pos\n\n    pb --\u003e|has| mtype[Map Type]\n\n    marea --\u003e|has\\ncoords| mcoords[Map Coords]\n    marea --\u003e|has\\naltitude| mzoom([getMapZoom])\n    mzoom --\u003e zoom\n\n    pos --\u003e mdata[(Map Data)]\n    mtype --\u003e mdata\n    mcoords --\u003e mdata\n    zoom --\u003e mdata\nend\n\nmdata --\u003e|use map data| mview([Load Leaflet Map])\n```\n\n### Known issues\n\n- Sometimes the zoom level is completely wrong\n- Not working when a website does not use an iFrame / embed\n- Not working when iFrame uses only CIDs\n- No routes, just positions\n- If insufficient information is gathered, the map stays blank\n\n\u003c!-- Badges \u0026 Links --\u003e\n[badge-license]: https://img.shields.io/github/license/nobkd/replace-maps\n[badge-amo]: https://img.shields.io/amo/v/replace-maps\n[badge-status-ci]: https://img.shields.io/github/actions/workflow/status/nobkd/replace-maps/ci.yml?label=ci\n\n[icon-logo]: icons/icon.svg\n[icon-amo]: icons/get-firefox-addon.svg\n\n[link-license]: LICENSE\n[link-latest-release]: https://github.com/nobkd/replace-maps/releases/latest\n[link-workflow-ci]: https://github.com/nobkd/replace-maps/actions/workflows/ci.yml\n[link-amo]: https://addons.mozilla.org/addon/replace-maps/\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnobkd%2Freplace-maps","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fnobkd%2Freplace-maps","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnobkd%2Freplace-maps/lists"}