@ng-nest/ui 20.1.6 → 20.2.0

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 (203) hide show
  1. package/attachments/index.d.ts +277 -0
  2. package/auto-complete/index.d.ts +11 -2
  3. package/card/index.d.ts +12 -2
  4. package/cascade/index.d.ts +2 -1
  5. package/collapse/index.d.ts +0 -3
  6. package/color-picker/index.d.ts +2 -1
  7. package/core/index.d.ts +41 -43
  8. package/date-picker/index.d.ts +20 -4
  9. package/dialog/index.d.ts +8 -10
  10. package/drawer/index.d.ts +10 -12
  11. package/dropdown/index.d.ts +32 -9
  12. package/fesm2022/ng-nest-ui-affix.mjs +11 -11
  13. package/fesm2022/ng-nest-ui-alert.mjs +13 -13
  14. package/fesm2022/ng-nest-ui-alert.mjs.map +1 -1
  15. package/fesm2022/ng-nest-ui-anchor.mjs +18 -18
  16. package/fesm2022/ng-nest-ui-anchor.mjs.map +1 -1
  17. package/fesm2022/ng-nest-ui-api.mjs +7 -7
  18. package/fesm2022/ng-nest-ui-api.mjs.map +1 -1
  19. package/fesm2022/ng-nest-ui-attachments.mjs +331 -0
  20. package/fesm2022/ng-nest-ui-attachments.mjs.map +1 -0
  21. package/fesm2022/ng-nest-ui-auto-complete.mjs +36 -26
  22. package/fesm2022/ng-nest-ui-auto-complete.mjs.map +1 -1
  23. package/fesm2022/ng-nest-ui-avatar.mjs +18 -18
  24. package/fesm2022/ng-nest-ui-avatar.mjs.map +1 -1
  25. package/fesm2022/ng-nest-ui-back-top.mjs +12 -12
  26. package/fesm2022/ng-nest-ui-back-top.mjs.map +1 -1
  27. package/fesm2022/ng-nest-ui-badge.mjs +13 -13
  28. package/fesm2022/ng-nest-ui-badge.mjs.map +1 -1
  29. package/fesm2022/ng-nest-ui-base-form.mjs +8 -8
  30. package/fesm2022/ng-nest-ui-bubble.mjs +20 -20
  31. package/fesm2022/ng-nest-ui-bubble.mjs.map +1 -1
  32. package/fesm2022/ng-nest-ui-button.mjs +19 -19
  33. package/fesm2022/ng-nest-ui-button.mjs.map +1 -1
  34. package/fesm2022/ng-nest-ui-calendar.mjs +11 -11
  35. package/fesm2022/ng-nest-ui-card.mjs +20 -14
  36. package/fesm2022/ng-nest-ui-card.mjs.map +1 -1
  37. package/fesm2022/ng-nest-ui-carousel.mjs +21 -21
  38. package/fesm2022/ng-nest-ui-carousel.mjs.map +1 -1
  39. package/fesm2022/ng-nest-ui-cascade.mjs +27 -25
  40. package/fesm2022/ng-nest-ui-cascade.mjs.map +1 -1
  41. package/fesm2022/ng-nest-ui-checkbox.mjs +12 -12
  42. package/fesm2022/ng-nest-ui-checkbox.mjs.map +1 -1
  43. package/fesm2022/ng-nest-ui-collapse.mjs +20 -28
  44. package/fesm2022/ng-nest-ui-collapse.mjs.map +1 -1
  45. package/fesm2022/ng-nest-ui-color-picker.mjs +31 -29
  46. package/fesm2022/ng-nest-ui-color-picker.mjs.map +1 -1
  47. package/fesm2022/ng-nest-ui-color.mjs +11 -11
  48. package/fesm2022/ng-nest-ui-color.mjs.map +1 -1
  49. package/fesm2022/ng-nest-ui-comment.mjs +18 -18
  50. package/fesm2022/ng-nest-ui-container.mjs +35 -35
  51. package/fesm2022/ng-nest-ui-container.mjs.map +1 -1
  52. package/fesm2022/ng-nest-ui-core.mjs +48 -148
  53. package/fesm2022/ng-nest-ui-core.mjs.map +1 -1
  54. package/fesm2022/ng-nest-ui-coversations.mjs +11 -11
  55. package/fesm2022/ng-nest-ui-crumb.mjs +11 -11
  56. package/fesm2022/ng-nest-ui-date-picker.mjs +92 -78
  57. package/fesm2022/ng-nest-ui-date-picker.mjs.map +1 -1
  58. package/fesm2022/ng-nest-ui-description.mjs +20 -20
  59. package/fesm2022/ng-nest-ui-description.mjs.map +1 -1
  60. package/fesm2022/ng-nest-ui-dialog.mjs +68 -67
  61. package/fesm2022/ng-nest-ui-dialog.mjs.map +1 -1
  62. package/fesm2022/ng-nest-ui-doc.mjs +7 -7
  63. package/fesm2022/ng-nest-ui-doc.mjs.map +1 -1
  64. package/fesm2022/ng-nest-ui-drag.mjs +11 -11
  65. package/fesm2022/ng-nest-ui-drawer.mjs +67 -84
  66. package/fesm2022/ng-nest-ui-drawer.mjs.map +1 -1
  67. package/fesm2022/ng-nest-ui-dropdown.mjs +182 -58
  68. package/fesm2022/ng-nest-ui-dropdown.mjs.map +1 -1
  69. package/fesm2022/ng-nest-ui-empty.mjs +11 -11
  70. package/fesm2022/ng-nest-ui-examples.mjs +7 -7
  71. package/fesm2022/ng-nest-ui-examples.mjs.map +1 -1
  72. package/fesm2022/ng-nest-ui-find.mjs +12 -12
  73. package/fesm2022/ng-nest-ui-find.mjs.map +1 -1
  74. package/fesm2022/ng-nest-ui-form.mjs +19 -19
  75. package/fesm2022/ng-nest-ui-form.mjs.map +1 -1
  76. package/fesm2022/ng-nest-ui-highlight.mjs +15 -15
  77. package/fesm2022/ng-nest-ui-highlight.mjs.map +1 -1
  78. package/fesm2022/ng-nest-ui-i18n.mjs +14 -14
  79. package/fesm2022/ng-nest-ui-icon.mjs +14 -14
  80. package/fesm2022/ng-nest-ui-icon.mjs.map +1 -1
  81. package/fesm2022/ng-nest-ui-image.mjs +22 -22
  82. package/fesm2022/ng-nest-ui-image.mjs.map +1 -1
  83. package/fesm2022/ng-nest-ui-inner.mjs +11 -11
  84. package/fesm2022/ng-nest-ui-inner.mjs.map +1 -1
  85. package/fesm2022/ng-nest-ui-input-number.mjs +12 -12
  86. package/fesm2022/ng-nest-ui-input-number.mjs.map +1 -1
  87. package/fesm2022/ng-nest-ui-input.mjs +19 -19
  88. package/fesm2022/ng-nest-ui-input.mjs.map +1 -1
  89. package/fesm2022/ng-nest-ui-keyword.mjs +11 -11
  90. package/fesm2022/ng-nest-ui-keyword.mjs.map +1 -1
  91. package/fesm2022/ng-nest-ui-layout.mjs +18 -18
  92. package/fesm2022/ng-nest-ui-layout.mjs.map +1 -1
  93. package/fesm2022/ng-nest-ui-link.mjs +12 -12
  94. package/fesm2022/ng-nest-ui-link.mjs.map +1 -1
  95. package/fesm2022/ng-nest-ui-list.mjs +52 -28
  96. package/fesm2022/ng-nest-ui-list.mjs.map +1 -1
  97. package/fesm2022/ng-nest-ui-loading.mjs +12 -12
  98. package/fesm2022/ng-nest-ui-loading.mjs.map +1 -1
  99. package/fesm2022/ng-nest-ui-menu.mjs +18 -18
  100. package/fesm2022/ng-nest-ui-message-box.mjs +10 -10
  101. package/fesm2022/ng-nest-ui-message.mjs +10 -10
  102. package/fesm2022/ng-nest-ui-notification.mjs +10 -10
  103. package/fesm2022/ng-nest-ui-outlet.mjs +8 -8
  104. package/fesm2022/ng-nest-ui-page-header.mjs +11 -11
  105. package/fesm2022/ng-nest-ui-pagination.mjs +11 -11
  106. package/fesm2022/ng-nest-ui-pagination.mjs.map +1 -1
  107. package/fesm2022/ng-nest-ui-pattern.mjs +7 -7
  108. package/fesm2022/ng-nest-ui-pattern.mjs.map +1 -1
  109. package/fesm2022/ng-nest-ui-popconfirm.mjs +11 -11
  110. package/fesm2022/ng-nest-ui-popover.mjs +25 -21
  111. package/fesm2022/ng-nest-ui-popover.mjs.map +1 -1
  112. package/fesm2022/ng-nest-ui-portal.mjs +7 -7
  113. package/fesm2022/ng-nest-ui-progress.mjs +11 -11
  114. package/fesm2022/ng-nest-ui-prompts.mjs +17 -12
  115. package/fesm2022/ng-nest-ui-prompts.mjs.map +1 -1
  116. package/fesm2022/ng-nest-ui-radio.mjs +12 -12
  117. package/fesm2022/ng-nest-ui-radio.mjs.map +1 -1
  118. package/fesm2022/ng-nest-ui-rate.mjs +12 -12
  119. package/fesm2022/ng-nest-ui-rate.mjs.map +1 -1
  120. package/fesm2022/ng-nest-ui-resizable.mjs +11 -11
  121. package/fesm2022/ng-nest-ui-resizable.mjs.map +1 -1
  122. package/fesm2022/ng-nest-ui-result.mjs +11 -11
  123. package/fesm2022/ng-nest-ui-ripple.mjs +11 -11
  124. package/fesm2022/ng-nest-ui-ripple.mjs.map +1 -1
  125. package/fesm2022/ng-nest-ui-scrollable.mjs +8 -8
  126. package/fesm2022/ng-nest-ui-scrollable.mjs.map +1 -1
  127. package/fesm2022/ng-nest-ui-select.mjs +37 -26
  128. package/fesm2022/ng-nest-ui-select.mjs.map +1 -1
  129. package/fesm2022/ng-nest-ui-sender.mjs +19 -18
  130. package/fesm2022/ng-nest-ui-sender.mjs.map +1 -1
  131. package/fesm2022/ng-nest-ui-skeleton.mjs +11 -11
  132. package/fesm2022/ng-nest-ui-slider-select.mjs +13 -13
  133. package/fesm2022/ng-nest-ui-slider-select.mjs.map +1 -1
  134. package/fesm2022/ng-nest-ui-slider.mjs +12 -12
  135. package/fesm2022/ng-nest-ui-slider.mjs.map +1 -1
  136. package/fesm2022/ng-nest-ui-statistic.mjs +18 -18
  137. package/fesm2022/ng-nest-ui-steps.mjs +11 -11
  138. package/fesm2022/ng-nest-ui-suggestion.mjs +110 -0
  139. package/fesm2022/ng-nest-ui-suggestion.mjs.map +1 -0
  140. package/fesm2022/ng-nest-ui-switch.mjs +12 -12
  141. package/fesm2022/ng-nest-ui-switch.mjs.map +1 -1
  142. package/fesm2022/ng-nest-ui-table-view.mjs +60 -60
  143. package/fesm2022/ng-nest-ui-table-view.mjs.map +1 -1
  144. package/fesm2022/ng-nest-ui-table.mjs +58 -47
  145. package/fesm2022/ng-nest-ui-table.mjs.map +1 -1
  146. package/fesm2022/ng-nest-ui-tabs.mjs +30 -30
  147. package/fesm2022/ng-nest-ui-tabs.mjs.map +1 -1
  148. package/fesm2022/ng-nest-ui-tag.mjs +22 -18
  149. package/fesm2022/ng-nest-ui-tag.mjs.map +1 -1
  150. package/fesm2022/ng-nest-ui-text-retract.mjs +11 -11
  151. package/fesm2022/ng-nest-ui-textarea.mjs +12 -12
  152. package/fesm2022/ng-nest-ui-textarea.mjs.map +1 -1
  153. package/fesm2022/ng-nest-ui-theme.mjs +11 -11
  154. package/fesm2022/ng-nest-ui-thought-chain.mjs +121 -0
  155. package/fesm2022/ng-nest-ui-thought-chain.mjs.map +1 -0
  156. package/fesm2022/ng-nest-ui-time-ago.mjs +7 -7
  157. package/fesm2022/ng-nest-ui-time-picker.mjs +31 -29
  158. package/fesm2022/ng-nest-ui-time-picker.mjs.map +1 -1
  159. package/fesm2022/ng-nest-ui-time-range.mjs +7 -7
  160. package/fesm2022/ng-nest-ui-timeline.mjs +36 -14
  161. package/fesm2022/ng-nest-ui-timeline.mjs.map +1 -1
  162. package/fesm2022/ng-nest-ui-tooltip.mjs +27 -74
  163. package/fesm2022/ng-nest-ui-tooltip.mjs.map +1 -1
  164. package/fesm2022/ng-nest-ui-transfer.mjs +12 -12
  165. package/fesm2022/ng-nest-ui-transfer.mjs.map +1 -1
  166. package/fesm2022/ng-nest-ui-tree-file.mjs +11 -11
  167. package/fesm2022/ng-nest-ui-tree-select.mjs +27 -25
  168. package/fesm2022/ng-nest-ui-tree-select.mjs.map +1 -1
  169. package/fesm2022/ng-nest-ui-tree.mjs +23 -23
  170. package/fesm2022/ng-nest-ui-tree.mjs.map +1 -1
  171. package/fesm2022/ng-nest-ui-typography.mjs +11 -11
  172. package/fesm2022/ng-nest-ui-upload.mjs +221 -24
  173. package/fesm2022/ng-nest-ui-upload.mjs.map +1 -1
  174. package/fesm2022/ng-nest-ui-welcome.mjs +11 -11
  175. package/fesm2022/ng-nest-ui.mjs +4 -0
  176. package/fesm2022/ng-nest-ui.mjs.map +1 -1
  177. package/index.d.ts +4 -0
  178. package/list/index.d.ts +30 -18
  179. package/package.json +44 -32
  180. package/popover/index.d.ts +2 -1
  181. package/prompts/index.d.ts +17 -2
  182. package/select/index.d.ts +12 -2
  183. package/sender/index.d.ts +1 -0
  184. package/style/animates/base.scss +32 -0
  185. package/style/animates/conect.scss +32 -0
  186. package/style/animates/fade.scss +32 -0
  187. package/style/animates/index.scss +11 -0
  188. package/style/animates/move.scss +129 -0
  189. package/style/animates/opacity.scss +26 -0
  190. package/style/animates/slide.scss +113 -0
  191. package/style/core/index.css +353 -0
  192. package/style/core/index.css.map +1 -1
  193. package/style/core/index.scss +1 -6
  194. package/suggestion/index.d.ts +96 -0
  195. package/table/index.d.ts +15 -4
  196. package/table-view/index.d.ts +1 -1
  197. package/tag/index.d.ts +2 -1
  198. package/thought-chain/index.d.ts +107 -0
  199. package/time-picker/index.d.ts +2 -1
  200. package/timeline/index.d.ts +35 -19
  201. package/tooltip/index.d.ts +2 -12
  202. package/tree-select/index.d.ts +2 -1
  203. package/upload/index.d.ts +39 -2
