work on frontend

This commit is contained in:
Josh
2018-05-24 16:59:20 -04:00
parent 3dd7b33363
commit a1a41bfa43
12 changed files with 189 additions and 60 deletions

View File

@ -10,8 +10,7 @@
<body class="app-background" data-controller="<%= params[:controller] %>" data-action="<%= params[:action] %>"
data-resource="<%= params[:resource] %>"
data-current-user="<%= current_user.try(:encrypted_id) %>"
style="background-image:url(<%= image_path('background.png') if params[:controller] == 'main' %>);">
data-current-user="<%= current_user.try(:encrypted_id) %>">
<!-- Messages -->
<div id='alerts'>
@ -27,17 +26,10 @@
</div>
</div>
<!-- Header -->
<div class='header'>
<span class="logo-wrapper pull-left">
<% if current_user %>
<%= link_to image_tag("bbb_logo.png", :alt => "BigBlueButton", :class => "logo"), room_path(current_user) %>
<% else %>
<%= link_to image_tag("bbb_logo.png", :alt => "BigBlueButton", :class => "logo"), root_path %>
<% end %>
</span>
</div>
<%= render "shared/header" %>
<%= yield %>
<%= render "shared/footer" %>
</body>
</html>

View File

@ -1,36 +1,18 @@
<% content_for :title do %>
<div class="title">
<h2>Landing Title</h2>
</div>
<% end %>
<div class="container">
<h1 class="display-3 text-center text-primary">Teach Students Online</h1>
<hr class="small-rule">
<div class="page-wrapper meetings">
<div class="container-fluid">
<%= render "shared/start_meeting" %>
<div class="center-panel-wrapper">
<%= render layout: 'shared/center_panel' do %>
<div class="center-block center-panel-content-size col-xs-12">
<%= form_for(:meeting, url: create_meeting_path) do |f| %>
<div class="input-field col s12">
<%= f.label :name, "Name" %>
<%= f.text_field :name %>
</div>
<br>
<%= f.submit "Start Meeting", class: "btn white-text light-green" %>
<% end %>
</div>
<% end %>
</div>
<br>
<% unless configured_providers.empty? %>
<div class="center-block col-xs-6 login">
<%= render 'shared/signup' %>
</div>
<% end %>
<div class="text-center" style="padding-top:20px;">
<iframe width="560" height="315" src="https://www.youtube.com/embed/yGX3JCv7OVM" frameborder="0" allowfullscreen></iframe>
</div>
</div>
<%= render "shared/features" %>
</div>
<%= render "shared/video_modal" %>
<script>
$(window).on('load',function(){
$('#welcomeModal').modal('show');
});
</script>

View File

@ -0,0 +1,11 @@
<h1 class="text-center text-primary">Features</h1>
<hr class="small-rule">
<div class="row text-center">
<div class="col-6">
<h1>Feature One</h1>
</div>
<div class="col-6">
<h1>Feature Two</h1>
</div>
</div>

View File

@ -0,0 +1,3 @@
<div class="footer">
<h5 class="text-center">Powered by BigBlueButton.</h5>
</div>

View File

@ -0,0 +1,27 @@
<div class="header py-4">
<div class="container">
<div class="d-flex">
<a class="header-brand" href="{{ site.base }}/index.html">
<%= image_tag("bbb_logo.png", class: "header-brand-img") %>
</a>
<div class="d-flex order-lg-2 ml-auto">
<% if current_user %>
<div class="dropdown">
<a href="#" class="nav-link pr-0 leading-none" data-toggle="dropdown">
<span class="avatar" style="background-image: url({{ site.base }}/{{ user.photo }})"></span>
<span class="ml-2 d-none d-lg-block">
<span class="text-default">{{ user.name }} {{ user.surname }}</span>
<small class="text-muted d-block mt-1">Administrator</small>
</span>
</a>
</div>
<% else %>
<button type="submit" class="btn btn-pill btn-outline-primary ml-auto" data-toggle="modal" data-target="#loginModal">Login</button>
<%= render "shared/login_modal" %>
<% end %>
</div>
</div>
</div>
</div>

View File

@ -0,0 +1,35 @@
<div class="modal fade" id="loginModal" tabindex="-1" role="dialog">
<div class="modal-dialog modal-dialog-centered" role="document">
<div class="modal-content text-center">
<div class="modal-body">
<div class="card-body p-6">
<div class="card-title text-primary">
<h3>Login</h3>
</div>
<hr class="small-rule">
<% configured_providers.each do |provider| %>
<%= link_to omniauth_login_url(provider), class: "btn btn-pill btn-#{provider} btn-block" do %>
<i class="fab fa-<%= provider %>"></i>&ensp;<%= "Login with #{provider.capitalize}" %>
<% end %>
<% end %>
<hr>
<div class="form-group">
<input type="email" class="form-control" id="exampleInputEmail1" aria-describedby="emailHelp" placeholder="Email">
</div>
<div class="form-group">
<input type="password" class="form-control" id="exampleInputPassword1" placeholder="Password">
</div>
<div class="form-footer">
<button type="submit" class="btn btn-outline-primary btn-block btn-pill">Login</button>
</div>
</div>
<div class="card-footer">
<%= link_to "Don't have an account, sign up!", "google.com" %>
</div>
</div>
</div>
</div>
</div>

View File

@ -0,0 +1,15 @@
<div class="card text-center">
<div class="card-body">
<div class="col-8 offset-2 form-group">
<div class="input-group">
<input type="text" class="form-control" placeholder="Enter a meeting name to start!">
<span class="input-group-append">
<button class="btn btn-primary" type="button">Start Meeting</button>
</span>
</div>
</div>
</div>
<div class="card-footer">
Invite URL and stuff goes here.
</div>
</div>

View File

@ -0,0 +1,23 @@
<div class="modal fade" id="welcomeModal" tabindex="-1" role="dialog">
<div class="modal-dialog modal-dialog-centered" role="document">
<div class="modal-content text-center">
<div class="modal-body">
<div class="card-body p-6">
<div class="card-title text-primary">
<h3>Welcome</h3>
</div>
<hr class="small-rule">
<div class="video-container">
<iframe src="https://www.youtube.com/embed/yGX3JCv7OVM" frameborder="0" allowfullscreen></iframe>
</div>
<div class="col-6 offset-3">
<button type="submit" class="btn btn-outline-primary btn-block btn-pill mt-5" data-dismiss="modal">Enter Site</button>
</div>
</div>
</div>
</div>
</div>
</div>