/[pub]/suikawiki/script/default/config.wp2
Suika

Contents of /suikawiki/script/default/config.wp2

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.4 - (show annotations) (download)
Fri Jan 16 08:06:42 2004 UTC (21 years, 6 months ago) by wakaba
Branch: MAIN
Changes since 1.3: +84 -7 lines
*** empty log message ***

1 #?SuikaWikiConfig/2.0
2
3 Plugin:
4 @Name: config
5 @Description:
6 @@@: Per-Wiki Configuration Pseudo-Plugin
7 @@lang:en
8 @License: %%GPL%%
9 @Date.RCS: $Date: 2003/12/26 07:05:09 $
10
11 ViewFragment:
12 @Name: navbar
13 @Order: 20
14 @Formatting:
15 %link-to-wikipage (
16 page => {Wiki//Page//Create},
17 label => {%link-to-it (
18 label => "%res(name=>GoToCreatePage);"p,
19 description => "%res(name=>GoToCreatePageLong);"p,
20 );},
21 );
22 %link-to-wikipage (
23 page => {IndexPage},
24 label => {%link-to-it (
25 label=>"%res(name=>GoToIndexPage);"p,
26 description=>"%res(name=>GoToIndexPageLong);"p,
27 );},
28 rel => index,
29 );
30 %link-to-wikipage (
31 page => {Wiki//Page//Search},
32 label => {%link-to-it (
33 label=>"%res(name=>GoToSearchPage);"p,
34 description=>"%res(name=>GoToSearchPageLong);"p,
35 );},
36 rel => search,
37 );
38 %link-to-wikipage (
39 page => {RecentChanges},
40 label => {%link-to-it (
41 label=>"%res(name=>GoToRecentChanges);"p,
42 description=>"%res(name=>GoToRecentChangesLong);"p,
43 );},
44 rel => news,
45 );
46
47 ViewFragment:
48 @Name: links
49 @Formatting:
50 %link-wiki(page=>"Wiki//News",rel=>news,
51 description=>"%res(name=>GoToWikiNewsLink);"p);
52 %link-wiki(page=>"Wiki//Help",rel=>help,
53 description=>"%res(name=>GoToWikiHelpLink);"p);
54 %link-wiki(page=>"Wiki//Page//License",rel=>copyright,
55 description=>"%res(name=>GoToWikiPageLicenseLink);"p);
56
57 %link-wiki(page=>"Wiki//Page//Search",rel=>search,
58 description=>"%res(name=>GoToSearchPageLink);"p);
59
60 ViewFragment:
61 @Name: ws--post-content
62 @Description:
63 @@@: After content body -- navigation bar
64 @@lang:en
65 @Order: 100
66 @Formatting:
67 %section (
68 id => children,
69 title => {%res(name=>{Children:Title});}p, heading,
70 content => {%page-list (
71 ns => {%page-name;}p, recursive => 0,
72 type => both,
73 template => {%res(name=>{Children:Item});}p,
74 );}p,
75 );
76 %section (
77 id => see-also,
78 title => {%res(name=>SeeAlso);}p, heading,
79 content => {%search-result;}p,
80 );
81 %section (
82 id => referer,
83 title => {%res(name=>Referer);}p, heading,
84 content => {%referer-list;}p,
85 );
86
87 ViewFragment:
88 @Name: ws--footer
89 @Formatting:
90 %link-to-wikipage (
91 page => {Wiki//Page//License},
92 label => {%link-to-it (
93 label => {%res (name => {Footer:License:SeeLicensePage});}p,
94 description => {%res (name => {Footer:License:SeeLicensePageLong});}p,
95 );},
96 );
97 %wpr--remove-button;
98
99 ViewFragment:
100 @Template[list]:wr--read-body
101 @Order: -10
102 @Description:
103 @@@: "Read" mode body -- Calender
104 @@lang:en
105 @Formatting:
106 %if-calender(month,true=>{
107 %format(context=>form_input,template=>{%calender;});
108 },false=>{
109 %if-calender(true=>{
110 %format(context=>form_input,template=>{%calender-months;});
111 });
112 });
113
114
115 ViewFragment:
116 @Template[list]:
117 we--edit-body
118 we--conflict-body
119 @Order: 1000
120 @Description:
121 @@@: WikiPage editing guide
122 @@lang:en
123 @Formatting:
124 %block (
125 id => edit-help,
126 content => {%read(page=>{Wiki//EditHelp});}p,
127 );
128
129
130
131
132 Resource:
133 @GoToWikiNewsLink:
134 @@@: News
135 @@lang:en
136 @GoToWikiHelpLink:
137 @@@: Help
138 @@lang:en
139 @GoToWikiPageLicenseLink:
140 @@@: License
141 @@lang:en
142
143 ViewFragment:
144 @Name: we--edit
145 @Order: -100
146 @Formatting:
147 %line(content=>{
148 %submit(accesskey=>S,label=>{%res(name=>{Edit:Save});}p);
149 [%wpp--next-anchor-index;]
150 }p);
151
152 ViewFragment:
153 @Name: we--edit
154 @Order: -10
155 @Formatting: %line(content=>{
156 ViewFragment:
157 @Name: we--edit
158 @Order: 10
159 @Formatting: }p);
160
161 ViewFragment:
162 @Name: we--edit
163 @Order: 150
164 @Formatting:
165 %line(content=>{
166
167 ViewFragment:
168 @Name: we--edit
169 @Order: 250
170 @Formatting:
171 %mode-after-edit-selection;
172
173 %we--update-lastmodified-datetime;
174
175 }p);
176
177 Resource:
178 @Footer:License:SeeLicensePage:
179 @@@: %char (ucs => {U+00A9});
180 @Footer:License:SeeLicensePageLong:
181 @@@: See license document
182 @@lang:en
183
184 ## --- Should be moved to proper plugin module ---
185
186 ## WikiPageRename
187 ViewFragment:
188 @Template[list]: we--adminedit-body
189 @Order:100
190 @Description:
191 @@@: Renaming WikiName section
192 @@lang:en
193 @Formatting:
194 %section (
195 title => {%res(name=>{Edit:Rename:Title});}p, heading,
196 content => {
197 %wp-rename-form (
198 content => {
199 %text (
200 id => to,
201 label => {%res(name=>{Edit:Rename:To=});}p,
202 size => 10,
203 default => {%page-name;}p,
204 );
205 %submit;
206 }p,
207 );
208 }p,
209 );
210
211 PluginConst:
212 @NS_XHTML1:
213 http://www.w3.org/1999/xhtml
214
215 FormattingRule:
216 @Name: debug-sw09-text-xml-text-diff
217 @Formatting:
218 my $page = $p->{page} ? [split m#//#, $p->{page}]
219 : $o->{wiki}->{var}->{page};
220 my $sw09 = SuikaWiki::Plugin->module_package ('SuikaWiki09');
221
222 ## Original Text Format
223 my $text1 = $o->{wiki}->{db}->get (content => $page);
224
225 ## Text format -> XML format
226 my $xml = new Message::Markup::XML::Node type => '#fragment';
227 $sw09->text_to_xml ($text1, {-parent => $xml});
228
229 ## XML format -> Text format
230 my $text2 = $sw09->xml_to_text ($xml, {});
231
232 $p->{-parent}->append_new_node (type => '#element',
233 namespace_uri => $NS_XHTML1,
234 local_name => 'pre')
235 ->append_text ($xml->outer_xml);
236 SuikaWiki::Plugin->module_package ('WikiEdit')
237 ->diff_in_html (\$text1, \$text2 =>
238 $p->{-parent}->append_new_node (type => '#element',
239 namespace_uri => $NS_XHTML1,
240 local_name => 'pre')
241 );
242
243 FormattingRule:
244 @Category[list]:view
245 @Name: debug-sw09-text-xml-text-diff
246 @Formatting:
247 my $page = $p->{page} ? [split m#//#, $p->{page}]
248 : $o->{wiki}->{var}->{page};
249 my $sw09 = SuikaWiki::Plugin->module_package ('SuikaWiki09');
250
251 ## Original Text Format
252 my $text1 = $o->{wiki}->{db}->get (content => $page);
253
254 ## Text format -> XML format
255 my $xml = new Message::Markup::XML::Node type => '#fragment';
256 $sw09->text_to_xml ($text1, {-parent => $xml});
257
258 ## XML format -> Text format
259 my $text2 = $sw09->xml_to_text ($xml, {});
260
261 $p->{-parent}->append_new_node (type => '#element',
262 namespace_uri => $NS_XHTML1,
263 local_name => 'pre')
264 ->append_text ($xml->outer_xml);
265 $p->{-parent}->append_new_node (type => '#element',
266 namespace_uri => $NS_XHTML1,
267 local_name => 'pre')
268 ->append_text ($text2);
269 SuikaWiki::Plugin->module_package ('WikiEdit')
270 ->diff_in_html (\$text1, \$text2 => $p->{-parent});
271
272
273 Was ViewFragment:
274 @Template[list]:wr--read-body
275 @Order: 120
276 @Formatting:
277 %section (
278 heading,
279 title => "Diff",
280 content => {
281 %debug-sw09-text-xml-text-diff;
282 }p,
283 );

admin@suikawiki.org
ViewVC Help
Powered by ViewVC 1.1.24