fix: copied logs line break (#2603)

This commit is contained in:
Louis 2024-04-04 10:57:37 +07:00 committed by GitHub
parent c4da1cbc90
commit 7f92a5aef0
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
3 changed files with 3 additions and 3 deletions

View File

@ -45,7 +45,7 @@ const AppLogs = () => {
themes="outline" themes="outline"
className="bg-white dark:bg-secondary/50" className="bg-white dark:bg-secondary/50"
onClick={() => { onClick={() => {
clipboard.copy(logs.slice(-50) ?? '') clipboard.copy(logs.slice(-50).join('\n') ?? '')
}} }}
> >
<div className="flex items-center space-x-2"> <div className="flex items-center space-x-2">

View File

@ -32,7 +32,7 @@ const DeviceSpecs = () => {
themes="outline" themes="outline"
className="bg-white dark:bg-secondary/50" className="bg-white dark:bg-secondary/50"
onClick={() => { onClick={() => {
clipboard.copy(logs ?? '') clipboard.copy(logs.join('\n') ?? '')
}} }}
> >
<div className="flex items-center space-x-2"> <div className="flex items-center space-x-2">

View File

@ -75,7 +75,7 @@ const ServerLogs = (props: ServerLogsProps) => {
themes="outline" themes="outline"
className="bg-white dark:bg-secondary/50" className="bg-white dark:bg-secondary/50"
onClick={() => { onClick={() => {
clipboard.copy(logs.slice(-100) ?? '') clipboard.copy(logs.slice(-100).join('\n') ?? '')
}} }}
> >
<div className="flex items-center space-x-2"> <div className="flex items-center space-x-2">