@patch-adams/core 1.5.0 → 1.5.1
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/dist/cli.cjs +10 -10
- package/dist/cli.cjs.map +1 -1
- package/dist/cli.js +10 -10
- package/dist/cli.js.map +1 -1
- package/dist/index.cjs +10 -10
- package/dist/index.cjs.map +1 -1
- package/dist/index.js +10 -10
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/index.cjs
CHANGED
|
@@ -4764,8 +4764,8 @@ function generateSkinCssLoader(options) {
|
|
|
4764
4764
|
function buildSkinCssOptions(config) {
|
|
4765
4765
|
if (!config.skin) return null;
|
|
4766
4766
|
return {
|
|
4767
|
-
remoteUrl: `${config.remoteDomain}/skin/${config.skin}.css`,
|
|
4768
|
-
localPath: `skin/${config.skin}.css`,
|
|
4767
|
+
remoteUrl: `${config.remoteDomain}/skin/${config.skin}/style.css`,
|
|
4768
|
+
localPath: `skin/${config.skin}/style.css`,
|
|
4769
4769
|
timeout: config.cssAfter.timeout
|
|
4770
4770
|
// reuse cssAfter timeout
|
|
4771
4771
|
};
|
|
@@ -4865,8 +4865,8 @@ function generateSkinJsLoader(options) {
|
|
|
4865
4865
|
function buildSkinJsOptions(config) {
|
|
4866
4866
|
if (!config.skin) return null;
|
|
4867
4867
|
return {
|
|
4868
|
-
remoteUrl: `${config.remoteDomain}/skin/${config.skin}.js`,
|
|
4869
|
-
localPath: `skin/${config.skin}.js`,
|
|
4868
|
+
remoteUrl: `${config.remoteDomain}/skin/${config.skin}/script.js`,
|
|
4869
|
+
localPath: `skin/${config.skin}/script.js`,
|
|
4870
4870
|
timeout: config.jsAfter.timeout
|
|
4871
4871
|
// reuse jsAfter timeout
|
|
4872
4872
|
};
|
|
@@ -6141,13 +6141,13 @@ var Patcher = class {
|
|
|
6141
6141
|
);
|
|
6142
6142
|
}
|
|
6143
6143
|
if (this.config.skin) {
|
|
6144
|
-
const skinCssUrl = `${remoteDomain}/skin/${this.config.skin}.css`;
|
|
6144
|
+
const skinCssUrl = `${remoteDomain}/skin/${this.config.skin}/style.css`;
|
|
6145
6145
|
fetchPromises.push(
|
|
6146
6146
|
this.fetchFile(skinCssUrl).then((content) => {
|
|
6147
6147
|
fetched.skinCss = content;
|
|
6148
6148
|
})
|
|
6149
6149
|
);
|
|
6150
|
-
const skinJsUrl = `${remoteDomain}/skin/${this.config.skin}.js`;
|
|
6150
|
+
const skinJsUrl = `${remoteDomain}/skin/${this.config.skin}/script.js`;
|
|
6151
6151
|
fetchPromises.push(
|
|
6152
6152
|
this.fetchFile(skinJsUrl).then((content) => {
|
|
6153
6153
|
fetched.skinJs = content;
|
|
@@ -6375,9 +6375,9 @@ var Patcher = class {
|
|
|
6375
6375
|
buildManifestPaths(addedFiles) {
|
|
6376
6376
|
const paths = {};
|
|
6377
6377
|
for (const filePath of addedFiles) {
|
|
6378
|
-
if (this.config.skin && filePath.endsWith(`skin/${this.config.skin}.css`)) {
|
|
6378
|
+
if (this.config.skin && filePath.endsWith(`skin/${this.config.skin}/style.css`)) {
|
|
6379
6379
|
paths.skinCss = filePath;
|
|
6380
|
-
} else if (this.config.skin && filePath.endsWith(`skin/${this.config.skin}.js`)) {
|
|
6380
|
+
} else if (this.config.skin && filePath.endsWith(`skin/${this.config.skin}/script.js`)) {
|
|
6381
6381
|
paths.skinJs = filePath;
|
|
6382
6382
|
} else if (filePath.endsWith(this.config.cssBefore.filename)) {
|
|
6383
6383
|
paths.cssBefore = filePath;
|
|
@@ -6464,14 +6464,14 @@ var Patcher = class {
|
|
|
6464
6464
|
if (fetched.jsAfter) console.log(`[Patcher] Using fetched content for ${path}`);
|
|
6465
6465
|
}
|
|
6466
6466
|
if (this.config.skin) {
|
|
6467
|
-
const skinCssPath = `${basePath}skin/${this.config.skin}.css`;
|
|
6467
|
+
const skinCssPath = `${basePath}skin/${this.config.skin}/style.css`;
|
|
6468
6468
|
const skinCssContent = fetched.skinCss ?? `/* PA-Patcher: Skin CSS (${this.config.skin}) */
|
|
6469
6469
|
`;
|
|
6470
6470
|
zip.addFile(skinCssPath, Buffer.from(skinCssContent, "utf-8"));
|
|
6471
6471
|
added.push(skinCssPath);
|
|
6472
6472
|
if (fetched.skinCss) console.log(`[Patcher] Using fetched skin CSS for ${skinCssPath}`);
|
|
6473
6473
|
else console.log(`[Patcher] Added placeholder skin CSS: ${skinCssPath}`);
|
|
6474
|
-
const skinJsPath = `${basePath}skin/${this.config.skin}.js`;
|
|
6474
|
+
const skinJsPath = `${basePath}skin/${this.config.skin}/script.js`;
|
|
6475
6475
|
const skinJsContent = fetched.skinJs ?? `// PA-Patcher: Skin JS (${this.config.skin})
|
|
6476
6476
|
`;
|
|
6477
6477
|
zip.addFile(skinJsPath, Buffer.from(skinJsContent, "utf-8"));
|