@designsystemsinternational/email 0.0.3 → 0.0.4
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/cjs/browser.cjs +2 -1
- package/dist/cjs/index.cjs +1 -1
- package/dist/esm/browser.js +2 -1
- package/dist/esm/index.js +1 -1
- package/package.json +1 -1
- package/src/packageBrowser.js +3 -2
- package/src/packageNode.js +2 -2
package/dist/cjs/browser.cjs
CHANGED
|
@@ -212,7 +212,8 @@ const preparePackageFactory =
|
|
|
212
212
|
/data:image\/([a-zA-Z]*);base64,(.*)/,
|
|
213
213
|
);
|
|
214
214
|
|
|
215
|
-
const hash =
|
|
215
|
+
const hash = hashFromString(`${data}`);
|
|
216
|
+
console.log(hash);
|
|
216
217
|
|
|
217
218
|
const filename = alt
|
|
218
219
|
? `${formatFilename(alt)}-text-${hash}.${ext}`
|
package/dist/cjs/index.cjs
CHANGED
|
@@ -215,7 +215,7 @@ const preparePackageFactory =
|
|
|
215
215
|
/data:image\/([a-zA-Z]*);base64,(.*)/,
|
|
216
216
|
);
|
|
217
217
|
|
|
218
|
-
const hash =
|
|
218
|
+
const hash = hashFromString(`${data}`);
|
|
219
219
|
|
|
220
220
|
const filename = alt
|
|
221
221
|
? `${formatFilename(alt)}-text-${hash}.${ext}`
|
package/dist/esm/browser.js
CHANGED
|
@@ -210,7 +210,8 @@ const preparePackageFactory =
|
|
|
210
210
|
/data:image\/([a-zA-Z]*);base64,(.*)/,
|
|
211
211
|
);
|
|
212
212
|
|
|
213
|
-
const hash =
|
|
213
|
+
const hash = hashFromString(`${data}`);
|
|
214
|
+
console.log(hash);
|
|
214
215
|
|
|
215
216
|
const filename = alt
|
|
216
217
|
? `${formatFilename(alt)}-text-${hash}.${ext}`
|
package/dist/esm/index.js
CHANGED
|
@@ -213,7 +213,7 @@ const preparePackageFactory =
|
|
|
213
213
|
/data:image\/([a-zA-Z]*);base64,(.*)/,
|
|
214
214
|
);
|
|
215
215
|
|
|
216
|
-
const hash =
|
|
216
|
+
const hash = hashFromString(`${data}`);
|
|
217
217
|
|
|
218
218
|
const filename = alt
|
|
219
219
|
? `${formatFilename(alt)}-text-${hash}.${ext}`
|
package/package.json
CHANGED
package/src/packageBrowser.js
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
import posthtml from 'posthtml';
|
|
4
4
|
|
|
5
5
|
import { BASE64_REGEX } from './constants.js';
|
|
6
|
-
import { formatFilename } from './util/string.js';
|
|
6
|
+
import { formatFilename, hashFromString } from './util/string.js';
|
|
7
7
|
|
|
8
8
|
/**
|
|
9
9
|
* Turns base64 inlined images into image buffers and updates their src
|
|
@@ -30,7 +30,8 @@ export const preparePackageFactory =
|
|
|
30
30
|
/data:image\/([a-zA-Z]*);base64,(.*)/,
|
|
31
31
|
);
|
|
32
32
|
|
|
33
|
-
const hash =
|
|
33
|
+
const hash = hashFromString(`${data}`);
|
|
34
|
+
console.log(hash);
|
|
34
35
|
|
|
35
36
|
const filename = alt
|
|
36
37
|
? `${formatFilename(alt)}-text-${hash}.${ext}`
|
package/src/packageNode.js
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
import posthtml from 'posthtml';
|
|
3
3
|
|
|
4
4
|
import { BASE64_REGEX } from './constants.js';
|
|
5
|
-
import { formatFilename } from './util/string.js';
|
|
5
|
+
import { formatFilename, hashFromString } from './util/string.js';
|
|
6
6
|
|
|
7
7
|
/**
|
|
8
8
|
* Turns base64 inlined images into image buffers and updates their src
|
|
@@ -29,7 +29,7 @@ export const preparePackageFactory =
|
|
|
29
29
|
/data:image\/([a-zA-Z]*);base64,(.*)/,
|
|
30
30
|
);
|
|
31
31
|
|
|
32
|
-
const hash =
|
|
32
|
+
const hash = hashFromString(`${data}`);
|
|
33
33
|
|
|
34
34
|
const filename = alt
|
|
35
35
|
? `${formatFilename(alt)}-text-${hash}.${ext}`
|