@corva/ui 0.28.0-rc.0 → 0.29.0-3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/assets/1bfc6e5d9cbb531a554ab8d025fa23e9.svg +84 -0
- package/assets/76e3ee12638391cba164716321509ad7.svg +207 -0
- package/assets/9b185a425ea91b6c2beedfef39c06663.svg +306 -0
- package/assets/e607e3aa0a4603bb7ae7f83a2148511e.svg +14 -0
- package/components/Annotations/components/AnnotationsList/index.js +1 -1
- package/components/DevCenter/DevCenterAppContainer/components/DevCenterAppView/DevCenterAppView.js +1 -1
- package/components/EmptyView/EmptyAppView/index.js +1 -1
- package/components/TextField/index.js +1 -1
- package/package.json +1 -1
- package/assets/c1a2b19a1ee8b33bbffcec8f0476591b.png +0 -0
|
@@ -1 +1 @@
|
|
|
1
|
-
import t from"@babel/runtime/helpers/defineProperty";import e from"@babel/runtime/helpers/slicedToArray";import n from"@babel/runtime/regenerator";import o from"@babel/runtime/helpers/asyncToGenerator";import{isNativeDetected as
|
|
1
|
+
import t from"@babel/runtime/helpers/defineProperty";import e from"@babel/runtime/helpers/slicedToArray";import n from"@babel/runtime/regenerator";import o from"@babel/runtime/helpers/asyncToGenerator";import{isNativeDetected as r}from"../../../../utils/mobileDetect.js";import{showSuccessNotification as a}from"../../../../utils/notificationToasts.js";import"../../../../utils/index.js";import{jsx as i,jsxs as s,Fragment as c}from"react/jsx-runtime";import{RootRef as p,Paper as d,Typography as m,Tooltip as l,IconButton as u}from"@material-ui/core";import{memo as f,useRef as h,useState as y,useEffect as b}from"react";import{getAnnotations as g}from"../../../../clients/jsonApi/index.js";import A from"../../../../effects/useOutsideClick.js";import{number as v,string as I,shape as C,func as T,bool as N}from"prop-types";import x from"classnames";import{withStyles as j}from"@material-ui/core/styles";import L from"@material-ui/icons/ChevronLeft";import k from"../../../InfiniteList/index.js";import{SET_ANNOTATIONS as R,APPEND_ANNOTATIONS as _}from"../../constants.js";import{useAnnotationsState as q,useAnnotationsDispatch as w}from"../../AnnotationsContext.js";import S from"./components/AddAnnotationForm/index.js";import H from"./components/Annotation/index.js";import U from"./style.css.js";var F="AppAnnotationsPo",O=function(r){var f,v=r.appId,I=r.appTitle,C=r.assetId,T=r.assetCompanyId,N=r.appSettings,j=r.currentUser,O=r.onClose,P=r.isNative,W=r.classes,B=r.dashboardType,D=q().annotations,E=w(),G=h(),M=h();A(G,O);var z=y(!1),J=e(z,2),K=J[0],Q=J[1],V=y(!0),X=e(V,2),Y=X[0],Z=X[1],$=y(!0),tt=e($,2),et=tt[0],nt=tt[1],ot=y(1),rt=e(ot,2),at=rt[0],it=rt[1];function st(){return(st=o(n.mark((function t(){var e,o,r;return n.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(v&&C){t.next=2;break}return t.abrupt("return");case 2:return Z(!0),t.prev=3,o={page:at,per_page:4,sort:"created_at",order:"desc"},B&&(o.dashboard_type=B),t.next=8,g(v,C,o);case 8:e=t.sent,E({type:1===at?R:_,annotations:e}),t.next=15;break;case 12:t.prev=12,t.t0=t.catch(3),console.error(t.t0);case 15:r=e&&e.data.length<4,it(at+1),nt(!r),Z(!1);case 19:case"end":return t.stop()}}),t,null,[[3,12]])})))).apply(this,arguments)}return b((function(){Q(!0)}),[]),i(p,{rootRef:G,children:s(d,{className:x(U.cAnnotationsList,(f={},t(f,U.cAnnotationsListOpen,K),t(f,U.cAnnotationsListOpenNative,P),f)),children:[i(k,{infiniteClassName:U.cAnnotationsListContentContainer,headerComponent:s(c,{children:[i(m,{"data-testid":"".concat(F,"_appTitle"),variant:"body1",className:W.title,children:I}),i("div",{className:U.cAnnotationsListContentTop,children:s(m,{"data-testid":"".concat(F,"_annotationsTitle"),variant:"caption",className:W.secondaryTitle,children:["Annotations (",D.data?D.data.length:0,")"]})}),i(S,{appId:v,assetId:C,assetCompanyId:T,appSettings:N,currentUser:j,showSuccessNotification:a,dashboardType:B})]}),useWindow:P,items:D.data||[],showNoItemsFound:!(D.data&&0!==D.data.length||Y),noItemsFoundLabel:i(m,{variant:"body2","data-testid":"".concat(F,"_noAnnotations"),className:W.noAnnotations,children:"No Annotations yet"}),threshold:50,infiniteContainerHeight:G.current&&M.current?G.current.clientHeight-M.current.clientHeight:null,moreItemsMayExist:et,pathToCreatedAt:["attributes","created_at"],renderItem:function(t){return i(H,{isNative:P,annotation:t,assetCompanyId:T,included:D.included,currentUser:j,showSuccessNotification:a},t.id)},loadItems:function(){return st.apply(this,arguments)}}),i("div",{className:U.cAnnotationsListActions,ref:M,children:i(l,{title:"Hide",placement:"bottom",children:i(u,{"data-testid":"".concat(F,"_hideButton"),onClick:O,className:W.backIcon,children:i(L,{})})})})]})})};O.propTypes={appId:v.isRequired,appTitle:I.isRequired,assetId:v.isRequired,assetCompanyId:v.isRequired,appSettings:C(),classes:C().isRequired,onClose:T.isRequired,currentUser:C({}).isRequired,isNative:N,dashboardType:I},O.defaultProps={appSettings:{},isNative:r,dashboardType:null};var P=j((function(t){return{title:{fontWeight:200,marginBottom:20},secondaryTitle:{fontWeight:200,textTransform:"uppercase",color:t.palette.grey[600]},annotateIcon:{padding:0,"&:hover":{backgroundColor:"transparent",boxShadow:"none"}},noAnnotations:{marginTop:16},backIcon:{cursor:"pointer",color:t.palette.grey[600],padding:5}}}))(f(O));export default P;
|
package/components/DevCenter/DevCenterAppContainer/components/DevCenterAppView/DevCenterAppView.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
import t from"@babel/runtime/helpers/defineProperty";import"@babel/runtime/helpers/toConsumableArray";import"../../../../../constants/completion.js";import"../../../../../constants/alerts.js";import"lodash";import"@babel/runtime/helpers/slicedToArray";import"../../../../../constants/goals.js";import{SEGMENTS as e}from"../../../../../constants/segment.js";import"../../../../../constants/apps.js";import"../../../../../constants/drillstring.js";import"../../../../../constants/notifications.js";import"@babel/runtime/regenerator";import"@babel/runtime/helpers/asyncToGenerator";import"../../../../../utils/mobileDetect.js";import"@babel/runtime/helpers/typeof";import"../../../../../utils/index.js";import{jsx as r,jsxs as i,Fragment as o}from"react/jsx-runtime";import"@material-ui/core";import"react";import"querystring";import"uuid/v1";import"../../../../../clients/jsonApi/index.js";import"../../../../../clients/subscriptions.js";import"uuid";import"@babel/runtime/helpers/objectWithoutProperties";import"classnames";import"../../../../Modal/index.js";import"../../../../IconMenu/index.js";import"../../../../StyledMenuItem/index.js";import s from"../../../../LoadingIndicator/LoadingIndicator.js";import"../../../../Tooltip.js";import"../../../../Avatar/index.js";import"../../../../Annotations/AnnotationsContext.js";import"../../../DevCenterRouterContext/DevCenterRouterContext.js";import"react-router";import"../../../DevCenterRouterContext/UniversalLink/UniversalLink.js";import"../../../../ConfirmationDialog.js";import"../../../../Annotations/components/AnnotationsList/index.js";import"../../../../Annotations/components/LastAnnotation/index.js";import"../../../../PadModeSelect/PadModeSelect.js";import"../../../AppHeader/AppHeader.js";import"../../../AppSideBar/AppSideBar.js";import"../../../AppContext.js";import"../../../AppsDataProvider/AppsDataProvider.js";import"@material-ui/icons/Help";import"../AppActions/AppActions.css.js";import
|
|
1
|
+
import t from"@babel/runtime/helpers/defineProperty";import"@babel/runtime/helpers/toConsumableArray";import"../../../../../constants/completion.js";import"../../../../../constants/alerts.js";import"lodash";import"@babel/runtime/helpers/slicedToArray";import"../../../../../constants/goals.js";import{SEGMENTS as e}from"../../../../../constants/segment.js";import"../../../../../constants/apps.js";import"../../../../../constants/drillstring.js";import"../../../../../constants/notifications.js";import"@babel/runtime/regenerator";import"@babel/runtime/helpers/asyncToGenerator";import"../../../../../utils/mobileDetect.js";import"@babel/runtime/helpers/typeof";import"../../../../../utils/index.js";import{jsx as r,jsxs as i,Fragment as o}from"react/jsx-runtime";import"@material-ui/core";import"react";import"querystring";import"uuid/v1";import"../../../../../clients/jsonApi/index.js";import"../../../../../clients/subscriptions.js";import"uuid";import"@babel/runtime/helpers/objectWithoutProperties";import"classnames";import"../../../../Modal/index.js";import"../../../../IconMenu/index.js";import"../../../../StyledMenuItem/index.js";import s from"../../../../LoadingIndicator/LoadingIndicator.js";import"../../../../Tooltip.js";import"../../../../Avatar/index.js";import"../../../../Annotations/AnnotationsContext.js";import"../../../DevCenterRouterContext/DevCenterRouterContext.js";import"react-router";import"../../../DevCenterRouterContext/UniversalLink/UniversalLink.js";import"../../../../ConfirmationDialog.js";import"../../../../Annotations/components/AnnotationsList/index.js";import"../../../../Annotations/components/LastAnnotation/index.js";import"../../../../PadModeSelect/PadModeSelect.js";import"../../../AppHeader/AppHeader.js";import"../../../AppSideBar/AppSideBar.js";import"../../../AppContext.js";import"../../../AppsDataProvider/AppsDataProvider.js";import"@material-ui/icons/Help";import"../AppActions/AppActions.css.js";import"../../../../ErrorBoundary/InternalErrorView/InternalErrorView.js";import n from"../../../../ErrorBoundary/ErrorBoundary.js";import"../../../../Typography.js";import"../../../../ErrorBoundary/DevCenterAppErrorView/DevCenterAppErrorView.js";import"../DisabledSettingsMessage/DisabledSettingsMessage.js";import"../../../../SlateFormattedText/RenderElements.js";import"../../../../SlateFormattedText/SlateFormattedText.js";import"../AppSettingsDialog/AppSettingsDialog.js";import"../AnnotationsButton/AnnotationsButton.js";import"../NonPriorityMenus/NonPriorityMenus.js";import"../FullscreenButton/FullscreenButton.js";import p from"../AppInfoMessage/AppInfoMessage.js";import"../HelpCenterDialog/HelpCenterDialog.js";import"../../DevCenterAppContainer.css.js";import"../RestoreAppSizeButton/index.js";import"../PriorityMenus/PriorityMenus.css.js";import"../../../NavigationBar/NavigationBar.js";import"../../../SideBar/SideBar.js";import"../../../../TruncatedText/index.js";import"../../../../AssetEditor/SingleAssetEditor.js";import"../../../../AssetEditor/AssetEditorAutocomplete.js";import"../../../../AssetEditor/index.js";import"../../../../AppVersionsSelect/AppVersionsSelect.js";import"../../../../CollapsableSidebar.js";import"../../../../DateTimePicker/index.js";import"../../../../DatePicker/index.js";import"../../../../ColorPicker/PaletteChromePicker/PaletteChromePicker.js";import"../../../../ColorPicker/ColorPicker.js";import"../../../../ParameterCharts/AddEditTrack.js";import"../../../../ParameterCharts/ParameterCharts.js";import"../../../../ChartActionsList/ChartActionsList.js";import"../../../../SettingEditors/ColorEditor/index.js";import"../../../../SettingEditors/DropdownEditor/index.js";import"../../../../SettingEditors/RadioEditor/index.js";import"../../../../SwitchControl/index.js";import"../../../../RangeSlider/RangeSlider.js";import"../../../../Login/components/Login.js";import"../../../../Login/components/PasswordField.js";import"../../../../Login/components/Chip.js";import"../../../../Login/components/StepFooter.js";import"../../../../Login/components/StepContent.js";import"../../../../Login/components/StepHeader.js";import"../../../../Login/components/Step.js";import"../../../../Login/components/OrDivider.js";import"../../../../Login/components/HiddenEmailField.js";import"../../../../Login/components/EmailField.js";import"../../../../Breadcrumbs/index.js";import"../../../../VirtualizedTable/index.js";import"../../../../EmptyView/index.js";import a from"../../../../EmptyView/EmptyAppView/index.js";import"../../../../Button/index.js";import"../../../../MenuItem/index.js";import"../../../../ContextMenuItem/index.js";import"../../../../FolderMenuItem/index.js";import"../../../../EditableItem/EditableItem/index.js";import"../../../../EditableItem/EditableItemWithBadge/index.js";import"../../../../Checkbox/index.js";import"../../../../FolderMenuItemWithLinks/index.js";import"../../../../IconButton/index.js";import"../../../../TextField/index.js";import"../../../../Chip/index.js";import"../../../../Counter/index.js";import"../../../../AnchorsList/AnchorsList.js";import"../../../../Select/index.js";import"../../../../Tabs/Tabs.js";import"../../../../Tabs/Tab.js";import"../../../../Drillstring/BHASchematic.js";import"../../../../Drillstring/BHAComponentIcon.js";import"../../../../Drillstring/BHATable/index.js";import"../../../../Drillstring/BHAComponentDetail/index.js";import"../../../../Casing/CasingComponentIcon.js";import"../../../../Casing/CasingTable/index.js";import"../../../../WellSummary/WellSummaryItemLabel.js";import"../../../../WellSummary/WellSummaryItemTitle.js";import"../../../../WellSummary/WellSummaryItemValue.js";import"../../../../WellSummary/ActivitySummaryChart.js";import"../../../../WellSummary/FracWirelineTimeChart.js";import"../../../../BICOffsetPickerDialog/index.js";import"../../../../OffsetWellPickerV2/OffsetWellPickerDialog.js";import"../../../../Notifications/Notifications.js";import"../../../../TextLink/index.js";import"../../../../Template/TemplatePopover/index.js";import"../../../../PinnableFilters/PinnableFilters.js";import"../../../../HeaderLayout/HeaderLayout.js";import"../../../../PadOffsetsPicker/PadOffsetsPicker.js";import"../../../../PadOffsetsPicker/OffsetAssetChip.js";import"../../../../PadOffsetsPicker/OffsetAssetsListExpander.js";import"../../../../PadOffsetsPicker/StagesSelector.js";import"../../../../Table/TableToolbar/TableToolbar.js";import"../../../../PriceInput/PriceInput.js";import"../../../../LabelsCounter/LabelsCounter.js";import"../../../../Stepper/Step.js";import"../../../../Stepper/StepsWrapper.js";import"../../../../Stepper/Stepper.js";import"../../../../Comment/CommentIcon/index.js";import"../../../../FilesLoader/FilesLoader.js";import"../../../../SearchInput/index.js";function m(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(t);e&&(i=i.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),r.push.apply(r,i)}return r}function l(e){for(var r=1;r<arguments.length;r++){var i=null!=arguments[r]?arguments[r]:{};r%2?m(Object(i),!0).forEach((function(r){t(e,r,i[r])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):m(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}function d(t){var m,d=t.AppComponent,j=t.app,c=t.appData,u=t.appProps,S=t.isAppNotSubscribed,g=t.isLoading,A=t.isMultiRig,P=t.layoutEnvironment,b=t.segment,E=null==u||null===(m=u.coordinates)||void 0===m?void 0:m.pixelHeight;if(!j.package)return r(p,{app:j,children:r(a,{title:a.APP_MESSAGES.appPackageWasNotFound.title,subtitle:a.APP_MESSAGES.appPackageWasNotFound.subtitle,appHeight:E,state:a.EMPTY_STATES.error})});if(g)return r(s,{});if(S){var f=a.APP_MESSAGES.appNotSubscribed,x=f.title,C=f.subtitle;return r(p,{app:j,children:r(a,{title:x,subtitle:C,appHeight:E,state:a.EMPTY_STATES.noSubscription})})}if(!d)return r(p,{message:"App component was not found",app:j});if(!A){var h;if(c.rig&&!c.well)return r(p,{app:j,message:i(o,{children:[c.rig.name,r("br",{}),"has no active well"]})});if("general"===(null==P?void 0:P.type)&&b===e.COMPLETION&&!c.fracFleet)return r(p,{app:j,children:r(a,{title:a.APP_MESSAGES.fracFleetWasNotFound.title,appHeight:E,state:a.EMPTY_STATES.empty})});if(!("general"!==(null==P?void 0:P.type)||b!==e.COMPLETION||null!==(h=c.fracFleet)&&void 0!==h&&h.current_pad_id||j.settings.padId))return r(p,{app:j,children:r(a,{title:a.APP_MESSAGES.fracFleetHasNoPad.title,appHeight:E,state:a.EMPTY_STATES.empty})});if("general"===(null==P?void 0:P.type)&&b===e.COMPLETION&&(!c.wells||c.wells.length<1))return r(p,{app:j,children:r(a,{title:a.APP_MESSAGES.padHasNoWells.title,appHeight:E,state:a.EMPTY_STATES.empty})});if(!(c.rig||c.well||c.settings||c.wells))return r(p,{app:j,message:"No asset data were found"})}return r(n,{ErrorView:r(a,{title:a.APP_MESSAGES.internalAppError.title,subtitle:a.APP_MESSAGES.internalAppError.subtitle,appHeight:E,state:a.EMPTY_STATES.error}),app:j,withAppHeader:!0,children:r(d,l(l(l({app:j},j.settings),c),u))})}export default d;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{jsxs as
|
|
1
|
+
import e from"@babel/runtime/helpers/defineProperty";import{jsxs as t,jsx as a}from"react/jsx-runtime";import{makeStyles as i}from"@material-ui/core";import r from"prop-types";import o from"classnames";var n,s={appNotSubscribed:{title:"No Subscriptions exist for this app.",subtitle:"Contact your Corva Account rep to get acces to this app!"},assetNotSubscribed:{title:"Selected Asset is no longer subscribed to the app.",subtitle:"Сhange the asset in settings."},internalAppError:{title:"App Loading Error",subtitle:t("span",{children:["This app failed to load. Try refreshing the page or",a("span",{styles:{color:"blue"},onClick:function(){return window.Intercom&&window.Intercom("show")},children:"contact support"}),"."]})},appPackageWasNotFound:{title:"App package was not found",subtitle:"Please choose another version in the app settings menu or delete and add app again on your dashboard"},fracFleetWasNotFound:{title:"Frac fleet was not found"},fracFleetHasNoPad:{title:"Frac fleet has no active pad"},padHasNoWells:{title:"This pad has no wells"}},l={empty:"empty",error:"error",noData:"noData",noSubscription:"noSubscription"},p=(e(n={},l.empty,"/static/media/e607e3aa0a4603bb7ae7f83a2148511e.svg"),e(n,l.error,"/static/media/9b185a425ea91b6c2beedfef39c06663.svg"),e(n,l.noData,"/static/media/1bfc6e5d9cbb531a554ab8d025fa23e9.svg"),e(n,l.noSubscription,"/static/media/76e3ee12638391cba164716321509ad7.svg"),n),c=i((function(e){var t=e.palette;return{wrapper:{display:"flex",flexDirection:"column",textAlign:"center",alignItems:"center",justifyContent:"center",height:"100%",padding:24,overflow:"auto"},title:{color:t.primary.text7,fontSize:32,lineHeight:"38px",marginBottom:8,"&.medium":{fontSize:24,lineHeight:"28px"},"&.small":{fontSize:24,lineHeight:"28px"}},subtitle:{color:t.primary.text6,fontSize:16,lineHeight:"22px",marginBottom:24,"&.medium":{fontSize:14,lineHeight:"20px"},"&.small":{fontSize:14,lineHeight:"20px"}},imageWrapper:{display:"flex",flexGrow:"1",maxWidth:390,maxHeight:300,width:"100%","&.medium":{maxidth:260,maxHeight:200}},backgroundImage:{width:"100%",backgroundImage:function(e){return"url(".concat([p[e.state]],")")},backgroundRepeat:"no-repeat",backgroundPosition:"center",backgroundSize:"contain"}}}));function d(e){var i=e.title,r=e.subtitle,n=e.appHeight,s=e.state,l=c({state:s}),p=n<300,d=n<400;return t("div",{className:l.wrapper,children:[a("div",{className:o(l.title,d&&"medium",p&&"small"),children:i}),r&&a("div",{className:o(l.subtitle,d&&"medium",p&&"small"),children:r}),!p&&a("div",{className:o(l.imageWrapper,d&&"medium"),children:a("div",{className:l.backgroundImage})})]})}d.propTypes={title:r.string.isRequired,subtitle:r.string,appHeight:r.number.isRequired,state:r.string},d.defaultProps={subtitle:"",state:l.empty},d.APP_MESSAGES=s,d.EMPTY_STATES=l;export default d;export{s as APP_MESSAGES,l as EMPTY_STATES};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import t from"@babel/runtime/helpers/defineProperty";import{jsx as n}from"react/jsx-runtime";import{makeStyles as
|
|
1
|
+
import t from"@babel/runtime/helpers/defineProperty";import{jsx as n}from"react/jsx-runtime";import{makeStyles as r,TextField as e,InputAdornment as o}from"@material-ui/core";import u from"../../config/theme/palette.mjs.js";import i from"@babel/runtime/helpers/objectWithoutProperties";import s from"prop-types";import{useCustomShrink as l}from"./effects/index.js";function a(t,n){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var e=Object.getOwnPropertySymbols(t);n&&(e=e.filter((function(n){return Object.getOwnPropertyDescriptor(t,n).enumerable}))),r.push.apply(r,e)}return r}function p(n){for(var r=1;r<arguments.length;r++){var e=null!=arguments[r]?arguments[r]:{};r%2?a(Object(e),!0).forEach((function(r){t(n,r,e[r])})):Object.getOwnPropertyDescriptors?Object.defineProperties(n,Object.getOwnPropertyDescriptors(e)):a(Object(e)).forEach((function(t){Object.defineProperty(n,t,Object.getOwnPropertyDescriptor(e,t))}))}return n}var c=r((function(t){return{textField:{marginTop:16,marginBottom:8,"& .MuiFormLabel-root":{marginLeft:function(t){return t.startlabelOffset?"".concat(t.startlabelOffset+8,"px"):0},marginRight:function(t){return t.endlabelOffset?"".concat(t.endlabelOffset+8,"px"):0}},"&:hover":{"&.MuiTextField-root .MuiInput-root":{"& .MuiInputAdornment-root svg.MuiSvgIcon-root":{fill:u.primary.contrastText}}},"&.MuiTextField-root .MuiInput-root":{"& .MuiInputAdornment-root svg.MuiSvgIcon-root":{width:16,height:16,fontSize:16,fill:"#DADADA"},"&.Mui-error .MuiInputAdornment-root svg.MuiSvgIcon-root":{fill:"".concat(t.palette.error.main," !important")}},"& .Mui-focused .MuiInputAdornment-root svg.MuiSvgIcon-root":{fill:"".concat(t.palette.primary.main," !important")}},shrunkLabel:{"&.MuiInputLabel-shrink.MuiFormLabel-root":{marginLeft:0}}}})),f=function(t){var r=t.startIcon,u=t.endIcon,s=t.onFocus,a=t.onBlur,f=t.InputProps,d=t.value,m=t.startAdornment,b=t.endAdornment,I=i(t,["startIcon","endIcon","onFocus","onBlur","InputProps","value","startAdornment","endAdornment"]),O=l({startIcon:r,endIcon:u,onFocus:s,onBlur:a,value:d,InputProps:f}),g=O.shrink,v=O.onInputFocus,h=O.onInputBlur,P=O.startlabelOffset,A=O.endlabelOffset,M=O.startAdornmentRef,j=O.endAdornmentRef,y=c({startlabelOffset:P,endlabelOffset:A});return n(e,p(p({},I),{},{onFocus:v,onBlur:h,classes:{root:y.textField},InputLabelProps:p({shrink:g,classes:{shrink:y.shrunkLabel}},t.InputLabelProps),InputProps:p({startAdornment:r?n(o,{position:"start",ref:M,children:r}):m,endAdornment:u?n(o,{position:"end",ref:j,children:u}):b},t.InputProps)}))};f.propTypes={startIcon:s.node,endIcon:s.node,InputProps:s.shape({startAdornment:null}),InputLabelProps:s.shape({startAdornment:null}),value:s.oneOf([s.string,s.number]),onFocus:s.func,onBlur:s.func,endAdornment:s.node,startAdornment:s.node},f.defaultProps={startIcon:null,endIcon:null,InputProps:void 0,InputLabelProps:void 0,value:"",onFocus:void 0,onBlur:void 0,endAdornment:null,startAdornment:null};export default f;
|
package/package.json
CHANGED
|
Binary file
|