-
Notifications
You must be signed in to change notification settings - Fork 10
Expand file tree
/
Copy pathcontext.ts
More file actions
38 lines (32 loc) · 1.1 KB
/
context.ts
File metadata and controls
38 lines (32 loc) · 1.1 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
import { createContext } from '@lit/context';
import type { Ref } from 'lit/directives/ref.js';
import type { IgcSplitterComponent } from '../../index.js';
import type IgcCarouselComponent from '../carousel/carousel.js';
import type { ChatState } from '../chat/chat-state.js';
import type IgcTileManagerComponent from '../tile-manager/tile-manager.js';
export type TileManagerContext = {
/** The igc-tile-manager instance. */
instance: IgcTileManagerComponent;
/** The internal CSS grid container of the igc-tile-manager. */
grid: Ref<HTMLElement>;
};
const carouselContext = createContext<IgcCarouselComponent>(
Symbol('carousel-context')
);
const tileManagerContext = createContext<TileManagerContext>(
Symbol('tile-manager-context')
);
const chatContext = createContext<ChatState>(Symbol('chat-context'));
const chatUserInputContext = createContext<ChatState>(
Symbol('chat-user-input-context')
);
const splitterContext = createContext<IgcSplitterComponent>(
Symbol('splitter-context')
);
export {
carouselContext,
tileManagerContext,
chatContext,
chatUserInputContext,
splitterContext,
};