@elliemae/ds-chat 1.53.4-rc.3 → 1.53.5-rc.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 (195) hide show
  1. package/cjs/index.js +14 -1
  2. package/cjs/index.js.map +1 -1
  3. package/cjs/parts/bubble/ChatBubble.js +8 -1
  4. package/cjs/parts/bubble/ChatBubble.js.map +1 -1
  5. package/cjs/parts/bubble/config/useValidateProps.js +32 -0
  6. package/cjs/parts/bubble/config/useValidateProps.js.map +1 -0
  7. package/cjs/parts/bubble/index.js +4 -1
  8. package/cjs/parts/bubble/index.js.map +1 -1
  9. package/cjs/parts/bubble/props.js +4 -4
  10. package/cjs/parts/bubble/props.js.map +1 -1
  11. package/cjs/parts/bubble/styled.js +1 -1
  12. package/cjs/parts/bubble/styled.js.map +1 -1
  13. package/cjs/parts/chat-card/ChatCard.js +9 -6
  14. package/cjs/parts/chat-card/ChatCard.js.map +1 -1
  15. package/cjs/parts/chat-card/config/useValidateProps.js +12 -0
  16. package/cjs/parts/chat-card/config/useValidateProps.js.map +1 -0
  17. package/cjs/parts/chat-card/index.js +3 -1
  18. package/cjs/parts/chat-card/index.js.map +1 -1
  19. package/cjs/parts/chat-card/props.js +1 -1
  20. package/cjs/parts/chat-card/props.js.map +1 -1
  21. package/cjs/parts/chat-composer/ChatContainerComposer.js +19 -2
  22. package/cjs/parts/chat-composer/ChatContainerComposer.js.map +1 -1
  23. package/cjs/parts/chat-composer/config/useValidateProps.js +12 -0
  24. package/cjs/parts/chat-composer/config/useValidateProps.js.map +1 -0
  25. package/cjs/parts/chat-composer/index.js +2 -0
  26. package/cjs/parts/chat-composer/index.js.map +1 -1
  27. package/cjs/parts/chat-composer/props.js +6 -4
  28. package/cjs/parts/chat-composer/props.js.map +1 -1
  29. package/cjs/parts/chat-composer/styled.js +2 -2
  30. package/cjs/parts/chat-composer/styled.js.map +1 -1
  31. package/cjs/parts/chat-container/ChatContainer.js +10 -1
  32. package/cjs/parts/chat-container/ChatContainer.js.map +1 -1
  33. package/cjs/parts/chat-container/config/useValidateProps.js +12 -0
  34. package/cjs/parts/chat-container/config/useValidateProps.js.map +1 -0
  35. package/cjs/parts/chat-container/index.js +7 -0
  36. package/cjs/parts/chat-container/index.js.map +1 -1
  37. package/cjs/parts/chat-container/props.js +3 -2
  38. package/cjs/parts/chat-container/props.js.map +1 -1
  39. package/cjs/parts/chat-container/styled.js +3 -1
  40. package/cjs/parts/chat-container/styled.js.map +1 -1
  41. package/cjs/parts/chat-container-messages-list/ChatContainerMessagesList.js +70 -11
  42. package/cjs/parts/chat-container-messages-list/ChatContainerMessagesList.js.map +1 -1
  43. package/cjs/parts/chat-container-messages-list/config/useValidateProps.js +12 -0
  44. package/cjs/parts/chat-container-messages-list/config/useValidateProps.js.map +1 -0
  45. package/cjs/parts/chat-container-messages-list/index.js +5 -0
  46. package/cjs/parts/chat-container-messages-list/index.js.map +1 -1
  47. package/cjs/parts/chat-container-messages-list/props.js +1 -1
  48. package/cjs/parts/chat-container-messages-list/props.js.map +1 -1
  49. package/cjs/parts/chat-container-messages-list/styled.js +9 -1
  50. package/cjs/parts/chat-container-messages-list/styled.js.map +1 -1
  51. package/cjs/parts/chat-empty-state/ChatEmptyState.js +14 -3
  52. package/cjs/parts/chat-empty-state/ChatEmptyState.js.map +1 -1
  53. package/cjs/parts/chat-empty-state/config/useValidateProps.js +12 -0
  54. package/cjs/parts/chat-empty-state/config/useValidateProps.js.map +1 -0
  55. package/cjs/parts/chat-empty-state/props.js +2 -1
  56. package/cjs/parts/chat-empty-state/props.js.map +1 -1
  57. package/cjs/parts/chat-sidebar/SideBarChat.js +12 -8
  58. package/cjs/parts/chat-sidebar/SideBarChat.js.map +1 -1
  59. package/cjs/parts/chat-sidebar/config/useValidateProps.js +12 -0
  60. package/cjs/parts/chat-sidebar/config/useValidateProps.js.map +1 -0
  61. package/cjs/parts/chat-sidebar/index.js +4 -1
  62. package/cjs/parts/chat-sidebar/index.js.map +1 -1
  63. package/cjs/parts/floating-button/FloatingButton.js.map +1 -1
  64. package/cjs/parts/grid-influencer/InfluencerContainer.js +9 -0
  65. package/cjs/parts/grid-influencer/InfluencerContainer.js.map +1 -1
  66. package/cjs/parts/message-delimiter/MessageDelimiter.js +8 -5
  67. package/cjs/parts/message-delimiter/MessageDelimiter.js.map +1 -1
  68. package/cjs/parts/message-delimiter/config/useValidateProps.js +12 -0
  69. package/cjs/parts/message-delimiter/config/useValidateProps.js.map +1 -0
  70. package/cjs/parts/message-delimiter/index.js +2 -0
  71. package/cjs/parts/message-delimiter/index.js.map +1 -1
  72. package/cjs/parts/message-delimiter/props.js +1 -1
  73. package/cjs/parts/message-delimiter/props.js.map +1 -1
  74. package/cjs/parts/sidebar-button/SidebarButton.js.map +1 -1
  75. package/cjs/parts/sidebar-button/styled.js +3 -1
  76. package/cjs/parts/sidebar-button/styled.js.map +1 -1
  77. package/cjs/parts/system-message/SystemMessage.js +7 -4
  78. package/cjs/parts/system-message/SystemMessage.js.map +1 -1
  79. package/cjs/parts/system-message/config/useValidateProps.js +12 -0
  80. package/cjs/parts/system-message/config/useValidateProps.js.map +1 -0
  81. package/cjs/parts/system-message/index.js +2 -0
  82. package/cjs/parts/system-message/index.js.map +1 -1
  83. package/cjs/parts/tile-button/TileButton.js +3 -1
  84. package/cjs/parts/tile-button/TileButton.js.map +1 -1
  85. package/cjs/parts/tile-button/config/useValidateProps.js +12 -0
  86. package/cjs/parts/tile-button/config/useValidateProps.js.map +1 -0
  87. package/cjs/parts/tile-button/index.js +2 -1
  88. package/cjs/parts/tile-button/index.js.map +1 -1
  89. package/cjs/parts/tile-button/props.js +3 -5
  90. package/cjs/parts/tile-button/props.js.map +1 -1
  91. package/cjs/parts/tile-button/styled.js +9 -5
  92. package/cjs/parts/tile-button/styled.js.map +1 -1
  93. package/esm/index.js +14 -2
  94. package/esm/index.js.map +1 -1
  95. package/esm/parts/bubble/ChatBubble.js +8 -2
  96. package/esm/parts/bubble/ChatBubble.js.map +1 -1
  97. package/esm/parts/bubble/config/useValidateProps.js +28 -0
  98. package/esm/parts/bubble/config/useValidateProps.js.map +1 -0
  99. package/esm/parts/bubble/index.js +4 -2
  100. package/esm/parts/bubble/index.js.map +1 -1
  101. package/esm/parts/bubble/props.js +4 -4
  102. package/esm/parts/bubble/props.js.map +1 -1
  103. package/esm/parts/bubble/styled.js +1 -1
  104. package/esm/parts/bubble/styled.js.map +1 -1
  105. package/esm/parts/chat-card/ChatCard.js +9 -6
  106. package/esm/parts/chat-card/ChatCard.js.map +1 -1
  107. package/esm/parts/chat-card/config/useValidateProps.js +8 -0
  108. package/esm/parts/chat-card/config/useValidateProps.js.map +1 -0
  109. package/esm/parts/chat-card/index.js +3 -1
  110. package/esm/parts/chat-card/index.js.map +1 -1
  111. package/esm/parts/chat-card/props.js +1 -1
  112. package/esm/parts/chat-card/props.js.map +1 -1
  113. package/esm/parts/chat-composer/ChatContainerComposer.js +19 -2
  114. package/esm/parts/chat-composer/ChatContainerComposer.js.map +1 -1
  115. package/esm/parts/chat-composer/config/useValidateProps.js +8 -0
  116. package/esm/parts/chat-composer/config/useValidateProps.js.map +1 -0
  117. package/esm/parts/chat-composer/index.js +2 -0
  118. package/esm/parts/chat-composer/index.js.map +1 -1
  119. package/esm/parts/chat-composer/props.js +6 -4
  120. package/esm/parts/chat-composer/props.js.map +1 -1
  121. package/esm/parts/chat-composer/styled.js +2 -2
  122. package/esm/parts/chat-composer/styled.js.map +1 -1
  123. package/esm/parts/chat-container/ChatContainer.js +10 -1
  124. package/esm/parts/chat-container/ChatContainer.js.map +1 -1
  125. package/esm/parts/chat-container/config/useValidateProps.js +8 -0
  126. package/esm/parts/chat-container/config/useValidateProps.js.map +1 -0
  127. package/esm/parts/chat-container/index.js +7 -0
  128. package/esm/parts/chat-container/index.js.map +1 -1
  129. package/esm/parts/chat-container/props.js +3 -2
  130. package/esm/parts/chat-container/props.js.map +1 -1
  131. package/esm/parts/chat-container/styled.js +3 -1
  132. package/esm/parts/chat-container/styled.js.map +1 -1
  133. package/esm/parts/chat-container-messages-list/ChatContainerMessagesList.js +71 -12
  134. package/esm/parts/chat-container-messages-list/ChatContainerMessagesList.js.map +1 -1
  135. package/esm/parts/chat-container-messages-list/config/useValidateProps.js +8 -0
  136. package/esm/parts/chat-container-messages-list/config/useValidateProps.js.map +1 -0
  137. package/esm/parts/chat-container-messages-list/index.js +5 -0
  138. package/esm/parts/chat-container-messages-list/index.js.map +1 -1
  139. package/esm/parts/chat-container-messages-list/props.js +1 -1
  140. package/esm/parts/chat-container-messages-list/props.js.map +1 -1
  141. package/esm/parts/chat-container-messages-list/styled.js +9 -2
  142. package/esm/parts/chat-container-messages-list/styled.js.map +1 -1
  143. package/esm/parts/chat-empty-state/ChatEmptyState.js +14 -4
  144. package/esm/parts/chat-empty-state/ChatEmptyState.js.map +1 -1
  145. package/esm/parts/chat-empty-state/config/useValidateProps.js +8 -0
  146. package/esm/parts/chat-empty-state/config/useValidateProps.js.map +1 -0
  147. package/esm/parts/chat-empty-state/props.js +2 -1
  148. package/esm/parts/chat-empty-state/props.js.map +1 -1
  149. package/esm/parts/chat-sidebar/SideBarChat.js +12 -8
  150. package/esm/parts/chat-sidebar/SideBarChat.js.map +1 -1
  151. package/esm/parts/chat-sidebar/config/useValidateProps.js +8 -0
  152. package/esm/parts/chat-sidebar/config/useValidateProps.js.map +1 -0
  153. package/esm/parts/chat-sidebar/index.js +4 -1
  154. package/esm/parts/chat-sidebar/index.js.map +1 -1
  155. package/esm/parts/floating-button/FloatingButton.js.map +1 -1
  156. package/esm/parts/grid-influencer/InfluencerContainer.js +9 -0
  157. package/esm/parts/grid-influencer/InfluencerContainer.js.map +1 -1
  158. package/esm/parts/message-delimiter/MessageDelimiter.js +8 -5
  159. package/esm/parts/message-delimiter/MessageDelimiter.js.map +1 -1
  160. package/esm/parts/message-delimiter/config/useValidateProps.js +8 -0
  161. package/esm/parts/message-delimiter/config/useValidateProps.js.map +1 -0
  162. package/esm/parts/message-delimiter/index.js +2 -0
  163. package/esm/parts/message-delimiter/index.js.map +1 -1
  164. package/esm/parts/message-delimiter/props.js +1 -1
  165. package/esm/parts/message-delimiter/props.js.map +1 -1
  166. package/esm/parts/sidebar-button/SidebarButton.js.map +1 -1
  167. package/esm/parts/sidebar-button/styled.js +3 -1
  168. package/esm/parts/sidebar-button/styled.js.map +1 -1
  169. package/esm/parts/system-message/SystemMessage.js +7 -4
  170. package/esm/parts/system-message/SystemMessage.js.map +1 -1
  171. package/esm/parts/system-message/config/useValidateProps.js +8 -0
  172. package/esm/parts/system-message/config/useValidateProps.js.map +1 -0
  173. package/esm/parts/system-message/index.js +2 -0
  174. package/esm/parts/system-message/index.js.map +1 -1
  175. package/esm/parts/tile-button/TileButton.js +3 -1
  176. package/esm/parts/tile-button/TileButton.js.map +1 -1
  177. package/esm/parts/tile-button/config/useValidateProps.js +8 -0
  178. package/esm/parts/tile-button/config/useValidateProps.js.map +1 -0
  179. package/esm/parts/tile-button/index.js +2 -1
  180. package/esm/parts/tile-button/index.js.map +1 -1
  181. package/esm/parts/tile-button/props.js +3 -4
  182. package/esm/parts/tile-button/props.js.map +1 -1
  183. package/esm/parts/tile-button/styled.js +9 -5
  184. package/esm/parts/tile-button/styled.js.map +1 -1
  185. package/package.json +5 -5
  186. package/parts/bubble/config/useValidateProps/package.json +10 -0
  187. package/parts/chat-card/config/useValidateProps/package.json +10 -0
  188. package/parts/chat-composer/config/useValidateProps/package.json +10 -0
  189. package/parts/chat-container/config/useValidateProps/package.json +10 -0
  190. package/parts/chat-container-messages-list/config/useValidateProps/package.json +10 -0
  191. package/parts/chat-empty-state/config/useValidateProps/package.json +10 -0
  192. package/parts/chat-sidebar/config/useValidateProps/package.json +10 -0
  193. package/parts/message-delimiter/config/useValidateProps/package.json +10 -0
  194. package/parts/system-message/config/useValidateProps/package.json +10 -0
  195. package/parts/tile-button/config/useValidateProps/package.json +10 -0
