diff --git a/src/Fieldtypes/HasSelectOptions.php b/src/Fieldtypes/HasSelectOptions.php index 3d5164a891..fb134dd841 100644 --- a/src/Fieldtypes/HasSelectOptions.php +++ b/src/Fieldtypes/HasSelectOptions.php @@ -212,4 +212,13 @@ private function multiSelectGqlType() }, ]; } + + public function extraRenderableFieldData(): array + { + return [ + 'options' => collect($this->getOptions()) + ->mapWithKeys(fn ($option) => [$option['value'] => $option['label']]) + ->all(), + ]; + } }