Skip to content

Commit

Permalink
Pass placeholder through to edit input-field
Browse files Browse the repository at this point in the history
  • Loading branch information
renefitzke1 committed Nov 5, 2024
1 parent ef8a089 commit 241ed16
Show file tree
Hide file tree
Showing 5 changed files with 9 additions and 0 deletions.
5 changes: 5 additions & 0 deletions src/Date/CalendarEdit.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@ function CalendarEdit({
locale,
inputEnabled,
withDateFormatInLabel,
placeholder,
}: {
mode: ModeType
label?: string
Expand All @@ -37,6 +38,7 @@ function CalendarEdit({
locale: string
inputEnabled?: boolean
withDateFormatInLabel?: boolean
placeholder?: string
}) {
const dateInput = useRef<TextInputNative | null>(null)
const startInput = useRef<TextInputNative | null>(null)
Expand Down Expand Up @@ -96,6 +98,7 @@ function CalendarEdit({
autoComplete={'off'}
inputEnabled={inputEnabled}
withDateFormatInLabel={withDateFormatInLabel}
placeholder={placeholder}
/>
) : null}
{mode === 'range' ? (
Expand All @@ -114,6 +117,7 @@ function CalendarEdit({
autoComplete={'off'}
inputEnabled={inputEnabled}
withDateFormatInLabel={withDateFormatInLabel}
placeholder={placeholder}
/>
<View style={styles.separator} />
<DatePickerInputWithoutModal
Expand All @@ -129,6 +133,7 @@ function CalendarEdit({
autoComplete="off"
inputEnabled={inputEnabled}
withDateFormatInLabel={withDateFormatInLabel}
placeholder={placeholder}
/>
</View>
) : null}
Expand Down
1 change: 1 addition & 0 deletions src/Date/DatePickerInput.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -88,6 +88,7 @@ function DatePickerInput(
label={rest.label as any}
startWeekOnMonday={startWeekOnMonday}
withDateFormatInLabel={rest.withDateFormatInLabel}
placeholder={rest.placeholder}
/>
) : null
}
Expand Down
1 change: 1 addition & 0 deletions src/Date/DatePickerModal.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -102,6 +102,7 @@ export function DatePickerModal(
disableStatusBar={disableStatusBar}
statusBarOnTopOfBackdrop={isPageSheet || statusBarOnTopOfBackdrop}
withDateFormatInLabel={props.withDateFormatInLabel}
placeholder={props.placeholder}
/>
</View>
</View>
Expand Down
1 change: 1 addition & 0 deletions src/Date/DatePickerModalContent.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -213,6 +213,7 @@ export function DatePickerModalContent(
locale={locale}
inputEnabled={props.inputEnabled}
withDateFormatInLabel={props.withDateFormatInLabel}
placeholder={props.placeholder}
/>
}
/>
Expand Down
1 change: 1 addition & 0 deletions src/Date/DatePickerModalContentHeader.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ export interface HeaderPickProps {
label?: string
emptyLabel?: string
withDateFormatInLabel?: boolean
placeholder?: string
saveLabel?: string
uppercase?: boolean
headerSeparator?: string
Expand Down

0 comments on commit 241ed16

Please sign in to comment.