@yadsh/dsh-l10n-overrides 0.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/LICENSE ADDED
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2026 xarleyn
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
package/README.md ADDED
@@ -0,0 +1,83 @@
1
+ # dsh-l10n-overrides
2
+
3
+ [![CI](https://github.com/xarleyn/dsh-plugins/actions/workflows/ci.yml/badge.svg)](https://github.com/xarleyn/dsh-plugins/actions/workflows/ci.yml)
4
+ [![npm version](https://img.shields.io/npm/v/%40yadsh%2Fdsh-l10n-overrides.svg)](https://www.npmjs.com/package/@yadsh/dsh-l10n-overrides)
5
+ [![npm downloads](https://img.shields.io/npm/dm/%40yadsh%2Fdsh-l10n-overrides.svg)](https://www.npmjs.com/package/@yadsh/dsh-l10n-overrides)
6
+ [![Node.js](https://img.shields.io/node/v/%40yadsh%2Fdsh-l10n-overrides.svg)](package.json)
7
+ [![License: MIT](https://img.shields.io/badge/license-MIT-blue.svg)](LICENSE)
8
+
9
+ Runtime localization overrides for [DeepSeek Harness](https://github.com/deepseek-ai/deepseek-harness) plugins.
10
+
11
+ `dsh-l10n-overrides` overlays missing or incorrect locale entries without replacing the host locale service. Translation packs can also provide narrowly scoped DOM fallbacks for text and selected accessibility attributes.
12
+
13
+ [Specification](docs/SPEC.md) · [Roadmap](ROADMAP.md)
14
+
15
+ ## Installation
16
+
17
+ The package is not published yet. Build and install it from a local monorepo checkout:
18
+
19
+ ```bash
20
+ pnpm --filter @yadsh/dsh-l10n-overrides build
21
+ dsh plugin --profile web add ./plugins/dsh-l10n-overrides
22
+ ```
23
+
24
+ Once a public release is available, install it by package name:
25
+
26
+ ```bash
27
+ dsh plugin --profile web add @yadsh/dsh-l10n-overrides
28
+ ```
29
+
30
+ To remove the plugin:
31
+
32
+ ```bash
33
+ dsh plugin --profile web remove @yadsh/dsh-l10n-overrides
34
+ ```
35
+
36
+ Restart the DeepSeek Harness host if bundle hot reload does not pick up the newly installed browser client.
37
+
38
+ ## What works now
39
+
40
+ - validated and indexed translation packs;
41
+ - locale-key overlays that preserve the host locale service;
42
+ - optional package-version compatibility ranges;
43
+ - exact-match DOM fallbacks for text content;
44
+ - scoped fallbacks for `placeholder`, `title`, `aria-label`, and `alt` attributes;
45
+ - package and browser-bundle verification.
46
+
47
+ The implementation is tested, but it is not considered ready for a public release until it has real translation packs and integration coverage in a live DSH browser session. See the [roadmap](ROADMAP.md).
48
+
49
+ ## Translation packs
50
+
51
+ Packs live in `src/packs` and conform to the exported `TranslationPack` type. Each pack declares its target package, optional compatible version range, locale-key overrides, and optional exact-match DOM fallback rules.
52
+
53
+ DOM rules must use a non-empty CSS scope. They are deliberately conservative: substring and regular-expression replacements are not supported, and fallback rules only touch explicitly supported text or accessibility attributes.
54
+
55
+ ## Requirements
56
+
57
+ - Node.js `^22.19.0` or `>=24.0.0`
58
+ - pnpm 10.4.1 for development
59
+ - DeepSeek Harness `>=0.1.1-rc.2 <0.2.0`
60
+ - Cordis `^4.0.1`
61
+
62
+ ## Development
63
+
64
+ From the monorepo root:
65
+
66
+ ```bash
67
+ pnpm install --frozen-lockfile
68
+ pnpm --filter @yadsh/dsh-l10n-overrides check
69
+ ```
70
+
71
+ The package check runs formatting, type checking, tests, production builds, and package smoke checks. CI runs the same quality gate through the monorepo.
72
+
73
+ ## Releases
74
+
75
+ This package uses independent Nx Version Plans from the monorepo. Add a plan with `pnpm release:plan`; maintainers publish verified tarballs through the shared [release workflow](../../docs/RELEASING.md).
76
+
77
+ ## Contributing
78
+
79
+ Issues, translation packs, and focused pull requests are welcome. Read the monorepo [contribution guide](../../CONTRIBUTING.md) and run the package check before submitting a change.
80
+
81
+ ## License
82
+
83
+ [MIT](LICENSE). This is an independent community project and is not affiliated with or endorsed by DeepSeek.
package/ROADMAP.md ADDED
@@ -0,0 +1,35 @@
1
+ # Roadmap
2
+
3
+ ## Implemented foundation
4
+
5
+ - Translation pack contracts, validation, diagnostics, precedence, and lookup.
6
+ - Safe interpolation for named and positional placeholders.
7
+ - Reversible locale-runtime hook with shared-installation lifecycle handling.
8
+ - Scoped, exact-match DOM translation with mutation observation and restoration.
9
+ - DSH client composition and module-loader bundle generation.
10
+ - Unit, integration, build, and package smoke checks.
11
+
12
+ ## Required before the first public release
13
+
14
+ - Run an end-to-end smoke test inside a real DSH browser session, including
15
+ plugin reload and disposal.
16
+ - Harden duplicate installation under real Cordis fibers: keep locale listeners
17
+ owned per fiber, DOM translators per document, and prevent a partially drained
18
+ installation from being leased again.
19
+ - Replace the example pack with reviewed translations for actual target plugins
20
+ and record their supported version ranges.
21
+ - Verify the packed npm tarball contents and imports from a clean consumer
22
+ project, not only from the repository build output.
23
+ - Confirm compatibility against the supported DSH and locale-plugin versions.
24
+ - Document installation and enablement once the real DSH loading path is
25
+ verified.
26
+
27
+ ## Follow-up work
28
+
29
+ - Add optional settings and debug diagnostics UI.
30
+ - Support external or user-authored pack loading after defining a trust model.
31
+ - Add more target locales without changing the English-first core semantics.
32
+ - Split the DOM translation engine into smaller parsing, matching, and ownership
33
+ modules as its rule surface grows.
34
+ - Evaluate broader selector and SVG attribute support only with explicit tests;
35
+ the current HTML-oriented scope and attribute rules remain intentional.
@@ -0,0 +1,4 @@
1
+ # The DSH plugin manager discovers this bundle through package.json.
2
+ - insert:
3
+ - id: dsh-l10n-overrides
4
+ name: "@yadsh/dsh-l10n-overrides"