refactor(apps): rename hanzogui.config.ts → gui.config.ts in all 8 admin-* + gui.hanzo.ai + kitchen-sink-go consumers
Drops the redundant brand-stutter from local config filenames. Static extractor still uses .hanzogui/ as its temp-dir name (that's an internal implementation detail of the extractor, not a public surface). All vite.config.ts, tsconfig.json include arrays, and src/main.tsx import specifiers now reference 'gui.config' / 'gui.config.ts'.
This commit is contained in:
@@ -0,0 +1,28 @@
|
||||
// Hanzo GUI v7 config for the Hanzo Agents admin SPA.
|
||||
//
|
||||
// Use the canonical @hanzogui/config v5 default — same shape
|
||||
// admin-tasks uses — so Hanzo GUI's runtime theme registry resolves
|
||||
// cleanly. Hanzo brand recoloring lives in src/index.css as CSS
|
||||
// variables that we layer on top of Hanzo GUI's `dark` theme, NOT
|
||||
// by mutating the themes object.
|
||||
//
|
||||
// IMPORTANT: this config file imports from `hanzogui` (workspace
|
||||
// umbrella), NOT `@hanzo/gui`. Source code uses `@hanzo/gui`; the
|
||||
// Vite alias in vite.config.ts routes that to this same workspace
|
||||
// package at bundle time.
|
||||
|
||||
import { defaultConfig } from '@hanzogui/config/v5'
|
||||
import { createHanzogui } from 'hanzogui'
|
||||
|
||||
export const config = createHanzogui(defaultConfig)
|
||||
|
||||
export default config
|
||||
|
||||
export type Conf = typeof config
|
||||
|
||||
declare module 'hanzogui' {
|
||||
interface HanzoguiCustomConfig extends Conf {}
|
||||
}
|
||||
declare module '@hanzogui/web' {
|
||||
interface HanzoguiCustomConfig extends Conf {}
|
||||
}
|
||||
@@ -10,7 +10,7 @@ import ReactDOM from 'react-dom/client'
|
||||
import { BrowserRouter, Navigate, Route, Routes } from 'react-router-dom'
|
||||
import { HanzoguiProvider } from 'hanzogui'
|
||||
import { PageShell } from '@hanzogui/admin'
|
||||
import config from '../hanzogui.config'
|
||||
import config from '../gui.config'
|
||||
import App from './App'
|
||||
import { ApiKeysPage } from './pages/ApiKeys'
|
||||
import { BillingPage } from './pages/Billing'
|
||||
|
||||
@@ -19,5 +19,5 @@
|
||||
"forceConsistentCasingInFileNames": true,
|
||||
"types": ["vite/client", "node"]
|
||||
},
|
||||
"include": ["src", "hanzogui.config.ts"]
|
||||
"include": ["src", "gui.config.ts"]
|
||||
}
|
||||
|
||||
@@ -20,7 +20,7 @@ export default defineConfig({
|
||||
plugins: [
|
||||
hanzoguiPlugin({
|
||||
components: ['hanzogui'],
|
||||
config: path.resolve(__dirname, 'hanzogui.config.ts'),
|
||||
config: path.resolve(__dirname, 'gui.config.ts'),
|
||||
}),
|
||||
react(),
|
||||
],
|
||||
@@ -40,6 +40,10 @@ export default defineConfig({
|
||||
// admin-tasks uses.
|
||||
'react-native-svg': '@hanzogui/react-native-svg',
|
||||
},
|
||||
// Pick the `source` export condition so unbuilt workspace packages
|
||||
// (e.g. `@hanzogui/admin`, which ships its TypeScript directly) load
|
||||
// from their `./src/index.ts` instead of an absent `./dist`.
|
||||
conditions: ['source', 'browser', 'module', 'import', 'default'],
|
||||
dedupe: [
|
||||
'react',
|
||||
'react-dom',
|
||||
|
||||
@@ -0,0 +1,26 @@
|
||||
// Tamagui config for Hanzo Base admin UI.
|
||||
//
|
||||
// Same shape as admin-tasks — uses @hanzogui/config v5 default so
|
||||
// runtime theme registry resolves. Brand recoloring lives in
|
||||
// src/index.css as CSS variables layered over Tamagui's `dark` theme.
|
||||
//
|
||||
// IMPORTANT: imports from `hanzogui` (workspace umbrella). The static
|
||||
// extractor copies this file into `.hanzogui/` at build time and
|
||||
// re-resolves imports from there — that temp dir can find `hanzogui`
|
||||
// via standard node_modules walk-up.
|
||||
|
||||
import { defaultConfig } from '@hanzogui/config/v5'
|
||||
import { createHanzogui } from 'hanzogui'
|
||||
|
||||
export const config = createHanzogui(defaultConfig)
|
||||
|
||||
export default config
|
||||
|
||||
export type Conf = typeof config
|
||||
|
||||
declare module 'hanzogui' {
|
||||
interface HanzoguiCustomConfig extends Conf {}
|
||||
}
|
||||
declare module '@hanzogui/web' {
|
||||
interface HanzoguiCustomConfig extends Conf {}
|
||||
}
|
||||
@@ -19,7 +19,7 @@ import {
|
||||
} from 'react-router-dom'
|
||||
import { HanzoguiProvider } from 'hanzogui'
|
||||
import { PageShell } from '@hanzogui/admin'
|
||||
import config from '../hanzogui.config'
|
||||
import config from '../gui.config'
|
||||
import App from './App'
|
||||
import { useAuth } from './hooks/useAuth'
|
||||
import { CollectionEdit } from './pages/CollectionEdit'
|
||||
|
||||
@@ -18,5 +18,5 @@
|
||||
"esModuleInterop": true,
|
||||
"allowSyntheticDefaultImports": true
|
||||
},
|
||||
"include": ["src", "hanzogui.config.ts", "vite.config.ts"]
|
||||
"include": ["src", "gui.config.ts", "vite.config.ts"]
|
||||
}
|
||||
|
||||
@@ -22,7 +22,7 @@ export default defineConfig({
|
||||
plugins: [
|
||||
hanzoguiPlugin({
|
||||
components: ['hanzogui'],
|
||||
config: path.resolve(__dirname, 'hanzogui.config.ts'),
|
||||
config: path.resolve(__dirname, 'gui.config.ts'),
|
||||
}),
|
||||
react(),
|
||||
],
|
||||
|
||||
@@ -0,0 +1,28 @@
|
||||
// Hanzo GUI config for admin-bot v0.1 — mirrors apps/admin-tasks shape.
|
||||
//
|
||||
// Use the canonical @hanzogui/config v5 default so the runtime theme
|
||||
// registry resolves cleanly. Brand recoloring (if/when the bot brand
|
||||
// diverges from neutral Hanzo) lives in CSS variables, NOT by mutating
|
||||
// the themes object — spreading it through a JS module breaks the
|
||||
// static shape getThemeProxied() depends on.
|
||||
//
|
||||
// IMPORTANT: this config file imports from `hanzogui` (workspace
|
||||
// umbrella). The static extractor copies this file into `.hanzogui/`
|
||||
// at build time; that temp dir can find `hanzogui` via standard
|
||||
// node_modules walk-up.
|
||||
|
||||
import { defaultConfig } from '@hanzogui/config/v5'
|
||||
import { createHanzogui } from 'hanzogui'
|
||||
|
||||
export const config = createHanzogui(defaultConfig)
|
||||
|
||||
export default config
|
||||
|
||||
export type Conf = typeof config
|
||||
|
||||
declare module 'hanzogui' {
|
||||
interface HanzoguiCustomConfig extends Conf {}
|
||||
}
|
||||
declare module '@hanzogui/web' {
|
||||
interface HanzoguiCustomConfig extends Conf {}
|
||||
}
|
||||
@@ -10,7 +10,7 @@ import ReactDOM from 'react-dom/client'
|
||||
import { BrowserRouter, Navigate, Route, Routes } from 'react-router-dom'
|
||||
import { HanzoguiProvider } from 'hanzogui'
|
||||
import { PageShell } from '@hanzogui/admin'
|
||||
import config from '../hanzogui.config'
|
||||
import config from '../gui.config'
|
||||
import App from './App'
|
||||
import { AgentsPage } from './pages/Agents'
|
||||
import { ChannelsPage } from './pages/Channels'
|
||||
|
||||
@@ -18,5 +18,5 @@
|
||||
"esModuleInterop": true,
|
||||
"allowSyntheticDefaultImports": true
|
||||
},
|
||||
"include": ["src", "hanzogui.config.ts", "vite.config.ts"]
|
||||
"include": ["src", "gui.config.ts", "vite.config.ts"]
|
||||
}
|
||||
|
||||
@@ -25,7 +25,7 @@ export default defineConfig({
|
||||
components: ['hanzogui'],
|
||||
// Absolute path — keeps the extractor from getting confused
|
||||
// when it copies the config into a `.hanzogui/` temp dir.
|
||||
config: path.resolve(__dirname, 'hanzogui.config.ts'),
|
||||
config: path.resolve(__dirname, 'gui.config.ts'),
|
||||
}),
|
||||
react(),
|
||||
],
|
||||
@@ -41,6 +41,10 @@ export default defineConfig({
|
||||
'react-native': 'react-native-web',
|
||||
'react-native-svg': '@hanzogui/react-native-svg',
|
||||
},
|
||||
// Pick the `source` export condition so unbuilt workspace packages
|
||||
// (e.g. `@hanzogui/admin`, which ships its TypeScript directly) load
|
||||
// from their `./src/index.ts` instead of an absent `./dist`.
|
||||
conditions: ['source', 'browser', 'module', 'import', 'default'],
|
||||
dedupe: [
|
||||
'react',
|
||||
'react-dom',
|
||||
|
||||
@@ -0,0 +1,19 @@
|
||||
// Hanzo GUI config for the Commerce admin SPA. Mirrors admin-tasks —
|
||||
// uses @hanzogui/config v5 default so the static extractor can resolve
|
||||
// the theme registry from the generated .hanzogui temp dir.
|
||||
|
||||
import { defaultConfig } from '@hanzogui/config/v5'
|
||||
import { createHanzogui } from 'hanzogui'
|
||||
|
||||
export const config = createHanzogui(defaultConfig)
|
||||
|
||||
export default config
|
||||
|
||||
export type Conf = typeof config
|
||||
|
||||
declare module 'hanzogui' {
|
||||
interface HanzoguiCustomConfig extends Conf {}
|
||||
}
|
||||
declare module '@hanzogui/web' {
|
||||
interface HanzoguiCustomConfig extends Conf {}
|
||||
}
|
||||
@@ -6,7 +6,7 @@ import ReactDOM from 'react-dom/client'
|
||||
import { BrowserRouter, Navigate, Route, Routes } from 'react-router-dom'
|
||||
import { HanzoguiProvider } from 'hanzogui'
|
||||
import { PageShell } from '@hanzogui/admin'
|
||||
import config from '../hanzogui.config'
|
||||
import config from '../gui.config'
|
||||
import App from './App'
|
||||
import { BillingPage } from './pages/Billing'
|
||||
import { CollectionsPage } from './pages/Collections'
|
||||
|
||||
@@ -18,5 +18,5 @@
|
||||
"esModuleInterop": true,
|
||||
"allowSyntheticDefaultImports": true
|
||||
},
|
||||
"include": ["src", "hanzogui.config.ts", "vite.config.ts"]
|
||||
"include": ["src", "gui.config.ts", "vite.config.ts"]
|
||||
}
|
||||
|
||||
@@ -16,7 +16,7 @@ export default defineConfig({
|
||||
plugins: [
|
||||
hanzoguiPlugin({
|
||||
components: ['hanzogui'],
|
||||
config: path.resolve(__dirname, 'hanzogui.config.ts'),
|
||||
config: path.resolve(__dirname, 'gui.config.ts'),
|
||||
}),
|
||||
react(),
|
||||
],
|
||||
@@ -32,6 +32,10 @@ export default defineConfig({
|
||||
'react-native': 'react-native-web',
|
||||
'react-native-svg': '@hanzogui/react-native-svg',
|
||||
},
|
||||
// Pick the `source` export condition so unbuilt workspace packages
|
||||
// (e.g. `@hanzogui/admin`, which ships its TypeScript directly) load
|
||||
// from their `./src/index.ts` instead of an absent `./dist`.
|
||||
conditions: ['source', 'browser', 'module', 'import', 'default'],
|
||||
dedupe: [
|
||||
'react',
|
||||
'react-dom',
|
||||
|
||||
@@ -0,0 +1,34 @@
|
||||
// Tamagui config for Hanzo Tasks UI v2.
|
||||
//
|
||||
// Use the canonical @hanzogui/config v5 default (same shape the
|
||||
// starter at ~/work/hanzo/gui/code/starters/expo-router uses) so
|
||||
// Tamagui's runtime theme registry resolves cleanly. Hanzo brand
|
||||
// recoloring lives in src/index.css as CSS variables that we layer
|
||||
// on top of Tamagui's `dark` theme, NOT by mutating the themes
|
||||
// object — spreading it through a JS module breaks the static
|
||||
// shape Tamagui's getThemeProxied() depends on.
|
||||
|
||||
// IMPORTANT: this config file imports from `hanzogui` (workspace
|
||||
// umbrella), NOT `@hanzo/gui`. Source code uses `@hanzo/gui` (the
|
||||
// canonical Hanzo umbrella name) — the Vite alias in vite.config.ts
|
||||
// routes that to this same workspace package at bundle time. The
|
||||
// static extractor copies this file into `.hanzogui/` at build time
|
||||
// and re-resolves imports from there — that temp dir can find
|
||||
// `hanzogui` via standard node_modules walk-up but NOT `@hanzo/gui`,
|
||||
// which has no walk-up reach from a generated subdir.
|
||||
|
||||
import { defaultConfig } from '@hanzogui/config/v5'
|
||||
import { createHanzogui } from 'hanzogui'
|
||||
|
||||
export const config = createHanzogui(defaultConfig)
|
||||
|
||||
export default config
|
||||
|
||||
export type Conf = typeof config
|
||||
|
||||
declare module 'hanzogui' {
|
||||
interface HanzoguiCustomConfig extends Conf {}
|
||||
}
|
||||
declare module '@hanzogui/web' {
|
||||
interface HanzoguiCustomConfig extends Conf {}
|
||||
}
|
||||
@@ -11,7 +11,7 @@ import ReactDOM from 'react-dom/client'
|
||||
import { BrowserRouter, Navigate, Route, Routes } from 'react-router-dom'
|
||||
import { HanzoguiProvider } from 'hanzogui'
|
||||
import { PageShell } from '@hanzogui/admin'
|
||||
import config from '../hanzogui.config'
|
||||
import config from '../gui.config'
|
||||
import App from './App'
|
||||
import { ActivitiesPage } from './pages/Activities'
|
||||
import { ArchivalPage } from './pages/Archival'
|
||||
|
||||
@@ -18,5 +18,5 @@
|
||||
"esModuleInterop": true,
|
||||
"allowSyntheticDefaultImports": true
|
||||
},
|
||||
"include": ["src", "hanzogui.config.ts", "vite.config.ts"]
|
||||
"include": ["src", "gui.config.ts", "vite.config.ts"]
|
||||
}
|
||||
|
||||
@@ -28,7 +28,7 @@ export default defineConfig({
|
||||
// Absolute path — keeps the extractor from getting confused
|
||||
// when it copies the config into a `.hanzogui/` temp dir and
|
||||
// tries to re-resolve workspace deps from there.
|
||||
config: path.resolve(__dirname, 'hanzogui.config.ts'),
|
||||
config: path.resolve(__dirname, 'gui.config.ts'),
|
||||
// Extraction is required for production. If the temp-dir
|
||||
// workspace-resolution still bites, we'll inline a stub at
|
||||
// build time, never disable.
|
||||
|
||||
@@ -0,0 +1,16 @@
|
||||
import { createHanzogui } from 'hanzogui'
|
||||
import { config } from '@hanzogui/dev-config'
|
||||
|
||||
const guiConf = createHanzogui(config)
|
||||
|
||||
export type Conf = typeof guiConf
|
||||
|
||||
declare module 'hanzogui' {
|
||||
interface HanzoguiCustomConfig extends Conf {}
|
||||
|
||||
interface TypeOverride {
|
||||
groupNames(): 'card' | 'takeoutBody' | 'content' | 'item'
|
||||
}
|
||||
}
|
||||
|
||||
export default guiConf
|
||||
@@ -0,0 +1,12 @@
|
||||
import { defaultConfig } from '@hanzogui/config/v5'
|
||||
import { createHanzogui } from 'hanzogui'
|
||||
|
||||
const hanzoguiConfig = createHanzogui(defaultConfig)
|
||||
|
||||
export type Conf = typeof hanzoguiConfig
|
||||
|
||||
declare module 'hanzogui' {
|
||||
interface HanzoguiCustomConfig extends Conf {}
|
||||
}
|
||||
|
||||
export default hanzoguiConfig
|
||||
@@ -0,0 +1,34 @@
|
||||
// Hanzo GUI v7 config for the @hanzogui/admin shared chrome.
|
||||
//
|
||||
// This file exists for one reason: typing. The shared chrome under
|
||||
// pkgs/ui-admin/ is published as a library (`@hanzogui/admin`) and
|
||||
// runs its own `tsc --noEmit` in isolation. Without a config file
|
||||
// here, the umbrella `hanzogui` types cannot resolve a concrete
|
||||
// `HanzoguiCustomConfig` — every shorthand prop (`p`, `px`, `bg`,
|
||||
// `rounded`, `items`, `justify`, `gap`, `maxW`, ...) widens and the
|
||||
// type checker rejects valid JSX. Each consumer app already declares
|
||||
// its own augmentation (see apps/admin-tasks/hanzogui.config.ts) but
|
||||
// that augmentation is invisible to this package's standalone build.
|
||||
//
|
||||
// The runtime never executes this file. We import the canonical v5
|
||||
// default (the same shape every Hanzo GUI surface uses) and re-declare
|
||||
// the module augmentation so this package's tsc run sees the full
|
||||
// shorthand contract. No theme overrides, no token mutation — brand
|
||||
// recoloring lives at the consumer level via CSS variables, never by
|
||||
// spreading themes through a JS module (that breaks getThemeProxied()).
|
||||
|
||||
import { defaultConfig } from '@hanzogui/config/v5'
|
||||
import { createHanzogui } from 'hanzogui'
|
||||
|
||||
export const config = createHanzogui(defaultConfig)
|
||||
|
||||
export default config
|
||||
|
||||
export type Conf = typeof config
|
||||
|
||||
declare module 'hanzogui' {
|
||||
interface HanzoguiCustomConfig extends Conf {}
|
||||
}
|
||||
declare module '@hanzogui/web' {
|
||||
interface HanzoguiCustomConfig extends Conf {}
|
||||
}
|
||||
@@ -15,5 +15,5 @@
|
||||
"isolatedModules": true,
|
||||
"noEmit": true
|
||||
},
|
||||
"include": ["src", "test", "vitest.config.ts", "hanzogui.config.ts"]
|
||||
"include": ["src", "test", "vitest.config.ts", "gui.config.ts"]
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user