@blocklet/images 1.16.33-beta-20241112-122339-e39fa9e7 → 1.16.33

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.
@@ -35,7 +35,8 @@ const validateLogo = (logoName, options) => {
35
35
  if (!imgType || !logoType.includes(imgType.ext)) {
36
36
  errorMessages.push(`${preLogoMessage} format is not supported, expected: [${logoType}].`);
37
37
  }
38
- if (`.${imgType?.ext}` !== path_1.default.extname(logoPath)) {
38
+ const logoExt = path_1.default.extname(logoPath);
39
+ if (`.${imgType?.ext}` !== logoExt && logoExt !== '.jpeg') {
39
40
  errorMessages.push(`${preLogoMessage} extension is not match the real file extension [.${imgType?.ext}].`);
40
41
  }
41
42
  const logoMeta = (0, image_size_1.default)(logoPath);
@@ -50,7 +50,8 @@ const validateScreenshots = (screenshots, options) => {
50
50
  asyncErrors[screenshot].push(`${preMessage} is not a valid image file.`);
51
51
  return;
52
52
  }
53
- if (`.${imgType.ext}` !== path_1.default.extname(screenshotsPath)) {
53
+ const screenshotExt = path_1.default.extname(screenshotsPath);
54
+ if (`.${imgType.ext}` !== screenshotExt && screenshotExt !== '.jpeg') {
54
55
  asyncErrors[screenshot].push(`${preMessage} extension is not match the real file extension [.${imgType.ext}].`);
55
56
  }
56
57
  const imageMeta = (0, image_size_1.default)(screenshotsPath);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@blocklet/images",
3
- "version": "1.16.33-beta-20241112-122339-e39fa9e7",
3
+ "version": "1.16.33",
4
4
  "main": "lib/index.js",
5
5
  "types": "./lib/index.d.ts",
6
6
  "license": "MIT",
@@ -51,5 +51,5 @@
51
51
  "ts-node": "^10.9.1",
52
52
  "typescript": "^5.6.3"
53
53
  },
54
- "gitHead": "1bd2f185f5ffc1fba8d3cdeb232333d088ea65e1"
54
+ "gitHead": "f314706b7a6150adbf6bf700f06d2989981eaf1f"
55
55
  }