@@ -1 +1 @@
1
- {"version":3,"file":"ng-nest-ui-textarea.mjs","sources":["../../../../lib/ng-nest/ui/textarea/textarea.property.ts","../../../../lib/ng-nest/ui/textarea/textarea.component.ts","../../../../lib/ng-nest/ui/textarea/textarea.component.html","../../../../lib/ng-nest/ui/textarea/textarea.module.ts","../../../../lib/ng-nest/ui/textarea/ng-nest-ui-textarea.ts"],"sourcesContent":["import { XToBoolean, XToNumber, XToCssPixelValue } from '@ng-nest/ui/core';\r\nimport { Component, TemplateRef, input, output } from '@angular/core';\r\nimport { XFormControlFunction, XFormOption } from '@ng-nest/ui/base-form';\r\nimport type {\r\n XNumber,\r\n XBoolean,\r\n XPositionLeftRight,\r\n XDirection,\r\n XAlign,\r\n XJustify,\r\n XTemplate,\r\n XVariant\r\n} from '@ng-nest/ui/core';\r\n\r\n/**\r\n * Textarea\r\n * @selector x-textarea\r\n * @decorator component\r\n */\r\nexport const XTextareaPrefix = 'x-textarea';\r\nconst X_TEXTAREA_CONFIG_NAME = 'textarea';\r\n\r\n/**\r\n * Textarea Property\r\n */\r\n@Component({ selector: `${XTextareaPrefix}-property`, template: '' })\r\nexport class XTextareaProperty extends XFormControlFunction(X_TEXTAREA_CONFIG_NAME) {\r\n /**\r\n * @zh_CN 形态变体\r\n * @en_US Input variant\r\n */\r\n readonly variant = input<XTextareaVariant>(this.config?.variant ?? 'outlined');\r\n /**\r\n * @zh_CN 清除按钮\r\n * @en_US Clear button\r\n */\r\n readonly clearable = input<boolean, XBoolean>(this.config?.clearable ?? false, { transform: XToBoolean });\r\n /**\r\n * @zh_CN 图标\r\n * @en_US Icon\r\n */\r\n readonly icon = input<string>();\r\n /**\r\n * @zh_CN 图标布局方式\r\n * @en_US Icon layout\r\n */\r\n readonly iconLayout = input<XTextareaIconLayoutType>('right');\r\n /**\r\n * @zh_CN 图标动画\r\n * @en_US Icon animation\r\n */\r\n readonly iconSpin = input<boolean, XBoolean>(false, { transform: XToBoolean });\r\n /**\r\n * @zh_CN 输入最大长度\r\n * @en_US Enter the maximum length\r\n */\r\n readonly maxlength = input<number | null, XNumber>(null, { transform: XToNumber });\r\n /**\r\n * @zh_CN 高度\r\n * @en_US height\r\n */\r\n readonly height = input<string, XNumber>('6rem', { transform: XToCssPixelValue });\r\n /**\r\n * @zh_CN 输入提示信息\r\n * @en_US Enter prompt information\r\n */\r\n override readonly placeholder = input<string | string[]>('');\r\n /**\r\n * @zh_CN 标签\r\n * @en_US Label\r\n */\r\n override readonly label = input<XTemplate>('');\r\n /**\r\n * @zh_CN 标签宽度\r\n * @en_US Label width\r\n */\r\n override readonly labelWidth = input<string, XNumber>('', { transform: XToCssPixelValue });\r\n /**\r\n * @zh_CN 标签文字对齐方式\r\n * @en_US Label text alignment method\r\n */\r\n override readonly labelAlign = input<XAlign>('start');\r\n /**\r\n * @zh_CN flex 布局下的子元素水平排列方式\r\n * @en_US The level of sub-element level arrangement under flex layout\r\n */\r\n override readonly justify = input<XJustify>('start');\r\n /**\r\n * @zh_CN flex 布局下的子元素垂直排列方式\r\n * @en_US sub-element vertical arrangement method under flex layout\r\n */\r\n override readonly align = input<XAlign>('start');\r\n /**\r\n * @zh_CN flex 布局下的子元素排列方向\r\n * @en_US The direction of the sub-element arrangement under flex layout\r\n */\r\n override readonly direction = input<XDirection>('column');\r\n /**\r\n * @zh_CN 禁用\r\n * @en_US Disabled\r\n */\r\n override readonly disabled = input<boolean, XBoolean>(false, { transform: XToBoolean });\r\n /**\r\n * @zh_CN 必填\r\n * @en_US Required\r\n */\r\n override readonly required = input<boolean, XBoolean>(false, { transform: XToBoolean });\r\n /**\r\n * @zh_CN 只读\r\n * @en_US Readonly\r\n */\r\n override readonly readonly = input<boolean, XBoolean>(false, { transform: XToBoolean });\r\n /**\r\n * @zh_CN 正则验证规则\r\n * @en_US Regular verification rules\r\n */\r\n override readonly pattern = input<RegExp | RegExp[] | any>(null);\r\n /**\r\n * @zh_CN 验证不通过提示文字\r\n * @en_US Verify not pass the prompt text\r\n */\r\n override readonly message = input<string | string[]>([]);\r\n /**\r\n * @zh_CN 输入验证函数\r\n * @en_US Enter the verification function\r\n */\r\n override readonly inputValidator = input<(value: any) => boolean>();\r\n /**\r\n * @zh_CN 清除按钮的事件\r\n * @en_US Clear button event\r\n */\r\n readonly clearEmit = output<any>();\r\n}\r\n\r\n/**\r\n * Textarea Option\r\n */\r\nexport interface XTextareaOption extends XFormOption {\r\n /**\r\n * @zh_CN 形态变体\r\n * @en_US Input variant\r\n */\r\n variant?: XTextareaVariant;\r\n /**\r\n * @zh_CN 清除按钮\r\n * @en_US Clear button\r\n */\r\n clearable?: boolean;\r\n /**\r\n * @zh_CN 图标\r\n * @en_US Icon\r\n */\r\n icon?: string;\r\n /**\r\n * @zh_CN 图标布局方式\r\n * @en_US Icon layout\r\n */\r\n iconLayout?: XTextareaIconLayoutType;\r\n /**\r\n * @zh_CN 图标动画\r\n * @en_US Icon animation\r\n */\r\n iconSpin?: boolean;\r\n /**\r\n * @zh_CN 输入最大长度\r\n * @en_US Enter the maximum length\r\n */\r\n maxlength?: number;\r\n /**\r\n * @zh_CN 高度\r\n * @en_US height\r\n */\r\n height?: string;\r\n /**\r\n * @zh_CN 清除按钮的事件\r\n * @en_US Clear button event\r\n */\r\n clearEmit?: (value: any) => void;\r\n /**\r\n * @zh_CN 输入框点击样式\r\n * @en_US Input pointer\r\n */\r\n pointer?: boolean;\r\n /**\r\n * @zh_CN 标签\r\n * @en_US Label\r\n */\r\n label?: string;\r\n /**\r\n * @zh_CN 标签宽度\r\n * @en_US Label width\r\n */\r\n labelWidth?: string;\r\n /**\r\n * @zh_CN 标签文字对齐方式\r\n * @en_US Label text alignment method\r\n */\r\n labelAlign?: XAlign;\r\n /**\r\n * @zh_CN flex 布局下的子元素水平排列方式\r\n * @en_US The level of sub-element level arrangement under flex layout\r\n */\r\n justify?: XJustify;\r\n /**\r\n * @zh_CN flex 布局下的子元素垂直排列方式\r\n * @en_US sub-element vertical arrangement method under flex layout\r\n */\r\n align?: XAlign;\r\n /**\r\n * @zh_CN flex 布局下的子元素排列方向\r\n * @en_US The direction of the sub-element arrangement under flex layout\r\n */\r\n direction?: XDirection;\r\n /**\r\n * @zh_CN 输入提示信息\r\n * @en_US Enter prompt information\r\n */\r\n placeholder?: string;\r\n /**\r\n * @zh_CN 禁用\r\n * @en_US Disabled\r\n */\r\n disabled?: boolean;\r\n /**\r\n * @zh_CN 必填\r\n * @en_US Required\r\n */\r\n required?: boolean;\r\n /**\r\n * @zh_CN 只读\r\n * @en_US Readonly\r\n */\r\n readonly?: boolean;\r\n /**\r\n * @zh_CN 值模板\r\n * @en_US Node template\r\n */\r\n valueTpl?: TemplateRef<any>;\r\n /**\r\n * @zh_CN 值模板参数\r\n * @en_US Node template\r\n */\r\n valueTplContext?: any;\r\n /**\r\n * @zh_CN 前置标签\r\n * @en_US Before label\r\n */\r\n before?: XTemplate;\r\n /**\r\n * @zh_CN 后置标签\r\n * @en_US After label\r\n */\r\n after?: XTemplate;\r\n /**\r\n * @zh_CN 正则验证规则\r\n * @en_US Regular verification rules\r\n */\r\n pattern?: RegExp | RegExp[];\r\n /**\r\n * @zh_CN 验证不通过提示文字\r\n * @en_US Verify not pass the prompt text\r\n */\r\n message?: string | string[];\r\n /**\r\n * @zh_CN 激活状态\r\n * @en_US Activation state\r\n */\r\n active?: boolean;\r\n /**\r\n * @zh_CN 输入验证函数\r\n * @en_US Enter the verification function\r\n */\r\n inputValidator?: (value: any) => boolean;\r\n}\r\n\r\n/**\r\n * @zh_CN 图标布局方式,指在输入框中的位置\r\n * @en_US Icon layout, refers to the position in the input box\r\n * @value \"left\" 靠左\r\n * @value \"right\" 靠右\r\n */\r\nexport type XTextareaIconLayoutType = XPositionLeftRight;\r\n\r\n/**\r\n * @zh_CN 输入框形态变体\r\n * @en_US Input box variant\r\n */\r\nexport type XTextareaVariant = XVariant;\r\n","import {\r\n Component,\r\n ViewEncapsulation,\r\n ChangeDetectionStrategy,\r\n ElementRef,\r\n inject,\r\n computed,\r\n viewChild\r\n} from '@angular/core';\r\nimport { XTextareaPrefix, XTextareaProperty } from './textarea.property';\r\nimport { XIsEmpty, XConfigService } from '@ng-nest/ui/core';\r\nimport { XValueAccessor } from '@ng-nest/ui/base-form';\r\nimport { NgClass } from '@angular/common';\r\nimport { FormsModule, ReactiveFormsModule } from '@angular/forms';\r\nimport { XIconComponent } from '@ng-nest/ui/icon';\r\nimport { XOutletDirective } from '@ng-nest/ui/outlet';\r\n\r\n@Component({\r\n selector: `${XTextareaPrefix}`,\r\n imports: [NgClass, FormsModule, ReactiveFormsModule, XIconComponent, XOutletDirective],\r\n templateUrl: './textarea.component.html',\r\n styleUrls: ['./style/index.scss'],\r\n encapsulation: ViewEncapsulation.None,\r\n changeDetection: ChangeDetectionStrategy.OnPush,\r\n providers: [XValueAccessor(XTextareaComponent)]\r\n})\r\nexport class XTextareaComponent extends XTextareaProperty {\r\n textareaRef = viewChild.required<ElementRef<HTMLElement>>('textareaRef');\r\n\r\n valueLength = computed(() => {\r\n if (this.maxlength()) {\r\n return XIsEmpty(this.value()) ? 0 : `${this.value()}`.length;\r\n }\r\n return 0;\r\n });\r\n lengthTotal = computed(() => {\r\n if (this.maxlength()) {\r\n return `${this.valueLength()}/${this.maxlength()}`;\r\n }\r\n return '';\r\n });\r\n\r\n clearShow = computed(() => {\r\n if (this.clearable() && !this.disabledComputed()) {\r\n return !XIsEmpty(this.value());\r\n } else {\r\n return false;\r\n }\r\n });\r\n\r\n getIcon = computed(() => !XIsEmpty(this.icon()));\r\n getIconLayoutLeft = computed(() => !XIsEmpty(this.icon()) && this.iconLayout() === 'left');\r\n getIconLayoutRight = computed(() => !XIsEmpty(this.icon()) && this.iconLayout() === 'right');\r\n paddingLeft = computed(() => (this.getIconLayoutLeft() ? 2.15 : 0.75));\r\n paddingRight = computed(() => (this.getIconLayoutRight() ? 2.15 : 0.75));\r\n\r\n configService = inject(XConfigService);\r\n\r\n classMap = computed(() => ({\r\n [`${XTextareaPrefix}-${this.size()}`]: !!this.size(),\r\n [`x-justify-${this.justify()}`]: !!this.justify(),\r\n [`x-align-${this.align()}`]: !!this.align(),\r\n [`x-direction-${this.direction()}`]: !!this.direction()\r\n }));\r\n labelMapSignal = computed(() => ({\r\n [`x-text-align-${this.labelAlign()}`]: !!this.labelAlign()\r\n }));\r\n\r\n change(value: any) {\r\n if (this.onChange) this.onChange(value);\r\n }\r\n\r\n onClear() {\r\n const clearValue = this.value();\r\n this.value.set('');\r\n this.change(this.value());\r\n this.clearEmit.emit(clearValue);\r\n this.textareaRef().nativeElement.focus();\r\n }\r\n}\r\n","<div\r\n #textarea\r\n class=\"x-textarea\"\r\n [class.x-flex]=\"justify() || align() || direction()\"\r\n [class.x-disabled]=\"disabledComputed()\"\r\n [class.x-required]=\"requiredIsEmpty()\"\r\n [class.x-invalid]=\"invalid()\"\r\n [class.x-clearable]=\"clearable()\"\r\n [class.x-clear-show]=\"clearShow()\"\r\n [class.x-textarea-icon]=\"getIcon()\"\r\n [class.x-textarea-filled]=\"variant() === 'filled'\"\r\n [class.x-textarea-borderless]=\"variant() === 'borderless'\"\r\n [class.x-textarea-underlined]=\"variant() === 'underlined'\"\r\n [class.x-textarea-icon-left]=\"getIconLayoutLeft()\"\r\n [class.x-textarea-icon-right]=\"getIconLayoutRight()\"\r\n [ngClass]=\"classMap()\"\r\n>\r\n @if (label()) {\r\n <label\r\n [class.x-textarea-label-required]=\"requiredComputed()\"\r\n [style.width]=\"labelWidth()\"\r\n [ngClass]=\"labelMapSignal()\"\r\n *xOutlet=\"label()\"\r\n >\r\n {{ label() }}\r\n </label>\r\n }\r\n <div class=\"x-textarea-row\">\r\n <textarea\r\n #textareaRef\r\n [placeholder]=\"placeholder()\"\r\n [required]=\"requiredComputed()\"\r\n [disabled]=\"disabledComputed()\"\r\n [readonly]=\"readonly()\"\r\n [maxlength]=\"maxlength()\"\r\n [(ngModel)]=\"value\"\r\n (ngModelChange)=\"change($event)\"\r\n [style.height]=\"height()\"\r\n [style.padding-left.rem]=\"paddingLeft()\"\r\n [style.padding-right.rem]=\"paddingRight()\"\r\n (input)=\"formControlValidator()\"\r\n ></textarea>\r\n @if (clearShow()) {\r\n <x-icon class=\"x-textarea-clear\" type=\"fto-x\" (click)=\"onClear()\"></x-icon>\r\n }\r\n @if (icon() && ((!clearShow() && getIconLayoutRight()) || getIconLayoutLeft())) {\r\n <x-icon class=\"x-textarea-icon-in\" [type]=\"icon()\" [spin]=\"iconSpin()\"></x-icon>\r\n }\r\n @if (maxlength()) {\r\n <span class=\"x-textarea-max-length\">{{ lengthTotal() }}</span>\r\n }\r\n @if (invalid()) {\r\n <span class=\"x-textarea-error-message\">{{ invalidMessage() }}</span>\r\n }\r\n @if (requiredIsEmpty() || invalid()) {\r\n <div class=\"x-border-error x-top-left\"></div>\r\n <div class=\"x-border-error x-top-right\"></div>\r\n <div class=\"x-border-error x-bottom-left\"></div>\r\n <div class=\"x-border-error x-bottom-right\"></div>\r\n }\r\n </div>\r\n</div>\r\n","import { NgModule } from '@angular/core';\r\nimport { XTextareaComponent } from './textarea.component';\r\n\r\n@NgModule({\r\n exports: [XTextareaComponent],\r\n imports: [XTextareaComponent]\r\n})\r\nexport class XTextareaModule {}\r\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;;;;;;;AAcA;;;;AAIG;AACI,MAAM,eAAe,GAAG;AAC/B,MAAM,sBAAsB,GAAG,UAAU;AAEzC;;AAEG;MAEU,iBAAkB,SAAQ,oBAAoB,CAAC,sBAAsB,CAAC,CAAA;AADnF,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AAA,QAAA,EAAA,OAAA,EAAA,QAAA,EAAA,QAAA,EAAA,EAAA,EAAA,IAAA,EAAA,eAAe,YAFhB,kBAAkB,CAAA,EAAA,CAAA,CAAA;;2FAEjB,eAAe,EAAA,UAAA,EAAA,CAAA;kBAJ3B,QAAQ;AAAC,YAAA,IAAA,EAAA,CAAA;oBACR,OAAO,EAAE,CAAC,kBAAkB,CAAC;oBAC7B,OAAO,EAAE,CAAC,kBAAkB;AAC7B,iBAAA;;;ACND;;AAEG;;;;"}
1
+ {"version":3,"file":"ng-nest-ui-textarea.mjs","sources":["../../../../lib/ng-nest/ui/textarea/textarea.property.ts","../../../../lib/ng-nest/ui/textarea/textarea.component.ts","../../../../lib/ng-nest/ui/textarea/textarea.component.html","../../../../lib/ng-nest/ui/textarea/textarea.module.ts","../../../../lib/ng-nest/ui/textarea/ng-nest-ui-textarea.ts"],"sourcesContent":["import { XToBoolean, XToNumber, XToCssPixelValue } from '@ng-nest/ui/core';\r\nimport { Component, TemplateRef, input, output } from '@angular/core';\r\nimport { XFormControlFunction, XFormOption } from '@ng-nest/ui/base-form';\r\nimport type {\r\n XNumber,\r\n XBoolean,\r\n XPositionLeftRight,\r\n XDirection,\r\n XAlign,\r\n XJustify,\r\n XTemplate,\r\n XVariant\r\n} from '@ng-nest/ui/core';\r\n\r\n/**\r\n * Textarea\r\n * @selector x-textarea\r\n * @decorator component\r\n */\r\nexport const XTextareaPrefix = 'x-textarea';\r\nconst X_TEXTAREA_CONFIG_NAME = 'textarea';\r\n\r\n/**\r\n * Textarea Property\r\n */\r\n@Component({ selector: `${XTextareaPrefix}-property`, template: '' })\r\nexport class XTextareaProperty extends XFormControlFunction(X_TEXTAREA_CONFIG_NAME) {\r\n /**\r\n * @zh_CN 形态变体\r\n * @en_US Input variant\r\n */\r\n readonly variant = input<XTextareaVariant>(this.config?.variant ?? 'outlined');\r\n /**\r\n * @zh_CN 清除按钮\r\n * @en_US Clear button\r\n */\r\n readonly clearable = input<boolean, XBoolean>(this.config?.clearable ?? false, { transform: XToBoolean });\r\n /**\r\n * @zh_CN 图标\r\n * @en_US Icon\r\n */\r\n readonly icon = input<string>();\r\n /**\r\n * @zh_CN 图标布局方式\r\n * @en_US Icon layout\r\n */\r\n readonly iconLayout = input<XTextareaIconLayoutType>('right');\r\n /**\r\n * @zh_CN 图标动画\r\n * @en_US Icon animation\r\n */\r\n readonly iconSpin = input<boolean, XBoolean>(false, { transform: XToBoolean });\r\n /**\r\n * @zh_CN 输入最大长度\r\n * @en_US Enter the maximum length\r\n */\r\n readonly maxlength = input<number | null, XNumber>(null, { transform: XToNumber });\r\n /**\r\n * @zh_CN 高度\r\n * @en_US height\r\n */\r\n readonly height = input<string, XNumber>('6rem', { transform: XToCssPixelValue });\r\n /**\r\n * @zh_CN 输入提示信息\r\n * @en_US Enter prompt information\r\n */\r\n override readonly placeholder = input<string | string[]>('');\r\n /**\r\n * @zh_CN 标签\r\n * @en_US Label\r\n */\r\n override readonly label = input<XTemplate>('');\r\n /**\r\n * @zh_CN 标签宽度\r\n * @en_US Label width\r\n */\r\n override readonly labelWidth = input<string, XNumber>('', { transform: XToCssPixelValue });\r\n /**\r\n * @zh_CN 标签文字对齐方式\r\n * @en_US Label text alignment method\r\n */\r\n override readonly labelAlign = input<XAlign>('start');\r\n /**\r\n * @zh_CN flex 布局下的子元素水平排列方式\r\n * @en_US The level of sub-element level arrangement under flex layout\r\n */\r\n override readonly justify = input<XJustify>('start');\r\n /**\r\n * @zh_CN flex 布局下的子元素垂直排列方式\r\n * @en_US sub-element vertical arrangement method under flex layout\r\n */\r\n override readonly align = input<XAlign>('start');\r\n /**\r\n * @zh_CN flex 布局下的子元素排列方向\r\n * @en_US The direction of the sub-element arrangement under flex layout\r\n */\r\n override readonly direction = input<XDirection>('column');\r\n /**\r\n * @zh_CN 禁用\r\n * @en_US Disabled\r\n */\r\n override readonly disabled = input<boolean, XBoolean>(false, { transform: XToBoolean });\r\n /**\r\n * @zh_CN 必填\r\n * @en_US Required\r\n */\r\n override readonly required = input<boolean, XBoolean>(false, { transform: XToBoolean });\r\n /**\r\n * @zh_CN 只读\r\n * @en_US Readonly\r\n */\r\n override readonly readonly = input<boolean, XBoolean>(false, { transform: XToBoolean });\r\n /**\r\n * @zh_CN 正则验证规则\r\n * @en_US Regular verification rules\r\n */\r\n override readonly pattern = input<RegExp | RegExp[] | any>(null);\r\n /**\r\n * @zh_CN 验证不通过提示文字\r\n * @en_US Verify not pass the prompt text\r\n */\r\n override readonly message = input<string | string[]>([]);\r\n /**\r\n * @zh_CN 输入验证函数\r\n * @en_US Enter the verification function\r\n */\r\n override readonly inputValidator = input<(value: any) => boolean>();\r\n /**\r\n * @zh_CN 清除按钮的事件\r\n * @en_US Clear button event\r\n */\r\n readonly clearEmit = output<any>();\r\n}\r\n\r\n/**\r\n * Textarea Option\r\n */\r\nexport interface XTextareaOption extends XFormOption {\r\n /**\r\n * @zh_CN 形态变体\r\n * @en_US Input variant\r\n */\r\n variant?: XTextareaVariant;\r\n /**\r\n * @zh_CN 清除按钮\r\n * @en_US Clear button\r\n */\r\n clearable?: boolean;\r\n /**\r\n * @zh_CN 图标\r\n * @en_US Icon\r\n */\r\n icon?: string;\r\n /**\r\n * @zh_CN 图标布局方式\r\n * @en_US Icon layout\r\n */\r\n iconLayout?: XTextareaIconLayoutType;\r\n /**\r\n * @zh_CN 图标动画\r\n * @en_US Icon animation\r\n */\r\n iconSpin?: boolean;\r\n /**\r\n * @zh_CN 输入最大长度\r\n * @en_US Enter the maximum length\r\n */\r\n maxlength?: number;\r\n /**\r\n * @zh_CN 高度\r\n * @en_US height\r\n */\r\n height?: string;\r\n /**\r\n * @zh_CN 清除按钮的事件\r\n * @en_US Clear button event\r\n */\r\n clearEmit?: (value: any) => void;\r\n /**\r\n * @zh_CN 输入框点击样式\r\n * @en_US Input pointer\r\n */\r\n pointer?: boolean;\r\n /**\r\n * @zh_CN 标签\r\n * @en_US Label\r\n */\r\n label?: string;\r\n /**\r\n * @zh_CN 标签宽度\r\n * @en_US Label width\r\n */\r\n labelWidth?: string;\r\n /**\r\n * @zh_CN 标签文字对齐方式\r\n * @en_US Label text alignment method\r\n */\r\n labelAlign?: XAlign;\r\n /**\r\n * @zh_CN flex 布局下的子元素水平排列方式\r\n * @en_US The level of sub-element level arrangement under flex layout\r\n */\r\n justify?: XJustify;\r\n /**\r\n * @zh_CN flex 布局下的子元素垂直排列方式\r\n * @en_US sub-element vertical arrangement method under flex layout\r\n */\r\n align?: XAlign;\r\n /**\r\n * @zh_CN flex 布局下的子元素排列方向\r\n * @en_US The direction of the sub-element arrangement under flex layout\r\n */\r\n direction?: XDirection;\r\n /**\r\n * @zh_CN 输入提示信息\r\n * @en_US Enter prompt information\r\n */\r\n placeholder?: string;\r\n /**\r\n * @zh_CN 禁用\r\n * @en_US Disabled\r\n */\r\n disabled?: boolean;\r\n /**\r\n * @zh_CN 必填\r\n * @en_US Required\r\n */\r\n required?: boolean;\r\n /**\r\n * @zh_CN 只读\r\n * @en_US Readonly\r\n */\r\n readonly?: boolean;\r\n /**\r\n * @zh_CN 值模板\r\n * @en_US Node template\r\n */\r\n valueTpl?: TemplateRef<any>;\r\n /**\r\n * @zh_CN 值模板参数\r\n * @en_US Node template\r\n */\r\n valueTplContext?: any;\r\n /**\r\n * @zh_CN 前置标签\r\n * @en_US Before label\r\n */\r\n before?: XTemplate;\r\n /**\r\n * @zh_CN 后置标签\r\n * @en_US After label\r\n */\r\n after?: XTemplate;\r\n /**\r\n * @zh_CN 正则验证规则\r\n * @en_US Regular verification rules\r\n */\r\n pattern?: RegExp | RegExp[];\r\n /**\r\n * @zh_CN 验证不通过提示文字\r\n * @en_US Verify not pass the prompt text\r\n */\r\n message?: string | string[];\r\n /**\r\n * @zh_CN 激活状态\r\n * @en_US Activation state\r\n */\r\n active?: boolean;\r\n /**\r\n * @zh_CN 输入验证函数\r\n * @en_US Enter the verification function\r\n */\r\n inputValidator?: (value: any) => boolean;\r\n}\r\n\r\n/**\r\n * @zh_CN 图标布局方式,指在输入框中的位置\r\n * @en_US Icon layout, refers to the position in the input box\r\n * @value \"left\" 靠左\r\n * @value \"right\" 靠右\r\n */\r\nexport type XTextareaIconLayoutType = XPositionLeftRight;\r\n\r\n/**\r\n * @zh_CN 输入框形态变体\r\n * @en_US Input box variant\r\n */\r\nexport type XTextareaVariant = XVariant;\r\n","import {\r\n Component,\r\n ViewEncapsulation,\r\n ChangeDetectionStrategy,\r\n ElementRef,\r\n inject,\r\n computed,\r\n viewChild\r\n} from '@angular/core';\r\nimport { XTextareaPrefix, XTextareaProperty } from './textarea.property';\r\nimport { XIsEmpty, XConfigService } from '@ng-nest/ui/core';\r\nimport { XValueAccessor } from '@ng-nest/ui/base-form';\r\nimport { NgClass } from '@angular/common';\r\nimport { FormsModule, ReactiveFormsModule } from '@angular/forms';\r\nimport { XIconComponent } from '@ng-nest/ui/icon';\r\nimport { XOutletDirective } from '@ng-nest/ui/outlet';\r\n\r\n@Component({\r\n selector: `${XTextareaPrefix}`,\r\n imports: [NgClass, FormsModule, ReactiveFormsModule, XIconComponent, XOutletDirective],\r\n templateUrl: './textarea.component.html',\r\n styleUrls: ['./style/index.scss'],\r\n encapsulation: ViewEncapsulation.None,\r\n changeDetection: ChangeDetectionStrategy.OnPush,\r\n providers: [XValueAccessor(XTextareaComponent)]\r\n})\r\nexport class XTextareaComponent extends XTextareaProperty {\r\n textareaRef = viewChild.required<ElementRef<HTMLElement>>('textareaRef');\r\n\r\n valueLength = computed(() => {\r\n if (this.maxlength()) {\r\n return XIsEmpty(this.value()) ? 0 : `${this.value()}`.length;\r\n }\r\n return 0;\r\n });\r\n lengthTotal = computed(() => {\r\n if (this.maxlength()) {\r\n return `${this.valueLength()}/${this.maxlength()}`;\r\n }\r\n return '';\r\n });\r\n\r\n clearShow = computed(() => {\r\n if (this.clearable() && !this.disabledComputed()) {\r\n return !XIsEmpty(this.value());\r\n } else {\r\n return false;\r\n }\r\n });\r\n\r\n getIcon = computed(() => !XIsEmpty(this.icon()));\r\n getIconLayoutLeft = computed(() => !XIsEmpty(this.icon()) && this.iconLayout() === 'left');\r\n getIconLayoutRight = computed(() => !XIsEmpty(this.icon()) && this.iconLayout() === 'right');\r\n paddingLeft = computed(() => (this.getIconLayoutLeft() ? 2.15 : 0.75));\r\n paddingRight = computed(() => (this.getIconLayoutRight() ? 2.15 : 0.75));\r\n\r\n configService = inject(XConfigService);\r\n\r\n classMap = computed(() => ({\r\n [`${XTextareaPrefix}-${this.size()}`]: !!this.size(),\r\n [`x-justify-${this.justify()}`]: !!this.justify(),\r\n [`x-align-${this.align()}`]: !!this.align(),\r\n [`x-direction-${this.direction()}`]: !!this.direction()\r\n }));\r\n labelMapSignal = computed(() => ({\r\n [`x-text-align-${this.labelAlign()}`]: !!this.labelAlign()\r\n }));\r\n\r\n change(value: any) {\r\n if (this.onChange) this.onChange(value);\r\n }\r\n\r\n onClear() {\r\n const clearValue = this.value();\r\n this.value.set('');\r\n this.change(this.value());\r\n this.clearEmit.emit(clearValue);\r\n this.textareaRef().nativeElement.focus();\r\n }\r\n}\r\n","<div\r\n #textarea\r\n class=\"x-textarea\"\r\n [class.x-flex]=\"justify() || align() || direction()\"\r\n [class.x-disabled]=\"disabledComputed()\"\r\n [class.x-required]=\"requiredIsEmpty()\"\r\n [class.x-invalid]=\"invalid()\"\r\n [class.x-clearable]=\"clearable()\"\r\n [class.x-clear-show]=\"clearShow()\"\r\n [class.x-textarea-icon]=\"getIcon()\"\r\n [class.x-textarea-filled]=\"variant() === 'filled'\"\r\n [class.x-textarea-borderless]=\"variant() === 'borderless'\"\r\n [class.x-textarea-underlined]=\"variant() === 'underlined'\"\r\n [class.x-textarea-icon-left]=\"getIconLayoutLeft()\"\r\n [class.x-textarea-icon-right]=\"getIconLayoutRight()\"\r\n [ngClass]=\"classMap()\"\r\n>\r\n @if (label()) {\r\n <label\r\n [class.x-textarea-label-required]=\"requiredComputed()\"\r\n [style.width]=\"labelWidth()\"\r\n [ngClass]=\"labelMapSignal()\"\r\n *xOutlet=\"label()\"\r\n >\r\n {{ label() }}\r\n </label>\r\n }\r\n <div class=\"x-textarea-row\">\r\n <textarea\r\n #textareaRef\r\n [placeholder]=\"placeholder()\"\r\n [required]=\"requiredComputed()\"\r\n [disabled]=\"disabledComputed()\"\r\n [readonly]=\"readonly()\"\r\n [maxlength]=\"maxlength()\"\r\n [(ngModel)]=\"value\"\r\n (ngModelChange)=\"change($event)\"\r\n [style.height]=\"height()\"\r\n [style.padding-left.rem]=\"paddingLeft()\"\r\n [style.padding-right.rem]=\"paddingRight()\"\r\n (input)=\"formControlValidator()\"\r\n ></textarea>\r\n @if (clearShow()) {\r\n <x-icon class=\"x-textarea-clear\" type=\"fto-x\" (click)=\"onClear()\"></x-icon>\r\n }\r\n @if (icon() && ((!clearShow() && getIconLayoutRight()) || getIconLayoutLeft())) {\r\n <x-icon class=\"x-textarea-icon-in\" [type]=\"icon()\" [spin]=\"iconSpin()\"></x-icon>\r\n }\r\n @if (maxlength()) {\r\n <span class=\"x-textarea-max-length\">{{ lengthTotal() }}</span>\r\n }\r\n @if (invalid()) {\r\n <span class=\"x-textarea-error-message\">{{ invalidMessage() }}</span>\r\n }\r\n @if (requiredIsEmpty() || invalid()) {\r\n <div class=\"x-border-error x-top-left\"></div>\r\n <div class=\"x-border-error x-top-right\"></div>\r\n <div class=\"x-border-error x-bottom-left\"></div>\r\n <div class=\"x-border-error x-bottom-right\"></div>\r\n }\r\n </div>\r\n</div>\r\n","import { NgModule } from '@angular/core';\r\nimport { XTextareaComponent } from './textarea.component';\r\n\r\n@NgModule({\r\n exports: [XTextareaComponent],\r\n imports: [XTextareaComponent]\r\n})\r\nexport class XTextareaModule {}\r\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;;;;;;;AAcA;;;;AAIG;AACI,MAAM,eAAe,GAAG;AAC/B,MAAM,sBAAsB,GAAG,UAAU;AAEzC;;AAEG;MAEU,iBAAkB,SAAQ,oBAAoB,CAAC,sB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,CAAA,EAAA,CAAA,CAAA;AAGjB,uBAAA,SAAA,IAAA,CAAA,IAAA,GAAA,EAAA,CAAA,mBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,QAAA,EAAA,QAAA,EAAA,EAAA,EAAA,IAAA,EAAA,eAAe,YAFhB,kBAAkB,CAAA,EAAA,CAAA,CAAA;;2FAEjB,eAAe,EAAA,UAAA,EAAA,CAAA;kBAJ3B,QAAQ;AAAC,YAAA,IAAA,EAAA,CAAA;oBACR,OAAO,EAAE,CAAC,kBAAkB,CAAC;oBAC7B,OAAO,EAAE,CAAC,kBAAkB;AAC7B,iBAAA;;;ACND;;AAEG;;;;"}
@@ -64,13 +64,13 @@ class XThemeProperty extends XFormControlFunction(X_THEME_CONFIG_NAME) {
64
64
  */
65
65
  this.defaultClick = output();
66
66
  }
67
- /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.0", ngImport: i0, type: XThemeProperty, deps: null, target: i0.ɵɵFactoryTarget.Component }); }
68
- /** @nocollapse */ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "20.3.0", type: XThemeProperty, isStandalone: true, selector: "x-theme-property", inputs: { prefix: { classPropertyName: "prefix", publicName: "prefix", isSignal: true, isRequired: false, transformFunction: null }, amounts: { classPropertyName: "amounts", publicName: "amounts", isSignal: true, isRequired: false, transformFunction: null }, showDark: { classPropertyName: "showDark", publicName: "showDark", isSignal: true, isRequired: false, transformFunction: null }, showDetail: { classPropertyName: "showDetail", publicName: "showDetail", isSignal: true, isRequired: false, transformFunction: null }, dark: { classPropertyName: "dark", publicName: "dark", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { dark: "darkChange", defaultClick: "defaultClick" }, usesInheritance: true, ngImport: i0, template: '', isInline: true }); }
67
+ /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.5", ngImport: i0, type: XThemeProperty, deps: null, target: i0.ɵɵFactoryTarget.Component }); }
68
+ /** @nocollapse */ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "20.3.5", type: XThemeProperty, isStandalone: true, selector: "x-theme-property", inputs: { prefix: { classPropertyName: "prefix", publicName: "prefix", isSignal: true, isRequired: false, transformFunction: null }, amounts: { classPropertyName: "amounts", publicName: "amounts", isSignal: true, isRequired: false, transformFunction: null }, showDark: { classPropertyName: "showDark", publicName: "showDark", isSignal: true, isRequired: false, transformFunction: null }, showDetail: { classPropertyName: "showDetail", publicName: "showDetail", isSignal: true, isRequired: false, transformFunction: null }, dark: { classPropertyName: "dark", publicName: "dark", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { dark: "darkChange", defaultClick: "defaultClick" }, usesInheritance: true, ngImport: i0, template: '', isInline: true }); }
69
69
  }
