X-Git-Url: http://these/git/?a=blobdiff_plain;f=src%2Fshared%2Fcomponents%2Fperson%2Fprofile.tsx;h=cc334db5ee5449381c02fad9fa08981e879ae754;hb=9869b911cf480ee88c7b1e7d2f689cc2e1c65157;hp=b6a3200d62bf833dd0316878711e160b2eceeee2;hpb=02ffa85b589ea630b259f6c2617b399e05972716;p=lemmy-ui.git diff --git a/src/shared/components/person/profile.tsx b/src/shared/components/person/profile.tsx index b6a3200..cc334db 100644 --- a/src/shared/components/person/profile.tsx +++ b/src/shared/components/person/profile.tsx @@ -1,4 +1,30 @@ +import { + editComment, + editPost, + editWith, + enableDownvotes, + enableNsfw, + getCommentParentId, + myAuth, + myAuthRequired, + setIsoData, + updatePersonBlock, +} from "@utils/app"; +import { restoreScrollPosition, saveScrollPosition } from "@utils/browser"; +import { + capitalizeFirstLetter, + futureDaysToUnixTime, + getPageFromString, + getQueryParams, + getQueryString, + numToSI, +} from "@utils/helpers"; +import { canMod, isAdmin, isBanned } from "@utils/roles"; +import type { QueryParams } from "@utils/types"; +import { RouteDataResponse } from "@utils/types"; import classNames from "classnames"; +import format from "date-fns/format"; +import parseISO from "date-fns/parseISO"; import { NoOptionI18nKeys } from "i18next"; import { Component, linkEvent } from "inferno"; import { Link } from "inferno-router"; @@ -46,46 +72,19 @@ import { SortType, TransferCommunity, } from "lemmy-js-client"; -import moment from "moment"; -import { i18n } from "../../i18next"; +import { fetchLimit, relTags } from "../../config"; import { InitialFetchRequest, PersonDetailsView } from "../../interfaces"; -import { UserService } from "../../services"; -import { FirstLoadService } from "../../services/FirstLoadService"; +import { mdToHtml } from "../../markdown"; +import { FirstLoadService, I18NextService, UserService } from "../../services"; import { HttpService, RequestState } from "../../services/HttpService"; -import { - capitalizeFirstLetter, - editComment, - editPost, - editWith, - enableDownvotes, - enableNsfw, - fetchLimit, - futureDaysToUnixTime, - getCommentParentId, - getPageFromString, - mdToHtml, - myAuth, - myAuthRequired, - numToSI, - relTags, - restoreScrollPosition, - saveScrollPosition, - setIsoData, - setupTippy, - toast, - updatePersonBlock, -} from "../../utils"; -import { getQueryParams } from "../../utils/helpers/get-query-params"; -import { getQueryString } from "../../utils/helpers/get-query-string"; -import { canMod } from "../../utils/roles/can-mod"; -import { isAdmin } from "../../utils/roles/is-admin"; -import { isBanned } from "../../utils/roles/is-banned"; -import type { QueryParams } from "../../utils/types/query-params"; +import { setupTippy } from "../../tippy"; +import { toast } from "../../toast"; import { BannerIconHeader } from "../common/banner-icon-header"; import { HtmlTags } from "../common/html-tags"; import { Icon, Spinner } from "../common/icon"; import { MomentTime } from "../common/moment-time"; import { SortSelect } from "../common/sort-select"; +import { UserBadges } from "../common/user-badges"; import { CommunityLink } from "../community/community-link"; import { PersonDetails } from "./person-details"; import { PersonListing } from "./person-listing"; @@ -138,7 +137,7 @@ const getCommunitiesListing = ( communityViews.length > 0 && (