forked from prometheus/alertmanager
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Types.elm
69 lines (62 loc) · 2.11 KB
/
Types.elm
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
module Types exposing (Model, Msg(..), Route(..))
import Browser.Navigation exposing (Key)
import Utils.Filter exposing (Filter, SilenceFormGetParams)
import Utils.Types exposing (ApiData)
import Views.AlertList.Types as AlertList exposing (AlertListMsg)
import Views.Settings.Types as SettingsView exposing (SettingsMsg)
import Views.SilenceForm.Types as SilenceForm exposing (SilenceFormMsg)
import Views.SilenceList.Types as SilenceList exposing (SilenceListMsg)
import Views.SilenceView.Types as SilenceView exposing (SilenceViewMsg)
import Views.Status.Types exposing (StatusModel, StatusMsg)
type alias Model =
{ silenceList : SilenceList.Model
, silenceView : SilenceView.Model
, silenceForm : SilenceForm.Model
, alertList : AlertList.Model
, route : Route
, filter : Filter
, status : StatusModel
, basePath : String
, apiUrl : String
, libUrl : String
, bootstrapCSS : ApiData String
, fontAwesomeCSS : ApiData String
, elmDatepickerCSS : ApiData String
, defaultCreator : String
, expandAll : Bool
, key : Key
, settings : SettingsView.Model
}
type Msg
= MsgForAlertList AlertListMsg
| MsgForSilenceView SilenceViewMsg
| MsgForSilenceForm SilenceFormMsg
| MsgForSilenceList SilenceListMsg
| MsgForStatus StatusMsg
| MsgForSettings SettingsMsg
| NavigateToAlerts Filter
| NavigateToNotFound
| NavigateToSilenceView String
| NavigateToSilenceFormEdit String
| NavigateToSilenceFormNew SilenceFormGetParams
| NavigateToSilenceList Filter
| NavigateToStatus
| NavigateToSettings
| NavigateToInternalUrl String
| NavigateToExternalUrl String
| RedirectAlerts
| BootstrapCSSLoaded (ApiData String)
| FontAwesomeCSSLoaded (ApiData String)
| ElmDatepickerCSSLoaded (ApiData String)
| SetDefaultCreator String
| SetGroupExpandAll Bool
type Route
= AlertsRoute Filter
| NotFoundRoute
| SilenceFormEditRoute String
| SilenceFormNewRoute SilenceFormGetParams
| SilenceListRoute Filter
| SilenceViewRoute String
| StatusRoute
| TopLevelRoute
| SettingsRoute