Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
T
thecybernanny-webapp
Project
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
asranov0003
thecybernanny-webapp
Commits
ca6a7e36
Commit
ca6a7e36
authored
Jul 23, 2025
by
asranov0003
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
refactor: browser history loading and data
parent
abaf3077
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
22 additions
and
17 deletions
+22
-17
BrowserHistory.tsx
src/pages/BrowserHistory/BrowserHistory.tsx
+22
-17
No files found.
src/pages/BrowserHistory/BrowserHistory.tsx
View file @
ca6a7e36
...
...
@@ -10,6 +10,7 @@ import {
}
from
"../../stores/store"
;
import
{
fetchBrowserHistory
}
from
"../../stores/slices/browserHistorySlice"
;
import
{
useTranslation
}
from
"react-i18next"
;
import
CLoading
from
"../../components/CLoading"
;
const
BrowserHistory
:
React
.
FC
=
()
=>
{
const
today
=
new
Date
().
toISOString
().
split
(
"T"
)[
0
];
...
...
@@ -52,28 +53,32 @@ const BrowserHistory: React.FC = () => {
<
MdInfoOutline
className=
"browserhistory__content__header__icon"
/>
</
div
>
{
loading
&&
<
p
>
{
t
(
"common.loading"
)
}
</
p
>
}
{
loading
&&
(
<
div
className=
"cloading__center"
>
<
CLoading
/>
</
div
>
)
}
{
error
&&
<
p
className=
"text-danger"
>
{
error
}
</
p
>
}
{
browserHistories
.
length
>
0
?
(
<
div
className=
"browserhistory__list"
>
{
browserHistories
.
map
((
history
,
index
)
=>
{
return
(
<
div
className=
"browserhistory__item"
key=
{
index
}
>
<
p
className=
"browserhistory__item__title"
>
{
t
(
"browserHistory.website"
)
}
:
{
history
.
name
}
</
p
>
<
p
>
{
t
(
"browserHistory.date"
)
}
:
{
history
.
date
}
</
p
>
</
div
>
);
})
}
</
div
>
)
:
(
{
browserHistories
.
length
===
0
&&
!
loading
&&
(
<
p
>
{
t
(
"browserHistory.empty"
)
}
</
p
>
)
}
<
div
className=
"browserhistory__list"
>
{
browserHistories
.
map
((
history
,
index
)
=>
{
return
(
<
div
className=
"browserhistory__item"
key=
{
index
}
>
<
p
className=
"browserhistory__item__title"
>
{
t
(
"browserHistory.website"
)
}
:
{
history
.
name
}
</
p
>
<
p
>
{
t
(
"browserHistory.date"
)
}
:
{
history
.
date
}
</
p
>
</
div
>
);
})
}
</
div
>
</
div
>
<
div
className=
"browserhistory__filter"
>
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
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 comment