Skip to content

Commit

Permalink
✨ [#2] Exclude placeholder from select component
Browse files Browse the repository at this point in the history
  • Loading branch information
sergei-maertens committed Nov 13, 2023
1 parent cc460b9 commit 31f2f06
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions src/formio/components/select.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,8 @@ type TranslatableKeys = 'label' | 'description' | 'tooltip';

export type SelectInputSchema = InputComponentSchema<string, Validator, TranslatableKeys>;

export type SelectUnsupported = 'hideLabel' | 'disabled' | 'placeholder';

/**
* @group Form.io components
* @category Base types
Expand All @@ -19,7 +21,7 @@ interface BaseSelectSchema {
* @group Form.io components
* @category Base types
*/
type SelectManualValuesSchema = Omit<SelectInputSchema, 'hideLabel' | 'disabled'> &
type SelectManualValuesSchema = Omit<SelectInputSchema, SelectUnsupported> &
BaseSelectSchema & {
openForms: OFExtensions<TranslatableKeys>['openForms'] & ManualValues;
values: Option[];
Expand All @@ -29,7 +31,7 @@ type SelectManualValuesSchema = Omit<SelectInputSchema, 'hideLabel' | 'disabled'
* @group Form.io components
* @category Base types
*/
type SelectVariableValuesSchema = Omit<SelectInputSchema, 'hideLabel' | 'disabled'> &
type SelectVariableValuesSchema = Omit<SelectInputSchema, SelectUnsupported> &
BaseSelectSchema & {
openForms: OFExtensions<TranslatableKeys>['openForms'] & VariableValues;
};
Expand Down

0 comments on commit 31f2f06

Please sign in to comment.