70
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.0", ngImport: i0, type: XThemeProperty, decorators: [{
70
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.5", ngImport: i0, type: XThemeProperty, decorators: [{
71
71
  type: Component,
72
72
  args: [{ selector: `${XThemePrefix}-property`, template: '' }]
73
- }] });
73
+ }], propDecorators: { prefix: [{ type: i0.Input, args: [{ isSignal: true, alias: "prefix", required: false }] }], amounts: [{ type: i0.Input, args: [{ isSignal: true, alias: "amounts", required: false }] }], showDark: [{ type: i0.Input, args: [{ isSignal: true, alias: "showDark", required: false }] }], showDetail: [{ type: i0.Input, args: [{ isSignal: true, alias: "showDetail", required: false }] }], dark: [{ type: i0.Input, args: [{ isSignal: true, alias: "dark", required: false }] }, { type: i0.Output, args: ["darkChange"] }], defaultClick: [{ type: i0.Output, args: ["defaultClick"] }] } });
74
74
 
75
75
  class XThemeComponent extends XThemeProperty {
76
76
  writeValue(value) {
@@ -219,10 +219,10 @@ class XThemeComponent extends XThemeProperty {
219
219
  }
220
220
  this.formGroup().patchValue(colors);
221
221
  }
222
- /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.0", ngImport: i0, type: XThemeComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
223
- /** @nocollapse */ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "20.3.0", type: XThemeComponent, isStandalone: true, selector: "x-theme", providers: [XValueAccessor(XThemeComponent)], usesInheritance: true, ngImport: i0, template: "<div class=\"x-theme\">\r\n <x-row>\r\n @if (showDark()) {\r\n <x-col [style.width.rem]=\"8\">\r\n <x-switch\r\n direction=\"row\"\r\n [label]=\"locale().darkMode!\"\r\n [(ngModel)]=\"dark\"\r\n (ngModelChange)=\"darkChanges()\"\r\n ></x-switch>\r\n </x-col>\r\n }\r\n <x-col [style.width.rem]=\"8\">\r\n <x-button (click)=\"default()\">{{ locale().initDefault }}</x-button>\r\n </x-col>\r\n </x-row>\r\n <x-form [formGroup]=\"formGroup()\" [controls]=\"controls()\" [width]=\"width()\" span=\"2\" space=\"1\"></x-form>\r\n</div>\r\n", styles: [".x-theme{margin:0;padding:0}.x-theme{display:inline-block}.x-theme x-color-picker:not(:first-child){margin-left:.125rem}.x-theme-darken,.x-theme-default,.x-theme-gradual{display:flex}.x-theme-default x-color-picker{width:9.25rem}\n"], dependencies: [{ kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i1.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "ngmodule", type: ReactiveFormsModule }, { kind: "directive", type: i1.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "component", type: XSwitchComponent, selector: "x-switch" }, { kind: "component", type: XButtonComponent, selector: "x-button" }, { kind: "component", type: XRowComponent, selector: "x-row" }, { kind: "component", type: XColComponent, selector: "x-col" }, { kind: "component", type: XFormComponent, selector: "x-form" }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
222
+ /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.5", ngImport: i0, type: XThemeComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
223
+ /** @nocollapse */ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "20.3.5", type: XThemeComponent, isStandalone: true, selector: "x-theme", providers: [XValueAccessor(XThemeComponent)], usesInheritance: true, ngImport: i0, template: "<div class=\"x-theme\">\r\n <x-row>\r\n @if (showDark()) {\r\n <x-col [style.width.rem]=\"8\">\r\n <x-switch\r\n direction=\"row\"\r\n [label]=\"locale().darkMode!\"\r\n [(ngModel)]=\"dark\"\r\n (ngModelChange)=\"darkChanges()\"\r\n ></x-switch>\r\n </x-col>\r\n }\r\n <x-col [style.width.rem]=\"8\">\r\n <x-button (click)=\"default()\">{{ locale().initDefault }}</x-button>\r\n </x-col>\r\n </x-row>\r\n <x-form [formGroup]=\"formGroup()\" [controls]=\"controls()\" [width]=\"width()\" span=\"2\" space=\"1\"></x-form>\r\n</div>\r\n", styles: [".x-theme{margin:0;padding:0}.x-theme{display:inline-block}.x-theme x-color-picker:not(:first-child){margin-left:.125rem}.x-theme-darken,.x-theme-default,.x-theme-gradual{display:flex}.x-theme-default x-color-picker{width:9.25rem}\n"], dependencies: [{ kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i1.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "ngmodule", type: ReactiveFormsModule }, { kind: "directive", type: i1.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "component", type: XSwitchComponent, selector: "x-switch" }, { kind: "component", type: XButtonComponent, selector: "x-button" }, { kind: "component", type: XRowComponent, selector: "x-row" }, { kind: "component", type: XColComponent, selector: "x-col" }, { kind: "component", type: XFormComponent, selector: "x-form" }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
224
224
  }
225
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.0", ngImport: i0, type: XThemeComponent, decorators: [{
225
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.5", ngImport: i0, type: XThemeComponent, decorators: [{
226
226
  type: Component,
227
227
  args: [{ selector: 'x-theme', imports: [
228
228
  FormsModule,
@@ -236,11 +236,11 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.0", ngImpor
236
236
  }], ctorParameters: () => [] });
237
237
 
238
238
  class XThemeModule {
239
- /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.0", ngImport: i0, type: XThemeModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
240
- /** @nocollapse */ static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "20.3.0", ngImport: i0, type: XThemeModule, imports: [XThemeComponent], exports: [XThemeComponent] }); }
241
- /** @nocollapse */ static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "20.3.0", ngImport: i0, type: XThemeModule, imports: [XThemeComponent] }); }
239
+ /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.5", ngImport: i0, type: XThemeModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
240
+ /** @nocollapse */ static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "20.3.5", ngImport: i0, type: XThemeModule, imports: [XThemeComponent], exports: [XThemeComponent] }); }
241
+ /** @nocollapse */ static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "20.3.5", ngImport: i0, type: XThemeModule, imports: [XThemeComponent] }); }
242
242
  }
