@magmamath/frontend-config 1.0.19-hf.4 → 1.0.20

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/dist/index.d.mts CHANGED
@@ -35,6 +35,7 @@ declare enum Platform {
35
35
  TEACHERS_WEB = "TEACHERS",
36
36
  DISTRICT_DASHBOARD = "DISTRICT",
37
37
  AUTH_WEB = "AUTH_WEB",
38
+ WEB_ADMIN = "WEB_ADMIN",
38
39
  MOBILE = "MOBILE"
39
40
  }
40
41
  declare enum Environment {
@@ -98,6 +99,10 @@ declare enum SSO {
98
99
  CANVAS = "CANVAS",
99
100
  QR_CODE = "QR_CODE"
100
101
  }
102
+ declare enum ApiRegion {
103
+ MAIN = "MAIN",
104
+ CANADA = "CANADA"
105
+ }
101
106
 
102
107
  declare enum MatrixMode {
103
108
  SKILL = "SKILL",
@@ -279,11 +284,30 @@ type MobileVarsPreset = {
279
284
  };
280
285
  };
281
286
 
287
+ type RegionSpecificWebAdminVars = {
288
+ API_URL: string;
289
+ CDN_HOST: string;
290
+ STUDENTS_WEB_URL: string;
291
+ DISTRICT_WEB_URL: string;
292
+ TEACHERS_WEB_URL: string;
293
+ };
294
+ type WebAdminCommon = {
295
+ MARS_URL: string;
296
+ PROD_URL: string;
297
+ };
298
+ type WebAdminVars = RegionSpecificWebAdminVars & WebAdminCommon;
299
+ type WebAdminVarsPreset = {
300
+ [key in Locale]: {
301
+ [key in Environment]: WebAdminVars;
302
+ };
303
+ };
304
+
282
305
  type EnvPreset = Readonly<{
283
306
  [Platform.STUDENTS_WEB]: StudentsWebVarsPreset;
284
307
  [Platform.TEACHERS_WEB]: TeachersWebVarsPreset;
285
308
  [Platform.DISTRICT_DASHBOARD]: DistrictWebVarsPreset;
286
309
  [Platform.AUTH_WEB]: AuthWebVarsPreset;
310
+ [Platform.WEB_ADMIN]: WebAdminVarsPreset;
287
311
  [Platform.MOBILE]: MobileVarsPreset;
288
312
  }>;
289
313
  type EnvironmentVars<P extends Platform> = EnvPreset[P][Locale][Environment];
@@ -424,6 +448,15 @@ type AuthWebLocaleConfig<T extends SSOVariant> = {
424
448
  locale: Locale;
425
449
  };
426
450
 
451
+ type WebAdminLocaleConfig = {
452
+ name: string;
453
+ icon: ComponentType<IconProps>;
454
+ locale: Locale;
455
+ isPrimaryRegion: boolean;
456
+ regionGroup: string;
457
+ apiRegion: ApiRegion;
458
+ };
459
+
427
460
  type CommonLocaleConfig = Readonly<{
428
461
  name: string;
429
462
  languageName: string;
@@ -444,6 +477,9 @@ type LocalePreset = {
444
477
  [Platform.AUTH_WEB]: {
445
478
  [key in Locale]: AuthWebLocaleConfig<SSOByLocale[key]>;
446
479
  };
480
+ [Platform.WEB_ADMIN]: {
481
+ [key in Locale]: WebAdminLocaleConfig;
482
+ };
447
483
  [Platform.MOBILE]: {
448
484
  [key in Locale]: AuthWebLocaleConfig<SSOByLocale[key]>;
449
485
  };
@@ -488,10 +524,11 @@ declare class AppConfigManager<P extends Platform, L extends Locale> {
488
524
  TEACHERS: TeachersWebVarsPreset;
489
525
  DISTRICT: DistrictWebVarsPreset;
490
526
  AUTH_WEB: AuthWebVarsPreset;
527
+ WEB_ADMIN: WebAdminVarsPreset;
491
528
  MOBILE: MobileVarsPreset;
492
529
  }>;
493
530
  localePreset: LocalePreset;
494
531
  };
495
532
  }
496
533
 
497
- export { AppConfigManager, type AuthWebBaseVars, type AuthWebVars, type AuthWebVarsPreset, DateFormat, DateLocale, type DistrictCommon, type DistrictDashboardVars, type DistrictWebVarsPreset, type EnvPreset, Environment, type EnvironmentVars, Locale, LoginSource, MatrixMode, type MobileBaseVars, type MobileCommon, type MobileVars, type MobileVarsPreset, Platform, PlatformBuildTarget, SSO, type SSOByLocale, type SSOConfig, type SSOVariant, type SSO_DE, type SSO_SE, type SSO_UK, type SSO_US, Source, type StudentsWebCommon, type StudentsWebVars, type StudentsWebVarsPreset, type TeachersWebCommon, type TeachersWebVars, type TeachersWebVarsPreset, buildTargetToEnvironment };
534
+ export { ApiRegion, AppConfigManager, DateFormat, DateLocale, type EnvPreset, Environment, type EnvironmentVars, Locale, LoginSource, MatrixMode, Platform, PlatformBuildTarget, SSO, type SSOConfig, Source, buildTargetToEnvironment };
package/dist/index.d.ts CHANGED
@@ -35,6 +35,7 @@ declare enum Platform {
35
35
  TEACHERS_WEB = "TEACHERS",
36
36
  DISTRICT_DASHBOARD = "DISTRICT",
37
37
  AUTH_WEB = "AUTH_WEB",
38
+ WEB_ADMIN = "WEB_ADMIN",
38
39
  MOBILE = "MOBILE"
39
40
  }
40
41
  declare enum Environment {
@@ -98,6 +99,10 @@ declare enum SSO {
98
99
  CANVAS = "CANVAS",
99
100
  QR_CODE = "QR_CODE"
100
101
  }
102
+ declare enum ApiRegion {
103
+ MAIN = "MAIN",
104
+ CANADA = "CANADA"
105
+ }
101
106
 
102
107
  declare enum MatrixMode {
103
108
  SKILL = "SKILL",
@@ -279,11 +284,30 @@ type MobileVarsPreset = {
279
284
  };
280
285
  };
281
286
 
287
+ type RegionSpecificWebAdminVars = {
288
+ API_URL: string;
289
+ CDN_HOST: string;
290
+ STUDENTS_WEB_URL: string;
291
+ DISTRICT_WEB_URL: string;
292
+ TEACHERS_WEB_URL: string;
293
+ };
294
+ type WebAdminCommon = {
295
+ MARS_URL: string;
296
+ PROD_URL: string;
297
+ };
298
+ type WebAdminVars = RegionSpecificWebAdminVars & WebAdminCommon;
299
+ type WebAdminVarsPreset = {
300
+ [key in Locale]: {
301
+ [key in Environment]: WebAdminVars;
302
+ };
303
+ };
304
+
282
305
  type EnvPreset = Readonly<{
283
306
  [Platform.STUDENTS_WEB]: StudentsWebVarsPreset;
284
307
  [Platform.TEACHERS_WEB]: TeachersWebVarsPreset;
285
308
  [Platform.DISTRICT_DASHBOARD]: DistrictWebVarsPreset;
286
309
  [Platform.AUTH_WEB]: AuthWebVarsPreset;
310
+ [Platform.WEB_ADMIN]: WebAdminVarsPreset;
287
311
  [Platform.MOBILE]: MobileVarsPreset;
288
312
  }>;
289
313
  type EnvironmentVars<P extends Platform> = EnvPreset[P][Locale][Environment];
@@ -424,6 +448,15 @@ type AuthWebLocaleConfig<T extends SSOVariant> = {
424
448
  locale: Locale;
425
449
  };
426
450
 
451
+ type WebAdminLocaleConfig = {
452
+ name: string;
453
+ icon: ComponentType<IconProps>;
454
+ locale: Locale;
455
+ isPrimaryRegion: boolean;
456
+ regionGroup: string;
457
+ apiRegion: ApiRegion;
458
+ };
459
+
427
460
  type CommonLocaleConfig = Readonly<{
428
461
  name: string;
429
462
  languageName: string;
@@ -444,6 +477,9 @@ type LocalePreset = {
444
477
  [Platform.AUTH_WEB]: {
445
478
  [key in Locale]: AuthWebLocaleConfig<SSOByLocale[key]>;
446
479
  };
480
+ [Platform.WEB_ADMIN]: {
481
+ [key in Locale]: WebAdminLocaleConfig;
482
+ };
447
483
  [Platform.MOBILE]: {
448
484
  [key in Locale]: AuthWebLocaleConfig<SSOByLocale[key]>;
449
485
  };
@@ -488,10 +524,11 @@ declare class AppConfigManager<P extends Platform, L extends Locale> {
488
524
  TEACHERS: TeachersWebVarsPreset;
489
525
  DISTRICT: DistrictWebVarsPreset;
490
526
  AUTH_WEB: AuthWebVarsPreset;
527
+ WEB_ADMIN: WebAdminVarsPreset;
491
528
  MOBILE: MobileVarsPreset;
492
529
  }>;
493
530
  localePreset: LocalePreset;
494
531
  };
495
532
  }
496
533
 
497
- export { AppConfigManager, type AuthWebBaseVars, type AuthWebVars, type AuthWebVarsPreset, DateFormat, DateLocale, type DistrictCommon, type DistrictDashboardVars, type DistrictWebVarsPreset, type EnvPreset, Environment, type EnvironmentVars, Locale, LoginSource, MatrixMode, type MobileBaseVars, type MobileCommon, type MobileVars, type MobileVarsPreset, Platform, PlatformBuildTarget, SSO, type SSOByLocale, type SSOConfig, type SSOVariant, type SSO_DE, type SSO_SE, type SSO_UK, type SSO_US, Source, type StudentsWebCommon, type StudentsWebVars, type StudentsWebVarsPreset, type TeachersWebCommon, type TeachersWebVars, type TeachersWebVarsPreset, buildTargetToEnvironment };
534
+ export { ApiRegion, AppConfigManager, DateFormat, DateLocale, type EnvPreset, Environment, type EnvironmentVars, Locale, LoginSource, MatrixMode, Platform, PlatformBuildTarget, SSO, type SSOConfig, Source, buildTargetToEnvironment };