forked from rucio/webui
-
Notifications
You must be signed in to change notification settings - Fork 0
/
rucio.d.ts
181 lines (158 loc) · 3.87 KB
/
rucio.d.ts
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
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
/************************ Rucio WebUI Client PropType Definitions ************************/
type AccountType = {
account: string
scope?: string
identities?: string[]
rules?: string[]
email?: string
type?: 'USER' | 'GROUP' | 'SERVICE'
}
type AccountLimitType = {}
type AuthHeaders = {}
type RuleType = {
rule_id: string
locks?: any[]
history?: any[]
scope_name?: string
analysis?: object
}
type DidType = {
id: string
}
type RSEType = {
rse: string
remaining_quota?: string
total_quota?: string
}
/************************ Rucio WebUI Story Components PropType Definitions ************************/
interface AlertProps {
open?: boolean
leftIcon?: ReactElement | undefined
rightIcon?: ReactElement | undefined
message?: string | any
variant?: 'primary' | 'warn' | 'success' | 'error'
onClose?: () => void
}
interface BoxProps {
title?: string
type?: 'condensed' | 'spacious' | 'blue' | 'danger'
background?: string
children?: any
}
interface ButtonProps {
icon?: ReactNode
kind?: 'primary' | 'secondary' | 'outline'
show?: 'danger' | 'block' | 'invisible' | 'normal'
size?: 'small' | 'medium' | 'large'
label: string
type?: 'button' | 'submit' | 'reset'
selected?: boolean
disabled?: boolean
onClick?: (args: unknown) => void
}
interface CardProps {
img?: any
header?: ReactElement | string
content: ReactElement
footer?: Array<any>
onCardClick?: (args: unknown) => void
hoverable?: boolean
}
interface CheckboxProps {
isChecked?: boolean
label: string
kind?: 'danger' | 'warning' | 'success' | 'info'
size?: 'small' | 'normal' | 'medium' | 'large'
style?: 'rounded_checkbox' | 'block' | 'no_border' | 'background-color'
type?: 'checkbox' | 'radio'
name?: string
handleChange?: (args: any) => void
}
interface DropdownProps {
label?: string
options?: Array<string>
handleChange?: (args: any) => void
}
interface FormProps {
title?: string
subtitle?: string
children?: any
onSubmit?: (args: unknown) => void
}
interface HeaderProps {
menuActive?: boolean
menuCollapsible?: boolean
user?: {
name: string
}
onLogin?: () => void
onLogout?: () => void
onCreateAccount?: () => void
}
interface ImageProps {
src: string
type?: string
height?: number
width?: number
}
interface InputProps {
type?: string
label?: string
name?: string
placeholder?: string
kind?: 'primary' | 'info' | 'link' | 'normal'
show?: 'danger' | 'warning' | 'success' | 'rounded'
size?: 'small' | 'medium' | 'large'
value?: any
min?: number
max?: number
width?: string | number
focusByDefault?: boolean
onChange?: (args: any) => void
}
interface ModalProps {
active?: boolean
body?: ReactElement
title?: string
onClose?: () => void
}
interface NavProps {
active?: boolean
menuItems?: any
}
interface ProgressBarProps {
title?: string
size?: 'small' | 'medium' | 'large'
type?: 'primary' | 'link' | 'info' | 'success' | 'warning' | 'danger'
value?: number
max?: number
}
interface StepsProps {
steps: Array<any>
active?: number
size?: 'small' | 'medium' | 'large'
}
interface TableProps {
id?: string
columns?: string[]
rows?: any[]
footer?: string[]
}
interface TabsProps {
tabs: Array<string>
active: number
alignment?: 'right' | 'centered'
size?: 'small' | 'medium' | 'large'
rounded?: 'toggle' | 'toggle-rounded'
boxed?: 'boxed'
fullwidth?: 'fullwidth'
handleClick: (args: any) => void
}
interface ToggleSwitchProps {
label?: string
kind?: 'danger' | 'warning' | 'success' | 'info'
size?: 'small' | 'normal' | 'medium' | 'large'
style?: 'rounded' | 'outlined'
checked?: boolean
handleChange?: (event: any) => void
}