@mks2508/mks-ui 0.3.2 → 0.4.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 (322) hide show
  1. package/dist/react-ui/blocks/Terminal/ResttyAdapter.d.ts +146 -0
  2. package/dist/react-ui/blocks/Terminal/ResttyAdapter.d.ts.map +1 -0
  3. package/dist/react-ui/blocks/Terminal/ResttyAdapter.js +213 -0
  4. package/dist/react-ui/blocks/Terminal/Terminal.adapter.d.ts +55 -0
  5. package/dist/react-ui/blocks/Terminal/Terminal.adapter.d.ts.map +1 -0
  6. package/dist/react-ui/blocks/Terminal/Terminal.adapter.js +68 -0
  7. package/dist/react-ui/blocks/Terminal/Terminal.theme.d.ts +43 -0
  8. package/dist/react-ui/blocks/Terminal/Terminal.theme.d.ts.map +1 -0
  9. package/dist/react-ui/blocks/Terminal/Terminal.theme.js +59 -0
  10. package/dist/react-ui/blocks/Terminal/Terminal.theme.restty.d.ts +63 -0
  11. package/dist/react-ui/blocks/Terminal/Terminal.theme.restty.d.ts.map +1 -0
  12. package/dist/react-ui/blocks/Terminal/Terminal.theme.restty.js +109 -0
  13. package/dist/react-ui/blocks/Terminal/Terminal.types.d.ts +351 -0
  14. package/dist/react-ui/blocks/Terminal/Terminal.types.d.ts.map +1 -0
  15. package/dist/react-ui/blocks/Terminal/TerminalPanel.d.ts +60 -0
  16. package/dist/react-ui/blocks/Terminal/TerminalPanel.d.ts.map +1 -0
  17. package/dist/react-ui/blocks/Terminal/TerminalPanel.js +183 -0
  18. package/dist/react-ui/blocks/Terminal/TerminalRestty.d.ts +111 -0
  19. package/dist/react-ui/blocks/Terminal/TerminalRestty.d.ts.map +1 -0
  20. package/dist/react-ui/blocks/Terminal/TerminalRestty.js +185 -0
  21. package/dist/react-ui/blocks/Terminal/TerminalXterm.d.ts +58 -0
  22. package/dist/react-ui/blocks/Terminal/TerminalXterm.d.ts.map +1 -0
  23. package/dist/react-ui/blocks/Terminal/TerminalXterm.js +143 -0
  24. package/dist/react-ui/blocks/Terminal/XTermAdapter.d.ts +87 -0
  25. package/dist/react-ui/blocks/Terminal/XTermAdapter.d.ts.map +1 -0
  26. package/dist/react-ui/blocks/Terminal/XTermAdapter.js +135 -0
  27. package/dist/react-ui/blocks/Terminal/components/LogLineBadges.d.ts +160 -0
  28. package/dist/react-ui/blocks/Terminal/components/LogLineBadges.d.ts.map +1 -0
  29. package/dist/react-ui/blocks/Terminal/components/LogLineBadges.js +185 -0
  30. package/dist/react-ui/blocks/Terminal/components/SpecializedSyntaxHighlighter.d.ts +48 -0
  31. package/dist/react-ui/blocks/Terminal/components/SpecializedSyntaxHighlighter.d.ts.map +1 -0
  32. package/dist/react-ui/blocks/Terminal/components/SpecializedSyntaxHighlighter.js +139 -0
  33. package/dist/react-ui/blocks/Terminal/components/SyntaxHighlight.d.ts +60 -0
  34. package/dist/react-ui/blocks/Terminal/components/SyntaxHighlight.d.ts.map +1 -0
  35. package/dist/react-ui/blocks/Terminal/components/SyntaxHighlight.js +352 -0
  36. package/dist/react-ui/blocks/Terminal/components/TerminalLogBadge.d.ts +36 -0
  37. package/dist/react-ui/blocks/Terminal/components/TerminalLogBadge.d.ts.map +1 -0
  38. package/dist/react-ui/blocks/Terminal/components/TerminalLogBadge.js +52 -0
  39. package/dist/react-ui/blocks/Terminal/components/index.d.ts +10 -0
  40. package/dist/react-ui/blocks/Terminal/components/index.d.ts.map +1 -0
  41. package/dist/react-ui/blocks/Terminal/components/index.js +4 -0
  42. package/dist/react-ui/blocks/Terminal/hooks/index.d.ts +11 -0
  43. package/dist/react-ui/blocks/Terminal/hooks/index.d.ts.map +1 -0
  44. package/dist/react-ui/blocks/Terminal/hooks/index.js +2 -0
  45. package/dist/react-ui/blocks/Terminal/hooks/useTerminalSettings.d.ts +69 -0
  46. package/dist/react-ui/blocks/Terminal/hooks/useTerminalSettings.d.ts.map +1 -0
  47. package/dist/react-ui/blocks/Terminal/hooks/useTerminalSettings.js +162 -0
  48. package/dist/react-ui/blocks/Terminal/hooks/useTerminalWebSocket.d.ts +104 -0
  49. package/dist/react-ui/blocks/Terminal/hooks/useTerminalWebSocket.d.ts.map +1 -0
  50. package/dist/react-ui/blocks/Terminal/hooks/useTerminalWebSocket.js +180 -0
  51. package/dist/react-ui/blocks/Terminal/index.d.ts +39 -0
  52. package/dist/react-ui/blocks/Terminal/index.d.ts.map +1 -0
  53. package/dist/react-ui/blocks/Terminal/index.js +38 -0
  54. package/dist/react-ui/blocks/Terminal/panel/LogLinesViewer.d.ts +58 -0
  55. package/dist/react-ui/blocks/Terminal/panel/LogLinesViewer.d.ts.map +1 -0
  56. package/dist/react-ui/blocks/Terminal/panel/LogLinesViewer.js +222 -0
  57. package/dist/react-ui/blocks/Terminal/panel/TerminalDebugPanel.d.ts +74 -0
  58. package/dist/react-ui/blocks/Terminal/panel/TerminalDebugPanel.d.ts.map +1 -0
  59. package/dist/react-ui/blocks/Terminal/panel/TerminalDebugPanel.js +168 -0
  60. package/dist/react-ui/blocks/Terminal/panel/TerminalFilterDropdown.d.ts +42 -0
  61. package/dist/react-ui/blocks/Terminal/panel/TerminalFilterDropdown.d.ts.map +1 -0
  62. package/dist/react-ui/blocks/Terminal/panel/TerminalFilterDropdown.js +175 -0
  63. package/dist/react-ui/blocks/Terminal/panel/TerminalFilterTabs.d.ts +43 -0
  64. package/dist/react-ui/blocks/Terminal/panel/TerminalFilterTabs.d.ts.map +1 -0
  65. package/dist/react-ui/blocks/Terminal/panel/TerminalInteractivePanel.d.ts +38 -0
  66. package/dist/react-ui/blocks/Terminal/panel/TerminalInteractivePanel.d.ts.map +1 -0
  67. package/dist/react-ui/blocks/Terminal/panel/TerminalInteractivePanel.js +62 -0
  68. package/dist/react-ui/blocks/Terminal/panel/TerminalInteractivePanel.types.d.ts +67 -0
  69. package/dist/react-ui/blocks/Terminal/panel/TerminalInteractivePanel.types.d.ts.map +1 -0
  70. package/dist/react-ui/blocks/Terminal/panel/TerminalInteractivePanelRestty.d.ts +32 -0
  71. package/dist/react-ui/blocks/Terminal/panel/TerminalInteractivePanelRestty.d.ts.map +1 -0
  72. package/dist/react-ui/blocks/Terminal/panel/TerminalInteractivePanelRestty.js +326 -0
  73. package/dist/react-ui/blocks/Terminal/panel/TerminalInteractivePanelXterm.d.ts +36 -0
  74. package/dist/react-ui/blocks/Terminal/panel/TerminalInteractivePanelXterm.d.ts.map +1 -0
  75. package/dist/react-ui/blocks/Terminal/panel/TerminalInteractivePanelXterm.js +371 -0
  76. package/dist/react-ui/blocks/Terminal/panel/TerminalLogsPanel.d.ts +67 -0
  77. package/dist/react-ui/blocks/Terminal/panel/TerminalLogsPanel.d.ts.map +1 -0
  78. package/dist/react-ui/blocks/Terminal/panel/TerminalLogsPanel.js +417 -0
  79. package/dist/react-ui/blocks/Terminal/panel/TerminalLogsPanel.types.d.ts +197 -0
  80. package/dist/react-ui/blocks/Terminal/panel/TerminalLogsPanel.types.d.ts.map +1 -0
  81. package/dist/react-ui/blocks/Terminal/panel/TerminalPanelChrome.d.ts +54 -0
  82. package/dist/react-ui/blocks/Terminal/panel/TerminalPanelChrome.d.ts.map +1 -0
  83. package/dist/react-ui/blocks/Terminal/panel/TerminalPanelChrome.js +193 -0
  84. package/dist/react-ui/blocks/Terminal/panel/TerminalPanelChrome.types.d.ts +57 -0
  85. package/dist/react-ui/blocks/Terminal/panel/TerminalPanelChrome.types.d.ts.map +1 -0
  86. package/dist/react-ui/blocks/Terminal/panel/TerminalPanelFooter.d.ts +30 -0
  87. package/dist/react-ui/blocks/Terminal/panel/TerminalPanelFooter.d.ts.map +1 -0
  88. package/dist/react-ui/blocks/Terminal/panel/TerminalPanelFooter.js +126 -0
  89. package/dist/react-ui/blocks/Terminal/panel/TerminalPanelHeader.d.ts +31 -0
  90. package/dist/react-ui/blocks/Terminal/panel/TerminalPanelHeader.d.ts.map +1 -0
  91. package/dist/react-ui/blocks/Terminal/panel/TerminalPanelHeader.js +149 -0
  92. package/dist/react-ui/blocks/Terminal/panel/TerminalPanelToolbar.d.ts +35 -0
  93. package/dist/react-ui/blocks/Terminal/panel/TerminalPanelToolbar.d.ts.map +1 -0
  94. package/dist/react-ui/blocks/Terminal/panel/TerminalSessionControl.d.ts +58 -0
  95. package/dist/react-ui/blocks/Terminal/panel/TerminalSessionControl.d.ts.map +1 -0
  96. package/dist/react-ui/blocks/Terminal/panel/TerminalSessionTabs.d.ts +63 -0
  97. package/dist/react-ui/blocks/Terminal/panel/TerminalSessionTabs.d.ts.map +1 -0
  98. package/dist/react-ui/blocks/Terminal/panel/TerminalSessionTabs.js +245 -0
  99. package/dist/react-ui/blocks/Terminal/panel/TerminalSettingsPopover.d.ts +24 -0
  100. package/dist/react-ui/blocks/Terminal/panel/TerminalSettingsPopover.d.ts.map +1 -0
  101. package/dist/react-ui/blocks/Terminal/panel/TerminalSettingsPopover.js +225 -0
  102. package/dist/react-ui/blocks/Terminal/panel/TerminalThemeSelector.d.ts +35 -0
  103. package/dist/react-ui/blocks/Terminal/panel/TerminalThemeSelector.d.ts.map +1 -0
  104. package/dist/react-ui/blocks/Terminal/panel/TerminalThemeSelector.js +187 -0
  105. package/dist/react-ui/blocks/Terminal/panel/index.d.ts +30 -0
  106. package/dist/react-ui/blocks/Terminal/panel/index.d.ts.map +1 -0
  107. package/dist/react-ui/blocks/Terminal/panel/terminal-filter-dropdown.module-Bovc57nm.css +60 -0
  108. package/dist/react-ui/blocks/Terminal/panel/terminal-filter-dropdown.module.js +5 -0
  109. package/dist/react-ui/blocks/Terminal/panel/terminal-session-tabs.module-QyxHO7cN.css +60 -0
  110. package/dist/react-ui/blocks/Terminal/panel/terminal-session-tabs.module.js +5 -0
  111. package/dist/react-ui/blocks/Terminal/parsing/BadgeFormatter.d.ts +73 -0
  112. package/dist/react-ui/blocks/Terminal/parsing/BadgeFormatter.d.ts.map +1 -0
  113. package/dist/react-ui/blocks/Terminal/parsing/BadgeFormatter.js +136 -0
  114. package/dist/react-ui/blocks/Terminal/parsing/HttpLogParser.d.ts +117 -0
  115. package/dist/react-ui/blocks/Terminal/parsing/HttpLogParser.d.ts.map +1 -0
  116. package/dist/react-ui/blocks/Terminal/parsing/HttpLogParser.js +174 -0
  117. package/dist/react-ui/blocks/Terminal/parsing/LogParser.types.d.ts +221 -0
  118. package/dist/react-ui/blocks/Terminal/parsing/LogParser.types.d.ts.map +1 -0
  119. package/dist/react-ui/blocks/Terminal/parsing/LogParserService.d.ts +184 -0
  120. package/dist/react-ui/blocks/Terminal/parsing/LogParserService.d.ts.map +1 -0
  121. package/dist/react-ui/blocks/Terminal/parsing/LogParserService.js +478 -0
  122. package/dist/react-ui/blocks/Terminal/parsing/MultilineAggregator.d.ts +173 -0
  123. package/dist/react-ui/blocks/Terminal/parsing/MultilineAggregator.d.ts.map +1 -0
  124. package/dist/react-ui/blocks/Terminal/parsing/MultilineAggregator.js +313 -0
  125. package/dist/react-ui/blocks/Terminal/parsing/PersistentLogBuffer.d.ts +181 -0
  126. package/dist/react-ui/blocks/Terminal/parsing/PersistentLogBuffer.d.ts.map +1 -0
  127. package/dist/react-ui/blocks/Terminal/parsing/PersistentLogBuffer.js +221 -0
  128. package/dist/react-ui/blocks/Terminal/parsing/SyntaxHighlighter.d.ts +69 -0
  129. package/dist/react-ui/blocks/Terminal/parsing/SyntaxHighlighter.d.ts.map +1 -0
  130. package/dist/react-ui/blocks/Terminal/parsing/SyntaxHighlighter.js +142 -0
  131. package/dist/react-ui/blocks/Terminal/parsing/TableParser.d.ts +125 -0
  132. package/dist/react-ui/blocks/Terminal/parsing/TableParser.d.ts.map +1 -0
  133. package/dist/react-ui/blocks/Terminal/parsing/TableParser.js +245 -0
  134. package/dist/react-ui/blocks/Terminal/parsing/ansi/AnsiColorMapper.d.ts +165 -0
  135. package/dist/react-ui/blocks/Terminal/parsing/ansi/AnsiColorMapper.d.ts.map +1 -0
  136. package/dist/react-ui/blocks/Terminal/parsing/ansi/AnsiColorMapper.js +225 -0
  137. package/dist/react-ui/blocks/Terminal/parsing/ansi/AnsiParser.d.ts +164 -0
  138. package/dist/react-ui/blocks/Terminal/parsing/ansi/AnsiParser.d.ts.map +1 -0
  139. package/dist/react-ui/blocks/Terminal/parsing/ansi/AnsiParser.js +285 -0
  140. package/dist/react-ui/blocks/Terminal/parsing/ansi/ansi.constants.d.ts +188 -0
  141. package/dist/react-ui/blocks/Terminal/parsing/ansi/ansi.constants.d.ts.map +1 -0
  142. package/dist/react-ui/blocks/Terminal/parsing/ansi/ansi.constants.js +178 -0
  143. package/dist/react-ui/blocks/Terminal/parsing/ansi/index.d.ts +12 -0
  144. package/dist/react-ui/blocks/Terminal/parsing/ansi/index.d.ts.map +1 -0
  145. package/dist/react-ui/blocks/Terminal/parsing/index.d.ts +24 -0
  146. package/dist/react-ui/blocks/Terminal/parsing/index.d.ts.map +1 -0
  147. package/dist/react-ui/blocks/Terminal/parsing/levels/LogLevel.types.d.ts +56 -0
  148. package/dist/react-ui/blocks/Terminal/parsing/levels/LogLevel.types.d.ts.map +1 -0
  149. package/dist/react-ui/blocks/Terminal/parsing/levels/LogLevelDetector.d.ts +140 -0
  150. package/dist/react-ui/blocks/Terminal/parsing/levels/LogLevelDetector.d.ts.map +1 -0
  151. package/dist/react-ui/blocks/Terminal/parsing/levels/LogLevelDetector.js +325 -0
  152. package/dist/react-ui/blocks/Terminal/parsing/levels/index.d.ts +10 -0
  153. package/dist/react-ui/blocks/Terminal/parsing/levels/index.d.ts.map +1 -0
  154. package/dist/react-ui/blocks/index.d.ts +11 -0
  155. package/dist/react-ui/blocks/index.d.ts.map +1 -0
  156. package/dist/react-ui/icons/lucide-animated/activity.js +1 -1
  157. package/dist/react-ui/icons/lucide-animated/bell-electric.js +1 -1
  158. package/dist/react-ui/icons/lucide-animated/bell.js +1 -1
  159. package/dist/react-ui/icons/lucide-animated/bot.js +1 -1
  160. package/dist/react-ui/icons/lucide-animated/box.js +1 -1
  161. package/dist/react-ui/icons/lucide-animated/circle-check.js +1 -1
  162. package/dist/react-ui/icons/lucide-animated/delete.js +1 -1
  163. package/dist/react-ui/icons/lucide-animated/download.js +1 -1
  164. package/dist/react-ui/icons/lucide-animated/home.js +1 -1
  165. package/dist/react-ui/icons/lucide-animated/layout-panel-top.js +1 -1
  166. package/dist/react-ui/icons/lucide-animated/plus.js +1 -1
  167. package/dist/react-ui/icons/lucide-animated/search.js +1 -1
  168. package/dist/react-ui/icons/lucide-animated/settings.js +1 -1
  169. package/dist/react-ui/icons/lucide-animated/trending-down.js +1 -1
  170. package/dist/react-ui/icons/lucide-animated/trending-up.js +1 -1
  171. package/dist/react-ui/icons/lucide-animated/x.js +1 -1
  172. package/dist/react-ui/index.js +3 -1
  173. package/dist/react-ui/lib/icon-wrapper.d.ts +37 -0
  174. package/dist/react-ui/lib/icon-wrapper.d.ts.map +1 -0
  175. package/dist/react-ui/lib/icon-wrapper.js +55 -0
  176. package/dist/react-ui/lib/index.d.ts +1 -0
  177. package/dist/react-ui/lib/index.d.ts.map +1 -1
  178. package/dist/react-ui/lib/index.js +1 -0
  179. package/dist/react-ui/primitives/AutoHeight/index.d.ts +1 -1
  180. package/dist/react-ui/primitives/CountingNumber/index.d.ts +1 -1
  181. package/dist/react-ui/primitives/waapi/SlidingNumber/SlidingNumber.styles.d.ts +1 -1
  182. package/dist/react-ui/primitives/waapi/SlidingText/SlidingText.styles.d.ts +1 -1
  183. package/dist/react-ui/ui/Accordion/Accordion.styles.d.ts +1 -1
  184. package/dist/react-ui/ui/Accordion/Accordion.types.d.ts +1 -1
  185. package/dist/react-ui/ui/AlertDialog/AlertDialog.styles.d.ts +1 -1
  186. package/dist/react-ui/ui/AlertDialog/AlertDialog.types.d.ts +1 -1
  187. package/dist/react-ui/ui/Badge/Badge.styles.d.ts +1 -1
  188. package/dist/react-ui/ui/Badge/Badge.types.d.ts +1 -1
  189. package/dist/react-ui/ui/Button/Button.styles.d.ts +2 -2
  190. package/dist/react-ui/ui/Button/Button.types.d.ts +1 -1
  191. package/dist/react-ui/ui/Card/Card.styles.d.ts +1 -1
  192. package/dist/react-ui/ui/Card/Card.types.d.ts +1 -1
  193. package/dist/react-ui/ui/Checkbox/Checkbox.styles.d.ts +1 -1
  194. package/dist/react-ui/ui/Checkbox/Checkbox.types.d.ts +1 -1
  195. package/dist/react-ui/ui/Combobox/Combobox.styles.d.ts +1 -1
  196. package/dist/react-ui/ui/Combobox/Combobox.types.d.ts +1 -1
  197. package/dist/react-ui/ui/CornerBracket/CornerBracket.styles.d.ts +2 -2
  198. package/dist/react-ui/ui/CornerBracket/CornerBracket.styles.js +1 -1
  199. package/dist/react-ui/ui/CornerBracket/CornerBracket.types.d.ts +1 -1
  200. package/dist/react-ui/ui/DataCard/DataCard.styles.d.ts +1 -1
  201. package/dist/react-ui/ui/DataCard/DataCard.types.d.ts +1 -1
  202. package/dist/react-ui/ui/DataCard/index.d.ts +1 -1
  203. package/dist/react-ui/ui/Dialog/Dialog.styles.d.ts +1 -1
  204. package/dist/react-ui/ui/Dialog/Dialog.types.d.ts +1 -1
  205. package/dist/react-ui/ui/DropdownMenu/DropdownMenu.styles.d.ts +1 -1
  206. package/dist/react-ui/ui/DropdownMenu/DropdownMenu.types.d.ts +1 -1
  207. package/dist/react-ui/ui/Field/Field.styles.d.ts +1 -1
  208. package/dist/react-ui/ui/Field/Field.types.d.ts +1 -1
  209. package/dist/react-ui/ui/Input/Input.styles.d.ts +1 -1
  210. package/dist/react-ui/ui/Input/Input.types.d.ts +1 -1
  211. package/dist/react-ui/ui/InputGroup/InputGroup.styles.d.ts +1 -1
  212. package/dist/react-ui/ui/InputGroup/InputGroup.types.d.ts +1 -1
  213. package/dist/react-ui/ui/Label/Label.styles.d.ts +1 -1
  214. package/dist/react-ui/ui/Label/Label.types.d.ts +1 -1
  215. package/dist/react-ui/ui/Menu/Menu.styles.d.ts +1 -1
  216. package/dist/react-ui/ui/Menu/Menu.types.d.ts +2 -2
  217. package/dist/react-ui/ui/Popover/Popover.styles.d.ts +1 -1
  218. package/dist/react-ui/ui/Popover/Popover.types.d.ts +1 -1
  219. package/dist/react-ui/ui/Progress/Progress.styles.d.ts +1 -1
  220. package/dist/react-ui/ui/Progress/Progress.types.d.ts +2 -2
  221. package/dist/react-ui/ui/Select/Select.styles.d.ts +1 -1
  222. package/dist/react-ui/ui/Select/Select.types.d.ts +1 -1
  223. package/dist/react-ui/ui/Separator/Separator.styles.d.ts +1 -1
  224. package/dist/react-ui/ui/Separator/Separator.types.d.ts +1 -1
  225. package/dist/react-ui/ui/Switch/Switch.styles.d.ts +1 -1
  226. package/dist/react-ui/ui/Switch/Switch.types.d.ts +1 -1
  227. package/dist/react-ui/ui/Tabs/Tabs.styles.d.ts +43 -25
  228. package/dist/react-ui/ui/Tabs/Tabs.styles.d.ts.map +1 -1
  229. package/dist/react-ui/ui/Tabs/Tabs.styles.js +105 -13
  230. package/dist/react-ui/ui/Tabs/Tabs.types.d.ts +9 -6
  231. package/dist/react-ui/ui/Tabs/Tabs.types.d.ts.map +1 -1
  232. package/dist/react-ui/ui/Tabs/index.d.ts +18 -9
  233. package/dist/react-ui/ui/Tabs/index.d.ts.map +1 -1
  234. package/dist/react-ui/ui/Tabs/index.js +99 -27
  235. package/dist/react-ui/ui/TextFlow/TextFlow.styles.d.ts +1 -1
  236. package/dist/react-ui/ui/Textarea/Textarea.styles.d.ts +1 -1
  237. package/dist/react-ui/ui/Textarea/Textarea.types.d.ts +1 -1
  238. package/dist/react-ui/ui/Tooltip/Tooltip.styles.d.ts +1 -1
  239. package/dist/react-ui/ui/Tooltip/Tooltip.types.d.ts +1 -1
  240. package/dist/react-ui/ui/index.js +1 -0
  241. package/package.json +54 -6
  242. package/src/react-ui/blocks/Terminal/ResttyAdapter.ts +278 -0
  243. package/src/react-ui/blocks/Terminal/Terminal.adapter.ts +97 -0
  244. package/src/react-ui/blocks/Terminal/Terminal.theme.restty.ts +155 -0
  245. package/src/react-ui/blocks/Terminal/Terminal.theme.ts +80 -0
  246. package/src/react-ui/blocks/Terminal/Terminal.types.ts +438 -0
  247. package/src/react-ui/blocks/Terminal/TerminalPanel.tsx +269 -0
  248. package/src/react-ui/blocks/Terminal/TerminalRestty.tsx +326 -0
  249. package/src/react-ui/blocks/Terminal/TerminalXterm.tsx +230 -0
  250. package/src/react-ui/blocks/Terminal/XTermAdapter.ts +163 -0
  251. package/src/react-ui/blocks/Terminal/components/LogLineBadges.tsx +316 -0
  252. package/src/react-ui/blocks/Terminal/components/SpecializedSyntaxHighlighter.tsx +218 -0
  253. package/src/react-ui/blocks/Terminal/components/SyntaxHighlight.tsx +386 -0
  254. package/src/react-ui/blocks/Terminal/components/TerminalLogBadge.tsx +67 -0
  255. package/src/react-ui/blocks/Terminal/components/index.ts +10 -0
  256. package/src/react-ui/blocks/Terminal/hooks/index.ts +22 -0
  257. package/src/react-ui/blocks/Terminal/hooks/useTerminalSettings.ts +229 -0
  258. package/src/react-ui/blocks/Terminal/hooks/useTerminalWebSocket.ts +292 -0
  259. package/src/react-ui/blocks/Terminal/index.ts +103 -0
  260. package/src/react-ui/blocks/Terminal/panel/LogLinesViewer.tsx +330 -0
  261. package/src/react-ui/blocks/Terminal/panel/TerminalDebugPanel.tsx +242 -0
  262. package/src/react-ui/blocks/Terminal/panel/TerminalFilterDropdown.tsx +202 -0
  263. package/src/react-ui/blocks/Terminal/panel/TerminalFilterTabs.tsx +140 -0
  264. package/src/react-ui/blocks/Terminal/panel/TerminalInteractivePanel.tsx +68 -0
  265. package/src/react-ui/blocks/Terminal/panel/TerminalInteractivePanel.types.ts +85 -0
  266. package/src/react-ui/blocks/Terminal/panel/TerminalInteractivePanelRestty.tsx +383 -0
  267. package/src/react-ui/blocks/Terminal/panel/TerminalInteractivePanelXterm.tsx +439 -0
  268. package/src/react-ui/blocks/Terminal/panel/TerminalLogsPanel.tsx +550 -0
  269. package/src/react-ui/blocks/Terminal/panel/TerminalLogsPanel.types.ts +259 -0
  270. package/src/react-ui/blocks/Terminal/panel/TerminalPanelChrome.tsx +237 -0
  271. package/src/react-ui/blocks/Terminal/panel/TerminalPanelChrome.types.ts +76 -0
  272. package/src/react-ui/blocks/Terminal/panel/TerminalPanelFooter.tsx +112 -0
  273. package/src/react-ui/blocks/Terminal/panel/TerminalPanelHeader.tsx +178 -0
  274. package/src/react-ui/blocks/Terminal/panel/TerminalPanelToolbar.tsx +203 -0
  275. package/src/react-ui/blocks/Terminal/panel/TerminalSessionControl.tsx +252 -0
  276. package/src/react-ui/blocks/Terminal/panel/TerminalSessionTabs.tsx +334 -0
  277. package/src/react-ui/blocks/Terminal/panel/TerminalSettingsPopover.tsx +261 -0
  278. package/src/react-ui/blocks/Terminal/panel/TerminalThemeSelector.tsx +248 -0
  279. package/src/react-ui/blocks/Terminal/panel/index.ts +72 -0
  280. package/src/react-ui/blocks/Terminal/panel/terminal-filter-dropdown.module.css +59 -0
  281. package/src/react-ui/blocks/Terminal/panel/terminal-session-tabs.module.css +59 -0
  282. package/src/react-ui/blocks/Terminal/parsing/BadgeFormatter.ts +180 -0
  283. package/src/react-ui/blocks/Terminal/parsing/HttpLogParser.ts +248 -0
  284. package/src/react-ui/blocks/Terminal/parsing/LogParser.types.ts +283 -0
  285. package/src/react-ui/blocks/Terminal/parsing/LogParserService.ts +686 -0
  286. package/src/react-ui/blocks/Terminal/parsing/MultilineAggregator.ts +466 -0
  287. package/src/react-ui/blocks/Terminal/parsing/PersistentLogBuffer.ts +343 -0
  288. package/src/react-ui/blocks/Terminal/parsing/SyntaxHighlighter.ts +167 -0
  289. package/src/react-ui/blocks/Terminal/parsing/TableParser.ts +348 -0
  290. package/src/react-ui/blocks/Terminal/parsing/ansi/AnsiColorMapper.ts +251 -0
  291. package/src/react-ui/blocks/Terminal/parsing/ansi/AnsiParser.ts +390 -0
  292. package/src/react-ui/blocks/Terminal/parsing/ansi/ansi.constants.ts +320 -0
  293. package/src/react-ui/blocks/Terminal/parsing/ansi/index.ts +20 -0
  294. package/src/react-ui/blocks/Terminal/parsing/index.ts +69 -0
  295. package/src/react-ui/blocks/Terminal/parsing/levels/LogLevel.types.ts +68 -0
  296. package/src/react-ui/blocks/Terminal/parsing/levels/LogLevelDetector.ts +436 -0
  297. package/src/react-ui/blocks/Terminal/parsing/levels/index.ts +14 -0
  298. package/src/react-ui/blocks/index.ts +11 -0
  299. package/src/react-ui/icons/lucide-animated/activity.tsx +2 -2
  300. package/src/react-ui/icons/lucide-animated/bell-electric.tsx +1 -1
  301. package/src/react-ui/icons/lucide-animated/bell.tsx +2 -2
  302. package/src/react-ui/icons/lucide-animated/bot.tsx +1 -1
  303. package/src/react-ui/icons/lucide-animated/box.tsx +2 -2
  304. package/src/react-ui/icons/lucide-animated/circle-check.tsx +2 -2
  305. package/src/react-ui/icons/lucide-animated/delete.tsx +2 -2
  306. package/src/react-ui/icons/lucide-animated/download.tsx +2 -2
  307. package/src/react-ui/icons/lucide-animated/home.tsx +2 -2
  308. package/src/react-ui/icons/lucide-animated/layout-panel-top.tsx +1 -1
  309. package/src/react-ui/icons/lucide-animated/plus.tsx +1 -1
  310. package/src/react-ui/icons/lucide-animated/search.tsx +1 -1
  311. package/src/react-ui/icons/lucide-animated/settings.tsx +1 -1
  312. package/src/react-ui/icons/lucide-animated/trending-down.tsx +2 -2
  313. package/src/react-ui/icons/lucide-animated/trending-up.tsx +2 -2
  314. package/src/react-ui/icons/lucide-animated/x.tsx +2 -2
  315. package/src/react-ui/lib/icon-wrapper.tsx +70 -0
  316. package/src/react-ui/lib/index.ts +1 -0
  317. package/src/react-ui/ui/CornerBracket/CornerBracket.styles.ts +1 -1
  318. package/src/react-ui/ui/Tabs/Tabs.css +39 -0
  319. package/src/react-ui/ui/Tabs/Tabs.styles.ts +119 -31
  320. package/src/react-ui/ui/Tabs/Tabs.types.ts +8 -3
  321. package/src/react-ui/ui/Tabs/index.tsx +135 -27
  322. package/dist/index.css +0 -129
