dce-reactkit 4.1.7 → 4.1.8
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/cjs/index.js +5 -0
- package/dist/cjs/index.js.map +1 -1
- package/dist/cjs/types/types/LogFunction.d.ts +3 -0
- package/dist/esm/index.js +5 -0
- package/dist/esm/index.js.map +1 -1
- package/dist/esm/types/types/LogFunction.d.ts +3 -0
- package/dist/index.d.ts +3 -0
- package/package.json +1 -1
- package/src/helpers/logClientEvent.tsx +5 -0
- package/src/types/LogFunction.ts +6 -0
package/dist/index.d.ts
CHANGED
package/package.json
CHANGED
|
@@ -115,6 +115,11 @@ const logClientEvent: LogFunction = async (opts) => {
|
|
|
115
115
|
? (opts as any).action
|
|
116
116
|
: undefined
|
|
117
117
|
),
|
|
118
|
+
overriddenUserInfo: {
|
|
119
|
+
userId: opts.userId,
|
|
120
|
+
userFirstName: opts.userFirstName,
|
|
121
|
+
userLastName: opts.userLastName,
|
|
122
|
+
},
|
|
118
123
|
},
|
|
119
124
|
});
|
|
120
125
|
};
|
package/src/types/LogFunction.ts
CHANGED
|
@@ -23,6 +23,12 @@ type LogFunction = (
|
|
|
23
23
|
},
|
|
24
24
|
// Log level (default is info)
|
|
25
25
|
level?: LogLevel,
|
|
26
|
+
// Optional Canvas userId that overrides the current userId from the session (if there is one)
|
|
27
|
+
userId?: number,
|
|
28
|
+
// Optional Canvas user first name that overrides the current user first name from the session (if there is one)
|
|
29
|
+
userFirstName?: string,
|
|
30
|
+
// Optional Canvas user last name that overrides the current user last name from the session (if there is one)
|
|
31
|
+
userLastName?: string,
|
|
26
32
|
} & (
|
|
27
33
|
// Error
|
|
28
34
|
| {
|