@llmnative/react 2.2.0 → 2.2.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.
@@ -14,6 +14,8 @@ export interface I18nDict {
14
14
  next: string;
15
15
  notFoundMessage: string;
16
16
  goHome: string;
17
+ /** The button that opens the menu on a small screen (the header of the scaffold). */
18
+ openNavigation: string;
17
19
  };
18
20
  auth: {
19
21
  signIn: string;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@llmnative/react",
3
- "version": "2.2.0",
3
+ "version": "2.2.1",
4
4
  "description": "LLM-native React framework for deterministic UI generation. Data-driven by default, schema-driven optional. Ultra-low token consumption — built for AI agents, not just humans.",
5
5
  "main": "dist/index.js",
6
6
  "module": "dist/index.mjs",
@@ -1,9 +1,9 @@
1
- import React from 'react';
2
-
3
- export default function Footer() {
4
- return (
5
- <footer className="shrink-0 border-t border-footer-border bg-footer px-4 py-1.5 text-end text-xs text-footer-foreground">
6
- Powered by [projectname]
7
- </footer>
8
- );
9
- }
1
+ import React from 'react';
2
+
3
+ export default function Footer() {
4
+ return (
5
+ <footer className="shrink-0 border-t border-footer-border bg-footer px-4 py-1.5 text-end text-xs text-footer-foreground">
6
+ © {new Date().getFullYear()} [projectname]
7
+ </footer>
8
+ );
9
+ }
@@ -1,24 +1,26 @@
1
- import React from 'react';
2
- import { ActionButton, AuthButton, Brand } from '@llmnative/react';
3
-
4
- type HeaderProps = {
5
- onMenuToggle: () => void;
6
- };
7
-
8
- export default function Header({ onMenuToggle }: HeaderProps) {
9
- return (
10
- <header className="flex h-14 shrink-0 items-center gap-3 border-b border-header-border bg-header px-4 text-header-foreground">
11
- <ActionButton
12
- icon="menu"
13
- ariaLabel="Toggle navigation"
14
- variant="link"
15
- wrapperClassName="lg:hidden"
16
- onClick={onMenuToggle}
17
- />
18
- <Brand url="/" label="[projectname]" />
19
- <div className="ms-auto">
20
- <AuthButton aspect="avatar" />
21
- </div>
22
- </header>
23
- );
24
- }
1
+ import React from 'react';
2
+ import { ActionButton, AuthButton, Brand, useI18n } from '@llmnative/react';
3
+
4
+ type HeaderProps = {
5
+ onMenuToggle: () => void;
6
+ };
7
+
8
+ export default function Header({ onMenuToggle }: HeaderProps) {
9
+ const common = useI18n('common');
10
+
11
+ return (
12
+ <header className="flex h-14 shrink-0 items-center gap-3 border-b border-header-border bg-header px-4 text-header-foreground">
13
+ <ActionButton
14
+ icon="menu"
15
+ ariaLabel={common.openNavigation}
16
+ variant="link"
17
+ wrapperClassName="lg:hidden"
18
+ onClick={onMenuToggle}
19
+ />
20
+ <Brand url="/" label="[projectname]" />
21
+ <div className="ms-auto">
22
+ <AuthButton aspect="avatar" />
23
+ </div>
24
+ </header>
25
+ );
26
+ }