@@ -0,0 +1,87 @@
1
+ /**
2
+ * XTerm Adapter - ITerminalAdapter implementation for xterm.js.
3
+ *
4
+ * Wrapper class that adapts xterm.js Terminal to the ITerminalAdapter
5
+ * interface, enabling consistent API across different backends.
6
+ *
7
+ * @module components/devenv/terminal/XTermAdapter
8
+ */
9
+ import type { ITerminalAdapter, ITerminalAdapterCapabilities, ITerminalOptions, ITerminalMode } from './Terminal.types';
10
+ /**
11
+ * XTermAdapter implements ITerminalAdapter for xterm.js.
12
+ *
13
+ * Provides xterm.js functionality through the standardized adapter interface.
14
+ * Manages terminal lifecycle including initialization, data writing,
15
+ * resizing, and cleanup.
16
+ */
17
+ export declare class XTermAdapter implements ITerminalAdapter {
18
+ /** Backend type identifier */
19
+ readonly type: "xterm";
20
+ /** Adapter capabilities for runtime feature detection */
21
+ readonly capabilities: ITerminalAdapterCapabilities;
22
+ /** xterm.js Terminal instance */
23
+ private terminal;
24
+ /** FitAddon for auto-resize */
25
+ private fitAddon;
26
+ /** Current options */
27
+ private options;
28
+ /**
29
+ * Create XTermAdapter instance.
30
+ *
31
+ * @param options - Terminal initialization options
32
+ */
33
+ constructor(options: ITerminalOptions);
34
+ /**
35
+ * Initialize the terminal in the given container element.
36
+ *
37
+ * Creates xterm.js Terminal instance, loads addons, and opens
38
+ * in the provided container.
39
+ *
40
+ * @param container - DOM element to render terminal into
41
+ * @param options - Terminal initialization options
42
+ * @returns Promise that resolves when terminal is ready
43
+ */
44
+ initialize(container: HTMLElement, options: ITerminalOptions): Promise<void>;
45
+ /**
46
+ * Write data to the terminal without newline.
47
+ *
48
+ * @param data - String data to write
49
+ */
50
+ write(data: string): void;
51
+ /**
52
+ * Write data to the terminal with newline.
53
+ *
54
+ * @param data - String data to write
55
+ */
56
+ writeln(data: string): void;
57
+ /**
58
+ * Clear the terminal buffer.
59
+ */
60
+ clear(): void;
61
+ /**
62
+ * Resize the terminal to the given dimensions.
63
+ *
64
+ * @param cols - Number of columns
65
+ * @param rows - Number of rows
66
+ */
67
+ resize(cols: number, rows: number): void;
68
+ /**
69
+ * Dispose of the terminal and release resources.
70
+ */
71
+ dispose(): void;
72
+ /**
73
+ * Switch between interactive and readonly modes.
74
+ *
75
+ * @param mode - Target mode
76
+ */
77
+ setMode(mode: ITerminalMode): void;
78
+ /**
79
+ * Focus the terminal for input.
80
+ */
81
+ focus(): void;
82
+ /**
83
+ * Remove focus from the terminal.
84
+ */
85
+ blur(): void;
86
+ }
87
+ //# sourceMappingURL=XTermAdapter.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"XTermAdapter.d.ts","sourceRoot":"","sources":["../../../../src/react-ui/blocks/Terminal/XTermAdapter.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AAIH,OAAO,KAAK,EACV,gBAAgB,EAChB,4BAA4B,EAC5B,gBAAgB,EAChB,aAAa,EACd,MAAM,kBAAkB,CAAC;AAE1B;;;;;;GAMG;AACH,qBAAa,YAAa,YAAW,gBAAgB;IACnD,8BAA8B;IAC9B,SAAgB,IAAI,EAAG,OAAO,CAAU;IAExC,yDAAyD;IACzD,SAAgB,YAAY,EAAE,4BAA4B,CAKxD;IAEF,iCAAiC;IACjC,OAAO,CAAC,QAAQ,CAAyB;IAEzC,+BAA+B;IAC/B,OAAO,CAAC,QAAQ,CAAyB;IAEzC,sBAAsB;IACtB,OAAO,CAAC,OAAO,CAAmB;IAElC;;;;OAIG;gBACS,OAAO,EAAE,gBAAgB;IAIrC;;;;;;;;;OASG;IACG,UAAU,CAAC,SAAS,EAAE,WAAW,EAAE,OAAO,EAAE,gBAAgB,GAAG,OAAO,CAAC,IAAI,CAAC;IA6BlF;;;;OAIG;IACH,KAAK,CAAC,IAAI,EAAE,MAAM,GAAG,IAAI;IAIzB;;;;OAIG;IACH,OAAO,CAAC,IAAI,EAAE,MAAM,GAAG,IAAI;IAI3B;;OAEG;IACH,KAAK,IAAI,IAAI;IAIb;;;;;OAKG;IACH,MAAM,CAAC,IAAI,EAAE,MAAM,EAAE,IAAI,EAAE,MAAM,GAAG,IAAI;IAIxC;;OAEG;IACH,OAAO,IAAI,IAAI;IAMf;;;;OAIG;IACH,OAAO,CAAC,IAAI,EAAE,aAAa,GAAG,IAAI;IAMlC;;OAEG;IACH,KAAK,IAAI,IAAI;IAIb;;OAEG;IACH,IAAI,IAAI,IAAI;CAGb"}
@@ -0,0 +1,135 @@
1
+ import { Terminal } from "@xterm/xterm";
2
+ import { FitAddon } from "@xterm/addon-fit";
3
+
4
+ //#region src/react-ui/blocks/Terminal/XTermAdapter.ts
5
+ /**
6
+ * XTerm Adapter - ITerminalAdapter implementation for xterm.js.
7
+ *
8
+ * Wrapper class that adapts xterm.js Terminal to the ITerminalAdapter
9
+ * interface, enabling consistent API across different backends.
10
+ *
11
+ * @module components/devenv/terminal/XTermAdapter
12
+ */
13
+ /**
14
+ * XTermAdapter implements ITerminalAdapter for xterm.js.
15
+ *
16
+ * Provides xterm.js functionality through the standardized adapter interface.
17
+ * Manages terminal lifecycle including initialization, data writing,
18
+ * resizing, and cleanup.
19
+ */
20
+ var XTermAdapter = class {
21
+ /** Backend type identifier */
22
+ type = "xterm";
23
+ /** Adapter capabilities for runtime feature detection */
24
+ capabilities = {
25
+ managesOwnConnection: false,
26
+ gpuRendering: false,
27
+ multiPane: false,
28
+ builtinThemes: false
29
+ };
30
+ /** xterm.js Terminal instance */
31
+ terminal = null;
32
+ /** FitAddon for auto-resize */
33
+ fitAddon = null;
34
+ /** Current options */
35
+ options;
36
+ /**
37
+ * Create XTermAdapter instance.
38
+ *
39
+ * @param options - Terminal initialization options
40
+ */
41
+ constructor(options) {
42
+ this.options = options;
43
+ }
44
+ /**
45
+ * Initialize the terminal in the given container element.
46
+ *
47
+ * Creates xterm.js Terminal instance, loads addons, and opens
48
+ * in the provided container.
49
+ *
50
+ * @param container - DOM element to render terminal into
51
+ * @param options - Terminal initialization options
52
+ * @returns Promise that resolves when terminal is ready
53
+ */
54
+ async initialize(container, options) {
55
+ this.options = options;
56
+ this.terminal = new Terminal({
57
+ cursorBlink: options.cursorBlink ?? true,
58
+ scrollback: options.scrollback ?? 1e3,
59
+ fontSize: options.fontSize ?? 14,
60
+ fontFamily: options.fontFamily ?? "'JetBrains Mono', 'Fira Code', 'SF Mono', 'Monaco', 'Inconsolata', monospace",
61
+ theme: options.theme ?? {},
62
+ convertEol: true
63
+ });
64
+ this.fitAddon = new FitAddon();
65
+ this.terminal.loadAddon(this.fitAddon);
66
+ this.terminal.open(container);
67
+ this.fitAddon.fit();
68
+ if (options.mode === "interactive" && options.onData) this.terminal.onData(options.onData);
69
+ }
70
+ /**
71
+ * Write data to the terminal without newline.
72
+ *
73
+ * @param data - String data to write
74
+ */
75
+ write(data) {
76
+ this.terminal?.write(data);
77
+ }
78
+ /**
79
+ * Write data to the terminal with newline.
80
+ *
81
+ * @param data - String data to write
82
+ */
83
+ writeln(data) {
84
+ this.terminal?.writeln(data);
85
+ }
86
+ /**
87
+ * Clear the terminal buffer.
88
+ */
89
+ clear() {
90
+ this.terminal?.clear();
91
+ }
92
+ /**
93
+ * Resize the terminal to the given dimensions.
94
+ *
95
+ * @param cols - Number of columns
96
+ * @param rows - Number of rows
97
+ */
98
+ resize(cols, rows) {
99
+ this.terminal?.resize(cols, rows);
100
+ }
101
+ /**
102
+ * Dispose of the terminal and release resources.
103
+ */
104
+ dispose() {
105
+ this.terminal?.dispose();
106
+ this.terminal = null;
107
+ this.fitAddon = null;
108
+ }
109
+ /**
110
+ * Switch between interactive and readonly modes.
111
+ *
112
+ * @param mode - Target mode
113
+ */
114
+ setMode(mode) {
115
+ this.options = {
116
+ ...this.options,
117
+ mode
118
+ };
119
+ }
120
+ /**
121
+ * Focus the terminal for input.
122
+ */
123
+ focus() {
124
+ this.terminal?.focus();
125
+ }
126
+ /**
127
+ * Remove focus from the terminal.
128
+ */
129
+ blur() {
130
+ this.terminal?.blur();
131
+ }
132
+ };
133
+
134
+ //#endregion
135
+ export { XTermAdapter };
@@ -0,0 +1,160 @@
1
+ /**
2
+ * React badge components for log lines.
3
+ *
4
+ * Styled badge components using Tailwind CSS for the React log viewer.
5
+ * Provides level badges, timestamp badges, and tag badges with consistent
6
+ * Synthwave Dark theme styling.
7
+ *
8
+ * All badge components are memoized for optimal performance.
9
+ *
10
+ * @module components/devenv/terminal/LogLineBadges
11
+ */
12
+ import type { TLogLevel, TContentType } from '../parsing';
13
+ /**
14
+ * Props for LevelBadge component.
15
+ */
16
+ export interface ILevelBadgeProps {
17
+ /** Log level to display */
18
+ level: TLogLevel;
19
+ /** Optional custom class name */
20
+ className?: string;
21
+ }
22
+ /**
23
+ * Level badge component (memoized).
24
+ *
25
+ * Displays a colored badge with the log level label.
26
+ * Uses Synthwave Dark theme colors with glassmorphic effect.
27
+ *
28
+ * @example
29
+ * ```tsx
30
+ * <LevelBadge level="info" />
31
+ * // Renders: [INFO] with blue background
32
+ * ```
33
+ */
34
+ export declare const LevelBadge: import("react").NamedExoticComponent<ILevelBadgeProps>;
35
+ /**
36
+ * Props for TimestampBadge component.
37
+ */
38
+ export interface ITimestampBadgeProps {
39
+ /** Timestamp string to display */
40
+ timestamp: string;
41
+ /** Optional custom class name */
42
+ className?: string;
43
+ }
44
+ /**
45
+ * Timestamp badge component (memoized).
46
+ *
47
+ * Displays a timestamp with muted styling.
48
+ * Uses tabular numbers for consistent alignment.
49
+ *
50
+ * @example
51
+ * ```tsx
52
+ * <TimestampBadge timestamp="22:41:03" />
53
+ * // Renders: 22:41:03 in gray
54
+ * ```
55
+ */
56
+ export declare const TimestampBadge: import("react").NamedExoticComponent<ITimestampBadgeProps>;
57
+ /**
58
+ * Props for TagBadge component.
59
+ */
60
+ export interface ITagBadgeProps {
61
+ /** Tag string to display */
62
+ tag: string;
63
+ /** Optional custom class name */
64
+ className?: string;
65
+ }
66
+ /**
67
+ * Tag badge component (memoized).
68
+ *
69
+ * Displays a component tag (e.g., "API", "ROUTES").
70
+ * Truncates long tags to 12 characters.
71
+ *
72
+ * @example
73
+ * ```tsx
74
+ * <TagBadge tag="WORKSPACEMANAGER" />
75
+ * // Renders: [WORKSPACEMAN...] in cyan
76
+ * ```
77
+ */
78
+ export declare const TagBadge: import("react").NamedExoticComponent<ITagBadgeProps>;
79
+ /**
80
+ * Props for TagBadges component.
81
+ */
82
+ export interface ITagBadgesProps {
83
+ /** Array of tag strings */
84
+ tags: string[];
85
+ /** Optional custom class name */
86
+ className?: string;
87
+ }
88
+ /**
89
+ * Tag badges container component (memoized).
90
+ *
91
+ * Displays multiple tag badges with consistent spacing.
92
+ *
93
+ * @example
94
+ * ```tsx
95
+ * <TagBadges tags={['API', 'ROUTES']} />
96
+ * // Renders: [API][ROUTES] with spacing
97
+ * ```
98
+ */
99
+ export declare const TagBadges: import("react").NamedExoticComponent<ITagBadgesProps>;
100
+ /**
101
+ * Props for ContentTypeBadge component.
102
+ */
103
+ export interface IContentTypeBadgeProps {
104
+ /** Content type of the log entry */
105
+ contentType: TContentType;
106
+ /** HTTP method (GET, POST, etc.) — shown instead of generic "HTTP" label */
107
+ httpMethod?: string;
108
+ /** Optional custom class name */
109
+ className?: string;
110
+ }
111
+ /**
112
+ * Content type badge component (memoized).
113
+ *
114
+ * Displays a colored badge indicating the content type of a log entry
115
+ * (HTTP, JSON, TABLE, ERR). HTTP entries show the actual method
116
+ * (GET, POST, etc.) instead of a generic "HTTP" label.
117
+ *
118
+ * Returns null for 'plain' content type — no badge rendered.
119
+ *
120
+ * @example
121
+ * ```tsx
122
+ * <ContentTypeBadge contentType="http" httpMethod="GET" />
123
+ * // Renders: [GET] in cyan
124
+ *
125
+ * <ContentTypeBadge contentType="json" />
126
+ * // Renders: [JSON] in emerald
127
+ * ```
128
+ */
129
+ export declare const ContentTypeBadge: import("react").NamedExoticComponent<IContentTypeBadgeProps>;
130
+ /**
131
+ * Props for LogLineContainer component.
132
+ */
133
+ export interface ILogLineContainerProps {
134
+ /** Log level for styling */
135
+ level: TLogLevel;
136
+ /** Line number */
137
+ lineNumber: number;
138
+ /** Whether this is a continuation line */
139
+ isContinuation?: boolean;
140
+ /** Optional custom class name */
141
+ className?: string;
142
+ /** Child elements */
143
+ children: React.ReactNode;
144
+ }
145
+ /**
146
+ * Log line container component.
147
+ *
148
+ * Provides consistent styling and structure for log lines.
149
+ * Adds subtle hover effect and line number on hover.
150
+ *
151
+ * @example
152
+ * ```tsx
153
+ * <LogLineContainer level="info" lineNumber={42}>
154
+ * <LevelBadge level="info" />
155
+ * <span>Log message here</span>
156
+ * </LogLineContainer>
157
+ * ```
158
+ */
159
+ export declare function LogLineContainer({ level, lineNumber, isContinuation, className, children, }: ILogLineContainerProps): React.JSX.Element;
160
+ //# sourceMappingURL=LogLineBadges.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"LogLineBadges.d.ts","sourceRoot":"","sources":["../../../../../src/react-ui/blocks/Terminal/components/LogLineBadges.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;GAUG;AAKH,OAAO,KAAK,EAAE,SAAS,EAAE,YAAY,EAAE,MAAM,YAAY,CAAC;AAkB1D;;GAEG;AACH,MAAM,WAAW,gBAAgB;IAC/B,2BAA2B;IAC3B,KAAK,EAAE,SAAS,CAAC;IACjB,iCAAiC;IACjC,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB;AAED;;;;;;;;;;;GAWG;AACH,eAAO,MAAM,UAAU,wDAYrB,CAAC;AAEH;;GAEG;AACH,MAAM,WAAW,oBAAoB;IACnC,kCAAkC;IAClC,SAAS,EAAE,MAAM,CAAC;IAClB,iCAAiC;IACjC,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB;AAED;;;;;;;;;;;GAWG;AACH,eAAO,MAAM,cAAc,4DAiBzB,CAAC;AAEH;;GAEG;AACH,MAAM,WAAW,cAAc;IAC7B,4BAA4B;IAC5B,GAAG,EAAE,MAAM,CAAC;IACZ,iCAAiC;IACjC,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB;AAED;;;;;;;;;;;GAWG;AACH,eAAO,MAAM,QAAQ,sDAenB,CAAC;AAEH;;GAEG;AACH,MAAM,WAAW,eAAe;IAC9B,2BAA2B;IAC3B,IAAI,EAAE,MAAM,EAAE,CAAC;IACf,iCAAiC;IACjC,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB;AAED;;;;;;;;;;GAUG;AACH,eAAO,MAAM,SAAS,uDAUpB,CAAC;AA4BH;;GAEG;AACH,MAAM,WAAW,sBAAsB;IACrC,oCAAoC;IACpC,WAAW,EAAE,YAAY,CAAC;IAC1B,4EAA4E;IAC5E,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,iCAAiC;IACjC,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB;AAED;;;;;;;;;;;;;;;;;GAiBG;AACH,eAAO,MAAM,gBAAgB,8DAsB3B,CAAC;AAEH;;GAEG;AACH,MAAM,WAAW,sBAAsB;IACrC,4BAA4B;IAC5B,KAAK,EAAE,SAAS,CAAC;IACjB,kBAAkB;IAClB,UAAU,EAAE,MAAM,CAAC;IACnB,0CAA0C;IAC1C,cAAc,CAAC,EAAE,OAAO,CAAC;IACzB,iCAAiC;IACjC,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,qBAAqB;IACrB,QAAQ,EAAE,KAAK,CAAC,SAAS,CAAC;CAC3B;AAED;;;;;;;;;;;;;GAaG;AACH,wBAAgB,gBAAgB,CAAC,EAC/B,KAAK,EACL,UAAU,EACV,cAAsB,EACtB,SAAS,EACT,QAAQ,GACT,EAAE,sBAAsB,GAAG,KAAK,CAAC,GAAG,CAAC,OAAO,CAiB5C"}
@@ -0,0 +1,185 @@
1
+ 'use client';
2
+
3
+ import { cn } from "../../../lib/utils.js";
4
+ import { memo } from "react";
5
+ import { jsx } from "react/jsx-runtime";
6
+
7
+ //#region src/react-ui/blocks/Terminal/components/LogLineBadges.tsx
8
+ /**
9
+ * React badge components for log lines.
10
+ *
11
+ * Styled badge components using Tailwind CSS for the React log viewer.
12
+ * Provides level badges, timestamp badges, and tag badges with consistent
13
+ * Synthwave Dark theme styling.
14
+ *
15
+ * All badge components are memoized for optimal performance.
16
+ *
17
+ * @module components/devenv/terminal/LogLineBadges
18
+ */
19
+ /**
20
+ * Level badge color mapping.
21
+ *
22
+ * Maps each log level to its corresponding Tailwind color classes.
23
+ */
24
+ const LEVEL_COLORS = {
25
+ info: "bg-blue-500/15 text-blue-400 border-blue-500/25 shadow-[0_0_6px_rgba(59,130,246,0.15)]",
26
+ warn: "bg-yellow-500/15 text-yellow-400 border-yellow-500/25 shadow-[0_0_6px_rgba(234,179,8,0.15)]",
27
+ error: "bg-red-500/20 text-red-400 border-red-500/30 shadow-[0_0_8px_rgba(239,68,68,0.2)]",
28
+ fatal: "bg-pink-500/20 text-pink-400 border-pink-500/30 shadow-[0_0_8px_rgba(236,72,153,0.2)]",
29
+ debug: "bg-cyan-500/15 text-cyan-400 border-cyan-500/25 shadow-[0_0_6px_rgba(6,182,212,0.15)]",
30
+ trace: "bg-gray-500/10 text-gray-400 border-gray-500/20",
31
+ unknown: "bg-gray-500/8 text-gray-500 border-gray-500/15"
32
+ };
33
+ /**
34
+ * Level badge component (memoized).
35
+ *
36
+ * Displays a colored badge with the log level label.
37
+ * Uses Synthwave Dark theme colors with glassmorphic effect.
38
+ *
39
+ * @example
40
+ * ```tsx
41
+ * <LevelBadge level="info" />
42
+ * // Renders: [INFO] with blue background
43
+ * ```
44
+ */
45
+ const LevelBadge = memo(function LevelBadge({ level, className }) {
46
+ return /* @__PURE__ */ jsx("span", {
47
+ className: cn("px-2 py-0.5 rounded border font-mono text-[10px] font-bold tracking-wider", LEVEL_COLORS[level], className),
48
+ children: level.toUpperCase()
49
+ });
50
+ });
51
+ /**
52
+ * Timestamp badge component (memoized).
53
+ *
54
+ * Displays a timestamp with muted styling.
55
+ * Uses tabular numbers for consistent alignment.
56
+ *
57
+ * @example
58
+ * ```tsx
59
+ * <TimestampBadge timestamp="22:41:03" />
60
+ * // Renders: 22:41:03 in gray
61
+ * ```
62
+ */
63
+ const TimestampBadge = memo(function TimestampBadge({ timestamp, className }) {
64
+ const timeOnly = timestamp.includes(".") ? timestamp.split(".")[0] : timestamp;
65
+ return /* @__PURE__ */ jsx("span", {
66
+ className: cn("ml-auto text-muted-foreground font-mono text-xs tabular-nums", "opacity-70", className),
67
+ children: timeOnly
68
+ });
69
+ });
70
+ /**
71
+ * Tag badge component (memoized).
72
+ *
73
+ * Displays a component tag (e.g., "API", "ROUTES").
74
+ * Truncates long tags to 12 characters.
75
+ *
76
+ * @example
77
+ * ```tsx
78
+ * <TagBadge tag="WORKSPACEMANAGER" />
79
+ * // Renders: [WORKSPACEMAN...] in cyan
80
+ * ```
81
+ */
82
+ const TagBadge = memo(function TagBadge({ tag, className }) {
83
+ const displayTag = tag.length > 12 ? tag.slice(0, 9) + "..." : tag;
84
+ return /* @__PURE__ */ jsx("span", {
85
+ className: cn("px-1.5 py-0.5 rounded border font-mono text-xs", "bg-purple-500/10 text-purple-400 border-purple-500/20", className),
86
+ children: displayTag
87
+ });
88
+ });
89
+ /**
90
+ * Tag badges container component (memoized).
91
+ *
92
+ * Displays multiple tag badges with consistent spacing.
93
+ *
94
+ * @example
95
+ * ```tsx
96
+ * <TagBadges tags={['API', 'ROUTES']} />
97
+ * // Renders: [API][ROUTES] with spacing
98
+ * ```
99
+ */
100
+ const TagBadges = memo(function TagBadges({ tags, className }) {
101
+ if (!tags || tags.length === 0) return null;
102
+ return /* @__PURE__ */ jsx("span", {
103
+ className: cn("flex items-center gap-1", className),
104
+ children: tags.map((tag) => /* @__PURE__ */ jsx(TagBadge, { tag }, tag))
105
+ });
106
+ });
107
+ /**
108
+ * Content type badge color and label mapping.
109
+ *
110
+ * Maps each content type to its display label and Tailwind color classes.
111
+ * 'plain' entries are hidden (no badge rendered).
112
+ */
113
+ const CONTENT_TYPE_STYLES = {
114
+ plain: {
115
+ label: "",
116
+ className: ""
117
+ },
118
+ http: {
119
+ label: "HTTP",
120
+ className: "bg-cyan-500/15 text-cyan-400 border-cyan-500/25 shadow-[0_0_6px_rgba(6,182,212,0.15)]"
121
+ },
122
+ json: {
123
+ label: "JSON",
124
+ className: "bg-emerald-500/15 text-emerald-400 border-emerald-500/25 shadow-[0_0_6px_rgba(16,185,129,0.15)]"
125
+ },
126
+ table: {
127
+ label: "TABLE",
128
+ className: "bg-violet-500/15 text-violet-400 border-violet-500/25 shadow-[0_0_6px_rgba(139,92,246,0.15)]"
129
+ },
130
+ error: {
131
+ label: "ERR",
132
+ className: "bg-red-500/20 text-red-400 border-red-500/30 shadow-[0_0_8px_rgba(239,68,68,0.2)]"
133
+ }
134
+ };
135
+ /**
136
+ * Content type badge component (memoized).
137
+ *
138
+ * Displays a colored badge indicating the content type of a log entry
139
+ * (HTTP, JSON, TABLE, ERR). HTTP entries show the actual method
140
+ * (GET, POST, etc.) instead of a generic "HTTP" label.
141
+ *
142
+ * Returns null for 'plain' content type — no badge rendered.
143
+ *
144
+ * @example
145
+ * ```tsx
146
+ * <ContentTypeBadge contentType="http" httpMethod="GET" />
147
+ * // Renders: [GET] in cyan
148
+ *
149
+ * <ContentTypeBadge contentType="json" />
150
+ * // Renders: [JSON] in emerald
151
+ * ```
152
+ */
153
+ const ContentTypeBadge = memo(function ContentTypeBadge({ contentType, httpMethod, className }) {
154
+ if (contentType === "plain" || !contentType) return null;
155
+ const style = CONTENT_TYPE_STYLES[contentType];
156
+ const label = contentType === "http" && httpMethod ? httpMethod.toUpperCase() : style.label;
157
+ return /* @__PURE__ */ jsx("span", {
158
+ className: cn("px-1.5 py-0.5 rounded border font-mono text-[10px] font-bold tracking-wider", style.className, className),
159
+ children: label
160
+ });
161
+ });
162
+ /**
163
+ * Log line container component.
164
+ *
165
+ * Provides consistent styling and structure for log lines.
166
+ * Adds subtle hover effect and line number on hover.
167
+ *
168
+ * @example
169
+ * ```tsx
170
+ * <LogLineContainer level="info" lineNumber={42}>
171
+ * <LevelBadge level="info" />
172
+ * <span>Log message here</span>
173
+ * </LogLineContainer>
174
+ * ```
175
+ */
176
+ function LogLineContainer({ level, lineNumber, isContinuation = false, className, children }) {
177
+ return /* @__PURE__ */ jsx("div", {
178
+ className: cn("group flex items-start gap-2 py-0.5 px-2 rounded-sm", "hover:bg-white/5 transition-colors duration-150", "border-l-2", isContinuation ? "border-transparent ml-6" : "border-transparent", `hover:border-${level === "error" || level === "fatal" ? "red" : level === "warn" ? "yellow" : "blue"}-500/50`, className),
179
+ title: `Line ${lineNumber}`,
180
+ children
181
+ });
182
+ }
183
+
184
+ //#endregion
185
+ export { ContentTypeBadge, LevelBadge, LogLineContainer, TagBadge, TagBadges, TimestampBadge };
@@ -0,0 +1,48 @@
1
+ /**
2
+ * Specialized syntax highlighter for different log content types.
3
+ *
4
+ * Provides syntax highlighting for HTTP requests, tables, and JSON
5
+ * with appropriate styling for each type.
6
+ *
7
+ * @module components/devenv/terminal/SpecializedSyntaxHighlighter
8
+ */
9
+ /**
10
+ * Props for specialized syntax highlighting.
11
+ */
12
+ export interface ISpecializedSyntaxHighlighterProps {
13
+ /** Content type */
14
+ contentType?: 'plain' | 'http' | 'json' | 'table' | 'error';
15
+ /** HTTP method (for HTTP content) */
16
+ httpMethod?: string;
17
+ /** HTTP path (for HTTP content) */
18
+ httpPath?: string;
19
+ /** Table data (for table content) */
20
+ tableData?: unknown;
21
+ /** JSON data (for JSON content) */
22
+ jsonData?: Record<string, unknown> | unknown;
23
+ /** Raw text to highlight */
24
+ text: string;
25
+ /** Optional custom class name */
26
+ className?: string;
27
+ }
28
+ /**
29
+ * Specialized syntax highlighter component.
30
+ *
31
+ * Applies appropriate highlighting based on content type:
32
+ * - HTTP: pink method, cyan path
33
+ * - JSON: structured syntax highlighting
34
+ * - Table: borders in gray, content in colors
35
+ * - Plain: default highlighting
36
+ *
37
+ * @example
38
+ * ```tsx
39
+ * <SpecializedSyntaxHighlighter
40
+ * contentType="http"
41
+ * httpMethod="GET"
42
+ * httpPath="/api/endpoint"
43
+ * text="GET /api/endpoint {"
44
+ * />
45
+ * ```
46
+ */
47
+ export declare function SpecializedSyntaxHighlighter({ contentType, httpMethod: _httpMethod, httpPath: _httpPath, tableData: _tableData, jsonData, text, className, }: ISpecializedSyntaxHighlighterProps): React.JSX.Element;
48
+ //# sourceMappingURL=SpecializedSyntaxHighlighter.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"SpecializedSyntaxHighlighter.d.ts","sourceRoot":"","sources":["../../../../../src/react-ui/blocks/Terminal/components/SpecializedSyntaxHighlighter.tsx"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AASH;;GAEG;AACH,MAAM,WAAW,kCAAkC;IACjD,mBAAmB;IACnB,WAAW,CAAC,EAAE,OAAO,GAAG,MAAM,GAAG,MAAM,GAAG,OAAO,GAAG,OAAO,CAAC;IAE5D,qCAAqC;IACrC,UAAU,CAAC,EAAE,MAAM,CAAC;IAEpB,mCAAmC;IACnC,QAAQ,CAAC,EAAE,MAAM,CAAC;IAElB,qCAAqC;IACrC,SAAS,CAAC,EAAE,OAAO,CAAC;IAEpB,mCAAmC;IACnC,QAAQ,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,GAAG,OAAO,CAAC;IAE7C,4BAA4B;IAC5B,IAAI,EAAE,MAAM,CAAC;IAEb,iCAAiC;IACjC,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB;AAMD;;;;;;;;;;;;;;;;;;GAkBG;AACH,wBAAgB,4BAA4B,CAAC,EAC3C,WAAqB,EACrB,UAAU,EAAE,WAAW,EACvB,QAAQ,EAAE,SAAS,EACnB,SAAS,EAAE,UAAU,EACrB,QAAQ,EACR,IAAI,EACJ,SAAS,GACV,EAAE,kCAAkC,GAAG,KAAK,CAAC,GAAG,CAAC,OAAO,CAsBxD"}