diff --git a/TODO.md b/TODO.md new file mode 100644 index 0000000..75fd5ca --- /dev/null +++ b/TODO.md @@ -0,0 +1,55 @@ +* Make animated inserting to the any position + +* Make drag'n'dropping with saving position + +* Correctly handle changing size of item + +* make rational spans +* make item-specific width + +* utilize modernizr to detect features + +* Insert inside the list - animate displacing + +* Make layouter - generic layout description thing + +* Correct chrome rounding of item offsets + +* Use translate-3d and calc, if possible. If not - use simple absolute positioning. + +* BUG: data-col-width fails to read + +* BUG: fix case where there’s only three items, but pasteable 4 columns (footer in kudago) + * Min-col-num property, max-col-num + +* Restrict max columns number + +* Move out animations to the css + +* Finish up deferreds (fix zepto/jquery bad behaviour, test for nested images) + +* Make full equivalent to css-columns + +* Test on jquery sequential image-loading along with non-image elements (as header inside content) + +* On `add` - animate from bottom of the screen + +* BUG: Fucks up layout if -webkit-animation top + +* Update only visible part on add, do not recalculate + +* Speed up appending of elements. Too slow for now. + +* Deferred image loading of new elements. + +* Scroll only visible part + +* Specified number of columns, e.g. 2,4,6. No 3. + +* Keep viewport scrolling on reflow + +* Fixed-width floating aside column +* Correct reflow when inner element size changed +* Displacement as on gplus when new item added. +* Test float elements with prerender mode +* Keep position(order) tracking, e.g. if I want to fix some element on top of column \ No newline at end of file diff --git a/appearance_menu.html.erb b/appearance_menu.html.erb new file mode 100644 index 0000000..07fba92 --- /dev/null +++ b/appearance_menu.html.erb @@ -0,0 +1,17 @@ + diff --git a/cabecalho.css b/cabecalho.css new file mode 100644 index 0000000..5cbdb5b --- /dev/null +++ b/cabecalho.css @@ -0,0 +1,1198 @@ +/*(amarelo-claro=#fcdd4e)*/ +/*(amarelo-escuro=#f9c404)*/ +/****************** cabecalho ******************/ +#theme-header{height: auto;} + +#header { + padding: 13px 0 0 0; +background-color: #fcdd4e;/*(amarelo-claro)*/ + /* Old browsers */ + background-color: #f9c404; /*(amarelo-escuro)*/ + background-image: -moz-radial-gradient(center, ellipse cover, #fcdd4e 1%, #f9c404 100%); /*(amarelo-claro)(amarelo-escuro)*/ + /* FF3.6+ */ + background-image: -webkit-gradient(radial, center center, 0px, center center, 100%, color-stop(1%,#fcdd4e), color-stop(100%,#f9c404)); + /* Chrome,Safari4+ */ + background-image: -webkit-radial-gradient(center, ellipse cover, #fcdd4e 1%,#f9c404 100%); + /* Chrome10+,Safari5.1+ */ + background-image: -o-radial-gradient(center, ellipse cover, #fcdd4e 1%,#f9c404 100%); + /* Opera 12+ */ + background-image: -ms-radial-gradient(center, ellipse cover, #fcdd4e 1%,#f9c404 100%); + /* IE10+ */ + background-image: radial-gradient(ellipse at center, #fcdd4e 1%,#f9c404 100%); + /* W3C */ +/* filter: progid:DXImageTransform.Microsoft.gradient( startColorstr='#fcdd4e', endColorstr='#f9c404',GradientType=1 );*/ + /* IE6-9 fallback on horizontal gradient */ + color: #fff; +} + +#header>div { + max-width: 960px; + margin: 0 auto; +} + +.header-content * { + margin: 0; + padding: 0; + list-style: none; + vertical-align: baseline; +} + +.header-content { + height: 5px; + transition-duration: 0.6s; + overflow: hidden; +} + +.header-content:hover, +.header-content *:focus + .header-content, +.header-content *:focus > .header-content { + height: 173px; +} + +.header-content li { display: inline; } + +#brasilgov { + background: #00510f; + border-bottom: 1px solid #ffcc00; + padding: 5px 10px; + color: #03316f; +} + +#accessibility { + display: block !important; + float: left; + font-family: arial; + font-size: 10px; + width: 50%; +} + +#accessibility a { + color: #00500f; + margin-right: 8px; +} + +#accessibility span { + background: none repeat scroll 0 0 #497B16; + color: #FFFFFF; + padding: 0 4px; +} + + + +/* logo */ +#logo { + padding: 0; + float: left; + width: 70%; +} + +#logo span { + display: block; +} + +#logo a { + display: block; + width: 100%; + color: #03316f !important; + margin: 1em 0px; +} + +#logo a, #logo #portal-title { + color: #03316f; +} + +#logo #portal-title { + margin: 30px 0px 46px 0px; + color: #03316f; + font-size: 40px; + font-family: 'Open Sans Extrabold', Arial, Helvetica, sans-serif; + font-weight: normal; + line-height: 1em; + letter-spacing: -0.05em; +} + +#logo .luongo { + font-size: 3em !important; + line-height: 1.1em; + margin-bottom: 0.2em; +} + +#logo #portal-description { + font-size: 1.2em; + text-transform: uppercase; +} + +/* Site Actions */ +#portal-siteactions { + display: block; + float: right; + clear: left; + border-bottom: 1px dotted #00500f; + padding-bottom: 2px; + margin-top: -15px; + font-size: 10px; + text-align: center; +} + +#portal-siteactions a { + color: #00500f; + text-decoration: none; + padding: 4px 0 4px 10px; + text-transform: uppercase; + font-family: 'Open Sans', Arial, Helvetica, sans-serif; +} + +#portal-siteactions a:hover { + color: #03316f; +} + +#portal-siteactions li { + display: inline; +} + +#portal-siteactions li a:hover { +color: #75ad0a +} +#portal-siteactions li a { + padding: 4px 0px; +} + +#social-icons { + float: right; + clear: right; + margin: 0px; +} + +#social-icons ul { + display: table-row; +} + +#social-icons li { + display: table-cell; +} + +#social-icons li a { + border: none; + padding: 0 5px; +} + +#siteaction-accessibility, +#siteaction-contraste { + margin: 0px 15px 0px 0px; +} +/* */ + +/* Top links */ +#theme-header .header-content #link-faq a { + border-right: 1px solid #00500f; + padding: 0 10px; +} +#theme-header .header-content #link-contact a { + padding-left: 10px; +} + +#theme-header #sobre { + line-height: 20px; + font-size: 12px; +} +/* */ + +/* Sobre o brasil */ +#sobre { + clear: both; + max-width: 100% !important; + margin: 0; + background: #f8c300;/*amarelo-mais-escuro*/ + padding: 5px 0; +} + +#sobre ul { + max-width: 960px; + margin: 0 auto; + text-align: right; +} + +#sobre a { + color: #00500f; + font-family: 'Open Sans', Arial, Helvetica, sans-serif; +} + +#sobre .portalservicos-item a { + padding: 0 10px; + border-right: 1px solid #03316f; +} + +#sobre .last-item a { + padding: 0 0 0 10px; + border-right: none; +} + +/* Searchbox */ +.LSBox { + margin: 0; + padding: 0; + border: none; +} + +input.searchField { + -moz-appearance: none; +} + +#portal-searchbox { + clear: right; + float: right; + font-size: 80%; + margin: 30px 0 14px; + /*margin: 3.12em 0px 3px 0px;*/ + text-align: right; + border-radius: 5px; + -moz-border-radius: 5px; + -webkit-border-radius: 5px; + border: 1px solid #CCCCCC; + background: #fff; + padding: 2px; +} + +#portal-searchbox .searchField { + padding: 0.45em; + border-right: none; + border: none; + width: 170px; +} + +#portal-searchbox form { +white-space: nowrap; +} + +#portal-searchbox label { +font-weight: normal; +} + +#searchGadget { +width: 13em; +} + +#header input.searchButton { + padding: 0.3em; + background: transparent; + text-indent: -2000px; + padding: 4px 15px; + border: none; +} + +#content input.searchField { +margin-bottom: 1em; +} +input.searchField { +-moz-appearance: searchfield; +} + +#header input.searchButton { + background-image: url("images/search-button.gif"); + background-position: 8px 2px; + background-repeat: no-repeat; + background-color: #ffffff; +} + +#LSResult { + z-index: 1; + margin-top: 0.5%; +} + + +/* Search Button */ +#search-button a { + display: inline-block; + width: 29px; + height: 25px; + margin-right: 3px; + margin-top: 10px; +} + +#search-button a:hover { + opacity: 0.6; +} + +#search-button #sb_search { +background-image: url(images/search.png); +background-size: 100% 100%; +} + +#search-button span { display: none; } + + +/* */ + +/* Social Buttons */ +#social-buttons a { + width: 18px; + height: 20px; + margin-right: 3px; + margin-top: 10px; +} + +#social-icons li a { + width: 20px; + height: 20px; + padding: 0px; + display: inline-block; + background-repeat: no-repeat; +} + +#social-icons li { + float: right; + width: 20px; + margin-left: 4px; +} + +#social-icons #sb_face { +background-image: url(images/icone-verde-facebook.png); +} +#social-icons #sb_face:hover { +background: url(images/icone-verde-facebook.png) 0 20px; +} + +#social-icons #sb_tweet { +background-image: url(images/icone-verde-twitter.png); +} +#social-icons #sb_tweet:hover { +background: url(images/icone-verde-twitter.png) 0 20px; +} + +#social-icons #sb_youtb { +background-image: url(images/icone-verde-youtube.png); +} +#social-icons #sb_youtb:hover { +background: url(images/icone-verde-youtube.png) 0 20px; +} + +#social-icons #sb_flickr { +background-image: url(images/icone-verde-flickr.png); +} +#social-icons #sb_flickr:hover { +background: url(images/icone-verde-flickr.png) 0 20px; +} + +#social-icons span { display: none; } + +/* FIM social Buttons */ + +/****************** FIM cabecalho ******************/ + + + +/****************** Barra do usuário e Espaço do usuário ******************/ + +/********ABA Lateral - Espaço do Usuário**********/ +/*escondendo e revelando a aba lateral*/ +.notransition { + -webkit-transition: none !important; + -moz-transition: none !important; + -o-transition: none !important; + -ms-transition: none !important; + transition: none !important; +} +div#wrap-1,div#wrap-0,div#theme-footer { + transition-duration: 0.6s; + -webkit-transition-duration:0.6s; +} +div#wrap-1,div#theme-footer {float: right;width:100%;} +div#wrap-1.menu,div#theme-footer.menu {width: 80%;} +div#wrap-0.menu{/*width: 20%*/; /*float: left;height: 1px;*/} + +/*Propriedades da aba lateral e elementos internos*/ +#navigation-control { + width: 0%; + transition: 0.6s; + /*position: absolute;*/ + position: fixed; + left: 0px; + display: inline-block; + background-color: transparent; + color: black; + z-index: -1; + font-size:80%; +} + +.menu #navigation-control {width: 20%;} + +#navigation-control a{} + +#navigation-control ul li { + margin: 10px 0; + text-align: left; + list-style: none; +} + +#navigation-control ul li a.button.with-text, +#navigation-control ul li a.button.with-text:visited { + border: 0px solid #AAA; +} + +#navigation-control ul li a span { + background-repeat: no-repeat; + /*padding-left: 25px;*/ +} + +/**/ +#navigation-control .perfil{ + display: inline-block; + background-color: gray; + width: 100%; +} + +#navigation-control .perfil ul{padding-left: 0;} + +#navigation-control .perfil ul li{} + +#navigation-control .perfil .name{text-align: center;} + +#navigation-control .perfil .name h1{color: #fff;} + +#navigation-control .perfil .picture{display: inline-block;width: 100%;text-align: center;} + +#navigation-control .perfil .picture img{max-width: 140px; max-height: 140px;overflow: hidden;/*border-radius: 50%;border: 1px solid red;*/} + +#navigation-control .perfil .tasks_inner{cursor:pointer; color: #fff;display: inline-block;width: 49%;text-align: center;background: url(images/barra-menu-task.png) no-repeat 10px center gray;} + +#navigation-control .perfil .user_status{cursor:pointer; display:inline-block; width:49% ; text-align: center;} + +#navigation-control .perfil .online{color: greenyellow;} +#navigation-control .perfil .busy{color: red;} +#navigation-control .perfil .away{color: yellow;} +#navigation-control .perfil .offline{color: #ccc;} + +#navigation-control .perfil .online span{font-size: large;vertical-align: -1px;} + + +#navigation-control .menu_user{margin-top: 0;} + +#navigation-control .menu_user .activity_menu {margin-top: 0;padding: 0;border-top: 1px solid #ddd;} + +#navigation-control .menu_user .activity_menu .activity_menu_item{ + color: #ddd; + background-color: gray; + padding: 0 28px; + margin: 0; + border-bottom: 1px solid #ddd; + height: 40px; +} + +#navigation-control .menu_user .activity_menu .activity_menu_item * { + line-height: 40px; +} +#navigation-control .menu_user .activity_menu .activity_menu_item a { + display: inline-block; + width: 100%; +} + +#navigation-control .menu_user .activity_menu .activity_menu_item:hover {background-color: #ddd; color: #333;} + +#navigation-control .menu_user .activity_menu .activity_menu_item .arrow{float: right;} + +#navigation-control .menu_user .activity_menu .activity_menu_item .quick_post{padding: 14px;background-color: #fff;margin-top: 10px;display: none;} + +/********FIM ABA Lateral - Espaço do Usuário**********/ + + +/****************** Barra do usuário ******************/ +#top-bar { + position: relative; + height: 40px; + margin: auto; + background: url(images/top-bar-bg.png) repeat-x; +} + +#top-bar.top { + background-color: #fff; + height: 40px; +} + +#top-bar li { + float: left; +} + + +/*****Botões da barra do usuário - Menu - Pendẽncias - Mensagens *****/ +.btn_control_panel { + min-width: 40px; + height: 40px; + color: #999; + margin-top: 0; + margin-right: -3px; + display: inline-block; + /*float: left;*/ + vertical-align:top; + cursor: pointer; + border-right: 1px solid #999; + opacity:0.4; + filter:alpha(opacity=40); + padding: 0px 0px 0 35px; + position:relative; + /*z-index: 99;*/ +} + +#user .logged-in #pending-tasks-count { + background-color: #eee; + padding-left: 15px; + border-left: 1px solid #999; + border-right: 1px solid #999; + margin-left: 15px; + height: 40px; + display: inline-block; +} +#user .logged-in #pending-tasks-count i { + left: 0; +} + +#theme-header .btn_control_panel #user a:hover { + background-color: #eee; + opacity:0.8; + filter:alpha(opacity=80); +} +#theme-header .btn_control_panel #user a { + display: inline-block; + margin: 0; +} +#theme-header .btn_control_panel #user a strong { + line-height: 40px; + padding: 10px 5px 10px 33px; +} +#theme-header .btn_control_panel #user a span { + line-height: 40px; +} +#theme-header .btn_control_panel #user a i { + left: 10px; + top: 12px; +} +#theme-header .btn_control_panel #user a .task-count { + padding: 5px; + margin-left: 16px; +} +#theme-header .btn_control_panel #user .ctrl-panel { + display: none; +} + +/* +#theme-header .btn_control_panel #user a strong:hover { + line-height: 40px; +}*/ + +.btn_control_panel span{ + border: 1px solid gray; + border-radius: 5px; + background-color: white; + padding: 3px; + color: #333; + display: inline; +} + +a.btn_control_panel span{margin:0px; border: 0px solid gray;border-radius: 0px; background-color: transparent; padding: 0px;color: #333;display: inline-block;height: 35px;} + +.btn_control_panel ul {padding-left: 0;text-align: left;margin: 0;padding: 1em} + +.btn_control_panel ul li {display: none;padding-left: 0;text-align: left;margin: 0;padding: 1em} + +a.btn_control_panel:hover ul li{display: block;} + +.btn_control_panel ul li ul {display: none;} + +.btn_control_panel ul.menu_conteudo li:hover ul {display: inline-block} + +.btn_control_panel.btn_control {padding: 0;} + +/*****FIM Botões da barra do usuário - Menu - Pendẽncias - Mensagens *****/ + +/*.btn_control,*/ +.btn_menu { + background: url(images/barra-menu-control.png) no-repeat 14px center #eee; + padding-left: 10px; +} + +#navigation ul li#btn_profile { + border-left: 0; + padding: 0; + margin: 5px 10px; +} +#navigation ul li#btn_profile a { + border-left: 0; + padding: 0 10px; +} +#navigation ul li#btn_profile a img { + vertical-align: middle; +} +#navigation ul li#btn_profile span { + background: none; + padding: 0 0 0 5px; + color: rgb(170, 170, 170); + font-weight: bold; +} + +.icon-menu-tasks { + background-image: url(images/barra-menu-task.png); +} + +.btn_msg { + background: url(images/barra-menu-mail.png) no-repeat 10px center #eee; +} + + +/*tarefas da barra do usuário*/ +.task_list { + position: absolute; + background: #eee; + z-index: 9999; + margin-left: 50px; + visibility: visible; + display: block; +} + +#msg_list.task_list {margin-left: 122px;} + +.task_list ul {display: inline-block;padding-left: 0;} + +.task_list ul li { + float: none; + display: block; + padding: 10px; +} +.task_list ul .task_box { + border-bottom: 1px solid #ccc; + padding:16px; +} + +.task_icon { + float: left; + margin-right: 14px; +} + +.task_list ul .task_decisions { + clear: right; +} + +.task_information { + display: inline-block; + width: 300px; +} + +.task_list ul .task_title {margin-right: 0px !important} + +.task_list .button-bar{float: right;margin-right: 10px;} + +.task_list .button-bar a.button.with-text { + padding: 5px 10px; + padding-left: 20px; + padding-right: 5px; +} +.task_list .button-bar input.button.with-text { + max-height: 32px; + height: 32px; + padding: 0 25px; + padding-right: 10px; +} + +.task_list.hide {display: none; visibility: hidden;} + +/*FIM tarefas da barra do usuário*/ + + +/**/ + +/************* Bar Psocial Style - Menu Horizontal**************/ + +#user{ + font-size: 12px; + position: static; + z-index: 9; +} + +#user form { + top: -32px; + right: -200px; +} + +#user form input { + width: 180px; + height: 20px; +} + +#user .logged-in { + visibility: hidden; + display: block; + background:url("images/barra-menu-user-bg.png") repeat-x bottom center #FEFEFE; + display: block; + padding: 0; + text-align: left; + width: 130px; + border-radius: 10px +} + +#user .logged-in:hover { + visibility: visible; +} +#user .logged-in a#homepage-link { + visibility: visible; +} + + +#user .logged-in span.welcome { + display: none; +} + +#user .logged-in a { + width: auto; +} + +/*info do usuário na barra do usuário*/ +#top-bar .layout_user #user .logged-in a{text-decoration: none;} + +#top-bar .layout_user #user .logged-in { + visibility: visible; + display: block; + background: none; + display: block; + text-align: left; + width: auto; + border-radius: 0; + border: 0px; +} + +.btn_control_panel #user span.not-logged-in, +.btn_control_panel #user span.not-logged-in span { +margin: 5px 5px 5px 5px; +border: 0; +background-color: transparent; +padding: 3px; +color: #333; +} + +#top-bar .layout_user #user .not-logged-in a{text-decoration: none;} + +/*info do usuário no espaço do usuário*/ +#navigation-control{ + height: 100%; + overflow-y: scroll; + overflow-x: hidden; + background-color:gray; +} + +#navigation-control #user{margin-top: 0;width: 300px;} + + +#navigation-control #user .logged-in { + visibility: visible; + display: block; + background: none; + display: block; + padding: 5px; + text-align: left; + width: auto; + border-radius: 0; + border: 0px; + margin-top: 0; + padding: 0; + border-top: 0px solid #DDD; +} + +#navigation-control #user .logged-in a { + text-decoration: none; + color: #DDD; + background-color: #808080; + padding: 14px 28px; + margin: 0; + border-bottom: 1px solid #DDD; +} + +#navigation-control #user .logged-in a strong { +font-weight: normal; +color: #DDD; +background-color: #808080; +padding: 14px; +margin: 0; +border-bottom: 0px solid #DDD; +font-size: 16px; +font-family: Arial, sans-serif; +text-decoration: none; +} + +#navigation-control .menu_user .activity_menu{border-top: 0px solid #DDD;} + + +/*modificação da scroll bar DO ESPAÇO DO USUÁRIO*/ +#navigation-control::-webkit-scrollbar-button { + height: 0; + width: 0; +} + +#navigation-control::-webkit-scrollbar-thumb { + background-clip: padding-box; + background-color: gray;/*rgba(0,0,0,.3);*/ + border: 5px solid transparent; + border-radius: 10px; + min-height: 20px; + min-width: 20px; + height: 5px; + width: 5px; +} + +#navigation-control::-webkit-scrollbar-thumb:hover { + background-clip: padding-box; + background-color: #eee;/*rgba(0,0,0,.3);*/ + border: 5px solid transparent; + border-radius: 10px; + min-height: 20px; + min-width: 20px; + height: 5px; + width: 5px; +} + + +#navigation-control::-webkit-scrollbar { + height: 15px; + width: 15px; +} + +/*fim de modificação da scroll bar DO ESPAÇO DO USUÁRIO */ + +/****************** FIM Barra do usuário ******************/ + +/****************** FIM Barra do usuário e Menu do usuário ******************/ + + +/****************** Painel de Controle ******************/ + +.btn_home { + margin-right: 14px; + float: right; + line-height: 40px; +} + +.btn_home a{ + display: inline-block; + text-decoration: none; + margin-left: 5px; + width: 35px; + background: url("images/logo.png") no-repeat left center transparent; +} + +/*Botão Painel de controle*/ + +#btn_open_control_panel { +/* float: right;*/ +/* width: 100%;*/ + background-color: #eee; + position: relative; + padding: 0 14px; + text-decoration: none; + font-size: small; + color: #666; +} + +#navigation li span { + position: relative; + background: url("images/20-gear2.png") no-repeat left center transparent; + padding-left: 30px; + display: inline-block; + height: 30px; + line-height: 30px; + text-decoration: none; +} + +#btn_open_control_panel.show span {} + +/*****FIM Botão Painel de controle*****/ + +/*barra (menu) painel de controle*/ + +#control_panel_bar { + /*width: 100%;*/ + text-align: center; + display: inline-block; + padding-top: 0px; + overflow: hidden; + height: 0px; + transition: 0.6s; + /*margin-bottom: 14px;*/ + width: 100%; +} + +#control_panel_bar.show { + padding-top: 0px; + background-color: rgb(248, 248, 248); + height: 60px; +} + +#navigation { + text-align: right; + position: static; + background: none; + background-color: #eee; + border-bottom: 1px solid #d3d7cf; +} + +#navigation ul { + text-align: center; + height: auto; + float: none; + font-size: small; + color: #666; + padding: 0; +} +#wrap-1 #wrap-2 { + padding: 0; + border-top: none; +} + +#navigation #navigation-end { + width: 0px; + height: 0px; + background: none; + clear: both; +} + +#navigation ul li{ +border-left: 1px solid rgb(187, 187, 187); +padding: 0 14px; +width: auto; +margin: 12px 0; +float: right; +} +#navigation ul li:hover { + cursor: pointer; + background-color: rgb(112, 112, 112); + color: #FFF; +} + +#navigation ul li#btn_icon { + border: none; + padding: 4px; + margin: 0; + background: none; + cursor: auto; +} + +#control_panel_bar .btn_control_panel{ + float: none; +} + +#control_panel_bar #new_content{ + background-image: url(images/text-editor.png); + background-repeat: no-repeat; +} + +#control_panel_bar .btn_control { + background-position: center 3px; + height: 35px; + padding: 40px 14px 0px 14px; + display: inline-block; + width: 100px; + vertical-align: top; + background-size: 25%; +} + +#control_panel_bar .btn_menu{ + background-position: center 3px; + height: 0px; + overflow: hidden; + padding: 0px; + display: inline-block; + width: 100px; + vertical-align: top; + background-size: 25%; + transition: 0.6s; +} + +#control_panel_bar.show .btn_menu{ + background-position: center 3px; + height: 35px; + overflow: hidden; + padding: 40px 14px 0px 14px; + display: inline-block; + width: 100px; + vertical-align: top; + background-size: 25%; +} + +#control_panel_bar.show .btn_menu:hover{ + overflow: visible; +} + +/*Menu e SubMenu do Painel de controle*/ +#control_panel_bar a.btn_control_panel span{margin:0px; border: 0px solid gray;border-radius: 0px; background-color: transparent; padding: 0px;color: #333;display: inline-block;height: 35px;} + + +#control_panel_bar .btn_control_panel ul {display: inline-block;padding-left: 0;padding-top: 0;text-align: left;margin: 0;position: relative;left: -14px;} + +#control_panel_bar .btn_control_panel ul:hover {} + +#control_panel_bar .btn_control_panel ul li {padding: 0;display: block;display: inline-block;}/*{display: block;padding-left: 0;text-align: left;margin: 0;padding: 0 1em}*/ + +#control_panel_bar a.btn_control_panel:hover ul li{display: block;} + +#control_panel_bar a.btn_control_panel ul li span{height: auto;width: 140px;background-color: #eee;padding: 7px 14px;} + +#control_panel_bar a.btn_control_panel ul li span:hover{background-color: #ccc;} + +#control_panel_bar .btn_control_panel ul li ul {display: none;} + +#control_panel_bar .btn_control_panel ul.menu_conteudo li:hover ul {display: inline-block} +/*FIM Menu e SubMenu do Painel de controle*/ + +/* FIM barra (menu) painel de controle*/ + + + +/****************** FIM Painel de Controle ******************/ + + +#assets-menu { + background: #E8E8E8; + top: 35px; + left: 80px; + min-width: 132px; +} + +#assets-menu a { + border: 1px solid #E8E8E8; +} + +#categories_menu { + /*max-width: 960px;*/ + padding: 0 1em; + margin: auto; + float: left; +} + +#cat_menu { + background: url(images/logo-ps.png) no-repeat center left; + height: 40px; + padding-left: 70px; + +} + +#cat_menu li { + list-style: none; + font-size: 12px; + font-weight: bold; + padding: 0px 20px; + height: 100%; + text-transform: uppercase; +} + +#cat_menu li:hover { + background-color: #E1E4E4; +} + +#cat_menu li a { + line-height: 40px; + width: 100%; + height: 100%; + display: block; +} +/************* FIM Bar Psocial Style - Menu Horizontal**************/ + +/*ajuste no content*/ +#content{margin-top: 8px;} + + +/******************Footer - Rodapé**********************************/ + +#theme-footer { + background-color: #eee; + position: relative; + margin-bottom: 0; +} +} + +#footer-content { + background: #fff; +} + +#footer-logos { + background: #F28F00; + max-width: 100%; + padding: 2em 0; + height: 49px; +} + +#footer-logos div { + max-width: 960px; + margin: 0 auto; +} + +#footer-logos a { + display: block; + height: 49px; + float: left; +} + +#footer-logos span { + display: none; +} + +#footer-logos .logo-acesso { + background: transparent url(images/acesso-a-informacao.png) center center no-repeat; + width: 107px; +} + +#footer-logos .logo-brasil { + background: transparent url(images/brasil.png) center center no-repeat; + width: 153px; +} + +#footer-logos .logo-sgpr { + background: transparent url(images/sgpr.png) center center no-repeat; + width: 187px; + margin-right: 30px; +} + +#footer-logos .institucionais { + float: right; +} + +#footer-license { + max-width: 960px; + margin: 0 auto; + text-align: left; + padding: 19px; +} + +#footer-license p { + color: #F28F00; + text-align: left; +} + +#user #homepage-link { + background: url(images/barra-menu-control.png) no-repeat 10px center; + margin-left: 0px; +} +#user #homepage-link i { + display: none; +} + +#control_panel_bar .control-panel a { + margin: 0; + border: 0; + line-height: normal; + background-color: transparent; + background-size: 32px; + padding: 0 0 0 36px; + width: 120px; + font-size: 13px; + background-position: 0 0; + color: rgb(60, 60, 60); +} +#control_panel_bar .control-panel span { + background: none; + padding-left: 0; +} + +.controller-profile_editor a.icon-new { + background-image: url(../../../images/control-panel/text-editor.png); +} + +#openchat .unread-messages { + position: relative; + left: 27px; + border: 0; +} diff --git a/content_menu.html.erb b/content_menu.html.erb new file mode 100644 index 0000000..ffb8993 --- /dev/null +++ b/content_menu.html.erb @@ -0,0 +1,14 @@ + diff --git a/errors.css b/errors.css new file mode 100644 index 0000000..b78d6d1 --- /dev/null +++ b/errors.css @@ -0,0 +1,5 @@ +@import url(../base/errors.css); + +#logo { + background: url(images/logo-noosfero.png) no-repeat; +} diff --git a/favicon.ico b/favicon.ico new file mode 100644 index 0000000..ff2bde6 Binary files /dev/null and b/favicon.ico differ diff --git a/footer.html.erb b/footer.html.erb new file mode 100644 index 0000000..4e1a0bc --- /dev/null +++ b/footer.html.erb @@ -0,0 +1,7 @@ + + +<%= language_chooser(environment) %> diff --git a/header.html.erb b/header.html.erb new file mode 100644 index 0000000..11cb716 --- /dev/null +++ b/header.html.erb @@ -0,0 +1,21 @@ +<% user = (session[:user] && User.find_by_id(session[:user])) || nil %> +<%= theme_include "user_menu", :locals => {:person => user.person} if user %> + + + +
+
+
+ <%= render :partial => 'layouts/user' %> +
+
+ + +   +
+ + diff --git a/images/20-gear2.png b/images/20-gear2.png new file mode 100644 index 0000000..48b6f92 Binary files /dev/null and b/images/20-gear2.png differ diff --git a/images/503-logo.jpg b/images/503-logo.jpg new file mode 100644 index 0000000..9abf016 Binary files /dev/null and b/images/503-logo.jpg differ diff --git a/images/503-small.jpg b/images/503-small.jpg new file mode 100644 index 0000000..c2c0efa Binary files /dev/null and b/images/503-small.jpg differ diff --git a/images/503.jpg b/images/503.jpg new file mode 100644 index 0000000..5048c71 Binary files /dev/null and b/images/503.jpg differ diff --git a/images/acesso-a-informacao.png b/images/acesso-a-informacao.png new file mode 100644 index 0000000..fffec98 Binary files /dev/null and b/images/acesso-a-informacao.png differ diff --git a/images/acesso-a-infornacao.png b/images/acesso-a-infornacao.png new file mode 100644 index 0000000..fffec98 Binary files /dev/null and b/images/acesso-a-infornacao.png differ diff --git a/images/apagar.jpg b/images/apagar.jpg new file mode 100644 index 0000000..16b3221 Binary files /dev/null and b/images/apagar.jpg differ diff --git a/images/arrow_down.jpg b/images/arrow_down.jpg new file mode 100644 index 0000000..ae93957 Binary files /dev/null and b/images/arrow_down.jpg differ diff --git a/images/arrow_right.jpg b/images/arrow_right.jpg new file mode 100644 index 0000000..c91c8d0 Binary files /dev/null and b/images/arrow_right.jpg differ diff --git a/images/background_footer.png b/images/background_footer.png new file mode 100644 index 0000000..2082c3e Binary files /dev/null and b/images/background_footer.png differ diff --git a/images/balao-amarelo.png b/images/balao-amarelo.png new file mode 100644 index 0000000..a3adc03 Binary files /dev/null and b/images/balao-amarelo.png differ diff --git a/images/barra-menu-control.png b/images/barra-menu-control.png new file mode 100644 index 0000000..8c4ee5e Binary files /dev/null and b/images/barra-menu-control.png differ diff --git a/images/barra-menu-mail.png b/images/barra-menu-mail.png new file mode 100644 index 0000000..a733a94 Binary files /dev/null and b/images/barra-menu-mail.png differ diff --git a/images/barra-menu-task.png b/images/barra-menu-task.png new file mode 100644 index 0000000..abfee5c Binary files /dev/null and b/images/barra-menu-task.png differ diff --git a/images/barra-menu-user-bg.png b/images/barra-menu-user-bg.png new file mode 100644 index 0000000..08e7707 Binary files /dev/null and b/images/barra-menu-user-bg.png differ diff --git a/images/barra-menu/18-envelope.png b/images/barra-menu/18-envelope.png new file mode 100644 index 0000000..cbe22c5 Binary files /dev/null and b/images/barra-menu/18-envelope.png differ diff --git a/images/barra-menu/19-gear.png b/images/barra-menu/19-gear.png new file mode 100644 index 0000000..699445e Binary files /dev/null and b/images/barra-menu/19-gear.png differ diff --git a/images/barra-menu/20-gear2.png b/images/barra-menu/20-gear2.png new file mode 100644 index 0000000..48b6f92 Binary files /dev/null and b/images/barra-menu/20-gear2.png differ diff --git a/images/barra-menu/bell.png b/images/barra-menu/bell.png new file mode 100644 index 0000000..b564dd3 Binary files /dev/null and b/images/barra-menu/bell.png differ diff --git a/images/barra-menu/email 1.png b/images/barra-menu/email 1.png new file mode 100644 index 0000000..1ec2c3e Binary files /dev/null and b/images/barra-menu/email 1.png differ diff --git a/images/barra-menu/email 2.png b/images/barra-menu/email 2.png new file mode 100644 index 0000000..be2471f Binary files /dev/null and b/images/barra-menu/email 2.png differ diff --git a/images/barra-menu/engine.png b/images/barra-menu/engine.png new file mode 100644 index 0000000..934ac6c Binary files /dev/null and b/images/barra-menu/engine.png differ diff --git a/images/barra-menu/list 2.png b/images/barra-menu/list 2.png new file mode 100644 index 0000000..66070a5 Binary files /dev/null and b/images/barra-menu/list 2.png differ diff --git a/images/barra-psocial-bg-contarste.png b/images/barra-psocial-bg-contarste.png new file mode 100644 index 0000000..d533843 Binary files /dev/null and b/images/barra-psocial-bg-contarste.png differ diff --git a/images/barra-psocial-bg.png b/images/barra-psocial-bg.png new file mode 100644 index 0000000..c379867 Binary files /dev/null and b/images/barra-psocial-bg.png differ diff --git a/images/barra-psocial.png b/images/barra-psocial.png new file mode 100644 index 0000000..f2946eb Binary files /dev/null and b/images/barra-psocial.png differ diff --git a/images/bg-bloco-de-trilhas.png b/images/bg-bloco-de-trilhas.png new file mode 100644 index 0000000..df72b20 Binary files /dev/null and b/images/bg-bloco-de-trilhas.png differ diff --git a/images/bg-btn-buscar.png b/images/bg-btn-buscar.png new file mode 100644 index 0000000..0aba29c Binary files /dev/null and b/images/bg-btn-buscar.png differ diff --git a/images/bg-btn-ver-mais-1px.png b/images/bg-btn-ver-mais-1px.png new file mode 100644 index 0000000..1ffab6a Binary files /dev/null and b/images/bg-btn-ver-mais-1px.png differ diff --git a/images/bg-btn-ver-mais.png b/images/bg-btn-ver-mais.png new file mode 100644 index 0000000..c6d331d Binary files /dev/null and b/images/bg-btn-ver-mais.png differ diff --git a/images/bg-fundo-verde-tags.png b/images/bg-fundo-verde-tags.png new file mode 100644 index 0000000..82ca489 Binary files /dev/null and b/images/bg-fundo-verde-tags.png differ diff --git a/images/bg-linhas-cinza.png b/images/bg-linhas-cinza.png new file mode 100644 index 0000000..3dcb773 Binary files /dev/null and b/images/bg-linhas-cinza.png differ diff --git a/images/bg-menu-mobile-panel.png b/images/bg-menu-mobile-panel.png new file mode 100644 index 0000000..0a084bf Binary files /dev/null and b/images/bg-menu-mobile-panel.png differ diff --git a/images/bg-menu-mobile.png b/images/bg-menu-mobile.png new file mode 100644 index 0000000..3b7954f Binary files /dev/null and b/images/bg-menu-mobile.png differ diff --git a/images/bg-paginacao-preto.png b/images/bg-paginacao-preto.png new file mode 100644 index 0000000..5d8f15a Binary files /dev/null and b/images/bg-paginacao-preto.png differ diff --git a/images/bg-paginacao.png b/images/bg-paginacao.png new file mode 100644 index 0000000..1362729 Binary files /dev/null and b/images/bg-paginacao.png differ diff --git a/images/bg-palacio-do-planalto.jpg b/images/bg-palacio-do-planalto.jpg new file mode 100644 index 0000000..7034432 Binary files /dev/null and b/images/bg-palacio-do-planalto.jpg differ diff --git a/images/bg-palacio-do-planalto_old.jpg b/images/bg-palacio-do-planalto_old.jpg new file mode 100644 index 0000000..00db70d Binary files /dev/null and b/images/bg-palacio-do-planalto_old.jpg differ diff --git a/images/bg-titulo-interno.png b/images/bg-titulo-interno.png new file mode 100644 index 0000000..b186658 Binary files /dev/null and b/images/bg-titulo-interno.png differ diff --git a/images/bg-titulo-login.png b/images/bg-titulo-login.png new file mode 100644 index 0000000..3672fa0 Binary files /dev/null and b/images/bg-titulo-login.png differ diff --git a/images/bg_h1.gif b/images/bg_h1.gif new file mode 100644 index 0000000..2f5414f Binary files /dev/null and b/images/bg_h1.gif differ diff --git a/images/bg_h3_busca.gif b/images/bg_h3_busca.gif new file mode 100644 index 0000000..73faf7f Binary files /dev/null and b/images/bg_h3_busca.gif differ diff --git a/images/bg_tags.png b/images/bg_tags.png new file mode 100644 index 0000000..2e30379 Binary files /dev/null and b/images/bg_tags.png differ diff --git a/images/border-hor.png b/images/border-hor.png new file mode 100644 index 0000000..8c1f185 Binary files /dev/null and b/images/border-hor.png differ diff --git a/images/border-ver.png b/images/border-ver.png new file mode 100644 index 0000000..037ebdb Binary files /dev/null and b/images/border-ver.png differ diff --git a/images/botao-enviar-pairwise.png b/images/botao-enviar-pairwise.png new file mode 100644 index 0000000..9f5025b Binary files /dev/null and b/images/botao-enviar-pairwise.png differ diff --git a/images/brasil.png b/images/brasil.png new file mode 100644 index 0000000..0ac6ed2 Binary files /dev/null and b/images/brasil.png differ diff --git a/images/btn_busca.png b/images/btn_busca.png new file mode 100644 index 0000000..5e3dd03 Binary files /dev/null and b/images/btn_busca.png differ diff --git a/images/btn_cancelar_login.png b/images/btn_cancelar_login.png new file mode 100644 index 0000000..b081e5e Binary files /dev/null and b/images/btn_cancelar_login.png differ diff --git a/images/btn_commit.png b/images/btn_commit.png new file mode 100644 index 0000000..5e3dd03 Binary files /dev/null and b/images/btn_commit.png differ diff --git a/images/btn_continue.png b/images/btn_continue.png new file mode 100644 index 0000000..74445f1 Binary files /dev/null and b/images/btn_continue.png differ diff --git a/images/btn_duvida_pairwise.png b/images/btn_duvida_pairwise.png new file mode 100644 index 0000000..49f06ac Binary files /dev/null and b/images/btn_duvida_pairwise.png differ diff --git a/images/btn_duvida_pairwise_hover.png b/images/btn_duvida_pairwise_hover.png new file mode 100644 index 0000000..666f105 Binary files /dev/null and b/images/btn_duvida_pairwise_hover.png differ diff --git a/images/btn_entrar_login.png b/images/btn_entrar_login.png new file mode 100644 index 0000000..7900127 Binary files /dev/null and b/images/btn_entrar_login.png differ diff --git a/images/btn_entrar_login_hover.png b/images/btn_entrar_login_hover.png new file mode 100644 index 0000000..e3bb0d7 Binary files /dev/null and b/images/btn_entrar_login_hover.png differ diff --git a/images/bullet.png b/images/bullet.png new file mode 100644 index 0000000..e5fb945 Binary files /dev/null and b/images/bullet.png differ diff --git a/images/button-read-more-vazio-contraste.png b/images/button-read-more-vazio-contraste.png new file mode 100755 index 0000000..0be02f4 Binary files /dev/null and b/images/button-read-more-vazio-contraste.png differ diff --git a/images/button-read-more-vazio.png b/images/button-read-more-vazio.png new file mode 100644 index 0000000..fe2488e Binary files /dev/null and b/images/button-read-more-vazio.png differ diff --git a/images/button-read-more2.png b/images/button-read-more2.png new file mode 100644 index 0000000..6d0c0f0 Binary files /dev/null and b/images/button-read-more2.png differ diff --git a/images/cabecalho_pairwise.png b/images/cabecalho_pairwise.png new file mode 100755 index 0000000..6756212 Binary files /dev/null and b/images/cabecalho_pairwise.png differ diff --git a/images/cadeado.png b/images/cadeado.png new file mode 100644 index 0000000..f2e1c87 Binary files /dev/null and b/images/cadeado.png differ diff --git a/images/carta-comentarios.png b/images/carta-comentarios.png new file mode 100644 index 0000000..c72c4f2 Binary files /dev/null and b/images/carta-comentarios.png differ diff --git a/images/coala.jpeg b/images/coala.jpeg new file mode 100644 index 0000000..6e8eaac Binary files /dev/null and b/images/coala.jpeg differ diff --git a/images/comentarios.png b/images/comentarios.png new file mode 100644 index 0000000..f1855a3 Binary files /dev/null and b/images/comentarios.png differ diff --git a/images/em-destaque.png b/images/em-destaque.png new file mode 100644 index 0000000..d729d35 Binary files /dev/null and b/images/em-destaque.png differ diff --git a/images/enterprise-big.png b/images/enterprise-big.png new file mode 100644 index 0000000..12746e8 Binary files /dev/null and b/images/enterprise-big.png differ diff --git a/images/enterprise-icon.png b/images/enterprise-icon.png new file mode 100644 index 0000000..8f31987 Binary files /dev/null and b/images/enterprise-icon.png differ diff --git a/images/enterprise-minor.png b/images/enterprise-minor.png new file mode 100644 index 0000000..4460368 Binary files /dev/null and b/images/enterprise-minor.png differ diff --git a/images/enterprise-portrait.png b/images/enterprise-portrait.png new file mode 100644 index 0000000..637515b Binary files /dev/null and b/images/enterprise-portrait.png differ diff --git a/images/enterprise-thumb.png b/images/enterprise-thumb.png new file mode 100644 index 0000000..68f65e1 Binary files /dev/null and b/images/enterprise-thumb.png differ diff --git a/images/facebook-widget.png b/images/facebook-widget.png new file mode 100644 index 0000000..60fb8f8 Binary files /dev/null and b/images/facebook-widget.png differ diff --git a/images/facebook.png b/images/facebook.png new file mode 100644 index 0000000..5895cc6 Binary files /dev/null and b/images/facebook.png differ diff --git a/images/favicon.ico b/images/favicon.ico new file mode 100644 index 0000000..f8c4036 Binary files /dev/null and b/images/favicon.ico differ diff --git a/images/flag-en.gif b/images/flag-en.gif new file mode 100644 index 0000000..350aa05 Binary files /dev/null and b/images/flag-en.gif differ diff --git a/images/flag-en.png b/images/flag-en.png new file mode 100644 index 0000000..0f4fb95 Binary files /dev/null and b/images/flag-en.png differ diff --git a/images/flag-es.gif b/images/flag-es.gif new file mode 100644 index 0000000..b98c599 Binary files /dev/null and b/images/flag-es.gif differ diff --git a/images/flag-pt_br.png b/images/flag-pt_br.png new file mode 100644 index 0000000..f0e0221 Binary files /dev/null and b/images/flag-pt_br.png differ diff --git a/images/flickr.png b/images/flickr.png new file mode 100644 index 0000000..bc3aee7 Binary files /dev/null and b/images/flickr.png differ diff --git a/images/fundo-de-tela-amarelo.png b/images/fundo-de-tela-amarelo.png new file mode 100644 index 0000000..44ffb0d Binary files /dev/null and b/images/fundo-de-tela-amarelo.png differ diff --git a/images/google_follow.png b/images/google_follow.png new file mode 100644 index 0000000..385410f Binary files /dev/null and b/images/google_follow.png differ diff --git a/images/google_follow.svg b/images/google_follow.svg new file mode 100644 index 0000000..bc1ee39 --- /dev/null +++ b/images/google_follow.svg @@ -0,0 +1,23 @@ + + + + + + + + + + + + diff --git a/images/header.gif b/images/header.gif new file mode 100644 index 0000000..9e231ba Binary files /dev/null and b/images/header.gif differ diff --git a/images/hub-arrow-right.png b/images/hub-arrow-right.png new file mode 100644 index 0000000..6c65f4c Binary files /dev/null and b/images/hub-arrow-right.png differ diff --git a/images/hub-not-pinned-icon.png b/images/hub-not-pinned-icon.png new file mode 100644 index 0000000..9b510c8 Binary files /dev/null and b/images/hub-not-pinned-icon.png differ diff --git a/images/hub-not-promote-icon.png b/images/hub-not-promote-icon.png new file mode 100644 index 0000000..4f57c4e Binary files /dev/null and b/images/hub-not-promote-icon.png differ diff --git a/images/hub-pinned-icon.png b/images/hub-pinned-icon.png new file mode 100644 index 0000000..9b510c8 Binary files /dev/null and b/images/hub-pinned-icon.png differ diff --git a/images/hub-promote-icon.png b/images/hub-promote-icon.png new file mode 100644 index 0000000..4f57c4e Binary files /dev/null and b/images/hub-promote-icon.png differ diff --git a/images/hub-remove-icon.png b/images/hub-remove-icon.png new file mode 100644 index 0000000..1246778 Binary files /dev/null and b/images/hub-remove-icon.png differ diff --git a/images/hub-samarelo-a.png b/images/hub-samarelo-a.png new file mode 100644 index 0000000..453d2a4 Binary files /dev/null and b/images/hub-samarelo-a.png differ diff --git a/images/hub-samarelo-b.png b/images/hub-samarelo-b.png new file mode 100644 index 0000000..936bf46 Binary files /dev/null and b/images/hub-samarelo-b.png differ diff --git a/images/hub-samarelo.gif b/images/hub-samarelo.gif new file mode 100644 index 0000000..2da3de2 Binary files /dev/null and b/images/hub-samarelo.gif differ diff --git a/images/hub-sverde-a.png b/images/hub-sverde-a.png new file mode 100644 index 0000000..5bc1c40 Binary files /dev/null and b/images/hub-sverde-a.png differ diff --git a/images/hub-sverde-b.png b/images/hub-sverde-b.png new file mode 100644 index 0000000..ee21942 Binary files /dev/null and b/images/hub-sverde-b.png differ diff --git a/images/hub-svermelho-a.png b/images/hub-svermelho-a.png new file mode 100644 index 0000000..36d4dfc Binary files /dev/null and b/images/hub-svermelho-a.png differ diff --git a/images/hub-svermelho-b.png b/images/hub-svermelho-b.png new file mode 100644 index 0000000..6df643a Binary files /dev/null and b/images/hub-svermelho-b.png differ diff --git a/images/hub-time-bg.gif b/images/hub-time-bg.gif new file mode 100644 index 0000000..43032c7 Binary files /dev/null and b/images/hub-time-bg.gif differ diff --git a/images/icone-branco-facebook.png b/images/icone-branco-facebook.png new file mode 100644 index 0000000..5f4046c Binary files /dev/null and b/images/icone-branco-facebook.png differ diff --git a/images/icone-branco-flickr.png b/images/icone-branco-flickr.png new file mode 100644 index 0000000..bf9b974 Binary files /dev/null and b/images/icone-branco-flickr.png differ diff --git a/images/icone-branco-twitter.png b/images/icone-branco-twitter.png new file mode 100644 index 0000000..b91d361 Binary files /dev/null and b/images/icone-branco-twitter.png differ diff --git a/images/icone-branco-youtube.png b/images/icone-branco-youtube.png new file mode 100644 index 0000000..345983e Binary files /dev/null and b/images/icone-branco-youtube.png differ diff --git a/images/icone-facebook.gif b/images/icone-facebook.gif new file mode 100644 index 0000000..5cdbe68 Binary files /dev/null and b/images/icone-facebook.gif differ diff --git a/images/icone-facebook.png b/images/icone-facebook.png new file mode 100644 index 0000000..9e12698 Binary files /dev/null and b/images/icone-facebook.png differ diff --git a/images/icone-flickr.png b/images/icone-flickr.png new file mode 100644 index 0000000..fa805c1 Binary files /dev/null and b/images/icone-flickr.png differ diff --git a/images/icone-related-items.png b/images/icone-related-items.png new file mode 100644 index 0000000..59bac09 Binary files /dev/null and b/images/icone-related-items.png differ diff --git a/images/icone-twitter-branco.png b/images/icone-twitter-branco.png new file mode 100644 index 0000000..bb08da3 Binary files /dev/null and b/images/icone-twitter-branco.png differ diff --git a/images/icone-twitter.png b/images/icone-twitter.png new file mode 100644 index 0000000..2538edc Binary files /dev/null and b/images/icone-twitter.png differ diff --git a/images/icone-verde-facebook.png b/images/icone-verde-facebook.png new file mode 100644 index 0000000..18b907a Binary files /dev/null and b/images/icone-verde-facebook.png differ diff --git a/images/icone-verde-flickr.png b/images/icone-verde-flickr.png new file mode 100644 index 0000000..0d997cf Binary files /dev/null and b/images/icone-verde-flickr.png differ diff --git a/images/icone-verde-twitter.png b/images/icone-verde-twitter.png new file mode 100644 index 0000000..d0b3b5a Binary files /dev/null and b/images/icone-verde-twitter.png differ diff --git a/images/icone-verde-youtube.png b/images/icone-verde-youtube.png new file mode 100644 index 0000000..4ed1206 Binary files /dev/null and b/images/icone-verde-youtube.png differ diff --git a/images/icone-youtube.png b/images/icone-youtube.png new file mode 100644 index 0000000..003c75b Binary files /dev/null and b/images/icone-youtube.png differ diff --git a/images/img-padrao-comunidade.png b/images/img-padrao-comunidade.png new file mode 100644 index 0000000..4e6aa39 Binary files /dev/null and b/images/img-padrao-comunidade.png differ diff --git a/images/img-padrao-usuario-grande.png b/images/img-padrao-usuario-grande.png new file mode 100644 index 0000000..8f22233 Binary files /dev/null and b/images/img-padrao-usuario-grande.png differ diff --git a/images/img-padrao-usuario.png b/images/img-padrao-usuario.png new file mode 100644 index 0000000..76ad7aa Binary files /dev/null and b/images/img-padrao-usuario.png differ diff --git a/images/img_login_popUp.png b/images/img_login_popUp.png new file mode 100644 index 0000000..ce82e38 Binary files /dev/null and b/images/img_login_popUp.png differ diff --git a/images/instagram-widget.png b/images/instagram-widget.png new file mode 100644 index 0000000..b51f7de Binary files /dev/null and b/images/instagram-widget.png differ diff --git a/images/logo-PS-barra-pb.png b/images/logo-PS-barra-pb.png new file mode 100644 index 0000000..f9f9d42 Binary files /dev/null and b/images/logo-PS-barra-pb.png differ diff --git a/images/logo-PS-barra.png b/images/logo-PS-barra.png new file mode 100644 index 0000000..77c694e Binary files /dev/null and b/images/logo-PS-barra.png differ diff --git a/images/logo-noosfero-no-text.png b/images/logo-noosfero-no-text.png new file mode 100644 index 0000000..9001ea7 Binary files /dev/null and b/images/logo-noosfero-no-text.png differ diff --git a/images/logo-noosfero.png b/images/logo-noosfero.png new file mode 100644 index 0000000..6fbb2a8 Binary files /dev/null and b/images/logo-noosfero.png differ diff --git a/images/logo-noosfero.xcf b/images/logo-noosfero.xcf new file mode 100644 index 0000000..a90a5eb Binary files /dev/null and b/images/logo-noosfero.xcf differ diff --git a/images/logo-participa.png b/images/logo-participa.png new file mode 100644 index 0000000..436bceb Binary files /dev/null and b/images/logo-participa.png differ diff --git a/images/logo-ps.png b/images/logo-ps.png new file mode 100644 index 0000000..a9c6bcb Binary files /dev/null and b/images/logo-ps.png differ diff --git a/images/logo.png b/images/logo.png new file mode 100644 index 0000000..73123bc Binary files /dev/null and b/images/logo.png differ diff --git a/images/logo_facebook_50x50.png b/images/logo_facebook_50x50.png new file mode 100644 index 0000000..7e5fdb3 Binary files /dev/null and b/images/logo_facebook_50x50.png differ diff --git a/images/logo_twitter_50x50.png b/images/logo_twitter_50x50.png new file mode 100644 index 0000000..4ffd721 Binary files /dev/null and b/images/logo_twitter_50x50.png differ diff --git a/images/logo_twitter_bird_blue_50x50.png b/images/logo_twitter_bird_blue_50x50.png new file mode 100644 index 0000000..a43574b Binary files /dev/null and b/images/logo_twitter_bird_blue_50x50.png differ diff --git a/images/logo_twitter_bird_white_50x50.png b/images/logo_twitter_bird_white_50x50.png new file mode 100644 index 0000000..90fdebd Binary files /dev/null and b/images/logo_twitter_bird_white_50x50.png differ diff --git a/images/mais_fotos.png b/images/mais_fotos.png new file mode 100644 index 0000000..9aa88f0 Binary files /dev/null and b/images/mais_fotos.png differ diff --git a/images/marca-participacao-social.png b/images/marca-participacao-social.png new file mode 100644 index 0000000..4ad05e3 Binary files /dev/null and b/images/marca-participacao-social.png differ diff --git a/images/mascote-bug.png b/images/mascote-bug.png new file mode 100644 index 0000000..e9f98ec Binary files /dev/null and b/images/mascote-bug.png differ diff --git a/images/menu-ativo.gif b/images/menu-ativo.gif new file mode 100644 index 0000000..89415eb Binary files /dev/null and b/images/menu-ativo.gif differ diff --git a/images/menu-mobile-itemx.png b/images/menu-mobile-itemx.png new file mode 100644 index 0000000..d3fa756 Binary files /dev/null and b/images/menu-mobile-itemx.png differ diff --git a/images/negative-hand.png b/images/negative-hand.png new file mode 100644 index 0000000..59804b4 Binary files /dev/null and b/images/negative-hand.png differ diff --git a/images/no-image.gif b/images/no-image.gif new file mode 100644 index 0000000..e565824 Binary files /dev/null and b/images/no-image.gif differ diff --git a/images/no-image.png b/images/no-image.png new file mode 100644 index 0000000..34340e5 Binary files /dev/null and b/images/no-image.png differ diff --git a/images/oops.png b/images/oops.png new file mode 100644 index 0000000..ddeb2dd Binary files /dev/null and b/images/oops.png differ diff --git a/images/person-minor.png b/images/person-minor.png new file mode 100644 index 0000000..b410d88 Binary files /dev/null and b/images/person-minor.png differ diff --git a/images/person-minor_50.png b/images/person-minor_50.png new file mode 100644 index 0000000..7bf25a3 Binary files /dev/null and b/images/person-minor_50.png differ diff --git a/images/portlet-footer-textmore.png b/images/portlet-footer-textmore.png new file mode 100644 index 0000000..777d1af Binary files /dev/null and b/images/portlet-footer-textmore.png differ diff --git a/images/portlet-header-expanded.gif b/images/portlet-header-expanded.gif new file mode 100644 index 0000000..a46eb43 Binary files /dev/null and b/images/portlet-header-expanded.gif differ diff --git a/images/portlet-header.gif b/images/portlet-header.gif new file mode 100644 index 0000000..6aa5d3f Binary files /dev/null and b/images/portlet-header.gif differ diff --git a/images/positive-hand.png b/images/positive-hand.png new file mode 100644 index 0000000..44c85ca Binary files /dev/null and b/images/positive-hand.png differ diff --git a/images/prompt_bg.png b/images/prompt_bg.png new file mode 100644 index 0000000..5a8ce78 Binary files /dev/null and b/images/prompt_bg.png differ diff --git a/images/prompt_bg_hover.png b/images/prompt_bg_hover.png new file mode 100644 index 0000000..25eb01e Binary files /dev/null and b/images/prompt_bg_hover.png differ diff --git a/images/prompt_bg_normal.png b/images/prompt_bg_normal.png new file mode 100644 index 0000000..c8cc9c1 Binary files /dev/null and b/images/prompt_bg_normal.png differ diff --git a/images/rails.png b/images/rails.png new file mode 100644 index 0000000..b8441f1 Binary files /dev/null and b/images/rails.png differ diff --git a/images/read-more-home.png b/images/read-more-home.png new file mode 100644 index 0000000..a39fcd0 Binary files /dev/null and b/images/read-more-home.png differ diff --git a/images/readmoreblue.png b/images/readmoreblue.png new file mode 100644 index 0000000..74408e3 Binary files /dev/null and b/images/readmoreblue.png differ diff --git a/images/readmorebrown.png b/images/readmorebrown.png new file mode 100644 index 0000000..291a6e8 Binary files /dev/null and b/images/readmorebrown.png differ diff --git a/images/readmoredarkblue.png b/images/readmoredarkblue.png new file mode 100644 index 0000000..18eacef Binary files /dev/null and b/images/readmoredarkblue.png differ diff --git a/images/readmoredarkgray.png b/images/readmoredarkgray.png new file mode 100644 index 0000000..898ac8b Binary files /dev/null and b/images/readmoredarkgray.png differ diff --git a/images/readmoregray.png b/images/readmoregray.png new file mode 100644 index 0000000..4ead1c0 Binary files /dev/null and b/images/readmoregray.png differ diff --git a/images/readmoregreen.png b/images/readmoregreen.png new file mode 100644 index 0000000..8c486b8 Binary files /dev/null and b/images/readmoregreen.png differ diff --git a/images/readmoreorange.png b/images/readmoreorange.png new file mode 100644 index 0000000..d5f5a01 Binary files /dev/null and b/images/readmoreorange.png differ diff --git a/images/readmorepurple.png b/images/readmorepurple.png new file mode 100644 index 0000000..ad9f569 Binary files /dev/null and b/images/readmorepurple.png differ diff --git a/images/readmorewhiteblue.png b/images/readmorewhiteblue.png new file mode 100644 index 0000000..98b89ba Binary files /dev/null and b/images/readmorewhiteblue.png differ diff --git a/images/reportar-erros.png b/images/reportar-erros.png new file mode 100644 index 0000000..b28c2a1 Binary files /dev/null and b/images/reportar-erros.png differ diff --git a/images/rss.png b/images/rss.png new file mode 100644 index 0000000..7661d92 Binary files /dev/null and b/images/rss.png differ diff --git a/images/rss.svg b/images/rss.svg new file mode 100644 index 0000000..8256f3b --- /dev/null +++ b/images/rss.svg @@ -0,0 +1,14 @@ + + + + + + + + + + + diff --git a/images/search-buttom.gif b/images/search-buttom.gif new file mode 100644 index 0000000..460a98e Binary files /dev/null and b/images/search-buttom.gif differ diff --git a/images/search-button-30px.gif b/images/search-button-30px.gif new file mode 100644 index 0000000..3ea65f2 Binary files /dev/null and b/images/search-button-30px.gif differ diff --git a/images/search-button.gif b/images/search-button.gif new file mode 100644 index 0000000..460a98e Binary files /dev/null and b/images/search-button.gif differ diff --git a/images/search-ico.png b/images/search-ico.png new file mode 100644 index 0000000..6d102ce Binary files /dev/null and b/images/search-ico.png differ diff --git a/images/search.png b/images/search.png new file mode 100644 index 0000000..757f6a5 Binary files /dev/null and b/images/search.png differ diff --git a/images/sections-ico.png b/images/sections-ico.png new file mode 100644 index 0000000..4ba2a1e Binary files /dev/null and b/images/sections-ico.png differ diff --git a/images/seta_cidadania_justica.png b/images/seta_cidadania_justica.png new file mode 100644 index 0000000..242a3a2 Binary files /dev/null and b/images/seta_cidadania_justica.png differ diff --git a/images/seta_ciencia_tecnologia.png b/images/seta_ciencia_tecnologia.png new file mode 100644 index 0000000..ae05455 Binary files /dev/null and b/images/seta_ciencia_tecnologia.png differ diff --git a/images/seta_cultura.png b/images/seta_cultura.png new file mode 100644 index 0000000..d221d2c Binary files /dev/null and b/images/seta_cultura.png differ diff --git a/images/seta_defesa_seguranca.png b/images/seta_defesa_seguranca.png new file mode 100644 index 0000000..2668bd1 Binary files /dev/null and b/images/seta_defesa_seguranca.png differ diff --git a/images/seta_economia_emprego.png b/images/seta_economia_emprego.png new file mode 100644 index 0000000..ff79913 Binary files /dev/null and b/images/seta_economia_emprego.png differ diff --git a/images/seta_educacao.png b/images/seta_educacao.png new file mode 100644 index 0000000..7934c02 Binary files /dev/null and b/images/seta_educacao.png differ diff --git a/images/seta_esporte.png b/images/seta_esporte.png new file mode 100644 index 0000000..dd484c6 Binary files /dev/null and b/images/seta_esporte.png differ diff --git a/images/seta_governo.png b/images/seta_governo.png new file mode 100644 index 0000000..7d6341d Binary files /dev/null and b/images/seta_governo.png differ diff --git a/images/seta_infraestrutura.png b/images/seta_infraestrutura.png new file mode 100644 index 0000000..66cdff1 Binary files /dev/null and b/images/seta_infraestrutura.png differ diff --git a/images/seta_meio_ambiente.png b/images/seta_meio_ambiente.png new file mode 100644 index 0000000..2079b67 Binary files /dev/null and b/images/seta_meio_ambiente.png differ diff --git a/images/seta_saude.png b/images/seta_saude.png new file mode 100644 index 0000000..8cd6d10 Binary files /dev/null and b/images/seta_saude.png differ diff --git a/images/seta_tursimo.png b/images/seta_tursimo.png new file mode 100644 index 0000000..ed796e4 Binary files /dev/null and b/images/seta_tursimo.png differ diff --git a/images/sgpr.png b/images/sgpr.png new file mode 100644 index 0000000..0c6187e Binary files /dev/null and b/images/sgpr.png differ diff --git a/images/shadow-bottom.gif b/images/shadow-bottom.gif new file mode 100644 index 0000000..f804faa Binary files /dev/null and b/images/shadow-bottom.gif differ diff --git a/images/site-footer.png b/images/site-footer.png new file mode 100644 index 0000000..ce5e61d Binary files /dev/null and b/images/site-footer.png differ diff --git a/images/sprite-icons.png b/images/sprite-icons.png new file mode 100644 index 0000000..70781ca Binary files /dev/null and b/images/sprite-icons.png differ diff --git a/images/sprite-setas.png b/images/sprite-setas.png new file mode 100644 index 0000000..4537a80 Binary files /dev/null and b/images/sprite-setas.png differ diff --git a/images/sprite.png b/images/sprite.png new file mode 100644 index 0000000..440acbb Binary files /dev/null and b/images/sprite.png differ diff --git a/images/sprite_social-2.png b/images/sprite_social-2.png new file mode 100644 index 0000000..f9f90a6 Binary files /dev/null and b/images/sprite_social-2.png differ diff --git a/images/sprite_social-verde.png b/images/sprite_social-verde.png new file mode 100644 index 0000000..87eb3f5 Binary files /dev/null and b/images/sprite_social-verde.png differ diff --git a/images/sprite_social.png b/images/sprite_social.png new file mode 100644 index 0000000..300cb9d Binary files /dev/null and b/images/sprite_social.png differ diff --git a/images/steps_bg.png b/images/steps_bg.png new file mode 100644 index 0000000..430b99d Binary files /dev/null and b/images/steps_bg.png differ diff --git a/images/text-editor.png b/images/text-editor.png new file mode 100644 index 0000000..0365687 Binary files /dev/null and b/images/text-editor.png differ diff --git a/images/thin-logo.png b/images/thin-logo.png new file mode 100644 index 0000000..1aeb9fc Binary files /dev/null and b/images/thin-logo.png differ diff --git a/images/thin-logo.xcf b/images/thin-logo.xcf new file mode 100644 index 0000000..d8ccb03 Binary files /dev/null and b/images/thin-logo.xcf differ diff --git a/images/touch_icon.png b/images/touch_icon.png new file mode 100644 index 0000000..98c3ad4 Binary files /dev/null and b/images/touch_icon.png differ diff --git a/images/twitter-widget.png b/images/twitter-widget.png new file mode 100644 index 0000000..e0cd726 Binary files /dev/null and b/images/twitter-widget.png differ diff --git a/images/twitter.png b/images/twitter.png new file mode 100644 index 0000000..aededc4 Binary files /dev/null and b/images/twitter.png differ diff --git a/images/usuario_participa.png b/images/usuario_participa.png new file mode 100644 index 0000000..a86a6a3 Binary files /dev/null and b/images/usuario_participa.png differ diff --git a/images/visualizacoes.png b/images/visualizacoes.png new file mode 100644 index 0000000..9a014d5 Binary files /dev/null and b/images/visualizacoes.png differ diff --git a/images/voltar-topo.png b/images/voltar-topo.png new file mode 100644 index 0000000..3303386 Binary files /dev/null and b/images/voltar-topo.png differ diff --git a/images/youtube.png b/images/youtube.png new file mode 100644 index 0000000..22b1fb7 Binary files /dev/null and b/images/youtube.png differ diff --git a/index.html.erb b/index.html.erb new file mode 100644 index 0000000..0911d06 --- /dev/null +++ b/index.html.erb @@ -0,0 +1,91 @@ + + + + <%= h page_title %> + <%= yield(:feeds) %> + + + + + + + + + + + + + + + + + <% if @page %> + + <% @page.body_images_paths.each do |img| %> + + + <% end %> + <% end %> + + + <%= noosfero_javascript %> + <%= noosfero_stylesheets %> + + <%# Add custom tags/styles/etc via content_for %> + <%= yield :head %> + <%= + @plugins.dispatch(:head_ending).collect do |content| + content.respond_to?(:call) ? content.call : content + end.join("\n") + %> + + + + + + <%= _("Go to the content") %> + + <%= + @plugins.dispatch(:body_beginning).collect do |content| + content.respond_to?(:call) ? content.call : content + end.join("\n") + %> + +
+ + +
+ <%= theme_header %> +
+ + +
+ + + +

