@capillarytech/creatives-library 7.17.84 → 7.17.86

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/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@capillarytech/creatives-library",
3
3
  "author": "meharaj",
4
- "version": "7.17.84",
4
+ "version": "7.17.86",
5
5
  "description": "Capillary creatives ui",
6
6
  "main": "./index.js",
7
7
  "module": "./index.es.js",
@@ -499,35 +499,37 @@ export const Whatsapp = (props) => {
499
499
  };
500
500
 
501
501
  // as per change in message body we filter out url using regex
502
- useEffect(() => {
503
- if (updatedSmsEditor?.length > 0) {
504
- const previewUrlArr = updatedSmsEditor.join("").match(previewUrlMatchingRegex) || [];
505
- if (previewUrlArr?.length > 0) {
506
- setPreviewUrl(previewUrlArr[0]);
507
- } else {
508
- setPreviewUrl('');
509
- }
510
- }
511
- }, [updatedSmsEditor])
512
-
513
- const debounceFn = useCallback(
514
- debounce(url => {
515
- actions.getMetaTags({
516
- previewUrl: url,
517
- callBack: actionCallback,
518
- })
519
- }, 500),
520
- [],
521
- );
502
+ // preview URL is not supported by the Gateway (Karix/Gupshup), show hiding it for now. once the Gateway support is available, previewUrl option would be shown.
503
+ // useEffect(() => {
504
+ // if (updatedSmsEditor?.length > 0) {
505
+ // const previewUrlArr = updatedSmsEditor.join("").match(previewUrlMatchingRegex) || [];
506
+ // if (previewUrlArr?.length > 0) {
507
+ // setPreviewUrl(previewUrlArr[0]);
508
+ // } else {
509
+ // setPreviewUrl('');
510
+ // }
511
+ // }
512
+ // }, [updatedSmsEditor])
513
+
514
+ // const debounceFn = useCallback(
515
+ // debounce(url => {
516
+ // actions.getMetaTags({
517
+ // previewUrl: url,
518
+ // callBack: actionCallback,
519
+ // })
520
+ // }, 500),
521
+ // [],
522
+ // );
522
523
 
523
524
  // as per change in url and preview checkbox we call api and extract the meta information of url
524
- useEffect(() => {
525
- if (!isEmpty(previewUrl) && showUrlPreview) {
526
- debounceFn(previewUrl);
527
- } else {
528
- actions.resetMetaTags();
529
- }
530
- }, [previewUrl, showUrlPreview])
525
+ // we will open once preview url support
526
+ // useEffect(() => {
527
+ // if (!isEmpty(previewUrl) && showUrlPreview) {
528
+ // debounceFn(previewUrl);
529
+ // } else {
530
+ // actions.resetMetaTags();
531
+ // }
532
+ // }, [previewUrl, showUrlPreview])
531
533
 
532
534
  //performs tag validation
533
535
  useEffect(() => {
@@ -1910,6 +1912,7 @@ export const Whatsapp = (props) => {
1910
1912
  ) : (
1911
1913
  ""
1912
1914
  )}
1915
+ {/* preview URL is not supported by the Gateway (Karix/Gupshup), show hiding it for now. once the Gateway support is available, previewUrl option would be shown.
1913
1916
  <CapRow>
1914
1917
  <CapCheckbox
1915
1918
  className={`whatsapp-unsubscribe-checkbox ${'whatsapp-create-unsubscribe-checkbox'}`}
@@ -1922,7 +1925,7 @@ export const Whatsapp = (props) => {
1922
1925
  {formatMessage(messages.showUrlPreview)}
1923
1926
  </span>
1924
1927
  </CapCheckbox>
1925
- </CapRow>
1928
+ </CapRow> */}
1926
1929
  {templateFooter && isHostIsNotTwilio && (
1927
1930
  <>
1928
1931
  <CapHeader