@dosgato/templating 1.2.0 → 1.2.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/uitemplate.d.ts +39 -16
- package/package.json +1 -1
package/dist/uitemplate.d.ts
CHANGED
|
@@ -211,35 +211,58 @@ export interface TracingInterface {
|
|
|
211
211
|
event?: (name: string, details: any, env?: TracingEnvironment) => void;
|
|
212
212
|
}
|
|
213
213
|
export interface BaseEvent {
|
|
214
|
-
/**
|
|
215
|
-
*
|
|
214
|
+
/**
|
|
215
|
+
* The name of the UI component that is recording the event. This should help you track
|
|
216
|
+
* down where the event is being logged in the code.
|
|
217
|
+
*
|
|
218
|
+
* @example 'ActionPanel', 'PageEditor', 'ComponentDialog'
|
|
219
|
+
*/
|
|
216
220
|
eventType: string;
|
|
217
221
|
/** The specific action the user took. Typically the label for the element that emits
|
|
218
222
|
* the event.
|
|
219
223
|
* @example 'Add Page', 'Edit Page', 'Preview', 'Cancel Preview' */
|
|
220
224
|
action: string;
|
|
221
225
|
/** Additional data points specific to a particular event type's context. These should
|
|
222
|
-
* be significant enough to understanding the event to
|
|
226
|
+
* be significant enough to understanding the event to merit adding additional columns
|
|
223
227
|
* in tools like elastic-search.
|
|
224
|
-
* @warning This is NOT a catch-all property.
|
|
228
|
+
* @warning This is NOT a catch-all property. It should be used for metrics an analytics
|
|
229
|
+
* report would be likely to filter or group by.
|
|
225
230
|
* @example { hiddenLabel: action.hiddenLabel } // The aria label for an action element. */
|
|
226
231
|
additionalProperties?: Record<string, string | undefined>;
|
|
227
232
|
}
|
|
228
|
-
/**
|
|
229
|
-
*
|
|
230
|
-
*
|
|
233
|
+
/** Common model for user interaction events in DosGato, designed to capture contextually
|
|
234
|
+
* important properties for analytics and metrics logging and create enough shared structure
|
|
235
|
+
* to make it easy to generate meaningful reports and insights. */
|
|
231
236
|
export interface UserEvent extends BaseEvent {
|
|
232
|
-
/**
|
|
233
|
-
*
|
|
234
|
-
*
|
|
237
|
+
/**
|
|
238
|
+
* The sveltekit route the user is looking at when the event is triggered.
|
|
239
|
+
*
|
|
240
|
+
* Some dialogs will add the dialog name after a '#' for extra context, but this behavior is
|
|
241
|
+
* deprecated.
|
|
242
|
+
* @example '/pages', '/pages/[id]', '/pages/[id]#dialog' (deprecated) */
|
|
235
243
|
screen: string;
|
|
236
|
-
/**
|
|
237
|
-
*
|
|
238
|
-
*
|
|
244
|
+
/**
|
|
245
|
+
* Identify a section of the screen to help identify what the user was looking at when
|
|
246
|
+
* taking the action. Very useful for tabs that do not have their own sveltekit routes.
|
|
247
|
+
*
|
|
248
|
+
* Also, if interacting inside a modal dialog that has a title,
|
|
249
|
+
* the title of the dialog could go here.
|
|
250
|
+
*
|
|
251
|
+
* Do not duplicate eventType here.
|
|
252
|
+
*/
|
|
253
|
+
section?: string;
|
|
254
|
+
/**
|
|
255
|
+
* The target of the action reported in the `action` property.
|
|
256
|
+
*
|
|
257
|
+
* Each component that logs an event should consider the best value to place here. It's best
|
|
258
|
+
* if it's human-readable (avoid numeric and UUIDs), specific enough to understand what the user
|
|
259
|
+
* was doing, but not so unique that an analytics search would never filter or group on it.
|
|
239
260
|
*
|
|
240
|
-
* For example:
|
|
241
|
-
*
|
|
242
|
-
*
|
|
261
|
+
* For example: When moving a page, the path of the page being moved. When moving many pages, the
|
|
262
|
+
* path of the page being moved into. When adding a component to a page, the templateKey of the
|
|
263
|
+
* component being added.
|
|
264
|
+
* @example '/site3-sandbox/about', 'hero-banner'
|
|
265
|
+
* */
|
|
243
266
|
target: string;
|
|
244
267
|
}
|
|
245
268
|
interface AssetMetaDisplay {
|