forked from bootstrap-vue/bootstrap-vue
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathindex.d.ts
67 lines (57 loc) · 1.56 KB
/
index.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
import Vue, { Component, PluginFunction, PluginObject } from 'vue'
// Plugin Config Options
export type BvConfigComponentOptionValue =
| string
| string[]
| number
| number[]
| boolean
| object
| null
export type BvConfigBreakpointsValue = string[]
export interface BvConfigComponentOptions {
[key: string]: BvConfigComponentOptionValue | any
}
export interface BvConfigOptions {
breakpoints?: BvConfigBreakpointsValue
[key: string]: BvConfigComponentOptions | any
}
// Plugin definition
export interface BvPlugin extends PluginObject<BvConfigOptions> {
install: PluginFunction<BvConfigOptions>
}
// Component base definition
export class BvComponent extends Vue {
// Simple catch-all to allow any prop/type
[key: string]: any
}
// Generic BvEvent Object
export interface BvEvent {
readonly type: string
readonly cancelable: boolean
readonly nativeEvent: any
readonly target: any
readonly relatedTarget: any
readonly defaultPrevented: boolean
readonly vueTarget: Vue | Component | null
readonly componentId: string | null
preventDefault: () => void
// Catch all
[key: string]: any
}
// Vue prototype augments
import './vue-injections'
// BvConfig Plugin
export * from './bv-config'
// Components & Plugins
export * from './components'
// Icons & Plugin
export * from './icons'
// Directives & Plugins
export * from './directives'
// BootstrapVue plugin
export interface BootstrapVuePlugin extends BvPlugin {
setConfig: (config: BvConfigOptions) => void
}
export declare const BootstrapVue: BootstrapVuePlugin
export default BootstrapVue