@topconsultnpm/sdkui-react-beta 6.12.103 → 6.12.105

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.
@@ -499,7 +499,7 @@ const TMLoginForm = (props) => {
499
499
  if (!ra) {
500
500
  ra = [];
501
501
  }
502
- ;
502
+ ; //NOSONAR
503
503
  let maxId = ra.length > 0
504
504
  ? ra.reduce((max, obj) => (obj.id > max.id ? obj : max), ra[0]).id //NOSONAR
505
505
  : 0;
@@ -584,6 +584,16 @@ const CeredentialContainer = forwardRef(({ isMobile = false, authMode = Authenti
584
584
  return usernameRef.current;
585
585
  });
586
586
  const usernameRef = useRef(null);
587
+ useEffect(() => {
588
+ setTimeout(() => {
589
+ const autoUser = usernameRef.current?.value ?? '';
590
+ const autoPass = passwordRef.current?.value ?? '';
591
+ if (autoUser !== username)
592
+ onUsernameChanged(autoUser);
593
+ if (autoPass !== password)
594
+ onPasswordChanged(autoPass);
595
+ }, 100);
596
+ }, []);
587
597
  useEffect(() => {
588
598
  if (!secondaryRef)
589
599
  return;
@@ -23,9 +23,13 @@ export class UserSettings {
23
23
  // Ensure userID and archiveID are set
24
24
  settings.userID = userID;
25
25
  settings.archiveID = archiveID;
26
+ // Update the CSS variable for font size
26
27
  document.documentElement.style.setProperty('--base-font-size', settings.themeSettings.fontSize);
27
28
  // Wrap the settings object in a Proxy to intercept property updates
28
- return createProxy(settings, UserSettings.SaveSettings);
29
+ const proxiedSettings = createProxy(settings, UserSettings.SaveSettings);
30
+ // Automatically set the global userSettings
31
+ SDKUI_Globals.userSettings = proxiedSettings;
32
+ return proxiedSettings;
29
33
  }
30
34
  /** Save settings to local storage or other sources */
31
35
  static SaveSettings(settings) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@topconsultnpm/sdkui-react-beta",
3
- "version": "6.12.103",
3
+ "version": "6.12.105",
4
4
  "description": "",
5
5
  "scripts": {
6
6
  "test": "echo \"Error: no test specified\" && exit 1",