如何更改破折号表Python中的“过滤数据...”占位符?

问题描述 投票:0回答:1

我一直在Python中使用dash库。我在其中使用破折号表,但在过滤器数据单元格中,我将“过滤器数据...”作为占位符,我想更改它。

在Python中的破折号库中,我使用破折号表,但在过滤器数据单元格中,我将“过滤器数据...”作为占位符,我想更改它。

python html css plotly-dash
1个回答
0
投票

有点晚了,但是您可以使用带有

filter_options
键的
placeholder_text
字典。所以,就像:

    dash_table.DataTable(
        sort_action='native',    
        filter_action='native',
        filter_options={
           'placeholder_text': 'Type filter...',
           'case': 'insensitive'
        },

上面将为您提供一个默认的不区分大小写的过滤器,其中包含占位符“类型过滤器...”。

© www.soinside.com 2019 - 2024. All rights reserved.