mirror of
https://github.com/ToolJet/ToolJet
synced 2026-04-21 21:47:17 +00:00
Updated data-cy with review comments
This commit is contained in:
parent
7e30956aa7
commit
f7ea317b6f
3 changed files with 23 additions and 25 deletions
|
|
@ -75,7 +75,7 @@ describe("Workflows features", () => {
|
|||
});
|
||||
|
||||
// Need to run after bug fixes
|
||||
it.only("Creating workflow inside Workflow and validating execution", () => {
|
||||
it("Creating workflow inside Workflow and validating execution", () => {
|
||||
cy.createWorkflowApp(data.childWFName);
|
||||
enterJsonInputInStartNode();
|
||||
cy.connectDataSourceNode(workflowsText.runjsNodeLabel);
|
||||
|
|
|
|||
|
|
@ -52,6 +52,7 @@ export function Workflows({ options, optionsChanged, currentState }) {
|
|||
return (
|
||||
<>
|
||||
<label className="mb-1">Workflow</label>
|
||||
<div data-cy="workflow-dropdown"></div>
|
||||
<Select
|
||||
options={workflowOptions}
|
||||
value={options.workflowId ?? {}}
|
||||
|
|
@ -60,7 +61,6 @@ export function Workflows({ options, optionsChanged, currentState }) {
|
|||
optionsChanged({ workflowId });
|
||||
}}
|
||||
placeholder="Select workflow"
|
||||
data-cy="workflow-dropdown"
|
||||
height="32px"
|
||||
useMenuPortal={true}
|
||||
closeMenuOnSelect={true}
|
||||
|
|
|
|||
|
|
@ -57,28 +57,26 @@ export const SelectComponent = ({ options = [], value, onChange, closeMenuOnSele
|
|||
};
|
||||
|
||||
return (
|
||||
<div data-cy={restProps['data-cy']}>
|
||||
<Select
|
||||
{...restProps}
|
||||
ref={selectRef}
|
||||
selectRef={selectRef} // Exposed ref for custom components if needed
|
||||
isLoading={isLoading}
|
||||
isDisabled={isDisabled || isLoading}
|
||||
options={selectOptions}
|
||||
value={currentValue}
|
||||
isSearchable={hasSearch}
|
||||
onChange={handleOnChange}
|
||||
placeholder={placeholder}
|
||||
styles={customStyles}
|
||||
openMenuOnFocus={openMenuOnFocus}
|
||||
formatOptionLabel={(option) => renderCustomOption(option)}
|
||||
menuPlacement={menuPlacement}
|
||||
maxMenuHeight={maxMenuHeight}
|
||||
menuPortalTarget={useMenuPortal ? document.body : menuPortalTarget}
|
||||
closeMenuOnSelect={closeMenuOnSelect ?? true}
|
||||
classNamePrefix={`${customClassPrefix} ${isDarkMode && 'dark-theme'} ${'react-select'}`}
|
||||
data-cy={restProps['data-cy']}
|
||||
/>
|
||||
</div>
|
||||
<Select
|
||||
{...restProps}
|
||||
ref={selectRef}
|
||||
selectRef={selectRef}
|
||||
isLoading={isLoading}
|
||||
isDisabled={isDisabled || isLoading}
|
||||
options={selectOptions}
|
||||
value={currentValue}
|
||||
isSearchable={hasSearch}
|
||||
onChange={handleOnChange}
|
||||
placeholder={placeholder}
|
||||
styles={customStyles}
|
||||
openMenuOnFocus={openMenuOnFocus}
|
||||
formatOptionLabel={(option) => renderCustomOption(option)}
|
||||
menuPlacement={menuPlacement}
|
||||
maxMenuHeight={maxMenuHeight}
|
||||
menuPortalTarget={useMenuPortal ? document.body : menuPortalTarget}
|
||||
closeMenuOnSelect={closeMenuOnSelect ?? true}
|
||||
classNamePrefix={`${customClassPrefix} ${isDarkMode && 'dark-theme'} ${'react-select'}`}
|
||||
data-cy={restProps['data-cy']}
|
||||
/>
|
||||
);
|
||||
};
|
||||
|
|
|
|||
Loading…
Reference in a new issue