@rxova/brand 1.0.0 → 1.1.1
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/MIGRATION.md +3 -2
- package/README.md +6 -6
- package/package.json +1 -1
- package/src/sites.ts +25 -25
- package/src/tokens.css +4 -0
package/MIGRATION.md
CHANGED
|
@@ -31,8 +31,9 @@ returns now point into `@rxova/astro-ui`.
|
|
|
31
31
|
| `@rxova/brand/starlight.css` | `@rxova/astro-ui/styles/starlight.css` |
|
|
32
32
|
| `@rxova/brand/tokens.css`, `fonts.css`, `assets/*` | unchanged |
|
|
33
33
|
|
|
34
|
-
`<Chrome>` is `
|
|
35
|
-
`
|
|
34
|
+
`<Chrome>` is `Header`, `SiteFooter`, `ProjectSwitcher`, `ThemeToggle` or
|
|
35
|
+
`ThemeScript`. `SiteShell` has no replacement: `@rxova/astro-ui` removed it in 0.3.0, so give the
|
|
36
|
+
page its own layout. `<Override>` is `SiteTitle`, `SocialIcons`,
|
|
36
37
|
`Footer` or `ThemeSelect`.
|
|
37
38
|
|
|
38
39
|
## 4. Rename the short token aliases
|
package/README.md
CHANGED
|
@@ -30,12 +30,12 @@ pnpm add @rxova/brand
|
|
|
30
30
|
|
|
31
31
|
## What's in it
|
|
32
32
|
|
|
33
|
-
| Export | What it is
|
|
34
|
-
| ------------------------- |
|
|
35
|
-
| `@rxova/brand` | `PROJECTS`, `REPOS`, `docsUrl()`, `siteUrl()`, `canonicalUrl()`, feeds
|
|
36
|
-
| `@rxova/brand/tokens.css` | The `--rx-*` custom properties. Everything derives from these.
|
|
37
|
-
| `@rxova/brand/fonts.css` | Self-hosted Space Grotesk + IBM Plex Mono
|
|
38
|
-
| `@rxova/brand/assets/*` | The mark, logos and per-project OG images
|
|
33
|
+
| Export | What it is |
|
|
34
|
+
| ------------------------- | ------------------------------------------------------------------------------------------ |
|
|
35
|
+
| `@rxova/brand` | `PROJECTS`, `REPOS`, `docsUrl()`, `siteUrl()`, `canonicalUrl()`, feeds |
|
|
36
|
+
| `@rxova/brand/tokens.css` | The `--rx-*` custom properties, `--rx-on-primary` included. Everything derives from these. |
|
|
37
|
+
| `@rxova/brand/fonts.css` | Self-hosted Space Grotesk + IBM Plex Mono |
|
|
38
|
+
| `@rxova/brand/assets/*` | The mark, logos and per-project OG images |
|
|
39
39
|
|
|
40
40
|
## The palette
|
|
41
41
|
|
package/package.json
CHANGED
package/src/sites.ts
CHANGED
|
@@ -6,32 +6,14 @@
|
|
|
6
6
|
/** Canonical origin. Override for a staging deploy (e.g. https://web.rxova.org). */
|
|
7
7
|
export const RXOVA_ORIGIN = process.env.RXOVA_ORIGIN ?? 'https://rxova.org'
|
|
8
8
|
|
|
9
|
-
export type ProjectId =
|
|
10
|
-
'overlock' | 'journey' | 'react-inputs' | 'use-everywhere' | 'ts-extended-errors'
|
|
11
|
-
|
|
12
|
-
export interface Project {
|
|
13
|
-
id: ProjectId
|
|
14
|
-
/** Display name, used in the header, the switcher and the landing cards. */
|
|
15
|
-
label: string
|
|
16
|
-
/** Path the aggregator mounts this project's docs at. Leading and trailing slash. */
|
|
17
|
-
mount: `/${string}/`
|
|
18
|
-
tagline: string
|
|
19
|
-
repo: string
|
|
20
|
-
/** The package a newcomer should install first. */
|
|
21
|
-
npm: string
|
|
22
|
-
/** npm package names, most prominent first. */
|
|
23
|
-
packages: string[]
|
|
24
|
-
}
|
|
25
|
-
|
|
26
9
|
/**
|
|
27
|
-
*
|
|
28
|
-
*
|
|
10
|
+
* Every rxova project, in display order: the landing's project rail and the docs switcher.
|
|
11
|
+
* The one list of projects; `sources.json` only says which are deployed. overlock stays last.
|
|
29
12
|
*/
|
|
30
|
-
|
|
13
|
+
const DEFINITIONS = [
|
|
31
14
|
{
|
|
32
15
|
id: 'journey',
|
|
33
16
|
label: 'journey',
|
|
34
|
-
mount: '/packages/journey/',
|
|
35
17
|
tagline: 'Declarative journey graphs for non-linear UI flows.',
|
|
36
18
|
repo: 'https://github.com/rxova/journey',
|
|
37
19
|
npm: 'https://www.npmjs.com/package/@rxova/journey-core',
|
|
@@ -40,7 +22,6 @@ export const PROJECTS: readonly Project[] = [
|
|
|
40
22
|
{
|
|
41
23
|
id: 'react-inputs',
|
|
42
24
|
label: 'react-inputs',
|
|
43
|
-
mount: '/packages/react-inputs/',
|
|
44
25
|
tagline: 'The tricky React inputs, done right.',
|
|
45
26
|
repo: 'https://github.com/rxova/react-inputs',
|
|
46
27
|
npm: 'https://www.npmjs.com/package/@rxova/react-inputs',
|
|
@@ -60,7 +41,6 @@ export const PROJECTS: readonly Project[] = [
|
|
|
60
41
|
{
|
|
61
42
|
id: 'use-everywhere',
|
|
62
43
|
label: 'use-everywhere',
|
|
63
|
-
mount: '/packages/use-everywhere/',
|
|
64
44
|
tagline: 'State and messages that exist in every tab, window, and worker.',
|
|
65
45
|
repo: 'https://github.com/rxova/use-everywhere',
|
|
66
46
|
npm: 'https://www.npmjs.com/package/use-everywhere',
|
|
@@ -69,7 +49,6 @@ export const PROJECTS: readonly Project[] = [
|
|
|
69
49
|
{
|
|
70
50
|
id: 'ts-extended-errors',
|
|
71
51
|
label: 'ts-extended-errors',
|
|
72
|
-
mount: '/packages/ts-extended-errors/',
|
|
73
52
|
tagline: 'Typed, serializable errors that survive a JSON round trip.',
|
|
74
53
|
repo: 'https://github.com/rxova/ts-extended-errors',
|
|
75
54
|
npm: 'https://www.npmjs.com/package/ts-extended-errors',
|
|
@@ -78,7 +57,6 @@ export const PROJECTS: readonly Project[] = [
|
|
|
78
57
|
{
|
|
79
58
|
id: 'overlock',
|
|
80
59
|
label: 'overlock',
|
|
81
|
-
mount: '/packages/overlock/',
|
|
82
60
|
tagline: 'A deterministic gate on test integrity in a git patch.',
|
|
83
61
|
repo: 'https://github.com/rxova/overlock',
|
|
84
62
|
npm: 'https://www.npmjs.com/package/overlock',
|
|
@@ -86,6 +64,28 @@ export const PROJECTS: readonly Project[] = [
|
|
|
86
64
|
},
|
|
87
65
|
] as const
|
|
88
66
|
|
|
67
|
+
export type ProjectId = (typeof DEFINITIONS)[number]['id']
|
|
68
|
+
|
|
69
|
+
export interface Project {
|
|
70
|
+
id: ProjectId
|
|
71
|
+
/** Display name, used in the header, the switcher and the landing cards. */
|
|
72
|
+
label: string
|
|
73
|
+
/** Path the aggregator mounts this project's docs at: always `/packages/<id>/`. */
|
|
74
|
+
mount: `/${string}/`
|
|
75
|
+
tagline: string
|
|
76
|
+
repo: string
|
|
77
|
+
/** The package a newcomer should install first. */
|
|
78
|
+
npm: string
|
|
79
|
+
/** npm package names, most prominent first. */
|
|
80
|
+
packages: string[]
|
|
81
|
+
}
|
|
82
|
+
|
|
83
|
+
export const PROJECTS: readonly Project[] = DEFINITIONS.map((project) => ({
|
|
84
|
+
...project,
|
|
85
|
+
mount: `/packages/${project.id}/`,
|
|
86
|
+
packages: [...project.packages],
|
|
87
|
+
}))
|
|
88
|
+
|
|
89
89
|
export function getProject(id: ProjectId): Project {
|
|
90
90
|
const project = PROJECTS.find((p) => p.id === id)
|
|
91
91
|
if (!project) throw new Error(`[@rxova/brand] unknown project id: ${id}`)
|
package/src/tokens.css
CHANGED
|
@@ -27,6 +27,8 @@
|
|
|
27
27
|
--rx-primary-light: #8159f3;
|
|
28
28
|
--rx-primary-lighter: #9375f5;
|
|
29
29
|
--rx-primary-lightest: #b7a3f9;
|
|
30
|
+
/* Text on a --rx-primary fill; the page colour, since white on the lightened dark-mode violet fails AA. */
|
|
31
|
+
--rx-on-primary: #ffffff;
|
|
30
32
|
|
|
31
33
|
--rx-glow-tint: rgb(107 61 240 / 0.14);
|
|
32
34
|
--rx-shadow-soft: 0 20px 60px -30px rgb(107 61 240 / 0.35);
|
|
@@ -53,6 +55,7 @@
|
|
|
53
55
|
--rx-primary-light: #b7a3f9;
|
|
54
56
|
--rx-primary-lighter: #cbbcfb;
|
|
55
57
|
--rx-primary-lightest: #e0d7fd;
|
|
58
|
+
--rx-on-primary: #100f0d;
|
|
56
59
|
|
|
57
60
|
--rx-glow-tint: rgb(244 241 234 / 0.06);
|
|
58
61
|
--rx-shadow-soft: 0 20px 60px -30px rgb(0 0 0 / 0.6);
|
|
@@ -83,6 +86,7 @@
|
|
|
83
86
|
--rx-primary-light: #b7a3f9;
|
|
84
87
|
--rx-primary-lighter: #cbbcfb;
|
|
85
88
|
--rx-primary-lightest: #e0d7fd;
|
|
89
|
+
--rx-on-primary: #100f0d;
|
|
86
90
|
|
|
87
91
|
--rx-glow-tint: rgb(244 241 234 / 0.06);
|
|
88
92
|
--rx-shadow-soft: 0 20px 60px -30px rgb(0 0 0 / 0.6);
|