Changeset - 732ccbb5f07c
[Not reviewed]
default
1 2 0
Sean Farley - 11 years ago 2014-07-16 02:18:52
sean.michael.farley@gmail.com
eye.png: use new icon-eye font
3 files changed with 1 insertions and 2 deletions:
0 comments (0 inline, 0 general)
kallithea/public/css/contextbar.css
Show inline comments
 
/**
 
 * Stylesheets for the context bar
 
 */
 

	
 
i.icon-arrow-right { background-image: url('../images/icons/arrow_right.png');}
 
i.icon-bar-chart { background-image: url("../images/icons/chart_bar.png"); }
 
i.icon-code-merge { background-image: url("../images/icons/arrow_merge.png"); } /* unused! */
 
i.icon-ellipsis-horizontal:after { content: ' ...';}
 
i.icon-eye-open { background-image: url("../images/icons/eye.png"); }
 
i.icon-file-txt { background-image: url("../images/icons/note_error.png"); }
 
i.icon-git { background-image: url('../images/icons/giticon.png');}
 
i.icon-hg { background-image: url('../images/icons/hgicon.png');}
 
i.icon-disabled { background-image: url('../images/icons/shading.png');} /* todo: use instead of minus sign */
 

	
 
i[class^='icon-'] {
 
    background-repeat: no-repeat;
 
    background-position: center;
 
    display: inline-block;
 
    min-width: 16px;
 
    min-height: 16px;
 
    margin: -2px 0 -4px 0;
 
    /* background-color: red; /* for debugging */
 

	
 
}
 

	
 
/* css classes for diff file status ... it'd be nice if css had a way to
 
   inherit from another class but alas, we must make sure this content is the
 
   same from the icon font file */
 

	
 
.icon-diff-M:before {
 
    font-family: 'kallithea';
 
    content: '\e805';
 
    color: #d0b44c;
 
}
 

	
 
.icon-diff-D:before {
 
    font-family: 'kallithea';
 
    content: '\e807';
 
    color: #bd2c00;
 
}
 

	
 
.icon-diff-A:before {
 
    font-family: 'kallithea';
 
    content: '\e806';
 
    color: #6cc644;
 
}
 

	
 
.icon-diff-R:before {
 
    font-family: 'kallithea';
 
    content: '\e81f';
 
    color: #677a85;
 
}
 

	
 
#content #context-bar {
 
    position: relative;
 
    overflow: visible;
 
    background-color: #577632;
 
    padding: 0 5px;
 
    min-height: 36px;
 
}
 

	
 
#content #context-bar h2 {
 
    display: inline-block;
 
    color: #FFF;
 
}
 

	
 
#header #header-inner #quick a,
 
#content #context-bar,
 
#content #context-bar a {
 
    color: #FFFFFF;
 
}
 

	
 
#header #header-inner #quick a:hover,
 
#content #context-bar a:hover {
 
    text-decoration: none;
 
}
 

	
 
#content #context-bar .icon {
 
    display: inline-block;
 
    width: 16px;
 
    height: 16px;
 
    vertical-align: text-bottom;
 
}
 

	
 
ul.horizontal-list {
 
    display: block;
 
}
 

	
 
ul.horizontal-list > li {
 
    float: left;
 
    position: relative;
 
}
 

	
 
#header #header-inner #quick ul,
 
ul.horizontal-list > li ul {
 
    position: absolute;
 
    display: none;
 
    right: 0;
 
    z-index: 999;
 
}
 

	
 
#header #header-inner #quick li:hover > ul,
 
ul.horizontal-list li:hover > ul {
 
    display: block;
 
}
 

	
 
#header #header-inner #quick li ul li,
 
ul.horizontal-list ul li {
 
    position: relative;
 
    border-bottom: 1px solid rgba(0,0,0,0.1);
 
    border-top: 1px solid rgba(255,255,255,0.1);
 
}
 

	
 
ul.horizontal-list > li ul ul {
 
    position: absolute;
 
    right: 100%;
 
    top: -1px;
 
    min-width: 200px;
 
    max-height: 400px;
 
    overflow-x: hidden;
 
    overflow-y: auto;
 
}
 

	
 
#header #header-inner #quick ul a,
 
ul.horizontal-list li a {
 
    white-space: nowrap;
 
}
 

	
 
