@artsy/cohesion 4.369.0 → 4.370.0--canary.714.15136.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/dist/Schema/index.d.ts +1 -0
- package/dist/Schema/index.js +12 -0
- package/dist/Schema/os/Events/FilterSortSearch.d.ts +162 -0
- package/dist/Schema/os/Events/FilterSortSearch.js +1 -0
- package/dist/Schema/os/Events/index.d.ts +26 -1
- package/dist/Schema/os/Events/index.js +6 -0
- package/dist/Schema/os/Values/OsContextModule.d.ts +2 -0
- package/dist/Schema/os/Values/OsContextModule.js +2 -0
- package/package.json +1 -1
package/dist/Schema/index.d.ts
CHANGED
|
@@ -54,6 +54,7 @@ export * from "./os/Events";
|
|
|
54
54
|
export * from "./os/Events/BrandKit";
|
|
55
55
|
export * from "./os/Events/Click";
|
|
56
56
|
export * from "./os/Events/ConnectedAppsFlow";
|
|
57
|
+
export * from "./os/Events/FilterSortSearch";
|
|
57
58
|
export * from "./os/Events/InstagramEditor";
|
|
58
59
|
export * from "./os/Events/InventoryTable";
|
|
59
60
|
export * from "./os/Events/MultiAddFlow";
|
package/dist/Schema/index.js
CHANGED
|
@@ -568,6 +568,18 @@ Object.keys(_ConnectedAppsFlow).forEach(function (key) {
|
|
|
568
568
|
});
|
|
569
569
|
});
|
|
570
570
|
|
|
571
|
+
var _FilterSortSearch = require("./os/Events/FilterSortSearch");
|
|
572
|
+
|
|
573
|
+
Object.keys(_FilterSortSearch).forEach(function (key) {
|
|
574
|
+
if (key === "default" || key === "__esModule") return;
|
|
575
|
+
Object.defineProperty(exports, key, {
|
|
576
|
+
enumerable: true,
|
|
577
|
+
get: function get() {
|
|
578
|
+
return _FilterSortSearch[key];
|
|
579
|
+
}
|
|
580
|
+
});
|
|
581
|
+
});
|
|
582
|
+
|
|
571
583
|
var _InstagramEditor = require("./os/Events/InstagramEditor");
|
|
572
584
|
|
|
573
585
|
Object.keys(_InstagramEditor).forEach(function (key) {
|
|
@@ -0,0 +1,162 @@
|
|
|
1
|
+
import { OsContextModule } from "../Values/OsContextModule";
|
|
2
|
+
import { OsOwnerType } from "../Values/OsOwnerType";
|
|
3
|
+
import { OsActionType } from ".";
|
|
4
|
+
/**
|
|
5
|
+
* Schemas describing Art OS Filter, Sort & Search events
|
|
6
|
+
* @packageDocumentation
|
|
7
|
+
*/
|
|
8
|
+
/**
|
|
9
|
+
* A partner opens the filter drawer via the Filter pill in the inventory or collection view.
|
|
10
|
+
*
|
|
11
|
+
* This schema describes events sent to Segment from [[OsClickedFilterDrawer]]
|
|
12
|
+
*
|
|
13
|
+
* @example
|
|
14
|
+
* ```
|
|
15
|
+
* {
|
|
16
|
+
* action: "clickedFilterDrawer",
|
|
17
|
+
* context_module: "artworkFilters",
|
|
18
|
+
* context_page_owner_type: "inventory",
|
|
19
|
+
* value: 2
|
|
20
|
+
* }
|
|
21
|
+
* ```
|
|
22
|
+
*/
|
|
23
|
+
export interface OsClickedFilterDrawer {
|
|
24
|
+
action: OsActionType.clickedFilterDrawer;
|
|
25
|
+
context_module: OsContextModule.artworkFilters;
|
|
26
|
+
context_page_owner_type: OsOwnerType.inventory | OsOwnerType.collection;
|
|
27
|
+
/** Number of active filters when opening the drawer */
|
|
28
|
+
value: number;
|
|
29
|
+
}
|
|
30
|
+
/**
|
|
31
|
+
* A partner applies a filter in the filter drawer.
|
|
32
|
+
* One event fires per selection; `label` identifies the filter type
|
|
33
|
+
* and `value` carries the selected value.
|
|
34
|
+
*
|
|
35
|
+
* This schema describes events sent to Segment from [[OsAppliedFilter]]
|
|
36
|
+
*
|
|
37
|
+
* @example Availability filter
|
|
38
|
+
* ```
|
|
39
|
+
* {
|
|
40
|
+
* action: "appliedFilter",
|
|
41
|
+
* context_module: "artworkFilters",
|
|
42
|
+
* context_page_owner_type: "inventory",
|
|
43
|
+
* label: "availability",
|
|
44
|
+
* value: "for sale"
|
|
45
|
+
* }
|
|
46
|
+
* ```
|
|
47
|
+
*
|
|
48
|
+
* @example Artist filter
|
|
49
|
+
* ```
|
|
50
|
+
* {
|
|
51
|
+
* action: "appliedFilter",
|
|
52
|
+
* context_module: "artworkFilters",
|
|
53
|
+
* context_page_owner_type: "collection",
|
|
54
|
+
* label: "artist",
|
|
55
|
+
* value: "<artistId>"
|
|
56
|
+
* }
|
|
57
|
+
* ```
|
|
58
|
+
*/
|
|
59
|
+
export interface OsAppliedFilter {
|
|
60
|
+
action: OsActionType.appliedFilter;
|
|
61
|
+
context_module: OsContextModule.artworkFilters;
|
|
62
|
+
context_page_owner_type: OsOwnerType.inventory | OsOwnerType.collection;
|
|
63
|
+
label: "availability" | "status" | "location" | "artist" | "coa";
|
|
64
|
+
value: string;
|
|
65
|
+
}
|
|
66
|
+
/**
|
|
67
|
+
* A partner removes a single filter via the selected-filter pill or the per-section Clear link.
|
|
68
|
+
*
|
|
69
|
+
* This schema describes events sent to Segment from [[OsRemovedFilter]]
|
|
70
|
+
*
|
|
71
|
+
* @example
|
|
72
|
+
* ```
|
|
73
|
+
* {
|
|
74
|
+
* action: "removedFilter",
|
|
75
|
+
* context_module: "artworkFilters",
|
|
76
|
+
* context_page_owner_type: "inventory",
|
|
77
|
+
* label: "availability",
|
|
78
|
+
* value: "for sale"
|
|
79
|
+
* }
|
|
80
|
+
* ```
|
|
81
|
+
*/
|
|
82
|
+
export interface OsRemovedFilter {
|
|
83
|
+
action: OsActionType.removedFilter;
|
|
84
|
+
context_module: OsContextModule.artworkFilters;
|
|
85
|
+
context_page_owner_type: OsOwnerType.inventory | OsOwnerType.collection;
|
|
86
|
+
label: "availability" | "status" | "location" | "artist" | "coa";
|
|
87
|
+
value: string;
|
|
88
|
+
}
|
|
89
|
+
/**
|
|
90
|
+
* A partner clears all active filters via the "Clear all" button.
|
|
91
|
+
*
|
|
92
|
+
* This schema describes events sent to Segment from [[OsClearedFilters]]
|
|
93
|
+
*
|
|
94
|
+
* @example
|
|
95
|
+
* ```
|
|
96
|
+
* {
|
|
97
|
+
* action: "clearedFilters",
|
|
98
|
+
* context_module: "artworkFilters",
|
|
99
|
+
* context_page_owner_type: "inventory",
|
|
100
|
+
* value: 3
|
|
101
|
+
* }
|
|
102
|
+
* ```
|
|
103
|
+
*/
|
|
104
|
+
export interface OsClearedFilters {
|
|
105
|
+
action: OsActionType.clearedFilters;
|
|
106
|
+
context_module: OsContextModule.artworkFilters;
|
|
107
|
+
context_page_owner_type: OsOwnerType.inventory | OsOwnerType.collection;
|
|
108
|
+
/** Number of filters cleared */
|
|
109
|
+
value: number;
|
|
110
|
+
}
|
|
111
|
+
/**
|
|
112
|
+
* A partner clicks a sortable column header to sort the artwork table.
|
|
113
|
+
* A column-header click cycles ascending → descending → default.
|
|
114
|
+
*
|
|
115
|
+
* This schema describes events sent to Segment from [[OsSortedColumn]]
|
|
116
|
+
*
|
|
117
|
+
* @example
|
|
118
|
+
* ```
|
|
119
|
+
* {
|
|
120
|
+
* action: "sortedColumn",
|
|
121
|
+
* context_module: "artworkTable",
|
|
122
|
+
* context_page_owner_type: "inventory",
|
|
123
|
+
* label: "date added",
|
|
124
|
+
* value: "asc"
|
|
125
|
+
* }
|
|
126
|
+
* ```
|
|
127
|
+
*/
|
|
128
|
+
export interface OsSortedColumn {
|
|
129
|
+
action: OsActionType.sortedColumn;
|
|
130
|
+
context_module: OsContextModule.artworkTable;
|
|
131
|
+
context_page_owner_type: OsOwnerType.inventory | OsOwnerType.collection;
|
|
132
|
+
/** The column being sorted */
|
|
133
|
+
label: string;
|
|
134
|
+
value: "asc" | "desc" | "default";
|
|
135
|
+
}
|
|
136
|
+
/**
|
|
137
|
+
* A partner submits a keyword search in the artwork search bar.
|
|
138
|
+
* Fires on the debounced commit (not per keystroke).
|
|
139
|
+
*
|
|
140
|
+
* This schema describes events sent to Segment from [[OsSearchedArtworks]]
|
|
141
|
+
*
|
|
142
|
+
* @example
|
|
143
|
+
* ```
|
|
144
|
+
* {
|
|
145
|
+
* action: "searchedArtworks",
|
|
146
|
+
* context_module: "artworkSearch",
|
|
147
|
+
* context_page_owner_type: "inventory",
|
|
148
|
+
* query: "Kelly",
|
|
149
|
+
* value: 42
|
|
150
|
+
* }
|
|
151
|
+
* ```
|
|
152
|
+
*/
|
|
153
|
+
export interface OsSearchedArtworks {
|
|
154
|
+
action: OsActionType.searchedArtworks;
|
|
155
|
+
context_module: OsContextModule.artworkSearch;
|
|
156
|
+
context_page_owner_type: OsOwnerType.inventory | OsOwnerType.collection;
|
|
157
|
+
/** The committed search string */
|
|
158
|
+
query: string;
|
|
159
|
+
/** Number of results after the search resolves */
|
|
160
|
+
value: number;
|
|
161
|
+
}
|
|
162
|
+
export type OsFilterSortSearch = OsAppliedFilter | OsClearedFilters | OsClickedFilterDrawer | OsRemovedFilter | OsSearchedArtworks | OsSortedColumn;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { ClickedAddBrandKitFile, ClickedBrandKitColor, ClickedBrandKitFont, ClickedSaveBrandKit } from "./BrandKit";
|
|
2
2
|
import { OsClickEvent } from "./Click";
|
|
3
3
|
import { OsConnectedAppsFlow } from "./ConnectedAppsFlow";
|
|
4
|
+
import { OsFilterSortSearch } from "./FilterSortSearch";
|
|
4
5
|
import { OsInstagramEditor } from "./InstagramEditor";
|
|
5
6
|
import { OsInventoryTable } from "./InventoryTable";
|
|
6
7
|
import { OsMaterialsEditor } from "./MaterialsEditor";
|
|
@@ -11,13 +12,17 @@ import { OsSubmitEvent } from "./Submit";
|
|
|
11
12
|
*
|
|
12
13
|
* Each event describes one ActionType
|
|
13
14
|
*/
|
|
14
|
-
export type OsEvent = OsMultiAddFlow | ClickedBrandKitColor | ClickedBrandKitFont | ClickedAddBrandKitFile | ClickedSaveBrandKit | OsConnectedAppsFlow | OsClickEvent | OsInstagramEditor | OsInventoryTable | OsMaterialsEditor | OsSubmitEvent;
|
|
15
|
+
export type OsEvent = OsMultiAddFlow | ClickedBrandKitColor | ClickedBrandKitFont | ClickedAddBrandKitFile | ClickedSaveBrandKit | OsConnectedAppsFlow | OsClickEvent | OsFilterSortSearch | OsInstagramEditor | OsInventoryTable | OsMaterialsEditor | OsSubmitEvent;
|
|
15
16
|
/**
|
|
16
17
|
* List of all Art OS actions
|
|
17
18
|
*
|
|
18
19
|
* Each OsActionType corresponds with a table in Redshift.
|
|
19
20
|
*/
|
|
20
21
|
export declare enum OsActionType {
|
|
22
|
+
/**
|
|
23
|
+
* Corresponds to {@link OsFilterSortSearch}
|
|
24
|
+
*/
|
|
25
|
+
appliedFilter = "appliedFilter",
|
|
21
26
|
/**
|
|
22
27
|
* Corresponds to {@link OsInventoryTable}
|
|
23
28
|
*/
|
|
@@ -59,6 +64,10 @@ export declare enum OsActionType {
|
|
|
59
64
|
* Corresponds to {@link ClickedCancelBulkEdit}
|
|
60
65
|
*/
|
|
61
66
|
clickedCancelBulkEdit = "clickedCancelBulkEdit",
|
|
67
|
+
/**
|
|
68
|
+
* Corresponds to {@link OsFilterSortSearch}
|
|
69
|
+
*/
|
|
70
|
+
clickedFilterDrawer = "clickedFilterDrawer",
|
|
62
71
|
/**
|
|
63
72
|
* Corresponds to {@link ClickedConnectAccount}
|
|
64
73
|
*/
|
|
@@ -115,6 +124,10 @@ export declare enum OsActionType {
|
|
|
115
124
|
* Corresponds to {@link OsMaterialsEditor} and {@link OsInstagramEditor}
|
|
116
125
|
*/
|
|
117
126
|
createdStudioContent = "createdStudioContent",
|
|
127
|
+
/**
|
|
128
|
+
* Corresponds to {@link OsFilterSortSearch}
|
|
129
|
+
*/
|
|
130
|
+
clearedFilters = "clearedFilters",
|
|
118
131
|
/**
|
|
119
132
|
* Corresponds to {@link DeletedArtwork}
|
|
120
133
|
*/
|
|
@@ -131,6 +144,10 @@ export declare enum OsActionType {
|
|
|
131
144
|
* Corresponds to {@link OsInventoryTable}
|
|
132
145
|
*/
|
|
133
146
|
removedArtworkDocument = "removedArtworkDocument",
|
|
147
|
+
/**
|
|
148
|
+
* Corresponds to {@link OsFilterSortSearch}
|
|
149
|
+
*/
|
|
150
|
+
removedFilter = "removedFilter",
|
|
134
151
|
/**
|
|
135
152
|
* Corresponds to {@link ResumedArtworkImport}
|
|
136
153
|
*/
|
|
@@ -139,6 +156,14 @@ export declare enum OsActionType {
|
|
|
139
156
|
* Corresponds to {@link OsInventoryTable}
|
|
140
157
|
*/
|
|
141
158
|
savedArtworkImages = "savedArtworkImages",
|
|
159
|
+
/**
|
|
160
|
+
* Corresponds to {@link OsFilterSortSearch}
|
|
161
|
+
*/
|
|
162
|
+
searchedArtworks = "searchedArtworks",
|
|
163
|
+
/**
|
|
164
|
+
* Corresponds to {@link OsFilterSortSearch}
|
|
165
|
+
*/
|
|
166
|
+
sortedColumn = "sortedColumn",
|
|
142
167
|
/**
|
|
143
168
|
* Corresponds to {@link StartedArtworkImport}
|
|
144
169
|
*/
|
|
@@ -20,6 +20,7 @@ var OsActionType;
|
|
|
20
20
|
exports.OsActionType = OsActionType;
|
|
21
21
|
|
|
22
22
|
(function (OsActionType) {
|
|
23
|
+
OsActionType["appliedFilter"] = "appliedFilter";
|
|
23
24
|
OsActionType["addedArtist"] = "addedArtist";
|
|
24
25
|
OsActionType["addedArtworkDocument"] = "addedArtworkDocument";
|
|
25
26
|
OsActionType["addedLocation"] = "addedLocation";
|
|
@@ -31,6 +32,7 @@ exports.OsActionType = OsActionType;
|
|
|
31
32
|
OsActionType["clickedAspectRatio"] = "clickedAspectRatio";
|
|
32
33
|
OsActionType["clickedBrandKitModal"] = "clickedBrandKitModal";
|
|
33
34
|
OsActionType["clickedCancelBulkEdit"] = "clickedCancelBulkEdit";
|
|
35
|
+
OsActionType["clickedFilterDrawer"] = "clickedFilterDrawer";
|
|
34
36
|
OsActionType["clickedConnectAccount"] = "clickedConnectAccount";
|
|
35
37
|
OsActionType["clickedConnectAccountModal"] = "clickedConnectAccountModal";
|
|
36
38
|
OsActionType["clickedConnectModal"] = "clickedConnectModal";
|
|
@@ -45,11 +47,15 @@ exports.OsActionType = OsActionType;
|
|
|
45
47
|
OsActionType["completedArtworkImport"] = "completedArtworkImport";
|
|
46
48
|
OsActionType["createdImportedArtworks"] = "createdImportedArtworks";
|
|
47
49
|
OsActionType["createdStudioContent"] = "createdStudioContent";
|
|
50
|
+
OsActionType["clearedFilters"] = "clearedFilters";
|
|
48
51
|
OsActionType["deletedArtwork"] = "deletedArtwork";
|
|
49
52
|
OsActionType["distributedArtworks"] = "distributedArtworks";
|
|
50
53
|
OsActionType["editedArtworkField"] = "editedArtworkField";
|
|
51
54
|
OsActionType["removedArtworkDocument"] = "removedArtworkDocument";
|
|
55
|
+
OsActionType["removedFilter"] = "removedFilter";
|
|
52
56
|
OsActionType["resumedArtworkImport"] = "resumedArtworkImport";
|
|
53
57
|
OsActionType["savedArtworkImages"] = "savedArtworkImages";
|
|
58
|
+
OsActionType["searchedArtworks"] = "searchedArtworks";
|
|
59
|
+
OsActionType["sortedColumn"] = "sortedColumn";
|
|
54
60
|
OsActionType["startedArtworkImport"] = "startedArtworkImport";
|
|
55
61
|
})(OsActionType || (exports.OsActionType = OsActionType = {}));
|
|
@@ -8,6 +8,8 @@ export declare enum OsContextModule {
|
|
|
8
8
|
actionsDropdown = "actionsDropdown",
|
|
9
9
|
addArtistModal = "addArtistModal",
|
|
10
10
|
addLocationModal = "addLocationModal",
|
|
11
|
+
artworkFilters = "artworkFilters",
|
|
12
|
+
artworkSearch = "artworkSearch",
|
|
11
13
|
artworkTable = "artworkTable",
|
|
12
14
|
brandKit = "brandKit",
|
|
13
15
|
brandKitPromptModal = "brandKitPromptModal",
|
|
@@ -18,6 +18,8 @@ exports.OsContextModule = OsContextModule;
|
|
|
18
18
|
OsContextModule["actionsDropdown"] = "actionsDropdown";
|
|
19
19
|
OsContextModule["addArtistModal"] = "addArtistModal";
|
|
20
20
|
OsContextModule["addLocationModal"] = "addLocationModal";
|
|
21
|
+
OsContextModule["artworkFilters"] = "artworkFilters";
|
|
22
|
+
OsContextModule["artworkSearch"] = "artworkSearch";
|
|
21
23
|
OsContextModule["artworkTable"] = "artworkTable";
|
|
22
24
|
OsContextModule["brandKit"] = "brandKit";
|
|
23
25
|
OsContextModule["brandKitPromptModal"] = "brandKitPromptModal";
|