@equinor/mad-core 0.9.12 → 0.10.1
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/CHANGELOG.md +23 -0
- package/CODE_OF_CONDUCT.md +25 -30
- package/dist/{chunk-5Q7ZXDFE.js → chunk-2EBLJCZH.js} +8 -14
- package/dist/{chunk-73DTZ72P.js → chunk-3DWMQWGO.js} +3 -4
- package/dist/{chunk-E6ZYHW72.js → chunk-45SUJ4GS.js} +2 -4
- package/dist/{chunk-WUCGJV35.js → chunk-46UQWICK.js} +1 -1
- package/dist/{chunk-AJJ4VFS3.js → chunk-4DXH3SPN.js} +1 -1
- package/dist/{chunk-OG52JYYV.js → chunk-4J43OC2B.js} +4 -4
- package/dist/{chunk-64OQU7W4.js → chunk-4ZZKAQ7C.js} +1 -1
- package/dist/{chunk-CZAFV2L7.js → chunk-5BWKCV3H.js} +1 -1
- package/dist/{chunk-VRSHTEZL.js → chunk-5TKF6KQO.js} +5 -7
- package/dist/{chunk-6T6NE74H.js → chunk-6A7XY5VK.js} +3 -3
- package/dist/{chunk-T5FRJCLW.js → chunk-6JEPMDC4.js} +3 -4
- package/dist/{chunk-JNNCA3V2.js → chunk-7FBCK6I4.js} +1 -1
- package/dist/{chunk-ZLW2PMDL.js → chunk-7JHIDQQ7.js} +1 -1
- package/dist/{chunk-ZYGXHZCE.js → chunk-A4OAMNA3.js} +2 -3
- package/dist/{chunk-ROKKC7LJ.js → chunk-ADBVMDRF.js} +3 -4
- package/dist/{chunk-KL32BPEW.js → chunk-C5PTOP7U.js} +7 -7
- package/dist/{chunk-L434TQRF.js → chunk-CXXCHRHS.js} +1 -1
- package/dist/{chunk-TMC6RSMM.js → chunk-DC5ASEDD.js} +3 -3
- package/dist/{chunk-WRQWW7QV.js → chunk-HN6FG72A.js} +1 -1
- package/dist/{chunk-JAANGYXX.js → chunk-IWTCXKE2.js} +2 -2
- package/dist/{chunk-AQXI6FKQ.js → chunk-LDHADSAI.js} +3 -3
- package/dist/{chunk-BE6LXCPW.js → chunk-LRACCJE4.js} +5 -5
- package/dist/{chunk-TYHV32QV.js → chunk-LZVFDNET.js} +1 -1
- package/dist/{chunk-GAKL37JH.js → chunk-NE7MJB3C.js} +13 -14
- package/dist/{chunk-SNG5ADEI.js → chunk-NJ5W3O5I.js} +2 -3
- package/dist/{chunk-QVU6TANN.js → chunk-OZJ2PBO6.js} +6 -6
- package/dist/{chunk-5E7LGWBD.js → chunk-PWORULZD.js} +2 -3
- package/dist/{chunk-B6LK3MOD.js → chunk-Q4SX3UP3.js} +4 -7
- package/dist/{chunk-7SJM4NDH.js → chunk-QLL6LKDN.js} +2 -4
- package/dist/{chunk-5SUL6W5R.js → chunk-SDKRNZRS.js} +6 -10
- package/dist/{chunk-ZWS33QDE.js → chunk-TGYT7TUP.js} +1 -2
- package/dist/{chunk-VEAO5KM2.js → chunk-UV3M2SNJ.js} +4 -7
- package/dist/{chunk-YYNDOD2M.js → chunk-VWR2AFO7.js} +2 -3
- package/dist/{chunk-3JJAYLEH.js → chunk-WEUFP6WW.js} +3 -6
- package/dist/{chunk-NANV25P2.js → chunk-WP22W6IZ.js} +4 -6
- package/dist/{chunk-ZWBWZKYN.js → chunk-XCK6ZFYO.js} +1 -1
- package/dist/{chunk-WLYQWDPT.js → chunk-XJX4HQF2.js} +1 -1
- package/dist/{chunk-ZPXPIE5I.js → chunk-XLQYZR5C.js} +1 -1
- package/dist/components/EnvironmentBanner.js +4 -4
- package/dist/components/EnvironmentProvider.js +4 -4
- package/dist/components/ErrorBoundary.js +2 -2
- package/dist/components/NavigationContainer.js +2 -2
- package/dist/components/ToastEmitter.js +1 -1
- package/dist/components/createCoreStackNavigator.js +34 -34
- package/dist/components/index.js +39 -39
- package/dist/components/navigation/MadCoreSubHeader.js +9 -9
- package/dist/components/navigation/coreRoutes.js +1 -1
- package/dist/components/navigation/index.js +10 -10
- package/dist/components/navigation/navigation-creators.js +10 -10
- package/dist/components/screens/AboutScreen.js +4 -4
- package/dist/components/screens/LoginScreen.js +7 -7
- package/dist/components/screens/create-incident/CreateIncidentScreen.js +6 -6
- package/dist/components/screens/create-incident/UserInfo.js +1 -1
- package/dist/components/screens/create-incident/createIncident.js +2 -2
- package/dist/components/screens/language/SelectLanguageScreen.js +8 -8
- package/dist/components/screens/language/components/SelectLanguageCellGroup.js +4 -4
- package/dist/components/screens/release-notes/ChangeLog.js +2 -2
- package/dist/components/screens/release-notes/ReleaseNotesScreen.js +9 -9
- package/dist/components/screens/release-notes/WhatsNewScreen.js +10 -10
- package/dist/components/screens/release-notes/fetchReleaseNotes.js +4 -4
- package/dist/components/screens/settings/Section.js +4 -4
- package/dist/components/screens/settings/SettingsScreen.js +8 -8
- package/dist/components/screens/settings/index.js +8 -8
- package/dist/components/screens/settings/renderCell.js +1 -1
- package/dist/components/screens/settings/useSignOut.js +5 -5
- package/dist/components/service-message/ServiceMessageBanner.js +7 -7
- package/dist/components/service-message/ServiceMessageProvider.js +5 -5
- package/dist/components/service-message/components/DisableableSwipeable.js +2 -2
- package/dist/components/service-message/components/ExpansionToggle.js +1 -1
- package/dist/components/service-message/hooks/useFetchServiceMessage.js +4 -4
- package/dist/components/service-message/utils/resolveMessageFromServiceMessage.js +1 -1
- package/dist/hooks/UseReleaseNotes.js +6 -6
- package/dist/hooks/index.js +4 -4
- package/dist/hooks/useAccountOrDemoAccount.js +4 -4
- package/dist/hooks/useCoreStackNavigation.js +1 -1
- package/dist/hooks/useNavigateFromLanguageSelectScreen.js +5 -5
- package/dist/hooks/useNavigateFromLoginScreen.js +6 -6
- package/dist/hooks/useNavigateFromWhatsNewScreen.js +5 -5
- package/dist/hooks/useScreenTitleFromDictionary.js +4 -4
- package/dist/index.js +39 -39
- package/dist/language/useDictionary.js +3 -3
- package/dist/store/demo-mode/demo-mode.js +1 -1
- package/dist/store/demo-mode/index.js +1 -1
- package/dist/store/index.js +3 -3
- package/dist/store/language/index.js +3 -3
- package/dist/store/language/language.js +3 -3
- package/dist/store/mad-config/hooks.js +3 -3
- package/dist/store/mad-config/index.js +3 -3
- package/dist/store/mad-config/mad-config.js +3 -3
- package/dist/store/release-notes/index.js +1 -1
- package/dist/store/release-notes/release-notes.js +1 -1
- package/dist/store/storage.js +1 -1
- package/dist/utils/createEnvironmentProxy.js +3 -3
- package/dist/utils/createMadCoreNavigator.js +27 -27
- package/dist/utils/dateUtils.js +1 -1
- package/dist/utils/getDefaultScreenOptionsForLoginScreen.js +1 -1
- package/dist/utils/getFinalSettingsConfig.js +2 -2
- package/dist/utils/getNavigationRouteForLoginScreen.js +3 -3
- package/dist/utils/getNavigationRouteForSelectLanguageScreen.js +2 -2
- package/dist/utils/getNavigationRouteForWhatsNewScreen.js +2 -2
- package/dist/utils/getPremadeSettings.js +2 -2
- package/dist/utils/getRedirectUriFromAuthConfig.js +1 -1
- package/dist/utils/getTopOffsetForToast.js +1 -1
- package/dist/utils/initiateAuthenticationClient.js +4 -4
- package/dist/utils/madCommonUtils.js +1 -1
- package/package.json +41 -38
- /package/dist/{chunk-LOPKRCGI.js → chunk-CWMXXUWU.js} +0 -0
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,28 @@
|
|
|
1
1
|
# @equinor/mad-core
|
|
2
2
|
|
|
3
|
+
## 0.10.1
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- Updated dependencies [49c59fd]
|
|
8
|
+
- @equinor/mad-components@0.17.0
|
|
9
|
+
- @equinor/mad-auth@0.2.10
|
|
10
|
+
- @equinor/mad-toast@0.2.1
|
|
11
|
+
|
|
12
|
+
## 0.10.0
|
|
13
|
+
|
|
14
|
+
### Minor Changes
|
|
15
|
+
|
|
16
|
+
- 75df020: Changed dependencies to require Expo 52 compatable versions
|
|
17
|
+
|
|
18
|
+
### Patch Changes
|
|
19
|
+
|
|
20
|
+
- Updated dependencies [75df020]
|
|
21
|
+
- @equinor/mad-components@0.16.0
|
|
22
|
+
- @equinor/mad-navigation@0.4.0
|
|
23
|
+
- @equinor/mad-toast@0.2.0
|
|
24
|
+
- @equinor/mad-auth@0.2.9
|
|
25
|
+
|
|
3
26
|
## 0.9.12
|
|
4
27
|
|
|
5
28
|
### Patch Changes
|
package/CODE_OF_CONDUCT.md
CHANGED
|
@@ -1,49 +1,44 @@
|
|
|
1
1
|
# How we work
|
|
2
2
|
|
|
3
|
-
In Equinor,
|
|
4
|
-
deliver](https://www.equinor.com/en/careers/our-culture.html).
|
|
3
|
+
In Equinor,
|
|
4
|
+
[how we deliver is as important as what we deliver](https://www.equinor.com/en/careers/our-culture.html).
|
|
5
5
|
|
|
6
|
-
This set the expectations for how we collaborate in our open source projects,
|
|
7
|
-
|
|
8
|
-
project.
|
|
6
|
+
This set the expectations for how we collaborate in our open source projects, and applies to all
|
|
7
|
+
community members and participants in any Equinor maintained project.
|
|
9
8
|
|
|
10
9
|
## Handling issues within the communities
|
|
11
10
|
|
|
12
|
-
We expect all to have a low threshold for raising issues, or in general discuss
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
encourage all community members to appreciate when concerns are raised, and make
|
|
16
|
-
its best effort in solving them.
|
|
11
|
+
We expect all to have a low threshold for raising issues, or in general discuss how we live up to
|
|
12
|
+
our [values](https://www.equinor.com/en/about-us.html#our-values). Equally, we also encourage all
|
|
13
|
+
community members to appreciate when concerns are raised, and make its best effort in solving them.
|
|
17
14
|
|
|
18
|
-
As well as responsibility for what is delivered the project maintainers are also
|
|
19
|
-
|
|
20
|
-
the communities.
|
|
15
|
+
As well as responsibility for what is delivered the project maintainers are also responsible
|
|
16
|
+
creating an environment for proper handling of issues raised within the communities.
|
|
21
17
|
|
|
22
18
|
## Call out for assistance
|
|
23
19
|
|
|
24
|
-
For any problem not directly resolvable within the community, we encourage you
|
|
25
|
-
|
|
26
|
-
|
|
20
|
+
For any problem not directly resolvable within the community, we encourage you to call out for
|
|
21
|
+
assistance. Getting an outsiders perspective on the topic might be just what is needed for you to
|
|
22
|
+
proceed.
|
|
27
23
|
|
|
28
|
-
Send an e-mail to opensource_at_equinor.com and invite for a discussion. The
|
|
29
|
-
|
|
24
|
+
Send an e-mail to opensource_at_equinor.com and invite for a discussion. The email will be handled
|
|
25
|
+
by a team within the Equinor organization.
|
|
30
26
|
|
|
31
|
-
Your request will be kept confidential from the team or community in question,
|
|
32
|
-
|
|
27
|
+
Your request will be kept confidential from the team or community in question, unless you chose to
|
|
28
|
+
disclose it yourself.
|
|
33
29
|
|
|
34
30
|
## Ethics helpline
|
|
35
31
|
|
|
36
|
-
In Equinor, we want you to speak up whenever you see unethical behaviour that
|
|
37
|
-
|
|
32
|
+
In Equinor, we want you to speak up whenever you see unethical behaviour that conflicts with our
|
|
33
|
+
values or threatens our reputation.
|
|
38
34
|
|
|
39
|
-
To underline this, we continuously encourage and remind our employees and any
|
|
40
|
-
|
|
41
|
-
|
|
35
|
+
To underline this, we continuously encourage and remind our employees and any external third parties
|
|
36
|
+
interacting with us to raise concerns or report any suspected or potential breaches of law or
|
|
37
|
+
company policies.
|
|
42
38
|
|
|
43
|
-
For any questions or issues that one suspect falls outside the scope of
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
Ethics
|
|
47
|
-
helpline](https://secure.ethicspoint.eu/domain/media/en/gui/102166/index.html).
|
|
39
|
+
For any questions or issues that one suspect falls outside the scope of behaviour regulated, and
|
|
40
|
+
handled within the open source code of conduct, or you wish to place an anonymous, confidential
|
|
41
|
+
report we encourage to use the
|
|
42
|
+
[Equinor Ethics helpline](https://secure.ethicspoint.eu/domain/media/en/gui/102166/index.html).
|
|
48
43
|
|
|
49
44
|
This helpline is hosted by a third party helpline provider.
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import {
|
|
2
2
|
getPremadeSettings
|
|
3
|
-
} from "./chunk-
|
|
3
|
+
} from "./chunk-45SUJ4GS.js";
|
|
4
4
|
import {
|
|
5
5
|
getRedirectUriFromAuthConfig
|
|
6
6
|
} from "./chunk-MODG2KVN.js";
|
|
@@ -10,7 +10,7 @@ import {
|
|
|
10
10
|
import {
|
|
11
11
|
__export,
|
|
12
12
|
__spreadValues
|
|
13
|
-
} from "./chunk-
|
|
13
|
+
} from "./chunk-CWMXXUWU.js";
|
|
14
14
|
|
|
15
15
|
// src/store/mad-config/mad-config.ts
|
|
16
16
|
import { create } from "zustand";
|
|
@@ -33,22 +33,19 @@ var useMadConfigStore = create()(
|
|
|
33
33
|
var MAD_CONFIG_NOT_FOUND_ERROR = "Mad config has not been provided! Make sure you use 'createCoreStackNavigator' to provide your config";
|
|
34
34
|
var useMadConfig = () => {
|
|
35
35
|
const config = useMadConfigStore().config;
|
|
36
|
-
if (!config)
|
|
37
|
-
throw new Error(MAD_CONFIG_NOT_FOUND_ERROR);
|
|
36
|
+
if (!config) throw new Error(MAD_CONFIG_NOT_FOUND_ERROR);
|
|
38
37
|
return useMemo(() => {
|
|
39
38
|
return createEnvironmentProxy(config.currentEnvironment);
|
|
40
39
|
}, [config, config.currentEnvironment]);
|
|
41
40
|
};
|
|
42
41
|
var getConfig = () => {
|
|
43
42
|
const config = useMadConfigStore.getState().config;
|
|
44
|
-
if (!config)
|
|
45
|
-
throw new Error(MAD_CONFIG_NOT_FOUND_ERROR);
|
|
43
|
+
if (!config) throw new Error(MAD_CONFIG_NOT_FOUND_ERROR);
|
|
46
44
|
return createEnvironmentProxy(config.currentEnvironment);
|
|
47
45
|
};
|
|
48
46
|
var getPureConfig = () => {
|
|
49
47
|
const config = useMadConfigStore.getState().config;
|
|
50
|
-
if (!config)
|
|
51
|
-
throw new Error(MAD_CONFIG_NOT_FOUND_ERROR);
|
|
48
|
+
if (!config) throw new Error(MAD_CONFIG_NOT_FOUND_ERROR);
|
|
52
49
|
return config;
|
|
53
50
|
};
|
|
54
51
|
var setConfig = (config) => {
|
|
@@ -65,10 +62,8 @@ var getSupportedLanguages = () => getConfig().language.supportedLanguages;
|
|
|
65
62
|
var getDefaultLanguage = () => {
|
|
66
63
|
const supportedLanguages = getSupportedLanguages();
|
|
67
64
|
const defaultLanguageCode = getConfig().language.defaultLanguageCode;
|
|
68
|
-
if (supportedLanguages.length === 0)
|
|
69
|
-
|
|
70
|
-
if (!defaultLanguageCode)
|
|
71
|
-
return supportedLanguages[0];
|
|
65
|
+
if (supportedLanguages.length === 0) throw new Error("There are no supported languages");
|
|
66
|
+
if (!defaultLanguageCode) return supportedLanguages[0];
|
|
72
67
|
const defaultLanguage = supportedLanguages.find(
|
|
73
68
|
(language4) => language4.code === defaultLanguageCode
|
|
74
69
|
);
|
|
@@ -413,8 +408,7 @@ var useSettingsScreenPremadeConfig = () => {
|
|
|
413
408
|
|
|
414
409
|
// src/utils/createEnvironmentProxy.ts
|
|
415
410
|
function isEnvironmentValuesObject(obj) {
|
|
416
|
-
if (!obj)
|
|
417
|
-
return false;
|
|
411
|
+
if (!obj) return false;
|
|
418
412
|
const template = ["dev", "test", "qa", "prod"];
|
|
419
413
|
const objectKeys = Object.keys(obj);
|
|
420
414
|
return objectKeys.every((key) => template.includes(key));
|
|
@@ -6,13 +6,13 @@ import {
|
|
|
6
6
|
} from "./chunk-BIMOM43W.js";
|
|
7
7
|
import {
|
|
8
8
|
getConfig
|
|
9
|
-
} from "./chunk-
|
|
9
|
+
} from "./chunk-2EBLJCZH.js";
|
|
10
10
|
import {
|
|
11
11
|
CoreRoutes
|
|
12
12
|
} from "./chunk-UKAZW3CQ.js";
|
|
13
13
|
import {
|
|
14
14
|
__async
|
|
15
|
-
} from "./chunk-
|
|
15
|
+
} from "./chunk-CWMXXUWU.js";
|
|
16
16
|
|
|
17
17
|
// src/components/screens/settings/useSignOut.ts
|
|
18
18
|
import { useCallback } from "react";
|
|
@@ -25,8 +25,7 @@ var useSignOut = () => {
|
|
|
25
25
|
var _a;
|
|
26
26
|
try {
|
|
27
27
|
const result = ((_a = getConfig().experimental) == null ? void 0 : _a.useExpoAuthSession) ? ExpoAuthSession.signOut() : yield signOut();
|
|
28
|
-
if (!demoMode.isEnabled && !result)
|
|
29
|
-
throw new Error("Unable to sign out");
|
|
28
|
+
if (!demoMode.isEnabled && !result) throw new Error("Unable to sign out");
|
|
30
29
|
demoMode.disableDemoMode();
|
|
31
30
|
navigation.navigate(CoreRoutes.LOGIN);
|
|
32
31
|
} catch (_) {
|
|
@@ -29,10 +29,8 @@ var getLanguageConfig = (dictionary) => ({
|
|
|
29
29
|
});
|
|
30
30
|
var getPremadeSettings = (config, dictionary) => {
|
|
31
31
|
const premadeCommonNavigationItems = [getReleaseNotesConfig(dictionary)];
|
|
32
|
-
if (config.about)
|
|
33
|
-
|
|
34
|
-
if (config.serviceNow)
|
|
35
|
-
premadeCommonNavigationItems.push(getServiceNowConfig(dictionary));
|
|
32
|
+
if (config.about) premadeCommonNavigationItems.push(getAboutConfig(dictionary));
|
|
33
|
+
if (config.serviceNow) premadeCommonNavigationItems.push(getServiceNowConfig(dictionary));
|
|
36
34
|
const premadeLanguageSection = config.language.supportedLanguages.length >= 2 ? { items: [getLanguageConfig(dictionary)] } : void 0;
|
|
37
35
|
const premadeCommonNavigationSection = {
|
|
38
36
|
items: premadeCommonNavigationItems
|
|
@@ -1,16 +1,16 @@
|
|
|
1
1
|
import {
|
|
2
2
|
SelectLanguageCellGroup
|
|
3
|
-
} from "./chunk-
|
|
3
|
+
} from "./chunk-CXXCHRHS.js";
|
|
4
4
|
import {
|
|
5
5
|
useScreenTitleFromDictionary
|
|
6
|
-
} from "./chunk-
|
|
6
|
+
} from "./chunk-5BWKCV3H.js";
|
|
7
7
|
import {
|
|
8
8
|
useNavigateFromLanguageSelectScreen
|
|
9
|
-
} from "./chunk-
|
|
9
|
+
} from "./chunk-ADBVMDRF.js";
|
|
10
10
|
import {
|
|
11
11
|
useDictionary,
|
|
12
12
|
useLanguage
|
|
13
|
-
} from "./chunk-
|
|
13
|
+
} from "./chunk-2EBLJCZH.js";
|
|
14
14
|
|
|
15
15
|
// src/components/screens/language/SelectLanguageScreen.tsx
|
|
16
16
|
import React, { useState } from "react";
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import {
|
|
2
2
|
DisableableSwipeable
|
|
3
|
-
} from "./chunk-
|
|
3
|
+
} from "./chunk-XJX4HQF2.js";
|
|
4
4
|
import {
|
|
5
5
|
ExpansionToggle
|
|
6
6
|
} from "./chunk-YWPELSTX.js";
|
|
@@ -9,11 +9,11 @@ import {
|
|
|
9
9
|
} from "./chunk-SHKOH7MA.js";
|
|
10
10
|
import {
|
|
11
11
|
useServiceMessageState
|
|
12
|
-
} from "./chunk-
|
|
12
|
+
} from "./chunk-HN6FG72A.js";
|
|
13
13
|
import {
|
|
14
14
|
__spreadProps,
|
|
15
15
|
__spreadValues
|
|
16
|
-
} from "./chunk-
|
|
16
|
+
} from "./chunk-CWMXXUWU.js";
|
|
17
17
|
|
|
18
18
|
// src/components/service-message/ServiceMessageBanner.tsx
|
|
19
19
|
import React from "react";
|
|
@@ -42,10 +42,8 @@ var ServiceMessageBanner = () => {
|
|
|
42
42
|
LayoutAnimation.configureNext(__spreadProps(__spreadValues({}, LayoutAnimation.Presets.easeInEaseOut), { duration: 100 }));
|
|
43
43
|
setIsExpanded((isExpanded2) => !isExpanded2);
|
|
44
44
|
};
|
|
45
|
-
if (isDismissed)
|
|
46
|
-
|
|
47
|
-
if (!serviceMessage)
|
|
48
|
-
return null;
|
|
45
|
+
if (isDismissed) return null;
|
|
46
|
+
if (!serviceMessage) return null;
|
|
49
47
|
const { message, url } = resolveMessageFromServiceMessage(serviceMessage, isError);
|
|
50
48
|
return /* @__PURE__ */ React.createElement(SafeAreaView, null, /* @__PURE__ */ React.createElement(
|
|
51
49
|
DisableableSwipeable,
|
|
@@ -1,15 +1,15 @@
|
|
|
1
1
|
import {
|
|
2
2
|
ChangeLog
|
|
3
|
-
} from "./chunk-
|
|
3
|
+
} from "./chunk-XLQYZR5C.js";
|
|
4
4
|
import {
|
|
5
5
|
getShortDate
|
|
6
6
|
} from "./chunk-OCWASWDK.js";
|
|
7
7
|
import {
|
|
8
8
|
useScreenTitleFromDictionary
|
|
9
|
-
} from "./chunk-
|
|
9
|
+
} from "./chunk-5BWKCV3H.js";
|
|
10
10
|
import {
|
|
11
11
|
useReleaseNotes
|
|
12
|
-
} from "./chunk-
|
|
12
|
+
} from "./chunk-UV3M2SNJ.js";
|
|
13
13
|
|
|
14
14
|
// src/components/screens/release-notes/ReleaseNotesScreen.tsx
|
|
15
15
|
import React from "react";
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import {
|
|
2
2
|
getNavigationRouteForWhatsNewScreen
|
|
3
|
-
} from "./chunk-
|
|
3
|
+
} from "./chunk-WEUFP6WW.js";
|
|
4
4
|
import {
|
|
5
5
|
useCoreStackNavigation
|
|
6
6
|
} from "./chunk-BIMOM43W.js";
|
|
@@ -8,7 +8,7 @@ import {
|
|
|
8
8
|
useLanguage,
|
|
9
9
|
useMadConfig,
|
|
10
10
|
useNavigateToMainRoute
|
|
11
|
-
} from "./chunk-
|
|
11
|
+
} from "./chunk-2EBLJCZH.js";
|
|
12
12
|
|
|
13
13
|
// src/hooks/useNavigateFromWhatsNewScreen.ts
|
|
14
14
|
var useNavigateFromWhatsNewScreen = () => {
|
|
@@ -23,8 +23,7 @@ var useNavigateFromWhatsNewScreen = () => {
|
|
|
23
23
|
supportedLanguages,
|
|
24
24
|
skipOnboarding
|
|
25
25
|
);
|
|
26
|
-
if (route)
|
|
27
|
-
return () => navigation.navigate(route);
|
|
26
|
+
if (route) return () => navigation.navigate(route);
|
|
28
27
|
return navigateToMainRoute;
|
|
29
28
|
};
|
|
30
29
|
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import {
|
|
2
2
|
getNavigationRouteForWhatsNewScreen
|
|
3
|
-
} from "./chunk-
|
|
3
|
+
} from "./chunk-WEUFP6WW.js";
|
|
4
4
|
import {
|
|
5
5
|
CoreRoutes
|
|
6
6
|
} from "./chunk-UKAZW3CQ.js";
|
|
@@ -14,8 +14,7 @@ var getNavigationRouteForLoginScreen = ({
|
|
|
14
14
|
supportedLanguages,
|
|
15
15
|
skipOnboarding
|
|
16
16
|
}) => {
|
|
17
|
-
if (isDemoModeEnabled)
|
|
18
|
-
return CoreRoutes.WHATS_NEW;
|
|
17
|
+
if (isDemoModeEnabled) return CoreRoutes.WHATS_NEW;
|
|
19
18
|
if (!lastDisplayedReleaseNotesVersion || lastDisplayedReleaseNotesVersion < appVersion)
|
|
20
19
|
return CoreRoutes.WHATS_NEW;
|
|
21
20
|
return getNavigationRouteForWhatsNewScreen(
|
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
import {
|
|
2
2
|
getNavigationRouteForSelectLanguageScreen
|
|
3
|
-
} from "./chunk-
|
|
3
|
+
} from "./chunk-TGYT7TUP.js";
|
|
4
4
|
import {
|
|
5
5
|
useCoreStackNavigation,
|
|
6
6
|
useCoreStackRoute
|
|
7
7
|
} from "./chunk-BIMOM43W.js";
|
|
8
8
|
import {
|
|
9
9
|
useNavigateToMainRoute
|
|
10
|
-
} from "./chunk-
|
|
10
|
+
} from "./chunk-2EBLJCZH.js";
|
|
11
11
|
import {
|
|
12
12
|
CoreRoutes
|
|
13
13
|
} from "./chunk-UKAZW3CQ.js";
|
|
@@ -19,8 +19,7 @@ var useNavigateFromLanguageSelectScreen = () => {
|
|
|
19
19
|
const navigateToMainRoute = useNavigateToMainRoute();
|
|
20
20
|
const isOnboarding = coreRoute.name === CoreRoutes.SELECT_LANGUAGE_ONBOARDING;
|
|
21
21
|
const route = getNavigationRouteForSelectLanguageScreen(isOnboarding);
|
|
22
|
-
if (route)
|
|
23
|
-
return () => navigation.navigate(route);
|
|
22
|
+
if (route) return () => navigation.navigate(route);
|
|
24
23
|
return navigateToMainRoute;
|
|
25
24
|
};
|
|
26
25
|
|
|
@@ -1,24 +1,24 @@
|
|
|
1
1
|
import {
|
|
2
2
|
ChangeLog
|
|
3
|
-
} from "./chunk-
|
|
3
|
+
} from "./chunk-XLQYZR5C.js";
|
|
4
4
|
import {
|
|
5
5
|
getShortDate
|
|
6
6
|
} from "./chunk-OCWASWDK.js";
|
|
7
7
|
import {
|
|
8
8
|
useScreenTitleFromDictionary
|
|
9
|
-
} from "./chunk-
|
|
9
|
+
} from "./chunk-5BWKCV3H.js";
|
|
10
10
|
import {
|
|
11
11
|
whats_new_exports
|
|
12
|
-
} from "./chunk-
|
|
12
|
+
} from "./chunk-4DXH3SPN.js";
|
|
13
13
|
import {
|
|
14
14
|
fetchReleaseNotes
|
|
15
|
-
} from "./chunk-
|
|
15
|
+
} from "./chunk-WP22W6IZ.js";
|
|
16
16
|
import {
|
|
17
17
|
useReleaseNotesVersion
|
|
18
18
|
} from "./chunk-5BVQKJQB.js";
|
|
19
19
|
import {
|
|
20
20
|
useNavigateFromWhatsNewScreen
|
|
21
|
-
} from "./chunk-
|
|
21
|
+
} from "./chunk-6JEPMDC4.js";
|
|
22
22
|
import {
|
|
23
23
|
useDemoMode
|
|
24
24
|
} from "./chunk-UZ6YMQV2.js";
|
|
@@ -26,11 +26,11 @@ import {
|
|
|
26
26
|
useAppVersion,
|
|
27
27
|
useEnvironment,
|
|
28
28
|
useServicePortalName
|
|
29
|
-
} from "./chunk-
|
|
29
|
+
} from "./chunk-2EBLJCZH.js";
|
|
30
30
|
import {
|
|
31
31
|
__spreadProps,
|
|
32
32
|
__spreadValues
|
|
33
|
-
} from "./chunk-
|
|
33
|
+
} from "./chunk-CWMXXUWU.js";
|
|
34
34
|
|
|
35
35
|
// src/components/screens/release-notes/WhatsNewScreen.tsx
|
|
36
36
|
import React, { useEffect, useState } from "react";
|
|
@@ -3,14 +3,14 @@ import {
|
|
|
3
3
|
} from "./chunk-3WUJAVUO.js";
|
|
4
4
|
import {
|
|
5
5
|
createIncident
|
|
6
|
-
} from "./chunk-
|
|
6
|
+
} from "./chunk-NJ5W3O5I.js";
|
|
7
7
|
import {
|
|
8
8
|
useAccountOrDemoAccount
|
|
9
|
-
} from "./chunk-
|
|
9
|
+
} from "./chunk-VWR2AFO7.js";
|
|
10
10
|
import {
|
|
11
11
|
useEnvironment,
|
|
12
12
|
useServiceNow
|
|
13
|
-
} from "./chunk-
|
|
13
|
+
} from "./chunk-2EBLJCZH.js";
|
|
14
14
|
|
|
15
15
|
// src/components/screens/create-incident/CreateIncidentScreen.tsx
|
|
16
16
|
import {
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import {
|
|
2
2
|
ServiceMessageBanner
|
|
3
|
-
} from "./chunk-
|
|
3
|
+
} from "./chunk-5TKF6KQO.js";
|
|
4
4
|
import {
|
|
5
5
|
EnvironmentBanner
|
|
6
|
-
} from "./chunk-
|
|
6
|
+
} from "./chunk-PWORULZD.js";
|
|
7
7
|
|
|
8
8
|
// src/components/navigation/MadCoreSubHeader.tsx
|
|
9
9
|
import React from "react";
|
|
@@ -1,16 +1,16 @@
|
|
|
1
1
|
import {
|
|
2
2
|
useNavigateFromLoginScreen
|
|
3
|
-
} from "./chunk-
|
|
3
|
+
} from "./chunk-SDKRNZRS.js";
|
|
4
4
|
import {
|
|
5
5
|
getConfig,
|
|
6
6
|
useAuthConfig,
|
|
7
7
|
useDictionary,
|
|
8
8
|
useLoginScreenConfig
|
|
9
|
-
} from "./chunk-
|
|
9
|
+
} from "./chunk-2EBLJCZH.js";
|
|
10
10
|
import {
|
|
11
11
|
__spreadProps,
|
|
12
12
|
__spreadValues
|
|
13
|
-
} from "./chunk-
|
|
13
|
+
} from "./chunk-CWMXXUWU.js";
|
|
14
14
|
|
|
15
15
|
// src/components/screens/LoginScreen.tsx
|
|
16
16
|
import { Button, EDSProvider, EDSStyleSheet, useStyles } from "@equinor/mad-components";
|
|
@@ -1,19 +1,19 @@
|
|
|
1
1
|
import {
|
|
2
2
|
initiateAuthenticationClient
|
|
3
|
-
} from "./chunk-
|
|
3
|
+
} from "./chunk-46UQWICK.js";
|
|
4
4
|
import {
|
|
5
5
|
createNativeStackNavigator
|
|
6
|
-
} from "./chunk-
|
|
6
|
+
} from "./chunk-7JHIDQQ7.js";
|
|
7
7
|
import {
|
|
8
8
|
createMadCoreNavigator
|
|
9
|
-
} from "./chunk-
|
|
9
|
+
} from "./chunk-NE7MJB3C.js";
|
|
10
10
|
import {
|
|
11
11
|
setConfig
|
|
12
|
-
} from "./chunk-
|
|
12
|
+
} from "./chunk-2EBLJCZH.js";
|
|
13
13
|
import {
|
|
14
14
|
__spreadProps,
|
|
15
15
|
__spreadValues
|
|
16
|
-
} from "./chunk-
|
|
16
|
+
} from "./chunk-CWMXXUWU.js";
|
|
17
17
|
|
|
18
18
|
// src/components/createCoreStackNavigator.tsx
|
|
19
19
|
var createCoreStackNavigator = (config) => {
|
|
@@ -1,33 +1,33 @@
|
|
|
1
|
+
import {
|
|
2
|
+
SelectLanguageScreen
|
|
3
|
+
} from "./chunk-4J43OC2B.js";
|
|
1
4
|
import {
|
|
2
5
|
ReleaseNotesScreen
|
|
3
|
-
} from "./chunk-
|
|
6
|
+
} from "./chunk-6A7XY5VK.js";
|
|
4
7
|
import {
|
|
5
8
|
WhatsNewScreen
|
|
6
|
-
} from "./chunk-
|
|
7
|
-
import {
|
|
8
|
-
SelectLanguageScreen
|
|
9
|
-
} from "./chunk-OG52JYYV.js";
|
|
9
|
+
} from "./chunk-C5PTOP7U.js";
|
|
10
10
|
import {
|
|
11
11
|
CreateIncidentScreen
|
|
12
|
-
} from "./chunk-
|
|
12
|
+
} from "./chunk-DC5ASEDD.js";
|
|
13
13
|
import {
|
|
14
14
|
LoginScreen
|
|
15
|
-
} from "./chunk-
|
|
15
|
+
} from "./chunk-LDHADSAI.js";
|
|
16
16
|
import {
|
|
17
17
|
ServiceMessageProvider
|
|
18
|
-
} from "./chunk-
|
|
18
|
+
} from "./chunk-HN6FG72A.js";
|
|
19
19
|
import {
|
|
20
20
|
AboutScreen
|
|
21
|
-
} from "./chunk-
|
|
21
|
+
} from "./chunk-7FBCK6I4.js";
|
|
22
22
|
import {
|
|
23
23
|
getDefaultScreenOptionsForLoginScreen
|
|
24
24
|
} from "./chunk-RGJ4RWVB.js";
|
|
25
25
|
import {
|
|
26
26
|
EnvironmentProvider
|
|
27
|
-
} from "./chunk-
|
|
27
|
+
} from "./chunk-4ZZKAQ7C.js";
|
|
28
28
|
import {
|
|
29
29
|
useMadConfig
|
|
30
|
-
} from "./chunk-
|
|
30
|
+
} from "./chunk-2EBLJCZH.js";
|
|
31
31
|
import {
|
|
32
32
|
CoreRoutes
|
|
33
33
|
} from "./chunk-UKAZW3CQ.js";
|
|
@@ -37,7 +37,7 @@ import {
|
|
|
37
37
|
import {
|
|
38
38
|
__spreadProps,
|
|
39
39
|
__spreadValues
|
|
40
|
-
} from "./chunk-
|
|
40
|
+
} from "./chunk-CWMXXUWU.js";
|
|
41
41
|
|
|
42
42
|
// src/utils/createMadCoreNavigator.tsx
|
|
43
43
|
import React from "react";
|
|
@@ -45,8 +45,7 @@ import { AppInsightsInitializer } from "@equinor/mad-insights";
|
|
|
45
45
|
var createMadCoreNavigator = (Stack) => {
|
|
46
46
|
function MadCoreNavigator(props) {
|
|
47
47
|
const config = useMadConfig();
|
|
48
|
-
if (!config)
|
|
49
|
-
return null;
|
|
48
|
+
if (!config) return null;
|
|
50
49
|
return /* @__PURE__ */ React.createElement(AppInsightsInitializer, { config: config.applicationInsights }, /* @__PURE__ */ React.createElement(EnvironmentProvider, null, /* @__PURE__ */ React.createElement(ServiceMessageProvider, null, /* @__PURE__ */ React.createElement(Stack.Navigator, __spreadProps(__spreadValues({}, props), { initialRouteName: CoreRoutes.LOGIN }), config.login.addScreenManually !== true && /* @__PURE__ */ React.createElement(
|
|
51
50
|
Stack.Screen,
|
|
52
51
|
{
|
|
@@ -4,7 +4,7 @@ import {
|
|
|
4
4
|
} from "./chunk-ZB37EIZB.js";
|
|
5
5
|
import {
|
|
6
6
|
__async
|
|
7
|
-
} from "./chunk-
|
|
7
|
+
} from "./chunk-CWMXXUWU.js";
|
|
8
8
|
|
|
9
9
|
// src/components/screens/create-incident/createIncident.ts
|
|
10
10
|
import { authenticateSilently } from "@equinor/mad-auth";
|
|
@@ -12,8 +12,7 @@ var createIncident = (data, env, serviceNow) => __async(void 0, null, function*
|
|
|
12
12
|
const baseUrl = getMadCommonBaseUrl(env);
|
|
13
13
|
const scopes = getMadCommonScopes(env);
|
|
14
14
|
const authenticationResponse = yield authenticateSilently(scopes);
|
|
15
|
-
if (!authenticationResponse)
|
|
16
|
-
throw new Error("Unable to authenticate silently");
|
|
15
|
+
if (!authenticationResponse) throw new Error("Unable to authenticate silently");
|
|
17
16
|
const fetchResponse = yield fetch(`${baseUrl}/ServiceNow/apps/${serviceNow}/incidents`, {
|
|
18
17
|
method: "POST",
|
|
19
18
|
body: JSON.stringify(data),
|