#breadcrumbs {
 
    float: left;
 
    padding: 6px 0 5px 0;
 
    padding-left: 5px;
 
    font-weight: bold;
 
    font-size: 14px;
 
}
 

	
 
#breadcrumbs span {
 
    font-weight: bold;
 
    font-size: 1.4em;
 
}
 

	
 
#header #header-inner #quick ul,
 
#revision-changer,
 
#context-pages,
 
#context-pages ul {
 
    background: #3b6998; /* Old browsers */
 
    background: -moz-linear-gradient(top, #577632 0%, #577632 100%); /* FF3.6+ */
 
    background: -webkit-gradient(linear, left top, left bottom, color-stop(0%,#577632), color-stop(100%,#577632)); /* Chrome,Safari4+ */
 
    background: -webkit-linear-gradient(top, #577632 0%, #577632 100%); /* Chrome10+,Safari5.1+ */
 
    background: -o-linear-gradient(top, #577632 0%, #577632 100%); /* Opera 11.10+ */
 
    background: -ms-linear-gradient(top, #577632 0%, #577632 100%); /* IE10+ */
 
    background: linear-gradient(to bottom, #577632 0%, #577632 100%); /* W3C */
 
    /*Filter on IE will also use overflow:hidden implicitly, and that would clip our inner menus.*/
 
    /*filter: progid:DXImageTransform.Microsoft.gradient( startColorstr='#577632', endColorstr='#577632',GradientType=0 ); /* IE6-9 */*/
 
}
 

	
 
#header #header-inner #quick a,
 
#context-actions a,
 
#context-pages a {
 
    background-repeat: no-repeat;
 
    background-position: 10px 50%;
 
    padding-left: 30px;
 
}
 

	
 
#quick a,
 
#context-pages ul ul a {
 
    padding-left: 10px;
 
}
 

	
 
ul#context-actions {
 
    display: inline-block;
 
    float: right;
 
    border-radius: 4px;
 
    background-image: linear-gradient(top, #577632 0%, #577632 100%);
 
}
 

	
 
#content ul#context-actions li {
 
    padding: 0px;
 
    border-right: 1px solid rgba(0,0,0,0.1);
 
    border-left: 1px solid rgba(255,255,255,0.1);
 
}
 

	
 
#context-actions a {
 
    display: block;
 
    cursor: pointer;
 
    background: none;
 
    border: none;
 
    margin: 0px;
 
    height: auto;
 
    padding: 10px 10px 10px 30px;
 
    background-repeat: no-repeat;
 
    background-position: 10px 50%;
 
    font-size: 1em;
 
}
 

	
 
#context-actions a {
 
    padding: 11px 10px 12px 30px;
 
}
 

	
 
#header #header-inner #quick li:hover,
 
#revision-changer:hover,
kallithea/public/images/icons/eye.png
Show inline comments
 
deleted file
 
binary diff not shown
Show images
kallithea/templates/journal/journal.html
Show inline comments
 
## -*- coding: utf-8 -*-
 
<%inherit file="/base/base.html"/>
 
<%def name="title()">
 
    ${_('Journal')}
 
    %if c.site_name:
 
        &middot; ${c.site_name}
 
    %endif
 
</%def>
 
<%def name="breadcrumbs()">
 
    <h5>
 
    <form id="filter_form">
 
    <input class="q_filter_box ${'' if c.search_term else 'initial'}" id="j_filter" size="15" type="text" name="filter" value="${c.search_term or _('quick filter...')}"/>
 
    <span class="tooltip" title="${h.tooltip(h.journal_filter_help())}">?</span>
 
    <input type='submit' value="${_('Filter')}" class="btn btn-small" style="padding:0px 2px 0px 2px;margin:0px"/>
 
    ${_('Journal')} - ${ungettext('%s Entry', '%s Entries', c.journal_pager.item_count) % (c.journal_pager.item_count)}
 
    </form>
 
    ${h.end_form()}
 
    </h5>
 
</%def>
 
<%def name="page_nav()">
 
    ${self.menu('journal')}
 
</%def>
 
<%def name="head_extra()">
 
<link href="${h.url('journal_atom', api_key=c.authuser.api_key)}" rel="alternate" title="${_('ATOM journal feed')}" type="application/atom+xml" />
 
<link href="${h.url('journal_rss', api_key=c.authuser.api_key)}" rel="alternate" title="${_('RSS journal feed')}" type="application/rss+xml" />
 
</%def>
 
<%def name="main()">
 

	
 
    <div class="box box-left">
 
        <!-- box / title -->
 
        <div class="title">
 
         ${self.breadcrumbs()}
 
         <ul class="links icon-only-links">
 
           <li>
 
             <span><a id="refresh" href="${h.url('journal')}"><i class="icon-arrows-cw"></i></a></span>
 
           </li>
 
           <li>
 
             <span><a href="${h.url('journal_atom', api_key=c.authuser.api_key)}"><i class="icon-rss-squared"></i></a></span>
 
           </li>
 
         </ul>
 
        </div>
 
        <div id="journal">${c.journal_data}</div>
 
    </div>
 
    <div class="box box-right">
 
        <!-- box / title -->
 

	
 
        <div class="title">
 
            <h5>
 
            <input class="q_filter_box" id="q_filter" size="15" type="text" name="filter" placeholder="${_('quick filter...')}" value="" style="display: none"/>
 
            <input class="q_filter_box" id="q_filter_watched" size="15" type="text" name="filter" placeholder="${_('quick filter...')}" value="" style="display: none"/>
 
            </h5>
 
            <ul class="links nav nav-tabs">
 
                <li class="active" id="show_watched_li">
 
                    <a id="show_watched" href="#watched"><i class="icon-eye-open"></i> ${_('Watched')}</a>
 
                    <a id="show_watched" href="#watched"><i class="icon-eye"></i> ${_('Watched')}</a>
 
                </li>
 
                <li id="show_my_li">
 
                    <a id="show_my" href="#my"><i class="icon-database"></i> ${_('My Repos')}</a>
 
               </li>
 
            </ul>
 
        </div>
 

	
 
        <!-- end box / title -->
 
        <div id="my_container" style="display:none">
 
            <div class="table-grid table yui-skin-sam" id="repos_list_wrap"></div>
 
            <div id="user-paginator" style="padding: 0px 0px 0px 20px"></div>
 
        </div>
 

	
 
        <div id="watched_container">
 
            <div class="table-grid table yui-skin-sam" id="watched_repos_list_wrap"></div>
 
            <div id="watched-user-paginator" style="padding: 0px 0px 0px 20px"></div>
 
        </div>
 
    </div>
 

	
 
    <script type="text/javascript">
 

	
 
    $('#j_filter').click(function(){
 
        var $jfilter = $('#j_filter');
 
        if($jfilter.hasClass('initial')){
 
            $jfilter.val('');
 
        }
 
    });
 
    var fix_j_filter_width = function(len){
 
        $('#j_filter').css('width', Math.max(80, len*6.50)+'px');
 
    };
 
    $('#j_filter').keyup(function(){
 
        fix_j_filter_width($('#j_filter').val().length);
 
    });
 
    $('#filter_form').submit(function(e){
 
        e.preventDefault();
 
        var val = $('#j_filter').val();
 
        window.location = "${url.current(filter='__FILTER__')}".replace('__FILTER__',val);
 
    });
 
    fix_j_filter_width($('#j_filter').val().length);
 

	
 
    $('#refresh').click(function(e){
 
        asynchtml("${h.url.current(filter=c.search_term)}", $("#journal"), function(){
 
            show_more_event();
 
            tooltip_activate();
 
            show_changeset_tooltip();
 
            });
 
        e.preventDefault();
 
    });
 

	
 
    var show_my = function(e){
 
        $('#watched_container').hide();
 
        $('#my_container').show();
 
        $('#q_filter').show();
 
        $('#q_filter_watched').hide();
 

	
 
        $('#show_my_li').addClass('active');
 
        $('#show_watched_li').removeClass('active');
 
        if(!$('#show_my').hasClass('loaded')){
 
            table_renderer(${c.data |n});
 
            $('#show_my').addClass('loaded');
 
        }
 
    };
 
    $('#show_my').click(function(){
 
        show_my();
 
    });
 
    var show_watched = function(){
 
        $('#my_container').hide();
 
        $('#watched_container').show();
 
        $('#q_filter_watched').show();
 
        $('#q_filter').hide();
 

	
 
        $('#show_watched_li').addClass('active');
 
        $('#show_my_li').removeClass('active');
 
        if(!$('#show_watched').hasClass('loaded')){
 
            watched_renderer(${c.watched_data |n});
 
            $('#show_watched').addClass('loaded');
 
        }
 
    };
 
    $('#show_watched').click(function(){
 
        show_watched();
 
    });
 
    //init watched
 
    show_watched();
 

	
 
    var tabs = {
 
        'watched': show_watched,
 
        'my': show_my
 
    }
 
    var url = location.href.split('#');
 
    if (url[1]) {
 
        //We have a hash
 
        var tabHash = url[1];
 
        var func = tabs[tabHash]
 
        if (func){
 
            func();
 
        }
 
    }
 
    function watched_renderer(data){
 
        var myDataSource = new YAHOO.util.DataSource(data);
 
        myDataSource.responseType = YAHOO.util.DataSource.TYPE_JSON;
 

	
 
        myDataSource.responseSchema = {
 
            resultsList: "records",
 
            fields: [
 
               {key:"menu"},
 
               {key:"raw_name"},
 
               {key:"name"},
 
               {key:"last_changeset"},
 
               {key:"last_rev_raw"},
 
               {key:"action"}
 
            ]
 
         };
 
        myDataSource.doBeforeCallback = function(req,raw,res,cb) {
 
            // This is the filter function
 
            var data     = res.results || [],
 
                filtered = [],
 
                i,l;
 

	
 
            if (req) {
 
                req = req.toLowerCase();
 
                for (i = 0; i<data.length; i++) {
 
                    var pos = data[i].raw_name.toLowerCase().indexOf(req)
 
                    if (pos != -1) {
 
                        filtered.push(data[i]);
 
                    }
 
                }
 
                res.results = filtered;
 
            }
 
            return res;
 
        }
 
        // main table sorting
 
        var myColumnDefs = [
 
            {key:"menu",label:"",sortable:false,className:"quick_repo_menu hidden"},
 
            {key:"name",label:"${_('Name')}",sortable:true,
 
                sortOptions: { sortFunction: nameSort }},
 
            {key:"last_changeset",label:"${_('Tip')}",sortable:true,
 
                sortOptions: { sortFunction: revisionSort }},
 
            {key:"action",label:"${_('Action')}",sortable:false}
 
        ];
 

	
 
        var myDataTable = new YAHOO.widget.DataTable("watched_repos_list_wrap", myColumnDefs, myDataSource,{
 
          sortedBy:{key:"name",dir:"asc"},
 
          paginator: YUI_paginator(25, ['watched-user-paginator']),
 

	
 
          MSG_SORTASC:"${_('Click to sort ascending')}",
 
          MSG_SORTDESC:"${_('Click to sort descending')}",
 
          MSG_EMPTY:"${_('No records found.')}",
 
          MSG_ERROR:"${_('Data error.')}",
 
          MSG_LOADING:"${_('Loading...')}"
 
        }
 
        );
 
        myDataTable.subscribe('postRenderEvent',function(oArgs) {
 
            tooltip_activate();
 
            quick_repo_menu();
 
        });
 

	
 
        var filterTimeout = null;
 

	
 
        updateFilter  = function () {
 
            // Reset timeout
 
            filterTimeout = null;
 

	
 
            // Reset sort
 
            var state = myDataTable.getState();
 
            state.sortedBy = {key:'name', dir:YAHOO.widget.DataTable.CLASS_ASC};
 

	
 
            // Get filtered data
 
            myDataSource.sendRequest(YUD.get('q_filter_watched').value,{
 
                success : myDataTable.onDataReturnInitializeTable,
 
                failure : myDataTable.onDataReturnInitializeTable,
 
                scope   : myDataTable,
 
                argument: state
 
            });
 

	
 
        };
 
        $('#q_filter_watched').click(function(){
 
            if(!$('#q_filter_watched').hasClass('loaded')) {
 
                //TODO: load here full list later to do search within groups
 
                $('#q_filter_watched').css('loaded');
 
            }
 
        });
 

	
 
        $('#q_filter_watched').keyup(function(){
 
            clearTimeout(filterTimeout);
 
            filterTimeout = setTimeout(updateFilter,600);
 
        });
 
      }
 

	
 
    function table_renderer(data){
 
        var myDataSource = new YAHOO.util.DataSource(data);
 
        myDataSource.responseType = YAHOO.util.DataSource.TYPE_JSON;
 

	
0 comments (0 inline, 0 general)