From 23ec55cd52b5c2f32bbd9a33030fcae558bb1083 Mon Sep 17 00:00:00 2001 From: Eston Bond Date: Fri, 22 Oct 2010 17:03:47 -0700 Subject: [PATCH 01/37] Adding my scratch directory --- scratch/TODO | 5 ++++ scratch/page.html | 74 +++++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 79 insertions(+) create mode 100644 scratch/TODO create mode 100644 scratch/page.html diff --git a/scratch/TODO b/scratch/TODO new file mode 100644 index 00000000..742577df --- /dev/null +++ b/scratch/TODO @@ -0,0 +1,5 @@ +Create Common Layout +Create Basic CSS +Create View Page +Create History Page +Create Edit Page \ No newline at end of file diff --git a/scratch/page.html b/scratch/page.html new file mode 100644 index 00000000..841fccab --- /dev/null +++ b/scratch/page.html @@ -0,0 +1,74 @@ + + + + + Page Name — Site Name + + + +
+
+
+
+ +
+
+

+ Lorem ipsum dolor sit amet, consectetur adipiscing elit. Pellentesque congue ultrices metus, sit amet blandit nunc pretium ut. Donec ornare, nisl et suscipit tempor, dolor nunc ornare magna, a ullamcorper massa orci ut urna. Lorem ipsum dolor sit amet, consectetur adipiscing elit. Quisque purus erat, posuere aliquam sagittis sed, tincidunt eu magna. Mauris eu justo tellus. Suspendisse urna magna: +

+
    +
  1. Ordered list 1
  2. +
  3. Ordered list 2
  4. +
  5. Ordered list 3
  6. +
+

+ Tempus a consequat ut, accumsan vitae tellus. Nunc aliquet tempus lectus, non accumsan elit gravida faucibus. Proin in imperdiet ligula. Mauris nec posuere felis. Etiam tempus sollicitudin massa, vel vestibulum est lacinia sed. +

+

+ Nam iaculis volutpat dolor, laoreet blandit felis scelerisque sagittis. Suspendisse pretium lorem in nunc interdum vel malesuada ante pretium. Nam consectetur tortor scelerisque mi congue rhoncus. Curabitur vulputate nunc non urna condimentum in consequat elit lobortis. Etiam eu purus mi. Lorem ipsum dolor sit amet, consectetur adipiscing elit. Morbi sit amet arcu enim, id iaculis tortor. +

+
+

+ Quisque rhoncus, elit et eleifend laoreet, metus mauris placerat enim, euismod aliquet justo justo gravida augue. Mauris sit amet urna eu lacus luctus porta eu eget tortor. Suspendisse potenti. +

+
+

+ In urna dolor, pulvinar nec porttitor vitae, varius quis sem. Nulla at nisl nisl. In lobortis enim lacinia lectus semper fermentum id sit amet quam. Vestibulum ante ipsum primis in faucibus orci luctus et ultrices posuere cubilia Curae. +

+
+
+
+

+ Back to Page Name +

+

Directory Name