@@ -1 +1 @@
1
- {"version":3,"file":"props.js","sources":["../../../../src/parts/chat-container-messages-list/props.ts"],"sourcesContent":["import { Ref } from 'react';\nimport { PropTypes } from 'react-desc';\nimport { noop } from 'lodash';\nimport { BubbleProps } from '../bubble/props';\n\ninterface ActionRef {\n scrollToIndex: (n: number, b: { align: 'end' | 'center' | 'start' }) => void;\n getMessagesInView: () => number[];\n}\nexport interface ChatContainerMessagesListProps {\n messages: BubbleProps[];\n actionRef: Ref<ActionRef>;\n onScrollEnds: (indexList: number[]) => number[];\n isLoading?: 'top' | 'bottom';\n hasMoreItems?: 'top' | 'bottom';\n getMoreMessages: PropTypes.func;\n sendingMessages?: Array<string | number>;\n sendingText: string;\n}\n\nexport const defaultProps: ChatContainerMessagesListProps = {\n messages: [],\n actionRef: noop,\n onScrollEnds: () => [],\n getMoreMessages: noop,\n sendingMessages: undefined,\n sendingText: 'Sending',\n};\n\nexport const listProps = {\n messages: PropTypes.arrayOf(PropTypes.object)\n .description('The array of out-of-the-box items you want to render inside the ChatMessageList')\n .defaultValue(defaultProps.messages),\n actionRef: PropTypes.func\n .description(\n `Reference: \n { \n scrollToIndex: (n: number) => void,\n getMessagesInView: () => number[],\n }\n \n `,\n )\n .defaultValue(defaultProps.messages),\n onScrollEnds: PropTypes.func.description(`Called when the scroll stops.`),\n isLoading: PropTypes.oneOf(['top', 'bottom', undefined]).description(\n 'Keeps the load more space while the loading is in progress',\n ),\n hasMoreItems: PropTypes.oneOf(['top', 'bottom', undefined]).description(\n 'Show Load More button at the `top` or `bottom` of the container',\n ),\n getMoreMessages: PropTypes.func\n .description('Called when the user clicks on load more')\n .defaultValue(defaultProps.getMoreMessages),\n sendingMessages: PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.string, PropTypes.number]))\n .description('Array of ids of sending messages')\n .defaultValue(defaultProps.sendingMessages),\n sendingText: PropTypes.string\n .description('Label description for messages in sending status')\n .defaultValue(defaultProps.sendingText),\n};\n"],"names":["defaultProps","messages","actionRef","noop","onScrollEnds","getMoreMessages","sendingMessages","undefined","sendingText","listProps","PropTypes","arrayOf","object","description","defaultValue","func","isLoading","oneOf","hasMoreItems","oneOfType","string","number"],"mappings":";;;;;;;IAoBaA,YAA4C,GAAG;AAC1DC,EAAAA,QAAQ,EAAE,EADgD;AAE1DC,EAAAA,SAAS,EAAEC,WAF+C;AAG1DC,EAAAA,YAAY,EAAE;AAAA,WAAM,EAAN;AAAA,GAH4C;AAI1DC,EAAAA,eAAe,EAAEF,WAJyC;AAK1DG,EAAAA,eAAe,EAAEC,SALyC;AAM1DC,EAAAA,WAAW,EAAE;AAN6C;IAS/CC,SAAS,GAAG;AACvBR,EAAAA,QAAQ,EAAES,mBAAS,CAACC,OAAV,CAAkBD,mBAAS,CAACE,MAA5B,EACPC,WADO,CACK,iFADL,EAEPC,YAFO,CAEMd,YAAY,CAACC,QAFnB,CADa;AAIvBC,EAAAA,SAAS,EAAEQ,mBAAS,CAACK,IAAV,CACRF,WADQ,sJAURC,YAVQ,CAUKd,YAAY,CAACC,QAVlB,CAJY;AAevBG,EAAAA,YAAY,EAAEM,mBAAS,CAACK,IAAV,CAAeF,WAAf,iCAfS;AAgBvBG,EAAAA,SAAS,EAAEN,mBAAS,CAACO,KAAV,CAAgB,CAAC,KAAD,EAAQ,QAAR,EAAkBV,SAAlB,CAAhB,EAA8CM,WAA9C,CACT,4DADS,CAhBY;AAmBvBK,EAAAA,YAAY,EAAER,mBAAS,CAACO,KAAV,CAAgB,CAAC,KAAD,EAAQ,QAAR,EAAkBV,SAAlB,CAAhB,EAA8CM,WAA9C,CACZ,iEADY,CAnBS;AAsBvBR,EAAAA,eAAe,EAAEK,mBAAS,CAACK,IAAV,CACdF,WADc,CACF,0CADE,EAEdC,YAFc,CAEDd,YAAY,CAACK,eAFZ,CAtBM;AAyBvBC,EAAAA,eAAe,EAAEI,mBAAS,CAACC,OAAV,CAAkBD,mBAAS,CAACS,SAAV,CAAoB,CAACT,mBAAS,CAACU,MAAX,EAAmBV,mBAAS,CAACW,MAA7B,CAApB,CAAlB,EACdR,WADc,CACF,kCADE,EAEdC,YAFc,CAEDd,YAAY,CAACM,eAFZ,CAzBM;AA4BvBE,EAAAA,WAAW,EAAEE,mBAAS,CAACU,MAAV,CACVP,WADU,CACE,kDADF,EAEVC,YAFU,CAEGd,YAAY,CAACQ,WAFhB;AA5BU;;;;;"}
1
+ {"version":3,"file":"props.js","sources":["../../../../src/parts/chat-container-messages-list/props.ts"],"sourcesContent":["import { Ref } from 'react';\nimport { PropTypes } from 'react-desc';\nimport { noop } from 'lodash';\nimport { BubbleProps } from '../bubble/props';\n\ninterface ActionRef {\n scrollToIndex: (n: number, b: { align: 'end' | 'center' | 'start' }) => void;\n getMessagesInView: () => number[];\n}\nexport interface ChatContainerMessagesListProps {\n messages: BubbleProps[];\n actionRef: any;\n onScrollEnds: (indexList: number[]) => number[];\n isLoading?: 'top' | 'bottom';\n hasMoreItems?: 'top' | 'bottom';\n getMoreMessages: PropTypes.func;\n sendingMessages?: Array<string | number>;\n sendingText: string;\n}\n\nexport const defaultProps: ChatContainerMessagesListProps = {\n messages: [],\n actionRef: noop,\n onScrollEnds: () => [],\n getMoreMessages: noop,\n sendingMessages: undefined,\n sendingText: 'Sending',\n};\n\nexport const listProps = {\n messages: PropTypes.arrayOf(PropTypes.object)\n .description('The array of out-of-the-box items you want to render inside the ChatMessageList')\n .defaultValue(defaultProps.messages),\n actionRef: PropTypes.object\n .description(\n `Reference: \n { \n scrollToIndex: (n: number) => void,\n getMessagesInView: () => number[],\n focusToIndex: (n: number) => void,\n focusToList: () => void,\n focusToComposer: () => void,\n focusToSend: () => void,\n }\n \n `,\n )\n .defaultValue(defaultProps.actionRef),\n onScrollEnds: PropTypes.func.description(`Called when the scroll stops.`),\n isLoading: PropTypes.oneOf(['top', 'bottom', undefined]).description(\n 'Keeps the load more space while the loading is in progress',\n ),\n hasMoreItems: PropTypes.oneOf(['top', 'bottom', undefined]).description(\n 'Show Load More button at the `top` or `bottom` of the container',\n ),\n getMoreMessages: PropTypes.func\n .description('Called when the user clicks on load more')\n .defaultValue(defaultProps.getMoreMessages),\n sendingMessages: PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.string, PropTypes.number]))\n .description('Array of ids of sending messages')\n .defaultValue(defaultProps.sendingMessages),\n sendingText: PropTypes.string\n .description('Label description for messages in sending status')\n .defaultValue(defaultProps.sendingText),\n};\n"],"names":["defaultProps","messages","actionRef","noop","onScrollEnds","getMoreMessages","sendingMessages","undefined","sendingText","listProps","PropTypes","arrayOf","object","description","defaultValue","func","isLoading","oneOf","hasMoreItems","oneOfType","string","number"],"mappings":";;;;;;;IAoBaA,YAA4C,GAAG;AAC1DC,EAAAA,QAAQ,EAAE,EADgD;AAE1DC,EAAAA,SAAS,EAAEC,WAF+C;AAG1DC,EAAAA,YAAY,EAAE;AAAA,WAAM,EAAN;AAAA,GAH4C;AAI1DC,EAAAA,eAAe,EAAEF,WAJyC;AAK1DG,EAAAA,eAAe,EAAEC,SALyC;AAM1DC,EAAAA,WAAW,EAAE;AAN6C;IAS/CC,SAAS,GAAG;AACvBR,EAAAA,QAAQ,EAAES,mBAAS,CAACC,OAAV,CAAkBD,mBAAS,CAACE,MAA5B,EACPC,WADO,CACK,iFADL,EAEPC,YAFO,CAEMd,YAAY,CAACC,QAFnB,CADa;AAIvBC,EAAAA,SAAS,EAAEQ,mBAAS,CAACE,MAAV,CACRC,WADQ,oTAcRC,YAdQ,CAcKd,YAAY,CAACE,SAdlB,CAJY;AAmBvBE,EAAAA,YAAY,EAAEM,mBAAS,CAACK,IAAV,CAAeF,WAAf,iCAnBS;AAoBvBG,EAAAA,SAAS,EAAEN,mBAAS,CAACO,KAAV,CAAgB,CAAC,KAAD,EAAQ,QAAR,EAAkBV,SAAlB,CAAhB,EAA8CM,WAA9C,CACT,4DADS,CApBY;AAuBvBK,EAAAA,YAAY,EAAER,mBAAS,CAACO,KAAV,CAAgB,CAAC,KAAD,EAAQ,QAAR,EAAkBV,SAAlB,CAAhB,EAA8CM,WAA9C,CACZ,iEADY,CAvBS;AA0BvBR,EAAAA,eAAe,EAAEK,mBAAS,CAACK,IAAV,CACdF,WADc,CACF,0CADE,EAEdC,YAFc,CAEDd,YAAY,CAACK,eAFZ,CA1BM;AA6BvBC,EAAAA,eAAe,EAAEI,mBAAS,CAACC,OAAV,CAAkBD,mBAAS,CAACS,SAAV,CAAoB,CAACT,mBAAS,CAACU,MAAX,EAAmBV,mBAAS,CAACW,MAA7B,CAApB,CAAlB,EACdR,WADc,CACF,kCADE,EAEdC,YAFc,CAEDd,YAAY,CAACM,eAFZ,CA7BM;AAgCvBE,EAAAA,WAAW,EAAEE,mBAAS,CAACU,MAAV,CACVP,WADU,CACE,kDADF,EAEVC,YAFU,CAEGd,YAAY,CAACQ,WAFhB;AAhCU;;;;;"}
@@ -6,12 +6,14 @@ var styled = require('styled-components');
6
6
  require('../bubble/ChatBubble.js');
7
7
  var parts_bubble_props = require('../bubble/props.js');
8
8
  require('react');
9
+ require('react-desc');
9
10
  require('@elliemae/ds-icons/WarningCircleFill');
10
11
  require('../bubble/styled.js');
11
12
  require('@elliemae/ds-grid');
13
+ require('../bubble/config/useValidateProps.js');
14
+ require('@elliemae/ds-props-helpers');
12
15
  require('../bubble/ChatBubbleArrow.js');
13
16
  require('prop-types');
14
- require('react-desc');
15
17
  require('lodash');
16
18
 
17
19
  function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'default' in e ? e : { 'default': e }; }
@@ -56,7 +58,13 @@ var StyledLoadMoreContainer = /*#__PURE__*/styled__default['default'].div.withCo
56
58
  }, function (props) {
57
59
  return props.hasMoreItems === 'bottom' ? 'bottom: 0;' : '';
58
60
  });
61
+ var ListItem = /*#__PURE__*/styled__default['default'].div.withConfig({
62
+ componentId: "sc-1jhprzr-5"
63
+ })(["&:focus,&:focus-visible{outline:none;&:after{content:'';display:block;position:absolute;pointer-events:none;background:rgba(255,255,255,0.5);width:calc(100% + ", ");height:100%;}}"], function (props) {
64
+ return props.theme.space.xxs;
65
+ });
59
66
 
67
+ exports.ListItem = ListItem;
60
68
  exports.StyledChatContainerContentList = StyledChatContainerContentList;
61
69
  exports.StyledChatContainerContentListScroll = StyledChatContainerContentListScroll;
62
70
  exports.StyledLoadMoreContainer = StyledLoadMoreContainer;
