alphavalid-sdk 0.1.5 → 0.1.7

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/bin/alphavalid.js CHANGED
@@ -45,12 +45,22 @@ function copyLoaderGif() {
45
45
 
46
46
  if (!fs.existsSync(loaderSrc)) return;
47
47
 
48
- // Angular/Ionic Angular: src/assets/images
48
+ // Angular/Ionic Angular
49
49
  if (fs.existsSync(path.join(projectRoot, 'angular.json'))) {
50
+ // Canonical destination used by the SDK: src/assets/images (plural)
50
51
  const angularImages = path.join(projectRoot, 'src', 'assets', 'images');
51
52
  fs.mkdirSync(angularImages, { recursive: true });
52
53
  fs.copyFileSync(loaderSrc, path.join(angularImages, 'alphaloader.gif'));
53
54
  console.log('[AlphaValid] Loader GIF copiado para', angularImages);
55
+
56
+ // Compatibility: if the project already uses src/assets/image (singular), also copy there
57
+ const angularImageSingular = path.join(projectRoot, 'src', 'assets', 'image');
58
+ if (fs.existsSync(angularImageSingular)) {
59
+ fs.mkdirSync(angularImageSingular, { recursive: true });
60
+ fs.copyFileSync(loaderSrc, path.join(angularImageSingular, 'alphaloader.gif'));
61
+ console.log('[AlphaValid] Loader GIF (compat) copiado para', angularImageSingular);
62
+ }
63
+
54
64
  return;
55
65
  }
56
66
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "alphavalid-sdk",
3
- "version": "0.1.5",
3
+ "version": "0.1.7",
4
4
  "description": "SDK de validação facial e liveness",
5
5
  "main": "dist/alphavalid.umd.js",
6
6
  "module": "dist/alphavalid.es.js",
Binary file