UNPKG

@gsretail.com/gui-core

Version:

A skeleton to create your own React component library using Rollup, TypeScript, Sass and Storybook

2 lines (1 loc) 2.8 kB
import o from"../../../@babel/runtime/helpers/esm/extends.js";import e from"../../../@babel/runtime/helpers/esm/objectWithoutPropertiesLoose.js";import*as n from"react";import r from"../../../prop-types/index.js";import{useTimePickerDefaultizedProps as t,timePickerValueManager as p}from"../TimePicker/shared.js";import{TimePickerToolbar as s}from"../TimePicker/TimePickerToolbar.js";import{DesktopWrapper as i}from"../internals/components/wrappers/DesktopWrapper.js";import{useTimeValidation as a}from"../internals/hooks/validation/useTimeValidation.js";import{KeyboardDateInput as m}from"../internals/components/KeyboardDateInput.js";import{usePickerState as c}from"../internals/hooks/usePickerState.js";import{jsx as l}from"react/jsx-runtime";import{CalendarOrClockPicker as u}from"../internals/components/CalendarOrClockPicker/CalendarOrClockPicker.js";const b=["onChange","PaperProps","PopperProps","ToolbarComponent","TransitionComponent","value","components","componentsProps"],P=n.forwardRef((function(n,r){const P=t(n,"MuiDesktopTimePicker"),f=null!==a(P),{pickerProps:d,inputProps:T,wrapperProps:j}=c(P,p),{PaperProps:k,PopperProps:C,ToolbarComponent:h=s,TransitionComponent:O,components:g,componentsProps:y}=P,I=e(P,b),D=o({},T,I,{components:g,componentsProps:y,ref:r,validationError:f});return l(i,o({},j,{DateInputProps:D,KeyboardDateInputComponent:m,PopperProps:C,PaperProps:k,TransitionComponent:O,components:g,componentsProps:y,children:l(u,o({},d,{autoFocus:!0,toolbarTitle:P.label||P.toolbarTitle,ToolbarComponent:h,DateInputProps:D,components:g,componentsProps:y},I))}))}));"production"!==process.env.NODE_ENV&&(P.propTypes={acceptRegex:r.instanceOf(RegExp),ampm:r.bool,ampmInClock:r.bool,children:r.node,className:r.string,closeOnSelect:r.bool,components:r.object,componentsProps:r.object,disabled:r.bool,disableIgnoringDatePartForTimeValidation:r.bool,disableMaskedInput:r.bool,disableOpenPicker:r.bool,getClockLabelText:r.func,getOpenDialogAriaText:r.func,ignoreInvalidInputs:r.bool,InputAdornmentProps:r.object,inputFormat:r.string,InputProps:r.object,inputRef:r.oneOfType([r.func,r.shape({current:r.object})]),label:r.node,mask:r.string,maxTime:r.any,minTime:r.any,minutesStep:r.number,onAccept:r.func,onChange:r.func.isRequired,onClose:r.func,onError:r.func,onOpen:r.func,onViewChange:r.func,open:r.bool,OpenPickerButtonProps:r.object,openTo:r.oneOf(["hours","minutes","seconds"]),orientation:r.oneOf(["landscape","portrait"]),PaperProps:r.object,PopperProps:r.object,readOnly:r.bool,renderInput:r.func.isRequired,rifmFormatter:r.func,shouldDisableTime:r.func,showToolbar:r.bool,ToolbarComponent:r.elementType,toolbarTitle:r.node,TransitionComponent:r.elementType,value:r.any,views:r.arrayOf(r.oneOf(["hours","minutes","seconds"]).isRequired)});export{P as DesktopTimePicker};