File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 11# ScreenData
22A Data Model structure for displaying UI Screens
33
4-
5- ## Model POC
6-
7- ### Screen
8- ```
9- Screen {
10- id: String? // UUID
11-
12- title: String
13- subtitle: String?
14-
15- backgroundColor: Color
16-
17- headerView: View?
18- views: [View]
19- footerView: View?
20- }
21- ```
22-
23- ### ViewDirectionAxis
24- ```
25- enum ViewDirectionAxis {
26- case vertical
27- case horizontal
28- }
29- ```
30-
31- ### View
32- ```
33- View {
34- title: String
35- subtitle: String?
36-
37- type: ViewType
38-
39- image: Image?
40-
41- destination: Screen?
42- axis: ViewDirectionAxis
43-
44- views: [View]
45- }
46- ```
47-
48- ### ViewType
49- ```
50- enum ViewType {
51- case label
52- case image
53- case labeledImage
54- case container
55- }
56- ```
57-
58- ### Views
59-
60- #### Label
61- ```
62- Label {
63- title: String
64- subtitle: String?
65-
66- type: ViewType = .label
67-
68- destination: Screen?
69- }
70- ```
71-
72- #### Image
73- ```
74- Image {
75- image: Image
76-
77- type: ViewType = .image
78-
79- destination: Screen?
80- }
81- ```
82-
83- #### LabeledImage
84- ```
85- LabeledImage {
86- title: String
87- subtitle: String?
88- image: Image
89-
90- type: ViewType = .labeledImage
91-
92- destination: Screen?
93- }
94- ```
95-
96- #### ContainerView
97- ```
98- ContainerView {
99- type: ViewType = .container
100-
101- axis: ViewDirectionAxis
102-
103- views: [View]
104- }
105- ```
106-
107- #### DestinationType
108- ```
109- DestinationType {
110- case screen
111- case url
112- case deepLink
113- }
114- ```
115-
116- #### ScreenDestination
117- ```
118- ScreenDestination {
119- screenID: String
120- type: DesitinationType = .screen
121- }
122- ```
123-
124- #### URLDestination
125- ```
126- URLDestination {
127- url: String
128- type: DestinationType = .url
129- }
130- ```
131-
132- #### DeepLinkDestination
133- ```
134- DeepLinkDestination {
135- screens: [DeepLinkScreen]
136- type: DestinationType = .deepLink
137- }
138- ```
139-
140- ##### DeepLinkScreen
141- ```
142- DeepLinkScreen {
143- screenID: String
144- order: Int
145- }
146- ```
You can’t perform that action at this time.
0 commit comments