rbbt-rest 1.6.21 → 1.6.22

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 29af4a586ecd7cf0a2283f030cdf2de22fcee9e9
4
- data.tar.gz: 93ea26c456fe9126fef2e6ff5e29f2ecde4a82cf
3
+ metadata.gz: 110620bc324d7c75a8fe1a8f20c7e61b3612c373
4
+ data.tar.gz: 1ef09f30a13ea2e1641032479be10cac04774d38
5
5
  SHA512:
6
- metadata.gz: 044f6ee1833c243e12514bcd414f063e61096d557677a745342cc2d25fa835e7f2b71f8026ec6020f645b0a7dfc262ca47924261173f75c5fc209a5103fbc101
7
- data.tar.gz: 75e4553a068d80f8e5fbce2c60eb53117b31b53e023d8246a6c1cfad1a0e061dfe9f97c8db76636f2af3bc3e8a484afebb5199e840c1f3fb14a91cb1309c512f
6
+ metadata.gz: 307970ba88b8ccf83ecbbfe7110fb339c6e4697c86762733e029c36596ededb7f29ffc77017b3d01db96095503faf56f2017b17677e5d152a4e0f83501b2d216
7
+ data.tar.gz: 95e04a9112cd3cf9849e0dbfa7669b703669c6bd6cb90106baf224e343dd00879c8a417bd3bb44052e1bdb693512c2f1d4d0fa2606844ba9308a05ea1521fbb0
@@ -8,6 +8,12 @@
8
8
  list-style: none
9
9
  padding-left: 0
10
10
 
11
+ .clearfix
12
+ &:after
13
+ content: ""
14
+ clear: both
15
+ display: block
16
+
11
17
  $subtle-font: rgba(0,0,0,0.30)
12
18
 
13
19
  body
@@ -17,6 +23,7 @@ body
17
23
  padding: 64px 16px 0 32px
18
24
  width: 100%
19
25
  margin-bottom: 2em
26
+ @extend .clearfix
20
27
 
21
28
  #top_menu
22
29
  z-index: 100
@@ -366,3 +373,4 @@ body
366
373
  .preload
367
374
  #footer
368
375
  display: none
376
+
@@ -24,7 +24,7 @@
24
24
  - inputs.each do |input|
25
25
  - input_id = id.nil? ? nil : id + "__" << input.to_s
26
26
  - hide = (options[input] != nil and options[input][:hide])
27
- %div(class="input field #{types[input]} #{input} #{hide ? 'hide' : ''}")
27
+ %div(class="field #{types[input]} #{input} #{hide ? 'hide' : ''}")
28
28
  - input_options = options[input]
29
29
  - input_options = input_options.dup unless input_options.nil?
30
30
  != form_input(input, types[input], defaults[input], values[input], descriptions[input], input_id, input_options)
@@ -48,3 +48,33 @@ rbbt.mview.ibutton = function(options,args){
48
48
  rbbt.mview.dropdown = function(name, options){
49
49
  return m('.ui.dropdown.item', [m('i.icon.dropdown'), name, m('.menu', options)])
50
50
  }
51
+
52
+ rbbt.mview.input = function(type, value, bind, attrs){
53
+ var input = m('input', {type: type})
54
+
55
+ if (value){
56
+ input.attrs[value] = bind.call()
57
+ input.attrs.onchange = m.withAttr(value, bind)
58
+ }
59
+
60
+ if (attrs) input.attrs = $.extend({}, input.attrs, attrs)
61
+
62
+ return input
63
+ }
64
+
65
+ rbbt.mview.field = function(input, label, change, attrs){
66
+ var field = m('.ui.field')
67
+ if (label){
68
+ var lab = m('label', label)
69
+ if (input.attrs.id) lab.attrs.for = input.attrs.id
70
+ field.children.push(lab)
71
+ }
72
+ if (change){
73
+ input.attrs.onchange = change
74
+ }
75
+ field.children.push(input)
76
+
77
+ if (attrs) field.attrs = $.extend({}, field.attrs, attrs)
78
+ return(field)
79
+ }
80
+
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: rbbt-rest
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.6.21
4
+ version: 1.6.22
5
5
  platform: ruby
6
6
  authors:
7
7
  - Miguel Vazquez
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2015-07-31 00:00:00.000000000 Z
11
+ date: 2015-08-04 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rake