Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions projects/core/src/avatar/avatar.examples.ts
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ export const Default = {
export const Image = {
render: () => html`
<nve-avatar>
<img src="static/images/test-image-1.svg" alt="User Avatar" />
<img src="/static/images/test-image-1.svg" alt="User Avatar" />
</nve-avatar>
`};

Expand Down Expand Up @@ -100,4 +100,4 @@ export const Color = {
<nve-avatar color="brand-green">AV</nve-avatar>
</div>
`
}
}
4 changes: 2 additions & 2 deletions projects/core/src/card/card.examples.ts
Original file line number Diff line number Diff line change
Expand Up @@ -65,13 +65,13 @@ export const MediaCard = {
render: () => html`
<div nve-layout="grid gap:md span-items:6 align:stretch" style="max-width: 900px">
<nve-card style="height: 100%; width: 100%;">
<img src="static/images/test-image-1.svg" alt="example visualization for media card demo" loading="lazy" style="width: 100%; object-fit: cover;" />
<img src="/static/images/test-image-1.svg" alt="example visualization for media card demo" loading="lazy" style="width: 100%; object-fit: cover;" />
<nve-card-content>
<p nve-text="body" style="min-height: 24px">card content</p>
</nve-card-content>
</nve-card>
<nve-card style="height: 100%; width: 100%;">
<img src="static/images/test-image-1.svg" alt="example visualization for media card demo" loading="lazy" style="width: 100%; object-fit: cover;" />
<img src="/static/images/test-image-1.svg" alt="example visualization for media card demo" loading="lazy" style="width: 100%; object-fit: cover;" />
<nve-card-content>
<p nve-text="body" style="min-height: 24px">card content</p>
</nve-card-content>
Expand Down
2 changes: 1 addition & 1 deletion projects/core/src/page/page.examples.ts
Original file line number Diff line number Diff line change
Expand Up @@ -946,7 +946,7 @@ export const LayoutCardGrid = {
<section nve-layout="grid span-items:3 gap:md">
${new Array(24).fill('').map(() => html`
<nve-card style="height: 100%; width: 100%;">
<img src="static/images/test-image-1.svg" alt="example visualization for media card demo" loading="lazy" style="width: 100%; object-fit: cover;" />
<img src="/static/images/test-image-1.svg" alt="example visualization for media card demo" loading="lazy" style="width: 100%; object-fit: cover;" />
<nve-card-content>
<p nve-text="body">•︎•︎•︎ •︎•︎•︎ •︎•︎•︎</p>
</nve-card-content>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -171,7 +171,7 @@ export const Custom = {
<nve-icon-button icon-name="map-pin" readonly></nve-icon-button>
<input value="37.3706254,-121.9671894" disabled aria-label="map coordinates" />
</nve-input>
<img src="static/images/test-map-2.webp" width="300px" alt="non-interactive demo map" />
<img src="/static/images/test-map-2.webp" width="300px" alt="non-interactive demo map" />
</nve-dropdown>
`
}
Expand Down
2 changes: 1 addition & 1 deletion projects/internals/patterns/src/templates.examples.ts
Original file line number Diff line number Diff line change
Expand Up @@ -584,7 +584,7 @@ export const MediaListView = {
{ id: 'av-2833', route: 'Mountain pass', vehicle: 'av-prototype-041', duration: '5h 06m', distance: '312 km' },
].map(d => html`
<nve-card style="height: 100%; width: 100%;">
<img src="static/images/test-image-1.svg" alt="route preview for ${d.route}" loading="lazy" style="width: 100%; object-fit: cover; max-height: 200px;" />
<img src="/static/images/test-image-1.svg" alt="route preview for ${d.route}" loading="lazy" style="width: 100%; object-fit: cover; max-height: 200px;" />
<nve-card-header>
<h3 nve-text="heading sm">${d.route}</h3>
</nve-card-header>
Expand Down
13 changes: 9 additions & 4 deletions projects/site/src/_11ty/layouts/links.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,15 @@ import { relative } from 'node:path';
import { fileURLToPath } from 'node:url';
import { describe, expect, it } from 'vitest';

const RELATIVE_INTERNAL_LINK_PATTERN = /(?:href=["']|]\()(?:\.\/)?(?:docs|examples|starters)\//;
const BASE_PREFIXED_INTERNAL_LINK_PATTERN = /(?:href=["']|]\()\/elements\/(?:docs|examples|starters)\//;
const JS_RELATIVE_INTERNAL_LINK_PATTERN = /\bhref:\s*['"](?:\.\/)?(?:docs|examples|starters)\//;
const JS_BASE_PREFIXED_INTERNAL_LINK_PATTERN = /\bhref:\s*['"]\/elements\/(?:docs|examples|starters)\//;
const AUTHORED_SITE_SEGMENTS = '(?:docs|examples|starters|static)';
const RELATIVE_INTERNAL_LINK_PATTERN = new RegExp(`(?:href=["']|src=["']|]\\()(?:\\.\\/)?${AUTHORED_SITE_SEGMENTS}\\/`);
const BASE_PREFIXED_INTERNAL_LINK_PATTERN = new RegExp(
`(?:href=["']|src=["']|]\\()\\/elements\\/${AUTHORED_SITE_SEGMENTS}\\/`
);
const JS_RELATIVE_INTERNAL_LINK_PATTERN = new RegExp(`\\b(?:href|src):\\s*['"](?:\\.\\/)?${AUTHORED_SITE_SEGMENTS}\\/`);
const JS_BASE_PREFIXED_INTERNAL_LINK_PATTERN = new RegExp(
`\\b(?:href|src):\\s*['"]\\/elements\\/${AUTHORED_SITE_SEGMENTS}\\/`
);

async function getAuthoredFiles(dir: URL): Promise<URL[]> {
const entries = await readdir(dir, { withFileTypes: true });
Expand Down
2 changes: 1 addition & 1 deletion projects/site/src/_internal/theme-preview/theme-preview.ts
Original file line number Diff line number Diff line change
Expand Up @@ -215,7 +215,7 @@ export class ThemePreview extends LitElement {
<div class="bento-box-column">
<nve-card>
<img
src="static/images/test-image-1.svg"
src="/static/images/test-image-1.svg"
alt="example visualization for media card demo"
loading="lazy"
style="width: calc(var(--nve-ref-scale-size) * 160px + var(--nve-ref-scale-text) * 160px); object-fit: cover; aspect-ratio: 16 / 9;" />
Expand Down
4 changes: 2 additions & 2 deletions projects/site/src/docs/about/contributions.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ This guide facilitates and streamlines your contribution process and helps ensur
The team may not accept all contributions or may need more time before implementation. Take into account that a design system component or pattern requires a significant amount of time. Each use case, many apps, frameworks, API design, and guidelines applicable to all must be carefully considered.
The main focus is to enable you to deliver value to your users.

<img src="static/images/contributions.drawio.svg" alt="Flowchart for evaluating a potential Elements contribution against existing features, similar patterns, and whether to use, request, or build custom functionality." style="padding: 12px 0 0 0" />
<img src="/static/images/contributions.drawio.svg" alt="Flowchart for evaluating a potential Elements contribution against existing features, similar patterns, and whether to use, request, or build custom functionality." style="padding: 12px 0 0 0" />

## Types of Contributions

Expand All @@ -37,7 +37,7 @@ The main focus is to enable you to deliver value to your users.

## Bug Reporting

1. **Create a new issue** using the [bug template]({{ELEMENTS_REPO_BASE_URL}}/-/issues/new?issuable_template=default), providing as much detail as you can about the problem and how to reproduce it. Use the [Elements Playground]({{ELEMENTS_PLAYGROUND_BASE_URL}}/ui/elements-playground) to provide a minimal reproducible example if possible.
1. **Create a new issue** using the [bug template]({{ELEMENTS_REPO_BASE_URL}}/-/issues/new?issuable_template=default), providing as much detail as you can about the problem and how to reproduce it. Use the [Elements Playground]({{ELEMENTS_PLAYGROUND_BASE_URL}}/ui/elements-playground/browse.html) to provide a minimal reproducible example if possible.

## Feature Requests

Expand Down
2 changes: 1 addition & 1 deletion projects/site/src/docs/about/requests.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,4 +8,4 @@

# {{ title }}

<img src="static/images/requests.drawio.svg" alt="Flowchart for reviewing Elements requests across feature, support, and bug paths, including backlog, implementation, workaround, fix, and release decisions." class="full-width" />
<img src="/static/images/requests.drawio.svg" alt="Flowchart for reviewing Elements requests across feature, support, and bug paths, including backlog, implementation, workaround, fix, and release decisions." class="full-width" />
4 changes: 2 additions & 2 deletions projects/site/src/docs/about/support.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@

## Frameworks

Elements [supports a wide variety](https://custom-elements-everywhere.com) of JavaScript frameworks and libraries as well as vanilla JS. Read more at the [installation](/docs/about/installation/) page.
Elements [supports a wide variety](https://custom-elements-everywhere.com) of JavaScript frameworks and libraries as well as vanilla JS. Read more at the [installation](/docs/integrations/installation/) page.

<section nve-layout="row gap:sm align:wrap">
<nve-button>
Expand Down Expand Up @@ -49,7 +49,7 @@ Elements [supports a wide variety](https://custom-elements-everywhere.com) of Ja
<a href="/docs/integrations/solidjs/">{% svg-logo 'solidjs' '18' %} SolidJS</a>
</nve-button>
<nve-button>
<a href="/docs/about/installation/">{% svg-logo 'javascript' '18' %} JavaScript</a>
<a href="/docs/integrations/installation/">{% svg-logo 'javascript' '18' %} JavaScript</a>
</nve-button>
</section>

Expand Down
10 changes: 0 additions & 10 deletions projects/site/src/docs/foundations/themes/index.11ty.js
Original file line number Diff line number Diff line change
Expand Up @@ -81,16 +81,6 @@ ${getThemeDemo('debug')}
\`\`\`
${getThemeDemo('high-contrast')}
## Brand
The \`brand\` theme is a set of themes that are designed to be used with the \`@nvidia-elements/brand\` package.
[Learn more](/docs/labs/brand/).
\`\`\`css
\`\`\`
${getThemeDemo('brand-dark')}
`,
'md'
);
Expand Down
2 changes: 1 addition & 1 deletion projects/site/src/docs/integrations/angular.md
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ Properties and events then work via the standard Angular template syntax.

Elements provides a suite of form components that leverage standard HTML input types. This enables frameworks to take advantage of built in framework features like [Angular Reactive Forms](https://angular.io/guide/reactive-forms) for managing form validation and state.

<nve-alert>To integrate custom form control types into Elements checkout the <a nve-text="link" href="/docs/elements/forms/controls/#custom-controls" onClick="location.reload()">custom control</a> documentation.</nve-alert>
<nve-alert>To integrate custom form control types into Elements checkout the <a nve-text="link" href="/docs/elements/control/#custom-controls" onClick="location.reload()">custom control</a> documentation.</nve-alert>

```html
<form [formGroup]="form" (ngSubmit)="submit()">
Expand Down