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
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
|
using System.Configuration;
using MaterialDesignDemo;
using MaterialDesignDemo.Domain;
using MaterialDesignThemes.Wpf;
using MaterialDesignThemes.Wpf.Transitions;
using System.Windows.Controls;
using System;
namespace MaterialDesignColors.WpfExample.Domain
{
public class MainWindowViewModel
{
public MainWindowViewModel(ISnackbarMessageQueue snackbarMessageQueue)
{
if (snackbarMessageQueue == null) throw new ArgumentNullException(nameof(snackbarMessageQueue));
DemoItems = new[]
{
new DemoItem("Home", new Home(),
new []
{
new DocumentationLink(DocumentationLinkType.Wiki, $"{ConfigurationManager.AppSettings["GitHub"]}/wiki", "WIKI"),
DocumentationLink.DemoPageLink<Home>()
}
),
new DemoItem("Palette", new PaletteSelector { DataContext = new PaletteSelectorViewModel() },
new []
{
DocumentationLink.WikiLink("Brush-Names", "Brushes"),
DocumentationLink.WikiLink("Custom-Palette-Hues", "Custom Palettes"),
DocumentationLink.WikiLink("Swatches-and-Recommended-Colors", "Swatches"),
DocumentationLink.DemoPageLink<PaletteSelector>("Demo View"),
DocumentationLink.DemoPageLink<PaletteSelectorViewModel>("Demo View Model"),
DocumentationLink.ApiLink<PaletteHelper>()
}),
new DemoItem("Buttons & Toggles", new Buttons { DataContext = new ButtonsViewModel() } ,
new []
{
DocumentationLink.WikiLink("Button-Styles", "Buttons"),
DocumentationLink.DemoPageLink<Buttons>("Demo View"),
DocumentationLink.DemoPageLink<ButtonsViewModel>("Demo View Model"),
DocumentationLink.StyleLink("Button"),
DocumentationLink.StyleLink("CheckBox"),
DocumentationLink.StyleLink("PopupBox"),
DocumentationLink.StyleLink("ToggleButton"),
DocumentationLink.ApiLink<PopupBox>()
})
{
VerticalScrollBarVisibilityRequirement = ScrollBarVisibility.Auto
},
new DemoItem("Fields", new TextFields(),
new []
{
DocumentationLink.DemoPageLink<TextFields>(),
DocumentationLink.StyleLink("TextBox"),
DocumentationLink.StyleLink("ComboBox"),
})
{
VerticalScrollBarVisibilityRequirement = ScrollBarVisibility.Auto
},
new DemoItem("Pickers", new Pickers { DataContext = new PickersViewModel()},
new []
{
DocumentationLink.DemoPageLink<Pickers>(),
DocumentationLink.StyleLink("Clock"),
DocumentationLink.StyleLink("DatePicker"),
DocumentationLink.ApiLink<TimePicker>()
}),
new DemoItem("Sliders", new Sliders(), new []
{
DocumentationLink.DemoPageLink<Sliders>(),
DocumentationLink.StyleLink("Sliders")
}),
new DemoItem("Chips", new Chips(), new []
{
DocumentationLink.DemoPageLink<Chips>(),
DocumentationLink.StyleLink("Chip"),
DocumentationLink.ApiLink<Chip>()
}),
new DemoItem("Typography", new Typography(), new []
{
DocumentationLink.DemoPageLink<Typography>(),
DocumentationLink.StyleLink("TextBlock")
})
{
VerticalScrollBarVisibilityRequirement = ScrollBarVisibility.Auto,
HorizontalScrollBarVisibilityRequirement = ScrollBarVisibility.Auto
},
new DemoItem("Cards", new Cards(), new []
{
DocumentationLink.DemoPageLink<Cards>(),
DocumentationLink.StyleLink("Card"),
DocumentationLink.ApiLink<Card>()
})
{
VerticalScrollBarVisibilityRequirement = ScrollBarVisibility.Auto
},
new DemoItem("Icon Pack", new IconPack { DataContext = new IconPackViewModel(snackbarMessageQueue) },
new []
{
DocumentationLink.DemoPageLink<IconPack>("Demo View"),
DocumentationLink.DemoPageLink<IconPackViewModel>("Demo View Model"),
DocumentationLink.ApiLink<PackIcon>()
}),
new DemoItem("Colour Zones", new ColorZones(),
new []
{
DocumentationLink.DemoPageLink<ColorZones>(),
DocumentationLink.ApiLink<ColorZone>()
}),
new DemoItem("Lists", new Lists { DataContext = new ListsAndGridsViewModel()},
new []
{
DocumentationLink.DemoPageLink<Lists>("Demo View"),
DocumentationLink.DemoPageLink<ListsAndGridsViewModel>("Demo View Model", "Domain"),
DocumentationLink.StyleLink("ListBox"),
DocumentationLink.StyleLink("ListView")
})
{
VerticalScrollBarVisibilityRequirement = ScrollBarVisibility.Auto
},
new DemoItem("Trees", new Trees { DataContext = new TreesViewModel() },
new []
{
DocumentationLink.DemoPageLink<Trees>("Demo View"),
DocumentationLink.DemoPageLink<TreesViewModel>("Demo View Model"),
DocumentationLink.StyleLink("TreeView")
}),
new DemoItem("Grids", new Grids { DataContext = new ListsAndGridsViewModel()},
new []
{
DocumentationLink.DemoPageLink<Grids>("Demo View"),
DocumentationLink.DemoPageLink<ListsAndGridsViewModel>("Demo View Model", "Domain"),
DocumentationLink.StyleLink("DataGrid")
}),
new DemoItem("Expander", new Expander(),
new []
{
DocumentationLink.DemoPageLink<Expander>(),
DocumentationLink.StyleLink("Expander")
}),
new DemoItem("Group Boxes", new GroupBoxes(),
new []
{
DocumentationLink.DemoPageLink<GroupBoxes>(),
DocumentationLink.StyleLink("GroupBox")
}),
new DemoItem("Menus & Tool Bars", new MenusAndToolBars(),
new []
{
DocumentationLink.DemoPageLink<MenusAndToolBars>(),
DocumentationLink.StyleLink("Menu"),
DocumentationLink.StyleLink("ToolBar")
}),
new DemoItem("Progress Indicators", new Progress(),
new []
{
DocumentationLink.DemoPageLink<Progress>(),
DocumentationLink.StyleLink("ProgressBar")
}),
new DemoItem("Dialogs", new Dialogs { DataContext = new DialogsViewModel()},
new []
{
DocumentationLink.WikiLink("Dialogs", "Dialogs"),
DocumentationLink.DemoPageLink<Dialogs>("Demo View"),
DocumentationLink.DemoPageLink<DialogsViewModel>("Demo View Model", "Domain"),
DocumentationLink.ApiLink<DialogHost>()
}),
new DemoItem("Drawer", new Drawers(),
new []
{
DocumentationLink.DemoPageLink<Drawers>(),
DocumentationLink.ApiLink<DrawerHost>()
}),
new DemoItem("Snackbar", new Snackbars(),
new []
{
DocumentationLink.WikiLink("Snackbar", "Snackbar"),
DocumentationLink.DemoPageLink<Snackbars>(),
DocumentationLink.StyleLink("Snackbar"),
DocumentationLink.ApiLink<Snackbar>(),
DocumentationLink.ApiLink<ISnackbarMessageQueue>()
}),
new DemoItem("Transitions", new Transitions(),
new []
{
DocumentationLink.WikiLink("Transitions", "Transitions"),
DocumentationLink.DemoPageLink<Transitions>(),
DocumentationLink.ApiLink<Transitioner>("Transitions"),
DocumentationLink.ApiLink<TransitionerSlide>("Transitions"),
DocumentationLink.ApiLink<TransitioningContent>("Transitions"),
}),
new DemoItem("Shadows", new Shadows(),
new []
{
DocumentationLink.DemoPageLink<Shadows>(),
}),
};
}
public DemoItem[] DemoItems { get; }
}
}
|