+ +
+
+ +
+ + + + + \ No newline at end of file From 3260c120c15c2cad7fad777cc6457a32d9229220 Mon Sep 17 00:00:00 2001 From: Eston Bond Date: Fri, 22 Oct 2010 17:24:16 -0700 Subject: [PATCH 02/37] Adding boilerplate files --- scratch/css/gollum.css | 0 scratch/css/page.css | 0 scratch/js/gollum.editor.js | 0 scratch/js/gollum.fx.js | 0 scratch/js/jquery.js | 166 ++++++++++++++++++++++++++++++++++++ scratch/page.html | 8 +- 6 files changed, 170 insertions(+), 4 deletions(-) create mode 100644 scratch/css/gollum.css create mode 100644 scratch/css/page.css create mode 100644 scratch/js/gollum.editor.js create mode 100644 scratch/js/gollum.fx.js create mode 100644 scratch/js/jquery.js diff --git a/scratch/css/gollum.css b/scratch/css/gollum.css new file mode 100644 index 00000000..e69de29b diff --git a/scratch/css/page.css b/scratch/css/page.css new file mode 100644 index 00000000..e69de29b diff --git a/scratch/js/gollum.editor.js b/scratch/js/gollum.editor.js new file mode 100644 index 00000000..e69de29b diff --git a/scratch/js/gollum.fx.js b/scratch/js/gollum.fx.js new file mode 100644 index 00000000..e69de29b diff --git a/scratch/js/jquery.js b/scratch/js/jquery.js new file mode 100644 index 00000000..c941a5f7 --- /dev/null +++ b/scratch/js/jquery.js @@ -0,0 +1,166 @@ +/*! + * jQuery JavaScript Library v1.4.3 + * http://jquery.com/ + * + * Copyright 2010, John Resig + * Dual licensed under the MIT or GPL Version 2 licenses. + * http://jquery.org/license + * + * Includes Sizzle.js + * http://sizzlejs.com/ + * Copyright 2010, The Dojo Foundation + * Released under the MIT, BSD, and GPL Licenses. + * + * Date: Thu Oct 14 23:10:06 2010 -0400 + */ +(function(E,A){function U(){return false}function ba(){return true}function ja(a,b,d){d[0].type=a;return c.event.handle.apply(b,d)}function Ga(a){var b,d,e=[],f=[],h,k,l,n,s,v,B,D;k=c.data(this,this.nodeType?"events":"__events__");if(typeof k==="function")k=k.events;if(!(a.liveFired===this||!k||!k.live||a.button&&a.type==="click")){if(a.namespace)D=RegExp("(^|\\.)"+a.namespace.split(".").join("\\.(?:.*\\.)?")+"(\\.|$)");a.liveFired=this;var H=k.live.slice(0);for(n=0;nd)break;a.currentTarget=f.elem;a.data=f.handleObj.data; +a.handleObj=f.handleObj;D=f.handleObj.origHandler.apply(f.elem,arguments);if(D===false||a.isPropagationStopped()){d=f.level;if(D===false)b=false}}return b}}function Y(a,b){return(a&&a!=="*"?a+".":"")+b.replace(Ha,"`").replace(Ia,"&")}function ka(a,b,d){if(c.isFunction(b))return c.grep(a,function(f,h){return!!b.call(f,h,f)===d});else if(b.nodeType)return c.grep(a,function(f){return f===b===d});else if(typeof b==="string"){var e=c.grep(a,function(f){return f.nodeType===1});if(Ja.test(b))return c.filter(b, +e,!d);else b=c.filter(b,e)}return c.grep(a,function(f){return c.inArray(f,b)>=0===d})}function la(a,b){var d=0;b.each(function(){if(this.nodeName===(a[d]&&a[d].nodeName)){var e=c.data(a[d++]),f=c.data(this,e);if(e=e&&e.events){delete f.handle;f.events={};for(var h in e)for(var k in e[h])c.event.add(this,h,e[h][k],e[h][k].data)}}})}function Ka(a,b){b.src?c.ajax({url:b.src,async:false,dataType:"script"}):c.globalEval(b.text||b.textContent||b.innerHTML||"");b.parentNode&&b.parentNode.removeChild(b)} +function ma(a,b,d){var e=b==="width"?a.offsetWidth:a.offsetHeight;if(d==="border")return e;c.each(b==="width"?La:Ma,function(){d||(e-=parseFloat(c.css(a,"padding"+this))||0);if(d==="margin")e+=parseFloat(c.css(a,"margin"+this))||0;else e-=parseFloat(c.css(a,"border"+this+"Width"))||0});return e}function ca(a,b,d,e){if(c.isArray(b)&&b.length)c.each(b,function(f,h){d||Na.test(a)?e(a,h):ca(a+"["+(typeof h==="object"||c.isArray(h)?f:"")+"]",h,d,e)});else if(!d&&b!=null&&typeof b==="object")c.isEmptyObject(b)? +e(a,""):c.each(b,function(f,h){ca(a+"["+f+"]",h,d,e)});else e(a,b)}function S(a,b){var d={};c.each(na.concat.apply([],na.slice(0,b)),function(){d[this]=a});return d}function oa(a){if(!da[a]){var b=c("<"+a+">").appendTo("body"),d=b.css("display");b.remove();if(d==="none"||d==="")d="block";da[a]=d}return da[a]}function ea(a){return c.isWindow(a)?a:a.nodeType===9?a.defaultView||a.parentWindow:false}var u=E.document,c=function(){function a(){if(!b.isReady){try{u.documentElement.doScroll("left")}catch(i){setTimeout(a, +1);return}b.ready()}}var b=function(i,r){return new b.fn.init(i,r)},d=E.jQuery,e=E.$,f,h=/^(?:[^<]*(<[\w\W]+>)[^>]*$|#([\w\-]+)$)/,k=/\S/,l=/^\s+/,n=/\s+$/,s=/\W/,v=/\d/,B=/^<(\w+)\s*\/?>(?:<\/\1>)?$/,D=/^[\],:{}\s]*$/,H=/\\(?:["\\\/bfnrt]|u[0-9a-fA-F]{4})/g,w=/"[^"\\\n\r]*"|true|false|null|-?\d+(?:\.\d*)?(?:[eE][+\-]?\d+)?/g,G=/(?:^|:|,)(?:\s*\[)+/g,M=/(webkit)[ \/]([\w.]+)/,g=/(opera)(?:.*version)?[ \/]([\w.]+)/,j=/(msie) ([\w.]+)/,o=/(mozilla)(?:.*? rv:([\w.]+))?/,m=navigator.userAgent,p=false, +q=[],t,x=Object.prototype.toString,C=Object.prototype.hasOwnProperty,P=Array.prototype.push,N=Array.prototype.slice,R=String.prototype.trim,Q=Array.prototype.indexOf,L={};b.fn=b.prototype={init:function(i,r){var y,z,F;if(!i)return this;if(i.nodeType){this.context=this[0]=i;this.length=1;return this}if(i==="body"&&!r&&u.body){this.context=u;this[0]=u.body;this.selector="body";this.length=1;return this}if(typeof i==="string")if((y=h.exec(i))&&(y[1]||!r))if(y[1]){F=r?r.ownerDocument||r:u;if(z=B.exec(i))if(b.isPlainObject(r)){i= +[u.createElement(z[1])];b.fn.attr.call(i,r,true)}else i=[F.createElement(z[1])];else{z=b.buildFragment([y[1]],[F]);i=(z.cacheable?z.fragment.cloneNode(true):z.fragment).childNodes}return b.merge(this,i)}else{if((z=u.getElementById(y[2]))&&z.parentNode){if(z.id!==y[2])return f.find(i);this.length=1;this[0]=z}this.context=u;this.selector=i;return this}else if(!r&&!s.test(i)){this.selector=i;this.context=u;i=u.getElementsByTagName(i);return b.merge(this,i)}else return!r||r.jquery?(r||f).find(i):b(r).find(i); +else if(b.isFunction(i))return f.ready(i);if(i.selector!==A){this.selector=i.selector;this.context=i.context}return b.makeArray(i,this)},selector:"",jquery:"1.4.3",length:0,size:function(){return this.length},toArray:function(){return N.call(this,0)},get:function(i){return i==null?this.toArray():i<0?this.slice(i)[0]:this[i]},pushStack:function(i,r,y){var z=b();b.isArray(i)?P.apply(z,i):b.merge(z,i);z.prevObject=this;z.context=this.context;if(r==="find")z.selector=this.selector+(this.selector?" ": +"")+y;else if(r)z.selector=this.selector+"."+r+"("+y+")";return z},each:function(i,r){return b.each(this,i,r)},ready:function(i){b.bindReady();if(b.isReady)i.call(u,b);else q&&q.push(i);return this},eq:function(i){return i===-1?this.slice(i):this.slice(i,+i+1)},first:function(){return this.eq(0)},last:function(){return this.eq(-1)},slice:function(){return this.pushStack(N.apply(this,arguments),"slice",N.call(arguments).join(","))},map:function(i){return this.pushStack(b.map(this,function(r,y){return i.call(r, +y,r)}))},end:function(){return this.prevObject||b(null)},push:P,sort:[].sort,splice:[].splice};b.fn.init.prototype=b.fn;b.extend=b.fn.extend=function(){var i=arguments[0]||{},r=1,y=arguments.length,z=false,F,I,K,J,fa;if(typeof i==="boolean"){z=i;i=arguments[1]||{};r=2}if(typeof i!=="object"&&!b.isFunction(i))i={};if(y===r){i=this;--r}for(;r0)){if(q){for(var r=0;i=q[r++];)i.call(u,b);q=null}b.fn.triggerHandler&&b(u).triggerHandler("ready")}}},bindReady:function(){if(!p){p=true;if(u.readyState==="complete")return setTimeout(b.ready, +1);if(u.addEventListener){u.addEventListener("DOMContentLoaded",t,false);E.addEventListener("load",b.ready,false)}else if(u.attachEvent){u.attachEvent("onreadystatechange",t);E.attachEvent("onload",b.ready);var i=false;try{i=E.frameElement==null}catch(r){}u.documentElement.doScroll&&i&&a()}}},isFunction:function(i){return b.type(i)==="function"},isArray:Array.isArray||function(i){return b.type(i)==="array"},isWindow:function(i){return i&&typeof i==="object"&&"setInterval"in i},isNaN:function(i){return i== +null||!v.test(i)||isNaN(i)},type:function(i){return i==null?String(i):L[x.call(i)]||"object"},isPlainObject:function(i){if(!i||b.type(i)!=="object"||i.nodeType||b.isWindow(i))return false;if(i.constructor&&!C.call(i,"constructor")&&!C.call(i.constructor.prototype,"isPrototypeOf"))return false;for(var r in i);return r===A||C.call(i,r)},isEmptyObject:function(i){for(var r in i)return false;return true},error:function(i){throw i;},parseJSON:function(i){if(typeof i!=="string"||!i)return null;i=b.trim(i); +if(D.test(i.replace(H,"@").replace(w,"]").replace(G,"")))return E.JSON&&E.JSON.parse?E.JSON.parse(i):(new Function("return "+i))();else b.error("Invalid JSON: "+i)},noop:function(){},globalEval:function(i){if(i&&k.test(i)){var r=u.getElementsByTagName("head")[0]||u.documentElement,y=u.createElement("script");y.type="text/javascript";if(b.support.scriptEval)y.appendChild(u.createTextNode(i));else y.text=i;r.insertBefore(y,r.firstChild);r.removeChild(y)}},nodeName:function(i,r){return i.nodeName&&i.nodeName.toUpperCase()=== +r.toUpperCase()},each:function(i,r,y){var z,F=0,I=i.length,K=I===A||b.isFunction(i);if(y)if(K)for(z in i){if(r.apply(i[z],y)===false)break}else for(;F";a=u.createDocumentFragment();a.appendChild(d.firstChild);c.support.checkClone=a.cloneNode(true).cloneNode(true).lastChild.checked;c(function(){var s=u.createElement("div"); +s.style.width=s.style.paddingLeft="1px";u.body.appendChild(s);c.boxModel=c.support.boxModel=s.offsetWidth===2;if("zoom"in s.style){s.style.display="inline";s.style.zoom=1;c.support.inlineBlockNeedsLayout=s.offsetWidth===2;s.style.display="";s.innerHTML="
";c.support.shrinkWrapBlocks=s.offsetWidth!==2}s.innerHTML="
t
";var v=s.getElementsByTagName("td");c.support.reliableHiddenOffsets=v[0].offsetHeight=== +0;v[0].style.display="";v[1].style.display="none";c.support.reliableHiddenOffsets=c.support.reliableHiddenOffsets&&v[0].offsetHeight===0;s.innerHTML="";u.body.removeChild(s).style.display="none"});a=function(s){var v=u.createElement("div");s="on"+s;var B=s in v;if(!B){v.setAttribute(s,"return;");B=typeof v[s]==="function"}return B};c.support.submitBubbles=a("submit");c.support.changeBubbles=a("change");a=b=d=f=h=null}})();c.props={"for":"htmlFor","class":"className",readonly:"readOnly",maxlength:"maxLength", +cellspacing:"cellSpacing",rowspan:"rowSpan",colspan:"colSpan",tabindex:"tabIndex",usemap:"useMap",frameborder:"frameBorder"};var pa={},Oa=/^(?:\{.*\}|\[.*\])$/;c.extend({cache:{},uuid:0,expando:"jQuery"+c.now(),noData:{embed:true,object:"clsid:D27CDB6E-AE6D-11cf-96B8-444553540000",applet:true},data:function(a,b,d){if(c.acceptData(a)){a=a==E?pa:a;var e=a.nodeType,f=e?a[c.expando]:null,h=c.cache;if(!(e&&!f&&typeof b==="string"&&d===A)){if(e)f||(a[c.expando]=f=++c.uuid);else h=a;if(typeof b==="object")if(e)h[f]= +c.extend(h[f],b);else c.extend(h,b);else if(e&&!h[f])h[f]={};a=e?h[f]:h;if(d!==A)a[b]=d;return typeof b==="string"?a[b]:a}}},removeData:function(a,b){if(c.acceptData(a)){a=a==E?pa:a;var d=a.nodeType,e=d?a[c.expando]:a,f=c.cache,h=d?f[e]:e;if(b){if(h){delete h[b];d&&c.isEmptyObject(h)&&c.removeData(a)}}else if(d&&c.support.deleteExpando)delete a[c.expando];else if(a.removeAttribute)a.removeAttribute(c.expando);else if(d)delete f[e];else for(var k in a)delete a[k]}},acceptData:function(a){if(a.nodeName){var b= +c.noData[a.nodeName.toLowerCase()];if(b)return!(b===true||a.getAttribute("classid")!==b)}return true}});c.fn.extend({data:function(a,b){if(typeof a==="undefined")return this.length?c.data(this[0]):null;else if(typeof a==="object")return this.each(function(){c.data(this,a)});var d=a.split(".");d[1]=d[1]?"."+d[1]:"";if(b===A){var e=this.triggerHandler("getData"+d[1]+"!",[d[0]]);if(e===A&&this.length){e=c.data(this[0],a);if(e===A&&this[0].nodeType===1){e=this[0].getAttribute("data-"+a);if(typeof e=== +"string")try{e=e==="true"?true:e==="false"?false:e==="null"?null:!c.isNaN(e)?parseFloat(e):Oa.test(e)?c.parseJSON(e):e}catch(f){}else e=A}}return e===A&&d[1]?this.data(d[0]):e}else return this.each(function(){var h=c(this),k=[d[0],b];h.triggerHandler("setData"+d[1]+"!",k);c.data(this,a,b);h.triggerHandler("changeData"+d[1]+"!",k)})},removeData:function(a){return this.each(function(){c.removeData(this,a)})}});c.extend({queue:function(a,b,d){if(a){b=(b||"fx")+"queue";var e=c.data(a,b);if(!d)return e|| +[];if(!e||c.isArray(d))e=c.data(a,b,c.makeArray(d));else e.push(d);return e}},dequeue:function(a,b){b=b||"fx";var d=c.queue(a,b),e=d.shift();if(e==="inprogress")e=d.shift();if(e){b==="fx"&&d.unshift("inprogress");e.call(a,function(){c.dequeue(a,b)})}}});c.fn.extend({queue:function(a,b){if(typeof a!=="string"){b=a;a="fx"}if(b===A)return c.queue(this[0],a);return this.each(function(){var d=c.queue(this,a,b);a==="fx"&&d[0]!=="inprogress"&&c.dequeue(this,a)})},dequeue:function(a){return this.each(function(){c.dequeue(this, +a)})},delay:function(a,b){a=c.fx?c.fx.speeds[a]||a:a;b=b||"fx";return this.queue(b,function(){var d=this;setTimeout(function(){c.dequeue(d,b)},a)})},clearQueue:function(a){return this.queue(a||"fx",[])}});var qa=/[\n\t]/g,ga=/\s+/,Pa=/\r/g,Qa=/^(?:href|src|style)$/,Ra=/^(?:button|input)$/i,Sa=/^(?:button|input|object|select|textarea)$/i,Ta=/^a(?:rea)?$/i,ra=/^(?:radio|checkbox)$/i;c.fn.extend({attr:function(a,b){return c.access(this,a,b,true,c.attr)},removeAttr:function(a){return this.each(function(){c.attr(this, +a,"");this.nodeType===1&&this.removeAttribute(a)})},addClass:function(a){if(c.isFunction(a))return this.each(function(s){var v=c(this);v.addClass(a.call(this,s,v.attr("class")))});if(a&&typeof a==="string")for(var b=(a||"").split(ga),d=0,e=this.length;d-1)return true;return false}, +val:function(a){if(!arguments.length){var b=this[0];if(b){if(c.nodeName(b,"option")){var d=b.attributes.value;return!d||d.specified?b.value:b.text}if(c.nodeName(b,"select")){var e=b.selectedIndex;d=[];var f=b.options;b=b.type==="select-one";if(e<0)return null;var h=b?e:0;for(e=b?e+1:f.length;h=0;else if(c.nodeName(this,"select")){var B=c.makeArray(v);c("option",this).each(function(){this.selected= +c.inArray(c(this).val(),B)>=0});if(!B.length)this.selectedIndex=-1}else this.value=v}})}});c.extend({attrFn:{val:true,css:true,html:true,text:true,data:true,width:true,height:true,offset:true},attr:function(a,b,d,e){if(!a||a.nodeType===3||a.nodeType===8)return A;if(e&&b in c.attrFn)return c(a)[b](d);e=a.nodeType!==1||!c.isXMLDoc(a);var f=d!==A;b=e&&c.props[b]||b;if(a.nodeType===1){var h=Qa.test(b);if((b in a||a[b]!==A)&&e&&!h){if(f){b==="type"&&Ra.test(a.nodeName)&&a.parentNode&&c.error("type property can't be changed"); +if(d===null)a.nodeType===1&&a.removeAttribute(b);else a[b]=d}if(c.nodeName(a,"form")&&a.getAttributeNode(b))return a.getAttributeNode(b).nodeValue;if(b==="tabIndex")return(b=a.getAttributeNode("tabIndex"))&&b.specified?b.value:Sa.test(a.nodeName)||Ta.test(a.nodeName)&&a.href?0:A;return a[b]}if(!c.support.style&&e&&b==="style"){if(f)a.style.cssText=""+d;return a.style.cssText}f&&a.setAttribute(b,""+d);if(!a.attributes[b]&&a.hasAttribute&&!a.hasAttribute(b))return A;a=!c.support.hrefNormalized&&e&& +h?a.getAttribute(b,2):a.getAttribute(b);return a===null?A:a}}});var X=/\.(.*)$/,ha=/^(?:textarea|input|select)$/i,Ha=/\./g,Ia=/ /g,Ua=/[^\w\s.|`]/g,Va=function(a){return a.replace(Ua,"\\$&")},sa={focusin:0,focusout:0};c.event={add:function(a,b,d,e){if(!(a.nodeType===3||a.nodeType===8)){if(c.isWindow(a)&&a!==E&&!a.frameElement)a=E;if(d===false)d=U;var f,h;if(d.handler){f=d;d=f.handler}if(!d.guid)d.guid=c.guid++;if(h=c.data(a)){var k=a.nodeType?"events":"__events__",l=h[k],n=h.handle;if(typeof l=== +"function"){n=l.handle;l=l.events}else if(!l){a.nodeType||(h[k]=h=function(){});h.events=l={}}if(!n)h.handle=n=function(){return typeof c!=="undefined"&&!c.event.triggered?c.event.handle.apply(n.elem,arguments):A};n.elem=a;b=b.split(" ");for(var s=0,v;k=b[s++];){h=f?c.extend({},f):{handler:d,data:e};if(k.indexOf(".")>-1){v=k.split(".");k=v.shift();h.namespace=v.slice(0).sort().join(".")}else{v=[];h.namespace=""}h.type=k;if(!h.guid)h.guid=d.guid;var B=l[k],D=c.event.special[k]||{};if(!B){B=l[k]=[]; +if(!D.setup||D.setup.call(a,e,v,n)===false)if(a.addEventListener)a.addEventListener(k,n,false);else a.attachEvent&&a.attachEvent("on"+k,n)}if(D.add){D.add.call(a,h);if(!h.handler.guid)h.handler.guid=d.guid}B.push(h);c.event.global[k]=true}a=null}}},global:{},remove:function(a,b,d,e){if(!(a.nodeType===3||a.nodeType===8)){if(d===false)d=U;var f,h,k=0,l,n,s,v,B,D,H=a.nodeType?"events":"__events__",w=c.data(a),G=w&&w[H];if(w&&G){if(typeof G==="function"){w=G;G=G.events}if(b&&b.type){d=b.handler;b=b.type}if(!b|| +typeof b==="string"&&b.charAt(0)==="."){b=b||"";for(f in G)c.event.remove(a,f+b)}else{for(b=b.split(" ");f=b[k++];){v=f;l=f.indexOf(".")<0;n=[];if(!l){n=f.split(".");f=n.shift();s=RegExp("(^|\\.)"+c.map(n.slice(0).sort(),Va).join("\\.(?:.*\\.)?")+"(\\.|$)")}if(B=G[f])if(d){v=c.event.special[f]||{};for(h=e||0;h=0){a.type= +f=f.slice(0,-1);a.exclusive=true}if(!d){a.stopPropagation();c.event.global[f]&&c.each(c.cache,function(){this.events&&this.events[f]&&c.event.trigger(a,b,this.handle.elem)})}if(!d||d.nodeType===3||d.nodeType===8)return A;a.result=A;a.target=d;b=c.makeArray(b);b.unshift(a)}a.currentTarget=d;(e=d.nodeType?c.data(d,"handle"):(c.data(d,"__events__")||{}).handle)&&e.apply(d,b);e=d.parentNode||d.ownerDocument;try{if(!(d&&d.nodeName&&c.noData[d.nodeName.toLowerCase()]))if(d["on"+f]&&d["on"+f].apply(d,b)=== +false){a.result=false;a.preventDefault()}}catch(h){}if(!a.isPropagationStopped()&&e)c.event.trigger(a,b,e,true);else if(!a.isDefaultPrevented()){e=a.target;var k,l=f.replace(X,""),n=c.nodeName(e,"a")&&l==="click",s=c.event.special[l]||{};if((!s._default||s._default.call(d,a)===false)&&!n&&!(e&&e.nodeName&&c.noData[e.nodeName.toLowerCase()])){try{if(e[l]){if(k=e["on"+l])e["on"+l]=null;c.event.triggered=true;e[l]()}}catch(v){}if(k)e["on"+l]=k;c.event.triggered=false}}},handle:function(a){var b,d,e; +d=[];var f,h=c.makeArray(arguments);a=h[0]=c.event.fix(a||E.event);a.currentTarget=this;b=a.type.indexOf(".")<0&&!a.exclusive;if(!b){e=a.type.split(".");a.type=e.shift();d=e.slice(0).sort();e=RegExp("(^|\\.)"+d.join("\\.(?:.*\\.)?")+"(\\.|$)")}a.namespace=a.namespace||d.join(".");f=c.data(this,this.nodeType?"events":"__events__");if(typeof f==="function")f=f.events;d=(f||{})[a.type];if(f&&d){d=d.slice(0);f=0;for(var k=d.length;f-1?c.map(a.options,function(e){return e.selected}).join("-"):"";else if(a.nodeName.toLowerCase()==="select")d=a.selectedIndex;return d},Z=function(a,b){var d=a.target,e,f;if(!(!ha.test(d.nodeName)||d.readOnly)){e=c.data(d,"_change_data");f=va(d);if(a.type!=="focusout"||d.type!=="radio")c.data(d,"_change_data",f);if(!(e===A||f===e))if(e!=null||f){a.type="change";a.liveFired= +A;return c.event.trigger(a,b,d)}}};c.event.special.change={filters:{focusout:Z,beforedeactivate:Z,click:function(a){var b=a.target,d=b.type;if(d==="radio"||d==="checkbox"||b.nodeName.toLowerCase()==="select")return Z.call(this,a)},keydown:function(a){var b=a.target,d=b.type;if(a.keyCode===13&&b.nodeName.toLowerCase()!=="textarea"||a.keyCode===32&&(d==="checkbox"||d==="radio")||d==="select-multiple")return Z.call(this,a)},beforeactivate:function(a){a=a.target;c.data(a,"_change_data",va(a))}},setup:function(){if(this.type=== +"file")return false;for(var a in V)c.event.add(this,a+".specialChange",V[a]);return ha.test(this.nodeName)},teardown:function(){c.event.remove(this,".specialChange");return ha.test(this.nodeName)}};V=c.event.special.change.filters;V.focus=V.beforeactivate}u.addEventListener&&c.each({focus:"focusin",blur:"focusout"},function(a,b){function d(e){e=c.event.fix(e);e.type=b;return c.event.trigger(e,null,e.target)}c.event.special[b]={setup:function(){sa[b]++===0&&u.addEventListener(a,d,true)},teardown:function(){--sa[b]=== +0&&u.removeEventListener(a,d,true)}}});c.each(["bind","one"],function(a,b){c.fn[b]=function(d,e,f){if(typeof d==="object"){for(var h in d)this[b](h,e,d[h],f);return this}if(c.isFunction(e)||e===false){f=e;e=A}var k=b==="one"?c.proxy(f,function(n){c(this).unbind(n,k);return f.apply(this,arguments)}):f;if(d==="unload"&&b!=="one")this.one(d,e,f);else{h=0;for(var l=this.length;h0?this.bind(b,d,e):this.trigger(b)};if(c.attrFn)c.attrFn[b]=true});E.attachEvent&&!E.addEventListener&&c(E).bind("unload",function(){for(var a in c.cache)if(c.cache[a].handle)try{c.event.remove(c.cache[a].handle.elem)}catch(b){}}); +(function(){function a(g,j,o,m,p,q){p=0;for(var t=m.length;p0){C=x;break}}x=x[g]}m[p]=C}}}var d=/((?:\((?:\([^()]+\)|[^()]+)+\)|\[(?:\[[^\[\]]*\]|['"][^'"]*['"]|[^\[\]'"]+)+\]|\\.|[^ >+~,(\[\\]+)+|[>+~])(\s*,\s*)?((?:.|\r|\n)*)/g,e=0,f=Object.prototype.toString,h=false,k=true;[0,0].sort(function(){k=false;return 0});var l=function(g,j,o,m){o=o||[];var p=j=j||u;if(j.nodeType!==1&&j.nodeType!==9)return[];if(!g||typeof g!=="string")return o;var q=[],t,x,C,P,N=true,R=l.isXML(j),Q=g,L;do{d.exec("");if(t=d.exec(Q)){Q=t[3];q.push(t[1]);if(t[2]){P=t[3]; +break}}}while(t);if(q.length>1&&s.exec(g))if(q.length===2&&n.relative[q[0]])x=M(q[0]+q[1],j);else for(x=n.relative[q[0]]?[j]:l(q.shift(),j);q.length;){g=q.shift();if(n.relative[g])g+=q.shift();x=M(g,x)}else{if(!m&&q.length>1&&j.nodeType===9&&!R&&n.match.ID.test(q[0])&&!n.match.ID.test(q[q.length-1])){t=l.find(q.shift(),j,R);j=t.expr?l.filter(t.expr,t.set)[0]:t.set[0]}if(j){t=m?{expr:q.pop(),set:D(m)}:l.find(q.pop(),q.length===1&&(q[0]==="~"||q[0]==="+")&&j.parentNode?j.parentNode:j,R);x=t.expr?l.filter(t.expr, +t.set):t.set;if(q.length>0)C=D(x);else N=false;for(;q.length;){t=L=q.pop();if(n.relative[L])t=q.pop();else L="";if(t==null)t=j;n.relative[L](C,t,R)}}else C=[]}C||(C=x);C||l.error(L||g);if(f.call(C)==="[object Array]")if(N)if(j&&j.nodeType===1)for(g=0;C[g]!=null;g++){if(C[g]&&(C[g]===true||C[g].nodeType===1&&l.contains(j,C[g])))o.push(x[g])}else for(g=0;C[g]!=null;g++)C[g]&&C[g].nodeType===1&&o.push(x[g]);else o.push.apply(o,C);else D(C,o);if(P){l(P,p,o,m);l.uniqueSort(o)}return o};l.uniqueSort=function(g){if(w){h= +k;g.sort(w);if(h)for(var j=1;j0};l.find=function(g,j,o){var m;if(!g)return[];for(var p=0,q=n.order.length;p":function(g,j){var o=typeof j==="string",m,p=0,q=g.length;if(o&&!/\W/.test(j))for(j=j.toLowerCase();p=0))o||m.push(t);else if(o)j[q]=false;return false},ID:function(g){return g[1].replace(/\\/g,"")},TAG:function(g){return g[1].toLowerCase()},CHILD:function(g){if(g[1]==="nth"){var j=/(-?)(\d*)n((?:\+|-)?\d*)/.exec(g[2]==="even"&&"2n"||g[2]==="odd"&&"2n+1"||!/\D/.test(g[2])&&"0n+"+g[2]||g[2]);g[2]=j[1]+(j[2]||1)-0;g[3]=j[3]-0}g[0]=e++;return g},ATTR:function(g,j,o, +m,p,q){j=g[1].replace(/\\/g,"");if(!q&&n.attrMap[j])g[1]=n.attrMap[j];if(g[2]==="~=")g[4]=" "+g[4]+" ";return g},PSEUDO:function(g,j,o,m,p){if(g[1]==="not")if((d.exec(g[3])||"").length>1||/^\w/.test(g[3]))g[3]=l(g[3],null,null,j);else{g=l.filter(g[3],j,o,true^p);o||m.push.apply(m,g);return false}else if(n.match.POS.test(g[0])||n.match.CHILD.test(g[0]))return true;return g},POS:function(g){g.unshift(true);return g}},filters:{enabled:function(g){return g.disabled===false&&g.type!=="hidden"},disabled:function(g){return g.disabled=== +true},checked:function(g){return g.checked===true},selected:function(g){return g.selected===true},parent:function(g){return!!g.firstChild},empty:function(g){return!g.firstChild},has:function(g,j,o){return!!l(o[3],g).length},header:function(g){return/h\d/i.test(g.nodeName)},text:function(g){return"text"===g.type},radio:function(g){return"radio"===g.type},checkbox:function(g){return"checkbox"===g.type},file:function(g){return"file"===g.type},password:function(g){return"password"===g.type},submit:function(g){return"submit"=== +g.type},image:function(g){return"image"===g.type},reset:function(g){return"reset"===g.type},button:function(g){return"button"===g.type||g.nodeName.toLowerCase()==="button"},input:function(g){return/input|select|textarea|button/i.test(g.nodeName)}},setFilters:{first:function(g,j){return j===0},last:function(g,j,o,m){return j===m.length-1},even:function(g,j){return j%2===0},odd:function(g,j){return j%2===1},lt:function(g,j,o){return jo[3]-0},nth:function(g,j,o){return o[3]- +0===j},eq:function(g,j,o){return o[3]-0===j}},filter:{PSEUDO:function(g,j,o,m){var p=j[1],q=n.filters[p];if(q)return q(g,o,j,m);else if(p==="contains")return(g.textContent||g.innerText||l.getText([g])||"").indexOf(j[3])>=0;else if(p==="not"){j=j[3];o=0;for(m=j.length;o=0}},ID:function(g,j){return g.nodeType===1&&g.getAttribute("id")===j},TAG:function(g,j){return j==="*"&&g.nodeType===1||g.nodeName.toLowerCase()=== +j},CLASS:function(g,j){return(" "+(g.className||g.getAttribute("class"))+" ").indexOf(j)>-1},ATTR:function(g,j){var o=j[1];o=n.attrHandle[o]?n.attrHandle[o](g):g[o]!=null?g[o]:g.getAttribute(o);var m=o+"",p=j[2],q=j[4];return o==null?p==="!=":p==="="?m===q:p==="*="?m.indexOf(q)>=0:p==="~="?(" "+m+" ").indexOf(q)>=0:!q?m&&o!==false:p==="!="?m!==q:p==="^="?m.indexOf(q)===0:p==="$="?m.substr(m.length-q.length)===q:p==="|="?m===q||m.substr(0,q.length+1)===q+"-":false},POS:function(g,j,o,m){var p=n.setFilters[j[2]]; +if(p)return p(g,o,j,m)}}},s=n.match.POS,v=function(g,j){return"\\"+(j-0+1)},B;for(B in n.match){n.match[B]=RegExp(n.match[B].source+/(?![^\[]*\])(?![^\(]*\))/.source);n.leftMatch[B]=RegExp(/(^(?:.|\r|\n)*?)/.source+n.match[B].source.replace(/\\(\d+)/g,v))}var D=function(g,j){g=Array.prototype.slice.call(g,0);if(j){j.push.apply(j,g);return j}return g};try{Array.prototype.slice.call(u.documentElement.childNodes,0)}catch(H){D=function(g,j){var o=j||[],m=0;if(f.call(g)==="[object Array]")Array.prototype.push.apply(o, +g);else if(typeof g.length==="number")for(var p=g.length;m";var o=u.documentElement;o.insertBefore(g,o.firstChild);if(u.getElementById(j)){n.find.ID=function(m,p,q){if(typeof p.getElementById!=="undefined"&&!q)return(p=p.getElementById(m[1]))?p.id===m[1]||typeof p.getAttributeNode!=="undefined"&&p.getAttributeNode("id").nodeValue===m[1]?[p]:A:[]};n.filter.ID=function(m,p){var q=typeof m.getAttributeNode!=="undefined"&&m.getAttributeNode("id");return m.nodeType===1&&q&&q.nodeValue===p}}o.removeChild(g); +o=g=null})();(function(){var g=u.createElement("div");g.appendChild(u.createComment(""));if(g.getElementsByTagName("*").length>0)n.find.TAG=function(j,o){var m=o.getElementsByTagName(j[1]);if(j[1]==="*"){for(var p=[],q=0;m[q];q++)m[q].nodeType===1&&p.push(m[q]);m=p}return m};g.innerHTML="";if(g.firstChild&&typeof g.firstChild.getAttribute!=="undefined"&&g.firstChild.getAttribute("href")!=="#")n.attrHandle.href=function(j){return j.getAttribute("href",2)};g=null})();u.querySelectorAll&& +function(){var g=l,j=u.createElement("div");j.innerHTML="

";if(!(j.querySelectorAll&&j.querySelectorAll(".TEST").length===0)){l=function(m,p,q,t){p=p||u;if(!t&&!l.isXML(p))if(p.nodeType===9)try{return D(p.querySelectorAll(m),q)}catch(x){}else if(p.nodeType===1&&p.nodeName.toLowerCase()!=="object"){var C=p.id,P=p.id="__sizzle__";try{return D(p.querySelectorAll("#"+P+" "+m),q)}catch(N){}finally{if(C)p.id=C;else p.removeAttribute("id")}}return g(m,p,q,t)};for(var o in g)l[o]=g[o]; +j=null}}();(function(){var g=u.documentElement,j=g.matchesSelector||g.mozMatchesSelector||g.webkitMatchesSelector||g.msMatchesSelector,o=false;try{j.call(u.documentElement,":sizzle")}catch(m){o=true}if(j)l.matchesSelector=function(p,q){try{if(o||!n.match.PSEUDO.test(q))return j.call(p,q)}catch(t){}return l(q,null,null,[p]).length>0}})();(function(){var g=u.createElement("div");g.innerHTML="
";if(!(!g.getElementsByClassName||g.getElementsByClassName("e").length=== +0)){g.lastChild.className="e";if(g.getElementsByClassName("e").length!==1){n.order.splice(1,0,"CLASS");n.find.CLASS=function(j,o,m){if(typeof o.getElementsByClassName!=="undefined"&&!m)return o.getElementsByClassName(j[1])};g=null}}})();l.contains=u.documentElement.contains?function(g,j){return g!==j&&(g.contains?g.contains(j):true)}:function(g,j){return!!(g.compareDocumentPosition(j)&16)};l.isXML=function(g){return(g=(g?g.ownerDocument||g:0).documentElement)?g.nodeName!=="HTML":false};var M=function(g, +j){for(var o=[],m="",p,q=j.nodeType?[j]:j;p=n.match.PSEUDO.exec(g);){m+=p[0];g=g.replace(n.match.PSEUDO,"")}g=n.relative[g]?g+"*":g;p=0;for(var t=q.length;p0)for(var h=d;h0},closest:function(a, +b){var d=[],e,f,h=this[0];if(c.isArray(a)){var k={},l,n=1;if(h&&a.length){e=0;for(f=a.length;e-1:c(h).is(e))d.push({selector:l,elem:h,level:n})}h=h.parentNode;n++}}return d}k=$a.test(a)?c(a,b||this.context):null;e=0;for(f=this.length;e-1:c.find.matchesSelector(h,a)){d.push(h);break}else{h=h.parentNode;if(!h|| +!h.ownerDocument||h===b)break}d=d.length>1?c.unique(d):d;return this.pushStack(d,"closest",a)},index:function(a){if(!a||typeof a==="string")return c.inArray(this[0],a?c(a):this.parent().children());return c.inArray(a.jquery?a[0]:a,this)},add:function(a,b){var d=typeof a==="string"?c(a,b||this.context):c.makeArray(a),e=c.merge(this.get(),d);return this.pushStack(!d[0]||!d[0].parentNode||d[0].parentNode.nodeType===11||!e[0]||!e[0].parentNode||e[0].parentNode.nodeType===11?e:c.unique(e))},andSelf:function(){return this.add(this.prevObject)}}); +c.each({parent:function(a){return(a=a.parentNode)&&a.nodeType!==11?a:null},parents:function(a){return c.dir(a,"parentNode")},parentsUntil:function(a,b,d){return c.dir(a,"parentNode",d)},next:function(a){return c.nth(a,2,"nextSibling")},prev:function(a){return c.nth(a,2,"previousSibling")},nextAll:function(a){return c.dir(a,"nextSibling")},prevAll:function(a){return c.dir(a,"previousSibling")},nextUntil:function(a,b,d){return c.dir(a,"nextSibling",d)},prevUntil:function(a,b,d){return c.dir(a,"previousSibling", +d)},siblings:function(a){return c.sibling(a.parentNode.firstChild,a)},children:function(a){return c.sibling(a.firstChild)},contents:function(a){return c.nodeName(a,"iframe")?a.contentDocument||a.contentWindow.document:c.makeArray(a.childNodes)}},function(a,b){c.fn[a]=function(d,e){var f=c.map(this,b,d);Wa.test(a)||(e=d);if(e&&typeof e==="string")f=c.filter(e,f);f=this.length>1?c.unique(f):f;if((this.length>1||Ya.test(e))&&Xa.test(a))f=f.reverse();return this.pushStack(f,a,Za.call(arguments).join(","))}}); +c.extend({filter:function(a,b,d){if(d)a=":not("+a+")";return b.length===1?c.find.matchesSelector(b[0],a)?[b[0]]:[]:c.find.matches(a,b)},dir:function(a,b,d){var e=[];for(a=a[b];a&&a.nodeType!==9&&(d===A||a.nodeType!==1||!c(a).is(d));){a.nodeType===1&&e.push(a);a=a[b]}return e},nth:function(a,b,d){b=b||1;for(var e=0;a;a=a[d])if(a.nodeType===1&&++e===b)break;return a},sibling:function(a,b){for(var d=[];a;a=a.nextSibling)a.nodeType===1&&a!==b&&d.push(a);return d}});var xa=/ jQuery\d+="(?:\d+|null)"/g, +$=/^\s+/,ya=/<(?!area|br|col|embed|hr|img|input|link|meta|param)(([\w:]+)[^>]*)\/>/ig,za=/<([\w:]+)/,ab=/\s]+\/)>/g,O={option:[1,""],legend:[1,"
","
"],thead:[1,"","
"],tr:[2,"","
"],td:[3,"","
"],col:[2,"","
"], +area:[1,"",""],_default:[0,"",""]};O.optgroup=O.option;O.tbody=O.tfoot=O.colgroup=O.caption=O.thead;O.th=O.td;if(!c.support.htmlSerialize)O._default=[1,"div
","
"];c.fn.extend({text:function(a){if(c.isFunction(a))return this.each(function(b){var d=c(this);d.text(a.call(this,b,d.text()))});if(typeof a!=="object"&&a!==A)return this.empty().append((this[0]&&this[0].ownerDocument||u).createTextNode(a));return c.text(this)},wrapAll:function(a){if(c.isFunction(a))return this.each(function(d){c(this).wrapAll(a.call(this, +d))});if(this[0]){var b=c(a,this[0].ownerDocument).eq(0).clone(true);this[0].parentNode&&b.insertBefore(this[0]);b.map(function(){for(var d=this;d.firstChild&&d.firstChild.nodeType===1;)d=d.firstChild;return d}).append(this)}return this},wrapInner:function(a){if(c.isFunction(a))return this.each(function(b){c(this).wrapInner(a.call(this,b))});return this.each(function(){var b=c(this),d=b.contents();d.length?d.wrapAll(a):b.append(a)})},wrap:function(a){return this.each(function(){c(this).wrapAll(a)})}, +unwrap:function(){return this.parent().each(function(){c.nodeName(this,"body")||c(this).replaceWith(this.childNodes)}).end()},append:function(){return this.domManip(arguments,true,function(a){this.nodeType===1&&this.appendChild(a)})},prepend:function(){return this.domManip(arguments,true,function(a){this.nodeType===1&&this.insertBefore(a,this.firstChild)})},before:function(){if(this[0]&&this[0].parentNode)return this.domManip(arguments,false,function(b){this.parentNode.insertBefore(b,this)});else if(arguments.length){var a= +c(arguments[0]);a.push.apply(a,this.toArray());return this.pushStack(a,"before",arguments)}},after:function(){if(this[0]&&this[0].parentNode)return this.domManip(arguments,false,function(b){this.parentNode.insertBefore(b,this.nextSibling)});else if(arguments.length){var a=this.pushStack(this,"after",arguments);a.push.apply(a,c(arguments[0]).toArray());return a}},remove:function(a,b){for(var d=0,e;(e=this[d])!=null;d++)if(!a||c.filter(a,[e]).length){if(!b&&e.nodeType===1){c.cleanData(e.getElementsByTagName("*")); +c.cleanData([e])}e.parentNode&&e.parentNode.removeChild(e)}return this},empty:function(){for(var a=0,b;(b=this[a])!=null;a++)for(b.nodeType===1&&c.cleanData(b.getElementsByTagName("*"));b.firstChild;)b.removeChild(b.firstChild);return this},clone:function(a){var b=this.map(function(){if(!c.support.noCloneEvent&&!c.isXMLDoc(this)){var d=this.outerHTML,e=this.ownerDocument;if(!d){d=e.createElement("div");d.appendChild(this.cloneNode(true));d=d.innerHTML}return c.clean([d.replace(xa,"").replace(cb,'="$1">').replace($, +"")],e)[0]}else return this.cloneNode(true)});if(a===true){la(this,b);la(this.find("*"),b.find("*"))}return b},html:function(a){if(a===A)return this[0]&&this[0].nodeType===1?this[0].innerHTML.replace(xa,""):null;else if(typeof a==="string"&&!Aa.test(a)&&(c.support.leadingWhitespace||!$.test(a))&&!O[(za.exec(a)||["",""])[1].toLowerCase()]){a=a.replace(ya,"<$1>");try{for(var b=0,d=this.length;b0||e.cacheable||this.length>1?l.cloneNode(true):l)}k.length&&c.each(k,Ka)}return this}});c.buildFragment=function(a,b,d){var e,f,h;b=b&&b[0]?b[0].ownerDocument||b[0]:u;if(a.length===1&&typeof a[0]==="string"&&a[0].length<512&&b===u&&!Aa.test(a[0])&&(c.support.checkClone|| +!Ba.test(a[0]))){f=true;if(h=c.fragments[a[0]])if(h!==1)e=h}if(!e){e=b.createDocumentFragment();c.clean(a,b,e,d)}if(f)c.fragments[a[0]]=h?e:1;return{fragment:e,cacheable:f}};c.fragments={};c.each({appendTo:"append",prependTo:"prepend",insertBefore:"before",insertAfter:"after",replaceAll:"replaceWith"},function(a,b){c.fn[a]=function(d){var e=[];d=c(d);var f=this.length===1&&this[0].parentNode;if(f&&f.nodeType===11&&f.childNodes.length===1&&d.length===1){d[b](this[0]);return this}else{f=0;for(var h= +d.length;f0?this.clone(true):this).get();c(d[f])[b](k);e=e.concat(k)}return this.pushStack(e,a,d.selector)}}});c.extend({clean:function(a,b,d,e){b=b||u;if(typeof b.createElement==="undefined")b=b.ownerDocument||b[0]&&b[0].ownerDocument||u;for(var f=[],h=0,k;(k=a[h])!=null;h++){if(typeof k==="number")k+="";if(k){if(typeof k==="string"&&!bb.test(k))k=b.createTextNode(k);else if(typeof k==="string"){k=k.replace(ya,"<$1>");var l=(za.exec(k)||["",""])[1].toLowerCase(),n=O[l]||O._default, +s=n[0],v=b.createElement("div");for(v.innerHTML=n[1]+k+n[2];s--;)v=v.lastChild;if(!c.support.tbody){s=ab.test(k);l=l==="table"&&!s?v.firstChild&&v.firstChild.childNodes:n[1]===""&&!s?v.childNodes:[];for(n=l.length-1;n>=0;--n)c.nodeName(l[n],"tbody")&&!l[n].childNodes.length&&l[n].parentNode.removeChild(l[n])}!c.support.leadingWhitespace&&$.test(k)&&v.insertBefore(b.createTextNode($.exec(k)[0]),v.firstChild);k=v.childNodes}if(k.nodeType)f.push(k);else f=c.merge(f,k)}}if(d)for(h=0;f[h];h++)if(e&& +c.nodeName(f[h],"script")&&(!f[h].type||f[h].type.toLowerCase()==="text/javascript"))e.push(f[h].parentNode?f[h].parentNode.removeChild(f[h]):f[h]);else{f[h].nodeType===1&&f.splice.apply(f,[h+1,0].concat(c.makeArray(f[h].getElementsByTagName("script"))));d.appendChild(f[h])}return f},cleanData:function(a){for(var b,d,e=c.cache,f=c.event.special,h=c.support.deleteExpando,k=0,l;(l=a[k])!=null;k++)if(!(l.nodeName&&c.noData[l.nodeName.toLowerCase()]))if(d=l[c.expando]){if((b=e[d])&&b.events)for(var n in b.events)f[n]? +c.event.remove(l,n):c.removeEvent(l,n,b.handle);if(h)delete l[c.expando];else l.removeAttribute&&l.removeAttribute(c.expando);delete e[d]}}});var Ca=/alpha\([^)]*\)/i,db=/opacity=([^)]*)/,eb=/-([a-z])/ig,fb=/([A-Z])/g,Da=/^-?\d+(?:px)?$/i,gb=/^-?\d/,hb={position:"absolute",visibility:"hidden",display:"block"},La=["Left","Right"],Ma=["Top","Bottom"],W,ib=u.defaultView&&u.defaultView.getComputedStyle,jb=function(a,b){return b.toUpperCase()};c.fn.css=function(a,b){if(arguments.length===2&&b===A)return this; +return c.access(this,a,b,true,function(d,e,f){return f!==A?c.style(d,e,f):c.css(d,e)})};c.extend({cssHooks:{opacity:{get:function(a,b){if(b){var d=W(a,"opacity","opacity");return d===""?"1":d}else return a.style.opacity}}},cssNumber:{zIndex:true,fontWeight:true,opacity:true,zoom:true,lineHeight:true},cssProps:{"float":c.support.cssFloat?"cssFloat":"styleFloat"},style:function(a,b,d,e){if(!(!a||a.nodeType===3||a.nodeType===8||!a.style)){var f,h=c.camelCase(b),k=a.style,l=c.cssHooks[h];b=c.cssProps[h]|| +h;if(d!==A){if(!(typeof d==="number"&&isNaN(d)||d==null)){if(typeof d==="number"&&!c.cssNumber[h])d+="px";if(!l||!("set"in l)||(d=l.set(a,d))!==A)try{k[b]=d}catch(n){}}}else{if(l&&"get"in l&&(f=l.get(a,false,e))!==A)return f;return k[b]}}},css:function(a,b,d){var e,f=c.camelCase(b),h=c.cssHooks[f];b=c.cssProps[f]||f;if(h&&"get"in h&&(e=h.get(a,true,d))!==A)return e;else if(W)return W(a,b,f)},swap:function(a,b,d){var e={},f;for(f in b){e[f]=a.style[f];a.style[f]=b[f]}d.call(a);for(f in b)a.style[f]= +e[f]},camelCase:function(a){return a.replace(eb,jb)}});c.curCSS=c.css;c.each(["height","width"],function(a,b){c.cssHooks[b]={get:function(d,e,f){var h;if(e){if(d.offsetWidth!==0)h=ma(d,b,f);else c.swap(d,hb,function(){h=ma(d,b,f)});return h+"px"}},set:function(d,e){if(Da.test(e)){e=parseFloat(e);if(e>=0)return e+"px"}else return e}}});if(!c.support.opacity)c.cssHooks.opacity={get:function(a,b){return db.test((b&&a.currentStyle?a.currentStyle.filter:a.style.filter)||"")?parseFloat(RegExp.$1)/100+"": +b?"1":""},set:function(a,b){var d=a.style;d.zoom=1;var e=c.isNaN(b)?"":"alpha(opacity="+b*100+")",f=d.filter||"";d.filter=Ca.test(f)?f.replace(Ca,e):d.filter+" "+e}};if(ib)W=function(a,b,d){var e;d=d.replace(fb,"-$1").toLowerCase();if(!(b=a.ownerDocument.defaultView))return A;if(b=b.getComputedStyle(a,null)){e=b.getPropertyValue(d);if(e===""&&!c.contains(a.ownerDocument.documentElement,a))e=c.style(a,d)}return e};else if(u.documentElement.currentStyle)W=function(a,b){var d,e,f=a.currentStyle&&a.currentStyle[b], +h=a.style;if(!Da.test(f)&&gb.test(f)){d=h.left;e=a.runtimeStyle.left;a.runtimeStyle.left=a.currentStyle.left;h.left=b==="fontSize"?"1em":f||0;f=h.pixelLeft+"px";h.left=d;a.runtimeStyle.left=e}return f};if(c.expr&&c.expr.filters){c.expr.filters.hidden=function(a){var b=a.offsetHeight;return a.offsetWidth===0&&b===0||!c.support.reliableHiddenOffsets&&(a.style.display||c.css(a,"display"))==="none"};c.expr.filters.visible=function(a){return!c.expr.filters.hidden(a)}}var kb=c.now(),lb=/)<[^<]*)*<\/script>/gi, +mb=/^(?:select|textarea)/i,nb=/^(?:color|date|datetime|email|hidden|month|number|password|range|search|tel|text|time|url|week)$/i,ob=/^(?:GET|HEAD|DELETE)$/,Na=/\[\]$/,T=/\=\?(&|$)/,ia=/\?/,pb=/([?&])_=[^&]*/,qb=/^(\w+:)?\/\/([^\/?#]+)/,rb=/%20/g,sb=/#.*$/,Ea=c.fn.load;c.fn.extend({load:function(a,b,d){if(typeof a!=="string"&&Ea)return Ea.apply(this,arguments);else if(!this.length)return this;var e=a.indexOf(" ");if(e>=0){var f=a.slice(e,a.length);a=a.slice(0,e)}e="GET";if(b)if(c.isFunction(b)){d= +b;b=null}else if(typeof b==="object"){b=c.param(b,c.ajaxSettings.traditional);e="POST"}var h=this;c.ajax({url:a,type:e,dataType:"html",data:b,complete:function(k,l){if(l==="success"||l==="notmodified")h.html(f?c("
").append(k.responseText.replace(lb,"")).find(f):k.responseText);d&&h.each(d,[k.responseText,l,k])}});return this},serialize:function(){return c.param(this.serializeArray())},serializeArray:function(){return this.map(function(){return this.elements?c.makeArray(this.elements):this}).filter(function(){return this.name&& +!this.disabled&&(this.checked||mb.test(this.nodeName)||nb.test(this.type))}).map(function(a,b){var d=c(this).val();return d==null?null:c.isArray(d)?c.map(d,function(e){return{name:b.name,value:e}}):{name:b.name,value:d}}).get()}});c.each("ajaxStart ajaxStop ajaxComplete ajaxError ajaxSuccess ajaxSend".split(" "),function(a,b){c.fn[b]=function(d){return this.bind(b,d)}});c.extend({get:function(a,b,d,e){if(c.isFunction(b)){e=e||d;d=b;b=null}return c.ajax({type:"GET",url:a,data:b,success:d,dataType:e})}, +getScript:function(a,b){return c.get(a,null,b,"script")},getJSON:function(a,b,d){return c.get(a,b,d,"json")},post:function(a,b,d,e){if(c.isFunction(b)){e=e||d;d=b;b={}}return c.ajax({type:"POST",url:a,data:b,success:d,dataType:e})},ajaxSetup:function(a){c.extend(c.ajaxSettings,a)},ajaxSettings:{url:location.href,global:true,type:"GET",contentType:"application/x-www-form-urlencoded",processData:true,async:true,xhr:function(){return new E.XMLHttpRequest},accepts:{xml:"application/xml, text/xml",html:"text/html", +script:"text/javascript, application/javascript",json:"application/json, text/javascript",text:"text/plain",_default:"*/*"}},ajax:function(a){var b=c.extend(true,{},c.ajaxSettings,a),d,e,f,h=b.type.toUpperCase(),k=ob.test(h);b.url=b.url.replace(sb,"");b.context=a&&a.context!=null?a.context:b;if(b.data&&b.processData&&typeof b.data!=="string")b.data=c.param(b.data,b.traditional);if(b.dataType==="jsonp"){if(h==="GET")T.test(b.url)||(b.url+=(ia.test(b.url)?"&":"?")+(b.jsonp||"callback")+"=?");else if(!b.data|| +!T.test(b.data))b.data=(b.data?b.data+"&":"")+(b.jsonp||"callback")+"=?";b.dataType="json"}if(b.dataType==="json"&&(b.data&&T.test(b.data)||T.test(b.url))){d=b.jsonpCallback||"jsonp"+kb++;if(b.data)b.data=(b.data+"").replace(T,"="+d+"$1");b.url=b.url.replace(T,"="+d+"$1");b.dataType="script";var l=E[d];E[d]=function(m){f=m;c.handleSuccess(b,w,e,f);c.handleComplete(b,w,e,f);if(c.isFunction(l))l(m);else{E[d]=A;try{delete E[d]}catch(p){}}v&&v.removeChild(B)}}if(b.dataType==="script"&&b.cache===null)b.cache= +false;if(b.cache===false&&h==="GET"){var n=c.now(),s=b.url.replace(pb,"$1_="+n);b.url=s+(s===b.url?(ia.test(b.url)?"&":"?")+"_="+n:"")}if(b.data&&h==="GET")b.url+=(ia.test(b.url)?"&":"?")+b.data;b.global&&c.active++===0&&c.event.trigger("ajaxStart");n=(n=qb.exec(b.url))&&(n[1]&&n[1]!==location.protocol||n[2]!==location.host);if(b.dataType==="script"&&h==="GET"&&n){var v=u.getElementsByTagName("head")[0]||u.documentElement,B=u.createElement("script");if(b.scriptCharset)B.charset=b.scriptCharset;B.src= +b.url;if(!d){var D=false;B.onload=B.onreadystatechange=function(){if(!D&&(!this.readyState||this.readyState==="loaded"||this.readyState==="complete")){D=true;c.handleSuccess(b,w,e,f);c.handleComplete(b,w,e,f);B.onload=B.onreadystatechange=null;v&&B.parentNode&&v.removeChild(B)}}}v.insertBefore(B,v.firstChild);return A}var H=false,w=b.xhr();if(w){b.username?w.open(h,b.url,b.async,b.username,b.password):w.open(h,b.url,b.async);try{if(b.data!=null&&!k||a&&a.contentType)w.setRequestHeader("Content-Type", +b.contentType);if(b.ifModified){c.lastModified[b.url]&&w.setRequestHeader("If-Modified-Since",c.lastModified[b.url]);c.etag[b.url]&&w.setRequestHeader("If-None-Match",c.etag[b.url])}n||w.setRequestHeader("X-Requested-With","XMLHttpRequest");w.setRequestHeader("Accept",b.dataType&&b.accepts[b.dataType]?b.accepts[b.dataType]+", */*; q=0.01":b.accepts._default)}catch(G){}if(b.beforeSend&&b.beforeSend.call(b.context,w,b)===false){b.global&&c.active--===1&&c.event.trigger("ajaxStop");w.abort();return false}b.global&& +c.triggerGlobal(b,"ajaxSend",[w,b]);var M=w.onreadystatechange=function(m){if(!w||w.readyState===0||m==="abort"){H||c.handleComplete(b,w,e,f);H=true;if(w)w.onreadystatechange=c.noop}else if(!H&&w&&(w.readyState===4||m==="timeout")){H=true;w.onreadystatechange=c.noop;e=m==="timeout"?"timeout":!c.httpSuccess(w)?"error":b.ifModified&&c.httpNotModified(w,b.url)?"notmodified":"success";var p;if(e==="success")try{f=c.httpData(w,b.dataType,b)}catch(q){e="parsererror";p=q}if(e==="success"||e==="notmodified")d|| +c.handleSuccess(b,w,e,f);else c.handleError(b,w,e,p);d||c.handleComplete(b,w,e,f);m==="timeout"&&w.abort();if(b.async)w=null}};try{var g=w.abort;w.abort=function(){w&&g.call&&g.call(w);M("abort")}}catch(j){}b.async&&b.timeout>0&&setTimeout(function(){w&&!H&&M("timeout")},b.timeout);try{w.send(k||b.data==null?null:b.data)}catch(o){c.handleError(b,w,null,o);c.handleComplete(b,w,e,f)}b.async||M();return w}},param:function(a,b){var d=[],e=function(h,k){k=c.isFunction(k)?k():k;d[d.length]=encodeURIComponent(h)+ +"="+encodeURIComponent(k)};if(b===A)b=c.ajaxSettings.traditional;if(c.isArray(a)||a.jquery)c.each(a,function(){e(this.name,this.value)});else for(var f in a)ca(f,a[f],b,e);return d.join("&").replace(rb,"+")}});c.extend({active:0,lastModified:{},etag:{},handleError:function(a,b,d,e){a.error&&a.error.call(a.context,b,d,e);a.global&&c.triggerGlobal(a,"ajaxError",[b,a,e])},handleSuccess:function(a,b,d,e){a.success&&a.success.call(a.context,e,d,b);a.global&&c.triggerGlobal(a,"ajaxSuccess",[b,a])},handleComplete:function(a, +b,d){a.complete&&a.complete.call(a.context,b,d);a.global&&c.triggerGlobal(a,"ajaxComplete",[b,a]);a.global&&c.active--===1&&c.event.trigger("ajaxStop")},triggerGlobal:function(a,b,d){(a.context&&a.context.url==null?c(a.context):c.event).trigger(b,d)},httpSuccess:function(a){try{return!a.status&&location.protocol==="file:"||a.status>=200&&a.status<300||a.status===304||a.status===1223}catch(b){}return false},httpNotModified:function(a,b){var d=a.getResponseHeader("Last-Modified"),e=a.getResponseHeader("Etag"); +if(d)c.lastModified[b]=d;if(e)c.etag[b]=e;return a.status===304},httpData:function(a,b,d){var e=a.getResponseHeader("content-type")||"",f=b==="xml"||!b&&e.indexOf("xml")>=0;a=f?a.responseXML:a.responseText;f&&a.documentElement.nodeName==="parsererror"&&c.error("parsererror");if(d&&d.dataFilter)a=d.dataFilter(a,b);if(typeof a==="string")if(b==="json"||!b&&e.indexOf("json")>=0)a=c.parseJSON(a);else if(b==="script"||!b&&e.indexOf("javascript")>=0)c.globalEval(a);return a}});if(E.ActiveXObject)c.ajaxSettings.xhr= +function(){if(E.location.protocol!=="file:")try{return new E.XMLHttpRequest}catch(a){}try{return new E.ActiveXObject("Microsoft.XMLHTTP")}catch(b){}};c.support.ajax=!!c.ajaxSettings.xhr();var da={},tb=/^(?:toggle|show|hide)$/,ub=/^([+\-]=)?([\d+.\-]+)(.*)$/,aa,na=[["height","marginTop","marginBottom","paddingTop","paddingBottom"],["width","marginLeft","marginRight","paddingLeft","paddingRight"],["opacity"]];c.fn.extend({show:function(a,b,d){if(a||a===0)return this.animate(S("show",3),a,b,d);else{a= +0;for(b=this.length;a=0;e--)if(d[e].elem===this){b&&d[e](true);d.splice(e,1)}});b||this.dequeue();return this}});c.each({slideDown:S("show",1),slideUp:S("hide",1),slideToggle:S("toggle",1),fadeIn:{opacity:"show"},fadeOut:{opacity:"hide"}},function(a,b){c.fn[a]=function(d,e,f){return this.animate(b, +d,e,f)}});c.extend({speed:function(a,b,d){var e=a&&typeof a==="object"?c.extend({},a):{complete:d||!d&&b||c.isFunction(a)&&a,duration:a,easing:d&&b||b&&!c.isFunction(b)&&b};e.duration=c.fx.off?0:typeof e.duration==="number"?e.duration:e.duration in c.fx.speeds?c.fx.speeds[e.duration]:c.fx.speeds._default;e.old=e.complete;e.complete=function(){e.queue!==false&&c(this).dequeue();c.isFunction(e.old)&&e.old.call(this)};return e},easing:{linear:function(a,b,d,e){return d+e*a},swing:function(a,b,d,e){return(-Math.cos(a* +Math.PI)/2+0.5)*e+d}},timers:[],fx:function(a,b,d){this.options=b;this.elem=a;this.prop=d;if(!b.orig)b.orig={}}});c.fx.prototype={update:function(){this.options.step&&this.options.step.call(this.elem,this.now,this);(c.fx.step[this.prop]||c.fx.step._default)(this)},cur:function(){if(this.elem[this.prop]!=null&&(!this.elem.style||this.elem.style[this.prop]==null))return this.elem[this.prop];var a=parseFloat(c.css(this.elem,this.prop));return a&&a>-1E4?a:0},custom:function(a,b,d){function e(h){return f.step(h)} +this.startTime=c.now();this.start=a;this.end=b;this.unit=d||this.unit||"px";this.now=this.start;this.pos=this.state=0;var f=this;a=c.fx;e.elem=this.elem;if(e()&&c.timers.push(e)&&!aa)aa=setInterval(a.tick,a.interval)},show:function(){this.options.orig[this.prop]=c.style(this.elem,this.prop);this.options.show=true;this.custom(this.prop==="width"||this.prop==="height"?1:0,this.cur());c(this.elem).show()},hide:function(){this.options.orig[this.prop]=c.style(this.elem,this.prop);this.options.hide=true; +this.custom(this.cur(),0)},step:function(a){var b=c.now(),d=true;if(a||b>=this.options.duration+this.startTime){this.now=this.end;this.pos=this.state=1;this.update();this.options.curAnim[this.prop]=true;for(var e in this.options.curAnim)if(this.options.curAnim[e]!==true)d=false;if(d){if(this.options.overflow!=null&&!c.support.shrinkWrapBlocks){var f=this.elem,h=this.options;c.each(["","X","Y"],function(l,n){f.style["overflow"+n]=h.overflow[l]})}this.options.hide&&c(this.elem).hide();if(this.options.hide|| +this.options.show)for(var k in this.options.curAnim)c.style(this.elem,k,this.options.orig[k]);this.options.complete.call(this.elem)}return false}else{a=b-this.startTime;this.state=a/this.options.duration;b=this.options.easing||(c.easing.swing?"swing":"linear");this.pos=c.easing[this.options.specialEasing&&this.options.specialEasing[this.prop]||b](this.state,a,0,1,this.options.duration);this.now=this.start+(this.end-this.start)*this.pos;this.update()}return true}};c.extend(c.fx,{tick:function(){for(var a= +c.timers,b=0;b-1;e={};var s={};if(n)s=f.position();k=n?s.top:parseInt(k,10)||0;l=n?s.left:parseInt(l,10)||0;if(c.isFunction(b))b=b.call(a,d,h);if(b.top!=null)e.top=b.top-h.top+k;if(b.left!=null)e.left=b.left-h.left+l;"using"in b?b.using.call(a, +e):f.css(e)}};c.fn.extend({position:function(){if(!this[0])return null;var a=this[0],b=this.offsetParent(),d=this.offset(),e=Fa.test(b[0].nodeName)?{top:0,left:0}:b.offset();d.top-=parseFloat(c.css(a,"marginTop"))||0;d.left-=parseFloat(c.css(a,"marginLeft"))||0;e.top+=parseFloat(c.css(b[0],"borderTopWidth"))||0;e.left+=parseFloat(c.css(b[0],"borderLeftWidth"))||0;return{top:d.top-e.top,left:d.left-e.left}},offsetParent:function(){return this.map(function(){for(var a=this.offsetParent||u.body;a&&!Fa.test(a.nodeName)&& +c.css(a,"position")==="static";)a=a.offsetParent;return a})}});c.each(["Left","Top"],function(a,b){var d="scroll"+b;c.fn[d]=function(e){var f=this[0],h;if(!f)return null;if(e!==A)return this.each(function(){if(h=ea(this))h.scrollTo(!a?e:c(h).scrollLeft(),a?e:c(h).scrollTop());else this[d]=e});else return(h=ea(f))?"pageXOffset"in h?h[a?"pageYOffset":"pageXOffset"]:c.support.boxModel&&h.document.documentElement[d]||h.document.body[d]:f[d]}});c.each(["Height","Width"],function(a,b){var d=b.toLowerCase(); +c.fn["inner"+b]=function(){return this[0]?parseFloat(c.css(this[0],d,"padding")):null};c.fn["outer"+b]=function(e){return this[0]?parseFloat(c.css(this[0],d,e?"margin":"border")):null};c.fn[d]=function(e){var f=this[0];if(!f)return e==null?null:this;if(c.isFunction(e))return this.each(function(h){var k=c(this);k[d](e.call(this,h,k[d]()))});return c.isWindow(f)?f.document.compatMode==="CSS1Compat"&&f.document.documentElement["client"+b]||f.document.body["client"+b]:f.nodeType===9?Math.max(f.documentElement["client"+ +b],f.body["scroll"+b],f.documentElement["scroll"+b],f.body["offset"+b],f.documentElement["offset"+b]):e===A?parseFloat(c.css(f,d)):this.css(d,typeof e==="string"?e:e+"px")}})})(window); diff --git a/scratch/page.html b/scratch/page.html index 841fccab..a46e3839 100644 --- a/scratch/page.html +++ b/scratch/page.html @@ -62,13 +62,13 @@
- - + + \ No newline at end of file From 60901ddd75d5c95aef195e91efaf681372a50e8e Mon Sep 17 00:00:00 2001 From: Eston Bond Date: Fri, 22 Oct 2010 17:50:44 -0700 Subject: [PATCH 03/37] Added history, page --- scratch/history.html | 108 +++++++++++++++++++++++++++++++++++++++++++ scratch/page.html | 12 +++-- 2 files changed, 117 insertions(+), 3 deletions(-) create mode 100644 scratch/history.html diff --git a/scratch/history.html b/scratch/history.html new file mode 100644 index 00000000..e777ed80 --- /dev/null +++ b/scratch/history.html @@ -0,0 +1,108 @@ + + + + + Page Name — Site Name + + +
+ +
+ + + +
+
+
+ + + + + + + + + + + + + + + + + + + + +
+ + + + avatar: username + username + + + 3 days ago:  + Rewrote home page as Markdown… + [a45719f…] + + Revert to a45719f… +
+ + + + avatar: username + username + + + 3 days ago:  + Rewrote home page as Markdown… + [a45719f…] + + Revert to a45719f… +
+ + + + avatar: username + username + + + 3 days ago:  + Rewrote home page as Markdown… + [a45719f…] + + Revert to a45719f… +
+ + + + + + + + + + \ No newline at end of file diff --git a/scratch/page.html b/scratch/page.html index a46e3839..9a3741f2 100644 --- a/scratch/page.html +++ b/scratch/page.html @@ -5,12 +5,16 @@ Page Name — Site Name +
@@ -68,6 +72,8 @@ +
+ From 3b6b06a5992a7c98236a32191eaaf58efd5f3a02 Mon Sep 17 00:00:00 2001 From: Eston Bond Date: Mon, 25 Oct 2010 14:46:52 -0700 Subject: [PATCH 04/37] Basic text formatting --- scratch/css/gollum.css | 68 ++++++++++++++++++++++ scratch/css/template.css | 122 +++++++++++++++++++++++++++++++++++++++ scratch/page.html | 36 +++++++++++- 3 files changed, 225 insertions(+), 1 deletion(-) create mode 100644 scratch/css/template.css diff --git a/scratch/css/gollum.css b/scratch/css/gollum.css index e69de29b..c163e95e 100644 --- a/scratch/css/gollum.css +++ b/scratch/css/gollum.css @@ -0,0 +1,68 @@ +/* + gollum.css + A basic stylesheet for Gollum +*/ + +/* @section core */ +body, html { + font-family: "Helvetica Neue", Helvetica, Arial, sans-serif; + font-size: 10px; /* -> 1em */ + margin: 0; + padding: 0; +} + +#wiki-wrapper { + margin: 0 auto; + overflow: visible; + width: 80%; +} + + +/* @section head */ +#head { + border-bottom: 1px solid #ccc; + margin: 4.5em 0 0.5em; + padding: 0.5em 0; + overflow: hidden; +} + + #head h1 { + font-size: 3.3em; + float: left; + line-height: normal; + margin: 0; + padding: 0; + } + + #head ul.actions { + display: block; + float: right; + list-style-type: none; + overflow: hidden; + padding: 0.6em 0 0; + } + + #head ul.actions li { + float: left; + font-size: 1.2em; + margin-left: 0.6em; + } + + +/* @section content */ +#wiki-content { + height: 1%; + overflow: visible; +} + + /* @section comments */ + #wiki-body #inline-comment { + display: none; /* todo */ + } + + /* @section body */ + #wiki-body { + float: left; + margin-right: 5%; + width: 70%; + } diff --git a/scratch/css/template.css b/scratch/css/template.css new file mode 100644 index 00000000..db1a333e --- /dev/null +++ b/scratch/css/template.css @@ -0,0 +1,122 @@ +/* + template.css + Wiki content formatting +*/ + +#template { + margin-bottom: 4em; /* Give it some breathing room */ +} + +#template p { + font-size: 1.4em; + line-height: 1.6em; +} + + /* See http://webtypography.net/Rhythm_and_Proportion/ */ + #template p + p { + margin: -0.75em 0 0; + text-indent: 1em; + } + + /* Everybody loves type ornaments */ + #template p:last-child:after { + color: #999; + content: " āˆ"; + font-size: 0.8em; + } + + +#template ul, #template ol { + margin: 1.0em 0; + padding: 0; +} + +#template p + ul, #template p + ol, +#template ul li > ul, #template ol li > ol { + margin: 0; +} + + #template ul { + list-style-type: square; + } + + #template ol li > ol li { + font-size: 1.0em !important; + list-style-type: lower-roman; + list-style-position: inside; + } + + #template ol li > ol li > ol li { + list-style-type: lower-alpha; + } + + #template ol li > ol li > ol li > ol li { + list-style-type: lower-greek; + } + +#template ul li, #template ol li { + font-size: 1.4em; + line-height: 1.6em; + padding-top: 0.1em; /* Line up ordinals */ +} + +#template blockquote { + margin: 0 4.0em 0 2.0em; + padding: 0; +} + + #template blockquote p { + color: #888; + font-style: italic; + } + + +/* Headings */ +#template h1, #template h2, #template h3, +#template h4, #template h5, #template h6 { + margin: 0; + padding: 0.5em 0 0; +} + +#template h1 { + font-size: 2.6em; + font-weight: bold; +} + +#template h2 { + font-size: 2.2em; + font-weight: bold; +} + +#template h3 { + font-size: 2.0em; + font-weight: bold; +} + +#template h4 { + font-size: 1.8em; + font-weight: bold; +} + +#template h5 { + font-size: 1.6em; + font-weight: bold; + +} + +#template h6 { + font-size: 1.4em; + font-weight: bold; + margin-top: 1.0em; + text-transform: uppercase; /* all caps */ +} + + +/* Code-related */ +#template p code { + background-color: #f7f7f7; + border: 1px solid #ddd; + color: #222; /* This is a little heavy when #000 */ + font-family: Consolas, Monaco, "Courier New", monospace; + padding: 0.15em 0.3em; +} \ No newline at end of file diff --git a/scratch/page.html b/scratch/page.html index 9a3741f2..8eb96cc5 100644 --- a/scratch/page.html +++ b/scratch/page.html @@ -1,7 +1,9 @@ + + Page Name — Site Name @@ -35,10 +37,16 @@
  1. Ordered list 1
  2. Ordered list 2
  3. +
  4. +
      +
    1. Nest 1
    2. +
    3. Nest 2
    4. +
    +
  5. Ordered list 3

- Tempus a consequat ut, accumsan vitae tellus. Nunc aliquet tempus lectus, non accumsan elit gravida faucibus. Proin in imperdiet ligula. Mauris nec posuere felis. Etiam tempus sollicitudin massa, vel vestibulum est lacinia sed. + Tempus a consequat ut, accumsan vitae tellus. Nunc aliquet tempus lectus, non accumsan elit gravida faucibus. Proin in imperdiet ligula. Mauris nec posuere felis. Etiam tempus sollicitudin massa, vel vestibulum est lacinia sed.

Nam iaculis volutpat dolor, laoreet blandit felis scelerisque sagittis. Suspendisse pretium lorem in nunc interdum vel malesuada ante pretium. Nam consectetur tortor scelerisque mi congue rhoncus. Curabitur vulputate nunc non urna condimentum in consequat elit lobortis. Etiam eu purus mi. Lorem ipsum dolor sit amet, consectetur adipiscing elit. Morbi sit amet arcu enim, id iaculis tortor. @@ -51,6 +59,32 @@

In urna dolor, pulvinar nec porttitor vitae, varius quis sem. Nulla at nisl nisl. In lobortis enim lacinia lectus semper fermentum id sit amet quam. Vestibulum ante ipsum primis in faucibus orci luctus et ultrices posuere cubilia Curae.

+

Heading 3

+

+ Vestibulum ante ipsum primis in faucibus orci luctus et ultrices posuere cubilia Curae; Praesent leo neque, lacinia vitae posuere sed, adipiscing vitae massa. Lorem ipsum dolor sit amet, consectetur adipiscing elit. Morbi felis sem, dictum ut interdum sit amet, tincidunt at tellus. +

+

+ Duis convallis, mauris in ultrices convallis, ligula arcu laoreet dolor, in elementum justo lorem et magna. Sed posuere est at ante aliquam hendrerit. Ut porta ipsum a neque porta at gravida lacus dictum. Cras at cursus massa. Aliquam dignissim sagittis augue, non pellentesque massa adipiscing sit amet. Donec at faucibus massa. Etiam hendrerit accumsan rutrum. Mauris venenatis justo nec sem tincidunt gravida. Quisque ut lacus mi, at iaculis urna. Sed id libero neque. +

+

Heading 4

+

+ Nulla facilisi. Duis sem risus, malesuada eget tempor eu, elementum sed mi. Pellentesque habitant morbi tristique senectus et netus et malesuada fames ac turpis egestas. Donec commodo libero ac risus hendrerit gravida. Nullam id orci nulla, nec pulvinar dui. Donec elit odio, pulvinar ut cursus id, rhoncus eu urna. Aliquam molestie interdum aliquam. +

+
Heading 5
+

+ Vestibulum sed neque mauris, quis imperdiet lorem. Fusce id sollicitudin est. Vivamus porta blandit nibh, ultricies ultricies tortor scelerisque nec. Aliquam et ipsum ut neque aliquet accumsan at eu ante. Donec velit turpis, feugiat non venenatis at, rutrum cursus neque. Integer nunc purus, porta vel semper et, venenatis a nisi. +

+

+ Nunc malesuada, diam nec euismod tristique, lacus nibh ornare dolor, eleifend rhoncus nunc enim nec nisi. Nulla neque tellus, scelerisque porttitor commodo vitae, euismod vitae est. Sed adipiscing metus vitae nisi sodales porta. Pellentesque habitant morbi tristique senectus et netus et malesuada fames ac turpis egestas. Cras a urna massa. Vestibulum ac sapien urna. +

+
Heading 6
+
    +
  • Unordered list item 1
  • +
  • Unordered list item 2
  • +
+

+ Sed sit amet arcu lectus, eu hendrerit eros. Pellentesque at neque sed justo luctus mattis. Maecenas egestas, urna sit amet pulvinar dictum, nisl urna consequat purus, at consectetur eros metus eu ligula. Mauris sed magna sed risus commodo faucibus. Etiam sit amet dui id urna mollis pretium. Nam dolor augue, bibendum sit amet congue eget, lacinia at dolor. Vestibulum id quam sed dolor laoreet pellentesque eget ut leo. +

From 21ff30af4ddf21ee66a23706e072c8e810bbd4ab Mon Sep 17 00:00:00 2001 From: Eston Bond Date: Mon, 25 Oct 2010 15:54:42 -0700 Subject: [PATCH 05/37] Shadows, minibuttons and more --- scratch/css/gollum.css | 128 ++++++++++++++++++++++++++++++++++++++- scratch/css/template.css | 10 ++- scratch/page.html | 2 + 3 files changed, 136 insertions(+), 4 deletions(-) diff --git a/scratch/css/gollum.css b/scratch/css/gollum.css index c163e95e..0e40f2a7 100644 --- a/scratch/css/gollum.css +++ b/scratch/css/gollum.css @@ -17,6 +17,15 @@ body, html { width: 80%; } +a:link { + color: #4183c4; + text-decoration: none; +} + +a:hover, a:visited { + text-decoration: underline; +} + /* @section head */ #head { @@ -31,7 +40,7 @@ body, html { float: left; line-height: normal; margin: 0; - padding: 0; + padding: 0.08em 0 0 0; } #head ul.actions { @@ -39,7 +48,7 @@ body, html { float: right; list-style-type: none; overflow: hidden; - padding: 0.6em 0 0; + padding: 0; } #head ul.actions li { @@ -48,6 +57,39 @@ body, html { margin-left: 0.6em; } + /* @control minibutton */ + .minibutton a { + background-color: #f7f7f7; + border: 1px solid #d4d4d4; + color: #333; + display: block; + font-weight: bold; + margin: 0; + padding: 0.4em 1em; + + text-shadow: 0 1px 0 #fff; + + filter:progid:DXImageTransform.Microsoft.gradient(GradientType=0, startColorstr='#f4f4f4', endColorstr='#ececec'); + background: -webkit-gradient(linear, left top, left bottom, from(#f4f4f4), to(#ececec)); + background: -moz-linear-gradient(top, #f4f4f4, #ececec); + + border-radius: 3px; + -moz-border-radius: 3px; + -webkit-border-radius: 3px; + } + + .minibutton a:hover { + background: #3072b3; + border-color: #518cc6 #518cc6 #2a65a0; + color: #fff; + text-shadow: 0 -1px 0 rgba(0, 0, 0, 0.3); + text-decoration: none; + + filter:progid:DXImageTransform.Microsoft.gradient(GradientType=0, startColorstr='#599bdc', endColorstr='#3072b3'); + background: -webkit-gradient(linear, left top, left bottom, from(#599bdc), to(#3072b3)); + background: -moz-linear-gradient(top, #599bdc, #3072b3); + } + /* @section content */ #wiki-content { @@ -63,6 +105,86 @@ body, html { /* @section body */ #wiki-body { float: left; - margin-right: 5%; + margin-right: 3%; width: 70%; } + + /* @section rightbar */ + #wiki-rightbar { + float: right; + width: 27%; + } + + #wiki-rightbar #nav { + background-color: #f7f7f7; + border: 1px solid #ddd; + margin-top: 1.5em; + padding: 1em; + + border-radius: 0.5em; + -moz-border-radius: 0.5em; + -webkit-border-radius: 0.5em; + } + + #wiki-rightbar #nav { + font-size: 1.2em; + line-height: 1.5em; + } + + #wiki-rightbar #nav p.parent { + border-bottom: 1px solid #bbb; + font-weight: bold; + margin: 0 0 0.5em 0; + padding: 0 0 0.5em 0; + text-shadow: 0 1px 0 #fff; + } + + /* Back arrow */ + #wiki-rightbar #nav p.parent:before { + color: #666; + content: "← "; + } + + #wiki-rightbar #nav h3 { + font-size: 1.2em; + color: #333; + margin: 1.2em 0 0; + padding: 0; + text-shadow: 0 1px 0 #fff; + } + + #wiki-rightbar #nav ul { + margin: 0.5em 0 1em; + padding: 0; + } + + #wiki-rightbar #nav ul li { + list-style-position: inside; + list-style-type: none; + margin: 0; + padding: 0 0 0 1em; + line-height: 1.75em; + } + + #wiki-rightbar #nav ul li a { + font-weight: bold; + text-shadow: 0 1px 0 #fff; + } + + /* @section footer */ + #wiki-footer { + clear: both; + } + + + /* @section page-footer */ + #footer { + border-top: 1px solid #ccc; + font-size: 1.2em; + line-height: 1.6em; + margin: 1em 0 7em; + } + + #footer p#last-edit { + color: #999; + } diff --git a/scratch/css/template.css b/scratch/css/template.css index db1a333e..5d6a6f95 100644 --- a/scratch/css/template.css +++ b/scratch/css/template.css @@ -24,7 +24,15 @@ content: " āˆ"; font-size: 0.8em; } - + +#template a:link { + color: #4183c4; + text-decoration: none; +} + +#template a:hover, #template a:visited { + text-decoration: underline; +} #template ul, #template ol { margin: 1.0em 0; diff --git a/scratch/page.html b/scratch/page.html index 8eb96cc5..dfe92551 100644 --- a/scratch/page.html +++ b/scratch/page.html @@ -88,6 +88,7 @@
+
-
+ +
+
+ \ No newline at end of file From 67651afb48e00805c04a980c19e7372ed4e558be Mon Sep 17 00:00:00 2001 From: Eston Bond Date: Mon, 25 Oct 2010 16:57:33 -0700 Subject: [PATCH 09/37] This should do --- scratch/css/gollum.css | 9 +++++++-- scratch/js/gollum.js | 12 ++++++++++++ 2 files changed, 19 insertions(+), 2 deletions(-) diff --git a/scratch/css/gollum.css b/scratch/css/gollum.css index 095fe458..63a64ad7 100644 --- a/scratch/css/gollum.css +++ b/scratch/css/gollum.css @@ -224,7 +224,12 @@ a:hover, a:visited { list-style-position: inside; list-style-type: square; padding: 0; - margin-left: 0.6em; + margin-left: 0.75em; + } + + #wiki-footer #footer-content ul.links li a { + font-weight: bold; + text-shadow: 0 1px 0 #fff; } #wiki-footer #footer-content ul.links li:first-child { @@ -233,7 +238,7 @@ a:hover, a:visited { } .ff #wiki-footer #footer-content ul.links li:first-child { - margin: 0 -0.6em 0 0; + margin: 0 -0.75em 0 0; } /* @section page-footer */ diff --git a/scratch/js/gollum.js b/scratch/js/gollum.js index 6c2ede74..b7dfb2f3 100644 --- a/scratch/js/gollum.js +++ b/scratch/js/gollum.js @@ -1,5 +1,7 @@ // ua $(document).ready(function() { + + // ua detection if ($.browser.mozilla) { $('body').addClass('ff'); } else if ($.browser.webkit) { @@ -12,4 +14,14 @@ $(document).ready(function() { $('body').addClass('ie8'); } } + + // no widows in wiki body + if ($('#wiki-wrapper').hasClass('page')) { + $('#template h1, #template h2, #template h3, #template h4, #template h5, #template h6, #template li, #template p').each( + function(){ + $(this).html($(this).html().replace(/\s([^\s<]+)\s*$/,' $1')); + } + ); + } + }); \ No newline at end of file From e0c1ea0ec1009fa954554d71b2a9d1d749a8b136 Mon Sep 17 00:00:00 2001 From: Eston Bond Date: Mon, 25 Oct 2010 18:49:24 -0700 Subject: [PATCH 10/37] Adding rudimentary hover anims on history --- scratch/css/gollum.css | 224 +++++++++++++++++++++++++++++-------- scratch/css/template.css | 2 + scratch/history.html | 48 ++++---- scratch/js/gollum.js | 36 +++++- scratch/js/jquery.color.js | 123 ++++++++++++++++++++ 5 files changed, 362 insertions(+), 71 deletions(-) create mode 100644 scratch/js/jquery.color.js diff --git a/scratch/css/gollum.css b/scratch/css/gollum.css index 63a64ad7..c4a8d191 100644 --- a/scratch/css/gollum.css +++ b/scratch/css/gollum.css @@ -42,52 +42,9 @@ a:hover, a:visited { margin: 0; padding: 0.08em 0 0 0; } - + #head ul.actions { - display: block; float: right; - list-style-type: none; - overflow: hidden; - padding: 0; - } - - #head ul.actions li { - float: left; - font-size: 1.2em; - margin-left: 0.6em; - } - - /* @control minibutton */ - .minibutton a { - background-color: #f7f7f7; - border: 1px solid #d4d4d4; - color: #333; - display: block; - font-weight: bold; - margin: 0; - padding: 0.4em 1em; - - text-shadow: 0 1px 0 #fff; - - filter:progid:DXImageTransform.Microsoft.gradient(GradientType=0, startColorstr='#f4f4f4', endColorstr='#ececec'); - background: -webkit-gradient(linear, left top, left bottom, from(#f4f4f4), to(#ececec)); - background: -moz-linear-gradient(top, #f4f4f4, #ececec); - - border-radius: 3px; - -moz-border-radius: 3px; - -webkit-border-radius: 3px; - } - - .minibutton a:hover { - background: #3072b3; - border-color: #518cc6 #518cc6 #2a65a0; - color: #fff; - text-shadow: 0 -1px 0 rgba(0, 0, 0, 0.3); - text-decoration: none; - - filter:progid:DXImageTransform.Microsoft.gradient(GradientType=0, startColorstr='#599bdc', endColorstr='#3072b3'); - background: -webkit-gradient(linear, left top, left bottom, from(#599bdc), to(#3072b3)); - background: -moz-linear-gradient(top, #599bdc, #3072b3); } @@ -242,14 +199,14 @@ a:hover, a:visited { } /* @section page-footer */ - #footer { + .page #footer { border-top: 1px solid #ccc; - font-size: 1.2em; - line-height: 1.6em; margin: 1em 0 7em; } #footer p#last-edit { + font-size: 1.2em; + line-height: 1.6em; color: #999; margin: 0.9em 0; } @@ -257,3 +214,176 @@ a:hover, a:visited { #footer p#last-edit span.username { font-weight: bold; } + + +/* @section history */ +.history h1 { + color: #999; + font-weight: normal; +} + + .history h1 strong { + color: #000; + font-weight: bold; + } + +#wiki-history { + margin-top: 3em; +} + + #wiki-history fieldset { + border: 0; + margin: 0; + padding: 0; + } + + #wiki-history table, #wiki-history tbody { + border-collapse: collapse; + padding: 0; + margin: 0; + width: 100%; + } + + #wiki-history table tr { + padding: 0; + margin: 0; + } + + #wiki-history table tr { + background-color: #ebf2f6; + } + + #wiki-history table tr td { + border: 1px solid #c0dce9; + font-size: 1.2em; + line-height: 1.6em; + margin: 0; + padding: 0.6em; + } + + #wiki-history table tr td.checkbox input { + cursor: pointer; + display: block; + padding-right: 0; + padding-top: 0.4em; + margin-right: -0.3em; + } + + #wiki-history table tr:nth-child(2n), + #wiki-history table tr.alt-row { + background-color: #f3f7fa; + } + + #wiki-history table tr.selected { + background-color: #ffffea !important; + z-index: 100; + } + + #wiki-history table tr td.commit-name { + border-right: none; + padding-left: 1.2em; + } + + #wiki-history table tr td.commit-name span.time-elapsed { + color: #999; + } + + #wiki-history table tr td.author { + width: 20%; + } + + #wiki-history table tr td.author a { + color: #000; + font-weight: bold; + } + + #wiki-history table tr td.author a span.username { + display: block; + padding-top: 3px; + } + + #wiki-history table tr td img { + background-color: #fff; + border: 1px solid #999; + display: block; + float: left; + height: 18px; + overflow: hidden; + margin: 0 0.5em 0 0; + width: 18px; + padding: 2px; + } + + #wiki-history table tr td.commit-name a { + font-size: 0.9em; + font-family: 'Monaco', 'Andale Mono', Consolas, 'Courier New', monospace; + padding: 0 0.2em; + } + + #wiki-history table tr td.revert-action { + border-left: 0; + text-align: right; + padding-right: 1.2em; + } + + #wiki-history table tr td.revert-action a { + font-weight: bold; + } + + #wiki-history table tr td.revert-action a span { + font-size: 0.9em; + font-family: 'Monaco', 'Andale Mono', Consolas, 'Courier New', monospace; + } + +.history #wiki-history ul.actions li, +.history #footer ul.actions li { + margin: 0 0.6em 0 0; +} + + + +/* @control minibutton */ +ul.actions { + display: block; + list-style-type: none; + overflow: hidden; + padding: 0; + } + + ul.actions li { + float: left; + font-size: 1.2em; + margin-left: 0.6em; + } + +.minibutton a { + background-color: #f7f7f7; + border: 1px solid #d4d4d4; + color: #333; + display: block; + font-weight: bold; + margin: 0; + padding: 0.4em 1em; + + text-shadow: 0 1px 0 #fff; + + filter:progid:DXImageTransform.Microsoft.gradient(GradientType=0, startColorstr='#f4f4f4', endColorstr='#ececec'); + background: -webkit-gradient(linear, left top, left bottom, from(#f4f4f4), to(#ececec)); + background: -moz-linear-gradient(top, #f4f4f4, #ececec); + + border-radius: 3px; + -moz-border-radius: 3px; + -webkit-border-radius: 3px; +} + +.minibutton a:hover { + background: #3072b3; + border-color: #518cc6 #518cc6 #2a65a0; + color: #fff; + text-shadow: 0 -1px 0 rgba(0, 0, 0, 0.3); + text-decoration: none; + + filter:progid:DXImageTransform.Microsoft.gradient(GradientType=0, startColorstr='#599bdc', endColorstr='#3072b3'); + background: -webkit-gradient(linear, left top, left bottom, from(#599bdc), to(#3072b3)); + background: -moz-linear-gradient(top, #599bdc, #3072b3); +} \ No newline at end of file diff --git a/scratch/css/template.css b/scratch/css/template.css index 784e12bc..882877ff 100644 --- a/scratch/css/template.css +++ b/scratch/css/template.css @@ -1,6 +1,8 @@ /* template.css Wiki content formatting + Keeping this file separate so it can be easily swapped out if you + want to format your wiki content differently from the default. */ #template { diff --git a/scratch/history.html b/scratch/history.html index e777ed80..9d07a5c0 100644 --- a/scratch/history.html +++ b/scratch/history.html @@ -22,32 +22,31 @@
- - - - - - + + + + + + + +
- - - - avatar: username - username - - - 3 days ago:  - Rewrote home page as Markdown… - [a45719f…] - - Revert to a45719f… -
+ + + + avatar: username + username + + + 3 days ago:  + Rewrote home page as Markdown… + [a45719f…] + + Revert to a45719f… +
@@ -56,7 +55,7 @@ avatar: username - username + username @@ -76,7 +75,7 @@ avatar: username - username + username @@ -88,6 +87,7 @@ Revert to a45719f…
@@ -103,6 +103,8 @@ + + \ No newline at end of file diff --git a/scratch/js/gollum.js b/scratch/js/gollum.js index b7dfb2f3..e4321ce4 100644 --- a/scratch/js/gollum.js +++ b/scratch/js/gollum.js @@ -24,4 +24,38 @@ $(document).ready(function() { ); } -}); \ No newline at end of file + if ($('#wiki-wrapper').hasClass('history')) { + $('#wiki-history td.checkbox input').each(highlightChecked); + $('#wiki-history td.checkbox input').click(highlightChecked); + + $('#wiki-history td.revert-action a').mouseenter(highlightOn); + $('#wiki-history td.revert-action a').mouseleave(highlightOff); + }; + +}); + +function highlightOn() { + $(this).parent().parent().animate({ + backgroundColor: '#ffffea', + duration: 400 + }); +} + +function highlightOff() { + var color = '#ebf2f6'; + if ($(this).parent().parent().hasClass('alt-row')) { + color = '#f3f7fa'; + } + $(this).parent().parent().animate({ + backgroundColor: color, + duration: 400 + }); +} + +function highlightChecked() { + if ($(this).is(':checked')) { + $(this).parent().parent().addClass('selected'); + } else { + $(this).parent().parent().removeClass('selected'); + } +} \ No newline at end of file diff --git a/scratch/js/jquery.color.js b/scratch/js/jquery.color.js new file mode 100644 index 00000000..634719d3 --- /dev/null +++ b/scratch/js/jquery.color.js @@ -0,0 +1,123 @@ +/* + * jQuery Color Animations + * Copyright 2007 John Resig + * Released under the MIT and GPL licenses. + */ + +(function(jQuery){ + + // We override the animation for all of these color styles + jQuery.each(['backgroundColor', 'borderBottomColor', 'borderLeftColor', 'borderRightColor', 'borderTopColor', 'color', 'outlineColor'], function(i,attr){ + jQuery.fx.step[attr] = function(fx){ + if ( fx.state == 0 ) { + fx.start = getColor( fx.elem, attr ); + fx.end = getRGB( fx.end ); + } + + fx.elem.style[attr] = "rgb(" + [ + Math.max(Math.min( parseInt((fx.pos * (fx.end[0] - fx.start[0])) + fx.start[0]), 255), 0), + Math.max(Math.min( parseInt((fx.pos * (fx.end[1] - fx.start[1])) + fx.start[1]), 255), 0), + Math.max(Math.min( parseInt((fx.pos * (fx.end[2] - fx.start[2])) + fx.start[2]), 255), 0) + ].join(",") + ")"; + } + }); + + // Color Conversion functions from highlightFade + // By Blair Mitchelmore + // http://jquery.offput.ca/highlightFade/ + + // Parse strings looking for color tuples [255,255,255] + function getRGB(color) { + var result; + + // Check if we're already dealing with an array of colors + if ( color && color.constructor == Array && color.length == 3 ) + return color; + + // Look for rgb(num,num,num) + if (result = /rgb\(\s*([0-9]{1,3})\s*,\s*([0-9]{1,3})\s*,\s*([0-9]{1,3})\s*\)/.exec(color)) + return [parseInt(result[1]), parseInt(result[2]), parseInt(result[3])]; + + // Look for rgb(num%,num%,num%) + if (result = /rgb\(\s*([0-9]+(?:\.[0-9]+)?)\%\s*,\s*([0-9]+(?:\.[0-9]+)?)\%\s*,\s*([0-9]+(?:\.[0-9]+)?)\%\s*\)/.exec(color)) + return [parseFloat(result[1])*2.55, parseFloat(result[2])*2.55, parseFloat(result[3])*2.55]; + + // Look for #a0b1c2 + if (result = /#([a-fA-F0-9]{2})([a-fA-F0-9]{2})([a-fA-F0-9]{2})/.exec(color)) + return [parseInt(result[1],16), parseInt(result[2],16), parseInt(result[3],16)]; + + // Look for #fff + if (result = /#([a-fA-F0-9])([a-fA-F0-9])([a-fA-F0-9])/.exec(color)) + return [parseInt(result[1]+result[1],16), parseInt(result[2]+result[2],16), parseInt(result[3]+result[3],16)]; + + // Otherwise, we're most likely dealing with a named color + return colors[jQuery.trim(color).toLowerCase()]; + } + + function getColor(elem, attr) { + var color; + + do { + color = jQuery.curCSS(elem, attr); + + // Keep going until we find an element that has color, or we hit the body + if ( color != '' && color != 'transparent' || jQuery.nodeName(elem, "body") ) + break; + + attr = "backgroundColor"; + } while ( elem = elem.parentNode ); + + return getRGB(color); + }; + + // Some named colors to work with + // From Interface by Stefan Petre + // http://interface.eyecon.ro/ + + var colors = { + aqua:[0,255,255], + azure:[240,255,255], + beige:[245,245,220], + black:[0,0,0], + blue:[0,0,255], + brown:[165,42,42], + cyan:[0,255,255], + darkblue:[0,0,139], + darkcyan:[0,139,139], + darkgrey:[169,169,169], + darkgreen:[0,100,0], + darkkhaki:[189,183,107], + darkmagenta:[139,0,139], + darkolivegreen:[85,107,47], + darkorange:[255,140,0], + darkorchid:[153,50,204], + darkred:[139,0,0], + darksalmon:[233,150,122], + darkviolet:[148,0,211], + fuchsia:[255,0,255], + gold:[255,215,0], + green:[0,128,0], + indigo:[75,0,130], + khaki:[240,230,140], + lightblue:[173,216,230], + lightcyan:[224,255,255], + lightgreen:[144,238,144], + lightgrey:[211,211,211], + lightpink:[255,182,193], + lightyellow:[255,255,224], + lime:[0,255,0], + magenta:[255,0,255], + maroon:[128,0,0], + navy:[0,0,128], + olive:[128,128,0], + orange:[255,165,0], + pink:[255,192,203], + purple:[128,0,128], + violet:[128,0,128], + red:[255,0,0], + silver:[192,192,192], + white:[255,255,255], + yellow:[255,255,0] + }; + +})(jQuery); From 927b012d6c69a3565deb8dae0bca2b54e914b9a1 Mon Sep 17 00:00:00 2001 From: Eston Bond Date: Mon, 25 Oct 2010 18:52:45 -0700 Subject: [PATCH 11/37] Tightening up table --- scratch/css/gollum.css | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/scratch/css/gollum.css b/scratch/css/gollum.css index c4a8d191..d22f9535 100644 --- a/scratch/css/gollum.css +++ b/scratch/css/gollum.css @@ -233,7 +233,7 @@ a:hover, a:visited { #wiki-history fieldset { border: 0; - margin: 0; + margin: 2em 0; padding: 0; } @@ -258,7 +258,11 @@ a:hover, a:visited { font-size: 1.2em; line-height: 1.6em; margin: 0; - padding: 0.6em; + padding: 0.3em 0.7em; + } + + #wiki-history table tr td.checkbox { + padding: 0.3em; } #wiki-history table tr td.checkbox input { @@ -266,7 +270,7 @@ a:hover, a:visited { display: block; padding-right: 0; padding-top: 0.4em; - margin-right: -0.3em; + margin-right: -0.2em; } #wiki-history table tr:nth-child(2n), @@ -281,7 +285,6 @@ a:hover, a:visited { #wiki-history table tr td.commit-name { border-right: none; - padding-left: 1.2em; } #wiki-history table tr td.commit-name span.time-elapsed { @@ -323,7 +326,6 @@ a:hover, a:visited { #wiki-history table tr td.revert-action { border-left: 0; text-align: right; - padding-right: 1.2em; } #wiki-history table tr td.revert-action a { From 0b1f1a5338ad2880fddad6ef1bf43f2ad758bca5 Mon Sep 17 00:00:00 2001 From: Eston Bond Date: Wed, 27 Oct 2010 16:03:16 -0700 Subject: [PATCH 12/37] Beginnings of new editor --- scratch/css/editor.css | 4 + scratch/edit.html | 74 +++++++++ scratch/js/gollum-editor/langs/markdown.js | 1 + scratch/js/gollum.editor.js | 174 +++++++++++++++++++++ 4 files changed, 253 insertions(+) create mode 100644 scratch/css/editor.css create mode 100644 scratch/edit.html create mode 100644 scratch/js/gollum-editor/langs/markdown.js diff --git a/scratch/css/editor.css b/scratch/css/editor.css new file mode 100644 index 00000000..bcf10862 --- /dev/null +++ b/scratch/css/editor.css @@ -0,0 +1,4 @@ +/* + editor.css + Wiki editor formatting +*/ \ No newline at end of file diff --git a/scratch/edit.html b/scratch/edit.html new file mode 100644 index 00000000..7641ad7f --- /dev/null +++ b/scratch/edit.html @@ -0,0 +1,74 @@ + + + + + + + Page Name — Site Name + + +
+ +
+
+
+
+ +
+
+
+ + +
+ +
+ +
+
+
+
+
+
+ +
+ + + + + + \ No newline at end of file diff --git a/scratch/js/gollum-editor/langs/markdown.js b/scratch/js/gollum-editor/langs/markdown.js new file mode 100644 index 00000000..d77af0c7 --- /dev/null +++ b/scratch/js/gollum-editor/langs/markdown.js @@ -0,0 +1 @@ +// meh \ No newline at end of file diff --git a/scratch/js/gollum.editor.js b/scratch/js/gollum.editor.js index e69de29b..34173319 100644 --- a/scratch/js/gollum.editor.js +++ b/scratch/js/gollum.editor.js @@ -0,0 +1,174 @@ +/** + * gollum.editor.js + * A jQuery plugin that creates the Gollum Editor. + * + * Usage: + * $.GollumEditor(); on DOM ready. +**/ +/* (function($) { */ + + var GollumDefaults = { + MarkupType: 'markdown', + EditorMode: 'code', + HasFunctionBar: true, + Debug: true + }; + + var ActiveOptions = {}; + + $.GollumEditor = function(options) { + + ActiveOptions = $.extend(GollumDefaults, options); + debug('GollumEditor loading'); + + if ( EditorHas.baseEditorMarkup() ) { + + // Initialise the function bar by loading proper definitions + if ( EditorHas.functionBar() ) { + var htmlSetMarkupLang = + $('#gollum-editor-body').attr('data-markup-lang'); + + if ( htmlSetMarkupLang ) { + ActiveOptions.MarkupType = htmlSetMarkupLang; + } + + if ( !LanguageDefinition.isLoadedFor(ActiveOptions.MarkupType) ) { + debug('Loading language definition for ' + ActiveOptions.MarkupType); + LanguageDefinition.loadFor(ActiveOptions.MarkupType, + function(data, textStatus) { + if (textStatus != 'success') { + debug('Language definition could not be loaded for markup ' + + 'type ' + ActiveOptions.MarkupType); + return; + } + // activate the function bar + FunctionBar.activate(); + }); + } + } + + } + }; + + + + /** + * debug + * Prints debug information to console.log if debug output is enabled. + * + * @param mixed Whatever you want to dump to console.log + * @return void + **/ + var debug = function(m) { + if ( ActiveOptions.Debug && console + && typeof console.log == 'function' ) { + console.log(m); + } + }; + + + + /** + * LanguageDefinition + * Language definition file handler + * Loads language definition files as necessary. + **/ + var LanguageDefinition = { + + _LOADED_LANGS: [], + + /** + * loadFor + * Asynchronously loads a definition file for the current markup. + * Definition files are necessary to use the code editor. + * + * @param string markup_name The markup name you want to load + * @return void + **/ + loadFor: function( markup_name, on_complete ) { + // attempt to load the definition for this language + var script_uri = 'js/gollum-editor/langs/' + markup_name + '.js'; + $.ajax({ + url: script_uri, + dataType: 'script', + complete: function(xhr, textStatus) { + if (textStatus == 'success') { + LanguageDefinition._LOADED_LANGS.push(markup_name); + } + if (typeof on_complete == 'function') { + on_complete(xhr, textStatus, markup_name); + } + } + }); + }, + + + /** + * isLoadedFor + * Checks to see if a definition file has been loaded for the + * specified markup language. + * + * @param string markup_name The name of the markup. + * @return boolean + **/ + isLoadedFor: function( markup_name ) { + if ( LanguageDefinition._LOADED_LANGS.length == 0 ) return false; + + for (var i=0; i < LanguageDefinition._LOADED_LANGS.length; i++) { + if ( LanguageDefinition._LOADED_LANGS[i] == markup_name ) + return true; + } + return false; + } + + }; + + + /** + * EditorHas + * Various conditionals to check what features of the Gollum Editor are + * active/operational. + **/ + var EditorHas = { + + baseEditorMarkup: function() { + return ( $('#gollum-editor').length && + $('#gollum-editor-body').length ); + }, + + functionBar: function() { + return ( ActiveOptions.HasFunctionBar && + $('#gollum-editor-function-bar').length ); + } + + }; + + + /** + * FunctionBar + * + * Things the function bar does. + **/ + var FunctionBar = { + + isActive: false, + + activate: function() { + $('#gollum-editor-function-bar a.function-button') + .click(FunctionBar.evtFunctionButtonClick); + // show bar as active + $('#gollum-editor-function-bar').addClass('active'); + this.isActive = true; + }, + + evtFunctionButtonClick: function(e) { + alert('eee'); + } + + }; + +/* })(jQuery); */ + +jQuery(document).ready(function() { + $.GollumEditor(); +}); \ No newline at end of file From c9cc0d3d378c7f5bfb9628b7d1201a0573082151 Mon Sep 17 00:00:00 2001 From: Eston Bond Date: Wed, 27 Oct 2010 16:47:30 -0700 Subject: [PATCH 13/37] Added markdown definition, workin' on the editor --- scratch/js/gollum-editor/langs/markdown.js | 51 +++++++++++++++++++++- scratch/js/gollum.editor.js | 21 ++++++++- 2 files changed, 69 insertions(+), 3 deletions(-) diff --git a/scratch/js/gollum-editor/langs/markdown.js b/scratch/js/gollum-editor/langs/markdown.js index d77af0c7..1e113962 100644 --- a/scratch/js/gollum-editor/langs/markdown.js +++ b/scratch/js/gollum-editor/langs/markdown.js @@ -1 +1,50 @@ -// meh \ No newline at end of file +/** + * Markdown Language Definition + * + * A language definition for string manipulation operations, in this case + * for the Markdown, uh, markup language. Uses regexes for various functions + * by default. If regexes won't do and you need to do some serious + * manipulation, you can declare a function in the object instead. + * + * Code example: + * 'functionbar-id' : { + * exec: function(text, selectedText) { + * functionStuffHere(); + * }, + * search: /somesearchregex/gi, + * replace: 'replace text for RegExp.replace', + * append: "just add this where the cursor is" + * } + * +**/ + +var MarkDown = { + + 'function-bold' : { + search: /([^\n]+)([\n]*)/gi, + replace: "**$1**$2" + }, + + 'function-italic' : { + search: /([^\n]+)([\n]*)/gi, + replace: "_$1_$2" + }, + + 'function-code' : { + search: /([^\n]+)([\n]*)/gi, + replace: "`$1`$2" + }, + + 'function-hr' : { + append: "\n***\n" + }, + + 'function-ul' : { + search: /(.+)([\n]?)/gi, + replace: "* $1$2" + } + +}; + +// this is necessary for GollumEditor to pick this up +jQuery.GollumEditor.defineLanguage('markdown', MarkDown); \ No newline at end of file diff --git a/scratch/js/gollum.editor.js b/scratch/js/gollum.editor.js index 34173319..1844199f 100644 --- a/scratch/js/gollum.editor.js +++ b/scratch/js/gollum.editor.js @@ -50,6 +50,14 @@ } }; + $.GollumEditor.defineLanguage = function( language_name, languageObject ) { + if ( typeof languageObject == 'object' ) + LanguageDefinition.define( language_name, languageObject ); + else + debug('GollumEditor.defineLanguage: definition for ' + language_name + + ' is not an object'); + }; + /** @@ -75,7 +83,15 @@ **/ var LanguageDefinition = { - _LOADED_LANGS: [], + _LOADED_LANGS: [], + _LANG: {}, + + /** + * Defines a language + **/ + define: function( name, definitionObject ) { + LanguageDefinition._LANG[name] = definitionObject; + }, /** * loadFor @@ -162,7 +178,8 @@ }, evtFunctionButtonClick: function(e) { - alert('eee'); + e.preventDefault(); + alert($(this).attr('id')); } }; From 135156cea58dbbf20ec666f0128704e709b36eb7 Mon Sep 17 00:00:00 2001 From: Eston Bond Date: Wed, 27 Oct 2010 17:29:11 -0700 Subject: [PATCH 14/37] Adding code replacement techniques --- scratch/js/gollum.editor.js | 75 ++++++++++++++++++++++++-- scratch/js/jquery.fieldselection.js | 83 +++++++++++++++++++++++++++++ 2 files changed, 155 insertions(+), 3 deletions(-) create mode 100644 scratch/js/jquery.fieldselection.js diff --git a/scratch/js/gollum.editor.js b/scratch/js/gollum.editor.js index 1844199f..299b05e4 100644 --- a/scratch/js/gollum.editor.js +++ b/scratch/js/gollum.editor.js @@ -83,6 +83,7 @@ **/ var LanguageDefinition = { + _ACTIVE_LANG: '', _LOADED_LANGS: [], _LANG: {}, @@ -91,8 +92,32 @@ **/ define: function( name, definitionObject ) { LanguageDefinition._LANG[name] = definitionObject; + LanguageDefinition._ACTIVE_LANG = name; }, + + /** + * gets a definition object for a specified attribute + * + * @param string attr The specified attribute. + * @param string specified_lang The language to pull a definition for. + * @return object if exists, null otherwise + **/ + getDefinitionFor: function( attr, specified_lang ) { + if ( !specified_lang ) { + specified_lang = LanguageDefinition._ACTIVE_LANG; + } + + if ( LanguageDefinition.isLoadedFor(specified_lang) && + LanguageDefinition._LANG[specified_lang][attr] && + typeof LanguageDefinition_LANG[specified_lang][attr] == 'object' ) { + return LanguageDefinition._LANG[specified_lang][attr]; + } + + return null; + }, + + /** * loadFor * Asynchronously loads a definition file for the current markup. @@ -174,14 +199,58 @@ .click(FunctionBar.evtFunctionButtonClick); // show bar as active $('#gollum-editor-function-bar').addClass('active'); - this.isActive = true; + FunctionBar.isActive = true; }, evtFunctionButtonClick: function(e) { e.preventDefault(); - alert($(this).attr('id')); - } + var def = LanguageDefinition.getDefinitionFor( $(this).attr() ); + if ( def ) { + FunctionBar.executeAction( def ); + } + }, + executeAction: function( definitionObject ) { + // get the selected text from the textarea + var txt = $('#gollum-editor-body').val(); + // hmm, I'm not sure this will work in a textarea + var selText = $('#gollum-editor-body').getSelection(); + var repText = null; + + // exec a function if it exists first + if ( definitionObject.exec && + typeof definitionObject.exec == 'function' ) { + definitionObject(txt, selText, $('#gollum-editor-body')); + } + + // exec search/replace if both exist + if ( definitionObject.replace && + typeof definitionObject.replace == 'string' ) { + + var searchRegex = /(.*)/gi; + if ( definitionObject.search && + ( typeof definitionObject.search == 'string' || + typeof definitionObject.search == 'regexp' )) { + searchRegex = definitionObject.search; + } else { + debug('Invalid search regex, using default'); + } + + repText = selText.replace(searchRegex, definitionObject.replace); + } else { + debug('Invalid replacement string'); + } + + // now, add append if it exists + if ( definitionObject.append && + typeof definitionObject.append == 'string' ) { + repText += definitionObject.append; + } + + if (repText) + $('#gollum-editor-body').replaceSelection(repText); + + } }; /* })(jQuery); */ diff --git a/scratch/js/jquery.fieldselection.js b/scratch/js/jquery.fieldselection.js new file mode 100644 index 00000000..92fb6562 --- /dev/null +++ b/scratch/js/jquery.fieldselection.js @@ -0,0 +1,83 @@ +/* + * jQuery plugin: fieldSelection - v0.1.0 - last change: 2006-12-16 + * (c) 2006 Alex Brem - http://blog.0xab.cd + */ + +(function() { + + var fieldSelection = { + + getSelection: function() { + + var e = this.jquery ? this[0] : this; + + return ( + + /* mozilla / dom 3.0 */ + ('selectionStart' in e && function() { + var l = e.selectionEnd - e.selectionStart; + return { start: e.selectionStart, end: e.selectionEnd, length: l, text: e.value.substr(e.selectionStart, l) }; + }) || + + /* exploder */ + (document.selection && function() { + + e.focus(); + + var r = document.selection.createRange(); + if (r == null) { + return { start: 0, end: e.value.length, length: 0 } + } + + var re = e.createTextRange(); + var rc = re.duplicate(); + re.moveToBookmark(r.getBookmark()); + rc.setEndPoint('EndToStart', re); + + return { start: rc.text.length, end: rc.text.length + r.text.length, length: r.text.length, text: r.text }; + }) || + + /* browser not supported */ + function() { + return { start: 0, end: e.value.length, length: 0 }; + } + + )(); + + }, + + replaceSelection: function() { + + var e = this.jquery ? this[0] : this; + var text = arguments[0] || ''; + + return ( + + /* mozilla / dom 3.0 */ + ('selectionStart' in e && function() { + e.value = e.value.substr(0, e.selectionStart) + text + e.value.substr(e.selectionEnd, e.value.length); + return this; + }) || + + /* exploder */ + (document.selection && function() { + e.focus(); + document.selection.createRange().text = text; + return this; + }) || + + /* browser not supported */ + function() { + e.value += text; + return this; + } + + )(); + + } + + }; + + jQuery.each(fieldSelection, function(i) { jQuery.fn[i] = this; }); + +})(); \ No newline at end of file From b4006ec007952f31ed39cc0a79bbb2b5ccf9a6a1 Mon Sep 17 00:00:00 2001 From: Eston Bond Date: Mon, 1 Nov 2010 15:32:46 -0700 Subject: [PATCH 15/37] Most of the editor css, working editor --- scratch/css/editor.css | 125 ++++++- scratch/css/gollum.css | 12 + scratch/edit.html | 19 +- scratch/js/gollum-editor/gollum.editor.js | 393 ++++++++++++++++++++++ scratch/js/gollum.editor.js | 260 -------------- scratch/page.html | 2 +- 6 files changed, 535 insertions(+), 276 deletions(-) create mode 100644 scratch/js/gollum-editor/gollum.editor.js delete mode 100644 scratch/js/gollum.editor.js diff --git a/scratch/css/editor.css b/scratch/css/editor.css index bcf10862..51777e14 100644 --- a/scratch/css/editor.css +++ b/scratch/css/editor.css @@ -1,4 +1,127 @@ /* editor.css Wiki editor formatting -*/ \ No newline at end of file +*/ + +#gollum-editor { + border: 1px solid #e4e4e4; + background: #f9f9f9; + overflow: hidden; + padding: 1em; + + border-radius: 1em; + -moz-border-radius: 1em; + -webkit-border-radius: 1em; +} + +#gollum-editor form fieldset { + border: 0; + margin: 0; + padding: 0; + width: 100%; +} + +/* @control editor-view-tab */ +#gollum-editor #gollum-editor-type-switcher { + display: none; +} + +/* @control function-bar */ +#gollum-editor #gollum-editor-function-bar { + border-bottom: 1px solid #ddd; + overflow: hidden; + padding: 0 0 0.5em 0; + display: none; +} + +#gollum-editor #gollum-editor-function-bar.active { + display: block; +} + +#gollum-editor #gollum-editor-function-bar a.function-button { + background: #f7f7f7; + border: 1px solid #ddd; + color: #333; + display: block; + float: left; + height: 25px; + overflow: hidden; + margin: 0 0.5em 0 0; + /* text-indent: -5000px; */ + text-shadow: 0 1px 0 #fff; + width: 25px; + + border-radius: 0.3em; + -moz-border-radius: 0.3em; + -webkit-border-radius: 0.3em; + + filter:progid:DXImageTransform.Microsoft.gradient(GradientType=0, startColorstr='#f4f4f4', endColorstr='#ececec'); + background: -webkit-gradient(linear, left top, left bottom, from(#f4f4f4), to(#ececec)); + background: -moz-linear-gradient(top, #f4f4f4, #ececec); +} + +#gollum-editor #gollum-editor-function-bar a.function-button:hover { + color: #fff; + text-shadow: 0 -1px 0 rgba(0, 0, 0, 0.3); + text-decoration: none; + + filter:progid:DXImageTransform.Microsoft.gradient(GradientType=0, startColorstr='#599bdc', endColorstr='#3072b3'); + background: -webkit-gradient(linear, left top, left bottom, from(#599bdc), to(#3072b3)); + background: -moz-linear-gradient(top, #599bdc, #3072b3); +} + +#gollum-editor #gollum-editor-function-bar span.function-divider { + display: block; + float: left; + width: 0.5em; +} + + +/* @section form-fields */ + +#gollum-editor textarea#gollum-editor-body { + background: #fff; + border: 1px solid #ddd; + font-size: 1.3em; + font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif; + line-height: 1.8em; + margin: 0.5em 0; + padding: 0.5em; /* I don't really like mixing pct & em here… */ + width: 98%; + height: 20em; +} + +#gollum-editor input#gollum-editor-submit { + background-color: #f7f7f7; + border: 1px solid #d4d4d4; + color: #333; + cursor: pointer; + display: block; + font-size: 1.2em; + font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif; + font-weight: bold; + margin: 0; + padding: 0.4em 1em; + + text-shadow: 0 1px 0 #fff; + + filter:progid:DXImageTransform.Microsoft.gradient(GradientType=0, startColorstr='#f4f4f4', endColorstr='#ececec'); + background: -webkit-gradient(linear, left top, left bottom, from(#f4f4f4), to(#ececec)); + background: -moz-linear-gradient(top, #f4f4f4, #ececec); + + border-radius: 3px; + -moz-border-radius: 3px; + -webkit-border-radius: 3px; +} + +#gollum-editor input#gollum-editor-submit:hover { + background: #3072b3; + border-color: #518cc6 #518cc6 #2a65a0; + color: #fff; + text-shadow: 0 -1px 0 rgba(0, 0, 0, 0.3); + text-decoration: none; + + filter:progid:DXImageTransform.Microsoft.gradient(GradientType=0, startColorstr='#599bdc', endColorstr='#3072b3'); + background: -webkit-gradient(linear, left top, left bottom, from(#599bdc), to(#3072b3)); + background: -moz-linear-gradient(top, #599bdc, #3072b3); +} \ No newline at end of file diff --git a/scratch/css/gollum.css b/scratch/css/gollum.css index d22f9535..b8b14894 100644 --- a/scratch/css/gollum.css +++ b/scratch/css/gollum.css @@ -343,6 +343,18 @@ a:hover, a:visited { } +/* @section edit */ +.edit h1 { + color: #999; + font-weight: normal; +} + + .edit h1 strong { + color: #000; + font-weight: bold; + } + + /* @control minibutton */ ul.actions { diff --git a/scratch/edit.html b/scratch/edit.html index 7641ad7f..a22342ef 100644 --- a/scratch/edit.html +++ b/scratch/edit.html @@ -21,15 +21,6 @@
-
-
- -

- +
diff --git a/scratch/js/gollum-editor/gollum.editor.js b/scratch/js/gollum-editor/gollum.editor.js index 3cf77c3e..b2201342 100644 --- a/scratch/js/gollum-editor/gollum.editor.js +++ b/scratch/js/gollum-editor/gollum.editor.js @@ -60,7 +60,6 @@ // EditorHas.functionBar } // EditorHas.baseEditorMarkup - }; @@ -88,7 +87,8 @@ * @return void */ var debug = function(m) { - if ( ActiveOptions.Debug && console + if ( ActiveOptions.Debug + && typeof console != 'undefined' && typeof console.log == 'function' ) { console.log( m ); } diff --git a/scratch/js/gollum-editor/langs/markdown.js b/scratch/js/gollum-editor/langs/markdown.js index 1e113962..0f734997 100644 --- a/scratch/js/gollum-editor/langs/markdown.js +++ b/scratch/js/gollum-editor/langs/markdown.js @@ -39,12 +39,58 @@ var MarkDown = { append: "\n***\n" }, - 'function-ul' : { + 'function-ul' : { search: /(.+)([\n]?)/gi, replace: "* $1$2" + }, + + /* This looks silly but is completely valid Markdown */ + 'function-ol' : { + search: /(.+)([\n]?)/gi, + replace: "1. $1$2" + }, + + 'function-blockquote' : { + search: /(.+)([\n]?)/gi, + replace: "> $1$2" + }, + + 'function-link' : { + exec: function( txt, selText, $field ) { + var results = null; + res = $.GollumEditor.Dialog({ + title: '', + fields: [ + { + id: 'text', + name: 'Link Text', + type: 'text', + help: 'The text to display to the user.' + }, + { + id: 'href', + name: 'URL', + type: 'text', + help: 'The URL to link to.' + } + ] + }); + + if ( res['text'] && res['href'] ) { + return '[' + res['text'] + '](' + + res['href'] + ')'; + } + else + return ''; + } + }, + + 'function-image' : { + /* Stub */ } - + }; + // this is necessary for GollumEditor to pick this up jQuery.GollumEditor.defineLanguage('markdown', MarkDown); \ No newline at end of file From 6c76ba20a2fe7aacc11d563ca9a7c8836fa7ce19 Mon Sep 17 00:00:00 2001 From: Eston Bond Date: Mon, 1 Nov 2010 18:52:28 -0700 Subject: [PATCH 18/37] keep things event-driven --- scratch/js/gollum-editor/gollum.editor.js | 25 +++++++++++++++++++++- scratch/js/gollum-editor/langs/markdown.js | 19 +++++++++------- 2 files changed, 35 insertions(+), 9 deletions(-) diff --git a/scratch/js/gollum-editor/gollum.editor.js b/scratch/js/gollum-editor/gollum.editor.js index b2201342..e3ee688a 100644 --- a/scratch/js/gollum-editor/gollum.editor.js +++ b/scratch/js/gollum-editor/gollum.editor.js @@ -79,6 +79,17 @@ + /** + * $.GollumEditor.Dialog + * Used in exec() to display dialogs with dynamic fields. + * + */ + $.GollumEditor.Dialog = function( argObject ) { + return Dialog.init( argObject ); + }; + + + /** * debug * Prints debug information to console.log if debug output is enabled. @@ -385,14 +396,26 @@ $field.val( fullStr.substring(0, selPos.start) + replaceText + fullStr.substring(selPos.end)); + $field[0].focus(); if ( selectNew && $field[0].setSelectionRange ) { - $field[0].focus(); $field[0].setSelectionRange( selPos.start, selPos.start + replaceText.length ); } } }; + + + + /** + * Dialog + * Used by FunctionBar & internally to display editor-specific messages, + * inputs and more. + * + */ + var Dialog = { + //TODO + }; })(jQuery); diff --git a/scratch/js/gollum-editor/langs/markdown.js b/scratch/js/gollum-editor/langs/markdown.js index 0f734997..9cc460f0 100644 --- a/scratch/js/gollum-editor/langs/markdown.js +++ b/scratch/js/gollum-editor/langs/markdown.js @@ -58,7 +58,7 @@ var MarkDown = { 'function-link' : { exec: function( txt, selText, $field ) { var results = null; - res = $.GollumEditor.Dialog({ + $.GollumEditor.Dialog({ title: '', fields: [ { @@ -73,15 +73,18 @@ var MarkDown = { type: 'text', help: 'The URL to link to.' } - ] + ], + OK: function( res ) { + if ( res['text'] && res['href'] ) { + return '[' + res['text'] + '](' + + res['href'] + ')'; + } + else + return ''; + } }); - if ( res['text'] && res['href'] ) { - return '[' + res['text'] + '](' - + res['href'] + ')'; - } - else - return ''; + } }, From 9ffa79e44e24959652cbcd3c587bd35d4576ec31 Mon Sep 17 00:00:00 2001 From: Eston Bond Date: Tue, 2 Nov 2010 16:37:46 -0700 Subject: [PATCH 19/37] Adding this before my battery dies --- scratch/js/gollum-editor/gollum.editor.js | 49 ++++++++++++++++++++++- 1 file changed, 47 insertions(+), 2 deletions(-) diff --git a/scratch/js/gollum-editor/gollum.editor.js b/scratch/js/gollum-editor/gollum.editor.js index e3ee688a..9caab8b3 100644 --- a/scratch/js/gollum-editor/gollum.editor.js +++ b/scratch/js/gollum-editor/gollum.editor.js @@ -85,7 +85,7 @@ * */ $.GollumEditor.Dialog = function( argObject ) { - return Dialog.init( argObject ); + Dialog.init( argObject ); }; @@ -414,7 +414,52 @@ * */ var Dialog = { - //TODO + + markupCreated = false, + + createMarkup: function( title, body ) { + return '
' + + '

' + title + '

' + + '
' + body + '
' + '
' + + 'OK' + + '' + + 'Cancel' + + '
'; + }, + + hide: function() { + $('#gollum-editor-dialog') + }, + + init: function( argObject ) { + + }, + + show: function( title, body ) { + if ( Dialog.markupCreated ) { + $('#gollum-editor-dialog').remove(); + } + var $dialog = $( Dialog.createMarkup( title, body ) ); + $('body').append( $dialog ); + Dialog.position(); // position this thing + Dialog.attachEvents(); + $('#gollum-editor-dialog').animate({ opacity: 0 }, { + duration: 1, + complete: function() { + $('#gollum-editor-dialog').addClass('active'); + $('#gollum-editor-dialog').animate({ opacity: 100 }, { + duration: 700 + }); + } + }); + + }, + + position: function() { + + } + }; })(jQuery); From 742ca5e6dce3ce67325ff976fe25ba57b56dd02e Mon Sep 17 00:00:00 2001 From: Eston Bond Date: Wed, 3 Nov 2010 14:51:33 -0700 Subject: [PATCH 20/37] Adding creole & asciidoc --- scratch/js/gollum-editor/gollum.editor.js | 90 ++++++++++++----- scratch/js/gollum-editor/langs/asciidoc.js | 108 +++++++++++++++++++++ scratch/js/gollum-editor/langs/creole.js | 107 ++++++++++++++++++++ scratch/js/gollum-editor/langs/markdown.js | 33 ++++++- 4 files changed, 312 insertions(+), 26 deletions(-) create mode 100644 scratch/js/gollum-editor/langs/asciidoc.js create mode 100644 scratch/js/gollum-editor/langs/creole.js diff --git a/scratch/js/gollum-editor/gollum.editor.js b/scratch/js/gollum-editor/gollum.editor.js index 9caab8b3..c1a78335 100644 --- a/scratch/js/gollum-editor/gollum.editor.js +++ b/scratch/js/gollum-editor/gollum.editor.js @@ -84,9 +84,7 @@ * Used in exec() to display dialogs with dynamic fields. * */ - $.GollumEditor.Dialog = function( argObject ) { - Dialog.init( argObject ); - }; + $.GollumEditor.Dialog = Dialog; @@ -329,7 +327,6 @@ reselect = false; } repText += definitionObject.append; - } if (repText) @@ -394,6 +391,11 @@ var selectNew = false; } + var scrollTop = null; + if ( $field[0].scrollTop ) { + scrollTop = $field[0].scrollTop; + } + $field.val( fullStr.substring(0, selPos.start) + replaceText + fullStr.substring(selPos.end)); $field[0].focus(); @@ -402,6 +404,11 @@ $field[0].setSelectionRange( selPos.start, selPos.start + replaceText.length ); } + + if ( scrollTop ) { + // this jumps sometimes in FF + $field[0].scrollTop = scrollTop; + } } }; @@ -417,7 +424,13 @@ markupCreated = false, + attachEvents: function( evtOK ) { + $('#gollum-editor-action-ok').click( Dialog.eventOK( evtOK ) ); + $('#gollum-editor-action-cancel').click( Dialog.eventCancel ); + }, + createMarkup: function( title, body ) { + Dialog.markupCreated = true; return '
' + '

' + title + '

' + '
' + body + '
' @@ -428,32 +441,63 @@ '
'; }, + eventCancel: function() { + Dialog.hide(); + }, + + eventOK: function( evtOK ) { + var results = {}; + + // pass them to evtOK if it exists (which it should) + if ( evtOK && + typeof evtOK == 'function' ) { + evtOK( results ); + } + }, + hide: function() { - $('#gollum-editor-dialog') + $('#gollum-editor-dialog').animate({ opacity: 0 }, { + duration: 700 + complete: function() { + $('#gollum-editor-dialog').removeClass('active'); + } + }); }, init: function( argObject ) { + var title = ''; + var body = ''; + // bail out if necessary + if ( !argObject || + typeof argObject != 'object' ) { + debug('Editor Dialog: Cannot init; invalid init object'); + return; + } + + if ( Dialog.markupCreated ) { + $('#gollum-editor-dialog').remove(); + } + var $dialog = $( Dialog.createMarkup( title, body ) ); + $('body').append( $dialog ); + Dialog.attachEvents( evtOK ); }, - show: function( title, body ) { - if ( Dialog.markupCreated ) { - $('#gollum-editor-dialog').remove(); - } - var $dialog = $( Dialog.createMarkup( title, body ) ); - $('body').append( $dialog ); - Dialog.position(); // position this thing - Dialog.attachEvents(); - $('#gollum-editor-dialog').animate({ opacity: 0 }, { - duration: 1, - complete: function() { - $('#gollum-editor-dialog').addClass('active'); - $('#gollum-editor-dialog').animate({ opacity: 100 }, { - duration: 700 - }); - } - }); - + show: function() { + if ( !Dialog.markupCreated ) { + debug('Dialog: No markup to show. Please use init first.') + } else { + Dialog.position(); // position this thing + $('#gollum-editor-dialog').animate({ opacity: 0 }, { + duration: 1, + complete: function() { + $('#gollum-editor-dialog').addClass('active'); + $('#gollum-editor-dialog').animate({ opacity: 100 }, { + duration: 700 + }); + } + }); + } }, position: function() { diff --git a/scratch/js/gollum-editor/langs/asciidoc.js b/scratch/js/gollum-editor/langs/asciidoc.js new file mode 100644 index 00000000..03a9c729 --- /dev/null +++ b/scratch/js/gollum-editor/langs/asciidoc.js @@ -0,0 +1,108 @@ +/** + * ASCIIDoc Language Definition + * + */ + +(function() { + +var ASCIIDoc = { + + 'function-bold' : { + search: /([^\n]+)([\n]*)/gi, + replace: "*$1*$2" + }, + + 'function-italic' : { + search: /([^\n]+)([\n]*)/gi, + replace: "_$1_$2" + }, + + 'function-code' : { + search: /([^\n]+)([\n]*)/gi, + replace: "+$1+$2" + }, + + 'function-ul' : { + search: /(.+)([\n]?)/gi, + replace: "* $1$2" + }, + + /* This looks silly but is completely valid Markdown */ + 'function-ol' : { + search: /(.+)([\n]?)/gi, + replace: ". $1$2" + }, + + 'function-blockquote' : { + search: /(.+)([\n]?)/gi, + replace: "----\n$1$2\n----\n" + }, + + 'function-link' : { + exec: function( txt, selText, $field ) { + var results = null; + $.GollumEditor.Dialog({ + title: 'Insert Link', + fields: [ + { + id: 'text', + name: 'Link Text', + type: 'text', + help: 'The text to display to the user.' + }, + { + id: 'href', + name: 'URL', + type: 'text', + help: 'The URL to link to.' + } + ], + OK: function( res ) { + if ( res['text'] && res['href'] ) { + return res['href'] + '[' + + res['text'] + ']'; + } + else + return ''; + } + }); + + + } + }, + + 'function-image' : { + exec: function( txt, selText, $field ) { + var results = null; + $.GollumEditor.Dialog.init({ + title: 'Insert Image', + fields: [ + { + id: 'url', + name: 'Image URL', + type: 'text' + }, + { + id: 'alt', + name: 'Alt Text', + type: 'text' + } + ], + OK: function( res ) { + if ( res['url'] && res['alt'] ) { + return 'image::' + res['url'] + + '[' + res['alt'] + ']'; + } else + return ''; + } + }); + } + } + +}; + + +// this is necessary for GollumEditor to pick this up +jQuery.GollumEditor.defineLanguage('markdown', ASCIIDoc); + +})(); diff --git a/scratch/js/gollum-editor/langs/creole.js b/scratch/js/gollum-editor/langs/creole.js new file mode 100644 index 00000000..3f0e7c57 --- /dev/null +++ b/scratch/js/gollum-editor/langs/creole.js @@ -0,0 +1,107 @@ +/** + * Creole Language Definition + * + */ +(function() { + +var Creole = { + + 'function-bold' : { + search: /([^\n]+)([\n]*)/gi, + replace: "**$1**$2" + }, + + 'function-italic' : { + search: /([^\n]+)([\n]*)/gi, + replace: "//$1//$2" + }, + + 'function-code' : { + search: /([^\n]+)([\n]*)/gi, + replace: "{{{$1}}}$2" + }, + + 'function-hr' : { + append: "\n\n----\n\n"; + }, + + 'function-ul' : { + search: /(.+)([\n]?)/gi, + replace: "* $1$2" + }, + + /* This looks silly but is completely valid Markdown */ + 'function-ol' : { + search: /(.+)([\n]?)/gi, + replace: "# $1$2" + }, + + 'function-link' : { + exec: function( txt, selText, $field ) { + var results = null; + $.GollumEditor.Dialog({ + title: 'Insert Link', + fields: [ + { + id: 'text', + name: 'Link Text', + type: 'text', + help: 'The text to display to the user.' + }, + { + id: 'href', + name: 'URL', + type: 'text', + help: 'The URL to link to.' + } + ], + OK: function( res ) { + if ( res['text'] && res['href'] ) { + return '[[' + res['href'] + '|' + + res['text'] + ']]'; + } + else + return ''; + } + }); + + + } + }, + + 'function-image' : { + exec: function( txt, selText, $field ) { + var results = null; + $.GollumEditor.Dialog.init({ + title: 'Insert Image', + fields: [ + { + id: 'url', + name: 'Image URL', + type: 'text' + }, + { + id: 'alt', + name: 'Alt Text', + type: 'text' + } + ], + OK: function( res ) { + if ( res['url'] && res['alt'] ) { + var h = '{{' + res['url']; + if ( res['alt'] != '' ) { + h += '|' + res['alt'] + '}}'; + } + return h; + } else + return ''; + } + }); + } + } + +}; + +jQuery.GollumEditor.defineLanguage('creole', Creole); + +})(); \ No newline at end of file diff --git a/scratch/js/gollum-editor/langs/markdown.js b/scratch/js/gollum-editor/langs/markdown.js index 9cc460f0..d2500db9 100644 --- a/scratch/js/gollum-editor/langs/markdown.js +++ b/scratch/js/gollum-editor/langs/markdown.js @@ -17,6 +17,7 @@ * } * **/ +(function() { var MarkDown = { @@ -59,7 +60,7 @@ var MarkDown = { exec: function( txt, selText, $field ) { var results = null; $.GollumEditor.Dialog({ - title: '', + title: 'Insert Link', fields: [ { id: 'text', @@ -89,11 +90,37 @@ var MarkDown = { }, 'function-image' : { - /* Stub */ + exec: function( txt, selText, $field ) { + var results = null; + $.GollumEditor.Dialog.init({ + title: 'Insert Image', + fields: [ + { + id: 'url', + name: 'Image URL', + type: 'text' + }, + { + id: 'alt', + name: 'Alt Text', + type: 'text' + } + ], + OK: function( res ) { + if ( res['url'] && res['alt'] ) { + return '![' + res['alt'] + ']' + + '(' + res['url'] + ')'; + } else + return ''; + } + }); + } } }; // this is necessary for GollumEditor to pick this up -jQuery.GollumEditor.defineLanguage('markdown', MarkDown); \ No newline at end of file +jQuery.GollumEditor.defineLanguage('markdown', MarkDown); + +})(); From 649393eb6e2ab7d6b125c9a72ec15fc1cecf0ea9 Mon Sep 17 00:00:00 2001 From: Eston Bond Date: Wed, 3 Nov 2010 14:52:02 -0700 Subject: [PATCH 21/37] Don't need this plugin anymore --- scratch/js/jquery.fieldselection.js | 83 ----------------------------- 1 file changed, 83 deletions(-) delete mode 100644 scratch/js/jquery.fieldselection.js diff --git a/scratch/js/jquery.fieldselection.js b/scratch/js/jquery.fieldselection.js deleted file mode 100644 index 92fb6562..00000000 --- a/scratch/js/jquery.fieldselection.js +++ /dev/null @@ -1,83 +0,0 @@ -/* - * jQuery plugin: fieldSelection - v0.1.0 - last change: 2006-12-16 - * (c) 2006 Alex Brem - http://blog.0xab.cd - */ - -(function() { - - var fieldSelection = { - - getSelection: function() { - - var e = this.jquery ? this[0] : this; - - return ( - - /* mozilla / dom 3.0 */ - ('selectionStart' in e && function() { - var l = e.selectionEnd - e.selectionStart; - return { start: e.selectionStart, end: e.selectionEnd, length: l, text: e.value.substr(e.selectionStart, l) }; - }) || - - /* exploder */ - (document.selection && function() { - - e.focus(); - - var r = document.selection.createRange(); - if (r == null) { - return { start: 0, end: e.value.length, length: 0 } - } - - var re = e.createTextRange(); - var rc = re.duplicate(); - re.moveToBookmark(r.getBookmark()); - rc.setEndPoint('EndToStart', re); - - return { start: rc.text.length, end: rc.text.length + r.text.length, length: r.text.length, text: r.text }; - }) || - - /* browser not supported */ - function() { - return { start: 0, end: e.value.length, length: 0 }; - } - - )(); - - }, - - replaceSelection: function() { - - var e = this.jquery ? this[0] : this; - var text = arguments[0] || ''; - - return ( - - /* mozilla / dom 3.0 */ - ('selectionStart' in e && function() { - e.value = e.value.substr(0, e.selectionStart) + text + e.value.substr(e.selectionEnd, e.value.length); - return this; - }) || - - /* exploder */ - (document.selection && function() { - e.focus(); - document.selection.createRange().text = text; - return this; - }) || - - /* browser not supported */ - function() { - e.value += text; - return this; - } - - )(); - - } - - }; - - jQuery.each(fieldSelection, function(i) { jQuery.fn[i] = this; }); - -})(); \ No newline at end of file From 8645927cbcf2e8119ffd93c57f9fa266896ca476 Mon Sep 17 00:00:00 2001 From: Eston Bond Date: Wed, 3 Nov 2010 15:00:20 -0700 Subject: [PATCH 22/37] Adding textile definition --- scratch/TODO | 15 ++- scratch/js/gollum-editor/langs/textile.js | 111 ++++++++++++++++++++++ 2 files changed, 121 insertions(+), 5 deletions(-) create mode 100644 scratch/js/gollum-editor/langs/textile.js diff --git a/scratch/TODO b/scratch/TODO index 742577df..553a390e 100644 --- a/scratch/TODO +++ b/scratch/TODO @@ -1,5 +1,10 @@ -Create Common Layout -Create Basic CSS -Create View Page -Create History Page -Create Edit Page \ No newline at end of file +Gollum Editor + - Style / Generate dialogs + - Dynamically show/hide different function bar buttons based on active language capabilities + - Def: Org + - Def: Pod + - Def: RDoc + - Def: Restructured Text + +Make function bar button sprite +Roll scratch/ design into Mustache \ No newline at end of file diff --git a/scratch/js/gollum-editor/langs/textile.js b/scratch/js/gollum-editor/langs/textile.js new file mode 100644 index 00000000..961ad247 --- /dev/null +++ b/scratch/js/gollum-editor/langs/textile.js @@ -0,0 +1,111 @@ +/** + * Textile Language Definition + */ +(function() { + +var Textile = { + + 'function-bold' : { + search: /([^\n]+)([\n]*)/gi, + replace: "*$1*$2" + }, + + 'function-italic' : { + search: /([^\n]+)([\n]*)/gi, + replace: "_$1_$2" + }, + + 'function-hr' : { + append: "\n***\n" + }, + + 'function-code' : { + search: /([^\n]+)([\n]*)/gi, + replace: "
$1
$2" + }, + + 'function-ul' : { + search: /(.+)([\n]?)/gi, + replace: "* $1$2" + }, + + /* This looks silly but is completely valid Markdown */ + 'function-ol' : { + search: /(.+)([\n]?)/gi, + replace: "# $1$2" + }, + + 'function-blockquote' : { + search: /(.+)([\n]?)/gi, + replace: "bq. $1$2" + }, + + 'function-link' : { + exec: function( txt, selText, $field ) { + var results = null; + $.GollumEditor.Dialog({ + title: 'Insert Link', + fields: [ + { + id: 'text', + name: 'Link Text', + type: 'text', + help: 'The text to display to the user.' + }, + { + id: 'href', + name: 'URL', + type: 'text', + help: 'The URL to link to.' + } + ], + OK: function( res ) { + if ( res['text'] && res['href'] ) { + return '"' + res['text'] + '":' + + res['href']; + } + else + return ''; + } + }); + + + } + }, + + 'function-image' : { + exec: function( txt, selText, $field ) { + var results = null; + $.GollumEditor.Dialog.init({ + title: 'Insert Image', + fields: [ + { + id: 'url', + name: 'Image URL', + type: 'text' + }, + { + id: 'alt', + name: 'Alt Text', + type: 'text' + } + ], + OK: function( res ) { + if ( res['url'] ) { + var h = '!' + res['url']; + if ( res['alt'] != '' ) { + h += '(' + res['alt'] + ')'; + } + h += '!'; + return h; + } + } + }); + } + } + +}; + +jQuery.GollumEditor.defineLanguage('markdown', Textile); + +})(); From 338c51e0194a32d9e1cfd385ab96ea2f8d531325 Mon Sep 17 00:00:00 2001 From: Eston Bond Date: Wed, 3 Nov 2010 15:18:52 -0700 Subject: [PATCH 23/37] Egregious bugs --- scratch/TODO | 1 - scratch/css/editor.css | 4 ++++ scratch/edit.html | 8 -------- scratch/js/gollum-editor/gollum.editor.js | 18 ++++++++++++------ scratch/js/gollum-editor/langs/asciidoc.js | 2 +- scratch/js/gollum-editor/langs/markdown.js | 2 +- scratch/js/gollum-editor/langs/textile.js | 2 +- 7 files changed, 19 insertions(+), 18 deletions(-) diff --git a/scratch/TODO b/scratch/TODO index 553a390e..4c9a20ad 100644 --- a/scratch/TODO +++ b/scratch/TODO @@ -1,6 +1,5 @@ Gollum Editor - Style / Generate dialogs - - Dynamically show/hide different function bar buttons based on active language capabilities - Def: Org - Def: Pod - Def: RDoc diff --git a/scratch/css/editor.css b/scratch/css/editor.css index 1dfeb239..b5f0d329 100644 --- a/scratch/css/editor.css +++ b/scratch/css/editor.css @@ -71,6 +71,10 @@ background: -moz-linear-gradient(top, #599bdc, #3072b3); } +#gollum-editor #gollum-editor-function-bar a.disabled { + display: none; +} + #gollum-editor #gollum-editor-function-bar span.function-divider { display: block; float: left; diff --git a/scratch/edit.html b/scratch/edit.html index 0bc8f0ed..870e1307 100644 --- a/scratch/edit.html +++ b/scratch/edit.html @@ -41,14 +41,6 @@   Link Image - -
- -
-
-
-
-

Loading content...

-
- - - - -
- -
- - +
+ +
+
+ {{>editor}} +
+
\ No newline at end of file diff --git a/lib/gollum/frontend/templates/edit.mustache b/lib/gollum/frontend/templates/edit.mustache index 0c855c62..d447aeaf 100644 --- a/lib/gollum/frontend/templates/edit.mustache +++ b/lib/gollum/frontend/templates/edit.mustache @@ -1,38 +1,16 @@ -
- « Back -

{{title}}

- -
-
- -
- -
- -
- {{>editbar}} -
- -
-
-
-

Loading content...

-
-
- - -
- -
-
-
+
+ +
+
+ {{>editor}} +
+
\ No newline at end of file diff --git a/lib/gollum/frontend/templates/editbar.mustache b/lib/gollum/frontend/templates/editbar.mustache deleted file mode 100644 index 94fd61d0..00000000 --- a/lib/gollum/frontend/templates/editbar.mustache +++ /dev/null @@ -1,1196 +0,0 @@ -
- -
-
-
Headers
- -
Images
-
Code
-
Formatting
-
Lists
-
Math
-
-
- - - - - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
DescriptionWhat you typeWhat you get
Basic internal image -
[[/images/example.png]]
-
- -
Basic external image -
[[http://example.com/example.png]]
-
- -
Image with alt text -
[[/example.png|alt=Shapes]]
-
- Shapes -
Image with frame and caption -
[[/example.png|frame|alt=Shapes]]
-
-
ShapesShapes
-
Image with specific width -
[[/example.png|width=40px]]
-
- -
Image with specific height -
[[/example.png|height=40px]]
-
- -
Image aligned left -
The quick brown fox jumps.
-
 
-
[[/example.png|align=left]]
-
-
-

The quick brown fox jumps.

-

Shapes

-
-
Image aligned center -
The quick brown fox jumps.
-
 
-
[[/example.png|align=center]]
-
-
-

The quick brown fox jumps.

-

Shapes

-
-
Image aligned right -
The quick brown fox jumps.
-
 
-
[[/example.png|align=right]]
-
-
-

The quick brown fox jumps.

-

Shapes

-
-
Image floated left -
The quick brown fox jumps
-[[/example.png|float|align=left]]
-over the lazy dog and feels as
-if he were in seventh heaven.
-
-
-

The quick brown fox jumps Shapes over the lazy dog and feels as if he were in seventh heaven.

-
-
Image floated left -
The quick brown fox jumps
-[[/example.png|float|align=right]]
-over the lazy dog and feels as
-if he were in seventh heaven.
-
-
-

The quick brown fox jumps Shapes over the lazy dog and feels as if he were in seventh heaven.

-
-
-
- - - -
- - - - - - - - - - - -
DescriptionWhat you typeWhat you get
Hilighted Code block
```ruby
-def foo
-puts 'bar'
-end
-```
def foo
-  puts 'bar'
-end
-
-
- - - - - - - - -
Language Identifiers for use in Hilighted Code Blocks
-
    -
  • ABAP: abap
  • -
  • ActionScript: as, actionscript
  • -
  • ActionScript 3: as3, actionscript3
  • -
  • Ada: ada, ada95ada2005
  • -
  • ANTLR: antlr
  • -
  • ANTLR With ActionScript Target: antlr-as, antlr-actionscript
  • -
  • ANTLR With C# Target: antlr-csharp, antlr-c#
  • -
  • ANTLR With CPP Target: antlr-cpp
  • -
  • ANTLR With Java Target: antlr-java
  • -
  • ANTLR With ObjectiveC Target: antlr-objc
  • -
  • ANTLR With Perl Target: antlr-perl
  • -
  • ANTLR With Python Target: antlr-python
  • -
  • ANTLR With Ruby Target: antlr-ruby, antlr-rb
  • -
  • ApacheConf: apacheconf, aconf, apache
  • -
  • AppleScript: applescript
  • -
  • aspx-cs: aspx-cs
  • -
  • aspx-vb: aspx-vb
  • -
  • Asymptote: asy, asymptote
  • -
  • Bash: bash, sh, ksh
  • -
  • Bash Session: console
  • -
  • Batchfile: bat
  • -
  • BBCode: bbcode
  • -
  • Befunge: befunge
  • -
  • Boo: boo
  • -
  • Brainfuck: brainfuck, bf
  • -
  • C: c
  • -
  • C#: csharp, c#
  • -
  • C++: cpp, c++
  • -
  • c-objdump: c-objdump
  • -
  • cfstatement: cfs
  • -
  • Cheetah: cheetah, spitfire
  • -
  • Clojure: clojure, clj
  • -
  • CMake: cmake
  • -
  • CoffeeScript: coffee-script, coffeescript
  • -
  • Coldufsion HTML: cfm
  • -
  • Common Lisp: common-lisp, cl
  • -
  • cpp-objdump: cpp-objdump, c++-objdumb, cxx-objdump
  • -
  • CSS: css
  • -
  • CSS+Django/Jinja: css+django, css+jinja
  • -
  • CSS+Genshi Text: css+genshitext, css+genshi
  • -
  • CSS+Mako: css+mako
  • -
  • CSS+Myghty: css+myghty
  • -
  • CSS+PHP: css+php
  • -
  • CSS+Ruby: css+erb, css+ruby
  • -
  • CSS+Smarty: css+smarty
  • -
  • Cython: cython, pyx
  • -
  • D: d
  • -
  • d-objdump: d-objdump
  • -
  • Darcs Patch: dpatch
  • -
  • Debian Control file: control
  • -
  • Debian Sourcelist: sourceslist, sources.list
  • -
  • Delphi: delphi, pas, pascal, objectpascal
  • -
  • Diff: diff, udiff
  • -
  • Django/Jinja: django, jinja
  • -
  • Dylan: dylan
  • -
  • Embedded Ragel: ragel-em
  • -
  • ERB: erb
  • -
  • Erlang: erlang
  • -
  • Erlang erl session: erl
  • -
  • Evoque: evoque
  • -
  • Felix: felix, flx
  • -
  • Fortran: fortran
  • -
  • GAS: gas
  • -
  • Genshi: genshi, kid, xml+genshi, xml+kid
  • -
  • Genshi Text: genshitext
  • -
  • Gettext Catalog: pot, po
  • -
  • Gherkin: Cucumber, cucumber, Gherkin, gherkin
  • -
  • GLSL: glsl
  • -
  • Gnuplot: gnuplot
  • -
  • Go: go
  • -
  • Groff: groff, nroff, man
  • -
  • Haml: haml, HAML
  • -
  • Haskell: haskell, hs
  • -
  • haXe: hx, haXe
  • -
  • HTML: html
  • -
  • HTML+Cheetah: html+cheetah, html+spitfire
  • -
  • HTML+Django/Jinja: html+django, html+jinja
  • -
  • HTML+Evoque: html+evoque
  • -
  • HTML+Genshi: html+genshi, html+kid
  • -
  • HTML+Mako: html+mako
  • -
  • HTML+Myghty: html+myghty
  • -
  • HTML+PHP: html+php
  • -
  • HTML+Smarty: html+smarty
  • -
  • INI: ini, cfg
  • -
-
-
    -
  • Io: io
  • -
  • IRC logs: irc
  • -
  • Java: java
  • -
  • Java Server Page: jsp
  • -
  • JavaScript: js, javascript
  • -
  • Lighttpd configuration file: lighty, lighttpd
  • -
  • Literate Haskell: lhs, literate-haskell
  • -
  • LLVM: llvm
  • -
  • Logtalk: logtalk
  • -
  • Lua: lua
  • -
  • Makefile: make, makefile, mf, bsdmake
  • -
  • Makefile: basemake
  • -
  • Mako: mako
  • -
  • Matlab: matlab, octave
  • -
  • Matlab session: matlabsession
  • -
  • MiniD: minid
  • -
  • Modelica: modelica
  • -
  • Modula-2: modula2, m2
  • -
  • MoinMoin/Trac Wiki markup: trac-wiki, moin
  • -
  • MOOCode: moocode
  • -
  • MuPAD: mupad
  • -
  • MXML: mxml
  • -
  • Myghty: myghty
  • -
  • MySQL: mysql
  • -
  • NASM: nasm
  • -
  • Newspeak: newspeak
  • -
  • Nginx configuration file: nginx
  • -
  • NumPy: numpy
  • -
  • objdump: objdump
  • -
  • Objective-C: objective-c, objectivec, obj-c, objc
  • -
  • Objective-J: objective-j, objectivej, obj-j, objj
  • -
  • OCaml: ocaml
  • -
  • Ooc: ooc
  • -
  • Perl: perl, pl
  • -
  • PHP: php, php3, php4, php5
  • -
  • POVRay: pov
  • -
  • Prolog: prolog
  • -
  • Python: python, py
  • -
  • Python 3: python3, py3
  • -
  • Python 3.0 Traceback: py3tb
  • -
  • Python console session: pycon
  • -
  • Python Traceback: pytb
  • -
  • Ragel: ragel
  • -
  • Ragel in C Host: ragel-c
  • -
  • Ragel in CPP Host: ragel-cpp
  • -
  • Ragel in D Host: ragel-d
  • -
  • Ragel in Java Host: ragel-java
  • -
  • Ragel in Objective C Host: ragel-objc
  • -
  • Ragel in Ruby Host: ragel-ruby, ragel-rb
  • -
  • Raw token data: raw
  • -
  • RConsole: rconsole, rout
  • -
  • REBOL: rebol
  • -
  • Redcode: redcode
  • -
  • reStructuredText: rst, rest, restructuredtext
  • -
  • RHTML: rhtml, html+erb, html+ruby
  • -
  • Ruby: rb, ruby
  • -
  • Ruby irb session: rbcon, irb
  • -
  • S: splus, s, r
  • -
  • Sass: sass, SASS
  • -
  • Scala: scala
  • -
  • Scheme: scheme, scm
  • -
  • Smalltalk: smalltalk, squeak
  • -
  • Smarty: smarty
  • -
  • SQL: sql
  • -
  • sqlite3con: sqlite3
  • -
  • SquidConf: squidconf, squid.conf, squid
  • -
  • Tcl: tcl
  • -
  • Tcsh: tcsh, csh
  • -
  • TeX: tex, latex
  • -
  • Text only: text
  • -
  • Vala: vala, vapi
  • -
  • VB.net: vb.net, vbnet
  • -
  • VimL: vim
  • -
  • XML: xml
  • -
  • XML+Cheetah: xml+cheetah, xml+spitfire
  • -
  • XML+Django/Jinja: xml+django, xml+jinja
  • -
  • XML+Evoque: xml+evoque
  • -
  • XML+Mako: xml+mako
  • -
  • XML+Myghty: xml+myghty
  • -
  • XML+PHP: xml+php
  • -
  • XML+Ruby: xml+erb, xml+ruby
  • -
  • XML+Smarty: xml+smarty
  • -
  • XSLT: xslt
  • -
  • YAML: yaml
  • -
-
-
- - - - - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
DescriptionWhat you typeWhat you get
Bold
*bold text*
bold text
Italic
_italic text_
italic text
Monospace
+monospace text+
monospace text
Single quoted
`single quoted text'
ā€˜single quoted text’
Double quoted
``double quoted text''
ā€œdouble quoted textā€
Superscript
x^2^
x2
Subscript
H~2~O
H2O
-
- - - -
- - - - - - - - - - - - - - - - - - - - - -
DescriptionWhat you typeWhat you get
Bold
**bold text**
bold text
Italic
//italic text//
italic text
Monospace
{{{monospace text}}}
monospace text
-
- - - -
- - - - - - - - - - - - - - - - - - - - - -
DescriptionWhat you typeWhat you get
Bold
**bold text**
bold text
Italic
*italic text*
italic text
Inline code
`inline code`
inline code
-
- - - -
- - - - - - - - - - - - - - - - - - - - - -
DescriptionWhat you typeWhat you get
Bold
*bold text*
bold text
Italic
/italic text/
italic text
Inline code
=inline code=
inline code
-
- - - -
- - - - - - - - - - - - - - - - - - - - - -
DescriptionWhat you typeWhat you get
Bold
B<bold text>
bold text
Italic
I<italic text>
italic text
Inline code
C<inline code>
inline code
-
- - - -
- - - - - - - - - - - - - - - - - - - - - -
DescriptionWhat you typeWhat you get
Bold
*bold text*
bold text
Italic
_italic text_
italic text
Monospace
+monospace text+
monospace text
-
- - - -
- - - - - - - - - - - - - - - - - - - - - -
DescriptionWhat you typeWhat you get
Bold
**bold text**
bold text
Italic
*italic text*
italic text
Monospace
``monospace text``
monospace text
-
- - - -
- - - - - - - - - - - - - - - - - - - - - -
DescriptionWhat you typeWhat you get
Bold
*bold text*
bold text
Italic
_italic text_
italic text
Inline code
@inline code@
inline code
-
- - - - - - - -
- - - - - - - - - - - - - - - - - - - - - -
DescriptionWhat you typeWhat you get
First level heading
= Heading Text

Heading Text

Second level heading
== Heading Text

Heading Text

Third level heading
=== Heading Text

Heading Text

-
- - - -
- - - - - - - - - - - - - - - - - - - - - -
DescriptionWhat you typeWhat you get
First level heading
* Heading Text

Heading Text

Second level heading
** Heading Text

Heading Text

Third level heading
*** Heading Text

Heading Text

-
- - - -
- - - - - - - - - - - - - - - - - - - - - -
DescriptionWhat you typeWhat you get
First level heading
# Heading Text

Heading Text

Second level heading
## Heading Text

Heading Text

Third level heading
### Heading Text

Heading Text

-
- - - -
- - - - - - - - - - - - - - - - - - - - - -
DescriptionWhat you typeWhat you get
First level heading
=head1 Heading Text

Heading Text

Second level heading
=head2 Heading Text

Heading Text

Third level heading
=head3 Heading Text

Heading Text

-
- - - -
- - - - - - - - - - - - - - - - - - - - - -
DescriptionWhat you typeWhat you get
First level heading
Heading Text
============

Heading Text

Second level heading
Heading Text
------------

Heading Text

Third level heading
Heading Text
~~~~~~~~~~~~

Heading Text

-
- - - -
- - - - - - - - - - - - - - - - - - - - - -
DescriptionWhat you typeWhat you get
First level heading
h1. Heading Text

Heading Text

Second level heading
h2. Heading Text

Heading Text

Third level heading
h3. Heading Text

Heading Text

-
- - - -
- - - - - - - - - - - - - - - - -
DescriptionWhat you typeWhat you get
Unordered list
* Item 1
-** Item 1.1
-* Item 2
-* Item 3
-
-
  • Item 1

    -
    • Item 1.1

  • Item 2

    -
  • Item 3

-
-
Ordered list
. Item 1
-.. Item 1.1
-. Item 2
-. Item 3
-
-
  1. Item 1

    -
    1. - Item 1.1

  2. Item 2

  3. -

    Item 3

-
-
-
- - - -
- - - - - - - - - - - - - - - - -
DescriptionWhat you typeWhat you get
Unordered list
* Item 1
-** Item 1.1
-* Item 2
-* Item 3
-
-
  • Item 1
    • Item 1.1
  • Item 2
  • -
  • Item 3
-
-
Ordered list
# Item 1
-## Item 1.1
-# Item 2
-# Item 3
-
-
  1. Item 1
    1. Item 1.1
  2. Item 2
  3. -
  4. Item 3
-
-
-
- - - -
- - - - - - - - - - - - - - - - -
DescriptionWhat you typeWhat you get
Unordered list
* Item 1
-* Item 1.1
-* Item 2
-* Item 3
-
-
  • Item 1
    • Item 1.1
  • Item 2
  • -
  • Item 3
-
-
Ordered list
1. Item 1
-1. Item 1.1
-2. Item 2
-3. Item 3
-
-
  1. Item 1
    1. Item 1.1
  2. Item 2
  3. -
  4. Item 3
-
-
-
- - - -
- - - - - - - - - - - - - - - - -
DescriptionWhat you typeWhat you get
Unordered list
- Item 1
-- Item 1.1
-- Item 2
-- Item 3
-
-
  • Item 1
    1. Item 1.1
  • Item 2
  • -
  • Item 3
-
-
Ordered list
1. Item 1
-1. Item 1.1
-2. Item 2
-3. Item 3
-
-
  1. Item 1
    1. Item 1.1
  2. Item 2
  3. -
  4. Item 3
-
-
-
- - - -
- - - - - - - - - - - - - - - - -
DescriptionWhat you typeWhat you get
Unordered list
=over 4
-
-=item * Item 1
-
-=item * Item 2
-
-=item * Item 3
-
-=back
-
-
  • Item 1
  • Item 2
  • -
  • Item 3
-
-
Ordered list
=over 4
-
-=item 1. Item 1
-
-=item 2. Item 2
-
-=item 3. Item 3
-
-=back
-
-
  1. Item 1
  2. Item 2
  3. -
  4. Item 3
-
-
-
- - - -
- - - - - - - - - - - - - - - - -
DescriptionWhat you typeWhat you get
Unordered list
* Item 1
-* Item 1.1
-* Item 2
-* Item 3
-
-
  • Item 1
    • Item 1.1
  • Item 2
  • -
  • Item 3
-
-
Ordered list
1. Item 1
-1. Item 1.1
-2. Item 2
-3. Item 3
-
-
  1. Item 1
    1. Item 1.1
  2. Item 2
  3. -
  4. Item 3
-
-
-
- - - -
- - - - - - - - - - - - - - - - -
DescriptionWhat you typeWhat you get
Unordered list
* Item 1
-
-* Item 1.1
-
-* Item 2
-
-* Item 3
-
-
  • Item 1
    • Item 1.1
  • Item 2
  • -
  • Item 3
-
-
Ordered list
1. Item 1
-
-1. Item 1.1
-
-2. Item 2
-
-3. Item 3
-
-
  1. Item 1
    1. Item 1.1
  2. Item 2
  3. -
  4. Item 3
-
-
-
- - - -
- - - - - - - - - - - - - - - - -
DescriptionWhat you typeWhat you get
Unordered list
* Item 1
-* Item 1.1
-* Item 2
-* Item 3
-
-
  • Item 1
    • Item 1.1
  • Item 2
  • -
  • Item 3
-
-
Ordered list
1. Item 1
-1. Item 1.1
-2. Item 2
-3. Item 3
-
-
  1. Item 1
    1. Item 1.1
  2. Item 2
  3. -
  4. Item 3
-
-
-
- - - - - -
- - - - - - - - - - - - - - - - -
DescriptionWhat you typeWhat you get
Block
\[ \left( \sum_{k=1}^n a_k b_k \right)^2 \]
Inline
Consider \( x^2 + y^2 \).
Consider .
-
- -
-
-
\ No newline at end of file diff --git a/lib/gollum/frontend/templates/editor.mustache b/lib/gollum/frontend/templates/editor.mustache new file mode 100644 index 00000000..8fb90183 --- /dev/null +++ b/lib/gollum/frontend/templates/editor.mustache @@ -0,0 +1,40 @@ + \ No newline at end of file diff --git a/lib/gollum/frontend/templates/history.mustache b/lib/gollum/frontend/templates/history.mustache index 678e2854..cf99c254 100644 --- a/lib/gollum/frontend/templates/history.mustache +++ b/lib/gollum/frontend/templates/history.mustache @@ -1,37 +1,62 @@ -
-
-
- « Back -
-

{{title}}

-
- - - - - {{#versions}} - - - - - - - - {{/versions}} -
- Select any two versions to -
- - - {{id7}} - - Gravatar - {{author}} - {{message}}{{date}}
- -
-
+
+ +
+ + + +
+
+ + + + {{#versions}} + + + + + + + {{/versions}} + + +
+ + + + avatar: {{author}} + {{author}} + + + {{date}}:  + {{message}} + [{{id7}}…] + + Revert to {{id7}}… +
+
+
+
+
\ No newline at end of file diff --git a/lib/gollum/frontend/templates/layout.mustache b/lib/gollum/frontend/templates/layout.mustache index b08ac18c..94c78020 100644 --- a/lib/gollum/frontend/templates/layout.mustache +++ b/lib/gollum/frontend/templates/layout.mustache @@ -1,33 +1,23 @@ - - - - {{title}} - - - - - - - - - - - + + + + + + {{title}} + + - -
-
-
- {{{yield}}} -
-
-
- +{{{yield}}} + + + + + + + + diff --git a/lib/gollum/frontend/templates/page.mustache b/lib/gollum/frontend/templates/page.mustache index c5217be0..cd0d42d9 100644 --- a/lib/gollum/frontend/templates/page.mustache +++ b/lib/gollum/frontend/templates/page.mustache @@ -1,33 +1,49 @@ -
-
-
-
-
- Home | - Edit | - -
-
-
-

{{title}}

-
+
+ +
+
+
+
{{{content}}}
- {{#has_footer}} - + {{#has_sidebar}} +
+ + {{{sidebar_content}}} +
+ {{/has_sidebar}} + {{#has_footer}} + + {{/has_footer}} +
+ +
+ -
-
- Last edited by {{author}}, {{date}} -
- Home | Edit -
-
-
diff --git a/scratch/history.html b/scratch/history.html index 9d07a5c0..d2467db0 100644 --- a/scratch/history.html +++ b/scratch/history.html @@ -28,6 +28,7 @@
+ - - - - - - - - - - - -
@@ -48,45 +49,7 @@
- - - - avatar: username - username - - - 3 days ago:  - Rewrote home page as Markdown… - [a45719f…] - - Revert to a45719f… -
- - - - avatar: username - username - - - 3 days ago:  - Rewrote home page as Markdown… - [a45719f…] - - Revert to a45719f… -
diff --git a/scratch/js/gollum.js b/scratch/js/gollum.js index e4321ce4..73b104d8 100644 --- a/scratch/js/gollum.js +++ b/scratch/js/gollum.js @@ -30,6 +30,15 @@ $(document).ready(function() { $('#wiki-history td.revert-action a').mouseenter(highlightOn); $('#wiki-history td.revert-action a').mouseleave(highlightOff); + + $('li.minibutton a.action-compare-revision').click(function( e ) { + e.preventDefault(); + $('#version-form').submit(); + }); + $('li.minibutton a.action-back-to-top').click(function( e ) { + e.preventDefault(); + $('body').scrollTop = 0; + }); }; }); From a1c6829cfc225696c0d2f68f0b57ad8639098e1b Mon Sep 17 00:00:00 2001 From: Eston Bond Date: Thu, 4 Nov 2010 16:27:53 -0700 Subject: [PATCH 30/37] Added title field for create page --- lib/gollum/frontend/public/css/editor.css | 40 +++++++++++++++++++ .../javascript/gollum-editor/gollum.editor.js | 24 +++++++---- lib/gollum/frontend/templates/create.mustache | 7 +++- lib/gollum/frontend/templates/edit.mustache | 7 +++- lib/gollum/frontend/templates/editor.mustache | 10 +++-- lib/gollum/frontend/templates/layout.mustache | 18 +++++---- scratch/TODO | 18 ++++----- 7 files changed, 95 insertions(+), 29 deletions(-) diff --git a/lib/gollum/frontend/public/css/editor.css b/lib/gollum/frontend/public/css/editor.css index 6d99045b..df072eef 100644 --- a/lib/gollum/frontend/public/css/editor.css +++ b/lib/gollum/frontend/public/css/editor.css @@ -22,6 +22,46 @@ width: 100%; } +/* @control title */ +#gollum-editor-title-field { + display: none; +} + +#gollum-editor-title-field.active { + border-bottom: 1px solid #ddd; + display: block; + margin: 0 0 0.3em 0; + padding: 0 0 0.5em 0; +} + +#gollum-editor-title-field label { + /* JAWS should see it, but you can't */ + display: block; + height: 1px; + left: -5000px; + overflow: hidden; + position: absolute; + top: -5000px; + width: 1px; +} + +#gollum-editor-title-field input { + background: #fff; + border: 1px solid #ddd; + color: #000; + font-size: 1.3em; + font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif; + font-weight: bold; + line-height: 1.8em; + margin: 0; + padding: 0.5em; + width: 40%; +} + +#gollum-editor-title-field input.ph { + color: #999; +} + /* @control editor-view-tab */ #gollum-editor #gollum-editor-type-switcher { display: none; diff --git a/lib/gollum/frontend/public/javascript/gollum-editor/gollum.editor.js b/lib/gollum/frontend/public/javascript/gollum-editor/gollum.editor.js index 8cfbed60..7b0906db 100644 --- a/lib/gollum/frontend/public/javascript/gollum-editor/gollum.editor.js +++ b/lib/gollum/frontend/public/javascript/gollum-editor/gollum.editor.js @@ -11,6 +11,7 @@ var DefaultOptions = { MarkupType: 'markdown', EditorMode: 'code', + NewFile: false, HasFunctionBar: true, Debug: true }; @@ -24,12 +25,21 @@ */ $.GollumEditor = function( IncomingOptions ) { - ActiveOptions = $.extend( DefaultOptions, IncomingOptions ); + ActiveOptions = $.extend( DefaultOptions, IncomingOptions ); + debug('GollumEditor loading'); - if ( EditorHas.baseEditorMarkup() ) { - // Initialise the function bar by loading proper definitions + if ( EditorHas.baseEditorMarkup() ) { + + if ( ActiveOptions.NewFile ) { + $('#gollum-editor-title-field').addClass('active'); + $('#gollum-editor-title-field input').focus(function() { + $(this)[0].select(); + }); + } + + // Initialize the function bar by loading proper definitions if ( EditorHas.functionBar() ) { var htmlSetMarkupLang = $('#gollum-editor-body').attr('data-markup-lang'); @@ -226,6 +236,10 @@ ff4Environment: function() { var ua = new RegExp(/Firefox\/4.0b/); return ( ua.test( navigator.userAgent ) ); + }, + + titleDisplayed: function() { + return ( ActiveOptions.NewFile ); } }; @@ -597,7 +611,3 @@ } // })(jQuery); - -jQuery(document).ready(function() { - $.GollumEditor(); -}); \ No newline at end of file diff --git a/lib/gollum/frontend/templates/create.mustache b/lib/gollum/frontend/templates/create.mustache index 2f88edfa..4dc7457a 100644 --- a/lib/gollum/frontend/templates/create.mustache +++ b/lib/gollum/frontend/templates/create.mustache @@ -7,4 +7,9 @@ {{>editor}}
-
\ No newline at end of file +
+ \ No newline at end of file diff --git a/lib/gollum/frontend/templates/edit.mustache b/lib/gollum/frontend/templates/edit.mustache index d447aeaf..b86a71cd 100644 --- a/lib/gollum/frontend/templates/edit.mustache +++ b/lib/gollum/frontend/templates/edit.mustache @@ -13,4 +13,9 @@ {{>editor}}
-
\ No newline at end of file + + \ No newline at end of file diff --git a/lib/gollum/frontend/templates/editor.mustache b/lib/gollum/frontend/templates/editor.mustache index 8fb90183..d4fa5321 100644 --- a/lib/gollum/frontend/templates/editor.mustache +++ b/lib/gollum/frontend/templates/editor.mustache @@ -1,5 +1,9 @@
-
+ +
+ + +
Bold @@ -32,8 +36,8 @@
-
+ data-markup-lang="markdown" name="content">{{content}} +
diff --git a/lib/gollum/frontend/templates/layout.mustache b/lib/gollum/frontend/templates/layout.mustache index 94c78020..724cc036 100644 --- a/lib/gollum/frontend/templates/layout.mustache +++ b/lib/gollum/frontend/templates/layout.mustache @@ -5,19 +5,21 @@ + + + + + + + + {{title}} {{{yield}}} - - - - - - diff --git a/scratch/TODO b/scratch/TODO index 4c9a20ad..3ca791b6 100644 --- a/scratch/TODO +++ b/scratch/TODO @@ -1,9 +1,9 @@ -Gollum Editor - - Style / Generate dialogs - - Def: Org - - Def: Pod - - Def: RDoc - - Def: Restructured Text - -Make function bar button sprite -Roll scratch/ design into Mustache \ No newline at end of file +* Editor + * Add sidebar field + * Add footer field + * Add edit summary field + * Create rest of markup lang definitions +* Create Error Page +* Create Compare Revisions Page +* Create Search Results Page +* Write Editor/Sidebar implementation notes for Rick \ No newline at end of file From a24d1ca78ec4a720b29c387e379ebad8c4a7ad8f Mon Sep 17 00:00:00 2001 From: Eston Bond Date: Thu, 4 Nov 2010 16:47:20 -0700 Subject: [PATCH 31/37] Adding history field --- lib/gollum/frontend/public/css/editor.css | 32 +++++++++++-------- lib/gollum/frontend/templates/editor.mustache | 12 +++++-- 2 files changed, 27 insertions(+), 17 deletions(-) diff --git a/lib/gollum/frontend/public/css/editor.css b/lib/gollum/frontend/public/css/editor.css index df072eef..a6833e9d 100644 --- a/lib/gollum/frontend/public/css/editor.css +++ b/lib/gollum/frontend/public/css/editor.css @@ -3,6 +3,17 @@ Wiki editor formatting */ +.jaws { + /* JAWS should see it, but you can't */ + display: block; + height: 1px; + left: -5000px; + overflow: hidden; + position: absolute; + top: -5000px; + width: 1px; +} + #gollum-editor { border: 1px solid #e4e4e4; background: #f9f9f9; @@ -22,9 +33,8 @@ width: 100%; } -/* @control title */ -#gollum-editor-title-field { - display: none; +#gollum-editor-title-field input { + font-weight: bold; } #gollum-editor-title-field.active { @@ -34,31 +44,25 @@ padding: 0 0 0.5em 0; } -#gollum-editor-title-field label { - /* JAWS should see it, but you can't */ +#gollum-editor .singleline { display: block; - height: 1px; - left: -5000px; + margin: 0 0 0.7em 0; overflow: hidden; - position: absolute; - top: -5000px; - width: 1px; } -#gollum-editor-title-field input { +#gollum-editor .singleline input { background: #fff; border: 1px solid #ddd; color: #000; font-size: 1.3em; font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif; - font-weight: bold; line-height: 1.8em; margin: 0; padding: 0.5em; - width: 40%; + width: 98%; } -#gollum-editor-title-field input.ph { +#gollum-editor .singleline input.ph { color: #999; } diff --git a/lib/gollum/frontend/templates/editor.mustache b/lib/gollum/frontend/templates/editor.mustache index d4fa5321..aac9180a 100644 --- a/lib/gollum/frontend/templates/editor.mustache +++ b/lib/gollum/frontend/templates/editor.mustache @@ -1,7 +1,7 @@
-
- +
+
@@ -37,7 +37,13 @@
-
+ +
+ + +
+ +
From 055e80bbee52ef7b0b0f9bfa626a42eddfd925f4 Mon Sep 17 00:00:00 2001 From: Eston Bond Date: Thu, 4 Nov 2010 17:06:46 -0700 Subject: [PATCH 32/37] Build a rudimentary placeholder engine into the editor --- lib/gollum/frontend/public/css/editor.css | 26 ++++---- .../javascript/gollum-editor/gollum.editor.js | 66 +++++++++++++++++-- 2 files changed, 75 insertions(+), 17 deletions(-) diff --git a/lib/gollum/frontend/public/css/editor.css b/lib/gollum/frontend/public/css/editor.css index a6833e9d..525f1fe0 100644 --- a/lib/gollum/frontend/public/css/editor.css +++ b/lib/gollum/frontend/public/css/editor.css @@ -33,17 +33,6 @@ width: 100%; } -#gollum-editor-title-field input { - font-weight: bold; -} - -#gollum-editor-title-field.active { - border-bottom: 1px solid #ddd; - display: block; - margin: 0 0 0.3em 0; - padding: 0 0 0.5em 0; -} - #gollum-editor .singleline { display: block; margin: 0 0 0.7em 0; @@ -66,6 +55,21 @@ color: #999; } +#gollum-editor-title-field input { + font-weight: bold; +} + +#gollum-editor-title-field.active { + border-bottom: 1px solid #ddd; + display: block; + margin: 0 0 0.3em 0; + padding: 0 0 0.5em 0; +} + +#gollum-editor-title-field input#gollum-editor-page-title.ph { + color: #000; +} + /* @control editor-view-tab */ #gollum-editor #gollum-editor-type-switcher { display: none; diff --git a/lib/gollum/frontend/public/javascript/gollum-editor/gollum.editor.js b/lib/gollum/frontend/public/javascript/gollum-editor/gollum.editor.js index 7b0906db..1e027bf9 100644 --- a/lib/gollum/frontend/public/javascript/gollum-editor/gollum.editor.js +++ b/lib/gollum/frontend/public/javascript/gollum-editor/gollum.editor.js @@ -25,18 +25,18 @@ */ $.GollumEditor = function( IncomingOptions ) { - ActiveOptions = $.extend( DefaultOptions, IncomingOptions ); - + ActiveOptions = $.extend( DefaultOptions, IncomingOptions ); debug('GollumEditor loading'); if ( EditorHas.baseEditorMarkup() ) { - if ( ActiveOptions.NewFile ) { + if ( EditorHas.titleDisplayed() ) { $('#gollum-editor-title-field').addClass('active'); - $('#gollum-editor-title-field input').focus(function() { - $(this)[0].select(); - }); + } + + if ( EditorHas.editSummaryMarkup() ) { + Placeholder.add( $('#gollum-editor-edit-summary input') ) } // Initialize the function bar by loading proper definitions @@ -238,6 +238,10 @@ return ( ua.test( navigator.userAgent ) ); }, + editSummaryMarkup: function() { + return ( $('input#gollum-editor-message-field').length > 0 ); + }, + titleDisplayed: function() { return ( ActiveOptions.NewFile ); } @@ -609,5 +613,55 @@ $.GollumEditor.replaceSelection = function( repText ) { FunctionBar.replaceFieldSelection( $('#gollum-editor-body'), repText ); } + + + var Placeholder = { + + _PLACEHOLDERS : [], + + _p : function( $field ) { + + this.fieldObject = $field; + this.placeholderText = $field.val(); + var placeholderText = $field.val(); + + $field.addClass('ph'); + + $field.blur(function() { + if ( $(this).val() == '' ) { + $(this).val( placeholderText ); + $(this).addClass('ph'); + } + }); + + $field.focus(function() { + $(this).removeClass('ph'); + if ( $(this).val() == placeholderText ) { + $(this).val(''); + } else { + $(this)[0].select(); + } + }); + + }, + + add : function( $field ) { + Placeholder._PLACEHOLDERS.push( new Placeholder._p( $field ) ); + }, + + clearAll: function() { + for ( var i=0; i < Placeholder._PLACEHOLDERS.length; i++ ) { + if ( Placeholder._PLACEHOLDERS[i].fieldObject.val() == + Placeholder._PLACEHOLDERS[i].placeholderText ) { + Placeholder._PLACEHOLDERS[i].fieldObject.val(''); + } + } + }, + + exists : function() { + return ( _PLACEHOLDERS.length ); + } + + } // })(jQuery); From bc00c0f2ae19bc58b4974c0284eb04be9cd1d242 Mon Sep 17 00:00:00 2001 From: Eston Bond Date: Mon, 8 Nov 2010 13:57:48 -0800 Subject: [PATCH 33/37] Adding footer and sidebar fields to editor --- lib/gollum/frontend/public/css/editor.css | 106 +++++++++++++++++- .../frontend/public/images/icon-sprite.png | Bin 7876 -> 9668 bytes .../javascript/gollum-editor/gollum.editor.js | 15 ++- lib/gollum/frontend/templates/editor.mustache | 14 +++ scratch/TODO | 6 +- 5 files changed, 133 insertions(+), 8 deletions(-) diff --git a/lib/gollum/frontend/public/css/editor.css b/lib/gollum/frontend/public/css/editor.css index 525f1fe0..31a1e9ee 100644 --- a/lib/gollum/frontend/public/css/editor.css +++ b/lib/gollum/frontend/public/css/editor.css @@ -46,7 +46,7 @@ font-size: 1.3em; font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif; line-height: 1.8em; - margin: 0; + margin: 1em 0 0.4em; padding: 0.5em; width: 98%; } @@ -55,8 +55,9 @@ color: #999; } -#gollum-editor-title-field input { +#gollum-editor-title-field input#gollum-editor-page-title { font-weight: bold; + margin-top: 0; } #gollum-editor-title-field.active { @@ -79,7 +80,7 @@ #gollum-editor #gollum-editor-function-bar { border-bottom: 1px solid #ddd; overflow: hidden; - padding: 0 0 0.5em 0; + padding: 0.6em 0 1.1em 0; display: none; } @@ -204,7 +205,7 @@ a#function-image:hover span { background-position: -324px -28px; } font-size: 1.3em; font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif; line-height: 1.8em; - margin: 0.5em 0; + margin: 1em 0 0.4em; padding: 0.5em; /* I don't really like mixing pct & em here… */ width: 98%; height: 20em; @@ -248,6 +249,103 @@ a#function-image:hover span { background-position: -324px -28px; } background: -moz-linear-gradient(top, #599bdc, #3072b3); } +#gollum-editor .collapsed, +#gollum-editor .expanded { + border-bottom: 1px solid #ddd; + display: block; + overflow: hidden; + padding: 1em 0 0.5em; +} + +#gollum-editor #gollum-editor-body + .collapsed, +#gollum-editor #gollum-editor-body + .expanded { + border-top: 1px solid #ddd; + margin-top: 0.7em; +} + +#gollum-editor .collapsed a.button, +#gollum-editor .expanded a.button { + background: #f7f7f7; + border: 1px solid #ddd; + color: #333; + display: block; + float: left; + height: 25px; + overflow: hidden; + margin: 0.2em 0.5em 0.75em 0; + text-shadow: 0 1px 0 #fff; + width: 25px; + + border-radius: 0.3em; + -moz-border-radius: 0.3em; + -webkit-border-radius: 0.3em; + + filter:progid:DXImageTransform.Microsoft.gradient(GradientType=0, startColorstr='#f4f4f4', endColorstr='#ececec'); + background: -webkit-gradient(linear, left top, left bottom, from(#f4f4f4), to(#ececec)); + background: -moz-linear-gradient(top, #f4f4f4, #ececec); +} + +#gollum-editor .collapsed h4, +#gollum-editor .expanded h4 { + font-size: 1.6em; + float: left; + margin: 0; + padding: 0.4em 0 0 0.3em; + text-shadow: 0 -1px 0 #fff; +} + +#gollum-editor .collapsed a.button:hover, +#gollum-editor .expanded h4 a.button:hover { + color: #fff; + text-shadow: 0 -1px 0 rgba(0, 0, 0, 0.3); + text-decoration: none; + + filter:progid:DXImageTransform.Microsoft.gradient(GradientType=0, startColorstr='#599bdc', endColorstr='#3072b3'); + background: -webkit-gradient(linear, left top, left bottom, from(#599bdc), to(#3072b3)); + background: -moz-linear-gradient(top, #599bdc, #3072b3); +} + +#gollum-editor .collapsed a span, +#gollum-editor .expanded a span { + background-image: url(../images/icon-sprite.png); + background-position: -351px -1px; + background-repeat: no-repeat; + display: block; + height: 25px; + overflow: hidden; + text-indent: -5000px; + width: 25px; +} + +#gollum-editor .collapsed a:hover span { + background-position: -351px -28px; +} + +#gollum-editor .expanded a span { + background-position: -378px 0; +} + +#gollum-editor .expanded a:hover span { + background-position: -378px -28px; +} + +#gollum-editor .collapsed textarea { + display: none; +} + +#gollum-editor .expanded textarea { + border: 1px solid #ddd; + clear: both; + display: block; + font-size: 1.3em; + font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif; + height: 7em; + line-height: 1.8em; + margin: 0.7em 0; + padding: 0.5em; + width: 98%; +} + /* @control dialog */ diff --git a/lib/gollum/frontend/public/images/icon-sprite.png b/lib/gollum/frontend/public/images/icon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oe&Xsyi_?-bFRJ!Gg&Bw(R^Wiu{ z_>c(bNchR=qOJveo3rV-*|rT}aC)!}Ff-yAxZo$Bzp2o|L%c`^7cvVA35}R59($2L zd>UCt3xLm*Z<9lcpm>c)gf`5tu-x4>Es8}^zFlq00000 diff --git a/lib/gollum/frontend/public/javascript/gollum-editor/gollum.editor.js b/lib/gollum/frontend/public/javascript/gollum-editor/gollum.editor.js index 1e027bf9..34485953 100644 --- a/lib/gollum/frontend/public/javascript/gollum-editor/gollum.editor.js +++ b/lib/gollum/frontend/public/javascript/gollum-editor/gollum.editor.js @@ -39,6 +39,15 @@ Placeholder.add( $('#gollum-editor-edit-summary input') ) } + if ( EditorHas.collapsibleInputs() ) { + $('#gollum-editor .collapsed a.button, ' + + '#gollum-editor .expanded a.button').click(function( e ) { + e.preventDefault(); + $(this).parent().toggleClass('expanded'); + $(this).parent().toggleClass('collapsed'); + }); + } + // Initialize the function bar by loading proper definitions if ( EditorHas.functionBar() ) { var htmlSetMarkupLang = @@ -214,6 +223,10 @@ $('#gollum-editor-body').length ); }, + collapsibleInputs: function() { + return $('#gollum-editor .collapsed, #gollum-editor .expanded').length; + }, + /** * EditorHas.functionBar @@ -662,6 +675,6 @@ return ( _PLACEHOLDERS.length ); } - } + }; // })(jQuery); diff --git a/lib/gollum/frontend/templates/editor.mustache b/lib/gollum/frontend/templates/editor.mustache index aac9180a..c2baa6d3 100644 --- a/lib/gollum/frontend/templates/editor.mustache +++ b/lib/gollum/frontend/templates/editor.mustache @@ -37,12 +37,26 @@
+ + + + +
+
diff --git a/scratch/TODO b/scratch/TODO index 3ca791b6..c4986b97 100644 --- a/scratch/TODO +++ b/scratch/TODO @@ -1,9 +1,9 @@ * Editor * Add sidebar field * Add footer field - * Add edit summary field * Create rest of markup lang definitions * Create Error Page -* Create Compare Revisions Page +* Create Compare Revisions Page (like, when comparing the two) * Create Search Results Page -* Write Editor/Sidebar implementation notes for Rick \ No newline at end of file +* Write Editor/Sidebar implementation notes for Rick +* Write print.css \ No newline at end of file From 83e5c7fe5daf05f28f8d23a5776565cd4a6880c0 Mon Sep 17 00:00:00 2001 From: Eston Bond Date: Mon, 8 Nov 2010 14:03:39 -0800 Subject: [PATCH 34/37] Fixing sprite BG --- .../frontend/public/images/icon-sprite.png | Bin 9668 -> 8352 bytes scratch/TODO | 2 -- 2 files changed, 2 deletions(-) diff --git a/lib/gollum/frontend/public/images/icon-sprite.png b/lib/gollum/frontend/public/images/icon-sprite.png index 20dac3b2ff954818538d15034418ee33e42d2b1d..bc00ae8e73d4f79c77e20269b0cfaf35726e538d 100644 GIT binary patch delta 7524 zcmZ{pWmHw+yX~c*km-5t_h0@C1SQBu++-Q6H1UD73;BC+X^R&c{vp7XzB z+&jj(^V9mU*BEQ;@x1eyzxfU-=S$U_BO>zgB~R$Gq%%h_R`78S?Le+Qg02(9ZM`TFK=M!ncB=k=2Ks`pP`L0 zGG9$R)gE_ycLn!%?HlX`=GlqupFnW}a=NB}9Gf`hc(l!qjVYm{{!;{A!Uf$=;O9RT z_xJsi;>XZ`O2+u_9}M#rl=lgR<2gl=$=2$bA+Us5%Usgh(7(+?7>qWtBW8Ru;Xf3O@jy?W&bYP*CvkrdT>`8`A-YTdRuGD*O>~7gvFtft*e%Y&JM?Tyx}<#J5_N zRt?WsfrBx0VTB85RIx^$jDo?8fcul&WGhXM5FD1dqTyA}8rvKUuh;zF_2-`Ktd627{F}rH;d*?{AJj|9N=G!$CvKk9;W~rXbB7`1f}!0U@E;TCUqVN)Rde(3IOLpfW>V~=w@?X?qNV{5xuXx#elj*5!P%Iz->F7um(ik27l>`maagcQp}HyiBm-BB7mwDK=jgv6F%4#tuF5t$er zUFaY6OA{9Z_7uL>yCBS^_Vdt4TVU)Wy$S4*vXy#ww7h5G%{luL5EoA18GdjXaZqF7 zXCM;7N;Q#|4*9wle7sbrj6)^-!rsLNIzKme)!ADty;R!fz7tLnS)D+JQ6RO;oqj6M zi&#;qhKDp;XV!z4Fp@eyKd+RaG?XhAP7MD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CuZ-UpGfOIjT2kVEkmDqqBA)4t=-?kzFK|SaA81U zyfSboDw%?N33eub{;p;&CVGu4f?3uJF~MwL<{0O&t2>*1#CM>@>W?$JgOe*_5GjSwh(LWr3C3XC}O*5TturgL5h$y*^y&6*$eK zIKzm0)-v@IeVsEEk^Hs1Bs6+XF`_3NC?(wXYCBy2tMfwIvR}I5=`O&CcMx?IfME~c z6xn4HiE3GP@LGA`mzaoffOe@6vk7D=hV(9K7w+C48G5SmwAa_;`PanecK7v*Pmboh zEBAZ2?q7QVO6(`?w+R#`7dYH!hAlNd{@u=)m;VMz{v>Ci1XuqPQoBy9GSU(P{`@Tc zbobzxJsDd=^9%Op%SbW(aQfZ3`fevzXcXU-K=a}EX$OwYs4gLS1 zi?Wd|DNGT+c2kn(&IZ;VzaKn;06|y~3|`(uOSEC~+npc@jcU?8ycJ3DCn)3}D6KQH zc`SpB-_*&3M3Ay?Cu8t#=!*~D_&W!%q8R5r zc)K_$HI20Z9`DyOt}{AQffnO#U}pY)r*J~SR}Bxp97zy%2PTOdre%p9luddnr%9)N zd;=sc^Ejj8$(`Y8-ir5TsX{X6%`<@ER}dL-Hr0i$WfJVMH~eqs#Kt^Dza!qESJ0QnOyi2wiq diff --git a/scratch/TODO b/scratch/TODO index c4986b97..e58ee544 100644 --- a/scratch/TODO +++ b/scratch/TODO @@ -1,6 +1,4 @@ * Editor - * Add sidebar field - * Add footer field * Create rest of markup lang definitions * Create Error Page * Create Compare Revisions Page (like, when comparing the two) From 92aa7f2cd714b40df0aae23a7cc72816be8ad4bd Mon Sep 17 00:00:00 2001 From: Eston Bond Date: Mon, 8 Nov 2010 15:26:58 -0700 Subject: [PATCH 35/37] Write a small message here explaining this change. (Optional) --- Home.md | 1 + 1 file changed, 1 insertion(+) create mode 100644 Home.md diff --git a/Home.md b/Home.md new file mode 100644 index 00000000..cbf11fc4 --- /dev/null +++ b/Home.md @@ -0,0 +1 @@ +Something \ No newline at end of file From 46104dcb834b1d5f0fabb0a60d40bc8053e76207 Mon Sep 17 00:00:00 2001 From: Eston Bond Date: Mon, 8 Nov 2010 14:34:52 -0800 Subject: [PATCH 36/37] Fixing some CSS bugs --- lib/gollum/frontend/public/css/editor.css | 2 +- lib/gollum/frontend/public/css/gollum.css | 5 +++++ lib/gollum/frontend/templates/editor.mustache | 12 +++++++++++- lib/gollum/frontend/templates/page.mustache | 2 +- scratch/TODO | 1 + 5 files changed, 19 insertions(+), 3 deletions(-) diff --git a/lib/gollum/frontend/public/css/editor.css b/lib/gollum/frontend/public/css/editor.css index 31a1e9ee..b87816f7 100644 --- a/lib/gollum/frontend/public/css/editor.css +++ b/lib/gollum/frontend/public/css/editor.css @@ -171,7 +171,7 @@ a#function-image:hover span { background-position: -324px -28px; } #gollum-editor #gollum-editor-function-bar #gollum-editor-format-selector select { - background-color: #f7f7f7; + background-color: #f9f9f9; border: 1px solid transparent; float: right; diff --git a/lib/gollum/frontend/public/css/gollum.css b/lib/gollum/frontend/public/css/gollum.css index b8b14894..627d98ef 100644 --- a/lib/gollum/frontend/public/css/gollum.css +++ b/lib/gollum/frontend/public/css/gollum.css @@ -54,6 +54,11 @@ a:hover, a:visited { overflow: visible; } + #wiki-content .wrap { + height: 1%; + overflow: auto; + } + /* @section comments */ #wiki-body #inline-comment { display: none; /* todo */ diff --git a/lib/gollum/frontend/templates/editor.mustache b/lib/gollum/frontend/templates/editor.mustache index c2baa6d3..80c3599f 100644 --- a/lib/gollum/frontend/templates/editor.mustache +++ b/lib/gollum/frontend/templates/editor.mustache @@ -1,5 +1,6 @@
+
@@ -33,8 +34,17 @@ Link Image + +
+ +
-
diff --git a/lib/gollum/frontend/templates/page.mustache b/lib/gollum/frontend/templates/page.mustache index cd0d42d9..4cafd2bf 100644 --- a/lib/gollum/frontend/templates/page.mustache +++ b/lib/gollum/frontend/templates/page.mustache @@ -9,7 +9,7 @@
-
+
{{{content}}} diff --git a/scratch/TODO b/scratch/TODO index e58ee544..4fd99a9a 100644 --- a/scratch/TODO +++ b/scratch/TODO @@ -1,5 +1,6 @@ * Editor * Create rest of markup lang definitions + * Hook up format selector * Create Error Page * Create Compare Revisions Page (like, when comparing the two) * Create Search Results Page From 34b75c2a60abf073cfe97d17f5ab38e7eb9b8acc Mon Sep 17 00:00:00 2001 From: Eston Bond Date: Mon, 8 Nov 2010 14:48:04 -0800 Subject: [PATCH 37/37] Changing display of page title depending on edit/create state --- lib/gollum/frontend/public/css/editor.css | 8 ++++++-- .../javascript/gollum-editor/gollum.editor.js | 5 +++++ lib/gollum/frontend/templates/editor.mustache | 5 +++++ lib/gollum/frontend/templates/history.mustache | 2 +- lib/gollum/frontend/views/create.rb | 8 ++++++++ lib/gollum/frontend/views/edit.rb | 17 +++++++++++++++-- lib/gollum/frontend/views/history.rb | 2 +- 7 files changed, 41 insertions(+), 6 deletions(-) diff --git a/lib/gollum/frontend/public/css/editor.css b/lib/gollum/frontend/public/css/editor.css index b87816f7..ad1862e4 100644 --- a/lib/gollum/frontend/public/css/editor.css +++ b/lib/gollum/frontend/public/css/editor.css @@ -77,13 +77,17 @@ } /* @control function-bar */ -#gollum-editor #gollum-editor-function-bar { +#gollum-editor #gollum-editor-function-bar { border-bottom: 1px solid #ddd; overflow: hidden; - padding: 0.6em 0 1.1em 0; + padding: 0 0 1.1em 0; display: none; } +#gollum-editor-title-field + #gollum-editor-function-bar { + margin-top: 0.6em; +} + #gollum-editor #gollum-editor-function-bar.active { display: block; } diff --git a/lib/gollum/frontend/public/javascript/gollum-editor/gollum.editor.js b/lib/gollum/frontend/public/javascript/gollum-editor/gollum.editor.js index 34485953..613c706e 100644 --- a/lib/gollum/frontend/public/javascript/gollum-editor/gollum.editor.js +++ b/lib/gollum/frontend/public/javascript/gollum-editor/gollum.editor.js @@ -37,6 +37,11 @@ if ( EditorHas.editSummaryMarkup() ) { Placeholder.add( $('#gollum-editor-edit-summary input') ) + $('#gollum-editor form[name="gollum-editor"]').submit(function( e ) { + e.preventDefault(); + Placeholder.clearAll(); + $(this).submit(); + }); } if ( EditorHas.collapsibleInputs() ) { diff --git a/lib/gollum/frontend/templates/editor.mustache b/lib/gollum/frontend/templates/editor.mustache index 80c3599f..436a957b 100644 --- a/lib/gollum/frontend/templates/editor.mustache +++ b/lib/gollum/frontend/templates/editor.mustache @@ -1,10 +1,15 @@
+ {{#show_title}}
+ {{/show_title}} + {{#hidden_title}} + + {{/hidden_title}}
Bold diff --git a/lib/gollum/frontend/templates/history.mustache b/lib/gollum/frontend/templates/history.mustache index cf99c254..a2ef1e88 100644 --- a/lib/gollum/frontend/templates/history.mustache +++ b/lib/gollum/frontend/templates/history.mustache @@ -4,7 +4,7 @@
diff --git a/lib/gollum/frontend/views/create.rb b/lib/gollum/frontend/views/create.rb index 515d3e1d..a4cce0cf 100644 --- a/lib/gollum/frontend/views/create.rb +++ b/lib/gollum/frontend/views/create.rb @@ -8,6 +8,14 @@ module Precious def title "Create a new page" end + + def show_title + true + end + + def hidden_title + false + end def page_name @name.gsub('-', ' ') diff --git a/lib/gollum/frontend/views/edit.rb b/lib/gollum/frontend/views/edit.rb index 7165b801..15bc5727 100644 --- a/lib/gollum/frontend/views/edit.rb +++ b/lib/gollum/frontend/views/edit.rb @@ -5,9 +5,22 @@ module Precious attr_reader :page, :content - def title - "Editing #{@page.title}" + def page_name + @name.gsub('-', ' ') end + + def edit_title + false + end + + def hidden_title + true + end + + def title + "#{@page.title}" + end + end end end diff --git a/lib/gollum/frontend/views/history.rb b/lib/gollum/frontend/views/history.rb index d7628d56..d3cb143f 100644 --- a/lib/gollum/frontend/views/history.rb +++ b/lib/gollum/frontend/views/history.rb @@ -4,7 +4,7 @@ module Precious attr_reader :page, :page_num def title - "History of #{@page.title}" + @page.title end def versions