add the SelectButtonTitle prop to the DateTimePicker

This commit is contained in:
Simone Taeggi 2022-12-14 14:26:23 +01:00
parent 412533434c
commit 6c8b34f2fd
4 changed files with 4 additions and 0 deletions

View File

@ -460,6 +460,7 @@
"app.utils.select-filter": "Select filter",
"app.utils.unpublish": "Unpublish",
"clearLabel": "Clear",
"selectButtonTitle": "Select",
"coming.soon": "This content is currently under construction and will be back in a few weeks!",
"component.Input.error.validation.integer": "The value must be an integer",
"components.AutoReloadBlocker.description": "Run Strapi with one of the following commands:",

View File

@ -55,6 +55,7 @@ const Inputs = ({ label, onChange, options, type, value }) => {
onClear={() => onChange(null)}
value={value ? new Date(value) : null}
selectedDateLabel={(formattedDate) => `Date picker, current is ${formattedDate}`}
selectButtonTitle={formatMessage({ id: 'selectButtonTitle', defaultMessage: 'Select' })}
/>
);
}

View File

@ -210,6 +210,7 @@ const GenericInput = ({
required={required}
value={value && new Date(value)}
selectedDateLabel={(formattedDate) => `Date picker, current is ${formattedDate}`}
selectButtonTitle={formatMessage({ id: 'selectButtonTitle', defaultMessage: 'Select' })}
/>
);
}

View File

@ -21,6 +21,7 @@ const FilterValueInput = ({ label, onChange, options, type, value }) => {
onClear={() => onChange('')}
value={value ? new Date(value) : null}
selectedDateLabel={(formattedDate) => `Date picker, current is ${formattedDate}`}
selectButtonTitle={formatMessage({ id: 'selectButtonTitle', defaultMessage: 'Select' })}
/>
);
}