Bumps [i18next-cli](https://github.com/i18next/i18next-cli) from 1.77.0 to 1.80.0. <details> <summary>Changelog</summary> <p><em>Sourced from <a href="https://github.com/i18next/i18next-cli/blob/main/CHANGELOG.md">i18next-cli's changelog</a>.</em></p> <blockquote> <h2>1.80.0</h2> <ul> <li>feat(lint): in the i18next format, the translation files of every locale are compared with the primary language: interpolations by name (<code>{{name}}</code>, <code>{{- name}}</code>, <code>{{val, number}}</code>), nested <code>$t(key)</code> references and tags (<code><0></code>, <code><1/></code>, <code><bold></code>), except the basic HTML react-i18next keeps (<code>transKeepBasicHtmlNodesFor</code>). A translation that renamed or dropped a placeholder is reported with file, key and line, e.g. <code>greeting: missing {{name}}, unexpected {{nom}} (compared with "en")</code>. Plural forms are compared as a group, so <code>{{count}}</code> may be left out of <code>_one</code> or <code>_zero</code>. A warning by default, so existing CI runs keep passing; <code>lint.checkTranslationPlaceholders: 'error'</code> fails the run, <code>'off'</code> disables it. Until now only ICU and MF2 projects had this check.</li> <li>feat(status): values identical to the primary language (English copied into <code>de</code>) are marked <code>≈ (identical to en)</code> and counted in the summary. <code>status.checkIdentical</code>: <code>'warn'</code> (default) still counts them as translated and keeps the exit code, <code>'error'</code> counts them as untranslated, <code>'off'</code> disables it. Locales of the primary's language (<code>en-GB</code> with <code>en</code>), values without letters, URLs, e-mail addresses and short all-caps words (<code>OK</code>, <code>FAQ</code>) are skipped; other values that stay the same go into <code>status.ignoreKeys</code>.</li> <li>feat(lint): <code>lint --update-baseline</code> writes the current issues to <code>i18next-lint-baseline.json</code> (<code>lint.baseline</code> for another path). While the file exists, <code>lint</code> reports and fails only on new issues, so a codebase with existing hardcoded strings can run <code>lint</code> in CI. Issues are matched by file, type and text, not by line.</li> <li>fix(lint): interpolations are read like i18next does. The unescaped <code>{{-name}}</code> was read as a parameter <code>-name</code>, so <code>t('Hi {{-name}}', { name })</code> reported two false interpolation issues; <code>{{- name}}</code> and names outside <code>[A-Za-z0-9_.-]</code> (<code>{{größe}}</code>) were not read at all.</li> <li>docs(types): <code>transKeepBasicHtmlNodesFor</code> defaults to react-i18next's <code>['br', 'strong', 'i', 'p']</code>.</li> <li>docs(skill, localize): after translating by hand, run <code>lint</code> to check the placeholders.</li> </ul> <h2>1.79.1</h2> <ul> <li>fix(init, migrate-config): the default source glob includes <code>.mjs</code> (<code>src/**/*.{js,jsx,mjs,ts,tsx}</code>), in <code>init</code>, in the config detected for a project without one, and in <code>migrate-config</code> when the old config has no <code>input</code>. Existing configs do not change. <a href="https://redirect.github.com/i18next/i18next-cli/pull/309#issuecomment-6310275918">#309</a></li> </ul> <h2>1.79.0</h2> <ul> <li>feat(extract, instrument, lint): a <code>.mjs</code> file with JSX is parsed with the same JSX fallback as a <code>.js</code> file, including the constants pre-scan of <code>extract</code>. Before, it failed with a syntax error and <code>extract</code> exited with 1. <a href="https://redirect.github.com/i18next/i18next-cli/pull/309">#309</a></li> </ul> <h2>1.78.0</h2> <ul> <li>feat(lint): with <code>messageFormat: 'mf2'</code>, <code>lint</code> warns when whitespace at the start or end of a pattern differs from the primary language. MF2 keeps a space inside <code>{{ }}</code> as text, so <code>{{ {$count} files}}</code> shows it in the app. A warning does not fail the run.</li> <li>fix(lint): a language code with <code>_</code> (<code>ru_RU</code>, <code>pt_BR</code>) is read as <code>ru-RU</code>, <code>pt-BR</code> for the plural categories. Before, <code>Intl</code> rejected it and only <code>other</code> was required, so a <code>ru_RU</code> plural with only <code>one</code> and <code>other</code> passed.</li> <li>fix(lint): the required plural categories are <code>other</code> plus every category a whole number below one million selects (was 0 to 1000), the same rule as Locize; exact selectors count for a category only when it selects a few small numbers. No locale's result changes with today's CLDR data.</li> <li>docs(skill): the ICU and MF2 reference names the common MF2 plural mistakes: <code>other</code> instead of <code>*</code>, <code>{{ {$count}</code> instead of <code>{{{$count}</code>, and spaces inside <code>{{ }}</code>.</li> </ul> </blockquote> </details> <details> <summary>Commits</summary> <ul> <li><a href="https://github.com/i18next/i18next-cli/commit/6a339b2ab661cc4465b46f5276c448e2e44287b2"><code>6a339b2</code></a> 1.80.0</li> <li><a href="https://github.com/i18next/i18next-cli/commit/3f5ffd91fdc458fb0c0be086a5f6cf9e75c6a084"><code>3f5ffd9</code></a> feat(lint, status): placeholders across locales, identical values, lint baseline</li> <li><a href="https://github.com/i18next/i18next-cli/commit/73b085de457bcf6ffd9b868f2c5d71cc55c5dfb6"><code>73b085d</code></a> 1.79.1</li> <li><a href="https://github.com/i18next/i18next-cli/commit/f479d53ac90ade3d7e7dc71313fd9f79b0e198c4"><code>f479d53</code></a> fix(init, migrate-config): include .mjs in the default source glob</li> <li><a href="https://github.com/i18next/i18next-cli/commit/ee7b1aa652ec89fab53f8d2b3f74e23910b91099"><code>ee7b1aa</code></a> 1.79.0</li> <li><a href="https://github.com/i18next/i18next-cli/commit/7c95544e98d6732f816a0c724d5e9816e25a31b5"><code>7c95544</code></a> fix(extract): JSX fallback for .mjs in the constants pre-scan too</li> <li><a href="https://github.com/i18next/i18next-cli/commit/d320c6aad9d3d5f21907281406963a1852ece7a4"><code>d320c6a</code></a> feat(extract, instrument, lint): support .mjs files with JSX (<a href="https://redirect.github.com/i18next/i18next-cli/issues/309">#309</a>)</li> <li><a href="https://github.com/i18next/i18next-cli/commit/20524b8fe98937c79859cad42658f40709304bde"><code>20524b8</code></a> 1.78.0</li> <li><a href="https://github.com/i18next/i18next-cli/commit/462ed40b05e2b9637d56efcce9c850a287312a3d"><code>462ed40</code></a> feat(lint): MF2 pattern-edge whitespace warning, <code>_</code> language codes, plural r...</li> <li>See full diff in <a href="https://github.com/i18next/i18next-cli/compare/v1.77.0...v1.80.0">compare view</a></li> </ul> </details> <br /> [](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores) Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting `@dependabot rebase`. [//]: # (dependabot-automerge-start) [//]: # (dependabot-automerge-end) --- <details> <summary>Dependabot commands and options</summary> <br /> You can trigger Dependabot actions by commenting on this PR: - `@dependabot rebase` will rebase this PR - `@dependabot recreate` will recreate this PR, overwriting any edits that have been made to it - `@dependabot show <dependency name> ignore conditions` will show all of the ignore conditions of the specified dependency - `@dependabot ignore this major version` will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself) - `@dependabot ignore this minor version` will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself) - `@dependabot ignore this dependency` will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself) </details> Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Maputnik
A free and open visual editor for the MapLibre GL styles targeted at developers and map designers.
Usage
- 🔗 Design your maps online at https://www.maplibre.org/maputnik/ (all in local storage)
- 🔗 Use the Maputnik CLI for local style development
- In a Docker, run this command and browse to http://localhost:8888, Ctrl+C to stop the server.
docker run -it --rm -p 8888:8000 ghcr.io/maplibre/maputnik:main
To see the CLI options (for example file watching or style serving) run:
docker run -it --rm -p 8888:8000 ghcr.io/maplibre/maputnik:main --help
You might need to mount a volume (-v) to be able to use these options.
Documentation
The documentation can be found in the Wiki. You are welcome to collaborate!
- 🔗 Study the Maputnik Wiki
- 📹 Design a map from Scratch https://youtu.be/XoDh0gEnBQo
Develop
Maputnik is written in typescript and is using React and MapLibre GL JS.
We ensure building and developing Maputnik works with the current active LTS Node.js version and above.
Check out our Internationalization guide for UI text related changes.
Getting Involved
Join the #maplibre or #maputnik slack channel at OSMUS: get an invite at https://slack.openstreetmap.us/ Read the the below guide in order to get familiar with how we do things around here.
Install the deps, start the dev server and open the web browser on http://localhost:8888/.
# install dependencies
npm install
# start dev server
npm run start
If you want Maputnik to be accessible externally use the --host option:
# start externally accessible dev server
npm run start -- --host 0.0.0.0
The build process will watch for changes to the filesystem, rebuild and autoreload the editor.
npm run build
Lint the JavaScript code.
# run linter
npm run lint
npm run lint-css
npm run sort-styles
Tests
End-to-end tests
For E2E testing we use Playwright. The tests live in the e2e directory and drive the app through the MaputnikDriver page object.
The first time you run the tests, install the browser:
npx playwright install chromium
Playwright automatically starts the dev server (npm run start) for you, so you can just run:
npm run test
Some useful options:
# see the tests run in a headed browser
npm run test -- --headed
# run a single spec / filter by title
npm run test -- e2e/map.spec.ts
npm run test -- -g "zoom level"
# open the interactive UI mode
npx playwright test --ui
Running the E2E tests also produces a code-coverage report in coverage/ (collected via istanbul instrumentation of the dev server).
Unit & component tests
Unit tests and component tests run with Vitest; component tests (*.browser.test.tsx) use Vitest's browser mode with the Playwright provider.
npm run test-unit
Release process
- Review
CHANGELOG.md- Double-check that all changes included in the release are appropriately documented.
- To-be-released changes should be under the "main" header.
- Commit any final changes to the changelog.
- Run Create bump version PR by manual workflow dispatch and set the version number in the input. This will create a PR that changes the changelog and
package.jsonfile to review and merge. - Once merged, an automatic process will kick in and creates a GitHub release and uploads release assets.
Sponsors
Thanks to the supporters of the Kickstarter campaign. This project would not be possible without these commercial and individual sponsors. You can see this file's history for previous sponsors of the original Maputnik repo. Read more about the MapLibre Sponsorship Program at https://maplibre.org/sponsors/.
License
Maputnik is licensed under MIT and is Copyright (c) Lukas Martinelli and Maplibre contributors. As contributor please take extra care of not violating any Mapbox trademarks. Do not get inspired by other map studios and make your own decisions for a good style editor.
