@corva/ui 0.26.0-7 → 0.26.0-8

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.
@@ -1 +1 @@
1
- import"@babel/runtime/helpers/defineProperty";import{get as r}from"lodash";import{updateUserUnits as t}from"../../../utils/convert.js";import e from"@babel/runtime/helpers/slicedToArray";import n from"@babel/runtime/regenerator";import o from"@babel/runtime/helpers/asyncToGenerator";import{useState as s,useEffect as i}from"react";import{setAuthToken as a,removeAuthToken as u,getAuthToken as c}from"../../../clients/clientStorage/index.js";import{post as p}from"../../../clients/api/apiCore.js";import"../../../clients/constants.js";import{getCurrentUser as l}from"../../../clients/jsonApi/index.js";import"../../../clients/subscriptions.js";import"uuid";import{LOGIN_ROUTE_REG_EXP as m}from"../../constants/index.js";function f(f){var h=s(null),v=e(h,2),d=v[0],b=v[1],y=s(!0),x=e(y,2),g=x[0],j=x[1],w=s(null),k=e(w,2),_=k[0],A=k[1];function T(){return U.apply(this,arguments)}function U(){return(U=o(n.mark((function e(){var o;return n.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.prev=0,j(!0),e.next=4,l();case 4:o=e.sent,b(o),t({userUnits:o.unit_system,companyUnits:r(o,"company.unit_system")}),e.next=14;break;case 9:e.prev=9,e.t0=e.catch(0),u(),f.push("/login"),console.error(e.t0);case 14:j(!1);case 15:case"end":return e.stop()}}),e,null,[[0,9]])})))).apply(this,arguments)}var C,G=(C=o(n.mark((function r(t,e){var o;return n.wrap((function(r){for(;;)switch(r.prev=r.next){case 0:return r.prev=0,A(null),j(!0),r.next=5,p("/v1/user_token",{auth:t});case 5:o=r.sent,a(o.jwt),r.next=14;break;case 9:return r.prev=9,r.t0=r.catch(0),console.error(r.t0),j(!1),r.abrupt("return",A("Wrong user name or password"));case 14:T().then(e);case 15:case"end":return r.stop()}}),r,null,[[0,9]])}))),function(r,t){return C.apply(this,arguments)});return i((function(){var r;try{r=c()}catch(r){u()}var t=m.test(f.location.pathname);return!r&&t?j(!1):r?void T():(f.push("/login"),j(!1))}),[]),{user:d,loading:g,error:_,login:G,logout:function(){u(),f.push("/login")}}}export default f;
1
+ import"@babel/runtime/helpers/defineProperty";import{get as r}from"lodash";import{updateUserUnits as t}from"../../../utils/convert.js";import e from"@babel/runtime/helpers/slicedToArray";import n from"@babel/runtime/regenerator";import o from"@babel/runtime/helpers/asyncToGenerator";import{useState as s,useRef as i,useEffect as a}from"react";import{setAuthToken as u,removeAuthToken as c,getAuthToken as p}from"../../../clients/clientStorage/index.js";import{post as l}from"../../../clients/api/apiCore.js";import"../../../clients/constants.js";import{getCurrentUser as m}from"../../../clients/jsonApi/index.js";import"../../../clients/subscriptions.js";import"uuid";import{LOGIN_ROUTE_REG_EXP as f}from"../../constants/index.js";import h from"../../../clients/auth0/index.js";function v(v){var d=s(null),b=e(d,2),x=b[0],y=b[1],j=s(!0),g=e(j,2),w=g[0],k=g[1],_=s(null),A=e(_,2),T=A[0],U=A[1],C=i();function G(){return P.apply(this,arguments)}function P(){return(P=o(n.mark((function e(){var o;return n.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.prev=0,k(!0),e.next=4,m();case 4:o=e.sent,y(o),t({userUnits:o.unit_system,companyUnits:r(o,"company.unit_system")}),e.next=14;break;case 9:e.prev=9,e.t0=e.catch(0),c(),v.push("/login"),console.error(e.t0);case 14:k(!1);case 15:case"end":return e.stop()}}),e,null,[[0,9]])})))).apply(this,arguments)}C.current||(C.current=new h);var S,W=(S=o(n.mark((function r(t,e){var o;return n.wrap((function(r){for(;;)switch(r.prev=r.next){case 0:return r.prev=0,U(null),k(!0),r.next=5,l("/v1/user_token",{auth:t});case 5:o=r.sent,u(o.jwt),r.next=14;break;case 9:return r.prev=9,r.t0=r.catch(0),console.error(r.t0),k(!1),r.abrupt("return",U("Wrong user name or password"));case 14:G().then(e);case 15:case"end":return r.stop()}}),r,null,[[0,9]])}))),function(r,t){return S.apply(this,arguments)});return a((function(){var r;try{r=p()}catch(r){c()}var t=f.test(v.location.pathname);return!r&&t?k(!1):r?void G():(v.push("/login"),k(!1))}),[]),{user:x,loading:w,error:T,login:W,logout:function(){c(),v.push("/login")},auth0:C.current}}export default v;
@@ -1 +1 @@
1
- import o from"@babel/runtime/helpers/slicedToArray";import n from"@babel/runtime/regenerator";import r from"@babel/runtime/helpers/asyncToGenerator";import{jsxs as e,jsx as t}from"react/jsx-runtime";import{styled as i,Grid as m,Button as s}from"@material-ui/core";import{memo as a,useState as p}from"react";import c from"prop-types";import"../../../../components/Login/components/Login.js";import l from"../../../../components/Login/components/PasswordField.js";import d from"../../../../components/Login/components/Chip.js";import u from"../../../../components/Login/components/StepFooter.js";import f from"../../../../components/Login/components/StepContent.js";import g from"../../../../components/Login/components/StepHeader.js";import h from"../../../../components/Login/components/Step.js";import v from"../../../../components/Login/components/OrDivider.js";import j from"../../../../components/Login/components/HiddenEmailField.js";import"../../../../components/Login/components/EmailField.js";import{useAuth as L}from"../../../context/auth.js";import{NEED_HELP_EXTERNAL_LINK as b}from"../../../constants/index.js";import y from"./SSOButton.js";var w=i(m)((function(o){var n=o.theme;return{marginTop:2*n.spacing(1),marginBottom:2*n.spacing(1),"&:first-of-type":{marginTop:0},"&:last-of-type":{marginBottom:0}}})),S=i(s)((function(o){var n=o.theme;return{width:71,padding:n.spacing(),whiteSpace:"nowrap",backgroundColor:n.status.loginButton,"&:hover":{backgroundColor:"".concat(n.status.loginButtonHovered)}}}));function k(i){var s,a=i.email,c=i.schemas,k=i.onBack,B=i.onFinishLogin,C=L(),x=p(""),F=o(x,2),q=F[0],R=F[1],T=p(!1),H=o(T,2),I=H[0],E=H[1],O=I?C.error:null,A=(s=r(n.mark((function o(r){return n.wrap((function(o){for(;;)switch(o.prev=o.next){case 0:return r.preventDefault(),E(!0),o.next=4,C.login({email:a,password:q},B);case 4:case"end":return o.stop()}}),o)}))),function(o){return s.apply(this,arguments)}),D=c.find((function(o){return"password"===o.provider})),P=c.filter((function(o){return"password"!==o.provider}));return e(h,{children:[t(g,{children:"Sign In"}),t(f,{children:e(m,{container:!0,direction:"column",children:[t(d,{"data-not-migrated-MuiChip":!0,label:a,onClick:k}),P.map((function(o){return t(w,{item:!0,children:t(y,{title:o.title,provider:o.provider,connection:o.connection,redirectURI:"qwerty"})},o.title)})),D&&P.length>0&&t(m,{item:!0,children:t(v,{})}),D&&t(w,{item:!0,children:e("form",{id:"sign-in-form",onSubmit:A,children:[t(j,{email:a}),t(l,{value:q,onChange:function(o){R(o.target.value),E(!1)},disabled:C.loading,error:O})]})})]})}),t(u,{needHelpExternalLink:b,children:D&&t(S,{"data-testid":"".concat("AuthorizationPo","_signInButton"),form:"sign-in-form",type:"submit",variant:"contained",color:"primary",disabled:!q||C.loading||!!O,onClick:A,children:"Sign In"})})]})}k.propTypes={email:c.string.isRequired,schemas:c.arrayOf(c.shape({})).isRequired,onBack:c.func.isRequired,onFinishLogin:c.func.isRequired};var B=a(k);export default B;
1
+ import o from"@babel/runtime/helpers/slicedToArray";import n from"@babel/runtime/regenerator";import r from"@babel/runtime/helpers/asyncToGenerator";import{jsxs as t,jsx as e}from"react/jsx-runtime";import{styled as i,Grid as m,Button as a}from"@material-ui/core";import{memo as s,useState as p}from"react";import c from"prop-types";import"../../../../components/Login/components/Login.js";import l from"../../../../components/Login/components/PasswordField.js";import d from"../../../../components/Login/components/Chip.js";import u from"../../../../components/Login/components/StepFooter.js";import f from"../../../../components/Login/components/StepContent.js";import g from"../../../../components/Login/components/StepHeader.js";import h from"../../../../components/Login/components/Step.js";import v from"../../../../components/Login/components/OrDivider.js";import j from"../../../../components/Login/components/HiddenEmailField.js";import"../../../../components/Login/components/EmailField.js";import{useAuth as L}from"../../../context/auth.js";import{NEED_HELP_EXTERNAL_LINK as b}from"../../../constants/index.js";import y from"./SSOButton.js";var w=i(m)((function(o){var n=o.theme;return{marginTop:2*n.spacing(1),marginBottom:2*n.spacing(1),"&:first-of-type":{marginTop:0},"&:last-of-type":{marginBottom:0}}})),S=i(a)((function(o){var n=o.theme;return{width:71,padding:n.spacing(),whiteSpace:"nowrap",backgroundColor:n.status.loginButton,"&:hover":{backgroundColor:"".concat(n.status.loginButtonHovered)}}}));function k(i){var a,s=i.email,c=i.schemas,k=i.onBack,B=i.onFinishLogin,C=L(),x=p(""),F=o(x,2),q=F[0],R=F[1],T=p(!1),H=o(T,2),I=H[0],E=H[1],O=I?C.error:null,A=(a=r(n.mark((function o(r){return n.wrap((function(o){for(;;)switch(o.prev=o.next){case 0:return r.preventDefault(),E(!0),o.next=4,C.login({email:s,password:q},B);case 4:case"end":return o.stop()}}),o)}))),function(o){return a.apply(this,arguments)}),D=c.find((function(o){return"password"===o.provider})),P=c.filter((function(o){return"password"!==o.provider}));return t(h,{children:[e(g,{children:"Sign In"}),e(f,{children:t(m,{container:!0,direction:"column",children:[e(d,{"data-not-migrated-MuiChip":!0,label:s,onClick:k}),P.map((function(o){return e(w,{item:!0,children:e(y,{title:o.title,provider:o.provider,connection:o.connection,redirectURI:"qwerty",auth0:C.auth0})},o.title)})),D&&P.length>0&&e(m,{item:!0,children:e(v,{})}),D&&e(w,{item:!0,children:t("form",{id:"sign-in-form",onSubmit:A,children:[e(j,{email:s}),e(l,{value:q,onChange:function(o){R(o.target.value),E(!1)},disabled:C.loading,error:O})]})})]})}),e(u,{needHelpExternalLink:b,children:D&&e(S,{"data-testid":"".concat("AuthorizationPo","_signInButton"),form:"sign-in-form",type:"submit",variant:"contained",color:"primary",disabled:!q||C.loading||!!O,onClick:A,children:"Sign In"})})]})}k.propTypes={email:c.string.isRequired,schemas:c.arrayOf(c.shape({})).isRequired,onBack:c.func.isRequired,onFinishLogin:c.func.isRequired};var B=s(k);export default B;
@@ -1 +1 @@
1
- import r from"@babel/runtime/helpers/slicedToArray";import{jsx as e,jsxs as t}from"react/jsx-runtime";import{withStyles as i,ButtonBase as o,Grid as s,Avatar as n,Typography as a,CircularProgress as l}from"@material-ui/core";import{useState as c}from"react";import d from"prop-types";import g from"../../../../clients/auth0/index.js";var m={google:"/static/media/55de612562c712e3a9d6ea86000e18c7.svg",microsoft:"/static/media/319d9b9a39d511547cf55d1336a8eca4.svg"};function p(i){var d=i.connection,p=i.title,u=i.provider,f=i.classes,h=c(!1),b=r(h,2),v=b[0],R=b[1],y=m[u];return e(o,{className:f.button,onClick:function(r){r.preventDefault(),v||(R(!0),g.loginWithConnection(d))},children:t(s,{container:!0,justify:"space-between",alignItems:"center",children:[e(s,{item:!0,children:t(s,{container:!0,justify:"flex-start",alignItems:"center",children:[e(s,{item:!0,children:y?e("img",{className:f.logo,src:y,alt:p}):e(n,{className:f.avatar,children:p&&p[0].toUpperCase()})}),e(s,{item:!0,children:e(a,{variant:"body2",children:p})})]})}),e(s,{item:!0,children:v&&e(l,{classes:{root:f.progressRoot,colorPrimary:f.progressColor},color:"primary",size:30})})]})})}p.propTypes={title:d.string.isRequired,provider:d.string.isRequired,connection:d.string.isRequired,classes:d.shape({button:d.string.isRequired,logo:d.string.isRequired,avatar:d.string.isRequired,progressRoot:d.string.isRequired,progressColor:d.string.isRequired}).isRequired};var u=i((function(r){return{button:{width:"100%",height:56,fontSize:16,fontWeight:400,color:"#fff",display:"inline-flex",padding:0,alignItems:"center",justifyContent:"flex-start",whiteSpace:"nowrap",borderRadius:4,borderWidth:1,borderStyle:"solid",borderColor:"#616161",textDecoration:"none","&:hover":{borderColor:r.status.loginButton}},logo:{height:30,width:30,margin:12},avatar:{height:30,width:30,margin:12,color:"#ffffff",backgroundColor:r.status.loginButton},progressRoot:{margin:"12px 24px"},progressColor:{color:r.status.loginButton}}}))(p);export default u;
1
+ import e from"@babel/runtime/helpers/slicedToArray";import{jsx as r,jsxs as t}from"react/jsx-runtime";import{withStyles as o,ButtonBase as i,Grid as n,Avatar as a,Typography as l,CircularProgress as s}from"@material-ui/core";import{useState as c}from"react";var d={google:"/static/media/55de612562c712e3a9d6ea86000e18c7.svg",microsoft:"/static/media/319d9b9a39d511547cf55d1336a8eca4.svg"};var m=o((function(e){return{button:{width:"100%",height:56,fontSize:16,fontWeight:400,color:"#fff",display:"inline-flex",padding:0,alignItems:"center",justifyContent:"flex-start",whiteSpace:"nowrap",borderRadius:4,borderWidth:1,borderStyle:"solid",borderColor:"#616161",textDecoration:"none","&:hover":{borderColor:e.status.loginButton}},logo:{height:30,width:30,margin:12},avatar:{height:30,width:30,margin:12,color:"#ffffff",backgroundColor:e.status.loginButton},progressRoot:{margin:"12px 24px"},progressColor:{color:e.status.loginButton}}}))((function(o){var m=o.connection,f=o.title,g=o.provider,h=o.auth0,u=o.classes,p=c(!1),b=e(p,2),v=b[0],y=b[1],C=d[g];return r(i,{className:u.button,onClick:function(e){e.preventDefault(),v||(y(!0),h.loginWithConnection(m))},children:t(n,{container:!0,justify:"space-between",alignItems:"center",children:[r(n,{item:!0,children:t(n,{container:!0,justify:"flex-start",alignItems:"center",children:[r(n,{item:!0,children:C?r("img",{className:u.logo,src:C,alt:f}):r(a,{className:u.avatar,children:f&&f[0].toUpperCase()})}),r(n,{item:!0,children:r(l,{variant:"body2",children:f})})]})}),r(n,{item:!0,children:v&&r(s,{classes:{root:u.progressRoot,colorPrimary:u.progressColor},color:"primary",size:30})})]})})}));export default m;
@@ -1 +1 @@
1
- import"@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"../../../constants/segment.js";import"../../../constants/apps.js";import"../../../constants/drillstring.js";import"@babel/runtime/regenerator";import"@babel/runtime/helpers/asyncToGenerator";import"../../../utils/mobileDetect.js";import{showErrorNotification as o}from"../../../utils/notificationToasts.js";import"@babel/runtime/helpers/typeof";import"../../../utils/index.js";import{jsx as t}from"react/jsx-runtime";import"@material-ui/core";import{useEffect as e}from"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"../../../components/Modal/index.js";import"../../../components/IconMenu/index.js";import"../../../components/StyledMenuItem/index.js";import n from"../../../components/LoadingIndicator/LoadingIndicator.js";import"../../../components/Tooltip.js";import"../../../components/Avatar/index.js";import"../../../components/Annotations/AnnotationsContext.js";import"../../../components/DevCenter/DevCenterRouterContext/DevCenterRouterContext.js";import"react-router";import"../../../components/DevCenter/DevCenterRouterContext/UniversalLink/UniversalLink.js";import"../../../components/ConfirmationDialog.js";import"../../../components/Annotations/components/AnnotationsList/index.js";import"../../../components/Annotations/components/LastAnnotation/index.js";import"../../../components/PadModeSelect/PadModeSelect.js";import"../../../components/DevCenter/AppHeader/AppHeader.js";import"../../../components/DevCenter/AppSideBar/AppSideBar.js";import"../../../components/DevCenter/AppContext.js";import"../../../components/DevCenter/AppsDataProvider/AppsDataProvider.js";import"../../../components/DevCenter/DevCenterAppContainer/components/AppActions/AppActions.css.js";import"../../../components/ErrorBoundary/InternalErrorView/InternalErrorView.js";import"../../../components/ErrorBoundary/ErrorBoundary.js";import"../../../components/Typography.js";import"../../../components/ErrorBoundary/DevCenterAppErrorView/DevCenterAppErrorView.js";import"../../../components/SlateFormattedText/RenderElements.js";import"../../../components/SlateFormattedText/SlateFormattedText.js";import"../../../components/DevCenter/DevCenterAppContainer/components/AppSettingsDialog/AppSettingsDialog.js";import"../../../components/DevCenter/DevCenterAppContainer/components/AnnotationsButton/AnnotationsButton.js";import"../../../components/DevCenter/DevCenterAppContainer/components/NonPriorityMenus/NonPriorityMenus.js";import"../../../components/DevCenter/DevCenterAppContainer/components/FullscreenButton/FullscreenButton.js";import"../../../components/DevCenter/DevCenterAppContainer/components/AppInfoMessage/AppInfoMessage.js";import"../../../components/DevCenter/DevCenterAppContainer/DevCenterAppContainer.css.js";import"../../../components/DevCenter/DevCenterAppContainer/components/RestoreAppSizeButton/index.js";import"../../../components/DevCenter/DevCenterAppContainer/components/PriorityMenus/PriorityMenus.css.js";import"../../../components/DevCenter/NavigationBar/NavigationBar.js";import"../../../components/DevCenter/SideBar/SideBar.js";import"../../../components/TruncatedText/index.js";import"../../../components/AssetEditor/SingleAssetEditor.js";import"../../../components/AssetEditor/AssetEditorAutocomplete.js";import"../../../components/AssetEditor/index.js";import"../../../components/AppVersionsSelect/AppVersionsSelect.js";import"../../../components/CollapsableSidebar.js";import"../../../components/DateTimePicker/index.js";import"../../../components/DatePicker/index.js";import"../../../components/ColorPicker/ColorPicker.js";import"../../../components/ParameterCharts/AddEditTrack.js";import"../../../components/ParameterCharts/ParameterCharts.js";import"../../../components/ChartActionsList/ChartActionsList.js";import"../../../components/SettingEditors/ColorEditor/index.js";import"../../../components/SettingEditors/DropdownEditor/index.js";import"../../../components/SettingEditors/RadioEditor/index.js";import"../../../components/SwitchControl/index.js";import"../../../components/RangeSlider/RangeSlider.js";import"../../../components/Login/components/Login.js";import"../../../components/Login/components/PasswordField.js";import"../../../components/Login/components/Chip.js";import"../../../components/Login/components/StepFooter.js";import"../../../components/Login/components/StepContent.js";import"../../../components/Login/components/StepHeader.js";import"../../../components/Login/components/Step.js";import"../../../components/Login/components/OrDivider.js";import"../../../components/Login/components/HiddenEmailField.js";import"../../../components/Login/components/EmailField.js";import"../../../components/Breadcrumbs/index.js";import"../../../components/VirtualizedTable/index.js";import"../../../components/EmptyView/index.js";import"../../../components/EmptyView/EmptyAppView/index.js";import"../../../components/Button/index.js";import"../../../components/MenuItem/index.js";import"../../../components/ContextMenuItem/index.js";import"../../../components/FolderMenuItem/index.js";import"../../../components/EditableItem/EditableItem/index.js";import"../../../components/EditableItem/EditableItemWithBadge/index.js";import"../../../components/Checkbox/index.js";import"../../../components/FolderMenuItemWithLinks/index.js";import"../../../components/IconButton/index.js";import"../../../components/Chip/index.js";import"../../../components/Counter/index.js";import"../../../components/AnchorsList/AnchorsList.js";import"../../../components/Select/index.js";import"../../../components/Tabs/Tabs.js";import"../../../components/Tabs/Tab.js";import"../../../components/Drillstring/BHASchematic.js";import"../../../components/Drillstring/BHAComponentIcon.js";import"../../../components/Drillstring/BHATable/index.js";import"../../../components/Drillstring/BHAComponentDetail/index.js";import"../../../components/Casing/CasingComponentIcon.js";import"../../../components/Casing/CasingTable/index.js";import"../../../components/WellSummary/WellSummaryItemLabel.js";import"../../../components/WellSummary/WellSummaryItemTitle.js";import"../../../components/WellSummary/WellSummaryItemValue.js";import"../../../components/WellSummary/ActivitySummaryChart.js";import"../../../components/WellSummary/FracWirelineTimeChart.js";import"../../../components/BICOffsetPickerDialog/index.js";import"../../../components/OffsetWellPickerV2/OffsetWellPickerDialog.js";import"../../../components/Notifications/Notifications.js";import"../../../components/TextLink/index.js";import"../../../components/Template/TemplatePopover/index.js";import"../../../components/PinnableFilters/PinnableFilters.js";import"../../../components/HeaderLayout/HeaderLayout.js";import"../../../components/PadOffsetsPicker/PadOffsetsPicker.js";import"../../../components/PadOffsetsPicker/OffsetAssetChip.js";import"../../../components/PadOffsetsPicker/OffsetAssetsListExpander.js";import"../../../components/PadOffsetsPicker/StagesSelector.js";import"../../../components/Table/TableToolbar/TableToolbar.js";import"../../../components/PriceInput/PriceInput.js";import"../../../components/LabelsCounter/LabelsCounter.js";import"../../../components/Stepper/Step.js";import"../../../components/Stepper/StepsWrapper.js";import"../../../components/Stepper/Stepper.js";import"../../../components/Comment/CommentIcon/index.js";import"../../../components/FilesLoader/FilesLoader.js";import{useAuth as s}from"../../context/auth.js";import r from"../../../clients/auth0/index.js";function i(i){var p=i.router,m=s().login;return e((function(){r.handleAuthentication((function(o){return m({token:o.accessToken},(function(){return p.push("/")}))}),(function(){o("Sorry, but we couldn’t log you in. Please contact Corva support if you need assistance"),p.push("/login")}))}),[]),t(n,{fullscreen:!1})}export default i;
1
+ import"@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"../../../constants/segment.js";import"../../../constants/apps.js";import"../../../constants/drillstring.js";import"@babel/runtime/regenerator";import"@babel/runtime/helpers/asyncToGenerator";import"../../../utils/mobileDetect.js";import{showErrorNotification as o}from"../../../utils/notificationToasts.js";import"@babel/runtime/helpers/typeof";import"../../../utils/index.js";import{jsx as t}from"react/jsx-runtime";import"@material-ui/core";import{useEffect as e}from"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"../../../components/Modal/index.js";import"../../../components/IconMenu/index.js";import"../../../components/StyledMenuItem/index.js";import n from"../../../components/LoadingIndicator/LoadingIndicator.js";import"../../../components/Tooltip.js";import"../../../components/Avatar/index.js";import"../../../components/Annotations/AnnotationsContext.js";import"../../../components/DevCenter/DevCenterRouterContext/DevCenterRouterContext.js";import"react-router";import"../../../components/DevCenter/DevCenterRouterContext/UniversalLink/UniversalLink.js";import"../../../components/ConfirmationDialog.js";import"../../../components/Annotations/components/AnnotationsList/index.js";import"../../../components/Annotations/components/LastAnnotation/index.js";import"../../../components/PadModeSelect/PadModeSelect.js";import"../../../components/DevCenter/AppHeader/AppHeader.js";import"../../../components/DevCenter/AppSideBar/AppSideBar.js";import"../../../components/DevCenter/AppContext.js";import"../../../components/DevCenter/AppsDataProvider/AppsDataProvider.js";import"../../../components/DevCenter/DevCenterAppContainer/components/AppActions/AppActions.css.js";import"../../../components/ErrorBoundary/InternalErrorView/InternalErrorView.js";import"../../../components/ErrorBoundary/ErrorBoundary.js";import"../../../components/Typography.js";import"../../../components/ErrorBoundary/DevCenterAppErrorView/DevCenterAppErrorView.js";import"../../../components/SlateFormattedText/RenderElements.js";import"../../../components/SlateFormattedText/SlateFormattedText.js";import"../../../components/DevCenter/DevCenterAppContainer/components/AppSettingsDialog/AppSettingsDialog.js";import"../../../components/DevCenter/DevCenterAppContainer/components/AnnotationsButton/AnnotationsButton.js";import"../../../components/DevCenter/DevCenterAppContainer/components/NonPriorityMenus/NonPriorityMenus.js";import"../../../components/DevCenter/DevCenterAppContainer/components/FullscreenButton/FullscreenButton.js";import"../../../components/DevCenter/DevCenterAppContainer/components/AppInfoMessage/AppInfoMessage.js";import"../../../components/DevCenter/DevCenterAppContainer/DevCenterAppContainer.css.js";import"../../../components/DevCenter/DevCenterAppContainer/components/RestoreAppSizeButton/index.js";import"../../../components/DevCenter/DevCenterAppContainer/components/PriorityMenus/PriorityMenus.css.js";import"../../../components/DevCenter/NavigationBar/NavigationBar.js";import"../../../components/DevCenter/SideBar/SideBar.js";import"../../../components/TruncatedText/index.js";import"../../../components/AssetEditor/SingleAssetEditor.js";import"../../../components/AssetEditor/AssetEditorAutocomplete.js";import"../../../components/AssetEditor/index.js";import"../../../components/AppVersionsSelect/AppVersionsSelect.js";import"../../../components/CollapsableSidebar.js";import"../../../components/DateTimePicker/index.js";import"../../../components/DatePicker/index.js";import"../../../components/ColorPicker/ColorPicker.js";import"../../../components/ParameterCharts/AddEditTrack.js";import"../../../components/ParameterCharts/ParameterCharts.js";import"../../../components/ChartActionsList/ChartActionsList.js";import"../../../components/SettingEditors/ColorEditor/index.js";import"../../../components/SettingEditors/DropdownEditor/index.js";import"../../../components/SettingEditors/RadioEditor/index.js";import"../../../components/SwitchControl/index.js";import"../../../components/RangeSlider/RangeSlider.js";import"../../../components/Login/components/Login.js";import"../../../components/Login/components/PasswordField.js";import"../../../components/Login/components/Chip.js";import"../../../components/Login/components/StepFooter.js";import"../../../components/Login/components/StepContent.js";import"../../../components/Login/components/StepHeader.js";import"../../../components/Login/components/Step.js";import"../../../components/Login/components/OrDivider.js";import"../../../components/Login/components/HiddenEmailField.js";import"../../../components/Login/components/EmailField.js";import"../../../components/Breadcrumbs/index.js";import"../../../components/VirtualizedTable/index.js";import"../../../components/EmptyView/index.js";import"../../../components/EmptyView/EmptyAppView/index.js";import"../../../components/Button/index.js";import"../../../components/MenuItem/index.js";import"../../../components/ContextMenuItem/index.js";import"../../../components/FolderMenuItem/index.js";import"../../../components/EditableItem/EditableItem/index.js";import"../../../components/EditableItem/EditableItemWithBadge/index.js";import"../../../components/Checkbox/index.js";import"../../../components/FolderMenuItemWithLinks/index.js";import"../../../components/IconButton/index.js";import"../../../components/Chip/index.js";import"../../../components/Counter/index.js";import"../../../components/AnchorsList/AnchorsList.js";import"../../../components/Select/index.js";import"../../../components/Tabs/Tabs.js";import"../../../components/Tabs/Tab.js";import"../../../components/Drillstring/BHASchematic.js";import"../../../components/Drillstring/BHAComponentIcon.js";import"../../../components/Drillstring/BHATable/index.js";import"../../../components/Drillstring/BHAComponentDetail/index.js";import"../../../components/Casing/CasingComponentIcon.js";import"../../../components/Casing/CasingTable/index.js";import"../../../components/WellSummary/WellSummaryItemLabel.js";import"../../../components/WellSummary/WellSummaryItemTitle.js";import"../../../components/WellSummary/WellSummaryItemValue.js";import"../../../components/WellSummary/ActivitySummaryChart.js";import"../../../components/WellSummary/FracWirelineTimeChart.js";import"../../../components/BICOffsetPickerDialog/index.js";import"../../../components/OffsetWellPickerV2/OffsetWellPickerDialog.js";import"../../../components/Notifications/Notifications.js";import"../../../components/TextLink/index.js";import"../../../components/Template/TemplatePopover/index.js";import"../../../components/PinnableFilters/PinnableFilters.js";import"../../../components/HeaderLayout/HeaderLayout.js";import"../../../components/PadOffsetsPicker/PadOffsetsPicker.js";import"../../../components/PadOffsetsPicker/OffsetAssetChip.js";import"../../../components/PadOffsetsPicker/OffsetAssetsListExpander.js";import"../../../components/PadOffsetsPicker/StagesSelector.js";import"../../../components/Table/TableToolbar/TableToolbar.js";import"../../../components/PriceInput/PriceInput.js";import"../../../components/LabelsCounter/LabelsCounter.js";import"../../../components/Stepper/Step.js";import"../../../components/Stepper/StepsWrapper.js";import"../../../components/Stepper/Stepper.js";import"../../../components/Comment/CommentIcon/index.js";import"../../../components/FilesLoader/FilesLoader.js";import{useAuth as s}from"../../context/auth.js";function r(r){var i=r.router,p=s(),m=p.login,c=p.auth0;return e((function(){c.handleAuthentication((function(o){return m({token:o.accessToken},(function(){return i.push("/")}))}),(function(){o("Sorry, but we couldn’t log you in. Please contact Corva support if you need assistance"),i.push("/login")}))}),[]),t(n,{fullscreen:!1})}export default r;
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var t,e=require('../../../ext-cjs/@babel/runtime/helpers/defineProperty.js');function r(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(t);e&&(a=a.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),r.push.apply(r,a)}return r}function a(t){for(var a=1;a<arguments.length;a++){var i=null!=arguments[a]?arguments[a]:{};a%2?r(Object(i),!0).forEach((function(r){e(t,r,i[r])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(i)):r(Object(i)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(i,e))}))}return t}var i={qa:"qa",staging:"staging",production:"production"},o={REACT_APP_AUTH0_REDIRECT_URI:"http://app.local.corva.ai:8080/login/oauth-callback",REACT_APP_AUTH0_DOMAIN:"corva.auth0.com",REACT_APP_AUTH0_CLIENT_ID:"L1B0xGD5AuXwuTDFdFA9czDTM7Vvw464"},c=(e(t={},i.qa,a(a({},o),{},{REACT_APP_API_URL:"https://api.qa.corva.ai",REACT_APP_SUBSCRIPTIONS_URL:"https://subscriptions.qa.corva.ai",REACT_APP_AUTH0_AUDIENCE:"https://api.qa.corva.ai/v1"})),e(t,i.staging,a(a({},o),{},{REACT_APP_API_URL:"https://api.staging.corva.ai",REACT_APP_SUBSCRIPTIONS_URL:"https://subscriptions.staging.corva.ai",REACT_APP_AUTH0_AUDIENCE:"https://api.staging.corva.ai/v1"})),e(t,i.production,a(a({},o),{},{REACT_APP_API_URL:"https://api.corva.ai",REACT_APP_SUBSCRIPTIONS_URL:"https://subscriptions.corva.ai",REACT_APP_AUTH0_AUDIENCE:"https://api.corva.ai/v1"})),t);exports.CORVA_API_ENVS=i,exports.CORVA_API_ENV_VARIABLES=c,exports.CORVA_GLOBAL_DEPENDENCIES={"@corva/ui":"","@material-ui/core":"4.11.2","@material-ui/icons":"4.9.1","@material-ui/lab":"4.0.0-alpha.57","@material-ui/pickers":"3.2.10",classnames:"2.2.6","corva-convert-units":"1.10.17",highcharts:"8.1.2","highcharts-react-official":"2.2.2",html2canvas:"1.0.0-alpha.12",jsona:"1.5.1",lodash:"^4.17.4","mapbox.js":"3.2.1",moment:"2.23.0","moment-timezone":"0.5.23",react:"17.0.1","react-dom":"17.0.1","react-sortable-hoc":"0.6.8","react-sizeme":"2.5.2","react-redux":"5.1.1","react-virtualized":"9.21.2",redux:"3.7.2","redux-thunk":"2.3.0",reselect:"2.5.4","prop-types":"^15.6.1",uuid:"3.4.0"};
1
+ "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var t,e=require('../../../ext-cjs/@babel/runtime/helpers/defineProperty.js');function r(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(t);e&&(a=a.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),r.push.apply(r,a)}return r}function a(t){for(var a=1;a<arguments.length;a++){var i=null!=arguments[a]?arguments[a]:{};a%2?r(Object(i),!0).forEach((function(r){e(t,r,i[r])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(i)):r(Object(i)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(i,e))}))}return t}var i={qa:"qa",staging:"staging",production:"production"},o={REACT_APP_AUTH0_REDIRECT_URI:"/login/oauth-callback",REACT_APP_AUTH0_DOMAIN:"corva.auth0.com",REACT_APP_AUTH0_CLIENT_ID:"L1B0xGD5AuXwuTDFdFA9czDTM7Vvw464"},c=(e(t={},i.qa,a(a({},o),{},{REACT_APP_API_URL:"https://api.qa.corva.ai",REACT_APP_SUBSCRIPTIONS_URL:"https://subscriptions.qa.corva.ai",REACT_APP_AUTH0_AUDIENCE:"https://api.qa.corva.ai/v1"})),e(t,i.staging,a(a({},o),{},{REACT_APP_API_URL:"https://api.staging.corva.ai",REACT_APP_SUBSCRIPTIONS_URL:"https://subscriptions.staging.corva.ai",REACT_APP_AUTH0_AUDIENCE:"https://api.staging.corva.ai/v1"})),e(t,i.production,a(a({},o),{},{REACT_APP_API_URL:"https://api.corva.ai",REACT_APP_SUBSCRIPTIONS_URL:"https://subscriptions.corva.ai",REACT_APP_AUTH0_AUDIENCE:"https://api.corva.ai/v1"})),t);exports.CORVA_API_ENVS=i,exports.CORVA_API_ENV_VARIABLES=c,exports.CORVA_GLOBAL_DEPENDENCIES={"@corva/ui":"","@material-ui/core":"4.11.2","@material-ui/icons":"4.9.1","@material-ui/lab":"4.0.0-alpha.57","@material-ui/pickers":"3.2.10",classnames:"2.2.6","corva-convert-units":"1.10.17",highcharts:"8.1.2","highcharts-react-official":"2.2.2",html2canvas:"1.0.0-alpha.12",jsona:"1.5.1",lodash:"^4.17.4","mapbox.js":"3.2.1",moment:"2.23.0","moment-timezone":"0.5.23",react:"17.0.1","react-dom":"17.0.1","react-sortable-hoc":"0.6.8","react-sizeme":"2.5.2","react-redux":"5.1.1","react-virtualized":"9.21.2",redux:"3.7.2","redux-thunk":"2.3.0",reselect:"2.5.4","prop-types":"^15.6.1",uuid:"3.4.0"};
@@ -1 +1 @@
1
- "use strict";var e=require('../../../ext-cjs/@babel/runtime/helpers/defineProperty.js'),r=require("./constants.js"),n=require("./webpack.config.common.js"),o=require("./plugins/checkCorvaUIVersion.js");function t(e,r){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);r&&(o=o.filter((function(r){return Object.getOwnPropertyDescriptor(e,r).enumerable}))),n.push.apply(n,o)}return n}function i(r){for(var n=1;n<arguments.length;n++){var o=null!=arguments[n]?arguments[n]:{};n%2?t(Object(o),!0).forEach((function(n){e(r,n,o[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(r,Object.getOwnPropertyDescriptors(o)):t(Object(o)).forEach((function(e){Object.defineProperty(r,e,Object.getOwnPropertyDescriptor(o,e))}))}return r}var c=require("webpack-merge").merge,s=require("path"),p=require("webpack"),l=require("clean-webpack-plugin").CleanWebpackPlugin,a=require("copy-webpack-plugin"),u=require("html-webpack-plugin"),d=require("chalk");require("dotenv").config({path:s.resolve(n.APP_DIRECTORY,"./.env")});module.exports=function(e,t){var v,O=process.env.HOST||"app.local.corva.ai",m=process.env.PORT||8080;return c(n.default(e,t),{mode:"development",devtool:"inline-source-map",devServer:{contentBase:"./dist",public:"".concat(O,":").concat(m),port:m},entry:s.resolve(__dirname,"DevServerEntryPoint.js"),plugins:[new l,new a({patterns:[{from:s.resolve(__dirname,"public")},{from:s.resolve(process.cwd(),"node_modules","@corva/ui/assets"),to:"static/media",noErrorOnMissing:!0}]}),new u({filename:"index.html",inject:!0,template:s.resolve(__dirname,"public","index.html")}),new p.EnvironmentPlugin(i(i({},process.env),{},{DEV_CENTER_APP_PATH:process.cwd(),REACT_APP_ENVIRONMENT:process.env.REACT_APP_ENVIRONMENT||"development"},(v=process.env.CORVA_API_ENV||r.CORVA_API_ENVS.production,v in r.CORVA_API_ENVS?r.CORVA_API_ENV_VARIABLES[v]:(console.log(d.red("CORVA_API_ENV should be one of [".concat(Object.keys(r.CORVA_API_ENVS).join(", "),"]"))),process.exit(1))))),o],module:{rules:[{test:/\.(png|jpe?g|gif)$/i,use:[{loader:"file-loader"}]},{test:/\.svg$/,use:[{loader:"svg-url-loader",options:{limit:1e4}}]}]}})};
1
+ "use strict";var e=require('../../../ext-cjs/@babel/runtime/helpers/defineProperty.js'),r=require("./constants.js"),o=require("./webpack.config.common.js"),n=require("./plugins/checkCorvaUIVersion.js");function t(e,r){var o=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);r&&(n=n.filter((function(r){return Object.getOwnPropertyDescriptor(e,r).enumerable}))),o.push.apply(o,n)}return o}function s(r){for(var o=1;o<arguments.length;o++){var n=null!=arguments[o]?arguments[o]:{};o%2?t(Object(n),!0).forEach((function(o){e(r,o,n[o])})):Object.getOwnPropertyDescriptors?Object.defineProperties(r,Object.getOwnPropertyDescriptors(n)):t(Object(n)).forEach((function(e){Object.defineProperty(r,e,Object.getOwnPropertyDescriptor(n,e))}))}return r}var i=require("webpack-merge").merge,c=require("path"),l=require("webpack"),p=require("clean-webpack-plugin").CleanWebpackPlugin,u=require("copy-webpack-plugin"),a=require("html-webpack-plugin"),d=require("chalk");require("dotenv").config({path:c.resolve(o.APP_DIRECTORY,"./.env")});module.exports=function(e,t){var v,O=process.env.HOST||t.host||"localhost",m=process.env.PORT||t.port||8080;return i(o.default(e,t),{mode:"development",devtool:"inline-source-map",devServer:{contentBase:"./dist",public:"".concat(O,":").concat(m),port:m},entry:c.resolve(__dirname,"DevServerEntryPoint.js"),plugins:[new p,new u({patterns:[{from:c.resolve(__dirname,"public")},{from:c.resolve(process.cwd(),"node_modules","@corva/ui/assets"),to:"static/media",noErrorOnMissing:!0}]}),new a({filename:"index.html",inject:!0,template:c.resolve(__dirname,"public","index.html")}),new l.EnvironmentPlugin(s(s({},process.env),{},{DEV_CENTER_APP_PATH:process.cwd(),REACT_APP_ENVIRONMENT:process.env.REACT_APP_ENVIRONMENT||"development"},(v=process.env.CORVA_API_ENV||r.CORVA_API_ENVS.production,v in r.CORVA_API_ENVS?r.CORVA_API_ENV_VARIABLES[v]:(console.log(d.red("CORVA_API_ENV should be one of [".concat(Object.keys(r.CORVA_API_ENVS).join(", "),"]"))),process.exit(1))))),n],module:{rules:[{test:/\.(png|jpe?g|gif)$/i,use:[{loader:"file-loader"}]},{test:/\.svg$/,use:[{loader:"svg-url-loader",options:{limit:1e4}}]}]}})};
@@ -1 +1 @@
1
- import e from"@babel/runtime/helpers/defineProperty";import n from"@babel/runtime/helpers/classCallCheck";import t from"auth0-js";var o=process.env.REACT_APP_AUTH0_DOMAIN?new function o(){var r=this;n(this,o),e(this,"handleAuthentication",(function(e,n){return r.webAuth.parseHash((function(t,o){o&&o.accessToken?e(o):t&&n(t)}))})),e(this,"loginWithConnection",(function(e){return r.webAuth.authorize({connection:e})})),this.webAuth=new t.WebAuth({domain:process.env.REACT_APP_AUTH0_DOMAIN,clientID:process.env.REACT_APP_AUTH0_CLIENT_ID,redirectUri:process.env.REACT_APP_AUTH0_REDIRECT_URI,audience:process.env.REACT_APP_AUTH0_AUDIENCE,responseType:"token",scope:"openid profile email"})}:{};export default o;
1
+ import e from"@babel/runtime/helpers/defineProperty";import n from"@babel/runtime/helpers/classCallCheck";import t from"auth0-js";var o=function o(){var i=this;n(this,o),e(this,"handleAuthentication",(function(e,n){return i.webAuth.parseHash((function(t,o){o&&o.accessToken?e(o):t&&n(t)}))})),e(this,"loginWithConnection",(function(e){return i.webAuth.authorize({connection:e})})),this.webAuth=new t.WebAuth({domain:process.env.REACT_APP_AUTH0_DOMAIN,clientID:process.env.REACT_APP_AUTH0_CLIENT_ID,redirectUri:"".concat(window.location.origin,"/login/oauth-callback"),audience:process.env.REACT_APP_AUTH0_AUDIENCE,responseType:"token",scope:"openid profile email"})};export default o;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@corva/ui",
3
- "version": "0.26.0-7",
3
+ "version": "0.26.0-8",
4
4
  "description": "Shared components/utils for Corva ui projects",
5
5
  "keywords": [
6
6
  "corva-ui"