mirror of
https://github.com/hpware/news-analyze.git
synced 2025-06-25 05:44:23 +00:00
Compare commits
No commits in common. "ad0f13a1a25a149963227bd632e4ff7c543ae5b3" and "075e33d2af112129413c5018eb12634c4fdc708e" have entirely different histories.
ad0f13a1a2
...
075e33d2af
3 changed files with 2 additions and 23 deletions
|
@ -81,15 +81,7 @@ const updateContent = async (url: string, tabAction: boolean) => {
|
||||||
const req = await fetch(`/api/home/lt?query=${url.trim()}`);
|
const req = await fetch(`/api/home/lt?query=${url.trim()}`);
|
||||||
const data = await req.json();
|
const data = await req.json();
|
||||||
if (data) {
|
if (data) {
|
||||||
// Made by coderabbit: https://github.com/hpware/news-analyze/pull/6#discussion_r2144713017
|
contentArray.value = [...data.uuidData, ...(data.nuuiddata?.items || [])];
|
||||||
const coolArray = [
|
|
||||||
...(data.uuidData ?? []),
|
|
||||||
...(data.nuuiddata?.items ?? []),
|
|
||||||
];
|
|
||||||
contentArray.value =
|
|
||||||
coolArray.sort(
|
|
||||||
(title1, title2) => title2.publishTimeUnix - title1.publishTimeUnix,
|
|
||||||
) || [];
|
|
||||||
switchTabs.value = false;
|
switchTabs.value = false;
|
||||||
isDataCached.value = data.cached || false;
|
isDataCached.value = data.cached || false;
|
||||||
displayTranslateContent.value = false;
|
displayTranslateContent.value = false;
|
||||||
|
|
|
@ -43,11 +43,6 @@ const validateUserInfo = async () => {
|
||||||
isLoggedIn.value = true;
|
isLoggedIn.value = true;
|
||||||
};
|
};
|
||||||
|
|
||||||
const intervalTime = 1000 * 60 * 2; // Validate user Info for every ten min while the admin page is opened.
|
|
||||||
setInterval(async () => {
|
|
||||||
await validateUserInfo();
|
|
||||||
}, intervalTime);
|
|
||||||
|
|
||||||
const emit = defineEmits(["windowopener"]);
|
const emit = defineEmits(["windowopener"]);
|
||||||
|
|
||||||
const logoutAction = async () => {
|
const logoutAction = async () => {
|
||||||
|
@ -101,7 +96,6 @@ const showDeleteDialog = ref(false);
|
||||||
const showLogoutDialog = ref(false);
|
const showLogoutDialog = ref(false);
|
||||||
const confirmDelete = async () => {
|
const confirmDelete = async () => {
|
||||||
await deleteAccount();
|
await deleteAccount();
|
||||||
await validateUserInfo();
|
|
||||||
showDeleteDialog.value = false;
|
showDeleteDialog.value = false;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
|
@ -132,14 +132,7 @@ useSeoMeta({
|
||||||
<TooltipProvider>
|
<TooltipProvider>
|
||||||
<Tooltip>
|
<Tooltip>
|
||||||
<TooltipTrigger>
|
<TooltipTrigger>
|
||||||
<NuxtLink
|
<NuxtLink :to="localePath('/desktop?openapp=onboard')">
|
||||||
:to="
|
|
||||||
localePath({
|
|
||||||
path: '/desktop',
|
|
||||||
query: { openapp: 'onboard' },
|
|
||||||
})
|
|
||||||
"
|
|
||||||
>
|
|
||||||
<button
|
<button
|
||||||
class="m-4 mr-1 ml-1 bg-[#8C9393] text-white p-3 rounded-[10px] bg-gradient-to-l from-sky-500 to-purple-600 transition-all duration-150 hover:transform hover:scale-105 hover:shadow-lg"
|
class="m-4 mr-1 ml-1 bg-[#8C9393] text-white p-3 rounded-[10px] bg-gradient-to-l from-sky-500 to-purple-600 transition-all duration-150 hover:transform hover:scale-105 hover:shadow-lg"
|
||||||
>
|
>
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue