美人鱼 - 降价中的样式课程图

发布于 2025-02-11 02:26:28 字数 553 浏览 2 评论 0 原文

您好,我会设计一个由美人鱼定义的课程图。我需要将此图集成到Markdown文档(无CSS自定义)中。

%%{init: {'theme': 'dark'}}%%
classDiagram

class Company {
    id: string
    cognito_sub: string
    first_name: string
        last_name: string
        phone: Phone
        email: string
        tax_code: string
        birth_date: number
        birth_place: string
        img_url: string
        origin: string
        status: CustomerStatus
        note: Note[]
        created_at: number
        updated_at: number
}

我会改变背景和边框颜色。我不能使用CSS,因为我需要在概念文档上集成此图。

Hello I would styling a class diagram defined with mermaid. I need to integrate this diagram in a markdown document (no css customization).

%%{init: {'theme': 'dark'}}%%
classDiagram

class Company {
    id: string
    cognito_sub: string
    first_name: string
        last_name: string
        phone: Phone
        email: string
        tax_code: string
        birth_date: number
        birth_place: string
        img_url: string
        origin: string
        status: CustomerStatus
        note: Note[]
        created_at: number
        updated_at: number
}

I would change background and border color. I can't use css because I need to integrate this diagram on a Notion document.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

套路撩心 2025-02-18 02:26:28

您可以使用 themevariables 内部自定义图表 init block,例如:

%%{init: {'theme': 'base', 'themeVariables': { 'primaryBorderColor': 'green', 'background': 'yellow'}}}%%

有关可访问变量的更多信息:

You can customise diagram with themeVariables inside init block, for example:

%%{init: {'theme': 'base', 'themeVariables': { 'primaryBorderColor': 'green', 'background': 'yellow'}}}%%

More information about accessible variables: https://mermaid-js.github.io/mermaid/#/./theming?id=theme-variables-reference-table

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文