extension-develop 4.0.29 → 4.0.32
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/README.md +5 -5
- package/dist/0~rspack-config.mjs +137 -64
- package/dist/101.mjs +50 -42
- package/dist/extension-js-devtools/chrome/content_scripts/content-0.js +1 -1
- package/dist/extension-js-devtools/chrome/pages/welcome.js +1 -1
- package/dist/extension-js-devtools/chromium/content_scripts/content-0.js +1 -1
- package/dist/extension-js-devtools/chromium/pages/welcome.js +1 -1
- package/dist/extension-js-devtools/edge/content_scripts/content-0.js +1 -1
- package/dist/extension-js-devtools/edge/pages/welcome.js +1 -1
- package/dist/extension-js-devtools/firefox/content_scripts/content-0.js +1 -1
- package/dist/extension-js-devtools/firefox/pages/welcome.js +1 -1
- package/dist/plugin-compilation/env.d.ts +6 -0
- package/dist/plugin-web-extension/feature-manifest/manifest-lib/legacy-paths.d.ts +26 -0
- package/dist/plugin-web-extension/feature-manifest/messages.d.ts +1 -1
- package/dist/plugin-web-extension/feature-manifest/steps/legacy-warnings.d.ts +1 -0
- package/dist/plugin-web-extension/feature-manifest/steps/update-manifest.d.ts +1 -0
- package/package.json +1 -1
|
@@ -7,3 +7,9 @@ export declare class EnvPlugin {
|
|
|
7
7
|
constructor(options: Partial<PluginInterface>);
|
|
8
8
|
apply(compiler: Compiler): void;
|
|
9
9
|
}
|
|
10
|
+
/**
|
|
11
|
+
* Env values available to `$EXTENSION_*` placeholders in emitted .json/.html.
|
|
12
|
+
* Mirrors DefinePlugin: dotenv/process values plus the per-build-target
|
|
13
|
+
* browser and mode synthetics JS already reads via import.meta.env.
|
|
14
|
+
*/
|
|
15
|
+
export declare function buildTemplateVars(combinedVars: Record<string, unknown>, browser: DevOptions['browser'], mode: string): Record<string, string>;
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Old Extension.js scaffold layout → current standardized HTML destinations.
|
|
3
|
+
* Detection is field-scoped on purpose: a string that merely looks like an old
|
|
4
|
+
* path in description, web_accessible_resources, or any other field is not a hit.
|
|
5
|
+
*/
|
|
6
|
+
export interface LegacyManifestPathRule {
|
|
7
|
+
/** Dot-path into the author manifest (e.g. `options_ui.page`). */
|
|
8
|
+
field: string;
|
|
9
|
+
/** Exact path the old scaffold wrote into that field. */
|
|
10
|
+
legacyPath: string;
|
|
11
|
+
/** Canonical emit destination Extension.js rewrites the field to. */
|
|
12
|
+
modernPath: string;
|
|
13
|
+
}
|
|
14
|
+
export interface LegacyManifestPathHit {
|
|
15
|
+
field: string;
|
|
16
|
+
legacyPath: string;
|
|
17
|
+
modernPath: string;
|
|
18
|
+
}
|
|
19
|
+
export declare const LEGACY_MANIFEST_PATH_RULES: readonly LegacyManifestPathRule[];
|
|
20
|
+
/** Collapse author path noise so `./x` and `/x` match the scaffold form. */
|
|
21
|
+
export declare function normalizeLegacyPathRef(raw: string): string;
|
|
22
|
+
/**
|
|
23
|
+
* Field-by-field scan of the *author* manifest for old scaffold HTML paths.
|
|
24
|
+
* Call this on the pre-rewrite source; the emitted asset already has modern paths.
|
|
25
|
+
*/
|
|
26
|
+
export declare function findLegacyManifestPathHits(manifest: unknown): LegacyManifestPathHit[];
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
export declare function serverRestartRequiredFromManifestError(fileAdded: string, fileRemoved: string): string;
|
|
2
|
-
export declare function legacyManifestPathWarning(legacyPath: string): string;
|
|
2
|
+
export declare function legacyManifestPathWarning(field: string, legacyPath: string, modernPath: string): string;
|
|
3
3
|
export declare function fatalManifestShapeFixed(field: string, detail: string): string;
|
|
4
4
|
export declare function invalidThemeValue(field: string, detail: string, value: string): string;
|
|
5
5
|
export declare function themeNotSupportedByBrowser(browser: string): string;
|
|
@@ -3,6 +3,7 @@ import type { DevOptions, PluginInterface } from '../../../types';
|
|
|
3
3
|
export declare class UpdateManifest {
|
|
4
4
|
readonly manifestPath: string;
|
|
5
5
|
readonly browser: DevOptions['browser'];
|
|
6
|
+
private reportedFatalFixes;
|
|
6
7
|
constructor(options: PluginInterface);
|
|
7
8
|
private applyDevOverrides;
|
|
8
9
|
apply(compiler: Compiler): void;
|