@egovernments/digit-ui-libraries 1.5.0-beta.4 → 1.5.0-beta.5

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/index.js CHANGED
@@ -37136,10 +37136,10 @@ var ShareFiles = {
37136
37136
  targetLink: function targetLink(target, shortUrl) {
37137
37137
  switch (target) {
37138
37138
  case "mail":
37139
- return window.open("mailto:?body=" + shortUrl, "_blank");
37139
+ return window.open("mailto:?body=" + encodeURIComponent(shortUrl), "_blank");
37140
37140
 
37141
37141
  case "whatsapp":
37142
- if (window.mSewaApp && window.mSewaApp.isMsewaApp()) return window.open("https://wa.me/send?text=" + shortUrl, "_blank");else return window.open("https://web.whatsapp.com/send?text=" + shortUrl, "_blank");
37142
+ return window.open('https://' + (window.mSewaApp && window.mSewaApp.isMsewaApp() ? 'api' : 'web') + '.whatsapp.com/send?text=' + encodeURIComponent(shortUrl), "_blank");
37143
37143
 
37144
37144
  default:
37145
37145
  return window.open(shortUrl, "_blank");