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

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

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.7 - (hide annotations) (download)
Sat Feb 14 11:04:00 2004 UTC (20 years, 9 months ago) by wakaba
Branch: MAIN
Changes since 1.6: +14 -49 lines
Calender and WikiPageRename form removed

1 wakaba 1.1 #?SuikaWikiConfig/2.0
2    
3     Plugin:
4     @Name: config
5     @Description:
6     @@@: Per-Wiki Configuration Pseudo-Plugin
7     @@lang:en
8 wakaba 1.7 @License: %%Perl%%
9     @Date.RCS:
10     $Date: 2004/02/08 09:02:24 $
11 wakaba 1.1
12     ViewFragment:
13     @Name: navbar
14     @Order: 20
15     @Formatting:
16 wakaba 1.3 %link-to-wikipage (
17     page => {Wiki//Page//Create},
18     label => {%link-to-it (
19     label => "%res(name=>GoToCreatePage);"p,
20     description => "%res(name=>GoToCreatePageLong);"p,
21     );},
22     );
23     %link-to-wikipage (
24     page => {Wiki//Page//Search},
25     label => {%link-to-it (
26 wakaba 1.1 label=>"%res(name=>GoToSearchPage);"p,
27 wakaba 1.3 description=>"%res(name=>GoToSearchPageLong);"p,
28     );},
29     rel => search,
30     );
31     %link-to-wikipage (
32 wakaba 1.5 page => {IndexPage},
33 wakaba 1.3 label => {%link-to-it (
34 wakaba 1.5 label=>"%res(name=>GoToIndexPage);"p,
35     description=>"%res(name=>GoToIndexPageLong);"p,
36 wakaba 1.3 );},
37 wakaba 1.5 rel => index,
38 wakaba 1.3 );
39 wakaba 1.1
40 wakaba 1.5
41 wakaba 1.1 ViewFragment:
42     @Name: links
43     @Formatting:
44 wakaba 1.3 %link-wiki(page=>"Wiki//News",rel=>news,
45     description=>"%res(name=>GoToWikiNewsLink);"p);
46     %link-wiki(page=>"Wiki//Help",rel=>help,
47     description=>"%res(name=>GoToWikiHelpLink);"p);
48     %link-wiki(page=>"Wiki//Page//License",rel=>copyright,
49     description=>"%res(name=>GoToWikiPageLicenseLink);"p);
50 wakaba 1.1
51 wakaba 1.3 %link-wiki(page=>"Wiki//Page//Search",rel=>search,
52 wakaba 1.5 description=>"%res(name=>GoToSearchPageLink);"p);
53 wakaba 1.7
54     %link-to-resource (
55     iw-name => {wiki-content-in-cvs-repository},
56     iw-parameter => {%page-name;}p,
57     rel => history,
58     class => wiki-cmd,
59     label => {%html-link (
60     description => {%res (name => ViewHistoryOfThisPageLink);}p,
61     );},
62     );
63 wakaba 1.2
64 wakaba 1.5 ## TODO: Resource, URI
65     %link-to-resource (
66     uri => {javascript:var%20WikiName=prompt('Please%20input%20the%20WikiName:','','Jump%20to%20SuikaWiki');if(WikiName)%7B_content.location.href='wiki%3F'+encodeURIComponent(WikiName)%7D},
67     rel => jump,
68     class => wiki-cmd,
69     label => {%html-link (
70     description => {%res(name=>JumpToLink);}p,
71     );},
72     );
73     %link-to-resource (
74     uri => {javascript:var%20WikiName=prompt('Please%20input%20the%20WikiName:','','Jump%20to%20SuikaWiki');if(WikiName)%7B_content.location.href='wiki%3Fmycmd=edit;mypage='+encodeURIComponent(WikiName)%7D},
75     rel => jump,
76     class => wiki-cmd,
77     label => {%html-link (
78     description => {%res(name=>JumpToEditLink);}p,
79     );},
80 wakaba 1.2 );
81    
82 wakaba 1.1 ViewFragment:
83     @Name: ws--footer
84     @Formatting:
85     %link-to-wikipage (
86     page => {Wiki//Page//License},
87 wakaba 1.3 label => {%link-to-it (
88     label => {%res (name => {Footer:License:SeeLicensePage});}p,
89     description => {%res (name => {Footer:License:SeeLicensePageLong});}p,
90     );},
91 wakaba 1.1 );
92 wakaba 1.2
93     ViewFragment:
94     @Template[list]:
95     we--edit-body
96     we--conflict-body
97     @Order: 1000
98     @Description:
99     @@@: WikiPage editing guide
100     @@lang:en
101     @Formatting:
102     %block (
103     id => edit-help,
104     content => {%read(page=>{Wiki//EditHelp});}p,
105     );
106    
107    
108    
109    
110 wakaba 1.1 Resource:
111     @GoToWikiNewsLink:
112     @@@: News
113     @@lang:en
114     @GoToWikiHelpLink:
115     @@@: Help
116     @@lang:en
117     @GoToWikiPageLicenseLink:
118     @@@: License
119     @@lang:en
120    
121     ViewFragment:
122     @Name: we--edit
123     @Order: -100
124     @Formatting:
125 wakaba 1.3 %line(content=>{
126 wakaba 1.1 %submit(accesskey=>S,label=>{%res(name=>{Edit:Save});}p);
127 wakaba 1.4 [%wpp--next-anchor-index;]
128     }p);
129 wakaba 1.1
130     ViewFragment:
131     @Name: we--edit
132     @Order: -10
133 wakaba 1.3 @Formatting: %line(content=>{
134 wakaba 1.1 ViewFragment:
135     @Name: we--edit
136     @Order: 10
137     @Formatting: }p);
138    
139     ViewFragment:
140     @Name: we--edit
141     @Order: 150
142     @Formatting:
143 wakaba 1.3 %line(content=>{
144 wakaba 1.1
145     ViewFragment:
146     @Name: we--edit
147     @Order: 250
148     @Formatting:
149 wakaba 1.6 %mode-after-edit-selection (
150     description => {%res (name => {Edit:SaveAnd:Description});}p,
151     );
152 wakaba 1.1
153 wakaba 1.4 %we--update-lastmodified-datetime;
154 wakaba 1.1 }p);
155    
156 wakaba 1.3 Resource:
157     @Footer:License:SeeLicensePage:
158     @@@: %char (ucs => {U+00A9});
159     @Footer:License:SeeLicensePageLong:
160     @@@: See license document
161     @@lang:en
162 wakaba 1.2
163 wakaba 1.4 PluginConst:
164     @NS_XHTML1:
165     http://www.w3.org/1999/xhtml
166    
167     FormattingRule:
168     @Name: debug-sw09-text-xml-text-diff
169     @Formatting:
170 wakaba 1.7 my $page = $o->{wiki}->name ($p->{page} || $o->{wiki}->{var}->{page});
171 wakaba 1.4 my $sw09 = SuikaWiki::Plugin->module_package ('SuikaWiki09');
172    
173     ## Original Text Format
174     my $text1 = $o->{wiki}->{db}->get (content => $page);
175    
176     ## Text format -> XML format
177     my $xml = new Message::Markup::XML::Node type => '#fragment';
178     $sw09->text_to_xml ($text1, {-parent => $xml});
179    
180     ## XML format -> Text format
181     my $text2 = $sw09->xml_to_text ($xml, {});
182    
183     $p->{-parent}->append_new_node (type => '#element',
184     namespace_uri => $NS_XHTML1,
185     local_name => 'pre')
186     ->append_text ($xml->outer_xml);
187     SuikaWiki::Plugin->module_package ('WikiEdit')
188     ->diff_in_html (\$text1, \$text2 =>
189     $p->{-parent}->append_new_node (type => '#element',
190     namespace_uri => $NS_XHTML1,
191     local_name => 'pre')
192     );
193    
194     FormattingRule:
195     @Category[list]:view
196     @Name: debug-sw09-text-xml-text-diff
197     @Formatting:
198     my $page = $p->{page} ? [split m#//#, $p->{page}]
199     : $o->{wiki}->{var}->{page};
200     my $sw09 = SuikaWiki::Plugin->module_package ('SuikaWiki09');
201    
202     ## Original Text Format
203     my $text1 = $o->{wiki}->{db}->get (content => $page);
204    
205     ## Text format -> XML format
206     my $xml = new Message::Markup::XML::Node type => '#fragment';
207     $sw09->text_to_xml ($text1, {-parent => $xml});
208    
209     ## XML format -> Text format
210     my $text2 = $sw09->xml_to_text ($xml, {});
211    
212     $p->{-parent}->append_new_node (type => '#element',
213     namespace_uri => $NS_XHTML1,
214     local_name => 'pre')
215     ->append_text ($xml->outer_xml);
216     $p->{-parent}->append_new_node (type => '#element',
217     namespace_uri => $NS_XHTML1,
218     local_name => 'pre')
219     ->append_text ($text2);
220     SuikaWiki::Plugin->module_package ('WikiEdit')
221     ->diff_in_html (\$text1, \$text2 => $p->{-parent});
222    
223    
224     Was ViewFragment:
225     @Template[list]:wr--read-body
226     @Order: 120
227     @Formatting:
228     %section (
229     heading,
230     title => "Diff",
231     content => {
232     %debug-sw09-text-xml-text-diff;
233     }p,
234     );

admin@suikawiki.org
ViewVC Help
Powered by ViewVC 1.1.24