@commercetools-frontend/application-shell 22.5.0 → 22.6.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/dist/{application-entry-point-98c4a247.cjs.prod.js → application-entry-point-2000359c.cjs.prod.js} +1 -1
- package/dist/{application-entry-point-b9ed252b.cjs.dev.js → application-entry-point-8c1b932a.cjs.dev.js} +1 -1
- package/dist/{application-entry-point-c3884344.esm.js → application-entry-point-afa36f4a.esm.js} +1 -1
- package/dist/commercetools-frontend-application-shell.cjs.dev.js +4 -4
- package/dist/commercetools-frontend-application-shell.cjs.prod.js +4 -4
- package/dist/commercetools-frontend-application-shell.esm.js +4 -4
- package/dist/{configure-apollo-5baefe27.esm.js → configure-apollo-010b521a.esm.js} +3 -2
- package/dist/{configure-apollo-4187db53.cjs.dev.js → configure-apollo-e0273cd1.cjs.dev.js} +3 -2
- package/dist/{configure-apollo-235efa51.cjs.prod.js → configure-apollo-f632e6cf.cjs.prod.js} +3 -2
- package/dist/{constants-55f41c8c.esm.js → constants-a09fbec1.esm.js} +1 -0
- package/dist/{constants-4408614d.cjs.prod.js → constants-a1140922.cjs.dev.js} +1 -0
- package/dist/{constants-5c1ecb73.cjs.dev.js → constants-ed10e935.cjs.prod.js} +1 -0
- package/dist/declarations/src/components/application-shell-authenticated/application-shell-authenticated.d.ts +4 -1
- package/dist/declarations/src/components/application-shell-authenticated/new-main-navigation-flag-wrapper.d.ts +4 -0
- package/dist/declarations/src/components/navbar/index.d.ts +1 -0
- package/dist/declarations/src/components/project-container/index.d.ts +1 -0
- package/dist/declarations/src/constants.d.ts +1 -0
- package/dist/declarations/src/feature-toggles.d.ts +4 -1
- package/dist/{index-53b461f0.cjs.prod.js → index-0bfb96a9.cjs.prod.js} +208 -204
- package/dist/{index-31dd568f.cjs.dev.js → index-419189bf.cjs.dev.js} +210 -221
- package/dist/{index-937934ba.esm.js → index-c24c3bbf.esm.js} +211 -222
- package/dist/{navbar-80df957b.cjs.dev.js → navbar-1e90d18c.cjs.dev.js} +5 -5
- package/dist/{navbar-a5c6bfcb.esm.js → navbar-27c12ed8.esm.js} +5 -5
- package/dist/{navbar-766fb0fd.cjs.prod.js → navbar-c548a201.cjs.prod.js} +5 -5
- package/dist/{oidc-3376ec84.cjs.dev.js → oidc-244125d3.cjs.dev.js} +1 -1
- package/dist/{oidc-3a2cf8b3.cjs.prod.js → oidc-a780f067.cjs.prod.js} +1 -1
- package/dist/{oidc-38887b2d.esm.js → oidc-c4e99cfc.esm.js} +1 -1
- package/dist/{oidc-callback-d408517e.esm.js → oidc-callback-518b3a62.esm.js} +4 -4
- package/dist/{oidc-callback-f46de3c1.cjs.dev.js → oidc-callback-54e4b551.cjs.dev.js} +4 -4
- package/dist/{oidc-callback-d31b1579.cjs.prod.js → oidc-callback-e0687f34.cjs.prod.js} +4 -4
- package/dist/{project-container-5c3c1313.cjs.prod.js → project-container-17d86e50.cjs.prod.js} +9 -9
- package/dist/{project-container-a905608b.esm.js → project-container-3243f800.esm.js} +9 -9
- package/dist/{project-container-b35d260e.cjs.dev.js → project-container-9c7806ef.cjs.dev.js} +9 -9
- package/dist/{project-expired-1a5269ad.cjs.prod.js → project-expired-443cd7e0.cjs.prod.js} +5 -5
- package/dist/{project-expired-b956df4c.cjs.dev.js → project-expired-6dab919c.cjs.dev.js} +5 -5
- package/dist/{project-expired-2569ae58.esm.js → project-expired-c3a6aa3c.esm.js} +5 -5
- package/dist/{project-not-found-0bc6b9f7.cjs.dev.js → project-not-found-1a5bad77.cjs.dev.js} +5 -5
- package/dist/{project-not-found-cf2cc554.cjs.prod.js → project-not-found-5fcc4b22.cjs.prod.js} +5 -5
- package/dist/{project-not-found-60750783.esm.js → project-not-found-c728c4c2.esm.js} +5 -5
- package/dist/{project-not-initialized-75f5537a.cjs.prod.js → project-not-initialized-316131ae.cjs.prod.js} +5 -5
- package/dist/{project-not-initialized-f2578daa.esm.js → project-not-initialized-86835aca.esm.js} +5 -5
- package/dist/{project-not-initialized-191aa18a.cjs.dev.js → project-not-initialized-c48f8d83.cjs.dev.js} +5 -5
- package/dist/{project-suspended-f66a1459.cjs.dev.js → project-suspended-271303c3.cjs.dev.js} +5 -5
- package/dist/{project-suspended-4c195259.cjs.prod.js → project-suspended-2d6404d2.cjs.prod.js} +5 -5
- package/dist/{project-suspended-873c47c2.esm.js → project-suspended-4db209e6.esm.js} +5 -5
- package/dist/{quick-access-34af5278.esm.js → quick-access-07b2fea2.esm.js} +4 -4
- package/dist/{quick-access-923ce592.cjs.dev.js → quick-access-097009ce.cjs.dev.js} +4 -4
- package/dist/{quick-access-567cd0e8.cjs.prod.js → quick-access-8e4e90a0.cjs.prod.js} +4 -4
- package/dist/{redirect-to-login-7d02dc5b.cjs.dev.js → redirect-to-login-531c3d52.cjs.dev.js} +3 -3
- package/dist/{redirect-to-login-5710f920.cjs.prod.js → redirect-to-login-7cb94c3e.cjs.prod.js} +3 -3
- package/dist/{redirect-to-login-07eb52a4.esm.js → redirect-to-login-d9dcccac.esm.js} +3 -3
- package/dist/{redirect-to-logout-e3b14844.cjs.dev.js → redirect-to-logout-2e314afc.cjs.dev.js} +4 -4
- package/dist/{redirect-to-logout-cc82cee3.cjs.prod.js → redirect-to-logout-54a2fc06.cjs.prod.js} +4 -4
- package/dist/{redirect-to-logout-bebe4068.esm.js → redirect-to-logout-c4173114.esm.js} +4 -4
- package/dist/{requests-in-flight-loader-f87c011b.esm.js → requests-in-flight-loader-0b09c194.esm.js} +4 -4
- package/dist/{requests-in-flight-loader-81315c1b.cjs.dev.js → requests-in-flight-loader-6ba8df53.cjs.dev.js} +4 -4
- package/dist/{requests-in-flight-loader-4d55dd23.cjs.prod.js → requests-in-flight-loader-ecde7bbe.cjs.prod.js} +4 -4
- package/dist/{service-page-project-switcher-1f88b9ef.cjs.dev.js → service-page-project-switcher-1977dcac.cjs.dev.js} +1 -1
- package/dist/{service-page-project-switcher-c0df9b6e.esm.js → service-page-project-switcher-8ee27c7e.esm.js} +1 -1
- package/dist/{service-page-project-switcher-e1562491.cjs.prod.js → service-page-project-switcher-a0df49fc.cjs.prod.js} +1 -1
- package/dist/{use-applications-menu-8857654a.cjs.dev.js → use-applications-menu-4ba2061e.cjs.dev.js} +1 -1
- package/dist/{use-applications-menu-862cdf4b.cjs.prod.js → use-applications-menu-af860769.cjs.prod.js} +1 -1
- package/dist/{use-applications-menu-435f0838.esm.js → use-applications-menu-f296617c.esm.js} +1 -1
- package/dist/{user-settings-menu-d5d5dba3.cjs.prod.js → user-settings-menu-6a7b4699.cjs.prod.js} +5 -5
- package/dist/{user-settings-menu-7aec4a5a.cjs.dev.js → user-settings-menu-85485124.cjs.dev.js} +5 -5
- package/dist/{user-settings-menu-ff17aa78.esm.js → user-settings-menu-c7836a3c.esm.js} +5 -5
- package/dist/{version-tracker-b4681839.cjs.prod.js → version-tracker-16b5844a.cjs.prod.js} +2 -2
- package/dist/{version-tracker-7df81f43.cjs.dev.js → version-tracker-d30bd05d.cjs.dev.js} +2 -2
- package/dist/{version-tracker-9ca66a1c.esm.js → version-tracker-de5d57b3.esm.js} +2 -2
- package/package.json +16 -16
- package/ssr/dist/commercetools-frontend-application-shell-ssr.cjs.dev.js +2 -2
- package/ssr/dist/commercetools-frontend-application-shell-ssr.cjs.prod.js +2 -2
- package/ssr/dist/commercetools-frontend-application-shell-ssr.esm.js +2 -2
- package/test-utils/dist/commercetools-frontend-application-shell-test-utils.cjs.dev.js +3 -3
- package/test-utils/dist/commercetools-frontend-application-shell-test-utils.cjs.prod.js +3 -3
- package/test-utils/dist/commercetools-frontend-application-shell-test-utils.esm.js +3 -3
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var configureApollo = require('./configure-apollo-
|
|
3
|
+
var configureApollo = require('./configure-apollo-f632e6cf.cjs.prod.js');
|
|
4
4
|
var _pt = require('prop-types');
|
|
5
5
|
var react = require('react');
|
|
6
6
|
var reactRouterDom = require('react-router-dom');
|
|
@@ -24,7 +24,7 @@ var constants$1 = require('@commercetools-frontend/constants');
|
|
|
24
24
|
var i18n = require('@commercetools-frontend/i18n');
|
|
25
25
|
var reactNotifications = require('@commercetools-frontend/react-notifications');
|
|
26
26
|
var sentry = require('@commercetools-frontend/sentry');
|
|
27
|
-
var constants = require('./constants-
|
|
27
|
+
var constants = require('./constants-ed10e935.cjs.prod.js');
|
|
28
28
|
require('uuid');
|
|
29
29
|
require('@babel/runtime-corejs3/core-js-stable/url');
|
|
30
30
|
var _concatInstanceProperty = require('@babel/runtime-corejs3/core-js-stable/instance/concat');
|
|
@@ -73,7 +73,7 @@ var ldAdapter = require('@flopflip/launchdarkly-adapter');
|
|
|
73
73
|
var _reduceInstanceProperty = require('@babel/runtime-corejs3/core-js-stable/instance/reduce');
|
|
74
74
|
var reactRedux = require('react-redux');
|
|
75
75
|
var upperFirst = require('lodash/upperFirst');
|
|
76
|
-
var oidc = require('./oidc-
|
|
76
|
+
var oidc = require('./oidc-a780f067.cjs.prod.js');
|
|
77
77
|
require('@commercetools-uikit/design-system/materials/resets.css');
|
|
78
78
|
var _JSON$stringify = require('@babel/runtime-corejs3/core-js-stable/json/stringify');
|
|
79
79
|
var _someInstanceProperty = require('@babel/runtime-corejs3/core-js-stable/instance/some');
|
|
@@ -125,7 +125,7 @@ var upperFirst__default = /*#__PURE__*/_interopDefault(upperFirst);
|
|
|
125
125
|
var _JSON$stringify__default = /*#__PURE__*/_interopDefault(_JSON$stringify);
|
|
126
126
|
var _someInstanceProperty__default = /*#__PURE__*/_interopDefault(_someInstanceProperty);
|
|
127
127
|
|
|
128
|
-
const RequestsInFlightLoader = /*#__PURE__*/react.lazy(() => Promise.resolve().then(function () { return require('./requests-in-flight-loader-
|
|
128
|
+
const RequestsInFlightLoader = /*#__PURE__*/react.lazy(() => Promise.resolve().then(function () { return require('./requests-in-flight-loader-ecde7bbe.cjs.prod.js' /* webpackChunkName: "requests-in-flight-loader" */); }));
|
|
129
129
|
|
|
130
130
|
// Attempt to load the `projectKey` from localStorage
|
|
131
131
|
function selectProjectKeyFromLocalStorage() {
|
|
@@ -283,11 +283,11 @@ function ownKeys$8(object, enumerableOnly) { var keys = _Object$keys__default["d
|
|
|
283
283
|
function _objectSpread$8(target) { for (var i = 1; i < arguments.length; i++) { var _context, _context2; var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? _forEachInstanceProperty__default["default"](_context = ownKeys$8(Object(source), !0)).call(_context, function (key) { _defineProperty(target, key, source[key]); }) : _Object$getOwnPropertyDescriptors__default["default"] ? _Object$defineProperties__default["default"](target, _Object$getOwnPropertyDescriptors__default["default"](source)) : _forEachInstanceProperty__default["default"](_context2 = ownKeys$8(Object(source))).call(_context2, function (key) { _Object$defineProperty__default["default"](target, key, _Object$getOwnPropertyDescriptor__default["default"](source, key)); }); } return target; }
|
|
284
284
|
var ProjectsQuery = { kind: "Document", definitions: [{ kind: "OperationDefinition", operation: "query", name: { kind: "Name", value: "FetchUserProjects" }, variableDefinitions: [], directives: [], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", alias: { kind: "Name", value: "user" }, name: { kind: "Name", value: "me" }, arguments: [], directives: [], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "id" }, arguments: [], directives: [] }, { kind: "Field", name: { kind: "Name", value: "projects" }, arguments: [], directives: [], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "results" }, arguments: [], directives: [], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "name" }, arguments: [], directives: [] }, { kind: "Field", name: { kind: "Name", value: "key" }, arguments: [], directives: [] }, { kind: "Field", name: { kind: "Name", value: "suspension" }, arguments: [], directives: [], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "isActive" }, arguments: [], directives: [] }] } }, { kind: "Field", name: { kind: "Name", value: "expiry" }, arguments: [], directives: [], selectionSet: { kind: "SelectionSet", selections: [{ kind: "Field", name: { kind: "Name", value: "isActive" }, arguments: [], directives: [] }] } }] } }] } }] } }] } }], loc: { start: 0, end: 218, source: { body: "query FetchUserProjects {\n user: me {\n id\n projects {\n results {\n name\n key\n suspension {\n isActive\n }\n expiry {\n isActive\n }\n }\n }\n }\n}\n", name: "GraphQL request", locationOffset: { line: 1, column: 1 } } } };
|
|
285
285
|
const PROJECT_SWITCHER_LABEL_ID = 'project-switcher-label';
|
|
286
|
-
var _ref3
|
|
286
|
+
var _ref3 = {
|
|
287
287
|
name: "82a6rk",
|
|
288
288
|
styles: "flex:1"
|
|
289
289
|
} ;
|
|
290
|
-
var _ref4
|
|
290
|
+
var _ref4 = {
|
|
291
291
|
name: "zol16h",
|
|
292
292
|
styles: "display:flex;flex:1;align-items:center"
|
|
293
293
|
} ;
|
|
@@ -295,9 +295,9 @@ const ProjectSwitcherValueContainer = _ref5 => {
|
|
|
295
295
|
let projectCount = _ref5.projectCount,
|
|
296
296
|
restProps = _objectWithoutProperties(_ref5, _excluded$1);
|
|
297
297
|
return jsxRuntime.jsxs("div", {
|
|
298
|
-
css: _ref4
|
|
298
|
+
css: _ref4,
|
|
299
299
|
children: [jsxRuntime.jsx("div", {
|
|
300
|
-
css: _ref3
|
|
300
|
+
css: _ref3,
|
|
301
301
|
children: jsxRuntime.jsx(SelectInput__default["default"].ValueContainer, _objectSpread$8(_objectSpread$8({}, restProps), {}, {
|
|
302
302
|
children: restProps.children
|
|
303
303
|
}))
|
|
@@ -409,7 +409,7 @@ ProjectSwitcher.displayName = 'ProjectSwitcher';
|
|
|
409
409
|
// eslint-disable-next-line import/prefer-default-export
|
|
410
410
|
const REQUESTS_IN_FLIGHT_LOADER_DOM_ID = 'loader-for-requests-in-flight';
|
|
411
411
|
|
|
412
|
-
const UserSettingsMenu = /*#__PURE__*/react.lazy(() => Promise.resolve().then(function () { return require('./user-settings-menu-
|
|
412
|
+
const UserSettingsMenu = /*#__PURE__*/react.lazy(() => Promise.resolve().then(function () { return require('./user-settings-menu-6a7b4699.cjs.prod.js' /* webpackChunkName: "user-settings-menu" */); }));
|
|
413
413
|
|
|
414
414
|
var _ref$1 = {
|
|
415
415
|
name: "36bnqj",
|
|
@@ -600,7 +600,7 @@ FetchUser.propTypes = {
|
|
|
600
600
|
};
|
|
601
601
|
FetchUser.displayName = 'FetchUser';
|
|
602
602
|
|
|
603
|
-
const Navbar = /*#__PURE__*/react.lazy(() => Promise.resolve().then(function () { return require('./navbar-
|
|
603
|
+
const Navbar = /*#__PURE__*/react.lazy(() => Promise.resolve().then(function () { return require('./navbar-c548a201.cjs.prod.js' /* webpackChunkName: "navbar" */); }));
|
|
604
604
|
|
|
605
605
|
const _excluded = ["icon"];
|
|
606
606
|
function ownKeys$7(object, enumerableOnly) { var keys = _Object$keys__default["default"](object); if (_Object$getOwnPropertySymbols__default["default"]) { var symbols = _Object$getOwnPropertySymbols__default["default"](object); enumerableOnly && (symbols = _filterInstanceProperty__default["default"](symbols).call(symbols, function (sym) { return _Object$getOwnPropertyDescriptor__default["default"](object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
|
|
@@ -991,7 +991,7 @@ const LoadingNavBar = () => {
|
|
|
991
991
|
};
|
|
992
992
|
LoadingNavBar.displayName = 'LoadingNavBar';
|
|
993
993
|
|
|
994
|
-
const ProjectContainer = /*#__PURE__*/react.lazy(() => Promise.resolve().then(function () { return require('./project-container-
|
|
994
|
+
const ProjectContainer = /*#__PURE__*/react.lazy(() => Promise.resolve().then(function () { return require('./project-container-17d86e50.cjs.prod.js' /* webpackChunkName: "project-container" */); }));
|
|
995
995
|
|
|
996
996
|
const getSelectedDataLocaleForProject = projectLocales => {
|
|
997
997
|
const cachedDataLocale = window.localStorage.getItem(constants.STORAGE_KEYS.SELECTED_DATA_LOCALE);
|
|
@@ -1103,7 +1103,7 @@ var pimIndexerStates = {
|
|
|
1103
1103
|
NOT_INDEXED: 'NOT_INDEXED'
|
|
1104
1104
|
};
|
|
1105
1105
|
|
|
1106
|
-
const QuickAccess = /*#__PURE__*/react.lazy(() => Promise.resolve().then(function () { return require('./quick-access-
|
|
1106
|
+
const QuickAccess = /*#__PURE__*/react.lazy(() => Promise.resolve().then(function () { return require('./quick-access-8e4e90a0.cjs.prod.js' /* webpackChunkName: "quick-access" */); }));
|
|
1107
1107
|
|
|
1108
1108
|
const QuickAccessTrigger = props => {
|
|
1109
1109
|
const _useState = react.useState(false),
|
|
@@ -1190,7 +1190,7 @@ const QuickAccessTrigger = props => {
|
|
|
1190
1190
|
QuickAccessTrigger.propTypes = {};
|
|
1191
1191
|
QuickAccessTrigger.displayName = 'QuickAccessTrigger';
|
|
1192
1192
|
|
|
1193
|
-
const RedirectToLogout = /*#__PURE__*/react.lazy(() => Promise.resolve().then(function () { return require('./redirect-to-logout-
|
|
1193
|
+
const RedirectToLogout = /*#__PURE__*/react.lazy(() => Promise.resolve().then(function () { return require('./redirect-to-logout-54a2fc06.cjs.prod.js' /* webpackChunkName: "redirect-to-logout" */); }));
|
|
1194
1194
|
|
|
1195
1195
|
const RedirectToProjectCreate = /*#__PURE__*/react.lazy(() => Promise.resolve().then(function () { return require('./redirect-to-project-create-2266c427.cjs.prod.js' /* webpackChunkName: "redirect-to-project-create" */); }));
|
|
1196
1196
|
|
|
@@ -1213,7 +1213,10 @@ const RedirectToProjectCreate = /*#__PURE__*/react.lazy(() => Promise.resolve().
|
|
|
1213
1213
|
* them to off until fetched).
|
|
1214
1214
|
*/
|
|
1215
1215
|
|
|
1216
|
-
const
|
|
1216
|
+
const MAIN_NAVIGATION = 'newMainNavigationBar';
|
|
1217
|
+
const FLAGS = {
|
|
1218
|
+
[MAIN_NAVIGATION]: false
|
|
1219
|
+
};
|
|
1217
1220
|
|
|
1218
1221
|
function ownKeys$6(object, enumerableOnly) { var keys = _Object$keys__default["default"](object); if (_Object$getOwnPropertySymbols__default["default"]) { var symbols = _Object$getOwnPropertySymbols__default["default"](object); enumerableOnly && (symbols = _filterInstanceProperty__default["default"](symbols).call(symbols, function (sym) { return _Object$getOwnPropertyDescriptor__default["default"](object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
|
|
1219
1222
|
function _objectSpread$6(target) { for (var i = 1; i < arguments.length; i++) { var _context, _context2; var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? _forEachInstanceProperty__default["default"](_context = ownKeys$6(Object(source), !0)).call(_context, function (key) { _defineProperty(target, key, source[key]); }) : _Object$getOwnPropertyDescriptors__default["default"] ? _Object$defineProperties__default["default"](target, _Object$getOwnPropertyDescriptors__default["default"](source)) : _forEachInstanceProperty__default["default"](_context2 = ownKeys$6(Object(source))).call(_context2, function (key) { _Object$defineProperty__default["default"](target, key, _Object$getOwnPropertyDescriptor__default["default"](source, key)); }); } return target; }
|
|
@@ -1338,7 +1341,13 @@ const ThemeSwitcher = () => {
|
|
|
1338
1341
|
});
|
|
1339
1342
|
};
|
|
1340
1343
|
|
|
1341
|
-
const VersionTracker = /*#__PURE__*/react.lazy(() => Promise.resolve().then(function () { return require('./version-tracker-
|
|
1344
|
+
const VersionTracker = /*#__PURE__*/react.lazy(() => Promise.resolve().then(function () { return require('./version-tracker-16b5844a.cjs.prod.js' /* webpackChunkName: "version-tracker" */); }));
|
|
1345
|
+
|
|
1346
|
+
// TODO: Remove this file once the new navigation is enabled for all users
|
|
1347
|
+
const NewMainNavigationFlagWrapper = props => {
|
|
1348
|
+
const isNewNavigationEnabled = reactBroadcast.useFeatureToggle(MAIN_NAVIGATION);
|
|
1349
|
+
return props.children(isNewNavigationEnabled);
|
|
1350
|
+
};
|
|
1342
1351
|
|
|
1343
1352
|
function ownKeys$4(object, enumerableOnly) { var keys = _Object$keys__default["default"](object); if (_Object$getOwnPropertySymbols__default["default"]) { var symbols = _Object$getOwnPropertySymbols__default["default"](object); enumerableOnly && (symbols = _filterInstanceProperty__default["default"](symbols).call(symbols, function (sym) { return _Object$getOwnPropertyDescriptor__default["default"](object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
|
|
1344
1353
|
function _objectSpread$4(target) { for (var i = 1; i < arguments.length; i++) { var _context2, _context3; var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? _forEachInstanceProperty__default["default"](_context2 = ownKeys$4(Object(source), !0)).call(_context2, function (key) { _defineProperty(target, key, source[key]); }) : _Object$getOwnPropertyDescriptors__default["default"] ? _Object$defineProperties__default["default"](target, _Object$getOwnPropertyDescriptors__default["default"](source)) : _forEachInstanceProperty__default["default"](_context3 = ownKeys$4(Object(source))).call(_context3, function (key) { _Object$defineProperty__default["default"](target, key, _Object$getOwnPropertyDescriptor__default["default"](source, key)); }); } return target; }
|
|
@@ -1351,10 +1360,7 @@ const getHasUserBeenDeletedError = graphQLErrors => _findInstanceProperty__defau
|
|
|
1351
1360
|
});
|
|
1352
1361
|
const MainContainer = /*#__PURE__*/_styled__default["default"]("main", {
|
|
1353
1362
|
target: "esrtekc0"
|
|
1354
|
-
} )(
|
|
1355
|
-
name: "1rdshd",
|
|
1356
|
-
styles: "grid-column:2;grid-row:3;min-width:0;overflow-x:hidden;overflow-y:scroll;display:flex;flex-direction:column;position:relative"
|
|
1357
|
-
} );
|
|
1363
|
+
} )(props => props.isNewNavigationEnabled ? "\n grid-column: 2/3;\n grid-row: 3/4;\n " : "\n grid-column: 2;\n grid-row: 3;\n ", ";min-width:0;overflow-x:hidden;overflow-y:scroll;display:flex;flex-direction:column;position:relative;" + ("" ));
|
|
1358
1364
|
|
|
1359
1365
|
/**
|
|
1360
1366
|
* This component is rendered whenever the user is considered "authenticated"
|
|
@@ -1365,14 +1371,6 @@ var _ref = {
|
|
|
1365
1371
|
styles: "flex-grow:1;display:flex;flex-direction:column;position:relative;>*:not(:first-of-type){flex-grow:1;display:flex;flex-direction:column;}"
|
|
1366
1372
|
} ;
|
|
1367
1373
|
var _ref2 = {
|
|
1368
|
-
name: "14w5yo3",
|
|
1369
|
-
styles: "position:relative;grid-row:3;display:flex;flex-direction:column"
|
|
1370
|
-
} ;
|
|
1371
|
-
var _ref3 = {
|
|
1372
|
-
name: "fqjitq",
|
|
1373
|
-
styles: "grid-row:2;grid-column:1/3"
|
|
1374
|
-
} ;
|
|
1375
|
-
var _ref4 = {
|
|
1376
1374
|
name: "8bdwu0",
|
|
1377
1375
|
styles: "grid-row:1;grid-column:1/3"
|
|
1378
1376
|
} ;
|
|
@@ -1391,10 +1389,10 @@ const ApplicationShellAuthenticated = props => {
|
|
|
1391
1389
|
notificationsPageRef
|
|
1392
1390
|
});
|
|
1393
1391
|
return jsxRuntime.jsx(FetchUser, {
|
|
1394
|
-
children:
|
|
1395
|
-
let isLoadingUser =
|
|
1396
|
-
user =
|
|
1397
|
-
error =
|
|
1392
|
+
children: _ref3 => {
|
|
1393
|
+
let isLoadingUser = _ref3.isLoading,
|
|
1394
|
+
user = _ref3.user,
|
|
1395
|
+
error = _ref3.error;
|
|
1398
1396
|
if (error) {
|
|
1399
1397
|
// In case there is an unauthorized error, we redirect to the login page
|
|
1400
1398
|
if (error.graphQLErrors && _Array$isArray__default["default"](error.graphQLErrors)) {
|
|
@@ -1414,9 +1412,9 @@ const ApplicationShellAuthenticated = props => {
|
|
|
1414
1412
|
return jsxRuntime.jsx(i18n.AsyncLocaleData, {
|
|
1415
1413
|
locale: userLocale,
|
|
1416
1414
|
applicationMessages: props.applicationMessages,
|
|
1417
|
-
children:
|
|
1418
|
-
let locale =
|
|
1419
|
-
messages =
|
|
1415
|
+
children: _ref4 => {
|
|
1416
|
+
let locale = _ref4.locale,
|
|
1417
|
+
messages = _ref4.messages;
|
|
1420
1418
|
sentry.reportErrorToSentry(error, {});
|
|
1421
1419
|
return jsxRuntime.jsx(ConfigureIntlProvider, {
|
|
1422
1420
|
locale: locale,
|
|
@@ -1433,10 +1431,10 @@ const ApplicationShellAuthenticated = props => {
|
|
|
1433
1431
|
children: jsxRuntime.jsx(i18n.AsyncLocaleData, {
|
|
1434
1432
|
locale: user === null || user === void 0 ? void 0 : user.language,
|
|
1435
1433
|
applicationMessages: props.applicationMessages,
|
|
1436
|
-
children:
|
|
1437
|
-
let isLoadingLocaleData =
|
|
1438
|
-
locale =
|
|
1439
|
-
messages =
|
|
1434
|
+
children: _ref5 => {
|
|
1435
|
+
let isLoadingLocaleData = _ref5.isLoading,
|
|
1436
|
+
locale = _ref5.locale,
|
|
1437
|
+
messages = _ref5.messages;
|
|
1440
1438
|
return jsxRuntime.jsx(ConfigureIntlProvider
|
|
1441
1439
|
// We do not want to pass the language as long as the locale data
|
|
1442
1440
|
// is not loaded.
|
|
@@ -1450,180 +1448,186 @@ const ApplicationShellAuthenticated = props => {
|
|
|
1450
1448
|
ldClientSideId: applicationEnvironment.ldClientSideId,
|
|
1451
1449
|
flags: props.featureFlags,
|
|
1452
1450
|
defaultFlags: props.defaultFeatureFlags,
|
|
1453
|
-
children: jsxRuntime.
|
|
1454
|
-
children:
|
|
1455
|
-
|
|
1456
|
-
|
|
1457
|
-
|
|
1458
|
-
|
|
1459
|
-
|
|
1460
|
-
|
|
1461
|
-
|
|
1462
|
-
|
|
1463
|
-
|
|
1464
|
-
|
|
1465
|
-
|
|
1466
|
-
|
|
1467
|
-
|
|
1468
|
-
|
|
1469
|
-
|
|
1470
|
-
|
|
1471
|
-
|
|
1472
|
-
|
|
1473
|
-
|
|
1474
|
-
|
|
1475
|
-
|
|
1476
|
-
|
|
1477
|
-
|
|
1478
|
-
|
|
1479
|
-
|
|
1480
|
-
|
|
1481
|
-
|
|
1482
|
-
|
|
1483
|
-
|
|
1484
|
-
|
|
1485
|
-
|
|
1486
|
-
|
|
1451
|
+
children: jsxRuntime.jsx(NewMainNavigationFlagWrapper, {
|
|
1452
|
+
children: isNewNavigationEnabled => {
|
|
1453
|
+
return jsxRuntime.jsxs(jsxRuntime.Fragment, {
|
|
1454
|
+
children: [jsxRuntime.jsx(ThemeSwitcher, {}), jsxRuntime.jsx(VersionTracker, {}), jsxRuntime.jsx(RequestsInFlightLoader, {}), jsxRuntime.jsx(sentry.SentryUserTracker, {
|
|
1455
|
+
user: user !== null && user !== void 0 ? user : undefined
|
|
1456
|
+
}), jsxRuntime.jsxs("div", {
|
|
1457
|
+
css: /*#__PURE__*/react$1.css("height:100vh;display:grid;grid-template-rows:", isNewNavigationEnabled ? "auto ".concat(constants.DIMENSIONS.header, " 1fr") : "auto ".concat(constants.DIMENSIONS.header, " 1fr"), ";grid-template-columns:", isNewNavigationEnabled ? 'minmax(80px, 256px) 1fr' : 'auto 1fr', ";" + ("" ), "" ),
|
|
1458
|
+
children: [jsxRuntime.jsxs("div", {
|
|
1459
|
+
ref: notificationsGlobalRef,
|
|
1460
|
+
role: "region",
|
|
1461
|
+
"aria-live": "polite",
|
|
1462
|
+
css: _ref2,
|
|
1463
|
+
children: [jsxRuntime.jsx("div", {
|
|
1464
|
+
id: "above-top-navigation"
|
|
1465
|
+
}), jsxRuntime.jsx(reactNotifications.NotificationsList, {
|
|
1466
|
+
domain: constants$1.DOMAINS.GLOBAL
|
|
1467
|
+
})]
|
|
1468
|
+
}), jsxRuntime.jsx(reactRouterDom.Route, {
|
|
1469
|
+
children: () => {
|
|
1470
|
+
if (!projectKeyFromUrl) return jsxRuntime.jsx(QuickAccessTrigger, {});
|
|
1471
|
+
return jsxRuntime.jsx(FetchProject, {
|
|
1472
|
+
projectKey: projectKeyFromUrl,
|
|
1473
|
+
children: _ref6 => {
|
|
1474
|
+
let isProjectLoading = _ref6.isLoading,
|
|
1475
|
+
project = _ref6.project;
|
|
1476
|
+
if (isProjectLoading || !project) return null;
|
|
1477
|
+
|
|
1478
|
+
// when used outside of a project context,
|
|
1479
|
+
// or when the project is expired or supsended
|
|
1480
|
+
const shouldUseProjectContext = !(project.suspension && project.suspension.isActive || project.expiry && project.expiry.isActive);
|
|
1481
|
+
if (!shouldUseProjectContext) return jsxRuntime.jsx(QuickAccessTrigger, {});
|
|
1482
|
+
return jsxRuntime.jsx(ProjectDataLocale, {
|
|
1483
|
+
locales: project.languages,
|
|
1484
|
+
children: _ref7 => {
|
|
1485
|
+
let dataLocale = _ref7.locale,
|
|
1486
|
+
setProjectDataLocale = _ref7.setProjectDataLocale;
|
|
1487
|
+
return jsxRuntime.jsx(applicationShellConnectors.ApplicationContextProvider, {
|
|
1488
|
+
user: user,
|
|
1489
|
+
project: project,
|
|
1490
|
+
projectDataLocale: dataLocale,
|
|
1491
|
+
environment: applicationEnvironment,
|
|
1492
|
+
children: jsxRuntime.jsx(QuickAccessTrigger, {
|
|
1493
|
+
onChangeProjectDataLocale: setProjectDataLocale
|
|
1494
|
+
})
|
|
1495
|
+
});
|
|
1496
|
+
}
|
|
1497
|
+
});
|
|
1498
|
+
}
|
|
1499
|
+
});
|
|
1500
|
+
}
|
|
1501
|
+
}), jsxRuntime.jsx("header", {
|
|
1502
|
+
css: /*#__PURE__*/react$1.css("grid-row:", isNewNavigationEnabled ? '2/3' : '2', ";grid-column:", isNewNavigationEnabled ? '2/3' : '1/3', ";" + ("" ), "" ),
|
|
1503
|
+
children: jsxRuntime.jsx(AppBar, {
|
|
1504
|
+
user: user,
|
|
1505
|
+
projectKeyFromUrl: projectKeyFromUrl
|
|
1506
|
+
})
|
|
1507
|
+
}), jsxRuntime.jsx("aside", {
|
|
1508
|
+
css: /*#__PURE__*/react$1.css(isNewNavigationEnabled === false && "position: relative;\n grid-row: 3;\n display: flex;\n flex-direction: column;", " ", isNewNavigationEnabled === true && "grid-column: 1/2;\n grid-row: 2/4;\n background-color: beige;", ";" + ("" ), "" ),
|
|
1509
|
+
children: (() => {
|
|
1510
|
+
// The <NavBar> should only be rendered within a project
|
|
1511
|
+
// context, therefore when there is a `projectKey`.
|
|
1512
|
+
// If there is no `projectKey` in the URL (e.g. `/account`
|
|
1513
|
+
// routes), we don't render it.
|
|
1514
|
+
// NOTE: we also "cache" the `projectKey` in localStorage
|
|
1515
|
+
// but this should only be used to "re-hydrate" the URL
|
|
1516
|
+
// location (e.g when you go to `/`, there should be a
|
|
1517
|
+
// redirect to `/:projectKey`). Therefore, we should not
|
|
1518
|
+
// rely on the value in localStorage to determine which
|
|
1519
|
+
// `projectKey` is currently used.
|
|
1520
|
+
if (!projectKeyFromUrl) return null;
|
|
1521
|
+
return jsxRuntime.jsx(FetchProject, {
|
|
1522
|
+
projectKey: projectKeyFromUrl,
|
|
1523
|
+
children: _ref8 => {
|
|
1524
|
+
let isLoadingProject = _ref8.isLoading,
|
|
1525
|
+
project = _ref8.project;
|
|
1526
|
+
// Render the loading navbar as long as all the data
|
|
1527
|
+
// hasn't been loaded, or if the project does not exist.
|
|
1528
|
+
if (isLoadingUser || isLoadingLocaleData || isLoadingProject || !locale || !project) return jsxRuntime.jsx(LoadingNavBar, {});
|
|
1487
1529
|
return jsxRuntime.jsx(applicationShellConnectors.ApplicationContextProvider, {
|
|
1488
1530
|
user: user,
|
|
1489
|
-
|
|
1490
|
-
|
|
1491
|
-
|
|
1492
|
-
|
|
1493
|
-
|
|
1531
|
+
environment: applicationEnvironment
|
|
1532
|
+
// NOTE: do not pass the `project` into the application context.
|
|
1533
|
+
// The permissions for the Navbar are resolved separately, within
|
|
1534
|
+
// a different React context.
|
|
1535
|
+
,
|
|
1536
|
+
children: isNewNavigationEnabled === false && jsxRuntime.jsx(Navbar, {
|
|
1537
|
+
applicationLocale: locale,
|
|
1538
|
+
projectKey: projectKeyFromUrl,
|
|
1539
|
+
project: project,
|
|
1540
|
+
environment: applicationEnvironment,
|
|
1541
|
+
onMenuItemClick: props.onMenuItemClick
|
|
1494
1542
|
})
|
|
1495
1543
|
});
|
|
1496
1544
|
}
|
|
1497
1545
|
});
|
|
1498
|
-
}
|
|
1499
|
-
})
|
|
1500
|
-
|
|
1501
|
-
|
|
1502
|
-
|
|
1503
|
-
|
|
1504
|
-
|
|
1505
|
-
|
|
1506
|
-
|
|
1507
|
-
|
|
1508
|
-
|
|
1509
|
-
|
|
1510
|
-
// The <NavBar> should only be rendered within a project
|
|
1511
|
-
// context, therefore when there is a `projectKey`.
|
|
1512
|
-
// If there is no `projectKey` in the URL (e.g. `/account`
|
|
1513
|
-
// routes), we don't render it.
|
|
1514
|
-
// NOTE: we also "cache" the `projectKey` in localStorage
|
|
1515
|
-
// but this should only be used to "re-hydrate" the URL
|
|
1516
|
-
// location (e.g when you go to `/`, there should be a
|
|
1517
|
-
// redirect to `/:projectKey`). Therefore, we should not
|
|
1518
|
-
// rely on the value in localStorage to determine which
|
|
1519
|
-
// `projectKey` is currently used.
|
|
1520
|
-
if (!projectKeyFromUrl) return null;
|
|
1521
|
-
return jsxRuntime.jsx(FetchProject, {
|
|
1522
|
-
projectKey: projectKeyFromUrl,
|
|
1523
|
-
children: _ref10 => {
|
|
1524
|
-
let isLoadingProject = _ref10.isLoading,
|
|
1525
|
-
project = _ref10.project;
|
|
1526
|
-
// Render the loading navbar as long as all the data
|
|
1527
|
-
// hasn't been loaded, or if the project does not exist.
|
|
1528
|
-
if (isLoadingUser || isLoadingLocaleData || isLoadingProject || !locale || !project) return jsxRuntime.jsx(LoadingNavBar, {});
|
|
1529
|
-
return jsxRuntime.jsx(applicationShellConnectors.ApplicationContextProvider, {
|
|
1530
|
-
user: user,
|
|
1531
|
-
environment: applicationEnvironment
|
|
1532
|
-
// NOTE: do not pass the `project` into the application context.
|
|
1533
|
-
// The permissions for the Navbar are resolved separately, within
|
|
1534
|
-
// a different React context.
|
|
1535
|
-
,
|
|
1536
|
-
children: jsxRuntime.jsx(Navbar, {
|
|
1537
|
-
applicationLocale: locale,
|
|
1538
|
-
projectKey: projectKeyFromUrl,
|
|
1539
|
-
project: project,
|
|
1540
|
-
environment: applicationEnvironment,
|
|
1541
|
-
onMenuItemClick: props.onMenuItemClick
|
|
1542
|
-
})
|
|
1543
|
-
});
|
|
1544
|
-
}
|
|
1545
|
-
});
|
|
1546
|
-
})()
|
|
1547
|
-
}), isLoadingUser || isLoadingLocaleData ? jsxRuntime.jsx(MainContainer, {
|
|
1548
|
-
role: "main",
|
|
1549
|
-
children: jsxRuntime.jsx(ApplicationLoader, {})
|
|
1550
|
-
}) : jsxRuntime.jsxs(MainContainer, {
|
|
1551
|
-
role: "main",
|
|
1552
|
-
children: [jsxRuntime.jsx("div", {
|
|
1553
|
-
ref: notificationsPageRef,
|
|
1554
|
-
children: jsxRuntime.jsx(reactNotifications.NotificationsList, {
|
|
1555
|
-
domain: constants$1.DOMAINS.PAGE
|
|
1556
|
-
})
|
|
1557
|
-
}), jsxRuntime.jsx(reactNotifications.NotificationsList, {
|
|
1558
|
-
domain: constants$1.DOMAINS.SIDE
|
|
1559
|
-
}), jsxRuntime.jsxs("div", {
|
|
1560
|
-
css: _ref,
|
|
1561
|
-
children: [jsxRuntime.jsx(applicationComponents.PortalsContainer
|
|
1562
|
-
// @ts-ignore
|
|
1563
|
-
, {
|
|
1564
|
-
ref: layoutRefs,
|
|
1565
|
-
offsetTop: constants.DIMENSIONS.header,
|
|
1566
|
-
offsetLeft: projectKeyFromUrl ? constants.DIMENSIONS.navMenu : '0px',
|
|
1567
|
-
offsetLeftOnExpandedMenu: projectKeyFromUrl ? constants.DIMENSIONS.navMenuExpanded : '0px'
|
|
1568
|
-
}), jsxRuntime.jsxs(reactRouterDom.Switch, {
|
|
1569
|
-
children: [jsxRuntime.jsx(reactRouterDom.Redirect, {
|
|
1570
|
-
from: "/profile",
|
|
1571
|
-
to: "/account/profile"
|
|
1572
|
-
}), jsxRuntime.jsx(reactRouterDom.Route, {
|
|
1573
|
-
path: "/account",
|
|
1574
|
-
children:
|
|
1575
|
-
/**
|
|
1576
|
-
* In case the AppShell uses the `render` function, we assume it's one of two cases:
|
|
1577
|
-
* 1. The application does not use `children` and therefore implements the routes including
|
|
1578
|
-
* the <RouteCatchAll> (this is the "legacy" behavior).
|
|
1579
|
-
* 2. It's the account application, which always uses `render` and therefore should render as normal.
|
|
1580
|
-
*
|
|
1581
|
-
* In case the AppShell uses the `children` function, we can always assume that
|
|
1582
|
-
* it's a normal Custom Application and that it should trigger a force reload.
|
|
1583
|
-
*/
|
|
1584
|
-
props.render ? jsxRuntime.jsx(jsxRuntime.Fragment, {
|
|
1585
|
-
children: props.render()
|
|
1586
|
-
}) : jsxRuntime.jsx(configureApollo.RouteCatchAll, {})
|
|
1587
|
-
}), jsxRuntime.jsx(reactRouterDom.Route, {
|
|
1588
|
-
exact: true,
|
|
1589
|
-
path: "/",
|
|
1590
|
-
children: (() => {
|
|
1591
|
-
var _user$defaultProjectK;
|
|
1592
|
-
const previousProjectKey = getPreviousProjectKey((_user$defaultProjectK = user === null || user === void 0 ? void 0 : user.defaultProjectKey) !== null && _user$defaultProjectK !== void 0 ? _user$defaultProjectK : undefined);
|
|
1593
|
-
|
|
1594
|
-
/**
|
|
1595
|
-
* NOTE:
|
|
1596
|
-
* Given the user has not been loaded a loading spinner is shown.
|
|
1597
|
-
* Given the user was not working on a project previously nor has a default
|
|
1598
|
-
* project, the user will be prompted to create one.
|
|
1599
|
-
* Given the user was working on a project previously or has a default
|
|
1600
|
-
* project, the application will redirect to that project.
|
|
1601
|
-
*/
|
|
1602
|
-
if (!user) return jsxRuntime.jsx(ApplicationLoader, {});
|
|
1603
|
-
if (!previousProjectKey) return jsxRuntime.jsx(RedirectToProjectCreate, {});
|
|
1604
|
-
return jsxRuntime.jsx(reactRouterDom.Redirect, {
|
|
1605
|
-
to: "/".concat(previousProjectKey)
|
|
1606
|
-
});
|
|
1607
|
-
})()
|
|
1608
|
-
}), jsxRuntime.jsx(reactRouterDom.Route, {
|
|
1609
|
-
exact: false,
|
|
1610
|
-
path: "/:projectKey",
|
|
1611
|
-
children: jsxRuntime.jsx(ProjectContainer, {
|
|
1612
|
-
user: user,
|
|
1613
|
-
environment: applicationEnvironment,
|
|
1614
|
-
disableRoutePermissionCheck: props.disableRoutePermissionCheck
|
|
1615
|
-
// This effectively renders the
|
|
1616
|
-
// children, which is the application
|
|
1617
|
-
// specific part
|
|
1618
|
-
,
|
|
1619
|
-
render: props.render,
|
|
1620
|
-
children: props.children
|
|
1546
|
+
})()
|
|
1547
|
+
}), isLoadingUser || isLoadingLocaleData ? jsxRuntime.jsx(MainContainer, {
|
|
1548
|
+
isNewNavigationEnabled: isNewNavigationEnabled,
|
|
1549
|
+
role: "main",
|
|
1550
|
+
children: jsxRuntime.jsx(ApplicationLoader, {})
|
|
1551
|
+
}) : jsxRuntime.jsxs(MainContainer, {
|
|
1552
|
+
isNewNavigationEnabled: isNewNavigationEnabled,
|
|
1553
|
+
role: "main",
|
|
1554
|
+
children: [jsxRuntime.jsx("div", {
|
|
1555
|
+
ref: notificationsPageRef,
|
|
1556
|
+
children: jsxRuntime.jsx(reactNotifications.NotificationsList, {
|
|
1557
|
+
domain: constants$1.DOMAINS.PAGE
|
|
1621
1558
|
})
|
|
1559
|
+
}), jsxRuntime.jsx(reactNotifications.NotificationsList, {
|
|
1560
|
+
domain: constants$1.DOMAINS.SIDE
|
|
1561
|
+
}), jsxRuntime.jsxs("div", {
|
|
1562
|
+
css: _ref,
|
|
1563
|
+
children: [jsxRuntime.jsx(applicationComponents.PortalsContainer
|
|
1564
|
+
// @ts-ignore
|
|
1565
|
+
, {
|
|
1566
|
+
ref: layoutRefs,
|
|
1567
|
+
offsetTop: constants.DIMENSIONS.header,
|
|
1568
|
+
offsetLeft: projectKeyFromUrl ? constants.DIMENSIONS.navMenu : '0px',
|
|
1569
|
+
offsetLeftOnExpandedMenu: projectKeyFromUrl ? constants.DIMENSIONS.navMenuExpanded : '0px'
|
|
1570
|
+
}), jsxRuntime.jsxs(reactRouterDom.Switch, {
|
|
1571
|
+
children: [jsxRuntime.jsx(reactRouterDom.Redirect, {
|
|
1572
|
+
from: "/profile",
|
|
1573
|
+
to: "/account/profile"
|
|
1574
|
+
}), jsxRuntime.jsx(reactRouterDom.Route, {
|
|
1575
|
+
path: "/account",
|
|
1576
|
+
children:
|
|
1577
|
+
/**
|
|
1578
|
+
* In case the AppShell uses the `render` function, we assume it's one of two cases:
|
|
1579
|
+
* 1. The application does not use `children` and therefore implements the routes including
|
|
1580
|
+
* the <RouteCatchAll> (this is the "legacy" behavior).
|
|
1581
|
+
* 2. It's the account application, which always uses `render` and therefore should render as normal.
|
|
1582
|
+
*
|
|
1583
|
+
* In case the AppShell uses the `children` function, we can always assume that
|
|
1584
|
+
* it's a normal Custom Application and that it should trigger a force reload.
|
|
1585
|
+
*/
|
|
1586
|
+
props.render ? jsxRuntime.jsx(jsxRuntime.Fragment, {
|
|
1587
|
+
children: props.render()
|
|
1588
|
+
}) : jsxRuntime.jsx(configureApollo.RouteCatchAll, {})
|
|
1589
|
+
}), jsxRuntime.jsx(reactRouterDom.Route, {
|
|
1590
|
+
exact: true,
|
|
1591
|
+
path: "/",
|
|
1592
|
+
children: (() => {
|
|
1593
|
+
var _user$defaultProjectK;
|
|
1594
|
+
const previousProjectKey = getPreviousProjectKey((_user$defaultProjectK = user === null || user === void 0 ? void 0 : user.defaultProjectKey) !== null && _user$defaultProjectK !== void 0 ? _user$defaultProjectK : undefined);
|
|
1595
|
+
|
|
1596
|
+
/**
|
|
1597
|
+
* NOTE:
|
|
1598
|
+
* Given the user has not been loaded a loading spinner is shown.
|
|
1599
|
+
* Given the user was not working on a project previously nor has a default
|
|
1600
|
+
* project, the user will be prompted to create one.
|
|
1601
|
+
* Given the user was working on a project previously or has a default
|
|
1602
|
+
* project, the application will redirect to that project.
|
|
1603
|
+
*/
|
|
1604
|
+
if (!user) return jsxRuntime.jsx(ApplicationLoader, {});
|
|
1605
|
+
if (!previousProjectKey) return jsxRuntime.jsx(RedirectToProjectCreate, {});
|
|
1606
|
+
return jsxRuntime.jsx(reactRouterDom.Redirect, {
|
|
1607
|
+
to: "/".concat(previousProjectKey)
|
|
1608
|
+
});
|
|
1609
|
+
})()
|
|
1610
|
+
}), jsxRuntime.jsx(reactRouterDom.Route, {
|
|
1611
|
+
exact: false,
|
|
1612
|
+
path: "/:projectKey",
|
|
1613
|
+
children: jsxRuntime.jsx(ProjectContainer, {
|
|
1614
|
+
user: user,
|
|
1615
|
+
environment: applicationEnvironment,
|
|
1616
|
+
disableRoutePermissionCheck: props.disableRoutePermissionCheck
|
|
1617
|
+
// This effectively renders the
|
|
1618
|
+
// children, which is the application
|
|
1619
|
+
// specific part
|
|
1620
|
+
,
|
|
1621
|
+
render: props.render,
|
|
1622
|
+
children: props.children
|
|
1623
|
+
})
|
|
1624
|
+
})]
|
|
1625
|
+
})]
|
|
1622
1626
|
})]
|
|
1623
1627
|
})]
|
|
1624
1628
|
})]
|
|
1625
|
-
})
|
|
1626
|
-
}
|
|
1629
|
+
});
|
|
1630
|
+
}
|
|
1627
1631
|
})
|
|
1628
1632
|
})
|
|
1629
1633
|
}));
|
|
@@ -1809,7 +1813,7 @@ const hasCachedAuthenticationState = () => {
|
|
|
1809
1813
|
return window.localStorage.getItem(constants.STORAGE_KEYS.IS_AUTHENTICATED) === 'true';
|
|
1810
1814
|
};
|
|
1811
1815
|
|
|
1812
|
-
const OidcCallback = /*#__PURE__*/react.lazy(() => Promise.resolve().then(function () { return require('./oidc-callback-
|
|
1816
|
+
const OidcCallback = /*#__PURE__*/react.lazy(() => Promise.resolve().then(function () { return require('./oidc-callback-e0687f34.cjs.prod.js' /* webpackChunkName: "oidc-callback" */); }));
|
|
1813
1817
|
|
|
1814
1818
|
function ownKeys$2(object, enumerableOnly) { var keys = _Object$keys__default["default"](object); if (_Object$getOwnPropertySymbols__default["default"]) { var symbols = _Object$getOwnPropertySymbols__default["default"](object); enumerableOnly && (symbols = _filterInstanceProperty__default["default"](symbols).call(symbols, function (sym) { return _Object$getOwnPropertyDescriptor__default["default"](object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
|
|
1815
1819
|
function _objectSpread$2(target) { for (var i = 1; i < arguments.length; i++) { var _context, _context2; var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? _forEachInstanceProperty__default["default"](_context = ownKeys$2(Object(source), !0)).call(_context, function (key) { _defineProperty(target, key, source[key]); }) : _Object$getOwnPropertyDescriptors__default["default"] ? _Object$defineProperties__default["default"](target, _Object$getOwnPropertyDescriptors__default["default"](source)) : _forEachInstanceProperty__default["default"](_context2 = ownKeys$2(Object(source))).call(_context2, function (key) { _Object$defineProperty__default["default"](target, key, _Object$getOwnPropertyDescriptor__default["default"](source, key)); }); } return target; }
|
|
@@ -1959,7 +1963,7 @@ const ApplicationShellProvider = props => {
|
|
|
1959
1963
|
ApplicationShellProvider.propTypes = {};
|
|
1960
1964
|
ApplicationShellProvider.displayName = 'ApplicationShellProvider';
|
|
1961
1965
|
|
|
1962
|
-
const RedirectToLogin = /*#__PURE__*/react.lazy(() => Promise.resolve().then(function () { return require('./redirect-to-login-
|
|
1966
|
+
const RedirectToLogin = /*#__PURE__*/react.lazy(() => Promise.resolve().then(function () { return require('./redirect-to-login-7cb94c3e.cjs.prod.js' /* webpackChunkName: "redirect-to-login" */); }));
|
|
1963
1967
|
|
|
1964
1968
|
const styles = {
|
|
1965
1969
|
name: "1prreal",
|