You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@jspwiki.apache.org by br...@apache.org on 2010/02/28 22:12:41 UTC
svn commit: r917294 [3/3] - in /incubator/jspwiki/trunk: ./ etc/ini/
src/WebContent/WEB-INF/classes/templates/ src/WebContent/scripts/
src/WebContent/scripts/wysiwyg/ src/WebContent/scripts/wysiwyg/images/
src/WebContent/templates/default/ src/WebConte...
Modified: incubator/jspwiki/trunk/src/WebContent/templates/default/PageInfo.jsp
URL: http://svn.apache.org/viewvc/incubator/jspwiki/trunk/src/WebContent/templates/default/PageInfo.jsp?rev=917294&r1=917293&r2=917294&view=diff
==============================================================================
--- incubator/jspwiki/trunk/src/WebContent/templates/default/PageInfo.jsp (original)
+++ incubator/jspwiki/trunk/src/WebContent/templates/default/PageInfo.jsp Sun Feb 28 21:12:40 2010
@@ -1,4 +1,4 @@
-<%--
+<%--
JSPWiki - a JSP-based WikiWiki clone.
Licensed to the Apache Software Foundation (ASF) under one
@@ -16,7 +16,7 @@
"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
KIND, either express or implied. See the License for the
specific language governing permissions and limitations
- under the License.
+ under the License.
--%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/fmt" prefix="fmt" %>
<%@ taglib uri="http://jakarta.apache.org/jspwiki.tld" prefix="wiki" %>
@@ -47,7 +47,7 @@
<wiki:Param name="page" value="${wikiActionBean.page.name}" />
</wiki:Tab>
</wiki:Permission>
-
+
<%-- Attachments tab --%>
<wiki:Tab id="attachments" accesskey="a"
title="${wiki:attachmentsTitle(request.Locale, wikiActionBean.attachments)}">
@@ -66,10 +66,14 @@
<td colspan="2"><s:errors field="newAttachments" /></td>
</tr>
<tr>
+ <td><s:label for="attachfile" name="attach.add.selectfile" /></td>
+ <td><s:file name="newAttachments[0]" id="attachfile0" /></td>
+<%--
<td><s:label for="attachfile0" name="attach.add.selectfile" /></td>
<td><s:file name="newAttachments[0]" id="attachfile0" /><br/>
<s:file name="newAttachments[1]" id="attachfile1" /><br/>
<s:file name="newAttachments[2]" id="attachfile2" /></td>
+--%>
</tr>
<tr>
<td><s:label for="attachnote" name="attach.add.changenote" /></td>
@@ -92,7 +96,7 @@
<%-- Info tab --%>
<wiki:Tab id="info" titleKey="info.tab" accesskey="i">
-
+
<%-- Rename page --%>
<wiki:Permission permission="rename">
<s:form beanclass="org.apache.wiki.action.RenameActionBean" class="wikiform" id="renameform" method="post" acceptcharset="UTF-8" >
@@ -106,7 +110,7 @@
</p>
</s:form>
</wiki:Permission>
-
+
<%-- Delete page --%>
<wiki:Permission permission="delete">
<s:form beanclass="org.apache.wiki.action.DeleteActionBean" class="wikiform" id="deleteForm" method="post" acceptcharset="UTF-8">
@@ -116,7 +120,7 @@
</p>
</s:form>
</wiki:Permission>
-
+
<%-- Referring pages, previous versions --%>
<jsp:include page="${'tabs/PageInfoTab.jsp'}" />
Added: incubator/jspwiki/trunk/src/WebContent/templates/default/editors/wysiwyg.jsp
URL: http://svn.apache.org/viewvc/incubator/jspwiki/trunk/src/WebContent/templates/default/editors/wysiwyg.jsp?rev=917294&view=auto
==============================================================================
--- incubator/jspwiki/trunk/src/WebContent/templates/default/editors/wysiwyg.jsp (added)
+++ incubator/jspwiki/trunk/src/WebContent/templates/default/editors/wysiwyg.jsp Sun Feb 28 21:12:40 2010
@@ -0,0 +1,235 @@
+<%--
+ JSPWiki - a JSP-based WikiWiki clone.
+
+ Licensed to the Apache Software Foundation (ASF) under one
+ or more contributor license agreements. See the NOTICE file
+ distributed with this work for additional information
+ regarding copyright ownership. The ASF licenses this file
+ to you under the Apache License, Version 2.0 (the
+ "License"); you may not use this file except in compliance
+ with the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing,
+ software distributed under the License is distributed on an
+ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ KIND, either express or implied. See the License for the
+ specific language governing permissions and limitations
+ under the License.
+--%>
+<%@ page language="java" pageEncoding="UTF-8" %>
+<%@ taglib uri="http://jakarta.apache.org/jspwiki.tld" prefix="wiki" %>
+<%@ page import="java.util.Properties" %>
+<%@ page import="org.apache.wiki.*" %>
+<%@ page import="org.apache.wiki.action.WikiContextFactory" %>
+<%@ page import="org.apache.wiki.auth.*" %>
+<%@ page import="org.apache.wiki.auth.permissions.*" %>
+<%@ page import="org.apache.wiki.render.*" %>
+<%@ page import="org.apache.wiki.parser.JSPWikiMarkupParser" %>
+<%@ page import="org.apache.wiki.ui.*" %>
+<%@ page import="org.apache.wiki.util.TextUtil" %>
+<%@ page import="org.apache.wiki.filters.*" %>
+<%@ page import="org.apache.wiki.api.WikiPage" %>
+<%@ page import="org.apache.commons.lang.*" %>
+
+<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %>
+<%@ taglib uri="http://java.sun.com/jsp/jstl/fmt" prefix="fmt" %>
+<%@ taglib uri="http://stripes.sourceforge.net/stripes.tld" prefix="s" %>
+<%@ page import="org.apache.wiki.action.WikiContextFactory" %>
+<%--
+ This provides a WYSIWYG editor for JSPWiki, based on mooeditable.
+
+ FIXME:
+ first hack of the wysiwyg editor for jspwiki
+
+ Clientside js is based on "mooeditable".
+ See http://github.com/cheeaun/mooeditable, by Lim Chee Aun.
+
+--%>
+<%
+
+ WikiContext context = WikiContextFactory.findContext( pageContext );
+ WikiEngine engine = context.getEngine();
+ //c.setVariable( RenderingManager.WYSIWYG_EDITOR_MODE, Boolean.TRUE );
+ //c.setVariable( WikiEngine.PROP_RUNFILTERS, "false" );
+
+ WikiPage wikiPage = context.getPage();
+ //String originalCCLOption = (String)wikiPage.getAttribute(JSPWikiMarkupParser.PROP_CAMELCASELINKS );
+ //wikiPage.setAttribute( JSPWikiMarkupParser.PROP_CAMELCASELINKS, "false" );
+
+ //String usertext = EditorManager.getEditedText(pageContext);
+ String usertext = engine.getPureText( wikiPage );
+
+
+ //FIXME: seems to be broken
+ //probably the default layout is invoked before these lines are executed.
+ //Needs to be refactored (ref v2.x)
+ TemplateManager.addResourceRequest( context, "script", "scripts/wysiwyg/MooEditable.js" );
+ TemplateManager.addResourceRequest( context, "css", "scripts/wysiwyg/MooEditable.SilkTheme.css" );
+%>
+<script type="text/javascript" src="<wiki:Link format='url' jsp='scripts/wysiwyg/MooEditable.js' />"></script>
+
+<link rel="stylesheet" media="screen, projection, print" type="text/css" href="<wiki:Link format='url' jsp='scripts/wysiwyg/MooEditable.css' />" />
+
+<link rel="stylesheet" media="screen, projection, print" type="text/css" href="<wiki:Link format='url' jsp='scripts/wysiwyg/MooEditableSilkTheme.css' />" />
+
+<wiki:CheckRequestContext context="edit">
+<wiki:NoSuchPage> <%-- this is a new page, check if we're cloning --%>
+<%
+ String clone = request.getParameter( "clone" );
+ if( clone != null )
+ {
+ WikiPage p = engine.getPage( clone );
+ if( p != null )
+ {
+ AuthorizationManager mgr = engine.getAuthorizationManager();
+ PagePermission pp = new PagePermission( p, PagePermission.VIEW_ACTION );
+
+ try
+ {
+ if( mgr.checkPermission( context.getWikiSession(), pp ) )
+ {
+ usertext = engine.getPureText( p );
+ }
+ }
+ catch( Exception e ) { /*log.error( "Accessing clone page "+clone, e );*/ }
+ }
+ }
+%>
+</wiki:NoSuchPage>
+<%--
+ if( usertext == null )
+ {
+ usertext = engine.getPureText( context.getPage() );
+ }
+--%>
+</wiki:CheckRequestContext>
+<%
+ if( usertext == null ) usertext = "";
+
+ RenderingManager renderingManager = new RenderingManager();
+
+ // since the WikiProperties are shared, we'll want to make our own copy of it for modifying.
+ Properties props = new Properties();
+ props.putAll( engine.getWikiProperties() );
+ props.setProperty( "jspwiki.renderingManager.renderer", WysiwygEditingRenderer.class.getName() );
+ renderingManager.initialize( engine, props );
+
+ //String pageAsHtml = StringEscapeUtils.escapeJavaScript( renderingManager.getHTML( context, usertext ) );
+ String pageAsHtml = renderingManager.getHTML( context, usertext ) ;
+
+ // Disable the WYSIWYG_EDITOR_MODE and reset the other properties immediately
+ // after the XHTML has been rendered.
+ //context.setVariable( RenderingManager.WYSIWYG_EDITOR_MODE, Boolean.FALSE );
+ //context.setVariable( WikiEngine.PROP_RUNFILTERS, null );
+ //wikiPage.setAttribute( JSPWikiMarkupParser.PROP_CAMELCASELINKS, originalCCLOption );
+
+%>
+
+<div style="width:100%"> <%-- Required for IE6 on Windows --%>
+
+ <%-- Print any validation errors --%>
+ <s:errors />
+
+ <s:form beanclass="org.apache.wiki.action.EditActionBean"
+ class="wikiform"
+ id="editform"
+ method="post"
+ acceptcharset="UTF-8"
+ enctype="application/x-www-form-urlencoded" >
+
+ <%-- If any conflicts, print the conflicting text here --%>
+ <c:if test="${not empty wikiActionBean.conflictText}">
+ <p>
+ <s:label for="conflictText" />
+ <s:textarea name="conflictText" readonly="true" />
+ </p>
+ </c:if>
+
+
+ <%-- EditActionBean relies on these being found. So be careful, if you make changes. --%>
+ <p id="submitbuttons">
+ <s:hidden name="page" />
+ <s:hidden name="startTime" />
+ <s:hidden name="append" />
+ <c:set var="saveTitle" scope="page"><fmt:message key="editor.plain.save.title" /></c:set>
+ <wiki:CheckRequestContext context='edit'>
+ <s:submit name="save" accesskey="s" title="${saveTitle}" />
+ </wiki:CheckRequestContext>
+ <wiki:CheckRequestContext context='comment'>
+ <s:submit name="comment" accesskey="s" title="${saveTitle}" />
+ </wiki:CheckRequestContext>
+
+ <c:set var="previewTitle" scope="page"><fmt:message key="editor.plain.preview.title" /></c:set>
+ <s:submit name="preview" accesskey="v" title="${previewTitle}" />
+
+ <c:set var="cancelTitle" scope="page"><fmt:message key="editor.plain.cancel.title" /></c:set>
+ <s:submit name="cancel" accesskey="q" title="${cancelTitle}" />
+ </p>
+
+ <%-- Fields for changenote, renaming etc. --%>
+ <table>
+ <tr>
+ <td>
+ <s:label for="changenote" name="changenote" />
+ </td>
+ <td>
+ <s:text name="changenote" id="changenote" size="50" maxlength="80" />
+ </td>
+ </tr>
+
+ <wiki:CheckRequestContext context="comment">
+ <tr>
+ <td><s:label for="author" accesskey="n" name="author" /></td>
+ <td><s:text id="author" name="author" />
+ <s:checkbox id="remember" name="remember" />
+ <s:label for="remember" name="remember" />
+ </td>
+ </tr>
+ <tr>
+ <td><s:label for="link" accesskey="m" name="editor.plain.email" /></td>
+ <td><s:text id="link" name="link" size="24" /></td>
+ </tr>
+ </wiki:CheckRequestContext>
+
+ </table>
+
+ <%-- FIXME: just for testing...
+ <s:textarea id="htmlPageText" name="htmlPageText" class="editor" rows="10" cols="80" />
+ --%>
+ <%-- FIXME:
+ Remove all <a class="hashlink" >.</a> from the pageAsHtml !!
+ --%>
+ <textarea id="htmlPageText" name="htmlPageText" class="editor" rows="20" cols="80" ><%= pageAsHtml%></textarea>
+
+ <%-- FIXME: fake textarea to fool the action bean --%>
+ <div style="display:none">
+ <s:textarea id="wikiText" name="wikiText" class="editor" rows="20" cols="80" />
+ </div>
+
+
+ <%-- Spam detection fields --%>
+ <wiki:SpamProtect />
+
+</s:form>
+</div>
+
+<script type="text/javascript">
+//<![CDATA[
+
+//FIXME: move this to jspwiki-edit.js
+window.addEvent('load', function(){
+ $('htmlPageText').mooEditable();
+
+ // Post submit
+ /*
+ $('editform').addEvent('submit', function(e){
+ alert($('htmlPageText').value);
+ return true;
+ });
+ */
+});
+
+//]]>
+</script>
Added: incubator/jspwiki/trunk/src/WebContent/templates/default/images/delete.png
URL: http://svn.apache.org/viewvc/incubator/jspwiki/trunk/src/WebContent/templates/default/images/delete.png?rev=917294&view=auto
==============================================================================
Binary file - no diff available.
Propchange: incubator/jspwiki/trunk/src/WebContent/templates/default/images/delete.png
------------------------------------------------------------------------------
svn:executable = *
Propchange: incubator/jspwiki/trunk/src/WebContent/templates/default/images/delete.png
------------------------------------------------------------------------------
svn:mime-type = application/octet-stream
Modified: incubator/jspwiki/trunk/src/WebContent/templates/default/jspwiki.css
URL: http://svn.apache.org/viewvc/incubator/jspwiki/trunk/src/WebContent/templates/default/jspwiki.css?rev=917294&r1=917293&r2=917294&view=diff
==============================================================================
--- incubator/jspwiki/trunk/src/WebContent/templates/default/jspwiki.css (original)
+++ incubator/jspwiki/trunk/src/WebContent/templates/default/jspwiki.css Sun Feb 28 21:12:40 2010
@@ -66,6 +66,8 @@
- error (light pink) : #ffe0e0/.#ERROR#./
- diff inserted lines: #9f9/.#DIFFADD#./
- diff deleted lines: #f93/.#DIFFDEL#./
+ - slimbox overlay color: #000/.#SLIMBOX-OVERLAY#./
+ - slimbox main backgroun: #fff/.#SLIMBOX#./
History:
* April 07, based on BrushedTemplate, v2.6/v2.8
@@ -133,11 +135,11 @@
DOM structure:
(start code)
-<body class="view|edit|comment hidefav">
+<body class="view|edit|comment fullscreen">
<div id="wikibody" class="<empty>|fav-right">
<div id="header"> ................ </div>
<div id="content">
- <div id="main">
+ <div id="page">
<div id="actionsTop"> ........ </div>
... page content goes here ...
<div id="actionsBottom"> ..... </div>
@@ -150,7 +152,7 @@
*/
-/*DEBUG./
+/*DEBUG
#header,#content,#footer { border:1px solid red; }
#page,#favorites, .applicationlogo, .breadcrumbs, .userbox, .searchbox, .titlebox { border:1px solid lime; }
#previewcontent, #info, #pagecontent, #attach, #findcontent { border:1px solid pink; }
@@ -175,15 +177,18 @@
}
.fav-right #page {
float:left;
- xxmargin:0 10px 0 0; /*replace by split-handle ? */
+ _margin-left:auto;
_margin-right:-3px;/* ie hack - three pixel text jog */
}
-.hidefav #page, .hidefav .fav-right #page {
+body.fullscreen #page, body.fullscreen .fav-right #page {
width:auto;
float:none;
}
-.hidefav #favorites {
- width:20%;
+body.fullscreen #favorites {
+ xposition:relative;
+ xtop:0;
+ xbackground:white;
+ xz-index:5;
}
.fav-right #header .applicationlogo {
right:2em;
@@ -461,6 +466,9 @@
font:110% Monaco, "Courier New", Courier, monospace;
line-height:1.1;
border:1px solid #ddd/*#BORDER#*/;
+ -moz-border-radius:3px;
+ -webkit-border-radius:3px;
+ padding:0 0.25em;
}
pre {
clear:both;
@@ -624,8 +632,8 @@
clear:both;
margin:1em 0;
padding:1em 32px;
- -moz-border-radius:3px;
- -webkit-border-radius:3px;
+ -moz-border-radius:5px;
+ -webkit-border-radius:5px;
}
td .information, td .warning, td .error {
margin:0; /* make sure to fill the table cell with the background color*/
@@ -677,6 +685,20 @@
#upload {
float:left;
}
+ul.fileupload {
+ margin:0;
+ padding:0;
+}
+.fileupload li {
+ list-style:none;
+ padding:0.5em 0;
+}
+.fileupload .delete {
+ float:left;
+ display:block;
+ background-image:url("images/delete.png");
+ cursor:pointer;
+}
#progressbar {
float:left;
margin-left:1em;
@@ -703,6 +725,7 @@
/*
Style: AttachmentTab
Add attachment icons per type of attachement.
+ Ref. http://www.w3schools.com/media/media_mimeref.asp
DOM structure
> <div class="mime image-gif"> ... </div>
@@ -742,21 +765,19 @@
display:none;
}
a.external {
- padding-right:6px;
+ /*padding-right:6px;
background:transparent url(images/out.png) no-repeat center right;
-}
-/* FIXME
-a.external {
padding-right:18px;
- background:transparent url(images/extern.gif) no-repeat center right;
+ background:transparent url(images/extern.gif) no-repeat center right;*/
}
a.external[href^='mailto:'] {
padding-right:20px;
background:transparent url(images/email.png) no-repeat center right;
}
-a.createpage{
+/*
+a.createpage {
padding-right:20px;
- background:transparent url(images/pencil.png) no-repeat center right;
+ background:transparent url(images/pencil.png) no-repeat center right ;
}
*/
/* fixme
@@ -986,7 +1007,7 @@
}
.resize-bar {
background:#ddd/*#BORDER#*/ url(images/resize-horizontal.gif) top center;
- cursor:s-resize; /* css3 row-resize */
+ cursor:row-resize; /*ns-resize;*/ /* css3 row-resize */
font-size:1px;
height:6px;
line-height:6px;
@@ -1074,46 +1095,57 @@
*/
#favorites {
overflow:hidden; /*avoid overflow for wide content of leftmenu or leftmenufooter */
- padding-top:1.75em;
+ padding:1.75em 0.5em 0.5em 0.5em;
}
#page {
position:relative;
- padding:0 0 0 16px;
-}
-.fav-right #page {
- padding:0 16px 0 0;
+ padding:0 1em;
}
-#page .splitbar {
+#page a.splitbar {
position:absolute;
- width:4px;
- top:1.75em; /* 1.5line-height + ?0.25 */
- left:12px;
- bottom:2em; /* 1.5line-height + 0.5margin-bottom */
- background:#f9f9f9/*#COMMENT#*/;
- xxborder-top:1px solid #f9f9f9/*#COMMENT#*/;
- cursor:pointer;
+ width:1em;
+ top:1.75em; /* tabmenu height = 1.5line-height + ?0.25 */
+ bottom:1.75em; /* page-bottom height = 1.5line-height + 0.5margin-bottom */
+ left:0;
+ cursor:w-resize; /*col-resize*/
+ z-index:5;
+}
+.fullscreen #page .splitbar {
+ cursor:e-resize;
}
.fav-right #page .splitbar {
left:auto;
- right:12px;
+ right:0;
+ cursor:e-resize;
+}
+.fav-right .fullscreen #page .splitbar {
+ cursor:w-resize;
}
-#page .splitbar.hover {
- background:#eee;
+/* if needed, overwrite standard :hover treatment
+a.splitbar:hover{
+ background-color:#adf4ff;
}
-#splitPointer, .hidefav .fav-right #splitPointer {
+*/
+
+/*
+FIXME: can be removed, when cursor:x-resize is supported by the browser
+ Check IE7/IE6
+
+#splitPointer, .fullscreen .fav-right #splitPointer {
position:absolute;
- width:4px;
- height:12px;
+ width:5px;
+ height:#1px;
background:url(images/arrleft.gif) top left no-repeat;
- margin-top:-16px;
+ margin-top:-5px;
z-index:5;
}
-.hidefav #splitPointer, .fav-right #splitPointer {
+.fullscreen #splitPointer, .fav-right #splitPointer {
background-image:url(images/arrright.gif);
-}
+*/
+
.wikiversion, .rssfeed {
font-size:90%;
padding:0.25em;
@@ -1398,8 +1430,9 @@
#hiddenmorepopup {
display:none;
- border:1px solid #ddd/*#BORDER#*/;
+ xborder:1px solid #ddd/*#BORDER#*/;
}
+/* replace by .more class ??*/
#hiddenmorepopup ul {
list-style:none;
margin:0;
@@ -1471,8 +1504,8 @@
so the majority of visible styles are applied to two inner {{span}}.
DOM structure
-> <a class=".btn"><span><span>...</span></span></a>
-> <button class=".btn"><span><span>...</span></span></button>
+> <a class="btn"><span><span>...</span></span></a>
+> <button class="btn"><span><span>...</span></span></button>
Credit:
http://stopdesign.com/eg/buttons/3.0/code.html
@@ -1612,10 +1645,9 @@
*/
.spin {
- background:url(images/spin.gif) no-repeat;
+ background:url(images/spin.gif) no-repeat center;
height:16px;
- text-indent:20px;
- xmargin:0 0.5em;
+ text-indent:20px; /* shift optional text inside spin element */
}
/*
@@ -2277,7 +2309,7 @@
color:blue;
font:bold small Monaco, "Courier New", Courier, monospace;
width:1.2em;
- height:1em;
+ line-height:1.2em;
}
.collapseOpen, .collapseClose {
cursor:pointer;
@@ -2333,183 +2365,171 @@
/*
Style: SLIMBOX
- SLIMBOX is the attachment viewer etc.
+ SLIMBOX is a modal viewer for images, video, wikipages
+ and external sites (iframe)
Credit:
- Todo
+ Inspired by Slimbox by Christophe Bleys.
+ (see http://www.digitalia.be/software/slimbox)
+ and the mediaboxAdvanced by John Einselen
+ (see http://iaian7.com/webcode/mediaboxAdvanced)
+
+DOM Structure:
+ DOM structure of the JSPWiki Slimbox viewer.
+ (start code)
+ <div id="lbOverlay"></div>
+ <div id="lbCenter" class="or spin">
+ <div id="lbImage">
+ <!-- img or iframe element is inserted here -->
+ </div>
+ </div>
+ <div id="lbBottomContainer">
+ <div id="lbBottom">
+ <a id="lbCloseLink"/>
+ <a id="lbNextLink"/>
+ <a id="lbPrevLink"/>
+ <div id="lbCaption">
+ <div id="lbNumber">
+ </div>
+ </div>
+ (end)
*/
-a.slimbox {
- font-weight:bold;
- font-size:1.3em;
- padding:0 0.25em;
+.slimboxbtn {
+ padding:0 0.5em;
color:transparent;
- background: url(images/slimbox.gif) no-repeat center;
-}
-a.slimbox:visited, a.slimbox:active, a.slimbox:link {
- text-decoration:none;
- border:none;
-}
-a.slimbox:hover {
- background-color:#ddd/*#HOVER#*/;
+ background: transparent url(images/slimbox.gif) no-repeat center;
}
-
#lbOverlay {
- position:absolute;
- left:0;
+ position:fixed;
+ _position:absolute;
+ z-index:99;
top:0;
+ left:0;
width:100%;
- background-color:#000;
+ height:100%;/**/
+ background-color:#000;/*#SLIMBOX-OVERLAY#*/
cursor:pointer;
-
}
-#lbCenter, #lbBottomContainer {
+#lbCenter {
position:absolute;
- left:50%;
- overflow:hidden;
- font: 90% Verdana, Helvetica, sans-serif;
- color:#666;
- line-height:1.5;
- text-align:left;
+ z-index:99;/**/
+ padding:10px;
+ /*left:50%;*/
+ background-color:rgba(0,0,0,0.85);
+ padding-bottom:3em; /* placeholder for lbBottomContainer */
+ -moz-border-radius:10px;
+ -webkit-border-radius:10px;
+ -moz-box-shadow:0 10px 40px rgba(0,0,0,0.5);
+ -webkit-box-shadow:0 10px 40px rgba(0,0,0,0.5);
}
#lbBottomContainer {
- padding:0 12px;
-}
-#lbCenter {
- padding:12px 12px 0 12px;
-}
-#lbCenter a {
- outline:none;
-}
-.lbLoading {
- background:#fff url(images/spin.gif) no-repeat center;
+ position:absolute;
+ z-index:99;/**/
+ padding:1em;
+ /*left:50%;*/
+ overflow:hidden;_overflow:visible;_zoom:1;/*FIXME ?? inherit .line*/
}
#lbImage {
- border:10px solid #fff;
- border-top-width:1.4em;
- background-color:#fff;
- background-repeat:no-repeat;
+ /*position:absolute;*/
+ top:0;
+ left:0;
+ background-repeat:no-repeat; /* needed in case image is smaller the minimal window size */
background-position:center center;
- position:relative;
}
#lbBottom {
- border:10px solid #fff;
- border-top-style:none;
- background-color:#fff;
+ color: #999; /*#SLIMBOX-TEXT#*/
+ line-height: 1.5;
+ text-align: left;
}
-#lbBottom div {
+#lbBottom * {
+ padding:0.5em;
white-space:nowrap;
- overflow:hidden;
-}
-#lbCaption, #lbPrevLink, #lbNextLink {
- font-weight:bold;
-}
-#lbPrevLink {
- padding-right:1em;
+ /*overflow:hidden;*/
}
-#lbNextLink {
- padding-left:1em;
+#lbBottom div {
+ float:left;
}
-#lbCloseLink {
+#lbBottom a {
display:block;
- position:absolute;
- width:28px;
- height:28px;
- top:0;
- right:0;
- background:url(images/slimbox_close.png) no-repeat;
- z-index:10;
+ float:right;
+ color:inherit;
+ font-weight:bold;
+ outline:none;
+ text-decoration:none;
+ cursor:pointer;
}
-/* gif icons for ie */
-* html #lbCloseLink {
- background:url(images/slimbox_close.gif) 4px 12px no-repeat;
+#lbBottom a:hover {
+ color:white !important;
+ background-color:rgba(0,0,0,0.5);
+ -moz-border-radius:10px;
+ -webkit-border-radius:10px;
}
-* html #lbCloseLink:hover {
- background-image:url(images/slimbox_close_hover.gif);
+/*
+#lbNumber {
}
-
-#lbBottomContainer *:visited, #lbBottomContainer *:active, #lbBottomContainer *:link,
-#lbCenter *:visited, #lbCenter *:active, #lbCenter *:link {
- text-decoration:none;
- border-bottom:none;
+*/
+#lbCaption {
+ font-weight:bold;
}
+
/*
Style: Category
+
+DOM structure:
+(start code)
+ <span>
+ <a href=".." class="wikipage categoryLink">category-page></a>
+ <div class="categoryPopup">
+ <p><a href=".." class="wikipage categoryLink">category-page</a></p>
+ <ul>
+ <li><a>..</a></li>
+ </ul>
+ </div>
+ </span>
+(end)
*/
.categoryLink {
border-bottom:2px solid #545454;
text-decoration:none;
}
.categoryPopup {
- color:white;
z-index:100;
- font-size:90%;
- margin-top:2px;
position:absolute;
z-index:10;
background-color:rgba(0,0,0,0.7);
-moz-border-radius:10px;
- -webkit-border-radius:5px;
- -webkit-box-shadow:0 0 5px rgba(0, 0, 0, 0.5);
-}
-/* ie6 hack */
-* html .categoryPopup {
- width:240px;
-}
-/* ie7 hack */
-*:first-child+html .categoryPopup {
- width:240px;
+ -webkit-border-radius:10px;
+ -webkit-box-shadow:0 0 10px rgba(0, 0, 0, 0.5);
+ _width:240px; /* IEx: width of the tip.png background image */
}
-.categoryPopup a:link, .categoryPopup a:active,.categoryPopup a:visited {
+.categoryPopup a {
color:white;
text-decoration:none;
}
-.categoryTitle {
- padding:4px;
+.categoryPopup p {
+ margin:0;
+ padding:0.25em 10px;
font-weight:bold;
+ _background:url(images/tip.png) top left;
}
-/* ie6 hack */
-* html .categoryTitle {
- background:url(images/tip.png) top left;
-}
-/* ie7 hack */
-*:first-child+html .categoryTitle {
- background:url(images/tip.png) top left;
-}
-.categoryText {
- padding:4px 0;
-}
-/* ie6 hack */
-* html .categoryText {
- background:url(images/tip.png) bottom right;
-}
-/* ie7 hack */
-*:first-child+html .categoryText {
- background:url(images/tip.png) bottom right;
-}
-.categoryText ul {
+div.categoryPopup ul {
+ margin:0;
+ padding:0;
+ _background:url(images/tip.png) bottom right;
list-style:none;
- margin:0 !important;
- padding:0 !important;
}
-.categoryText li {
+div.categoryPopup li {
display:block;
- padding:0 8px;
+ padding:0.15em 10px;
}
.categoryPopup .hover {
background-color:rgba(0,0,0,0.5);
-moz-border-radius:10px;
- -webkit-border-radius:5px;
-}
-/* ie6 hack */
-* html .categoryPopup .hover {
- background-color:black;
-}
-/* ie7 hack */
-*:first-child+html .categoryPopup .hover {
- background-color:black;
+ -webkit-border-radius:10px;
+ _background-color:black;
}
@@ -2550,6 +2570,19 @@
.atv { color: #080; }
.dec { color: #606; }
+/* linenumbers */
+.prettylines {
+ float:left;
+ margin:0;
+ color:#aaa;
+ text-align:right;
+ background:none;
+ border-color:transparent;
+}
+.prettyprint {
+ clear:right;
+}
+
@media print {
.str {color: #060; }
.kwd {color: #006; font-weight: bold; }
@@ -2797,7 +2830,7 @@
overflow-x:visible;
}
/* use !important to overwrite css style on following specified blocks */
-.pagename, #header, #footer, #page {
+/*.pagename, #header, #footer, #xpage {
width:100% !important;
margin:0 !important;
padding:0 !important;
@@ -2806,6 +2839,7 @@
position:static !important;
overflow:visible !important;
}
+*/
.pagename {
font-size:250%;
margin-bottom:1.5em;
Modified: incubator/jspwiki/trunk/src/WebContent/templates/default/layout/DefaultLayout.jsp
URL: http://svn.apache.org/viewvc/incubator/jspwiki/trunk/src/WebContent/templates/default/layout/DefaultLayout.jsp?rev=917294&r1=917293&r2=917294&view=diff
==============================================================================
--- incubator/jspwiki/trunk/src/WebContent/templates/default/layout/DefaultLayout.jsp (original)
+++ incubator/jspwiki/trunk/src/WebContent/templates/default/layout/DefaultLayout.jsp Sun Feb 28 21:12:40 2010
@@ -51,7 +51,7 @@
2) DefaultLayout injects additional JSPs that are meant to be
customized. These include:
-
+
LocalHeader.jsp : A "local header" that can contain company logos
or other markup. Default=blank
@@ -60,7 +60,7 @@
<head>
<title>
<%--
-
+
Title: by default, use the "view page" title
--%>
<s:layout-component name="headTitle">
@@ -117,6 +117,7 @@
<script type="text/javascript" src="<wiki:Link format='url' jsp='scripts/prettify.js' />"></script>
<script type="text/javascript" src="<wiki:Link format='url' jsp='scripts/jspwiki-common.js' />"></script>
+ <script type="text/javascript" src="<wiki:Link format='url' jsp='scripts/jspwiki-slimbox.js' />"></script>
<script type="text/javascript" src="<wiki:Link format='url' jsp='scripts/jspwiki-commonstyles.js' />"></script>
<s:layout-component name="script" />
<%--
@@ -173,7 +174,7 @@
<div id="localHeader">
<jsp:include page="${templates['layout/LocalHeader.jsp']}" />
</div>
-
+
<%--
Header
--%>
Modified: incubator/jspwiki/trunk/src/WebContent/templates/default/tabs/AttachmentsTab.jsp
URL: http://svn.apache.org/viewvc/incubator/jspwiki/trunk/src/WebContent/templates/default/tabs/AttachmentsTab.jsp?rev=917294&r1=917293&r2=917294&view=diff
==============================================================================
--- incubator/jspwiki/trunk/src/WebContent/templates/default/tabs/AttachmentsTab.jsp (original)
+++ incubator/jspwiki/trunk/src/WebContent/templates/default/tabs/AttachmentsTab.jsp Sun Feb 28 21:12:40 2010
@@ -1,4 +1,4 @@
-<%--
+<%--
JSPWiki - a JSP-based WikiWiki clone.
Licensed to the Apache Software Foundation (ASF) under one
@@ -16,7 +16,7 @@
"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
KIND, either express or implied. See the License for the
specific language governing permissions and limitations
- under the License.
+ under the License.
--%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %>
<%@ taglib uri="http://java.sun.com/jsp/jstl/fmt" prefix="fmt" %>
@@ -45,7 +45,7 @@
<tr>
<%-- The 'title' attribute is used to sort empty cells --%>
<td title="${attachment.contentType}">
- <div class="${fn:replace(attachment.contentType,'/','-')}"> </div>
+ <div class="mime ${fn:replace(attachment.contentType,'/','-')}" />
</td>
<td title="${attachment.name}">
<s:link beanclass="org.apache.wiki.action.AttachmentActionBean" event="download">
@@ -63,6 +63,11 @@
${attachment.version}
</s:link>
</td>
+ <%-- FIXME
+ Needs to return date/time converted to msec, to allow numeric sorting
+ eg. attachment.lastModified.getTime() ...
+ A ISO8601DATE does not sort properly.
+ --%>
<td jspwiki:sortvalue="${wiki:iso8601date(attachment.lastModified)}">
<fmt:formatDate value="${attachment.lastModified}" pattern="${prefs.TimeFormat}" timeZone="${prefs.TimeZone}" />
</td>
Modified: incubator/jspwiki/trunk/src/java/org/apache/wiki/Release.java
URL: http://svn.apache.org/viewvc/incubator/jspwiki/trunk/src/java/org/apache/wiki/Release.java?rev=917294&r1=917293&r2=917294&view=diff
==============================================================================
--- incubator/jspwiki/trunk/src/java/org/apache/wiki/Release.java (original)
+++ incubator/jspwiki/trunk/src/java/org/apache/wiki/Release.java Sun Feb 28 21:12:40 2010
@@ -77,7 +77,7 @@
* <p>
* If the build identifier is empty, it is not added.
*/
- public static final String BUILD = "210";
+ public static final String BUILD = "211";
/**
* This is the generic version string you should use
Modified: incubator/jspwiki/trunk/src/java/org/apache/wiki/action/ViewActionBean.java
URL: http://svn.apache.org/viewvc/incubator/jspwiki/trunk/src/java/org/apache/wiki/action/ViewActionBean.java?rev=917294&r1=917293&r2=917294&view=diff
==============================================================================
--- incubator/jspwiki/trunk/src/java/org/apache/wiki/action/ViewActionBean.java (original)
+++ incubator/jspwiki/trunk/src/java/org/apache/wiki/action/ViewActionBean.java Sun Feb 28 21:12:40 2010
@@ -62,6 +62,7 @@
private static final Logger log = LoggerFactory.getLogger( ViewActionBean.class );
private String m_renameTo = null;
+ private String m_wikiPage = null;
private int m_version = WikiProvider.LATEST_VERSION;
@@ -84,24 +85,18 @@
public void stream( HttpServletResponse response ) throws IOException
{
WikiContext context = getContext();
- WikiPage page = getPage();
Writer out = response.getWriter();
- out.write( "<div class='categoryTitle'>");
- out.write( context.getViewURL( page.getName() ) );
- out.write( "</div>" );
- out.write( "<div class='categoryText'>");
PluginManager mgr = context.getEngine().getPluginManager();
String result;
try
{
- result = mgr.execute( context, "{ReferringPagesPlugin,page="+page.getName()+",max=20,before='*',after='\n'}" );
+ result = mgr.execute( context, "{ReferringPagesPlugin,page="+getPage().getName()+",max=20,before='*',after='\\n'}" );
}
catch (PluginException e)
{
result = e.getMessage();
}
out.write( result );
- out.write( "</div>" );
}
};
return r;