diff --git a/package-lock.json b/package-lock.json index f74757f108..e5f33eec96 100644 --- a/package-lock.json +++ b/package-lock.json @@ -8659,6 +8659,19 @@ "resolved": "services/web", "link": true }, + "node_modules/@phosphor-icons/react": { + "version": "2.1.7", + "resolved": "https://registry.npmjs.org/@phosphor-icons/react/-/react-2.1.7.tgz", + "integrity": "sha512-g2e2eVAn1XG2a+LI09QU3IORLhnFNAFkNbo2iwbX6NOKSLOwvEMmTa7CgOzEbgNWR47z8i8kwjdvYZ5fkGx1mQ==", + "license": "MIT", + "engines": { + "node": ">=10" + }, + "peerDependencies": { + "react": ">= 16.8", + "react-dom": ">= 16.8" + } + }, "node_modules/@pkgjs/parseargs": { "version": "0.11.0", "resolved": "https://registry.npmjs.org/@pkgjs/parseargs/-/parseargs-0.11.0.tgz", @@ -41457,6 +41470,7 @@ "@overleaf/promise-utils": "*", "@overleaf/redis-wrapper": "*", "@overleaf/settings": "*", + "@phosphor-icons/react": "^2.1.7", "@slack/webhook": "^7.0.2", "@xmldom/xmldom": "^0.7.13", "accepts": "^1.3.7", @@ -51198,6 +51212,7 @@ "@overleaf/redis-wrapper": "*", "@overleaf/settings": "*", "@overleaf/stream-utils": "*", + "@phosphor-icons/react": "^2.1.7", "@pmmmwh/react-refresh-webpack-plugin": "^0.5.11", "@pollyjs/adapter-node-http": "^6.0.6", "@pollyjs/core": "^6.0.6", @@ -53338,6 +53353,12 @@ } } }, + "@phosphor-icons/react": { + "version": "2.1.7", + "resolved": "https://registry.npmjs.org/@phosphor-icons/react/-/react-2.1.7.tgz", + "integrity": "sha512-g2e2eVAn1XG2a+LI09QU3IORLhnFNAFkNbo2iwbX6NOKSLOwvEMmTa7CgOzEbgNWR47z8i8kwjdvYZ5fkGx1mQ==", + "requires": {} + }, "@pkgjs/parseargs": { "version": "0.11.0", "resolved": "https://registry.npmjs.org/@pkgjs/parseargs/-/parseargs-0.11.0.tgz", diff --git a/services/web/frontend/js/features/header-footer-react/index.tsx b/services/web/frontend/js/features/header-footer-react/index.tsx index 2ac25a090f..e808b58322 100644 --- a/services/web/frontend/js/features/header-footer-react/index.tsx +++ b/services/web/frontend/js/features/header-footer-react/index.tsx @@ -2,11 +2,17 @@ import ReactDOM from 'react-dom' import getMeta from '@/utils/meta' import DefaultNavbar from '@/features/ui/components/bootstrap-5/navbar/default-navbar' import Footer from '@/features/ui/components/bootstrap-5/footer/footer' +import { SplitTestProvider } from '@/shared/context/split-test-context' const navbarElement = document.getElementById('navbar-container') if (navbarElement) { const navbarProps = getMeta('ol-navbar') - ReactDOM.render(, navbarElement) + ReactDOM.render( + + + , + navbarElement + ) } const footerElement = document.getElementById('footer-container') diff --git a/services/web/frontend/js/features/project-list/components/sidebar/sidebar-ds-nav.tsx b/services/web/frontend/js/features/project-list/components/sidebar/sidebar-ds-nav.tsx index 9a965dc882..0a2942f944 100644 --- a/services/web/frontend/js/features/project-list/components/sidebar/sidebar-ds-nav.tsx +++ b/services/web/frontend/js/features/project-list/components/sidebar/sidebar-ds-nav.tsx @@ -1,11 +1,11 @@ import { useState } from 'react' import classnames from 'classnames' +import { Question, User } from '@phosphor-icons/react' import NewProjectButton from '../new-project-button' import SidebarFilters from './sidebar-filters' import AddAffiliation, { useAddAffiliation } from '../add-affiliation' import SurveyWidget from '../survey-widget' -import { usePersistedResize } from '../../../../shared/hooks/use-resize' -import MaterialIcon from '@/shared/components/material-icon' +import { usePersistedResize } from '@/shared/hooks/use-resize' import { Dropdown } from 'react-bootstrap-5' import getMeta from '@/utils/meta' import OLTooltip from '@/features/ui/components/ol/ol-tooltip' @@ -77,11 +77,18 @@ function SidebarDsNav() { }} >
- +
- +
- +
- +
  • @@ -68,7 +74,11 @@ export default function TagsList() { color: getTagColor(tag), }} > - + {isDsNav ? ( + + ) : ( + + )} {tag.name}{' '} diff --git a/services/web/frontend/js/features/ui/components/bootstrap-5/navbar/account-menu-items.tsx b/services/web/frontend/js/features/ui/components/bootstrap-5/navbar/account-menu-items.tsx index 45e1dc9c1b..cbd0d2c73f 100644 --- a/services/web/frontend/js/features/ui/components/bootstrap-5/navbar/account-menu-items.tsx +++ b/services/web/frontend/js/features/ui/components/bootstrap-5/navbar/account-menu-items.tsx @@ -5,6 +5,8 @@ import type { NavbarSessionUser } from '@/features/ui/components/types/navbar' import DropdownListItem from '@/features/ui/components/bootstrap-5/dropdown-list-item' import NavDropdownDivider from './nav-dropdown-divider' import NavDropdownLinkItem from './nav-dropdown-link-item' +import { useIsDsNav } from '@/features/project-list/components/use-is-ds-nav' +import { SignOut } from '@phosphor-icons/react' export function AccountMenuItems({ sessionUser, @@ -15,7 +17,7 @@ export function AccountMenuItems({ }) { const { t } = useTranslation() const logOutFormId = 'logOutForm' - + const isDsNav = useIsDsNav() return ( <> @@ -43,8 +45,10 @@ export function AccountMenuItems({ type="submit" form={logOutFormId} role="menuitem" + className="d-flex align-items-center justify-content-between" > - {t('log_out')} + {t('log_out')} + {isDsNav && }
    diff --git a/services/web/frontend/stylesheets/bootstrap-5/pages/project-list-ds-nav.scss b/services/web/frontend/stylesheets/bootstrap-5/pages/project-list-ds-nav.scss index 3416e2ce3e..3848181d20 100644 --- a/services/web/frontend/stylesheets/bootstrap-5/pages/project-list-ds-nav.scss +++ b/services/web/frontend/stylesheets/bootstrap-5/pages/project-list-ds-nav.scss @@ -239,6 +239,7 @@ &.show { background-color: var(--bg-accent-03); + color: var(--green-60); } &::after { diff --git a/services/web/package.json b/services/web/package.json index 6120345027..7dbdb04700 100644 --- a/services/web/package.json +++ b/services/web/package.json @@ -85,6 +85,7 @@ "@overleaf/promise-utils": "*", "@overleaf/redis-wrapper": "*", "@overleaf/settings": "*", + "@phosphor-icons/react": "^2.1.7", "@slack/webhook": "^7.0.2", "@xmldom/xmldom": "^0.7.13", "accepts": "^1.3.7",