Skip to content

Commit

Permalink
Merge branch 'master' into feat/conventional-commits-config
Browse files Browse the repository at this point in the history
  • Loading branch information
fahslaj committed Mar 13, 2024
2 parents 390ef38 + 73a8091 commit 777c361
Show file tree
Hide file tree
Showing 47 changed files with 960 additions and 394 deletions.
2 changes: 1 addition & 1 deletion docs/shared/monorepo-ci-azure.md
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ jobs:
- script: git branch --track main origin/main
# This line enables distribution
# The "--stop-agents-after" is optional, but allows idle agents to shut down once the "e2e-ci" targets have been requested
- script: npx nx-cloud start-ci-run --distribute-on="5 linux-medium-js" --stop-agents-after="e2e-ci"
# - script: npx nx-cloud start-ci-run --distribute-on="5 linux-medium-js" --stop-agents-after="e2e-ci"
- script: npm ci

- script: npx nx-cloud record -- nx format:check --base=$(BASE_SHA)
Expand Down
2 changes: 1 addition & 1 deletion docs/shared/monorepo-ci-bitbucket-pipelines.md
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ pipelines:
- export NX_BRANCH=$BITBUCKET_PR_ID
# This line enables distribution
# The "--stop-agents-after" is optional, but allows idle agents to shut down once the "e2e-ci" targets have been requested
- npx nx-cloud start-ci-run --distribute-on="5 linux-medium-js" --stop-agents-after="e2e-ci"
# - npx nx-cloud start-ci-run --distribute-on="5 linux-medium-js" --stop-agents-after="e2e-ci"
- npm ci

- npx nx-cloud record -- nx format:check
Expand Down
2 changes: 1 addition & 1 deletion docs/shared/monorepo-ci-circle-ci.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ jobs:
- checkout
# This line enables distribution
# The "--stop-agents-after" is optional, but allows idle agents to shut down once the "e2e-ci" targets have been requested
- run: npx nx-cloud start-ci-run --distribute-on="5 linux-medium-js" --stop-agents-after="e2e-ci"
# - run: npx nx-cloud start-ci-run --distribute-on="5 linux-medium-js" --stop-agents-after="e2e-ci"
- run: npm ci

- nx/set-shas
Expand Down
2 changes: 1 addition & 1 deletion docs/shared/monorepo-ci-github-actions.md
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ jobs:
cache: 'npm'
# This line enables distribution
# The "--stop-agents-after" is optional, but allows idle agents to shut down once the "e2e-ci" targets have been requested
- run: npx nx-cloud start-ci-run --distribute-on="5 linux-medium-js" --stop-agents-after="e2e-ci"
# - run: npx nx-cloud start-ci-run --distribute-on="5 linux-medium-js" --stop-agents-after="e2e-ci"
- run: npm ci

- uses: nrwl/nx-set-shas@v3
Expand Down
2 changes: 1 addition & 1 deletion docs/shared/monorepo-ci-gitlab.md
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ main:
script:
# Connect your workspace on <%= nxCloudHost %> and uncomment this to enable task distribution.
# The "--stop-agents-after" is optional, but allows idle agents to shut down once the "e2e-ci" targets have been requested
- npx nx-cloud start-ci-run --distribute-on="5 linux-medium-js" --stop-agents-after="e2e-ci"
# - npx nx-cloud start-ci-run --distribute-on="5 linux-medium-js" --stop-agents-after="e2e-ci"

