Skip to content

Commit 5209f0b

Browse files
committed
chore: add constants for default plugin state
1 parent 08cdf3e commit 5209f0b

File tree

3 files changed

+15
-0
lines changed

3 files changed

+15
-0
lines changed
Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
import { PluginDataStoreType, PluginListFiltersType } from './types'
2+
3+
export const DEFAULT_PLUGIN_DATA_STORE: PluginDataStoreType = {
4+
parentPluginStore: {},
5+
pluginVersionStore: {},
6+
}
7+
8+
export const DEFAULT_PLUGIN_LIST_FILTERS: PluginListFiltersType = {
9+
searchKey: '',
10+
selectedTags: [],
11+
offset: 0,
12+
showSelectedPlugins: false,
13+
}

src/Shared/Components/Plugin/index.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
11
export * from './types'
22
export * from './service'
33
export * from './utils'
4+
export * from './constants'

src/Shared/Components/Plugin/types.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -54,6 +54,7 @@ export interface PluginDetailPayloadType {
5454

5555
export interface PluginListFiltersType extends Pick<BaseFilterQueryParams<unknown>, 'searchKey' | 'offset'> {
5656
selectedTags: string[]
57+
showSelectedPlugins: boolean
5758
}
5859

5960
interface ParentPluginType extends Pick<ParentPluginDTO, 'id' | 'name' | 'description' | 'type' | 'icon'> {

0 commit comments

Comments
 (0)