From 4b100bd8716009e4f6bc4d26ba2e49c09008bc0e Mon Sep 17 00:00:00 2001 From: Ashley Johnson <61059402+PapaRascal2020@users.noreply.github.com> Date: Fri, 27 Sep 2024 15:52:45 +0100 Subject: [PATCH] More refactoring of Playground code - Extracted User and Bot Messages --- .../Components/sidekick-bot-message.blade.php | 17 +++++++ .../sidekick-user-message.blade.php | 10 ++++ .../resources/views/Pages/chatroom.blade.php | 50 ++++++------------- 3 files changed, 42 insertions(+), 35 deletions(-) create mode 100644 stubs/default/resources/views/Components/sidekick-bot-message.blade.php create mode 100644 stubs/default/resources/views/Components/sidekick-user-message.blade.php diff --git a/stubs/default/resources/views/Components/sidekick-bot-message.blade.php b/stubs/default/resources/views/Components/sidekick-bot-message.blade.php new file mode 100644 index 0000000..4f1fc99 --- /dev/null +++ b/stubs/default/resources/views/Components/sidekick-bot-message.blade.php @@ -0,0 +1,17 @@ +
+ Assistant
+{{ $slot }}
++ User
+{{ $slot }}
+- @include('Components.user') User
-{!! $message['content'] !!}
-- @include('Components.bot') Assistant
-{!! nl2br($message['content']) !!}
-- @include('Components.user') User
-${message}
-- @include('Components.bot') Assistant
- -- @include('Components.bot') Assistant
-${response}
-