mirror of
https://github.com/indentlabs/notebook.git
synced 2025-10-26 11:19:22 +00:00
character view changes
This commit is contained in:
parent
bb1c222d6f
commit
8ebef947f0
16
app/assets/stylesheets/forms.css.scss
Normal file
16
app/assets/stylesheets/forms.css.scss
Normal file
@ -0,0 +1,16 @@
|
||||
form {
|
||||
.text_field {
|
||||
padding: 0 8px;
|
||||
border-top: 1px solid #c0c0c0;
|
||||
-webkit-box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.1);
|
||||
-moz-box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.1);
|
||||
box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.1);
|
||||
min-height: 29px;
|
||||
background-color: #ffffff;
|
||||
border: 1px solid #d9d9d9;
|
||||
-webkit-transition: border linear .2s, box-shadow linear .2s;
|
||||
-moz-transition: border linear .2s, box-shadow linear .2s;
|
||||
-o-transition: border linear .2s, box-shadow linear .2s;
|
||||
transition: border linear .2s, box-shadow linear .2s;
|
||||
}
|
||||
}
|
||||
@ -1,4 +1,3 @@
|
||||
<%= form_for @character, :url => character_edit_process_path, :html => { :class => 'form-horizontal' } do |f| %>
|
||||
<div class="hidden section starter_section general_section">
|
||||
<div class="control-group">
|
||||
<%= f.label :name, :class => 'control-label' %>
|
||||
@ -271,15 +270,3 @@
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="form-actions">
|
||||
<%= f.submit nil, :class => 'btn btn-primary' %>
|
||||
<%= link_to t('.cancel', :default => t("helpers.links.cancel")),
|
||||
character_list_path, :class => 'btn' %>
|
||||
<%= link_to 'Delete character', character_path,
|
||||
:class => 'btn pull-right btn-danger',
|
||||
:method => :delete,
|
||||
:confirm => 'Are you sure? This action cannot be undone!' %>
|
||||
</div>
|
||||
<% end %>
|
||||
|
||||
@ -1,14 +1,22 @@
|
||||
<%= form_for @character, :url => character_create_process_path, :html => { :class => 'form-horizontal' } do |f| %>
|
||||
<div class="hidden section starter_section general_section">
|
||||
<div class="control-group">
|
||||
<%= f.label :name, :class => 'control-label' %>
|
||||
<div class="controls">
|
||||
<%= f.text_field :name, :class => 'text_field' %>
|
||||
<a href="#" class="help-inline character_name_generator">
|
||||
<i class="icon-refresh"></i> Randomize
|
||||
<div class="row">
|
||||
<div class="col-xs-2" style="text-align: right;">
|
||||
<%= f.label :name, :class => 'control-label' %>
|
||||
</div>
|
||||
<div class="col-xs-9">
|
||||
<%= f.text_field :name, :class => 'form-control' %>
|
||||
</div>
|
||||
<div class="col-xs-1">
|
||||
<a href="#" class="btn character_name_generator">
|
||||
<span class="glyphicon glyphicon-random"></span>
|
||||
</a>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
<div class="control-group">
|
||||
</div>
|
||||
<div class="control-group">
|
||||
<%= f.label 'Role in story', :class => 'control-label' %>
|
||||
<div class="controls">
|
||||
@ -32,8 +40,8 @@
|
||||
</div>
|
||||
<div class="control-group">
|
||||
<%= f.label :universe, :class => 'control-label' %>
|
||||
<div class="controls">
|
||||
<%= f.text_field :universe, :class => 'text_field', :value => @character.universe ? @character.universe.name : "" %>
|
||||
<div class="input-group">
|
||||
<%= f.text_field :universe, :class => 'form-control', :value => @character.universe ? @character.universe.name : "" %>
|
||||
<%= universe_picker %>
|
||||
</div>
|
||||
</div>
|
||||
@ -103,12 +111,12 @@
|
||||
</div>
|
||||
|
||||
<div class="hidden section social_section">
|
||||
<div class="control-group">
|
||||
<%= f.label 'Best Friend', :class => 'control-label' %>
|
||||
<div class="controls">
|
||||
<%= f.text_field :bestfriend, :class => 'text_field' %>
|
||||
<div>
|
||||
<%= f.label 'Best Friend', class: 'control-label' %>
|
||||
<span class="input-group">
|
||||
<%= f.text_field :bestfriend, class: 'form-control' %>
|
||||
<%= character_picker %>
|
||||
</div>
|
||||
</span>
|
||||
</div>
|
||||
<div class="control-group">
|
||||
<%= f.label 'Religion', :class => 'control-label' %>
|
||||
@ -271,10 +279,3 @@
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="form-actions">
|
||||
<%= f.submit nil, :class => 'btn btn-primary' %>
|
||||
<%= link_to t('.cancel', :default => t("helpers.links.cancel")),
|
||||
character_list_path, :class => 'btn' %>
|
||||
</div>
|
||||
<% end %>
|
||||
|
||||
@ -1,14 +1,14 @@
|
||||
|
||||
|
||||
|
||||
|
||||
<ul class="nav nav-tabs">
|
||||
<li class="active tab"><%= link_to "General", "#", :id => "show_general" %></li>
|
||||
<li class="tab"><%= link_to "Appearance", "#", :id => "show_appearance" %></li>
|
||||
<li class="tab"><%= link_to "Social", "#", :id => "show_social" %></li>
|
||||
<li class="tab"><%= link_to "Behavior", "#", :id => "show_behavior" %></li>
|
||||
<li class="tab"><%= link_to "History", "#", :id => "show_history" %></li>
|
||||
<li class="tab"><%= link_to "Favorites", "#", :id => "show_favorites" %></li>
|
||||
<li class="tab"><%= link_to "Relationships", "#", :id => "show_relationships" %></li>
|
||||
<li class="tab"><%= link_to "Notes", "#", :id => "show_notes" %></li>
|
||||
<ul class="nav nav-stacked">
|
||||
<li class="active tab"><%= link_to "General", "#general", :id => "show_general" %></li>
|
||||
<li class="tab"><%= link_to "Appearance", "#appearance", :id => "show_appearance" %></li>
|
||||
<li class="tab"><%= link_to "Social", "#social", :id => "show_social" %></li>
|
||||
<li class="tab"><%= link_to "Behavior", "#behavior", :id => "show_behavior" %></li>
|
||||
<li class="tab"><%= link_to "History", "#history", :id => "show_history" %></li>
|
||||
<li class="tab"><%= link_to "Favorites", "#favorites", :id => "show_favorites" %></li>
|
||||
<li class="tab"><%= link_to "Relationships", "#relationships", :id => "show_relationships" %></li>
|
||||
<li class="tab"><%= link_to "Notes", "#notes", :id => "show_notes" %></li>
|
||||
<li class="divider"></li>
|
||||
<li class="tab"><a href="#expand-all">
|
||||
<span class="glyphicon glyphicon-sort-by-attributes-alt"></span> Expand All
|
||||
</a></li>
|
||||
</ul>
|
||||
|
||||
@ -1,12 +1,37 @@
|
||||
<%- model_class = @character.class -%>
|
||||
|
||||
<div class="row">
|
||||
<div class="col-md-8">
|
||||
<div class="col-xs-3">
|
||||
<div class="card">
|
||||
<h1 class="card-heading">Facets</h1>
|
||||
<%= render :partial => 'tabs' %>
|
||||
</div>
|
||||
|
||||
<div class="card">
|
||||
<h1 class="card-heading">Danger-zone</h1>
|
||||
<div class="card-body">
|
||||
<%= render :partial => 'edit_form' %>
|
||||
<%= link_to 'Delete character forever', character_path,
|
||||
:class => 'btn btn-danger',
|
||||
:method => :delete,
|
||||
:confirm => 'Are you sure? This action cannot be undone!' %>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="col-xs-8">
|
||||
<div class="card">
|
||||
<h1 class="card-heading">Editing <%= @character.name %></h1>
|
||||
<%= form_for @character,
|
||||
:url => character_edit_process_path,
|
||||
:html => { :class => 'form-horizontal' } do |form| %>
|
||||
<div class="card-body">
|
||||
<%= render :partial => 'form', :locals => { :f => form } %>
|
||||
</div>
|
||||
<div class="card-comments">
|
||||
<%= form.submit nil, :class => 'btn btn-primary' %>
|
||||
<%= link_to 'Cancel', character_list_path, :class => 'btn' %>
|
||||
</div>
|
||||
<% end %>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
Loading…
Reference in New Issue
Block a user