We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 23299
    • 1,161 Posts
    This is more of a head scratcher than I thought it was going to be...

    I would like to style my own Breadcrumbs in Revo. There is no Breadcrumbs CSS, right? All the current layout of Breadcrumbs seems to come from the Breadcrumbs Default Properties? There is a warning:
    Note: It is best to not edit default properties for snippets installed via Package Management, as if those snippets are upgraded the default properties will be overwritten. Use a Property Set instead.


    I would like to remove the default crumbSeparator and add a triangle shaped image to the right side of each crumb link. I see there are a number of classes that Breadcrumbs generates. I can add CSS to those classes.

    Before I get started is there anything else I need to do before working with the CSS? Do I need to adjust anything in the Default Breadcrumbs Properties or build a new custom Property set?

    Any tips on styling breadcrumbs in Revo would be most welcome...

    Thanks!
      • 17499 ☆ A M B ☆
      • 872 Posts
      There is a second apckage name crumb[+something] available. It is made by Opengeek, more recent than Breadcrumbs and more customisable as well.
        • 23299
        • 1,161 Posts
        Quote from: lossendae at Feb 25, 2011, 02:55 PM

        There is a second apckage name crumb[+something] available. It is made by Opengeek, more recent than Breadcrumbs and more customisable as well.

        Really? Is it ready for prime time?

        In the mean time I did this:

        * I turned off the crumbSeparator value to get rid of the forward marker text thingy
        * I then used Firebug to see what CSS classes were being generated.
        * I added custom CSS with some longer than anticipated testing and trial and error along the way.
        #breadCrumbsContainer{
        	margin: 20px 0 20px 0;
        	border: 1px solid #dedede;
        	padding: 4px 20px 4px 10px;}
        
        .B_crumbBox{
        	padding: 5px 20px 5px 30px;
        	background: #fff;}
        	
        .B_crumbBox a{
        	color:#999;
        	font-size: .8em;
        	text-decoration:none;}
        	
        .B_crumbBox a:hover{
        	text-decoration:underline;}
        
        .B_firstCrumb .B_homeCrumb{
        	padding: 5px 15px 5px 0;
        	margin-right:5px;}
        	
        .B_firstCrumb a{
        	background:url(../images/crumbs.gif) no-repeat right center;}
        	
        .B_crumb{
        	padding:5px 15px 5px 0;
        	margin-right: -5px;}
        	
        .B_crumb a{
        	background:url(../images/crumbs.gif) no-repeat right center;}
        	
        .B_lastCrumb a{
        	margin:0;}
        
        .B_lastCrumb a:hover{
        	text-decoration: none;
        	cursor:pointer;}


        This issue I kept fighting was strange gap spacing between the different links (first, regular, and last etc). I added some custom margins to get them to look decent. I am using a large image that is centered via the CSS so it will expand with user text size increases as needed. So far so good but I suspect I am needing to add the extra margins to overcome some default settings somehow?

        I will check out the extra snippet in due course...
          • 17499 ☆ A M B ☆
          • 872 Posts
          I did not find it on the website, see here for more informations:

          https://github.com/opengeek/quickcrumbs
            • 10075
            • 20 Posts
            While on the subject of Breadcrumbs in Revo:

            Is it true that the &homeId parameter has been completely removed from the Revo version of Breadcrumbs? It seems odd that a new version would deliberately remove functionality present in an older version. This makes Breadcrumbs in Revo a lot less flexible, and not terribly useful for sites where the "home" page isn’t necessarily the site index page (such as sites with a splash page or an interstitial).
              • 3749
              • 24,544 Posts
              Max: As long as you use properties (parameters) in the snippet tag to set things, you don’t have to worry about an upgrade interfering. If you want to make extensive changes to the default properties themselves, just go to the properties page of the snippet and click on the button to create a new property set. Call it MyBreadcrumbsProperties, make your changes, and put this in the snippet tag:

              [[Breadcrumbs@MyBreadcrumbsProperties]]


              The snippet will use the default properties you didn’t change + any that are overridden in your property set and your changes will survive any upgrades.

              Using your own CSS file and specifying it in the template should work fine and cause no trouble.
                Did I help you? Buy me a beer
                Get my Book: MODX:The Official Guide
                MODX info for everyone: http://bobsguides.com/modx.html
                My MODX Extras
                Bob's Guides is now hosted at A2 MODX Hosting