@genesislcap/pbc-notify-ui 1.0.1 → 1.0.3
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/README.md +17 -11
- package/dist/dts/components/components.d.ts.map +1 -1
- package/dist/dts/components/foundation-inbox/components/components.d.ts.map +1 -1
- package/dist/dts/components/foundation-inbox/components/foundation-inbox-counter/foundation-inbox-counter.d.ts +0 -3
- package/dist/dts/components/foundation-inbox/components/foundation-inbox-counter/foundation-inbox-counter.d.ts.map +1 -1
- package/dist/dts/components/foundation-inbox/inbox.d.ts +24 -26
- package/dist/dts/components/foundation-inbox/inbox.d.ts.map +1 -1
- package/dist/dts/components/foundation-inbox/inbox.styles.d.ts.map +1 -1
- package/dist/dts/components/foundation-inbox/inbox.template.d.ts.map +1 -1
- package/dist/dts/components/foundation-inbox/inbox.types.d.ts +11 -64
- package/dist/dts/components/foundation-inbox/inbox.types.d.ts.map +1 -1
- package/dist/dts/components/foundation-inbox/inbox.utils.d.ts +7 -6
- package/dist/dts/components/foundation-inbox/inbox.utils.d.ts.map +1 -1
- package/dist/dts/components/foundation-notification-dashboard/components/condition-builder/condition-builder.d.ts.map +1 -1
- package/dist/dts/components/foundation-notification-dashboard/components/parameter-builder/parameter-builder.template.d.ts.map +1 -1
- package/dist/dts/components/foundation-notification-dashboard/components/rule-dialog/rule-condition-builder/rule-condition-builder.d.ts +1 -1
- package/dist/dts/components/foundation-notification-dashboard/components/rule-dialog/rule-condition-builder/rule-condition-builder.d.ts.map +1 -1
- package/dist/dts/components/foundation-notification-dashboard/components/rule-dialog/rule-condition-builder/rule-condition-builder.template.d.ts.map +1 -1
- package/dist/dts/components/foundation-notification-dashboard/components/rule-dialog/rule-dialog.d.ts +2 -10
- package/dist/dts/components/foundation-notification-dashboard/components/rule-dialog/rule-dialog.d.ts.map +1 -1
- package/dist/dts/components/foundation-notification-dashboard/components/rule-dialog/rule-dialog.styles.d.ts.map +1 -1
- package/dist/dts/components/foundation-notification-dashboard/components/rule-dialog/rule-dialog.template.d.ts.map +1 -1
- package/dist/dts/components/foundation-notification-dashboard/components/rule-dialog/rule-dialog.types.d.ts +2 -2
- package/dist/dts/components/foundation-notification-dashboard/components/rule-dialog/rule-dialog.types.d.ts.map +1 -1
- package/dist/dts/components/foundation-notification-dashboard/components/template-dialog/template-dialog.d.ts +16 -31
- package/dist/dts/components/foundation-notification-dashboard/components/template-dialog/template-dialog.d.ts.map +1 -1
- package/dist/dts/components/foundation-notification-dashboard/components/template-dialog/template-dialog.styles.d.ts.map +1 -1
- package/dist/dts/components/foundation-notification-dashboard/components/template-dialog/template-dialog.template.d.ts.map +1 -1
- package/dist/dts/components/foundation-notification-dashboard/components/template-dialog/template-dialog.types.d.ts +8 -7
- package/dist/dts/components/foundation-notification-dashboard/components/template-dialog/template-dialog.types.d.ts.map +1 -1
- package/dist/dts/components/foundation-notification-dashboard/components/template-dialog/template-dialog.utils.d.ts +39 -0
- package/dist/dts/components/foundation-notification-dashboard/components/template-dialog/template-dialog.utils.d.ts.map +1 -1
- package/dist/dts/components/foundation-notification-dashboard/management/management.styles.d.ts +1 -0
- package/dist/dts/components/foundation-notification-dashboard/management/management.styles.d.ts.map +1 -1
- package/dist/dts/components/foundation-notification-dashboard/management/notify-audit-management.d.ts.map +1 -1
- package/dist/dts/components/foundation-notification-dashboard/management/rule-management.d.ts.map +1 -1
- package/dist/dts/components/foundation-notification-dashboard/management/rule-template-management.d.ts +5 -5
- package/dist/dts/components/foundation-notification-dashboard/management/rule-template-management.d.ts.map +1 -1
- package/dist/dts/components/foundation-notification-dashboard/management/screen-route-management.d.ts.map +1 -1
- package/dist/dts/components/foundation-notification-dashboard/notification-dashboard.d.ts.map +1 -1
- package/dist/dts/components/foundation-notification-dashboard/types/severity.d.ts +2 -2
- package/dist/dts/components/foundation-notification-dashboard/types/severity.d.ts.map +1 -1
- package/dist/dts/services/alert.service.d.ts.map +1 -1
- package/dist/dts/services/notify.service.d.ts +1 -1
- package/dist/dts/services/notify.service.d.ts.map +1 -1
- package/dist/dts/services/rule-template.service.d.ts +2 -0
- package/dist/dts/services/rule-template.service.d.ts.map +1 -1
- package/dist/dts/services/system.service.d.ts.map +1 -1
- package/dist/esm/components/components.js +0 -2
- package/dist/esm/components/foundation-inbox/components/components.js +1 -3
- package/dist/esm/components/foundation-inbox/components/foundation-inbox-counter/foundation-inbox-counter.js +0 -9
- package/dist/esm/components/foundation-inbox/inbox.js +97 -82
- package/dist/esm/components/foundation-inbox/inbox.styles.js +4 -2
- package/dist/esm/components/foundation-inbox/inbox.template.js +159 -164
- package/dist/esm/components/foundation-inbox/inbox.types.js +0 -4
- package/dist/esm/components/foundation-inbox/inbox.utils.js +47 -29
- package/dist/esm/components/foundation-notification-dashboard/components/condition-builder/condition-builder.js +0 -3
- package/dist/esm/components/foundation-notification-dashboard/components/condition-builder/condition-builder.styles.js +4 -4
- package/dist/esm/components/foundation-notification-dashboard/components/parameter-builder/parameter-builder.styles.js +4 -4
- package/dist/esm/components/foundation-notification-dashboard/components/parameter-builder/parameter-builder.template.js +2 -0
- package/dist/esm/components/foundation-notification-dashboard/components/rule-dialog/rule-condition-builder/rule-condition-builder.js +21 -11
- package/dist/esm/components/foundation-notification-dashboard/components/rule-dialog/rule-condition-builder/rule-condition-builder.styles.js +4 -4
- package/dist/esm/components/foundation-notification-dashboard/components/rule-dialog/rule-condition-builder/rule-condition-builder.template.js +4 -2
- package/dist/esm/components/foundation-notification-dashboard/components/rule-dialog/rule-dialog.js +34 -95
- package/dist/esm/components/foundation-notification-dashboard/components/rule-dialog/rule-dialog.styles.js +32 -12
- package/dist/esm/components/foundation-notification-dashboard/components/rule-dialog/rule-dialog.template.js +35 -30
- package/dist/esm/components/foundation-notification-dashboard/components/template-dialog/template-dialog.js +110 -157
- package/dist/esm/components/foundation-notification-dashboard/components/template-dialog/template-dialog.styles.js +40 -41
- package/dist/esm/components/foundation-notification-dashboard/components/template-dialog/template-dialog.template.js +70 -17
- package/dist/esm/components/foundation-notification-dashboard/components/template-dialog/template-dialog.utils.js +85 -2
- package/dist/esm/components/foundation-notification-dashboard/management/management.styles.js +23 -0
- package/dist/esm/components/foundation-notification-dashboard/management/notify-audit-management.js +8 -2
- package/dist/esm/components/foundation-notification-dashboard/management/rule-management.js +39 -28
- package/dist/esm/components/foundation-notification-dashboard/management/rule-template-management.js +64 -59
- package/dist/esm/components/foundation-notification-dashboard/management/screen-route-management.js +2 -1
- package/dist/esm/components/foundation-notification-dashboard/notification-dashboard.js +1 -1
- package/dist/esm/components/foundation-notification-dashboard/notification-dashboard.styles.js +1 -1
- package/dist/esm/components/foundation-notification-dashboard/types/severity.js +3 -3
- package/dist/esm/services/alert.service.js +15 -11
- package/dist/esm/services/notify.service.js +5 -6
- package/dist/esm/services/rule-template.service.js +34 -9
- package/package.json +2 -1
- package/dist/dts/components/foundation-alerts/alerts.config.d.ts +0 -64
- package/dist/dts/components/foundation-alerts/alerts.config.d.ts.map +0 -1
- package/dist/dts/components/foundation-alerts/alerts.d.ts +0 -74
- package/dist/dts/components/foundation-alerts/alerts.d.ts.map +0 -1
- package/dist/dts/components/foundation-alerts/alerts.template.d.ts +0 -10
- package/dist/dts/components/foundation-alerts/alerts.template.d.ts.map +0 -1
- package/dist/dts/components/foundation-alerts/alerts.types.d.ts +0 -72
- package/dist/dts/components/foundation-alerts/alerts.types.d.ts.map +0 -1
- package/dist/dts/components/foundation-alerts/components/foundation-alerts-condition-builder/foundation-alerts-condition-builder.config.d.ts +0 -9
- package/dist/dts/components/foundation-alerts/components/foundation-alerts-condition-builder/foundation-alerts-condition-builder.config.d.ts.map +0 -1
- package/dist/dts/components/foundation-alerts/components/foundation-alerts-condition-builder/foundation-alerts-condition-builder.d.ts +0 -37
- package/dist/dts/components/foundation-alerts/components/foundation-alerts-condition-builder/foundation-alerts-condition-builder.d.ts.map +0 -1
- package/dist/dts/components/foundation-alerts/components/foundation-alerts-condition-builder/foundation-alerts-condition-builder.styles.d.ts +0 -2
- package/dist/dts/components/foundation-alerts/components/foundation-alerts-condition-builder/foundation-alerts-condition-builder.styles.d.ts.map +0 -1
- package/dist/dts/components/foundation-alerts/components/foundation-alerts-condition-builder/foundation-alerts-condition-builder.template.d.ts +0 -4
- package/dist/dts/components/foundation-alerts/components/foundation-alerts-condition-builder/foundation-alerts-condition-builder.template.d.ts.map +0 -1
- package/dist/dts/components/foundation-alerts/components/foundation-alerts-condition-builder/foundation-alerts-condition-builder.types.d.ts +0 -28
- package/dist/dts/components/foundation-alerts/components/foundation-alerts-condition-builder/foundation-alerts-condition-builder.types.d.ts.map +0 -1
- package/dist/dts/components/foundation-alerts/components/foundation-alerts-form/foundation-alerts-form.d.ts +0 -30
- package/dist/dts/components/foundation-alerts/components/foundation-alerts-form/foundation-alerts-form.d.ts.map +0 -1
- package/dist/dts/components/foundation-alerts/components/foundation-alerts-form/foundation-alerts-form.styles.d.ts +0 -2
- package/dist/dts/components/foundation-alerts/components/foundation-alerts-form/foundation-alerts-form.styles.d.ts.map +0 -1
- package/dist/dts/components/foundation-alerts/components/foundation-alerts-form/foundation-alerts-form.template.d.ts +0 -4
- package/dist/dts/components/foundation-alerts/components/foundation-alerts-form/foundation-alerts-form.template.d.ts.map +0 -1
- package/dist/dts/components/foundation-alerts/components/foundation-alerts-navigation-button/foundation-alerts-navigation-button.d.ts +0 -8
- package/dist/dts/components/foundation-alerts/components/foundation-alerts-navigation-button/foundation-alerts-navigation-button.d.ts.map +0 -1
- package/dist/dts/components/foundation-alerts/components/foundation-alerts-navigation-button/foundation-alerts-navigation-button.styles.d.ts +0 -2
- package/dist/dts/components/foundation-alerts/components/foundation-alerts-navigation-button/foundation-alerts-navigation-button.styles.d.ts.map +0 -1
- package/dist/dts/components/foundation-alerts/components/foundation-alerts-navigation-button/foundation-alerts-navigation-button.template.d.ts +0 -4
- package/dist/dts/components/foundation-alerts/components/foundation-alerts-navigation-button/foundation-alerts-navigation-button.template.d.ts.map +0 -1
- package/dist/dts/components/foundation-alerts/components/index.d.ts +0 -5
- package/dist/dts/components/foundation-alerts/components/index.d.ts.map +0 -1
- package/dist/dts/components/foundation-alerts/index.d.ts +0 -2
- package/dist/dts/components/foundation-alerts/index.d.ts.map +0 -1
- package/dist/dts/components/foundation-alerts/index.federated.d.ts +0 -1
- package/dist/dts/components/foundation-alerts/index.federated.d.ts.map +0 -1
- package/dist/dts/components/foundation-alerts/styles/index.d.ts +0 -2
- package/dist/dts/components/foundation-alerts/styles/index.d.ts.map +0 -1
- package/dist/dts/components/foundation-alerts/styles/styles.d.ts +0 -5
- package/dist/dts/components/foundation-alerts/styles/styles.d.ts.map +0 -1
- package/dist/dts/components/foundation-alerts/utils/getConditionObject.d.ts +0 -8
- package/dist/dts/components/foundation-alerts/utils/getConditionObject.d.ts.map +0 -1
- package/dist/dts/components/foundation-alerts/utils/getDateMilliseconds.d.ts +0 -2
- package/dist/dts/components/foundation-alerts/utils/getDateMilliseconds.d.ts.map +0 -1
- package/dist/dts/components/foundation-alerts/utils/getDateStringFormat.d.ts +0 -2
- package/dist/dts/components/foundation-alerts/utils/getDateStringFormat.d.ts.map +0 -1
- package/dist/dts/components/foundation-alerts/utils/index.d.ts +0 -5
- package/dist/dts/components/foundation-alerts/utils/index.d.ts.map +0 -1
- package/dist/dts/components/foundation-alerts/utils/logger.d.ts +0 -2
- package/dist/dts/components/foundation-alerts/utils/logger.d.ts.map +0 -1
- package/dist/dts/components/foundation-inbox/components/foundation-inbox-toast/foundation-inbox-toast.d.ts +0 -10
- package/dist/dts/components/foundation-inbox/components/foundation-inbox-toast/foundation-inbox-toast.d.ts.map +0 -1
- package/dist/dts/components/foundation-inbox/components/foundation-inbox-toast/foundation-inbox-toast.styles.d.ts +0 -2
- package/dist/dts/components/foundation-inbox/components/foundation-inbox-toast/foundation-inbox-toast.styles.d.ts.map +0 -1
- package/dist/dts/components/foundation-inbox/inbox.config.d.ts +0 -6
- package/dist/dts/components/foundation-inbox/inbox.config.d.ts.map +0 -1
- package/dist/dts/components/foundation-inbox/layouts/default.d.ts +0 -3
- package/dist/dts/components/foundation-inbox/layouts/default.d.ts.map +0 -1
- package/dist/dts/components/foundation-inbox/layouts/index.d.ts +0 -2
- package/dist/dts/components/foundation-inbox/layouts/index.d.ts.map +0 -1
- package/dist/dts/components/foundation-inbox/services/foundation-inbox.service.d.ts +0 -11
- package/dist/dts/components/foundation-inbox/services/foundation-inbox.service.d.ts.map +0 -1
- package/dist/dts/components/foundation-inbox/styles/index.d.ts +0 -2
- package/dist/dts/components/foundation-inbox/styles/index.d.ts.map +0 -1
- package/dist/dts/components/foundation-inbox/styles/styles.d.ts +0 -3
- package/dist/dts/components/foundation-inbox/styles/styles.d.ts.map +0 -1
- package/dist/dts/components/foundation-inbox/utils/getSeverityByMessageType.d.ts +0 -3
- package/dist/dts/components/foundation-inbox/utils/getSeverityByMessageType.d.ts.map +0 -1
- package/dist/dts/components/foundation-inbox/utils/index.d.ts +0 -4
- package/dist/dts/components/foundation-inbox/utils/index.d.ts.map +0 -1
- package/dist/dts/components/foundation-inbox/utils/logger.d.ts +0 -2
- package/dist/dts/components/foundation-inbox/utils/logger.d.ts.map +0 -1
- package/dist/dts/components/foundation-inbox/utils/transformMessageToNotify.d.ts +0 -3
- package/dist/dts/components/foundation-inbox/utils/transformMessageToNotify.d.ts.map +0 -1
- package/dist/dts/layouts/default.d.ts +0 -3
- package/dist/dts/layouts/default.d.ts.map +0 -1
- package/dist/dts/layouts/index.d.ts +0 -2
- package/dist/dts/layouts/index.d.ts.map +0 -1
- package/dist/dts/styles/index.d.ts +0 -2
- package/dist/dts/styles/index.d.ts.map +0 -1
- package/dist/dts/styles/styles.d.ts +0 -3
- package/dist/dts/styles/styles.d.ts.map +0 -1
- package/dist/esm/components/foundation-alerts/alerts.config.js +0 -78
- package/dist/esm/components/foundation-alerts/alerts.js +0 -246
- package/dist/esm/components/foundation-alerts/alerts.template.js +0 -82
- package/dist/esm/components/foundation-alerts/alerts.types.js +0 -18
- package/dist/esm/components/foundation-alerts/components/foundation-alerts-condition-builder/foundation-alerts-condition-builder.config.js +0 -52
- package/dist/esm/components/foundation-alerts/components/foundation-alerts-condition-builder/foundation-alerts-condition-builder.js +0 -182
- package/dist/esm/components/foundation-alerts/components/foundation-alerts-condition-builder/foundation-alerts-condition-builder.styles.js +0 -68
- package/dist/esm/components/foundation-alerts/components/foundation-alerts-condition-builder/foundation-alerts-condition-builder.template.js +0 -135
- package/dist/esm/components/foundation-alerts/components/foundation-alerts-condition-builder/foundation-alerts-condition-builder.types.js +0 -1
- package/dist/esm/components/foundation-alerts/components/foundation-alerts-form/foundation-alerts-form.js +0 -145
- package/dist/esm/components/foundation-alerts/components/foundation-alerts-form/foundation-alerts-form.styles.js +0 -194
- package/dist/esm/components/foundation-alerts/components/foundation-alerts-form/foundation-alerts-form.template.js +0 -96
- package/dist/esm/components/foundation-alerts/components/foundation-alerts-navigation-button/foundation-alerts-navigation-button.js +0 -33
- package/dist/esm/components/foundation-alerts/components/foundation-alerts-navigation-button/foundation-alerts-navigation-button.styles.js +0 -27
- package/dist/esm/components/foundation-alerts/components/foundation-alerts-navigation-button/foundation-alerts-navigation-button.template.js +0 -14
- package/dist/esm/components/foundation-alerts/components/index.js +0 -52
- package/dist/esm/components/foundation-alerts/index.federated.js +0 -1
- package/dist/esm/components/foundation-alerts/index.js +0 -1
- package/dist/esm/components/foundation-alerts/styles/index.js +0 -1
- package/dist/esm/components/foundation-alerts/styles/styles.js +0 -198
- package/dist/esm/components/foundation-alerts/utils/getConditionObject.js +0 -24
- package/dist/esm/components/foundation-alerts/utils/getDateMilliseconds.js +0 -5
- package/dist/esm/components/foundation-alerts/utils/getDateStringFormat.js +0 -12
- package/dist/esm/components/foundation-alerts/utils/index.js +0 -4
- package/dist/esm/components/foundation-alerts/utils/logger.js +0 -2
- package/dist/esm/components/foundation-inbox/components/foundation-inbox-toast/foundation-inbox-toast.js +0 -42
- package/dist/esm/components/foundation-inbox/components/foundation-inbox-toast/foundation-inbox-toast.styles.js +0 -25
- package/dist/esm/components/foundation-inbox/inbox.config.js +0 -27
- package/dist/esm/components/foundation-inbox/layouts/default.js +0 -27
- package/dist/esm/components/foundation-inbox/layouts/index.js +0 -1
- package/dist/esm/components/foundation-inbox/services/foundation-inbox.service.js +0 -109
- package/dist/esm/components/foundation-inbox/styles/index.js +0 -1
- package/dist/esm/components/foundation-inbox/styles/styles.js +0 -13
- package/dist/esm/components/foundation-inbox/utils/getSeverityByMessageType.js +0 -4
- package/dist/esm/components/foundation-inbox/utils/index.js +0 -3
- package/dist/esm/components/foundation-inbox/utils/logger.js +0 -2
- package/dist/esm/components/foundation-inbox/utils/transformMessageToNotify.js +0 -12
- package/dist/esm/layouts/default.js +0 -27
- package/dist/esm/layouts/index.js +0 -1
- package/dist/esm/styles/index.js +0 -1
- package/dist/esm/styles/styles.js +0 -13
|
@@ -1,27 +0,0 @@
|
|
|
1
|
-
import { css } from '@microsoft/fast-element';
|
|
2
|
-
export const FoundationAlertsNavigationButtonStyles = css `
|
|
3
|
-
.button {
|
|
4
|
-
padding: calc(var(--design-unit) * 2px);
|
|
5
|
-
margin: 0;
|
|
6
|
-
background: none;
|
|
7
|
-
font-size: var(--type-ramp-base-font-size);
|
|
8
|
-
line-height: var(--type-ramp-base-line-height);
|
|
9
|
-
}
|
|
10
|
-
|
|
11
|
-
.button::part(icon) {
|
|
12
|
-
color: var(--neutral-color);
|
|
13
|
-
}
|
|
14
|
-
|
|
15
|
-
.button:hover {
|
|
16
|
-
background-color: var(--neutral-fill-hover);
|
|
17
|
-
}
|
|
18
|
-
|
|
19
|
-
.button:hover::part(icon) {
|
|
20
|
-
color: var(--neutral-foreground-rest);
|
|
21
|
-
}
|
|
22
|
-
|
|
23
|
-
.button::part(control) {
|
|
24
|
-
cursor: pointer;
|
|
25
|
-
padding: 0;
|
|
26
|
-
}
|
|
27
|
-
`;
|
|
@@ -1,14 +0,0 @@
|
|
|
1
|
-
import { html, when } from '@microsoft/fast-element';
|
|
2
|
-
export const FoundationAlertsNavigationButtonTemplate = (prefix = 'zero') => html `
|
|
3
|
-
<${prefix}-button class="button" @click=${(x) => x.handleChangeStateAction()}>
|
|
4
|
-
${when((x) => x.current === 'list', html `
|
|
5
|
-
<${prefix}-icon name="xmark" part="icon" size="lg"></${prefix}-icon>
|
|
6
|
-
`)}
|
|
7
|
-
${when((x) => x.current !== 'list', html `
|
|
8
|
-
<${prefix}-icon name="arrow-left" part="icon" size="lg"></${prefix}-icon>
|
|
9
|
-
`)}
|
|
10
|
-
</${prefix}-button
|
|
11
|
-
`;
|
|
12
|
-
export const FoundationAlertsConditionBuilderRenderer = html `
|
|
13
|
-
${(x) => FoundationAlertsNavigationButtonTemplate(x.prefix)}
|
|
14
|
-
`;
|
|
@@ -1,52 +0,0 @@
|
|
|
1
|
-
import { __awaiter } from "tslib";
|
|
2
|
-
import { logger } from '../utils';
|
|
3
|
-
import { FoundationAlertsConditionBuilder } from './foundation-alerts-condition-builder/foundation-alerts-condition-builder';
|
|
4
|
-
import { FoundationAlertsForm } from './foundation-alerts-form/foundation-alerts-form';
|
|
5
|
-
import { FoundationAlertsNavigationButton } from './foundation-alerts-navigation-button/foundation-alerts-navigation-button';
|
|
6
|
-
var ResourceType;
|
|
7
|
-
(function (ResourceType) {
|
|
8
|
-
ResourceType["LOCAL"] = "LOCAL";
|
|
9
|
-
ResourceType["REMOTE"] = "REMOTE";
|
|
10
|
-
})(ResourceType || (ResourceType = {}));
|
|
11
|
-
/**
|
|
12
|
-
* TODO: Think about sharing import functions across micro frontends.
|
|
13
|
-
*/
|
|
14
|
-
function loadZeroFallback() {
|
|
15
|
-
return import(
|
|
16
|
-
/* webpackMode: "lazy" */
|
|
17
|
-
'@genesislcap/foundation-zero');
|
|
18
|
-
}
|
|
19
|
-
/**
|
|
20
|
-
* Granular
|
|
21
|
-
*/
|
|
22
|
-
function loadZeroDesignSystem() {
|
|
23
|
-
return __awaiter(this, void 0, void 0, function* () {
|
|
24
|
-
let type = ResourceType.REMOTE;
|
|
25
|
-
try {
|
|
26
|
-
// @ts-ignore
|
|
27
|
-
return yield import('foundationZero/ZeroDesignSystem');
|
|
28
|
-
}
|
|
29
|
-
catch (e) {
|
|
30
|
-
type = ResourceType.LOCAL;
|
|
31
|
-
return yield loadZeroFallback();
|
|
32
|
-
}
|
|
33
|
-
finally {
|
|
34
|
-
logger.debug(`Using '${type}' version of foundationZero/ZeroDesignSystem`);
|
|
35
|
-
}
|
|
36
|
-
});
|
|
37
|
-
}
|
|
38
|
-
export function loadRemotes() {
|
|
39
|
-
return __awaiter(this, void 0, void 0, function* () {
|
|
40
|
-
const { registerZeroDesignSystem } = yield loadZeroDesignSystem();
|
|
41
|
-
return {
|
|
42
|
-
ZeroDesignSystem: registerZeroDesignSystem(),
|
|
43
|
-
};
|
|
44
|
-
});
|
|
45
|
-
}
|
|
46
|
-
/**
|
|
47
|
-
* Ensure tree shaking doesn't remove these
|
|
48
|
-
* Perhaps we keep these MFs style free, ie. they need to get wrapped to have style applied. Keeping it simple for now.
|
|
49
|
-
*/
|
|
50
|
-
FoundationAlertsForm;
|
|
51
|
-
FoundationAlertsNavigationButton;
|
|
52
|
-
FoundationAlertsConditionBuilder;
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import('./index');
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export * from './alerts';
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export * from './styles';
|
|
@@ -1,198 +0,0 @@
|
|
|
1
|
-
import { RapidColorHEX, NeutralRapidColorHEX } from '@genesislcap/foundation-zero';
|
|
2
|
-
import { css } from '@microsoft/fast-element';
|
|
3
|
-
const DEFAULT_DESIGN_UNIT = '4';
|
|
4
|
-
const DEFAULT_STROKE_WIDTH = '1';
|
|
5
|
-
const DEFAULT_BASE_HEIGHT_MULTIPLIER = '10';
|
|
6
|
-
const DEFAULT_CONTROL_CORNER_RADIUS = '4';
|
|
7
|
-
const DEFAULT_NEUTRAL_COLOR = RapidColorHEX.white;
|
|
8
|
-
const DEFAULT_NEUTRAL_FOREGROUND_REST = NeutralRapidColorHEX.grey;
|
|
9
|
-
/**
|
|
10
|
-
* @public
|
|
11
|
-
*/
|
|
12
|
-
export const FoundationAlertsStyles = css `
|
|
13
|
-
:host {
|
|
14
|
-
/*
|
|
15
|
-
--design-unit: ${DEFAULT_DESIGN_UNIT};
|
|
16
|
-
--base-height-multiplier: ${DEFAULT_BASE_HEIGHT_MULTIPLIER};
|
|
17
|
-
--stroke-width: ${DEFAULT_STROKE_WIDTH};
|
|
18
|
-
--control-corner-radius: ${DEFAULT_CONTROL_CORNER_RADIUS};
|
|
19
|
-
*/
|
|
20
|
-
--neutral-color: ${DEFAULT_NEUTRAL_COLOR};
|
|
21
|
-
--neutral-foreground-rest: ${DEFAULT_NEUTRAL_FOREGROUND_REST};
|
|
22
|
-
--neutral-stroke-rest: ${DEFAULT_NEUTRAL_FOREGROUND_REST};
|
|
23
|
-
}
|
|
24
|
-
|
|
25
|
-
.wrapper {
|
|
26
|
-
width: 100%;
|
|
27
|
-
height: 100%;
|
|
28
|
-
display: flex;
|
|
29
|
-
flex-direction: column;
|
|
30
|
-
--available-text-color: ${RapidColorHEX.green};
|
|
31
|
-
--unavailable-text-color: ${RapidColorHEX.red};
|
|
32
|
-
}
|
|
33
|
-
|
|
34
|
-
header {
|
|
35
|
-
font-size: 0;
|
|
36
|
-
justify-content: right;
|
|
37
|
-
display: flex;
|
|
38
|
-
padding:
|
|
39
|
-
calc(var(--design-unit) * 3px)
|
|
40
|
-
calc(var(--design-unit) * 1px)
|
|
41
|
-
0
|
|
42
|
-
calc(var(--design-unit) * 1px);
|
|
43
|
-
}
|
|
44
|
-
|
|
45
|
-
.wrapper-content {
|
|
46
|
-
width: 100%;
|
|
47
|
-
overflow: hidden;
|
|
48
|
-
flex-grow: 1;
|
|
49
|
-
}
|
|
50
|
-
|
|
51
|
-
.wrapper-content-scroll {
|
|
52
|
-
height: 100%;
|
|
53
|
-
overflow-y: auto;
|
|
54
|
-
}
|
|
55
|
-
|
|
56
|
-
foundation-alerts-rule-navigation-button {
|
|
57
|
-
position: right;
|
|
58
|
-
}
|
|
59
|
-
|
|
60
|
-
.list-header {
|
|
61
|
-
width: calc(100% - (var(--design-unit) * 5px - var(--design-unit) * 3px));
|
|
62
|
-
display: flex;
|
|
63
|
-
align-items: center;
|
|
64
|
-
padding:
|
|
65
|
-
calc(var(--design-unit) * 2px)
|
|
66
|
-
calc(var(--design-unit) * 3px)
|
|
67
|
-
calc(var(--design-unit) * 2px)
|
|
68
|
-
calc(var(--design-unit) * 5px);
|
|
69
|
-
}
|
|
70
|
-
|
|
71
|
-
.list-header .main-button {
|
|
72
|
-
margin: 0;
|
|
73
|
-
min-width: 25px;
|
|
74
|
-
min-height: 25px;
|
|
75
|
-
color: var(--neutral-fill-strong-rest);
|
|
76
|
-
}
|
|
77
|
-
|
|
78
|
-
.list-header .main-button::part(actions-container) {
|
|
79
|
-
position: relative;
|
|
80
|
-
}
|
|
81
|
-
|
|
82
|
-
.list-header .main-button::part(actions-container),
|
|
83
|
-
.list-header .main-button::part(actions-opener) {
|
|
84
|
-
height: 100%;
|
|
85
|
-
}
|
|
86
|
-
|
|
87
|
-
.list-header .main-button::part(actions-opener) {
|
|
88
|
-
color: var(--neutral-fill-strong-rest);
|
|
89
|
-
margin: 0;
|
|
90
|
-
}
|
|
91
|
-
|
|
92
|
-
.list-header .main-button::part(control) {
|
|
93
|
-
height: 100%;
|
|
94
|
-
}
|
|
95
|
-
|
|
96
|
-
.list-header .main-button::part(actions-menu) {
|
|
97
|
-
top: calc(100% + var(--design-unit) * 1px);
|
|
98
|
-
right: 0;
|
|
99
|
-
}
|
|
100
|
-
|
|
101
|
-
.title {
|
|
102
|
-
padding: 0;
|
|
103
|
-
margin: 0;
|
|
104
|
-
font-size: calc(var(--design-unit) * 6px);
|
|
105
|
-
font-weight: 500;
|
|
106
|
-
color: var(--neutral-color);
|
|
107
|
-
}
|
|
108
|
-
|
|
109
|
-
.main-menu {
|
|
110
|
-
display: flex;
|
|
111
|
-
margin-left: auto;
|
|
112
|
-
gap: calc(var(--design-unit) * 2px);
|
|
113
|
-
}
|
|
114
|
-
|
|
115
|
-
.list,
|
|
116
|
-
.item-title,
|
|
117
|
-
.item-bottom {
|
|
118
|
-
width: 100%;
|
|
119
|
-
}
|
|
120
|
-
|
|
121
|
-
.list {
|
|
122
|
-
padding: 0;
|
|
123
|
-
margin: 0;
|
|
124
|
-
list-style: none;
|
|
125
|
-
}
|
|
126
|
-
|
|
127
|
-
.item {
|
|
128
|
-
width: calc(100% - (var(--design-unit) * 3px) - (var(--design-unit) * 5px));
|
|
129
|
-
padding:
|
|
130
|
-
calc(var(--design-unit) * 4px)
|
|
131
|
-
calc(var(--design-unit) * 3px)
|
|
132
|
-
calc(var(--design-unit) * 4px)
|
|
133
|
-
calc(var(--design-unit) * 5px);
|
|
134
|
-
border-top: calc(var(--stroke-width) * 1px) solid var(--neutral-fill-hover);
|
|
135
|
-
color: var(--neutral-color);
|
|
136
|
-
}
|
|
137
|
-
|
|
138
|
-
.item:hover {
|
|
139
|
-
background-color: var(--neutral-fill-hover);
|
|
140
|
-
}
|
|
141
|
-
|
|
142
|
-
.item-title {
|
|
143
|
-
padding: 0;
|
|
144
|
-
font-size: calc(var(--design-unit) * 5px);
|
|
145
|
-
font-weight: 700;
|
|
146
|
-
}
|
|
147
|
-
|
|
148
|
-
.item-bottom {
|
|
149
|
-
display: flex;
|
|
150
|
-
flex-wrap: nowrap;
|
|
151
|
-
align-items: flex-start;
|
|
152
|
-
gap: calc(var(--design-unit) * 5px);
|
|
153
|
-
font-size: calc(var(--design-unit) * 5px);
|
|
154
|
-
}
|
|
155
|
-
|
|
156
|
-
.item-menu {
|
|
157
|
-
display: flex;
|
|
158
|
-
margin-left: auto;
|
|
159
|
-
gap: calc(var(--design-unit) * 5px);
|
|
160
|
-
}
|
|
161
|
-
|
|
162
|
-
.item-menu .button {
|
|
163
|
-
color: var(--neutral-stroke-active);
|
|
164
|
-
}
|
|
165
|
-
|
|
166
|
-
.item-menu .button:hover {
|
|
167
|
-
color: var(--neutral-stroke-focus);
|
|
168
|
-
}
|
|
169
|
-
|
|
170
|
-
.item-bottom .button {
|
|
171
|
-
background: none;
|
|
172
|
-
margin: 0;
|
|
173
|
-
min-width: auto;
|
|
174
|
-
}
|
|
175
|
-
|
|
176
|
-
.list-header .button::part(control),
|
|
177
|
-
.item-bottom .button::part(control) {
|
|
178
|
-
padding: 0;
|
|
179
|
-
}
|
|
180
|
-
|
|
181
|
-
.status.active {
|
|
182
|
-
color: var(--available-text-color);
|
|
183
|
-
}
|
|
184
|
-
|
|
185
|
-
.status.inactive {
|
|
186
|
-
color: var(--unavailable-text-color);
|
|
187
|
-
}
|
|
188
|
-
|
|
189
|
-
.empty {
|
|
190
|
-
font-size: 12px;
|
|
191
|
-
padding:
|
|
192
|
-
calc(var(--design-unit) * 4px)
|
|
193
|
-
calc(var(--design-unit) * 3px)
|
|
194
|
-
calc(var(--design-unit) * 4px)
|
|
195
|
-
calc(var(--design-unit) * 5px);
|
|
196
|
-
margin: 0;
|
|
197
|
-
}
|
|
198
|
-
`;
|
|
@@ -1,24 +0,0 @@
|
|
|
1
|
-
import { logger } from './logger';
|
|
2
|
-
// @tood fix after db will be ready
|
|
3
|
-
export function getConditionObject(alertRuleRow) {
|
|
4
|
-
let conditionMainType;
|
|
5
|
-
let conditionValueCondition;
|
|
6
|
-
let conditionValueType;
|
|
7
|
-
let conditionValue;
|
|
8
|
-
try {
|
|
9
|
-
const conditionData = JSON.parse(alertRuleRow['RULE_EXPRESSION']);
|
|
10
|
-
conditionMainType = conditionData.mainType;
|
|
11
|
-
conditionValueCondition = conditionData.valueCondition;
|
|
12
|
-
conditionValueType = conditionData.valueType;
|
|
13
|
-
conditionValue = conditionData.value;
|
|
14
|
-
}
|
|
15
|
-
catch (_a) {
|
|
16
|
-
logger.debug('conditionData is not valid JSON');
|
|
17
|
-
}
|
|
18
|
-
return {
|
|
19
|
-
conditionMainType,
|
|
20
|
-
conditionValueCondition,
|
|
21
|
-
conditionValueType,
|
|
22
|
-
conditionValue,
|
|
23
|
-
};
|
|
24
|
-
}
|
|
@@ -1,12 +0,0 @@
|
|
|
1
|
-
function to2Digits(num) {
|
|
2
|
-
return num.toString().padStart(2, '0');
|
|
3
|
-
}
|
|
4
|
-
export function getDateStringFormat(date) {
|
|
5
|
-
const dateObj = new Date(date);
|
|
6
|
-
const day = to2Digits(dateObj.getDate());
|
|
7
|
-
const month = to2Digits(dateObj.getMonth() + 1);
|
|
8
|
-
const year = dateObj.getFullYear();
|
|
9
|
-
const hours = to2Digits(dateObj.getHours());
|
|
10
|
-
const minutes = to2Digits(dateObj.getMinutes());
|
|
11
|
-
return `${[year, month, day].join('-')}T${[hours, minutes].join(':')}`;
|
|
12
|
-
}
|
|
@@ -1,42 +0,0 @@
|
|
|
1
|
-
import { __awaiter, __decorate } from "tslib";
|
|
2
|
-
import { Connect } from '@genesislcap/foundation-comms';
|
|
3
|
-
import { Toast, zeroToastTemplate } from '@genesislcap/foundation-zero';
|
|
4
|
-
import { customElement } from '@microsoft/fast-element';
|
|
5
|
-
import { FoundationInboxToastStyles } from './foundation-inbox-toast.styles';
|
|
6
|
-
let FoundationInboxToast = class FoundationInboxToast extends Toast {
|
|
7
|
-
connectedCallback() {
|
|
8
|
-
const _super = Object.create(null, {
|
|
9
|
-
connectedCallback: { get: () => super.connectedCallback }
|
|
10
|
-
});
|
|
11
|
-
return __awaiter(this, void 0, void 0, function* () {
|
|
12
|
-
_super.connectedCallback.call(this);
|
|
13
|
-
this.addEventListener('remove-toast', this.close);
|
|
14
|
-
});
|
|
15
|
-
}
|
|
16
|
-
close() {
|
|
17
|
-
super.close();
|
|
18
|
-
this.removeMessage(this.id);
|
|
19
|
-
}
|
|
20
|
-
removeMessage(ALERT_ID) {
|
|
21
|
-
this.connect.commitEvent('EVENT_DISMISS_NOTIFY_ALERT', {
|
|
22
|
-
DETAILS: {
|
|
23
|
-
ALERT_ID,
|
|
24
|
-
},
|
|
25
|
-
});
|
|
26
|
-
}
|
|
27
|
-
disconnectedCallback() {
|
|
28
|
-
super.disconnectedCallback();
|
|
29
|
-
this.removeEventListener('remove-toast', this.close);
|
|
30
|
-
}
|
|
31
|
-
};
|
|
32
|
-
__decorate([
|
|
33
|
-
Connect
|
|
34
|
-
], FoundationInboxToast.prototype, "connect", void 0);
|
|
35
|
-
FoundationInboxToast = __decorate([
|
|
36
|
-
customElement({
|
|
37
|
-
name: 'foundation-inbox-toast',
|
|
38
|
-
template: zeroToastTemplate,
|
|
39
|
-
styles: FoundationInboxToastStyles,
|
|
40
|
-
})
|
|
41
|
-
], FoundationInboxToast);
|
|
42
|
-
export { FoundationInboxToast };
|
|
@@ -1,25 +0,0 @@
|
|
|
1
|
-
import { zeroToastStyles } from '@genesislcap/foundation-zero';
|
|
2
|
-
import { css } from '@microsoft/fast-element';
|
|
3
|
-
export const FoundationInboxToastStyles = css `
|
|
4
|
-
${zeroToastStyles}
|
|
5
|
-
|
|
6
|
-
.toast {
|
|
7
|
-
--toast-min-width: none;
|
|
8
|
-
--toast-max-width: none;
|
|
9
|
-
|
|
10
|
-
width: calc(100% - (2 * var(--design-unit) * 5px));
|
|
11
|
-
background: transparent;
|
|
12
|
-
box-shadow: none;
|
|
13
|
-
margin: 0;
|
|
14
|
-
padding: calc(var(--design-unit) * 2px) calc(var(--design-unit) * 5px);
|
|
15
|
-
border: none;
|
|
16
|
-
}
|
|
17
|
-
|
|
18
|
-
.toast .close-icon {
|
|
19
|
-
display: none;
|
|
20
|
-
}
|
|
21
|
-
|
|
22
|
-
.toast .bottom {
|
|
23
|
-
width: 100%;
|
|
24
|
-
}
|
|
25
|
-
`;
|
|
@@ -1,27 +0,0 @@
|
|
|
1
|
-
const MESSAGE_TYPE_INFORMATION = 'Information';
|
|
2
|
-
const MESSAGE_TYPE_WARNING = 'Warning';
|
|
3
|
-
const MESSAGE_TYPE_SERIOUS = 'Serious';
|
|
4
|
-
const MESSAGE_TYPE_CRITICAL = 'Critical';
|
|
5
|
-
export const ALL_MESSAGE_TYPES = [
|
|
6
|
-
MESSAGE_TYPE_INFORMATION,
|
|
7
|
-
MESSAGE_TYPE_WARNING,
|
|
8
|
-
MESSAGE_TYPE_SERIOUS,
|
|
9
|
-
MESSAGE_TYPE_CRITICAL,
|
|
10
|
-
];
|
|
11
|
-
export const SEVERITY_TYPE_DEFAULT = 'default';
|
|
12
|
-
const SEVERITY_TYPE_WARNING = 'warning';
|
|
13
|
-
const SEVERITY_TYPE_SERIOUS = 'serious';
|
|
14
|
-
const SEVERITY_TYPE_CRITICAL = 'critical';
|
|
15
|
-
export const ALL_SEVERITIES_TYPES = [
|
|
16
|
-
SEVERITY_TYPE_DEFAULT,
|
|
17
|
-
SEVERITY_TYPE_WARNING,
|
|
18
|
-
SEVERITY_TYPE_SERIOUS,
|
|
19
|
-
SEVERITY_TYPE_CRITICAL,
|
|
20
|
-
];
|
|
21
|
-
export const MAP_MESSAGE_TYPE_TO_SEVERITY_TYPE = new Map([
|
|
22
|
-
[MESSAGE_TYPE_INFORMATION, SEVERITY_TYPE_DEFAULT],
|
|
23
|
-
[MESSAGE_TYPE_WARNING, SEVERITY_TYPE_WARNING],
|
|
24
|
-
[MESSAGE_TYPE_SERIOUS, SEVERITY_TYPE_SERIOUS],
|
|
25
|
-
[MESSAGE_TYPE_CRITICAL, SEVERITY_TYPE_CRITICAL],
|
|
26
|
-
]);
|
|
27
|
-
export const DEBOUNCED_SEARCH_TIME = 500;
|
|
@@ -1,27 +0,0 @@
|
|
|
1
|
-
import { css, html } from '@microsoft/fast-element';
|
|
2
|
-
import { FASTElementLayout } from '@microsoft/fast-router';
|
|
3
|
-
export const defaultLayout = new FASTElementLayout(html `
|
|
4
|
-
<div class="container">
|
|
5
|
-
<div class="content">
|
|
6
|
-
<slot></slot>
|
|
7
|
-
</div>
|
|
8
|
-
</div>
|
|
9
|
-
`, css `
|
|
10
|
-
:host {
|
|
11
|
-
}
|
|
12
|
-
|
|
13
|
-
.container {
|
|
14
|
-
width: 100%;
|
|
15
|
-
height: 100%;
|
|
16
|
-
display: block;
|
|
17
|
-
position: relative;
|
|
18
|
-
}
|
|
19
|
-
|
|
20
|
-
.content {
|
|
21
|
-
position: absolute;
|
|
22
|
-
top: 0;
|
|
23
|
-
bottom: 0;
|
|
24
|
-
left: 0;
|
|
25
|
-
right: 0;
|
|
26
|
-
}
|
|
27
|
-
`);
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export * from './default';
|
|
@@ -1,109 +0,0 @@
|
|
|
1
|
-
import { __awaiter, __decorate, __param } from "tslib";
|
|
2
|
-
import { Auth, Connect } from '@genesislcap/foundation-comms';
|
|
3
|
-
import { DI } from '@microsoft/fast-foundation';
|
|
4
|
-
import { DEBOUNCED_SEARCH_TIME } from '../inbox.config';
|
|
5
|
-
import { NotifyResourceNames } from '../inbox.types';
|
|
6
|
-
import { logger, transformMessageToNotify } from '../utils';
|
|
7
|
-
let FoundationInboxServiceImpl = class FoundationInboxServiceImpl {
|
|
8
|
-
constructor(connect, auth) {
|
|
9
|
-
this.connect = connect;
|
|
10
|
-
this.auth = auth;
|
|
11
|
-
this.resourceName = NotifyResourceNames.ALL_RECORDS;
|
|
12
|
-
this.subscriptions = [];
|
|
13
|
-
this.store = {
|
|
14
|
-
notifies: []
|
|
15
|
-
};
|
|
16
|
-
}
|
|
17
|
-
getNotificationRules() {
|
|
18
|
-
let notificationRules = [];
|
|
19
|
-
this.connect.request('NOTIFICATION_RULE').then((response) => {
|
|
20
|
-
if (!response.REPLY) {
|
|
21
|
-
return;
|
|
22
|
-
}
|
|
23
|
-
notificationRules = response.REPLY;
|
|
24
|
-
});
|
|
25
|
-
return notificationRules;
|
|
26
|
-
}
|
|
27
|
-
getStream() {
|
|
28
|
-
return this.connect.stream(this.resourceName, (result) => {
|
|
29
|
-
this.sourceRef = result.SOURCE_REF;
|
|
30
|
-
if (!(result === null || result === void 0 ? void 0 : result.ROW)) {
|
|
31
|
-
this.store.notifies = [];
|
|
32
|
-
return;
|
|
33
|
-
}
|
|
34
|
-
if (result.SEQUENCE_ID === 1) {
|
|
35
|
-
const newNotifies = [];
|
|
36
|
-
result.ROW.forEach((row) => newNotifies.push(transformMessageToNotify(row)));
|
|
37
|
-
this.store.notifies = newNotifies;
|
|
38
|
-
}
|
|
39
|
-
else {
|
|
40
|
-
const details = result === null || result === void 0 ? void 0 : result.ROW[0];
|
|
41
|
-
if ((details === null || details === void 0 ? void 0 : details.DETAILS.OPERATION) === 'DELETE') {
|
|
42
|
-
const notifyItemIndex = this.store.notifies.findIndex(({ rowRef }) => rowRef === details.DETAILS.ROW_REF);
|
|
43
|
-
if (notifyItemIndex > -1) {
|
|
44
|
-
this.store.notifies.splice(notifyItemIndex, 1);
|
|
45
|
-
}
|
|
46
|
-
}
|
|
47
|
-
if ((details === null || details === void 0 ? void 0 : details.DETAILS.OPERATION) === 'INSERT') {
|
|
48
|
-
this.store.notifies.push(transformMessageToNotify(details));
|
|
49
|
-
}
|
|
50
|
-
}
|
|
51
|
-
this.subscriptions.forEach((callback) => callback({ store: this.store }));
|
|
52
|
-
}, (response) => logger.error('Error: Could not load notify data.' + response));
|
|
53
|
-
}
|
|
54
|
-
subscribe(callback) {
|
|
55
|
-
this.subscriptions.push(callback);
|
|
56
|
-
if (this.stream) {
|
|
57
|
-
callback({ store: this.store });
|
|
58
|
-
}
|
|
59
|
-
else {
|
|
60
|
-
this.stream = this.getStream();
|
|
61
|
-
this.stream.subscribe();
|
|
62
|
-
}
|
|
63
|
-
}
|
|
64
|
-
unsubscribe(callback) {
|
|
65
|
-
const index = this.subscriptions.indexOf(callback);
|
|
66
|
-
if (index >= 0) {
|
|
67
|
-
this.subscriptions.splice(index, 1);
|
|
68
|
-
}
|
|
69
|
-
this.dataLogoff();
|
|
70
|
-
}
|
|
71
|
-
dataLogoff() {
|
|
72
|
-
if (this.sourceRef && this.auth.isLoggedIn) {
|
|
73
|
-
this.connect.dataLogoff(this.sourceRef);
|
|
74
|
-
}
|
|
75
|
-
this.stream = undefined;
|
|
76
|
-
this.store = {
|
|
77
|
-
notifies: []
|
|
78
|
-
};
|
|
79
|
-
this.sourceRef = undefined;
|
|
80
|
-
}
|
|
81
|
-
filter(filterTypes, payload) {
|
|
82
|
-
const criteriaByFilterType = {
|
|
83
|
-
search: `(Expr.containsIgnoreCase(MESSAGE, '${payload['search']}') || Expr.containsIgnoreCase(HEADER, '${payload['search']}'))`,
|
|
84
|
-
severity: `NOTIFY_SEVERITY == '${payload['severity']}'`,
|
|
85
|
-
};
|
|
86
|
-
const CRITERIA_MATCH = filterTypes
|
|
87
|
-
.map((filterType) => criteriaByFilterType[filterType])
|
|
88
|
-
.join(' && ');
|
|
89
|
-
return new Promise((resolve) => {
|
|
90
|
-
if (this.debounced) {
|
|
91
|
-
clearTimeout(this.debounced);
|
|
92
|
-
this.debounced = null;
|
|
93
|
-
}
|
|
94
|
-
this.debounced = setTimeout(() => __awaiter(this, void 0, void 0, function* () {
|
|
95
|
-
const { ROW: rows } = yield this.connect.snapshot(this.resourceName, { CRITERIA_MATCH });
|
|
96
|
-
let newNotifies = [];
|
|
97
|
-
if (rows) {
|
|
98
|
-
newNotifies = rows.map((row) => transformMessageToNotify(row));
|
|
99
|
-
}
|
|
100
|
-
return resolve(newNotifies);
|
|
101
|
-
}), DEBOUNCED_SEARCH_TIME);
|
|
102
|
-
});
|
|
103
|
-
}
|
|
104
|
-
};
|
|
105
|
-
FoundationInboxServiceImpl = __decorate([
|
|
106
|
-
__param(0, Connect),
|
|
107
|
-
__param(1, Auth)
|
|
108
|
-
], FoundationInboxServiceImpl);
|
|
109
|
-
export const FoundationInboxService = DI.createInterface((x) => x.singleton(FoundationInboxServiceImpl));
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export * from './styles';
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
import { css } from '@microsoft/fast-element';
|
|
2
|
-
export const mixinScreen = (display = 'block') => `
|
|
3
|
-
contain: content;
|
|
4
|
-
display: ${display};
|
|
5
|
-
height: 100%;
|
|
6
|
-
width: 100%;
|
|
7
|
-
overflow-y: auto;
|
|
8
|
-
`;
|
|
9
|
-
export const inboxStyles = css `
|
|
10
|
-
:host {
|
|
11
|
-
display: flex;
|
|
12
|
-
}
|
|
13
|
-
`;
|
|
@@ -1,12 +0,0 @@
|
|
|
1
|
-
import { formatDateTimeTimestamp } from '@genesislcap/foundation-utils';
|
|
2
|
-
import { SEVERITY_TYPE_DEFAULT, MAP_MESSAGE_TYPE_TO_SEVERITY_TYPE } from '../inbox.config';
|
|
3
|
-
export const transformMessageToNotify = (notifyRow) => {
|
|
4
|
-
return {
|
|
5
|
-
id: notifyRow.ALERT_ID,
|
|
6
|
-
rowRef: notifyRow.DETAILS.ROW_REF,
|
|
7
|
-
title: notifyRow.HEADER,
|
|
8
|
-
content: notifyRow.MESSAGE,
|
|
9
|
-
date: formatDateTimeTimestamp(notifyRow.CREATED_AT),
|
|
10
|
-
type: MAP_MESSAGE_TYPE_TO_SEVERITY_TYPE.get(notifyRow.NOTIFY_SEVERITY) || SEVERITY_TYPE_DEFAULT,
|
|
11
|
-
};
|
|
12
|
-
};
|
|
@@ -1,27 +0,0 @@
|
|
|
1
|
-
import { css, html } from '@microsoft/fast-element';
|
|
2
|
-
import { FASTElementLayout } from '@microsoft/fast-router';
|
|
3
|
-
export const defaultLayout = new FASTElementLayout(html `
|
|
4
|
-
<div class="container">
|
|
5
|
-
<div class="content">
|
|
6
|
-
<slot></slot>
|
|
7
|
-
</div>
|
|
8
|
-
</div>
|
|
9
|
-
`, css `
|
|
10
|
-
:host {
|
|
11
|
-
}
|
|
12
|
-
|
|
13
|
-
.container {
|
|
14
|
-
width: 100%;
|
|
15
|
-
height: 100%;
|
|
16
|
-
display: block;
|
|
17
|
-
position: relative;
|
|
18
|
-
}
|
|
19
|
-
|
|
20
|
-
.content {
|
|
21
|
-
position: absolute;
|
|
22
|
-
top: 0;
|
|
23
|
-
bottom: 0;
|
|
24
|
-
left: 0;
|
|
25
|
-
right: 0;
|
|
26
|
-
}
|
|
27
|
-
`);
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export * from './default';
|
package/dist/esm/styles/index.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export * from './styles';
|