36 lines
794 B
Svelte
36 lines
794 B
Svelte
<script>
|
|
import { Select, Label } from "@budibase/bbui"
|
|
import { currentAsset, store } from "builderStore"
|
|
import { getActionProviderComponents } from "builderStore/dataBinding"
|
|
|
|
export let parameters
|
|
|
|
$: actionProviders = getActionProviderComponents(
|
|
$currentAsset,
|
|
$store.selectedComponentId,
|
|
"RefreshDatasource"
|
|
)
|
|
</script>
|
|
|
|
<div class="root">
|
|
<Label small>Data Provider</Label>
|
|
<Select
|
|
bind:value={parameters.componentId}
|
|
options={actionProviders}
|
|
getOptionLabel={x => x._instanceName}
|
|
getOptionValue={x => x._id}
|
|
/>
|
|
</div>
|
|
|
|
<style>
|
|
.root {
|
|
display: grid;
|
|
column-gap: var(--spacing-l);
|
|
row-gap: var(--spacing-s);
|
|
grid-template-columns: 70px 1fr;
|
|
align-items: center;
|
|
max-width: 400px;
|
|
margin: 0 auto;
|
|
}
|
|
</style>
|