@creaditor/web-starterkit 1.0.64 → 1.0.65

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.
Files changed (204) hide show
  1. package/dist/112.creaditor.bundle.js.gz +0 -0
  2. package/dist/1142.creaditor.bundle.js +1 -1
  3. package/dist/1142.creaditor.bundle.js.gz +0 -0
  4. package/dist/1271.creaditor.bundle.js.gz +0 -0
  5. package/dist/1317.creaditor.bundle.js.LICENSE.txt.gz +0 -0
  6. package/dist/1317.creaditor.bundle.js.gz +0 -0
  7. package/dist/1334.creaditor.bundle.js.gz +0 -0
  8. package/dist/1396.creaditor.bundle.js.gz +0 -0
  9. package/dist/1403.creaditor.bundle.js.gz +0 -0
  10. package/dist/1456.creaditor.bundle.js.gz +0 -0
  11. package/dist/1529.creaditor.bundle.js.gz +0 -0
  12. package/dist/168.creaditor.bundle.js.LICENSE.txt.gz +0 -0
  13. package/dist/168.creaditor.bundle.js.gz +0 -0
  14. package/dist/170.creaditor.bundle.js.gz +0 -0
  15. package/dist/1728.creaditor.bundle.js +133 -0
  16. package/dist/1728.creaditor.bundle.js.gz +0 -0
  17. package/dist/175.creaditor.bundle.js.gz +0 -0
  18. package/dist/1972.creaditor.bundle.js.gz +0 -0
  19. package/dist/211.creaditor.bundle.js.gz +0 -0
  20. package/dist/2112.creaditor.bundle.js.gz +0 -0
  21. package/dist/2154.creaditor.bundle.js.gz +0 -0
  22. package/dist/2234.creaditor.bundle.js.gz +0 -0
  23. package/dist/2298.creaditor.bundle.js.gz +0 -0
  24. package/dist/235.creaditor.bundle.js.gz +0 -0
  25. package/dist/2350.creaditor.bundle.js.gz +0 -0
  26. package/dist/2377.creaditor.bundle.js.gz +0 -0
  27. package/dist/2384.creaditor.bundle.js.gz +0 -0
  28. package/dist/2397.creaditor.bundle.js.gz +0 -0
  29. package/dist/2409.creaditor.bundle.js.gz +0 -0
  30. package/dist/2547.creaditor.bundle.js.gz +0 -0
  31. package/dist/2550.creaditor.bundle.js.gz +0 -0
  32. package/dist/2590.creaditor.bundle.js.gz +0 -0
  33. package/dist/2655.creaditor.bundle.js.gz +0 -0
  34. package/dist/2706.creaditor.bundle.js.LICENSE.txt.gz +0 -0
  35. package/dist/2706.creaditor.bundle.js.gz +0 -0
  36. package/dist/271.creaditor.bundle.js.gz +0 -0
  37. package/dist/2717.creaditor.bundle.js.gz +0 -0
  38. package/dist/2765.creaditor.bundle.js.gz +0 -0
  39. package/dist/2773.creaditor.bundle.js.gz +0 -0
  40. package/dist/2833.creaditor.bundle.js.gz +0 -0
  41. package/dist/2837.creaditor.bundle.js.LICENSE.txt.gz +0 -0
  42. package/dist/2837.creaditor.bundle.js.gz +0 -0
  43. package/dist/2956.creaditor.bundle.js.gz +0 -0
  44. package/dist/2963.creaditor.bundle.js.gz +0 -0
  45. package/dist/3105.creaditor.bundle.js.gz +0 -0
  46. package/dist/3233.creaditor.bundle.js.gz +0 -0
  47. package/dist/3418.creaditor.bundle.js.gz +0 -0
  48. package/dist/3521.creaditor.bundle.js.gz +0 -0
  49. package/dist/353.creaditor.bundle.js.gz +0 -0
  50. package/dist/3545.creaditor.bundle.js.gz +0 -0
  51. package/dist/3553.creaditor.bundle.js.gz +0 -0
  52. package/dist/3600.creaditor.bundle.js.gz +0 -0
  53. package/dist/3601.creaditor.bundle.js +288 -0
  54. package/dist/3601.creaditor.bundle.js.gz +0 -0
  55. package/dist/3606.creaditor.bundle.js.gz +0 -0
  56. package/dist/3792.creaditor.bundle.js.gz +0 -0
  57. package/dist/380.creaditor.bundle.js.gz +0 -0
  58. package/dist/3827.creaditor.bundle.js.gz +0 -0
  59. package/dist/3847.creaditor.bundle.js.gz +0 -0
  60. package/dist/3875.creaditor.bundle.js.gz +0 -0
  61. package/dist/3971.creaditor.bundle.js.gz +0 -0
  62. package/dist/4000.creaditor.bundle.js.gz +0 -0
  63. package/dist/4061.creaditor.bundle.js.gz +0 -0
  64. package/dist/407.creaditor.bundle.js.gz +0 -0
  65. package/dist/4074.creaditor.bundle.js.gz +0 -0
  66. package/dist/4100.creaditor.bundle.js.gz +0 -0
  67. package/dist/4109.creaditor.bundle.js.gz +0 -0
  68. package/dist/4114.creaditor.bundle.js.gz +0 -0
  69. package/dist/4161.creaditor.bundle.js.gz +0 -0
  70. package/dist/4186.creaditor.bundle.js.LICENSE.txt.gz +0 -0
  71. package/dist/4186.creaditor.bundle.js.gz +0 -0
  72. package/dist/4288.creaditor.bundle.js.gz +0 -0
  73. package/dist/4413.creaditor.bundle.js.gz +0 -0
  74. package/dist/4475.creaditor.bundle.js.gz +0 -0
  75. package/dist/453.creaditor.bundle.js.gz +0 -0
  76. package/dist/4615.creaditor.bundle.js.gz +0 -0
  77. package/dist/4639.creaditor.bundle.js.gz +0 -0
  78. package/dist/467.creaditor.bundle.js.gz +0 -0
  79. package/dist/4762.creaditor.bundle.js.gz +0 -0
  80. package/dist/4770.creaditor.bundle.js.gz +0 -0
  81. package/dist/4947.creaditor.bundle.js.gz +0 -0
  82. package/dist/4987.creaditor.bundle.js.gz +0 -0
  83. package/dist/4988.creaditor.bundle.js.gz +0 -0
  84. package/dist/507.creaditor.bundle.js +334 -0
  85. package/dist/507.creaditor.bundle.js.gz +0 -0
  86. package/dist/5133.creaditor.bundle.js.gz +0 -0
  87. package/dist/5156.creaditor.bundle.js.gz +0 -0
  88. package/dist/5284.creaditor.bundle.js.gz +0 -0
  89. package/dist/5379.creaditor.bundle.js.gz +0 -0
  90. package/dist/5391.creaditor.bundle.js.gz +0 -0
  91. package/dist/5411.creaditor.bundle.js.gz +0 -0
  92. package/dist/5501.creaditor.bundle.js.gz +0 -0
  93. package/dist/5530.creaditor.bundle.js.gz +0 -0
  94. package/dist/5666.creaditor.bundle.js.gz +0 -0
  95. package/dist/567.creaditor.bundle.js.gz +0 -0
  96. package/dist/5713.creaditor.bundle.js.LICENSE.txt.gz +0 -0
  97. package/dist/5713.creaditor.bundle.js.gz +0 -0
  98. package/dist/574.creaditor.bundle.js.LICENSE.txt.gz +0 -0
  99. package/dist/574.creaditor.bundle.js.gz +0 -0
  100. package/dist/578.creaditor.bundle.js.gz +0 -0
  101. package/dist/5839.creaditor.bundle.js.gz +0 -0
  102. package/dist/5849.creaditor.bundle.js.gz +0 -0
  103. package/dist/5850.creaditor.bundle.js.gz +0 -0
  104. package/dist/5884.creaditor.bundle.js.gz +0 -0
  105. package/dist/59.creaditor.bundle.js.LICENSE.txt.gz +0 -0
  106. package/dist/59.creaditor.bundle.js.gz +0 -0
  107. package/dist/5926.creaditor.bundle.js.gz +0 -0
  108. package/dist/6036.creaditor.bundle.js.gz +0 -0
  109. package/dist/6151.creaditor.bundle.js.gz +0 -0
  110. package/dist/6216.creaditor.bundle.js.LICENSE.txt.gz +0 -0
  111. package/dist/6216.creaditor.bundle.js.gz +0 -0
  112. package/dist/{4819.creaditor.bundle.js → 6323.creaditor.bundle.js} +7 -7
  113. package/dist/6323.creaditor.bundle.js.gz +0 -0
  114. package/dist/638.creaditor.bundle.js.gz +0 -0
  115. package/dist/6442.creaditor.bundle.js.gz +0 -0
  116. package/dist/6496.creaditor.bundle.js.gz +0 -0
  117. package/dist/653.creaditor.bundle.js.gz +0 -0
  118. package/dist/6751.creaditor.bundle.js.gz +0 -0
  119. package/dist/6814.creaditor.bundle.js.gz +0 -0
  120. package/dist/6937.creaditor.bundle.js.gz +0 -0
  121. package/dist/7055.creaditor.bundle.js.gz +0 -0
  122. package/dist/7155.creaditor.bundle.js.gz +0 -0
  123. package/dist/7209.creaditor.bundle.js.gz +0 -0
  124. package/dist/7238.creaditor.bundle.js.gz +0 -0
  125. package/dist/7255.creaditor.bundle.js.gz +0 -0
  126. package/dist/7348.creaditor.bundle.js.gz +0 -0
  127. package/dist/738.creaditor.bundle.js.gz +0 -0
  128. package/dist/7380.creaditor.bundle.js.gz +0 -0
  129. package/dist/7463.creaditor.bundle.js.LICENSE.txt.gz +0 -0
  130. package/dist/7463.creaditor.bundle.js.gz +0 -0
  131. package/dist/7466.creaditor.bundle.js.gz +0 -0
  132. package/dist/7493.creaditor.bundle.js.gz +0 -0
  133. package/dist/752.creaditor.bundle.js.gz +0 -0
  134. package/dist/7523.creaditor.bundle.js.gz +0 -0
  135. package/dist/7564.creaditor.bundle.js.gz +0 -0
  136. package/dist/7654.creaditor.bundle.js.gz +0 -0
  137. package/dist/767.creaditor.bundle.js.gz +0 -0
  138. package/dist/7789.creaditor.bundle.js.LICENSE.txt.gz +0 -0
  139. package/dist/7789.creaditor.bundle.js.gz +0 -0
  140. package/dist/7838.creaditor.bundle.js.gz +0 -0
  141. package/dist/7997.creaditor.bundle.js.gz +0 -0
  142. package/dist/8042.creaditor.bundle.js.gz +0 -0
  143. package/dist/8064.creaditor.bundle.js.gz +0 -0
  144. package/dist/8088.creaditor.bundle.js +141 -0
  145. package/dist/8088.creaditor.bundle.js.gz +0 -0
  146. package/dist/8141.creaditor.bundle.js.gz +0 -0
  147. package/dist/8173.creaditor.bundle.js.LICENSE.txt.gz +0 -0
  148. package/dist/8173.creaditor.bundle.js.gz +0 -0
  149. package/dist/8196.creaditor.bundle.js.gz +0 -0
  150. package/dist/823.creaditor.bundle.js.gz +0 -0
  151. package/dist/8250.creaditor.bundle.js.gz +0 -0
  152. package/dist/8251.creaditor.bundle.js.gz +0 -0
  153. package/dist/8299.creaditor.bundle.js.gz +0 -0
  154. package/dist/8315.creaditor.bundle.js.gz +0 -0
  155. package/dist/8443.creaditor.bundle.js.gz +0 -0
  156. package/dist/8516.creaditor.bundle.js.gz +0 -0
  157. package/dist/8533.creaditor.bundle.js.gz +0 -0
  158. package/dist/8570.creaditor.bundle.js.gz +0 -0
  159. package/dist/8646.creaditor.bundle.js.gz +0 -0
  160. package/dist/8654.creaditor.bundle.js.gz +0 -0
  161. package/dist/8854.creaditor.bundle.js.gz +0 -0
  162. package/dist/8878.creaditor.bundle.js.gz +0 -0
  163. package/dist/8916.creaditor.bundle.js.gz +0 -0
  164. package/dist/8921.creaditor.bundle.js.gz +0 -0
  165. package/dist/898.creaditor.bundle.js.LICENSE.txt.gz +0 -0
  166. package/dist/898.creaditor.bundle.js.gz +0 -0
  167. package/dist/8983.creaditor.bundle.js.gz +0 -0
  168. package/dist/9041.creaditor.bundle.js.gz +0 -0
  169. package/dist/9158.creaditor.bundle.js.LICENSE.txt.gz +0 -0
  170. package/dist/9158.creaditor.bundle.js.gz +0 -0
  171. package/dist/9250.creaditor.bundle.js.gz +0 -0
  172. package/dist/9386.creaditor.bundle.js.gz +0 -0
  173. package/dist/9431.creaditor.bundle.js.gz +0 -0
  174. package/dist/9453.creaditor.bundle.js.gz +0 -0
  175. package/dist/9570.creaditor.bundle.js.gz +0 -0
  176. package/dist/9694.creaditor.bundle.js.gz +0 -0
  177. package/dist/975.creaditor.bundle.js.gz +0 -0
  178. package/dist/976.creaditor.bundle.js.gz +0 -0
  179. package/dist/9986.creaditor.bundle.js.gz +0 -0
  180. package/dist/9990.creaditor.bundle.js.gz +0 -0
  181. package/dist/9994.creaditor.bundle.js.gz +0 -0
  182. package/dist/creaditor.bundle.js +4 -4
  183. package/dist/creaditor.bundle.js.LICENSE.txt.gz +0 -0
  184. package/dist/creaditor.bundle.js.gz +0 -0
  185. package/dist/index.html.gz +0 -0
  186. package/dist/service-worker.js +1 -1
  187. package/dist/service-worker.js.gz +0 -0
  188. package/dist/workbox-f3063069.js.gz +0 -0
  189. package/package.json +1 -1
  190. package/dist/2001.creaditor.bundle.js +0 -335
  191. package/dist/2001.creaditor.bundle.js.LICENSE.txt +0 -11
  192. package/dist/2001.creaditor.bundle.js.LICENSE.txt.gz +0 -0
  193. package/dist/2001.creaditor.bundle.js.gz +0 -0
  194. package/dist/4819.creaditor.bundle.js.gz +0 -0
  195. package/dist/5791.creaditor.bundle.js +0 -288
  196. package/dist/5791.creaditor.bundle.js.gz +0 -0
  197. package/dist/7051.creaditor.bundle.js +0 -162
  198. package/dist/7051.creaditor.bundle.js.LICENSE.txt +0 -17
  199. package/dist/7051.creaditor.bundle.js.LICENSE.txt.gz +0 -0
  200. package/dist/7051.creaditor.bundle.js.gz +0 -0
  201. package/dist/715.creaditor.bundle.js +0 -142
  202. package/dist/715.creaditor.bundle.js.LICENSE.txt +0 -11
  203. package/dist/715.creaditor.bundle.js.LICENSE.txt.gz +0 -0
  204. package/dist/715.creaditor.bundle.js.gz +0 -0
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
@@ -0,0 +1,334 @@
1
+ "use strict";(("undefined"!=typeof self?self:this).webpackChunkCreaditor=("undefined"!=typeof self?self:this).webpackChunkCreaditor||[]).push([[507],{90507(e,i,t){t.r(i),t.d(i,{AttachedFilesPlugin:()=>f});var s,o,r,a,l,n,d=t(59088),p=t(36936),h=t(59929),c=t(49410);let f=(s=(0,c.EM)("cdtr-attached-files-plugin"),o=(0,c.MZ)({type:Object,attribute:!1}),s(((n=class extends h.WF{constructor(){super(),this.files=[],this.maxFiles=1/0,this.maxFileSizeMB=1/0,this.isLoading=!1,this.buttonText="Attached Files",this.addFilesText="Add Files",this.maxFilesReachedText="Maximum number of files reached",this.fileTooLargeText="File size exceeds the limit",this.error="",this.customColor="",this.customTextColor="",this.iconColor="",this.loadingText="Loading files...",(0,d.A)(this,"lazyLoad",l,this),this._isOpen=!1,this._lazyLoadPromise=null,this.initializeLazyLoad()}initializeLazyLoad(){let e,i;const t=new Promise((t,s)=>{e=t,i=s});this._lazyLoadPromise={promise:t,resolve:e,reject:i},this.lazyLoad=this._lazyLoadPromise,this._lazyLoadPromise.promise.then(e=>{this.handleLazyLoadedFiles(e)}).catch(e=>{console.error("Lazy load promise rejected:",e),this.error=`Failed to load files: ${e.message}`})}handleLazyLoadedFiles(e){if(!Array.isArray(e))return void console.error("Lazy loaded files must be an array");const i=e.filter(e=>e&&"object"==typeof e?!!(e.id&&e.name&&e.type&&e.url)||(console.warn("File missing required properties:",e),!1):(console.warn("Invalid file object:",e),!1));if(0===i.length)return void console.warn("No valid files found in lazy load");const t=this.maxFiles-this.files.length;if(t<=0)return this.error=this.maxFilesReachedText,void this.dispatchEvent(new CustomEvent("max-files-reached",{detail:{maxFiles:this.maxFiles},bubbles:!0,composed:!0}));const s=i.slice(0,t);this.files=[...this.files,...s],this.error="",this.dispatchEvent(new CustomEvent("lazy-files-loaded",{detail:{files:s,totalFiles:this.files.length},bubbles:!0,composed:!0})),this.requestUpdate()}resolveLazyLoad(e){this._lazyLoadPromise&&this._lazyLoadPromise.resolve(e)}rejectLazyLoad(e){this._lazyLoadPromise&&this._lazyLoadPromise.reject(e)}getLazyLoadPromise(){return this._lazyLoadPromise?.promise||null}resetLazyLoad(){this.initializeLazyLoad()}showLoading(e){this.isLoading=!0,e&&(this.loadingText=e),this.requestUpdate()}hideLoading(){this.isLoading=!1,this.requestUpdate()}formatFileSize(e){if(0===e)return"0 B";const i=Math.floor(Math.log(e)/Math.log(1024));return`${parseFloat((e/Math.pow(1024,i)).toFixed(2))} ${["B","KB","MB","GB"][i]}`}displayName(e){const i=e.name||e.url||"",t=i.split(/[?#]/)[0].split("/").filter(Boolean).pop()||i;try{return decodeURIComponent(t)}catch{return t}}extension(e){const i=this.displayName(e).match(/\.([a-z0-9]{1,5})$/i);return i?i[1].toLowerCase():""}fileKind(e){const i=(e.type||"").toLowerCase().split("/")[0];if(["image","pdf","video","audio"].includes(i))return i;if((e.type||"").toLowerCase().includes("pdf"))return"pdf";const t=this.extension(e);return/^(png|jpe?g|gif|webp|svg|bmp|avif)$/.test(t)?"image":"pdf"===t?"pdf":/^(mp4|mov|webm|avi|mkv)$/.test(t)?"video":/^(mp3|wav|ogg|m4a|aac)$/.test(t)?"audio":"file"}fileIcon(e){switch(e){case"pdf":return h.qy`<svg viewBox="0 0 24 24" fill="currentColor"><path d="M5 4H15V8H19V20H5V4ZM3.9985 2C3.44749 2 3 2.44405 3 2.9918V21.0082C3 21.5447 3.44476 22 3.9934 22H20.0066C20.5551 22 21 21.5489 21 20.9925L20.9997 7L16 2H3.9985ZM10.4999 7.5C10.4999 9.07749 10.0442 10.9373 9.27493 12.6534C8.50287 14.3757 7.46143 15.8502 6.37524 16.7191L7.55464 18.3321C10.4821 16.3804 13.7233 15.0421 16.8585 15.49L17.3162 13.5513C14.6435 12.6604 12.4999 9.98994 12.4999 7.5H10.4999ZM11.0999 13.4716C11.3673 12.8752 11.6042 12.2563 11.8037 11.6285C12.2753 12.3531 12.8553 13.0182 13.5101 13.5953C12.5283 13.7711 11.5665 14.0596 10.6352 14.4276C10.7999 14.1143 10.9551 13.7948 11.0999 13.4716Z"></path></svg>`;case"video":return h.qy`<svg viewBox="0 0 24 24" fill="currentColor"><path d="M3 3.9934C3 3.44476 3.44495 3 3.9934 3H20.0066C20.5552 3 21 3.44495 21 3.9934V20.0066C21 20.5552 20.5551 21 20.0066 21H3.9934C3.44476 21 3 20.5551 3 20.0066V3.9934ZM5 5V19H19V5H5ZM10.6219 8.41459L15.5008 11.6672C15.6846 11.7897 15.7343 12.0381 15.6117 12.2219C15.5824 12.2658 15.5447 12.3035 15.5008 12.3328L10.6219 15.5854C10.4381 15.708 10.1897 15.6583 10.0672 15.4745C10.0234 15.4088 10 15.3316 10 15.2526V8.74741C10 8.52649 10.1791 8.34741 10.4 8.34741C10.479 8.34741 10.5562 8.37078 10.6219 8.41459Z"></path></svg>`;case"audio":return h.qy`<svg viewBox="0 0 24 24" fill="currentColor"><path d="M20 3V17C20 19.2091 18.2091 21 16 21C13.7909 21 12 19.2091 12 17C12 14.7909 13.7909 13 16 13C16.7286 13 17.4117 13.1948 18 13.5351V6H9V17C9 19.2091 7.20914 21 5 21C2.79086 21 1 19.2091 1 17C1 14.7909 2.79086 13 5 13C5.72857 13 6.41165 13.1948 7 13.5351V3H20ZM5 19C6.10457 19 7 18.1046 7 17C7 15.8954 6.10457 15 5 15C3.89543 15 3 15.8954 3 17C3 18.1046 3.89543 19 5 19ZM16 19C17.1046 19 18 18.1046 18 17C18 15.8954 17.1046 15 16 15C14.8954 15 14 15.8954 14 17C14 18.1046 14.8954 19 16 19Z"></path></svg>`;default:return h.qy`<svg viewBox="0 0 24 24" fill="currentColor"><path d="M9 2.00318V2H19.9978C20.5513 2 21 2.45531 21 2.9918V21.0082C21 21.556 20.5551 22 20.0066 22H3.9934C3.44476 22 3 21.5501 3 20.9932V8L9 2.00318ZM5.82918 8H9V4.83086L5.82918 8ZM11 4V9C11 9.55228 10.5523 10 10 10H5V20H19V4H11Z"></path></svg>`}}getFilePreview(e){const i=this.fileKind(e);return"image"===i&&e.url?h.qy`<img src=${e.url} alt=${this.displayName(e)} />`:this.fileIcon(i)}handleFileSelect(e){const i=e.target;if(i.files&&i.files.length>0){const e=this.maxFiles-this.files.length;if(e<=0)return this.error=this.maxFilesReachedText,void this.dispatchEvent(new CustomEvent("max-files-reached",{detail:{maxFiles:this.maxFiles},bubbles:!0,composed:!0}));const t=1024*this.maxFileSizeMB*1024,s=Array.from(i.files).filter(e=>e.size>t);if(s.length>0)return this.error=`${this.fileTooLargeText} (${this.maxFileSizeMB}MB)`,void this.dispatchEvent(new CustomEvent("file-too-large",{detail:{files:s,maxSize:this.maxFileSizeMB},bubbles:!0,composed:!0}));this.error="",this.isLoading=!0;const o=Array.from(i.files).slice(0,e);let r=0;o.forEach(e=>{const i=new FileReader;i.onload=i=>{const t={id:Math.random().toString(36).substr(2,9),name:e.name,type:e.type.split("/")[0],url:i.target?.result,size:e.size};this.files=[...this.files,t],this.dispatchEvent(new CustomEvent("file-added",{detail:t,bubbles:!0,composed:!0})),r++,r===o.length&&(this.isLoading=!1)},i.readAsDataURL(e)})}}handleRemoveFile(e){const i=this.files.find(i=>i.id===e);i&&(this.files=this.files.filter(i=>i.id!==e),this.dispatchEvent(new CustomEvent("file-removed",{detail:i,bubbles:!0,composed:!0})))}render(){return Array.isArray(this.files)||(this.files=[]),h.qy`
2
+ <div class="button-container">
3
+ <cdtr-popover
4
+ ?opened=${this._isOpen}
5
+ @opened-changed=${e=>{this._isOpen=e.detail.value,this.requestUpdate(),this._isOpen||(this.error="")}}
6
+ >
7
+ <paper-button
8
+ slot="trigger"
9
+ dir="auto"
10
+ class=${this.isLoading?"loading-button":""}
11
+ >
12
+ ${this.isLoading?h.qy`<div class="button-loading-spinner"></div>`:h.qy`<svg
13
+ style="color: ${this.iconColor};"
14
+ width="18"
15
+ xmlns="http://www.w3.org/2000/svg"
16
+ viewBox="0 0 24 24"
17
+ fill="currentColor"
18
+ >
19
+ <path
20
+ d="M14.8287 7.75737L9.1718 13.4142C8.78127 13.8047 8.78127 14.4379 9.1718 14.8284C9.56232 15.219 10.1955 15.219 10.586 14.8284L16.2429 9.17158C17.4144 8.00001 17.4144 6.10052 16.2429 4.92894C15.0713 3.75737 13.1718 3.75737 12.0002 4.92894L6.34337 10.5858C4.39075 12.5384 4.39075 15.7042 6.34337 17.6569C8.29599 19.6095 11.4618 19.6095 13.4144 17.6569L19.0713 12L20.4855 13.4142L14.8287 19.0711C12.095 21.8047 7.66283 21.8047 4.92916 19.0711C2.19549 16.3374 2.19549 11.9053 4.92916 9.17158L10.586 3.51473C12.5386 1.56211 15.7045 1.56211 17.6571 3.51473C19.6097 5.46735 19.6097 8.63317 17.6571 10.5858L12.0002 16.2427C10.8287 17.4142 8.92916 17.4142 7.75759 16.2427C6.58601 15.0711 6.58601 13.1716 7.75759 12L13.4144 6.34316L14.8287 7.75737Z"
21
+ ></path>
22
+ </svg>`}
23
+ </paper-button>
24
+ <div slot="content" class="popover-content" dir="auto">
25
+ ${this.error?h.qy` <div class="error-message">${this.error}</div> `:""}
26
+ <div class="file-list">
27
+ ${this.files.map(e=>{const i=this.displayName(e),t=[this.extension(e),e.size?this.formatFileSize(e.size):""].filter(Boolean).join(" · ");return h.qy`
28
+ <div class="file-row">
29
+ <div class="file-thumb">${this.getFilePreview(e)}</div>
30
+ <div class="file-info">
31
+ ${e.url&&!e.url.startsWith("data:")?h.qy`<a
32
+ class="file-name"
33
+ href=${e.url}
34
+ target="_blank"
35
+ rel="noopener"
36
+ title=${i}
37
+ >${i}</a
38
+ >`:h.qy`<div class="file-name" title=${i}>
39
+ ${i}
40
+ </div>`}
41
+ ${t?h.qy`<div class="file-meta">${t}</div>`:""}
42
+ </div>
43
+ <button
44
+ class="remove-btn"
45
+ title="Remove"
46
+ @click=${()=>this.handleRemoveFile(e.id)}
47
+ >
48
+ <svg
49
+ xmlns="http://www.w3.org/2000/svg"
50
+ viewBox="0 0 24 24"
51
+ fill="currentColor"
52
+ width="16"
53
+ height="16"
54
+ >
55
+ <path
56
+ d="M17 6H22V8H20V21C20 21.5523 19.5523 22 19 22H5C4.44772 22 4 21.5523 4 21V8H2V6H7V3C7 2.44772 7.44772 2 8 2H16C16.5523 2 17 2.44772 17 3V6ZM18 8H6V20H18V8ZM9 11H11V17H9V11ZM13 11H15V17H13V11ZM9 4V6H15V4H9Z"
57
+ ></path>
58
+ </svg>
59
+ </button>
60
+ </div>
61
+ `})}
62
+ ${this.files.length<this.maxFiles?h.qy`
63
+ <div class="add-row">
64
+ <label class="add-files-btn">
65
+ <svg viewBox="0 0 24 24" fill="currentColor">
66
+ <path d="M11 11V5H13V11H19V13H13V19H11V13H5V11H11Z"></path>
67
+ </svg>
68
+ <span>${this.addFilesText}</span>
69
+ <input
70
+ type="file"
71
+ multiple
72
+ hidden
73
+ @change=${this.handleFileSelect}
74
+ />
75
+ </label>
76
+ ${this.isLoading?h.qy`<div class="loading-overlay">
77
+ <div class="loading-spinner"></div>
78
+ <div class="loading-text">${this.loadingText}</div>
79
+ </div>`:""}
80
+ </div>
81
+ `:h.qy`
82
+ <div class="error-message">
83
+ ${this.maxFilesReachedText} (${this.maxFiles})
84
+ </div>
85
+ `}
86
+ </div>
87
+ </div>
88
+ </cdtr-popover>
89
+ ${this.files.length>0?h.qy`
90
+ <span class="count-badge">${this.files.length}</span>
91
+ `:""}
92
+ </div>
93
+ `}}).styles=h.AH`
94
+ .popover-content {
95
+ width: 280px;
96
+ max-width: calc(100vw - 32px);
97
+ box-sizing: border-box;
98
+ font-family: inherit;
99
+ }
100
+
101
+ .file-list {
102
+ display: flex;
103
+ flex-direction: column;
104
+ gap: 6px;
105
+ padding: 12px;
106
+ max-height: calc(100vh - 200px);
107
+ overflow-y: auto;
108
+ box-sizing: border-box;
109
+ }
110
+
111
+ .file-row {
112
+ position: relative;
113
+ display: flex;
114
+ align-items: center;
115
+ gap: 10px;
116
+ padding: 8px 10px;
117
+ border-radius: 8px;
118
+ background: #f5f5f5;
119
+ min-width: 0;
120
+ }
121
+
122
+ .file-thumb {
123
+ flex: none;
124
+ width: 36px;
125
+ height: 36px;
126
+ border-radius: 6px;
127
+ background: #fff;
128
+ display: flex;
129
+ align-items: center;
130
+ justify-content: center;
131
+ overflow: hidden;
132
+ color: #555;
133
+ }
134
+
135
+ .file-thumb img {
136
+ width: 100%;
137
+ height: 100%;
138
+ object-fit: cover;
139
+ }
140
+
141
+ .file-thumb svg {
142
+ width: 20px;
143
+ height: 20px;
144
+ }
145
+
146
+ .file-info {
147
+ flex: 1;
148
+ min-width: 0;
149
+ display: flex;
150
+ flex-direction: column;
151
+ gap: 2px;
152
+ }
153
+
154
+ .file-name {
155
+ font-size: 13px;
156
+ color: #222;
157
+ white-space: nowrap;
158
+ overflow: hidden;
159
+ text-overflow: ellipsis;
160
+ text-decoration: none;
161
+ }
162
+
163
+ a.file-name:hover {
164
+ text-decoration: underline;
165
+ }
166
+
167
+ .file-meta {
168
+ font-size: 11px;
169
+ color: #777;
170
+ text-transform: uppercase;
171
+ }
172
+
173
+ .remove-btn {
174
+ flex: none;
175
+ width: 28px;
176
+ height: 28px;
177
+ border-radius: 6px;
178
+ background: transparent;
179
+ color: #888;
180
+ display: flex;
181
+ align-items: center;
182
+ justify-content: center;
183
+ cursor: pointer;
184
+ border: none;
185
+ padding: 0;
186
+ }
187
+
188
+ .remove-btn:hover {
189
+ background: #fde8e8;
190
+ color: #d32f2f;
191
+ }
192
+
193
+ .add-row {
194
+ position: relative;
195
+ margin-top: 2px;
196
+ }
197
+
198
+ .add-files-btn {
199
+ width: 100%;
200
+ box-sizing: border-box;
201
+ min-height: 44px;
202
+ display: flex;
203
+ align-items: center;
204
+ justify-content: center;
205
+ gap: 8px;
206
+ cursor: pointer;
207
+ border: 2px dashed #ccc;
208
+ border-radius: 8px;
209
+ background: transparent;
210
+ font-size: 13px;
211
+ color: #444;
212
+ }
213
+
214
+ .add-files-btn svg {
215
+ width: 18px;
216
+ height: 18px;
217
+ }
218
+
219
+ .add-files-btn:hover {
220
+ border-color: #666;
221
+ }
222
+
223
+ .error-message {
224
+ color: red;
225
+ font-size: 12px;
226
+ text-align: center;
227
+ padding: 8px;
228
+ }
229
+
230
+ .loading-overlay {
231
+ position: absolute;
232
+ top: 0;
233
+ left: 0;
234
+ right: 0;
235
+ bottom: 0;
236
+ background: rgba(255, 255, 255, 0.9);
237
+ display: flex;
238
+ flex-direction: column;
239
+ align-items: center;
240
+ justify-content: center;
241
+ z-index: 10;
242
+ border-radius: 8px;
243
+ backdrop-filter: blur(2px);
244
+ }
245
+
246
+ .loading-spinner {
247
+ width: 32px;
248
+ height: 32px;
249
+ border: 3px solid #f3f3f3;
250
+ border-top: 3px solid #3498db;
251
+ border-radius: 50%;
252
+ animation: spin 1s linear infinite;
253
+ margin-bottom: 8px;
254
+ }
255
+
256
+ .loading-text {
257
+ font-size: 12px;
258
+ color: #666;
259
+ text-align: center;
260
+ margin-top: 4px;
261
+ }
262
+
263
+ @keyframes spin {
264
+ 0% {
265
+ transform: rotate(0deg);
266
+ }
267
+ 100% {
268
+ transform: rotate(360deg);
269
+ }
270
+ }
271
+
272
+ .loading-button {
273
+ opacity: 0.7;
274
+ pointer-events: none;
275
+ }
276
+
277
+ .button-loading-spinner {
278
+ width: 18px;
279
+ height: 18px;
280
+ border: 2px solid #f3f3f3;
281
+ border-top: 2px solid #3498db;
282
+ border-radius: 50%;
283
+ animation: spin 1s linear infinite;
284
+ }
285
+
286
+ .preview-section {
287
+ margin-top: 8px;
288
+ display: flex;
289
+ gap: 8px;
290
+ flex-wrap: wrap;
291
+ }
292
+
293
+ .preview-item {
294
+ display: flex;
295
+ align-items: center;
296
+ gap: 4px;
297
+ padding: 4px 8px;
298
+ background: #f5f5f5;
299
+ border-radius: 4px;
300
+ font-size: 12px;
301
+ }
302
+ paper-button {
303
+ min-width: 10px;
304
+ }
305
+ .preview-item cdtr-icon {
306
+ width: 16px;
307
+ height: 16px;
308
+ }
309
+
310
+ .button-container {
311
+ position: relative;
312
+ display: inline-block;
313
+ }
314
+
315
+ .count-badge {
316
+ position: absolute;
317
+ top: 2px;
318
+ right: 2px;
319
+ min-width: 16px;
320
+ height: 16px;
321
+ padding: 0 4px;
322
+ box-sizing: border-box;
323
+ border-radius: 8px;
324
+ background: #e53935;
325
+ color: #fff;
326
+ font-size: 10px;
327
+ font-weight: 600;
328
+ line-height: 16px;
329
+ text-align: center;
330
+ pointer-events: none;
331
+ z-index: 2;
332
+ }
333
+
334
+ `,n.properties={files:{type:Array},maxFiles:{type:Number},maxFileSizeMB:{type:Number},isLoading:{type:Boolean},buttonText:{type:String},addFilesText:{type:String},maxFilesReachedText:{type:String},iconColor:{type:String},fileTooLargeText:{type:String},error:{type:String},customColor:{type:String},customTextColor:{type:String},loadingText:{type:String}},a=n,l=(0,p.A)(a.prototype,"lazyLoad",[o],{configurable:!0,enumerable:!0,writable:!0,initializer:function(){return null}}),r=a))||r)}}]);
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
@@ -1,4 +1,4 @@
1
- "use strict";(("undefined"!=typeof self?self:this).webpackChunkCreaditor=("undefined"!=typeof self?self:this).webpackChunkCreaditor||[]).push([[4819],{84819(t,e,i){i.r(e),i.d(e,{NameAndSubjectPlugin:()=>c});var o=i(59929),r=i(49410);i(78533);function s(){return window.___cdtr_isConsoleLogged||console.log("%cWe run on production, if you want to point to dev server, please add ?dev=1 at the url","color:green"),window.___cdtr_isConsoleLogged=!0,!1}window.___cdtr_isConsoleLogged=window.___cdtr_isConsoleLogged||!1,s(),s(),s(),s(),s(),s();const n=`${s()?"http://127.0.0.1:8000":"https://studio.creaditor.ai"}/api/email-subject`;async function a(t,e){const i=Array.from(document.querySelectorAll(".text-component")).map(t=>(t.textContent||"").trim()).filter(Boolean).join("\n");if(!i)throw new Error("The newsletter has no text yet");const o=JSON.stringify({content:i,field:t,...e.current?{current:e.current}:{},...e.subject?{subject:e.subject}:{},...e.docId?{doc_id:e.docId}:{}}),r=async t=>{const i=e.getToken?await e.getToken(t):null;return fetch(n,{method:"POST",headers:{"Content-Type":"application/json",...i?{Authorization:`Bearer ${i}`}:{}},body:o})};let s=await r(!1);if(401===s.status&&(s=await r(!0)),!s.ok)throw new Error(`HTTP error! status: ${s.status}`);const a=await s.json(),l="subject"===t?a.subject:a.preheader;if(!l)throw new Error("Empty result");return l}var l=Object.defineProperty,d=(t,e,i,o)=>{for(var r,s=void 0,n=t.length-1;n>=0;n--)(r=t[n])&&(s=r(e,i,s)||s);return s&&l(e,i,s),s};typeof window<"u"&&!window.__polymerElementsLoaded&&(window.__polymerElementsLoaded=!0,(async()=>{try{const t=["paper-dropdown-menu","paper-item","paper-listbox"].filter(t=>customElements.get(t));if(t.length>0)return void console.warn(`Polymer elements already loaded: ${t.join(", ")}. Skipping imports to prevent conflicts.`);if(customElements.get("dom-module"))return void console.warn("dom-module already defined, skipping Polymer element imports to prevent conflicts");await Promise.all([Promise.all([i.e(59),i.e(9158),i.e(7789),i.e(574)]).then(i.bind(i,50574)),i.e(898).then(i.bind(i,90898)),Promise.all([i.e(6216),i.e(7463)]).then(i.bind(i,97463))]),console.log("Polymer elements loaded successfully")}catch(t){console.warn("Failed to load Polymer elements:",t)}})().catch(console.error));const p="cdtr-name-and-subject-plugin",u=class extends o.WF{constructor(){super(...arguments),this.bgColor="#000",this.textColor="#000000",this.headerText="Details",this.nameLabel="Name",this.subjectLabel="Subject",this.subtitleLabel="Subtitle",this.saveButtonText="Save",this.subjectPlaceholder="Enter subject",this.mergeTags=[],this.name="",this.subject="",this.subtitle="",this.save=()=>{},this.docId="",this.isGeneratingSubject=!1,this.isGeneratingSubtitle=!1}getTextDirection(t){return/[\u0590-\u05FF]/.test(t)?"rtl":"ltr"}getPlaceholderStyle(){const t=this.getTextDirection(this.subjectPlaceholder);return`direction: ${t}; text-align: ${"rtl"===t?"right":"left"};`}handleSave(){"string"!=typeof this.subtitle&&(this.subtitle=""),"string"!=typeof this.subject&&(this.subject=""),this.dispatchEvent(new CustomEvent("save",{detail:{name:this.name,subject:this.subject,subtitle:this.subtitle}})),this.save(),setTimeout(()=>{var t,e;null==(e=null==(t=this.shadowRoot)?void 0:t.querySelector("#name-popover"))||e.close()},200)}handleFieldClick(t){this.subject+=t.value,this.requestUpdate()}handleEmojiSelect(t){const e=t.detail.unicode;this.subject=this.subject+e,this.requestUpdate()}open(){var t,e;null==(e=null==(t=this.shadowRoot)?void 0:t.querySelector("#name-popover"))||e.open()}focusInputs(t){var e;this.open();const i=null==(e=this.shadowRoot)?void 0:e.querySelectorAll("input");if(i)if(i.forEach(t=>t.classList.remove("shake")),t){const e=Array.from(i).find(e=>{var i;const o=e.previousElementSibling;return null==(i=null==o?void 0:o.textContent)?void 0:i.toLowerCase().includes(t.toLowerCase())});e&&(e.focus(),e.classList.add("shake"))}else i.forEach(t=>{t.focus(),t.classList.add("shake")})}handleGenerateSubject(){if(this.isGeneratingSubject)return;const t=this.subject||"";this.subject="",this.isGeneratingSubject=!0,this.requestUpdate(),async function(t){let e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};try{t(await a("subject",e))}catch(t){throw console.error("Error generating subject:",t),t}}(t=>{this.subject+=t,this.requestUpdate()},{getToken:this.studioTokenProvider,current:t,docId:this.docId}).catch(()=>{this.subject=t}).finally(()=>{this.isGeneratingSubject=!1,this.requestUpdate()})}handleGenerateSubtitle(){if(this.isGeneratingSubtitle)return;const t=this.subtitle||"";this.subtitle="",this.isGeneratingSubtitle=!0,this.requestUpdate(),async function(t){let e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};try{t(await a("preheader",e))}catch(t){throw console.error("Error generating subtitle:",t),t}}(t=>{this.subtitle+=t,this.requestUpdate()},{getToken:this.studioTokenProvider,current:t,subject:this.subject,docId:this.docId}).catch(()=>{this.subtitle=t}).finally(()=>{this.isGeneratingSubtitle=!1,this.requestUpdate()})}render(){return o.qy`
1
+ "use strict";(("undefined"!=typeof self?self:this).webpackChunkCreaditor=("undefined"!=typeof self?self:this).webpackChunkCreaditor||[]).push([[6323],{66323(t,e,i){i.r(e),i.d(e,{NameAndSubjectPlugin:()=>D});var r=i(59088),o=i(36936),n=i(59929),s=i(49410);i(78533);const a=`${(0,i(86959).Ay)()?"http://127.0.0.1:8000":"https://studio.creaditor.ai"}/api/email-subject`;async function l(t,e){const i=Array.from(document.querySelectorAll(".text-component")).map(t=>(t.textContent||"").trim()).filter(Boolean).join("\n");if(!i)throw new Error("The newsletter has no text yet");const r=JSON.stringify({content:i,field:t,...e.current?{current:e.current}:{},...e.subject?{subject:e.subject}:{},...e.docId?{doc_id:e.docId}:{}}),o=async t=>{const i=e.getToken?await e.getToken(t):null;return fetch(a,{method:"POST",headers:{"Content-Type":"application/json",...i?{Authorization:`Bearer ${i}`}:{}},body:r})};let n=await o(!1);if(401===n.status&&(n=await o(!0)),!n.ok)throw new Error(`HTTP error! status: ${n.status}`);const s=await n.json(),l="subject"===t?s.subject:s.preheader;if(!l)throw new Error("Empty result");return l}var u,p,d,c,h,b,g,f,C,m,v,w,y,x,L,j,k,M,S,A,$,Z,z,T,P,E,q,G,B,I,U,H,F,R,X,_;"undefined"==typeof window||window.__polymerElementsLoaded||(window.__polymerElementsLoaded=!0,(async()=>{try{const t=["paper-dropdown-menu","paper-item","paper-listbox"].filter(t=>customElements.get(t));if(t.length>0)return void console.warn(`Polymer elements already loaded: ${t.join(", ")}. Skipping imports to prevent conflicts.`);if(customElements.get("dom-module"))return void console.warn("dom-module already defined, skipping Polymer element imports to prevent conflicts");await Promise.all([Promise.all([i.e(59),i.e(9158),i.e(7789),i.e(574)]).then(i.bind(i,50574)),i.e(898).then(i.bind(i,90898)),Promise.all([i.e(6216),i.e(7463)]).then(i.bind(i,97463))]),console.log("Polymer elements loaded successfully")}catch(t){console.warn("Failed to load Polymer elements:",t)}})().catch(console.error));const V="cdtr-name-and-subject-plugin";let D=(u=(0,s.MZ)({type:String}),p=(0,s.MZ)({type:String}),d=(0,s.MZ)({type:String}),c=(0,s.MZ)({type:String}),h=(0,s.MZ)({type:String}),b=(0,s.MZ)({type:String}),g=(0,s.MZ)({type:String}),f=(0,s.MZ)({type:String}),C=(0,s.MZ)({type:Array}),m=(0,s.MZ)({type:String}),v=(0,s.MZ)({type:String}),w=(0,s.MZ)({type:String}),y=(0,s.MZ)({attribute:!1}),x=(0,s.MZ)({attribute:!1}),L=(0,s.MZ)({type:String}),j=(0,s.MZ)({type:Boolean}),k=(0,s.MZ)({type:Boolean}),_=class extends n.WF{constructor(){super(...arguments),(0,r.A)(this,"bgColor",S,this),(0,r.A)(this,"textColor",A,this),(0,r.A)(this,"headerText",$,this),(0,r.A)(this,"nameLabel",Z,this),(0,r.A)(this,"subjectLabel",z,this),(0,r.A)(this,"subtitleLabel",T,this),(0,r.A)(this,"saveButtonText",P,this),(0,r.A)(this,"subjectPlaceholder",E,this),(0,r.A)(this,"mergeTags",q,this),(0,r.A)(this,"name",G,this),(0,r.A)(this,"subject",B,this),(0,r.A)(this,"subtitle",I,this),(0,r.A)(this,"save",U,this),(0,r.A)(this,"studioTokenProvider",H,this),(0,r.A)(this,"docId",F,this),(0,r.A)(this,"isGeneratingSubject",R,this),(0,r.A)(this,"isGeneratingSubtitle",X,this)}getTextDirection(t){return/[\u0590-\u05FF]/.test(t)?"rtl":"ltr"}getPlaceholderStyle(){const t=this.getTextDirection(this.subjectPlaceholder);return`direction: ${t}; text-align: ${"rtl"===t?"right":"left"};`}handleSave(){"string"!=typeof this.subtitle&&(this.subtitle=""),"string"!=typeof this.subject&&(this.subject=""),this.dispatchEvent(new CustomEvent("save",{detail:{name:this.name,subject:this.subject,subtitle:this.subtitle}})),this.save(),setTimeout(()=>{this.shadowRoot?.querySelector("#name-popover")?.close()},200)}handleFieldClick(t){this.subject+=t.value,this.requestUpdate()}handleEmojiSelect(t){const e=t.detail.unicode;this.subject=this.subject+e,this.requestUpdate()}open(){this.shadowRoot?.querySelector("#name-popover")?.open()}focusInputs(t){this.open();const e=this.shadowRoot?.querySelectorAll("input");if(e)if(e.forEach(t=>t.classList.remove("shake")),t){const i=Array.from(e).find(e=>{const i=e.previousElementSibling;return i?.textContent?.toLowerCase().includes(t.toLowerCase())});i&&(i.focus(),i.classList.add("shake"))}else e.forEach(t=>{t.focus(),t.classList.add("shake")})}handleGenerateSubject(){if(this.isGeneratingSubject)return;const t=this.subject||"";this.subject="",this.isGeneratingSubject=!0,this.requestUpdate(),async function(t){let e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};try{t(await l("subject",e))}catch(t){throw console.error("Error generating subject:",t),t}}(t=>{this.subject+=t,this.requestUpdate()},{getToken:this.studioTokenProvider,current:t,docId:this.docId}).catch(()=>{this.subject=t}).finally(()=>{this.isGeneratingSubject=!1,this.requestUpdate()})}handleGenerateSubtitle(){if(this.isGeneratingSubtitle)return;const t=this.subtitle||"";this.subtitle="",this.isGeneratingSubtitle=!0,this.requestUpdate(),async function(t){let e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};try{t(await l("preheader",e))}catch(t){throw console.error("Error generating subtitle:",t),t}}(t=>{this.subtitle+=t,this.requestUpdate()},{getToken:this.studioTokenProvider,current:t,subject:this.subject,docId:this.docId}).catch(()=>{this.subtitle=t}).finally(()=>{this.isGeneratingSubtitle=!1,this.requestUpdate()})}render(){return n.qy`
2
2
  <div class="subject-input">
3
3
  <div class="subject-input-left">
4
4
  <cdtr-popover width="400px">
@@ -28,7 +28,7 @@
28
28
  </div>
29
29
  </cdtr-popover>
30
30
 
31
- ${this.mergeTags.length>0?o.qy` <cdtr-popover>
31
+ ${this.mergeTags.length>0?n.qy` <cdtr-popover>
32
32
  <paper-button
33
33
  style=${`color:${this.textColor}`}
34
34
  size="sm"
@@ -52,7 +52,7 @@
52
52
  <div class="popover-header">
53
53
  <h3 dir="auto">${this.headerText}</h3>
54
54
  </div>
55
- ${this.mergeTags.map(t=>o.qy`
55
+ ${this.mergeTags.map(t=>n.qy`
56
56
  <div
57
57
  class="field-item"
58
58
  @click=${()=>this.handleFieldClick(t)}
@@ -119,7 +119,7 @@
119
119
  ?disabled=${this.isGeneratingSubject}
120
120
  class="generate-button"
121
121
  >
122
- ${this.isGeneratingSubject?o.qy` <div class="loading-spinner"></div> `:o.qy`
122
+ ${this.isGeneratingSubject?n.qy` <div class="loading-spinner"></div> `:n.qy`
123
123
  <svg
124
124
  xmlns="http://www.w3.org/2000/svg"
125
125
  xmlnsXlink="http://www.w3.org/1999/xlink"
@@ -166,7 +166,7 @@
166
166
  ?disabled=${this.isGeneratingSubtitle}
167
167
  class="generate-button"
168
168
  >
169
- ${this.isGeneratingSubtitle?o.qy` <div class="loading-spinner"></div> `:o.qy`
169
+ ${this.isGeneratingSubtitle?n.qy` <div class="loading-spinner"></div> `:n.qy`
170
170
  <svg
171
171
  xmlns="http://www.w3.org/2000/svg"
172
172
  xmlnsXlink="http://www.w3.org/1999/xlink"
@@ -217,7 +217,7 @@
217
217
  </div>
218
218
  </cdtr-popover>
219
219
  </div>
220
- `}};u.styles=o.AH`
220
+ `}},_.styles=n.AH`
221
221
  * {
222
222
  box-sizing: border-box;
223
223
  }
@@ -404,4 +404,4 @@
404
404
  --button-active-background: #f1f3f5;
405
405
  --font-size: 14px;
406
406
  }
407
- `;let c=u;d([(0,r.MZ)({type:String})],c.prototype,"bgColor"),d([(0,r.MZ)({type:String})],c.prototype,"textColor"),d([(0,r.MZ)({type:String})],c.prototype,"headerText"),d([(0,r.MZ)({type:String})],c.prototype,"nameLabel"),d([(0,r.MZ)({type:String})],c.prototype,"subjectLabel"),d([(0,r.MZ)({type:String})],c.prototype,"subtitleLabel"),d([(0,r.MZ)({type:String})],c.prototype,"saveButtonText"),d([(0,r.MZ)({type:String})],c.prototype,"subjectPlaceholder"),d([(0,r.MZ)({type:Array})],c.prototype,"mergeTags"),d([(0,r.MZ)({type:String})],c.prototype,"name"),d([(0,r.MZ)({type:String})],c.prototype,"subject"),d([(0,r.MZ)({type:String})],c.prototype,"subtitle"),d([(0,r.MZ)({attribute:!1})],c.prototype,"save"),d([(0,r.MZ)({attribute:!1})],c.prototype,"studioTokenProvider"),d([(0,r.MZ)({type:String})],c.prototype,"docId"),d([(0,r.MZ)({type:Boolean})],c.prototype,"isGeneratingSubject"),d([(0,r.MZ)({type:Boolean})],c.prototype,"isGeneratingSubtitle"),customElements.get(p)||customElements.define(p,c)}}]);
407
+ `,M=_,S=(0,o.A)(M.prototype,"bgColor",[u],{configurable:!0,enumerable:!0,writable:!0,initializer:function(){return"#000"}}),A=(0,o.A)(M.prototype,"textColor",[p],{configurable:!0,enumerable:!0,writable:!0,initializer:function(){return"#000000"}}),$=(0,o.A)(M.prototype,"headerText",[d],{configurable:!0,enumerable:!0,writable:!0,initializer:function(){return"Details"}}),Z=(0,o.A)(M.prototype,"nameLabel",[c],{configurable:!0,enumerable:!0,writable:!0,initializer:function(){return"Name"}}),z=(0,o.A)(M.prototype,"subjectLabel",[h],{configurable:!0,enumerable:!0,writable:!0,initializer:function(){return"Subject"}}),T=(0,o.A)(M.prototype,"subtitleLabel",[b],{configurable:!0,enumerable:!0,writable:!0,initializer:function(){return"Subtitle"}}),P=(0,o.A)(M.prototype,"saveButtonText",[g],{configurable:!0,enumerable:!0,writable:!0,initializer:function(){return"Save"}}),E=(0,o.A)(M.prototype,"subjectPlaceholder",[f],{configurable:!0,enumerable:!0,writable:!0,initializer:function(){return"Enter subject"}}),q=(0,o.A)(M.prototype,"mergeTags",[C],{configurable:!0,enumerable:!0,writable:!0,initializer:function(){return[]}}),G=(0,o.A)(M.prototype,"name",[m],{configurable:!0,enumerable:!0,writable:!0,initializer:function(){return""}}),B=(0,o.A)(M.prototype,"subject",[v],{configurable:!0,enumerable:!0,writable:!0,initializer:function(){return""}}),I=(0,o.A)(M.prototype,"subtitle",[w],{configurable:!0,enumerable:!0,writable:!0,initializer:function(){return""}}),U=(0,o.A)(M.prototype,"save",[y],{configurable:!0,enumerable:!0,writable:!0,initializer:function(){return()=>{}}}),H=(0,o.A)(M.prototype,"studioTokenProvider",[x],{configurable:!0,enumerable:!0,writable:!0,initializer:null}),F=(0,o.A)(M.prototype,"docId",[L],{configurable:!0,enumerable:!0,writable:!0,initializer:function(){return""}}),R=(0,o.A)(M.prototype,"isGeneratingSubject",[j],{configurable:!0,enumerable:!0,writable:!0,initializer:function(){return!1}}),X=(0,o.A)(M.prototype,"isGeneratingSubtitle",[k],{configurable:!0,enumerable:!0,writable:!0,initializer:function(){return!1}}),M);customElements.get(V)||customElements.define(V,D)}}]);
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file