oneslash-design-system 2.1.0 → 2.2.0

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/README.md CHANGED
@@ -15,6 +15,13 @@ The package ships Tailwind class names, CSS variables and untranspiled `.jsx`. E
15
15
  3. **Tailwind v4:** import `oneslash-design-system/theme.css` (toggle) or `theme-auto.css` (OS), plus `typography.css` if you want the type scale.
16
16
  4. **Next.js:** `transpilePackages: ["oneslash-design-system"]` in `next.config`.
17
17
  5. **Scan the components:** v3 `content` gets `./node_modules/oneslash-design-system/dist/**/*.{js,jsx}`; v4 CSS gets `@source "../node_modules/oneslash-design-system/dist/**/*.jsx";`.
18
+ 6. **Load the fonts:** the package names Inter (`font-inter`) and JetBrains Mono (`font-mono`, for code, identifiers and type names) but does not ship them. Load both under their real family names, for example with one Google Fonts link in `<head>`:
19
+
20
+ ```html
21
+ <link rel="stylesheet" href="https://fonts.googleapis.com/css2?family=Inter:wght@400&family=JetBrains+Mono:wght@400&display=swap">
22
+ ```
23
+
24
+ `next/font/google` registers a hashed family name instead, so with it apply `mono.className` to the code element rather than relying on `font-mono`.
18
25
 
19
26
  ```css
20
27
  /* Tailwind v4, OS-driven dark mode */
@@ -1539,6 +1539,7 @@ export declare namespace spacing {
1539
1539
  }
1540
1540
  export declare namespace typography {
1541
1541
  let family: string;
1542
+ let monoFamily: string;
1542
1543
  namespace h1 {
1543
1544
  let weight: string;
1544
1545
  let size: string;
@@ -189,6 +189,7 @@ var base = {
189
189
  },
190
190
  typography: {
191
191
  family: 'Inter, sans-serif',
192
+ monoFamily: "'JetBrains Mono', ui-monospace, monospace",
192
193
  h1: {
193
194
  weight: '400',
194
195
  size: '96px',
@@ -359,7 +359,8 @@ module.exports = {
359
359
  ]
360
360
  },
361
361
  "fontFamily": {
362
- "inter": "Inter, sans-serif"
362
+ "inter": "Inter, sans-serif",
363
+ "mono": "'JetBrains Mono', ui-monospace, monospace"
363
364
  },
364
365
  "fontWeight": {
365
366
  "h1": "400",
@@ -353,7 +353,8 @@ module.exports = {
353
353
  ]
354
354
  },
355
355
  "fontFamily": {
356
- "inter": "Inter, sans-serif"
356
+ "inter": "Inter, sans-serif",
357
+ "mono": "'JetBrains Mono', ui-monospace, monospace"
357
358
  },
358
359
  "fontWeight": {
359
360
  "h1": "400",
@@ -1,6 +1,7 @@
1
1
  /* Generated from designTokens.js by scripts/build-tokens.js. Do not edit. */
2
2
  @theme inline {
3
3
  --font-inter: Inter, sans-serif;
4
+ --font-mono: 'JetBrains Mono', ui-monospace, monospace;
4
5
  --text-h1: 96px;
5
6
  --text-h1--line-height: 115px;
6
7
  --text-h1--letter-spacing: -1.5px;
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "oneslash-design-system",
3
3
  "description": "A design system for the Oneslash projects",
4
- "version": "2.1.0",
4
+ "version": "2.2.0",
5
5
  "private": false,
6
6
  "main": "./dist/index.js",
7
7
  "types": "./dist/index.d.ts",