@mparticle/aquarium 1.35.1-fix-typography.1 → 1.36.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/dist/aquarium.js +4095 -4093
- package/dist/aquarium.umd.cjs +46 -46
- package/dist/src/components/icons/index.d.ts +5 -1
- package/dist/src/components/index.d.ts +3 -4
- package/dist/src/services/user-preferences/composite-user-preferences-service/composite-user-preferences-service.d.ts +6 -10
- package/dist/src/services/user-preferences/index.d.ts +1 -0
- package/dist/src/services/user-preferences/models/definitions/index.d.ts +1 -0
- package/dist/src/services/user-preferences/models/definitions/user-preference-definition.d.ts +3 -3
- package/dist/src/services/user-preferences/models/definitions/user-preference-definitions.d.ts +2 -2
- package/dist/src/services/user-preferences/models/definitions/user-preference-per-scope.d.ts +4 -0
- package/dist/src/services/user-preferences/models/storage-models/index.d.ts +0 -2
- package/dist/src/services/user-preferences/user-preferences-service.d.ts +19 -0
- package/dist/src/services/user-preferences/user-preferences-service.spec.d.ts +16 -12
- package/dist/src/types/icons.d.ts +1 -1
- package/package.json +2 -1
- package/dist/src/services/user-preferences/models/storage-models/user-preference.d.ts +0 -3
- package/dist/src/services/user-preferences/models/storage-models/user-preferences.d.ts +0 -7
- package/dist/src/services/user-preferences/models/user-preferences/composite-user-preferences.d.ts +0 -4
- package/dist/src/services/user-preferences/user-preferences.d.ts +0 -21
|
@@ -8,6 +8,7 @@ import ChartLineIcon from '../../../../../../../../src/assets/svg/chart-line.svg
|
|
|
8
8
|
import CheckIcon from '../../../../../../../../src/assets/svg/check.svg?react';
|
|
9
9
|
import CircleNodesIcon from '../../../../../../../../src/assets/svg/circle-nodes.svg?react';
|
|
10
10
|
import CloudIcon from '../../../../../../../../src/assets/svg/cloud.svg?react';
|
|
11
|
+
import CrosshairIcon from '../../../../../../../../src/assets/svg/crosshair.svg?react';
|
|
11
12
|
import ConnectionsIcon from '../../../../../../../../src/assets/svg/connections.svg?react';
|
|
12
13
|
import DataPlatformIconDt from '../../../../../../../../src/assets/svg/mp_pm_dt_data-platform.svg?react';
|
|
13
14
|
import DatabaseIcon from '../../../../../../../../src/assets/svg/database.svg?react';
|
|
@@ -60,6 +61,8 @@ import DirectoryIcon from '../../../../../../../../src/assets/svg/mp_pm_lt_direc
|
|
|
60
61
|
import LockIcon from '../../../../../../../../src/assets/svg/mp_act_lt_lock.svg?react';
|
|
61
62
|
import UnlockIcon from '../../../../../../../../src/assets/svg/mp_act_lt_unlock.svg?react';
|
|
62
63
|
import NotificationIcon from '../../../../../../../../src/assets/svg/mp_pm_lt_notification.svg?react';
|
|
64
|
+
import NotificationSubscribedIcon from '../../../../../../../../src/assets/svg/mp_pm_lt_notification_subscribed.svg?react';
|
|
65
|
+
import NotificationSubscribeIcon from '../../../../../../../../src/assets/svg/mp_pm_lt_notification_subscribe.svg?react';
|
|
63
66
|
import PremiumIconDt from '../../../../../../../../src/assets/svg/mp_info_dt_premium.svg?react';
|
|
64
67
|
import OverviewIconDt from '../../../../../../../../src/assets/svg/mp_pm_dt_overview.svg?react';
|
|
65
68
|
import FilterIcon from '../../../../../../../../src/assets/svg/mp_act_lt_filter.svg?react';
|
|
@@ -86,4 +89,5 @@ import FullScreen from '../../../../../../../../src/assets/svg/mp_act_lt_full-sc
|
|
|
86
89
|
import Edit from '../../../../../../../../src/assets/svg/mp_act_lt_edit.svg?react';
|
|
87
90
|
import Copy from '../../../../../../../../src/assets/svg/mp_act_lt_copy.svg?react';
|
|
88
91
|
import MoreActions from '../../../../../../../../src/assets/svg/mp_act_lt_more-actions.svg?react';
|
|
89
|
-
|
|
92
|
+
import AbSplit from '../../../../../../../../src/assets/svg/mp_info_lt_ab-split.svg?react';
|
|
93
|
+
export { AbSplit, Account, ActiveIcon, AddIcon, AlicornIcon, AnalyticsIconDt, Annotation, C360IconDt, CatalogIcon, ChartColumnIcon, ChartLineIcon, CheckIcon, CircleNodesIcon, CloudIcon, CrosshairIcon, Cohort, ConnectionsIcon, ConversionIcon, Copy, Dashboard, DatabaseIcon, DataPlatformIconDt, Delete, DirectoryIcon, DragAndDropIcon, DropdownClose, DropdownOpen, DsrIcon, Edit, EmptyIcon, EnrichmentIcon, EventAttributeIcon, EventIcon, FilterIcon, FitToScreen, FolderClosedIcon, ForwardingIcon, FullScreen, Funnel, GearIcon, GridIcon, HeartIcon, HelpIcon, HelpVideoIcon, IdentityIcon, InfoIcon, JourneyAnalysis, JumpToIcon, LightBulbIcon, LinkIcon, LiveStreamIcon, LockIcon, MessageQuestionIcon, MoreActions, MpLogoIcon, NextIcon, NotificationIcon, NotificationSubscribedIcon, NotificationSubscribeIcon, ObservabilityIcon, OpenTabIcon, Organization, OversightIconDt, OverviewIconDt, PaywallIcon, Placeholder, PredictionsIcon, PredictionsIconDt, PremiumIcon, PremiumIconDt, PreviousIcon, Privileges, RefreshFrequency, RemoveIcon, ScheduledReport, SearchIcon, SegmentationAnalysis, SegmentationIconDt, ShieldKeyholeIcon, SignoutIcon, SplitIcon, SystemAlertsIcon, TextWidget, TransformationsIcon, UnlockIcon, UploadIcon, UserAttributeIcon, UserProfilesIcon, UsersIcon, WrenchIcon, ZoomIn, ZoomOut, };
|
|
@@ -78,9 +78,8 @@ export type { INavigationOrg, INavigationWorkspace, INavigationAccount, IWorkspa
|
|
|
78
78
|
export { type INotificationCenterProps, NotificationCenterZIndex, } from './navigation/GlobalNavigation/NotificationCenter';
|
|
79
79
|
export { SuiteLogo } from './navigation/GlobalNavigation/SuiteLogo';
|
|
80
80
|
export { Typography } from './general/Typography/Typography';
|
|
81
|
-
export { UserPreferencesService } from '../services/user-preferences
|
|
81
|
+
export { UserPreferencesService } from '../services/user-preferences';
|
|
82
82
|
export { CompositeUserPreferencesService } from '../services/user-preferences/composite-user-preferences-service';
|
|
83
|
-
export { type
|
|
84
|
-
export {
|
|
85
|
-
export { type UserPreferences, USER_PREFERENCE_SCOPE_SEPARATOR, UserPreferenceGlobalScope, type UserPreference, type UserPreferenceScope, } from '../services/user-preferences/models/storage-models';
|
|
83
|
+
export { UserPreferenceScopeType, type UserPreferenceDefinition, type UserPreferenceDefinitions, type UserPreferencesPerScope, } from '../services/user-preferences/models/definitions';
|
|
84
|
+
export { USER_PREFERENCE_SCOPE_SEPARATOR, UserPreferenceGlobalScope, type UserPreferenceScope, } from '../services/user-preferences/models/storage-models';
|
|
86
85
|
export { useNewExperienceReminder, type INewExperienceReminderOptions, type NewExperienceReminderHook, } from '../hooks/NewExperienceReminder/useNewExperienceReminder';
|
|
@@ -1,13 +1,9 @@
|
|
|
1
|
-
import { type
|
|
2
|
-
import { type UserPreferenceScope } from '../../../../../../../../../src/services/user-preferences/models/storage-models
|
|
3
|
-
import { type
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
getScopedUserPreferences(storedPreferences: UserPreferences<TPreferenceIds>, currentScope: UserPreferenceScope, definitions: UserPreferenceDefinitions<TPreferenceIds>): CompositeUserPreferences<TPreferenceIds>;
|
|
8
|
-
getUpdatedUserPreferenceStorageObject(preferenceId: TPreferenceIds, isOptedIn: boolean, currentScope: UserPreferenceScope, currentPreferences: UserPreferences<TPreferenceIds>, allowedScope: UserPreferenceScopeType): UserPreferences<TPreferenceIds>;
|
|
1
|
+
import { UserPreferenceScopeType, type UserPreferenceDefinitions } from '../../../../../../../../../src/services/user-preferences/models/definitions';
|
|
2
|
+
import { type UserPreferenceScope } from '../../../../../../../../../src/services/user-preferences/models/storage-models';
|
|
3
|
+
import { type UserPreferencesPerScope } from '../models/definitions/user-preference-per-scope';
|
|
4
|
+
export declare class CompositeUserPreferencesService<T extends Record<string, unknown>> {
|
|
5
|
+
getScopedUserPreferences(userPreferencesPerScope: UserPreferencesPerScope<T>, currentScope: UserPreferenceScope, definitions: UserPreferenceDefinitions<T>): T;
|
|
6
|
+
getUpdatedUserPreferenceStorageObject<TKey extends keyof T>(userPreferenceKey: TKey, value: T[TKey], currentScope: UserPreferenceScope, currentPreferences: UserPreferencesPerScope<T>, allowedScope: UserPreferenceScopeType): UserPreferencesPerScope<T>;
|
|
9
7
|
private createUserPreferenceEntryFromDefinition;
|
|
10
8
|
private getEffectiveScope;
|
|
11
|
-
private createPreferenceEntry;
|
|
12
|
-
private createCompositePreferencesFromEntries;
|
|
13
9
|
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './user-preferences-service';
|
package/dist/src/services/user-preferences/models/definitions/user-preference-definition.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { type UserPreferenceScopeType } from './user-preference-scope-type';
|
|
2
|
-
export
|
|
3
|
-
isOptedInByDefault: boolean;
|
|
2
|
+
export type UserPreferenceDefinition<T> = {
|
|
4
3
|
allowedScope: UserPreferenceScopeType;
|
|
5
|
-
|
|
4
|
+
defaultValue: T;
|
|
5
|
+
};
|
package/dist/src/services/user-preferences/models/definitions/user-preference-definitions.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
import { type UserPreferenceDefinition } from './user-preference-definition';
|
|
2
|
-
export type UserPreferenceDefinitions<
|
|
3
|
-
[
|
|
2
|
+
export type UserPreferenceDefinitions<T> = {
|
|
3
|
+
[P in keyof T]: UserPreferenceDefinition<T[P]>;
|
|
4
4
|
};
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import { type UserPreferenceScope } from '../../../../../../../../src/services/user-preferences/models/storage-models';
|
|
2
|
+
import { type CookieOptions } from '../../../../../../../../src/utils/Cookies';
|
|
3
|
+
import { type UserPreferenceDefinitions } from '../../../../../../../../src/components';
|
|
4
|
+
export declare class UserPreferencesService<T extends Record<string, unknown>> {
|
|
5
|
+
private readonly definitions;
|
|
6
|
+
private readonly currentScope;
|
|
7
|
+
private readonly cookieOptions;
|
|
8
|
+
private readonly onUpdate?;
|
|
9
|
+
private preferences;
|
|
10
|
+
private readonly compositeUserPreferencesService;
|
|
11
|
+
constructor(definitions: UserPreferenceDefinitions<T>, currentScope: UserPreferenceScope, cookieOptions: CookieOptions & {
|
|
12
|
+
key: string;
|
|
13
|
+
}, onUpdate?: ((resolvedPreferences: T) => void) | undefined);
|
|
14
|
+
getPreference<TKey extends keyof T, TValue extends T[TKey]>(key: TKey): Promise<TValue>;
|
|
15
|
+
setPreference<TKey extends keyof T, TValue extends T[TKey]>(key: TKey, value: TValue): Promise<void>;
|
|
16
|
+
init(): Promise<void>;
|
|
17
|
+
private getStoredPreferences;
|
|
18
|
+
private setStoredPreferences;
|
|
19
|
+
}
|
|
@@ -1,22 +1,26 @@
|
|
|
1
1
|
import { type UserPreferenceScope } from '../../../../../../../../src/services/user-preferences/models/storage-models/user-preference-scope';
|
|
2
|
-
import { type UserPreferences } from '../../../../../../../../src/services/user-preferences/models/storage-models/user-preferences';
|
|
3
|
-
import { type UserPreferenceDefinitions } from '../../../../../../../../src/services/user-preferences/models/definitions/user-preference-definitions';
|
|
4
2
|
import { UserPreferenceScopeType } from '../../../../../../../../src/services/user-preferences/models/definitions/user-preference-scope-type';
|
|
5
3
|
import { type Sync } from 'factory.ts';
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
4
|
+
import { type UserPreferenceDefinitions } from '../../../../../../../../src/components';
|
|
5
|
+
import { type UserPreferencesPerScope } from './models/definitions/user-preference-per-scope';
|
|
6
|
+
export type TestType = {
|
|
7
|
+
Default: {
|
|
8
|
+
isOptedIn: boolean;
|
|
9
|
+
};
|
|
10
|
+
PreferenceOne: {
|
|
11
|
+
isOptedIn: boolean;
|
|
12
|
+
};
|
|
13
|
+
};
|
|
10
14
|
export declare function TestUserPreferenceDefinitionsFakeFactory(config?: Array<{
|
|
11
|
-
id:
|
|
15
|
+
id: string;
|
|
12
16
|
isOptedInByDefault?: boolean;
|
|
13
17
|
allowedScope?: UserPreferenceScopeType;
|
|
14
|
-
}>): Sync.Builder<UserPreferenceDefinitions<
|
|
18
|
+
}>): Sync.Builder<UserPreferenceDefinitions<TestType>, keyof UserPreferenceDefinitions<TestType>>;
|
|
15
19
|
export interface TestUserPreferencesFakeBuilder {
|
|
16
20
|
wantsRandom?: boolean;
|
|
17
21
|
scope?: UserPreferenceScope;
|
|
18
|
-
|
|
19
|
-
|
|
22
|
+
keys?: string[];
|
|
23
|
+
defaultValues?: any[];
|
|
20
24
|
}
|
|
21
|
-
export declare function makeBuilderFromDefinition(definitions: UserPreferenceDefinitions<
|
|
22
|
-
export declare function TestUserPreferencesFakeFactory(scopes?: TestUserPreferencesFakeBuilder[]): Sync.Builder<
|
|
25
|
+
export declare function makeBuilderFromDefinition(definitions: UserPreferenceDefinitions<TestType>, scope?: UserPreferenceScope): TestUserPreferencesFakeBuilder;
|
|
26
|
+
export declare function TestUserPreferencesFakeFactory(scopes?: TestUserPreferencesFakeBuilder[]): Sync.Builder<UserPreferencesPerScope<TestType>, keyof UserPreferencesPerScope<TestType>>;
|
|
@@ -7,4 +7,4 @@ export type IconOptions = RequireAtLeastOne<{
|
|
|
7
7
|
default: IconVariant;
|
|
8
8
|
deprecated?: string;
|
|
9
9
|
}, IconVariant>;
|
|
10
|
-
export type IconNames = 'account' | 'active' | 'add' | 'alicorn' | 'analytics' | 'annotation' | 'api' | 'audiences' | 'C360' | 'catalog' | 'chartColumn' | 'chartLine' | 'check' | 'circleNodes' | 'close' | 'cloud' | 'cohort' | 'connections' | 'conversion' | 'copy' | 'dashboard' | 'database' | 'dataPlatform' | 'delete' | 'directory' | 'dragAndDrop' | 'dropdownClose' | 'dropdownOpen' | 'dsr' | 'edit' | 'empty' | 'enrichment' | 'event' | 'eventAttribute' | 'favorite' | 'filter' | 'fitToScreen' | 'folderClosed' | 'forwarding' | 'fullScreen' | 'funnel' | 'gear' | 'grid' | 'heart' | 'help' | 'helpVideo' | 'identity' | 'info' | 'insights' | 'journeyAnalysis' | 'journeys' | 'jumpTo' | 'lightBulb' | 'link' | 'liveStream' | 'lock' | 'logout' | 'messageQuestion' | 'moreActions' | 'mpLogo' | 'myHub' | 'next' | 'notification' | 'observability' | 'openTab' | 'organization' | 'oversight' | 'overview' | 'paywall' | 'pipelines' | 'placeholder' | 'predictions' | 'premium' | 'premiumDt' | 'previous' | 'privacy' | 'privileges' | 'refreshFrequency' | 'remove' | 'savedProjects' | 'scheduledReport' | 'search' | 'segmentation' | 'segmentationAnalysis' | 'selected' | 'settings' | 'setup' | 'shieldKeyhole' | 'signout' | 'siteMap' | 'sparkles' | 'split' | 'support' | 'systemAlerts' | 'textWidget' | 'transformation' | 'trends' | 'unlock' | 'upload' | 'userAttribute' | 'userProfiles' | 'users' | 'wrench' | 'zoomIn' | 'zoomOut';
|
|
10
|
+
export type IconNames = 'abSplit' | 'account' | 'active' | 'add' | 'alicorn' | 'analytics' | 'annotation' | 'api' | 'audiences' | 'C360' | 'catalog' | 'chartColumn' | 'chartLine' | 'check' | 'circleNodes' | 'close' | 'cloud' | 'cohort' | 'connections' | 'conversion' | 'copy' | 'crosshair' | 'dashboard' | 'database' | 'dataPlatform' | 'delete' | 'directory' | 'dragAndDrop' | 'dropdownClose' | 'dropdownOpen' | 'dsr' | 'edit' | 'empty' | 'enrichment' | 'event' | 'eventAttribute' | 'favorite' | 'filter' | 'fitToScreen' | 'folderClosed' | 'forwarding' | 'fullScreen' | 'funnel' | 'gear' | 'grid' | 'heart' | 'help' | 'helpVideo' | 'identity' | 'info' | 'insights' | 'journeyAnalysis' | 'journeys' | 'jumpTo' | 'lightBulb' | 'link' | 'liveStream' | 'lock' | 'logout' | 'messageQuestion' | 'moreActions' | 'mpLogo' | 'myHub' | 'next' | 'notification' | 'notificationSubscribed' | 'notificationSubscribe' | 'observability' | 'openTab' | 'organization' | 'oversight' | 'overview' | 'paywall' | 'pipelines' | 'placeholder' | 'predictions' | 'premium' | 'premiumDt' | 'previous' | 'privacy' | 'privileges' | 'refreshFrequency' | 'remove' | 'savedProjects' | 'scheduledReport' | 'search' | 'segmentation' | 'segmentationAnalysis' | 'selected' | 'settings' | 'setup' | 'shieldKeyhole' | 'signout' | 'siteMap' | 'sparkles' | 'split' | 'support' | 'systemAlerts' | 'textWidget' | 'transformation' | 'trends' | 'unlock' | 'upload' | 'userAttribute' | 'userProfiles' | 'users' | 'wrench' | 'zoomIn' | 'zoomOut';
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@mparticle/aquarium",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.36.1",
|
|
4
4
|
"description": "mParticle Component Library",
|
|
5
5
|
"license": "Apache-2.0",
|
|
6
6
|
"keywords": [
|
|
@@ -52,6 +52,7 @@
|
|
|
52
52
|
"@types/multer": "1.4.12",
|
|
53
53
|
"@typescript-eslint/eslint-plugin": "6.19.0",
|
|
54
54
|
"@vitejs/plugin-react": "4.2.1",
|
|
55
|
+
"@vitest/coverage-v8": "1.3.1",
|
|
55
56
|
"concurrently": "8.2.2",
|
|
56
57
|
"cz-conventional-changelog": "3.3.0",
|
|
57
58
|
"eslint": "8.56.0",
|
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
import { type UserPreferenceScope } from './user-preference-scope';
|
|
2
|
-
import { type UserPreference } from './user-preference';
|
|
3
|
-
export type UserPreferences<UserPreferenceId extends PropertyKey> = {
|
|
4
|
-
[K in UserPreferenceScope]?: {
|
|
5
|
-
[Id in UserPreferenceId]: UserPreference;
|
|
6
|
-
};
|
|
7
|
-
};
|
|
@@ -1,21 +0,0 @@
|
|
|
1
|
-
import { type CompositeUserPreferences } from '../../../../../../../../src/services/user-preferences/models/user-preferences/composite-user-preferences';
|
|
2
|
-
import { type UserPreferenceScope } from '../../../../../../../../src/services/user-preferences/models/storage-models/user-preference-scope';
|
|
3
|
-
import { type UserPreferenceDefinitions } from '../../../../../../../../src/services/user-preferences/models/definitions/user-preference-definitions';
|
|
4
|
-
import { type CompositeUserPreferencesService } from '../../../../../../../../src/services/user-preferences/composite-user-preferences-service';
|
|
5
|
-
import { type CookieOptions } from '../../../../../../../../src/utils/Cookies';
|
|
6
|
-
export declare class UserPreferencesService<TUserPreferenceId extends PropertyKey> {
|
|
7
|
-
private readonly definitions;
|
|
8
|
-
private readonly compositeUserPreferencesService;
|
|
9
|
-
private readonly currentScope;
|
|
10
|
-
private readonly cookieOptions;
|
|
11
|
-
private readonly onUpdate?;
|
|
12
|
-
preferences: CompositeUserPreferences<TUserPreferenceId>;
|
|
13
|
-
constructor(definitions: UserPreferenceDefinitions<TUserPreferenceId>, compositeUserPreferencesService: CompositeUserPreferencesService<TUserPreferenceId>, currentScope: UserPreferenceScope, cookieOptions: CookieOptions & {
|
|
14
|
-
key: string;
|
|
15
|
-
}, onUpdate?: ((resolvedPreferences: CompositeUserPreferences<TUserPreferenceId>) => void) | undefined);
|
|
16
|
-
init(): Promise<void>;
|
|
17
|
-
isOptedIn(userPreferenceId: TUserPreferenceId): Promise<boolean | undefined>;
|
|
18
|
-
setPreference(userPreferenceId: TUserPreferenceId, isOptedIn: boolean): Promise<void>;
|
|
19
|
-
private getStoredPreferences;
|
|
20
|
-
private setStoredPreferences;
|
|
21
|
-
}
|