Mobile theme W.I.P.:

-Fix nm header for new searchbox widget
This commit is contained in:
Hadi Nategh 2016-02-15 19:10:14 +00:00
parent 876072aa1f
commit d1186de773
3 changed files with 34 additions and 33 deletions

View File

@ -2301,6 +2301,7 @@ var et2_nextmatch_header_bar = et2_DOMWidget.extend(et2_INextmatchHeader,
*/ */
if (egwIsMobile()) if (egwIsMobile())
{ {
this.search_box.addClass('nm-mob-header');
jQuery(this.div).css({display:'inline-block'}).addClass('nm_header_hide'); jQuery(this.div).css({display:'inline-block'}).addClass('nm_header_hide');
//indicates appname in header //indicates appname in header
@ -2331,15 +2332,8 @@ var et2_nextmatch_header_bar = et2_DOMWidget.extend(et2_INextmatchHeader,
jQuery('tr.selected',self.nextmatch.div).trigger({type:'contextmenu',which:3,originalEvent:e}); jQuery('tr.selected',self.nextmatch.div).trigger({type:'contextmenu',which:3,originalEvent:e});
}) })
.prependTo(this.search_box); .prependTo(this.search_box);
this.search_button = et2_createWidget("button", {id: "search_button"}, this);
this.search.input.on ('focus blur', function (e){
self.search_box.toggleClass('searchOn');
});
} }
// Add category // Add category
if(!settings.no_cat) { if(!settings.no_cat) {
settings.cat_id_label = egw.lang("Category"); settings.cat_id_label = egw.lang("Category");

View File

@ -7725,7 +7725,7 @@ span.egw_tutorial_title {
font-weight: bold; font-weight: bold;
font-size: 18pt; font-size: 18pt;
} }
body .et2_nextmatch .search { body .et2_nextmatch .nm-mob-header {
background: #0c5da5; background: #0c5da5;
margin-top: 0; margin-top: 0;
padding-left: 60px; padding-left: 60px;
@ -7733,7 +7733,7 @@ span.egw_tutorial_title {
position: relative; position: relative;
z-index: 1; z-index: 1;
} }
body .et2_nextmatch .search button { body .et2_nextmatch .nm-mob-header button {
height: 50px; height: 50px;
width: 50px; width: 50px;
background-repeat: no-repeat; background-repeat: no-repeat;
@ -7746,7 +7746,11 @@ span.egw_tutorial_title {
box-shadow: none; box-shadow: none;
outline: none; outline: none;
} }
body .et2_nextmatch .search button.nm_toggle_header { body .et2_nextmatch .nm-mob-header div.et2_searchbox {
display: inline-block;
width: 50px;
}
body .et2_nextmatch .nm-mob-header button.nm_toggle_header {
background-position: center; background-position: center;
background-repeat: no-repeat; background-repeat: no-repeat;
margin-right: 5px; margin-right: 5px;
@ -7758,14 +7762,14 @@ span.egw_tutorial_title {
display: block; display: block;
float: right; float: right;
} }
body .et2_nextmatch .search button.nm_toggle_header:focus { body .et2_nextmatch .nm-mob-header button.nm_toggle_header:focus {
outline: none; outline: none;
} }
body .et2_nextmatch .search button.nm_toggle_header:after { body .et2_nextmatch .nm-mob-header button.nm_toggle_header:after {
font-size: 18pt; font-size: 18pt;
content: "\2261"; content: "\2261";
} }
body .et2_nextmatch .search button.nm_action_header { body .et2_nextmatch .nm-mob-header button.nm_action_header {
background-position: center; background-position: center;
background-repeat: no-repeat; background-repeat: no-repeat;
margin-right: 5px; margin-right: 5px;
@ -7777,15 +7781,15 @@ span.egw_tutorial_title {
display: block; display: block;
float: right; float: right;
} }
body .et2_nextmatch .search button.nm_action_header:focus { body .et2_nextmatch .nm-mob-header button.nm_action_header:focus {
outline: none; outline: none;
} }
body .et2_nextmatch .search button.nm_action_header:after { body .et2_nextmatch .nm-mob-header button.nm_action_header:after {
font-size: 18pt; font-size: 18pt;
content: "\205D"; content: "\205D";
font-weight: bold; font-weight: bold;
} }
body .et2_nextmatch .search div.nm_favorites_div { body .et2_nextmatch .nm-mob-header div.nm_favorites_div {
background-position: center; background-position: center;
background-repeat: no-repeat; background-repeat: no-repeat;
margin-right: 5px; margin-right: 5px;
@ -7797,51 +7801,51 @@ span.egw_tutorial_title {
display: block; display: block;
float: right; float: right;
} }
body .et2_nextmatch .search div.nm_favorites_div:focus { body .et2_nextmatch .nm-mob-header div.nm_favorites_div:focus {
outline: none; outline: none;
} }
body .et2_nextmatch .search div.nm_favorites_div div[name="favorite"] { body .et2_nextmatch .nm-mob-header div.nm_favorites_div div[name="favorite"] {
position: relative !important; position: relative !important;
top: 0 !important; top: 0 !important;
outline: none; outline: none;
} }
body .et2_nextmatch .search div.nm_favorites_div div[name="favorite"] .et2_dropdown button:first-child { body .et2_nextmatch .nm-mob-header div.nm_favorites_div div[name="favorite"] .et2_dropdown button:first-child {
display: none; display: none;
} }
body .et2_nextmatch .search div.nm_favorites_div div[name="favorite"] .et2_dropdown button:nth-child(2) div:first-child { body .et2_nextmatch .nm-mob-header div.nm_favorites_div div[name="favorite"] .et2_dropdown button:nth-child(2) div:first-child {
display: none; display: none;
} }
body .et2_nextmatch .search div.nm_favorites_div div[name="favorite"] .et2_dropdown button:nth-child(2):after { body .et2_nextmatch .nm-mob-header div.nm_favorites_div div[name="favorite"] .et2_dropdown button:nth-child(2):after {
font-size: 17pt; font-size: 17pt;
content: "\2606"; content: "\2606";
font-weight: bold; font-weight: bold;
vertical-align: super; vertical-align: super;
} }
body .et2_nextmatch .search div.nm_favorites_div div[name="favorite"] ul.favorites { body .et2_nextmatch .nm-mob-header div.nm_favorites_div div[name="favorite"] ul.favorites {
width: 160px; width: 160px;
box-shadow: 0px 4px 5px 2px silver; box-shadow: 0px 4px 5px 2px silver;
border: 1px solid silver; border: 1px solid silver;
} }
body .et2_nextmatch .search div.nm_favorites_div div[name="favorite"] ul.favorites li.ui-menu-item { body .et2_nextmatch .nm-mob-header div.nm_favorites_div div[name="favorite"] ul.favorites li.ui-menu-item {
white-space: nowrap; white-space: nowrap;
text-overflow: ellipsis; text-overflow: ellipsis;
overflow: hidden; overflow: hidden;
border-bottom: 1px solid silver; border-bottom: 1px solid silver;
} }
body .et2_nextmatch .search div.nm_favorites_div div[name="favorite"] ul.favorites li.ui-menu-item a { body .et2_nextmatch .nm-mob-header div.nm_favorites_div div[name="favorite"] ul.favorites li.ui-menu-item a {
width: 100%; width: 100%;
line-height: 30px; line-height: 30px;
} }
body .et2_nextmatch .search div.nm_favorites_div div[name="favorite"] ul.favorites li.ui-menu-item a input { body .et2_nextmatch .nm-mob-header div.nm_favorites_div div[name="favorite"] ul.favorites li.ui-menu-item a input {
display: none; display: none;
} }
body .et2_nextmatch .search div.nm_favorites_div div[name="favorite"] ul.favorites li.ui-menu-item a div.ui-icon-trash { body .et2_nextmatch .nm-mob-header div.nm_favorites_div div[name="favorite"] ul.favorites li.ui-menu-item a div.ui-icon-trash {
display: block; display: block;
} }
body .et2_nextmatch .search button.nm_toggle_header_on:after { body .et2_nextmatch .nm-mob-header button.nm_toggle_header_on:after {
content: "\2613"; content: "\2613";
} }
body .et2_nextmatch .search input[type="search"] { body .et2_nextmatch .nm-mob-header input[type="search"] {
width: 50px; width: 50px;
height: 50px; height: 50px;
font-size: large; font-size: large;
@ -7852,11 +7856,11 @@ span.egw_tutorial_title {
color: black; color: black;
position: absolute; position: absolute;
} }
body .et2_nextmatch .search input[type="search"]:active { body .et2_nextmatch .nm-mob-header input[type="search"]:active {
border: none; border: none;
background: #0c5da5; background: #0c5da5;
} }
body .et2_nextmatch .search input[type="search"]:focus { body .et2_nextmatch .nm-mob-header input[type="search"]:focus {
border: none; border: none;
background: white; background: white;
outline: none; outline: none;
@ -7867,7 +7871,7 @@ span.egw_tutorial_title {
height: 50px; height: 50px;
z-index: 2; z-index: 2;
} }
body .et2_nextmatch .search div.nm_appname_header { body .et2_nextmatch .nm-mob-header div.nm_appname_header {
width: 100%; width: 100%;
position: absolute; position: absolute;
top: 0; top: 0;

View File

@ -1251,7 +1251,7 @@
} }
} }
} }
.search { .nm-mob-header {
background: @mobile-nm-search-bg; background: @mobile-nm-search-bg;
margin-top: 0; margin-top: 0;
padding-left: 60px; padding-left: 60px;
@ -1271,7 +1271,10 @@
box-shadow: none; box-shadow: none;
outline: none; outline: none;
} }
div.et2_searchbox {
display: inline-block;
width:50px;
}
button.nm_toggle_header { button.nm_toggle_header {
background-position: center; background-position: center;
background-repeat: no-repeat; background-repeat: no-repeat;