@fayz-ai/plugin-linkinbio (英语)
科米/林克树型 生物链接 任何创建者的页面。 A 类 BioPage 是一个
身份+品牌+订购的内容块列表,作为公众提供,
未校正的页/p/:slug) (中文(简体) ).
状态 : 预览. v1 船载公页; 应用编辑器为 v2 后续.
公众使用(网站主机)
import { setGlobalSupabaseClient } from '@fayz-ai/core'
import { createPublicLinkInBioPlugin } from '@fayz-ai/plugin-linkinbio/public'
// Optional: point the provider at Supabase (`press_kits` table). Without a
// client, the plugin serves the seeded mock catalog.
setGlobalSupabaseClient(createClient(url, anonKey))
const bio = createPublicLinkInBioPlugin({
basePath: '/p',
seed: { perez: perezBioPage }, // mock/demo content by slug
poweredBy: { label: 'Powered by The Channel', url: '/' },
titleSuffix: 'Press Kit',
})
// bio.Provider wraps the app root; bio.manifest.routes has one guard:'public'
// route ({ path: '/p/:slug', component: BioPage }) to mount into your router.
区块登记(可扩展接合)
11个内置区块(hero, (中文(简体) ), bio, (中文(简体) ), gallery, (中文(简体) ), video-grid, (中文(简体) ), social-links, (中文(简体) ),
embed, (中文(简体) ), project, (中文(简体) ), stats, (中文(简体) ), venue-list, (中文(简体) ), cta, (中文(简体) ), text(通过内置渲染)
开关。 注册特殊区块类型, 不伪造 :
import { registerBlock } from '@fayz-ai/plugin-linkinbio/public'
registerBlock('tour-map', ({ block }) => <TourMap stops={block.stops} />)
数据
BioPageDataProvider.getBySlug(slug) ——模拟(种子地图)或Supabase. 苏帕基地
提供者读取a press_kits- 形状: slug, (中文(简体) ), is_published,并有一个jsonb
data 栏中按满数 BioPage 有效载荷,当
is_published 这是真的.
样式
块是只表示符号 : getBrandingVars(branding) 将页面品牌映射到
--pk-* CSS变量设置在页面容器上. 尾风工具类
用于布局; 不要求导入设计系统 CSS .