@corva/ui 3.12.0-1 → 3.12.0-2

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
- "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require('./../../../../../ext-esm/tslib/tslib.es6.js'),t=require("react/jsx-runtime"),a=require("../../../../ErrorBoundary/ErrorBoundary.js");require("../../../../ErrorBoundary/DevCenterAppErrorView/DevCenterAppErrorView.js");var r=require("../../../../LoadingIndicator/LoadingIndicator.js"),s=require("../../../../../constants/segment.js"),i=require("../../../../EmptyState/EmptyState.js"),o=require("./components/ChooseAssetButton.js"),p=require("../AppInfoMessage/AppInfoMessage.js"),l="DevCenterAppView",n=function(e){return"".concat(e," has no active well")};function d(d){var u,c=d.AppComponent,S=d.app,E=d.appData,A=d.appProps,g=d.availability,P=d.isCLIApp,j=d.isLoading,f=d.isMultiRig,m=d.layoutEnvironment,b=d.openIntercom,M=d.segment,x=d.toggleAppSettingsDialog,v=null==A?void 0:A.appHeaderProps;if(!S.package)return t.jsx(p.default,{appHeaderProps:v,children:t.jsx(i,{"data-testid":"".concat(l,"_EmptyState"),title:i.APP_MESSAGES.appPackageWasNotFound.title,subtitle:i.APP_MESSAGES.appPackageWasNotFound.subtitle,image:i.IMAGES.AppLoadingError})});if(j)return t.jsx(p.default,{appHeaderProps:v,children:t.jsx(r,{})});if(!g.hasProductSubscription||!g.isAppSubscribedForAsset){var _=i.APP_MESSAGES,N=_.appNotSubscribed,y=_.appNotSubscribedForAsset,G=i.IMAGES.NoSubscription,I=g.hasProductSubscription?y:N,h=I.title,H=I.subtitle;return t.jsx(p.default,{appHeaderProps:v,children:t.jsx(i,{"data-testid":"".concat(l,"_EmptyState"),title:h,subtitle:H,image:G})})}if(!c)return t.jsx(p.default,{appHeaderProps:v,children:t.jsx(i,{"data-testid":"".concat(l,"_EmptyState"),title:i.APP_MESSAGES.appComponentWasNotFound.title,image:i.IMAGES.AppLoadingError})});if(!f){var F=P&&t.jsx(o.ChooseAssetButton,{toggleAppSettingsDialog:x});if(E.rig&&!E.well)return t.jsx(p.default,{appHeaderProps:v,children:t.jsx(i,{"data-testid":"".concat(l,"_EmptyState"),title:n(E.rig.name),image:i.IMAGES.RigHasNoActiveWell,subtitle:F})});if("general"===(null==m?void 0:m.type)&&M===s.SEGMENTS.COMPLETION&&!E.fracFleet)return t.jsx(p.default,{appHeaderProps:v,children:t.jsx(i,{"data-testid":"".concat(l,"_EmptyState"),title:i.APP_MESSAGES.fracFleetWasNotFound.title,image:i.IMAGES.FracFleetHasNoActivePad,subtitle:F})});if("general"===(null==m?void 0:m.type)&&M===s.SEGMENTS.COMPLETION&&!(null===(u=E.fracFleet)||void 0===u?void 0:u.current_pad_id)&&!S.settings.padId)return t.jsx(p.default,{appHeaderProps:v,children:t.jsx(i,{"data-testid":"".concat(l,"_EmptyState"),image:i.IMAGES.FracFleetHasNoActivePad,subtitle:F,title:i.APP_MESSAGES.fracFleetHasNoPad.title})});if("general"===(null==m?void 0:m.type)&&M===s.SEGMENTS.COMPLETION&&(!E.wells||E.wells.length<1))return t.jsx(p.default,{appHeaderProps:v,children:t.jsx(i,{"data-testid":"".concat(l,"_EmptyState"),image:i.IMAGES.NoWellsSelected,subtitle:F,title:i.APP_MESSAGES.padHasNoWells.title})});if(!(E.rig||E.well||E.settings||E.wells))return t.jsx(p.default,{appHeaderProps:v,children:t.jsx(i,{"data-testid":"".concat(l,"_EmptyState"),image:i.IMAGES.AssetHasNoData,subtitle:F,title:i.APP_MESSAGES.assetNotAvailable.title})})}return t.jsx(a,{appHeaderProps:v,openIntercom:b,children:t.jsx(c,e.__assign({app:S},S.settings,E,A))})}d.defaultProps={availability:{hasProductSubscription:!0,isAppSubscribedForAsset:!0}},exports.default=d,exports.getNoActiveWellMessage=n;
1
+ "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require('./../../../../../ext-esm/tslib/tslib.es6.js'),t=require("react/jsx-runtime"),a=require("../../../../ErrorBoundary/ErrorBoundary.js");require("../../../../ErrorBoundary/DevCenterAppErrorView/DevCenterAppErrorView.js");var r=require("../../../../LoadingIndicator/LoadingIndicator.js"),s=require("../../../../../constants/segment.js"),i=require("../../../../EmptyState/EmptyState.js"),p=require("./components/ChooseAssetButton.js"),o=require("../AppInfoMessage/AppInfoMessage.js"),l="DevCenterAppView",n=function(e){return"".concat(e," has no active well")};function d(d){var u=d.AppComponent,c=d.app,S=d.appData,A=d.appProps,E=d.availability,g=d.isCLIApp,P=d.isLoading,f=d.isMultiRig,j=d.layoutEnvironment,m=d.openIntercom,b=d.segment,x=d.toggleAppSettingsDialog,M=null==A?void 0:A.appHeaderProps;if(!c.package)return t.jsx(o.default,{appHeaderProps:M,children:t.jsx(i,{"data-testid":"".concat(l,"_EmptyState"),title:i.APP_MESSAGES.appPackageWasNotFound.title,subtitle:i.APP_MESSAGES.appPackageWasNotFound.subtitle,image:i.IMAGES.AppLoadingError})});if(P)return t.jsx(o.default,{appHeaderProps:M,children:t.jsx(r,{})});if(!E.hasProductSubscription||!E.isAppSubscribedForAsset){var _=i.APP_MESSAGES,v=_.appNotSubscribed,y=_.appNotSubscribedForAsset,N=i.IMAGES.NoSubscription,h=E.hasProductSubscription?y:v,G=h.title,H=h.subtitle;return t.jsx(o.default,{appHeaderProps:M,children:t.jsx(i,{"data-testid":"".concat(l,"_EmptyState"),title:G,subtitle:H,image:N})})}if(!u)return t.jsx(o.default,{appHeaderProps:M,children:t.jsx(i,{"data-testid":"".concat(l,"_EmptyState"),title:i.APP_MESSAGES.appComponentWasNotFound.title,image:i.IMAGES.AppLoadingError})});if(!f){var I=g&&t.jsx(p.ChooseAssetButton,{toggleAppSettingsDialog:x});if(S.rig&&!S.well)return t.jsx(o.default,{appHeaderProps:M,children:t.jsx(i,{"data-testid":"".concat(l,"_EmptyState"),title:n(S.rig.name),image:i.IMAGES.RigHasNoActiveWell,subtitle:I})});var F="general"===(null==j?void 0:j.type),q=b===s.SEGMENTS.COMPLETION;if(F&&q&&!S.fracFleet)return t.jsx(o.default,{appHeaderProps:M,children:t.jsx(i,{"data-testid":"".concat(l,"_EmptyState"),title:i.APP_MESSAGES.fracFleetWasNotFound.title,image:i.IMAGES.FracFleetHasNoActivePad,subtitle:I})});if(q&&S.fracFleet&&!S.fracFleet.current_pad_id&&!c.settings.padId)return t.jsx(o.default,{appHeaderProps:M,children:t.jsx(i,{"data-testid":"".concat(l,"_EmptyState"),image:i.IMAGES.FracFleetHasNoActivePad,subtitle:I,title:i.APP_MESSAGES.fracFleetHasNoPad.title})});if(q&&F&&(!S.wells||S.wells.length<1))return t.jsx(o.default,{appHeaderProps:M,children:t.jsx(i,{"data-testid":"".concat(l,"_EmptyState"),image:i.IMAGES.NoWellsSelected,subtitle:I,title:i.APP_MESSAGES.padHasNoWells.title})});if(!(S.rig||S.well||S.settings||S.wells))return t.jsx(o.default,{appHeaderProps:M,children:t.jsx(i,{"data-testid":"".concat(l,"_EmptyState"),image:i.IMAGES.AssetHasNoData,subtitle:I,title:i.APP_MESSAGES.assetNotAvailable.title})})}return t.jsx(a,{appHeaderProps:M,openIntercom:m,children:t.jsx(u,e.__assign({app:c},c.settings,S,A))})}d.defaultProps={availability:{hasProductSubscription:!0,isAppSubscribedForAsset:!0}},exports.default=d,exports.getNoActiveWellMessage=n;
@@ -1 +1 @@
1
- {"version":3,"file":"DevCenterAppView.d.ts","sourceRoot":"","sources":["../../../../../../src/components/DevCenter/DevCenterAppContainer/components/DevCenterAppView/DevCenterAppView.tsx"],"names":[],"mappings":"AASA,eAAO,MAAM,sBAAsB,YAAa,MAAM,KAAG,MAAyC,CAAC;AAEnG,iBAAS,gBAAgB,CAAC,EACxB,YAAY,EACZ,GAAG,EACH,OAAO,EACP,QAAQ,EACR,YAAY,EACZ,QAAQ,EACR,SAAS,EACT,UAAU,EACV,iBAAiB,EACjB,YAAY,EACZ,OAAO,EACP,uBAAuB,GACxB;;;;;;;;;;;;;CAAA,eA6IA;kBA1JQ,gBAAgB;;;;;;;;AAmKzB,eAAe,gBAAgB,CAAC"}
1
+ {"version":3,"file":"DevCenterAppView.d.ts","sourceRoot":"","sources":["../../../../../../src/components/DevCenter/DevCenterAppContainer/components/DevCenterAppView/DevCenterAppView.tsx"],"names":[],"mappings":"AASA,eAAO,MAAM,sBAAsB,YAAa,MAAM,KAAG,MAAyC,CAAC;AAEnG,iBAAS,gBAAgB,CAAC,EACxB,YAAY,EACZ,GAAG,EACH,OAAO,EACP,QAAQ,EACR,YAAY,EACZ,QAAQ,EACR,SAAS,EACT,UAAU,EACV,iBAAiB,EACjB,YAAY,EACZ,OAAO,EACP,uBAAuB,GACxB;;;;;;;;;;;;;CAAA,eAyIA;kBAtJQ,gBAAgB;;;;;;;;AA+JzB,eAAe,gBAAgB,CAAC"}
@@ -1 +1 @@
1
- import{__assign as t}from'./../../../../../ext-esm/tslib/tslib.es6.js';import{jsx as e}from"react/jsx-runtime";import a from"../../../../ErrorBoundary/ErrorBoundary.js";import"../../../../ErrorBoundary/DevCenterAppErrorView/DevCenterAppErrorView.js";import r from"../../../../LoadingIndicator/LoadingIndicator.js";import{SEGMENTS as i}from"../../../../../constants/segment.js";import o from"../../../../EmptyState/EmptyState.js";import{ChooseAssetButton as p}from"./components/ChooseAssetButton.js";import s from"../AppInfoMessage/AppInfoMessage.js";var n="DevCenterAppView",l=function(t){return"".concat(t," has no active well")};function d(d){var c,u=d.AppComponent,S=d.app,m=d.appData,A=d.appProps,E=d.availability,g=d.isCLIApp,P=d.isLoading,f=d.isMultiRig,b=d.layoutEnvironment,M=d.openIntercom,v=d.segment,y=d.toggleAppSettingsDialog,I=null==A?void 0:A.appHeaderProps;if(!S.package)return e(s,{appHeaderProps:I,children:e(o,{"data-testid":"".concat(n,"_EmptyState"),title:o.APP_MESSAGES.appPackageWasNotFound.title,subtitle:o.APP_MESSAGES.appPackageWasNotFound.subtitle,image:o.IMAGES.AppLoadingError})});if(P)return e(s,{appHeaderProps:I,children:e(r,{})});if(!E.hasProductSubscription||!E.isAppSubscribedForAsset){var _=o.APP_MESSAGES,N=_.appNotSubscribed,H=_.appNotSubscribedForAsset,h=o.IMAGES.NoSubscription,G=E.hasProductSubscription?H:N,F=G.title,C=G.subtitle;return e(s,{appHeaderProps:I,children:e(o,{"data-testid":"".concat(n,"_EmptyState"),title:F,subtitle:C,image:h})})}if(!u)return e(s,{appHeaderProps:I,children:e(o,{"data-testid":"".concat(n,"_EmptyState"),title:o.APP_MESSAGES.appComponentWasNotFound.title,image:o.IMAGES.AppLoadingError})});if(!f){var j=g&&e(p,{toggleAppSettingsDialog:y});if(m.rig&&!m.well)return e(s,{appHeaderProps:I,children:e(o,{"data-testid":"".concat(n,"_EmptyState"),title:l(m.rig.name),image:o.IMAGES.RigHasNoActiveWell,subtitle:j})});if("general"===(null==b?void 0:b.type)&&v===i.COMPLETION&&!m.fracFleet)return e(s,{appHeaderProps:I,children:e(o,{"data-testid":"".concat(n,"_EmptyState"),title:o.APP_MESSAGES.fracFleetWasNotFound.title,image:o.IMAGES.FracFleetHasNoActivePad,subtitle:j})});if("general"===(null==b?void 0:b.type)&&v===i.COMPLETION&&!(null===(c=m.fracFleet)||void 0===c?void 0:c.current_pad_id)&&!S.settings.padId)return e(s,{appHeaderProps:I,children:e(o,{"data-testid":"".concat(n,"_EmptyState"),image:o.IMAGES.FracFleetHasNoActivePad,subtitle:j,title:o.APP_MESSAGES.fracFleetHasNoPad.title})});if("general"===(null==b?void 0:b.type)&&v===i.COMPLETION&&(!m.wells||m.wells.length<1))return e(s,{appHeaderProps:I,children:e(o,{"data-testid":"".concat(n,"_EmptyState"),image:o.IMAGES.NoWellsSelected,subtitle:j,title:o.APP_MESSAGES.padHasNoWells.title})});if(!(m.rig||m.well||m.settings||m.wells))return e(s,{appHeaderProps:I,children:e(o,{"data-testid":"".concat(n,"_EmptyState"),image:o.IMAGES.AssetHasNoData,subtitle:j,title:o.APP_MESSAGES.assetNotAvailable.title})})}return e(a,{appHeaderProps:I,openIntercom:M,children:e(u,t({app:S},S.settings,m,A))})}d.defaultProps={availability:{hasProductSubscription:!0,isAppSubscribedForAsset:!0}};export{d as default,l as getNoActiveWellMessage};
1
+ import{__assign as t}from'./../../../../../ext-esm/tslib/tslib.es6.js';import{jsx as e}from"react/jsx-runtime";import a from"../../../../ErrorBoundary/ErrorBoundary.js";import"../../../../ErrorBoundary/DevCenterAppErrorView/DevCenterAppErrorView.js";import r from"../../../../LoadingIndicator/LoadingIndicator.js";import{SEGMENTS as i}from"../../../../../constants/segment.js";import o from"../../../../EmptyState/EmptyState.js";import{ChooseAssetButton as p}from"./components/ChooseAssetButton.js";import s from"../AppInfoMessage/AppInfoMessage.js";var n="DevCenterAppView",l=function(t){return"".concat(t," has no active well")};function d(d){var c=d.AppComponent,S=d.app,u=d.appData,m=d.appProps,A=d.availability,E=d.isCLIApp,g=d.isLoading,P=d.isMultiRig,f=d.layoutEnvironment,b=d.openIntercom,M=d.segment,_=d.toggleAppSettingsDialog,v=null==m?void 0:m.appHeaderProps;if(!S.package)return e(s,{appHeaderProps:v,children:e(o,{"data-testid":"".concat(n,"_EmptyState"),title:o.APP_MESSAGES.appPackageWasNotFound.title,subtitle:o.APP_MESSAGES.appPackageWasNotFound.subtitle,image:o.IMAGES.AppLoadingError})});if(g)return e(s,{appHeaderProps:v,children:e(r,{})});if(!A.hasProductSubscription||!A.isAppSubscribedForAsset){var y=o.APP_MESSAGES,H=y.appNotSubscribed,I=y.appNotSubscribedForAsset,h=o.IMAGES.NoSubscription,F=A.hasProductSubscription?I:H,G=F.title,N=F.subtitle;return e(s,{appHeaderProps:v,children:e(o,{"data-testid":"".concat(n,"_EmptyState"),title:G,subtitle:N,image:h})})}if(!c)return e(s,{appHeaderProps:v,children:e(o,{"data-testid":"".concat(n,"_EmptyState"),title:o.APP_MESSAGES.appComponentWasNotFound.title,image:o.IMAGES.AppLoadingError})});if(!P){var j=E&&e(p,{toggleAppSettingsDialog:_});if(u.rig&&!u.well)return e(s,{appHeaderProps:v,children:e(o,{"data-testid":"".concat(n,"_EmptyState"),title:l(u.rig.name),image:o.IMAGES.RigHasNoActiveWell,subtitle:j})});var w="general"===(null==f?void 0:f.type),C=M===i.COMPLETION;if(w&&C&&!u.fracFleet)return e(s,{appHeaderProps:v,children:e(o,{"data-testid":"".concat(n,"_EmptyState"),title:o.APP_MESSAGES.fracFleetWasNotFound.title,image:o.IMAGES.FracFleetHasNoActivePad,subtitle:j})});if(C&&u.fracFleet&&!u.fracFleet.current_pad_id&&!S.settings.padId)return e(s,{appHeaderProps:v,children:e(o,{"data-testid":"".concat(n,"_EmptyState"),image:o.IMAGES.FracFleetHasNoActivePad,subtitle:j,title:o.APP_MESSAGES.fracFleetHasNoPad.title})});if(C&&w&&(!u.wells||u.wells.length<1))return e(s,{appHeaderProps:v,children:e(o,{"data-testid":"".concat(n,"_EmptyState"),image:o.IMAGES.NoWellsSelected,subtitle:j,title:o.APP_MESSAGES.padHasNoWells.title})});if(!(u.rig||u.well||u.settings||u.wells))return e(s,{appHeaderProps:v,children:e(o,{"data-testid":"".concat(n,"_EmptyState"),image:o.IMAGES.AssetHasNoData,subtitle:j,title:o.APP_MESSAGES.assetNotAvailable.title})})}return e(a,{appHeaderProps:v,openIntercom:b,children:e(c,t({app:S},S.settings,u,m))})}d.defaultProps={availability:{hasProductSubscription:!0,isAppSubscribedForAsset:!0}};export{d as default,l as getNoActiveWellMessage};
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@corva/ui",
3
- "version": "3.12.0-1",
3
+ "version": "3.12.0-2",
4
4
  "description": "Shared components/utils for Corva ui projects",
5
5
  "keywords": [
6
6
  "corva-ui"