@artsy/cohesion 4.390.0 → 4.391.0

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/CHANGELOG.md CHANGED
@@ -1,3 +1,15 @@
1
+ # v4.391.0 (Mon Aug 17 2026)
2
+
3
+ #### 🚀 Enhancement
4
+
5
+ - feat: add private vr events [#738](https://github.com/artsy/cohesion/pull/738) ([@dariakoko](https://github.com/dariakoko))
6
+
7
+ #### Authors: 1
8
+
9
+ - Daria Kozlova ([@dariakoko](https://github.com/dariakoko))
10
+
11
+ ---
12
+
1
13
  # v4.390.0 (Fri Aug 14 2026)
2
14
 
3
15
  #### 🚀 Enhancement
@@ -160,7 +160,11 @@ export interface OsClickedAspectRatio {
160
160
  label: "image aspect ratio" | "image zoom";
161
161
  }
162
162
  /**
163
- * A partner clicks "Cancel" or "Continue" in the Instagram post publish confirmation modal.
163
+ * A partner clicks "Cancel" or "Continue" in a publish confirmation modal.
164
+ *
165
+ * Shared across surfaces rather than Instagram-only: the Private Viewing Room
166
+ * editor sends it from its "Share without a passcode?" confirmation, which is
167
+ * why `context_page_owner_type` accepts any {@link OsOwnerType}.
164
168
  *
165
169
  * This schema describes events sent to Segment from [[OsClickedPublishConfirmation]]
166
170
  *
@@ -187,7 +191,7 @@ export interface OsClickedAspectRatio {
187
191
  export interface OsClickedPublishConfirmation {
188
192
  action: OsActionType.clickedPublishConfirmation;
189
193
  context_module: OsContextModule.publishConfirmationModal;
190
- context_page_owner_type: OsOwnerType.studioInstagram;
194
+ context_page_owner_type: OsOwnerType;
191
195
  value: "cancel" | "continue";
192
196
  }
193
197
  /**
@@ -0,0 +1,139 @@
1
+ import { OsContextModule } from "../Values/OsContextModule";
2
+ import { OsOwnerType } from "../Values/OsOwnerType";
3
+ import { OsActionType } from ".";
4
+ /**
5
+ * Schemas describing Art OS Private Viewing Room events
6
+ *
7
+ * A Private Viewing Room is a password-protected web page a gallery generates
8
+ * from a collection and shares with a client by link. It is a `PartnerList`
9
+ * with `listType: "PRIVATE_VIEWING_ROOM"`, so the generic list events
10
+ * (`createdList`, `addedArtworksToList`, …) also fire for it — these schemas
11
+ * cover only what is specific to sharing a room.
12
+ *
13
+ * Note the `privateViewingRoom` prefix throughout: `OwnerType.viewingRoom` and
14
+ * `ContextModule.viewingRoom` already exist for the consumer-facing viewing
15
+ * rooms on artsy.net, and both feed the same `context_page_owner_type` /
16
+ * `context_module` columns. Reusing the bare name would merge two unrelated
17
+ * products downstream.
18
+ *
19
+ * @packageDocumentation
20
+ */
21
+ /**
22
+ * A partner opens the Private Viewing Room editor, either to share a room for
23
+ * the first time or to update one already shared.
24
+ *
25
+ * `trigger` separates the three entry points: the Share button on an unshared
26
+ * room, the Manage panel on a shared one, and the banner shown when a shared
27
+ * room's artworks have drifted from the snapshot viewers currently see. Pairing
28
+ * the banner trigger with its `bannerViewed` impression is the only way to tell
29
+ * whether that nudge gets acted on.
30
+ *
31
+ * Fires on open, not on the first edit, so it is the denominator for
32
+ * share-completion rate when paired with {@link SharedPrivateViewingRoom}.
33
+ *
34
+ * This schema describes events sent to Segment from
35
+ * [[ClickedSharePrivateViewingRoom]]
36
+ *
37
+ * @example
38
+ * ```
39
+ * {
40
+ * action: "clickedSharePrivateViewingRoom",
41
+ * context_module: "listDetail",
42
+ * context_page_owner_type: "privateViewingRoom",
43
+ * list_id: "5d2b5b5d5e5b5d000e1b5b5d",
44
+ * value: "share",
45
+ * trigger: "shareButton"
46
+ * }
47
+ * ```
48
+ */
49
+ export interface ClickedSharePrivateViewingRoom {
50
+ action: OsActionType.clickedSharePrivateViewingRoom;
51
+ context_module: OsContextModule.listDetail;
52
+ context_page_owner_type: OsOwnerType.privateViewingRoom;
53
+ list_id: string;
54
+ value: "share" | "update";
55
+ trigger: "shareButton" | "manageMenu" | "updateBanner";
56
+ }
57
+ /**
58
+ * A partner successfully shares a Private Viewing Room — past this point the
59
+ * link works and the client can open the room. Fires from the publish
60
+ * mutation's success callback, so it means the room is live rather than that
61
+ * the gallery intended to share it.
62
+ *
63
+ * `value` distinguishes a first share from an update to an already-shared room.
64
+ * Every share goes through the editor: the stale-room banner opens the editor
65
+ * rather than republishing in one click, so the gallery always reviews the
66
+ * preview before viewers see a change.
67
+ *
68
+ * `has_passcode` is a boolean by design. The passcode itself is a shared access
69
+ * credential and is never sent.
70
+ *
71
+ * `content` is a generic catch-all holding the header choices and the artwork
72
+ * detail fields the gallery chose to expose — field names only, never their
73
+ * values. Kept generic on purpose, matching {@link OsCreatedStudioContent}, so
74
+ * it is parsed ad-hoc downstream rather than maintained as a rigid set of
75
+ * top-level fields.
76
+ *
77
+ * This schema describes events sent to Segment from
78
+ * [[SharedPrivateViewingRoom]]
79
+ *
80
+ * @example
81
+ * ```
82
+ * {
83
+ * action: "sharedPrivateViewingRoom",
84
+ * context_module: "privateViewingRoomEditor",
85
+ * context_page_owner_type: "privateViewingRoom",
86
+ * value: "shared",
87
+ * list_id: "5d2b5b5d5e5b5d000e1b5b5d",
88
+ * artwork_count: 12,
89
+ * has_passcode: true,
90
+ * brand_kit: true,
91
+ * content: {
92
+ * showGalleryName: true,
93
+ * hasHeading: true,
94
+ * hasDescription: false,
95
+ * artworkFields: ["artistName", "artworkTitle", "year", "medium"]
96
+ * }
97
+ * }
98
+ * ```
99
+ */
100
+ export interface SharedPrivateViewingRoom {
101
+ action: OsActionType.sharedPrivateViewingRoom;
102
+ context_module: OsContextModule.privateViewingRoomEditor;
103
+ context_page_owner_type: OsOwnerType.privateViewingRoom;
104
+ value: "shared" | "updated";
105
+ list_id: string;
106
+ artwork_count: number;
107
+ /** Whether a passcode is set. The passcode itself is never sent */
108
+ has_passcode: boolean;
109
+ brand_kit: boolean;
110
+ /** Generic catch-all for the header choices and exposed artwork detail fields */
111
+ content: Record<string, unknown>;
112
+ }
113
+ /**
114
+ * A partner stops sharing a Private Viewing Room, which immediately breaks the
115
+ * link the client was given. `trigger` distinguishes the Manage panel on the
116
+ * collection page from the editor's own footer.
117
+ *
118
+ * This schema describes events sent to Segment from
119
+ * [[StoppedSharingPrivateViewingRoom]]
120
+ *
121
+ * @example
122
+ * ```
123
+ * {
124
+ * action: "stoppedSharingPrivateViewingRoom",
125
+ * context_module: "listDetail",
126
+ * context_page_owner_type: "privateViewingRoom",
127
+ * list_id: "5d2b5b5d5e5b5d000e1b5b5d",
128
+ * trigger: "manageMenu"
129
+ * }
130
+ * ```
131
+ */
132
+ export interface StoppedSharingPrivateViewingRoom {
133
+ action: OsActionType.stoppedSharingPrivateViewingRoom;
134
+ context_module: OsContextModule.listDetail;
135
+ context_page_owner_type: OsOwnerType.privateViewingRoom;
136
+ list_id: string;
137
+ trigger: "manageMenu" | "editor";
138
+ }
139
+ export type OsPrivateViewingRoom = ClickedSharePrivateViewingRoom | SharedPrivateViewingRoom | StoppedSharingPrivateViewingRoom;
@@ -0,0 +1 @@
1
+ "use strict";
@@ -8,6 +8,7 @@ import { OsMailchimpEditor } from "./MailchimpEditor";
8
8
  import { OsMaterialsEditor } from "./MaterialsEditor";
9
9
  import { OsMultiAddFlow } from "./MultiAddFlow";
10
10
  import { OsOnboardingFlow } from "./OnboardingFlow";
11
+ import { OsPrivateViewingRoom } from "./PrivateViewingRoom";
11
12
  import { OsSubmitEvent } from "./Submit";
12
13
  import { OsToggleEvent } from "./Toggle";
13
14
  /**
@@ -15,7 +16,7 @@ import { OsToggleEvent } from "./Toggle";
15
16
  *
16
17
  * Each event describes one ActionType
17
18
  */
18
- export type OsEvent = ClickedAddBrandKitFile | ClickedBrandKitColor | ClickedBrandKitFont | ClickedSaveBrandKit | OsClickEvent | OsConnectedAppsFlow | OsFilterSortSearch | OsInstagramEditor | OsInventoryTable | OsMailchimpEditor | OsMaterialsEditor | OsMultiAddFlow | OsOnboardingFlow | OsSubmitEvent | OsToggleEvent;
19
+ export type OsEvent = ClickedAddBrandKitFile | ClickedBrandKitColor | ClickedBrandKitFont | ClickedSaveBrandKit | OsClickEvent | OsConnectedAppsFlow | OsFilterSortSearch | OsInstagramEditor | OsInventoryTable | OsMailchimpEditor | OsMaterialsEditor | OsMultiAddFlow | OsOnboardingFlow | OsPrivateViewingRoom | OsSubmitEvent | OsToggleEvent;
19
20
  /**
20
21
  * List of all Art OS actions
21
22
  *
@@ -131,6 +132,10 @@ export declare enum OsActionType {
131
132
  * Corresponds to {@link OsInstagramEditor}
132
133
  */
133
134
  clickedPublishConfirmation = "clickedPublishConfirmation",
135
+ /**
136
+ * Corresponds to {@link ClickedSharePrivateViewingRoom}
137
+ */
138
+ clickedSharePrivateViewingRoom = "clickedSharePrivateViewingRoom",
134
139
  /**
135
140
  * Corresponds to {@link ClickedShowMeHow}
136
141
  */
@@ -240,6 +245,10 @@ export declare enum OsActionType {
240
245
  * Corresponds to {@link OsFilterSortSearch}
241
246
  */
242
247
  searchedArtworks = "searchedArtworks",
248
+ /**
249
+ * Corresponds to {@link SharedPrivateViewingRoom}
250
+ */
251
+ sharedPrivateViewingRoom = "sharedPrivateViewingRoom",
243
252
  /**
244
253
  * Corresponds to {@link OsFilterSortSearch}
245
254
  */
@@ -248,6 +257,10 @@ export declare enum OsActionType {
248
257
  * Corresponds to {@link StartedArtworkImport}
249
258
  */
250
259
  startedArtworkImport = "startedArtworkImport",
260
+ /**
261
+ * Corresponds to {@link StoppedSharingPrivateViewingRoom}
262
+ */
263
+ stoppedSharingPrivateViewingRoom = "stoppedSharingPrivateViewingRoom",
251
264
  /**
252
265
  * Corresponds to {@link ToggledDistributionSync}
253
266
  */
@@ -48,6 +48,7 @@ exports.OsActionType = OsActionType;
48
48
  OsActionType["clickedImagesModal"] = "clickedImagesModal";
49
49
  OsActionType["clickedOpenList"] = "clickedOpenList";
50
50
  OsActionType["clickedPublishConfirmation"] = "clickedPublishConfirmation";
51
+ OsActionType["clickedSharePrivateViewingRoom"] = "clickedSharePrivateViewingRoom";
51
52
  OsActionType["clickedShowMeHow"] = "clickedShowMeHow";
52
53
  OsActionType["clickedSendConfirmation"] = "clickedSendConfirmation";
53
54
  OsActionType["clickedUploadImageBank"] = "clickedUploadImageBank";
@@ -75,8 +76,10 @@ exports.OsActionType = OsActionType;
75
76
  OsActionType["resumedArtworkImport"] = "resumedArtworkImport";
76
77
  OsActionType["savedArtworkImages"] = "savedArtworkImages";
77
78
  OsActionType["searchedArtworks"] = "searchedArtworks";
79
+ OsActionType["sharedPrivateViewingRoom"] = "sharedPrivateViewingRoom";
78
80
  OsActionType["sortedColumn"] = "sortedColumn";
79
81
  OsActionType["startedArtworkImport"] = "startedArtworkImport";
82
+ OsActionType["stoppedSharingPrivateViewingRoom"] = "stoppedSharingPrivateViewingRoom";
80
83
  OsActionType["toggledDistributionSync"] = "toggledDistributionSync";
81
84
  OsActionType["updatedEditionSet"] = "updatedEditionSet";
82
85
  OsActionType["updatedList"] = "updatedList";
@@ -35,6 +35,7 @@ export declare enum OsContextModule {
35
35
  multiAdd = "multiAdd",
36
36
  multiAddReview = "multiAddReview",
37
37
  onboardingFlow = "onboardingFlow",
38
+ privateViewingRoomEditor = "privateViewingRoomEditor",
38
39
  publishConfirmationModal = "publishConfirmationModal",
39
40
  sendConfirmationModal = "sendConfirmationModal",
40
41
  tableActions = "tableActions"
@@ -45,6 +45,7 @@ exports.OsContextModule = OsContextModule;
45
45
  OsContextModule["multiAdd"] = "multiAdd";
46
46
  OsContextModule["multiAddReview"] = "multiAddReview";
47
47
  OsContextModule["onboardingFlow"] = "onboardingFlow";
48
+ OsContextModule["privateViewingRoomEditor"] = "privateViewingRoomEditor";
48
49
  OsContextModule["publishConfirmationModal"] = "publishConfirmationModal";
49
50
  OsContextModule["sendConfirmationModal"] = "sendConfirmationModal";
50
51
  OsContextModule["tableActions"] = "tableActions";
@@ -7,6 +7,7 @@ export declare enum OsOwnerType {
7
7
  collection = "collection",
8
8
  connectedApps = "connectedApps",
9
9
  inventory = "inventory",
10
+ privateViewingRoom = "privateViewingRoom",
10
11
  studio = "studio",
11
12
  studioInstagram = "studioInstagram",
12
13
  studioMailchimp = "studioMailchimp",
@@ -17,6 +17,7 @@ exports.OsOwnerType = OsOwnerType;
17
17
  OsOwnerType["collection"] = "collection";
18
18
  OsOwnerType["connectedApps"] = "connectedApps";
19
19
  OsOwnerType["inventory"] = "inventory";
20
+ OsOwnerType["privateViewingRoom"] = "privateViewingRoom";
20
21
  OsOwnerType["studio"] = "studio";
21
22
  OsOwnerType["studioInstagram"] = "studioInstagram";
22
23
  OsOwnerType["studioMailchimp"] = "studioMailchimp";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@artsy/cohesion",
3
- "version": "4.390.0",
3
+ "version": "4.391.0",
4
4
  "description": "Analytics schema",
5
5
  "main": "dist/index.js",
6
6
  "publishConfig": {