@egen-civitas/esm-framework 3.0.0 → 4.0.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/CHANGELOG.md +60 -0
- package/dist/index.d.ts +1 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +1 -0
- package/dist/internal.d.ts +1 -0
- package/dist/internal.d.ts.map +1 -1
- package/dist/internal.js +1 -0
- package/mock-jest.tsx +17 -2
- package/mock.tsx +17 -2
- package/package.json +13 -12
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,65 @@
|
|
|
1
1
|
# @egen-civitas/esm-framework
|
|
2
2
|
|
|
3
|
+
## 4.0.0
|
|
4
|
+
|
|
5
|
+
### Major Changes
|
|
6
|
+
|
|
7
|
+
- 5958a56: Framework neutre : suppression des derniers résidus hospitaliers (FHIR, patients, établissement de santé).
|
|
8
|
+
|
|
9
|
+
Retirés :
|
|
10
|
+
|
|
11
|
+
- `esm-api` : `fhirBaseUrl` et le traitement spécifique des URL FHIR (`_summary=data`) dans `egenFetch`.
|
|
12
|
+
- `esm-data-api` : type `FHIRLocationResource`.
|
|
13
|
+
- `esm-styleguide` : composant `LocationPicker` (basé sur l'API FHIR `Location` et le tag « Login Location ») ; pictogrammes médicaux `AppointmentsPictogram`, `AppointmentsAltPictogram`, `Assessment1Pictogram`, `Assessment2Pictogram`, `FacilityPictogram`, `RegistrationPictogram` (identifiants `egen-pict-appointments`, `-assessment-1`, `-assessment-2`, `-facility`, `-registration`) ; icônes `GenderFemaleIcon`, `GenderMaleIcon`, `GenderOtherIcon`, `GenderUnknownIcon`.
|
|
14
|
+
- `esm-translations` : clés `errorLoadingLoginLocations`, `searchForLocation` et clés orphelines patient/clinique (`Clinic`, `patientAvatarAlt`, `patientIdentifierSticker`, `patientLists`, `patientPhotoAlt`, `patientPhotoPlaceholder`, `seeMoreLists`) dans toutes les langues.
|
|
15
|
+
|
|
16
|
+
Ajouté : `HomePictogram` est désormais un pictogramme de maison neutre (`egen-pict-home`) au lieu d'un alias du bâtiment d'hôpital.
|
|
17
|
+
|
|
18
|
+
Vocabulaire neutre dans la documentation, les exemples, les stories et les tests (patient, médicaments, rendez-vous, pharmacie remplacés).
|
|
19
|
+
|
|
20
|
+
### Minor Changes
|
|
21
|
+
|
|
22
|
+
- 669cbd6: Réforme multiplateforme, lot P0 (docs/EGEN-FRAMEWORK-DEV.md) :
|
|
23
|
+
|
|
24
|
+
- esm-globals : `EgenTarget`, `CapabilityName`, `getEgenTarget()`, `isNativeTarget()`.
|
|
25
|
+
- esm-platform (nouveau package, 1.0.0) : contrats des capacités (annexe 2), `PlatformError`, détection de la cible, `getPlatform()` (adaptateur Web : session vide, `openExternal`, `lifecycle`, `files.select`, `camera`, `permissions` ; jamais de faux coffre ni de biométrie simulée. En natif, aucune capacité tant que le client de pont n'est pas branché, `ready` rejette `INCOMPATIBLE` sans Host), `createMockPlatform` (sous-chemin `/testing`).
|
|
26
|
+
- esm-framework : ré-export de `@egen-civitas/esm-platform` (`index`, `internal`, mocks).
|
|
27
|
+
- egen (CLI) : option `build --platform web|android|ios`.
|
|
28
|
+
- esm-api : `setAuthorizationProvider` (jeton fourni par la plateforme, rafraîchissement unique sur 401, rejeu GET/HEAD, politique `credentials`) ; `FetchConfig.replayOnUnauthorized` ; `isDevAuthBypassEnabled()` inerte en natif. Sans fournisseur, comportement inchangé.
|
|
29
|
+
- esm-dynamic-loading : overrides d'import map et de route map désactivés en cible native.
|
|
30
|
+
|
|
31
|
+
### Patch Changes
|
|
32
|
+
|
|
33
|
+
- Updated dependencies [d1d2d7d]
|
|
34
|
+
- Updated dependencies [669cbd6]
|
|
35
|
+
- Updated dependencies [b3d9419]
|
|
36
|
+
- Updated dependencies [5958a56]
|
|
37
|
+
- Updated dependencies [478e80c]
|
|
38
|
+
- @egen-civitas/esm-globals@2.1.0
|
|
39
|
+
- @egen-civitas/esm-routes@1.2.0
|
|
40
|
+
- @egen-civitas/esm-platform@1.1.0
|
|
41
|
+
- @egen-civitas/esm-api@3.0.0
|
|
42
|
+
- @egen-civitas/esm-dynamic-loading@2.1.0
|
|
43
|
+
- @egen-civitas/esm-translations@1.0.4
|
|
44
|
+
- @egen-civitas/esm-data-api@3.0.0
|
|
45
|
+
- @egen-civitas/esm-styleguide@4.0.0
|
|
46
|
+
- @egen-civitas/esm-react-utils@3.0.1
|
|
47
|
+
- @egen-civitas/esm-ai-framework@1.3.4
|
|
48
|
+
- @egen-civitas/esm-extensions@2.4.1
|
|
49
|
+
- @egen-civitas/esm-offline@1.0.4
|
|
50
|
+
|
|
51
|
+
## 3.1.0
|
|
52
|
+
|
|
53
|
+
### Minor Changes
|
|
54
|
+
|
|
55
|
+
- 3d304d5: Slot de navigation de la TopBar sans numéro de niveau : nouvelle constante `TOPBAR_NAV_SLOT` (`topbar-nav-slot`) et `TOPBAR_NAV_SLOTS` (tous les noms à lire, officiel d'abord). `TOPBAR_LEVEL2_NAV_SLOT` (`topbar-level2-nav`) est conservée, marquée `@deprecated`, et reste honorée : `SectionNavPanel` lit les deux slots (sans doublon). Les apps migrent leur `routes.json` vers le nouveau nom quand elles veulent ; aucune rupture.
|
|
56
|
+
|
|
57
|
+
### Patch Changes
|
|
58
|
+
|
|
59
|
+
- Updated dependencies [3d304d5]
|
|
60
|
+
- @egen-civitas/esm-extensions@2.4.0
|
|
61
|
+
- @egen-civitas/esm-styleguide@3.3.0
|
|
62
|
+
|
|
3
63
|
## 3.0.0
|
|
4
64
|
|
|
5
65
|
### Major Changes
|
package/dist/index.d.ts
CHANGED
package/dist/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,cAAc,0BAA0B,CAAC;AACzC,cAAc,uBAAuB,CAAC;AACtC,cAAc,0BAA0B,CAAC;AACzC,cAAc,2BAA2B,CAAC;AAC1C,cAAc,mCAAmC,CAAC;AAClD,cAAc,4BAA4B,CAAC;AAC3C,cAAc,kCAAkC,CAAC;AACjD,cAAc,wCAAwC,CAAC;AACvD,cAAc,8BAA8B,CAAC;AAC7C,cAAc,iCAAiC,CAAC;AAChD,cAAc,2BAA2B,CAAC;AAC1C,cAAc,8BAA8B,CAAC;AAC7C,cAAc,2BAA2B,CAAC;AAC1C,cAAc,+BAA+B,CAAC;AAC9C,cAAc,yBAAyB,CAAC;AACxC,cAAc,8BAA8B,CAAC;AAC7C,cAAc,gCAAgC,CAAC;AAC/C,cAAc,yBAAyB,CAAC;AACxC,cAAc,gCAAgC,CAAC"}
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,cAAc,0BAA0B,CAAC;AACzC,cAAc,4BAA4B,CAAC;AAC3C,cAAc,uBAAuB,CAAC;AACtC,cAAc,0BAA0B,CAAC;AACzC,cAAc,2BAA2B,CAAC;AAC1C,cAAc,mCAAmC,CAAC;AAClD,cAAc,4BAA4B,CAAC;AAC3C,cAAc,kCAAkC,CAAC;AACjD,cAAc,wCAAwC,CAAC;AACvD,cAAc,8BAA8B,CAAC;AAC7C,cAAc,iCAAiC,CAAC;AAChD,cAAc,2BAA2B,CAAC;AAC1C,cAAc,8BAA8B,CAAC;AAC7C,cAAc,2BAA2B,CAAC;AAC1C,cAAc,+BAA+B,CAAC;AAC9C,cAAc,yBAAyB,CAAC;AACxC,cAAc,8BAA8B,CAAC;AAC7C,cAAc,gCAAgC,CAAC;AAC/C,cAAc,yBAAyB,CAAC;AACxC,cAAc,gCAAgC,CAAC"}
|
package/dist/index.js
CHANGED
package/dist/internal.d.ts
CHANGED
|
@@ -9,6 +9,7 @@ export * from '@egen-civitas/esm-feature-flags';
|
|
|
9
9
|
export * from '@egen-civitas/esm-globals';
|
|
10
10
|
export * from '@egen-civitas/esm-navigation';
|
|
11
11
|
export * from '@egen-civitas/esm-offline';
|
|
12
|
+
export * from '@egen-civitas/esm-platform';
|
|
12
13
|
export * from '@egen-civitas/esm-react-utils';
|
|
13
14
|
export * from '@egen-civitas/esm-routes';
|
|
14
15
|
export * from '@egen-civitas/esm-state';
|
package/dist/internal.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"internal.d.ts","sourceRoot":"","sources":["../src/internal.ts"],"names":[],"mappings":"AAAA,cAAc,uBAAuB,CAAC;AACtC,cAAc,0BAA0B,CAAC;AACzC,cAAc,mCAAmC,CAAC;AAClD,cAAc,4BAA4B,CAAC;AAC3C,cAAc,kCAAkC,CAAC;AACjD,cAAc,wCAAwC,CAAC;AACvD,cAAc,8BAA8B,CAAC;AAC7C,cAAc,iCAAiC,CAAC;AAChD,cAAc,2BAA2B,CAAC;AAC1C,cAAc,8BAA8B,CAAC;AAC7C,cAAc,2BAA2B,CAAC;AAC1C,cAAc,+BAA+B,CAAC;AAC9C,cAAc,0BAA0B,CAAC;AACzC,cAAc,yBAAyB,CAAC;AACxC,cAAc,8BAA8B,CAAC;AAC7C,cAAc,gCAAgC,CAAC;AAC/C,cAAc,yBAAyB,CAAC"}
|
|
1
|
+
{"version":3,"file":"internal.d.ts","sourceRoot":"","sources":["../src/internal.ts"],"names":[],"mappings":"AAAA,cAAc,uBAAuB,CAAC;AACtC,cAAc,0BAA0B,CAAC;AACzC,cAAc,mCAAmC,CAAC;AAClD,cAAc,4BAA4B,CAAC;AAC3C,cAAc,kCAAkC,CAAC;AACjD,cAAc,wCAAwC,CAAC;AACvD,cAAc,8BAA8B,CAAC;AAC7C,cAAc,iCAAiC,CAAC;AAChD,cAAc,2BAA2B,CAAC;AAC1C,cAAc,8BAA8B,CAAC;AAC7C,cAAc,2BAA2B,CAAC;AAC1C,cAAc,4BAA4B,CAAC;AAC3C,cAAc,+BAA+B,CAAC;AAC9C,cAAc,0BAA0B,CAAC;AACzC,cAAc,yBAAyB,CAAC;AACxC,cAAc,8BAA8B,CAAC;AAC7C,cAAc,gCAAgC,CAAC;AAC/C,cAAc,yBAAyB,CAAC"}
|
package/dist/internal.js
CHANGED
|
@@ -9,6 +9,7 @@ export * from "@egen-civitas/esm-feature-flags";
|
|
|
9
9
|
export * from "@egen-civitas/esm-globals";
|
|
10
10
|
export * from "@egen-civitas/esm-navigation";
|
|
11
11
|
export * from "@egen-civitas/esm-offline";
|
|
12
|
+
export * from "@egen-civitas/esm-platform";
|
|
12
13
|
export * from "@egen-civitas/esm-react-utils";
|
|
13
14
|
export * from "@egen-civitas/esm-routes";
|
|
14
15
|
export * from "@egen-civitas/esm-state";
|
package/mock-jest.tsx
CHANGED
|
@@ -2,6 +2,7 @@ import React, { useState } from 'react';
|
|
|
2
2
|
import { NEVER } from 'rxjs';
|
|
3
3
|
import type {} from '@egen-civitas/esm-globals';
|
|
4
4
|
import * as utils from '@egen-civitas/esm-utils/mock';
|
|
5
|
+
import { createMockPlatform } from '@egen-civitas/esm-platform/testing';
|
|
5
6
|
import dayjs from 'dayjs';
|
|
6
7
|
|
|
7
8
|
window.i18next = { ...window.i18next, language: 'en' };
|
|
@@ -62,6 +63,20 @@ export const goBackInHistory = jest.fn();
|
|
|
62
63
|
export const useConnectivity = jest.fn().mockReturnValue(true);
|
|
63
64
|
export const subscribeConnectivity = jest.fn();
|
|
64
65
|
|
|
66
|
+
/* esm-platform : un Platform de test sans Host. Les erreurs et la détection restent les vraies implémentations ;
|
|
67
|
+
* `getPlatform` retourne un Platform dont aucune capacité n'est fournie (comme en production sans adaptateur).
|
|
68
|
+
* Pour simuler une capacité : `getPlatform.mockReturnValue(createMockPlatform({ capabilities: { … } }))`. */
|
|
69
|
+
export {
|
|
70
|
+
PlatformError,
|
|
71
|
+
isPlatformError,
|
|
72
|
+
unavailable,
|
|
73
|
+
getPlatformEnvironment,
|
|
74
|
+
isNativePlatform,
|
|
75
|
+
hasHostBridge,
|
|
76
|
+
} from '@egen-civitas/esm-platform';
|
|
77
|
+
export { createMockPlatform };
|
|
78
|
+
export const getPlatform = jest.fn(() => createMockPlatform());
|
|
79
|
+
|
|
65
80
|
/* esm-styleguide */
|
|
66
81
|
export const showNotification = jest.fn();
|
|
67
82
|
export const showActionableNotification = jest.fn();
|
|
@@ -73,6 +88,8 @@ export const registerNavBehavior = jest.fn(() => () => {});
|
|
|
73
88
|
export const getNavBehavior = jest.fn();
|
|
74
89
|
// Constantes et validateurs purs : on garde les vraies implémentations (aucune raison de les simuler).
|
|
75
90
|
export {
|
|
91
|
+
TOPBAR_NAV_SLOT,
|
|
92
|
+
TOPBAR_NAV_SLOTS,
|
|
76
93
|
TOPBAR_LEVEL2_NAV_SLOT,
|
|
77
94
|
NAV_ALL_WORKSPACES,
|
|
78
95
|
isNavEntryMeta,
|
|
@@ -157,10 +174,8 @@ export const EgenDateRangePicker = jest.fn(({ id, labelText, value = [], onChang
|
|
|
157
174
|
/* esm-utils */
|
|
158
175
|
export {
|
|
159
176
|
getDefaultsFromConfigSchema,
|
|
160
|
-
selectPreferredName,
|
|
161
177
|
} from '@egen-civitas/esm-utils';
|
|
162
178
|
|
|
163
|
-
export const age = jest.fn((arg) => utils.age(arg));
|
|
164
179
|
|
|
165
180
|
export function isVersionSatisfied() {
|
|
166
181
|
return true;
|
package/mock.tsx
CHANGED
|
@@ -4,6 +4,7 @@ import { NEVER } from 'rxjs';
|
|
|
4
4
|
import { vi } from 'vitest';
|
|
5
5
|
import type {} from '@egen-civitas/esm-globals';
|
|
6
6
|
import * as utils from '@egen-civitas/esm-utils/mock';
|
|
7
|
+
import { createMockPlatform } from '@egen-civitas/esm-platform/testing';
|
|
7
8
|
|
|
8
9
|
window.i18next = { ...window.i18next, language: 'en' };
|
|
9
10
|
|
|
@@ -63,6 +64,20 @@ export const goBackInHistory = vi.fn();
|
|
|
63
64
|
export const useConnectivity = vi.fn().mockReturnValue(true);
|
|
64
65
|
export const subscribeConnectivity = vi.fn();
|
|
65
66
|
|
|
67
|
+
/* esm-platform : un Platform de test sans Host. Les erreurs et la détection restent les vraies implémentations ;
|
|
68
|
+
* `getPlatform` retourne un Platform dont aucune capacité n'est fournie (comme en production sans adaptateur).
|
|
69
|
+
* Pour simuler une capacité : `getPlatform.mockReturnValue(createMockPlatform({ capabilities: { … } }))`. */
|
|
70
|
+
export {
|
|
71
|
+
PlatformError,
|
|
72
|
+
isPlatformError,
|
|
73
|
+
unavailable,
|
|
74
|
+
getPlatformEnvironment,
|
|
75
|
+
isNativePlatform,
|
|
76
|
+
hasHostBridge,
|
|
77
|
+
} from '@egen-civitas/esm-platform';
|
|
78
|
+
export { createMockPlatform };
|
|
79
|
+
export const getPlatform = vi.fn(() => createMockPlatform());
|
|
80
|
+
|
|
66
81
|
/* esm-styleguide */
|
|
67
82
|
export const showNotification = vi.fn();
|
|
68
83
|
export const showActionableNotification = vi.fn();
|
|
@@ -74,6 +89,8 @@ export const registerNavBehavior = vi.fn(() => () => {});
|
|
|
74
89
|
export const getNavBehavior = vi.fn();
|
|
75
90
|
// Constantes et validateurs purs : on garde les vraies implémentations (aucune raison de les simuler).
|
|
76
91
|
export {
|
|
92
|
+
TOPBAR_NAV_SLOT,
|
|
93
|
+
TOPBAR_NAV_SLOTS,
|
|
77
94
|
TOPBAR_LEVEL2_NAV_SLOT,
|
|
78
95
|
NAV_ALL_WORKSPACES,
|
|
79
96
|
isNavEntryMeta,
|
|
@@ -158,10 +175,8 @@ export const EgenDateRangePicker = vi.fn(({ id, labelText, value = [], onChange,
|
|
|
158
175
|
/* esm-utils */
|
|
159
176
|
export {
|
|
160
177
|
getDefaultsFromConfigSchema,
|
|
161
|
-
selectPreferredName,
|
|
162
178
|
} from '@egen-civitas/esm-utils';
|
|
163
179
|
|
|
164
|
-
export const age = vi.fn((arg) => utils.age(arg));
|
|
165
180
|
|
|
166
181
|
export function isVersionSatisfied() {
|
|
167
182
|
return true;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@egen-civitas/esm-framework",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "4.0.0",
|
|
4
4
|
"license": "MPL-2.0",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "dist/index.js",
|
|
@@ -66,25 +66,26 @@
|
|
|
66
66
|
"access": "public"
|
|
67
67
|
},
|
|
68
68
|
"dependencies": {
|
|
69
|
-
"@egen-civitas/esm-ai-framework": "^1.3.
|
|
70
|
-
"@egen-civitas/esm-api": "^
|
|
69
|
+
"@egen-civitas/esm-ai-framework": "^1.3.4",
|
|
70
|
+
"@egen-civitas/esm-api": "^3.0.0",
|
|
71
71
|
"@egen-civitas/esm-config": "^2.0.0",
|
|
72
72
|
"@egen-civitas/esm-context": "^1.0.2",
|
|
73
|
-
"@egen-civitas/esm-data-api": "^
|
|
74
|
-
"@egen-civitas/esm-dynamic-loading": "^2.0
|
|
73
|
+
"@egen-civitas/esm-data-api": "^3.0.0",
|
|
74
|
+
"@egen-civitas/esm-dynamic-loading": "^2.1.0",
|
|
75
75
|
"@egen-civitas/esm-error-handling": "^1.0.2",
|
|
76
76
|
"@egen-civitas/esm-expression-evaluator": "^1.0.0",
|
|
77
|
-
"@egen-civitas/esm-extensions": "^2.1
|
|
77
|
+
"@egen-civitas/esm-extensions": "^2.4.1",
|
|
78
78
|
"@egen-civitas/esm-feature-flags": "^1.0.2",
|
|
79
|
-
"@egen-civitas/esm-globals": "^2.
|
|
79
|
+
"@egen-civitas/esm-globals": "^2.1.0",
|
|
80
80
|
"@egen-civitas/esm-navigation": "^1.0.0",
|
|
81
|
-
"@egen-civitas/esm-offline": "^1.0.
|
|
82
|
-
"@egen-civitas/esm-
|
|
83
|
-
"@egen-civitas/esm-
|
|
81
|
+
"@egen-civitas/esm-offline": "^1.0.4",
|
|
82
|
+
"@egen-civitas/esm-platform": "^1.1.0",
|
|
83
|
+
"@egen-civitas/esm-react-utils": "^3.0.1",
|
|
84
|
+
"@egen-civitas/esm-routes": "^1.2.0",
|
|
84
85
|
"@egen-civitas/esm-state": "^1.0.3",
|
|
85
|
-
"@egen-civitas/esm-styleguide": "^
|
|
86
|
+
"@egen-civitas/esm-styleguide": "^4.0.0",
|
|
86
87
|
"@egen-civitas/esm-tenant": "^1.0.0",
|
|
87
|
-
"@egen-civitas/esm-translations": "^1.0.
|
|
88
|
+
"@egen-civitas/esm-translations": "^1.0.4",
|
|
88
89
|
"@egen-civitas/esm-utils": "^2.0.0"
|
|
89
90
|
},
|
|
90
91
|
"peerDependencies": {
|