+1-888-365-2779
Try Now
More in this section

Forums / Designing with Sitefinity / News Archive Treeview styling

News Archive Treeview styling

4 posts, 0 answered
  1. Scott Rozman
    Scott Rozman avatar
    93 posts
    Registered:
    10 Oct 2012
    11 Jan 2011
    Link to this post
    In one part of my website, I am using the Site Treeview (RadTree) as navigation.
    In another part, I am displaying the News Archive (RadTree) as a navigation of news items.
    I would like these two to look and behave similarly.
    The Site Treeview has expanding nodes and gets classes rtplus and rtminus with a sprite image that I've changed to a rotating triangle, depending on whether the node is open or closed.
    Is there any trick to have the tree of the New Archive, also use rtplus and rtminus?
    Currently, I get a bullet circle on all of the News Archive items because it is picking up the style of my regular unordered lists.

    My Site Treeview:
    http://elpa.education.wisc.edu/People/Directory.aspx
    My News Archive:
    http://news.education.wisc.edu/edpsych.aspx

    Thanks in advance for any suggestions.
  2. Ivan Dimitrov
    Ivan Dimitrov avatar
    16072 posts
    Registered:
    25 Nov 2016
    12 Jan 2011
    Link to this post
    Hello Scott ,

    It looks like you have the images included, but you need to fix the css classes

    .SecondaryNav .RadTreeView_Default .rtMinus, .SecondaryNav .RadTreeView_Default .rtPlus {
        background-image: url("http://wd.education.wisc.edu/cdn/CSS/SoETemplate/UWRed/Images/TreeViewArrows.png") !important;
        background-repeat: no-repeat;
        display: block;
        float: left;
        padding: 6px;
        position: relative;
    }

    This is the location of the main stylesheet.
    http://wd.education.wisc.edu/cdn/CSS/SoETemplate/UWRed/Theme.css

    Greetings,
    Ivan Dimitrov
    the Telerik team
    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
  3. Scott Rozman
    Scott Rozman avatar
    93 posts
    Registered:
    10 Oct 2012
    12 Jan 2011
    Link to this post
    Hi Ivan,
    I noticed in the Site Treeview that I can drill into settings for the Treeview itself under Misc.
    I can change "EnableEmbeddedBaseStylesheet", which is true for the Site Treeview and gives CSS classes the background image pixel offsets to work with the sprite image.
    The News Archive control does not seem to load the web resource of this embedded style sheet which I'd think is the piece I am missing.... or perhaps one of the pieces.

    The HTML structure rendered out for both of the above pages is the same and the classes are the same, but the difference is that the I don't have that embedded style sheet.

    Any tricks for loading this with the news archive control?

    thanks again...
  4. Ivan Dimitrov
    Ivan Dimitrov avatar
    16072 posts
    Registered:
    25 Nov 2016
    12 Jan 2011
    Link to this post
    Hello Scott,

    NewsArchive has a property - LayoutTemplatePath which you can use to map an external template which contains the RadTreeView declaration from where you can set all properties you want.

    Here is the template declaration

    <%@ Control Language="C#" %>
    <%@ Register Namespace="Telerik.Web.UI" Assembly="Telerik.Web.UI" TagPrefix="telerik" %>
     
    <h2>
        <asp:Literal ID="controlTitle" runat="server"></asp:Literal>
    </h2>
    <!-- bulleted list mode -->
    <telerik:RadTreeView ID="archiveTreeView" ShowLineImages="false" runat="server"></telerik:RadTreeView>
     
    <!-- dropdown list mode -->
    <p><telerik:OptgroupDropDownList ID="dropDownList" runat="server">
    </telerik:OptgroupDropDownList></p>

    By default we do not disable embedded resources. You can take a look at How to map a template

    Kind regards,
    Ivan Dimitrov
    the Telerik team
    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
Register for webinar
4 posts, 0 answered