Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

#2 - improved UI using BS #3

Merged
merged 2 commits into from Dec 20, 2018
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
5 changes: 5 additions & 0 deletions static/styles/coo.css
Expand Up @@ -5,6 +5,11 @@
/* this class selector colors the font inside display_index */
.display_index {
color: white;
text-align: center;
}

#login_form {
text-align: center;
}

/* Style the header */
Expand Down
16 changes: 10 additions & 6 deletions templates/chatbox.html
Expand Up @@ -9,15 +9,19 @@
{% endblock %}

{% block heading %}
<h1>
Coo Chat Messaging
</h1>
{% endblock %}

<!-- futher extending body tag -->
{% block body %}

<!-- this is the upper header which displays the name-->
<header>
Logged in as <div id="dname">{{ name }}</div>
<h2>
Logged in as <div id="dname">{{ name }}</div>
</h2>
</header>

<section>
Expand All @@ -33,15 +37,15 @@
Create New Channel
<p>
<form id="new_channel">
<input id="channel_name" type="text" name="new_channel" class="chn_name" autocomplete="off" autofocus placeholder="New Channel">
<input id="submit" type=submit>
<input id="channel_name" type="text" name="new_channel" class="chn_name form-control" autocomplete="off" autofocus placeholder="New Channel">
<input id="submit" class="btn btn-primary" type=submit>
</form>
<p>
Direct Messages<br>
<table class="hoverTable" id="user_list">
</table>
<p>
<button id="logout_button" type=submit>Log Out</button>
<button id="logout_button" class="btn btn-secondary" type=submit>Log Out</button>
</nav>

<!-- this portion of page is used to handle the messages and message sender -->
Expand All @@ -51,10 +55,10 @@ <h4 id="message_header">Messages</h4>
</table>
<h4>Enter new message</h4>
<form id="new_message">
<textarea class="newchn_msg" id="message_text" placeholder="Enter message here" wrap="soft">
<textarea class="newchn_msg form-control" id="message_text" placeholder="Enter message here" wrap="soft">
</textarea>
<input type="hidden" value= {{ name }} id="displayname">
<input id="msg_submit" type="submit">
<input id="msg_submit" class="btn btn-primary" type="submit">
</form>
</article>
</section>
Expand Down
19 changes: 10 additions & 9 deletions templates/index.html
Expand Up @@ -13,13 +13,14 @@
{% block body %}
<h2 id="myname"></h2>
<h4 id="welcome"></h4>
<p>
<form id="login_form" action="{{ url_for('chatbox') }}", method="post">
<table>
<tr>
<td class="display_index">Display Name:</td>
<td><input autofocus id="dname_field" type="text" name="displayname" size="50" required></td></tr>
</table>
<button name="signin" id="signin">Sign In</button>
</form>
<div class="login_form form-group">
<div class="container" css="text-align:center">
<form id="login_form" action="{{ url_for('chatbox') }}" method="post">
<div class="display_index">COO</div><br>
<input autofocus placeholder="Enter Display Name" id="dname_field" class="form-control" type="text" name="displayname" size="50" required>
<br>
<button align="center" class="btn btn-primary" name="signin" id="signin">Sign In</button>
</form>
</div>
</div>
{% endblock %}