当前位置: 首页>>代码示例>>Python>>正文


Python dash_html_components.Ul方法代码示例

本文整理汇总了Python中dash_html_components.Ul方法的典型用法代码示例。如果您正苦于以下问题:Python dash_html_components.Ul方法的具体用法?Python dash_html_components.Ul怎么用?Python dash_html_components.Ul使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在dash_html_components的用法示例。


在下文中一共展示了dash_html_components.Ul方法的5个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。

示例1: build_loc_mode_hover_children

# 需要导入模块: import dash_html_components [as 别名]
# 或者: from dash_html_components import Ul [as 别名]
def build_loc_mode_hover_children(loc_mode):
    if loc_mode is None:
        return None
    loc_mode_cfg = LOC_MODE_INFO[loc_mode]
    url, examples, desc = (loc_mode_cfg.get(p) for p in ["url", "examples", "desc"])
    body = []
    if url is not None:
        body.append(
            html.Div([html.Span("View", className="mr-3"), loc_mode_cfg["url"]])
        )
    if examples is not None:
        body.append(
            html.Ul(
                [
                    html.Li(e, style={"listStyleType": "disc"}, className="mb-3")
                    for e in loc_mode_cfg["examples"]
                ],
                className="pt-3 mb-0",
            )
        )
    if desc is not None:
        body.append(html.Span(desc))
    return [
        html.I(className="ico-help-outline", style=dict(color="white")),
        html.Div(
            body,
            className="hoverable__content build-code",
            style=dict(width="auto", whiteSpace="nowrap", left="-2em", top="auto"),
        ),
    ] 
开发者ID:man-group,项目名称:dtale,代码行数:32,代码来源:layout.py

示例2: create_contents

# 需要导入模块: import dash_html_components [as 别名]
# 或者: from dash_html_components import Ul [as 别名]
def create_contents(contents):
    h = []
    for i in contents:
        if isinstance(i, list):
            h.append(create_contents(i))
        else:
            h.append(html.Li(i))
    return html.Ul(h) 
开发者ID:plotly,项目名称:dash-docs,代码行数:10,代码来源:run.py

示例3: Section

# 需要导入模块: import dash_html_components [as 别名]
# 或者: from dash_html_components import Ul [as 别名]
def Section(title, links, description=None, headerStyle={}):
    return html.Div(className='toc--section', children=[
        html.H2(title, style=merge(styles['underline'], headerStyle)),
        (
            html.Div(description)
            if description is not None else None
        ),
        html.Ul(links, className='toc--chapters')
    ]) 
开发者ID:plotly,项目名称:dash-docs,代码行数:11,代码来源:Section.py

示例4: make_nav

# 需要导入模块: import dash_html_components [as 别名]
# 或者: from dash_html_components import Ul [as 别名]
def make_nav(self, current_path, **kwargs):
        nav_items = []
        route_prefix = server.config["ROUTES_PATHNAME_PREFIX"]
        for i, (path, text) in enumerate(self.nav_items):
            href = get_url(path)
            active = (current_path == href) or (i == 0 and current_path == route_prefix)
            nav_item = dbc.NavItem(dbc.NavLink(text, href=href, active=active))
            nav_items.append(nav_item)
        return html.Ul(nav_items, className="navbar-nav", **kwargs) 
开发者ID:ned2,项目名称:slapdash,代码行数:11,代码来源:utils.py

示例5: make_header

# 需要导入模块: import dash_html_components [as 别名]
# 或者: from dash_html_components import Ul [as 别名]
def make_header(**kwargs):
    return dbc.Navbar(
        id="header",
        className="sticky-top",
        color="dark",
        dark=True,
        children=[
            make_brand(),
            html.Ul(
                id=server.config["NAVBAR_CONTAINER_ID"], className="navbar-nav ml-auto"
            ),
        ],
        **kwargs,
    ) 
开发者ID:ned2,项目名称:slapdash,代码行数:16,代码来源:components.py


注:本文中的dash_html_components.Ul方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。