Skip to content
Toggle navigation
Toggle navigation
This project
Loading...
Sign in
Administrator
/
chatgpt.ai-pro.org
Go to a project
Toggle navigation
Toggle navigation pinning
Projects
Groups
Snippets
Help
Project
Activity
Repository
Pipelines
Graphs
Issues
0
Merge Requests
3
Wiki
Network
Create a new issue
Builds
Commits
Issue Boards
Files
Commits
Network
Compare
Branches
Tags
96e58f60
authored
2023-02-09 09:26:20 +0800
by
RSA
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
fix
1 parent
b14db9b8
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
28 additions
and
5 deletions
client/src/App.js
client/src/color_theme_1.css
client/src/App.js
View file @
96e58f6
...
...
@@ -101,12 +101,11 @@ function App() {
}
setChatLog
([...
chatLogNew
,
{
user
:
"gpt"
,
message
:
`
${
replaceTags
}
`
}
])
// setChatLog([...chatLogNew, { user: "gpt", message: `<div>${parsedData}</div>`} ])
var
scrollToTheBottomChatLog
=
document
.
getElementsByClassName
(
"chat-log"
)[
0
];
scrollToTheBottomChatLog
.
scrollTop
=
scrollToTheBottomChatLog
.
scrollHeight
;
}
catch
(
error
)
{
const
errorMsg
=
"We a
re currently experiencing heavy flow as of the moment, p
lease try again."
;
setChatLog
([...
chatLogNew
,
{
user
:
"gpt"
,
message
:
`<div class="errormsg">
${
errorMsg
}
</div>`
}
])
const
errorMsg
=
"We a
pologize for any inconvenience caused due to the delay in the response time. P
lease try again."
;
setChatLog
([...
chatLogNew
,
{
user
:
"gpt"
,
message
:
`<div class="errormsg">
<span>i</span><div class="msg">
${
errorMsg
}
</div>
</div>`
}
])
// res.status(500).send(error || 'Something went wrong');
}
}
...
...
client/src/color_theme_1.css
View file @
96e58f6
...
...
@@ -3,10 +3,30 @@
}
.errormsg
{
border
:
1px
solid
red
;
border
:
1px
solid
#7ac5ff
;
padding
:
15px
25px
;
border-radius
:
10px
;
background
:
rgb
(
255
0
0
/
15%
);
background
:
rgb
(
0
139
245
/
6%
);
}
.errormsg
.msg
{
display
:
inline-block
;
width
:
90%
;
font-weight
:
600
;
}
.errormsg
span
{
background
:
#008BF5
;
padding
:
3px
12px
;
border-radius
:
50px
;
width
:
30px
;
height
:
30px
;
margin-right
:
10px
;
color
:
#fff
;
font-weight
:
900
;
display
:
inline-block
;
vertical-align
:
top
;
font-family
:
auto
;
font-size
:
20px
;
}
.side-menu-button
{
...
...
@@ -182,6 +202,10 @@ code br:nth-child(-n+2) {
.message
{
font-size
:
14px
;
}
.errormsg
{
padding
:
10px
;
width
:
80%
;
}
.chat-message-center
{
padding
:
20px
5vw
!important
;
}
...
...
Write
Preview
Styling with
Markdown
is supported
Attach a file
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to post a comment