This pull request introduces a new PlaygroundButton component to the flow toolbar in the frontend. The PlaygroundButton component replaces the existing logic for displaying the playground button, providing a cleaner and more modular implementation.
This PR also fixes a bug in which the icon on Playground was the old one when we didn't have ChatInput or ChatOutput on Canvas.
Key changes include:
New Component Addition:
Added PlaygroundButton component in src/frontend/src/components/flowToolbarComponent/components/playground-button.tsx. This component handles the display logic for the playground button, including active and disabled states.
Integration with Flow Toolbar:
Updated FlowToolbar component in src/frontend/src/components/flowToolbarComponent/index.tsx to use the new PlaygroundButton component instead of directly embedding the button logic. [1][2]
Styling Adjustments:
Added new CSS class .playground-btn-flow-toolbar to src/frontend/src/style/applies.css to style the playground button within the toolbar.
This pull request introduces a new
PlaygroundButton
component to the flow toolbar in the frontend. ThePlaygroundButton
component replaces the existing logic for displaying the playground button, providing a cleaner and more modular implementation.This PR also fixes a bug in which the icon on Playground was the old one when we didn't have ChatInput or ChatOutput on Canvas.
Key changes include:
New Component Addition:
PlaygroundButton
component insrc/frontend/src/components/flowToolbarComponent/components/playground-button.tsx
. This component handles the display logic for the playground button, including active and disabled states.Integration with Flow Toolbar:
FlowToolbar
component insrc/frontend/src/components/flowToolbarComponent/index.tsx
to use the newPlaygroundButton
component instead of directly embedding the button logic. [1] [2]Styling Adjustments:
.playground-btn-flow-toolbar
tosrc/frontend/src/style/applies.css
to style the playground button within the toolbar.