+ <%= theme_site_title %> +

+ + + +
+
+ <%= insert_boxes(yield) %> +
+
+
+
+
+ <%= render_environment_features(:logged_in) %> + + <%= noosfero_layout_features %> + <%= theme_javascript_ng %> + <%= addthis_javascript %> + + diff --git a/js/jquery.js b/js/jquery.js new file mode 100644 index 0000000..3b8d15d --- /dev/null +++ b/js/jquery.js @@ -0,0 +1,2 @@ +/*! jQuery v@1.8.1 jquery.com | jquery.org/license */ +(function(a,b){function G(a){var b=F[a]={};return p.each(a.split(s),function(a,c){b[c]=!0}),b}function J(a,c,d){if(d===b&&a.nodeType===1){var e="data-"+c.replace(I,"-$1").toLowerCase();d=a.getAttribute(e);if(typeof d=="string"){try{d=d==="true"?!0:d==="false"?!1:d==="null"?null:+d+""===d?+d:H.test(d)?p.parseJSON(d):d}catch(f){}p.data(a,c,d)}else d=b}return d}function K(a){var b;for(b in a){if(b==="data"&&p.isEmptyObject(a[b]))continue;if(b!=="toJSON")return!1}return!0}function ba(){return!1}function bb(){return!0}function bh(a){return!a||!a.parentNode||a.parentNode.nodeType===11}function bi(a,b){do a=a[b];while(a&&a.nodeType!==1);return a}function bj(a,b,c){b=b||0;if(p.isFunction(b))return p.grep(a,function(a,d){var e=!!b.call(a,d,a);return e===c});if(b.nodeType)return p.grep(a,function(a,d){return a===b===c});if(typeof b=="string"){var d=p.grep(a,function(a){return a.nodeType===1});if(be.test(b))return p.filter(b,d,!c);b=p.filter(b,d)}return p.grep(a,function(a,d){return p.inArray(a,b)>=0===c})}function bk(a){var b=bl.split("|"),c=a.createDocumentFragment();if(c.createElement)while(b.length)c.createElement(b.pop());return c}function bC(a,b){return a.getElementsByTagName(b)[0]||a.appendChild(a.ownerDocument.createElement(b))}function bD(a,b){if(b.nodeType!==1||!p.hasData(a))return;var c,d,e,f=p._data(a),g=p._data(b,f),h=f.events;if(h){delete g.handle,g.events={};for(c in h)for(d=0,e=h[c].length;d").appendTo(e.body),c=b.css("display");b.remove();if(c==="none"||c===""){bI=e.body.appendChild(bI||p.extend(e.createElement("iframe"),{frameBorder:0,width:0,height:0}));if(!bJ||!bI.createElement)bJ=(bI.contentWindow||bI.contentDocument).document,bJ.write(""),bJ.close();b=bJ.body.appendChild(bJ.createElement(a)),c=bH(b,"display"),e.body.removeChild(bI)}return bS[a]=c,c}function ci(a,b,c,d){var e;if(p.isArray(b))p.each(b,function(b,e){c||ce.test(a)?d(a,e):ci(a+"["+(typeof e=="object"?b:"")+"]",e,c,d)});else if(!c&&p.type(b)==="object")for(e in b)ci(a+"["+e+"]",b[e],c,d);else d(a,b)}function cz(a){return function(b,c){typeof b!="string"&&(c=b,b="*");var d,e,f,g=b.toLowerCase().split(s),h=0,i=g.length;if(p.isFunction(c))for(;h)[^>]*$|#([\w\-]*)$)/,v=/^<(\w+)\s*\/?>(?:<\/\1>|)$/,w=/^[\],:{}\s]*$/,x=/(?:^|:|,)(?:\s*\[)+/g,y=/\\(?:["\\\/bfnrt]|u[\da-fA-F]{4})/g,z=/"[^"\\\r\n]*"|true|false|null|-?(?:\d\d*\.|)\d+(?:[eE][\-+]?\d+|)/g,A=/^-ms-/,B=/-([\da-z])/gi,C=function(a,b){return(b+"").toUpperCase()},D=function(){e.addEventListener?(e.removeEventListener("DOMContentLoaded",D,!1),p.ready()):e.readyState==="complete"&&(e.detachEvent("onreadystatechange",D),p.ready())},E={};p.fn=p.prototype={constructor:p,init:function(a,c,d){var f,g,h,i;if(!a)return this;if(a.nodeType)return this.context=this[0]=a,this.length=1,this;if(typeof a=="string"){a.charAt(0)==="<"&&a.charAt(a.length-1)===">"&&a.length>=3?f=[null,a,null]:f=u.exec(a);if(f&&(f[1]||!c)){if(f[1])return c=c instanceof p?c[0]:c,i=c&&c.nodeType?c.ownerDocument||c:e,a=p.parseHTML(f[1],i,!0),v.test(f[1])&&p.isPlainObject(c)&&this.attr.call(a,c,!0),p.merge(this,a);g=e.getElementById(f[2]);if(g&&g.parentNode){if(g.id!==f[2])return d.find(a);this.length=1,this[0]=g}return this.context=e,this.selector=a,this}return!c||c.jquery?(c||d).find(a):this.constructor(c).find(a)}return p.isFunction(a)?d.ready(a):(a.selector!==b&&(this.selector=a.selector,this.context=a.context),p.makeArray(a,this))},selector:"",jquery:"1.8.1",length:0,size:function(){return this.length},toArray:function(){return k.call(this)},get:function(a){return a==null?this.toArray():a<0?this[this.length+a]:this[a]},pushStack:function(a,b,c){var d=p.merge(this.constructor(),a);return d.prevObject=this,d.context=this.context,b==="find"?d.selector=this.selector+(this.selector?" ":"")+c:b&&(d.selector=this.selector+"."+b+"("+c+")"),d},each:function(a,b){return p.each(this,a,b)},ready:function(a){return p.ready.promise().done(a),this},eq:function(a){return a=+a,a===-1?this.slice(a):this.slice(a,a+1)},first:function(){return this.eq(0)},last:function(){return this.eq(-1)},slice:function(){return this.pushStack(k.apply(this,arguments),"slice",k.call(arguments).join(","))},map:function(a){return this.pushStack(p.map(this,function(b,c){return a.call(b,c,b)}))},end:function(){return this.prevObject||this.constructor(null)},push:j,sort:[].sort,splice:[].splice},p.fn.init.prototype=p.fn,p.extend=p.fn.extend=function(){var a,c,d,e,f,g,h=arguments[0]||{},i=1,j=arguments.length,k=!1;typeof h=="boolean"&&(k=h,h=arguments[1]||{},i=2),typeof h!="object"&&!p.isFunction(h)&&(h={}),j===i&&(h=this,--i);for(;i0)return;d.resolveWith(e,[p]),p.fn.trigger&&p(e).trigger("ready").off("ready")},isFunction:function(a){return p.type(a)==="function"},isArray:Array.isArray||function(a){return p.type(a)==="array"},isWindow:function(a){return a!=null&&a==a.window},isNumeric:function(a){return!isNaN(parseFloat(a))&&isFinite(a)},type:function(a){return a==null?String(a):E[m.call(a)]||"object"},isPlainObject:function(a){if(!a||p.type(a)!=="object"||a.nodeType||p.isWindow(a))return!1;try{if(a.constructor&&!n.call(a,"constructor")&&!n.call(a.constructor.prototype,"isPrototypeOf"))return!1}catch(c){return!1}var d;for(d in a);return d===b||n.call(a,d)},isEmptyObject:function(a){var b;for(b in a)return!1;return!0},error:function(a){throw new Error(a)},parseHTML:function(a,b,c){var d;return!a||typeof a!="string"?null:(typeof b=="boolean"&&(c=b,b=0),b=b||e,(d=v.exec(a))?[b.createElement(d[1])]:(d=p.buildFragment([a],b,c?null:[]),p.merge([],(d.cacheable?p.clone(d.fragment):d.fragment).childNodes)))},parseJSON:function(b){if(!b||typeof b!="string")return null;b=p.trim(b);if(a.JSON&&a.JSON.parse)return a.JSON.parse(b);if(w.test(b.replace(y,"@").replace(z,"]").replace(x,"")))return(new Function("return "+b))();p.error("Invalid JSON: "+b)},parseXML:function(c){var d,e;if(!c||typeof c!="string")return null;try{a.DOMParser?(e=new DOMParser,d=e.parseFromString(c,"text/xml")):(d=new ActiveXObject("Microsoft.XMLDOM"),d.async="false",d.loadXML(c))}catch(f){d=b}return(!d||!d.documentElement||d.getElementsByTagName("parsererror").length)&&p.error("Invalid XML: "+c),d},noop:function(){},globalEval:function(b){b&&r.test(b)&&(a.execScript||function(b){a.eval.call(a,b)})(b)},camelCase:function(a){return a.replace(A,"ms-").replace(B,C)},nodeName:function(a,b){return a.nodeName&&a.nodeName.toUpperCase()===b.toUpperCase()},each:function(a,c,d){var e,f=0,g=a.length,h=g===b||p.isFunction(a);if(d){if(h){for(e in a)if(c.apply(a[e],d)===!1)break}else for(;f0&&a[0]&&a[i-1]||i===0||p.isArray(a));if(j)for(;h-1)i.splice(c,1),e&&(c<=g&&g--,c<=h&&h--)}),this},has:function(a){return p.inArray(a,i)>-1},empty:function(){return i=[],this},disable:function(){return i=j=c=b,this},disabled:function(){return!i},lock:function(){return j=b,c||l.disable(),this},locked:function(){return!j},fireWith:function(a,b){return b=b||[],b=[a,b.slice?b.slice():b],i&&(!d||j)&&(e?j.push(b):k(b)),this},fire:function(){return l.fireWith(this,arguments),this},fired:function(){return!!d}};return l},p.extend({Deferred:function(a){var b=[["resolve","done",p.Callbacks("once memory"),"resolved"],["reject","fail",p.Callbacks("once memory"),"rejected"],["notify","progress",p.Callbacks("memory")]],c="pending",d={state:function(){return c},always:function(){return e.done(arguments).fail(arguments),this},then:function(){var a=arguments;return p.Deferred(function(c){p.each(b,function(b,d){var f=d[0],g=a[b];e[d[1]](p.isFunction(g)?function(){var a=g.apply(this,arguments);a&&p.isFunction(a.promise)?a.promise().done(c.resolve).fail(c.reject).progress(c.notify):c[f+"With"](this===e?c:this,[a])}:c[f])}),a=null}).promise()},promise:function(a){return typeof a=="object"?p.extend(a,d):d}},e={};return d.pipe=d.then,p.each(b,function(a,f){var g=f[2],h=f[3];d[f[1]]=g.add,h&&g.add(function(){c=h},b[a^1][2].disable,b[2][2].lock),e[f[0]]=g.fire,e[f[0]+"With"]=g.fireWith}),d.promise(e),a&&a.call(e,e),e},when:function(a){var b=0,c=k.call(arguments),d=c.length,e=d!==1||a&&p.isFunction(a.promise)?d:0,f=e===1?a:p.Deferred(),g=function(a,b,c){return function(d){b[a]=this,c[a]=arguments.length>1?k.call(arguments):d,c===h?f.notifyWith(b,c):--e||f.resolveWith(b,c)}},h,i,j;if(d>1){h=new Array(d),i=new Array(d),j=new Array(d);for(;b
a",c=n.getElementsByTagName("*"),d=n.getElementsByTagName("a")[0],d.style.cssText="top:1px;float:left;opacity:.5";if(!c||!c.length||!d)return{};f=e.createElement("select"),g=f.appendChild(e.createElement("option")),h=n.getElementsByTagName("input")[0],b={leadingWhitespace:n.firstChild.nodeType===3,tbody:!n.getElementsByTagName("tbody").length,htmlSerialize:!!n.getElementsByTagName("link").length,style:/top/.test(d.getAttribute("style")),hrefNormalized:d.getAttribute("href")==="/a",opacity:/^0.5/.test(d.style.opacity),cssFloat:!!d.style.cssFloat,checkOn:h.value==="on",optSelected:g.selected,getSetAttribute:n.className!=="t",enctype:!!e.createElement("form").enctype,html5Clone:e.createElement("nav").cloneNode(!0).outerHTML!=="<:nav>",boxModel:e.compatMode==="CSS1Compat",submitBubbles:!0,changeBubbles:!0,focusinBubbles:!1,deleteExpando:!0,noCloneEvent:!0,inlineBlockNeedsLayout:!1,shrinkWrapBlocks:!1,reliableMarginRight:!0,boxSizingReliable:!0,pixelPosition:!1},h.checked=!0,b.noCloneChecked=h.cloneNode(!0).checked,f.disabled=!0,b.optDisabled=!g.disabled;try{delete n.test}catch(o){b.deleteExpando=!1}!n.addEventListener&&n.attachEvent&&n.fireEvent&&(n.attachEvent("onclick",m=function(){b.noCloneEvent=!1}),n.cloneNode(!0).fireEvent("onclick"),n.detachEvent("onclick",m)),h=e.createElement("input"),h.value="t",h.setAttribute("type","radio"),b.radioValue=h.value==="t",h.setAttribute("checked","checked"),h.setAttribute("name","t"),n.appendChild(h),i=e.createDocumentFragment(),i.appendChild(n.lastChild),b.checkClone=i.cloneNode(!0).cloneNode(!0).lastChild.checked,b.appendChecked=h.checked,i.removeChild(h),i.appendChild(n);if(n.attachEvent)for(k in{submit:!0,change:!0,focusin:!0})j="on"+k,l=j in n,l||(n.setAttribute(j,"return;"),l=typeof n[j]=="function"),b[k+"Bubbles"]=l;return p(function(){var c,d,f,g,h="padding:0;margin:0;border:0;display:block;overflow:hidden;",i=e.getElementsByTagName("body")[0];if(!i)return;c=e.createElement("div"),c.style.cssText="visibility:hidden;border:0;width:0;height:0;position:static;top:0;margin-top:1px",i.insertBefore(c,i.firstChild),d=e.createElement("div"),c.appendChild(d),d.innerHTML="
t
",f=d.getElementsByTagName("td"),f[0].style.cssText="padding:0;margin:0;border:0;display:none",l=f[0].offsetHeight===0,f[0].style.display="",f[1].style.display="none",b.reliableHiddenOffsets=l&&f[0].offsetHeight===0,d.innerHTML="",d.style.cssText="box-sizing:border-box;-moz-box-sizing:border-box;-webkit-box-sizing:border-box;padding:1px;border:1px;display:block;width:4px;margin-top:1%;position:absolute;top:1%;",b.boxSizing=d.offsetWidth===4,b.doesNotIncludeMarginInBodyOffset=i.offsetTop!==1,a.getComputedStyle&&(b.pixelPosition=(a.getComputedStyle(d,null)||{}).top!=="1%",b.boxSizingReliable=(a.getComputedStyle(d,null)||{width:"4px"}).width==="4px",g=e.createElement("div"),g.style.cssText=d.style.cssText=h,g.style.marginRight=g.style.width="0",d.style.width="1px",d.appendChild(g),b.reliableMarginRight=!parseFloat((a.getComputedStyle(g,null)||{}).marginRight)),typeof d.style.zoom!="undefined"&&(d.innerHTML="",d.style.cssText=h+"width:1px;padding:1px;display:inline;zoom:1",b.inlineBlockNeedsLayout=d.offsetWidth===3,d.style.display="block",d.style.overflow="visible",d.innerHTML="
",d.firstChild.style.width="5px",b.shrinkWrapBlocks=d.offsetWidth!==3,c.style.zoom=1),i.removeChild(c),c=d=f=g=null}),i.removeChild(n),c=d=f=g=h=i=n=null,b}();var H=/(?:\{[\s\S]*\}|\[[\s\S]*\])$/,I=/([A-Z])/g;p.extend({cache:{},deletedIds:[],uuid:0,expando:"jQuery"+(p.fn.jquery+Math.random()).replace(/\D/g,""),noData:{embed:!0,object:"clsid:D27CDB6E-AE6D-11cf-96B8-444553540000",applet:!0},hasData:function(a){return a=a.nodeType?p.cache[a[p.expando]]:a[p.expando],!!a&&!K(a)},data:function(a,c,d,e){if(!p.acceptData(a))return;var f,g,h=p.expando,i=typeof c=="string",j=a.nodeType,k=j?p.cache:a,l=j?a[h]:a[h]&&h;if((!l||!k[l]||!e&&!k[l].data)&&i&&d===b)return;l||(j?a[h]=l=p.deletedIds.pop()||++p.uuid:l=h),k[l]||(k[l]={},j||(k[l].toJSON=p.noop));if(typeof c=="object"||typeof c=="function")e?k[l]=p.extend(k[l],c):k[l].data=p.extend(k[l].data,c);return f=k[l],e||(f.data||(f.data={}),f=f.data),d!==b&&(f[p.camelCase(c)]=d),i?(g=f[c],g==null&&(g=f[p.camelCase(c)])):g=f,g},removeData:function(a,b,c){if(!p.acceptData(a))return;var d,e,f,g=a.nodeType,h=g?p.cache:a,i=g?a[p.expando]:p.expando;if(!h[i])return;if(b){d=c?h[i]:h[i].data;if(d){p.isArray(b)||(b in d?b=[b]:(b=p.camelCase(b),b in d?b=[b]:b=b.split(" ")));for(e=0,f=b.length;e1,null,!1))},removeData:function(a){return this.each(function(){p.removeData(this,a)})}}),p.extend({queue:function(a,b,c){var d;if(a)return b=(b||"fx")+"queue",d=p._data(a,b),c&&(!d||p.isArray(c)?d=p._data(a,b,p.makeArray(c)):d.push(c)),d||[]},dequeue:function(a,b){b=b||"fx";var c=p.queue(a,b),d=c.length,e=c.shift(),f=p._queueHooks(a,b),g=function(){p.dequeue(a,b)};e==="inprogress"&&(e=c.shift(),d--),e&&(b==="fx"&&c.unshift("inprogress"),delete f.stop,e.call(a,g,f)),!d&&f&&f.empty.fire()},_queueHooks:function(a,b){var c=b+"queueHooks";return p._data(a,c)||p._data(a,c,{empty:p.Callbacks("once memory").add(function(){p.removeData(a,b+"queue",!0),p.removeData(a,c,!0)})})}}),p.fn.extend({queue:function(a,c){var d=2;return typeof a!="string"&&(c=a,a="fx",d--),arguments.length1)},removeAttr:function(a){return this.each(function(){p.removeAttr(this,a)})},prop:function(a,b){return p.access(this,p.prop,a,b,arguments.length>1)},removeProp:function(a){return a=p.propFix[a]||a,this.each(function(){try{this[a]=b,delete this[a]}catch(c){}})},addClass:function(a){var b,c,d,e,f,g,h;if(p.isFunction(a))return this.each(function(b){p(this).addClass(a.call(this,b,this.className))});if(a&&typeof a=="string"){b=a.split(s);for(c=0,d=this.length;c-1)d=d.replace(" "+c[f]+" "," ");e.className=a?p.trim(d):""}}}return this},toggleClass:function(a,b){var c=typeof a,d=typeof b=="boolean";return p.isFunction(a)?this.each(function(c){p(this).toggleClass(a.call(this,c,this.className,b),b)}):this.each(function(){if(c==="string"){var e,f=0,g=p(this),h=b,i=a.split(s);while(e=i[f++])h=d?h:!g.hasClass(e),g[h?"addClass":"removeClass"](e)}else if(c==="undefined"||c==="boolean")this.className&&p._data(this,"__className__",this.className),this.className=this.className||a===!1?"":p._data(this,"__className__")||""})},hasClass:function(a){var b=" "+a+" ",c=0,d=this.length;for(;c-1)return!0;return!1},val:function(a){var c,d,e,f=this[0];if(!arguments.length){if(f)return c=p.valHooks[f.type]||p.valHooks[f.nodeName.toLowerCase()],c&&"get"in c&&(d=c.get(f,"value"))!==b?d:(d=f.value,typeof d=="string"?d.replace(P,""):d==null?"":d);return}return e=p.isFunction(a),this.each(function(d){var f,g=p(this);if(this.nodeType!==1)return;e?f=a.call(this,d,g.val()):f=a,f==null?f="":typeof f=="number"?f+="":p.isArray(f)&&(f=p.map(f,function(a){return a==null?"":a+""})),c=p.valHooks[this.type]||p.valHooks[this.nodeName.toLowerCase()];if(!c||!("set"in c)||c.set(this,f,"value")===b)this.value=f})}}),p.extend({valHooks:{option:{get:function(a){var b=a.attributes.value;return!b||b.specified?a.value:a.text}},select:{get:function(a){var b,c,d,e,f=a.selectedIndex,g=[],h=a.options,i=a.type==="select-one";if(f<0)return null;c=i?f:0,d=i?f+1:h.length;for(;c=0}),c.length||(a.selectedIndex=-1),c}}},attrFn:{},attr:function(a,c,d,e){var f,g,h,i=a.nodeType;if(!a||i===3||i===8||i===2)return;if(e&&p.isFunction(p.fn[c]))return p(a)[c](d);if(typeof a.getAttribute=="undefined")return p.prop(a,c,d);h=i!==1||!p.isXMLDoc(a),h&&(c=c.toLowerCase(),g=p.attrHooks[c]||(T.test(c)?M:L));if(d!==b){if(d===null){p.removeAttr(a,c);return}return g&&"set"in g&&h&&(f=g.set(a,d,c))!==b?f:(a.setAttribute(c,""+d),d)}return g&&"get"in g&&h&&(f=g.get(a,c))!==null?f:(f=a.getAttribute(c),f===null?b:f)},removeAttr:function(a,b){var c,d,e,f,g=0;if(b&&a.nodeType===1){d=b.split(s);for(;g=0}})});var V=/^(?:textarea|input|select)$/i,W=/^([^\.]*|)(?:\.(.+)|)$/,X=/(?:^|\s)hover(\.\S+|)\b/,Y=/^key/,Z=/^(?:mouse|contextmenu)|click/,$=/^(?:focusinfocus|focusoutblur)$/,_=function(a){return p.event.special.hover?a:a.replace(X,"mouseenter$1 mouseleave$1")};p.event={add:function(a,c,d,e,f){var g,h,i,j,k,l,m,n,o,q,r;if(a.nodeType===3||a.nodeType===8||!c||!d||!(g=p._data(a)))return;d.handler&&(o=d,d=o.handler,f=o.selector),d.guid||(d.guid=p.guid++),i=g.events,i||(g.events=i={}),h=g.handle,h||(g.handle=h=function(a){return typeof p!="undefined"&&(!a||p.event.triggered!==a.type)?p.event.dispatch.apply(h.elem,arguments):b},h.elem=a),c=p.trim(_(c)).split(" ");for(j=0;j=0&&(s=s.slice(0,-1),i=!0),s.indexOf(".")>=0&&(t=s.split("."),s=t.shift(),t.sort());if((!f||p.event.customEvent[s])&&!p.event.global[s])return;c=typeof c=="object"?c[p.expando]?c:new p.Event(s,c):new p.Event(s),c.type=s,c.isTrigger=!0,c.exclusive=i,c.namespace=t.join("."),c.namespace_re=c.namespace?new RegExp("(^|\\.)"+t.join("\\.(?:.*\\.|)")+"(\\.|$)"):null,m=s.indexOf(":")<0?"on"+s:"";if(!f){h=p.cache;for(j in h)h[j].events&&h[j].events[s]&&p.event.trigger(c,d,h[j].handle.elem,!0);return}c.result=b,c.target||(c.target=f),d=d!=null?p.makeArray(d):[],d.unshift(c),n=p.event.special[s]||{};if(n.trigger&&n.trigger.apply(f,d)===!1)return;q=[[f,n.bindType||s]];if(!g&&!n.noBubble&&!p.isWindow(f)){r=n.delegateType||s,k=$.test(r+s)?f:f.parentNode;for(l=f;k;k=k.parentNode)q.push([k,r]),l=k;l===(f.ownerDocument||e)&&q.push([l.defaultView||l.parentWindow||a,r])}for(j=0;j=0),h[l]&&j.push(k);j.length&&t.push({elem:f,matches:j})}n.length>o&&t.push({elem:this,matches:n.slice(o)});for(d=0;d0?this.on(b,null,a,c):this.trigger(b)},Y.test(b)&&(p.event.fixHooks[b]=p.event.keyHooks),Z.test(b)&&(p.event.fixHooks[b]=p.event.mouseHooks)}),function(a,b){function $(a,b,c,d){c=c||[],b=b||q;var e,f,g,j,k=b.nodeType;if(k!==1&&k!==9)return[];if(!a||typeof a!="string")return c;g=h(b);if(!g&&!d)if(e=L.exec(a))if(j=e[1]){if(k===9){f=b.getElementById(j);if(!f||!f.parentNode)return c;if(f.id===j)return c.push(f),c}else if(b.ownerDocument&&(f=b.ownerDocument.getElementById(j))&&i(b,f)&&f.id===j)return c.push(f),c}else{if(e[2])return u.apply(c,t.call(b.getElementsByTagName(a),0)),c;if((j=e[3])&&X&&b.getElementsByClassName)return u.apply(c,t.call(b.getElementsByClassName(j),0)),c}return bk(a,b,c,d,g)}function _(a){return function(b){var c=b.nodeName.toLowerCase();return c==="input"&&b.type===a}}function ba(a){return function(b){var c=b.nodeName.toLowerCase();return(c==="input"||c==="button")&&b.type===a}}function bb(a,b,c){if(a===b)return c;var d=a.nextSibling;while(d){if(d===b)return-1;d=d.nextSibling}return 1}function bc(a,b,c,d){var e,g,h,i,j,k,l,m,n,p,r=!c&&b!==q,s=(r?"":"")+a.replace(H,"$1"),u=y[o][s];if(u)return d?0:t.call(u,0);j=a,k=[],m=0,n=f.preFilter,p=f.filter;while(j){if(!e||(g=I.exec(j)))g&&(j=j.slice(g[0].length),h.selector=l),k.push(h=[]),l="",r&&(j=" "+j);e=!1;if(g=J.exec(j))l+=g[0],j=j.slice(g[0].length),e=h.push({part:g.pop().replace(H," "),string:g[0],captures:g});for(i in p)(g=S[i].exec(j))&&(!n[i]||(g=n[i](g,b,c)))&&(l+=g[0],j=j.slice(g[0].length),e=h.push({part:i,string:g.shift(),captures:g}));if(!e)break}return l&&(h.selector=l),d?j.length:j?$.error(a):t.call(y(s,k),0)}function bd(a,b,e,f){var g=b.dir,h=s++;return a||(a=function(a){return a===e}),b.first?function(b){while(b=b[g])if(b.nodeType===1)return a(b)&&b}:f?function(b){while(b=b[g])if(b.nodeType===1&&a(b))return b}:function(b){var e,f=h+"."+c,i=f+"."+d;while(b=b[g])if(b.nodeType===1){if((e=b[o])===i)return b.sizset;if(typeof e=="string"&&e.indexOf(f)===0){if(b.sizset)return b}else{b[o]=i;if(a(b))return b.sizset=!0,b;b.sizset=!1}}}}function be(a,b){return a?function(c){var d=b(c);return d&&a(d===!0?c:d)}:b}function bf(a,b,c){var d,e,g=0;for(;d=a[g];g++)f.relative[d.part]?e=bd(e,f.relative[d.part],b,c):e=be(e,f.filter[d.part].apply(null,d.captures.concat(b,c)));return e}function bg(a){return function(b){var c,d=0;for(;c=a[d];d++)if(c(b))return!0;return!1}}function bh(a,b,c,d){var e=0,f=b.length;for(;e0?i(h,c,g):[]}function bj(a,c,d,e){var f,g,h,i,j,k,l,m,n,o,p,q,r,s=0,t=a.length,v=S.POS,w=new RegExp("^"+v.source+"(?!"+A+")","i"),x=function(){var a=1,c=arguments.length-2;for(;al){g+=k.slice(l,n.index),l=p,q=[c],J.test(g)&&(m&&(q=m),m=e);if(r=O.test(g))g=g.slice(0,-5).replace(J,"$&*"),l++;n.length>1&&n[0].replace(w,x),m=bi(g,n[1],n[2],q,m,r)}g=""}}o||(g+=k),o=!1}g?J.test(g)?bh(g,m||[c],d,e):$(g,c,d,e?e.concat(m):m):u.apply(d,m)}return t===1?d:$.uniqueSort(d)}function bk(a,b,e,g,h){a=a.replace(H,"$1");var i,k,l,m,n,o,p,q,r,s,v=bc(a,b,h),w=b.nodeType;if(S.POS.test(a))return bj(v,b,e,g);if(g)i=t.call(g,0);else if(v.length===1){if((o=t.call(v[0],0)).length>2&&(p=o[0]).part==="ID"&&w===9&&!h&&f.relative[o[1].part]){b=f.find.ID(p.captures[0].replace(R,""),b,h)[0];if(!b)return e;a=a.slice(o.shift().string.length)}r=(v=N.exec(o[0].string))&&!v.index&&b.parentNode||b,q="";for(n=o.length-1;n>=0;n--){p=o[n],s=p.part,q=p.string+q;if(f.relative[s])break;if(f.order.test(s)){i=f.find[s](p.captures[0].replace(R,""),r,h);if(i==null)continue;a=a.slice(0,a.length-q.length)+q.replace(S[s],""),a||u.apply(e,t.call(i,0));break}}}if(a){k=j(a,b,h),c=k.dirruns++,i==null&&(i=f.find.TAG("*",N.test(a)&&b.parentNode||b));for(n=0;m=i[n];n++)d=k.runs++,k(m)&&e.push(m)}return e}var c,d,e,f,g,h,i,j,k,l,m=!0,n="undefined",o=("sizcache"+Math.random()).replace(".",""),q=a.document,r=q.documentElement,s=0,t=[].slice,u=[].push,v=function(a,b){return a[o]=b||!0,a},w=function(){var a={},b=[];return v(function(c,d){return b.push(c)>f.cacheLength&&delete a[b.shift()],a[c]=d},a)},x=w(),y=w(),z=w(),A="[\\x20\\t\\r\\n\\f]",B="(?:\\\\.|[-\\w]|[^\\x00-\\xa0])+",C=B.replace("w","w#"),D="([*^$|!~]?=)",E="\\["+A+"*("+B+")"+A+"*(?:"+D+A+"*(?:(['\"])((?:\\\\.|[^\\\\])*?)\\3|("+C+")|)|)"+A+"*\\]",F=":("+B+")(?:\\((?:(['\"])((?:\\\\.|[^\\\\])*?)\\2|([^()[\\]]*|(?:(?:"+E+")|[^:]|\\\\.)*|.*))\\)|)",G=":(nth|eq|gt|lt|first|last|even|odd)(?:\\(((?:-\\d)?\\d*)\\)|)(?=[^-]|$)",H=new RegExp("^"+A+"+|((?:^|[^\\\\])(?:\\\\.)*)"+A+"+$","g"),I=new RegExp("^"+A+"*,"+A+"*"),J=new RegExp("^"+A+"*([\\x20\\t\\r\\n\\f>+~])"+A+"*"),K=new RegExp(F),L=/^(?:#([\w\-]+)|(\w+)|\.([\w\-]+))$/,M=/^:not/,N=/[\x20\t\r\n\f]*[+~]/,O=/:not\($/,P=/h\d/i,Q=/input|select|textarea|button/i,R=/\\(?!\\)/g,S={ID:new RegExp("^#("+B+")"),CLASS:new RegExp("^\\.("+B+")"),NAME:new RegExp("^\\[name=['\"]?("+B+")['\"]?\\]"),TAG:new RegExp("^("+B.replace("w","w*")+")"),ATTR:new RegExp("^"+E),PSEUDO:new RegExp("^"+F),CHILD:new RegExp("^:(only|nth|last|first)-child(?:\\("+A+"*(even|odd|(([+-]|)(\\d*)n|)"+A+"*(?:([+-]|)"+A+"*(\\d+)|))"+A+"*\\)|)","i"),POS:new RegExp(G,"ig"),needsContext:new RegExp("^"+A+"*[>+~]|"+G,"i")},T=function(a){var b=q.createElement("div");try{return a(b)}catch(c){return!1}finally{b=null}},U=T(function(a){return a.appendChild(q.createComment("")),!a.getElementsByTagName("*").length}),V=T(function(a){return a.innerHTML="",a.firstChild&&typeof a.firstChild.getAttribute!==n&&a.firstChild.getAttribute("href")==="#"}),W=T(function(a){a.innerHTML="";var b=typeof a.lastChild.getAttribute("multiple");return b!=="boolean"&&b!=="string"}),X=T(function(a){return a.innerHTML="",!a.getElementsByClassName||!a.getElementsByClassName("e").length?!1:(a.lastChild.className="e",a.getElementsByClassName("e").length===2)}),Y=T(function(a){a.id=o+0,a.innerHTML="
",r.insertBefore(a,r.firstChild);var b=q.getElementsByName&&q.getElementsByName(o).length===2+q.getElementsByName(o+0).length;return e=!q.getElementById(o),r.removeChild(a),b});try{t.call(r.childNodes,0)[0].nodeType}catch(Z){t=function(a){var b,c=[];for(;b=this[a];a++)c.push(b);return c}}$.matches=function(a,b){return $(a,null,null,b)},$.matchesSelector=function(a,b){return $(b,null,null,[a]).length>0},g=$.getText=function(a){var b,c="",d=0,e=a.nodeType;if(e){if(e===1||e===9||e===11){if(typeof a.textContent=="string")return a.textContent;for(a=a.firstChild;a;a=a.nextSibling)c+=g(a)}else if(e===3||e===4)return a.nodeValue}else for(;b=a[d];d++)c+=g(b);return c},h=$.isXML=function(a){var b=a&&(a.ownerDocument||a).documentElement;return b?b.nodeName!=="HTML":!1},i=$.contains=r.contains?function(a,b){var c=a.nodeType===9?a.documentElement:a,d=b&&b.parentNode;return a===d||!!(d&&d.nodeType===1&&c.contains&&c.contains(d))}:r.compareDocumentPosition?function(a,b){return b&&!!(a.compareDocumentPosition(b)&16)}:function(a,b){while(b=b.parentNode)if(b===a)return!0;return!1},$.attr=function(a,b){var c,d=h(a);return d||(b=b.toLowerCase()),f.attrHandle[b]?f.attrHandle[b](a):W||d?a.getAttribute(b):(c=a.getAttributeNode(b),c?typeof a[b]=="boolean"?a[b]?b:null:c.specified?c.value:null:null)},f=$.selectors={cacheLength:50,createPseudo:v,match:S,order:new RegExp("ID|TAG"+(Y?"|NAME":"")+(X?"|CLASS":"")),attrHandle:V?{}:{href:function(a){return a.getAttribute("href",2)},type:function(a){return a.getAttribute("type")}},find:{ID:e?function(a,b,c){if(typeof b.getElementById!==n&&!c){var d=b.getElementById(a);return d&&d.parentNode?[d]:[]}}:function(a,c,d){if(typeof c.getElementById!==n&&!d){var e=c.getElementById(a);return e?e.id===a||typeof e.getAttributeNode!==n&&e.getAttributeNode("id").value===a?[e]:b:[]}},TAG:U?function(a,b){if(typeof b.getElementsByTagName!==n)return b.getElementsByTagName(a)}:function(a,b){var c=b.getElementsByTagName(a);if(a==="*"){var d,e=[],f=0;for(;d=c[f];f++)d.nodeType===1&&e.push(d);return e}return c},NAME:function(a,b){if(typeof b.getElementsByName!==n)return b.getElementsByName(name)},CLASS:function(a,b,c){if(typeof b.getElementsByClassName!==n&&!c)return b.getElementsByClassName(a)}},relative:{">":{dir:"parentNode",first:!0}," ":{dir:"parentNode"},"+":{dir:"previousSibling",first:!0},"~":{dir:"previousSibling"}},preFilter:{ATTR:function(a){return a[1]=a[1].replace(R,""),a[3]=(a[4]||a[5]||"").replace(R,""),a[2]==="~="&&(a[3]=" "+a[3]+" "),a.slice(0,4)},CHILD:function(a){return a[1]=a[1].toLowerCase(),a[1]==="nth"?(a[2]||$.error(a[0]),a[3]=+(a[3]?a[4]+(a[5]||1):2*(a[2]==="even"||a[2]==="odd")),a[4]=+(a[6]+a[7]||a[2]==="odd")):a[2]&&$.error(a[0]),a},PSEUDO:function(a,b,c){var d,e;if(S.CHILD.test(a[0]))return null;if(a[3])a[2]=a[3];else if(d=a[4])K.test(d)&&(e=bc(d,b,c,!0))&&(e=d.indexOf(")",d.length-e)-d.length)&&(d=d.slice(0,e),a[0]=a[0].slice(0,e)),a[2]=d;return a.slice(0,3)}},filter:{ID:e?function(a){return a=a.replace(R,""),function(b){return b.getAttribute("id")===a}}:function(a){return a=a.replace(R,""),function(b){var c=typeof b.getAttributeNode!==n&&b.getAttributeNode("id");return c&&c.value===a}},TAG:function(a){return a==="*"?function(){return!0}:(a=a.replace(R,"").toLowerCase(),function(b){return b.nodeName&&b.nodeName.toLowerCase()===a})},CLASS:function(a){var b=x[o][a];return b||(b=x(a,new RegExp("(^|"+A+")"+a+"("+A+"|$)"))),function(a){return b.test(a.className||typeof a.getAttribute!==n&&a.getAttribute("class")||"")}},ATTR:function(a,b,c){return b?function(d){var e=$.attr(d,a),f=e+"";if(e==null)return b==="!=";switch(b){case"=":return f===c;case"!=":return f!==c;case"^=":return c&&f.indexOf(c)===0;case"*=":return c&&f.indexOf(c)>-1;case"$=":return c&&f.substr(f.length-c.length)===c;case"~=":return(" "+f+" ").indexOf(c)>-1;case"|=":return f===c||f.substr(0,c.length+1)===c+"-"}}:function(b){return $.attr(b,a)!=null}},CHILD:function(a,b,c,d){if(a==="nth"){var e=s++;return function(a){var b,f,g=0,h=a;if(c===1&&d===0)return!0;b=a.parentNode;if(b&&(b[o]!==e||!a.sizset)){for(h=b.firstChild;h;h=h.nextSibling)if(h.nodeType===1){h.sizset=++g;if(h===a)break}b[o]=e}return f=a.sizset-d,c===0?f===0:f%c===0&&f/c>=0}}return function(b){var c=b;switch(a){case"only":case"first":while(c=c.previousSibling)if(c.nodeType===1)return!1;if(a==="first")return!0;c=b;case"last":while(c=c.nextSibling)if(c.nodeType===1)return!1;return!0}}},PSEUDO:function(a,b,c,d){var e,g=f.pseudos[a]||f.pseudos[a.toLowerCase()];return g||$.error("unsupported pseudo: "+a),g[o]?g(b,c,d):g.length>1?(e=[a,a,"",b],function(a){return g(a,0,e)}):g}},pseudos:{not:v(function(a,b,c){var d=j(a.replace(H,"$1"),b,c);return function(a){return!d(a)}}),enabled:function(a){return a.disabled===!1},disabled:function(a){return a.disabled===!0},checked:function(a){var b=a.nodeName.toLowerCase();return b==="input"&&!!a.checked||b==="option"&&!!a.selected},selected:function(a){return a.parentNode&&a.parentNode.selectedIndex,a.selected===!0},parent:function(a){return!f.pseudos.empty(a)},empty:function(a){var b;a=a.firstChild;while(a){if(a.nodeName>"@"||(b=a.nodeType)===3||b===4)return!1;a=a.nextSibling}return!0},contains:v(function(a){return function(b){return(b.textContent||b.innerText||g(b)).indexOf(a)>-1}}),has:v(function(a){return function(b){return $(a,b).length>0}}),header:function(a){return P.test(a.nodeName)},text:function(a){var b,c;return a.nodeName.toLowerCase()==="input"&&(b=a.type)==="text"&&((c=a.getAttribute("type"))==null||c.toLowerCase()===b)},radio:_("radio"),checkbox:_("checkbox"),file:_("file"),password:_("password"),image:_("image"),submit:ba("submit"),reset:ba("reset"),button:function(a){var b=a.nodeName.toLowerCase();return b==="input"&&a.type==="button"||b==="button"},input:function(a){return Q.test(a.nodeName)},focus:function(a){var b=a.ownerDocument;return a===b.activeElement&&(!b.hasFocus||b.hasFocus())&&(!!a.type||!!a.href)},active:function(a){return a===a.ownerDocument.activeElement}},setFilters:{first:function(a,b,c){return c?a.slice(1):[a[0]]},last:function(a,b,c){var d=a.pop();return c?a:[d]},even:function(a,b,c){var d=[],e=c?1:0,f=a.length;for(;e",a.querySelectorAll("[selected]").length||e.push("\\["+A+"*(?:checked|disabled|ismap|multiple|readonly|selected|value)"),a.querySelectorAll(":checked").length||e.push(":checked")}),T(function(a){a.innerHTML="

",a.querySelectorAll("[test^='']").length&&e.push("[*^$]="+A+"*(?:\"\"|'')"),a.innerHTML="",a.querySelectorAll(":enabled").length||e.push(":enabled",":disabled")}),e=e.length&&new RegExp(e.join("|")),bk=function(a,d,f,g,h){if(!g&&!h&&(!e||!e.test(a)))if(d.nodeType===9)try{return u.apply(f,t.call(d.querySelectorAll(a),0)),f}catch(i){}else if(d.nodeType===1&&d.nodeName.toLowerCase()!=="object"){var j,k,l,m=d.getAttribute("id"),n=m||o,p=N.test(a)&&d.parentNode||d;m?n=n.replace(c,"\\$&"):d.setAttribute("id",n),j=bc(a,d,h),n="[id='"+n+"']";for(k=0,l=j.length;k0})}(),f.setFilters.nth=f.setFilters.eq,f.filters=f.pseudos,$.attr=p.attr,p.find=$,p.expr=$.selectors,p.expr[":"]=p.expr.pseudos,p.unique=$.uniqueSort,p.text=$.getText,p.isXMLDoc=$.isXML,p.contains=$.contains}(a);var bc=/Until$/,bd=/^(?:parents|prev(?:Until|All))/,be=/^.[^:#\[\.,]*$/,bf=p.expr.match.needsContext,bg={children:!0,contents:!0,next:!0,prev:!0};p.fn.extend({find:function(a){var b,c,d,e,f,g,h=this;if(typeof a!="string")return p(a).filter(function(){for(b=0,c=h.length;b0)for(e=d;e=0:p.filter(a,this).length>0:this.filter(a).length>0)},closest:function(a,b){var c,d=0,e=this.length,f=[],g=bf.test(a)||typeof a!="string"?p(a,b||this.context):0;for(;d-1:p.find.matchesSelector(c,a)){f.push(c);break}c=c.parentNode}}return f=f.length>1?p.unique(f):f,this.pushStack(f,"closest",a)},index:function(a){return a?typeof a=="string"?p.inArray(this[0],p(a)):p.inArray(a.jquery?a[0]:a,this):this[0]&&this[0].parentNode?this.prevAll().length:-1},add:function(a,b){var c=typeof a=="string"?p(a,b):p.makeArray(a&&a.nodeType?[a]:a),d=p.merge(this.get(),c);return this.pushStack(bh(c[0])||bh(d[0])?d:p.unique(d))},addBack:function(a){return this.add(a==null?this.prevObject:this.prevObject.filter(a))}}),p.fn.andSelf=p.fn.addBack,p.each({parent:function(a){var b=a.parentNode;return b&&b.nodeType!==11?b:null},parents:function(a){return p.dir(a,"parentNode")},parentsUntil:function(a,b,c){return p.dir(a,"parentNode",c)},next:function(a){return bi(a,"nextSibling")},prev:function(a){return bi(a,"previousSibling")},nextAll:function(a){return p.dir(a,"nextSibling")},prevAll:function(a){return p.dir(a,"previousSibling")},nextUntil:function(a,b,c){return p.dir(a,"nextSibling",c)},prevUntil:function(a,b,c){return p.dir(a,"previousSibling",c)},siblings:function(a){return p.sibling((a.parentNode||{}).firstChild,a)},children:function(a){return p.sibling(a.firstChild)},contents:function(a){return p.nodeName(a,"iframe")?a.contentDocument||a.contentWindow.document:p.merge([],a.childNodes)}},function(a,b){p.fn[a]=function(c,d){var e=p.map(this,b,c);return bc.test(a)||(d=c),d&&typeof d=="string"&&(e=p.filter(d,e)),e=this.length>1&&!bg[a]?p.unique(e):e,this.length>1&&bd.test(a)&&(e=e.reverse()),this.pushStack(e,a,k.call(arguments).join(","))}}),p.extend({filter:function(a,b,c){return c&&(a=":not("+a+")"),b.length===1?p.find.matchesSelector(b[0],a)?[b[0]]:[]:p.find.matches(a,b)},dir:function(a,c,d){var e=[],f=a[c];while(f&&f.nodeType!==9&&(d===b||f.nodeType!==1||!p(f).is(d)))f.nodeType===1&&e.push(f),f=f[c];return e},sibling:function(a,b){var c=[];for(;a;a=a.nextSibling)a.nodeType===1&&a!==b&&c.push(a);return c}});var bl="abbr|article|aside|audio|bdi|canvas|data|datalist|details|figcaption|figure|footer|header|hgroup|mark|meter|nav|output|progress|section|summary|time|video",bm=/ jQuery\d+="(?:null|\d+)"/g,bn=/^\s+/,bo=/<(?!area|br|col|embed|hr|img|input|link|meta|param)(([\w:]+)[^>]*)\/>/gi,bp=/<([\w:]+)/,bq=/]","i"),bv=/^(?:checkbox|radio)$/,bw=/checked\s*(?:[^=]|=\s*.checked.)/i,bx=/\/(java|ecma)script/i,by=/^\s*\s*$/g,bz={option:[1,""],legend:[1,"
","
"],thead:[1,"","
"],tr:[2,"","
"],td:[3,"","
"],col:[2,"","
"],area:[1,"",""],_default:[0,"",""]},bA=bk(e),bB=bA.appendChild(e.createElement("div"));bz.optgroup=bz.option,bz.tbody=bz.tfoot=bz.colgroup=bz.caption=bz.thead,bz.th=bz.td,p.support.htmlSerialize||(bz._default=[1,"X
","
"]),p.fn.extend({text:function(a){return p.access(this,function(a){return a===b?p.text(this):this.empty().append((this[0]&&this[0].ownerDocument||e).createTextNode(a))},null,a,arguments.length)},wrapAll:function(a){if(p.isFunction(a))return this.each(function(b){p(this).wrapAll(a.call(this,b))});if(this[0]){var b=p(a,this[0].ownerDocument).eq(0).clone(!0);this[0].parentNode&&b.insertBefore(this[0]),b.map(function(){var a=this;while(a.firstChild&&a.firstChild.nodeType===1)a=a.firstChild;return a}).append(this)}return this},wrapInner:function(a){return p.isFunction(a)?this.each(function(b){p(this).wrapInner(a.call(this,b))}):this.each(function(){var b=p(this),c=b.contents();c.length?c.wrapAll(a):b.append(a)})},wrap:function(a){var b=p.isFunction(a);return this.each(function(c){p(this).wrapAll(b?a.call(this,c):a)})},unwrap:function(){return this.parent().each(function(){p.nodeName(this,"body")||p(this).replaceWith(this.childNodes)}).end()},append:function(){return this.domManip(arguments,!0,function(a){(this.nodeType===1||this.nodeType===11)&&this.appendChild(a)})},prepend:function(){return this.domManip(arguments,!0,function(a){(this.nodeType===1||this.nodeType===11)&&this.insertBefore(a,this.firstChild)})},before:function(){if(!bh(this[0]))return this.domManip(arguments,!1,function(a){this.parentNode.insertBefore(a,this)});if(arguments.length){var a=p.clean(arguments);return this.pushStack(p.merge(a,this),"before",this.selector)}},after:function(){if(!bh(this[0]))return this.domManip(arguments,!1,function(a){this.parentNode.insertBefore(a,this.nextSibling)});if(arguments.length){var a=p.clean(arguments);return this.pushStack(p.merge(this,a),"after",this.selector)}},remove:function(a,b){var c,d=0;for(;(c=this[d])!=null;d++)if(!a||p.filter(a,[c]).length)!b&&c.nodeType===1&&(p.cleanData(c.getElementsByTagName("*")),p.cleanData([c])),c.parentNode&&c.parentNode.removeChild(c);return this},empty:function(){var a,b=0;for(;(a=this[b])!=null;b++){a.nodeType===1&&p.cleanData(a.getElementsByTagName("*"));while(a.firstChild)a.removeChild(a.firstChild)}return this},clone:function(a,b){return a=a==null?!1:a,b=b==null?a:b,this.map(function(){return p.clone(this,a,b)})},html:function(a){return p.access(this,function(a){var c=this[0]||{},d=0,e=this.length;if(a===b)return c.nodeType===1?c.innerHTML.replace(bm,""):b;if(typeof a=="string"&&!bs.test(a)&&(p.support.htmlSerialize||!bu.test(a))&&(p.support.leadingWhitespace||!bn.test(a))&&!bz[(bp.exec(a)||["",""])[1].toLowerCase()]){a=a.replace(bo,"<$1>");try{for(;d1&&typeof j=="string"&&bw.test(j))return this.each(function(){p(this).domManip(a,c,d)});if(p.isFunction(j))return this.each(function(e){var f=p(this);a[0]=j.call(this,e,c?f.html():b),f.domManip(a,c,d)});if(this[0]){e=p.buildFragment(a,this,k),g=e.fragment,f=g.firstChild,g.childNodes.length===1&&(g=f);if(f){c=c&&p.nodeName(f,"tr");for(h=e.cacheable||l-1;i0?this.clone(!0):this).get(),p(g[e])[b](d),f=f.concat(d);return this.pushStack(f,a,g.selector)}}),p.extend({clone:function(a,b,c){var d,e,f,g;p.support.html5Clone||p.isXMLDoc(a)||!bu.test("<"+a.nodeName+">")?g=a.cloneNode(!0):(bB.innerHTML=a.outerHTML,bB.removeChild(g=bB.firstChild));if((!p.support.noCloneEvent||!p.support.noCloneChecked)&&(a.nodeType===1||a.nodeType===11)&&!p.isXMLDoc(a)){bE(a,g),d=bF(a),e=bF(g);for(f=0;d[f];++f)e[f]&&bE(d[f],e[f])}if(b){bD(a,g);if(c){d=bF(a),e=bF(g);for(f=0;d[f];++f)bD(d[f],e[f])}}return d=e=null,g},clean:function(a,b,c,d){var f,g,h,i,j,k,l,m,n,o,q,r,s=b===e&&bA,t=[];if(!b||typeof b.createDocumentFragment=="undefined")b=e;for(f=0;(h=a[f])!=null;f++){typeof h=="number"&&(h+="");if(!h)continue;if(typeof h=="string")if(!br.test(h))h=b.createTextNode(h);else{s=s||bk(b),l=b.createElement("div"),s.appendChild(l),h=h.replace(bo,"<$1>"),i=(bp.exec(h)||["",""])[1].toLowerCase(),j=bz[i]||bz._default,k=j[0],l.innerHTML=j[1]+h+j[2];while(k--)l=l.lastChild;if(!p.support.tbody){m=bq.test(h),n=i==="table"&&!m?l.firstChild&&l.firstChild.childNodes:j[1]===""&&!m?l.childNodes:[];for(g=n.length-1;g>=0;--g)p.nodeName(n[g],"tbody")&&!n[g].childNodes.length&&n[g].parentNode.removeChild(n[g])}!p.support.leadingWhitespace&&bn.test(h)&&l.insertBefore(b.createTextNode(bn.exec(h)[0]),l.firstChild),h=l.childNodes,l.parentNode.removeChild(l)}h.nodeType?t.push(h):p.merge(t,h)}l&&(h=l=s=null);if(!p.support.appendChecked)for(f=0;(h=t[f])!=null;f++)p.nodeName(h,"input")?bG(h):typeof h.getElementsByTagName!="undefined"&&p.grep(h.getElementsByTagName("input"),bG);if(c){q=function(a){if(!a.type||bx.test(a.type))return d?d.push(a.parentNode?a.parentNode.removeChild(a):a):c.appendChild(a)};for(f=0;(h=t[f])!=null;f++)if(!p.nodeName(h,"script")||!q(h))c.appendChild(h),typeof h.getElementsByTagName!="undefined"&&(r=p.grep(p.merge([],h.getElementsByTagName("script")),q),t.splice.apply(t,[f+1,0].concat(r)),f+=r.length)}return t},cleanData:function(a,b){var c,d,e,f,g=0,h=p.expando,i=p.cache,j=p.support.deleteExpando,k=p.event.special;for(;(e=a[g])!=null;g++)if(b||p.acceptData(e)){d=e[h],c=d&&i[d];if(c){if(c.events)for(f in c.events)k[f]?p.event.remove(e,f):p.removeEvent(e,f,c.handle);i[d]&&(delete i[d],j?delete e[h]:e.removeAttribute?e.removeAttribute(h):e[h]=null,p.deletedIds.push(d))}}}}),function(){var a,b;p.uaMatch=function(a){a=a.toLowerCase();var b=/(chrome)[ \/]([\w.]+)/.exec(a)||/(webkit)[ \/]([\w.]+)/.exec(a)||/(opera)(?:.*version|)[ \/]([\w.]+)/.exec(a)||/(msie) ([\w.]+)/.exec(a)||a.indexOf("compatible")<0&&/(mozilla)(?:.*? rv:([\w.]+)|)/.exec(a)||[];return{browser:b[1]||"",version:b[2]||"0"}},a=p.uaMatch(g.userAgent),b={},a.browser&&(b[a.browser]=!0,b.version=a.version),b.chrome?b.webkit=!0:b.webkit&&(b.safari=!0),p.browser=b,p.sub=function(){function a(b,c){return new a.fn.init(b,c)}p.extend(!0,a,this),a.superclass=this,a.fn=a.prototype=this(),a.fn.constructor=a,a.sub=this.sub,a.fn.init=function c(c,d){return d&&d instanceof p&&!(d instanceof a)&&(d=a(d)),p.fn.init.call(this,c,d,b)},a.fn.init.prototype=a.fn;var b=a(e);return a}}();var bH,bI,bJ,bK=/alpha\([^)]*\)/i,bL=/opacity=([^)]*)/,bM=/^(top|right|bottom|left)$/,bN=/^(none|table(?!-c[ea]).+)/,bO=/^margin/,bP=new RegExp("^("+q+")(.*)$","i"),bQ=new RegExp("^("+q+")(?!px)[a-z%]+$","i"),bR=new RegExp("^([-+])=("+q+")","i"),bS={},bT={position:"absolute",visibility:"hidden",display:"block"},bU={letterSpacing:0,fontWeight:400},bV=["Top","Right","Bottom","Left"],bW=["Webkit","O","Moz","ms"],bX=p.fn.toggle;p.fn.extend({css:function(a,c){return p.access(this,function(a,c,d){return d!==b?p.style(a,c,d):p.css(a,c)},a,c,arguments.length>1)},show:function(){return b$(this,!0)},hide:function(){return b$(this)},toggle:function(a,b){var c=typeof a=="boolean";return p.isFunction(a)&&p.isFunction(b)?bX.apply(this,arguments):this.each(function(){(c?a:bZ(this))?p(this).show():p(this).hide()})}}),p.extend({cssHooks:{opacity:{get:function(a,b){if(b){var c=bH(a,"opacity");return c===""?"1":c}}}},cssNumber:{fillOpacity:!0,fontWeight:!0,lineHeight:!0,opacity:!0,orphans:!0,widows:!0,zIndex:!0,zoom:!0},cssProps:{"float":p.support.cssFloat?"cssFloat":"styleFloat"},style:function(a,c,d,e){if(!a||a.nodeType===3||a.nodeType===8||!a.style)return;var f,g,h,i=p.camelCase(c),j=a.style;c=p.cssProps[i]||(p.cssProps[i]=bY(j,i)),h=p.cssHooks[c]||p.cssHooks[i];if(d===b)return h&&"get"in h&&(f=h.get(a,!1,e))!==b?f:j[c];g=typeof d,g==="string"&&(f=bR.exec(d))&&(d=(f[1]+1)*f[2]+parseFloat(p.css(a,c)),g="number");if(d==null||g==="number"&&isNaN(d))return;g==="number"&&!p.cssNumber[i]&&(d+="px");if(!h||!("set"in h)||(d=h.set(a,d,e))!==b)try{j[c]=d}catch(k){}},css:function(a,c,d,e){var f,g,h,i=p.camelCase(c);return c=p.cssProps[i]||(p.cssProps[i]=bY(a.style,i)),h=p.cssHooks[c]||p.cssHooks[i],h&&"get"in h&&(f=h.get(a,!0,e)),f===b&&(f=bH(a,c)),f==="normal"&&c in bU&&(f=bU[c]),d||e!==b?(g=parseFloat(f),d||p.isNumeric(g)?g||0:f):f},swap:function(a,b,c){var d,e,f={};for(e in b)f[e]=a.style[e],a.style[e]=b[e];d=c.call(a);for(e in b)a.style[e]=f[e];return d}}),a.getComputedStyle?bH=function(b,c){var d,e,f,g,h=a.getComputedStyle(b,null),i=b.style;return h&&(d=h[c],d===""&&!p.contains(b.ownerDocument,b)&&(d=p.style(b,c)),bQ.test(d)&&bO.test(c)&&(e=i.width,f=i.minWidth,g=i.maxWidth,i.minWidth=i.maxWidth=i.width=d,d=h.width,i.width=e,i.minWidth=f,i.maxWidth=g)),d}:e.documentElement.currentStyle&&(bH=function(a,b){var c,d,e=a.currentStyle&&a.currentStyle[b],f=a.style;return e==null&&f&&f[b]&&(e=f[b]),bQ.test(e)&&!bM.test(b)&&(c=f.left,d=a.runtimeStyle&&a.runtimeStyle.left,d&&(a.runtimeStyle.left=a.currentStyle.left),f.left=b==="fontSize"?"1em":e,e=f.pixelLeft+"px",f.left=c,d&&(a.runtimeStyle.left=d)),e===""?"auto":e}),p.each(["height","width"],function(a,b){p.cssHooks[b]={get:function(a,c,d){if(c)return a.offsetWidth===0&&bN.test(bH(a,"display"))?p.swap(a,bT,function(){return cb(a,b,d)}):cb(a,b,d)},set:function(a,c,d){return b_(a,c,d?ca(a,b,d,p.support.boxSizing&&p.css(a,"boxSizing")==="border-box"):0)}}}),p.support.opacity||(p.cssHooks.opacity={get:function(a,b){return bL.test((b&&a.currentStyle?a.currentStyle.filter:a.style.filter)||"")?.01*parseFloat(RegExp.$1)+"":b?"1":""},set:function(a,b){var c=a.style,d=a.currentStyle,e=p.isNumeric(b)?"alpha(opacity="+b*100+")":"",f=d&&d.filter||c.filter||"";c.zoom=1;if(b>=1&&p.trim(f.replace(bK,""))===""&&c.removeAttribute){c.removeAttribute("filter");if(d&&!d.filter)return}c.filter=bK.test(f)?f.replace(bK,e):f+" "+e}}),p(function(){p.support.reliableMarginRight||(p.cssHooks.marginRight={get:function(a,b){return p.swap(a,{display:"inline-block"},function(){if(b)return bH(a,"marginRight")})}}),!p.support.pixelPosition&&p.fn.position&&p.each(["top","left"],function(a,b){p.cssHooks[b]={get:function(a,c){if(c){var d=bH(a,b);return bQ.test(d)?p(a).position()[b]+"px":d}}}})}),p.expr&&p.expr.filters&&(p.expr.filters.hidden=function(a){return a.offsetWidth===0&&a.offsetHeight===0||!p.support.reliableHiddenOffsets&&(a.style&&a.style.display||bH(a,"display"))==="none"},p.expr.filters.visible=function(a){return!p.expr.filters.hidden(a)}),p.each({margin:"",padding:"",border:"Width"},function(a,b){p.cssHooks[a+b]={expand:function(c){var d,e=typeof c=="string"?c.split(" "):[c],f={};for(d=0;d<4;d++)f[a+bV[d]+b]=e[d]||e[d-2]||e[0];return f}},bO.test(a)||(p.cssHooks[a+b].set=b_)});var cd=/%20/g,ce=/\[\]$/,cf=/\r?\n/g,cg=/^(?:color|date|datetime|datetime-local|email|hidden|month|number|password|range|search|tel|text|time|url|week)$/i,ch=/^(?:select|textarea)/i;p.fn.extend({serialize:function(){return p.param(this.serializeArray())},serializeArray:function(){return this.map(function(){return this.elements?p.makeArray(this.elements):this}).filter(function(){return this.name&&!this.disabled&&(this.checked||ch.test(this.nodeName)||cg.test(this.type))}).map(function(a,b){var c=p(this).val();return c==null?null:p.isArray(c)?p.map(c,function(a,c){return{name:b.name,value:a.replace(cf,"\r\n")}}):{name:b.name,value:c.replace(cf,"\r\n")}}).get()}}),p.param=function(a,c){var d,e=[],f=function(a,b){b=p.isFunction(b)?b():b==null?"":b,e[e.length]=encodeURIComponent(a)+"="+encodeURIComponent(b)};c===b&&(c=p.ajaxSettings&&p.ajaxSettings.traditional);if(p.isArray(a)||a.jquery&&!p.isPlainObject(a))p.each(a,function(){f(this.name,this.value)});else for(d in a)ci(d,a[d],c,f);return e.join("&").replace(cd,"+")};var cj,ck,cl=/#.*$/,cm=/^(.*?):[ \t]*([^\r\n]*)\r?$/mg,cn=/^(?:about|app|app\-storage|.+\-extension|file|res|widget):$/,co=/^(?:GET|HEAD)$/,cp=/^\/\//,cq=/\?/,cr=/)<[^<]*)*<\/script>/gi,cs=/([?&])_=[^&]*/,ct=/^([\w\+\.\-]+:)(?:\/\/([^\/?#:]*)(?::(\d+)|)|)/,cu=p.fn.load,cv={},cw={},cx=["*/"]+["*"];try{cj=f.href}catch(cy){cj=e.createElement("a"),cj.href="",cj=cj.href}ck=ct.exec(cj.toLowerCase())||[],p.fn.load=function(a,c,d){if(typeof a!="string"&&cu)return cu.apply(this,arguments);if(!this.length)return this;var e,f,g,h=this,i=a.indexOf(" ");return i>=0&&(e=a.slice(i,a.length),a=a.slice(0,i)),p.isFunction(c)?(d=c,c=b):c&&typeof c=="object"&&(f="POST"),p.ajax({url:a,type:f,dataType:"html",data:c,complete:function(a,b){d&&h.each(d,g||[a.responseText,b,a])}}).done(function(a){g=arguments,h.html(e?p("
").append(a.replace(cr,"")).find(e):a)}),this},p.each("ajaxStart ajaxStop ajaxComplete ajaxError ajaxSuccess ajaxSend".split(" "),function(a,b){p.fn[b]=function(a){return this.on(b,a)}}),p.each(["get","post"],function(a,c){p[c]=function(a,d,e,f){return p.isFunction(d)&&(f=f||e,e=d,d=b),p.ajax({type:c,url:a,data:d,success:e,dataType:f})}}),p.extend({getScript:function(a,c){return p.get(a,b,c,"script")},getJSON:function(a,b,c){return p.get(a,b,c,"json")},ajaxSetup:function(a,b){return b?cB(a,p.ajaxSettings):(b=a,a=p.ajaxSettings),cB(a,b),a},ajaxSettings:{url:cj,isLocal:cn.test(ck[1]),global:!0,type:"GET",contentType:"application/x-www-form-urlencoded; charset=UTF-8",processData:!0,async:!0,accepts:{xml:"application/xml, text/xml",html:"text/html",text:"text/plain",json:"application/json, text/javascript","*":cx},contents:{xml:/xml/,html:/html/,json:/json/},responseFields:{xml:"responseXML",text:"responseText"},converters:{"* text":a.String,"text html":!0,"text json":p.parseJSON,"text xml":p.parseXML},flatOptions:{context:!0,url:!0}},ajaxPrefilter:cz(cv),ajaxTransport:cz(cw),ajax:function(a,c){function y(a,c,f,i){var k,s,t,u,w,y=c;if(v===2)return;v=2,h&&clearTimeout(h),g=b,e=i||"",x.readyState=a>0?4:0,f&&(u=cC(l,x,f));if(a>=200&&a<300||a===304)l.ifModified&&(w=x.getResponseHeader("Last-Modified"),w&&(p.lastModified[d]=w),w=x.getResponseHeader("Etag"),w&&(p.etag[d]=w)),a===304?(y="notmodified",k=!0):(k=cD(l,u),y=k.state,s=k.data,t=k.error,k=!t);else{t=y;if(!y||a)y="error",a<0&&(a=0)}x.status=a,x.statusText=""+(c||y),k?o.resolveWith(m,[s,y,x]):o.rejectWith(m,[x,y,t]),x.statusCode(r),r=b,j&&n.trigger("ajax"+(k?"Success":"Error"),[x,l,k?s:t]),q.fireWith(m,[x,y]),j&&(n.trigger("ajaxComplete",[x,l]),--p.active||p.event.trigger("ajaxStop"))}typeof a=="object"&&(c=a,a=b),c=c||{};var d,e,f,g,h,i,j,k,l=p.ajaxSetup({},c),m=l.context||l,n=m!==l&&(m.nodeType||m instanceof p)?p(m):p.event,o=p.Deferred(),q=p.Callbacks("once memory"),r=l.statusCode||{},t={},u={},v=0,w="canceled",x={readyState:0,setRequestHeader:function(a,b){if(!v){var c=a.toLowerCase();a=u[c]=u[c]||a,t[a]=b}return this},getAllResponseHeaders:function(){return v===2?e:null},getResponseHeader:function(a){var c;if(v===2){if(!f){f={};while(c=cm.exec(e))f[c[1].toLowerCase()]=c[2]}c=f[a.toLowerCase()]}return c===b?null:c},overrideMimeType:function(a){return v||(l.mimeType=a),this},abort:function(a){return a=a||w,g&&g.abort(a),y(0,a),this}};o.promise(x),x.success=x.done,x.error=x.fail,x.complete=q.add,x.statusCode=function(a){if(a){var b;if(v<2)for(b in a)r[b]=[r[b],a[b]];else b=a[x.status],x.always(b)}return this},l.url=((a||l.url)+"").replace(cl,"").replace(cp,ck[1]+"//"),l.dataTypes=p.trim(l.dataType||"*").toLowerCase().split(s),l.crossDomain==null&&(i=ct.exec(l.url.toLowerCase()),l.crossDomain=!(!i||i[1]==ck[1]&&i[2]==ck[2]&&(i[3]||(i[1]==="http:"?80:443))==(ck[3]||(ck[1]==="http:"?80:443)))),l.data&&l.processData&&typeof l.data!="string"&&(l.data=p.param(l.data,l.traditional)),cA(cv,l,c,x);if(v===2)return x;j=l.global,l.type=l.type.toUpperCase(),l.hasContent=!co.test(l.type),j&&p.active++===0&&p.event.trigger("ajaxStart");if(!l.hasContent){l.data&&(l.url+=(cq.test(l.url)?"&":"?")+l.data,delete l.data),d=l.url;if(l.cache===!1){var z=p.now(),A=l.url.replace(cs,"$1_="+z);l.url=A+(A===l.url?(cq.test(l.url)?"&":"?")+"_="+z:"")}}(l.data&&l.hasContent&&l.contentType!==!1||c.contentType)&&x.setRequestHeader("Content-Type",l.contentType),l.ifModified&&(d=d||l.url,p.lastModified[d]&&x.setRequestHeader("If-Modified-Since",p.lastModified[d]),p.etag[d]&&x.setRequestHeader("If-None-Match",p.etag[d])),x.setRequestHeader("Accept",l.dataTypes[0]&&l.accepts[l.dataTypes[0]]?l.accepts[l.dataTypes[0]]+(l.dataTypes[0]!=="*"?", "+cx+"; q=0.01":""):l.accepts["*"]);for(k in l.headers)x.setRequestHeader(k,l.headers[k]);if(!l.beforeSend||l.beforeSend.call(m,x,l)!==!1&&v!==2){w="abort";for(k in{success:1,error:1,complete:1})x[k](l[k]);g=cA(cw,l,c,x);if(!g)y(-1,"No Transport");else{x.readyState=1,j&&n.trigger("ajaxSend",[x,l]),l.async&&l.timeout>0&&(h=setTimeout(function(){x.abort("timeout")},l.timeout));try{v=1,g.send(t,y)}catch(B){if(v<2)y(-1,B);else throw B}}return x}return x.abort()},active:0,lastModified:{},etag:{}});var cE=[],cF=/\?/,cG=/(=)\?(?=&|$)|\?\?/,cH=p.now();p.ajaxSetup({jsonp:"callback",jsonpCallback:function(){var a=cE.pop()||p.expando+"_"+cH++;return this[a]=!0,a}}),p.ajaxPrefilter("json jsonp",function(c,d,e){var f,g,h,i=c.data,j=c.url,k=c.jsonp!==!1,l=k&&cG.test(j),m=k&&!l&&typeof i=="string"&&!(c.contentType||"").indexOf("application/x-www-form-urlencoded")&&cG.test(i);if(c.dataTypes[0]==="jsonp"||l||m)return f=c.jsonpCallback=p.isFunction(c.jsonpCallback)?c.jsonpCallback():c.jsonpCallback,g=a[f],l?c.url=j.replace(cG,"$1"+f):m?c.data=i.replace(cG,"$1"+f):k&&(c.url+=(cF.test(j)?"&":"?")+c.jsonp+"="+f),c.converters["script json"]=function(){return h||p.error(f+" was not called"),h[0]},c.dataTypes[0]="json",a[f]=function(){h=arguments},e.always(function(){a[f]=g,c[f]&&(c.jsonpCallback=d.jsonpCallback,cE.push(f)),h&&p.isFunction(g)&&g(h[0]),h=g=b}),"script"}),p.ajaxSetup({accepts:{script:"text/javascript, application/javascript, application/ecmascript, application/x-ecmascript"},contents:{script:/javascript|ecmascript/},converters:{"text script":function(a){return p.globalEval(a),a}}}),p.ajaxPrefilter("script",function(a){a.cache===b&&(a.cache=!1),a.crossDomain&&(a.type="GET",a.global=!1)}),p.ajaxTransport("script",function(a){if(a.crossDomain){var c,d=e.head||e.getElementsByTagName("head")[0]||e.documentElement;return{send:function(f,g){c=e.createElement("script"),c.async="async",a.scriptCharset&&(c.charset=a.scriptCharset),c.src=a.url,c.onload=c.onreadystatechange=function(a,e){if(e||!c.readyState||/loaded|complete/.test(c.readyState))c.onload=c.onreadystatechange=null,d&&c.parentNode&&d.removeChild(c),c=b,e||g(200,"success")},d.insertBefore(c,d.firstChild)},abort:function(){c&&c.onload(0,1)}}}});var cI,cJ=a.ActiveXObject?function(){for(var a in cI)cI[a](0,1)}:!1,cK=0;p.ajaxSettings.xhr=a.ActiveXObject?function(){return!this.isLocal&&cL()||cM()}:cL,function(a){p.extend(p.support,{ajax:!!a,cors:!!a&&"withCredentials"in a})}(p.ajaxSettings.xhr()),p.support.ajax&&p.ajaxTransport(function(c){if(!c.crossDomain||p.support.cors){var d;return{send:function(e,f){var g,h,i=c.xhr();c.username?i.open(c.type,c.url,c.async,c.username,c.password):i.open(c.type,c.url,c.async);if(c.xhrFields)for(h in c.xhrFields)i[h]=c.xhrFields[h];c.mimeType&&i.overrideMimeType&&i.overrideMimeType(c.mimeType),!c.crossDomain&&!e["X-Requested-With"]&&(e["X-Requested-With"]="XMLHttpRequest");try{for(h in e)i.setRequestHeader(h,e[h])}catch(j){}i.send(c.hasContent&&c.data||null),d=function(a,e){var h,j,k,l,m;try{if(d&&(e||i.readyState===4)){d=b,g&&(i.onreadystatechange=p.noop,cJ&&delete cI[g]);if(e)i.readyState!==4&&i.abort();else{h=i.status,k=i.getAllResponseHeaders(),l={},m=i.responseXML,m&&m.documentElement&&(l.xml=m);try{l.text=i.responseText}catch(a){}try{j=i.statusText}catch(n){j=""}!h&&c.isLocal&&!c.crossDomain?h=l.text?200:404:h===1223&&(h=204)}}}catch(o){e||f(-1,o)}l&&f(h,j,l,k)},c.async?i.readyState===4?setTimeout(d,0):(g=++cK,cJ&&(cI||(cI={},p(a).unload(cJ)),cI[g]=d),i.onreadystatechange=d):d()},abort:function(){d&&d(0,1)}}}});var cN,cO,cP=/^(?:toggle|show|hide)$/,cQ=new RegExp("^(?:([-+])=|)("+q+")([a-z%]*)$","i"),cR=/queueHooks$/,cS=[cY],cT={"*":[function(a,b){var c,d,e,f=this.createTween(a,b),g=cQ.exec(b),h=f.cur(),i=+h||0,j=1;if(g){c=+g[2],d=g[3]||(p.cssNumber[a]?"":"px");if(d!=="px"&&i){i=p.css(f.elem,a,!0)||c||1;do e=j=j||".5",i=i/j,p.style(f.elem,a,i+d),j=f.cur()/h;while(j!==1&&j!==e)}f.unit=d,f.start=i,f.end=g[1]?i+(g[1]+1)*c:c}return f}]};p.Animation=p.extend(cW,{tweener:function(a,b){p.isFunction(a)?(b=a,a=["*"]):a=a.split(" ");var c,d=0,e=a.length;for(;d-1,j={},k={},l,m;i?(k=e.position(),l=k.top,m=k.left):(l=parseFloat(g)||0,m=parseFloat(h)||0),p.isFunction(b)&&(b=b.call(a,c,f)),b.top!=null&&(j.top=b.top-f.top+l),b.left!=null&&(j.left=b.left-f.left+m),"using"in b?b.using.call(a,j):e.css(j)}},p.fn.extend({position:function(){if(!this[0])return;var a=this[0],b=this.offsetParent(),c=this.offset(),d=c_.test(b[0].nodeName)?{top:0,left:0}:b.offset();return c.top-=parseFloat(p.css(a,"marginTop"))||0,c.left-=parseFloat(p.css(a,"marginLeft"))||0,d.top+=parseFloat(p.css(b[0],"borderTopWidth"))||0,d.left+=parseFloat(p.css(b[0],"borderLeftWidth"))||0,{top:c.top-d.top,left:c.left-d.left}},offsetParent:function(){return this.map(function(){var a=this.offsetParent||e.body;while(a&&!c_.test(a.nodeName)&&p.css(a,"position")==="static")a=a.offsetParent;return a||e.body})}}),p.each({scrollLeft:"pageXOffset",scrollTop:"pageYOffset"},function(a,c){var d=/Y/.test(c);p.fn[a]=function(e){return p.access(this,function(a,e,f){var g=da(a);if(f===b)return g?c in g?g[c]:g.document.documentElement[e]:a[e];g?g.scrollTo(d?p(g).scrollLeft():f,d?f:p(g).scrollTop()):a[e]=f},a,e,arguments.length,null)}}),p.each({Height:"height",Width:"width"},function(a,c){p.each({padding:"inner"+a,content:c,"":"outer"+a},function(d,e){p.fn[e]=function(e,f){var g=arguments.length&&(d||typeof e!="boolean"),h=d||(e===!0||f===!0?"margin":"border");return p.access(this,function(c,d,e){var f;return p.isWindow(c)?c.document.documentElement["client"+a]:c.nodeType===9?(f=c.documentElement,Math.max(c.body["scroll"+a],f["scroll"+a],c.body["offset"+a],f["offset"+a],f["client"+a])):e===b?p.css(c,d,e,h):p.style(c,d,e,h)},c,g?e:b,g,null)}})}),a.jQuery=a.$=p,typeof define=="function"&&define.amd&&define.amd.jQuery&&define("jquery",[],function(){return p})})(window); \ No newline at end of file diff --git a/js/jquery.waterfall.js b/js/jquery.waterfall.js new file mode 100644 index 0000000..cd9c197 --- /dev/null +++ b/js/jquery.waterfall.js @@ -0,0 +1,585 @@ +/* Simple min-height-masonry layout plugin. +Like masonry column shift, but works. */ +;(function($) { + + 'use strict'; + + var cssPrefix = detectCSSPrefix(); + + var Waterfall = function(el, opts) { + this.$el = $(el); + this.el = el[0]; + this._create(opts); + }; + + Waterfall.defaultClass = 'waterfall'; + + $.extend(Waterfall.prototype, { + options: { + colMinWidth: 30, //width of column, used to calculate number of columns possible to display + defaultContainerWidth: window.clientWidth, + autoresize: true, + maxCols: 2, //used to restrict max number of columns + updateDelay: 45, //how often to reflow layout on window resize + useCalc: undefined, //set width through -prefix-calc value. Values: true, false, undefined. Autodetection. + useTranslate3d: undefined, //place items through translate3d instead of top/left. Values: true, false, undefined. Autodetection + animateShow: false, //whether to animate appending items (causes browser extra-reflows, slows down rendering) + + //callbacks + reflow: null + }, + + _create: function(opts) { + var self = this, + o = self.options = $.extend({}, self.options, opts); + + this.items = []; + + //init some vars + self.lastHeights = []; + self.lastItems = []; + self.colPriority = []; //most left = most minimal column + self.baseOrder = []; + + var cStyle = getComputedStyle(self.el); + self.el.hidden = true; + self.el.style.minHeight = cStyle.height; //prevent scrollbar width changing + if (self.$el.css('position') === 'static') self.el.style.position = 'relative'; + + //detect placing mode needed + if (o.useCalc === undefined) { + //transform calc detect + this.prefixedCalc = (function() { + var dummy = document.createElement('div'), + props = ['calc', '-webkit-calc', '-moz-calc', '-o-calc']; + for (var i = 0; i < props.length; ++i) { + var prop = props[i], propStr = prop + '(1px)'; + dummy.style.cssText = cssPrefix + 'transform: translate3d(' + [propStr, propStr, propStr].join(',') +');'; + //console.log(dummy.style[cssPrefix + 'transform']) + if (dummy.style.length && dummy.style[cssPrefix + 'transform'].length > 14) { + return prop; + } + } + })(); + o.useCalc = !!this.prefixedCalc; + } + //console.log(this.prefixedCalc); + if (o.useTranslate3d === undefined) { + this.prefixedTranslate3d = (function() { + var dummy = document.createElement('div'); + var props = ['translate3d', '-webkit-translate3d', '-moz-translate3d', '-o-translate3d']; + for (var i = 0; i < props.length; ++i) { + var prop = props[i]; + dummy.style.cssText = cssPrefix + 'transform:' + prop + '(1px, 0, 0);'; + if (dummy.style.length) + return prop; + } + })(); + o.useTranslate3d = !! this.prefixedTranslate3d; + } + //console.log(this.prefixedTranslate3d) + + //populate items + var items; + { + items = self.$el.children(); + } + + //remove text nodes + for (var i = 0; i < self.el.childNodes.length;){ + if (self.el.childNodes[i].nodeType !== 1){ + self.el.removeChild(self.el.childNodes[i]); + } else i++; + } + + items.each(function(i, e) { + //self.items[i].data('id', i); + self._addItem(e); + self._initItem(e); + }); + + self.lastItem = self.items[self.items.length - 1]; + + self.el.removeAttribute("hidden"); + + self._update(); + + if (o.autoresize) { + $(window) + .resize(self.reflow.bind(self)); + } + + this._observeMutations(); + }, + + _addItem: function(item){ + if (item.getAttribute("data-exclude")) return; + this.items.push(item); + }, + + _observeMutations: function() { + //Make Node changing observer - the fastest way to add items + if (window.MutationObserver) { + //FF, chrome + this.observer = new MutationObserver(function(mutations) { + var mNum = mutations.length; + for (var i = 0; i < mNum; i++) { + //console.log(mutations[i]) + if (mutations[i].removedNodes.length) { + this._removedItems(Array.prototype.slice.apply(mutations[i].removedNodes)); + } + if (mutations[i].addedNodes.length) { + var nodes = Array.prototype.slice.apply(mutations[i].addedNodes); + if (mutations[i].nextSibling) { + this._insertedItems(nodes); + } else { + this._appendedItems(nodes); + } + } + } + }.bind(this)); + + this.observer.observe(this.el, { + attributes: false, + childList: true, + characterData: false + }); + } else { + //opera, ie + this.$el.on('DOMNodeInserted', function(e) { + var evt = (e.originalEvent || e), + target = evt.target; + + if (target.nodeType !== 1) return; + if (target.parentNode !== this.el) return; //if insertee is below container + //console.log("--------" + target.className + " next:" + target.nextSibling + " prev:" + target.previousSibling) + + if (target.previousSibling && target.previousSibling.span && (!target.nextSibling || !target.nextSibling.span)) { + this._appendedItems([target]); //append specific case, times faster than _insertedItems + } else { + this._insertedItems([target]); + } + }.bind(this)).on('DOMNodeRemoved', function(e) { + var el = (e.originalEvent || e).target; + + if (el.nodeType !== 1) return; + if (el.parentNode !== this.el) return; //if insertee is below container + + this._removedItems([el]); + }.bind(this)); + } + }, + + //==========================API + //Ensures column number correct, reallocates items + reflow: function() { + var self = this, + o = self.options; + + window.clearTimeout(self._updateInterval); + self._updateInterval = window.setTimeout(self._update.bind(self), o.updateDelay); + + return self; + }, + + //========================= Techs + //called by mutation observer + _appendedItems: function(items) { + var l = items.length, + i = 0; + //console.log("append: " + this.items.length) + for (; i < l; i++) { + var el = items[i]; + if (el.nodeType !== 1) continue; + this._addItem(el); + this._initItem(el); //TODO: optimize + this._setItemWidth(el); + } + + for (i = 0; i < l; i++) { + this._placeItem(items[i]); + } + + this.lastItem = this.items[this.items.length - 1]; + + this._maximizeHeight(); + }, + + //if new items inserted somewhere inside the list + _insertedItems: function(items) { + //console.log("insert: " + this.items.length) + //clear old items + this.items.length = 0; + + //init new items + var l = items.length; + for (var i = 0; i < l; i++) { + var el = items[i]; + if (el.nodeType !== 1) continue; + this._initItem(el); //TODO: optimize + this._setItemWidth(el); + } + + //reinit all items + var children = this.el.childNodes, + itemsL = children.length; + + for (var i = 0; i < itemsL; i++){ + if (children[i].nodeType !== 1) continue; + if (!children[i].span) continue; + this._addItem(children[i]); + } + this.lastItem = this.items[this.items.length - 1]; + + this.reflow(); + }, + + //called by mutation observer + _removedItems: function(items) { + var childItems = this.el.childNodes, + cl = childItems.length; + //console.log("before removed: " + this.items.length) + + //reinit items + for (var i = 0; i < items.length; i++){ + this.items.splice(this.items.indexOf(items[i]), 1); + } + + //console.log("after remove:" + this.items.length) + this.lastItem = this.items[this.items.length - 1]; + + this.reflow(); + }, + + //simple trigger routine + _trigger: function(cbName, arg) { + try { + if (this.options[cbName]) this.options[cbName].call(this.$el, arg); + this.$el.trigger(cbName, [arg]); + } catch (err) { + throw (err); + } + }, + + //init item properties once item appended + _initItem: function(el) { + var o = this.options, + span = el.getAttribute('data-span') || 1, + floatVal = el.getAttribute('data-float') || el.getAttribute('data-column'); + + //set span + span = (span === 'all' ? o.maxCols : Math.max(0, Math.min(~~(span), o.maxCols))); + el.span = span; //quite bad, but no choice: dataset is sloow + + //save heavy style-attrs + var style = getComputedStyle(el); + el.mr = ~~(style.marginRight.slice(0, -2)); + el.ml = ~~(style.marginLeft.slice(0, -2)); + el.bt = ~~(style.borderTopWidth.slice(0, -2)); + el.bb = ~~(style.borderBottomWidth.slice(0, -2)); + el.mt = ~~(style.marginTop.slice(0, -2)); //ignored because of offsetTop instead of style.top + el.mb = ~~(style.marginBottom.slice(0, -2)); + + //set style + el.style.position = 'absolute'; + //this._setItemWidth(el); //make it external action to not to init frominside create + + //parset float + switch (floatVal) { + case null: //no float + el.floatCol = null; + break; + case 'right': + case 'last': + el.floatCol = -span; + break; + case 'left': + case 'first': + el.floatCol = 0; + break; + default: //int column + el.floatCol = ~~(floatVal) - 1; + break; + } + + if (o.animateShow) { + if (o.useTranslate3d) { + //TODO: this below crashes chrome + //el.style[cssPrefix+'translate'] = 'translate3d(0, ' + this.lastHeights[this.colPriority[0]] + 'px ,0)' + } else { + el.style.top = this.lastHeights[this.colPriority[this.colPriority.length - 1]] + 'px'; + el.style.left = this.colWidth * this.colPriority[this.colPriority.length - 1] + 'px'; + } + el.removeAttribute('hidden'); + } + }, + + _initLayoutParams: function() { + var self = this, + o = self.options, + cStyle = window.getComputedStyle(self.el), + i = 0, + prevCols = self.lastItems.length; + + self.pl = ~~(cStyle.paddingLeft.slice(0, -2)); + self.pt = ~~(cStyle.paddingTop.slice(0, -2)); + self.pr = ~~(cStyle.paddingRight.slice(0, -2)); + self.pb = ~~(cStyle.paddingBottom.slice(0, -2)); + + self.lastHeights.length = 0; + self.colPriority.length = 0; //most left = most minimal column + self.baseOrder.length = 0; + + self.colWidth = self.el.clientWidth - self.pl - self.pr; + + self.lastItems.length = ~~(self.colWidth / o.colMinWidth) || 1; //needed length + console.log(o.colMinWidth) + + var top = o.useTranslate3d ? 0 : self.pt; + for (i = 0; i < self.lastItems.length; i++) { + self.lastHeights.push(top); + self.baseOrder.push(i); + self.colPriority.push(i); + } + + self.colWidth /= self.lastItems.length; + + //console.log(prevCols + '->' + self.lastItems.length); + if (!o.useCalc || prevCols !== self.lastItems.length) { + //set item widths carefully - if columns changed or px widths used + for (i = self.items.length; i--;) { + this._setItemWidth(self.items[i]); + } + } + + return self.lastItems.length; + }, + + //full update of layout + _updateInterval: 0, + _update: function(from, to) { + //window.start = Date.now() + var self = this, + i = 0, + start = from || 0, + end = to || self.items.length, + colsNeeded = self._initLayoutParams(); + + //console.log('beforePlace:' + this.lastItems.length) + for (i = start; i < end; i++) { + self._placeItem(self.items[i]); + } + //console.log('afterPlace:' + this.lastItems.length) + + self._maximizeHeight(); + self._trigger('reflow'); + //console.log('time elapsed: ' + (Date.now() - window.start) + 'ms') + }, + + //set item width based on span/colWidth + _setItemWidth: function(el) { + var span = el.span > this.lastItems.length ? this.lastItems.length : el.span, + cols = this.lastItems.length, + colWeight = span / cols; + if (this.options.useCalc) { + el.w = (100 * colWeight); + el.style.width = this.prefixedCalc + '(' + (100 * colWeight) + '% - ' + (el.mr + el.ml + (this.pl + this.pr) * colWeight) + 'px)'; + } else { + el.w = ~~(this.colWidth * span - (el.ml + el.mr)); + el.style.width = el.w + 'px'; + } + }, + + _placeItem: function(e) { + var self = this, + o = self.options; + + var lastHeights = self.lastHeights, + lastItems = self.lastItems, + colPriority = self.colPriority, + minCol = 0, + minH = 0, + h = 0, + c = 0, + t = 0, + end = 0, + start = 0, + span = e.span > lastItems.length ? lastItems.length : e.span, + newH = 0, + spanCols = [], //numbers of spanned columns + spanHeights = [], //heights of spanned columns + style, + floatCol = e.floatCol; + + //console.log('------ item:' + e.innerHTML) + //console.log('span:'+span) + + //Find pro→per column to place item + //console.log(colPriority) + if (floatCol) { + floatCol = floatCol > 0 ? Math.min(floatCol, lastItems.length - span) : (lastItems.length + floatCol); + } + if (span === 1) { + //Single-span element + if (floatCol === null) { + //no align + minCol = colPriority.shift(); + } else { + //predefined column to align + minCol = floatCol; + for (c = 0; c < colPriority.length; c++) { + if (colPriority[c] == minCol) { + colPriority.splice(c, 1); + break; + } + } + } + spanCols.push(minCol); + minH = lastHeights[minCol]; + } else if (span >= lastItems.length) { //Full-span element + minCol = 0; + minH = lastHeights[colPriority[colPriority.length - 1]]; + spanCols = self.baseOrder.slice(); + spanCols.length = lastHeights.length; + colPriority.length = 0; + } else { //Some-span element + if (floatCol !== null) { + minCol = floatCol; + minH = Math.max.apply(Math, lastHeights.slice(minCol, minCol + span)); + //console.log(lastHeights.slice(minCol, span)) + //console.log('fCol:' + floatCol + ' minH: ' + minH) + } else { + //Make span heights alternatives + spanHeights.length = 0; + minH = Infinity; + minCol = 0; + for (c = 0; c <= lastItems.length - span; c++) { + spanHeights[c] = Math.max.apply(Math, lastHeights.slice(c, c + span)); + if (spanHeights[c] < minH) { + minCol = c; + minH = spanHeights[c]; + } + } + } + //Replace priorities + for (c = 0; c < colPriority.length;) { + if (colPriority[c] >= minCol && colPriority[c] < minCol + span) { + spanCols.push(colPriority.splice(c, 1)[0]); + } else c++; + } + } + + //console.log(spanCols) + //console.log(lastHeights) + //console.log('↑ spanCols to ↓') + + //TODO: correct to work ok with options + e.top = ~~minH; //stupid save value for translate3d + if (o.useTranslate3d) { + var offset = (100 * minCol / span) + '% + ' + ~~((e.ml + e.mr) * minCol / span) + 'px'; + if (o.useCalc) { + e.style[cssPrefix + 'transform'] = this.prefixedTranslate3d + '( ' + this.prefixedCalc + '(' + offset + '), ' + e.top + 'px, 0)'; + } else { + //Safari won't set -webkit-calc in element.style + e.style[cssPrefix + 'transform'] = this.prefixedTranslate3d + '(' + ~~(self.colWidth * minCol) + 'px, ' + e.top + 'px, 0)'; + } + } else { + e.style.top = e.top + 'px'; + e.style.left = self.colWidth * minCol + self.pl + 'px'; + } + //console.log(e.style[cssPrefix + 'transform']) + + //if element was added first time and is out of flow - show it + //e.style.opacity = 1; + e.removeAttribute('hidden'); + + newH = self._getBottom(e); //this is the most difficult operation (e.clientHeight) + for (t = 0; t < spanCols.length; t++) { + lastItems[spanCols[t]] = e; + self.lastHeights[spanCols[t]] = newH; + } + + //console.log(lastItems) + //console.log('↑ self.lastHeights to ↓') + //console.log(self.lastHeights) + //console.log('minCol:'+minCol+' minH:'+minH+' newH:'+newH) + //console.log(colPriority) + //console.log('↑ colPriorities to ↓') + + //Update colPriority + for (c = colPriority.length; c--;) { + h = self.lastHeights[colPriority[c]]; + if (newH >= h) { + Array.prototype.splice.apply(colPriority, [c + 1, 0].concat(spanCols)); + break; + } + } + if (colPriority.length < lastHeights.length) { + Array.prototype.unshift.apply(colPriority, spanCols); + //self.colPriority = spanCols.concat(colPriority) + } + }, + + _getBottom: function(e) { + if (!e) return 0; //this.pt; + //TODO: memrize height, look for height change to avoid reflow + return e.top + e.clientHeight + e.bt + e.bb + e.mb + e.mt; + }, + + _maximizeHeight: function() { + var top = this.options.useTranslate3d ? this.pt : 0; + this.el.style.minHeight = this.lastHeights[this.colPriority[this.colPriority.length - 1]] + this.pb + top + 'px'; + } + + }); + + + $.fn.waterfall = function(arg, arg2) { + if (typeof arg == 'string') { //Call API method + return $(this).each(function(i, el) { + $(el).data('waterfall')[arg](arg2); + }); + } else { + if (!this.length) { + throw new Error("No element passed to waterfall") + return false; + }; + var $this = $(this), + opts = $.extend({}, {"colMinWidth": ~~$this[0].getAttribute("data-col-min-width") ||~~$this[0].getAttribute("data-width")}, arg); + if (opts.width && !opts.colMinWidth) { + opts.colMinWidth = opts.width; + } + var wf = new Waterfall($this, opts); + if (!$this.data('waterfall')) $this.data('waterfall', wf); + return wf; + } + }; + + //prefix/features detector + + function detectCSSPrefix(property) { + if (!property) property = 'transform'; + + var style = document.defaultView.getComputedStyle(document.body, ''); + if (style[property]) return ''; + if (style['-webkit-' + property]) return '-webkit-'; + if (style['-moz-' + property]) return '-moz-'; + if (style['-o-' + property]) return '-o-'; + if (style['-khtml-' + property]) return '-khtml-'; + + return false; + } + + //autostart + $(function() { + var defClass = window.waterfall && window.waterfall.defaultClass || Waterfall.defaultClass; + + $('.' + defClass) + .each(function(i, e) { + var $e = $(e), + opts = window.waterfall || {}; + $e.waterfall(opts); + }); + }); + +})(window.jQuery || window.Zepto); diff --git a/js/jquery.waterfall.js~ b/js/jquery.waterfall.js~ new file mode 100644 index 0000000..6829b8b --- /dev/null +++ b/js/jquery.waterfall.js~ @@ -0,0 +1,585 @@ +/* Simple min-height-masonry layout plugin. +Like masonry column shift, but works. */ +;(function($) { + + 'use strict'; + + var cssPrefix = detectCSSPrefix(); + + var Waterfall = function(el, opts) { + this.$el = $(el); + this.el = el[0]; + this._create(opts); + }; + + Waterfall.defaultClass = 'waterfall'; + + $.extend(Waterfall.prototype, { + options: { + colMinWidth: 300, //width of column, used to calculate number of columns possible to display + defaultContainerWidth: window.clientWidth, + autoresize: true, + maxCols: 16, //used to restrict max number of columns + updateDelay: 45, //how often to reflow layout on window resize + useCalc: undefined, //set width through -prefix-calc value. Values: true, false, undefined. Autodetection. + useTranslate3d: undefined, //place items through translate3d instead of top/left. Values: true, false, undefined. Autodetection + animateShow: false, //whether to animate appending items (causes browser extra-reflows, slows down rendering) + + //callbacks + reflow: null + }, + + _create: function(opts) { + var self = this, + o = self.options = $.extend({}, self.options, opts); + + this.items = []; + + //init some vars + self.lastHeights = []; + self.lastItems = []; + self.colPriority = []; //most left = most minimal column + self.baseOrder = []; + + var cStyle = getComputedStyle(self.el); + self.el.hidden = true; + self.el.style.minHeight = cStyle.height; //prevent scrollbar width changing + if (self.$el.css('position') === 'static') self.el.style.position = 'relative'; + + //detect placing mode needed + if (o.useCalc === undefined) { + //transform calc detect + this.prefixedCalc = (function() { + var dummy = document.createElement('div'), + props = ['calc', '-webkit-calc', '-moz-calc', '-o-calc']; + for (var i = 0; i < props.length; ++i) { + var prop = props[i], propStr = prop + '(1px)'; + dummy.style.cssText = cssPrefix + 'transform: translate3d(' + [propStr, propStr, propStr].join(',') +');'; + //console.log(dummy.style[cssPrefix + 'transform']) + if (dummy.style.length && dummy.style[cssPrefix + 'transform'].length > 14) { + return prop; + } + } + })(); + o.useCalc = !!this.prefixedCalc; + } + //console.log(this.prefixedCalc); + if (o.useTranslate3d === undefined) { + this.prefixedTranslate3d = (function() { + var dummy = document.createElement('div'); + var props = ['translate3d', '-webkit-translate3d', '-moz-translate3d', '-o-translate3d']; + for (var i = 0; i < props.length; ++i) { + var prop = props[i]; + dummy.style.cssText = cssPrefix + 'transform:' + prop + '(1px, 0, 0);'; + if (dummy.style.length) + return prop; + } + })(); + o.useTranslate3d = !! this.prefixedTranslate3d; + } + //console.log(this.prefixedTranslate3d) + + //populate items + var items; + { + items = self.$el.children(); + } + + //remove text nodes + for (var i = 0; i < self.el.childNodes.length;){ + if (self.el.childNodes[i].nodeType !== 1){ + self.el.removeChild(self.el.childNodes[i]); + } else i++; + } + + items.each(function(i, e) { + //self.items[i].data('id', i); + self._addItem(e); + self._initItem(e); + }); + + self.lastItem = self.items[self.items.length - 1]; + + self.el.removeAttribute("hidden"); + + self._update(); + + if (o.autoresize) { + $(window) + .resize(self.reflow.bind(self)); + } + + this._observeMutations(); + }, + + _addItem: function(item){ + if (item.getAttribute("data-exclude")) return; + this.items.push(item); + }, + + _observeMutations: function() { + //Make Node changing observer - the fastest way to add items + if (window.MutationObserver) { + //FF, chrome + this.observer = new MutationObserver(function(mutations) { + var mNum = mutations.length; + for (var i = 0; i < mNum; i++) { + //console.log(mutations[i]) + if (mutations[i].removedNodes.length) { + this._removedItems(Array.prototype.slice.apply(mutations[i].removedNodes)); + } + if (mutations[i].addedNodes.length) { + var nodes = Array.prototype.slice.apply(mutations[i].addedNodes); + if (mutations[i].nextSibling) { + this._insertedItems(nodes); + } else { + this._appendedItems(nodes); + } + } + } + }.bind(this)); + + this.observer.observe(this.el, { + attributes: false, + childList: true, + characterData: false + }); + } else { + //opera, ie + this.$el.on('DOMNodeInserted', function(e) { + var evt = (e.originalEvent || e), + target = evt.target; + + if (target.nodeType !== 1) return; + if (target.parentNode !== this.el) return; //if insertee is below container + //console.log("--------" + target.className + " next:" + target.nextSibling + " prev:" + target.previousSibling) + + if (target.previousSibling && target.previousSibling.span && (!target.nextSibling || !target.nextSibling.span)) { + this._appendedItems([target]); //append specific case, times faster than _insertedItems + } else { + this._insertedItems([target]); + } + }.bind(this)).on('DOMNodeRemoved', function(e) { + var el = (e.originalEvent || e).target; + + if (el.nodeType !== 1) return; + if (el.parentNode !== this.el) return; //if insertee is below container + + this._removedItems([el]); + }.bind(this)); + } + }, + + //==========================API + //Ensures column number correct, reallocates items + reflow: function() { + var self = this, + o = self.options; + + window.clearTimeout(self._updateInterval); + self._updateInterval = window.setTimeout(self._update.bind(self), o.updateDelay); + + return self; + }, + + //========================= Techs + //called by mutation observer + _appendedItems: function(items) { + var l = items.length, + i = 0; + //console.log("append: " + this.items.length) + for (; i < l; i++) { + var el = items[i]; + if (el.nodeType !== 1) continue; + this._addItem(el); + this._initItem(el); //TODO: optimize + this._setItemWidth(el); + } + + for (i = 0; i < l; i++) { + this._placeItem(items[i]); + } + + this.lastItem = this.items[this.items.length - 1]; + + this._maximizeHeight(); + }, + + //if new items inserted somewhere inside the list + _insertedItems: function(items) { + //console.log("insert: " + this.items.length) + //clear old items + this.items.length = 0; + + //init new items + var l = items.length; + for (var i = 0; i < l; i++) { + var el = items[i]; + if (el.nodeType !== 1) continue; + this._initItem(el); //TODO: optimize + this._setItemWidth(el); + } + + //reinit all items + var children = this.el.childNodes, + itemsL = children.length; + + for (var i = 0; i < itemsL; i++){ + if (children[i].nodeType !== 1) continue; + if (!children[i].span) continue; + this._addItem(children[i]); + } + this.lastItem = this.items[this.items.length - 1]; + + this.reflow(); + }, + + //called by mutation observer + _removedItems: function(items) { + var childItems = this.el.childNodes, + cl = childItems.length; + //console.log("before removed: " + this.items.length) + + //reinit items + for (var i = 0; i < items.length; i++){ + this.items.splice(this.items.indexOf(items[i]), 1); + } + + //console.log("after remove:" + this.items.length) + this.lastItem = this.items[this.items.length - 1]; + + this.reflow(); + }, + + //simple trigger routine + _trigger: function(cbName, arg) { + try { + if (this.options[cbName]) this.options[cbName].call(this.$el, arg); + this.$el.trigger(cbName, [arg]); + } catch (err) { + throw (err); + } + }, + + //init item properties once item appended + _initItem: function(el) { + var o = this.options, + span = el.getAttribute('data-span') || 1, + floatVal = el.getAttribute('data-float') || el.getAttribute('data-column'); + + //set span + span = (span === 'all' ? o.maxCols : Math.max(0, Math.min(~~(span), o.maxCols))); + el.span = span; //quite bad, but no choice: dataset is sloow + + //save heavy style-attrs + var style = getComputedStyle(el); + el.mr = ~~(style.marginRight.slice(0, -2)); + el.ml = ~~(style.marginLeft.slice(0, -2)); + el.bt = ~~(style.borderTopWidth.slice(0, -2)); + el.bb = ~~(style.borderBottomWidth.slice(0, -2)); + el.mt = ~~(style.marginTop.slice(0, -2)); //ignored because of offsetTop instead of style.top + el.mb = ~~(style.marginBottom.slice(0, -2)); + + //set style + el.style.position = 'absolute'; + //this._setItemWidth(el); //make it external action to not to init frominside create + + //parset float + switch (floatVal) { + case null: //no float + el.floatCol = null; + break; + case 'right': + case 'last': + el.floatCol = -span; + break; + case 'left': + case 'first': + el.floatCol = 0; + break; + default: //int column + el.floatCol = ~~(floatVal) - 1; + break; + } + + if (o.animateShow) { + if (o.useTranslate3d) { + //TODO: this below crashes chrome + //el.style[cssPrefix+'translate'] = 'translate3d(0, ' + this.lastHeights[this.colPriority[0]] + 'px ,0)' + } else { + el.style.top = this.lastHeights[this.colPriority[this.colPriority.length - 1]] + 'px'; + el.style.left = this.colWidth * this.colPriority[this.colPriority.length - 1] + 'px'; + } + el.removeAttribute('hidden'); + } + }, + + _initLayoutParams: function() { + var self = this, + o = self.options, + cStyle = window.getComputedStyle(self.el), + i = 0, + prevCols = self.lastItems.length; + + self.pl = ~~(cStyle.paddingLeft.slice(0, -2)); + self.pt = ~~(cStyle.paddingTop.slice(0, -2)); + self.pr = ~~(cStyle.paddingRight.slice(0, -2)); + self.pb = ~~(cStyle.paddingBottom.slice(0, -2)); + + self.lastHeights.length = 0; + self.colPriority.length = 0; //most left = most minimal column + self.baseOrder.length = 0; + + self.colWidth = self.el.clientWidth - self.pl - self.pr; + + self.lastItems.length = ~~(self.colWidth / o.colMinWidth) || 1; //needed length + console.log(o.colMinWidth) + + var top = o.useTranslate3d ? 0 : self.pt; + for (i = 0; i < self.lastItems.length; i++) { + self.lastHeights.push(top); + self.baseOrder.push(i); + self.colPriority.push(i); + } + + self.colWidth /= self.lastItems.length; + + //console.log(prevCols + '->' + self.lastItems.length); + if (!o.useCalc || prevCols !== self.lastItems.length) { + //set item widths carefully - if columns changed or px widths used + for (i = self.items.length; i--;) { + this._setItemWidth(self.items[i]); + } + } + + return self.lastItems.length; + }, + + //full update of layout + _updateInterval: 0, + _update: function(from, to) { + //window.start = Date.now() + var self = this, + i = 0, + start = from || 0, + end = to || self.items.length, + colsNeeded = self._initLayoutParams(); + + //console.log('beforePlace:' + this.lastItems.length) + for (i = start; i < end; i++) { + self._placeItem(self.items[i]); + } + //console.log('afterPlace:' + this.lastItems.length) + + self._maximizeHeight(); + self._trigger('reflow'); + //console.log('time elapsed: ' + (Date.now() - window.start) + 'ms') + }, + + //set item width based on span/colWidth + _setItemWidth: function(el) { + var span = el.span > this.lastItems.length ? this.lastItems.length : el.span, + cols = this.lastItems.length, + colWeight = span / cols; + if (this.options.useCalc) { + el.w = (100 * colWeight); + el.style.width = this.prefixedCalc + '(' + (100 * colWeight) + '% - ' + (el.mr + el.ml + (this.pl + this.pr) * colWeight) + 'px)'; + } else { + el.w = ~~(this.colWidth * span - (el.ml + el.mr)); + el.style.width = el.w + 'px'; + } + }, + + _placeItem: function(e) { + var self = this, + o = self.options; + + var lastHeights = self.lastHeights, + lastItems = self.lastItems, + colPriority = self.colPriority, + minCol = 0, + minH = 0, + h = 0, + c = 0, + t = 0, + end = 0, + start = 0, + span = e.span > lastItems.length ? lastItems.length : e.span, + newH = 0, + spanCols = [], //numbers of spanned columns + spanHeights = [], //heights of spanned columns + style, + floatCol = e.floatCol; + + //console.log('------ item:' + e.innerHTML) + //console.log('span:'+span) + + //Find pro→per column to place item + //console.log(colPriority) + if (floatCol) { + floatCol = floatCol > 0 ? Math.min(floatCol, lastItems.length - span) : (lastItems.length + floatCol); + } + if (span === 1) { + //Single-span element + if (floatCol === null) { + //no align + minCol = colPriority.shift(); + } else { + //predefined column to align + minCol = floatCol; + for (c = 0; c < colPriority.length; c++) { + if (colPriority[c] == minCol) { + colPriority.splice(c, 1); + break; + } + } + } + spanCols.push(minCol); + minH = lastHeights[minCol]; + } else if (span >= lastItems.length) { //Full-span element + minCol = 0; + minH = lastHeights[colPriority[colPriority.length - 1]]; + spanCols = self.baseOrder.slice(); + spanCols.length = lastHeights.length; + colPriority.length = 0; + } else { //Some-span element + if (floatCol !== null) { + minCol = floatCol; + minH = Math.max.apply(Math, lastHeights.slice(minCol, minCol + span)); + //console.log(lastHeights.slice(minCol, span)) + //console.log('fCol:' + floatCol + ' minH: ' + minH) + } else { + //Make span heights alternatives + spanHeights.length = 0; + minH = Infinity; + minCol = 0; + for (c = 0; c <= lastItems.length - span; c++) { + spanHeights[c] = Math.max.apply(Math, lastHeights.slice(c, c + span)); + if (spanHeights[c] < minH) { + minCol = c; + minH = spanHeights[c]; + } + } + } + //Replace priorities + for (c = 0; c < colPriority.length;) { + if (colPriority[c] >= minCol && colPriority[c] < minCol + span) { + spanCols.push(colPriority.splice(c, 1)[0]); + } else c++; + } + } + + //console.log(spanCols) + //console.log(lastHeights) + //console.log('↑ spanCols to ↓') + + //TODO: correct to work ok with options + e.top = ~~minH; //stupid save value for translate3d + if (o.useTranslate3d) { + var offset = (100 * minCol / span) + '% + ' + ~~((e.ml + e.mr) * minCol / span) + 'px'; + if (o.useCalc) { + e.style[cssPrefix + 'transform'] = this.prefixedTranslate3d + '( ' + this.prefixedCalc + '(' + offset + '), ' + e.top + 'px, 0)'; + } else { + //Safari won't set -webkit-calc in element.style + e.style[cssPrefix + 'transform'] = this.prefixedTranslate3d + '(' + ~~(self.colWidth * minCol) + 'px, ' + e.top + 'px, 0)'; + } + } else { + e.style.top = e.top + 'px'; + e.style.left = self.colWidth * minCol + self.pl + 'px'; + } + //console.log(e.style[cssPrefix + 'transform']) + + //if element was added first time and is out of flow - show it + //e.style.opacity = 1; + e.removeAttribute('hidden'); + + newH = self._getBottom(e); //this is the most difficult operation (e.clientHeight) + for (t = 0; t < spanCols.length; t++) { + lastItems[spanCols[t]] = e; + self.lastHeights[spanCols[t]] = newH; + } + + //console.log(lastItems) + //console.log('↑ self.lastHeights to ↓') + //console.log(self.lastHeights) + //console.log('minCol:'+minCol+' minH:'+minH+' newH:'+newH) + //console.log(colPriority) + //console.log('↑ colPriorities to ↓') + + //Update colPriority + for (c = colPriority.length; c--;) { + h = self.lastHeights[colPriority[c]]; + if (newH >= h) { + Array.prototype.splice.apply(colPriority, [c + 1, 0].concat(spanCols)); + break; + } + } + if (colPriority.length < lastHeights.length) { + Array.prototype.unshift.apply(colPriority, spanCols); + //self.colPriority = spanCols.concat(colPriority) + } + }, + + _getBottom: function(e) { + if (!e) return 0; //this.pt; + //TODO: memrize height, look for height change to avoid reflow + return e.top + e.clientHeight + e.bt + e.bb + e.mb + e.mt; + }, + + _maximizeHeight: function() { + var top = this.options.useTranslate3d ? this.pt : 0; + this.el.style.minHeight = this.lastHeights[this.colPriority[this.colPriority.length - 1]] + this.pb + top + 'px'; + } + + }); + + + $.fn.waterfall = function(arg, arg2) { + if (typeof arg == 'string') { //Call API method + return $(this).each(function(i, el) { + $(el).data('waterfall')[arg](arg2); + }); + } else { + if (!this.length) { + throw new Error("No element passed to waterfall") + return false; + }; + var $this = $(this), + opts = $.extend({}, {"colMinWidth": ~~$this[0].getAttribute("data-col-min-width") ||~~$this[0].getAttribute("data-width")}, arg); + if (opts.width && !opts.colMinWidth) { + opts.colMinWidth = opts.width; + } + var wf = new Waterfall($this, opts); + if (!$this.data('waterfall')) $this.data('waterfall', wf); + return wf; + } + }; + + //prefix/features detector + + function detectCSSPrefix(property) { + if (!property) property = 'transform'; + + var style = document.defaultView.getComputedStyle(document.body, ''); + if (style[property]) return ''; + if (style['-webkit-' + property]) return '-webkit-'; + if (style['-moz-' + property]) return '-moz-'; + if (style['-o-' + property]) return '-o-'; + if (style['-khtml-' + property]) return '-khtml-'; + + return false; + } + + //autostart + $(function() { + var defClass = window.waterfall && window.waterfall.defaultClass || Waterfall.defaultClass; + + $('.' + defClass) + .each(function(i, e) { + var $e = $(e), + opts = window.waterfall || {}; + $e.waterfall(opts); + }); + }); + +})(window.jQuery || window.Zepto); diff --git a/js/zepto.js b/js/zepto.js new file mode 100644 index 0000000..112a1da --- /dev/null +++ b/js/zepto.js @@ -0,0 +1,2 @@ +/* Zepto v1.0-1-ga3cab6c - polyfill zepto detect event ajax form fx - zeptojs.com/license */ +(function(a){String.prototype.trim===a&&(String.prototype.trim=function(){return this.replace(/^\s+|\s+$/g,"")}),Array.prototype.reduce===a&&(Array.prototype.reduce=function(b){if(this===void 0||this===null)throw new TypeError;var c=Object(this),d=c.length>>>0,e=0,f;if(typeof b!="function")throw new TypeError;if(d==0&&arguments.length==1)throw new TypeError;if(arguments.length>=2)f=arguments[1];else do{if(e in c){f=c[e++];break}if(++e>=d)throw new TypeError}while(!0);while(e0?c.fn.concat.apply([],a):a}function O(a){return a.replace(/::/g,"/").replace(/([A-Z]+)([A-Z][a-z])/g,"$1_$2").replace(/([a-z\d])([A-Z])/g,"$1_$2").replace(/_/g,"-").toLowerCase()}function P(a){return a in j?j[a]:j[a]=new RegExp("(^|\\s)"+a+"(\\s|$)")}function Q(a,b){return typeof b=="number"&&!l[O(a)]?b+"px":b}function R(a){var b,c;return i[a]||(b=h.createElement(a),h.body.appendChild(b),c=k(b,"").getPropertyValue("display"),b.parentNode.removeChild(b),c=="none"&&(c="block"),i[a]=c),i[a]}function S(a){return"children"in a?f.call(a.children):c.map(a.childNodes,function(a){if(a.nodeType==1)return a})}function T(c,d,e){for(b in d)e&&(J(d[b])||K(d[b]))?(J(d[b])&&!J(c[b])&&(c[b]={}),K(d[b])&&!K(c[b])&&(c[b]=[]),T(c[b],d[b],e)):d[b]!==a&&(c[b]=d[b])}function U(b,d){return d===a?c(b):c(b).filter(d)}function V(a,b,c,d){return F(b)?b.call(a,c,d):b}function W(a,b,c){c==null?a.removeAttribute(b):a.setAttribute(b,c)}function X(b,c){var d=b.className,e=d&&d.baseVal!==a;if(c===a)return e?d.baseVal:d;e?d.baseVal=c:b.className=c}function Y(a){var b;try{return a?a=="true"||(a=="false"?!1:a=="null"?null:isNaN(b=Number(a))?/^[\[\{]/.test(a)?c.parseJSON(a):a:b):a}catch(d){return a}}function Z(a,b){b(a);for(var c in a.childNodes)Z(a.childNodes[c],b)}var a,b,c,d,e=[],f=e.slice,g=e.filter,h=window.document,i={},j={},k=h.defaultView.getComputedStyle,l={"column-count":1,columns:1,"font-weight":1,"line-height":1,opacity:1,"z-index":1,zoom:1},m=/^\s*<(\w+|!)[^>]*>/,n=/<(?!area|br|col|embed|hr|img|input|link|meta|param)(([\w:]+)[^>]*)\/>/ig,o=/^(?:body|html)$/i,p=["val","css","html","text","data","width","height","offset"],q=["after","prepend","before","append"],r=h.createElement("table"),s=h.createElement("tr"),t={tr:h.createElement("tbody"),tbody:r,thead:r,tfoot:r,td:s,th:s,"*":h.createElement("div")},u=/complete|loaded|interactive/,v=/^\.([\w-]+)$/,w=/^#([\w-]*)$/,x=/^[\w-]+$/,y={},z=y.toString,A={},B,C,D=h.createElement("div");return A.matches=function(a,b){if(!a||a.nodeType!==1)return!1;var c=a.webkitMatchesSelector||a.mozMatchesSelector||a.oMatchesSelector||a.matchesSelector;if(c)return c.call(a,b);var d,e=a.parentNode,f=!e;return f&&(e=D).appendChild(a),d=~A.qsa(e,b).indexOf(a),f&&D.removeChild(a),d},B=function(a){return a.replace(/-+(.)?/g,function(a,b){return b?b.toUpperCase():""})},C=function(a){return g.call(a,function(b,c){return a.indexOf(b)==c})},A.fragment=function(b,d,e){b.replace&&(b=b.replace(n,"<$1>")),d===a&&(d=m.test(b)&&RegExp.$1),d in t||(d="*");var g,h,i=t[d];return i.innerHTML=""+b,h=c.each(f.call(i.childNodes),function(){i.removeChild(this)}),J(e)&&(g=c(h),c.each(e,function(a,b){p.indexOf(a)>-1?g[a](b):g.attr(a,b)})),h},A.Z=function(a,b){return a=a||[],a.__proto__=c.fn,a.selector=b||"",a},A.isZ=function(a){return a instanceof A.Z},A.init=function(b,d){if(!b)return A.Z();if(F(b))return c(h).ready(b);if(A.isZ(b))return b;var e;if(K(b))e=M(b);else if(I(b))e=[J(b)?c.extend({},b):b],b=null;else if(m.test(b))e=A.fragment(b.trim(),RegExp.$1,d),b=null;else{if(d!==a)return c(d).find(b);e=A.qsa(h,b)}return A.Z(e,b)},c=function(a,b){return A.init(a,b)},c.extend=function(a){var b,c=f.call(arguments,1);return typeof a=="boolean"&&(b=a,a=c.shift()),c.forEach(function(c){T(a,c,b)}),a},A.qsa=function(a,b){var c;return H(a)&&w.test(b)?(c=a.getElementById(RegExp.$1))?[c]:[]:a.nodeType!==1&&a.nodeType!==9?[]:f.call(v.test(b)?a.getElementsByClassName(RegExp.$1):x.test(b)?a.getElementsByTagName(b):a.querySelectorAll(b))},c.contains=function(a,b){return a!==b&&a.contains(b)},c.type=E,c.isFunction=F,c.isWindow=G,c.isArray=K,c.isPlainObject=J,c.isEmptyObject=function(a){var b;for(b in a)return!1;return!0},c.inArray=function(a,b,c){return e.indexOf.call(b,a,c)},c.camelCase=B,c.trim=function(a){return a.trim()},c.uuid=0,c.support={},c.expr={},c.map=function(a,b){var c,d=[],e,f;if(L(a))for(e=0;e=0?b:b+this.length]},toArray:function(){return this.get()},size:function(){return this.length},remove:function(){return this.each(function(){this.parentNode!=null&&this.parentNode.removeChild(this)})},each:function(a){return e.every.call(this,function(b,c){return a.call(b,c,b)!==!1}),this},filter:function(a){return F(a)?this.not(this.not(a)):c(g.call(this,function(b){return A.matches(b,a)}))},add:function(a,b){return c(C(this.concat(c(a,b))))},is:function(a){return this.length>0&&A.matches(this[0],a)},not:function(b){var d=[];if(F(b)&&b.call!==a)this.each(function(a){b.call(this,a)||d.push(this)});else{var e=typeof b=="string"?this.filter(b):L(b)&&F(b.item)?f.call(b):c(b);this.forEach(function(a){e.indexOf(a)<0&&d.push(a)})}return c(d)},has:function(a){return this.filter(function(){return I(a)?c.contains(this,a):c(this).find(a).size()})},eq:function(a){return a===-1?this.slice(a):this.slice(a,+a+1)},first:function(){var a=this[0];return a&&!I(a)?a:c(a)},last:function(){var a=this[this.length-1];return a&&!I(a)?a:c(a)},find:function(a){var b,d=this;return typeof a=="object"?b=c(a).filter(function(){var a=this;return e.some.call(d,function(b){return c.contains(b,a)})}):this.length==1?b=c(A.qsa(this[0],a)):b=this.map(function(){return A.qsa(this,a)}),b},closest:function(a,b){var d=this[0],e=!1;typeof a=="object"&&(e=c(a));while(d&&!(e?e.indexOf(d)>=0:A.matches(d,a)))d=d!==b&&!H(d)&&d.parentNode;return c(d)},parents:function(a){var b=[],d=this;while(d.length>0)d=c.map(d,function(a){if((a=a.parentNode)&&!H(a)&&b.indexOf(a)<0)return b.push(a),a});return U(b,a)},parent:function(a){return U(C(this.pluck("parentNode")),a)},children:function(a){return U(this.map(function(){return S(this)}),a)},contents:function(){return this.map(function(){return f.call(this.childNodes)})},siblings:function(a){return U(this.map(function(a,b){return g.call(S(b.parentNode),function(a){return a!==b})}),a)},empty:function(){return this.each(function(){this.innerHTML=""})},pluck:function(a){return c.map(this,function(b){return b[a]})},show:function(){return this.each(function(){this.style.display=="none"&&(this.style.display=null),k(this,"").getPropertyValue("display")=="none"&&(this.style.display=R(this.nodeName))})},replaceWith:function(a){return this.before(a).remove()},wrap:function(a){var b=F(a);if(this[0]&&!b)var d=c(a).get(0),e=d.parentNode||this.length>1;return this.each(function(f){c(this).wrapAll(b?a.call(this,f):e?d.cloneNode(!0):d)})},wrapAll:function(a){if(this[0]){c(this[0]).before(a=c(a));var b;while((b=a.children()).length)a=b.first();c(a).append(this)}return this},wrapInner:function(a){var b=F(a);return this.each(function(d){var e=c(this),f=e.contents(),g=b?a.call(this,d):a;f.length?f.wrapAll(g):e.append(g)})},unwrap:function(){return this.parent().each(function(){c(this).replaceWith(c(this).children())}),this},clone:function(){return this.map(function(){return this.cloneNode(!0)})},hide:function(){return this.css("display","none")},toggle:function(b){return this.each(function(){var d=c(this);(b===a?d.css("display")=="none":b)?d.show():d.hide()})},prev:function(a){return c(this.pluck("previousElementSibling")).filter(a||"*")},next:function(a){return c(this.pluck("nextElementSibling")).filter(a||"*")},html:function(b){return b===a?this.length>0?this[0].innerHTML:null:this.each(function(a){var d=this.innerHTML;c(this).empty().append(V(this,b,a,d))})},text:function(b){return b===a?this.length>0?this[0].textContent:null:this.each(function(){this.textContent=b})},attr:function(c,d){var e;return typeof c=="string"&&d===a?this.length==0||this[0].nodeType!==1?a:c=="value"&&this[0].nodeName=="INPUT"?this.val():!(e=this[0].getAttribute(c))&&c in this[0]?this[0][c]:e:this.each(function(a){if(this.nodeType!==1)return;if(I(c))for(b in c)W(this,b,c[b]);else W(this,c,V(this,d,a,this.getAttribute(c)))})},removeAttr:function(a){return this.each(function(){this.nodeType===1&&W(this,a)})},prop:function(b,c){return c===a?this[0]&&this[0][b]:this.each(function(a){this[b]=V(this,c,a,this[b])})},data:function(b,c){var d=this.attr("data-"+O(b),c);return d!==null?Y(d):a},val:function(b){return b===a?this[0]&&(this[0].multiple?c(this[0]).find("option").filter(function(a){return this.selected}).pluck("value"):this[0].value):this.each(function(a){this.value=V(this,b,a,this.value)})},offset:function(a){if(a)return this.each(function(b){var d=c(this),e=V(this,a,b,d.offset()),f=d.offsetParent().offset(),g={top:e.top-f.top,left:e.left-f.left};d.css("position")=="static"&&(g.position="relative"),d.css(g)});if(this.length==0)return null;var b=this[0].getBoundingClientRect();return{left:b.left+window.pageXOffset,top:b.top+window.pageYOffset,width:Math.round(b.width),height:Math.round(b.height)}},css:function(a,c){if(arguments.length<2&&typeof a=="string")return this[0]&&(this[0].style[B(a)]||k(this[0],"").getPropertyValue(a));var d="";if(E(a)=="string")!c&&c!==0?this.each(function(){this.style.removeProperty(O(a))}):d=O(a)+":"+Q(a,c);else for(b in a)!a[b]&&a[b]!==0?this.each(function(){this.style.removeProperty(O(b))}):d+=O(b)+":"+Q(b,a[b])+";";return this.each(function(){this.style.cssText+=";"+d})},index:function(a){return a?this.indexOf(c(a)[0]):this.parent().children().indexOf(this[0])},hasClass:function(a){return e.some.call(this,function(a){return this.test(X(a))},P(a))},addClass:function(a){return this.each(function(b){d=[];var e=X(this),f=V(this,a,b,e);f.split(/\s+/g).forEach(function(a){c(this).hasClass(a)||d.push(a)},this),d.length&&X(this,e+(e?" ":"")+d.join(" "))})},removeClass:function(b){return this.each(function(c){if(b===a)return X(this,"");d=X(this),V(this,b,c,d).split(/\s+/g).forEach(function(a){d=d.replace(P(a)," ")}),X(this,d.trim())})},toggleClass:function(b,d){return this.each(function(e){var f=c(this),g=V(this,b,e,X(this));g.split(/\s+/g).forEach(function(b){(d===a?!f.hasClass(b):d)?f.addClass(b):f.removeClass(b)})})},scrollTop:function(){if(!this.length)return;return"scrollTop"in this[0]?this[0].scrollTop:this[0].scrollY},position:function(){if(!this.length)return;var a=this[0],b=this.offsetParent(),d=this.offset(),e=o.test(b[0].nodeName)?{top:0,left:0}:b.offset();return d.top-=parseFloat(c(a).css("margin-top"))||0,d.left-=parseFloat(c(a).css("margin-left"))||0,e.top+=parseFloat(c(b[0]).css("border-top-width"))||0,e.left+=parseFloat(c(b[0]).css("border-left-width"))||0,{top:d.top-e.top,left:d.left-e.left}},offsetParent:function(){return this.map(function(){var a=this.offsetParent||h.body;while(a&&!o.test(a.nodeName)&&c(a).css("position")=="static")a=a.offsetParent;return a})}},c.fn.detach=c.fn.remove,["width","height"].forEach(function(b){c.fn[b]=function(d){var e,f=this[0],g=b.replace(/./,function(a){return a[0].toUpperCase()});return d===a?G(f)?f["inner"+g]:H(f)?f.documentElement["offset"+g]:(e=this.offset())&&e[b]:this.each(function(a){f=c(this),f.css(b,V(this,d,a,f[b]()))})}}),q.forEach(function(a,b){var d=b%2;c.fn[a]=function(){var a,e=c.map(arguments,function(b){return a=E(b),a=="object"||a=="array"||b==null?b:A.fragment(b)}),f,g=this.length>1;return e.length<1?this:this.each(function(a,h){f=d?h:h.parentNode,h=b==0?h.nextSibling:b==1?h.firstChild:b==2?h:null,e.forEach(function(a){if(g)a=a.cloneNode(!0);else if(!f)return c(a).remove();Z(f.insertBefore(a,h),function(a){a.nodeName!=null&&a.nodeName.toUpperCase()==="SCRIPT"&&(!a.type||a.type==="text/javascript")&&!a.src&&window.eval.call(window,a.innerHTML)})})})},c.fn[d?a+"To":"insert"+(b?"Before":"After")]=function(b){return c(b)[a](this),this}}),A.Z.prototype=c.fn,A.uniq=C,A.deserializeValue=Y,c.zepto=A,c}();window.Zepto=Zepto,"$"in window||(window.$=Zepto),function(a){function b(a){var b=this.os={},c=this.browser={},d=a.match(/WebKit\/([\d.]+)/),e=a.match(/(Android)\s+([\d.]+)/),f=a.match(/(iPad).*OS\s([\d_]+)/),g=!f&&a.match(/(iPhone\sOS)\s([\d_]+)/),h=a.match(/(webOS|hpwOS)[\s\/]([\d.]+)/),i=h&&a.match(/TouchPad/),j=a.match(/Kindle\/([\d.]+)/),k=a.match(/Silk\/([\d._]+)/),l=a.match(/(BlackBerry).*Version\/([\d.]+)/),m=a.match(/(BB10).*Version\/([\d.]+)/),n=a.match(/(RIM\sTablet\sOS)\s([\d.]+)/),o=a.match(/PlayBook/),p=a.match(/Chrome\/([\d.]+)/)||a.match(/CriOS\/([\d.]+)/),q=a.match(/Firefox\/([\d.]+)/);if(c.webkit=!!d)c.version=d[1];e&&(b.android=!0,b.version=e[2]),g&&(b.ios=b.iphone=!0,b.version=g[2].replace(/_/g,".")),f&&(b.ios=b.ipad=!0,b.version=f[2].replace(/_/g,".")),h&&(b.webos=!0,b.version=h[2]),i&&(b.touchpad=!0),l&&(b.blackberry=!0,b.version=l[2]),m&&(b.bb10=!0,b.version=m[2]),n&&(b.rimtabletos=!0,b.version=n[2]),o&&(c.playbook=!0),j&&(b.kindle=!0,b.version=j[1]),k&&(c.silk=!0,c.version=k[1]),!k&&b.android&&a.match(/Kindle Fire/)&&(c.silk=!0),p&&(c.chrome=!0,c.version=p[1]),q&&(c.firefox=!0,c.version=q[1]),b.tablet=!!(f||o||e&&!a.match(/Mobile/)||q&&a.match(/Tablet/)),b.phone=!b.tablet&&!!(e||g||h||l||m||p&&a.match(/Android/)||p&&a.match(/CriOS\/([\d.]+)/)||q&&a.match(/Mobile/))}b.call(a,navigator.userAgent),a.__detect=b}(Zepto),function(a){function g(a){return a._zid||(a._zid=d++)}function h(a,b,d,e){b=i(b);if(b.ns)var f=j(b.ns);return(c[g(a)]||[]).filter(function(a){return a&&(!b.e||a.e==b.e)&&(!b.ns||f.test(a.ns))&&(!d||g(a.fn)===g(d))&&(!e||a.sel==e)})}function i(a){var b=(""+a).split(".");return{e:b[0],ns:b.slice(1).sort().join(" ")}}function j(a){return new RegExp("(?:^| )"+a.replace(" "," .* ?")+"(?: |$)")}function k(b,c,d){a.type(b)!="string"?a.each(b,d):b.split(/\s/).forEach(function(a){d(a,c)})}function l(a,b){return a.del&&(a.e=="focus"||a.e=="blur")||!!b}function m(a){return f[a]||a}function n(b,d,e,h,j,n){var o=g(b),p=c[o]||(c[o]=[]);k(d,e,function(c,d){var e=i(c);e.fn=d,e.sel=h,e.e in f&&(d=function(b){var c=b.relatedTarget;if(!c||c!==this&&!a.contains(this,c))return e.fn.apply(this,arguments)}),e.del=j&&j(d,c);var g=e.del||d;e.proxy=function(a){var c=g.apply(b,[a].concat(a.data));return c===!1&&(a.preventDefault(),a.stopPropagation()),c},e.i=p.length,p.push(e),b.addEventListener(m(e.e),e.proxy,l(e,n))})}function o(a,b,d,e,f){var i=g(a);k(b||"",d,function(b,d){h(a,b,d,e).forEach(function(b){delete c[i][b.i],a.removeEventListener(m(b.e),b.proxy,l(b,f))})})}function t(b){var c,d={originalEvent:b};for(c in b)!r.test(c)&&b[c]!==undefined&&(d[c]=b[c]);return a.each(s,function(a,c){d[a]=function(){return this[c]=p,b[a].apply(b,arguments)},d[c]=q}),d}function u(a){if(!("defaultPrevented"in a)){a.defaultPrevented=!1;var b=a.preventDefault;a.preventDefault=function(){this.defaultPrevented=!0,b.call(this)}}}var b=a.zepto.qsa,c={},d=1,e={},f={mouseenter:"mouseover",mouseleave:"mouseout"};e.click=e.mousedown=e.mouseup=e.mousemove="MouseEvents",a.event={add:n,remove:o},a.proxy=function(b,c){if(a.isFunction(b)){var d=function(){return b.apply(c,arguments)};return d._zid=g(b),d}if(typeof c=="string")return a.proxy(b[c],b);throw new TypeError("expected function")},a.fn.bind=function(a,b){return this.each(function(){n(this,a,b)})},a.fn.unbind=function(a,b){return this.each(function(){o(this,a,b)})},a.fn.one=function(a,b){return this.each(function(c,d){n(this,a,b,null,function(a,b){return function(){var c=a.apply(d,arguments);return o(d,b,a),c}})})};var p=function(){return!0},q=function(){return!1},r=/^([A-Z]|layer[XY]$)/,s={preventDefault:"isDefaultPrevented",stopImmediatePropagation:"isImmediatePropagationStopped",stopPropagation:"isPropagationStopped"};a.fn.delegate=function(b,c,d){return this.each(function(e,f){n(f,c,d,b,function(c){return function(d){var e,g=a(d.target).closest(b,f).get(0);if(g)return e=a.extend(t(d),{currentTarget:g,liveFired:f}),c.apply(g,[e].concat([].slice.call(arguments,1)))}})})},a.fn.undelegate=function(a,b,c){return this.each(function(){o(this,b,c,a)})},a.fn.live=function(b,c){return a(document.body).delegate(this.selector,b,c),this},a.fn.die=function(b,c){return a(document.body).undelegate(this.selector,b,c),this},a.fn.on=function(b,c,d){return!c||a.isFunction(c)?this.bind(b,c||d):this.delegate(c,b,d)},a.fn.off=function(b,c,d){return!c||a.isFunction(c)?this.unbind(b,c||d):this.undelegate(c,b,d)},a.fn.trigger=function(b,c){if(typeof b=="string"||a.isPlainObject(b))b=a.Event(b);return u(b),b.data=c,this.each(function(){"dispatchEvent"in this&&this.dispatchEvent(b)})},a.fn.triggerHandler=function(b,c){var d,e;return this.each(function(f,g){d=t(typeof b=="string"?a.Event(b):b),d.data=c,d.target=g,a.each(h(g,b.type||b),function(a,b){e=b.proxy(d);if(d.isImmediatePropagationStopped())return!1})}),e},"focusin focusout load resize scroll unload click dblclick mousedown mouseup mousemove mouseover mouseout mouseenter mouseleave change select keydown keypress keyup error".split(" ").forEach(function(b){a.fn[b]=function(a){return a?this.bind(b,a):this.trigger(b)}}),["focus","blur"].forEach(function(b){a.fn[b]=function(a){return a?this.bind(b,a):this.each(function(){try{this[b]()}catch(a){}}),this}}),a.Event=function(a,b){typeof a!="string"&&(b=a,a=b.type);var c=document.createEvent(e[a]||"Events"),d=!0;if(b)for(var f in b)f=="bubbles"?d=!!b[f]:c[f]=b[f];return c.initEvent(a,d,!0,null,null,null,null,null,null,null,null,null,null,null,null),c.isDefaultPrevented=function(){return this.defaultPrevented},c}}(Zepto),function($){function triggerAndReturn(a,b,c){var d=$.Event(b);return $(a).trigger(d,c),!d.defaultPrevented}function triggerGlobal(a,b,c,d){if(a.global)return triggerAndReturn(b||document,c,d)}function ajaxStart(a){a.global&&$.active++===0&&triggerGlobal(a,null,"ajaxStart")}function ajaxStop(a){a.global&&!--$.active&&triggerGlobal(a,null,"ajaxStop")}function ajaxBeforeSend(a,b){var c=b.context;if(b.beforeSend.call(c,a,b)===!1||triggerGlobal(b,c,"ajaxBeforeSend",[a,b])===!1)return!1;triggerGlobal(b,c,"ajaxSend",[a,b])}function ajaxSuccess(a,b,c){var d=c.context,e="success";c.success.call(d,a,e,b),triggerGlobal(c,d,"ajaxSuccess",[b,c,a]),ajaxComplete(e,b,c)}function ajaxError(a,b,c,d){var e=d.context;d.error.call(e,c,b,a),triggerGlobal(d,e,"ajaxError",[c,d,a]),ajaxComplete(b,c,d)}function ajaxComplete(a,b,c){var d=c.context;c.complete.call(d,b,a),triggerGlobal(c,d,"ajaxComplete",[b,c]),ajaxStop(c)}function empty(){}function mimeToDataType(a){return a&&(a=a.split(";",2)[0]),a&&(a==htmlType?"html":a==jsonType?"json":scriptTypeRE.test(a)?"script":xmlTypeRE.test(a)&&"xml")||"text"}function appendQuery(a,b){return(a+"&"+b).replace(/[&?]{1,2}/,"?")}function serializeData(a){a.processData&&a.data&&$.type(a.data)!="string"&&(a.data=$.param(a.data,a.traditional)),a.data&&(!a.type||a.type.toUpperCase()=="GET")&&(a.url=appendQuery(a.url,a.data))}function parseArguments(a,b,c,d){var e=!$.isFunction(b);return{url:a,data:e?b:undefined,success:e?$.isFunction(c)?c:undefined:b,dataType:e?d||c:c}}function serialize(a,b,c,d){var e,f=$.isArray(b);$.each(b,function(b,g){e=$.type(g),d&&(b=c?d:d+"["+(f?"":b)+"]"),!d&&f?a.add(g.name,g.value):e=="array"||!c&&e=="object"?serialize(a,g,c,b):a.add(b,g)})}var jsonpID=0,document=window.document,key,name,rscript=/)<[^<]*)*<\/script>/gi,scriptTypeRE=/^(?:text|application)\/javascript/i,xmlTypeRE=/^(?:text|application)\/xml/i,jsonType="application/json",htmlType="text/html",blankRE=/^\s*$/;$.active=0,$.ajaxJSONP=function(a){if("type"in a){var b="jsonp"+ ++jsonpID,c=document.createElement("script"),d=function(){clearTimeout(g),$(c).remove(),delete window[b]},e=function(c){d();if(!c||c=="timeout")window[b]=empty;ajaxError(null,c||"abort",f,a)},f={abort:e},g;return ajaxBeforeSend(f,a)===!1?(e("abort"),!1):(window[b]=function(b){d(),ajaxSuccess(b,f,a)},c.onerror=function(){e("error")},c.src=a.url.replace(/=\?/,"="+b),$("head").append(c),a.timeout>0&&(g=setTimeout(function(){e("timeout")},a.timeout)),f)}return $.ajax(a)},$.ajaxSettings={type:"GET",beforeSend:empty,success:empty,error:empty,complete:empty,context:null,global:!0,xhr:function(){return new window.XMLHttpRequest},accepts:{script:"text/javascript, application/javascript",json:jsonType,xml:"application/xml, text/xml",html:htmlType,text:"text/plain"},crossDomain:!1,timeout:0,processData:!0,cache:!0},$.ajax=function(options){var settings=$.extend({},options||{});for(key in $.ajaxSettings)settings[key]===undefined&&(settings[key]=$.ajaxSettings[key]);ajaxStart(settings),settings.crossDomain||(settings.crossDomain=/^([\w-]+:)?\/\/([^\/]+)/.test(settings.url)&&RegExp.$2!=window.location.host),settings.url||(settings.url=window.location.toString()),serializeData(settings),settings.cache===!1&&(settings.url=appendQuery(settings.url,"_="+Date.now()));var dataType=settings.dataType,hasPlaceholder=/=\?/.test(settings.url);if(dataType=="jsonp"||hasPlaceholder)return hasPlaceholder||(settings.url=appendQuery(settings.url,"callback=?")),$.ajaxJSONP(settings);var mime=settings.accepts[dataType],baseHeaders={},protocol=/^([\w-]+:)\/\//.test(settings.url)?RegExp.$1:window.location.protocol,xhr=settings.xhr(),abortTimeout;settings.crossDomain||(baseHeaders["X-Requested-With"]="XMLHttpRequest"),mime&&(baseHeaders.Accept=mime,mime.indexOf(",")>-1&&(mime=mime.split(",",2)[0]),xhr.overrideMimeType&&xhr.overrideMimeType(mime));if(settings.contentType||settings.contentType!==!1&&settings.data&&settings.type.toUpperCase()!="GET")baseHeaders["Content-Type"]=settings.contentType||"application/x-www-form-urlencoded";settings.headers=$.extend(baseHeaders,settings.headers||{}),xhr.onreadystatechange=function(){if(xhr.readyState==4){xhr.onreadystatechange=empty,clearTimeout(abortTimeout);var result,error=!1;if(xhr.status>=200&&xhr.status<300||xhr.status==304||xhr.status==0&&protocol=="file:"){dataType=dataType||mimeToDataType(xhr.getResponseHeader("content-type")),result=xhr.responseText;try{dataType=="script"?(1,eval)(result):dataType=="xml"?result=xhr.responseXML:dataType=="json"&&(result=blankRE.test(result)?null:$.parseJSON(result))}catch(e){error=e}error?ajaxError(error,"parsererror",xhr,settings):ajaxSuccess(result,xhr,settings)}else ajaxError(null,xhr.status?"error":"abort",xhr,settings)}};var async="async"in settings?settings.async:!0;xhr.open(settings.type,settings.url,async);for(name in settings.headers)xhr.setRequestHeader(name,settings.headers[name]);return ajaxBeforeSend(xhr,settings)===!1?(xhr.abort(),!1):(settings.timeout>0&&(abortTimeout=setTimeout(function(){xhr.onreadystatechange=empty,xhr.abort(),ajaxError(null,"timeout",xhr,settings)},settings.timeout)),xhr.send(settings.data?settings.data:null),xhr)},$.get=function(a,b,c,d){return $.ajax(parseArguments.apply(null,arguments))},$.post=function(a,b,c,d){var e=parseArguments.apply(null,arguments);return e.type="POST",$.ajax(e)},$.getJSON=function(a,b,c){var d=parseArguments.apply(null,arguments);return d.dataType="json",$.ajax(d)},$.fn.load=function(a,b,c){if(!this.length)return this;var d=this,e=a.split(/\s/),f,g=parseArguments(a,b,c),h=g.success;return e.length>1&&(g.url=e[0],f=e[1]),g.success=function(a){d.html(f?$("
").html(a.replace(rscript,"")).find(f):a),h&&h.apply(d,arguments)},$.ajax(g),this};var escape=encodeURIComponent;$.param=function(a,b){var c=[];return c.add=function(a,b){this.push(escape(a)+"="+escape(b))},serialize(c,a,b),c.join("&").replace(/%20/g,"+")}}(Zepto),function(a){a.fn.serializeArray=function(){var b=[],c;return a(Array.prototype.slice.call(this.get(0).elements)).each(function(){c=a(this);var d=c.attr("type");this.nodeName.toLowerCase()!="fieldset"&&!this.disabled&&d!="submit"&&d!="reset"&&d!="button"&&(d!="radio"&&d!="checkbox"||this.checked)&&b.push({name:c.attr("name"),value:c.val()})}),b},a.fn.serialize=function(){var a=[];return this.serializeArray().forEach(function(b){a.push(encodeURIComponent(b.name)+"="+encodeURIComponent(b.value))}),a.join("&")},a.fn.submit=function(b){if(b)this.bind("submit",b);else if(this.length){var c=a.Event("submit");this.eq(0).trigger(c),c.defaultPrevented||this.get(0).submit()}return this}}(Zepto),function(a,b){function s(a){return t(a.replace(/([a-z])([A-Z])/,"$1-$2"))}function t(a){return a.toLowerCase()}function u(a){return d?d+a:t(a)}var c="",d,e,f,g={Webkit:"webkit",Moz:"",O:"o",ms:"MS"},h=window.document,i=h.createElement("div"),j=/^((translate|rotate|scale)(X|Y|Z|3d)?|matrix(3d)?|perspective|skew(X|Y)?)$/i,k,l,m,n,o,p,q,r={};a.each(g,function(a,e){if(i.style[a+"TransitionProperty"]!==b)return c="-"+t(a)+"-",d=e,!1}),k=c+"transform",r[l=c+"transition-property"]=r[m=c+"transition-duration"]=r[n=c+"transition-timing-function"]=r[o=c+"animation-name"]=r[p=c+"animation-duration"]=r[q=c+"animation-timing-function"]="",a.fx={off:d===b&&i.style.transitionProperty===b,speeds:{_default:400,fast:200,slow:600},cssPrefix:c,transitionEnd:u("TransitionEnd"),animationEnd:u("AnimationEnd")},a.fn.animate=function(b,c,d,e){return a.isPlainObject(c)&&(d=c.easing,e=c.complete,c=c.duration),c&&(c=(typeof c=="number"?c:a.fx.speeds[c]||a.fx.speeds._default)/1e3),this.anim(b,c,d,e)},a.fn.anim=function(c,d,e,f){var g,h={},i,t="",u=this,v,w=a.fx.transitionEnd;d===b&&(d=.4),a.fx.off&&(d=0);if(typeof c=="string")h[o]=c,h[p]=d+"s",h[q]=e||"linear",w=a.fx.animationEnd;else{i=[];for(g in c)j.test(g)?t+=g+"("+c[g]+") ":(h[g]=c[g],i.push(s(g)));t&&(h[k]=t,i.push(k)),d>0&&typeof c=="object"&&(h[l]=i.join(", "),h[m]=d+"s",h[n]=e||"linear")}return v=function(b){if(typeof b!="undefined"){if(b.target!==b.currentTarget)return;a(b.target).unbind(w,v)}a(this).css(r),f&&f.call(this)},d>0&&this.bind(w,v),this.size()&&this.get(0).clientLeft,this.css(h),d<=0&&setTimeout(function(){u.each(function(){v.call(this)})},0),this},i=null}(Zepto) \ No newline at end of file diff --git a/message_list.html.erb b/message_list.html.erb new file mode 100644 index 0000000..2a08d5d --- /dev/null +++ b/message_list.html.erb @@ -0,0 +1,114 @@ +
+ +
    + +
    + +
    + Federalismo em debate +
    + +
    + + + + + + +
    + + + Nova Mensagem + + +
    + Gabriel de Souza Barbosa quer falar sobre Federalismo em debate sem descrição. +
    + + + +
    + +
    + +
    + Federalismo em debate +
    + +
    + + + + + + +
    + + + Mensagem da comunidade + + +
    + Gabriel de Souza Barbosa quer criar a comunidade Federalismo sem descrição. +
    + + + +
    +
    + +
    + Federalismo em debate +
    + +
    + + + + + + +
    + + + Mensagem Nova + + +
    + Gabriel de Souza Barbosa falar com você sobre Debate sem descrição. +
    + + + +
    + + + +
+
diff --git a/navigation.html.erb b/navigation.html.erb new file mode 100644 index 0000000..99f8f9b --- /dev/null +++ b/navigation.html.erb @@ -0,0 +1,12 @@ + +<% if profile && user %> +
  • Configurações
  • +
  • Aparência
  • +
  • Conteúdo
  • +
  •  
  • +
  • <%= link_to(profile_image(profile, :icon) + content_tag(:span, profile.name), profile.public_profile_url) %>
  • + + <%= theme_include 'content_menu' %> + <%= theme_include 'appearance_menu' %> + <%= theme_include 'settings_menu' %> +<% end %> diff --git a/preview.png b/preview.png new file mode 100644 index 0000000..74840bc Binary files /dev/null and b/preview.png differ diff --git a/preview.xcf b/preview.xcf new file mode 100644 index 0000000..d035f23 Binary files /dev/null and b/preview.xcf differ diff --git a/settings_menu.html.erb b/settings_menu.html.erb new file mode 100644 index 0000000..3b48703 --- /dev/null +++ b/settings_menu.html.erb @@ -0,0 +1,57 @@ + diff --git a/site_title.html.erb b/site_title.html.erb new file mode 100644 index 0000000..f5cc1aa --- /dev/null +++ b/site_title.html.erb @@ -0,0 +1 @@ +<%= link_to(image_tag("/designs/themes/noosfero/images/logo-noosfero.png"), environment.top_url) %> diff --git a/style-25-09-2014.css b/style-25-09-2014.css new file mode 100644 index 0000000..05e7252 --- /dev/null +++ b/style-25-09-2014.css @@ -0,0 +1,413 @@ +@import url(../base/style.css); +/****************** ESTILO BASE ******************/ +@import url(cabecalho.css); +/****************** FIM cabecalho amarelo ******************/ +@import url(style-core.css); +@import url(user-menu.css); + +body, th, td, input { +font-family: Arial, sans-serif; +} + +#wrap-2 {background-color:#ebeff2;} + +#wrap-1 { + min-width: 800px; +} + +#site-title { + position: relative; + top: 0; + width: auto; + height: auto; + display: none; + visibility: hidden; +} + +#site-title a { + display: block; + width: auto; + height: auto; + position: relative; + top: 0; + left: 0; +} + +/*largura dos blocos lateral e principal*/ + +/*Largura dos blocos funciona somente para duas colunas*/ +/*e somente com a barra lateral do lado direito*/ +/* +.box-1, +.no-boxes { +margin: 0 0 0 0; +float: left; +width: 80%; +} + +.box-1 .blocks, +.no-boxes .blocks { + width: auto; + float: none; + padding: 0 1em; +} + +.box-2, .box-3 { + position: relative; + float: left; + width: 20%; +} + +.box-2 .blocks{ + padding: 0 1em; +} +*/ + +/**Nova largura dos blocos lateral e principal**/ + +.box {display: inline-block;} + +.box-1, .no-boxes { +margin: 0 0 0 0; +display: inline-block; +position: relative; +overflow: hidden; +} + +.no-boxes{ + margin: 0 0 0 0; + display: block; + /*position: absolute;*/ + max-width: 100%; + left: 0%; + overflow: visible; +} + +.box-1{ + margin: 0 0 0 0; + display: block; + position: absolute; + max-width: 60%; + left: 20%; + overflow: visible; +} + +.box-2/*, .box-3 */{ +position: relative; +/*position: absolute;*/ +/*display: block;*/ +margin: 0; +vertical-align: top; +width: 20%; +} +.box-3{ +min-width: 20%; +position: absolute; +right: 0px; +} + + +.box-1 .blocks, +.no-boxes .blocks { + width: auto; + float: none; + padding: 0 1em; +} + +.box-2 .blocks, .box-3 .blocks{ + padding: 0 1em; +} + +#content .people-block ul, #content .profile-list-block ul, #content .enterprises-block ul, #content .members-block ul, #content .communities-block ul, #content .friends-block ul, #content .fans-block ul {min-width: auto;width: auto;} + +.box-2 .common-profile-list-block .vcard a.profile_link, .box-3 .common-profile-list-block .vcard a.profile_link {height: 112px;max-height: 112px;} + +.common-profile-list-block .vcard a, .comment-actions .vcard a{} + +/*estilo dos blocos*/ + +#main-content-wrapper-1, +#main-content-wrapper-2, +#main-content-wrapper-3, +#main-content-wrapper-4, +#main-content-wrapper-5, +#main-content-wrapper-6, +#main-content-wrapper-7, +#main-content-wrapper-8 { + background: url(images/no-image.gif) no-repeat; +} + +#main-content-wrapper-8 { + padding: 10px 20px; +} + +#content .block { + padding-bottom: 1em; + margin: 0; +} + +#content .block .block-inner-1 { + background-color: #fff; + box-shadow: 5px 5px 5px -2px #ddd; +} + +#content .block .block-inner-2 h3~div {padding:1em;} + +#content .box-1 .block, +#content .no-boxes .block{padding: 0;} + +#content .link-list-block{padding: 0;} + +#content .link-list-block li{margin: 0;} + +#content .link-list-block li a { + border-radius: 0; + padding: 10px 5px 10px 40px; + border-bottom: 1px solid #ccc; + background-color: #f7f9fa; + border-left: 3px solid #f7f9fa; +} + +/*bloco lateral de menu*/ +#content .link-list-block li a.link-this-page{ + max-width:100%; + width: auto; + border-right: 0px; + background-color: #257CAD; + color: white; + border-left: 3px solid #003366; + border-bottom: 0px solid gray; +} + +#content .link-list-block li a.link-this-page:hover, +#content .link-list-block li a:hover { + background-color: #257CAD; + border-left: 3px solid #ff0; + border-right: 0px solid #fff; +} + +#profile-header {margin-bottom: 20px;} +#content .block-title { font-variant: inherit; margin-bottom: 0px;} + +/*cabeçalho dos blocos laterais*/ +#content .block h3.block-title, +#content #content-inner .login-block .logged-user-info h2{ + font-size: 16px; + text-align: left; + border-bottom: 1px solid #AAA; + padding: 0.5em; + background-color: #257CAD; + color: white; + font-variant: inherit; +} + +/*cabeçalho do blocos principal*/ +#content .box-1 .block h3.block-title, +#content .no-boxes .block h3.block-title { + color: #333; + font-size: 16px; + text-align: left; + border-bottom: 0px solid #AAA; + padding: 0px; + background-color: transparent; +} + +/*ver todos blocos laterais*/ +#content .tags-block .block-footer-content a, #content .people-block .block-footer-content a, #content .profile-list-block .block-footer-content a, #content .enterprises-block .block-footer-content a, #content .members-block .block-footer-content a, #content .communities-block .block-footer-content a, #content .friends-block .block-footer-content a { + position: absolute; + top: 5px; + right: 5px; + font-size: 12px; + color: #000; + text-decoration: none; + background-color: #fff; + padding: 6px 20px 6px 12px; + border-radius: 12px; + background-position-x: 90%; +} + +#content .tags-block .block-footer-content a:hover, +#content .people-block .block-footer-content a:hover, +#content .profile-list-block .block-footer-content a:hover, +#content .enterprises-block .block-footer-content a:hover, +#content .members-block .block-footer-content a:hover, +#content .communities-block .block-footer-content a:hover, +#content .friends-block .block-footer-content a:hover { + position: absolute; + top: 5px; + right: 5px; + font-size: 12px; + color: #000; + text-decoration: none; + background-color: #257CAD; + color: white; + padding: 6px 20px 6px 12px; + border-radius: 12px; + border: 1px solid white; +} + +#content .main-block h1{ + font-variant: inherit; + color: #555753; + text-align: left; + border-bottom: 0px; +/*font-family: 'Roboto',sans-serif;*/ + margin: 0 0 5px; + font-weight: 700; + color: #4d4d4d; +} + +.search_form input[type="text"], +#public-profile-search input[type="text"]{ + padding: 6px 0; + font-size: 14px; + line-height: 1.42857143; + color: #555; + background-color: #fff; + background-image: none; + border: 1px solid #ccc; +} + +#content form input.button.submit { + max-height: 34px; + cursor: pointer; + height: 34px; + vertical-align: top; + margin-top: 2px; + margin-left: 16px; +} + +#public-profile-search, #profile-search-results form, .profile-search-block form { + padding: 10px; + margin-bottom: 15px; + background-color: transparent; + -moz-border-radius: 5px; + -webkit-border-radius: 0px; +} + +/*telas de edição*/ + +/*Estilo dos campos - input*/ +.formfield input, .formfield textarea { + background: none; + border: 2px solid #B0C4DE; + color: #333; + font-size: 16px; + border-radius: 5px; +} + +#content form input.button.submit {margin-left:0px; margin-right: 16px;} + +/*Campo inserir arquivo*/ +input[type~="file"] {border: none;} + +/*formulário de criação de artigos - lado esquerdo*/ +.controller-cms div.with_media_panel { + float: left; + width: 70%; + display: inline-block; + background-color: #FFF; + padding: 1em; + vertical-align: top; +} + +/*caixas de formulário da direita - Inserir imagem e buscar imagem*/ +.text-editor-sidebar{ + float: left; + position: relative; + width: 20%; + display: inline-block; + vertical-align: top; + margin-left: 3%; + right: 0; + top: 0; +} + +/*Campo inserir arquivo - lado direito*/ +.text-editor-sidebar .text-editor-sidebar-box #media-upload-form form input[type~="file"]{font-size: x-small;} + +/*campo de busca de mídia*/ +.text-editor-sidebar #media-search-box .formfield input { + display: inline-block; + width: 85% !important; +} + +/*botão de busca de mídia*/ +#content .text-editor-sidebar #media-search-box form input.button.submit { + max-height: 24px; + cursor: pointer; + height: 34px; + vertical-align: top; + margin-top: 2px; + margin-left: 0; + margin-right: 0; + width: 0px; + color: #EEE; + display: inline-block; +} + +/*botão cancelar*/ +#content a.button.with-text { +line-height: 32px; +height: 32px; +margin-top: 2px; +} + +.comment-details .menu-submenu { + right: 3px; +} + +.vote-actions { + top: 30px; +} + +.ui-widget-header { + background: none; + border-width: 0px 0px 1px 0px; +} + +#leave_scrap_content_left { + float: none; + text-align: left; +} + +#leave_scrap textarea { + float: left; +} + +#profile-activity ul, #profile-network ul, #profile-wall ul { + width: 100%; +} + +.profile-activity-lead { + width: 90%; +} + +.ui-tabs #profile-wall.ui-tabs-panel{ padding: 10px;} + +.profile-activities { + display: inline-block; +} + +#profile_activities .profile-activity-item { +/* width: 45%; + display: block; + float: left;*/ + margin: 1em 5px; + padding: 1em; + box-shadow: 5px 5px 5px lightgray; +} + +#leave_scrap { +/* width: 45%; + display: inline-block; + float: none;*/ +} + +#leave_scrap_response { +/* width: 45%; + display: inline-block;*/ +} +#profile-wall #leave_scrap textarea { + width: 100%; +} diff --git a/style-core.css b/style-core.css new file mode 100644 index 0000000..08668f9 --- /dev/null +++ b/style-core.css @@ -0,0 +1,7 @@ +#wrap-2 #user { + display: none; +} + +#user .logged-in a.ctrl-panel { + display: none; +} diff --git a/style-edit.css b/style-edit.css new file mode 100644 index 0000000..94d52b3 --- /dev/null +++ b/style-edit.css @@ -0,0 +1,1451 @@ +@import url(cabecalho.css); +/****************** FIM cabecalho amarelo ******************/ + +/* ==> button.css <== */ + +.button { + -moz-border-radius: 3px; + -webkit-border-radius: 3px; +} + +#content input.button, #content a.button { + background-repeat: no-repeat; + background-color: #EEE; + border: 1px solid #CCC; + color: #555; + line-height: 16px; + height: 16px; + text-decoration: none; +} + +#content input.button.with-text, #content a.button.with-text { + line-height: 20px; + height: 20px; +} + +input.button { + max-height: 20px; +} +input.button.with-text { + max-height: 22px; +} + +#content input.button:hover, #content a.button:hover { + color: #FFF; + background-color: #555; + border: 1px solid #2e3436; + text-decoration: none; +} + +/* ==> layout.css <== */ + +body { + background: #EEE; + font-family: Liberation Sans, Arial, sans-serif; +} + +#wrap-1, #theme-footer { +/* width: 960px;*/ + margin: auto; +} + +body, th, td, input { + font-size: 12px; +} + +#link-go-content { + position: absolute; + top: -100px; +} + +#wrap-2 { + padding: 10px; + position: relative; + border: 1px solid #d3d7cf; + background-color: white; +} + +.msie7 #wrap-2 { + height: 100%; +} + +#content { + /* margin-top: 105px;*/ +} + +/*************************** user bar ********************************/ +/* +#user { + text-align: right; + position: absolute; + right: 10px; + z-index: 10; +}*/ + +#user { + position: relative; + z-index: 9; +} + +#user #top-search {display: none;visibility:hidden;} + +#user a { + position: relative; + color: #888a85; +} + +#user a strong { + font-weight: bold; + color: #555753; +} + +#user .logged-in > * { + margin-left: 25px; +} + +#user a i { + display: block; + width: 16px; + height: 16px; + position: absolute; + left: -17px; + top: -1px; +} +.msie7 #user a i { + top: 3px; +} + +#user #homepage-link i { + width: 18px; + height: 18px; + left: -20px; + top: -2px; + background-position: 50% 50%; +} + +#user form { + position: relative; + display: inline; + margin-left: 20px; +} + +#user form input .blur { + width: 160px; + border: 1px solid #BBB; + -moz-border-radius: 3px; + -webkit-border-radius: 3px; + color: #CCC; +} +#user form input { + border: 1px solid #888; + color: #555; +} + +#user form div { + font-size: 11px; + color: #888; + visibility: hidden; +} +#user form.focused div { + visibility: visible; +} + + + +/*************************** logo ************************************/ + +#site-title { + margin: 0px; + padding: 0px; + position: absolute; + top: 20px; + left: 0px; + z-index: 7; + overflow: hidden; + width: 310px; + height: 90px; +} + +#site-title a { + display: block; + width: 300px; + height: 40px; + position: absolute; + top: 30px; + left: 20px; +} + +#site-title span { + font-size: 1px; + position: absolute; + top: -200px; +} + +/************************** navigation bar ***************************/ + +#navigation { + position: absolute; + top: 49px; + right: 0px; + width: 100%; + text-align: right; + background: #ccc url(imgs/menu-top-bg-left.png) no-repeat; +} + +#navigation-end { + position: absolute; + top: 0px; + right: 0px; + width: 14px; + height: 42px; + background: url(imgs/menu-top-bg-right.png); +} + +#navigation ul { + height: 42px; + margin: 0px; + padding: 0px 10px 0px 0px; + float: right; +} + +#navigation li { + list-style: none; + display: block; + height: auto; + width: 125px; + float: left; + text-align: center; + position: relative; +} + +#navigation a { + border-left: 1px solid #888a85; + display: block; + font-size: 15px; + line-height: 42px; + text-decoration: none; + color: #000; +} +#navigation a:hover { + background: url(imgs/menu-top-hilight.png); + color: #FFF; +} + +#navigation span { + padding: 0px 0px 0px 30px; + background-position: 5px 50%; + background-repeat: no-repeat; +} + +#navigation .menu-submenu ul, #navigation .menu-submenu li{ + float: none; + text-align: right; + border-left: 0px; +} + +#navigation .menu-submenu ul{ + border: 1px solid #888a85; + border-top: 0px; + background-color: #ccc; + padding-right: 2px; + height: auto; + display: block; + padding-top: 20px; +} + +#navigation .menu-submenu{ + bottom: -75px; + width: 126px; + top: 0px; + right: 0px; + position: relative; +} + +#navigation .menu-submenu a{ + padding: 4px 5px; + font-size: 12px; + line-height: normal; + border-left: 0; +} + +#navigation .menu-submenu-trigger { + background: #eee url(/images/down-arrow.png) center center no-repeat; + border: 0px; + height: 8px; + width: 124px; +} +#navigation li:hover .menu-submenu-trigger:hover { + background: #585858 url(imgs/down-arrow-light.png) center center no-repeat; +} + +#navigation li:hover .menu-submenu-trigger{ + display: block; +} + +#navigation li .menu-submenu-trigger{ + display: none; + height: 16px; + top: 42px; + left: 0; + border: 1px solid #888A85; + outline: none; +} + +#navigation .menu-submenu-header, #navigation .menu-submenu-footer, #navigation .menu-submenu h4{ + display: none; +} + +#navigation .common-profile-list-block .vcard .menu-submenu-trigger, +.menu-submenu-trigger { + left: 1px; + top: 33px; + -moz-border-radius: 0px; + -webkit-border-radius: 0px; +} + +/************************** main content *****************************/ + +#main-content-wrapper-1, #main-content-wrapper-2, +#main-content-wrapper-3, #main-content-wrapper-4, +#main-content-wrapper-5, #main-content-wrapper-6, +#main-content-wrapper-7, #main-content-wrapper-8 { + position: relative; +} + +#main-content-wrapper-1 { background: url(imgs/content-bg-N.png) 0% 0% repeat-x } +#main-content-wrapper-2 { background: url(imgs/content-bg-S.png) 0% 100% repeat-x } +#main-content-wrapper-3 { background: url(imgs/content-bg-L.png) 100% 0% repeat-y } +#main-content-wrapper-4 { background: url(imgs/content-bg-O.png) 0% 0% repeat-y } +#main-content-wrapper-5 { background: url(imgs/content-bg-NL.png) 100% 0% no-repeat } +#main-content-wrapper-6 { background: url(imgs/content-bg-NO.png) 0% 0% no-repeat } +#main-content-wrapper-7 { background: url(imgs/content-bg-SL.png) 100% 100% no-repeat } +#main-content-wrapper-8 { background: url(imgs/content-bg-SO.png) 0% 100% no-repeat } +#main-content-wrapper-8 { + padding: 10px 20px; +} + +#content .main-block h1, #not-found h1, #access-denied h1 { + font-variant: small-caps; + color: #555753; + text-align: left; + border-bottom: 2px solid #2e3436; +} + +.block { + position: relative; + padding: 10px 0; + float: none; +} + +/***************************** header ********************************/ +#theme-header { + /*height: 20px;*/ +} +#profile-header, #profile-footer{clear:left;} +/***************************** footer ********************************/ + +#theme-footer #language-chooser { + margin-top: 3em; + text-align: center; +} + + +#theme-footer { + padding: 0px; + font-size: 11px; + color: #555; + margin-bottom: 20px; +} + +#theme-footer a { + color: #333; + text-decoration: none; +} +#theme-footer a:hover { + color: #222; + text-decoration: underline; +} + +#footer-links { + text-align: left; + float: left; +} + +#link-to-doc { + background-repeat: no-repeat; + padding-left: 20px; + padding-top: 2px; + padding-bottom: 2px; +} + +#copyright { + text-align: right; +} + +#noosfero-license { + margin-bottom: 1em; +} + +div.no_media_panel { + margin: 0px; +} + +div#notice { + right: 50%; + margin-right: -470px; +} + +/* ==> blocks.css <== */ + +.block a { + color: #555753; +} +.block a:visited { + color: #888a85; + font-weight: normal; +} +.block a:hover { + color: #2e3436; + text-decoration: underline; +} + + +#content .block { + padding: 0px; + margin: 0px 0px 20px 0px; + position: relative; +} + + +#content .block-title { + font-variant: small-caps; + color: #AAA; + font-size: 14px; + text-align: left; + border-bottom: 2px solid #AAA; +} + +/*************************** Login block *****************************/ + +.login-box { + padding: 0px; +} + +.login-box-content { + margin: 0px; + border: none; + background: none; + padding: 0px; +} + +.login-box-content .button-bar .button { + position: relative; +} + +.login-box .formfieldline input { + width: 99%; +} + +.login-box form { + margin: 0px; +} +.msie7 .login-box form { + padding: 0px 10px 0px 0px; +} + +#content .login-block h2 { + font-variant: small-caps; + color: #AAA; + font-size: 14px; + text-align: left; + border-bottom: 2px solid #AAA; +} + +.login-box p { + text-align: center; + margin: 0px; + padding: 0px; +} + +.login-box .forgot-passwd a { + color: #555753; +} + +.want-to-be-an-user { + font-size: 13px; +} + +#content .logged-user-info h2 { + font-size: none; +} + +.logged-user-info ul { + margin-top: 5px; +} + +.logged-user-info .user-actions { + padding-left: 50px; +} + + +/************************** Profile List *****************************/ + +#content .people-block ul, +#content .profile-list-block ul, +#content .enterprises-block ul, +#content .members-block ul, +#content .communities-block ul, +#content .friends-block ul, +#content .fans-block ul { + min-width: 196px; + width: 192px; + margin: 0px 0px 0px -3px; + padding: 0px; +} + +#content .box-1 .people-block ul, +#content .box-1 .profile-list-block ul, +#content .box-1 .enterprises-block ul, +#content .box-1 .members-block ul, +#content .box-1 .communities-block ul, +#content .box-1 .friends-block ul, +#content .box-1 .fans-block ul { + width: auto; + display: block; +} + +#content .tags-block .block-footer-content a, +#content .people-block .block-footer-content a, +#content .profile-list-block .block-footer-content a, +#content .enterprises-block .block-footer-content a, +#content .members-block .block-footer-content a, +#content .communities-block .block-footer-content a, +#content .friends-block .block-footer-content a { + position: absolute; + top: 2px; + right: 0px; + font-size: 11px; + color: #000; + text-decoration: none; + padding-right: 15px; +} +#content .tags-block .block-footer-content a, +#content .people-block .block-footer-content a, +#content .profile-list-block .block-footer-content a, +#content .enterprises-block .block-footer-content a, +#content .communities-block .block-footer-content a, +#content .friends-block .block-footer-content a { + background: url(imgs/arrow-right-p.png) 100% 50% no-repeat; +} + +#content .members-block .block-footer-content .join-leave-button a { + position: relative; + background-color: #EEE; + border: 1px solid #CCC; + color: #555; + padding-right: inherit; +} + +#content .members-block .block-footer-content .join-leave-button a:hover { + color: #FFF; + background-color: #555; + border: 1px solid #2e3436; + text-decoration: none; +} + +#content .profile-list-block .block-title { + text-align: left; +} + +#content .profile-list li a, +#content .common-profile-list-block .vcard li a { + color: #555; +} +#content .profile-list li a:hover, +#content .common-profile-list-block .vcard li a:hover { + color: #000; + text-decoration: none; +} + +/************************* Recent Contents ***************************/ + +#content .feed-reader-block, +#content .recent-documents-block { + overflow: hidden; +} + +.feed-reader-block li, +.recent-documents-block li { + list-style-image: url(imgs/li-recent.gif); + padding: 5px 0px; +} + +.feed-reader-block li a, +.recent-documents-block li a { + font-weight: bold; +} + +.feed-reader-block li a:visited, +.recent-documents-block li a:visited { + font-weight: normal; +} + +.feed-reader-block li a:hover, +.recent-documents-block li a:hover { + text-decoration: underline; +} + +/************************* Profile Image *****************************/ + +#content .profile-image-block { +} +.profile-big-image-inner1 { + text-align: center; +} + +.profile-big-image { +} +.profile-big-image img { + border: none; + padding: 0px; +} + +.profile-image-block p { + margin: 0px; + font-size: 17px; + font-weight: bold; + color: #555; +} + +.profile-image-block .admin-link { + text-align: center; + font-size: 75%; + clear: both; +} + + +/*************************** My Network ******************************/ + +#content .block.my-network-block { + margin: 0px 0px 10px 0px; +} + +.my-network-block ul { + margin: 0px; + padding: 0px 0px 10px 20px; +} +.my-network-block li { + margin: 0px; + padding: 0px; + list-style: none; +} + + +/*************************** Link List *******************************/ + +.link-list-block .empty { + display: none; +} + +#content .box-1 .link-list-block { + margin: 0px; +} + +#content .link-list-block li { + background: #FFF; + padding: 0px; + margin: 5px 0px; +} + +#content .box-1 .link-list-block li { + display: inline-block; +} + +#content .link-list-block li a { + font-size: 14px; + line-height: 24px; + color: #000; + background-color: #EEE; + background-position: 4px 50%; + border-radius: 4px; +} + +#content .box-1 .link-list-block li a { + padding-left: 25px; + padding-right: 10px; + margin-right: 5px; + background-position: 5px 50%; +} + +#content .link-list-block li a.link-this-page { + border-radius-topright: 0px; + border-radius-bottomright: 0px; + background-color: #cecece; + max-width: 175px; + width: 200px; + border-right: 2px solid #555753; +} + +#content .box-1 .link-list-block li a.link-this-page { + width: auto; + border: none; + border-radius: 4px; +} + +#content .link-list-block li a:hover { + background-color: #555753; + color: #FFF; + text-decoration: none; +} +#content .link-list-block li a.link-this-page:hover { + border-right: 2px solid #555753; +} + + +/************************** Communities ******************************/ + +.communities-block .profile-image { + float: left; + padding-left: 4px; + max-width: 70px; + width: 75px; + height: auto; +} + +.msie7 .communities-block .common-profile-list-block .vcard a { + height: auto; + width: 99%; + padding-bottom: 1px; +} + +.communities-block .vcard a .org { + overflow: hidden; +} +.msie .communities-block .vcard a .org { + height: 30px; +} + +.communities-block .vcard a .may-clear { + clear: left; +} + +/****************************** Tags *********************************/ + +/* the style here is not only for #content .tags-block .tag_cloud */ + +.tag_cloud { + text-align: center; +} + +.tag_cloud a { + text-decoration: none; + white-space: nowrap; +} + +.tag_cloud a small { + opacity: 0.5; + filter:alpha(opacity=50); +} + + +/********************* Product Categories Block **********************/ + +.product-categories-block .catalog-home-link { + display: block; + background: rgba(0,0,0,0.08); + font-weight: bold; + text-align: center; + border-radius: 5px; + padding: 0px; + line-height: 200%; + text-decoration: none; + color: #000; +} +.product-categories-block .catalog-home-link:hover { + background: rgba(0,0,0,0.6); + color: #FFF; + text-decoration: none; +} + +.product-categories-block .catalog-categories-list { + margin-top: 0.5em; +} + +.product-categories-block ul { + list-style-type: none; + margin: 0px; + padding: 0px; + border-radius: 5px; + color: rgba(0,0,0,0.4); +} + +.product-categories-block li { + margin: 0; + padding: 0; + white-space: nowrap; +} + +.product-categories-block li li div { + padding: 0 0 0 1.5em; +} + +.product-categories-block .catalog-categories-list a { + text-decoration: none; + font-size: 120%; + line-height: 150%; + color: #333; + overflow: hidden; + text-overflow: ellipsis; + display: inline-block; + padding: 0 0.3em 0 0.5em; + border-radius: 5px; + max-width: 80%; + vertical-align: middle; +} +.product-categories-block .catalog-categories-list ul a { + text-decoration: none; + font-size: 110%; + line-height: 163.6%; +} +.product-categories-block .catalog-categories-list div:hover a:hover { + background: rgba(0,0,0,0.6); + color: #FFF; + text-decoration: none; +} + +.product-categories-block .catalog-categories-list div:hover a, +.product-categories-block .catalog-categories-list div:hover .count { + background: rgba(0,0,0,0.08); +} + +.block.product-categories-block .catalog-categories-list a { + font-weight: bold; +} + +.block.product-categories-block .catalog-categories-list ul a { + font-weight: normal; +} + +.product-categories-block a:hover { + text-decoration: underline; +} + +.product-categories-block .count { + display: inline-block; + vertical-align: middle; + margin-left: -0.2em; + padding: 0 0.2em; + line-height: 180%; + border-radius: 5px; +} + +.block.product-categories-block .count:before { + content: "("; +} +.block.product-categories-block .count:after { + content: ")"; +} + +.catalog-categories-notice { + color: rgba(0,0,0,0.3); + padding: 0.5em 1em; +} + +/********************* Environment Statistics ************************/ + +#content .environment-statistics-block ul { + margin: 0px 20px; + padding: 0px; +} +#content .environment-statistics-block li { + list-style-image: url(imgs/li-gray.gif); + padding: 3px 0px; + color: #777 +} + +/*************************** News Area *******************************/ + +.action-home-index #content h1 { + color: #555753; + border-bottom: 2px solid #555753; +} + +.highlighted-news-item { + border-top: 1px solid #CCC; + padding-top: 5px; +} +.highlighted-news-item.post-1 { + border: none; + padding-top: 0px; +} + +#highlighted-news h2 a { + font-weight: bold; + color: #2e3436; +} + +.news-area { + border: none; + background: #FFF; + height: auto; + position: relative; +} + +.news-area ul { + border: 1px solid #CCC; + border-top: 2px solid #07C; + height: 125px; + overflow: auto; + margin: 0px; + padding: 5px 10px; + background: url(imgs/comment-bg-S.png) 0% 100% repeat-x; + border-bottom: none; +} + +.news-area li { + margin-left: 15px; + padding: 0px 0px; + list-style-image: url(imgs/li-blue.gif); +} + +#content .news-area h3 a { + font-weight: bold; + color: #2e3436; +} +#content .news-area h3 a:hover { + text-decoration: none; +} + +#content .news-area h3 { + background: #FFF; + margin: 0px; + padding: 0px; +} + +#content .news-area a { + color: #000; +} + +#content .news-area a.news-see-more { + position: absolute; + top: 3px; + right: 0px; + + color: #000; + padding-right: 10px; + background: url(imgs/arrow-right-p.png) 100% 50% no-repeat; +} + +#content .news-area a.news-see-more:hover { + text-decoration: none; + color: #07C; +} + +#portal-news ul { + padding: 0px; + border-top: 1px solid #CCC; +} +#portal-news li { + list-style: none; + padding: 8px 0px; + border-bottom: 1px solid #CCC; +} +#portal-news li a { + font-weight: bold; + color: #555753; +} +#portal-news .post-date, #highlighted-news .post-date { + color: #555753; +} + +#portal-news .post-date { + float: left; +} +#portal-news .post-title { + display: block; + margin-left: 65px; +} + +#highlighted-news .post-title { + font-weight: bold; + font-size: 20px; +} +#highlighted-news h2 { + margin-bottom: 0px; +} + +/* ==> search-results.css <== */ + + +.msie .search-results-box { + width: 48%; +} + +#content .no-boxes h1 { + font-variant: small-caps; + color: #555753; + text-align: left; + border-bottom: 2px solid #2e3436; /*8C0*/ +} + +.query { + display: none; +} + +.controller-search #content .search_form h3 { + display: none; +} + +.controller-search #content .search_form h4 { + background: #DDD; + color: #777; +} +.controller-search .search-options { + border: 1px solid #777; + -moz-border-radius: 5px; + -webkit-border-radius: 5px; +} +.controller-search .search-options ul li { + position: relative; +} + +.controller-search .search-within select { + display: block; + margin-bottom: 5px; +} + +.controller-search .search-within label { + display: block; + float: left; + width: 100px; + text-align: right; + padding-right: 10px; + position: relative; + top: 5px; +} + +.controller-search a { + color: #555753; +} + +#search-results h3 { + color: #555753; /*6A0*/ + font-variant: small-caps; + margin: 0px; +} + +.search-results-innerbox { + border: 1px solid #CCC; + border-top: 2px solid #2e3436; + border-bottom: none; + background: url(imgs/comment-bg-S.png) 0% 100% repeat-x; +} +.only-one-result-box .search-results-innerbox { + border-top: 1px solid #CCC; +} + +#content .search-results-type-article li, +#content .search-results-type-event li { + padding: 5px 0px; +} + +.search-results-type-article a, +.search-results-type-event a { + text-decoration: none; +} +.search-results-type-article a:hover, +.search-results-type-event a:hover { + text-decoration: underline; +} + +/* ==> article.css <== */ + +#article a { + text-decoration: underline; +} + +hr.pre-posts, hr.sep-posts { + display: none; +} + +.blog-post { + background: url(imgs/blog-sep.png) repeat-x; + padding: 15px 20px 5px 20px; + margin: 0px -19px; +} + +#article-actions a.button, +#article-actions a.button:hover { + border: none; + background-color: transparent; + color: #888; +} +#article-actions a.button:hover { + color: #555753; +} +#content a.disabled, +#content a.disabled:hover { + color: #888; + text-decoration: none; +} +#content a.button.disabled, +#content a.button.disabled:hover { + background-color: #CCC; + border-color: #CCC; +} + +#addThis { + text-align: right; +} + +#content .blog-post .title { + border-bottom-color: #CCC; +} +#content .blog-post .title a { + font-weight: bold; + color: #000; + text-decoration: none; +} + +#content .main-block .created-at { + text-align: left; + color: #AAA; +} +#content .main-block .created-at a { + color: #AAA; + text-decoration: none; +} +#content .main-block .created-at a:hover { + color: #555; + text-decoration: underline; +} + +#article-tags { + color: #FFF; +} +#article-tags a { + text-decoration: none; + padding: 0px 2px; + -moz-border-radius: 3px; + -webkit-border-radius: 3px; + background: #BBB; + color: #FFF; +} +#article-tags a:hover { + background: #555753; +} + +#article-hits { + text-align: left; + color: #AAA; +} + +.msie .post_comment_box { + padding-top: 15px; +} + +.post_comment_box.closed h4 { + -moz-border-radius: 4px; + -webkit-border-radius: 4px; +} + +.post_comment_box.opened h4 { + display: block; + background: #FFF; + padding: 0px; + font-variant: small-caps; + color: #555753; + font-size: 14px; + text-align: left; + border-bottom: 2px solid #888a85; +} + +.post_comment_box.opened { + border: none; + background: transparent; +} + +/************* uploaded file *****************/ + +#article .gallery-navigation { + padding: 10px 0; +} + +#article .gallery-navigation .previous { + margin-right: 10px; +} + +#article .gallery-navigation .next { + margin-left: 10px; +} + +#article .gallery-navigation .total-of-images { + font-weight: bold; +} + +#article .uploaded-file-description { + background: #f6f6f6; + border-top: 1px solid #ccc; + border-bottom: 1px solid #ccc; + padding: 1em; +} +#article .uploaded-file-description.empty { + display: none; +} + +#article.file-generic .download-link { + display: block; + margin-bottom: 10px; +} +#article.file-generic .download-link span { + font-size: 150%; + padding-right: 5px; +} +#article.file-generic .download-link a { + font-size: 180%; + text-decoration: none; +} + +/**************************** Comments *******************************/ + +#content .comments h3 { + font-variant: small-caps; + color: #555753; + font-size: 14px; + text-align: left; + border-bottom: 2px solid #888a85; +} + +.article-comment { + border: none; + background: #FFF; +} + +.comment-logged-out h4 { + color: #888; +} + +#content .comment-picture { + text-align: left; + text-decoration: none; + position: relative; +} + +.comment-wrapper-1 { + margin-left: 60px; + background: url(imgs/comment-bg-N.png) 0% 0% repeat-x; +} +.comment-wrapper-2 { + background: url(imgs/comment-bg-S.png) 0% 100% repeat-x; +} +.comment-wrapper-3 { + background: url(imgs/comment-bg-L.png) 100% 0% repeat-y; +} +.comment-wrapper-4 { + background: url(imgs/comment-bg-O.png) 0% 0% repeat-y; +} +.comment-wrapper-5 { + background: url(imgs/comment-bg-SL.png) 100% 100% no-repeat; +} +.comment-wrapper-6 { + background: url(imgs/comment-bg-SO.png) 0% 100% no-repeat; +} +.comment-wrapper-7 { + background: url(imgs/comment-bg-NL.png) 100% 0% no-repeat; +} +.comment-wrapper-8 { + background: url(imgs/comment-bg-NO.png) 0% 0% no-repeat; +} + +.comment-from-owner .comment-wrapper-1 { + background: #fbf7b5 url(/images/comment-owner-bg-N.png) repeat-x; +} +.comment-from-owner .comment-wrapper-2 { + background: url(/images/comment-owner-bg-S.png) 0% 100% repeat-x; +} +.comment-from-owner .comment-wrapper-3 { + background: url(/images/comment-owner-bg-L.png) 100% 0% repeat-y; +} +.comment-from-owner .comment-wrapper-4 { + background: url(/images/comment-owner-bg-O.png) 0% 0% repeat-y; +} +.comment-from-owner .comment-wrapper-5 { + background: url(/images/comment-owner-bg-SL.png) 100% 100% no-repeat; +} +.comment-from-owner .comment-wrapper-6 { + background: url(/images/comment-owner-bg-SO.png) 0% 100% no-repeat; +} +.comment-from-owner .comment-wrapper-7 { + background: url(/images/comment-owner-bg-NL.png) 100% 0% no-repeat; +} +.comment-from-owner .comment-wrapper-8 { + background: url(/images/comment-owner-bg-NO.png) 0% 0% no-repeat; +} + +.comment-created-at { + position: relative; + padding-right: 9px; +} + +.comment-order { + float: right; + display: block; +} + +.comment-from-owner .comment-created-at { + color: #333; +} + +.article-comment .button-bar { + position: relative; + top: 9px; + right: 8px; + z-index: 10px; +} + +.article-comment .button-bar a { + position: relative; +} + +.comment-details { + margin: 0px; + padding: 7px 12px 3px 26px; +} + +/* ==> controllers.css <== */ + +/******** controller-friends action-friends-index ********/ + +.action-friends-index .profile-list li, +.common-profile-list-block .vcard { + border: 1px solid transparent; +} + +.action-friends-index .profile-list li:hover, +.common-profile-list-block .vcard:hover { + border: 1px solid #CCC; + -moz-border-radius: 5px; + -webkit-border-radius: 5px; + background: #EEE; + text-decoration: none; +} + +.common-profile-list-block .vcard a, +.common-profile-list-block .vcard a:hover { + background: transparent; + border: 0; +} + +/******** controller-profile action-profile-index ********/ + +table.profile th { + font-size: 15px; + text-align: left; +} + +/**** controller-memberships action-memberships-index ****/ + +#memberships-index li { + background-color: #FFF; + border: 1px solid #EEE; + -moz-border-radius: 9px; + -webkit-border-radius: 9px; + margin-bottom: 10px; +} + +#memberships-index li .vcard a.profile_link.url { + border: 1px solid transparent; + background-color: #FFF; +} + +#memberships-index li .vcard a.profile_link.url:hover { + border: 1px solid #CCC; + background-color: #EEE; + -moz-border-radius: 4px; + -webkit-border-radius: 4px; +} + +/************************** Control Panel ****************************/ + +.control-panel a, +.control-panel a:visited { + color: #000; + font-weight: bold; + background-position: 2px 50%; +} +.control-panel a:hover { + text-decoration: none; + color: #2e3436; + background-color: #d3d7cf; +} + + + +/* ==> doc.css <== */ + +#online-doc-navigation h1 { + font-variant: small-caps; + color: #AAA; + border-bottom: 2px solid #AAA; +} + +#online-doc-text { + background: transparent url(imgs/blog-sep.png) repeat-x scroll 0 0; + padding: 15px 20px 5px 20px; + margin: 10px -19px; +} + +#online-doc-text h1, +#online-doc-text h2, +#online-doc-text h3, +#online-doc-text h4, +#online-doc-text h5, +#online-doc-text h6 { + font-variant: small-caps; +} + +#online-doc-text h2 { + border-bottom: 2px solid black; +} + +/**************************** Browse *******************************/ + +#content .search-results-type-article li { + padding: 5px 0px; +} + +.search-results-type-article a { + text-decoration: none; +} +.search-results-type-article a:hover { + text-decoration: underline; +} + +/* simplemenu */ + +.simplemenu-submenu { + background: #EEE; + border: 1px solid #AAA; + opacity: 0.9; + text-align: left; +} +.user-status .simplemenu-item a { + color: black; +} + +/* chat */ + +#chat-window .history .self-name { + color: #3F3F90; +} +#chat-window .history .other-name { + color: #7F1F1F; +} + +/* recaptcha*/ + +table#recaptcha_table tr:hover td { + background-color: #fff; +} + + diff --git a/style.css b/style.css new file mode 100644 index 0000000..5cd6070 --- /dev/null +++ b/style.css @@ -0,0 +1,406 @@ +@import url(../base/style.css); +/****************** ESTILO BASE ******************/ +@import url(cabecalho.css); +/****************** FIM cabecalho amarelo ******************/ +@import url(style-core.css); +@import url(user-menu.css); + +body, th, td, input { +font-family: Arial, sans-serif; +} + +#wrap-2 {background-color:#ebeff2;} + +#wrap-1 { + min-width: 800px; +} + +#site-title { + position: relative; + top: 0; + width: auto; + height: auto; + display: none; + visibility: hidden; +} + +#site-title a { + display: block; + width: auto; + height: auto; + position: relative; + top: 0; + left: 0; +} + +/*largura dos blocos lateral e principal*/ + +/*Largura dos blocos funciona somente para duas colunas*/ +/*e somente com a barra lateral do lado direito*/ +/* +.box-1, +.no-boxes { +margin: 0 0 0 0; +float: left; +width: 80%; +} + +.box-1 .blocks, +.no-boxes .blocks { + width: auto; + float: none; + padding: 0 1em; +} + +.box-2, .box-3 { + position: relative; + float: left; + width: 20%; +} + +.box-2 .blocks{ + padding: 0 1em; +} +*/ + +/**Nova largura dos blocos lateral e principal**/ + +.box-1, .no-boxes { +margin: 0 0 0 0; +display: block; +position: relative; +overflow: hidden; +} + +.box-1 .blocks, +.no-boxes .blocks { + width: auto; + float: none; + padding: 0 1em; +} + + +.box-2/*, .box-3 */{ +position: relative; +display: block; +margin: 0; +vertical-align: top; +width: 20%; +} +.box-3{ +min-width: 20%; +} + +.box-2 .blocks, .box-3 .blocks{ + padding: 0 1em; +} + +#content .people-block ul, #content .profile-list-block ul, #content .enterprises-block ul, #content .members-block ul, #content .communities-block ul, #content .friends-block ul, #content .fans-block ul {min-width: auto;width: auto;} + +.box-2 .common-profile-list-block .vcard a.profile_link, .box-3 .common-profile-list-block .vcard a.profile_link {height: 112px;max-height: 112px;} + +.common-profile-list-block .vcard a, .comment-actions .vcard a{} + +/*estilo dos blocos*/ + +#main-content-wrapper-1, +#main-content-wrapper-2, +#main-content-wrapper-3, +#main-content-wrapper-4, +#main-content-wrapper-5, +#main-content-wrapper-6, +#main-content-wrapper-7, +#main-content-wrapper-8 { + background: url(images/no-image.gif) no-repeat; +} + +#main-content-wrapper-8 { + padding: 10px 20px; +} + +#content .block { + padding-bottom: 1em; + margin: 0; +} + +#content .block .block-inner-1 { + background-color: #fff; + box-shadow: 5px 5px 5px -2px #ddd; +} + +#content .box-1 .block .block-inner-1, +#content .no-boxes .block .no-boxes-inner-1 {padding:1em;} + +#content .block .block-inner-2 h3~div {padding:1em;} + +#content .box-1 .block, +#content .no-boxes .block{padding: 0;} + +#content .link-list-block{padding: 0;} + +#content .link-list-block li{margin: 0;} + +#content .link-list-block li a { + border-radius: 0; + padding: 10px 5px 10px 40px; + border-bottom: 1px solid #ccc; + background-color: #f7f9fa; + border-left: 3px solid #f7f9fa; +} + +/*bloco lateral de menu*/ +#content .link-list-block li a.link-this-page{ + max-width:100%; + width: auto; + border-right: 0px; + background-color: #257CAD; + color: white; + border-left: 3px solid #fff; +} + +#content .link-list-block li a.link-this-page:hover, +#content .link-list-block li a:hover { + background-color: #257CAD; + border-left: 3px solid #fff; + border-right: 0px solid #fff; +} + +#profile-header {margin-bottom: 20px;} +#content .block-title { font-variant: inherit; margin-bottom: 0px;} + +/*cabeçalho dos blocos laterais*/ +#content .block h3.block-title, +#content #content-inner .login-block .logged-user-info h2{ + font-size: 16px; + text-align: left; + border-bottom: 1px solid #AAA; + padding: 0.5em; + background-color: #257CAD; + color: white; + font-variant: inherit; +} + +/*cabeçalho do blocos principal*/ +#content .box-1 .block h3.block-title, +#content .no-boxes .block h3.block-title { + color: #333; + font-size: 16px; + text-align: left; + border-bottom: 0px solid #AAA; + padding: 0px; + background-color: transparent; +} + +/*ver todos blocos laterais*/ +#content .tags-block .block-footer-content a, #content .people-block .block-footer-content a, #content .profile-list-block .block-footer-content a, #content .enterprises-block .block-footer-content a, #content .members-block .block-footer-content a, #content .communities-block .block-footer-content a, #content .friends-block .block-footer-content a { + position: absolute; + top: 5px; + right: 5px; + font-size: 12px; + color: #000; + text-decoration: none; + background-color: #fff; + padding: 6px 20px 6px 12px; + border-radius: 12px; + background-position-x: 90%; +} + +#content .tags-block .block-footer-content a:hover, +#content .people-block .block-footer-content a:hover, +#content .profile-list-block .block-footer-content a:hover, +#content .enterprises-block .block-footer-content a:hover, +#content .members-block .block-footer-content a:hover, +#content .communities-block .block-footer-content a:hover, +#content .friends-block .block-footer-content a:hover { + position: absolute; + top: 5px; + right: 5px; + font-size: 12px; + color: #000; + text-decoration: none; + background-color: #257CAD; + color: white; + padding: 6px 20px 6px 12px; + border-radius: 12px; + border: 1px solid white; +} + +#content .main-block h1{ + font-variant: inherit; + color: #555753; + text-align: left; + border-bottom: 0px; +/*font-family: 'Roboto',sans-serif;*/ + margin: 0 0 5px; + font-weight: 700; + color: #4d4d4d; +} + +.search_form input[type="text"], +#public-profile-search input[type="text"]{ + padding: 6px 0; + font-size: 14px; + line-height: 1.42857143; + color: #555; + background-color: #fff; + background-image: none; + border: 1px solid #ccc; +} + +#content form input.button.submit { + max-height: 34px; + cursor: pointer; + height: 34px; + vertical-align: top; + margin-top: 2px; + margin-left: 16px; +} + +.controller-search #content form input.button.submit{ + height: 38px; + max-height: 38px; + background-position-x: 8px; +} + +.controller-search .search-results-box{ + float: none; + width: 100%; + margin-top: 2em; + box-shadow: 5px 5px 5px -2px #ddd; +} + +.controller-search .search-results-box h3{ + font-size: 16px; + text-align: left; + border-bottom: 1px solid #AAA; + padding: 0.5em; + background-color: #257CAD; + color: white !important; + font-variant: none; + margin-left: 0px !important; + text-transform: uppercase; +} + +.controller-search .search-results-innerbox { + height: 100%; + background-image: none; + background-color: white; + border: none; +} + +.search-field-label {width: auto;} + +.search-article-body { + width: 85%; +} + +.search-article-tags .search-article-tag, .search-article-categories .search-article-category { + padding: 5px 6px 3px; +} + +#public-profile-search, #profile-search-results form, .profile-search-block form { + padding: 10px; + margin-bottom: 15px; + background-color: transparent; + -moz-border-radius: 5px; + -webkit-border-radius: 0px; +} + + +/*telas de edição*/ + +/*Estilo dos campos - input*/ +.formfield input, .formfield textarea { + background: none; + border: 2px solid #B0C4DE; + color: #333; + font-size: 16px; + border-radius: 5px; +} + +#content form input.button.submit {margin-left:0px; margin-right: 16px;} + +/*Campo inserir arquivo*/ +input[type~="file"] {border: none;} + +/*formulário de criação de artigos - lado esquerdo*/ +.controller-cms div.with_media_panel { + float: left; + width: 70%; + display: inline-block; + background-color: #FFF; + padding: 1em; + vertical-align: top; +} + +/*caixas de formulário da direita - Inserir imagem e buscar imagem*/ +.text-editor-sidebar{ + float: left; + position: relative; + width: 20%; + display: inline-block; + vertical-align: top; + margin-left: 3%; + right: 0; + top: 0; +} + +/*Campo inserir arquivo - lado direito*/ +.text-editor-sidebar .text-editor-sidebar-box #media-upload-form form input[type~="file"]{font-size: x-small;} + +/*campo de busca de mídia*/ +.text-editor-sidebar #media-search-box .formfield input { + display: inline-block; + width: 85% !important; +} + +/*botão de busca de mídia*/ +#content .text-editor-sidebar #media-search-box form input.button.submit { + max-height: 24px; + cursor: pointer; + height: 34px; + vertical-align: top; + margin-top: 2px; + margin-left: 0; + margin-right: 0; + width: 0px; + color: #EEE; + display: inline-block; +} + +/*botão cancelar*/ +#content a.button.with-text { +line-height: 32px; +height: 32px; +margin-top: 2px; +} + +.comment-details .menu-submenu { + right: 3px; +} + +.vote-actions { + top: 30px; +} + +.ui-widget-header { + background: none; + border-width: 0px 0px 1px 0px; +} + +#leave_scrap_content_left { + float: none; + text-align: left; +} + +#leave_scrap textarea { + float: left; +} + +#profile-activity ul, #profile-network ul, #profile-wall ul { + width: 100%; +} + +.profile-activity-lead { + width: 90%; +} diff --git a/theme-25-09-2014.js b/theme-25-09-2014.js new file mode 100644 index 0000000..f30e11e --- /dev/null +++ b/theme-25-09-2014.js @@ -0,0 +1,63 @@ +jQuery(document).ready(function($) { + // Run code + $("#profile_activities .profile-activity-item").addClass("waterfall"); + + $(".waterfall").waterfall(); + + + $('.btn_control .logged-in #homepage-link').live('click', function(e){ + e.preventDefault(); + $("#wrap-0").toggleClass("menu"); + $("#wrap-1").toggleClass("menu"); + $("#theme-footer").toggleClass("menu"); + }); + +//abrir e fechar tarefas pendentes na barra do usuário// + $(".btn_tasks").click(function(){ + $("#task_list").addClass("hide"); + $("#msg_list").addClass("hide"); + $("#task_list").toggleClass("hide"); + }); + + $("#close_task").click(function(){ + $("#task_list").toggleClass("hide"); + }); + +//abrir e fechar mensagens não lidas na barra do usuário// + $(".btn_msg").click(function(){ + $("#task_list").addClass("hide"); + $("#msg_list").addClass("hide"); + $("#msg_list").toggleClass("hide"); + }); + + $("#close_msg").click(function(){ + $("#msg_list").toggleClass("hide"); + }); + +//abrir e fechar Painel de controle da comunidade// + $("#btn_open_control_panel span").click(function(){ + $("#control_panel_bar").toggleClass("show"); + $("#btn_open_control_panel").toggleClass("show"); + }); + +//abrir e fechar Painel de controle da comunidade// +//aba conteúdo// + $("#navigation ul li#btn_content").click(function(){ + $("#control_panel_bar.menu_aparence").removeClass("show"); + $("#control_panel_bar.menu_settings").removeClass("show"); + $("#control_panel_bar.menu_content").toggleClass("show", 200); + }); +//aba aparência// + $("#navigation ul li#btn_aparence").click(function(){ + $("#control_panel_bar.menu_settings").removeClass("show"); + $("#control_panel_bar.menu_content").removeClass("show"); + $("#control_panel_bar.menu_aparence").toggleClass("show", 200); + }); +//aba Configurações// + $("#navigation ul li#btn_settings").click(function(){ + $("#control_panel_bar.menu_content").removeClass("show"); + $("#control_panel_bar.menu_aparence").removeClass("show"); + $("#control_panel_bar.menu_settings").toggleClass("show", 200); + }); + +}); diff --git a/theme.js b/theme.js new file mode 100644 index 0000000..4f079c3 --- /dev/null +++ b/theme.js @@ -0,0 +1,59 @@ +jQuery(document).ready(function($) { + // Run code + + $('.btn_control .logged-in #homepage-link').live('click', function(e){ + e.preventDefault(); + $("#wrap-0").toggleClass("menu"); + $("#wrap-1").toggleClass("menu"); + $("#theme-footer").toggleClass("menu"); + }); + +//abrir e fechar tarefas pendentes na barra do usuário// + $(".btn_tasks").click(function(){ + $("#task_list").addClass("hide"); + $("#msg_list").addClass("hide"); + $("#task_list").toggleClass("hide"); + }); + + $("#close_task").click(function(){ + $("#task_list").toggleClass("hide"); + }); + +//abrir e fechar mensagens não lidas na barra do usuário// + $(".btn_msg").click(function(){ + $("#task_list").addClass("hide"); + $("#msg_list").addClass("hide"); + $("#msg_list").toggleClass("hide"); + }); + + $("#close_msg").click(function(){ + $("#msg_list").toggleClass("hide"); + }); + +//abrir e fechar Painel de controle da comunidade// + $("#btn_open_control_panel span").click(function(){ + $("#control_panel_bar").toggleClass("show"); + $("#btn_open_control_panel").toggleClass("show"); + }); + +//abrir e fechar Painel de controle da comunidade// +//aba conteúdo// + $("#navigation ul li#btn_content").click(function(){ + $("#control_panel_bar.menu_aparence").removeClass("show"); + $("#control_panel_bar.menu_settings").removeClass("show"); + $("#control_panel_bar.menu_content").toggleClass("show", 200); + }); +//aba aparência// + $("#navigation ul li#btn_aparence").click(function(){ + $("#control_panel_bar.menu_settings").removeClass("show"); + $("#control_panel_bar.menu_content").removeClass("show"); + $("#control_panel_bar.menu_aparence").toggleClass("show", 200); + }); +//aba Configurações// + $("#navigation ul li#btn_settings").click(function(){ + $("#control_panel_bar.menu_content").removeClass("show"); + $("#control_panel_bar.menu_aparence").removeClass("show"); + $("#control_panel_bar.menu_settings").toggleClass("show", 200); + }); + +}); diff --git a/theme.yml b/theme.yml new file mode 100644 index 0000000..af4d631 --- /dev/null +++ b/theme.yml @@ -0,0 +1,6 @@ +name: "Palpite.SERPRO" +#layout: "../../../public/designs/themes/participa-web/index" +layout: "application-ng" +jquery_theme: "smoothness" +icon_theme: [default, pidgin] +public: true diff --git a/theme.yml~ b/theme.yml~ new file mode 100644 index 0000000..5a58258 --- /dev/null +++ b/theme.yml~ @@ -0,0 +1,5 @@ +name: "Participa-WEB" +#layout: "../../../public/designs/themes/participa-web/index" +layout: "application-ng" +jquery_theme: "smoothness" +icon_theme: [default, pidgin] diff --git a/user-menu.css b/user-menu.css new file mode 100644 index 0000000..918089e --- /dev/null +++ b/user-menu.css @@ -0,0 +1,13 @@ +.activity_menu_item a { + color: #ddd; + text-decoration: none; +} +.activity_menu_item:hover a { + color: #333; +} +.activity_menu_item { + cursor: pointer; +} +#navigation-control { + font-size: 14px; +} diff --git a/user_menu.html.erb b/user_menu.html.erb new file mode 100644 index 0000000..92271f5 --- /dev/null +++ b/user_menu.html.erb @@ -0,0 +1,21 @@ +
    + +
    -- libgit2 0.21.2