- npm ci --cache .npm --prefer-offline
- NX_HEAD=$CI_COMMIT_SHA
Expand Down
4 changes: 2 additions & 2 deletions docs/shared/monorepo-ci-jenkins.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ pipeline {
steps {
// This line enables distribution
// The "--stop-agents-after" is optional, but allows idle agents to shut down once the "e2e-ci" targets have been requested
sh "npx nx-cloud start-ci-run --distribute-on='5 linux-medium-js' --stop-agents-after='e2e-ci'"
// sh "npx nx-cloud start-ci-run --distribute-on='5 linux-medium-js' --stop-agents-after='e2e-ci'"
sh "npm ci"
sh "npx nx-cloud record -- nx format:check"
sh "npx nx affected --base=HEAD~1 -t lint test build e2e-ci"
Expand All @@ -33,7 +33,7 @@ pipeline {
steps {
// This line enables distribution
// The "--stop-agents-after" is optional, but allows idle agents to shut down once the "e2e-ci" targets have been requested
sh "npx nx-cloud start-ci-run --distribute-on='5 linux-medium-js' --stop-agents-after='e2e-ci'"
// sh "npx nx-cloud start-ci-run --distribute-on='5 linux-medium-js' --stop-agents-after='e2e-ci'"
sh "npm ci"
sh "npx nx-cloud record -- nx format:check"
sh "npx nx affected --base origin/${env.CHANGE_TARGET} -t lint test build e2e-ci"
Expand Down
5 changes: 3 additions & 2 deletions nx-dev/feature-ai/src/lib/error-message.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ import {
ExclamationTriangleIcon,
XCircleIcon,
} from '@heroicons/react/24/outline';
import Link from 'next/link';

function ErrorMessage({ error }: { error: any }): JSX.Element {
try {
Expand All @@ -28,12 +29,12 @@ function ErrorMessage({ error }: { error: any }): JSX.Element {
</h3>
<div className="mt-2 text-sm text-yellow-700">
Sorry, I don't know how to help with that. You can visit the{' '}
<a
<Link
href="https://nx.dev/getting-started/intro"
className="underline"
>
Nx documentation
</a>{' '}
</Link>{' '}
for more info.
</div>
</div>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ import {
MagnifyingGlassIcon,
InformationCircleIcon,
} from '@heroicons/react/24/outline';
import Link from 'next/link';

export function RelatedDocumentsSection({
relatedCategories,
Expand Down Expand Up @@ -50,13 +51,13 @@ function CategoryBox({ category }: { category: RelatedDocumentsCategory }) {
key={d.id}
className="flex justify-between items-center py-1 pl-0 text-sm"
>
<a
<Link
href={d.path}
className="no-underline hover:underline hover:text-sky-600 dark:hover:text-sky-400 flex-grow flex justify-between items-center"
>
<span>{d.name}</span>
<ArrowRightIcon className="w-4 h-4 text-slate-500 dark:text-slate-400" />
</a>
</Link>
</li>
))}
</ul>
Expand Down
8 changes: 4 additions & 4 deletions nx-dev/feature-package-schema-viewer/src/lib/content.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -125,13 +125,13 @@ export function Content({
>
{schemaViewModel.type}
</div>
<a
<Link
className="relative mx-4 inline-flex rounded-md border border-green-100 bg-green-50 px-4 py-2 text-xs font-medium text-green-600 dark:border-green-900 dark:bg-green-900/30 dark:text-green-400"
href="/recipes/other/rescope"
title="Nx 16 package name changes"
>
Rescope @nrwl to @nx
</a>
</Link>
{schemaViewModel.deprecated && (
<div
aria-hidden="true"
Expand Down Expand Up @@ -159,7 +159,7 @@ export function Content({
>
{schemaViewModel.packageName}
</Link>
<a
<Link
href={schemaViewModel.schemaGithubUrl}
target="_blank"
rel="noreferrer"
Expand All @@ -177,7 +177,7 @@ export function Content({
></path>
</svg>
See schema
</a>
</Link>
</div>
</div>

Expand Down
13 changes: 7 additions & 6 deletions nx-dev/feature-package-schema-viewer/src/lib/ui/headings.tsx
Original file line number Diff line number Diff line change
@@ -1,18 +1,19 @@
import { LinkIcon } from '@heroicons/react/24/solid';
import { slugify } from '../slugify.utils';
import Link from 'next/link';

export const Heading1 = ({ title }: { title: string }) => (
<h1
id={slugify(title)}
className="group mb-5 text-4xl font-extrabold tracking-tight text-slate-900 dark:text-slate-100"
>
<span>{title}</span>
<a aria-hidden="true" tabIndex={-1} href={'#' + slugify(title)}>
<Link aria-hidden="true" tabIndex={-1} href={'#' + slugify(title)}>
<LinkIcon
role="img"
className="ml-2 mb-1 inline h-5 w-5 opacity-0 group-hover:opacity-100"
/>
</a>
</Link>
</h1>
);

Expand All @@ -22,12 +23,12 @@ export const Heading2 = ({ title }: { title: string }) => (
className="group mb-5 text-2xl font-bold tracking-tight text-slate-800 dark:text-slate-200"
>
<span>{title}</span>
<a aria-hidden="true" tabIndex={-1} href={'#' + slugify(title)}>
<Link aria-hidden="true" tabIndex={-1} href={'#' + slugify(title)}>
<LinkIcon
role="img"
className="ml-2 mb-1 inline h-5 w-5 opacity-0 group-hover:opacity-100"
/>
</a>
</Link>
</h2>
);

Expand All @@ -37,11 +38,11 @@ export const Heading3 = ({ title }: { title: string }) => (
className="group text-xl font-semibold tracking-tight text-slate-700 dark:text-slate-300"
>
<span>{title}</span>
<a aria-hidden="true" tabIndex={-1} href={'#' + slugify(title)}>
<Link aria-hidden="true" tabIndex={-1} href={'#' + slugify(title)}>
<LinkIcon
role="img"
className="ml-2 mb-1 inline h-5 w-5 opacity-0 group-hover:opacity-100"
/>
</a>
</Link>
</h3>
);
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
import Link from 'next/link';

export function TopSchemaLayout({
name,
url,
Expand All @@ -15,13 +17,13 @@ export function TopSchemaLayout({
>
Package
</div>
<a
<Link
className="relative mx-4 inline-flex rounded-md border border-green-100 bg-green-50 px-4 py-2 text-xs font-medium text-green-600 dark:border-green-900 dark:bg-green-900/30 dark:text-green-400"
href="/recipes/other/rescope"
title="Nx 16 package name changes"
>
Rescope @nrwl to @nx
</a>
</Link>
</div>
<div className="relative z-0 inline-flex flex-shrink-0">
<a
Expand Down
5 changes: 3 additions & 2 deletions nx-dev/nx-dev/pages/_app.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ import { useRouter } from 'next/router';
import Script from 'next/script';
import { useEffect } from 'react';
import '../styles/main.css';
import Link from 'next/link';

export default function CustomApp({
Component,
Expand Down Expand Up @@ -66,14 +67,14 @@ export default function CustomApp({
/>
<meta name="viewport" content="width=device-width, initial-scale=1" />
</Head>
<a
<Link
id="skip-to-content-link"
href="#main"
tabIndex={0}
className="absolute top-3 left-8 -translate-y-24 rounded-md bg-green-400 px-4 py-2 text-white transition focus:translate-y-0"
>
Skip to content
</a>
</Link>
<Component {...pageProps} />
{/* Global Site Tag (gtag.js) - Google Analytics */}
<Script
Expand Down
5 changes: 3 additions & 2 deletions nx-dev/nx-dev/pages/changelog.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ import { useNavToggle } from '../lib/navigation-toggle.effect';
import { menusApi } from '../lib/menus.api';
import { MenuItem } from '@nx/nx-dev/models-menu';
import { getBasicNxSection } from '@nx/nx-dev/data-access-menu';
import Link from 'next/link';

interface ChangelogEntry {
version: string;
Expand Down Expand Up @@ -269,9 +270,9 @@ export default function Changelog(props: ChangeLogProps): JSX.Element {
/>{' '}
v{changelog.version.split('.').slice(0, 2).join('.')}
</a>
<a aria-hidden="true" href={`#${changelog.version}`}>
<Link aria-hidden="true" href={`#${changelog.version}`}>
<LinkIcon className="ml-2 mb-1 inline h-5 w-5 opacity-0 group-hover:opacity-100" />
</a>
</Link>
</p>
<p className="py-0.5 text-xs leading-5 text-slate-400 dark:text-slate-500">
<time
Expand Down
4 changes: 2 additions & 2 deletions nx-dev/nx-dev/pages/nx-api/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -110,9 +110,9 @@ export default function Packages({
<p>
In version 16, we have rescoped our packages to{' '}
<code>@nx/*</code> from <code>@nrwl/*</code>.{' '}
<a href="/recipes/other/rescope" className="underline">
<Link href="/recipes/other/rescope" className="underline">
Read more about the rescope ≫
</a>
</Link>
</p>
</section>
<section id="packages-section" className="py-12">
Expand Down
4 changes: 2 additions & 2 deletions nx-dev/ui-common/src/lib/documentation-header.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -251,14 +251,14 @@ export function DocumentationHeader({
{/* <span className="relative inline-flex h-3 w-3 rounded-full bg-blue-500 dark:bg-sky-500" />*/}
{/*</span>*/}Launch Nx
</Link>
<a
<Link
href="https://nx.app/enterprise?utm_source=nx.dev&utm_medium=header-menu"
target="_blank"
title="Contact us"
className="hidden px-3 py-2 font-medium leading-tight hover:text-blue-500 dark:text-slate-200 dark:hover:text-sky-500 md:inline-flex"
>
Contact us
</a>
</Link>
</nav>
</div>
<div className="hidden flex-grow lg:flex">{/* SPACER */}</div>
Expand Down
4 changes: 2 additions & 2 deletions nx-dev/ui-common/src/lib/header.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -236,7 +236,7 @@ export function Header(): JSX.Element {
<div className="relative mx-auto flex w-full items-center justify-between p-4 lg:hidden">
<div className="flex flex-shrink-0">
{/*LOGO*/}
<a
<Link
href="/"
className="flex items-center text-slate-900 dark:text-white"
>
Expand All @@ -250,7 +250,7 @@ export function Header(): JSX.Element {
<title>Nx</title>
<path d="M11.987 14.138l-3.132 4.923-5.193-8.427-.012 8.822H0V4.544h3.691l5.247 8.833.005-3.998 3.044 4.759zm.601-5.761c.024-.048 0-3.784.008-3.833h-3.65c.002.059-.005 3.776-.003 3.833h3.645zm5.634 4.134a2.061 2.061 0 0 0-1.969 1.336 1.963 1.963 0 0 1 2.343-.739c.396.161.917.422 1.33.283a2.1 2.1 0 0 0-1.704-.88zm3.39 1.061c-.375-.13-.8-.277-1.109-.681-.06-.08-.116-.17-.176-.265a2.143 2.143 0 0 0-.533-.642c-.294-.216-.68-.322-1.18-.322a2.482 2.482 0 0 0-2.294 1.536 2.325 2.325 0 0 1 4.002.388.75.75 0 0 0 .836.334c.493-.105.46.36 1.203.518v-.133c-.003-.446-.246-.55-.75-.733zm2.024 1.266a.723.723 0 0 0 .347-.638c-.01-2.957-2.41-5.487-5.37-5.487a5.364 5.364 0 0 0-4.487 2.418c-.01-.026-1.522-2.39-1.538-2.418H8.943l3.463 5.423-3.379 5.32h3.54l1.54-2.366 1.568 2.366h3.541l-3.21-5.052a.7.7 0 0 1-.084-.32 2.69 2.69 0 0 1 2.69-2.691h.001c1.488 0 1.736.89 2.057 1.308.634.826 1.9.464 1.9 1.541a.707.707 0 0 0 1.066.596zm.35.133c-.173.372-.56.338-.755.639-.176.271.114.412.114.412s.337.156.538-.311c.104-.231.14-.488.103-.74z" />
</svg>
</a>
</Link>
{/*MENU*/}
<div className="ml-4 flex flex-shrink-0">
<Popover className="">
Expand Down
5 changes: 3 additions & 2 deletions nx-dev/ui-common/src/lib/plugin-card.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ import {
ClockIcon,
StarIcon,
} from '@heroicons/react/24/outline';
import Link from 'next/link';

export interface PluginCardProps {
name: string;
Expand Down Expand Up @@ -41,7 +42,7 @@ export function PluginCard({
</svg>{' '}
<span className="truncate">{name}</span>
</h3>
<a
<Link
href={url}
target={isOfficial ? undefined : '_blank'}
rel={isOfficial ? undefined : 'noreferrer'}
Expand Down Expand Up @@ -80,7 +81,7 @@ export function PluginCard({
)}
</div>
</div>
</a>
</Link>
</div>
</div>
);
Expand Down
5 changes: 3 additions & 2 deletions nx-dev/ui-community/src/lib/connect-with-us.tsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
import { EnvelopeIcon } from '@heroicons/react/24/solid';
import { SectionHeading } from '@nx/nx-dev/ui-common';
import Link from 'next/link';

export function ConnectWithUs(): JSX.Element {
return (
Expand All @@ -18,9 +19,9 @@ export function ConnectWithUs(): JSX.Element {
</p>
<p className="py-4">
Looking for community plugins? Find them listed in the{' '}
<a href="/plugin-registry" className="underline font-semibold">
<Link href="/plugin-registry" className="underline font-semibold">
plugin registry
</a>
</Link>
.
</p>
</div>
Expand Down
6 changes: 4 additions & 2 deletions nx-dev/ui-conference/src/lib/launch-week/intro.tsx
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
import Link from 'next/link';

export function LaunchNxIntro() {
return (
<div className="mx-auto max-w-screen-lg px-5 py-5 xl:max-w-screen-xl">
Expand Down Expand Up @@ -39,9 +41,9 @@ export function LaunchNxIntro() {
</h3>
<p className="mb-6 sm:text-lg">
Missed our Launch Nx Conf? Then follow up with the{' '}
<a href="#announcements" className="underline">
<Link href="#announcements" className="underline">
announcements
</a>{' '}
</Link>{' '}
below or watch the conference recording:
</p>

Expand Down
Loading

0 comments on commit 777c361

Please sign in to comment.