text/html as default web view
s-ol
3 years ago
116 | 116 |
index = @store\get_index path, depth
|
117 | 117 |
convert 'table', facet.type, index, fileder, facet.name
|
118 | 118 |
else
|
|
119 |
if facet.type == '?'
|
|
120 |
facet.type = 'text/html'
|
|
121 |
current = fileder
|
|
122 |
while current
|
|
123 |
if type = current\get '_web_view: type'
|
|
124 |
facet.type = type\match '^%s*(.-)%s*$'
|
|
125 |
break
|
|
126 |
|
|
127 |
if current.path == ''
|
|
128 |
break
|
|
129 |
|
|
130 |
path, _ = dir_base current.path
|
|
131 |
current = root\walk path
|
|
132 |
|
119 | 133 |
if facet.type == 'text/html+interactive'
|
120 | 134 |
@handle_interactive fileder, facet
|
121 | 135 |
else if base = facet.type\match '^DEBUG %-> (.*)'
|
|
176 | 190 |
facet = if facet == '' and (not type or type == '') and method ~= 'GET' and method ~= 'HEAD'
|
177 | 191 |
nil
|
178 | 192 |
else
|
179 | |
type or= 'text/html+interactive'
|
|
193 |
type or= '?'
|
180 | 194 |
type = type\match '%s*(.*)'
|
181 | 195 |
Key facet, type
|
182 | 196 |
|
4 | 4 |
div {
|
5 | 5 |
h3 link_to @
|
6 | 6 |
ul for child in *@children
|
|
7 |
continue if child\get 'hidden: bool'
|
7 | 8 |
desc = child\gett 'description: mmm/dom'
|
8 | 9 |
li (link_to child), ': ', desc
|
9 | 10 |
}
|