@corva/dc-platform-shared 0.65.0 → 0.66.0
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/CLI/components/App/App.js +1 -1
- package/CLI/components/App/components/AppBar/AppBar.js +1 -1
- package/CLI/constants/index.js +1 -1
- package/CLI/context/auth.js +1 -1
- package/CLI/hocs/effects/useProvideAuth/api.js +1 -1
- package/CLI/hocs/effects/useProvideAuth/constants.js +1 -1
- package/CLI/hocs/effects/useProvideAuth/useProvideAuth.js +1 -1
- package/CLI/hocs/utils.js +1 -1
- package/CLI/hocs/withAppDataProviderHOC.js +1 -1
- package/CLI/hocs/withCLIAppSettingsHOC.js +1 -1
- package/CLI/hocs/withCorvaMagicHOC.js +1 -1
- package/CLI/hocs/withDevCenterRouterHOC.js +1 -1
- package/CLI/hocs/withGridLayoutHOC/withGridLayoutHOC.js +1 -1
- package/CLI/hocs/withPDFLayoutHOC.js +1 -1
- package/CLI/hocs/withReactRouterHOC.js +1 -1
- package/CLI/screens/LoginScreen/LoginScreen.js +1 -1
- package/CLI/screens/LoginScreen/components/Auth.js +1 -1
- package/CLI/screens/LoginScreen/components/AuthStep.js +1 -1
- package/CLI/screens/LoginScreen/components/EmailStep.js +1 -1
- package/CLI/screens/LoginScreen/components/SSOButton.js +1 -1
- package/CLI/screens/OAuthCallbackScreen/index.js +1 -1
- package/_virtual/{arrayWithHoles.js → toPrimitive.js} +1 -1
- package/_virtual/{nonIterableRest.js → toPropertyKey.js} +1 -1
- package/cjs/devcenter/webpack/DevServerEntryPoint.js +1 -1
- package/cjs/devcenter/webpack/DevServerIsolatedAppEntryPoint.js +1 -1
- package/cjs/devcenter/webpack/MapboxGlDevSetupEntryPoint.js +1 -1
- package/cjs/devcenter/webpack/constants.js +1 -1
- package/cjs/devcenter/webpack/createAdaptiveRoot.js +1 -0
- package/cjs/devcenter/webpack/plugins/checkCorvaUIVersion.js +1 -1
- package/cjs/devcenter/webpack/utils/middlewares.js +1 -1
- package/cjs/devcenter/webpack/utils/serializeDotEnv.js +1 -1
- package/cjs/devcenter/webpack/validators/dependencies.js +1 -1
- package/cjs/devcenter/webpack/validators/index.js +1 -1
- package/cjs/devcenter/webpack/webpack.config.common.js +1 -1
- package/cjs/devcenter/webpack/webpack.config.dev.js +1 -1
- package/cjs/devcenter/webpack/webpack.config.prod.js +1 -1
- package/clients/auth0/index.js +1 -1
- package/components/GridLockButton/index.js +1 -1
- package/components/Login/components/Chip.js +1 -1
- package/components/Login/components/EmailField.js +1 -1
- package/components/Login/components/Login.js +1 -1
- package/components/Login/components/OrDivider.js +1 -1
- package/components/Login/components/PasswordField.js +1 -1
- package/components/Login/components/StepContent.js +1 -1
- package/components/Login/components/StepFooter.js +1 -1
- package/components/Login/components/StepHeader.js +1 -1
- package/components/Login/components/VerificationStep.js +1 -1
- package/ext-cjs/@babel/runtime/helpers/defineProperty.js +1 -1
- package/ext-cjs/@babel/runtime/helpers/toPrimitive.js +1 -0
- package/ext-cjs/@babel/runtime/helpers/toPropertyKey.js +1 -0
- package/ext-esm/auth0-js/dist/auth0.min.esm.js +1 -1
- package/package.json +8 -8
- package/utils/devcenter.js +1 -1
- package/utils/recaptcha.js +1 -1
- package/_virtual/arrayLikeToArray.js +0 -1
- package/_virtual/arrayWithoutHoles.js +0 -1
- package/_virtual/iterableToArray.js +0 -1
- package/_virtual/iterableToArrayLimit.js +0 -1
- package/_virtual/nonIterableSpread.js +0 -1
- package/_virtual/regeneratorRuntime.js +0 -1
- package/_virtual/unsupportedIterableToArray.js +0 -1
- package/ext-cjs/@babel/runtime/helpers/arrayLikeToArray.js +0 -1
- package/ext-cjs/@babel/runtime/helpers/arrayWithHoles.js +0 -1
- package/ext-cjs/@babel/runtime/helpers/arrayWithoutHoles.js +0 -1
- package/ext-cjs/@babel/runtime/helpers/asyncToGenerator.js +0 -1
- package/ext-cjs/@babel/runtime/helpers/iterableToArray.js +0 -1
- package/ext-cjs/@babel/runtime/helpers/iterableToArrayLimit.js +0 -1
- package/ext-cjs/@babel/runtime/helpers/nonIterableRest.js +0 -1
- package/ext-cjs/@babel/runtime/helpers/nonIterableSpread.js +0 -1
- package/ext-cjs/@babel/runtime/helpers/regeneratorRuntime.js +0 -1
- package/ext-cjs/@babel/runtime/helpers/slicedToArray.js +0 -1
- package/ext-cjs/@babel/runtime/helpers/toConsumableArray.js +0 -1
- package/ext-cjs/@babel/runtime/helpers/unsupportedIterableToArray.js +0 -1
- package/ext-cjs/@babel/runtime/regenerator/index.js +0 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
import
|
|
1
|
+
import{useReducer as o,useEffect as t}from"react";import r from"classnames";import{MuiThemeProvider as e}from"@material-ui/core";import{MuiPickersUtilsProvider as m}from"@material-ui/pickers";import i from"@date-io/moment";import a from"moment";import{isPDFReportView as n}from"@corva/ui/utils/reports";import{LOCAL_STORAGE_APP_THEME_KEY as p}from"@corva/ui/constants/localStorageKeys";import{NotificationsContainer as s}from"@corva/ui/components";import{THEMES as c}from"@corva/ui/constants/theme";import{darkTheme as l,lightTheme as f}from"@corva/ui/config/theme";import{setThemeVariables as u}from"@corva/ui/utils/themeVariables";import{LOGIN_ROUTE_REG_EXP as d}from"../../constants/index.js";import h from"./components/AppBar/AppBar.js";import{AuthContext as v}from"../../context/auth.js";import A from"../../hocs/effects/useProvideAuth/useProvideAuth.js";import g from"./App.css.js";import{jsx as j,jsxs as x,Fragment as I}from"react/jsx-runtime";function K(K){var C;let{children:D,router:P}=K;const R=A(P),S=!d.test(P.location.pathname)&&!R.loading,[,b]=o((o=>o+1),0),B=null!==(C=localStorage.getItem(p))&&void 0!==C?C:c.DARK,N=!S||!n&&B===c.DARK;t((()=>u(N)),[N]);return j(v.Provider,{value:R,children:j(e,{theme:N?l:f,children:j(m,{libInstance:a,utils:i,children:x(I,{children:[!S&&D,S&&x("div",{className:g.app,children:[j(s,{}),j(h,{toggleTheme:()=>{localStorage.setItem(p,N?c.LIGHT:c.DARK),b()}}),j("div",{className:r(g.appContent,n&&g.pdfAppContent,!N&&g.lightAppContent),children:D})]})]})})})})}export{K as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import
|
|
1
|
+
import{useState as e}from"react";import o from"prop-types";import{makeStyles as t,useTheme as r,AppBar as a,Toolbar as l,FormControlLabel as i,Checkbox as n,Tooltip as c,IconButton as s,Typography as p,Menu as m,MenuItem as d}from"@material-ui/core";import h from"@material-ui/icons/AccountCircle";import u from"@corva/ui/components/SwitchControl";import{FEATURE_FLAG_APPS_ISOLATION as g}from"@corva/ui/clients/clientStorage";import{LOCAL_STORAGE_PDF_REPORT_VIEW_KEY as f}from"@corva/ui/constants/localStorageKeys";import{isPDFReportView as v}from"@corva/ui/utils/reports";import C from"../../../../assets/DevCenterLogo.js";import{useAuth as b}from"../../../../context/auth.js";import{jsxs as w,jsx as B}from"react/jsx-runtime";const k=t((e=>({grow:{flexGrow:1},flex:{display:"flex"},appBar:{backgroundColor:"rgb(30, 31, 31)"},iconButtonRoot:{borderRadius:"unset"},userProfileIcon:{marginLeft:4},headerControl:{marginRight:32},formControlLabel:{fontSize:14}})));function S(o){var t,S;let{toggleTheme:L}=o;const A=k(),{user:I,logout:N}=b(),x=r(),[T,_]=e(null),z=Boolean(T),R=()=>_(null),y="".concat(null==I||null===(t=I.first_name)||void 0===t?void 0:t[0]).concat(null==I||null===(S=I.last_name)||void 0===S?void 0:S[0]).toUpperCase();return w("div",{children:[B(a,{position:"static",className:A.appBar,children:w(l,{children:[B(C,{}),B("div",{className:A.grow}),B(i,{control:B(n,{checked:"false"!==localStorage.getItem(g),size:"small",onChange:e=>{localStorage.setItem(g,e.target.checked),window.location.reload()}}),label:"App Isolation",classes:{label:A.formControlLabel},className:A.headerControl}),B(i,{control:B(n,{"data-testid":"".concat("AppBar","_pdfReport"),checked:v,size:"small",onChange:e=>{localStorage.setItem(f,e.target.checked),window.location.reload()}}),label:"PDF report view",classes:{label:A.formControlLabel},className:A.headerControl}),!v&&B(c,{title:"Switch to light theme to tune your app for PDF reports",placement:"bottom",children:B("div",{children:B(u,{"data-testid":"".concat("AppBar","_themeSwitch"),className:A.headerControl,leftLabel:"Dark Theme",rightLabel:"Light Theme",onChange:L,checked:x.isLightTheme,size:"small",title:""})})}),B("div",{children:B(s,{edge:"end","aria-label":"account of current user","aria-controls":"app-bar-menu","aria-haspopup":"true",onClick:e=>_(e.currentTarget),color:"inherit",className:A.iconButtonRoot,children:w("div",{className:A.flex,children:[B(p,{"data-testid":"".concat("AppBar","_userInitials"),children:y}),B(h,{className:A.userProfileIcon})]})})})]})}),B(m,{"data-testid":"".concat("AppBar","_userDropdown"),anchorEl:T,id:"app-bar-menu",keepMounted:!0,anchorOrigin:{vertical:"top",horizontal:"right"},transformOrigin:{vertical:"top",horizontal:"right"},open:z,onClose:R,children:B(d,{"data-testid":"".concat("AppBar","_signOutMenuItem"),onClick:()=>{N(),R()},children:"Sign Out"})})]})}S.propTypes={toggleTheme:o.func.isRequired};export{S as default};
|
package/CLI/constants/index.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
const p=new RegExp("^/login.*$"),o="https://app.corva.ai/login/help";export{p as LOGIN_ROUTE_REG_EXP,o as NEED_HELP_EXTERNAL_LINK};
|
package/CLI/context/auth.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
import{createContext as
|
|
1
|
+
import{createContext as o,useContext as r}from"react";const t=o(null),c=()=>r(t);export{t as AuthContext,c as useAuth};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{post as
|
|
1
|
+
import{post as e}from"@corva/ui/clients/api/apiCore";const i=i=>e("/v1/user_token",i),o=i=>e("/v1/sessions/verification/request",i);export{i as getUserToken,o as requestVerification};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
const i={wrongEmailOrPassword:"Wrong user name or password",missingVerificationCode:'"Missing verification code',invalidVerificationCode:"Invalid verification code"};export{i as ERRORS};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import
|
|
1
|
+
import{useState as t,useRef as n,useEffect as o}from"react";import{get as i}from"lodash";import*as s from"@corva/ui/clients/jsonApi";import{updateUserUnits as r}from"@corva/ui/utils/convert";import a from"../../../../clients/auth0/index.js";import{LOGIN_ROUTE_REG_EXP as e}from"../../../constants/index.js";import{ERRORS as c}from"./constants.js";import{getUserToken as m}from"./api.js";const u=t=>fetch("/dotenv",{method:"PATCH",headers:{"Content-Type":"application/json"},body:JSON.stringify(t)});function l(l){const[p,d]=t(null),[f,y]=t(!0),[h,g]=t(null),v=n(null);async function C(){y(!0);const t=await s.getCurrentUser();t?(d(t),r({userUnits:t.unit_system,companyUnits:i(t,"company.unit_system"),companyCustomUnitSystem:i(t,"company.custom_unit_system"),userCustomUnitSystem:i(t,"custom_unit_system"),companyCustomUnits:i(t,"company.custom_units")})):l.push("/login"),y(!1)}v.current||(v.current=new a);return o((()=>{if(e.test(l.location.pathname))return y(!1);C()}),[l.location.pathname]),{user:p,loading:f,error:h,login:async function(){let t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",n=arguments.length>1?arguments[1]:void 0,o=arguments.length>2?arguments[2]:void 0;g(null),y(!0);const i={auth:n};t&&(i.platform=t);try{const t=await m(i);u({AUTH_TOKEN:t.jwt}),C().then(o)}catch(t){var s,r;null!==(s=t.isInvalidVerificationCode)&&void 0!==s&&s.call(t)?g(c.invalidVerificationCode):null!==(r=t.isMissingVerificationCode)&&void 0!==r&&r.call(t)?g(c.missingVerificationCode):g(c.wrongEmailOrPassword)}y(!1)},logout:async()=>{u({AUTH_TOKEN:""}),await s.logout(),l.push("/login")},auth0:v.current}}export{l as default};
|
package/CLI/hocs/utils.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
import
|
|
1
|
+
import t from"@babel/runtime/helpers/defineProperty";import{DEFAULT_APP_SIZE as e}from"@corva/ui/constants/apps";function r(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(t);e&&(o=o.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),r.push.apply(r,o)}return r}function o(e){for(var o=1;o<arguments.length;o++){var n=null!=arguments[o]?arguments[o]:{};o%2?r(Object(n),!0).forEach((function(r){t(e,r,n[r])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):r(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function n(t){return JSON.parse(localStorage.getItem(t))||{}}function i(t,e){const r=n(t)||{};localStorage.setItem(t,JSON.stringify(o(o({},r),e)))}const c=t=>{var r,i,c,l;const p=null!==(r=null==t||null===(i=t.application)||void 0===i||null===(c=i.ui)||void 0===c?void 0:c.initial_size)&&void 0!==r?r:e;return n(null==t||null===(l=t.application)||void 0===l?void 0:l.key).coordinates||o(o({},p),{},{x:0,y:0})};export{c as getAppCoordinates,n as getLocalAppData,i as updateLocalAppData};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import e from"@babel/runtime/helpers/defineProperty";import t from"@babel/runtime/helpers/objectWithoutProperties";import{DEV_CENTER_CLI_APP_ID as r}from"@corva/ui/constants";import{getFeatureFlagAppsIsolation as o}from"@corva/ui/clients/clientStorage";import{AppsDataProvider as n,DevCenterIsolatedApp as
|
|
1
|
+
import e from"@babel/runtime/helpers/defineProperty";import t from"@babel/runtime/helpers/objectWithoutProperties";import{DEV_CENTER_CLI_APP_ID as r}from"@corva/ui/constants";import{getFeatureFlagAppsIsolation as o}from"@corva/ui/clients/clientStorage";import{AppsDataProvider as n,DevCenterIsolatedApp as p}from"@corva/ui/components";import{jsx as s}from"react/jsx-runtime";const i=["manifest","dashboardProps","coordinates"];function a(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,o)}return r}function c(t){for(var r=1;r<arguments.length;r++){var o=null!=arguments[r]?arguments[r]:{};r%2?a(Object(o),!0).forEach((function(r){e(t,r,o[r])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(o)):a(Object(o)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(o,e))}))}return t}const m=o(),b=e=>{let{CLIAppComponent:o,CLIAppSettings:a,packageJson:b}=e;return e=>{let{manifest:f,dashboardProps:l,coordinates:u}=e,d=t(e,i);const O=f.application.key,{version:g}=b,y={app:{app_key:O,platform:"dev_center"},id:r,package:{manifest:f,build:"".concat(O,"-").concat(g),version:g},segment:f.application.segments,settings:d.settings};return s(n,{dashboardAssetId:l.assetId,apps:[y],children:s(p,c(c({},d),{},{isIsolationFeatureEnabled:m,app:y,coordinates:u,CLIAppComponent:o,CLIAppSettings:a}))})}};export{b as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import t from"@babel/runtime/helpers/defineProperty";import
|
|
1
|
+
import t from"@babel/runtime/helpers/defineProperty";import{useState as e}from"react";import{getLocalAppData as r,updateLocalAppData as n}from"./utils.js";import{useAuth as o}from"../context/auth.js";import{jsx as s}from"react/jsx-runtime";function i(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),r.push.apply(r,n)}return r}function c(e){for(var r=1;r<arguments.length;r++){var n=null!=arguments[r]?arguments[r]:{};r%2?i(Object(n),!0).forEach((function(r){t(e,r,n[r])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):i(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}const p=t=>i=>{const{user:p}=o(),f=i.manifest.application.key,[a,u]=e(r(f).settings||{});return s(t,c(c({},i),{},{currentUser:p,settings:a,onSettingChange:(t,e)=>{const r=c(c({},a||{}),{},{[t]:e});n(f,{settings:r}),u(r)},onSettingsChange:t=>{const e=c(c({},a||{}),t);n(f,{settings:e}),u(e)}}))};export{p as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import*as o from"@corva/ui";import{ProvidePermissions as r}from"@corva/ui/permissions";import"@corva/ui/styles/index.global.css.js";import"@corva/ui/styles/reactVirtualized.global.css.js";import"@corva/ui/styles/emojiMart.global.css.js";import"@corva/ui/styles/mapbox.global.css.js";import"@corva/ui/styles/lightbox.global.css.js";import"@corva/ui/styles/generatedThemesVariables.global.css.js";import"@corva/ui/styles/customScrollbars.global.css.js";import{initGlobalDependencies as t}from"@corva/ui/config/initGlobalDependencies";import{isPDFReportView as s}from"@corva/ui/utils/reports";import i from"./withAppDataProviderHOC.js";import
|
|
1
|
+
import*as o from"@corva/ui";import{ProvidePermissions as r}from"@corva/ui/permissions";import"@corva/ui/styles/index.global.css.js";import"@corva/ui/styles/reactVirtualized.global.css.js";import"@corva/ui/styles/emojiMart.global.css.js";import"@corva/ui/styles/mapbox.global.css.js";import"@corva/ui/styles/lightbox.global.css.js";import"@corva/ui/styles/generatedThemesVariables.global.css.js";import"@corva/ui/styles/customScrollbars.global.css.js";import{initGlobalDependencies as t}from"@corva/ui/config/initGlobalDependencies";import{isPDFReportView as s}from"@corva/ui/utils/reports";import i from"./withAppDataProviderHOC.js";import e from"./withCLIAppSettingsHOC.js";import a from"./withReactRouterHOC.js";import m from"./withGridLayoutHOC/withGridLayoutHOC.js";import p from"./withPDFLayoutHOC.js";import{withDevCenterRouterHOC as c}from"./withDevCenterRouterHOC.js";import{jsx as l}from"react/jsx-runtime";window["@corva/ui"]=o,t();const n=o=>{let{component:t,settings:n,manifest:u,packageJson:f}=o;return()=>{const o=e(i({CLIAppComponent:t,CLIAppSettings:n,packageJson:f})),g=s?p(o):m(o),j=a(c(g));return l(r,{children:l(j,{manifest:u,dashboardProps:{}})})}};export{n as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import
|
|
1
|
+
import e from"@babel/runtime/helpers/defineProperty";import r from"@babel/runtime/helpers/objectWithoutProperties";import{useMemo as t}from"react";import{createDevCenterRouter as o}from"../../utils/devcenter.js";import"../../utils/recaptcha.js";import{jsx as n}from"react/jsx-runtime";const c=["router"];function i(e,r){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);r&&(o=o.filter((function(r){return Object.getOwnPropertyDescriptor(e,r).enumerable}))),t.push.apply(t,o)}return t}function p(r){for(var t=1;t<arguments.length;t++){var o=null!=arguments[t]?arguments[t]:{};t%2?i(Object(o),!0).forEach((function(t){e(r,t,o[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(r,Object.getOwnPropertyDescriptors(o)):i(Object(o)).forEach((function(e){Object.defineProperty(r,e,Object.getOwnPropertyDescriptor(o,e))}))}return r}const s=e=>i=>{let{router:s}=i,u=r(i,c);const b=t((()=>o(s)),[s.location]);return n(e,p(p({},u),{},{devCenterRouter:b}))};export{s as default,s as withDevCenterRouterHOC};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import o from"@babel/runtime/helpers/defineProperty";import e from"@babel/runtime/helpers/
|
|
1
|
+
import o from"@babel/runtime/helpers/defineProperty";import e from"@babel/runtime/helpers/objectWithoutProperties";import{useState as t}from"react";import{WidthProvider as r,Responsive as i}from"react-grid-layout";import{pick as n,cloneDeep as s}from"lodash";import{withSize as p}from"react-sizeme";import{isPhoneDetected as a,isNativeDetected as m,isMobileDetected as c}from"@corva/ui/utils/mobileDetect";import{getAppSize as l}from"@corva/ui/utils/apps";import{GRID_BREAKPOINTS as d,GRID_COLUMN_SIZES as g,GRID_ROW_HEIGHT as u,NON_DRAGGABLE_ELEMENT_SELECTOR as f}from"@corva/ui/constants/apps";import"../../../components/Login/components/Chip.js";import"../../../components/Login/components/EmailField.js";import"../../../components/Login/components/HiddenEmailField.js";import"../../../components/Login/components/Login.js";import"../../../components/Login/components/OrDivider.js";import"../../../components/Login/components/PasswordField.js";import"../../../components/Login/components/Step.js";import"../../../components/Login/components/StepContent.js";import"../../../components/Login/components/StepFooter.js";import"../../../components/Login/components/StepHeader.js";import"../../../components/Login/components/VerificationStep.js";import{AppsGridDragHandle as b}from"../../../components/AppsGridDragHandle/AppsGridDragHandle.js";import j from"../../../components/GridLockButton/index.js";import{isAppMaximized as h}from"../../../utils/devcenter.js";import"../../../utils/recaptcha.js";import{getLocalAppData as y,getAppCoordinates as O,updateLocalAppData as L}from"../utils.js";import"./withGridLayoutHOC.global.css.js";import D from"./withGridLayoutHOC.css.js";import{jsxs as v,jsx as w}from"react/jsx-runtime";const S=["size"];function P(o,e){var t=Object.keys(o);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(o);e&&(r=r.filter((function(e){return Object.getOwnPropertyDescriptor(o,e).enumerable}))),t.push.apply(t,r)}return t}function H(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?P(Object(r),!0).forEach((function(t){o(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):P(Object(r)).forEach((function(o){Object.defineProperty(e,o,Object.getOwnPropertyDescriptor(r,o))}))}return e}const x=".".concat(b.GRID_LAYOUT_DRAG_HANDLE_CLASS),C=r(i),z=o=>p()((r=>{var i;let{size:p}=r,P=e(r,S);const z=p.width,A=P.manifest.application.key,[G,R]=t(null!==(i=y(A).isDraggable)&&void 0!==i&&i),E=m||c,k=h(P.devCenterRouter.location.query),[F,M]=t(O(P.manifest)),{pixelHeight:W,pixelWidth:_}=l({coordinates:F,dashboardWidth:z,isMaximized:k}),N=o=>{let[e]=o;const t=n(e,["x","y","w","h"]);M(t),L(A,{coordinates:t})},[B,T]=t({});return v("div",{children:[w(C,{breakpoints:a?d.phone:d.general,cols:g,rowHeight:u,measureBeforeMount:!0,onResizeStop:N,onDragStop:N,isDraggable:!E&&G,isResizable:!E&&G,draggableCancel:f,useCSSTransforms:!1,draggableHandle:x,onLayoutChange:(o,e)=>{o===e.small?T(e):T(H(H({},B),{},{medium:s(o),large:s(o)}))},layouts:B,children:w("div",{"data-grid":F,children:v("div",{className:k?D.appMaximized:"",children:[w(o,H(H({},P),{},{coordinates:H(H({},F),{},{pixelHeight:W,pixelWidth:_}),layoutEnvironment:{type:"general",pdfReportMode:!1}})),!E&&G&&w(b,{})]})},"with-grid-layout-hoc")}),w(j,{isDraggableAndResizable:G,onClick:()=>{R(!G),L(A,{isDraggable:!G})},pageName:"DashboardPo"})]})}));export{z as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import e from"@babel/runtime/helpers/defineProperty";import{makeStyles as r}from"@material-ui/core";import{getAppType as t,getPDFAppPixelSize as o}from"@corva/ui/utils/dashboardReports";import{getAppCoordinates as i}from"./utils.js";import{jsx as n}from"react/jsx-runtime";function p(e,r){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);r&&(o=o.filter((function(r){return Object.getOwnPropertyDescriptor(e,r).enumerable}))),t.push.apply(t,o)}return t}function c(r){for(var t=1;t<arguments.length;t++){var o=null!=arguments[t]?arguments[t]:{};t%2?p(Object(o),!0).forEach((function(t){e(r,t,o[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(r,Object.getOwnPropertyDescriptors(o)):p(Object(o)).forEach((function(e){Object.defineProperty(r,e,Object.getOwnPropertyDescriptor(o,e))}))}return r}
|
|
1
|
+
import e from"@babel/runtime/helpers/defineProperty";import{makeStyles as r}from"@material-ui/core";import{getAppType as t,getPDFAppPixelSize as o}from"@corva/ui/utils/dashboardReports";import{getAppCoordinates as i}from"./utils.js";import{jsx as n}from"react/jsx-runtime";function p(e,r){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);r&&(o=o.filter((function(r){return Object.getOwnPropertyDescriptor(e,r).enumerable}))),t.push.apply(t,o)}return t}function c(r){for(var t=1;t<arguments.length;t++){var o=null!=arguments[t]?arguments[t]:{};t%2?p(Object(o),!0).forEach((function(t){e(r,t,o[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(r,Object.getOwnPropertyDescriptors(o)):p(Object(o)).forEach((function(e){Object.defineProperty(r,e,Object.getOwnPropertyDescriptor(o,e))}))}return r}const a=r({page:{backgroundColor:"#fff",width:"21cm",height:"29.7cm",margin:"auto",overflow:"hidden",position:"relative",pageBreakAfter:"always",boxShadow:"#ccc 0px 1px 3px 0px, #ccc 0px 0px 0px 1px",paddingTop:2},pdfReportApp:{display:"inline-block",overflow:"hidden",position:"relative",zoom:"0.5",margin:"0 0.1cm",pointerEvents:"none"}}),l=e=>r=>{var p;const l=a(),s=i(r.manifest),f=!(null===(p=r.manifest.application.ui)||void 0===p||!p.full_screen_report),d=t({coordinates:s,isFullScreenReport:f});return n("div",{className:l.page,children:n("div",{className:l.pdfReportApp,style:{width:"".concat(d.width,"cm"),height:"".concat(d.height,"cm")},children:n(e,c(c({},r),{},{coordinates:c(c({},s),o(d)),layoutEnvironment:{type:"general",pdfReportMode:!0}}))})})};export{l as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import r from"@babel/runtime/helpers/defineProperty";import{useMemo as e}from"react";import{BrowserRouter as t,useHistory as o,useLocation as n,Switch as c,Redirect as p,Route as a}from"react-router-dom";import{LoadingIndicator as i}from"@corva/ui/components";import
|
|
1
|
+
import r from"@babel/runtime/helpers/defineProperty";import{useMemo as e}from"react";import{BrowserRouter as t,useHistory as o,useLocation as n,Switch as c,Redirect as p,Route as a}from"react-router-dom";import{LoadingIndicator as i}from"@corva/ui/components";import s from"../screens/LoginScreen/LoginScreen.js";import u from"../screens/OAuthCallbackScreen/index.js";import{useAuth as m}from"../context/auth.js";import l from"../components/App/App.js";import{jsx as f,jsxs as h}from"react/jsx-runtime";function b(r,e){var t=Object.keys(r);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(r);e&&(o=o.filter((function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),t.push.apply(t,o)}return t}function O(e){for(var t=1;t<arguments.length;t++){var o=null!=arguments[t]?arguments[t]:{};t%2?b(Object(o),!0).forEach((function(t){r(e,t,o[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(o)):b(Object(o)).forEach((function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(o,r))}))}return e}function d(r){const e=new URLSearchParams(r),t={};return e.forEach(((r,e)=>{t[e]=r})),t}function j(r){let{WrappedComponent:e,componentProps:t,router:o,location:n}=r;const{loading:c}=m();return c?f(i,{fullscreen:!0}):f(e,O({location:n,router:o},t))}function y(r){let{WrappedComponent:t,componentProps:i}=r;const m=o(),b=n(),y=e((()=>function(r,e){const t=r=>{if("string"==typeof r)return r;const{pathname:e,query:t}=r;return{pathname:e,search:t?"?".concat(new URLSearchParams(t).toString()):""}};return{push:e=>r.push(t(e)),replace:e=>r.replace(t(e)),location:O(O({},e),{},{query:d(e.search)})}}(m,b)),[m,b]);return f(l,{router:y,children:h(c,{children:[f(p,{exact:!0,from:"/",to:"/app"}),f(a,{path:"/login/oauth-callback",children:f(u,{router:y})}),f(a,{path:"/login",children:f(s,{router:y,location:y.location})}),f(a,{path:"/app",children:f(j,{WrappedComponent:t,componentProps:i,router:y,location:y.location})})]})})}const P=r=>e=>f(t,{children:f(y,{WrappedComponent:r,componentProps:e})});export{P as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import
|
|
1
|
+
import{useEffect as o}from"react";import{getCurrentUser as n}from"@corva/ui/clients/jsonApi";import"../../../components/Login/components/Chip.js";import"../../../components/Login/components/EmailField.js";import"../../../components/Login/components/HiddenEmailField.js";import t from"../../../components/Login/components/Login.js";import"../../../components/Login/components/OrDivider.js";import"../../../components/Login/components/PasswordField.js";import"../../../components/Login/components/Step.js";import"../../../components/Login/components/StepContent.js";import"../../../components/Login/components/StepFooter.js";import"../../../components/Login/components/StepHeader.js";import"../../../components/Login/components/VerificationStep.js";import e from"./components/Auth.js";import i from"./components/IconLogo.js";import m from"./LoginScreen.css.js";import{jsx as p}from"react/jsx-runtime";function s(s){let{router:r,location:c}=s;return o((()=>{!async function(){let o=null;try{o=await n()}catch(o){console.error(o)}o&&r.replace("/")}()}),[]),p("div",{className:m.loginScreen,children:p(t,{location:c,logoIcon:p(i,{}),promoLink:"https://youtu.be/-q6LkceqpGs",children:p(e,{router:r})})})}export{s as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import
|
|
1
|
+
import{useState as e}from"react";import t from"./EmailStep.js";import s from"./AuthStep.js";import{jsx as i}from"react/jsx-runtime";function m(m){let{router:a}=m;const[o,r]=e({email:null,schemas:{},step:0});return 0===o.step?i(t,{onNext:(e,t)=>r((s=>({step:s.step+1,email:e,schemas:t})))}):i(s,{email:o.email,schemas:o.schemas.schemas,identityVerification:o.schemas.identity_verification,onBack:()=>r((e=>({step:e.step-1,email:null,schemas:null}))),onFinishLogin:()=>a.push("/")})}export{m as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import
|
|
1
|
+
import{memo as o,useState as n,useRef as e,useEffect as i}from"react";import{styled as t,Grid as r,Button as c}from"@material-ui/core";import{showErrorNotification as a}from"@corva/ui/utils";import{isSSOPlatformSupported as m}from"@corva/ui/clients/sso";import{initializeRecaptcha as s,GOOGLE_RECAPTCHA_KEY as p}from"../../../../utils/recaptcha.js";import l from"../../../../components/Login/components/Chip.js";import"../../../../components/Login/components/EmailField.js";import d from"../../../../components/Login/components/HiddenEmailField.js";import"../../../../components/Login/components/Login.js";import f from"../../../../components/Login/components/OrDivider.js";import u from"../../../../components/Login/components/PasswordField.js";import g from"../../../../components/Login/components/Step.js";import h from"../../../../components/Login/components/StepContent.js";import v from"../../../../components/Login/components/StepFooter.js";import j from"../../../../components/Login/components/StepHeader.js";import{VerificationStep as w}from"../../../../components/Login/components/VerificationStep.js";import{useAuth as L}from"../../../context/auth.js";import{NEED_HELP_EXTERNAL_LINK as S}from"../../../constants/index.js";import{ERRORS as C}from"../../../hocs/effects/useProvideAuth/constants.js";import{requestVerification as b}from"../../../hocs/effects/useProvideAuth/api.js";import y from"./SSOButton.js";import{jsx as k,jsxs as B}from"react/jsx-runtime";const P=t(r)((o=>{let{theme:n}=o;return{marginTop:2*n.spacing(1),marginBottom:2*n.spacing(1),"&:first-of-type":{marginTop:0},"&:last-of-type":{marginBottom:0}}})),_=t(c)((o=>{let{theme:n}=o;return{width:71,padding:n.spacing(),whiteSpace:"nowrap",backgroundColor:n.status.loginButton,"&:hover":{backgroundColor:"".concat(n.status.loginButtonHovered)}}}));var x=o((function(o){let{email:t,schemas:c,onBack:x,onFinishLogin:F,identityVerification:V}=o;const E=L(),[H,A]=n(""),[I,O]=n(!1),[T,z]=n({code:null,mode:null}),D=e(null),q=I&&E.error===C.wrongEmailOrPassword?E.error:null;i((()=>{s()}),[]);const M=o=>{if(!o)return a("Problem with initializing recaptcha");D.current=o;const n={email:t,password:H,recaptcha_token:o};T.code&&(n.verification_code=T.code,n.verification_mode=T.mode),E.login(null,n,F).then((()=>O(!0)))},G=async o=>{if(o.preventDefault(),!window.grecaptcha)return M();let n=!1;return window.grecaptcha.enterprise.ready((()=>{n=!0;try{window.grecaptcha.enterprise.execute(p,{action:"login"}).then(M).catch(console.error)}catch(o){console.error(o),a(o.message)}})),setTimeout((()=>{n||M()}),1e3)};i((()=>{if(!T.code)return;const o={email:t,password:H,recaptcha_token:D.current};T.code&&(o.verification_code=T.code,o.verification_mode=T.mode),E.login(null,o,F)}),[T.code]);const J=c.find((o=>"password"===o.provider)),K=c.filter((o=>{var n;return"password"!==o.provider&&m(null==o||null===(n=o.platform)||void 0===n?void 0:n.identifier)}));return I&&null!=V&&V.enabled&&!q?k(w,{email:t,identityVerification:V,loginVerificationFailure:E.error===C.invalidVerificationCode,onCodeProvided:z,password:H,requestVerification:b}):B(g,{children:[k(j,{children:"Sign In"}),k(h,{children:B(r,{container:!0,direction:"column",children:[k(l,{"data-not-migrated-MuiChip":!0,label:t,onClick:x}),K.map((o=>k(P,{item:!0,children:k(y,{title:o.title,provider:o.provider,connection:o.connection,platform:o.platform})},o.title))),J&&K.length>0&&k(r,{item:!0,children:k(f,{})}),J&&k(P,{item:!0,children:B("form",{id:"sign-in-form",onSubmit:G,children:[k(d,{email:t}),k(u,{value:H,onChange:o=>{A(o.target.value),O(!1)},disabled:E.loading,error:q})]})})]})}),k(v,{needHelpExternalLink:S,children:J&&k(_,{"data-testid":"".concat("AuthorizationPo","_signInButton"),form:"sign-in-form",type:"submit",variant:"contained",color:"primary",disabled:!H||E.loading||!!q,onClick:G,children:"Sign In"})})]})}));export{x as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import
|
|
1
|
+
import{memo as o,useState as n}from"react";import{styled as t}from"@material-ui/core/styles";import e from"@material-ui/core/Button";import{getUserAuthSchemas as i}from"@corva/ui/clients/jsonApi";import"../../../../components/Login/components/Chip.js";import r from"../../../../components/Login/components/EmailField.js";import"../../../../components/Login/components/HiddenEmailField.js";import"../../../../components/Login/components/Login.js";import"../../../../components/Login/components/OrDivider.js";import"../../../../components/Login/components/PasswordField.js";import m from"../../../../components/Login/components/Step.js";import p from"../../../../components/Login/components/StepContent.js";import s from"../../../../components/Login/components/StepFooter.js";import c from"../../../../components/Login/components/StepHeader.js";import"../../../../components/Login/components/VerificationStep.js";import{NEED_HELP_EXTERNAL_LINK as a}from"../../../constants/index.js";import{jsxs as l,jsx as d}from"react/jsx-runtime";const u=t(e)((o=>{let{theme:n}=o;return{width:71,padding:n.spacing(),backgroundColor:n.status.loginButton,"&:hover":{backgroundColor:"".concat(n.status.loginButtonHovered)}}}));var f=o((function(o){let{onNext:t}=o;const[e,f]=n(!1),[g,h]=n(null),[j,L]=n(""),v=o=>{if(o.preventDefault(),!j)return h("Required");f(!0),i({email:j,with_provider:!0}).then((o=>t(j,o))).catch((()=>h("Invalid email"))).finally((()=>f(!1)))};return l(m,{children:[d(c,{children:"Sign In"}),d(p,{children:d("form",{id:"email-form",onSubmit:v,autoComplete:"on",children:d(r,{value:j,onChange:o=>{L(o.target.value),h(null)},disabled:!!e,error:g})})}),d(s,{needHelpExternalLink:a,children:d(u,{"data-testid":"EmailPo_nextButton",form:"email-form",type:"submit",variant:"contained",color:"primary",disabled:e||!!g,onClick:v,children:"Next"})})]})}));export{f as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import
|
|
1
|
+
import{useState as t}from"react";import{withStyles as e,ButtonBase as o,Grid as r,Avatar as i,Typography as a,CircularProgress as n}from"@material-ui/core";import{getSSOProvider as s}from"@corva/ui/clients/sso";import{jsx as l,jsxs as c}from"react/jsx-runtime";const d={google:"/static/media/55de612562c712e3a9d6ea86000e18c7.svg",microsoft:"/static/media/319d9b9a39d511547cf55d1336a8eca4.svg"};var f=e((t=>({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:t.status.loginButton}},logo:{height:30,width:30,margin:12},avatar:{height:30,width:30,margin:12,color:"#ffffff",backgroundColor:t.status.loginButton},progressRoot:{margin:"12px 24px"},progressColor:{color:t.status.loginButton}})))((function(e){let{platform:f,connection:m,title:g,provider:h,classes:p}=e;const[u,b]=t(!1),v=d[h];return l(o,{className:p.button,onClick:t=>{if(t.preventDefault(),!u){b(!0),localStorage.setItem("ssoPlatform",f.identifier);const t=s(f.identifier);t.configure(f.options),t.authorize(m)}},children:c(r,{container:!0,justify:"space-between",alignItems:"center",children:[l(r,{item:!0,children:c(r,{container:!0,justify:"flex-start",alignItems:"center",children:[l(r,{item:!0,children:v?l("img",{className:p.logo,src:v,alt:g}):l(i,{className:p.avatar,children:g&&g[0].toUpperCase()})}),l(r,{item:!0,children:l(a,{variant:"body2",children:g})})]})}),l(r,{item:!0,children:u&&l(n,{classes:{root:p.progressRoot,colorPrimary:p.progressColor},color:"primary",size:30})})]})})}));export{f as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import
|
|
1
|
+
import{useEffect as o}from"react";import{LoadingIndicator as t}from"@corva/ui/components";import{showErrorNotification as r}from"@corva/ui/utils";import{getUserAuthPlatform as e}from"@corva/ui/clients/jsonApi";import{getSSOProvider as i}from"@corva/ui/clients/sso";import{useAuth as n}from"../../context/auth.js";import{jsx as a}from"react/jsx-runtime";function c(c){let{router:s}=c;const{login:u}=n(),m=o=>{console.error(o),r("Sorry, but we couldn’t log you in. Please contact Corva support if you need assistance"),s.push("/login")},f=async()=>{const o=localStorage.getItem("ssoPlatform");localStorage.removeItem("ssoPlatform");const{platform:t}=await e(o),r=i(t.identifier);if(!r)return m("No authentication platform found for ".concat(t.identifier));try{r.configure(t.options);const o=await r.authenticate();return((o,t)=>{u(o,{token:t},(()=>s.push("/")))})(t.identifier,o)}catch(o){return m(o)}};return o((()=>{f()}),[]),a(t,{fullscreen:!1})}export{c as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";var e=require('./../ext-cjs/@babel/runtime/helpers/
|
|
1
|
+
"use strict";var e=require('./../ext-cjs/@babel/runtime/helpers/toPrimitive.js');module.exports=e.toPrimitive_1;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";var e=require('./../ext-cjs/@babel/runtime/helpers/
|
|
1
|
+
"use strict";var e=require('./../ext-cjs/@babel/runtime/helpers/toPropertyKey.js');module.exports=e.toPropertyKey_1;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import
|
|
1
|
+
import t from"../../../CLI/hocs/withCorvaMagicHOC.js";import{createAdaptiveRoot as e}from"./createAdaptiveRoot.js";import{jsx as o}from"react/jsx-runtime";Promise.all([import("".concat(process.env.DEV_CENTER_APP_PATH,"/src/index.js")),import("".concat(process.env.DEV_CENTER_APP_PATH,"/manifest.json")),import("".concat(process.env.DEV_CENTER_APP_PATH,"/package.json"))]).then((n=>{let[s,r,c]=n;const a=t({component:s.default.component,settings:s.default.settings,manifest:r.default,packageJson:c.default});e(document.getElementById("root")).render(o(a,{}))}));
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import o from"
|
|
1
|
+
import o from"prop-types";import{makeStyles as t}from"@material-ui/core";import*as p from"@corva/ui";import{DevCenterIsolatedAppPage as n}from"@corva/ui/components";import{initGlobalDependencies as e}from"@corva/ui/config";import{createAdaptiveRoot as r}from"./createAdaptiveRoot.js";import{jsx as i}from"react/jsx-runtime";window["@corva/ui"]=p,e();const m=t((()=>({reportsContainer:{zoom:"0.5"}})));function s(o){let{CLIAppComponent:t,CLIAppSettings:p}=o;const e=m();return i(n,{CLIAppComponent:t,CLIAppSettings:p,containerReportClassName:e.reportsContainer})}s.propTypes={CLIAppComponent:o.func,CLIAppSettings:o.func},s.defaultProps={CLIAppComponent:null,CLIAppSettings:null},import("".concat(process.env.DEV_CENTER_APP_PATH,"/src/index.js")).then((o=>{const t=o.default.component,p=o.default.settings;r(document.getElementById("root")).render(i(s,{CLIAppComponent:t,CLIAppSettings:p}))}));
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import o from"mapbox-gl";try{
|
|
1
|
+
import o from"mapbox-gl";try{const i=window["@corva/ui"],n=i&&i.config&&i.config.initMapbox,c=i&&i.config&&i.config.MAP_BOX_ACCESS_TOKEN,a="function"==typeof n?n(o):o;a&&!a.accessToken&&c&&(a.accessToken=c),window["mapbox-gl"]=a}catch(o){console.warn("Failed to initialize mapbox-gl for local development:",o)}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e
|
|
1
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require('./../../../ext-cjs/@babel/runtime/helpers/defineProperty.js');function t(e,t){var a=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),a.push.apply(a,r)}return a}function a(a){for(var r=1;r<arguments.length;r++){var o=null!=arguments[r]?arguments[r]:{};r%2?t(Object(o),!0).forEach((function(t){e(a,t,o[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(a,Object.getOwnPropertyDescriptors(o)):t(Object(o)).forEach((function(e){Object.defineProperty(a,e,Object.getOwnPropertyDescriptor(o,e))}))}return a}const r={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"},i={[r.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"}),[r.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"}),[r.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"})};exports.CORVA_API_ENVS=r,exports.CORVA_API_ENV_VARIABLES=i,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.33",highcharts:["8.1.2","10.3.3"],"highcharts-react-official":"2.2.2",html2canvas:"1.0.0-alpha.12","@icon-park/react":"1.4.2",jsona:"1.5.1",lodash:["^4.17.21","^4.18.1"],"mapbox-gl":"3.16.0",moment:"2.29.4","moment-timezone":"0.5.43",react:["17.0.1","18.3.1"],"react-dom":["17.0.1","18.3.1"],"react-grid-layout":"1.3.4","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"},exports.DEPRECATED_DEPENDENCIES=[{dependency:"mapbox.js",message:'mapbox.js is deprecated and is no longer provided to Dev Center apps as a shared dependency. Use mapbox-gl 3.16.0 instead (provided by the platform as the window["mapbox-gl"] shared dependency). Remove mapbox.js from your package.json and migrate any L.mapbox usage to mapbox-gl.'}],exports.UNSUPPORTED_DEPENDENCIES=[{dependency:"date-fns",alternative:"moment"},{dependency:"date-fns-tz",alternative:"moment-timezone"},{dependency:"date-fns-timezone",alternative:"moment-timezone"}];
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import e from"react-dom";function o(o){return"function"==typeof e.createRoot?e.createRoot(o):(console.info("[dc-platform-shared] React 17 detected — mounting via legacy ReactDOM.render"),{render(t){e.render(t,o)},unmount(){e.unmountComponentAtNode(o)}})}export{o as createAdaptiveRoot};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";var e,r=require('./../../../../ext-cjs/@babel/runtime/helpers/taggedTemplateLiteral.js')
|
|
1
|
+
"use strict";var e,r=require('./../../../../ext-cjs/@babel/runtime/helpers/taggedTemplateLiteral.js');const o=require("node-fetch"),n=require("chalk"),t=require("semver/functions/gt"),a=require("path"),s=require("fs"),i=process.cwd(),u=JSON.parse(s.readFileSync(a.resolve(i,"./node_modules/@corva/ui/package.json"),"utf-8"));let c=null;module.exports=function(a){a.hooks.afterCompile.tapPromise("checkCorvaUIVersion",(async a=>{const s=a.getLogger("checkCorvaUIVersion"),i=u.version;c||(c=await function(e){return o("https://registry.npmjs.org/@corva/ui/latest").then((r=>r.ok?r.json().then((e=>e.version)):e.warn("Could not fetch latest @corva/ui version"))).catch((r=>e.warn("Connection error",r)))}(s)),c&&t(c,i)&&s.warn(n(e||(e=r(["\n ****************************************************************\n\n You are using outdated version of @corva/ui {grey (",")}.\n Current latest version is {green.bold (",")}.\n This may lead to problems once the app is published.\n Please update the @corva/ui with the following command:\n\n {green.bold yarn add @corva/ui@latest}\n\n ****************************************************************"])),i,c))}))};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require(
|
|
1
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("./serializeDotEnv.js");const r=require("fs").promises,t=require("path"),o=require("express");exports.onBeforeSetupMiddleware=function(s,i){let{APP_DIRECTORY:n}=i;s.use(o.json()),s.patch("/dotenv",(async function(o,s){let i="";try{i=await r.readFile(t.resolve(n,"./.env"),"utf8")}catch(e){}try{await r.writeFile(t.resolve(n,"./.env"),e.updateDotEnv(i,o.body))}catch(e){console.error("Could not write to .env file"),console.error(e)}s.sendStatus(200)}))};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});
|
|
1
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});const t=(t,e)=>"".concat(t,"=").concat((t=>{let e=t.replace(/\n/g,"\\n");return(e.includes(" ")||e.includes("\t"))&&(e='"'.concat(e.replace(/"/g,'\\"'),'"')),e})(e));exports.updateDotEnv=function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",n=arguments.length>1?arguments[1]:void 0;const c=n||{};return e.split("\n").map((e=>{if(!e.length||e.startsWith("#"))return e;const[n]=e.split("=");if(Object.keys(c).includes(n)){const e=c[n];return delete c[n],t(n,e)}return e})).concat(Object.entries(c).map((e=>{let[n,c]=e;return t(n,c)}))).join("\n")};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require(
|
|
1
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("../constants.js");exports.default=function(n){let{dependencies:t={}}=n;const s=[];return Object.entries(e.CORVA_GLOBAL_DEPENDENCIES).forEach((e=>{let[n,c]=e;if(c&&n in t){const e=t[n];Array.isArray(c)?c.includes(e)||s.push("".concat(n," version must be one of [").concat(c.join(", "),"]")):e!==c&&s.push("".concat(n," version must be ").concat(c))}})),e.UNSUPPORTED_DEPENDENCIES.forEach((e=>{let{dependency:n,alternative:c=""}=e;n in t&&s.push("".concat(n," is not supported.").concat(c?" Please use ".concat(c," instead."):""))})),s},exports.getDependenciesWarnings=function(n){let{dependencies:t={}}=n;const s=[];return e.DEPRECATED_DEPENDENCIES.forEach((e=>{let{dependency:n,message:c}=e;n in t&&s.push(c)})),s};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";var e=require("./dependencies.js")
|
|
1
|
+
"use strict";var e=require("./dependencies.js");const o=require("chalk");module.exports=function(n){let{packageJson:s}=n;const c=e.default(s);e.getDependenciesWarnings(s).forEach((e=>console.log(o.yellow(e)))),c.forEach((e=>console.log(o.red(e)))),c.length&&process.exit(1)};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("./validators/index.js")
|
|
1
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("./validators/index.js");const s=require("webpack"),o=require("path"),r=require("uuid/v1"),{CleanWebpackPlugin:t}=require("clean-webpack-plugin"),a=require("fs"),l=process.cwd(),n=JSON.parse(a.readFileSync(o.resolve(l,"./package.json"),"utf-8")),p=JSON.parse(a.readFileSync(o.resolve(l,"./manifest.json"),"utf-8"));exports.APP_DIRECTORY=l,exports.default=function(a,l){return e({packageJson:n}),{entry:"./src/index.js",output:{filename:"[name].[contenthash].js",path:o.resolve(process.cwd(),"dist")},devServer:{historyApiFallback:!0},performance:{maxAssetSize:1024e3},plugins:[new t,new s.ProvidePlugin({process:"process/browser"})],resolve:{symlinks:!1,extensions:[".js",".jsx",".json",".ts",".tsx"]},module:{rules:[{test:/\.(s[ac]|c)ss$/i,use:["style-loader",{loader:"css-loader",options:{modules:{localIdentName:"development"===l.mode?"[path][name]__[local]__[hash:base64:10]__".concat(r().substr(-5)):"[name]--[local]__[hash:base64:10]__".concat(r().substr(-5)),namedExport:!1},importLoaders:2}},{loader:"postcss-loader",options:{postcssOptions:{plugins:["postcss-preset-env"]}}},{loader:"sass-loader",options:{sourceMap:!0}}]},{test:/\.(js|jsx)$/,exclude:/[\\/]node_modules[\\/]/,use:{loader:"babel-loader",options:{presets:["@babel/preset-env",["@babel/preset-react",{runtime:"automatic"}]]}}},{test:/\.ts(x?)$/,exclude:/[\\/]node_modules[\\/]/,use:[{loader:"babel-loader",options:{presets:["@babel/preset-env",["@babel/preset-react",{runtime:"automatic"}]]}},{loader:"ts-loader",options:{compilerOptions:{noEmit:!1}}}]},{test:/\.m?js/,resolve:{fullySpecified:!1}}]}}},exports.manifestJson=p,exports.packageJson=n;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";var e=require('./../../../ext-cjs/@babel/runtime/helpers/defineProperty.js'),r=require(
|
|
1
|
+
"use strict";var e=require('./../../../ext-cjs/@babel/runtime/helpers/defineProperty.js'),r=require("./webpack.config.common.js"),t=require("./constants.js"),o=require("./plugins/checkCorvaUIVersion.js"),n=require("./utils/middlewares.js");function s(e,r){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);r&&(o=o.filter((function(r){return Object.getOwnPropertyDescriptor(e,r).enumerable}))),t.push.apply(t,o)}return t}function i(r){for(var t=1;t<arguments.length;t++){var o=null!=arguments[t]?arguments[t]:{};t%2?s(Object(o),!0).forEach((function(t){e(r,t,o[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(r,Object.getOwnPropertyDescriptors(o)):s(Object(o)).forEach((function(e){Object.defineProperty(r,e,Object.getOwnPropertyDescriptor(o,e))}))}return r}const c=require("@pmmmwh/react-refresh-webpack-plugin"),{merge:a}=require("webpack-merge"),p=require("path"),l=require("webpack"),{CleanWebpackPlugin:u}=require("clean-webpack-plugin"),d=require("copy-webpack-plugin"),m=require("html-webpack-plugin"),v=require("chalk");require("dotenv").config({path:p.resolve(r.APP_DIRECTORY,"./.env")});const _=()=>{const e=process.env.CORVA_API_ENV||t.CORVA_API_ENVS.production;return e in t.CORVA_API_ENVS?t.CORVA_API_ENV_VARIABLES[e]:(console.log(v.red("CORVA_API_ENV should be one of [".concat(Object.keys(t.CORVA_API_ENVS).join(", "),"]"))),process.exit(1))};function P(e,r,t){const o=p.join("@corva","dc-platform-shared"),n="@corva/ui",s=new RegExp("(^".concat(n,"$|^").concat(n,"/)([^]+)?"));if(!e.includes(o)){const e=s.exec(r);if(null!==e){return t(null,["window",n,...(e[2]||"").split("/").filter(Boolean)])}}return t()}const f=e=>p.dirname(require.resolve("".concat(e,"/package.json"),{paths:[r.APP_DIRECTORY]}));module.exports=function(e,t){const s=process.env.HOST||t.host||"app.local.corva.ai",v=process.env.PORT||t.port||8080,O="mapbox-gl"in(r.packageJson.dependencies||{})?[p.resolve(__dirname,"MapboxGlDevSetupEntryPoint.js")]:[];return a(r.default(e,t),{mode:"development",devtool:"inline-source-map",resolve:{alias:{react:f("react"),"react-dom":f("react-dom")}},devServer:{static:"./dist",host:s,port:v,onBeforeSetupMiddleware:e=>n.onBeforeSetupMiddleware(e.app,{APP_DIRECTORY:r.APP_DIRECTORY}),hot:!0,open:!1},entry:{devApp:[p.resolve(__dirname,"DevServerEntryPoint.js"),...O],isolatedApp:[p.resolve(__dirname,"DevServerIsolatedAppEntryPoint.js"),...O]},output:{filename:"[name].js"},plugins:[new u,new d({patterns:[{from:p.resolve(__dirname,"public")},{from:p.resolve(process.cwd(),"node_modules","@corva/ui/assets"),to:"static/media",noErrorOnMissing:!0},{from:p.resolve(process.cwd(),"node_modules","@corva/dc-platform-shared/assets"),to:"static/media",noErrorOnMissing:!0}]}),new m({filename:"index.html",inject:!1,template:p.resolve(__dirname,"public","index.html")}),new m({filename:"DevCenterIsolatedAppPage.html",inject:!1,template:p.resolve(__dirname,"public","DevCenterIsolatedAppPage.html")}),new l.EnvironmentPlugin(i(i({},process.env),{},{DEV_CENTER_APP_PATH:process.cwd(),REACT_APP_ENVIRONMENT:process.env.REACT_APP_ENVIRONMENT||"development"},_())),o,new c],externals:P,module:{rules:[{test:/\.(png|jpe?g|gif)$/i,type:"asset/resource"},{test:/\.svg$/,use:[{loader:"svg-url-loader",options:{limit:1e4}}]}]}})};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";var e=require(
|
|
1
|
+
"use strict";var e=require("./webpack.config.common.js"),r=require("./constants.js");const t=require("webpack"),{merge:n}=require("webpack-merge"),o=require("path"),s=require("terser-webpack-plugin"),i=require("copy-webpack-plugin"),{application:{key:a}}=e.manifestJson,{version:c}=e.packageJson,l=e=>{const r=a.replace(/\./g,"_");return e?r:"".concat(r,"-").concat(c)},u=Object.keys(r.CORVA_GLOBAL_DEPENDENCIES).map((e=>[e,new RegExp("(^".concat(e,"$|^").concat(e,"/)([^]+)?"))])),p=["react/jsx-runtime","highcharts/"];module.exports=function(r,a){const c=!(null==r||!r.local_debug);return n(e.default(r,a),{entry:"./src/index.js",output:{library:l(c),path:o.resolve(e.APP_DIRECTORY,"dist"),filename:"app.js",libraryTarget:"window"},mode:c?"development":"production",plugins:[new t.EnvironmentPlugin(process.env),new i({patterns:[{from:o.resolve(process.cwd(),"manifest.json"),to:"./",noErrorOnMissing:!0}]})],optimization:{minimizer:[new s({parallel:!0})]},externals:[function(e,r,t){if(r.endsWith(".css"))return t();for(let e=0;e<p.length;e+=1)if(r.startsWith(p[e]))return t();for(let e=0;e<u.length;e+=1){const[n,o]=u[e],s=o.exec(r);if(null!==s){return t(null,[n,...(s[2]||"").split("/").filter(Boolean)])}}return t()}],module:{rules:[{test:/\.(png|jpe?g|gif|woff|woff2|eot|ttf|otf)$/i,type:"asset/resource"},{test:/\.svg$/,use:[{loader:"svg-url-loader",options:{limit:1e4}}]}]}})};
|
package/clients/auth0/index.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
import e from"@babel/runtime/helpers/
|
|
1
|
+
import e from"@babel/runtime/helpers/defineProperty";import o from'./../../ext-esm/auth0-js/dist/auth0.min.esm.js';class t{constructor(){e(this,"handleAuthentication",((e,o)=>this.webAuth.parseHash(((t,i)=>{i&&i.accessToken?e(i):t&&o(t)})))),e(this,"loginWithConnection",(e=>this.webAuth.authorize({connection:e}))),this.webAuth=new o.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{t as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import
|
|
1
|
+
import e from"@babel/runtime/helpers/defineProperty";import{makeStyles as r,Tooltip as t,IconButton as o}from"@material-ui/core";import{UnlockIcon as c,LockIcon as a}from"@corva/ui/icons";import n from"classnames";import{jsx as i}from"react/jsx-runtime";function s(e,r){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);r&&(o=o.filter((function(r){return Object.getOwnPropertyDescriptor(e,r).enumerable}))),t.push.apply(t,o)}return t}function l(r){for(var t=1;t<arguments.length;t++){var o=null!=arguments[t]?arguments[t]:{};t%2?s(Object(o),!0).forEach((function(t){e(r,t,o[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(r,Object.getOwnPropertyDescriptors(o)):s(Object(o)).forEach((function(e){Object.defineProperty(r,e,Object.getOwnPropertyDescriptor(o,e))}))}return r}const b=r({root:{width:36,height:36,"&:hover":{backgroundColor:"rgba(255, 255, 255, 0.16)"},borderRadius:8},button:{width:"100%",height:"100%","&:hover":{backgroundColor:"rgba(255, 255, 255, 0.16)"}}});function d(e){let{className:r,disabled:s,isDraggableAndResizable:d,LockIcon:u=a,lockIconClassName:p,onClick:m,pageName:f,tooltipProps:h={}}=e;const g=b();return i(t,l(l({title:s?"Can't unlock dashboard layout":d?"Lock Dashboard Layout":"Unlock Dashboard Layout"},h),{},{children:i("div",{className:n(g.root,r),children:i(o,{className:g.button,"data-testid":"".concat(f,"_").concat(d?"gridUnlocked":"gridLocked"),disabled:s,onClick:m,children:d?i(c,{}):i(u,{className:p})})})}))}export{d as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import
|
|
1
|
+
import e from"prop-types";import{styled as t,withStyles as i,Grid as r,Chip as a}from"@material-ui/core";import o from"@material-ui/icons/ArrowBack";import{jsx as n}from"react/jsx-runtime";const l=t(o)((e=>{let{theme:t}=e;return{color:t.palette.primary.text6,fontSize:16}})),s=e=>{let{label:t,onClick:i,classes:o,dataTestid:s}=e;return n(r,{item:!0,className:o.chip,children:n(a,{label:t,className:o.chipContent,icon:n(l,{}),variant:"outlined",onClick:i,"data-testid":s})})};s.defaultProps={dataTestid:null},s.propTypes={label:e.string.isRequired,dataTestid:e.string,onClick:e.func.isRequired,classes:e.shape({}).isRequired};var p=i((e=>({chip:{marginTop:"-25px",marginBottom:20,textAlign:"center"},chipContent:{color:e.palette.primary.text6,fontSize:13,border:"none",background:"#2C2C2C",padding:"0 5px 0 10px"}})))(s);export{p as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import e from"prop-types";import{withStyles as l,TextField as i}from"@material-ui/core";import{jsx as o}from"react/jsx-runtime";
|
|
1
|
+
import e from"prop-types";import{withStyles as l,TextField as i}from"@material-ui/core";import{jsx as o}from"react/jsx-runtime";const a=e=>{let{value:l,onChange:a,disabled:t,error:r,classes:d}=e;return o(i,{"data-testid":"".concat("EmailField","_emailInput"),id:"email-input",label:"Email",type:"email",name:"email",autoComplete:"email",value:l,placeholder:"Enter your email address",variant:"outlined",InputLabelProps:{classes:{root:d.emailFieldLabelRoot,focused:d.emailFieldFocused}},InputProps:{classes:{root:d.emailFieldRoot,input:d.emailInput,disabled:d.emailFieldDisabled,focused:d.emailFieldFocused,error:d.emailFieldError}},onChange:a,disabled:t,error:!!r,helperText:r,fullWidth:!0})};a.defaultProps={disabled:!1,error:null},a.propTypes={value:e.string.isRequired,onChange:e.func.isRequired,disabled:e.bool,error:e.string,classes:e.shape({}).isRequired};var t=l((e=>({emailFieldRoot:{"&:hover:not($emailFieldDisabled):not($emailFieldFocused):not($emailFieldError) $emailFieldNotchedOutline":{borderColor:e.status.loginButton},"&$emailFieldFocused $emailFieldNotchedOutline":{borderColor:e.status.loginButton}},emailInput:{"&:-webkit-autofill":{WebkitBoxShadow:"0 0 0 100px #233 inset"}},emailFieldLabelRoot:{color:"#666","&$emailFieldFocused":{color:e.status.loginButton}}})))(a);export{t as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import o from"prop-types";import r from"classnames";import{styled as i,Tooltip as e}from"@material-ui/core";import{isMobileDetected as n,isTabletDetected as c}from"@corva/ui/utils/mobileDetect";import
|
|
1
|
+
import o from"prop-types";import r from"classnames";import{styled as i,Tooltip as e}from"@material-ui/core";import{isMobileDetected as n,isTabletDetected as c}from"@corva/ui/utils/mobileDetect";import l from"./LogoIcon.js";import"./Login.global.css.js";import{jsx as a,jsxs as t}from"react/jsx-runtime";const m=window.innerHeight<window.innerWidth,p=i(e)({maxWidth:300,margin:0}),g=o=>{let{children:i,location:e,logoIcon:l,logoTooltip:g,promoBackgroundImage:d,promoBackgroundWebM:s,promoBackgroundMp4:u,promoLink:h}=o;const b=s||u,k=t("a",{href:h,target:"_blank",rel:"noreferrer",className:r("c-login-promo",!b&&"c-login-promo__image"),style:{backgroundImage:!b&&"url(".concat(d,")")},children:["Promo",b&&t("video",{loop:!0,muted:!0,autoPlay:!0,playsinline:!0,className:"c-login-promo__video",children:[s&&a("source",{src:s,type:"video/webm"}),u&&a("source",{src:u,type:"video/mp4"})]})]});return t("div",{className:r("c-login",{"c-login-mobile":n||c,"c-login-large_content":"/login"!==e.path,"c-login-landscape":m}),children:[k,t("div",{className:"c-login-content",children:[a("div",{className:"c-login-logo",children:a(p,{title:g,placement:"bottom",children:a("div",{children:l})})}),i]})]})};g.propTypes={children:o.node,logoIcon:o.node,logoTooltip:o.string,promoLink:o.string,promoBackgroundImage:o.string,promoBackgroundWebM:o.string,promoBackgroundMp4:o.string},g.defaultProps={children:void 0,logoIcon:a(l,{}),logoTooltip:"",promoLink:"https://www.corva.ai/",promoBackgroundImage:"/static/media/67f05495a7dbbee777bb0c7974f4588a.jpg",promoBackgroundWebM:void 0,promoBackgroundMp4:void 0};export{g as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import e from"prop-types";import{withStyles as t}from"@material-ui/core/styles";import
|
|
1
|
+
import e from"prop-types";import{withStyles as t}from"@material-ui/core/styles";import i from"@material-ui/core/Divider";import r from"@material-ui/core/Grid";import s from"@material-ui/core/Typography";import{jsxs as a,jsx as m}from"react/jsx-runtime";function l(e){return a(r,{container:!0,justify:"space-between",alignItems:"center",wrap:"nowrap",children:[m(r,{item:!0,className:e.classes.dividerItem,children:m(i,{})}),m(r,{item:!0,className:e.classes.textItem,children:m(s,{variant:"subtitle1",className:e.classes.text,children:"OR"})}),m(r,{item:!0,className:e.classes.dividerItem,children:m(i,{})})]})}l.propTypes={classes:e.shape({dividerItem:e.string.isRequired,textItem:e.string.isRequired,text:e.string.isRequired}).isRequired};var c=t((e=>({dividerItem:{flex:10},textItem:{textAlign:"center",paddingLeft:24,paddingRight:24},text:{color:e.palette.primary.text6}})))(l);export{c as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import
|
|
1
|
+
import{useState as o}from"react";import{withStyles as e,TextField as s,InputAdornment as r}from"@material-ui/core";import i from"@material-ui/core/IconButton";import d from"@material-ui/icons/Visibility";import t from"@material-ui/icons/VisibilityOff";import{jsx as a}from"react/jsx-runtime";var l=e((o=>({passwordFieldRoot:{"&:hover:not($passwordFieldDisabled):not($passwordFieldFocused):not($passwordFieldError) $passwordFieldNotchedOutline":{borderColor:o.status.loginButton},"&$passwordFieldFocused $passwordFieldNotchedOutline":{borderColor:o.status.loginButton}},passwordFieldLabelRoot:{"&$passwordFieldFocused":{color:o.status.loginButton}},passwordField:{"&:-webkit-autofill":{WebkitBoxShadow:"0 0 0 100px #233 inset"}}})))((e=>{let{value:l,onChange:n,disabled:p,error:u,classes:c}=e;const[w,F]=o(!1);return a(s,{id:"password-input",label:"Password",type:w?"text":"password",name:"password",value:l,variant:"outlined",onChange:n,autoComplete:"password",disabled:p,error:!!u,helperText:u,InputProps:{endAdornment:a(r,{position:"end",children:a(i,{"aria-label":"Toggle password visibility",onClick:()=>F((o=>!o)),children:a(w?d:t,{})})}),classes:{root:c.passwordFieldRoot,input:c.passwordField,disabled:c.passwordFieldDisabled,focused:c.passwordFieldFocused,error:c.passwordFieldError,notchedOutline:c.passwordFieldNotchedOutline}},InputLabelProps:{classes:{root:c.passwordFieldLabelRoot,focused:c.passwordFieldFocused}},fullWidth:!0})}));export{l as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import r from"prop-types";import{withStyles as e}from"@material-ui/core/styles";import i from"@material-ui/core/Grid";import{jsx as
|
|
1
|
+
import r from"prop-types";import{withStyles as e}from"@material-ui/core/styles";import i from"@material-ui/core/Grid";import{jsx as s}from"react/jsx-runtime";function t(r){return s(i,{item:!0,className:r.classes.gridItem,children:r.children})}t.propTypes={children:r.node.isRequired,classes:r.shape({gridItem:r.string.isRequired}).isRequired};var m=e((r=>({gridItem:{padding:r.spacing(2,4,2,4),width:"100%"}})))(t);export{m as default};
|