Files
gsfdc/demo-dify/dify/web/features/app-access-error/page.stories.tsx
T
wuzilongandCursor 6519682885 chore: 纳入本地 Dify 1.19.0 源码及品牌与免登改动
演示目录只保留可重建的源码。运行密钥、数据卷、依赖和带口令的本地配置不进入仓库。

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-11-18 13:59:25 +08:00

48 lines
1.2 KiB
TypeScript

import type { Meta, StoryObj } from '@storybook/nextjs-vite'
import { ThemeProvider } from 'next-themes'
import AppNotAccessible from './page'
const meta = {
title: 'App/App Not Accessible',
component: AppNotAccessible,
parameters: {
layout: 'fullscreen',
nextjs: { appDirectory: true, navigation: { pathname: '/chat/app' } },
},
decorators: [
(Story) => (
<ThemeProvider attribute="data-theme" defaultTheme="light">
<Story />
</ThemeProvider>
),
],
} satisfies Meta<typeof AppNotAccessible>
export default meta
type Story = StoryObj<typeof meta>
export const WithoutIP: Story = {}
export const IPv4: Story = { args: { clientIp: '203.0.113.42' } }
export const IPv6: Story = { args: { clientIp: '2001:db8:1234:5678:90ab:cdef:1234:5678' } }
export const NarrowIframe: Story = {
render: () => (
<iframe
title="375px app error preview"
width={375}
height={667}
src="/iframe.html?id=app-app-not-accessible--i-pv-6&viewMode=story"
/>
),
}
export const ShortIframe: Story = {
render: () => (
<iframe
title="Short app error preview"
width={800}
height={360}
src="/iframe.html?id=app-app-not-accessible--i-pv-4&viewMode=story"
/>
),
}