243
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.0", ngImport: i0, type: XThemeModule, decorators: [{
243
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.5", ngImport: i0, type: XThemeModule, decorators: [{
244
244
  type: NgModule,
245
245
  args: [{
246
246
  exports: [XThemeComponent],
@@ -0,0 +1,121 @@
1
+ import * as i0 from '@angular/core';
2
+ import { model, input, Component, inject, ChangeDetectorRef, ChangeDetectionStrategy, ViewEncapsulation, NgModule } from '@angular/core';
3
+ import { XPropertyFunction, XToBoolean } from '@ng-nest/ui/core';
4
+ import { XTimelineComponent } from '@ng-nest/ui/timeline';
5
+ import { XOutletDirective } from '@ng-nest/ui/outlet';
6
+ import { XIconComponent } from '@ng-nest/ui/icon';
7
+ import { XLoadingComponent } from '@ng-nest/ui/loading';
8
+ import * as i1 from '@ng-nest/ui/collapse';
9
+ import { XCollapseModule } from '@ng-nest/ui/collapse';
10
+
11
+ /**
12
+ * ThoughtChain
13
+ * @selector x-thought-chain
14
+ * @decorator component
15
+ */
16
+ const XThoughtChainPrefix = 'x-thought-chain';
17
+ const X_THOUGHT_CHAIN_CONFIG_NAME = 'thoughtChain';
18
+ /**
19
+ * ThoughtChain Property
20
+ */
21
+ class XThoughtChainProperty extends XPropertyFunction(X_THOUGHT_CHAIN_CONFIG_NAME) {
22
+ constructor() {
23
+ super(...arguments);
24
+ /**
25
+ * @zh_CN 思维链节点数据
26
+ * @en_US ThoughtChain items
27
+ */
28
+ this.data = model([], ...(ngDevMode ? [{ debugName: "data" }] : []));
29
+ /**
30
+ * @zh_CN 显示序号
31
+ * @en_US Show number
32
+ */
33
+ this.showNumber = input(this.config?.showNumber ?? true, ...(ngDevMode ? [{ debugName: "showNumber", transform: XToBoolean }] : [{ transform: XToBoolean }]));
34
+ /**
35
+ * @zh_CN 尺寸
36
+ * @en_US Size
37
+ */
38
+ this.size = input(this.config?.size ?? 'medium', ...(ngDevMode ? [{ debugName: "size" }] : []));
39
+ /**
40
+ * @zh_CN 自定义内容模板
41
+ * @en_US Content template
42
+ */
43
+ this.wrapper = input(...(ngDevMode ? [undefined, { debugName: "wrapper" }] : []));
44
+ /**
45
+ * @zh_CN 自定义图标模板
46
+ * @en_US Icon template
47
+ */
48
+ this.icon = input(...(ngDevMode ? [undefined, { debugName: "icon" }] : []));
49
+ /**
50
+ * @zh_CN 节点标题右侧额外的内容模板
51
+ * @en_US Node extra content
52
+ */
53
+ this.extra = input(...(ngDevMode ? [undefined, { debugName: "extra" }] : []));
54
+ /**
55
+ * @zh_CN 节点详细内容模板
56
+ * @en_US Node detail content
57
+ */
58
+ this.content = input(...(ngDevMode ? [undefined, { debugName: "content" }] : []));
59
+ /**
60
+ * @zh_CN 详细内容是否可折叠
61
+ * @en_US Collapsible detail content
62
+ */
63
+ this.collapsible = input(this.config?.collapsible ?? false, ...(ngDevMode ? [{ debugName: "collapsible", transform: XToBoolean }] : [{ transform: XToBoolean }]));
64
+ /**
65
+ * @zh_CN loading 的类型样式
66
+ * @en_US Loading type style
67
+ */
68
+ this.loadingType = input(this.config?.loadingType ?? 'circular', ...(ngDevMode ? [{ debugName: "loadingType" }] : []));
69
+ }
70
+ /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.5", ngImport: i0, type: XThoughtChainProperty, deps: null, target: i0.ɵɵFactoryTarget.Component }); }
71
+ /** @nocollapse */ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "20.3.5", type: XThoughtChainProperty, isStandalone: true, selector: "x-thought-chain-property", inputs: { data: { classPropertyName: "data", publicName: "data", isSignal: true, isRequired: false, transformFunction: null }, showNumber: { classPropertyName: "showNumber", publicName: "showNumber", isSignal: true, isRequired: false, transformFunction: null }, size: { classPropertyName: "size", publicName: "size", isSignal: true, isRequired: false, transformFunction: null }, wrapper: { classPropertyName: "wrapper", publicName: "wrapper", isSignal: true, isRequired: false, transformFunction: null }, icon: { classPropertyName: "icon", publicName: "icon", isSignal: true, isRequired: false, transformFunction: null }, extra: { classPropertyName: "extra", publicName: "extra", isSignal: true, isRequired: false, transformFunction: null }, content: { classPropertyName: "content", publicName: "content", isSignal: true, isRequired: false, transformFunction: null }, collapsible: { classPropertyName: "collapsible", publicName: "collapsible", isSignal: true, isRequired: false, transformFunction: null }, loadingType: { classPropertyName: "loadingType", publicName: "loadingType", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { data: "dataChange" }, usesInheritance: true, ngImport: i0, template: '', isInline: true }); }
72
+ }
73
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.5", ngImport: i0, type: XThoughtChainProperty, decorators: [{
74
+ type: Component,
75
+ args: [{ selector: `${XThoughtChainPrefix}-property`, template: '' }]
76
+ }], propDecorators: { data: [{ type: i0.Input, args: [{ isSignal: true, alias: "data", required: false }] }, { type: i0.Output, args: ["dataChange"] }], showNumber: [{ type: i0.Input, args: [{ isSignal: true, alias: "showNumber", required: false }] }], size: [{ type: i0.Input, args: [{ isSignal: true, alias: "size", required: false }] }], wrapper: [{ type: i0.Input, args: [{ isSignal: true, alias: "wrapper", required: false }] }], icon: [{ type: i0.Input, args: [{ isSignal: true, alias: "icon", required: false }] }], extra: [{ type: i0.Input, args: [{ isSignal: true, alias: "extra", required: false }] }], content: [{ type: i0.Input, args: [{ isSignal: true, alias: "content", required: false }] }], collapsible: [{ type: i0.Input, args: [{ isSignal: true, alias: "collapsible", required: false }] }], loadingType: [{ type: i0.Input, args: [{ isSignal: true, alias: "loadingType", required: false }] }] } });
77
+
78
+ class XThoughtChainComponent extends XThoughtChainProperty {
79
+ constructor() {
80
+ super(...arguments);
81
+ this.cdr = inject(ChangeDetectorRef);
82
+ }
83
+ addNode(node) {
84
+ this.data.update((x) => [...x, node]);
85
+ }
86
+ updateNode(node) {
87
+ const nd = this.data().find((x) => x.id === node.id);
88
+ if (nd)
89
+ Object.assign(nd, node);
90
+ this.cdr.detectChanges();
91
+ }
92
+ removeNode(node) {
93
+ this.data.update((x) => [...x.filter((y) => y.id !== node.id)]);
94
+ }
95
+ /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.5", ngImport: i0, type: XThoughtChainComponent, deps: null, target: i0.ɵɵFactoryTarget.Component }); }
96
+ /** @nocollapse */ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "20.3.5", type: XThoughtChainComponent, isStandalone: true, selector: "x-thought-chain", usesInheritance: true, ngImport: i0, template: "<div class=\"x-thought-chain\">\r\n <x-timeline\r\n [data]=\"data()\"\r\n [showNumber]=\"showNumber()\"\r\n [icon]=\"iconTpl\"\r\n [wrapper]=\"wrapper() ?? wrapperTpl\"\r\n [size]=\"size()\"\r\n ></x-timeline>\r\n\r\n <ng-template #iconTpl let-node=\"$node\" let-index=\"$index\">\r\n <div\r\n class=\"x-thought-chain-icon\"\r\n [class.x-thought-chain-success]=\"node.status === 'success'\"\r\n [class.x-thought-chain-error]=\"node.status === 'error'\"\r\n [class.x-thought-chain-pending]=\"node.status === 'pending'\"\r\n [style.backgroundColor]=\"node.color\"\r\n >\r\n @if (showNumber() && !node.icon && !node.loading && node.status !== 'pending') {\r\n {{ index + 1 }}\r\n }\r\n @if (node.icon && !node.loading && node.status !== 'pending') {\r\n <x-icon [type]=\"node.icon\"></x-icon>\r\n }\r\n @if (node.loading || node.status === 'pending') {\r\n <x-loading inline [x-loading]=\"true\" [size]=\"size()\" [type]=\"loadingType()\"></x-loading>\r\n }\r\n </div>\r\n </ng-template>\r\n\r\n <ng-template #wrapperTpl let-node=\"$node\" let-index=\"$index\">\r\n @if (collapsible()) {\r\n <x-collapse class=\"x-thought-chain-collapse\" ghost iconPosition=\"left\">\r\n <x-collapse-panel [label]=\"labelTpl\">\r\n <ng-container *xOutlet=\"contentTpl\"></ng-container>\r\n </x-collapse-panel>\r\n </x-collapse>\r\n } @else {\r\n <ng-container *xOutlet=\"labelTpl\"></ng-container>\r\n <ng-container *xOutlet=\"contentTpl\"></ng-container>\r\n }\r\n <ng-template #labelTpl>\r\n <div class=\"x-thought-chain-wrapper\">\r\n <div class=\"x-thought-chain-inner\">\r\n <div class=\"x-thought-chain-label\">{{ node.label }}</div>\r\n <div class=\"x-thought-chain-description\">{{ node.description }}</div>\r\n </div>\r\n <div class=\"x-thought-chain-extra\">\r\n <ng-container *xOutlet=\"extra(); context: { $node: node, $index: index }\"></ng-container>\r\n </div>\r\n </div>\r\n </ng-template>\r\n\r\n <ng-template #contentTpl>\r\n @if (node.content || content()) {\r\n @if (content()) {\r\n <div class=\"x-thought-chain-content\">\r\n <ng-container *xOutlet=\"content(); context: { $node: node, $index: index }\"></ng-container>\r\n </div>\r\n } @else {\r\n <div class=\"x-thought-chain-content\" [innerHTML]=\"node.content\"></div>\r\n }\r\n }\r\n </ng-template>\r\n </ng-template>\r\n</div>\r\n", styles: [".x-thought-chain{margin:0;padding:0}.x-thought-chain-wrapper{display:flex}.x-thought-chain-inner{flex:1;display:flex;flex-direction:column}.x-thought-chain-label{font-weight:600}.x-thought-chain-description{color:var(--x-text-400)}.x-thought-chain-content{position:relative;border:var(--x-border-width) var(--x-border-style) var(--x-border);border-radius:var(--x-border-radius);background-color:var(--x-white)}.x-thought-chain-collapse .x-collapse-panel-header{padding:0;align-items:flex-start}.x-thought-chain-icon{width:100%;height:100%;border-radius:50%;display:flex;justify-content:center;align-items:center}.x-thought-chain-success{background-color:var(--x-success)}.x-thought-chain-error{background-color:var(--x-danger)}.x-thought-chain .x-timeline-big .x-thought-chain-label{line-height:calc(var(--x-height-big) - .5rem)}.x-thought-chain .x-timeline-big .x-thought-chain-content{line-height:calc(var(--x-height-big) - .75rem);padding:var(--x-padding-big)}.x-thought-chain .x-timeline-big .x-thought-chain-collapse .x-collapse-panel-header>.x-icon{height:calc(var(--x-height-big) - .5rem);display:flex;align-items:center}.x-thought-chain .x-timeline-big .x-thought-chain-collapse .x-collapse-panel-content{padding:calc(var(--x-padding-big) * .5) 0}.x-thought-chain .x-timeline-large .x-thought-chain-label{line-height:calc(var(--x-height-large) - .5rem)}.x-thought-chain .x-timeline-large .x-thought-chain-content{line-height:calc(var(--x-height-large) - .75rem);padding:var(--x-padding-large)}.x-thought-chain .x-timeline-large .x-thought-chain-collapse .x-collapse-panel-header>.x-icon{height:calc(var(--x-height-large) - .5rem);display:flex;align-items:center}.x-thought-chain .x-timeline-large .x-thought-chain-collapse .x-collapse-panel-content{padding:calc(var(--x-padding-large) * .5) 0}.x-thought-chain .x-timeline-medium .x-thought-chain-label{line-height:calc(var(--x-height-medium) - .5rem)}.x-thought-chain .x-timeline-medium .x-thought-chain-content{line-height:calc(var(--x-height-medium) - .75rem);padding:var(--x-padding-medium)}.x-thought-chain .x-timeline-medium .x-thought-chain-collapse .x-collapse-panel-header>.x-icon{height:calc(var(--x-height-medium) - .5rem);display:flex;align-items:center}.x-thought-chain .x-timeline-medium .x-thought-chain-collapse .x-collapse-panel-content{padding:calc(var(--x-padding-medium) * .5) 0}.x-thought-chain .x-timeline-small .x-thought-chain-label{line-height:calc(var(--x-height-small) - .5rem)}.x-thought-chain .x-timeline-small .x-thought-chain-content{line-height:calc(var(--x-height-small) - .75rem);padding:var(--x-padding-small)}.x-thought-chain .x-timeline-small .x-thought-chain-collapse .x-collapse-panel-header>.x-icon{height:calc(var(--x-height-small) - .5rem);display:flex;align-items:center}.x-thought-chain .x-timeline-small .x-thought-chain-collapse .x-collapse-panel-content{padding:calc(var(--x-padding-small) * .5) 0}.x-thought-chain .x-timeline-mini .x-thought-chain-label{line-height:calc(var(--x-height-mini) - .5rem)}.x-thought-chain .x-timeline-mini .x-thought-chain-content{line-height:calc(var(--x-height-mini) - .75rem);padding:var(--x-padding-mini)}.x-thought-chain .x-timeline-mini .x-thought-chain-collapse .x-collapse-panel-header>.x-icon{height:calc(var(--x-height-mini) - .5rem);display:flex;align-items:center}.x-thought-chain .x-timeline-mini .x-thought-chain-collapse .x-collapse-panel-content{padding:calc(var(--x-padding-mini) * .5) 0}\n"], dependencies: [{ kind: "component", type: XTimelineComponent, selector: "x-timeline" }, { kind: "directive", type: XOutletDirective, selector: "[xOutlet]", inputs: ["xOutletContext", "xOutlet"] }, { kind: "component", type: XIconComponent, selector: "x-icon" }, { kind: "component", type: XLoadingComponent, selector: "x-loading, [x-loading]" }, { kind: "ngmodule", type: XCollapseModule }, { kind: "component", type: i1.XCollapseComponent, selector: "x-collapse" }, { kind: "component", type: i1.XCollapsePanelComponent, selector: "x-collapse-panel" }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
97
+ }
98
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.5", ngImport: i0, type: XThoughtChainComponent, decorators: [{
99
+ type: Component,
100
+ args: [{ selector: 'x-thought-chain', encapsulation: ViewEncapsulation.None, changeDetection: ChangeDetectionStrategy.OnPush, imports: [XTimelineComponent, XOutletDirective, XIconComponent, XLoadingComponent, XCollapseModule], template: "<div class=\"x-thought-chain\">\r\n <x-timeline\r\n [data]=\"data()\"\r\n [showNumber]=\"showNumber()\"\r\n [icon]=\"iconTpl\"\r\n [wrapper]=\"wrapper() ?? wrapperTpl\"\r\n [size]=\"size()\"\r\n ></x-timeline>\r\n\r\n <ng-template #iconTpl let-node=\"$node\" let-index=\"$index\">\r\n <div\r\n class=\"x-thought-chain-icon\"\r\n [class.x-thought-chain-success]=\"node.status === 'success'\"\r\n [class.x-thought-chain-error]=\"node.status === 'error'\"\r\n [class.x-thought-chain-pending]=\"node.status === 'pending'\"\r\n [style.backgroundColor]=\"node.color\"\r\n >\r\n @if (showNumber() && !node.icon && !node.loading && node.status !== 'pending') {\r\n {{ index + 1 }}\r\n }\r\n @if (node.icon && !node.loading && node.status !== 'pending') {\r\n <x-icon [type]=\"node.icon\"></x-icon>\r\n }\r\n @if (node.loading || node.status === 'pending') {\r\n <x-loading inline [x-loading]=\"true\" [size]=\"size()\" [type]=\"loadingType()\"></x-loading>\r\n }\r\n </div>\r\n </ng-template>\r\n\r\n <ng-template #wrapperTpl let-node=\"$node\" let-index=\"$index\">\r\n @if (collapsible()) {\r\n <x-collapse class=\"x-thought-chain-collapse\" ghost iconPosition=\"left\">\r\n <x-collapse-panel [label]=\"labelTpl\">\r\n <ng-container *xOutlet=\"contentTpl\"></ng-container>\r\n </x-collapse-panel>\r\n </x-collapse>\r\n } @else {\r\n <ng-container *xOutlet=\"labelTpl\"></ng-container>\r\n <ng-container *xOutlet=\"contentTpl\"></ng-container>\r\n }\r\n <ng-template #labelTpl>\r\n <div class=\"x-thought-chain-wrapper\">\r\n <div class=\"x-thought-chain-inner\">\r\n <div class=\"x-thought-chain-label\">{{ node.label }}</div>\r\n <div class=\"x-thought-chain-description\">{{ node.description }}</div>\r\n </div>\r\n <div class=\"x-thought-chain-extra\">\r\n <ng-container *xOutlet=\"extra(); context: { $node: node, $index: index }\"></ng-container>\r\n </div>\r\n </div>\r\n </ng-template>\r\n\r\n <ng-template #contentTpl>\r\n @if (node.content || content()) {\r\n @if (content()) {\r\n <div class=\"x-thought-chain-content\">\r\n <ng-container *xOutlet=\"content(); context: { $node: node, $index: index }\"></ng-container>\r\n </div>\r\n } @else {\r\n <div class=\"x-thought-chain-content\" [innerHTML]=\"node.content\"></div>\r\n }\r\n }\r\n </ng-template>\r\n </ng-template>\r\n</div>\r\n", styles: [".x-thought-chain{margin:0;padding:0}.x-thought-chain-wrapper{display:flex}.x-thought-chain-inner{flex:1;display:flex;flex-direction:column}.x-thought-chain-label{font-weight:600}.x-thought-chain-description{color:var(--x-text-400)}.x-thought-chain-content{position:relative;border:var(--x-border-width) var(--x-border-style) var(--x-border);border-radius:var(--x-border-radius);background-color:var(--x-white)}.x-thought-chain-collapse .x-collapse-panel-header{padding:0;align-items:flex-start}.x-thought-chain-icon{width:100%;height:100%;border-radius:50%;display:flex;justify-content:center;align-items:center}.x-thought-chain-success{background-color:var(--x-success)}.x-thought-chain-error{background-color:var(--x-danger)}.x-thought-chain .x-timeline-big .x-thought-chain-label{line-height:calc(var(--x-height-big) - .5rem)}.x-thought-chain .x-timeline-big .x-thought-chain-content{line-height:calc(var(--x-height-big) - .75rem);padding:var(--x-padding-big)}.x-thought-chain .x-timeline-big .x-thought-chain-collapse .x-collapse-panel-header>.x-icon{height:calc(var(--x-height-big) - .5rem);display:flex;align-items:center}.x-thought-chain .x-timeline-big .x-thought-chain-collapse .x-collapse-panel-content{padding:calc(var(--x-padding-big) * .5) 0}.x-thought-chain .x-timeline-large .x-thought-chain-label{line-height:calc(var(--x-height-large) - .5rem)}.x-thought-chain .x-timeline-large .x-thought-chain-content{line-height:calc(var(--x-height-large) - .75rem);padding:var(--x-padding-large)}.x-thought-chain .x-timeline-large .x-thought-chain-collapse .x-collapse-panel-header>.x-icon{height:calc(var(--x-height-large) - .5rem);display:flex;align-items:center}.x-thought-chain .x-timeline-large .x-thought-chain-collapse .x-collapse-panel-content{padding:calc(var(--x-padding-large) * .5) 0}.x-thought-chain .x-timeline-medium .x-thought-chain-label{line-height:calc(var(--x-height-medium) - .5rem)}.x-thought-chain .x-timeline-medium .x-thought-chain-content{line-height:calc(var(--x-height-medium) - .75rem);padding:var(--x-padding-medium)}.x-thought-chain .x-timeline-medium .x-thought-chain-collapse .x-collapse-panel-header>.x-icon{height:calc(var(--x-height-medium) - .5rem);display:flex;align-items:center}.x-thought-chain .x-timeline-medium .x-thought-chain-collapse .x-collapse-panel-content{padding:calc(var(--x-padding-medium) * .5) 0}.x-thought-chain .x-timeline-small .x-thought-chain-label{line-height:calc(var(--x-height-small) - .5rem)}.x-thought-chain .x-timeline-small .x-thought-chain-content{line-height:calc(var(--x-height-small) - .75rem);padding:var(--x-padding-small)}.x-thought-chain .x-timeline-small .x-thought-chain-collapse .x-collapse-panel-header>.x-icon{height:calc(var(--x-height-small) - .5rem);display:flex;align-items:center}.x-thought-chain .x-timeline-small .x-thought-chain-collapse .x-collapse-panel-content{padding:calc(var(--x-padding-small) * .5) 0}.x-thought-chain .x-timeline-mini .x-thought-chain-label{line-height:calc(var(--x-height-mini) - .5rem)}.x-thought-chain .x-timeline-mini .x-thought-chain-content{line-height:calc(var(--x-height-mini) - .75rem);padding:var(--x-padding-mini)}.x-thought-chain .x-timeline-mini .x-thought-chain-collapse .x-collapse-panel-header>.x-icon{height:calc(var(--x-height-mini) - .5rem);display:flex;align-items:center}.x-thought-chain .x-timeline-mini .x-thought-chain-collapse .x-collapse-panel-content{padding:calc(var(--x-padding-mini) * .5) 0}\n"] }]
101
+ }] });
102
+
103
+ class XThoughtChainModule {
104
+ /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.5", ngImport: i0, type: XThoughtChainModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
105
+ /** @nocollapse */ static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "20.3.5", ngImport: i0, type: XThoughtChainModule, imports: [XThoughtChainComponent], exports: [XThoughtChainComponent] }); }
106
+ /** @nocollapse */ static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "20.3.5", ngImport: i0, type: XThoughtChainModule, imports: [XThoughtChainComponent] }); }
107
+ }
108
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.5", ngImport: i0, type: XThoughtChainModule, decorators: [{
109
+ type: NgModule,
110
+ args: [{
111
+ exports: [XThoughtChainComponent],
112
+ imports: [XThoughtChainComponent]
113
+ }]
114
+ }] });
115
+
116
+ /**
117
+ * Generated bundle index. Do not edit.
118
+ */
119
+
120
+ export { XThoughtChainComponent, XThoughtChainModule, XThoughtChainPrefix, XThoughtChainProperty };
121
+ //# sourceMappingURL=ng-nest-ui-thought-chain.mjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ng-nest-ui-thought-chain.mjs","sources":["../../../../lib/ng-nest/ui/thought-chain/thought-chain.property.ts","../../../../lib/ng-nest/ui/thought-chain/thought-chain.component.ts","../../../../lib/ng-nest/ui/thought-chain/thought-chain.component.html","../../../../lib/ng-nest/ui/thought-chain/thought-chain.module.ts","../../../../lib/ng-nest/ui/thought-chain/ng-nest-ui-thought-chain.ts"],"sourcesContent":["import { Component, input, model } from '@angular/core';\r\nimport { XPropertyFunction, XBoolean, XToBoolean, XSize, XTemplate } from '@ng-nest/ui/core';\r\nimport { XTimelineNode } from '@ng-nest/ui/timeline';\r\nimport type { XLoadingType } from '@ng-nest/ui/loading';\r\n\r\n/**\r\n * ThoughtChain\r\n * @selector x-thought-chain\r\n * @decorator component\r\n */\r\nexport const XThoughtChainPrefix = 'x-thought-chain';\r\nconst X_THOUGHT_CHAIN_CONFIG_NAME = 'thoughtChain';\r\n\r\n/**\r\n * ThoughtChain Property\r\n */\r\n@Component({ selector: `${XThoughtChainPrefix}-property`, template: '' })\r\nexport class XThoughtChainProperty extends XPropertyFunction(X_THOUGHT_CHAIN_CONFIG_NAME) {\r\n /**\r\n * @zh_CN 思维链节点数据\r\n * @en_US ThoughtChain items\r\n */\r\n readonly data = model<XThoughtChainNode[]>([]);\r\n /**\r\n * @zh_CN 显示序号\r\n * @en_US Show number\r\n */\r\n readonly showNumber = input<boolean, XBoolean>(this.config?.showNumber ?? true, { transform: XToBoolean });\r\n /**\r\n * @zh_CN 尺寸\r\n * @en_US Size\r\n */\r\n readonly size = input<XSize>(this.config?.size ?? 'medium');\r\n /**\r\n * @zh_CN 自定义内容模板\r\n * @en_US Content template\r\n */\r\n readonly wrapper = input<XTemplate>();\r\n /**\r\n * @zh_CN 自定义图标模板\r\n * @en_US Icon template\r\n */\r\n readonly icon = input<XTemplate>();\r\n /**\r\n * @zh_CN 节点标题右侧额外的内容模板\r\n * @en_US Node extra content\r\n */\r\n readonly extra = input<XTemplate>();\r\n /**\r\n * @zh_CN 节点详细内容模板\r\n * @en_US Node detail content\r\n */\r\n readonly content = input<XTemplate>();\r\n /**\r\n * @zh_CN 详细内容是否可折叠\r\n * @en_US Collapsible detail content\r\n */\r\n readonly collapsible = input<boolean, XBoolean>(this.config?.collapsible ?? false, { transform: XToBoolean });\r\n /**\r\n * @zh_CN loading 的类型样式\r\n * @en_US Loading type style\r\n */\r\n readonly loadingType = input<XLoadingType>(this.config?.loadingType ?? 'circular');\r\n}\r\n\r\n/**\r\n * @zh_CN 思维链节点\r\n * @en_US Thought chain node\r\n */\r\nexport interface XThoughtChainNode extends XTimelineNode {\r\n /**\r\n * @zh_CN 节点描述\r\n * @en_US Node description\r\n */\r\n description?: string;\r\n /**\r\n * @zh_CN 节点状态\r\n * @en_US Node status\r\n */\r\n status?: XThoughtChainNodeStatus;\r\n}\r\n\r\n/**\r\n * @zh_CN 节点状态\r\n * @en_US Node status\r\n */\r\nexport type XThoughtChainNodeStatus = 'success' | 'error' | 'pending';\r\n","import { ChangeDetectionStrategy, ChangeDetectorRef, Component, inject, ViewEncapsulation } from '@angular/core';\r\nimport { XThoughtChainNode, XThoughtChainProperty } from './thought-chain.property';\r\nimport { XTimelineComponent } from '@ng-nest/ui/timeline';\r\nimport { XOutletDirective } from '@ng-nest/ui/outlet';\r\nimport { XIconComponent } from '@ng-nest/ui/icon';\r\nimport { XLoadingComponent } from '@ng-nest/ui/loading';\r\nimport { XCollapseModule } from '@ng-nest/ui/collapse';\r\n\r\n@Component({\r\n selector: 'x-thought-chain',\r\n templateUrl: './thought-chain.component.html',\r\n styleUrls: ['./thought-chain.component.scss'],\r\n encapsulation: ViewEncapsulation.None,\r\n changeDetection: ChangeDetectionStrategy.OnPush,\r\n imports: [XTimelineComponent, XOutletDirective, XIconComponent, XLoadingComponent, XCollapseModule]\r\n})\r\nexport class XThoughtChainComponent extends XThoughtChainProperty {\r\n cdr = inject(ChangeDetectorRef);\r\n addNode(node: XThoughtChainNode) {\r\n this.data.update((x) => [...x, node]);\r\n }\r\n\r\n updateNode(node: XThoughtChainNode) {\r\n const nd = this.data().find((x) => x.id === node.id);\r\n if (nd) Object.assign(nd, node);\r\n this.cdr.detectChanges();\r\n }\r\n\r\n removeNode(node: XThoughtChainNode) {\r\n this.data.update((x) => [...x.filter((y) => y.id !== node.id)]);\r\n }\r\n}\r\n","<div class=\"x-thought-chain\">\r\n <x-timeline\r\n [data]=\"data()\"\r\n [showNumber]=\"showNumber()\"\r\n [icon]=\"iconTpl\"\r\n [wrapper]=\"wrapper() ?? wrapperTpl\"\r\n [size]=\"size()\"\r\n ></x-timeline>\r\n\r\n <ng-template #iconTpl let-node=\"$node\" let-index=\"$index\">\r\n <div\r\n class=\"x-thought-chain-icon\"\r\n [class.x-thought-chain-success]=\"node.status === 'success'\"\r\n [class.x-thought-chain-error]=\"node.status === 'error'\"\r\n [class.x-thought-chain-pending]=\"node.status === 'pending'\"\r\n [style.backgroundColor]=\"node.color\"\r\n >\r\n @if (showNumber() && !node.icon && !node.loading && node.status !== 'pending') {\r\n {{ index + 1 }}\r\n }\r\n @if (node.icon && !node.loading && node.status !== 'pending') {\r\n <x-icon [type]=\"node.icon\"></x-icon>\r\n }\r\n @if (node.loading || node.status === 'pending') {\r\n <x-loading inline [x-loading]=\"true\" [size]=\"size()\" [type]=\"loadingType()\"></x-loading>\r\n }\r\n </div>\r\n </ng-template>\r\n\r\n <ng-template #wrapperTpl let-node=\"$node\" let-index=\"$index\">\r\n @if (collapsible()) {\r\n <x-collapse class=\"x-thought-chain-collapse\" ghost iconPosition=\"left\">\r\n <x-collapse-panel [label]=\"labelTpl\">\r\n <ng-container *xOutlet=\"contentTpl\"></ng-container>\r\n </x-collapse-panel>\r\n </x-collapse>\r\n } @else {\r\n <ng-container *xOutlet=\"labelTpl\"></ng-container>\r\n <ng-container *xOutlet=\"contentTpl\"></ng-container>\r\n }\r\n <ng-template #labelTpl>\r\n <div class=\"x-thought-chain-wrapper\">\r\n <div class=\"x-thought-chain-inner\">\r\n <div class=\"x-thought-chain-label\">{{ node.label }}</div>\r\n <div class=\"x-thought-chain-description\">{{ node.description }}</div>\r\n </div>\r\n <div class=\"x-thought-chain-extra\">\r\n <ng-container *xOutlet=\"extra(); context: { $node: node, $index: index }\"></ng-container>\r\n </div>\r\n </div>\r\n </ng-template>\r\n\r\n <ng-template #contentTpl>\r\n @if (node.content || content()) {\r\n @if (content()) {\r\n <div class=\"x-thought-chain-content\">\r\n <ng-container *xOutlet=\"content(); context: { $node: node, $index: index }\"></ng-container>\r\n </div>\r\n } @else {\r\n <div class=\"x-thought-chain-content\" [innerHTML]=\"node.content\"></div>\r\n }\r\n }\r\n </ng-template>\r\n </ng-template>\r\n</div>\r\n","import { NgModule } from '@angular/core';\r\nimport { XThoughtChainComponent } from './thought-chain.component';\r\n\r\n@NgModule({\r\n exports: [XThoughtChainComponent],\r\n imports: [XThoughtChainComponent]\r\n})\r\nexport class XThoughtChainModule {}\r\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;;;;;;;AAKA;;;;AAIG;AACI,MAAM,mBAAmB,GAAG;AACnC,MAAM,2BAA2B,GAAG,cAAc;AAElD;;AAEG;MAEU,qBAAsB,SAAQ,iBAAiB,CAAC,2BAA2B,CAAC,CAAA;AADzF,IAAA,WAAA,GAAA;;AAEE;;;AAGG;AACM,QAAA,IAAA,CAAA,IAAI,GAAG,KAAK,CAAsB,EAAE,gDAAC;AAC9C;;;AAGG;QACM,IAAA,CAAA,UAAU,GAAG,KAAK,CAAoB,IAAI,CAAC,MAAM,EAAE,UAAU,IAAI,IA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;kBARlC,SAAS;AACE,YAAA,IAAA,EAAA,CAAA,EAAA,QAAA,EAAA,iBAAiB,iBAGZ,iBAAiB,CAAC,IAAI,EAAA,eAAA,EACpB,uBAAuB,CAAC,MAAM,EAAA,OAAA,EACtC,CAAC,kBAAkB,EAAE,gBAAgB,EAAE,cAAc,EAAE,iBAAiB,EAAE,eAAe,CAAC,EAAA,QAAA,EAAA,oiFAAA,EAAA,MAAA,EAAA,CAAA,m3GAAA,CAAA,EAAA;;;MEPxF,mBAAmB,CAAA;iIAAnB,mBAAmB,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,QAAA,EAAA,CAAA,CAAA;kIAAnB,mBAAmB,EAAA,OAAA,EAAA,CAFpB,sBAAsB,CAAA,EAAA,OAAA,EAAA,CADtB,sBAAsB,CAAA,EAAA,CAAA,CAAA;AAGrB,uBAAA,SAAA,IAAA,CAAA,IAAA,GAAA,EAAA,CAAA,mBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,QAAA,EAAA,QAAA,EAAA,EAAA,EAAA,IAAA,EAAA,mBAAmB,YAFpB,sBAAsB,CAAA,EAAA,CAAA,CAAA;;2FAErB,mBAAmB,EAAA,UAAA,EAAA,CAAA;kBAJ/B,QAAQ;AAAC,YAAA,IAAA,EAAA,CAAA;oBACR,OAAO,EAAE,CAAC,sBAAsB,CAAC;oBACjC,OAAO,EAAE,CAAC,sBAAsB;AACjC,iBAAA;;;ACND;;AAEG;;;;"}
@@ -67,20 +67,20 @@ class XTimeAgoPipe extends DatePipe {
67
67
  result = this.localeI18n()?.just;
68
68
  return result;
69
69
  }
