fix: Refactor DataFilterComponent inputs (#4524)
* refactor: Update DataFilterComponent inputs to use StrInput instead of MessageInput * refactor: Update DataFilterComponent inputs to use MessageTextInput instead of StrInput --------- Co-authored-by: Gabriel Luiz Freitas Almeida <gabriel@langflow.org>
This commit is contained in:
parent
ac540a0940
commit
8e0d6d55de
1 changed files with 9 additions and 4 deletions
|
|
@ -1,7 +1,7 @@
|
|||
from typing import Any
|
||||
|
||||
from langflow.custom import Component
|
||||
from langflow.io import DataInput, DropdownInput, MessageInput, Output
|
||||
from langflow.io import DataInput, DropdownInput, MessageTextInput, Output
|
||||
from langflow.schema import Data
|
||||
|
||||
|
||||
|
|
@ -17,14 +17,19 @@ class DataFilterComponent(Component):
|
|||
|
||||
inputs = [
|
||||
DataInput(name="input_data", display_name="Input Data", info="The list of data items to filter.", is_list=True),
|
||||
MessageInput(
|
||||
name="filter_key", display_name="Filter Key", info="The key to filter on (e.g., 'route').", value="route"
|
||||
MessageTextInput(
|
||||
name="filter_key",
|
||||
display_name="Filter Key",
|
||||
info="The key to filter on (e.g., 'route').",
|
||||
value="route",
|
||||
input_types=["Data"],
|
||||
),
|
||||
MessageInput(
|
||||
MessageTextInput(
|
||||
name="filter_value",
|
||||
display_name="Filter Value",
|
||||
info="The value to filter by (e.g., 'CMIP').",
|
||||
value="CMIP",
|
||||
input_types=["Data"],
|
||||
),
|
||||
DropdownInput(
|
||||
name="operator",
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue