Viewportとコンポーネント
Viewportとコンポーネント
ViewportはStripe DashboardでAppのUIがレンダリングされる特定の場所です。
利用可能なViewport
| Viewport | 場所 | ユースケース |
|---|---|---|
stripe.dashboard.customer.detail | 顧客詳細ページ | 顧客別のBrevo同期ステータス |
stripe.dashboard.home.overview | Dashboardホーム | インテグレーション全体の状態 |
stripe.dashboard.payment.detail | 支払い詳細ページ | 支払いトリガーキャンペーン情報 |
顧客詳細Viewport
import { Box, Button, Badge, Inline, Banner,} from '@stripe/ui-extension-sdk/ui';import type { ExtensionContextValue } from '@stripe/ui-extension-sdk/context';
const CustomerDetailView = ({ environment, userContext }: ExtensionContextValue) => { const customerId = environment.objectContext?.id;
return ( <Box css={{ padding: 'large' }}> <Inline css={{ fontWeight: 'bold', marginBottom: 'medium' }}> Brevo連絡先同期 </Inline> <Banner title="Brevoに同期済み" description="この顧客はBrevoに同期されています。" variant="default" /> <Button type="primary" css={{ marginTop: 'medium' }}> Brevoに同期 </Button> </Box> );};Tip
stripe.dashboard.customer.detail viewportから始めてください。これがTajo Brevoインテグレーションに最も有用なviewportです。
次のステップ
- Embedded Apps, App埋め込みパターン
- Post-Install, インストール後のオンボーディング