@elliemae/pui-app-sdk 2.21.1 → 2.21.5

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.
@@ -28,7 +28,9 @@ const setAppDynamicsUserData = params => {
28
28
  };
29
29
 
30
30
  if (brum) {
31
- brum.setCustomUserData(() => ({
31
+ var _brum$setCustomUserDa;
32
+
33
+ (_brum$setCustomUserDa = brum.setCustomUserData) === null || _brum$setCustomUserDa === void 0 ? void 0 : _brum$setCustomUserDa.call(brum, () => ({
32
34
  userData
33
35
  }));
34
36
  }
@@ -17,6 +17,8 @@ var _reduxSaga = _interopRequireDefault(require("redux-saga"));
17
17
 
18
18
  var _reducers = require("./reducers.js");
19
19
 
20
+ var _webpackHmr = require("./webpack-hmr.js");
21
+
20
22
  /* eslint-disable max-params */
21
23
  const rootReducer = (0, _reducers.createReducer)();
22
24
  // global variable
@@ -54,20 +56,7 @@ const createStore = (initialState, sagaMiddleware, history, middlewareConfig = {
54
56
  preloadedState: initialState,
55
57
  enhancers
56
58
  });
57
- let hotModule = null;
58
-
59
- try {
60
- var _module;
61
-
62
- hotModule = (_module = module) === null || _module === void 0 ? void 0 : _module.hot;
63
- } catch (err) {}
64
-
65
- if (hotModule) {
66
- hotModule.accept('./reducers', () => {
67
- (0, _reduxInjectors.forceReducerReload)(baseStore);
68
- });
69
- }
70
-
59
+ (0, _webpackHmr.enableHotReloading)(baseStore);
71
60
  return baseStore;
72
61
  };
73
62
 
@@ -0,0 +1,33 @@
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
6
+ exports.enableHotReloading = void 0;
7
+
8
+ var _reduxInjectors = require("redux-injectors");
9
+
10
+ // eslint-disable-next-line @typescript-eslint/ban-types
11
+ const enableHotReloading = baseStore => {
12
+ let hotModule = null;
13
+
14
+ try {
15
+ var _module;
16
+
17
+ hotModule = (_module = module) === null || _module === void 0 ? void 0 : _module.hot;
18
+ } catch (err) {
19
+ var _import$meta;
20
+
21
+ // eslint-disable-next-line @typescript-eslint/ban-ts-comment
22
+ // @ts-ignore
23
+ hotModule = (_import$meta = import.meta) === null || _import$meta === void 0 ? void 0 : _import$meta.webpackHot;
24
+ }
25
+
26
+ if (hotModule) {
27
+ hotModule.accept('./reducers', () => {
28
+ (0, _reduxInjectors.forceReducerReload)(baseStore);
29
+ });
30
+ }
31
+ };
32
+
33
+ exports.enableHotReloading = enableHotReloading;
package/dist/cjs/index.js CHANGED
@@ -43,6 +43,7 @@ var _exportNames = {
43
43
  setAppConfigValue: true,
44
44
  setAppConfig: true,
45
45
  getMicroFrontEndAppConfig: true,
46
+ getLogger: true,
46
47
  loadAppConfig: true,
47
48
  AppRoot: true,
48
49
  ErrorBoundary: true,
@@ -379,6 +380,12 @@ Object.defineProperty(exports, "getHostAppDataByKey", {
379
380
  return _store2.getHostAppDataByKey;
380
381
  }
381
382
  });
383
+ Object.defineProperty(exports, "getLogger", {
384
+ enumerable: true,
385
+ get: function () {
386
+ return _index8.getLogger;
387
+ }
388
+ });
382
389
  Object.defineProperty(exports, "getMicroFrontEndAppConfig", {
383
390
  enumerable: true,
384
391
  get: function () {
@@ -16,8 +16,10 @@ function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj &&
16
16
  const onPageView = pageTitle => {
17
17
  try {
18
18
  if (brum && pageTitle) {
19
- brum.setCustomVirtualPageName(pageTitle);
20
- brum.startVirtualPageMonitoringWithAutoEnd(pageTitle);
19
+ var _brum$setCustomVirtua, _brum$startVirtualPag;
20
+
21
+ (_brum$setCustomVirtua = brum.setCustomVirtualPageName) === null || _brum$setCustomVirtua === void 0 ? void 0 : _brum$setCustomVirtua.call(brum, pageTitle);
22
+ (_brum$startVirtualPag = brum.startVirtualPageMonitoringWithAutoEnd) === null || _brum$startVirtualPag === void 0 ? void 0 : _brum$startVirtualPag.call(brum, pageTitle);
21
23
  }
22
24
  } catch {// eslint-disable-next-line no-empty
23
25
  }
@@ -3,7 +3,7 @@
3
3
  Object.defineProperty(exports, "__esModule", {
4
4
  value: true
5
5
  });
6
- exports.getParameters = exports.decorators = void 0;
6
+ exports.loaders = exports.getParameters = exports.decorators = void 0;
7
7
 
8
8
  var _addonConsole = require("@storybook/addon-console");
9
9
 
@@ -21,11 +21,6 @@ var _history = require("../history.js");
21
21
 
22
22
  require("@elliemae/ds-basic/css/dimsum.css");
23
23
 
24
- (async () => {
25
- // eslint-disable-next-line no-undef
26
- await (0, _index.loadAppConfig)(__webpack_public_path__);
27
- })();
28
-
29
24
  const theme = (0, _puiTheme.getDefaultTheme)();
30
25
  const store = (0, _store.createAppStore)({}, _history.browserHistory);
31
26
 
@@ -59,4 +54,9 @@ const getParameters = storyBookTheme => ({
59
54
 
60
55
  exports.getParameters = getParameters;
61
56
  const decorators = [consoleDecorator, appDecorator];
62
- exports.decorators = decorators;
57
+ exports.decorators = decorators;
58
+ const loaders = [async () => {
59
+ // eslint-disable-next-line no-undef, camelcase
60
+ await (0, _index.loadAppConfig)(__webpack_public_path__ || './');
61
+ }];
62
+ exports.loaders = loaders;
@@ -35,7 +35,6 @@ const InputMask = ({
35
35
  name,
36
36
  defaultValue = '',
37
37
  rules = {},
38
- mask,
39
38
  ...rest
40
39
  }) => /*#__PURE__*/(0, _jsx3.default)(_reactHookForm.Controller, {
41
40
  name: name,
@@ -12,7 +12,9 @@ export const setAppDynamicsUserData = params => {
12
12
  };
13
13
 
14
14
  if (brum) {
15
- brum.setCustomUserData(() => ({
15
+ var _brum$setCustomUserDa;
16
+
17
+ (_brum$setCustomUserDa = brum.setCustomUserData) === null || _brum$setCustomUserDa === void 0 ? void 0 : _brum$setCustomUserDa.call(brum, () => ({
16
18
  userData
17
19
  }));
18
20
  }
@@ -1,10 +1,10 @@
1
1
  /* eslint-disable max-params */
2
- // @strip-block
3
2
  import { configureStore } from '@reduxjs/toolkit';
4
- import { createInjectorsEnhancer, forceReducerReload } from 'redux-injectors';
3
+ import { createInjectorsEnhancer } from 'redux-injectors';
5
4
  import { routerMiddleware } from 'connected-react-router';
6
5
  import createSagaMiddleware from 'redux-saga';
7
6
  import { createReducer } from "./reducers.js";
7
+ import { enableHotReloading } from "./webpack-hmr.js";
8
8
  const rootReducer = createReducer();
9
9
  // global variable
10
10
  let appStore = null;
@@ -35,27 +35,7 @@ const createStore = (initialState, sagaMiddleware, history, middlewareConfig = {
35
35
  preloadedState: initialState,
36
36
  enhancers
37
37
  });
38
- let hotModule = null;
39
-
40
- try {
41
- var _module;
42
-
43
- hotModule = (_module = module) === null || _module === void 0 ? void 0 : _module.hot;
44
- } catch (err) {
45
- var _import$meta;
46
-
47
- // eslint-disable-next-line @typescript-eslint/ban-ts-comment
48
- // @ts-ignore
49
- // block:start
50
- hotModule = (_import$meta = import.meta) === null || _import$meta === void 0 ? void 0 : _import$meta.webpackHot; // block:end
51
- }
52
-
53
- if (hotModule) {
54
- hotModule.accept('./reducers', () => {
55
- forceReducerReload(baseStore);
56
- });
57
- }
58
-
38
+ enableHotReloading(baseStore);
59
39
  return baseStore;
60
40
  };
61
41
 
@@ -0,0 +1,23 @@
1
+ import { forceReducerReload } from 'redux-injectors'; // eslint-disable-next-line @typescript-eslint/ban-types
2
+
3
+ export const enableHotReloading = baseStore => {
4
+ let hotModule = null;
5
+
6
+ try {
7
+ var _module;
8
+
9
+ hotModule = (_module = module) === null || _module === void 0 ? void 0 : _module.hot;
10
+ } catch (err) {
11
+ var _import$meta;
12
+
13
+ // eslint-disable-next-line @typescript-eslint/ban-ts-comment
14
+ // @ts-ignore
15
+ hotModule = (_import$meta = import.meta) === null || _import$meta === void 0 ? void 0 : _import$meta.webpackHot;
16
+ }
17
+
18
+ if (hotModule) {
19
+ hotModule.accept('./reducers', () => {
20
+ forceReducerReload(baseStore);
21
+ });
22
+ }
23
+ };
package/dist/es/index.js CHANGED
@@ -24,7 +24,7 @@ export { CMicroAppGuest } from "./utils/micro-frontend/guest.js";
24
24
  export { CMicroAppHost } from "./utils/micro-frontend/host.js";
25
25
  export { enableReactAppForHostIntegration } from "./utils/app-host-integration/react.js";
26
26
  export { getAppConfigValue, setAppConfigValue, setAppConfig } from "./utils/app-config/config.js";
27
- export { getMicroFrontEndAppConfig } from "./utils/micro-frontend/index.js";
27
+ export { getMicroFrontEndAppConfig, getLogger } from "./utils/micro-frontend/index.js";
28
28
  export { loadAppConfig } from "./utils/app-config/index.js";
29
29
  export { AppRoot } from "./view/app-root/index.js";
30
30
  export { ErrorBoundary } from "./view/error-boundary/index.js";
@@ -3,8 +3,10 @@ import { pageViewEvent } from "../analytics/page-view-event.js";
3
3
  export const onPageView = pageTitle => {
4
4
  try {
5
5
  if (brum && pageTitle) {
6
- brum.setCustomVirtualPageName(pageTitle);
7
- brum.startVirtualPageMonitoringWithAutoEnd(pageTitle);
6
+ var _brum$setCustomVirtua, _brum$startVirtualPag;
7
+
8
+ (_brum$setCustomVirtua = brum.setCustomVirtualPageName) === null || _brum$setCustomVirtua === void 0 ? void 0 : _brum$setCustomVirtua.call(brum, pageTitle);
9
+ (_brum$startVirtualPag = brum.startVirtualPageMonitoringWithAutoEnd) === null || _brum$startVirtualPag === void 0 ? void 0 : _brum$startVirtualPag.call(brum, pageTitle);
8
10
  }
9
11
  } catch {// eslint-disable-next-line no-empty
10
12
  }
@@ -6,12 +6,6 @@ import { loadAppConfig } from "../app-config/index.js";
6
6
  import { createTheme } from "./theme.js";
7
7
  import { browserHistory } from "../history.js";
8
8
  import '@elliemae/ds-basic/css/dimsum.css';
9
-
10
- (async () => {
11
- // eslint-disable-next-line no-undef
12
- await loadAppConfig(__webpack_public_path__);
13
- })();
14
-
15
9
  const theme = getDefaultTheme();
16
10
  const store = createAppStore({}, browserHistory);
17
11
  const appDecorator = withAppDecorator.bind(null, theme, store);
@@ -41,4 +35,8 @@ export const getParameters = storyBookTheme => ({
41
35
  hideEmpty: true
42
36
  }
43
37
  });
44
- export const decorators = [consoleDecorator, appDecorator];
38
+ export const decorators = [consoleDecorator, appDecorator];
39
+ export const loaders = [async () => {
40
+ // eslint-disable-next-line no-undef, camelcase
41
+ await loadAppConfig(__webpack_public_path__ || './');
42
+ }];
@@ -6,7 +6,6 @@ export const InputMask = ({
6
6
  name,
7
7
  defaultValue = '',
8
8
  rules = {},
9
- mask,
10
9
  ...rest
11
10
  }) => /*#__PURE__*/_jsx2(Controller, {
12
11
  name: name,
@@ -0,0 +1 @@
1
+ export declare const enableHotReloading: (baseStore: {}) => void;
@@ -23,7 +23,7 @@ export { CMicroAppGuest } from './utils/micro-frontend/guest';
23
23
  export { CMicroAppHost } from './utils/micro-frontend/host';
24
24
  export { enableReactAppForHostIntegration } from './utils/app-host-integration/react';
25
25
  export { getAppConfigValue, setAppConfigValue, setAppConfig, } from './utils/app-config/config';
26
- export { getMicroFrontEndAppConfig } from './utils/micro-frontend';
26
+ export { getMicroFrontEndAppConfig, getLogger } from './utils/micro-frontend';
27
27
  export { loadAppConfig } from './utils/app-config';
28
28
  export { AppRoot } from './view/app-root';
29
29
  export { ErrorBoundary } from './view/error-boundary';
@@ -22,3 +22,4 @@ export function getParameters(storyBookTheme: any): {
22
22
  };
23
23
  };
24
24
  export const decorators: (((story: () => import("react").ReactElement<any, string | import("react").JSXElementConstructor<any>>) => JSX.Element) | ((storyFn: any, context: any) => any))[];
25
+ export const loaders: (() => Promise<void>)[];
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@elliemae/pui-app-sdk",
3
- "version": "2.21.1",
3
+ "version": "2.21.5",
4
4
  "description": "ICE MT UI Platform Application SDK ",
5
5
  "sideEffects": [
6
6
  "*.css",
@@ -47,7 +47,7 @@
47
47
  "url": "http://git.elliemae.io/platform-ui/pui-app-sdk.git"
48
48
  },
49
49
  "engines": {
50
- "npm": ">=7",
50
+ "npm": ">=8",
51
51
  "node": ">=14"
52
52
  },
53
53
  "author": "ICE MT",
@@ -72,7 +72,7 @@
72
72
  "storybook:docs": "pui-cli storybook --docs",
73
73
  "storybook:docs:build": "pui-cli storybook -b --docs",
74
74
  "storybook:build": "pui-cli storybook -b",
75
- "storybook:prod": "npm run storybook:build && http-server -g -p 11000 demo",
75
+ "storybook:prod": "http-server -g -p 11000 demo",
76
76
  "setup": "rimraf -r node_modules && rimraf package-lock.json && npm i",
77
77
  "test": "pui-cli test -p",
78
78
  "test:fix": "pui-cli test -f",
@@ -89,37 +89,37 @@
89
89
  },
90
90
  "peerDependencies": {
91
91
  "@elliemae/app-react-dependencies": "^2.10.0",
92
- "@elliemae/ds-basic": "^2.0.0",
93
- "@elliemae/ds-button": "^2.0.0",
94
- "@elliemae/ds-form": "^2.0.0",
95
- "@elliemae/ds-loading-indicator": "^2.0.0",
96
- "@elliemae/ds-date-picker": "^2.0.0",
97
- "@elliemae/ds-modal": "^2.0.0",
98
- "@elliemae/ds-popperjs": "^2.0.0",
99
- "@elliemae/ds-toast": "^2.0.0",
92
+ "@elliemae/ds-basic": "^2.2.3",
93
+ "@elliemae/ds-button": "^2.2.3",
94
+ "@elliemae/ds-form": "^2.2.3",
95
+ "@elliemae/ds-loading-indicator": "^2.2.3",
96
+ "@elliemae/ds-date-picker": "^2.2.3",
97
+ "@elliemae/ds-modal": "^2.2.3",
98
+ "@elliemae/ds-popperjs": "^2.2.3",
99
+ "@elliemae/ds-toast": "^2.2.3",
100
100
  "@elliemae/em-ssf-guest": "^1.11.1",
101
101
  "@elliemae/pui-diagnostics": "^2.7.3",
102
- "@elliemae/pui-micro-frontend-base": "^1.10.0",
102
+ "@elliemae/pui-micro-frontend-base": "^1.10.1",
103
103
  "@elliemae/pui-theme": "^2.3.0",
104
- "@elliemae/pui-user-monitoring": "^1.12.2"
104
+ "@elliemae/pui-user-monitoring": "^1.13.0"
105
105
  },
106
106
  "devDependencies": {
107
107
  "@elliemae/app-react-dependencies": "~2.10.0",
108
108
  "@elliemae/browserslist-config-elliemae-latest-browsers": "~1.2.1",
109
- "@elliemae/ds-basic": "~2.0.0",
110
- "@elliemae/ds-button": "~2.0.0",
111
- "@elliemae/ds-form": "~2.0.0",
112
- "@elliemae/ds-loading-indicator": "~2.0.0",
113
- "@elliemae/ds-date-picker": "~2.0.0",
114
- "@elliemae/ds-modal": "~2.0.0",
115
- "@elliemae/ds-popperjs": "~2.0.0",
116
- "@elliemae/ds-toast": "~2.0.0",
109
+ "@elliemae/ds-basic": "~2.2.3",
110
+ "@elliemae/ds-button": "~2.2.3",
111
+ "@elliemae/ds-form": "~2.2.3",
112
+ "@elliemae/ds-loading-indicator": "~2.2.3",
113
+ "@elliemae/ds-date-picker": "~2.2.3",
114
+ "@elliemae/ds-modal": "~2.2.3",
115
+ "@elliemae/ds-popperjs": "~2.2.3",
116
+ "@elliemae/ds-toast": "~2.2.3",
117
117
  "@elliemae/em-ssf-guest": "~1.11.1",
118
- "@elliemae/pui-cli": "~5.23.0",
118
+ "@elliemae/pui-cli": "~5.26.2",
119
119
  "@elliemae/pui-diagnostics": "~2.7.3",
120
- "@elliemae/pui-e2e-test-sdk": "~6.8.0",
121
- "@elliemae/pui-micro-frontend-base": "~1.10.0",
120
+ "@elliemae/pui-e2e-test-sdk": "~6.10.0",
121
+ "@elliemae/pui-micro-frontend-base": "~1.10.1",
122
122
  "@elliemae/pui-theme": "~2.3.0",
123
- "@elliemae/pui-user-monitoring": "~1.12.2"
123
+ "@elliemae/pui-user-monitoring": "~1.13.0"
124
124
  }
125
125
  }