@lokalise/harmony 2.1.0-exp-testingContracts.5 → 2.1.0-exp-testingContracts.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/harmony103.cjs +1 -1
- package/dist/harmony103.mjs +1 -1
- package/dist/harmony104.cjs +7 -7
- package/dist/harmony104.mjs +7 -7
- package/dist/harmony107.cjs +1 -1
- package/dist/harmony107.mjs +1 -1
- package/dist/harmony108.cjs +1 -1
- package/dist/harmony108.mjs +1 -1
- package/dist/harmony109.cjs +11 -14
- package/dist/harmony109.cjs.map +1 -1
- package/dist/harmony109.mjs +11 -14
- package/dist/harmony109.mjs.map +1 -1
- package/dist/harmony110.cjs +22 -4
- package/dist/harmony110.cjs.map +1 -1
- package/dist/harmony110.mjs +21 -3
- package/dist/harmony110.mjs.map +1 -1
- package/dist/harmony111.cjs +13 -17
- package/dist/harmony111.cjs.map +1 -1
- package/dist/harmony111.mjs +13 -17
- package/dist/harmony111.mjs.map +1 -1
- package/dist/harmony112.cjs +3 -76
- package/dist/harmony112.cjs.map +1 -1
- package/dist/harmony112.mjs +3 -76
- package/dist/harmony112.mjs.map +1 -1
- package/dist/harmony113.cjs +17 -11
- package/dist/harmony113.cjs.map +1 -1
- package/dist/harmony113.mjs +17 -11
- package/dist/harmony113.mjs.map +1 -1
- package/dist/harmony114.cjs +76 -34
- package/dist/harmony114.cjs.map +1 -1
- package/dist/harmony114.mjs +76 -34
- package/dist/harmony114.mjs.map +1 -1
- package/dist/harmony115.cjs +12 -9
- package/dist/harmony115.cjs.map +1 -1
- package/dist/harmony115.mjs +12 -9
- package/dist/harmony115.mjs.map +1 -1
- package/dist/harmony116.cjs +34 -47
- package/dist/harmony116.cjs.map +1 -1
- package/dist/harmony116.mjs +34 -47
- package/dist/harmony116.mjs.map +1 -1
- package/dist/harmony117.cjs +10 -10
- package/dist/harmony117.cjs.map +1 -1
- package/dist/harmony117.mjs +9 -9
- package/dist/harmony117.mjs.map +1 -1
- package/dist/harmony118.cjs +45 -9
- package/dist/harmony118.cjs.map +1 -1
- package/dist/harmony118.mjs +47 -11
- package/dist/harmony118.mjs.map +1 -1
- package/dist/harmony119.cjs +8 -20
- package/dist/harmony119.cjs.map +1 -1
- package/dist/harmony119.mjs +8 -20
- package/dist/harmony119.mjs.map +1 -1
- package/dist/harmony122.cjs +84 -96
- package/dist/harmony122.cjs.map +1 -1
- package/dist/harmony122.mjs +84 -79
- package/dist/harmony122.mjs.map +1 -1
- package/dist/harmony123.cjs +30 -20
- package/dist/harmony123.cjs.map +1 -1
- package/dist/harmony123.mjs +30 -20
- package/dist/harmony123.mjs.map +1 -1
- package/dist/harmony124.cjs +20 -7
- package/dist/harmony124.cjs.map +1 -1
- package/dist/harmony124.mjs +20 -7
- package/dist/harmony124.mjs.map +1 -1
- package/dist/harmony125.cjs +6 -16
- package/dist/harmony125.cjs.map +1 -1
- package/dist/harmony125.mjs +7 -17
- package/dist/harmony125.mjs.map +1 -1
- package/dist/harmony126.cjs +16 -7
- package/dist/harmony126.cjs.map +1 -1
- package/dist/harmony126.mjs +16 -7
- package/dist/harmony126.mjs.map +1 -1
- package/dist/harmony127.cjs +3 -3
- package/dist/harmony127.cjs.map +1 -1
- package/dist/harmony127.mjs +3 -3
- package/dist/harmony127.mjs.map +1 -1
- package/dist/harmony128.cjs +7 -14
- package/dist/harmony128.cjs.map +1 -1
- package/dist/harmony128.mjs +7 -14
- package/dist/harmony128.mjs.map +1 -1
- package/dist/harmony129.cjs +14 -86
- package/dist/harmony129.cjs.map +1 -1
- package/dist/harmony129.mjs +14 -86
- package/dist/harmony129.mjs.map +1 -1
- package/dist/harmony130.cjs +98 -29
- package/dist/harmony130.cjs.map +1 -1
- package/dist/harmony130.mjs +81 -29
- package/dist/harmony130.mjs.map +1 -1
- package/dist/harmony131.cjs +9 -5
- package/dist/harmony131.cjs.map +1 -1
- package/dist/harmony131.mjs +9 -5
- package/dist/harmony131.mjs.map +1 -1
- package/dist/harmony132.cjs +13 -6
- package/dist/harmony132.cjs.map +1 -1
- package/dist/harmony132.mjs +12 -5
- package/dist/harmony132.mjs.map +1 -1
- package/dist/harmony133.cjs +15 -9
- package/dist/harmony133.cjs.map +1 -1
- package/dist/harmony133.mjs +14 -8
- package/dist/harmony133.mjs.map +1 -1
- package/dist/harmony134.cjs +13 -6
- package/dist/harmony134.cjs.map +1 -1
- package/dist/harmony134.mjs +15 -8
- package/dist/harmony134.mjs.map +1 -1
- package/dist/harmony135.cjs +7 -12
- package/dist/harmony135.cjs.map +1 -1
- package/dist/harmony135.mjs +9 -14
- package/dist/harmony135.mjs.map +1 -1
- package/dist/harmony136.cjs +20 -13
- package/dist/harmony136.cjs.map +1 -1
- package/dist/harmony136.mjs +22 -15
- package/dist/harmony136.mjs.map +1 -1
- package/dist/harmony137.cjs +9 -7
- package/dist/harmony137.cjs.map +1 -1
- package/dist/harmony137.mjs +11 -9
- package/dist/harmony137.mjs.map +1 -1
- package/dist/harmony138.cjs +30 -18
- package/dist/harmony138.cjs.map +1 -1
- package/dist/harmony138.mjs +32 -20
- package/dist/harmony138.mjs.map +1 -1
- package/dist/harmony139.cjs +6 -6
- package/dist/harmony139.cjs.map +1 -1
- package/dist/harmony139.mjs +6 -6
- package/dist/harmony139.mjs.map +1 -1
- package/dist/harmony140.cjs +13 -29
- package/dist/harmony140.cjs.map +1 -1
- package/dist/harmony140.mjs +14 -30
- package/dist/harmony140.mjs.map +1 -1
- package/dist/harmony141.cjs +31 -7
- package/dist/harmony141.cjs.map +1 -1
- package/dist/harmony141.mjs +32 -8
- package/dist/harmony141.mjs.map +1 -1
- package/dist/harmony142.cjs +21 -22
- package/dist/harmony142.cjs.map +1 -1
- package/dist/harmony142.mjs +20 -21
- package/dist/harmony142.mjs.map +1 -1
- package/dist/harmony143.cjs +15 -30
- package/dist/harmony143.cjs.map +1 -1
- package/dist/harmony143.mjs +17 -32
- package/dist/harmony143.mjs.map +1 -1
- package/dist/harmony144.cjs +3 -18
- package/dist/harmony144.cjs.map +1 -1
- package/dist/harmony144.mjs +3 -18
- package/dist/harmony144.mjs.map +1 -1
- package/dist/harmony145.cjs +15 -21
- package/dist/harmony145.cjs.map +1 -1
- package/dist/harmony145.mjs +14 -20
- package/dist/harmony145.mjs.map +1 -1
- package/dist/harmony146.cjs +10 -6
- package/dist/harmony146.cjs.map +1 -1
- package/dist/harmony146.mjs +9 -5
- package/dist/harmony146.mjs.map +1 -1
- package/dist/harmony147.cjs +5 -15
- package/dist/harmony147.cjs.map +1 -1
- package/dist/harmony147.mjs +5 -15
- package/dist/harmony147.mjs.map +1 -1
- package/dist/harmony148.cjs +6 -11
- package/dist/harmony148.cjs.map +1 -1
- package/dist/harmony148.mjs +5 -10
- package/dist/harmony148.mjs.map +1 -1
- package/dist/harmony149.cjs +1 -1
- package/dist/harmony149.mjs +1 -1
- package/dist/harmony150.cjs +1 -1
- package/dist/harmony150.mjs +1 -1
- package/dist/harmony151.cjs +1 -1
- package/dist/harmony151.mjs +1 -1
- package/dist/harmony152.cjs +3 -3
- package/dist/harmony152.mjs +3 -3
- package/dist/harmony153.cjs +3 -3
- package/dist/harmony153.mjs +3 -3
- package/dist/harmony154.cjs +1 -1
- package/dist/harmony154.mjs +1 -1
- package/dist/harmony157.cjs +1 -1
- package/dist/harmony157.mjs +1 -1
- package/dist/harmony158.cjs +2 -2
- package/dist/harmony158.mjs +2 -2
- package/dist/harmony167.cjs +32 -13
- package/dist/harmony167.cjs.map +1 -1
- package/dist/harmony167.mjs +32 -13
- package/dist/harmony167.mjs.map +1 -1
- package/dist/harmony168.cjs +12 -14
- package/dist/harmony168.cjs.map +1 -1
- package/dist/harmony168.mjs +12 -14
- package/dist/harmony168.mjs.map +1 -1
- package/dist/harmony169.cjs +13 -14
- package/dist/harmony169.cjs.map +1 -1
- package/dist/harmony169.mjs +13 -14
- package/dist/harmony169.mjs.map +1 -1
- package/dist/harmony17.cjs +1 -1
- package/dist/harmony17.mjs +1 -1
- package/dist/harmony170.cjs +15 -31
- package/dist/harmony170.cjs.map +1 -1
- package/dist/harmony170.mjs +15 -31
- package/dist/harmony170.mjs.map +1 -1
- package/dist/harmony171.cjs +1 -1
- package/dist/harmony171.mjs +1 -1
- package/dist/harmony173.cjs +3 -3
- package/dist/harmony173.mjs +3 -3
- package/dist/harmony175.cjs +4 -6
- package/dist/harmony175.cjs.map +1 -1
- package/dist/harmony175.mjs +4 -6
- package/dist/harmony175.mjs.map +1 -1
- package/dist/harmony176.cjs +5 -11
- package/dist/harmony176.cjs.map +1 -1
- package/dist/harmony176.mjs +5 -11
- package/dist/harmony176.mjs.map +1 -1
- package/dist/harmony177.cjs +11 -31
- package/dist/harmony177.cjs.map +1 -1
- package/dist/harmony177.mjs +11 -31
- package/dist/harmony177.mjs.map +1 -1
- package/dist/harmony178.cjs +28 -10
- package/dist/harmony178.cjs.map +1 -1
- package/dist/harmony178.mjs +28 -10
- package/dist/harmony178.mjs.map +1 -1
- package/dist/harmony179.cjs +14 -4
- package/dist/harmony179.cjs.map +1 -1
- package/dist/harmony179.mjs +14 -4
- package/dist/harmony179.mjs.map +1 -1
- package/dist/harmony20.cjs +1 -1
- package/dist/harmony20.mjs +1 -1
- package/dist/harmony28.cjs +1 -1
- package/dist/harmony28.mjs +1 -1
- package/dist/harmony29.cjs +1 -1
- package/dist/harmony29.mjs +1 -1
- package/dist/harmony32.cjs +1 -1
- package/dist/harmony32.mjs +1 -1
- package/dist/harmony33.cjs +1 -1
- package/dist/harmony33.mjs +1 -1
- package/dist/harmony34.cjs +1 -1
- package/dist/harmony34.mjs +1 -1
- package/dist/harmony39.cjs +1 -1
- package/dist/harmony39.mjs +1 -1
- package/dist/harmony40.cjs +1 -1
- package/dist/harmony40.mjs +1 -1
- package/dist/harmony41.cjs +1 -1
- package/dist/harmony41.mjs +1 -1
- package/dist/harmony42.cjs +2 -2
- package/dist/harmony42.mjs +2 -2
- package/dist/harmony43.cjs +2 -2
- package/dist/harmony43.mjs +2 -2
- package/dist/harmony44.cjs +1 -1
- package/dist/harmony44.mjs +1 -1
- package/dist/harmony53.cjs +3 -3
- package/dist/harmony53.cjs.map +1 -1
- package/dist/harmony53.mjs +1 -1
- package/dist/harmony53.mjs.map +1 -1
- package/dist/harmony78.cjs +74 -74
- package/dist/harmony78.cjs.map +1 -1
- package/dist/harmony78.mjs +1 -1
- package/dist/harmony78.mjs.map +1 -1
- package/dist/harmony79.cjs +52 -52
- package/dist/harmony79.cjs.map +1 -1
- package/dist/harmony79.mjs +1 -1
- package/dist/harmony79.mjs.map +1 -1
- package/dist/harmony80.cjs +4 -4
- package/dist/harmony80.cjs.map +1 -1
- package/dist/harmony80.mjs +1 -1
- package/dist/harmony80.mjs.map +1 -1
- package/dist/harmony81.cjs +18 -18
- package/dist/harmony81.cjs.map +1 -1
- package/dist/harmony81.mjs +1 -1
- package/dist/harmony81.mjs.map +1 -1
- package/dist/harmony82.cjs +15 -15
- package/dist/harmony82.cjs.map +1 -1
- package/dist/harmony82.mjs +1 -1
- package/dist/harmony82.mjs.map +1 -1
- package/dist/harmony83.cjs +96 -96
- package/dist/harmony83.cjs.map +1 -1
- package/dist/harmony83.mjs +1 -1
- package/dist/harmony83.mjs.map +1 -1
- package/dist/harmony84.cjs +24 -24
- package/dist/harmony84.cjs.map +1 -1
- package/dist/harmony84.mjs +1 -1
- package/dist/harmony84.mjs.map +1 -1
- package/dist/harmony85.cjs +14 -14
- package/dist/harmony85.cjs.map +1 -1
- package/dist/harmony85.mjs +1 -1
- package/dist/harmony85.mjs.map +1 -1
- package/dist/harmony86.cjs +2 -2
- package/dist/harmony86.cjs.map +1 -1
- package/dist/harmony86.mjs +1 -1
- package/dist/harmony86.mjs.map +1 -1
- package/dist/harmony87.cjs +40 -40
- package/dist/harmony87.cjs.map +1 -1
- package/dist/harmony87.mjs +1 -1
- package/dist/harmony87.mjs.map +1 -1
- package/dist/harmony88.cjs +27 -27
- package/dist/harmony88.cjs.map +1 -1
- package/dist/harmony88.mjs +1 -1
- package/dist/harmony88.mjs.map +1 -1
- package/dist/harmony89.cjs +10 -10
- package/dist/harmony89.cjs.map +1 -1
- package/dist/harmony89.mjs +1 -1
- package/dist/harmony89.mjs.map +1 -1
- package/dist/harmony95.cjs +1 -1
- package/dist/harmony95.mjs +1 -1
- package/dist/harmony97.cjs +2 -2
- package/dist/harmony97.mjs +2 -2
- package/dist/types/src/features/auth/core/types/jwtTokenPayload.d.ts +35 -8
- package/dist/types/src/features/auth/core/types/jwtTokenPayload.fixture.d.ts +1 -1
- package/dist/types/src/features/auth/frontend/hooks/useAuthenticatedProjectContributor.d.ts +3 -3
- package/dist/types/src/features/auth/frontend/hooks/useAuthenticatedUser.d.ts +2 -2
- package/dist/types/src/features/auth/frontend/services/generateTokenFromClassicSession.d.ts +4 -1
- package/dist/types/src/features/auth/frontend/services/refreshExpiredToken.d.ts +4 -1
- package/dist/types/src/features/navigation/hooks/useNavigationQueries.d.ts +48 -48
- package/dist/types/src/features/publicApi/TESTING_CONTRACTS.d.ts +238 -1
- package/dist/types/src/features/publicApi/contributors.d.ts +1072 -5
- package/dist/types/src/features/publicApi/hooks/useAddContributorsMutation.d.ts +7 -7
- package/dist/types/src/features/publicApi/hooks/useAddLanguagesToProjectMutation.d.ts +2 -2
- package/dist/types/src/features/publicApi/hooks/useCreateProjectMutation.d.ts +14 -14
- package/dist/types/src/features/publicApi/hooks/useCreateScoreMutation.d.ts +3 -3
- package/dist/types/src/features/publicApi/hooks/useListProjectsQuery.d.ts +1 -1
- package/dist/types/src/features/publicApi/hooks/useListTeamsQuery.d.ts +1 -1
- package/dist/types/src/features/publicApi/hooks/useRetrieveContributorQuery.d.ts +2 -2
- package/dist/types/src/features/publicApi/hooks/useRetrieveUserPermissions.d.ts +1 -1
- package/dist/types/src/features/publicApi/hooks/useUpdateContributorMutation.d.ts +5 -5
- package/dist/types/src/features/publicApi/hooks/useUpdateProjectMutation.d.ts +13 -13
- package/dist/types/src/features/publicApi/languages.d.ts +368 -3
- package/dist/types/src/features/publicApi/permissionTemplates.d.ts +117 -1
- package/dist/types/src/features/publicApi/projects.d.ts +1965 -6
- package/dist/types/src/features/publicApi/score.d.ts +290 -3
- package/dist/types/src/features/publicApi/team.d.ts +374 -2
- package/dist/types/src/features/publicApi/teamUsers.d.ts +318 -3
- package/dist/types/src/features/publicApi/types/contributorTypes.d.ts +834 -84
- package/dist/types/src/features/publicApi/types/languageTypes.d.ts +212 -22
- package/dist/types/src/features/publicApi/types/paginationTypes.d.ts +8 -2
- package/dist/types/src/features/publicApi/types/permissionTemplateTypes.d.ts +76 -71
- package/dist/types/src/features/publicApi/types/permissionTypes.d.ts +24 -48
- package/dist/types/src/features/publicApi/types/projectTypes.d.ts +1097 -211
- package/dist/types/src/features/publicApi/types/scoreTypes.d.ts +96 -32
- package/dist/types/src/features/publicApi/types/sharedTypes.d.ts +126 -30
- package/dist/types/src/features/publicApi/types/teamRoleTypes.d.ts +2 -7
- package/dist/types/src/features/publicApi/types/teamTypes.d.ts +328 -65
- package/dist/types/src/features/publicApi/types/teamUserTypes.d.ts +208 -91
- package/dist/types/src/features/publicApi/types/userTokenTypes.d.ts +39 -9
- package/dist/types/src/features/publicApi/userToken.d.ts +53 -1
- package/package.json +1 -1
package/dist/harmony103.cjs
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
3
3
|
const jsxRuntime = require("react/jsx-runtime");
|
|
4
4
|
const React = require("react");
|
|
5
|
-
const SidebarContext = require("./
|
|
5
|
+
const SidebarContext = require("./harmony112.cjs");
|
|
6
6
|
const SidebarProvider = ({
|
|
7
7
|
data,
|
|
8
8
|
jwt,
|
package/dist/harmony103.mjs
CHANGED
package/dist/harmony104.cjs
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
3
3
|
const jsxRuntime = require("react/jsx-runtime");
|
|
4
|
-
const IconLink = require("./
|
|
5
|
-
const ProfileMenu = require("./
|
|
6
|
-
const useSidebar = require("./
|
|
4
|
+
const IconLink = require("./harmony113.cjs");
|
|
5
|
+
const ProfileMenu = require("./harmony114.cjs");
|
|
6
|
+
const useSidebar = require("./harmony115.cjs");
|
|
7
7
|
const louis = require("@lokalise/louis");
|
|
8
|
-
const permissions = require("./
|
|
9
|
-
const Avatar = require("./
|
|
10
|
-
const HelpMenu = require("./
|
|
11
|
-
const SidebarContent_module = require("./
|
|
8
|
+
const permissions = require("./harmony116.cjs");
|
|
9
|
+
const Avatar = require("./harmony117.cjs");
|
|
10
|
+
const HelpMenu = require("./harmony118.cjs");
|
|
11
|
+
const SidebarContent_module = require("./harmony119.cjs");
|
|
12
12
|
const SidebarContent = ({ widgetsConfig, children, ...navProps }) => {
|
|
13
13
|
const sidebarContextProps = useSidebar.useSidebar();
|
|
14
14
|
const { jwt } = sidebarContextProps;
|
package/dist/harmony104.mjs
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
import { jsxs, jsx, Fragment } from "react/jsx-runtime";
|
|
2
|
-
import { IconLink } from "./
|
|
3
|
-
import { ProfileMenu } from "./
|
|
4
|
-
import { useSidebar } from "./
|
|
2
|
+
import { IconLink } from "./harmony113.mjs";
|
|
3
|
+
import { ProfileMenu } from "./harmony114.mjs";
|
|
4
|
+
import { useSidebar } from "./harmony115.mjs";
|
|
5
5
|
import { Skeleton, Rectangle, ProjectIcon, ShoppingBagIcon, StyleguideIcon, ChartLineIcon } from "@lokalise/louis";
|
|
6
|
-
import { canAccessStyleGuide, canAccessReporting } from "./
|
|
7
|
-
import { Avatar } from "./
|
|
8
|
-
import { HelpMenu } from "./
|
|
9
|
-
import styles from "./
|
|
6
|
+
import { canAccessStyleGuide, canAccessReporting } from "./harmony116.mjs";
|
|
7
|
+
import { Avatar } from "./harmony117.mjs";
|
|
8
|
+
import { HelpMenu } from "./harmony118.mjs";
|
|
9
|
+
import styles from "./harmony119.mjs";
|
|
10
10
|
const SidebarContent = ({ widgetsConfig, children, ...navProps }) => {
|
|
11
11
|
const sidebarContextProps = useSidebar();
|
|
12
12
|
const { jwt } = sidebarContextProps;
|
package/dist/harmony107.cjs
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
3
3
|
const React = require("react");
|
|
4
4
|
const NavigationClientProvider = require("./harmony16.cjs");
|
|
5
|
-
const toolbarVisibility = require("./
|
|
5
|
+
const toolbarVisibility = require("./harmony122.cjs");
|
|
6
6
|
const useExpertNavigation = (enabled, project, contributor) => {
|
|
7
7
|
const adminRights = (contributor == null ? void 0 : contributor.admin_rights) || [];
|
|
8
8
|
const marketingSupportProjectSelectedAppSlug = "selected-app-slug";
|
package/dist/harmony107.mjs
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { useMemo } from "react";
|
|
2
2
|
import { useNavigationClient } from "./harmony16.mjs";
|
|
3
|
-
import { getProjectNavigationVisibilityMap } from "./
|
|
3
|
+
import { getProjectNavigationVisibilityMap } from "./harmony122.mjs";
|
|
4
4
|
const useExpertNavigation = (enabled, project, contributor) => {
|
|
5
5
|
const adminRights = (contributor == null ? void 0 : contributor.admin_rights) || [];
|
|
6
6
|
const marketingSupportProjectSelectedAppSlug = "selected-app-slug";
|
package/dist/harmony108.cjs
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
3
3
|
const React = require("react");
|
|
4
4
|
const NavigationClientProvider = require("./harmony16.cjs");
|
|
5
|
-
const navigationSchema = require("./
|
|
5
|
+
const navigationSchema = require("./harmony123.cjs");
|
|
6
6
|
const useNextgenNavigation = (activeKey, enabled, project, contributor) => {
|
|
7
7
|
const navigationClient = NavigationClientProvider.useNavigationClient();
|
|
8
8
|
const nextgenUrl = navigationClient.getNextgenUrl();
|
package/dist/harmony108.mjs
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { useCallback, useMemo } from "react";
|
|
2
2
|
import { useNavigationClient } from "./harmony16.mjs";
|
|
3
|
-
import { navigationItems } from "./
|
|
3
|
+
import { navigationItems } from "./harmony123.mjs";
|
|
4
4
|
const useNextgenNavigation = (activeKey, enabled, project, contributor) => {
|
|
5
5
|
const navigationClient = useNavigationClient();
|
|
6
6
|
const nextgenUrl = navigationClient.getNextgenUrl();
|
package/dist/harmony109.cjs
CHANGED
|
@@ -1,17 +1,14 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
var __defProp = Object.defineProperty;
|
|
3
|
-
var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
4
|
-
var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "symbol" ? key + "" : key, value);
|
|
5
2
|
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
6
|
-
const
|
|
7
|
-
const
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
})
|
|
12
|
-
|
|
13
|
-
}
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
exports.
|
|
3
|
+
const jsxRuntime = require("react/jsx-runtime");
|
|
4
|
+
const louis = require("@lokalise/louis");
|
|
5
|
+
const styles_module = require("./harmony110.cjs");
|
|
6
|
+
const NavItemContents = ({ label, badge, novel }) => /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex gap-1", children: [
|
|
7
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { children: [
|
|
8
|
+
/* @__PURE__ */ jsxRuntime.jsx("span", { children: label }),
|
|
9
|
+
!!badge && /* @__PURE__ */ jsxRuntime.jsx("div", { className: styles_module.default.badge, "aria-label": `${badge} items requiring attention`, children: badge > 9 ? "9+" : badge })
|
|
10
|
+
] }),
|
|
11
|
+
!!novel && /* @__PURE__ */ jsxRuntime.jsx(louis.Tag, { className: styles_module.default.tag, children: novel })
|
|
12
|
+
] });
|
|
13
|
+
exports.NavItemContents = NavItemContents;
|
|
17
14
|
//# sourceMappingURL=harmony109.cjs.map
|
package/dist/harmony109.cjs.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"harmony109.cjs","sources":["../src/
|
|
1
|
+
{"version":3,"file":"harmony109.cjs","sources":["../src/components/NavigationPanel/components/NavigationTabs/NavigationTabsItem/NavItemContents.tsx"],"sourcesContent":["import { Tag } from '@lokalise/louis'\n\nimport classes from './styles.module.css'\n\ninterface NavItemContentProps {\n\tlabel: string\n\tbadge?: number\n\tnovel?: string\n}\nexport const NavItemContents = ({ label, badge, novel }: NavItemContentProps) => (\n\t<div className=\"flex gap-1\">\n\t\t<div>\n\t\t\t<span>{label}</span>\n\t\t\t{!!badge && (\n\t\t\t\t<div className={classes.badge} aria-label={`${badge} items requiring attention`}>\n\t\t\t\t\t{badge > 9 ? '9+' : badge}\n\t\t\t\t</div>\n\t\t\t)}\n\t\t</div>\n\t\t{!!novel && <Tag className={classes.tag}>{novel}</Tag>}\n\t</div>\n)\n"],"names":["jsxs","jsx","classes","Tag"],"mappings":";;;;;AASa,MAAA,kBAAkB,CAAC,EAAE,OAAO,OAAO,YAC/CA,2BAAA,KAAC,OAAI,EAAA,WAAU,cACd,UAAA;AAAA,EAAAA,gCAAC,OACA,EAAA,UAAA;AAAA,IAAAC,2BAAAA,IAAC,UAAM,UAAM,MAAA,CAAA;AAAA,IACZ,CAAC,CAAC,SACFA,+BAAC,SAAI,WAAWC,cAAA,QAAQ,OAAO,cAAY,GAAG,KAAK,8BACjD,UAAQ,QAAA,IAAI,OAAO,MACrB,CAAA;AAAA,EAAA,GAEF;AAAA,EACC,CAAC,CAAC,SAASD,2BAAA,IAACE,aAAI,WAAWD,sBAAQ,KAAM,UAAM,MAAA,CAAA;AAAA,EACjD,CAAA;;"}
|
package/dist/harmony109.mjs
CHANGED
|
@@ -1,17 +1,14 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
};
|
|
12
|
-
__publicField(_NewJwtIssuedEvent, "eventName", "new-jwt-issued");
|
|
13
|
-
let NewJwtIssuedEvent = _NewJwtIssuedEvent;
|
|
1
|
+
import { jsxs, jsx } from "react/jsx-runtime";
|
|
2
|
+
import { Tag } from "@lokalise/louis";
|
|
3
|
+
import classes from "./harmony110.mjs";
|
|
4
|
+
const NavItemContents = ({ label, badge, novel }) => /* @__PURE__ */ jsxs("div", { className: "flex gap-1", children: [
|
|
5
|
+
/* @__PURE__ */ jsxs("div", { children: [
|
|
6
|
+
/* @__PURE__ */ jsx("span", { children: label }),
|
|
7
|
+
!!badge && /* @__PURE__ */ jsx("div", { className: classes.badge, "aria-label": `${badge} items requiring attention`, children: badge > 9 ? "9+" : badge })
|
|
8
|
+
] }),
|
|
9
|
+
!!novel && /* @__PURE__ */ jsx(Tag, { className: classes.tag, children: novel })
|
|
10
|
+
] });
|
|
14
11
|
export {
|
|
15
|
-
|
|
12
|
+
NavItemContents
|
|
16
13
|
};
|
|
17
14
|
//# sourceMappingURL=harmony109.mjs.map
|
package/dist/harmony109.mjs.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"harmony109.mjs","sources":["../src/
|
|
1
|
+
{"version":3,"file":"harmony109.mjs","sources":["../src/components/NavigationPanel/components/NavigationTabs/NavigationTabsItem/NavItemContents.tsx"],"sourcesContent":["import { Tag } from '@lokalise/louis'\n\nimport classes from './styles.module.css'\n\ninterface NavItemContentProps {\n\tlabel: string\n\tbadge?: number\n\tnovel?: string\n}\nexport const NavItemContents = ({ label, badge, novel }: NavItemContentProps) => (\n\t<div className=\"flex gap-1\">\n\t\t<div>\n\t\t\t<span>{label}</span>\n\t\t\t{!!badge && (\n\t\t\t\t<div className={classes.badge} aria-label={`${badge} items requiring attention`}>\n\t\t\t\t\t{badge > 9 ? '9+' : badge}\n\t\t\t\t</div>\n\t\t\t)}\n\t\t</div>\n\t\t{!!novel && <Tag className={classes.tag}>{novel}</Tag>}\n\t</div>\n)\n"],"names":[],"mappings":";;;AASa,MAAA,kBAAkB,CAAC,EAAE,OAAO,OAAO,YAC/C,qBAAC,OAAI,EAAA,WAAU,cACd,UAAA;AAAA,EAAA,qBAAC,OACA,EAAA,UAAA;AAAA,IAAA,oBAAC,UAAM,UAAM,MAAA,CAAA;AAAA,IACZ,CAAC,CAAC,SACF,oBAAC,SAAI,WAAW,QAAQ,OAAO,cAAY,GAAG,KAAK,8BACjD,UAAQ,QAAA,IAAI,OAAO,MACrB,CAAA;AAAA,EAAA,GAEF;AAAA,EACC,CAAC,CAAC,SAAS,oBAAC,OAAI,WAAW,QAAQ,KAAM,UAAM,MAAA,CAAA;AAAA,EACjD,CAAA;"}
|
package/dist/harmony110.cjs
CHANGED
|
@@ -1,6 +1,24 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
Object.
|
|
3
|
-
const
|
|
4
|
-
const
|
|
5
|
-
|
|
2
|
+
Object.defineProperties(exports, { __esModule: { value: true }, [Symbol.toStringTag]: { value: "Module" } });
|
|
3
|
+
const badge = "_badge_1pc1v_1";
|
|
4
|
+
const tag = "_tag_1pc1v_15";
|
|
5
|
+
const withNavLinkStyle = "_withNavLinkStyle_1pc1v_42 _withLinkStyle_1pc1v_21";
|
|
6
|
+
const disabled = "_disabled_1pc1v_57";
|
|
7
|
+
const projectNavigationItem = "_projectNavigationItem_1pc1v_61";
|
|
8
|
+
const projectNavigationItemDisabled = "_projectNavigationItemDisabled_1pc1v_67";
|
|
9
|
+
const classes = {
|
|
10
|
+
badge,
|
|
11
|
+
tag,
|
|
12
|
+
withNavLinkStyle,
|
|
13
|
+
disabled,
|
|
14
|
+
projectNavigationItem,
|
|
15
|
+
projectNavigationItemDisabled
|
|
16
|
+
};
|
|
17
|
+
exports.badge = badge;
|
|
18
|
+
exports.default = classes;
|
|
19
|
+
exports.disabled = disabled;
|
|
20
|
+
exports.projectNavigationItem = projectNavigationItem;
|
|
21
|
+
exports.projectNavigationItemDisabled = projectNavigationItemDisabled;
|
|
22
|
+
exports.tag = tag;
|
|
23
|
+
exports.withNavLinkStyle = withNavLinkStyle;
|
|
6
24
|
//# sourceMappingURL=harmony110.cjs.map
|
package/dist/harmony110.cjs.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"harmony110.cjs","sources":[
|
|
1
|
+
{"version":3,"file":"harmony110.cjs","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;"}
|
package/dist/harmony110.mjs
CHANGED
|
@@ -1,6 +1,24 @@
|
|
|
1
|
-
|
|
2
|
-
const
|
|
1
|
+
const badge = "_badge_1pc1v_1";
|
|
2
|
+
const tag = "_tag_1pc1v_15";
|
|
3
|
+
const withNavLinkStyle = "_withNavLinkStyle_1pc1v_42 _withLinkStyle_1pc1v_21";
|
|
4
|
+
const disabled = "_disabled_1pc1v_57";
|
|
5
|
+
const projectNavigationItem = "_projectNavigationItem_1pc1v_61";
|
|
6
|
+
const projectNavigationItemDisabled = "_projectNavigationItemDisabled_1pc1v_67";
|
|
7
|
+
const classes = {
|
|
8
|
+
badge,
|
|
9
|
+
tag,
|
|
10
|
+
withNavLinkStyle,
|
|
11
|
+
disabled,
|
|
12
|
+
projectNavigationItem,
|
|
13
|
+
projectNavigationItemDisabled
|
|
14
|
+
};
|
|
3
15
|
export {
|
|
4
|
-
|
|
16
|
+
badge,
|
|
17
|
+
classes as default,
|
|
18
|
+
disabled,
|
|
19
|
+
projectNavigationItem,
|
|
20
|
+
projectNavigationItemDisabled,
|
|
21
|
+
tag,
|
|
22
|
+
withNavLinkStyle
|
|
5
23
|
};
|
|
6
24
|
//# sourceMappingURL=harmony110.mjs.map
|
package/dist/harmony110.mjs.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"harmony110.mjs","sources":[
|
|
1
|
+
{"version":3,"file":"harmony110.mjs","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;"}
|
package/dist/harmony111.cjs
CHANGED
|
@@ -1,21 +1,17 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
+
var __defProp = Object.defineProperty;
|
|
3
|
+
var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
4
|
+
var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "symbol" ? key + "" : key, value);
|
|
2
5
|
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
3
|
-
const
|
|
4
|
-
const
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
{
|
|
11
|
-
"aria-label": label,
|
|
12
|
-
className: clsx.clsx(IconLink_module.default.link, {
|
|
13
|
-
[IconLink_module.default.active]: typeof window !== "undefined" && window.location.pathname.startsWith(to)
|
|
14
|
-
}),
|
|
15
|
-
href: to,
|
|
16
|
-
children: /* @__PURE__ */ jsxRuntime.jsx(Icon, { size: "25px" })
|
|
17
|
-
}
|
|
18
|
-
) });
|
|
6
|
+
const jwtTokenPayload = require("./harmony20.cjs");
|
|
7
|
+
const _NewJwtIssuedEvent = class _NewJwtIssuedEvent extends CustomEvent {
|
|
8
|
+
constructor(token) {
|
|
9
|
+
super(_NewJwtIssuedEvent.eventName, {
|
|
10
|
+
detail: { token, payload: jwtTokenPayload.parseJwtTokenPayload(token.accessToken) }
|
|
11
|
+
});
|
|
12
|
+
}
|
|
19
13
|
};
|
|
20
|
-
|
|
14
|
+
__publicField(_NewJwtIssuedEvent, "eventName", "new-jwt-issued");
|
|
15
|
+
let NewJwtIssuedEvent = _NewJwtIssuedEvent;
|
|
16
|
+
exports.NewJwtIssuedEvent = NewJwtIssuedEvent;
|
|
21
17
|
//# sourceMappingURL=harmony111.cjs.map
|
package/dist/harmony111.cjs.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"harmony111.cjs","sources":["../src/
|
|
1
|
+
{"version":3,"file":"harmony111.cjs","sources":["../src/features/auth/frontend/events/NewJwtIssuedEvent.ts"],"sourcesContent":["import type { JwtTokenPayload } from '@features/auth/core/types/jwtTokenPayload'\nimport { parseJwtTokenPayload } from '@features/auth/core/utils/jwtTokenPayload'\nimport type { JwtToken } from '@features/publicApi/types/userTokenTypes'\n\ntype NewJwtIssuedEventDetail = {\n\ttoken: JwtToken\n\tpayload: JwtTokenPayload | undefined\n}\n\n/**\n * This event is emitted when a new JWT token is issued or refreshed.\n */\nexport class NewJwtIssuedEvent extends CustomEvent<NewJwtIssuedEventDetail> {\n\tstatic readonly eventName = 'new-jwt-issued' as const\n\n\tconstructor(token: JwtToken) {\n\t\tsuper(NewJwtIssuedEvent.eventName, {\n\t\t\tdetail: { token, payload: parseJwtTokenPayload(token.accessToken) },\n\t\t})\n\t}\n}\n\nexport const isNewJwtIssuedEvent = (event: Event): event is NewJwtIssuedEvent =>\n\tevent.type === NewJwtIssuedEvent.eventName\n\ndeclare global {\n\tinterface WindowEventMap {\n\t\t[NewJwtIssuedEvent.eventName]: NewJwtIssuedEvent\n\t}\n}\n"],"names":["parseJwtTokenPayload"],"mappings":";;;;;;AAYO,MAAM,qBAAN,MAAM,2BAA0B,YAAqC;AAAA,EAG3E,YAAY,OAAiB;AAC5B,UAAM,mBAAkB,WAAW;AAAA,MAClC,QAAQ,EAAE,OAAO,SAASA,gBAAAA,qBAAqB,MAAM,WAAW,EAAE;AAAA,IAAA,CAClE;AAAA,EAAA;AAEH;AAPC,cADY,oBACI,aAAY;AADtB,IAAM,oBAAN;;"}
|
package/dist/harmony111.mjs
CHANGED
|
@@ -1,21 +1,17 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
import
|
|
5
|
-
const
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
[styles.active]: typeof window !== "undefined" && window.location.pathname.startsWith(to)
|
|
12
|
-
}),
|
|
13
|
-
href: to,
|
|
14
|
-
children: /* @__PURE__ */ jsx(Icon, { size: "25px" })
|
|
15
|
-
}
|
|
16
|
-
) });
|
|
1
|
+
var __defProp = Object.defineProperty;
|
|
2
|
+
var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
3
|
+
var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "symbol" ? key + "" : key, value);
|
|
4
|
+
import { parseJwtTokenPayload } from "./harmony20.mjs";
|
|
5
|
+
const _NewJwtIssuedEvent = class _NewJwtIssuedEvent extends CustomEvent {
|
|
6
|
+
constructor(token) {
|
|
7
|
+
super(_NewJwtIssuedEvent.eventName, {
|
|
8
|
+
detail: { token, payload: parseJwtTokenPayload(token.accessToken) }
|
|
9
|
+
});
|
|
10
|
+
}
|
|
17
11
|
};
|
|
12
|
+
__publicField(_NewJwtIssuedEvent, "eventName", "new-jwt-issued");
|
|
13
|
+
let NewJwtIssuedEvent = _NewJwtIssuedEvent;
|
|
18
14
|
export {
|
|
19
|
-
|
|
15
|
+
NewJwtIssuedEvent
|
|
20
16
|
};
|
|
21
17
|
//# sourceMappingURL=harmony111.mjs.map
|
package/dist/harmony111.mjs.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"harmony111.mjs","sources":["../src/
|
|
1
|
+
{"version":3,"file":"harmony111.mjs","sources":["../src/features/auth/frontend/events/NewJwtIssuedEvent.ts"],"sourcesContent":["import type { JwtTokenPayload } from '@features/auth/core/types/jwtTokenPayload'\nimport { parseJwtTokenPayload } from '@features/auth/core/utils/jwtTokenPayload'\nimport type { JwtToken } from '@features/publicApi/types/userTokenTypes'\n\ntype NewJwtIssuedEventDetail = {\n\ttoken: JwtToken\n\tpayload: JwtTokenPayload | undefined\n}\n\n/**\n * This event is emitted when a new JWT token is issued or refreshed.\n */\nexport class NewJwtIssuedEvent extends CustomEvent<NewJwtIssuedEventDetail> {\n\tstatic readonly eventName = 'new-jwt-issued' as const\n\n\tconstructor(token: JwtToken) {\n\t\tsuper(NewJwtIssuedEvent.eventName, {\n\t\t\tdetail: { token, payload: parseJwtTokenPayload(token.accessToken) },\n\t\t})\n\t}\n}\n\nexport const isNewJwtIssuedEvent = (event: Event): event is NewJwtIssuedEvent =>\n\tevent.type === NewJwtIssuedEvent.eventName\n\ndeclare global {\n\tinterface WindowEventMap {\n\t\t[NewJwtIssuedEvent.eventName]: NewJwtIssuedEvent\n\t}\n}\n"],"names":[],"mappings":";;;;AAYO,MAAM,qBAAN,MAAM,2BAA0B,YAAqC;AAAA,EAG3E,YAAY,OAAiB;AAC5B,UAAM,mBAAkB,WAAW;AAAA,MAClC,QAAQ,EAAE,OAAO,SAAS,qBAAqB,MAAM,WAAW,EAAE;AAAA,IAAA,CAClE;AAAA,EAAA;AAEH;AAPC,cADY,oBACI,aAAY;AADtB,IAAM,oBAAN;"}
|
package/dist/harmony112.cjs
CHANGED
|
@@ -1,79 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
3
|
-
const
|
|
4
|
-
const
|
|
5
|
-
|
|
6
|
-
const CreateNewTeamPlaceholder = require("./harmony136.cjs");
|
|
7
|
-
const DarkModeToggle = require("./harmony137.cjs");
|
|
8
|
-
const ProfileSettingsMenuItem = require("./harmony138.cjs");
|
|
9
|
-
const ProviderMenuItem = require("./harmony139.cjs");
|
|
10
|
-
const TeamMenuItem = require("./harmony140.cjs");
|
|
11
|
-
const TeamSettingsMenuItem = require("./harmony141.cjs");
|
|
12
|
-
const TeamSwitch = require("./harmony142.cjs");
|
|
13
|
-
const UpgradeMenuItem = require("./harmony143.cjs");
|
|
14
|
-
const useSidebar = require("./harmony113.cjs");
|
|
15
|
-
const louis = require("@lokalise/louis");
|
|
16
|
-
const permissions = require("./harmony114.cjs");
|
|
17
|
-
const clsx = require("./harmony93.cjs");
|
|
18
|
-
const ProfileMenu_module = require("./harmony144.cjs");
|
|
19
|
-
const UpgradeIcon = require("./harmony145.cjs");
|
|
20
|
-
const ProfileMenu = ({ config }) => {
|
|
21
|
-
const {
|
|
22
|
-
jwt,
|
|
23
|
-
data: { currentTeam }
|
|
24
|
-
} = useSidebar.useSidebar();
|
|
25
|
-
const {
|
|
26
|
-
darkModeToggle,
|
|
27
|
-
teamSwitch,
|
|
28
|
-
createTeam,
|
|
29
|
-
createTeamPlaceholder,
|
|
30
|
-
upgradeMenuItem,
|
|
31
|
-
profileSettings
|
|
32
|
-
} = config;
|
|
33
|
-
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
34
|
-
louis.Menu,
|
|
35
|
-
{
|
|
36
|
-
menuButton: () => {
|
|
37
|
-
var _a;
|
|
38
|
-
return /* @__PURE__ */ jsxRuntime.jsxs("button", { className: ProfileMenu_module.default.profileButton, "aria-label": "Profile menu", type: "button", children: [
|
|
39
|
-
((_a = currentTeam.result) == null ? void 0 : _a.logoUrl) ? /* @__PURE__ */ jsxRuntime.jsx(
|
|
40
|
-
"img",
|
|
41
|
-
{
|
|
42
|
-
src: currentTeam.result.logoUrl,
|
|
43
|
-
className: clsx.clsx(ProfileMenu_module.default.profileImage, {
|
|
44
|
-
[ProfileMenu_module.default.profileImageHighlight]: permissions.canUpgradePlan(jwt)
|
|
45
|
-
}),
|
|
46
|
-
alt: "Team Logo"
|
|
47
|
-
}
|
|
48
|
-
) : /* @__PURE__ */ jsxRuntime.jsx(
|
|
49
|
-
"div",
|
|
50
|
-
{
|
|
51
|
-
className: clsx.clsx(ProfileMenu_module.default.userIconWrapper, "flex-row", "align-center", "items-center", {
|
|
52
|
-
[ProfileMenu_module.default.profileImageHighlight]: permissions.canUpgradePlan(jwt)
|
|
53
|
-
}),
|
|
54
|
-
children: /* @__PURE__ */ jsxRuntime.jsx(louis.UserIcon, { size: "25px" })
|
|
55
|
-
}
|
|
56
|
-
),
|
|
57
|
-
permissions.canUpgradePlan(jwt) && /* @__PURE__ */ jsxRuntime.jsx(UpgradeIcon.UpgradeIcon, { className: ProfileMenu_module.default.profileImageUpgradeIcon })
|
|
58
|
-
] });
|
|
59
|
-
},
|
|
60
|
-
children: /* @__PURE__ */ jsxRuntime.jsxs(louis.MenuList, { placement: "right-end", className: ProfileMenu_module.default.menuContainer, children: [
|
|
61
|
-
teamSwitch && /* @__PURE__ */ jsxRuntime.jsx(TeamSwitch.TeamSwitch, { onSwitchTeam: teamSwitch.onSwitchTeam }),
|
|
62
|
-
createTeam && /* @__PURE__ */ jsxRuntime.jsx(CreateNewTeam.CreateNewTeam, { onCreateTeam: createTeam.onCreateTeam }),
|
|
63
|
-
createTeamPlaceholder && /* @__PURE__ */ jsxRuntime.jsx(CreateNewTeamPlaceholder.CreateNewTeamPlaceholder, { onClick: createTeamPlaceholder.onClick }),
|
|
64
|
-
/* @__PURE__ */ jsxRuntime.jsx(TeamMenuItem.TeamMenuItem, {}),
|
|
65
|
-
upgradeMenuItem && /* @__PURE__ */ jsxRuntime.jsx(UpgradeMenuItem.UpgradeMenuItem, { href: upgradeMenuItem.href }),
|
|
66
|
-
/* @__PURE__ */ jsxRuntime.jsx(BillingMenuItem.BillingMenuItem, {}),
|
|
67
|
-
/* @__PURE__ */ jsxRuntime.jsx(TeamSettingsMenuItem.TeamSettingsMenuItem, {}),
|
|
68
|
-
/* @__PURE__ */ jsxRuntime.jsx(ProviderMenuItem.ProviderMenuItem, {}),
|
|
69
|
-
/* @__PURE__ */ jsxRuntime.jsx(louis.MenuDivider, {}),
|
|
70
|
-
/* @__PURE__ */ jsxRuntime.jsx(ProfileSettingsMenuItem.ProfileSettingsMenuItem, { ...profileSettings ?? {} }),
|
|
71
|
-
darkModeToggle && /* @__PURE__ */ jsxRuntime.jsx(DarkModeToggle.DarkModeToggle, { ...darkModeToggle }),
|
|
72
|
-
(permissions.canAccessProfileSettings(jwt) || darkModeToggle) && /* @__PURE__ */ jsxRuntime.jsx(louis.MenuDivider, {}),
|
|
73
|
-
/* @__PURE__ */ jsxRuntime.jsx(louis.MenuItem, { href: "/login?action=logout", children: "Logout" })
|
|
74
|
-
] })
|
|
75
|
-
}
|
|
76
|
-
);
|
|
77
|
-
};
|
|
78
|
-
exports.ProfileMenu = ProfileMenu;
|
|
3
|
+
const React = require("react");
|
|
4
|
+
const SidebarContext = React.createContext({});
|
|
5
|
+
exports.SidebarContext = SidebarContext;
|
|
79
6
|
//# sourceMappingURL=harmony112.cjs.map
|
package/dist/harmony112.cjs.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"harmony112.cjs","sources":["../src/components/Sidebar/
|
|
1
|
+
{"version":3,"file":"harmony112.cjs","sources":["../src/components/Sidebar/SidebarContext.ts"],"sourcesContent":["import { createContext, useContext } from 'react'\nimport type { SidebarContextProps } from './types'\n\nexport const SidebarContext = createContext({} as SidebarContextProps)\n\nexport const useSidebar = () => {\n\tconst context = useContext(SidebarContext)\n\n\tif (!context) {\n\t\tthrow new Error(\n\t\t\t'You are using useSidebar hook outside its context. Please review your code implementation',\n\t\t)\n\t}\n\n\treturn context\n}\n"],"names":["createContext"],"mappings":";;;AAGa,MAAA,iBAAiBA,MAAc,cAAA,CAAyB,CAAA;;"}
|
package/dist/harmony112.mjs
CHANGED
|
@@ -1,79 +1,6 @@
|
|
|
1
|
-
import {
|
|
2
|
-
|
|
3
|
-
import { CreateNewTeam } from "./harmony135.mjs";
|
|
4
|
-
import { CreateNewTeamPlaceholder } from "./harmony136.mjs";
|
|
5
|
-
import { DarkModeToggle } from "./harmony137.mjs";
|
|
6
|
-
import { ProfileSettingsMenuItem } from "./harmony138.mjs";
|
|
7
|
-
import { ProviderMenuItem } from "./harmony139.mjs";
|
|
8
|
-
import { TeamMenuItem } from "./harmony140.mjs";
|
|
9
|
-
import { TeamSettingsMenuItem } from "./harmony141.mjs";
|
|
10
|
-
import { TeamSwitch } from "./harmony142.mjs";
|
|
11
|
-
import { UpgradeMenuItem } from "./harmony143.mjs";
|
|
12
|
-
import { useSidebar } from "./harmony113.mjs";
|
|
13
|
-
import { Menu, MenuList, MenuDivider, MenuItem, UserIcon } from "@lokalise/louis";
|
|
14
|
-
import { canAccessProfileSettings, canUpgradePlan } from "./harmony114.mjs";
|
|
15
|
-
import { clsx } from "./harmony93.mjs";
|
|
16
|
-
import styles from "./harmony144.mjs";
|
|
17
|
-
import { UpgradeIcon } from "./harmony145.mjs";
|
|
18
|
-
const ProfileMenu = ({ config }) => {
|
|
19
|
-
const {
|
|
20
|
-
jwt,
|
|
21
|
-
data: { currentTeam }
|
|
22
|
-
} = useSidebar();
|
|
23
|
-
const {
|
|
24
|
-
darkModeToggle,
|
|
25
|
-
teamSwitch,
|
|
26
|
-
createTeam,
|
|
27
|
-
createTeamPlaceholder,
|
|
28
|
-
upgradeMenuItem,
|
|
29
|
-
profileSettings
|
|
30
|
-
} = config;
|
|
31
|
-
return /* @__PURE__ */ jsx(
|
|
32
|
-
Menu,
|
|
33
|
-
{
|
|
34
|
-
menuButton: () => {
|
|
35
|
-
var _a;
|
|
36
|
-
return /* @__PURE__ */ jsxs("button", { className: styles.profileButton, "aria-label": "Profile menu", type: "button", children: [
|
|
37
|
-
((_a = currentTeam.result) == null ? void 0 : _a.logoUrl) ? /* @__PURE__ */ jsx(
|
|
38
|
-
"img",
|
|
39
|
-
{
|
|
40
|
-
src: currentTeam.result.logoUrl,
|
|
41
|
-
className: clsx(styles.profileImage, {
|
|
42
|
-
[styles.profileImageHighlight]: canUpgradePlan(jwt)
|
|
43
|
-
}),
|
|
44
|
-
alt: "Team Logo"
|
|
45
|
-
}
|
|
46
|
-
) : /* @__PURE__ */ jsx(
|
|
47
|
-
"div",
|
|
48
|
-
{
|
|
49
|
-
className: clsx(styles.userIconWrapper, "flex-row", "align-center", "items-center", {
|
|
50
|
-
[styles.profileImageHighlight]: canUpgradePlan(jwt)
|
|
51
|
-
}),
|
|
52
|
-
children: /* @__PURE__ */ jsx(UserIcon, { size: "25px" })
|
|
53
|
-
}
|
|
54
|
-
),
|
|
55
|
-
canUpgradePlan(jwt) && /* @__PURE__ */ jsx(UpgradeIcon, { className: styles.profileImageUpgradeIcon })
|
|
56
|
-
] });
|
|
57
|
-
},
|
|
58
|
-
children: /* @__PURE__ */ jsxs(MenuList, { placement: "right-end", className: styles.menuContainer, children: [
|
|
59
|
-
teamSwitch && /* @__PURE__ */ jsx(TeamSwitch, { onSwitchTeam: teamSwitch.onSwitchTeam }),
|
|
60
|
-
createTeam && /* @__PURE__ */ jsx(CreateNewTeam, { onCreateTeam: createTeam.onCreateTeam }),
|
|
61
|
-
createTeamPlaceholder && /* @__PURE__ */ jsx(CreateNewTeamPlaceholder, { onClick: createTeamPlaceholder.onClick }),
|
|
62
|
-
/* @__PURE__ */ jsx(TeamMenuItem, {}),
|
|
63
|
-
upgradeMenuItem && /* @__PURE__ */ jsx(UpgradeMenuItem, { href: upgradeMenuItem.href }),
|
|
64
|
-
/* @__PURE__ */ jsx(BillingMenuItem, {}),
|
|
65
|
-
/* @__PURE__ */ jsx(TeamSettingsMenuItem, {}),
|
|
66
|
-
/* @__PURE__ */ jsx(ProviderMenuItem, {}),
|
|
67
|
-
/* @__PURE__ */ jsx(MenuDivider, {}),
|
|
68
|
-
/* @__PURE__ */ jsx(ProfileSettingsMenuItem, { ...profileSettings ?? {} }),
|
|
69
|
-
darkModeToggle && /* @__PURE__ */ jsx(DarkModeToggle, { ...darkModeToggle }),
|
|
70
|
-
(canAccessProfileSettings(jwt) || darkModeToggle) && /* @__PURE__ */ jsx(MenuDivider, {}),
|
|
71
|
-
/* @__PURE__ */ jsx(MenuItem, { href: "/login?action=logout", children: "Logout" })
|
|
72
|
-
] })
|
|
73
|
-
}
|
|
74
|
-
);
|
|
75
|
-
};
|
|
1
|
+
import { createContext } from "react";
|
|
2
|
+
const SidebarContext = createContext({});
|
|
76
3
|
export {
|
|
77
|
-
|
|
4
|
+
SidebarContext
|
|
78
5
|
};
|
|
79
6
|
//# sourceMappingURL=harmony112.mjs.map
|
package/dist/harmony112.mjs.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"harmony112.mjs","sources":["../src/components/Sidebar/
|
|
1
|
+
{"version":3,"file":"harmony112.mjs","sources":["../src/components/Sidebar/SidebarContext.ts"],"sourcesContent":["import { createContext, useContext } from 'react'\nimport type { SidebarContextProps } from './types'\n\nexport const SidebarContext = createContext({} as SidebarContextProps)\n\nexport const useSidebar = () => {\n\tconst context = useContext(SidebarContext)\n\n\tif (!context) {\n\t\tthrow new Error(\n\t\t\t'You are using useSidebar hook outside its context. Please review your code implementation',\n\t\t)\n\t}\n\n\treturn context\n}\n"],"names":[],"mappings":";AAGa,MAAA,iBAAiB,cAAc,CAAyB,CAAA;"}
|
package/dist/harmony113.cjs
CHANGED
|
@@ -1,15 +1,21 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
3
|
-
const
|
|
4
|
-
const
|
|
5
|
-
const
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
3
|
+
const jsxRuntime = require("react/jsx-runtime");
|
|
4
|
+
const louis = require("@lokalise/louis");
|
|
5
|
+
const clsx = require("./harmony93.cjs");
|
|
6
|
+
const IconLink_module = require("./harmony131.cjs");
|
|
7
|
+
const IconLink = ({ label, to, icon: Icon }) => {
|
|
8
|
+
return /* @__PURE__ */ jsxRuntime.jsx(louis.Tooltip, { placement: "right", tooltip: label, children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
9
|
+
louis.Link,
|
|
10
|
+
{
|
|
11
|
+
"aria-label": label,
|
|
12
|
+
className: clsx.clsx(IconLink_module.default.link, {
|
|
13
|
+
[IconLink_module.default.active]: typeof window !== "undefined" && window.location.pathname.startsWith(to)
|
|
14
|
+
}),
|
|
15
|
+
href: to,
|
|
16
|
+
children: /* @__PURE__ */ jsxRuntime.jsx(Icon, { size: "25px" })
|
|
17
|
+
}
|
|
18
|
+
) });
|
|
13
19
|
};
|
|
14
|
-
exports.
|
|
20
|
+
exports.IconLink = IconLink;
|
|
15
21
|
//# sourceMappingURL=harmony113.cjs.map
|