Skip to content

Commit ef3d106

Browse files
committed
Merge remote-tracking branch 'origin/main' into feature/1826_license_changes
2 parents 18a58a1 + 9222620 commit ef3d106

File tree

127 files changed

+12191
-4591
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

127 files changed

+12191
-4591
lines changed

.github/workflows/autofix.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ jobs:
2020
steps:
2121
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
2222

23-
- uses: voidzero-dev/setup-vp@a03302daa50cf2f017c8c7345730c2740df207d6 # v1
23+
- uses: voidzero-dev/setup-vp@8ecb39174989ce55af90f45cf55b02738599831d # v1
2424
with:
2525
node-version: lts/*
2626
cache: true

.github/workflows/chromatic.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ jobs:
2626
repository: ${{ github.event.pull_request.head.repo.full_name || github.repository }}
2727
ref: ${{ github.event.pull_request.head.sha || github.sha }}
2828

29-
- uses: voidzero-dev/setup-vp@a03302daa50cf2f017c8c7345730c2740df207d6 # v1
29+
- uses: voidzero-dev/setup-vp@8ecb39174989ce55af90f45cf55b02738599831d # v1
3030
with:
3131
node-version: lts/*
3232
cache: true

.github/workflows/ci.yml

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ jobs:
2828
steps:
2929
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
3030

31-
- uses: voidzero-dev/setup-vp@a03302daa50cf2f017c8c7345730c2740df207d6 # v1
31+
- uses: voidzero-dev/setup-vp@8ecb39174989ce55af90f45cf55b02738599831d # v1
3232
with:
3333
node-version: lts/*
3434
run-install: false
@@ -46,7 +46,7 @@ jobs:
4646
steps:
4747
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
4848

49-
- uses: voidzero-dev/setup-vp@a03302daa50cf2f017c8c7345730c2740df207d6 # v1
49+
- uses: voidzero-dev/setup-vp@8ecb39174989ce55af90f45cf55b02738599831d # v1
5050
with:
5151
node-version: lts/*
5252
cache: true
@@ -61,7 +61,7 @@ jobs:
6161
steps:
6262
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
6363

64-
- uses: voidzero-dev/setup-vp@a03302daa50cf2f017c8c7345730c2740df207d6 # v1
64+
- uses: voidzero-dev/setup-vp@8ecb39174989ce55af90f45cf55b02738599831d # v1
6565
with:
6666
node-version: lts/*
6767
cache: true
@@ -82,7 +82,7 @@ jobs:
8282
steps:
8383
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
8484

85-
- uses: voidzero-dev/setup-vp@a03302daa50cf2f017c8c7345730c2740df207d6 # v1
85+
- uses: voidzero-dev/setup-vp@8ecb39174989ce55af90f45cf55b02738599831d # v1
8686
with:
8787
node-version: lts/*
8888
cache: true
@@ -114,7 +114,7 @@ jobs:
114114
steps:
115115
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
116116

117-
- uses: voidzero-dev/setup-vp@a03302daa50cf2f017c8c7345730c2740df207d6 # v1
117+
- uses: voidzero-dev/setup-vp@8ecb39174989ce55af90f45cf55b02738599831d # v1
118118
with:
119119
node-version: lts/*
120120
cache: true
@@ -137,7 +137,7 @@ jobs:
137137
steps:
138138
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
139139

140-
- uses: voidzero-dev/setup-vp@a03302daa50cf2f017c8c7345730c2740df207d6 # v1
140+
- uses: voidzero-dev/setup-vp@8ecb39174989ce55af90f45cf55b02738599831d # v1
141141
with:
142142
node-version: lts/*
143143
cache: true
@@ -158,7 +158,7 @@ jobs:
158158
steps:
159159
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
160160

161-
- uses: voidzero-dev/setup-vp@a03302daa50cf2f017c8c7345730c2740df207d6 # v1
161+
- uses: voidzero-dev/setup-vp@8ecb39174989ce55af90f45cf55b02738599831d # v1
162162
with:
163163
node-version: lts/*
164164
cache: true
@@ -173,7 +173,7 @@ jobs:
173173
steps:
174174
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
175175

176-
- uses: voidzero-dev/setup-vp@a03302daa50cf2f017c8c7345730c2740df207d6 # v1
176+
- uses: voidzero-dev/setup-vp@8ecb39174989ce55af90f45cf55b02738599831d # v1
177177
with:
178178
node-version: lts/*
179179
run-install: false

.github/workflows/lunaria.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ jobs:
2828
# Makes the action clone the entire git history
2929
fetch-depth: 0
3030

31-
- uses: voidzero-dev/setup-vp@a03302daa50cf2f017c8c7345730c2740df207d6 # v1
31+
- uses: voidzero-dev/setup-vp@8ecb39174989ce55af90f45cf55b02738599831d # v1
3232
with:
3333
node-version: lts/*
3434
cache: true

.github/workflows/release-pr.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ jobs:
2020
with:
2121
fetch-depth: 0
2222

23-
- uses: voidzero-dev/setup-vp@a03302daa50cf2f017c8c7345730c2740df207d6 # v1
23+
- uses: voidzero-dev/setup-vp@8ecb39174989ce55af90f45cf55b02738599831d # v1
2424
with:
2525
node-version: lts/*
2626
run-install: false

.github/workflows/release-tag.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ jobs:
2323
with:
2424
fetch-depth: 0
2525

26-
- uses: voidzero-dev/setup-vp@a03302daa50cf2f017c8c7345730c2740df207d6 # v1
26+
- uses: voidzero-dev/setup-vp@8ecb39174989ce55af90f45cf55b02738599831d # v1
2727
with:
2828
node-version: lts/*
2929
run-install: false
@@ -95,7 +95,7 @@ jobs:
9595
with:
9696
ref: release
9797

98-
- uses: voidzero-dev/setup-vp@a03302daa50cf2f017c8c7345730c2740df207d6 # v1
98+
- uses: voidzero-dev/setup-vp@8ecb39174989ce55af90f45cf55b02738599831d # v1
9999
with:
100100
node-version: lts/*
101101
registry-url: https://registry.npmjs.org
Lines changed: 69 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,69 @@
1+
name: remove-needs-review-on-review
2+
3+
on:
4+
pull_request_review:
5+
types:
6+
- submitted
7+
8+
jobs:
9+
remove-needs-review:
10+
name: 🏷️ Remove needs review label
11+
if: github.repository == 'npmx-dev/npmx.dev'
12+
runs-on: ubuntu-slim
13+
permissions:
14+
contents: read
15+
issues: write
16+
pull-requests: write
17+
steps:
18+
- name: 🏷️ Remove needs review label
19+
uses: actions/github-script@ed597411d8f924073f98dfc5c65a23a2325f34cd # v8.0.0
20+
with:
21+
script: |
22+
const pr = context.payload.pull_request;
23+
const review = context.payload.review;
24+
const LABEL = 'needs review';
25+
const reviewer = review?.user?.login;
26+
const author = pr.user?.login;
27+
const reviewerType = review?.user?.type;
28+
29+
if (!reviewer) {
30+
console.log('No reviewer login found in payload, skipping.');
31+
return;
32+
}
33+
34+
if (reviewerType === 'Bot') {
35+
console.log(`Skipping bot review from @${reviewer} on PR #${pr.number}.`);
36+
return;
37+
}
38+
39+
if (reviewer === author) {
40+
console.log(`Skipping self-review from @${reviewer} on PR #${pr.number}.`);
41+
return;
42+
}
43+
44+
if (!pr.labels.some(({ name }) => name === LABEL)) {
45+
console.log(`PR #${pr.number} does not have the "${LABEL}" label.`);
46+
return;
47+
}
48+
49+
const { data: permission } = await github.rest.repos.getCollaboratorPermissionLevel({
50+
owner: context.repo.owner,
51+
repo: context.repo.repo,
52+
username: reviewer,
53+
});
54+
55+
console.log(`Reviewer @${reviewer} permission is "${permission.permission}".`);
56+
57+
if (!['admin', 'maintain', 'write'].includes(permission.permission)) {
58+
console.log(`Reviewer @${reviewer} is not a maintainer, skipping.`);
59+
return;
60+
}
61+
62+
await github.rest.issues.removeLabel({
63+
owner: context.repo.owner,
64+
repo: context.repo.repo,
65+
issue_number: pr.number,
66+
name: LABEL,
67+
});
68+
69+
console.log(`Removed "${LABEL}" from PR #${pr.number}.`);

.storybook/docs/colors.mdx

Lines changed: 110 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,110 @@
1+
import { Meta, ColorPalette, ColorItem } from '@storybook/addon-docs/blocks'
2+
import { theme } from '../../uno.theme.ts'
3+
4+
<Meta title="Colors" tags={['hide-toolbar']} />
5+
6+
# Colors
7+
8+
The npmx color system is built on CSS custom properties with support for light/dark themes and multiple background variants.
9+
10+
Color values are defined in `uno.theme.ts`.
11+
12+
## Background Colors
13+
14+
<ColorPalette>
15+
<ColorItem
16+
title="Background"
17+
subtitle="Main background colors"
18+
colors={Object.entries(theme.colors.bg).reduce(
19+
(acc, [key, value]) => ({
20+
...acc,
21+
[key === 'DEFAULT' ? 'bg' : `bg-${key}`]: value,
22+
}),
23+
{},
24+
)}
25+
/>
26+
</ColorPalette>
27+
28+
## Foreground Colors
29+
30+
<ColorPalette>
31+
<ColorItem
32+
title="Foreground"
33+
subtitle="Text and content colors"
34+
colors={Object.entries(theme.colors.fg).reduce(
35+
(acc, [key, value]) => ({
36+
...acc,
37+
[key === 'DEFAULT' ? 'fg' : `fg-${key}`]: value,
38+
}),
39+
{},
40+
)}
41+
/>
42+
</ColorPalette>
43+
44+
## Border Colors
45+
46+
<ColorPalette>
47+
<ColorItem
48+
title="Border"
49+
subtitle="Border and separator colors"
50+
colors={Object.entries(theme.colors.border).reduce(
51+
(acc, [key, value]) => ({
52+
...acc,
53+
[key === 'DEFAULT' ? 'border' : `border-${key}`]: value,
54+
}),
55+
{},
56+
)}
57+
/>
58+
</ColorPalette>
59+
60+
## Accent Colors
61+
62+
<ColorPalette>
63+
<ColorItem
64+
title="Primary Accent"
65+
subtitle="User-settable accent color"
66+
colors={Object.entries(theme.colors.accent).reduce(
67+
(acc, [key, value]) => ({
68+
...acc,
69+
[key === 'DEFAULT' ? 'accent' : `accent-${key}`]: value,
70+
}),
71+
{},
72+
)}
73+
/>
74+
</ColorPalette>
75+
76+
## Syntax Highlighting
77+
78+
<ColorPalette>
79+
<ColorItem
80+
title="Syntax"
81+
subtitle="Code syntax highlighting colors"
82+
colors={theme.colors.syntax}
83+
/>
84+
</ColorPalette>
85+
86+
## Badge Colors
87+
88+
<ColorPalette>
89+
<ColorItem
90+
title="Badges"
91+
subtitle="Badge background and text colors"
92+
colors={theme.colors.badge}
93+
/>
94+
</ColorPalette>
95+
96+
## Provider Brand Colors
97+
98+
<ColorPalette>
99+
<ColorItem
100+
title="Provider Brand Colors"
101+
subtitle="Playground provider and framework brand colors"
102+
colors={theme.colors.provider}
103+
/>
104+
</ColorPalette>
105+
106+
---
107+
108+
## Related
109+
110+
- [Design System Guidelines](https://storybook.npmx.dev/?path=/docs/guidelines--docs)

.storybook/docs/guidelines.mdx

Lines changed: 86 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,86 @@
1+
import { Meta } from '@storybook/addon-docs/blocks'
2+
3+
<Meta title="Guidelines" tags={['hide-toolbar']} />
4+
5+
# Guidelines
6+
7+
## Containers
8+
9+
We use three container types depending on content density.
10+
11+
**Main Container** is the default layout container. It should be used for pages with minimal or non-text content (e.g. graphs, dashboards).
12+
13+
**Content Container** is used for text-heavy layouts. All long-form content must be placed inside this container. The maximum readable width is **768px**.
14+
15+
**Extra Container** is used for dense layouts (e.g. code, detailed views) where additional horizontal space is required.
16+
17+
A right sidebar (304px) may be used for secondary content when needed.
18+
19+
Text and input fields should not exceed **768px** in width
20+
21+
## Element Sizes
22+
23+
Interactive element sizes:
24+
25+
- 24 — 2xs (rare)
26+
- 28 — xs (compact)
27+
- 32 — sm (minimum recommended)
28+
- 36 — md (default)
29+
- 42 — lg
30+
- 48 — xl
31+
- 56 — 2xl
32+
- 64 — 3xl
33+
34+
## Typography
35+
36+
- Base font size: **16px**
37+
- Minimum font size: **14px** (use sparingly)
38+
39+
Text casing:
40+
41+
- **Uppercase** — for headings
42+
- **Lowercase** — for UI elements
43+
- **Normal** - for body content
44+
45+
[See Typography](https://storybook.npmx.dev/?path=/docs/tokens-typography--docs)
46+
47+
## Surfaces & Sections
48+
49+
To visually separate content blocks (grouped content, cards, settings sections), use subtle background variations:
50+
51+
- `bg-muted`
52+
- `bg-subtle`
53+
54+
## Borders & Radius
55+
56+
- subtle border
57+
- light border radius
58+
- soft "glass-like" appearance
59+
60+
Only avatars should have fully circular shapes.
61+
62+
## Colors
63+
64+
- Primary surfaces: **white** (`fg`)
65+
- Secondary or less important content: use softer, muted tones
66+
67+
[See Colors](https://storybook.npmx.dev/?path=/docs/tokens-colors--docs)
68+
69+
## Layout Stability
70+
71+
Interfaces must remain visually stable across screens and pages. Avoid layout shifts. If shifts are unavoidable, place elements where movement is not critical to user interaction.
72+
73+
## Responsiveness specifics
74+
75+
On smaller screens:
76+
77+
- Button text may be hidden (icons only)
78+
- Keyboard shortcuts may be hidden
79+
80+
## General Principles
81+
82+
- Preserve the meaning of elements (avoid links like button, etc)
83+
- Maintain sufficient spacing
84+
- Keep interfaces accessible
85+
- Prefer simple, predictable layouts
86+
- Design components to be easy to implement and scale

0 commit comments

Comments
 (0)