basic view up with styles

This commit is contained in:
Torsten Ruger 2015-07-29 18:50:03 +03:00
parent 3bad4cc570
commit 264a52c184
7 changed files with 52 additions and 39 deletions

View File

@ -1 +1,41 @@
// Place your apps css here // Place your apps css here
@import "susy";
$susy: (
columns: 24 ,
gutter-position: split ,
);
.debugger-view { @include container(90%); }
.classes { @include span(3); }
.file-view {
@include span(4);
margin: span(1);
}
.source-view { @include span(6); }
.block-view {
@include span(4);
margin-right: span(3);
height: 200px;
}
.status-view {
@include span(2 at 22);
}
.registers-view {
@include span(20 at 3);
}
.register-view {
@include gallery(3);
margin-top: 10px;
}
.bright {
background-color: orange ;
}

View File

@ -2,12 +2,6 @@
client '/about', action: 'about' client '/about', action: 'about'
# Routes for login and signup, provided by user_templates component gem
client '/signup', component: 'user_templates', controller: 'signup'
client '/login', component: 'user_templates', controller: 'login', action: 'index'
client '/password_reset', component: 'user_templates', controller: 'password_reset', action: 'index'
client '/forgot', component: 'user_templates', controller: 'login', action: 'forgot'
client '/account', component: 'user_templates', controller: 'account', action: 'index'
# The main route, this should be last. It will match any params not # The main route, this should be last. It will match any params not
# previously matched. # previously matched.

View File

@ -2,10 +2,10 @@
module Main module Main
class MainController < Volt::ModelController class MainController < Volt::ModelController
def index def index
code = Ast::ExpressionList.new( [Ast::CallSiteExpression.new(:putstring, [] ,Ast::StringExpression.new("Hello again"))]) # code = Ast::ExpressionList.new( [Ast::CallSiteExpression.new(:putstring, [] ,Ast::StringExpression.new("Hello again"))])
Virtual::Compiler.compile( code , machine.space.get_main ) # Virtual::Compiler.compile( code , machine.space.get_main )
machine.run_before "Register::CallImplementation" # machine.run_before "Register::CallImplementation"
interpreter.start machine.init # interpreter.start machine.init
end end
def about def about

View File

@ -3,20 +3,19 @@
<:Body> <:Body>
<div class="debugger_view">
ClassView classes: machine.space.classes ClassView classes: machine.space.classes
<div class="file_view"> <div class="file-view">
"Future Source code view" "Future Source code view"
</div> </div>
<div class="source_view"> <div class="source-view">
<h4> Virtual Machine Instruction </h4> <h4> Virtual Machine Instruction </h4>
page.sources.each do |s| page.sources.each do |s|
<br> s </br> <br> s </br>
end end
</div> </div>
<div class="block_view"> <div class="block-view">
<div> <div>
<h4> method_name </h4> <h4> method_name </h4>
<h4> Block: #{block_name} </h4> <h4> Block: #{block_name} </h4>
@ -26,7 +25,7 @@
end end
</div> </div>
<div class="status_view"> <div class="status-view">
<div> <div>
button.bright { "next" }.on(:click) { interpreter.tick } button.bright { "next" }.on(:click) { interpreter.tick }
" ".br " ".br
@ -43,10 +42,8 @@
</div> </div>
</div> </div>
<div class="registers_view"> <div class="registers-view">
registers.each do |r , oid| registers.each do |r , oid|
RegisterView interpreter: interpreter , register: r RegisterView interpreter: interpreter , register: r
end end
</div> </div>
</div>

View File

@ -2,28 +2,11 @@
{{ view main_path, "title", {controller_group: 'main'} }} {{ view main_path, "title", {controller_group: 'main'} }}
<:Body> <:Body>
<div class="container"> <div class="debugger_view">
<div class="header">
<ul class="nav nav-pills pull-right">
<:nav href="/">Home</:nav>
<:nav href="/about">About</:nav>
<:user_templates:menu />
</ul>
<h3 class="text-muted">salama-debugger</h3>
</div>
<:volt:notices /> <:volt:notices />
{{ view main_path, 'body', {controller_group: 'main'} }} {{ view main_path, 'body', {controller_group: 'main'} }}
<div class="footer">
<p>&copy; Company {{ Time.now.year }}</p>
</div>
</div> </div>
<:Nav>
<li class="{{ if active_tab? }}active{{ end }}">
<a href="{{ attrs.href }}">{{ yield }}</a>
</li>

View File

@ -2,7 +2,6 @@
# the "home" component loads. # the "home" component loads.
# bootstrap css framework # bootstrap css framework
component 'bootstrap'
Opal.use_gem("salama-reader") Opal.use_gem("salama-reader")
Opal.use_gem("salama-object-file") Opal.use_gem("salama-object-file")