passbolt-styleguide 5.17.2 → 5.17.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.
Files changed (96) hide show
  1. package/RELEASE_NOTES.md +2 -4
  2. package/build/css/help.min.css +2 -2
  3. package/build/css/public.min.css +2 -2
  4. package/build/css/themes/default/api_authentication.min.css +2 -2
  5. package/build/css/themes/default/api_cloud.min.css +2 -2
  6. package/build/css/themes/default/api_main.min.css +2 -2
  7. package/build/css/themes/default/api_reports.min.css +2 -2
  8. package/build/css/themes/default/api_webinstaller.min.css +2 -2
  9. package/build/css/themes/default/ext_app.min.css +3 -3
  10. package/build/css/themes/default/ext_authentication.min.css +2 -2
  11. package/build/css/themes/default/ext_external.min.css +2 -2
  12. package/build/css/themes/default/ext_in_form_cta.min.css +2 -2
  13. package/build/css/themes/default/ext_in_form_menu.min.css +2 -2
  14. package/build/css/themes/default/ext_quickaccess.min.css +2 -2
  15. package/build/css/themes/midgar/api_authentication.min.css +2 -2
  16. package/build/css/themes/midgar/api_main.min.css +2 -2
  17. package/build/css/themes/midgar/api_reports.min.css +2 -2
  18. package/build/css/themes/midgar/ext_app.min.css +3 -3
  19. package/build/css/themes/midgar/ext_authentication.min.css +2 -2
  20. package/build/css/themes/midgar/ext_in_form_cta.min.css +2 -2
  21. package/build/css/themes/midgar/ext_in_form_menu.min.css +2 -2
  22. package/build/css/themes/midgar/ext_quickaccess.min.css +2 -2
  23. package/build/css/themes/solarized_dark/api_authentication.min.css +2 -2
  24. package/build/css/themes/solarized_dark/api_main.min.css +2 -2
  25. package/build/css/themes/solarized_dark/api_reports.min.css +2 -2
  26. package/build/css/themes/solarized_dark/ext_app.min.css +3 -3
  27. package/build/css/themes/solarized_dark/ext_authentication.min.css +2 -2
  28. package/build/css/themes/solarized_dark/ext_in_form_cta.min.css +2 -2
  29. package/build/css/themes/solarized_dark/ext_in_form_menu.min.css +2 -2
  30. package/build/css/themes/solarized_dark/ext_quickaccess.min.css +2 -2
  31. package/build/css/themes/solarized_light/api_authentication.min.css +2 -2
  32. package/build/css/themes/solarized_light/api_main.min.css +2 -2
  33. package/build/css/themes/solarized_light/api_reports.min.css +2 -2
  34. package/build/css/themes/solarized_light/ext_app.min.css +3 -3
  35. package/build/css/themes/solarized_light/ext_authentication.min.css +2 -2
  36. package/build/css/themes/solarized_light/ext_in_form_cta.min.css +2 -2
  37. package/build/css/themes/solarized_light/ext_in_form_menu.min.css +2 -2
  38. package/build/css/themes/solarized_light/ext_quickaccess.min.css +2 -2
  39. package/build/js/dist/api-app.js +1 -1
  40. package/build/locales/cs-CZ/common.json +96 -158
  41. package/build/locales/de-DE/common.json +90 -146
  42. package/build/locales/en-UK/common.json +1 -0
  43. package/build/locales/es-ES/common.json +92 -148
  44. package/build/locales/fr-FR/common.json +92 -148
  45. package/build/locales/it-IT/common.json +93 -149
  46. package/build/locales/ja-JP/common.json +92 -145
  47. package/build/locales/ko-KR/common.json +14 -67
  48. package/build/locales/lt-LT/common.json +101 -163
  49. package/build/locales/nl-NL/common.json +95 -151
  50. package/build/locales/pl-PL/common.json +93 -155
  51. package/build/locales/pt-BR/common.json +94 -150
  52. package/build/locales/ro-RO/common.json +88 -147
  53. package/build/locales/ru-RU/common.json +96 -158
  54. package/build/locales/sl-SI/common.json +96 -158
  55. package/build/locales/sv-SE/common.json +95 -151
  56. package/build/locales/uk-UA/common.json +104 -166
  57. package/package.json +1 -1
  58. package/src/locales/cs-CZ/common.json +96 -158
  59. package/src/locales/de-DE/common.json +90 -146
  60. package/src/locales/en-UK/common.json +1 -0
  61. package/src/locales/es-ES/common.json +92 -148
  62. package/src/locales/fr-FR/common.json +92 -148
  63. package/src/locales/it-IT/common.json +93 -149
  64. package/src/locales/ja-JP/common.json +92 -145
  65. package/src/locales/ko-KR/common.json +14 -67
  66. package/src/locales/lt-LT/common.json +101 -163
  67. package/src/locales/nl-NL/common.json +95 -151
  68. package/src/locales/pl-PL/common.json +93 -155
  69. package/src/locales/pt-BR/common.json +94 -150
  70. package/src/locales/ro-RO/common.json +88 -147
  71. package/src/locales/ru-RU/common.json +96 -158
  72. package/src/locales/sl-SI/common.json +96 -158
  73. package/src/locales/sv-SE/common.json +95 -151
  74. package/src/locales/uk-UA/common.json +104 -166
  75. package/src/react-extension/components/Administration/DisplayAdministrationWorkspaceActions/DisplayAdministrationMfaActions/DisplayAdministrationMfaActions.js +6 -14
  76. package/src/react-extension/components/Administration/DisplayOfflineAdministration/DisplayOfflineAdministration.js +29 -6
  77. package/src/react-extension/components/Administration/DisplayOfflineAdministration/DisplayOfflineAdministration.test.js +28 -0
  78. package/src/react-extension/components/Administration/DisplayOfflineAdministration/DisplayOfflineAdministration.test.page.js +10 -0
  79. package/src/react-extension/components/MFA/DisplayProviderList/DisplayProviderList.js +14 -0
  80. package/src/react-extension/components/MFA/DisplayProviderList/DisplayProviderList.test.js +15 -0
  81. package/src/react-extension/components/Resource/DisplayResourcesList/DisplayResourcesListContextualMenu.js +1 -1
  82. package/src/react-extension/components/Resource/DisplayResourcesList/DisplayResourcesListContextualMenu.test.js +4 -3
  83. package/src/react-extension/contexts/Authentication/AuthenticationLoginContext.js +15 -3
  84. package/src/react-extension/contexts/Authentication/AuthenticationLoginContext.test.js +50 -0
  85. package/src/react-quickaccess/components/LoginPage/LoginPage.js +6 -1
  86. package/src/react-quickaccess/components/LoginPage/LoginPage.test.js +16 -0
  87. package/src/react-web-integration/lib/InForm/InFormManager.js +4 -14
  88. package/src/react-web-integration/lib/InForm/InformManager.test.js +6 -53
  89. package/src/react-web-integration/services/DomExtraction/FieldAggregatorService.js +1 -23
  90. package/src/react-web-integration/services/DomExtraction/FieldAggregatorService.test.js +0 -37
  91. package/src/react-web-integration/services/ShadowDom/ShadowDomFocusHealerService.js +2 -2
  92. package/src/react-web-integration/services/ShadowDom/ShadowDomFocusHealerService.test.js +6 -18
  93. package/src/react-web-integration/services/ShadowDom/ShadowMutationObserverService.js +3 -5
  94. package/src/react-web-integration/services/ShadowDom/ShadowMutationObserverService.test.js +1 -12
  95. package/src/shared/services/rbacs/uiActionEnumeration.js +1 -0
  96. package/src/shared/services/rbacs/uiActionEnumeration.test.js +3 -2
@@ -158,9 +158,7 @@ describe("ShadowDomFocusHealerService", () => {
158
158
  focusHandler({ composedPath: () => [input, document.body, document] });
159
159
 
160
160
  expect(ShadowRootCacheService.invalidate).not.toHaveBeenCalled();
161
- expect(ShadowMutationObserverService.notifyShadowMutationSubscribers).toHaveBeenCalledWith(document, [], true, {
162
- fromFocus: true,
163
- });
161
+ expect(ShadowMutationObserverService.notifyShadowMutationSubscribers).toHaveBeenCalledWith(document, [], true);
164
162
  });
165
163
 
166
164
  it("should not trigger a rescan when the focused light-DOM input is already tracked", () => {
@@ -204,9 +202,7 @@ describe("ShadowDomFocusHealerService", () => {
204
202
 
205
203
  expect(ShadowRootCacheService.invalidate).toHaveBeenCalledTimes(1);
206
204
  expect(ShadowRootCacheService.invalidate).toHaveBeenCalledWith(document);
207
- expect(ShadowMutationObserverService.notifyShadowMutationSubscribers).toHaveBeenCalledWith(document, [], true, {
208
- fromFocus: true,
209
- });
205
+ expect(ShadowMutationObserverService.notifyShadowMutationSubscribers).toHaveBeenCalledWith(document, [], true);
210
206
  });
211
207
 
212
208
  it("should invalidate the parent scope when the shadow root in the path is not an instance of ShadowRoot (cross-realm/isolated world)", () => {
@@ -224,9 +220,7 @@ describe("ShadowDomFocusHealerService", () => {
224
220
  focusHandler({ composedPath: () => [input, crossRealmShadowRoot, host, document.body, document] });
225
221
 
226
222
  expect(ShadowRootCacheService.invalidate).toHaveBeenCalledWith(document);
227
- expect(ShadowMutationObserverService.notifyShadowMutationSubscribers).toHaveBeenCalledWith(document, [], true, {
228
- fromFocus: true,
229
- });
223
+ expect(ShadowMutationObserverService.notifyShadowMutationSubscribers).toHaveBeenCalledWith(document, [], true);
230
224
  });
231
225
 
232
226
  it("should invalidate the parent scopes of late-attached nested roots", () => {
@@ -249,9 +243,7 @@ describe("ShadowDomFocusHealerService", () => {
249
243
  expect(ShadowRootCacheService.invalidate).toHaveBeenCalledWith(outerRoot);
250
244
  expect(ShadowRootCacheService.invalidate).toHaveBeenCalledWith(document);
251
245
  expect(ShadowMutationObserverService.notifyShadowMutationSubscribers).toHaveBeenCalledTimes(1);
252
- expect(ShadowMutationObserverService.notifyShadowMutationSubscribers).toHaveBeenCalledWith(document, [], true, {
253
- fromFocus: true,
254
- });
246
+ expect(ShadowMutationObserverService.notifyShadowMutationSubscribers).toHaveBeenCalledWith(document, [], true);
255
247
  });
256
248
 
257
249
  it("should not invalidate when the focused field is inside a known shadow root", () => {
@@ -288,9 +280,7 @@ describe("ShadowDomFocusHealerService", () => {
288
280
  focusHandler({ composedPath: () => [input, shadowRoot, host, document.body, document] });
289
281
 
290
282
  expect(ShadowRootCacheService.invalidate).toHaveBeenCalledWith(document);
291
- expect(ShadowMutationObserverService.notifyShadowMutationSubscribers).toHaveBeenCalledWith(document, [], true, {
292
- fromFocus: true,
293
- });
283
+ expect(ShadowMutationObserverService.notifyShadowMutationSubscribers).toHaveBeenCalledWith(document, [], true);
294
284
  });
295
285
 
296
286
  it("should invalidate only the scope of the unknown root when its parent root is already known", () => {
@@ -316,9 +306,7 @@ describe("ShadowDomFocusHealerService", () => {
316
306
 
317
307
  expect(ShadowRootCacheService.invalidate).toHaveBeenCalledTimes(1);
318
308
  expect(ShadowRootCacheService.invalidate).toHaveBeenCalledWith(outerRoot);
319
- expect(ShadowMutationObserverService.notifyShadowMutationSubscribers).toHaveBeenCalledWith(document, [], true, {
320
- fromFocus: true,
321
- });
309
+ expect(ShadowMutationObserverService.notifyShadowMutationSubscribers).toHaveBeenCalledWith(document, [], true);
322
310
  });
323
311
  });
324
312
  });
@@ -103,7 +103,7 @@ class ShadowMutationObserverService {
103
103
 
104
104
  /**
105
105
  * Register a subscriber to the shadow root mutations
106
- * @param {(root: Document|ShadowRoot|Element, mutations: MutationRecord[], shadowRootsChanged: boolean, options: {fromFocus?: boolean}) => void} callback
106
+ * @param {(root: Document|ShadowRoot|Element, mutations: MutationRecord[], shadowRootsChanged: boolean) => void} callback
107
107
  * @return {() => void} unsubscribe closure — must be called in the consumer's teardown.
108
108
  */
109
109
  static subscribeToShadowMutations(callback) {
@@ -116,13 +116,11 @@ class ShadowMutationObserverService {
116
116
  * @param {Document|ShadowRoot|Element} root
117
117
  * @param {MutationRecord[]} mutations
118
118
  * @param {boolean} shadowRootsChanged
119
- * @param {object} [options]
120
- * @param {boolean} [options.fromFocus=false] Whether the notification comes from the user focusing a field.
121
119
  */
122
- static notifyShadowMutationSubscribers(root, mutations, shadowRootsChanged, options = {}) {
120
+ static notifyShadowMutationSubscribers(root, mutations, shadowRootsChanged) {
123
121
  for (const callback of ShadowMutationObserverService._shadowMutationSubscribers) {
124
122
  try {
125
- callback(root, mutations, shadowRootsChanged, options);
123
+ callback(root, mutations, shadowRootsChanged);
126
124
  } catch (error) {
127
125
  console.warn("ShadowMutationObserverService shadow-mutation subscriber threw", error);
128
126
  }
@@ -221,18 +221,7 @@ describe("ShadowMutationObserverService", () => {
221
221
 
222
222
  ShadowMutationObserverService.notifyShadowMutationSubscribers(root, mutations, true);
223
223
 
224
- expect(callback).toHaveBeenCalledWith(root, mutations, true, {});
225
- });
226
-
227
- it("should forward the notification options to the subscribers", () => {
228
- expect.assertions(1);
229
-
230
- const callback = jest.fn();
231
- ShadowMutationObserverService._shadowMutationSubscribers.add(callback);
232
-
233
- ShadowMutationObserverService.notifyShadowMutationSubscribers(document, [], true, { fromFocus: true });
234
-
235
- expect(callback).toHaveBeenCalledWith(document, [], true, { fromFocus: true });
224
+ expect(callback).toHaveBeenCalledWith(root, mutations, true);
236
225
  });
237
226
 
238
227
  it("should isolate a throwing subscriber so the others still run", () => {
@@ -30,4 +30,5 @@ export const uiActions = {
30
30
  DUO_CONFIGURATION: "Duo.configuration",
31
31
  AVATAR_UPLOAD: "Avatar.upload",
32
32
  SHARE_FOLDER: "Folders.share",
33
+ PASSKEYS_CONFIGURATION: "Passkeys.configuration",
33
34
  };
@@ -16,9 +16,9 @@ import { uiActions } from "./uiActionEnumeration";
16
16
 
17
17
  describe("uiActions", () => {
18
18
  it("should have the expected UI action keys", () => {
19
- expect.assertions(18);
19
+ expect.assertions(19);
20
20
 
21
- expect(Object.keys(uiActions).length).toEqual(17);
21
+ expect(Object.keys(uiActions).length).toEqual(18);
22
22
  expect(uiActions["FOLDERS_USE"]).toEqual("Folders.use");
23
23
  expect(uiActions["RESOURCES_IMPORT"]).toEqual("Resources.import");
24
24
  expect(uiActions["RESOURCES_EXPORT"]).toEqual("Resources.export");
@@ -36,5 +36,6 @@ describe("uiActions", () => {
36
36
  expect(uiActions["AVATAR_UPLOAD"]).toEqual("Avatar.upload");
37
37
  expect(uiActions["SHARE_FOLDER"]).toEqual("Folders.share");
38
38
  expect(uiActions["PROFIL_ACCOUNT_RECOVERY"]).toEqual("Profil.accountRecovery");
39
+ expect(uiActions["PASSKEYS_CONFIGURATION"]).toEqual("Passkeys.configuration");
39
40
  });
40
41
  });