Skip to content

Commit 972ff91

Browse files
Add deprecated types to maintain backward compatibility
Signed-off-by: Andrei Floricel <andrei.floricel@gmail.com>
1 parent 87b859e commit 972ff91

2 files changed

Lines changed: 49 additions & 0 deletions

File tree

src/context/ContextType.ts

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -44,3 +44,28 @@ export type ExperimentalContextType =
4444
* @see https://fdc3.finos.org/docs/context/spec
4545
*/
4646
export type ContextType = StandardContextType | ExperimentalContextType | (string & {});
47+
48+
/**
49+
* @deprecated Use {@link StandardContextType} instead
50+
*/
51+
export enum ContextTypes {
52+
Chart = 'fdc3.chart',
53+
ChatInitSettings = 'fdc3.chat.initSettings',
54+
ChatRoom = 'fdc3.chat.room',
55+
Contact = 'fdc3.contact',
56+
ContactList = 'fdc3.contactList',
57+
Country = 'fdc3.country',
58+
Currency = 'fdc3.currency',
59+
Email = 'fdc3.email',
60+
Instrument = 'fdc3.instrument',
61+
InstrumentList = 'fdc3.instrumentList',
62+
Interaction = 'fdc3.interaction',
63+
Nothing = 'fdc3.nothing',
64+
Organization = 'fdc3.organization',
65+
Portfolio = 'fdc3.portfolio',
66+
Position = 'fdc3.position',
67+
ChatSearchCriteria = 'fdc3.chat.searchCriteria',
68+
TimeRange = 'fdc3.timerange',
69+
TransactionResult = 'fdc3.transactionResult',
70+
Valuation = 'fdc3.valuation',
71+
}

src/intents/Intents.ts

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -39,3 +39,27 @@ export type Intent = StandardIntent | (string & {});
3939
* @example `ContextTypeFor<'StartCall'>` is equivalent to `'fdc3.contact' | 'fdc3.contactList' | 'fdc3.nothing'`
4040
*/
4141
export type ContextTypeFor<I extends StandardIntent> = typeof IntentsConfiguration[I][number];
42+
43+
/**
44+
* @deprecated Use {@link StandardIntent} instead
45+
*/
46+
export enum Intents {
47+
CreateInteraction = 'CreateInteraction',
48+
SendChatMessage = 'SendChatMessage',
49+
StartCall = 'StartCall',
50+
StartChat = 'StartChat',
51+
StartEmail = 'StartEmail',
52+
ViewAnalysis = 'ViewAnalysis',
53+
ViewChat = 'ViewChat',
54+
ViewChart = 'ViewChart',
55+
ViewContact = 'ViewContact',
56+
ViewHoldings = 'ViewHoldings',
57+
ViewInstrument = 'ViewInstrument',
58+
ViewInteractions = 'ViewInteractions',
59+
ViewMessages = 'ViewMessages',
60+
ViewNews = 'ViewNews',
61+
ViewOrders = 'ViewOrders',
62+
ViewProfile = 'ViewProfile',
63+
ViewQuote = 'ViewQuote',
64+
ViewResearch = 'ViewResearch',
65+
}

0 commit comments

Comments
 (0)