70
- /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.0", ngImport: i0, type: XTimeAgoPipe, deps: null, target: i0.ɵɵFactoryTarget.Pipe }); }
71
- /** @nocollapse */ static { this.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "20.3.0", ngImport: i0, type: XTimeAgoPipe, isStandalone: true, name: "xTimeAgo" }); }
70
+ /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.5", ngImport: i0, type: XTimeAgoPipe, deps: null, target: i0.ɵɵFactoryTarget.Pipe }); }
71
+ /** @nocollapse */ static { this.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "20.3.5", ngImport: i0, type: XTimeAgoPipe, isStandalone: true, name: "xTimeAgo" }); }
72
72
  }
73
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.0", ngImport: i0, type: XTimeAgoPipe, decorators: [{
73
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.5", ngImport: i0, type: XTimeAgoPipe, decorators: [{
74
74
  type: Pipe,
75
75
  args: [{ name: `${XTimeAgoPrefix}` }]
76
76
  }] });
77
77
 
78
78
  class XTimeAgoModule {
79
- /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.0", ngImport: i0, type: XTimeAgoModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
80
- /** @nocollapse */ static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "20.3.0", ngImport: i0, type: XTimeAgoModule, imports: [XTimeAgoPipe], exports: [XTimeAgoPipe] }); }
81
- /** @nocollapse */ static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "20.3.0", ngImport: i0, type: XTimeAgoModule }); }
79
+ /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.5", ngImport: i0, type: XTimeAgoModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
80
+ /** @nocollapse */ static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "20.3.5", ngImport: i0, type: XTimeAgoModule, imports: [XTimeAgoPipe], exports: [XTimeAgoPipe] }); }
81
+ /** @nocollapse */ static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "20.3.5", ngImport: i0, type: XTimeAgoModule }); }
82
82
  }
83
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.0", ngImport: i0, type: XTimeAgoModule, decorators: [{
83
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.5", ngImport: i0, type: XTimeAgoModule, decorators: [{
84
84
  type: NgModule,
85
85
  args: [{
86
86
  exports: [XTimeAgoPipe],