1
0
mirror of https://github.com/wbbaddons/Tims-Chat.git synced 2024-10-31 14:10:08 +00:00

First try of redesign

This commit is contained in:
Tim Düsterhus 2011-12-15 18:55:44 +01:00
parent 966a4f57d3
commit bb1fd6e82c
2 changed files with 140 additions and 148 deletions

View File

@ -57,6 +57,10 @@ if (typeof TimWolla.WCF == 'undefined') TimWolla.WCF = {};
event.preventDefault();
this.submit($(event.target));
}, this));
$('button').click(function (event) {
window.location.href = $(event.target).attr('value');
});
},
/**
* Changes the chat-room.

View File

@ -8,7 +8,6 @@
<style type="text/css">
#chatBox {
padding: 0;
background-color: #D8E7F5;
}
#chatBox > div {
@ -19,27 +18,7 @@
text-align: left;
}
#chatRoomContent {
margin: auto;
padding: 1px 10px 10px;
background-color: #FFFFFF;
width: 68%;
box-shadow: 0 0 5px rgba(0, 0, 0, 0.1);
-moz-box-shadow: 0 0 5px rgba(0, 0, 0, 0.1);
-webkit-box-shadow: 0 0 5px rgba(0, 0, 0, 0.1);
}
.chatSidebar.left {
float: left;
margin-left: -1px;
}
.chatSidebar.right {
float: right;
margin-right: -1px;
}
.chatSidebar {
aside {
overflow: auto;
padding: 0 1px 0 0;
width: 190px;
@ -52,38 +31,23 @@
display: block;
}
.chatSidebar h2 {
background-image: url({icon}arrowDown{/icon});
aside h2 {
margin: auto;
text-align: center;
font-size: 130%;
padding: 7px 25px 7px 35px;
background-position: 15px center;
background-repeat: no-repeat;
background-size: 16px auto;
color: #336699;
cursor: default;
font-weight: bold;
margin-top: 5px;
}
.chatSidebar ul li a {
aside ul li a {
color: #6699CC;
display: block;
padding: 5px 25px 7px 35px;
text-shadow: 0 1px 0 #FFFFFF;
}
.chatSidebar ul li.activeMenuItem a {
color: #336699;
font-weight: bold;
}
.chatSidebar.left ul li.activeMenuItem, .chatSidebar.right ul li.activeMenuItem .bgFix {
background-color: #FFFFFF;
box-shadow: 0 0 5px rgba(0, 0, 0, 0.1);
margin-right: -1px;
overflow: hidden;
}
#topic, #smileyList, #chatOptions {
padding: 5px;
}
@ -102,40 +66,32 @@
#chatForm {
margin-top: 15px;
white-space: nowrap;
margin-right: 34px;
margin-top: 10px;
height: 28px;
}
#chatForm .inputImage {
height: 100%;
margin-bottom: -8px;
}
#chatOptions {
display: inline-block;
}
#chatUserList > ul > li > .bgFix a {
#chatUserList > li > .bgFix a {
background-image: url({icon size='S'}arrowRight{/icon});
background-position: 15px center;
background-repeat: no-repeat;
background-size: 16px auto;
}
#chatUserList > ul > li.activeMenuItem > .bgFix a {
#chatUserList > li.activeMenuItem > .bgFix a {
background-image: url({icon size='S'}arrowDown{/icon});
}
.chatSidebar .chatUserMenu li a {
#chatUserList .chatUserMenu li a {
margin-left: 30px !important;
}
.chatUserMenu {
#chatUserList .chatUserMenu {
display: none;
}
#chatUserList > ul li a {
#chatUserList > li a {
margin-left: 20px;
}
@ -169,10 +125,6 @@
background-image: url({icon size='S'}toLeft1{/icon});
}
.chatSidebar a {
outline: none;
}
.ajaxLoad {
background-position: right center;
background-repeat: no-repeat;
@ -186,38 +138,62 @@
</head>
<body id="tpl{$templateName|ucfirst}">
{include file='header' sandbox=false}
<header class="mainHeading">
<img src="{icon size='L'}chat1{/icon}" alt="" />
<hgroup>
<h1>{lang}wcf.chat.title{/lang}</h1>
</hgroup>
</header>
<div class="tabMenuContainer">
<nav class="tabMenu">
<ul>
<li class="ui-state-active"><a href="{link controller="Chat"}{/link}" title="{lang}wcf.chat.title{/lang}">{lang}wcf.chat.title{/lang}</a></li>
<li><a href="{link controller="Chat" action="Log"}{/link}" title="{lang}wcf.chat.protocol{/lang}">{lang}wcf.chat.protocol{/lang}</a></li>
</ul>
</nav>
<section id="chatBox" class="border tabMenuContent hidden">
<a id="top"></a>
<!-- HEADER -->
<header id="pageHeader" class="pageHeader">
<div>
{hascontent}
<!-- top menu -->
<nav id="topMenu" class="topMenu">
<div>
<aside id="chatRoomList" class="chatSidebar left">
<h2>{lang}wcf.chat.rooms{/lang}</h2>
<ul>
{foreach from=$rooms item='roomListRoom'}
<li{if $roomListRoom->roomID == $room->roomID} class="activeMenuItem"{/if}>
<a href="{link controller='Chat' object=$roomListRoom}{/link}" class="chatRoom">{$roomListRoom}</a>
</li>
{/foreach}
{content}{event name='topMenu'}{/content}
</ul>
</aside>
<aside id="chatUserList" class="chatSidebar right">
<h2>{lang}wcf.chat.users{/lang}</h2>
</div>
</nav>
<!-- /top menu -->
{/hascontent}
<!-- logo -->
<div id="logo" class="logo">
<!-- clickable area -->
<a href="{link controller='Index'}{/link}">
<!-- *** insert header logo here -->
</a>
<!-- /clickable area -->
<!-- search area -->
{event name='searchArea'}
<!-- /search area -->
</div>
<!-- /logo -->
<!-- main menu -->
{include file='mainMenu'}
<!-- /main menu -->
<!-- header navigation -->
<nav class="headerNavigation">
<div>
<ul>
<li id="toBottomLink" class="toBottomLink"><a href="#bottom" title="{lang}wcf.global.scrollDown{/lang}" class="balloonTooltip"><img src="{icon size='S'}toBottom{/icon}" alt="" /> <span class="invisible">{lang}wcf.global.scrollDown{/lang}</span></a></li>
{event name='headerNavigation'}
</ul>
</div>
</nav>
<!-- /header navigation -->
</div>
</header>
<!-- /HEADER -->
<!-- MAIN -->
<div id="main" class="main right">
<div>
<aside class="sidebar">
<button title="{lang}wcf.chat.title{/lang}" value="{link controller="Chat"}{/link}">{lang}wcf.chat.title{/lang}</button>
<button title="{lang}wcf.chat.protocol{/lang}" value="{link controller="Chat" action="Log"}{/link}">{lang}wcf.chat.protocol{/lang}</button>
<h2>{lang}wcf.chat.users{/lang}</h2>
<ul id="chatUserList">
{section name=user start=1 loop=11}
<li id="user-{$user}" class="chatUser">
<span class="bgFix"><a class="chatUserLink" href="javascript:;">User {$user}</a></span>
@ -232,16 +208,31 @@
</li>
{/section}
</ul>
</aside>
<div id="chatRoomContent">
<h2>{lang}wcf.chat.rooms{/lang}</h2>
<nav class="sidebarMenu">
<div>
<ul>
{foreach from=$rooms item='roomListRoom'}
<li{if $roomListRoom->roomID == $room->roomID} class="activeMenuItem"{/if}>
<a href="{link controller='Chat' object=$roomListRoom}{/link}" class="chatRoom">{$roomListRoom}</a>
</li>
{/foreach}
</ul>
</div>
</nav>
</aside>
<!-- CONTENT -->
<section id="content" class="content">
{include file='breadcrumbs' sandbox=false}
<div id="chatRoomContent">
<div id="topic" class="border"{if $room->topic|language === ''} style="display: none;"{/if}>{$room->topic|language}</div>
<div class="chatMessageContainer border content">
<ul></ul>
</div>
<form id="chatForm" action="{link controller="Chat" action="Send"}{/link}" method="post">
<input type="text" id="chatInput" class="inputText" style="width: 100%" name="text" autocomplete="off" />
<input type="image" class="inputImage" alt="Absenden" src="{icon size=M}toRight1{/icon}" />
<input type="text" id="chatInput" class="inputText long" name="text" autocomplete="off" required="required" placeholder="Submit with enter" />
</form>
<div id="chatControls">
@ -281,9 +272,6 @@
</div>
</div>
</div>
</div>
</div>
</section>
</div>
<script type="text/javascript">