Changes For Pier

The Pharo images accessible from http://www.piercms.org are very handy and they have great CSS already present, however they don't work on Seaside Hosting, and the Smalltalk interface is much less responsive than a normal Squeak image. For this work, I've taken the web image from http://damiencassou.seasidehosting.st/Smalltalk/squeak-dev, and loaded the latest code in Monticello for pier and pieraddons (including the persistency).

Changes:

  1. The top of the page that you see here is made of a PRPathNavigationWidget, and an Advanced-search. The root environment is:

    <div class="container">
    	<div class="header column span-24">
    		<div class="title column span-20">+LinkPath+</div>
    		<div class="search column span-4 last">++Advanced Search++</div>
    		<div class="search column span-4 last">+search+</div>
    	</div>
    	<div class="body column span-24">
    		<div class="contents column span-20 last">+contents+</div>
    	</div>
    	<div class="footer column span-24">+footer+</div>
    </div>

    Note that divs need to be used, if the above are changed to spans, this will not work. Footer is a page:

    <div class="footer column span-24 last">
           <div class="column span-18">
                   +justlogincommand+
                   +loggedinuser+
                   <div class="commands">+commands+</div>
                   <div class="views">+views+</div>
                   <div class="sitemap">+sitemap+</div>
           </div>
           <div class="column span-6 last">+poweredby+</div>
    </div>

    justlogincommand is a command, only login is selected. loggedinuser is a page: Logged in as

    +value:user+ (+changePassword+?)

    For others, view is removed. changePassword is a PUSecurityWidget commands is a page, Commands: +commandsWidget+, commandWidget is a PRCommandWidget (all selected). views is a page: Views: +ViewComponent+. siteMap is a page: Sitemap +treeComponent+. pweredby is a page: Powered by *Pier>http://www.piercms.com*.

  2. The pier enhanced editor has a very nice resize feature available by clicking the two diagonal buttons at the bottom-right corner. Unfortunately, this only seens to work in Safari (not Internet Explorer or Firefox, the edit window is a tiny text area). CSS stylesheet have been modified to prevent this from being resized.
  3. Added stylesheet for changing tables that are created with | to have borders around them - Code changes are in the add-on pier-SW2-Sw1Features. CSS for this can be added as:

    table.prtable {table-layout: auto; width: auto; border: inset 1px;}
    table.prtable td {border: 1px solid;}

    After loading an updated CSS file to pier, and choosing it for the settings, its best to run the following from the Smalltalk environment to update the cache:

    WARegistry clearAllHandlers.
    MCFileBasedRepository flushAllCaches.

  4. Re-size for bold pre-formatted text - Consider:
    012345678901234567890123456789
    012345678901234567890123456789
    These two lines should be the same length (for this simple example, it doesn't look too bad, but for larger Ascii-Art, its a noticeable problem). The fix for this is a simple CSS change:

    /* 2009-Aug-2 - Bold pre-formatted text should be the same size as normal per-formatted text */
    pre b {font-size: 95%;}
    code b {font-size: 95%;}

    See Css Tutorial or CSS for Pier for more tips on CSS.

  5. Added custom links
  6. The package Pier-SW2 Model logging contains changes to PRHistoryPersistency>>writeToLogFrom:, however since Pier-Squeak-Persistency from http://source.lukas-renggli.ch/pier already provides better logging (using transactions.txt), this work is deprecated.
  7. Updating CSS - It may seem tempting to edit CSS by clicking Edit Design then changing the CSS directly, I haven't found that this works - the CSS changes do not have any consequences. It is better to edit the file in a text editor, and upload it each time (in Pier 2.0, this is the only option).
What needs to change:
  1. Move all of the new code to the *Pier-Smallwiki2 package
  2. When editing a component, it draws a DNU from PRComponent
  3. When you click changes, it should display when a change was made
  4. How can I move the search field so it is next to the right margin?