mirror of
https://github.com/PrimalHQ/primal-web-app.git
synced 2024-10-03 02:10:55 +00:00
Fix profile linking from follower lists
This commit is contained in:
parent
729af39c48
commit
56e06d81dc
@ -25,7 +25,7 @@ import { shortDate } from '../lib/dates';
|
|||||||
import styles from './Profile.module.scss';
|
import styles from './Profile.module.scss';
|
||||||
import StickySidebar from '../components/StickySidebar/StickySidebar';
|
import StickySidebar from '../components/StickySidebar/StickySidebar';
|
||||||
import ProfileSidebar from '../components/ProfileSidebar/ProfileSidebar';
|
import ProfileSidebar from '../components/ProfileSidebar/ProfileSidebar';
|
||||||
import { MenuItem, VanityProfiles } from '../types/primal';
|
import { MenuItem, PrimalUser, VanityProfiles } from '../types/primal';
|
||||||
import PageTitle from '../components/PageTitle/PageTitle';
|
import PageTitle from '../components/PageTitle/PageTitle';
|
||||||
import FollowButton from '../components/FollowButton/FollowButton';
|
import FollowButton from '../components/FollowButton/FollowButton';
|
||||||
import Search from '../components/Search/Search';
|
import Search from '../components/Search/Search';
|
||||||
@ -42,6 +42,7 @@ import VerificationCheck from '../components/VerificationCheck/VerificationCheck
|
|||||||
|
|
||||||
import PhotoSwipeLightbox from 'photoswipe/lightbox';
|
import PhotoSwipeLightbox from 'photoswipe/lightbox';
|
||||||
import NoteImage from '../components/NoteImage/NoteImage';
|
import NoteImage from '../components/NoteImage/NoteImage';
|
||||||
|
import { createStore } from 'solid-js/store';
|
||||||
|
|
||||||
const Profile: Component = () => {
|
const Profile: Component = () => {
|
||||||
|
|
||||||
@ -96,6 +97,20 @@ const Profile: Component = () => {
|
|||||||
return hex;
|
return hex;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
let firstTime = true;
|
||||||
|
|
||||||
|
createEffect(() => {
|
||||||
|
const npub = params.npub;
|
||||||
|
|
||||||
|
if (firstTime && npub) {
|
||||||
|
firstTime = false;
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
setProfile(getHex());
|
||||||
|
|
||||||
|
})
|
||||||
|
|
||||||
const setProfile = (hex: string | undefined) => {
|
const setProfile = (hex: string | undefined) => {
|
||||||
profile?.actions.setProfileKey(hex);
|
profile?.actions.setProfileKey(hex);
|
||||||
|
|
||||||
@ -454,7 +469,6 @@ const Profile: Component = () => {
|
|||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|
||||||
onMount(() => {
|
onMount(() => {
|
||||||
lightbox.init();
|
lightbox.init();
|
||||||
});
|
});
|
||||||
|
Loading…
Reference in New Issue
Block a user