@@ -1 +1 @@
1
- {"version":3,"file":"styled.js","sources":["../../../../src/parts/chat-container-messages-list/styled.ts"],"sourcesContent":["import styled from 'styled-components';\nimport { BUBBLE_TYPES } from '../bubble/index';\nimport { BubbleProps } from '../bubble/props';\n\nexport const StyledWrapper = styled.div`\n width: 100%;\n height: 100%;\n`;\n\n// list\nexport const StyledWrapperListItem = styled.div<Partial<BubbleProps>>`\n min-width: 100%;\n ${(props) =>\n props.type === BUBBLE_TYPES.SENDER &&\n `padding: ${props.theme.space.xxs} ${props.theme.space.xxs} 0px 13%\n `};\n ${(props) =>\n props.type === BUBBLE_TYPES.RECIPIENT &&\n `padding: ${props.theme.space.xxs} 13% ${props.theme.space.xxs}\n ${props.theme.space.xxs}\n `};\n ${(props) =>\n props.type === BUBBLE_TYPES.SYSTEM &&\n `padding: ${props.theme.space.xxs} 0px\n `};\n`;\n\nexport const StyledChatContainerContentList = styled.div`\n width: 100%;\n height: 100%;\n padding: ${(props) => props.theme.space.xs};\n padding-bottom: 0;\n overflow-y: auto;\n overflow-x: hidden;\n`;\nexport const StyledChatContainerContentListScroll = styled.div<{ height: string }>`\n width: 100%;\n height: ${(props) => props.height};\n position: relative;\n`;\n\nexport const StyledLoadMoreContainer = styled.div<{ hasMoreItems?: 'top' | 'bottom' }>`\n position: absolute;\n width: calc(100% + ${(props) => props.theme.space.xxs});\n padding: ${(props) => props.theme.space.xxs};\n left: -${(props) => props.theme.space.xxs};\n right: -${(props) => props.theme.space.xxs};\n display: grid;\n justify-content: center;\n align-items: center;\n ${(props) => (props.hasMoreItems === 'top' ? 'top: 0;' : '')}\n ${(props) => (props.hasMoreItems === 'bottom' ? 'bottom: 0;' : '')}\n`;\n"],"names":["StyledWrapper","styled","div","StyledWrapperListItem","props","type","BUBBLE_TYPES","SENDER","theme","space","xxs","RECIPIENT","SYSTEM","StyledChatContainerContentList","xs","StyledChatContainerContentListScroll","height","StyledLoadMoreContainer","hasMoreItems"],"mappings":";;;;;;;;;;;;;;;;;;;;IAIaA,aAAa,gBAAGC,0BAAM,CAACC,GAAV;AAAA;AAAA;;IAMbC,qBAAqB,gBAAGF,0BAAM,CAACC,GAAV;AAAA;AAAA,uCAE9B,UAACE,KAAD;AAAA,SACAA,KAAK,CAACC,IAAN,KAAeC,+BAAY,CAACC,MAA5B,uBACYH,KAAK,CAACI,KAAN,CAAYC,KAAZ,CAAkBC,GAD9B,cACqCN,KAAK,CAACI,KAAN,CAAYC,KAAZ,CAAkBC,GADvD,iBADA;AAAA,CAF8B,EAM9B,UAACN,KAAD;AAAA,SACAA,KAAK,CAACC,IAAN,KAAeC,+BAAY,CAACK,SAA5B,uBACYP,KAAK,CAACI,KAAN,CAAYC,KAAZ,CAAkBC,GAD9B,kBACyCN,KAAK,CAACI,KAAN,CAAYC,KAAZ,CAAkBC,GAD3D,mBAEEN,KAAK,CAACI,KAAN,CAAYC,KAAZ,CAAkBC,GAFpB,SADA;AAAA,CAN8B,EAW9B,UAACN,KAAD;AAAA,SACAA,KAAK,CAACC,IAAN,KAAeC,+BAAY,CAACM,MAA5B,uBACYR,KAAK,CAACI,KAAN,CAAYC,KAAZ,CAAkBC,GAD9B,aADA;AAAA,CAX8B;IAiBrBG,8BAA8B,gBAAGZ,0BAAM,CAACC,GAAV;AAAA;AAAA,gGAG9B,UAACE,KAAD;AAAA,SAAWA,KAAK,CAACI,KAAN,CAAYC,KAAZ,CAAkBK,EAA7B;AAAA,CAH8B;IAQ9BC,oCAAoC,gBAAGd,0BAAM,CAACC,GAAV;AAAA;AAAA,kDAErC,UAACE,KAAD;AAAA,SAAWA,KAAK,CAACY,MAAjB;AAAA,CAFqC;IAMpCC,uBAAuB,gBAAGhB,0BAAM,CAACC,GAAV;AAAA;AAAA,uJAEb,UAACE,KAAD;AAAA,SAAWA,KAAK,CAACI,KAAN,CAAYC,KAAZ,CAAkBC,GAA7B;AAAA,CAFa,EAGvB,UAACN,KAAD;AAAA,SAAWA,KAAK,CAACI,KAAN,CAAYC,KAAZ,CAAkBC,GAA7B;AAAA,CAHuB,EAIzB,UAACN,KAAD;AAAA,SAAWA,KAAK,CAACI,KAAN,CAAYC,KAAZ,CAAkBC,GAA7B;AAAA,CAJyB,EAKxB,UAACN,KAAD;AAAA,SAAWA,KAAK,CAACI,KAAN,CAAYC,KAAZ,CAAkBC,GAA7B;AAAA,CALwB,EAShC,UAACN,KAAD;AAAA,SAAYA,KAAK,CAACc,YAAN,KAAuB,KAAvB,GAA+B,SAA/B,GAA2C,EAAvD;AAAA,CATgC,EAUhC,UAACd,KAAD;AAAA,SAAYA,KAAK,CAACc,YAAN,KAAuB,QAAvB,GAAkC,YAAlC,GAAiD,EAA7D;AAAA,CAVgC;;;;;;;;"}
1
+ {"version":3,"file":"styled.js","sources":["../../../../src/parts/chat-container-messages-list/styled.ts"],"sourcesContent":["import styled from 'styled-components';\nimport { BUBBLE_TYPES } from '../bubble/index';\nimport { BubbleProps } from '../bubble/props';\n\nexport const StyledWrapper = styled.div`\n width: 100%;\n height: 100%;\n`;\n\n// list\nexport const StyledWrapperListItem = styled.div<Partial<BubbleProps>>`\n min-width: 100%;\n ${(props) =>\n props.type === BUBBLE_TYPES.SENDER &&\n `padding: ${props.theme.space.xxs} ${props.theme.space.xxs} 0px 13%\n `};\n ${(props) =>\n props.type === BUBBLE_TYPES.RECIPIENT &&\n `padding: ${props.theme.space.xxs} 13% ${props.theme.space.xxs}\n ${props.theme.space.xxs}\n `};\n ${(props) =>\n props.type === BUBBLE_TYPES.SYSTEM &&\n `padding: ${props.theme.space.xxs} 0px\n `};\n`;\n\nexport const StyledChatContainerContentList = styled.div`\n width: 100%;\n height: 100%;\n padding: ${(props) => props.theme.space.xs};\n padding-bottom: 0;\n overflow-y: auto;\n overflow-x: hidden;\n`;\nexport const StyledChatContainerContentListScroll = styled.div<{ height: string }>`\n width: 100%;\n height: ${(props) => props.height};\n position: relative;\n`;\n\nexport const StyledLoadMoreContainer = styled.div<{ hasMoreItems?: 'top' | 'bottom' }>`\n position: absolute;\n width: calc(100% + ${(props) => props.theme.space.xxs});\n padding: ${(props) => props.theme.space.xxs};\n left: -${(props) => props.theme.space.xxs};\n right: -${(props) => props.theme.space.xxs};\n display: grid;\n justify-content: center;\n align-items: center;\n ${(props) => (props.hasMoreItems === 'top' ? 'top: 0;' : '')}\n ${(props) => (props.hasMoreItems === 'bottom' ? 'bottom: 0;' : '')}\n`;\nexport const ListItem = styled.div`\n &:focus,\n &:focus-visible {\n outline: none;\n &:after {\n content: '';\n display: block;\n position: absolute;\n pointer-events: none;\n background: rgba(255, 255, 255, 0.5);\n width: calc(100% + ${(props) => props.theme.space.xxs});\n height: 100%;\n }\n }\n`;\n"],"names":["StyledWrapper","styled","div","StyledWrapperListItem","props","type","BUBBLE_TYPES","SENDER","theme","space","xxs","RECIPIENT","SYSTEM","StyledChatContainerContentList","xs","StyledChatContainerContentListScroll","height","StyledLoadMoreContainer","hasMoreItems","ListItem"],"mappings":";;;;;;;;;;;;;;;;;;;;;;IAIaA,aAAa,gBAAGC,0BAAM,CAACC,GAAV;AAAA;AAAA;;IAMbC,qBAAqB,gBAAGF,0BAAM,CAACC,GAAV;AAAA;AAAA,uCAE9B,UAACE,KAAD;AAAA,SACAA,KAAK,CAACC,IAAN,KAAeC,+BAAY,CAACC,MAA5B,uBACYH,KAAK,CAACI,KAAN,CAAYC,KAAZ,CAAkBC,GAD9B,cACqCN,KAAK,CAACI,KAAN,CAAYC,KAAZ,CAAkBC,GADvD,iBADA;AAAA,CAF8B,EAM9B,UAACN,KAAD;AAAA,SACAA,KAAK,CAACC,IAAN,KAAeC,+BAAY,CAACK,SAA5B,uBACYP,KAAK,CAACI,KAAN,CAAYC,KAAZ,CAAkBC,GAD9B,kBACyCN,KAAK,CAACI,KAAN,CAAYC,KAAZ,CAAkBC,GAD3D,mBAEEN,KAAK,CAACI,KAAN,CAAYC,KAAZ,CAAkBC,GAFpB,SADA;AAAA,CAN8B,EAW9B,UAACN,KAAD;AAAA,SACAA,KAAK,CAACC,IAAN,KAAeC,+BAAY,CAACM,MAA5B,uBACYR,KAAK,CAACI,KAAN,CAAYC,KAAZ,CAAkBC,GAD9B,aADA;AAAA,CAX8B;IAiBrBG,8BAA8B,gBAAGZ,0BAAM,CAACC,GAAV;AAAA;AAAA,gGAG9B,UAACE,KAAD;AAAA,SAAWA,KAAK,CAACI,KAAN,CAAYC,KAAZ,CAAkBK,EAA7B;AAAA,CAH8B;IAQ9BC,oCAAoC,gBAAGd,0BAAM,CAACC,GAAV;AAAA;AAAA,kDAErC,UAACE,KAAD;AAAA,SAAWA,KAAK,CAACY,MAAjB;AAAA,CAFqC;IAMpCC,uBAAuB,gBAAGhB,0BAAM,CAACC,GAAV;AAAA;AAAA,uJAEb,UAACE,KAAD;AAAA,SAAWA,KAAK,CAACI,KAAN,CAAYC,KAAZ,CAAkBC,GAA7B;AAAA,CAFa,EAGvB,UAACN,KAAD;AAAA,SAAWA,KAAK,CAACI,KAAN,CAAYC,KAAZ,CAAkBC,GAA7B;AAAA,CAHuB,EAIzB,UAACN,KAAD;AAAA,SAAWA,KAAK,CAACI,KAAN,CAAYC,KAAZ,CAAkBC,GAA7B;AAAA,CAJyB,EAKxB,UAACN,KAAD;AAAA,SAAWA,KAAK,CAACI,KAAN,CAAYC,KAAZ,CAAkBC,GAA7B;AAAA,CALwB,EAShC,UAACN,KAAD;AAAA,SAAYA,KAAK,CAACc,YAAN,KAAuB,KAAvB,GAA+B,SAA/B,GAA2C,EAAvD;AAAA,CATgC,EAUhC,UAACd,KAAD;AAAA,SAAYA,KAAK,CAACc,YAAN,KAAuB,QAAvB,GAAkC,YAAlC,GAAiD,EAA7D;AAAA,CAVgC;IAYvBC,QAAQ,gBAAGlB,0BAAM,CAACC,GAAV;AAAA;AAAA,4LAUM,UAACE,KAAD;AAAA,SAAWA,KAAK,CAACI,KAAN,CAAYC,KAAZ,CAAkBC,GAA7B;AAAA,CAVN;;;;;;;;;"}
@@ -3,19 +3,24 @@
3
3
  Object.defineProperty(exports, '__esModule', { value: true });
4
4
 
5
5
  var React = require('react');
6
+ var reactDesc = require('react-desc');
6
7
  var dsGrid = require('@elliemae/ds-grid');
7
8
  var Communications = require('@elliemae/ds-icons/Communications');
9
+ var parts_chatEmptyState_props = require('./props.js');
8
10
  var parts_chatEmptyState_styled = require('./styled.js');
11
+ var parts_chatEmptyState_config_useValidateProps = require('./config/useValidateProps.js');
9
12
  require('styled-components');
13
+ require('@elliemae/ds-props-helpers');
10
14
 
11
15
  function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'default' in e ? e : { 'default': e }; }
12
16
 
13
17
  var React__default = /*#__PURE__*/_interopDefaultLegacy(React);
14
18
  var Communications__default = /*#__PURE__*/_interopDefaultLegacy(Communications);
15
19
 
16
- var ChatEmptyState = function ChatEmptyState(_ref) {
17
- var label = _ref.label,
18
- action = _ref.action;
20
+ var ChatEmptyState = function ChatEmptyState(props) {
21
+ parts_chatEmptyState_config_useValidateProps.useValidateProps(props, ChatEmptyStateListWithSchema.toJSON());
22
+ var label = props.label,
23
+ action = props.action;
19
24
  var MainContent = React.useMemo(function () {
20
25
  return /*#__PURE__*/React__default['default'].createElement(dsGrid.Grid, {
21
26
  alignItems: "center",
@@ -40,5 +45,11 @@ var ChatEmptyState = function ChatEmptyState(_ref) {
40
45
  }, MainContent);
41
46
  };
42
47
 
48
+ ChatEmptyState.propTypes = parts_chatEmptyState_props.emptyStateProps;
49
+ ChatEmptyState.defaultProps = parts_chatEmptyState_props.defaultProps;
50
+ var ChatEmptyStateListWithSchema = reactDesc.describe(ChatEmptyState);
51
+ ChatEmptyStateListWithSchema.propTypes = parts_chatEmptyState_props.emptyStateProps;
52
+
43
53
  exports.ChatEmptyState = ChatEmptyState;
54
+ exports.ChatEmptyStateListWithSchema = ChatEmptyStateListWithSchema;
44
55
  //# sourceMappingURL=ChatEmptyState.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"ChatEmptyState.js","sources":["../../../../src/parts/chat-empty-state/ChatEmptyState.tsx"],"sourcesContent":["import React, { useMemo } from 'react';\nimport { Grid } from '@elliemae/ds-grid';\nimport Communications from '@elliemae/ds-icons/Communications';\nimport { ChatEmptyStateProps } from './props';\nimport { ChatEmptyStateWrapper, MessageWrapper } from './styled';\n\nexport const ChatEmptyState = ({ label, action }: ChatEmptyStateProps): JSX.Element => {\n const MainContent = useMemo(\n () => (\n <Grid alignItems=\"center\" justifyContent=\"center\">\n <Grid alignItems=\"center\" justifyContent=\"center\">\n <Communications size=\"xxl\" color={['neutral', 400]} />\n </Grid>\n <Grid alignItems=\"center\" justifyContent=\"center\">\n <MessageWrapper>{label}</MessageWrapper>\n </Grid>\n <Grid alignItems=\"center\" justifyContent=\"center\">\n {action}\n </Grid>\n </Grid>\n ),\n [label, action],\n );\n return (\n <ChatEmptyStateWrapper alignItems=\"center\" justifyContent=\"center\">\n {MainContent}\n </ChatEmptyStateWrapper>\n );\n};\n"],"names":["ChatEmptyState","label","action","MainContent","useMemo","React","Grid","Communications","MessageWrapper","ChatEmptyStateWrapper"],"mappings":";;;;;;;;;;;;;;;IAMaA,cAAc,GAAG,SAAjBA,cAAiB,OAAyD;AAAA,MAAtDC,KAAsD,QAAtDA,KAAsD;AAAA,MAA/CC,MAA+C,QAA/CA,MAA+C;AACrF,MAAMC,WAAW,GAAGC,aAAO,CACzB;AAAA,wBACEC,wCAACC,WAAD;AAAM,MAAA,UAAU,EAAC,QAAjB;AAA0B,MAAA,cAAc,EAAC;AAAzC,oBACED,wCAACC,WAAD;AAAM,MAAA,UAAU,EAAC,QAAjB;AAA0B,MAAA,cAAc,EAAC;AAAzC,oBACED,wCAACE,kCAAD;AAAgB,MAAA,IAAI,EAAC,KAArB;AAA2B,MAAA,KAAK,EAAE,CAAC,SAAD,EAAY,GAAZ;AAAlC,MADF,CADF,eAIEF,wCAACC,WAAD;AAAM,MAAA,UAAU,EAAC,QAAjB;AAA0B,MAAA,cAAc,EAAC;AAAzC,oBACED,wCAACG,0CAAD,QAAiBP,KAAjB,CADF,CAJF,eAOEI,wCAACC,WAAD;AAAM,MAAA,UAAU,EAAC,QAAjB;AAA0B,MAAA,cAAc,EAAC;AAAzC,OACGJ,MADH,CAPF,CADF;AAAA,GADyB,EAczB,CAACD,KAAD,EAAQC,MAAR,CAdyB,CAA3B;AAgBA,sBACEG,wCAACI,iDAAD;AAAuB,IAAA,UAAU,EAAC,QAAlC;AAA2C,IAAA,cAAc,EAAC;AAA1D,KACGN,WADH,CADF;AAKD;;;;"}
1
+ {"version":3,"file":"ChatEmptyState.js","sources":["../../../../src/parts/chat-empty-state/ChatEmptyState.tsx"],"sourcesContent":["import React, { useMemo } from 'react';\nimport { describe } from 'react-desc';\nimport { Grid } from '@elliemae/ds-grid';\nimport Communications from '@elliemae/ds-icons/Communications';\nimport { ChatEmptyStateProps, emptyStateProps, defaultProps } from './props';\nimport { ChatEmptyStateWrapper, MessageWrapper } from './styled';\nimport { useValidateProps } from './config/useValidateProps';\n\nconst ChatEmptyState = (props: ChatEmptyStateProps): JSX.Element => {\n useValidateProps(props, ChatEmptyStateListWithSchema.toJSON());\n const { label, action } = props;\n const MainContent = useMemo(\n () => (\n <Grid alignItems=\"center\" justifyContent=\"center\">\n <Grid alignItems=\"center\" justifyContent=\"center\">\n <Communications size=\"xxl\" color={['neutral', 400]} />\n </Grid>\n <Grid alignItems=\"center\" justifyContent=\"center\">\n <MessageWrapper>{label}</MessageWrapper>\n </Grid>\n <Grid alignItems=\"center\" justifyContent=\"center\">\n {action}\n </Grid>\n </Grid>\n ),\n [label, action],\n );\n return (\n <ChatEmptyStateWrapper alignItems=\"center\" justifyContent=\"center\">\n {MainContent}\n </ChatEmptyStateWrapper>\n );\n};\n\nChatEmptyState.propTypes = emptyStateProps;\nChatEmptyState.defaultProps = defaultProps;\nconst ChatEmptyStateListWithSchema = describe(ChatEmptyState);\nChatEmptyStateListWithSchema.propTypes = emptyStateProps;\n\nexport { ChatEmptyState, ChatEmptyStateListWithSchema };\n"],"names":["ChatEmptyState","props","useValidateProps","ChatEmptyStateListWithSchema","toJSON","label","action","MainContent","useMemo","React","Grid","Communications","MessageWrapper","ChatEmptyStateWrapper","propTypes","emptyStateProps","defaultProps","describe"],"mappings":";;;;;;;;;;;;;;;;;;;IAQMA,cAAc,GAAG,SAAjBA,cAAiB,CAACC,KAAD,EAA6C;AAClEC,EAAAA,6DAAgB,CAACD,KAAD,EAAQE,4BAA4B,CAACC,MAA7B,EAAR,CAAhB;AACA,MAAQC,KAAR,GAA0BJ,KAA1B,CAAQI,KAAR;AAAA,MAAeC,MAAf,GAA0BL,KAA1B,CAAeK,MAAf;AACA,MAAMC,WAAW,GAAGC,aAAO,CACzB;AAAA,wBACEC,wCAACC,WAAD;AAAM,MAAA,UAAU,EAAC,QAAjB;AAA0B,MAAA,cAAc,EAAC;AAAzC,oBACED,wCAACC,WAAD;AAAM,MAAA,UAAU,EAAC,QAAjB;AAA0B,MAAA,cAAc,EAAC;AAAzC,oBACED,wCAACE,kCAAD;AAAgB,MAAA,IAAI,EAAC,KAArB;AAA2B,MAAA,KAAK,EAAE,CAAC,SAAD,EAAY,GAAZ;AAAlC,MADF,CADF,eAIEF,wCAACC,WAAD;AAAM,MAAA,UAAU,EAAC,QAAjB;AAA0B,MAAA,cAAc,EAAC;AAAzC,oBACED,wCAACG,0CAAD,QAAiBP,KAAjB,CADF,CAJF,eAOEI,wCAACC,WAAD;AAAM,MAAA,UAAU,EAAC,QAAjB;AAA0B,MAAA,cAAc,EAAC;AAAzC,OACGJ,MADH,CAPF,CADF;AAAA,GADyB,EAczB,CAACD,KAAD,EAAQC,MAAR,CAdyB,CAA3B;AAgBA,sBACEG,wCAACI,iDAAD;AAAuB,IAAA,UAAU,EAAC,QAAlC;AAA2C,IAAA,cAAc,EAAC;AAA1D,KACGN,WADH,CADF;AAKD;;AAEDP,cAAc,CAACc,SAAf,GAA2BC,0CAA3B;AACAf,cAAc,CAACgB,YAAf,GAA8BA,uCAA9B;IACMb,4BAA4B,GAAGc,kBAAQ,CAACjB,cAAD;AAC7CG,4BAA4B,CAACW,SAA7B,GAAyCC,0CAAzC;;;;;"}
@@ -0,0 +1,12 @@
1
+ 'use strict';
2
+
3
+ Object.defineProperty(exports, '__esModule', { value: true });
4
+
5
+ var dsPropsHelpers = require('@elliemae/ds-props-helpers');
6
+
7
+ var useValidateProps = function useValidateProps(props, schema) {
8
+ dsPropsHelpers.useValidatePropTypes(props, schema);
9
+ };
10
+
11
+ exports.useValidateProps = useValidateProps;
12
+ //# sourceMappingURL=useValidateProps.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"useValidateProps.js","sources":["../../../../../src/parts/chat-empty-state/config/useValidateProps.tsx"],"sourcesContent":["import { useValidatePropTypes } from '@elliemae/ds-props-helpers';\nimport { ChatEmptyStateProps } from '../props';\n\nexport const useValidateProps = (props: ChatEmptyStateProps, schema: unknown): void => {\n useValidatePropTypes(props, schema);\n};\n"],"names":["useValidateProps","props","schema","useValidatePropTypes"],"mappings":";;;;;;IAGaA,gBAAgB,GAAG,SAAnBA,gBAAmB,CAACC,KAAD,EAA6BC,MAA7B,EAAuD;AACrFC,EAAAA,mCAAoB,CAACF,KAAD,EAAQC,MAAR,CAApB;AACD;;;;"}
@@ -9,7 +9,8 @@ var defaultProps = {
9
9
  action: null
10
10
  };
11
11
  var emptyStateProps = {
12
- label: reactDesc.PropTypes.arrayOf(reactDesc.PropTypes.string).description('No Message to show text helper').defaultValue(defaultProps.label)
12
+ label: reactDesc.PropTypes.arrayOf(reactDesc.PropTypes.string).description('No Message to show text helper').defaultValue(defaultProps.label),
13
+ action: reactDesc.PropTypes.node.description('action element').defaultValue(defaultProps.action)
13
14
  };
14
15
 
15
16
  exports.defaultProps = defaultProps;
@@ -1 +1 @@
1
- {"version":3,"file":"props.js","sources":["../../../../src/parts/chat-empty-state/props.tsx"],"sourcesContent":["import { PropTypes } from 'react-desc';\n\nexport interface ChatEmptyStateProps {\n label: string;\n action: React.FC;\n}\n\nexport const defaultProps: ChatEmptyStateProps = {\n label: 'No Messages Yet',\n action: null,\n};\n\nexport const emptyStateProps = {\n label: PropTypes.arrayOf(PropTypes.string)\n .description('No Message to show text helper')\n .defaultValue(defaultProps.label),\n};\n"],"names":["defaultProps","label","action","emptyStateProps","PropTypes","arrayOf","string","description","defaultValue"],"mappings":";;;;;;IAOaA,YAAiC,GAAG;AAC/CC,EAAAA,KAAK,EAAE,iBADwC;AAE/CC,EAAAA,MAAM,EAAE;AAFuC;IAKpCC,eAAe,GAAG;AAC7BF,EAAAA,KAAK,EAAEG,mBAAS,CAACC,OAAV,CAAkBD,mBAAS,CAACE,MAA5B,EACJC,WADI,CACQ,gCADR,EAEJC,YAFI,CAESR,YAAY,CAACC,KAFtB;AADsB;;;;;"}
1
+ {"version":3,"file":"props.js","sources":["../../../../src/parts/chat-empty-state/props.tsx"],"sourcesContent":["import { PropTypes } from 'react-desc';\n\nexport interface ChatEmptyStateProps {\n label: string;\n action: React.FC;\n}\n\nexport const defaultProps: ChatEmptyStateProps = {\n label: 'No Messages Yet',\n action: null,\n};\n\nexport const emptyStateProps = {\n label: PropTypes.arrayOf(PropTypes.string)\n .description('No Message to show text helper')\n .defaultValue(defaultProps.label),\n action: PropTypes.node.description('action element').defaultValue(defaultProps.action),\n};\n"],"names":["defaultProps","label","action","emptyStateProps","PropTypes","arrayOf","string","description","defaultValue","node"],"mappings":";;;;;;IAOaA,YAAiC,GAAG;AAC/CC,EAAAA,KAAK,EAAE,iBADwC;AAE/CC,EAAAA,MAAM,EAAE;AAFuC;IAKpCC,eAAe,GAAG;AAC7BF,EAAAA,KAAK,EAAEG,mBAAS,CAACC,OAAV,CAAkBD,mBAAS,CAACE,MAA5B,EACJC,WADI,CACQ,gCADR,EAEJC,YAFI,CAESR,YAAY,CAACC,KAFtB,CADsB;AAI7BC,EAAAA,MAAM,EAAEE,mBAAS,CAACK,IAAV,CAAeF,WAAf,CAA2B,gBAA3B,EAA6CC,YAA7C,CAA0DR,YAAY,CAACE,MAAvE;AAJqB;;;;;"}
@@ -11,6 +11,7 @@ var parts_chatSidebar_styled = require('./styled.js');
11
11
  var parts_tileButton_TileButton = require('../tile-button/TileButton.js');
12
12
  var parts_sidebarButton_SidebarButton = require('../sidebar-button/SidebarButton.js');
13
13
  var parts_chatSidebar_props = require('./props.js');
14
+ var parts_chatSidebar_config_useValidateProps = require('./config/useValidateProps.js');
14
15
  require('styled-components');
15
16
  require('@elliemae/ds-grid');
16
17
  require('../../styled.js');
@@ -18,12 +19,14 @@ require('@elliemae/ds-tooltip');
18
19
  require('@elliemae/ds-icons/CloseXsmall');
19
20
  require('../tile-button/styled.js');
20
21
  require('../tile-button/props.js');
21
- require('prop-types');
22
22
  require('lodash');
23
23
  require('@elliemae/ds-icons/Comments');
24
+ require('../tile-button/config/useValidateProps.js');
25
+ require('@elliemae/ds-props-helpers');
24
26
  require('@babel/runtime/helpers/objectWithoutProperties');
25
27
  require('../sidebar-button/styled.js');
26
28
  require('../sidebar-button/props.js');
29
+ require('prop-types');
27
30
 
28
31
  function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'default' in e ? e : { 'default': e }; }
29
32
 
@@ -47,13 +50,14 @@ var FooterChat = function FooterChat(_ref) {
47
50
  });
48
51
  };
49
52
 
50
- var SideBarChat = function SideBarChat(_ref2) {
51
- var sidebarItems = _ref2.sidebarItems,
52
- expanded = _ref2.expanded,
53
- onFooterClose = _ref2.onFooterClose,
54
- onFooterExpand = _ref2.onFooterExpand,
55
- selectedItem = _ref2.selectedItem,
56
- footerButtonExtraProps = _ref2.footerButtonExtraProps;
53
+ var SideBarChat = function SideBarChat(props) {
54
+ parts_chatSidebar_config_useValidateProps.useValidateProps(props, SideBarChatWithSchema.toJSON());
55
+ var sidebarItems = props.sidebarItems,
56
+ expanded = props.expanded,
57
+ onFooterClose = props.onFooterClose,
58
+ onFooterExpand = props.onFooterExpand,
59
+ selectedItem = props.selectedItem,
60
+ footerButtonExtraProps = props.footerButtonExtraProps;
57
61
  return /*#__PURE__*/React__default['default'].createElement(parts_chatSidebar_styled.StyledSideBarContainer, {
58
62
  rows: [1, 'auto']
59
63
  }, /*#__PURE__*/React__default['default'].createElement(parts_chatSidebar_styled.StyledSideBarButtonsContainer, null, sidebarItems.map(function (p) {
@@ -1 +1 @@
1
- {"version":3,"file":"SideBarChat.js","sources":["../../../../src/parts/chat-sidebar/SideBarChat.tsx"],"sourcesContent":["import React from 'react';\nimport { describe } from 'react-desc';\nimport MenuExpand from '@elliemae/ds-icons/MenuExpand';\nimport MenuCollapse from '@elliemae/ds-icons/MenuCollapse';\nimport {\n StyledSideBarContainer,\n StyledSideBarButtonsContainer,\n} from './styled';\nimport { TileButton } from '../tile-button';\nimport { SidebarButton } from '../sidebar-button/SidebarButton';\nimport { CharSidebarProps, defaultProps, chatSidebarProps } from './props';\n\nconst FooterChat = ({\n expanded,\n onFooterClose,\n onFooterExpand,\n footerButtonExtraProps,\n}: Pick<CharSidebarProps, 'expanded' | 'onFooterClose' | 'onFooterExpand' | 'footerButtonExtraProps'>) => (\n <SidebarButton\n dsId=\"sidebar_footer\"\n label={null}\n Icon={!expanded ? MenuCollapse : MenuExpand}\n onClick={expanded ? onFooterClose : onFooterExpand}\n aria-pressed={expanded}\n aria-label={footerButtonExtraProps['aria-label']}\n />\n);\n\nconst SideBarChat = ({\n sidebarItems,\n expanded,\n onFooterClose,\n onFooterExpand,\n selectedItem,\n footerButtonExtraProps,\n}: CharSidebarProps): JSX.Element => (\n <StyledSideBarContainer rows={[1, 'auto']}>\n <StyledSideBarButtonsContainer>\n {sidebarItems.map((p) => (\n <TileButton {...p} selected={selectedItem === p.dsId} />\n ))}\n </StyledSideBarButtonsContainer>\n <FooterChat\n expanded={expanded}\n onFooterClose={onFooterClose}\n onFooterExpand={onFooterExpand}\n footerButtonExtraProps={footerButtonExtraProps}\n />\n </StyledSideBarContainer>\n);\n\nSideBarChat.propTypes = chatSidebarProps;\nSideBarChat.defaultProps = defaultProps;\nconst SideBarChatWithSchema = describe(SideBarChat);\nSideBarChatWithSchema.propTypes = chatSidebarProps;\n\nexport { SideBarChat, SideBarChatWithSchema };\n"],"names":["FooterChat","expanded","onFooterClose","onFooterExpand","footerButtonExtraProps","React","SidebarButton","MenuCollapse","MenuExpand","SideBarChat","sidebarItems","selectedItem","StyledSideBarContainer","StyledSideBarButtonsContainer","map","p","TileButton","dsId","propTypes","chatSidebarProps","defaultProps","SideBarChatWithSchema","describe"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAYA,IAAMA,UAAU,GAAG,SAAbA,UAAa;AAAA,MACjBC,QADiB,QACjBA,QADiB;AAAA,MAEjBC,aAFiB,QAEjBA,aAFiB;AAAA,MAGjBC,cAHiB,QAGjBA,cAHiB;AAAA,MAIjBC,sBAJiB,QAIjBA,sBAJiB;AAAA,sBAMjBC,wCAACC,+CAAD;AACE,IAAA,IAAI,EAAC,gBADP;AAEE,IAAA,KAAK,EAAE,IAFT;AAGE,IAAA,IAAI,EAAE,CAACL,QAAD,GAAYM,gCAAZ,GAA2BC,8BAHnC;AAIE,IAAA,OAAO,EAAEP,QAAQ,GAAGC,aAAH,GAAmBC,cAJtC;AAKE,oBAAcF,QALhB;AAME,kBAAYG,sBAAsB,CAAC,YAAD;AANpC,IANiB;AAAA,CAAnB;;IAgBMK,WAAW,GAAG,SAAdA,WAAc;AAAA,MAClBC,YADkB,SAClBA,YADkB;AAAA,MAElBT,QAFkB,SAElBA,QAFkB;AAAA,MAGlBC,aAHkB,SAGlBA,aAHkB;AAAA,MAIlBC,cAJkB,SAIlBA,cAJkB;AAAA,MAKlBQ,YALkB,SAKlBA,YALkB;AAAA,MAMlBP,sBANkB,SAMlBA,sBANkB;AAAA,sBAQlBC,wCAACO,+CAAD;AAAwB,IAAA,IAAI,EAAE,CAAC,CAAD,EAAI,MAAJ;AAA9B,kBACEP,wCAACQ,sDAAD,QACGH,YAAY,CAACI,GAAb,CAAiB,UAACC,CAAD;AAAA,wBAChBV,wCAACW,sCAAD,mCAAgBD,CAAhB;AAAmB,MAAA,QAAQ,EAAEJ,YAAY,KAAKI,CAAC,CAACE;AAAhD,OADgB;AAAA,GAAjB,CADH,CADF,eAMEZ,wCAAC,UAAD;AACE,IAAA,QAAQ,EAAEJ,QADZ;AAEE,IAAA,aAAa,EAAEC,aAFjB;AAGE,IAAA,cAAc,EAAEC,cAHlB;AAIE,IAAA,sBAAsB,EAAEC;AAJ1B,IANF,CARkB;AAAA;;AAuBpBK,WAAW,CAACS,SAAZ,GAAwBC,wCAAxB;AACAV,WAAW,CAACW,YAAZ,GAA2BA,oCAA3B;IACMC,qBAAqB,GAAGC,kBAAQ,CAACb,WAAD;AACtCY,qBAAqB,CAACH,SAAtB,GAAkCC,wCAAlC;;;;;"}
1
+ {"version":3,"file":"SideBarChat.js","sources":["../../../../src/parts/chat-sidebar/SideBarChat.tsx"],"sourcesContent":["import React from 'react';\nimport { describe } from 'react-desc';\nimport MenuExpand from '@elliemae/ds-icons/MenuExpand';\nimport MenuCollapse from '@elliemae/ds-icons/MenuCollapse';\nimport { StyledSideBarContainer, StyledSideBarButtonsContainer } from './styled';\nimport { TileButton } from '../tile-button';\nimport { SidebarButton } from '../sidebar-button/SidebarButton';\nimport { CharSidebarProps, defaultProps, chatSidebarProps } from './props';\nimport { useValidateProps } from './config/useValidateProps';\n\nconst FooterChat = ({\n expanded,\n onFooterClose,\n onFooterExpand,\n footerButtonExtraProps,\n}: Pick<CharSidebarProps, 'expanded' | 'onFooterClose' | 'onFooterExpand' | 'footerButtonExtraProps'>) => (\n <SidebarButton\n dsId=\"sidebar_footer\"\n label={null}\n Icon={!expanded ? MenuCollapse : MenuExpand}\n onClick={expanded ? onFooterClose : onFooterExpand}\n aria-pressed={expanded}\n aria-label={footerButtonExtraProps['aria-label']}\n />\n);\n\nconst SideBarChat = (props: CharSidebarProps): JSX.Element => {\n useValidateProps(props, SideBarChatWithSchema.toJSON());\n const { sidebarItems, expanded, onFooterClose, onFooterExpand, selectedItem, footerButtonExtraProps } = props;\n return (\n <StyledSideBarContainer rows={[1, 'auto']}>\n <StyledSideBarButtonsContainer>\n {sidebarItems.map((p) => (\n <TileButton {...p} selected={selectedItem === p.dsId} />\n ))}\n </StyledSideBarButtonsContainer>\n <FooterChat\n expanded={expanded}\n onFooterClose={onFooterClose}\n onFooterExpand={onFooterExpand}\n footerButtonExtraProps={footerButtonExtraProps}\n />\n </StyledSideBarContainer>\n );\n};\n\nSideBarChat.propTypes = chatSidebarProps;\nSideBarChat.defaultProps = defaultProps;\nconst SideBarChatWithSchema = describe(SideBarChat);\nSideBarChatWithSchema.propTypes = chatSidebarProps;\n\nexport { SideBarChat, SideBarChatWithSchema };\n"],"names":["FooterChat","expanded","onFooterClose","onFooterExpand","footerButtonExtraProps","React","SidebarButton","MenuCollapse","MenuExpand","SideBarChat","props","useValidateProps","SideBarChatWithSchema","toJSON","sidebarItems","selectedItem","StyledSideBarContainer","StyledSideBarButtonsContainer","map","p","TileButton","dsId","propTypes","chatSidebarProps","defaultProps","describe"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAUA,IAAMA,UAAU,GAAG,SAAbA,UAAa;AAAA,MACjBC,QADiB,QACjBA,QADiB;AAAA,MAEjBC,aAFiB,QAEjBA,aAFiB;AAAA,MAGjBC,cAHiB,QAGjBA,cAHiB;AAAA,MAIjBC,sBAJiB,QAIjBA,sBAJiB;AAAA,sBAMjBC,wCAACC,+CAAD;AACE,IAAA,IAAI,EAAC,gBADP;AAEE,IAAA,KAAK,EAAE,IAFT;AAGE,IAAA,IAAI,EAAE,CAACL,QAAD,GAAYM,gCAAZ,GAA2BC,8BAHnC;AAIE,IAAA,OAAO,EAAEP,QAAQ,GAAGC,aAAH,GAAmBC,cAJtC;AAKE,oBAAcF,QALhB;AAME,kBAAYG,sBAAsB,CAAC,YAAD;AANpC,IANiB;AAAA,CAAnB;;IAgBMK,WAAW,GAAG,SAAdA,WAAc,CAACC,KAAD,EAA0C;AAC5DC,EAAAA,0DAAgB,CAACD,KAAD,EAAQE,qBAAqB,CAACC,MAAtB,EAAR,CAAhB;AACA,MAAQC,YAAR,GAAwGJ,KAAxG,CAAQI,YAAR;AAAA,MAAsBb,QAAtB,GAAwGS,KAAxG,CAAsBT,QAAtB;AAAA,MAAgCC,aAAhC,GAAwGQ,KAAxG,CAAgCR,aAAhC;AAAA,MAA+CC,cAA/C,GAAwGO,KAAxG,CAA+CP,cAA/C;AAAA,MAA+DY,YAA/D,GAAwGL,KAAxG,CAA+DK,YAA/D;AAAA,MAA6EX,sBAA7E,GAAwGM,KAAxG,CAA6EN,sBAA7E;AACA,sBACEC,wCAACW,+CAAD;AAAwB,IAAA,IAAI,EAAE,CAAC,CAAD,EAAI,MAAJ;AAA9B,kBACEX,wCAACY,sDAAD,QACGH,YAAY,CAACI,GAAb,CAAiB,UAACC,CAAD;AAAA,wBAChBd,wCAACe,sCAAD,mCAAgBD,CAAhB;AAAmB,MAAA,QAAQ,EAAEJ,YAAY,KAAKI,CAAC,CAACE;AAAhD,OADgB;AAAA,GAAjB,CADH,CADF,eAMEhB,wCAAC,UAAD;AACE,IAAA,QAAQ,EAAEJ,QADZ;AAEE,IAAA,aAAa,EAAEC,aAFjB;AAGE,IAAA,cAAc,EAAEC,cAHlB;AAIE,IAAA,sBAAsB,EAAEC;AAJ1B,IANF,CADF;AAeD;;AAEDK,WAAW,CAACa,SAAZ,GAAwBC,wCAAxB;AACAd,WAAW,CAACe,YAAZ,GAA2BA,oCAA3B;IACMZ,qBAAqB,GAAGa,kBAAQ,CAAChB,WAAD;AACtCG,qBAAqB,CAACU,SAAtB,GAAkCC,wCAAlC;;;;;"}
@@ -0,0 +1,12 @@
1
+ 'use strict';
2
+
3
+ Object.defineProperty(exports, '__esModule', { value: true });
4
+
5
+ var dsPropsHelpers = require('@elliemae/ds-props-helpers');
6
+
7
+ var useValidateProps = function useValidateProps(props, schema) {
8
+ dsPropsHelpers.useValidatePropTypes(props, schema);
9
+ };
10
+
11
+ exports.useValidateProps = useValidateProps;
12
+ //# sourceMappingURL=useValidateProps.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"useValidateProps.js","sources":["../../../../../src/parts/chat-sidebar/config/useValidateProps.tsx"],"sourcesContent":["import { useValidatePropTypes } from '@elliemae/ds-props-helpers';\nimport { CharSidebarProps } from '../props';\n\nexport const useValidateProps = (props: CharSidebarProps, schema: unknown): void => {\n useValidatePropTypes(props, schema);\n};\n"],"names":["useValidateProps","props","schema","useValidatePropTypes"],"mappings":";;;;;;IAGaA,gBAAgB,GAAG,SAAnBA,gBAAmB,CAACC,KAAD,EAA0BC,MAA1B,EAAoD;AAClFC,EAAAA,mCAAoB,CAACF,KAAD,EAAQC,MAAR,CAApB;AACD;;;;"}
@@ -17,14 +17,17 @@ require('@elliemae/ds-tooltip');
17
17
  require('@elliemae/ds-icons/CloseXsmall');
18
18
  require('../tile-button/styled.js');
19
19
  require('../tile-button/props.js');
20
- require('prop-types');
21
20
  require('lodash');
22
21
  require('@elliemae/ds-icons/Comments');
22
+ require('../tile-button/config/useValidateProps.js');
23
+ require('@elliemae/ds-props-helpers');
23
24
  require('../sidebar-button/SidebarButton.js');
24
25
  require('@babel/runtime/helpers/objectWithoutProperties');
25
26
  require('../sidebar-button/styled.js');
26
27
  require('../sidebar-button/props.js');
28
+ require('prop-types');
27
29
  require('./props.js');
30
+ require('./config/useValidateProps.js');
28
31
 
29
32
 
30
33
 
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
1
+ {"version":3,"file":"index.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
@@ -1 +1 @@
1
- {"version":3,"file":"FloatingButton.js","sources":["../../../../src/parts/floating-button/FloatingButton.tsx"],"sourcesContent":["import React from 'react';\nimport Comments from '@elliemae/ds-icons/Comments';\nimport { StyledFloatingButton } from './styled';\nimport {\n defaultFloatingButton,\n propsFloatingButton,\n FloatingButtonProps,\n} from './props';\n\nexport const FloatingButton = ({\n onClick,\n}: FloatingButtonProps): JSX.Element => (\n <StyledFloatingButton data-testid=\"chat-floating-button\" onClick={onClick}>\n <Comments size=\"l\" />\n </StyledFloatingButton>\n);\n\nFloatingButton.propTypes = propsFloatingButton;\nFloatingButton.defaultProps = defaultFloatingButton;\n"],"names":["FloatingButton","onClick","React","StyledFloatingButton","Comments","propTypes","propsFloatingButton","defaultProps","defaultFloatingButton"],"mappings":";;;;;;;;;;;;;;;;;IASaA,cAAc,GAAG,SAAjBA,cAAiB;AAAA,MAC5BC,OAD4B,QAC5BA,OAD4B;AAAA,sBAG5BC,wCAACC,gDAAD;AAAsB,mBAAY,sBAAlC;AAAyD,IAAA,OAAO,EAAEF;AAAlE,kBACEC,wCAACE,4BAAD;AAAU,IAAA,IAAI,EAAC;AAAf,IADF,CAH4B;AAAA;AAQ9BJ,cAAc,CAACK,SAAf,GAA2BC,8CAA3B;AACAN,cAAc,CAACO,YAAf,GAA8BC,gDAA9B;;;;"}
1
+ {"version":3,"file":"FloatingButton.js","sources":["../../../../src/parts/floating-button/FloatingButton.tsx"],"sourcesContent":["import React from 'react';\nimport Comments from '@elliemae/ds-icons/Comments';\nimport { StyledFloatingButton } from './styled';\nimport { defaultFloatingButton, propsFloatingButton, FloatingButtonProps } from './props';\n\nexport const FloatingButton = ({ onClick }: FloatingButtonProps): JSX.Element => (\n <StyledFloatingButton data-testid=\"chat-floating-button\" onClick={onClick}>\n <Comments size=\"l\" />\n </StyledFloatingButton>\n);\n\nFloatingButton.propTypes = propsFloatingButton;\nFloatingButton.defaultProps = defaultFloatingButton;\n"],"names":["FloatingButton","onClick","React","StyledFloatingButton","Comments","propTypes","propsFloatingButton","defaultProps","defaultFloatingButton"],"mappings":";;;;;;;;;;;;;;;;;IAKaA,cAAc,GAAG,SAAjBA,cAAiB;AAAA,MAAGC,OAAH,QAAGA,OAAH;AAAA,sBAC5BC,wCAACC,gDAAD;AAAsB,mBAAY,sBAAlC;AAAyD,IAAA,OAAO,EAAEF;AAAlE,kBACEC,wCAACE,4BAAD;AAAU,IAAA,IAAI,EAAC;AAAf,IADF,CAD4B;AAAA;AAM9BJ,cAAc,CAACK,SAAf,GAA2BC,8CAA3B;AACAN,cAAc,CAACO,YAAf,GAA8BC,gDAA9B;;;;"}
@@ -20,6 +20,8 @@ require('@babel/runtime/helpers/slicedToArray');
20
20
  require('@elliemae/ds-icons/PaperAirplane');
21
21
  require('../chat-composer/styled.js');
22
22
  require('@elliemae/ds-button');
23
+ require('../chat-composer/config/useValidateProps.js');
24
+ require('@elliemae/ds-props-helpers');
23
25
  require('../chat-composer/props.js');
24
26
  require('../chat-container-messages-list/ChatContainerMessagesList.js');
25
27
  require('react-virtual');
@@ -29,17 +31,22 @@ require('@elliemae/ds-icons/WarningCircleFill');
29
31
  require('../bubble/styled.js');
30
32
  require('../bubble/props.js');
31
33
  require('prop-types');
34
+ require('../bubble/config/useValidateProps.js');
32
35
  require('../bubble/ChatBubbleArrow.js');
33
36
  require('../message-delimiter/MessageDelimiter.js');
34
37
  require('../message-delimiter/styled.js');
35
38
  require('../message-delimiter/props.js');
39
+ require('../message-delimiter/config/useValidateProps.js');
36
40
  require('../system-message/SystemMessage.js');
37
41
  require('../system-message/style.js');
38
42
  require('../system-message/props.js');
43
+ require('../system-message/config/useValidateProps.js');
39
44
  require('../chat-container-messages-list/styled.js');
40
45
  require('../chat-container-messages-list/props.js');
46
+ require('../chat-container-messages-list/config/useValidateProps.js');
41
47
  require('../chat-container/props.js');
42
48
  require('../chat-container/styled.js');
49
+ require('../chat-container/config/useValidateProps.js');
43
50
  require('@elliemae/ds-icons/MenuExpand');
44
51
  require('@elliemae/ds-icons/MenuCollapse');
45
52
  require('../chat-sidebar/styled.js');
@@ -49,11 +56,13 @@ require('@elliemae/ds-icons/CloseXsmall');
49
56
  require('../tile-button/styled.js');
50
57
  require('../tile-button/props.js');
51
58
  require('@elliemae/ds-icons/Comments');
59
+ require('../tile-button/config/useValidateProps.js');
52
60
  require('../sidebar-button/SidebarButton.js');
53
61
  require('@babel/runtime/helpers/objectWithoutProperties');
54
62
  require('../sidebar-button/styled.js');
55
63
  require('../sidebar-button/props.js');
56
64
  require('../chat-sidebar/props.js');
65
+ require('../chat-sidebar/config/useValidateProps.js');
57
66
 
58
67
  function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'default' in e ? e : { 'default': e }; }
59
68
 
@@ -1 +1 @@
1
- {"version":3,"file":"InfluencerContainer.js","sources":["../../../../src/parts/grid-influencer/InfluencerContainer.tsx"],"sourcesContent":["/* eslint-disable react/prop-types */\nimport React from 'react';\nimport { StyledChatContainer } from './styled';\nimport { ChatContainer } from '../chat-container/ChatContainer';\nimport { SideBarChat } from '../chat-sidebar/SideBarChat';\n\nexport const InfluencerContainer: React.ComponentType<any> = (props) =>\n React.useMemo(\n () =>\n props.floating ? null : (\n <StyledChatContainer\n cols={['auto', props.expanded ? 1 : '0px']}\n expanded={props.expanded}\n expandedWidth={props.expandedWidth}\n >\n <SideBarChat />\n {props.expanded ? <ChatContainer /> : <div />}\n </StyledChatContainer>\n ),\n [props.floating, props.expanded, props.expandedWidth],\n );\n"],"names":["InfluencerContainer","props","React","useMemo","floating","StyledChatContainer","expanded","expandedWidth","SideBarChat","ChatContainer"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;IAMaA,mBAA6C,GAAG,SAAhDA,mBAAgD,CAACC,KAAD;AAAA,SAC3DC,yBAAK,CAACC,OAAN,CACE;AAAA,WACEF,KAAK,CAACG,QAAN,GAAiB,IAAjB,gBACEF,wCAACG,+CAAD;AACE,MAAA,IAAI,EAAE,CAAC,MAAD,EAASJ,KAAK,CAACK,QAAN,GAAiB,CAAjB,GAAqB,KAA9B,CADR;AAEE,MAAA,QAAQ,EAAEL,KAAK,CAACK,QAFlB;AAGE,MAAA,aAAa,EAAEL,KAAK,CAACM;AAHvB,oBAKEL,wCAACM,yCAAD,OALF,EAMGP,KAAK,CAACK,QAAN,gBAAiBJ,wCAACO,+CAAD,OAAjB,gBAAqCP,oDANxC,CAFJ;AAAA,GADF,EAYE,CAACD,KAAK,CAACG,QAAP,EAAiBH,KAAK,CAACK,QAAvB,EAAiCL,KAAK,CAACM,aAAvC,CAZF,CAD2D;AAAA;;;;"}
1
+ {"version":3,"file":"InfluencerContainer.js","sources":["../../../../src/parts/grid-influencer/InfluencerContainer.tsx"],"sourcesContent":["/* eslint-disable react/prop-types */\nimport React from 'react';\nimport { StyledChatContainer } from './styled';\nimport { ChatContainer } from '../chat-container/ChatContainer';\nimport { SideBarChat } from '../chat-sidebar/SideBarChat';\n\nexport const InfluencerContainer: React.ComponentType<any> = (props) =>\n React.useMemo(\n () =>\n props.floating ? null : (\n <StyledChatContainer\n cols={['auto', props.expanded ? 1 : '0px']}\n expanded={props.expanded}\n expandedWidth={props.expandedWidth}\n >\n <SideBarChat />\n {props.expanded ? <ChatContainer /> : <div />}\n </StyledChatContainer>\n ),\n [props.floating, props.expanded, props.expandedWidth],\n );\n"],"names":["InfluencerContainer","props","React","useMemo","floating","StyledChatContainer","expanded","expandedWidth","SideBarChat","ChatContainer"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;IAMaA,mBAA6C,GAAG,SAAhDA,mBAAgD,CAACC,KAAD;AAAA,SAC3DC,yBAAK,CAACC,OAAN,CACE;AAAA,WACEF,KAAK,CAACG,QAAN,GAAiB,IAAjB,gBACEF,wCAACG,+CAAD;AACE,MAAA,IAAI,EAAE,CAAC,MAAD,EAASJ,KAAK,CAACK,QAAN,GAAiB,CAAjB,GAAqB,KAA9B,CADR;AAEE,MAAA,QAAQ,EAAEL,KAAK,CAACK,QAFlB;AAGE,MAAA,aAAa,EAAEL,KAAK,CAACM;AAHvB,oBAKEL,wCAACM,yCAAD,OALF,EAMGP,KAAK,CAACK,QAAN,gBAAiBJ,wCAACO,+CAAD,OAAjB,gBAAqCP,oDANxC,CAFJ;AAAA,GADF,EAYE,CAACD,KAAK,CAACG,QAAP,EAAiBH,KAAK,CAACK,QAAvB,EAAiCL,KAAK,CAACM,aAAvC,CAZF,CAD2D;AAAA;;;;"}
@@ -6,18 +6,21 @@ var React = require('react');
6
6
  var reactDesc = require('react-desc');
7
7
  var parts_messageDelimiter_styled = require('./styled.js');
8
8
  var parts_messageDelimiter_props = require('./props.js');
9
+ var parts_messageDelimiter_config_useValidateProps = require('./config/useValidateProps.js');
9
10
  require('@elliemae/ds-grid');
10
11
  require('styled-components');
12
+ require('@elliemae/ds-props-helpers');
11
13
 
12
14
  function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'default' in e ? e : { 'default': e }; }
13
15
 
14
16
  var React__default = /*#__PURE__*/_interopDefaultLegacy(React);
15
17
 
16
- var MessageDelimiter = function MessageDelimiter(_ref) {
17
- var title = _ref.title,
18
- size = _ref.size,
19
- extraProps = _ref.extraProps,
20
- verticalMargin = _ref.verticalMargin;
18
+ var MessageDelimiter = function MessageDelimiter(props) {
19
+ parts_messageDelimiter_config_useValidateProps.useValidateProps(props, MessageDelimiterWithSchema.toJSON());
20
+ var title = props.title,
21
+ size = props.size,
22
+ extraProps = props.extraProps,
23
+ verticalMargin = props.verticalMargin;
21
24
  return /*#__PURE__*/React__default['default'].createElement(parts_messageDelimiter_styled.Wrapper, {
22
25
  cols: ['1fr', 'auto', '1fr']
23
26
  }, /*#__PURE__*/React__default['default'].createElement(parts_messageDelimiter_styled.Line, null), /*#__PURE__*/React__default['default'].createElement(parts_messageDelimiter_styled.Text, {
@@ -1 +1 @@
1
- {"version":3,"file":"MessageDelimiter.js","sources":["../../../../src/parts/message-delimiter/MessageDelimiter.tsx"],"sourcesContent":["import React from 'react';\nimport { describe } from 'react-desc';\nimport { Wrapper, Line, Text } from './styled';\nimport { defaultProps, messageDelimiterProps, MessageDelimiterProps } from './props';\n\nconst MessageDelimiter = ({ title, size, extraProps, verticalMargin }: MessageDelimiterProps): JSX.Element => (\n <Wrapper cols={['1fr', 'auto', '1fr']}>\n <Line />\n <Text size={size} verticalMargin={verticalMargin} data-testid={extraProps['data-testid']}>\n {title}\n </Text>\n <Line />\n </Wrapper>\n);\n\nMessageDelimiter.defaultProps = defaultProps;\nMessageDelimiter.propTypes = messageDelimiterProps;\nconst MessageDelimiterWithSchema = describe(MessageDelimiter);\nMessageDelimiterWithSchema.propTypes = messageDelimiterProps;\n\nexport { MessageDelimiter, MessageDelimiterWithSchema };\n"],"names":["MessageDelimiter","title","size","extraProps","verticalMargin","React","Wrapper","Line","Text","defaultProps","propTypes","messageDelimiterProps","MessageDelimiterWithSchema","describe"],"mappings":";;;;;;;;;;;;;;;IAKMA,gBAAgB,GAAG,SAAnBA,gBAAmB;AAAA,MAAGC,KAAH,QAAGA,KAAH;AAAA,MAAUC,IAAV,QAAUA,IAAV;AAAA,MAAgBC,UAAhB,QAAgBA,UAAhB;AAAA,MAA4BC,cAA5B,QAA4BA,cAA5B;AAAA,sBACvBC,wCAACC,qCAAD;AAAS,IAAA,IAAI,EAAE,CAAC,KAAD,EAAQ,MAAR,EAAgB,KAAhB;AAAf,kBACED,wCAACE,kCAAD,OADF,eAEEF,wCAACG,kCAAD;AAAM,IAAA,IAAI,EAAEN,IAAZ;AAAkB,IAAA,cAAc,EAAEE,cAAlC;AAAkD,mBAAaD,UAAU,CAAC,aAAD;AAAzE,KACGF,KADH,CAFF,eAKEI,wCAACE,kCAAD,OALF,CADuB;AAAA;;AAUzBP,gBAAgB,CAACS,YAAjB,GAAgCA,yCAAhC;AACAT,gBAAgB,CAACU,SAAjB,GAA6BC,kDAA7B;IACMC,0BAA0B,GAAGC,kBAAQ,CAACb,gBAAD;AAC3CY,0BAA0B,CAACF,SAA3B,GAAuCC,kDAAvC;;;;;"}
1
+ {"version":3,"file":"MessageDelimiter.js","sources":["../../../../src/parts/message-delimiter/MessageDelimiter.tsx"],"sourcesContent":["import React from 'react';\nimport { describe } from 'react-desc';\nimport { Wrapper, Line, Text } from './styled';\nimport { defaultProps, messageDelimiterProps, MessageDelimiterProps } from './props';\nimport { useValidateProps } from './config/useValidateProps';\n\nconst MessageDelimiter = (props: MessageDelimiterProps): JSX.Element => {\n useValidateProps(props, MessageDelimiterWithSchema.toJSON());\n const { title, size, extraProps, verticalMargin } = props;\n return (\n <Wrapper cols={['1fr', 'auto', '1fr']}>\n <Line />\n <Text size={size} verticalMargin={verticalMargin} data-testid={extraProps['data-testid']}>\n {title}\n </Text>\n <Line />\n </Wrapper>\n );\n};\n\nMessageDelimiter.defaultProps = defaultProps;\nMessageDelimiter.propTypes = messageDelimiterProps;\nconst MessageDelimiterWithSchema = describe(MessageDelimiter);\nMessageDelimiterWithSchema.propTypes = messageDelimiterProps;\n\nexport { MessageDelimiter, MessageDelimiterWithSchema };\n"],"names":["MessageDelimiter","props","useValidateProps","MessageDelimiterWithSchema","toJSON","title","size","extraProps","verticalMargin","React","Wrapper","Line","Text","defaultProps","propTypes","messageDelimiterProps","describe"],"mappings":";;;;;;;;;;;;;;;;;IAMMA,gBAAgB,GAAG,SAAnBA,gBAAmB,CAACC,KAAD,EAA+C;AACtEC,EAAAA,+DAAgB,CAACD,KAAD,EAAQE,0BAA0B,CAACC,MAA3B,EAAR,CAAhB;AACA,MAAQC,KAAR,GAAoDJ,KAApD,CAAQI,KAAR;AAAA,MAAeC,IAAf,GAAoDL,KAApD,CAAeK,IAAf;AAAA,MAAqBC,UAArB,GAAoDN,KAApD,CAAqBM,UAArB;AAAA,MAAiCC,cAAjC,GAAoDP,KAApD,CAAiCO,cAAjC;AACA,sBACEC,wCAACC,qCAAD;AAAS,IAAA,IAAI,EAAE,CAAC,KAAD,EAAQ,MAAR,EAAgB,KAAhB;AAAf,kBACED,wCAACE,kCAAD,OADF,eAEEF,wCAACG,kCAAD;AAAM,IAAA,IAAI,EAAEN,IAAZ;AAAkB,IAAA,cAAc,EAAEE,cAAlC;AAAkD,mBAAaD,UAAU,CAAC,aAAD;AAAzE,KACGF,KADH,CAFF,eAKEI,wCAACE,kCAAD,OALF,CADF;AASD;;AAEDX,gBAAgB,CAACa,YAAjB,GAAgCA,yCAAhC;AACAb,gBAAgB,CAACc,SAAjB,GAA6BC,kDAA7B;IACMZ,0BAA0B,GAAGa,kBAAQ,CAAChB,gBAAD;AAC3CG,0BAA0B,CAACW,SAA3B,GAAuCC,kDAAvC;;;;;"}
@@ -0,0 +1,12 @@
1
+ 'use strict';
2
+
3
+ Object.defineProperty(exports, '__esModule', { value: true });
4
+
5
+ var dsPropsHelpers = require('@elliemae/ds-props-helpers');
6
+
7
+ var useValidateProps = function useValidateProps(props, schema) {
8
+ dsPropsHelpers.useValidatePropTypes(props, schema);
9
+ };
10
+
11
+ exports.useValidateProps = useValidateProps;
12
+ //# sourceMappingURL=useValidateProps.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"useValidateProps.js","sources":["../../../../../src/parts/message-delimiter/config/useValidateProps.tsx"],"sourcesContent":["import { useValidatePropTypes } from '@elliemae/ds-props-helpers';\nimport { MessageDelimiterProps } from '../props';\n\nexport const useValidateProps = (props: MessageDelimiterProps, schema: unknown): void => {\n useValidatePropTypes(props, schema);\n};\n"],"names":["useValidateProps","props","schema","useValidatePropTypes"],"mappings":";;;;;;IAGaA,gBAAgB,GAAG,SAAnBA,gBAAmB,CAACC,KAAD,EAA+BC,MAA/B,EAAyD;AACvFC,EAAAA,mCAAoB,CAACF,KAAD,EAAQC,MAAR,CAApB;AACD;;;;"}
@@ -9,6 +9,8 @@ require('./styled.js');
9
9
  require('@elliemae/ds-grid');
10
10
  require('styled-components');
11
11
  require('./props.js');
12
+ require('./config/useValidateProps.js');
13
+ require('@elliemae/ds-props-helpers');
12
14
 
13
15
 
14
16
 
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;"}
1
+ {"version":3,"file":"index.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;"}
@@ -16,7 +16,7 @@ var messageDelimiterProps = {
16
16
  title: reactDesc.PropTypes.string.isRequired.description('Text to display in the delimiter'),
17
17
  size: reactDesc.PropTypes.oneOf(['s', 'l']).description('size of the delimiter').defaultValue('s'),
18
18
  extraProps: reactDesc.PropTypes.object.description('extra props for delimiter'),
19
- verticalMargin: reactDesc.PropTypes.string.description('Configurable css vertical margin property for flexibilty')
19
+ verticalMargin: reactDesc.PropTypes.oneOf(['string', 'number']).description('Configurable css vertical margin property for flexibilty')
20
20
  };
21
21
 
22
22
  exports.defaultProps = defaultProps;
@@ -1 +1 @@
1
- {"version":3,"file":"props.js","sources":["../../../../src/parts/message-delimiter/props.tsx"],"sourcesContent":["import { PropTypes } from 'react-desc';\n\nexport interface MessageDelimiterProps {\n title: string;\n size?: 's' | 'l';\n verticalMargin?: number | string;\n extraProps?: {};\n}\n\nexport const defaultProps: MessageDelimiterProps = {\n title: '',\n size: 's',\n verticalMargin: '0px',\n extraProps: { 'data-testid': 'chat-message-delimiter-title' },\n};\n\nexport const messageDelimiterProps = {\n title: PropTypes.string.isRequired.description('Text to display in the delimiter'),\n size: PropTypes.oneOf(['s', 'l']).description('size of the delimiter').defaultValue('s'),\n extraProps: PropTypes.object.description('extra props for delimiter'),\n verticalMargin: PropTypes.string.description('Configurable css vertical margin property for flexibilty'),\n};\n"],"names":["defaultProps","title","size","verticalMargin","extraProps","messageDelimiterProps","PropTypes","string","isRequired","description","oneOf","defaultValue","object"],"mappings":";;;;;;IASaA,YAAmC,GAAG;AACjDC,EAAAA,KAAK,EAAE,EAD0C;AAEjDC,EAAAA,IAAI,EAAE,GAF2C;AAGjDC,EAAAA,cAAc,EAAE,KAHiC;AAIjDC,EAAAA,UAAU,EAAE;AAAE,mBAAe;AAAjB;AAJqC;IAOtCC,qBAAqB,GAAG;AACnCJ,EAAAA,KAAK,EAAEK,mBAAS,CAACC,MAAV,CAAiBC,UAAjB,CAA4BC,WAA5B,CAAwC,kCAAxC,CAD4B;AAEnCP,EAAAA,IAAI,EAAEI,mBAAS,CAACI,KAAV,CAAgB,CAAC,GAAD,EAAM,GAAN,CAAhB,EAA4BD,WAA5B,CAAwC,uBAAxC,EAAiEE,YAAjE,CAA8E,GAA9E,CAF6B;AAGnCP,EAAAA,UAAU,EAAEE,mBAAS,CAACM,MAAV,CAAiBH,WAAjB,CAA6B,2BAA7B,CAHuB;AAInCN,EAAAA,cAAc,EAAEG,mBAAS,CAACC,MAAV,CAAiBE,WAAjB,CAA6B,0DAA7B;AAJmB;;;;;"}
1
+ {"version":3,"file":"props.js","sources":["../../../../src/parts/message-delimiter/props.tsx"],"sourcesContent":["import { PropTypes } from 'react-desc';\n\nexport interface MessageDelimiterProps {\n title: string;\n size?: 's' | 'l';\n verticalMargin?: number | string;\n extraProps?: {};\n}\n\nexport const defaultProps: MessageDelimiterProps = {\n title: '',\n size: 's',\n verticalMargin: '0px',\n extraProps: { 'data-testid': 'chat-message-delimiter-title' },\n};\n\nexport const messageDelimiterProps = {\n title: PropTypes.string.isRequired.description('Text to display in the delimiter'),\n size: PropTypes.oneOf(['s', 'l']).description('size of the delimiter').defaultValue('s'),\n extraProps: PropTypes.object.description('extra props for delimiter'),\n verticalMargin: PropTypes.oneOf(['string', 'number']).description(\n 'Configurable css vertical margin property for flexibilty',\n ),\n};\n"],"names":["defaultProps","title","size","verticalMargin","extraProps","messageDelimiterProps","PropTypes","string","isRequired","description","oneOf","defaultValue","object"],"mappings":";;;;;;IASaA,YAAmC,GAAG;AACjDC,EAAAA,KAAK,EAAE,EAD0C;AAEjDC,EAAAA,IAAI,EAAE,GAF2C;AAGjDC,EAAAA,cAAc,EAAE,KAHiC;AAIjDC,EAAAA,UAAU,EAAE;AAAE,mBAAe;AAAjB;AAJqC;IAOtCC,qBAAqB,GAAG;AACnCJ,EAAAA,KAAK,EAAEK,mBAAS,CAACC,MAAV,CAAiBC,UAAjB,CAA4BC,WAA5B,CAAwC,kCAAxC,CAD4B;AAEnCP,EAAAA,IAAI,EAAEI,mBAAS,CAACI,KAAV,CAAgB,CAAC,GAAD,EAAM,GAAN,CAAhB,EAA4BD,WAA5B,CAAwC,uBAAxC,EAAiEE,YAAjE,CAA8E,GAA9E,CAF6B;AAGnCP,EAAAA,UAAU,EAAEE,mBAAS,CAACM,MAAV,CAAiBH,WAAjB,CAA6B,2BAA7B,CAHuB;AAInCN,EAAAA,cAAc,EAAEG,mBAAS,CAACI,KAAV,CAAgB,CAAC,QAAD,EAAW,QAAX,CAAhB,EAAsCD,WAAtC,CACd,0DADc;AAJmB;;;;;"}
@@ -1 +1 @@
1
- {"version":3,"file":"SidebarButton.js","sources":["../../../../src/parts/sidebar-button/SidebarButton.tsx"],"sourcesContent":["import React from 'react';\nimport {\n StyledSidebarButton,\n StyledSidebarButtonLabel,\n StyledSidebarButtonIcon,\n} from './styled';\nimport {\n propsSidebarButton,\n defaultSidebarButton,\n SidebarButtonProps,\n} from './props';\n\nexport const SidebarButton = ({\n label,\n dsId,\n onClick,\n Icon,\n ...rest\n}: SidebarButtonProps): JSX.Element => {\n const handleClick = React.useCallback(() => {\n onClick(dsId);\n }, [onClick, dsId]);\n\n return (\n <StyledSidebarButton\n key={dsId}\n data-testid={`sidebar-button-${dsId}`}\n onClick={handleClick}\n {...rest}\n >\n <StyledSidebarButtonIcon alignItems=\"center\" justifyContent=\"center\">\n <Icon size=\"m\" />\n </StyledSidebarButtonIcon>\n {label && <StyledSidebarButtonLabel>{label}</StyledSidebarButtonLabel>}\n </StyledSidebarButton>\n );\n};\n\nSidebarButton.propTypes = propsSidebarButton;\nSidebarButton.defaultProps = defaultSidebarButton;\n"],"names":["SidebarButton","label","dsId","onClick","Icon","rest","handleClick","React","useCallback","StyledSidebarButton","StyledSidebarButtonIcon","StyledSidebarButtonLabel","propTypes","propsSidebarButton","defaultProps","defaultSidebarButton"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;IAYaA,aAAa,GAAG,SAAhBA,aAAgB,OAMU;AAAA,MALrCC,KAKqC,QALrCA,KAKqC;AAAA,MAJrCC,IAIqC,QAJrCA,IAIqC;AAAA,MAHrCC,OAGqC,QAHrCA,OAGqC;AAAA,MAFrCC,IAEqC,QAFrCA,IAEqC;AAAA,MADlCC,IACkC;;AACrC,MAAMC,WAAW,GAAGC,yBAAK,CAACC,WAAN,CAAkB,YAAM;AAC1CL,IAAAA,OAAO,CAACD,IAAD,CAAP;AACD,GAFmB,EAEjB,CAACC,OAAD,EAAUD,IAAV,CAFiB,CAApB;AAIA,sBACEK,wCAACE,8CAAD;AACE,IAAA,GAAG,EAAEP,IADP;AAEE,4CAA+BA,IAA/B,CAFF;AAGE,IAAA,OAAO,EAAEI;AAHX,KAIMD,IAJN,gBAMEE,wCAACG,kDAAD;AAAyB,IAAA,UAAU,EAAC,QAApC;AAA6C,IAAA,cAAc,EAAC;AAA5D,kBACEH,wCAAC,IAAD;AAAM,IAAA,IAAI,EAAC;AAAX,IADF,CANF,EASGN,KAAK,iBAAIM,wCAACI,mDAAD,QAA2BV,KAA3B,CATZ,CADF;AAaD;AAEDD,aAAa,CAACY,SAAd,GAA0BC,4CAA1B;AACAb,aAAa,CAACc,YAAd,GAA6BC,8CAA7B;;;;"}
1
+ {"version":3,"file":"SidebarButton.js","sources":["../../../../src/parts/sidebar-button/SidebarButton.tsx"],"sourcesContent":["import React from 'react';\nimport { StyledSidebarButton, StyledSidebarButtonLabel, StyledSidebarButtonIcon } from './styled';\nimport { propsSidebarButton, defaultSidebarButton, SidebarButtonProps } from './props';\n\nexport const SidebarButton = ({ label, dsId, onClick, Icon, ...rest }: SidebarButtonProps): JSX.Element => {\n const handleClick = React.useCallback(() => {\n onClick(dsId);\n }, [onClick, dsId]);\n\n return (\n <StyledSidebarButton key={dsId} data-testid={`sidebar-button-${dsId}`} onClick={handleClick} {...rest}>\n <StyledSidebarButtonIcon alignItems=\"center\" justifyContent=\"center\">\n <Icon size=\"m\" />\n </StyledSidebarButtonIcon>\n {label && <StyledSidebarButtonLabel>{label}</StyledSidebarButtonLabel>}\n </StyledSidebarButton>\n );\n};\n\nSidebarButton.propTypes = propsSidebarButton;\nSidebarButton.defaultProps = defaultSidebarButton;\n"],"names":["SidebarButton","label","dsId","onClick","Icon","rest","handleClick","React","useCallback","StyledSidebarButton","StyledSidebarButtonIcon","StyledSidebarButtonLabel","propTypes","propsSidebarButton","defaultProps","defaultSidebarButton"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;IAIaA,aAAa,GAAG,SAAhBA,aAAgB,OAA8E;AAAA,MAA3EC,KAA2E,QAA3EA,KAA2E;AAAA,MAApEC,IAAoE,QAApEA,IAAoE;AAAA,MAA9DC,OAA8D,QAA9DA,OAA8D;AAAA,MAArDC,IAAqD,QAArDA,IAAqD;AAAA,MAA5CC,IAA4C;;AACzG,MAAMC,WAAW,GAAGC,yBAAK,CAACC,WAAN,CAAkB,YAAM;AAC1CL,IAAAA,OAAO,CAACD,IAAD,CAAP;AACD,GAFmB,EAEjB,CAACC,OAAD,EAAUD,IAAV,CAFiB,CAApB;AAIA,sBACEK,wCAACE,8CAAD;AAAqB,IAAA,GAAG,EAAEP,IAA1B;AAAgC,4CAA+BA,IAA/B,CAAhC;AAAuE,IAAA,OAAO,EAAEI;AAAhF,KAAiGD,IAAjG,gBACEE,wCAACG,kDAAD;AAAyB,IAAA,UAAU,EAAC,QAApC;AAA6C,IAAA,cAAc,EAAC;AAA5D,kBACEH,wCAAC,IAAD;AAAM,IAAA,IAAI,EAAC;AAAX,IADF,CADF,EAIGN,KAAK,iBAAIM,wCAACI,mDAAD,QAA2BV,KAA3B,CAJZ,CADF;AAQD;AAEDD,aAAa,CAACY,SAAd,GAA0BC,4CAA1B;AACAb,aAAa,CAACc,YAAd,GAA6BC,8CAA7B;;;;"}
@@ -12,10 +12,12 @@ var styled__default = /*#__PURE__*/_interopDefaultLegacy(styled);
12
12
 
13
13
  var StyledSidebarButton = /*#__PURE__*/styled__default['default'].button.withConfig({
14
14
  componentId: "sc-6ygly3-0"
15
- })(["display:flex;align-items:center;justify-content:center;outline:none;height:", "px;width:", "px;position:relative;border:0;background:transparent;&:focus,&:hover{background:", ";}cursor:pointer;border-bottom:1px solid ", ";"], styled$1.BUTTON_SIDEBAR_HEIGHT, styled$1.MIN_WIDTH_SIDEBAR, function (props) {
15
+ })(["display:flex;align-items:center;justify-content:center;outline:none;height:", "px;width:", "px;position:relative;border:0;background:transparent;&:focus,&:hover{background:", ";}cursor:pointer;border-bottom:1px solid ", ";svg{fill:", ";}"], styled$1.BUTTON_SIDEBAR_HEIGHT, styled$1.MIN_WIDTH_SIDEBAR, function (props) {
16
16
  return props.theme.colors.neutral['080'];
17
17
  }, function (props) {
18
18
  return props.theme.colors.neutral['200'];
19
+ }, function (props) {
20
+ return props.theme.colors.neutral[500];
19
21
  });
20
22
  var StyledSidebarButtonIcon = /*#__PURE__*/styled__default['default'](dsGrid.Grid).withConfig({
21
23
  componentId: "sc-6ygly3-1"
@@ -1 +1 @@
1
- {"version":3,"file":"styled.js","sources":["../../../../src/parts/sidebar-button/styled.ts"],"sourcesContent":["import styled from 'styled-components';\nimport { Grid } from '@elliemae/ds-grid';\nimport { BUTTON_SIDEBAR_HEIGHT, MIN_WIDTH_SIDEBAR } from '../../styled';\n\n// Buttons\nexport const StyledSidebarButton = styled.button`\n display: flex;\n align-items: center;\n justify-content: center;\n outline: none;\n height: ${BUTTON_SIDEBAR_HEIGHT}px;\n width: ${MIN_WIDTH_SIDEBAR}px;\n position: relative;\n border: 0;\n background: transparent;\n &:focus,\n &:hover {\n background: ${(props) => props.theme.colors.neutral['080']};\n }\n cursor: pointer;\n border-bottom: 1px solid ${(props) => props.theme.colors.neutral['200']};\n`;\n\nexport const StyledSidebarButtonIcon = styled(Grid)`\n position: relative;\n`;\n\nexport const StyledSidebarButtonLabel = styled.div`\n width: 30px;\n text-transform: uppercase;\n overflow: hidden;\n text-align: center;\n`;\n"],"names":["StyledSidebarButton","styled","button","BUTTON_SIDEBAR_HEIGHT","MIN_WIDTH_SIDEBAR","props","theme","colors","neutral","StyledSidebarButtonIcon","Grid","StyledSidebarButtonLabel","div"],"mappings":";;;;;;;;;;;;IAKaA,mBAAmB,gBAAGC,0BAAM,CAACC,MAAV;AAAA;AAAA,uOAKpBC,8BALoB,EAMrBC,0BANqB,EAYd,UAACC,KAAD;AAAA,SAAWA,KAAK,CAACC,KAAN,CAAYC,MAAZ,CAAmBC,OAAnB,CAA2B,KAA3B,CAAX;AAAA,CAZc,EAeH,UAACH,KAAD;AAAA,SAAWA,KAAK,CAACC,KAAN,CAAYC,MAAZ,CAAmBC,OAAnB,CAA2B,KAA3B,CAAX;AAAA,CAfG;IAkBnBC,uBAAuB,gBAAGR,0BAAM,CAACS,WAAD,CAAT;AAAA;AAAA;IAIvBC,wBAAwB,gBAAGV,0BAAM,CAACW,GAAV;AAAA;AAAA;;;;;;"}
1
+ {"version":3,"file":"styled.js","sources":["../../../../src/parts/sidebar-button/styled.ts"],"sourcesContent":["import styled from 'styled-components';\nimport { Grid } from '@elliemae/ds-grid';\nimport { BUTTON_SIDEBAR_HEIGHT, MIN_WIDTH_SIDEBAR } from '../../styled';\n\n// Buttons\nexport const StyledSidebarButton = styled.button`\n display: flex;\n align-items: center;\n justify-content: center;\n outline: none;\n height: ${BUTTON_SIDEBAR_HEIGHT}px;\n width: ${MIN_WIDTH_SIDEBAR}px;\n position: relative;\n border: 0;\n background: transparent;\n &:focus,\n &:hover {\n background: ${(props) => props.theme.colors.neutral['080']};\n }\n cursor: pointer;\n border-bottom: 1px solid ${(props) => props.theme.colors.neutral['200']};\n\n svg {\n fill: ${(props) => props.theme.colors.neutral[500]};\n }\n`;\n\nexport const StyledSidebarButtonIcon = styled(Grid)`\n position: relative;\n`;\n\nexport const StyledSidebarButtonLabel = styled.div`\n width: 30px;\n text-transform: uppercase;\n overflow: hidden;\n text-align: center;\n`;\n"],"names":["StyledSidebarButton","styled","button","BUTTON_SIDEBAR_HEIGHT","MIN_WIDTH_SIDEBAR","props","theme","colors","neutral","StyledSidebarButtonIcon","Grid","StyledSidebarButtonLabel","div"],"mappings":";;;;;;;;;;;;IAKaA,mBAAmB,gBAAGC,0BAAM,CAACC,MAAV;AAAA;AAAA,sPAKpBC,8BALoB,EAMrBC,0BANqB,EAYd,UAACC,KAAD;AAAA,SAAWA,KAAK,CAACC,KAAN,CAAYC,MAAZ,CAAmBC,OAAnB,CAA2B,KAA3B,CAAX;AAAA,CAZc,EAeH,UAACH,KAAD;AAAA,SAAWA,KAAK,CAACC,KAAN,CAAYC,MAAZ,CAAmBC,OAAnB,CAA2B,KAA3B,CAAX;AAAA,CAfG,EAkBpB,UAACH,KAAD;AAAA,SAAWA,KAAK,CAACC,KAAN,CAAYC,MAAZ,CAAmBC,OAAnB,CAA2B,GAA3B,CAAX;AAAA,CAlBoB;IAsBnBC,uBAAuB,gBAAGR,0BAAM,CAACS,WAAD,CAAT;AAAA;AAAA;IAIvBC,wBAAwB,gBAAGV,0BAAM,CAACW,GAAV;AAAA;AAAA;;;;;;"}
@@ -6,17 +6,20 @@ var React = require('react');
6
6
  var reactDesc = require('react-desc');
7
7
  var parts_systemMessage_style = require('./style.js');
8
8
  var parts_systemMessage_props = require('./props.js');
9
+ var parts_systemMessage_config_useValidateProps = require('./config/useValidateProps.js');
9
10
  require('styled-components');
10
11
  require('@elliemae/ds-grid');
12
+ require('@elliemae/ds-props-helpers');
11
13
 
12
14
  function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'default' in e ? e : { 'default': e }; }
13
15
 
14
16
  var React__default = /*#__PURE__*/_interopDefaultLegacy(React);
15
17
 
16
- var SystemMessage = function SystemMessage(_ref) {
17
- var title = _ref.title,
18
- time = _ref.time,
19
- body = _ref.body;
18
+ var SystemMessage = function SystemMessage(props) {
19
+ parts_systemMessage_config_useValidateProps.useValidateProps(props, SystemMessageWithSchema.toJSON());
20
+ var title = props.title,
21
+ time = props.time,
22
+ body = props.body;
20
23
  return /*#__PURE__*/React__default['default'].createElement(parts_systemMessage_style.Wrapper, {
21
24
  rows: ['auto', 'auto']
22
25
  }, /*#__PURE__*/React__default['default'].createElement(parts_systemMessage_style.Header, {
@@ -1 +1 @@
1
- {"version":3,"file":"SystemMessage.js","sources":["../../../../src/parts/system-message/SystemMessage.tsx"],"sourcesContent":["import React from 'react';\nimport { describe } from 'react-desc';\nimport { Wrapper, Header, Title, Time, Message } from './style';\nimport { SystemMessageProps, systemMessageProps, defaultProps } from './props';\n\nconst SystemMessage = ({\n title,\n time,\n body,\n}: SystemMessageProps): JSX.Element => (\n <Wrapper rows={['auto', 'auto']}>\n <Header cols={['1fr', 'auto', '1fr']}>\n <span />\n <Title data-testid=\"chat-system-message-title\">{title}</Title>\n <Time data-testid=\"chat-system-message-time\">{time}</Time>\n </Header>\n <Message data-testid=\"chat-system-message-body\">{body}</Message>\n </Wrapper>\n);\n\nSystemMessage.defaultProps = defaultProps;\nSystemMessage.propTypes = systemMessageProps;\nconst SystemMessageWithSchema = describe(SystemMessage);\nSystemMessageWithSchema.propTypes = systemMessageProps;\n\nexport { SystemMessage, SystemMessageWithSchema };\n"],"names":["SystemMessage","title","time","body","React","Wrapper","Header","Title","Time","Message","defaultProps","propTypes","systemMessageProps","SystemMessageWithSchema","describe"],"mappings":";;;;;;;;;;;;;;;IAKMA,aAAa,GAAG,SAAhBA,aAAgB;AAAA,MACpBC,KADoB,QACpBA,KADoB;AAAA,MAEpBC,IAFoB,QAEpBA,IAFoB;AAAA,MAGpBC,IAHoB,QAGpBA,IAHoB;AAAA,sBAKpBC,wCAACC,iCAAD;AAAS,IAAA,IAAI,EAAE,CAAC,MAAD,EAAS,MAAT;AAAf,kBACED,wCAACE,gCAAD;AAAQ,IAAA,IAAI,EAAE,CAAC,KAAD,EAAQ,MAAR,EAAgB,KAAhB;AAAd,kBACEF,qDADF,eAEEA,wCAACG,+BAAD;AAAO,mBAAY;AAAnB,KAAgDN,KAAhD,CAFF,eAGEG,wCAACI,8BAAD;AAAM,mBAAY;AAAlB,KAA8CN,IAA9C,CAHF,CADF,eAMEE,wCAACK,iCAAD;AAAS,mBAAY;AAArB,KAAiDN,IAAjD,CANF,CALoB;AAAA;;AAetBH,aAAa,CAACU,YAAd,GAA6BA,sCAA7B;AACAV,aAAa,CAACW,SAAd,GAA0BC,4CAA1B;IACMC,uBAAuB,GAAGC,kBAAQ,CAACd,aAAD;AACxCa,uBAAuB,CAACF,SAAxB,GAAoCC,4CAApC;;;;;"}
1
+ {"version":3,"file":"SystemMessage.js","sources":["../../../../src/parts/system-message/SystemMessage.tsx"],"sourcesContent":["import React from 'react';\nimport { describe } from 'react-desc';\nimport { Wrapper, Header, Title, Time, Message } from './style';\nimport { SystemMessageProps, systemMessageProps, defaultProps } from './props';\nimport { useValidateProps } from './config/useValidateProps';\n\nconst SystemMessage = (props: SystemMessageProps): JSX.Element => {\n useValidateProps(props, SystemMessageWithSchema.toJSON());\n const { title, time, body } = props;\n return (\n <Wrapper rows={['auto', 'auto']}>\n <Header cols={['1fr', 'auto', '1fr']}>\n <span />\n <Title data-testid=\"chat-system-message-title\">{title}</Title>\n <Time data-testid=\"chat-system-message-time\">{time}</Time>\n </Header>\n <Message data-testid=\"chat-system-message-body\">{body}</Message>\n </Wrapper>\n );\n};\n\nSystemMessage.defaultProps = defaultProps;\nSystemMessage.propTypes = systemMessageProps;\nconst SystemMessageWithSchema = describe(SystemMessage);\nSystemMessageWithSchema.propTypes = systemMessageProps;\n\nexport { SystemMessage, SystemMessageWithSchema };\n"],"names":["SystemMessage","props","useValidateProps","SystemMessageWithSchema","toJSON","title","time","body","React","Wrapper","Header","Title","Time","Message","defaultProps","propTypes","systemMessageProps","describe"],"mappings":";;;;;;;;;;;;;;;;;IAMMA,aAAa,GAAG,SAAhBA,aAAgB,CAACC,KAAD,EAA4C;AAChEC,EAAAA,4DAAgB,CAACD,KAAD,EAAQE,uBAAuB,CAACC,MAAxB,EAAR,CAAhB;AACA,MAAQC,KAAR,GAA8BJ,KAA9B,CAAQI,KAAR;AAAA,MAAeC,IAAf,GAA8BL,KAA9B,CAAeK,IAAf;AAAA,MAAqBC,IAArB,GAA8BN,KAA9B,CAAqBM,IAArB;AACA,sBACEC,wCAACC,iCAAD;AAAS,IAAA,IAAI,EAAE,CAAC,MAAD,EAAS,MAAT;AAAf,kBACED,wCAACE,gCAAD;AAAQ,IAAA,IAAI,EAAE,CAAC,KAAD,EAAQ,MAAR,EAAgB,KAAhB;AAAd,kBACEF,qDADF,eAEEA,wCAACG,+BAAD;AAAO,mBAAY;AAAnB,KAAgDN,KAAhD,CAFF,eAGEG,wCAACI,8BAAD;AAAM,mBAAY;AAAlB,KAA8CN,IAA9C,CAHF,CADF,eAMEE,wCAACK,iCAAD;AAAS,mBAAY;AAArB,KAAiDN,IAAjD,CANF,CADF;AAUD;;AAEDP,aAAa,CAACc,YAAd,GAA6BA,sCAA7B;AACAd,aAAa,CAACe,SAAd,GAA0BC,4CAA1B;IACMb,uBAAuB,GAAGc,kBAAQ,CAACjB,aAAD;AACxCG,uBAAuB,CAACY,SAAxB,GAAoCC,4CAApC;;;;;"}
@@ -0,0 +1,12 @@
1
+ 'use strict';
2
+
3
+ Object.defineProperty(exports, '__esModule', { value: true });
4
+
5
+ var dsPropsHelpers = require('@elliemae/ds-props-helpers');
6
+
7
+ var useValidateProps = function useValidateProps(props, schema) {
8
+ dsPropsHelpers.useValidatePropTypes(props, schema);
9
+ };
10
+
11
+ exports.useValidateProps = useValidateProps;
12
+ //# sourceMappingURL=useValidateProps.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"useValidateProps.js","sources":["../../../../../src/parts/system-message/config/useValidateProps.tsx"],"sourcesContent":["import { useValidatePropTypes } from '@elliemae/ds-props-helpers';\nimport { SystemMessageProps } from '../props';\n\nexport const useValidateProps = (props: SystemMessageProps, schema: unknown): void => {\n useValidatePropTypes(props, schema);\n};\n"],"names":["useValidateProps","props","schema","useValidatePropTypes"],"mappings":";;;;;;IAGaA,gBAAgB,GAAG,SAAnBA,gBAAmB,CAACC,KAAD,EAA4BC,MAA5B,EAAsD;AACpFC,EAAAA,mCAAoB,CAACF,KAAD,EAAQC,MAAR,CAApB;AACD;;;;"}
@@ -9,6 +9,8 @@ require('./style.js');
9
9
  require('styled-components');
10
10
  require('@elliemae/ds-grid');
11
11
  require('./props.js');
12
+ require('./config/useValidateProps.js');
13
+ require('@elliemae/ds-props-helpers');
12
14
 
13
15
 
14
16
 
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;"}
1
+ {"version":3,"file":"index.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;"}