mirror of
https://gitlab.com/soapbox-pub/mkstack.git
synced 2026-12-05 08:23:35 +00:00
Compare commits
14
Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
39fbc7b6c2 | ||
|
|
39afb03570 | ||
|
|
83db2fd539 | ||
|
|
a2eab78ae3 | ||
|
|
65b974fb41 | ||
|
|
cadbc02947 | ||
|
|
37aaadbd70 | ||
|
|
0cda9cb7fc | ||
|
|
49952a10bf | ||
|
|
fce2a3da23 | ||
|
|
15dbc6df85 | ||
|
|
508fa84466 | ||
|
|
b7ff219e6e | ||
|
|
b9750b3759 |
No files matched your search
@@ -23,3 +23,8 @@ dist-ssr
|
|||||||
|
|
||||||
# Vercel
|
# Vercel
|
||||||
.vercel
|
.vercel
|
||||||
|
|
||||||
|
# Secrets
|
||||||
|
.env
|
||||||
|
.env.*
|
||||||
|
!.env.example
|
||||||
+10
-2
@@ -102,7 +102,7 @@ The AI assistant's behavior and knowledge is defined by the CONTEXT.md file, whi
|
|||||||
|
|
||||||
## "Vibed with MKStack"
|
## "Vibed with MKStack"
|
||||||
|
|
||||||
When building the site for the first time, include "Vibed with MKStack" somewhere in the UI, linked to this URL: https://soapbox.pub/tools/mkstack/
|
When building the site for the first time, include "Vibed with MKStack" somewhere in the UI, linked to this URL: https://soapbox.pub/mkstack
|
||||||
|
|
||||||
## Nostr Protocol Integration
|
## Nostr Protocol Integration
|
||||||
|
|
||||||
@@ -138,6 +138,8 @@ When implementing features that could use existing NIPs, follow this decision fr
|
|||||||
- The data structure is fundamentally different from existing patterns
|
- The data structure is fundamentally different from existing patterns
|
||||||
- The use case requires different storage characteristics (regular vs replaceable vs addressable)
|
- The use case requires different storage characteristics (regular vs replaceable vs addressable)
|
||||||
|
|
||||||
|
6. **Custom Kind Publishing**: When publishing events with custom kinds generated by `nostr__generate_kind`, always include a NIP-31 "alt" tag with a human-readable description of the event's purpose.
|
||||||
|
|
||||||
**Example Decision Process**:
|
**Example Decision Process**:
|
||||||
```
|
```
|
||||||
Need: Equipment marketplace for farmers
|
Need: Equipment marketplace for farmers
|
||||||
@@ -811,7 +813,13 @@ When users specify color schemes:
|
|||||||
|
|
||||||
## Writing Tests
|
## Writing Tests
|
||||||
|
|
||||||
**Important for AI Assistants**: Only create tests when the user is experiencing a specific problem or explicitly requests tests. Do not proactively write tests for new features or components unless the user is having issues that require testing to diagnose or resolve.
|
**⚠️ CRITICAL FOR AI ASSISTANTS**: **DO NOT WRITE TESTS** unless the user is experiencing a specific problem or explicitly requests tests. Writing unnecessary tests wastes significant time and money. Only create tests when:
|
||||||
|
|
||||||
|
1. **The user is experiencing a bug** that requires testing to diagnose
|
||||||
|
2. **The user explicitly asks for tests** to be written
|
||||||
|
3. **Existing functionality is broken** and tests are needed to verify fixes
|
||||||
|
|
||||||
|
**Never proactively write tests** for new features or components. Focus on building functionality that works, not on testing it unless specifically requested.
|
||||||
|
|
||||||
### Test Setup
|
### Test Setup
|
||||||
|
|
||||||
|
|||||||
@@ -1,5 +1,6 @@
|
|||||||
{
|
{
|
||||||
"model": "claude-sonnet-4",
|
"model": "claude-sonnet-4",
|
||||||
|
"temperature": 0.2,
|
||||||
"mcpServers": {
|
"mcpServers": {
|
||||||
"js-dev": {
|
"js-dev": {
|
||||||
"type": "stdio",
|
"type": "stdio",
|
||||||
|
|||||||
Generated
+4
-4
@@ -61,7 +61,7 @@
|
|||||||
"tailwind-merge": "^2.5.2",
|
"tailwind-merge": "^2.5.2",
|
||||||
"tailwindcss-animate": "^1.0.7",
|
"tailwindcss-animate": "^1.0.7",
|
||||||
"vaul": "^0.9.3",
|
"vaul": "^0.9.3",
|
||||||
"zod": "^3.23.8"
|
"zod": "^3.25.71"
|
||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"@eslint/js": "^9.9.0",
|
"@eslint/js": "^9.9.0",
|
||||||
@@ -8244,9 +8244,9 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/zod": {
|
"node_modules/zod": {
|
||||||
"version": "3.24.3",
|
"version": "3.25.71",
|
||||||
"resolved": "https://registry.npmjs.org/zod/-/zod-3.24.3.tgz",
|
"resolved": "https://registry.npmjs.org/zod/-/zod-3.25.71.tgz",
|
||||||
"integrity": "sha512-HhY1oqzWCQWuUqvBFnsyrtZRhyPeR7SUGv+C4+MsisMuVfSPx8HpwWqH8tRahSlt6M3PiFAcoeFhZAqIXTxoSg==",
|
"integrity": "sha512-BsBc/NPk7h8WsUWYWYL+BajcJPY8YhjelaWu2NMLuzgraKAz4Lb4/6K11g9jpuDetjMiqhZ6YaexFLOC0Ogi3Q==",
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"funding": {
|
"funding": {
|
||||||
"url": "https://github.com/sponsors/colinhacks"
|
"url": "https://github.com/sponsors/colinhacks"
|
||||||
|
|||||||
+1
-1
@@ -63,7 +63,7 @@
|
|||||||
"tailwind-merge": "^2.5.2",
|
"tailwind-merge": "^2.5.2",
|
||||||
"tailwindcss-animate": "^1.0.7",
|
"tailwindcss-animate": "^1.0.7",
|
||||||
"vaul": "^0.9.3",
|
"vaul": "^0.9.3",
|
||||||
"zod": "^3.23.8"
|
"zod": "^3.25.71"
|
||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"@eslint/js": "^9.9.0",
|
"@eslint/js": "^9.9.0",
|
||||||
|
|||||||
-32
@@ -1,32 +0,0 @@
|
|||||||
version: 1.0.0
|
|
||||||
title: Nostr Client Development
|
|
||||||
description: A recipe for building Nostr client applications
|
|
||||||
instructions: Create a Nostr client application according to the user's request.
|
|
||||||
extensions:
|
|
||||||
- type: builtin
|
|
||||||
name: developer
|
|
||||||
display_name: Developer Tools
|
|
||||||
timeout: 300
|
|
||||||
bundled: true
|
|
||||||
- type: stdio
|
|
||||||
name: nostr
|
|
||||||
cmd: npx
|
|
||||||
args:
|
|
||||||
- -y
|
|
||||||
- xjsr
|
|
||||||
- "@nostrbook/mcp"
|
|
||||||
envs: {}
|
|
||||||
timeout: 20
|
|
||||||
description: null
|
|
||||||
bundled: null
|
|
||||||
- type: stdio
|
|
||||||
name: fetch
|
|
||||||
cmd: uvx
|
|
||||||
args:
|
|
||||||
- mcp-server-fetch
|
|
||||||
envs: {}
|
|
||||||
timeout: 20
|
|
||||||
description: null
|
|
||||||
bundled: null
|
|
||||||
author:
|
|
||||||
contact: Alex Gleason <[email protected]>
|
|
||||||
+1
-1
@@ -32,7 +32,7 @@ const queryClient = new QueryClient({
|
|||||||
|
|
||||||
const defaultConfig: AppConfig = {
|
const defaultConfig: AppConfig = {
|
||||||
theme: "light",
|
theme: "light",
|
||||||
relayUrl: "wss://relay.nostr.band",
|
relayUrl: "wss://relay.primal.net",
|
||||||
};
|
};
|
||||||
|
|
||||||
const presetRelays = [
|
const presetRelays = [
|
||||||
|
|||||||
@@ -1,4 +1,5 @@
|
|||||||
import { ReactNode, useEffect } from 'react';
|
import { ReactNode, useEffect } from 'react';
|
||||||
|
import { z } from 'zod';
|
||||||
import { useLocalStorage } from '@/hooks/useLocalStorage';
|
import { useLocalStorage } from '@/hooks/useLocalStorage';
|
||||||
import { AppContext, type AppConfig, type AppContextType, type Theme } from '@/contexts/AppContext';
|
import { AppContext, type AppConfig, type AppContextType, type Theme } from '@/contexts/AppContext';
|
||||||
|
|
||||||
@@ -12,6 +13,12 @@ interface AppProviderProps {
|
|||||||
presetRelays?: { name: string; url: string }[];
|
presetRelays?: { name: string; url: string }[];
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Zod schema for AppConfig validation
|
||||||
|
const AppConfigSchema: z.ZodType<AppConfig, z.ZodTypeDef, unknown> = z.object({
|
||||||
|
theme: z.enum(['dark', 'light', 'system']),
|
||||||
|
relayUrl: z.string().url(),
|
||||||
|
});
|
||||||
|
|
||||||
export function AppProvider(props: AppProviderProps) {
|
export function AppProvider(props: AppProviderProps) {
|
||||||
const {
|
const {
|
||||||
children,
|
children,
|
||||||
@@ -21,7 +28,17 @@ export function AppProvider(props: AppProviderProps) {
|
|||||||
} = props;
|
} = props;
|
||||||
|
|
||||||
// App configuration state with localStorage persistence
|
// App configuration state with localStorage persistence
|
||||||
const [config, setConfig] = useLocalStorage<AppConfig>(storageKey, defaultConfig);
|
const [config, setConfig] = useLocalStorage<AppConfig>(
|
||||||
|
storageKey,
|
||||||
|
defaultConfig,
|
||||||
|
{
|
||||||
|
serialize: JSON.stringify,
|
||||||
|
deserialize: (value: string) => {
|
||||||
|
const parsed = JSON.parse(value);
|
||||||
|
return AppConfigSchema.parse(parsed);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
);
|
||||||
|
|
||||||
// Generic config updater with callback pattern
|
// Generic config updater with callback pattern
|
||||||
const updateConfig = (updater: (currentConfig: AppConfig) => AppConfig) => {
|
const updateConfig = (updater: (currentConfig: AppConfig) => AppConfig) => {
|
||||||
|
|||||||
@@ -28,7 +28,7 @@ export function AccountSwitcher({ onAddAccountClick }: AccountSwitcherProps) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<DropdownMenu>
|
<DropdownMenu modal={false}>
|
||||||
<DropdownMenuTrigger asChild>
|
<DropdownMenuTrigger asChild>
|
||||||
<button className='flex items-center gap-3 p-3 rounded-full hover:bg-accent transition-all w-full text-foreground'>
|
<button className='flex items-center gap-3 p-3 rounded-full hover:bg-accent transition-all w-full text-foreground'>
|
||||||
<Avatar className='w-10 h-10'>
|
<Avatar className='w-10 h-10'>
|
||||||
|
|||||||
@@ -135,6 +135,7 @@ const LoginDialog: React.FC<LoginDialogProps> = ({ isOpen, onClose, onLogin, onS
|
|||||||
Enter your nsec
|
Enter your nsec
|
||||||
</label>
|
</label>
|
||||||
<Input
|
<Input
|
||||||
|
type='password'
|
||||||
id='nsec'
|
id='nsec'
|
||||||
value={nsec}
|
value={nsec}
|
||||||
onChange={(e) => setNsec(e.target.value)}
|
onChange={(e) => setNsec(e.target.value)}
|
||||||
|
|||||||
@@ -24,7 +24,7 @@ const AvatarImage = React.forwardRef<
|
|||||||
>(({ className, ...props }, ref) => (
|
>(({ className, ...props }, ref) => (
|
||||||
<AvatarPrimitive.Image
|
<AvatarPrimitive.Image
|
||||||
ref={ref}
|
ref={ref}
|
||||||
className={cn("aspect-square h-full w-full", className)}
|
className={cn("aspect-square h-full w-full object-cover object-center", className)}
|
||||||
{...props}
|
{...props}
|
||||||
/>
|
/>
|
||||||
))
|
))
|
||||||
|
|||||||
@@ -19,6 +19,9 @@ export default defineConfig(() => ({
|
|||||||
onConsoleLog(log) {
|
onConsoleLog(log) {
|
||||||
return !log.includes("React Router Future Flag Warning");
|
return !log.includes("React Router Future Flag Warning");
|
||||||
},
|
},
|
||||||
|
env: {
|
||||||
|
DEBUG_PRINT_LIMIT: '0', // Suppress DOM output that exceeds AI context windows
|
||||||
|
},
|
||||||
},
|
},
|
||||||
resolve: {
|
resolve: {
|
||||||
alias: {
|
alias: {
|
||||||
|
|||||||
Reference in new issue
Block a user