Skip to content

Commit ad1f170

Browse files
authored
Merge pull request #520 from serverlessworkflow/style-operator-selector
Enhanced Operator Selection UI
2 parents a0ded8e + f498e55 commit ad1f170

File tree

2 files changed

+34
-24
lines changed

2 files changed

+34
-24
lines changed

src/dashboard/Synapse.Dashboard/Components/CreateWorkflowInstanceDialog/CreateWorkflowInstanceDialog.razor

Lines changed: 16 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -47,19 +47,24 @@
4747
</Tab>
4848
</Tabs>
4949

50-
<div class="py-3">
51-
@if (Operators != null && Operators.Count() > 0)
52-
{
53-
<select class="form-select m-2" @onchange="OnSelectOperatorChanged">
54-
<option value="">Any Operator</option>
55-
@foreach (var op in Operators)
50+
<Accordion class="py-3">
51+
<AccordionItem Title="Advanced Settings">
52+
<Content>
53+
@if (Operators != null && Operators.Count() > 0)
5654
{
57-
var name = op.GetName() + "." + op.GetNamespace();
58-
<option value="@name" selected="@(name == operatorName)">@name</option>
55+
<label for="operator">Select an Operator to run the Workflow:</label>
56+
<select id="operator" class="form-select" @onchange="OnSelectOperatorChanged">
57+
<option value="">Any Operator</option>
58+
@foreach (var op in Operators)
59+
{
60+
var name = op.GetName() + "." + op.GetNamespace();
61+
<option value="@name" selected="@(name == operatorName)">@name</option>
62+
}
63+
</select>
5964
}
60-
</select>
61-
}
62-
</div>
65+
</Content>
66+
</AccordionItem>
67+
</Accordion>
6368

6469
<div class="text-center">
6570
<Button Outline="true" Color="ButtonColor.Primary" class="m-auto mt-3 w-100" @onclick="async _ => await OnStartAsync()">

src/dashboard/Synapse.Dashboard/Pages/Workflows/Create/View.razor

Lines changed: 18 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -65,19 +65,24 @@ else
6565
</div>
6666
}
6767

68-
<div class="py-3">
69-
@if (operators != null && operators.Count() > 0)
70-
{
71-
<select class="form-select m-2" @onchange="(e) => Store.SetOperator(e.Value?.ToString())">
72-
<option value="">Any Operator</option>
73-
@foreach (var op in operators)
74-
{
75-
var name = op.GetName() + "." + op.GetNamespace();
76-
<option value="@name" selected="@(name == operatorName)">@name</option>
77-
}
78-
</select>
79-
}
80-
</div>
68+
<Accordion class="py-3">
69+
<AccordionItem Title="Advanced Settings">
70+
<Content>
71+
@if (operators != null && operators.Count() > 0)
72+
{
73+
<label for="operator">Select an Operator to run the Workflow:</label>
74+
<select id="operator" class="form-select" @onchange="(e) => Store.SetOperator(e.Value?.ToString())">
75+
<option value="">Any Operator</option>
76+
@foreach (var op in operators)
77+
{
78+
var name = op.GetName() + "." + op.GetNamespace();
79+
<option value="@name" selected="@(name == operatorName)">@name</option>
80+
}
81+
</select>
82+
}
83+
</Content>
84+
</AccordionItem>
85+
</Accordion>
8186

8287
<Button class="mt-3" Color="ButtonColor.Primary" Outline="true" Disabled="saving" @onclick="async (_) => await Store.SaveWorkflowDefinitionAsync()">
8388
@if(!saving)

0 commit comments

Comments
 (0)