Blame


1 2c251c14 2020-01-15 tracey /*
2 9460dac0 2020-01-15 tracey * Copyright (c) 2019, 2020 Tracey Emery <tracey@traceyemery.net>
3 2c251c14 2020-01-15 tracey *
4 2c251c14 2020-01-15 tracey * Permission to use, copy, modify, and distribute this software for any
5 2c251c14 2020-01-15 tracey * purpose with or without fee is hereby granted, provided that the above
6 2c251c14 2020-01-15 tracey * copyright notice and this permission notice appear in all copies.
7 2c251c14 2020-01-15 tracey *
8 2c251c14 2020-01-15 tracey * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
9 2c251c14 2020-01-15 tracey * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
10 2c251c14 2020-01-15 tracey * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
11 2c251c14 2020-01-15 tracey * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
12 2c251c14 2020-01-15 tracey * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
13 2c251c14 2020-01-15 tracey * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
14 2c251c14 2020-01-15 tracey * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
15 2c251c14 2020-01-15 tracey */
16 2c251c14 2020-01-15 tracey
17 2c251c14 2020-01-15 tracey #ifndef GOTWEB_UI_H
18 2c251c14 2020-01-15 tracey #define GOTWEB_UI_H
19 2c251c14 2020-01-15 tracey
20 2c251c14 2020-01-15 tracey /* general html */
21 2c251c14 2020-01-15 tracey
22 2c251c14 2020-01-15 tracey char *head =
23 2c251c14 2020-01-15 tracey "<meta name='viewport' content='initial-scale=1.0," \
24 2c251c14 2020-01-15 tracey " user-scalable=no' />" \
25 2c251c14 2020-01-15 tracey "<meta charset='utf-8' />" \
26 2c251c14 2020-01-15 tracey "<meta name='msapplication-TileColor' content='#da532c' />" \
27 2c251c14 2020-01-15 tracey "<meta name='theme-color' content='#ffffff' />" \
28 2c251c14 2020-01-15 tracey "<link rel='apple-touch-icon' sizes='180x180'" \
29 2c251c14 2020-01-15 tracey " href='/apple-touch-icon.png' />" \
30 2c251c14 2020-01-15 tracey "<link rel='icon' type='image/png' sizes='32x32'" \
31 2c251c14 2020-01-15 tracey " href='/favicon-32x32.png' />" \
32 2c251c14 2020-01-15 tracey "<link rel='icon' type='image/png' sizes='16x16'" \
33 2c251c14 2020-01-15 tracey " href='/favicon-16x16.png' />" \
34 2c251c14 2020-01-15 tracey "<link rel='manifest' href='/site.webmanifest' />" \
35 2c251c14 2020-01-15 tracey "<link rel='mask-icon' href='/safari-pinned-tab.svg'" \
36 2c251c14 2020-01-15 tracey " color='#5bbad5' />" \
37 2c251c14 2020-01-15 tracey "<link rel='stylesheet' type='text/css' href='/gotweb.css' />";
38 2c251c14 2020-01-15 tracey
39 2c251c14 2020-01-15 tracey char *got_link =
40 2c251c14 2020-01-15 tracey "<div id='got_link'>" \
41 2c251c14 2020-01-15 tracey "<a href='%s' target='_sotd'><img src='/%s' alt='logo' /></a>" \
42 2c251c14 2020-01-15 tracey "</div>";
43 2c251c14 2020-01-15 tracey
44 2c251c14 2020-01-15 tracey char *site_link =
45 2c251c14 2020-01-15 tracey "<div id='site_link'>" \
46 2c251c14 2020-01-15 tracey "<a href='%s'>%s</a> %s %s" \
47 2c251c14 2020-01-15 tracey "</div>";
48 2c251c14 2020-01-15 tracey
49 2c251c14 2020-01-15 tracey char *search =
50 87f9ebf5 2020-01-15 tracey "<!--/* <div id='search'>" \
51 2c251c14 2020-01-15 tracey "<form method='POST'>" \
52 2c251c14 2020-01-15 tracey "<input type='search' id='got-search' name='got-search' size='15'" \
53 2c251c14 2020-01-15 tracey " maxlength='50' />" \
54 2c251c14 2020-01-15 tracey "<button>Search</button>" \
55 2c251c14 2020-01-15 tracey "</form>" \
56 87f9ebf5 2020-01-15 tracey "</div> */-->";
57 2c251c14 2020-01-15 tracey
58 2c251c14 2020-01-15 tracey char *np_wrapper_start =
59 2c251c14 2020-01-15 tracey "<div id='np_wrapper'>" \
60 2c251c14 2020-01-15 tracey "<div id='nav_prev'>";
61 2c251c14 2020-01-15 tracey
62 2c251c14 2020-01-15 tracey char *div_end =
63 2c251c14 2020-01-15 tracey "</div>";
64 2c251c14 2020-01-15 tracey
65 2c251c14 2020-01-15 tracey char *nav_next =
66 2c251c14 2020-01-15 tracey "<div id='nav_next'>" \
67 2c251c14 2020-01-15 tracey "<a href='?page=%d'>Next<a/>" \
68 2c251c14 2020-01-15 tracey "</div>";
69 2c251c14 2020-01-15 tracey
70 2c251c14 2020-01-15 tracey char *nav_prev =
71 2c251c14 2020-01-15 tracey "<a href='?page=%d'>Previous<a/>";
72 2c251c14 2020-01-15 tracey
73 46b9c89b 2020-01-15 tracey char *repo_owner =
74 46b9c89b 2020-01-15 tracey "<div id='repo_owner_title'>Owner: </div>" \
75 46b9c89b 2020-01-15 tracey "<div id='repo_owner'>%s</div>";
76 46b9c89b 2020-01-15 tracey
77 8d4d2453 2020-01-15 tracey char *heads_row =
78 8d4d2453 2020-01-15 tracey "<div id='heads_wrapper'>" \
79 8d4d2453 2020-01-15 tracey "<div id='heads_age'>%s</div>" \
80 8d4d2453 2020-01-15 tracey "<div id='head'>%s</div>" \
81 8d4d2453 2020-01-15 tracey "</div>" \
82 8d4d2453 2020-01-15 tracey "<div id='navs_wrapper'>" \
83 8d4d2453 2020-01-15 tracey "<div id='navs'>%s</div>" \
84 8d4d2453 2020-01-15 tracey "</div>" \
85 8d4d2453 2020-01-15 tracey "</div>" \
86 8d4d2453 2020-01-15 tracey "<div id='dotted_line'></div>";
87 8d4d2453 2020-01-15 tracey
88 8d4d2453 2020-01-15 tracey char *heads_navs =
89 87f9ebf5 2020-01-15 tracey "<a href='?path=%s&action=summary&headref=%s'>summary</a> | " \
90 f2f46662 2020-01-23 tracey "<a href='?path=%s&action=briefs&headref=%s'>commit briefs</a> | " \
91 f2f46662 2020-01-23 tracey "<a href='?path=%s&action=commits&headref=%s'>commits</a>";
92 8d4d2453 2020-01-15 tracey
93 f2f46662 2020-01-23 tracey /* headers */
94 8087c3c5 2020-01-15 tracey
95 f2f46662 2020-01-23 tracey char *header_commit_html =
96 f2f46662 2020-01-23 tracey "<div id='header_commit_title'>Commit:</div>" \
97 f2f46662 2020-01-23 tracey "<div id='header_commit'>%s %s</div>";
98 8087c3c5 2020-01-15 tracey
99 f2f46662 2020-01-23 tracey char *header_age_html =
100 f2f46662 2020-01-23 tracey "<div id='header_age_title'>Date:</div>" \
101 f2f46662 2020-01-23 tracey "<div id='header_age'>%s</div>";
102 ec46ccd7 2020-01-15 tracey
103 f2f46662 2020-01-23 tracey char *header_commit_msg_html =
104 f2f46662 2020-01-23 tracey "<div id='header_commit_msg_title'>Message:</div>" \
105 f2f46662 2020-01-23 tracey "<div id='header_commit_msg'>%s</div>";
106 4ceb8155 2020-01-15 tracey
107 2c251c14 2020-01-15 tracey /* index.tmpl */
108 2c251c14 2020-01-15 tracey
109 2c251c14 2020-01-15 tracey char *index_projects_header =
110 2c251c14 2020-01-15 tracey "<div id='index_header'>" \
111 2c251c14 2020-01-15 tracey "<div id='index_header_project'>Project</div>" \
112 2c251c14 2020-01-15 tracey "<div id='index_header_description'>Description</div>" \
113 2c251c14 2020-01-15 tracey "<div id='index_header_owner'>Owner</div>" \
114 2c251c14 2020-01-15 tracey "<div id='index_header_age'>Last Change</div>" \
115 2c251c14 2020-01-15 tracey "</div>";
116 2c251c14 2020-01-15 tracey
117 2c251c14 2020-01-15 tracey char *index_projects =
118 2c251c14 2020-01-15 tracey "<div id='index_wrapper'>" \
119 2c251c14 2020-01-15 tracey "<div id='index_project'>" \
120 2c251c14 2020-01-15 tracey "<a href='?path=%s&action=summary'>%s</a>" \
121 2c251c14 2020-01-15 tracey "</div>" \
122 2c251c14 2020-01-15 tracey "<div id='index_project_description'>%s</div>" \
123 2c251c14 2020-01-15 tracey "<div id='index_project_owner'>%s</div>" \
124 2c251c14 2020-01-15 tracey "<div id='index_project_age'>%s</div>" \
125 2c251c14 2020-01-15 tracey "<div id='navs_wrapper'>" \
126 8d4d2453 2020-01-15 tracey "<div id='navs'>%s</div>" \
127 2c251c14 2020-01-15 tracey "</div>" \
128 bce5dac1 2020-01-28 stsp "</div>" \
129 bce5dac1 2020-01-28 stsp "<div id='dotted_line'></div>";
130 bce5dac1 2020-01-28 stsp
131 bce5dac1 2020-01-28 stsp char *index_projects_empty =
132 bce5dac1 2020-01-28 stsp "<div id='index_wrapper'>" \
133 bce5dac1 2020-01-28 stsp "No repositories found in %s" \
134 2c251c14 2020-01-15 tracey "</div>" \
135 2c251c14 2020-01-15 tracey "<div id='dotted_line'></div>";
136 2c251c14 2020-01-15 tracey
137 2c251c14 2020-01-15 tracey char *index_navs =
138 2c251c14 2020-01-15 tracey "<a href='?path=%s&action=summary'>summary</a> | " \
139 f2f46662 2020-01-23 tracey "<a href='?path=%s&action=briefs'>commit briefs</a> | " \
140 f2f46662 2020-01-23 tracey "<a href='?path=%s&action=commits'>commits</a> | " \
141 2c251c14 2020-01-15 tracey "<a href='?path=%s&action=tree'>tree</a>";
142 2c251c14 2020-01-15 tracey
143 2c251c14 2020-01-15 tracey #endif /* GOTWEB_UI_H */