New modifiers for template designers

View: New views
4 Messages — Rating Filter:   Alert me  

New modifiers for template designers

by Bruno Postle-2 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

MKDoc 1.6 CVS now has some new Petal modifiers to allow template
designers more freedom when displaying text.

The new modifiers use the same MKDoc::Text::Structured backend as
the Text Component.  This means that plain text strings can now be
displayed in a variety of ways:

The as_html_entities: modifier will add smartquotes and convert
simple ascii constructs such as (c) to their rich text equivalents.

  <title petal:content="structure as_html_entities: title">Document Title</title>

The as_html_inline: modifier will do the same, but will also add
inline tags such as strong or abbr.

  <h1 petal:content="structure as_html_inline: title">Document Title</h1>

The as_html_blocks: modifier will do the same, but will add block
level structures such as paragraph tags, lists etc...

  <div petal:content="structure as_html_blocks: description">Document Description</div>

For full documentation of MKDoc::Text::Structured, see:

  http://search.cpan.org/dist/MKDoc-Text-Structured/

--
Bruno
_______________________________________________
MKDoc-dev mailing list
MKDoc-dev@...
https://lists.webarch.co.uk/mailman/listinfo/mkdoc-dev

Re: New modifiers for template designers

by Chris Croome :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Hi

On Fri 18-Nov-2005 at 03:32:13PM +0000, Bruno Postle wrote:
> MKDoc 1.6 CVS now has some new Petal modifiers to allow template
> designers more freedom when displaying text.
>
> The new modifiers use the same MKDoc::Text::Structured backend as the
> Text Component.  

I think it makes sense to use this for the Rights, Publisher and
Description metadata when it appears on a page. Will this also turn URIs
into links and if not could this be an option?

Chris

--
Chris Croome                               <chris@...>
web design                             http://www.webarchitects.co.uk/ 
web content management                               http://mkdoc.com/   
_______________________________________________
MKDoc-dev mailing list
MKDoc-dev@...
https://lists.webarch.co.uk/mailman/listinfo/mkdoc-dev

Re: New modifiers for template designers

by Bruno Postle-2 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

On Fri 18-Nov-2005 at 15:57 +0000, Chris Croome wrote:
>
> I think it makes sense to use this for the Rights, Publisher and
> Description metadata when it appears on a page. Will this also turn URIs
> into links and if not could this be an option?

Yes the "as_html_inline:" and "as_html_blocks:" modifiers should
linkify URIs.

Basically "as_html_blocks:" does exactly the same conversion as the
Text Component.

--
Bruno
_______________________________________________
MKDoc-dev mailing list
MKDoc-dev@...
https://lists.webarch.co.uk/mailman/listinfo/mkdoc-dev

Re: New modifiers for template designers

by Chris Croome :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Hi

I have added the "structure as_html_inline:" modifier to the footnote
fragment and print template for the Publisher and Rights metadata
fields in MKDoc 1.6.

And I have added the "structure as_html_blocks:" modifier to the
Description field for the headlines component, the child listing
templates, the sitemap and the search results page.

I though about using a modifier for descriptions from RSS imports but I
think this is perhaps best done as a customisation as needs be for sites
since that want it because it's probably only going to be RSS feeds from
other MKDoc sites that will have descriptions that have been marked up
with MKDoc structured text...

Are there any places I have missed that should also use these modifiers?

Chris

--
Chris Croome                               <chris@...>
web design                             http://www.webarchitects.co.uk/ 
web content management                               http://mkdoc.com/   
_______________________________________________
MKDoc-dev mailing list
MKDoc-dev@...
https://lists.webarch.co.uk/mailman/listinfo/mkdoc-dev