mirror of
https://github.com/maputnik/editor.git
synced 2026-01-14 01:10:01 +00:00
## Launch Checklist <!-- Thanks for the PR! Feel free to add or remove items from the checklist. --> - [x] Briefly describe the changes in this PR. - [x] Link to related issues. - [x] Include before/after visuals or gifs if this PR includes visual changes. - [ ] Write tests for all new functionality. - [x] Add an entry to `CHANGELOG.md` under the `## main` section. ## Changes - This pull request makes use of the FileSystemFileHandle API to modify a local file. No need to download it - just click save. - I don't know how to cover this functionality by tests so I need directions in case test coverage is required. - The pull request adds [@types/wicg-file-system-access](https://www.npmjs.com/package/@types/wicg-file-system-access) as a new dev dependency which I am not really pleased about but can't think of a way around it. ## Known Limitations - The used File API is only available in when accessed from https or on localhost. - There is no visual indicator that the file has been saved. Previously the browser showed it as a new download. ## Issue - https://github.com/maplibre/maputnik/issues/964 ## Screenshots ### Menu <img src="https://github.com/user-attachments/assets/dfcfc5c2-0019-4857-ba26-224b5598fc11" /> ### Open modal <img src="https://github.com/user-attachments/assets/4e1293e8-16b6-4b86-925b-3bebb49d8ca6" height="200px" /> ### Save modal <img src="https://github.com/user-attachments/assets/4f10e2c0-2dd3-4726-a613-30e0406619b0" height="200px" /> --------- Co-authored-by: Harel M <harel.mazor@gmail.com>
151 lines
4.8 KiB
JSON
151 lines
4.8 KiB
JSON
{
|
|
"name": "maputnik",
|
|
"version": "2.1.1",
|
|
"description": "A MapLibre GL visual style editor",
|
|
"type": "module",
|
|
"main": "''",
|
|
"scripts": {
|
|
"start": "vite",
|
|
"build": "tsc && vite build --base=/maputnik/",
|
|
"build-desktop": "tsc && vite build --base=/ && cd desktop && make",
|
|
"i18n:refresh": "i18next 'src/**/*.{ts,tsx,js,jsx}'",
|
|
"lint": "eslint ./src ./cypress --ext ts,tsx,js,jsx --report-unused-disable-directives --max-warnings 0",
|
|
"test": "cypress run",
|
|
"cy:open": "cypress open",
|
|
"lint-css": "stylelint \"src/styles/*.scss\"",
|
|
"sort-styles": "jq 'sort_by(.id)' src/config/styles.json > tmp.json && mv tmp.json src/config/styles.json"
|
|
},
|
|
"repository": {
|
|
"type": "git",
|
|
"url": "https://github.com/maplibre/maputnik"
|
|
},
|
|
"author": "Lukas Martinelli",
|
|
"license": "MIT",
|
|
"homepage": "https://github.com/maplibre/maputnik#readme",
|
|
"dependencies": {
|
|
"@mapbox/mapbox-gl-rtl-text": "^0.2.3",
|
|
"@maplibre/maplibre-gl-geocoder": "^1.6.0",
|
|
"@maplibre/maplibre-gl-inspect": "^1.6.3",
|
|
"@maplibre/maplibre-gl-style-spec": "^20.1.1",
|
|
"@mdi/js": "^7.4.47",
|
|
"@mdi/react": "^1.6.1",
|
|
"@typescript-eslint/eslint-plugin": "^7.3.1",
|
|
"@typescript-eslint/parser": "^7.3.1",
|
|
"array-move": "^4.0.0",
|
|
"buffer": "^6.0.3",
|
|
"classnames": "^2.5.1",
|
|
"codemirror": "^5.65.2",
|
|
"color": "^4.2.3",
|
|
"cypress-plugin-tab": "^1.0.5",
|
|
"detect-browser": "^5.3.0",
|
|
"events": "^3.3.0",
|
|
"file-saver": "^2.0.5",
|
|
"i18next": "^23.12.2",
|
|
"i18next-browser-languagedetector": "^8.0.0",
|
|
"i18next-resources-to-backend": "^1.2.1",
|
|
"json-stringify-pretty-compact": "^4.0.0",
|
|
"json-to-ast": "^2.1.0",
|
|
"jsonlint": "github:josdejong/jsonlint#85a19d7",
|
|
"lodash": "^4.17.21",
|
|
"lodash.capitalize": "^4.2.1",
|
|
"lodash.clamp": "^4.0.3",
|
|
"lodash.clonedeep": "^4.5.0",
|
|
"lodash.get": "^4.4.2",
|
|
"lodash.isequal": "^4.5.0",
|
|
"lodash.throttle": "^4.1.1",
|
|
"maplibre-gl": "^4.1.2",
|
|
"maputnik-design": "github:maputnik/design#172b06c",
|
|
"ol": "^6.14.1",
|
|
"ol-mapbox-style": "^7.1.1",
|
|
"prop-types": "^15.8.1",
|
|
"react": "^18.2.0",
|
|
"react-accessible-accordion": "^5.0.0",
|
|
"react-aria-menubutton": "^7.0.3",
|
|
"react-aria-modal": "^5.0.2",
|
|
"react-autobind": "^1.0.6",
|
|
"react-autocomplete": "^1.8.1",
|
|
"react-collapse": "^5.1.1",
|
|
"react-color": "^2.19.3",
|
|
"react-dom": "^18.2.0",
|
|
"react-file-reader-input": "^2.0.0",
|
|
"react-i18next": "^15.0.1",
|
|
"react-icon-base": "^2.1.2",
|
|
"react-icons": "^5.0.1",
|
|
"react-sortable-hoc": "^2.0.0",
|
|
"reconnecting-websocket": "^4.4.0",
|
|
"sass": "^1.72.0",
|
|
"slugify": "^1.6.6",
|
|
"string-hash": "^1.1.3",
|
|
"url": "^0.11.3"
|
|
},
|
|
"jshintConfig": {
|
|
"esversion": 6
|
|
},
|
|
"stylelint": {
|
|
"extends": "stylelint-config-recommended-scss",
|
|
"rules": {
|
|
"no-descending-specificity": null,
|
|
"media-feature-name-no-unknown": [
|
|
true,
|
|
{
|
|
"ignoreMediaFeatureNames": [
|
|
"prefers-reduced-motion"
|
|
]
|
|
}
|
|
]
|
|
}
|
|
},
|
|
"devDependencies": {
|
|
"@cypress/code-coverage": "^3.12.30",
|
|
"@istanbuljs/nyc-config-typescript": "^1.0.2",
|
|
"@rollup/plugin-replace": "^5.0.5",
|
|
"@shellygo/cypress-test-utils": "^2.1.9",
|
|
"@types/codemirror": "^5.60.15",
|
|
"@types/color": "^3.0.6",
|
|
"@types/cors": "^2.8.17",
|
|
"@types/file-saver": "^2.0.7",
|
|
"@types/geojson": "^7946.0.14",
|
|
"@types/json-to-ast": "^2.1.4",
|
|
"@types/lodash.capitalize": "^4.2.9",
|
|
"@types/lodash.clamp": "^4.0.9",
|
|
"@types/lodash.clonedeep": "^4.5.9",
|
|
"@types/lodash.get": "^4.4.9",
|
|
"@types/lodash.isequal": "^4.5.8",
|
|
"@types/lodash.throttle": "^4.1.9",
|
|
"@types/mocha": "^10.0.6",
|
|
"@types/randomcolor": "^0.5.9",
|
|
"@types/react": "^18.2.67",
|
|
"@types/react-aria-menubutton": "^6.2.14",
|
|
"@types/react-aria-modal": "^4.0.10",
|
|
"@types/react-autocomplete": "^1.8.10",
|
|
"@types/react-collapse": "^5.0.4",
|
|
"@types/react-color": "^3.0.12",
|
|
"@types/react-dom": "^18.2.22",
|
|
"@types/react-file-reader-input": "^2.0.4",
|
|
"@types/react-icon-base": "^2.1.6",
|
|
"@types/string-hash": "^1.1.3",
|
|
"@types/uuid": "^9.0.8",
|
|
"@types/wicg-file-system-access": "^2023.10.5",
|
|
"@vitejs/plugin-react": "^4.2.1",
|
|
"cors": "^2.8.5",
|
|
"cypress": "^13.13.0",
|
|
"eslint": "^8.57.0",
|
|
"eslint-plugin-react": "^7.34.1",
|
|
"eslint-plugin-react-hooks": "^4.6.0",
|
|
"eslint-plugin-react-refresh": "^0.4.6",
|
|
"i18next-parser": "^9.0.1",
|
|
"istanbul": "^0.4.5",
|
|
"istanbul-lib-coverage": "^3.2.2",
|
|
"mocha": "^10.3.0",
|
|
"postcss": "^8.4.38",
|
|
"react-hot-loader": "^4.13.1",
|
|
"stylelint": "^16.2.1",
|
|
"stylelint-config-recommended-scss": "^14.0.0",
|
|
"stylelint-scss": "^6.2.1",
|
|
"typescript": "^5.4.3",
|
|
"uuid": "^9.0.1",
|
|
"vite": "^5.4.6",
|
|
"vite-plugin-istanbul": "^6.0.0"
|
|
}
|
|
}
|