rad_common_interface 0.0.6 → 0.0.7
Sign up to get free protection for your applications and to get access to all the features.
- data/Rakefile +1 -0
- data/app/static/demo/images/img1.jpg +0 -0
- data/app/static/demo/images/img1_200.jpg +0 -0
- data/app/static/demo/images/img1_icon.jpg +0 -0
- data/app/static/demo/images/img1_thumb.jpg +0 -0
- data/app/static/demo/images/img2.jpg +0 -0
- data/app/static/demo/images/img2_200.jpg +0 -0
- data/app/static/demo/images/img2_icon.jpg +0 -0
- data/app/static/demo/images/img2_thumb.jpg +0 -0
- data/app/static/demo/images/img3.jpg +0 -0
- data/app/static/demo/images/img3_200.jpg +0 -0
- data/app/static/demo/images/img3_icon.jpg +0 -0
- data/app/static/demo/images/img3_thumb.jpg +0 -0
- data/app/static/demo/images/img_big.jpg +0 -0
- data/app/static/demo/images/img_big_icon.jpg +0 -0
- data/app/static/demo/images/img_big_thum.jpg +0 -0
- data/app/static/demo/images/video_icon.png +0 -0
- data/app/static/face/attachments.js +85 -0
- data/app/static/face/dialogs.js +189 -0
- data/app/static/face/discussion.js +47 -0
- data/app/static/face/markup.js +53 -0
- data/app/static/face/more.js +33 -0
- data/app/static/face/table.js +24 -0
- data/app/static/face/tabs.js +26 -0
- data/app/static/face.css +8 -0
- data/app/static/face.js +109 -0
- data/app/static/lib/SimpleDialog/SimpleDialog.ContextMenu.js +36 -0
- data/app/static/lib/SimpleDialog/SimpleDialog.Image.js +121 -0
- data/app/static/lib/SimpleDialog/SimpleDialog.Mask.js +76 -0
- data/app/static/lib/SimpleDialog/SimpleDialog.Static.js +0 -0
- data/app/static/lib/SimpleDialog/SimpleDialog.css +12 -0
- data/app/static/lib/SimpleDialog/SimpleDialog.js +158 -0
- data/app/static/lib/ajax_file_uploading.js +33 -0
- data/app/static/themes/default/reset.css +127 -0
- data/app/static/themes/default/style/application.less +51 -0
- data/app/static/themes/default/style/aspects.less +15 -0
- data/app/static/themes/default/style/basic.less +49 -0
- data/app/static/themes/default/style/forms.less +34 -0
- data/app/static/themes/default/style/items.less +43 -0
- data/app/static/themes/default/style/markup.less +16 -0
- data/app/static/themes/default/style/micelaneous.less +10 -0
- data/app/static/themes/default/style/mixins.less +72 -0
- data/app/static/themes/default/style/styles.less +57 -0
- data/app/static/themes/default/style/tools.less +15 -0
- data/app/static/themes/default/style/variables.less +38 -0
- data/app/static/themes/default/style.css +944 -0
- data/app/static/themes/default/style.js +127 -0
- data/app/static/themes/default/style.less +22 -0
- data/app/static/vendor/flext.js +254 -0
- data/app/static/vendor/formalize/formalize.css +311 -0
- data/app/static/vendor/formalize/mootools.formalize.js +163 -0
- data/app/static/vendor/formalize/reset.css +171 -0
- data/app/static/vendor/iFrameFormRequest.js +95 -0
- data/app/static/vendor/mootools-more.js +4185 -0
- data/app/static/vendor/purr/purr.css +43 -0
- data/app/static/vendor/purr/purr.js +308 -0
- data/app/views/face/_attachments_tag.html.haml +17 -0
- data/app/views/rad/face/demo/commons/aspects.html.haml +32 -0
- data/app/views/rad/face/demo/commons/basic.html.haml +86 -0
- data/app/views/rad/face/demo/commons/forms.html.haml +57 -0
- data/app/views/rad/face/demo/commons/items.html.haml +32 -0
- data/app/views/rad/face/demo/commons/style.html.erb +111 -0
- data/app/views/rad/face/demo/dialogs/dialog.js.haml +1 -0
- data/app/views/rad/face/demo/dialogs/dialog_form.html.haml +7 -0
- data/app/views/rad/face/demo/dialogs/dialog_form.js.erb +1 -0
- data/app/views/rad/face/demo/dialogs/inplace/_element.html.haml +3 -0
- data/app/views/rad/face/demo/dialogs/inplace/_form.html.haml +3 -0
- data/app/views/rad/face/demo/dialogs/inplace.js.haml +1 -0
- data/app/views/rad/face/demo/dialogs/inplace_form.js.haml +2 -0
- data/app/views/rad/face/demo/dialogs/show.html.haml +27 -0
- data/app/views/rad/face/demo/helps/help.html.haml +1 -0
- data/app/views/rad/face/demo/helps/index.html.haml +25 -0
- data/app/views/rad/face/demo/layout.html.haml +3 -0
- data/app/views/rad/face/demo/layout.js.haml +11 -0
- data/app/views/rad/face/demo/shared/_comments.html.haml +11 -0
- data/app/views/rad/face/demo/shared/_core_tools.html.haml +6 -0
- data/app/views/rad/face/demo/shared/_line_previews.html.haml +40 -0
- data/app/views/rad/face/demo/shared/_paginator.html.haml +7 -0
- data/app/views/rad/face/demo/shared/_tools.html.haml +25 -0
- data/app/views/rad/face/demo/shared/_top_navigation_bottom.html.haml +34 -0
- data/app/views/rad/face/demo/sites/blog.html.haml +12 -0
- data/app/views/rad/face/demo/sites/home.html.haml +8 -0
- data/app/views/rad/face/demo/sites/post.html.haml +10 -0
- data/app/views/rad/face/demo/sites/style.html.haml +8 -0
- data/app/views/themes/default/application.html.haml +25 -0
- data/app/views/themes/default/basic_list.html.haml +2 -0
- data/app/views/themes/default/basic_list_item.html.haml +5 -0
- data/app/views/themes/default/bottom_panel.html.haml +16 -0
- data/app/views/themes/default/comment.html.haml +20 -0
- data/app/views/themes/default/controls.html.haml +3 -0
- data/app/views/themes/default/demo_metadata.rb +118 -0
- data/app/views/themes/default/details.html.haml +6 -0
- data/app/views/themes/default/discussion.html.haml +7 -0
- data/app/views/themes/default/divider.html.haml +2 -0
- data/app/views/themes/default/forms/errors.html.haml +4 -0
- data/app/views/themes/default/forms/field.html.haml +18 -0
- data/app/views/themes/default/forms/form.html.haml +4 -0
- data/app/views/themes/default/forms/line.html.haml +8 -0
- data/app/views/themes/default/help.html.haml +3 -0
- data/app/views/themes/default/html.html.haml +1 -0
- data/app/views/themes/default/index.html.haml +6 -0
- data/app/views/themes/default/item.html.haml +12 -0
- data/app/views/themes/default/layout_templates/dashboard.html.haml +1 -0
- data/app/views/themes/default/layout_templates/default.html.haml +22 -0
- data/app/views/themes/default/line.html.haml +21 -0
- data/app/views/themes/default/message.html.haml +2 -0
- data/app/views/themes/default/more.html.haml +8 -0
- data/app/views/themes/default/narrow.html.haml +2 -0
- data/app/views/themes/default/navigation.html.haml +16 -0
- data/app/views/themes/default/paginator.html.haml +8 -0
- data/app/views/themes/default/shared/details.html.haml +17 -0
- data/app/views/themes/default/table.html.haml +9 -0
- data/app/views/themes/default/table_row.html.haml +4 -0
- data/app/views/themes/default/tabs.html.haml +27 -0
- data/app/views/themes/default/tag_selector.html.haml +10 -0
- data/app/views/themes/default/text.html.haml +4 -0
- data/app/views/themes/default/thumb.html.haml +10 -0
- data/app/views/themes/default/title.html.haml +3 -0
- data/app/views/themes/default/tool.html.haml +5 -0
- data/app/views/themes/default/toolbar.html.haml +16 -0
- data/app/views/themes/default/top_panel.html.haml +18 -0
- metadata +153 -25
@@ -0,0 +1,121 @@
|
|
1
|
+
SimpleDialog.Image = new Class({
|
2
|
+
Extends: SimpleDialog,
|
3
|
+
|
4
|
+
options: {
|
5
|
+
images: [],
|
6
|
+
keys: {
|
7
|
+
left: function(){
|
8
|
+
var images = this.options.images;
|
9
|
+
var i = images.indexOf(this.imageUrl);
|
10
|
+
if(i >= 0){
|
11
|
+
i = i == 0 ? images.length - 1 : i - 1;
|
12
|
+
this.show(images[i]);
|
13
|
+
} else {
|
14
|
+
console.log("SimpleDialog.Image: can't show previous image!");
|
15
|
+
}
|
16
|
+
},
|
17
|
+
right: function(){
|
18
|
+
var images = this.options.images;
|
19
|
+
var i = images.indexOf(this.imageUrl);
|
20
|
+
if(i >= 0){
|
21
|
+
i = i == images.length - 1 ? 0 : i + 1;
|
22
|
+
this.show(images[i]);
|
23
|
+
} else {
|
24
|
+
console.log("SimpleDialog.Image: can't show next image!");
|
25
|
+
}
|
26
|
+
},
|
27
|
+
esc: function(){
|
28
|
+
this.destroy();
|
29
|
+
}
|
30
|
+
}
|
31
|
+
},
|
32
|
+
|
33
|
+
initialize: function(options){
|
34
|
+
this.parent(options);
|
35
|
+
},
|
36
|
+
|
37
|
+
|
38
|
+
//
|
39
|
+
// Protected methods
|
40
|
+
//
|
41
|
+
_buildContent: function(imageUrl){
|
42
|
+
this.imageUrl = imageUrl;
|
43
|
+
|
44
|
+
this.image = new Element('img', {
|
45
|
+
events: {
|
46
|
+
load: function(){
|
47
|
+
(function(){
|
48
|
+
var setSize = function(){
|
49
|
+
this.image.inject(this.element)
|
50
|
+
this.image.store('dimensions', this.image.getSize());
|
51
|
+
}.bind(this);
|
52
|
+
|
53
|
+
setSize();
|
54
|
+
this._resize();
|
55
|
+
setSize(); //stupid ie
|
56
|
+
this._relocate();
|
57
|
+
}).bind(this).delay(10);
|
58
|
+
}.bind(this),
|
59
|
+
error: function(){
|
60
|
+
this.fireEvent('error');
|
61
|
+
this.image.destroy();
|
62
|
+
this.element.set('html', this.options.errorMessage);
|
63
|
+
}.bind(this)
|
64
|
+
},
|
65
|
+
styles: {
|
66
|
+
width: 'auto',
|
67
|
+
height: 'auto'
|
68
|
+
}
|
69
|
+
});
|
70
|
+
this.image.src = imageUrl;
|
71
|
+
},
|
72
|
+
|
73
|
+
_resize: function(){
|
74
|
+
// //keep currentIndex height/width
|
75
|
+
// var currentDimensions = {x: '', y: ''};
|
76
|
+
// if(this.image) currentDimensions = this.image.getSize();
|
77
|
+
//
|
78
|
+
// ///empty the content, show the indicator
|
79
|
+
// this.element.set('html','').setStyles({
|
80
|
+
// width: currentDimensions.x,
|
81
|
+
// height: currentDimensions.y
|
82
|
+
// });
|
83
|
+
// this._position();
|
84
|
+
// // this.fade();
|
85
|
+
|
86
|
+
var imageDimensions = this.image.retrieve('dimensions');
|
87
|
+
if(imageDimensions){ // check if image already loaded
|
88
|
+
var maxX = (window.getSize().x * 0.9).toInt();
|
89
|
+
var maxY = (window.getSize().y * 0.9).toInt();
|
90
|
+
|
91
|
+
var imgX = imageDimensions.x; var imgY = imageDimensions.y;
|
92
|
+
|
93
|
+
var xRatio = 1, yRatio = 1;
|
94
|
+
if(imgX > maxX) xRatio = maxX / imgX;
|
95
|
+
if(imgY > maxY) yRatio = maxY / imgY;
|
96
|
+
var ratio = xRatio < yRatio ? xRatio : yRatio;
|
97
|
+
|
98
|
+
var imgX = (imgX * ratio).toInt();
|
99
|
+
var imgY = (imgY * ratio).toInt();
|
100
|
+
|
101
|
+
this.image.width = imgX;
|
102
|
+
this.image.height = imgY;
|
103
|
+
this.image.setStyles({width: imgX, height: imgY});
|
104
|
+
}
|
105
|
+
|
106
|
+
|
107
|
+
//
|
108
|
+
// //if image is taller than window...
|
109
|
+
// // if(imageDimensions && (imageDimensions.y > maxHeight)){
|
110
|
+
// // this.image.height = maxHeight;
|
111
|
+
// // this.image.width = (imageDimensions.x * (maxHeight / imageDimensions.y));
|
112
|
+
// // this.image.setStyles({
|
113
|
+
// // height: maxHeight,
|
114
|
+
// // width: (imageDimensions.x * (maxHeight / imageDimensions.y)).toInt()
|
115
|
+
// // });
|
116
|
+
// // }
|
117
|
+
//
|
118
|
+
// //get rid of styles
|
119
|
+
// this.element.setStyles({height: '', width: ''});
|
120
|
+
}
|
121
|
+
});
|
@@ -0,0 +1,76 @@
|
|
1
|
+
//
|
2
|
+
// You can attach a Mask to Dialog, and it will acts (show, hide, destroy) automatically.
|
3
|
+
//
|
4
|
+
// dialog = new SimpleDialog()
|
5
|
+
// SimpleDialog.Mask.new(dialog) // attach and forget about it, it will act automatically
|
6
|
+
// dialog ...
|
7
|
+
//
|
8
|
+
SimpleDialog.Mask = new Class({
|
9
|
+
initialize: function(dialog){
|
10
|
+
this.element = new Element('div', {'class': 'simple_dialog_mask', styles: {'display': 'none'}});
|
11
|
+
this.element.inject(document.body);
|
12
|
+
|
13
|
+
this._attachEvents();
|
14
|
+
this._attachToDialog(dialog);
|
15
|
+
},
|
16
|
+
|
17
|
+
show: function(){
|
18
|
+
this.element.show();
|
19
|
+
this._resize();
|
20
|
+
this._relocate();
|
21
|
+
return this;
|
22
|
+
},
|
23
|
+
|
24
|
+
hide: function(){
|
25
|
+
this.element.hide();
|
26
|
+
return this;
|
27
|
+
},
|
28
|
+
|
29
|
+
toElement: function (){
|
30
|
+
return this.element;
|
31
|
+
},
|
32
|
+
|
33
|
+
destroy: function(){
|
34
|
+
this._detachEvents();
|
35
|
+
this.element.destroy();
|
36
|
+
|
37
|
+
return this;
|
38
|
+
},
|
39
|
+
|
40
|
+
//
|
41
|
+
// Protected methods
|
42
|
+
//
|
43
|
+
_attachToDialog: function(dialog){
|
44
|
+
['show', 'hide', 'destroy'].each(function(name){
|
45
|
+
dialog.addEvent(name, this[name].bind(this));
|
46
|
+
}.bind(this));
|
47
|
+
},
|
48
|
+
|
49
|
+
_relocate: function(){
|
50
|
+
var scrollSize = window.getScroll();
|
51
|
+
this.element.setStyles({left: scrollSize.x, top: scrollSize.y});
|
52
|
+
return this;
|
53
|
+
},
|
54
|
+
|
55
|
+
_resize: function(){
|
56
|
+
var size = window.getSize();
|
57
|
+
this.element.setStyles({width: size.x, height: size.y});
|
58
|
+
return this;
|
59
|
+
},
|
60
|
+
|
61
|
+
_attachEvents: function(){
|
62
|
+
this.updateEvent = function(e){
|
63
|
+
this._resize();
|
64
|
+
this._relocate();
|
65
|
+
}.bind(this);
|
66
|
+
|
67
|
+
window.addEvent('resize', this.updateEvent);
|
68
|
+
window.addEvent('scroll', this.updateEvent);
|
69
|
+
},
|
70
|
+
|
71
|
+
// Detaches events upon close
|
72
|
+
_detachEvents: function(){
|
73
|
+
window.removeEvent('resize', this.updateEvent);
|
74
|
+
window.removeEvent('scroll', this.updateEvent);
|
75
|
+
}
|
76
|
+
});
|
File without changes
|
@@ -0,0 +1,158 @@
|
|
1
|
+
var SimpleDialog = new Class({
|
2
|
+
Implements: [Options, Events],
|
3
|
+
|
4
|
+
options: {
|
5
|
+
keys:{
|
6
|
+
esc: function(){this.destroy();}
|
7
|
+
}
|
8
|
+
},
|
9
|
+
|
10
|
+
initialize: function(options){
|
11
|
+
this.setOptions(options);
|
12
|
+
this._buildElement();
|
13
|
+
this._attachKeyEvents();
|
14
|
+
this._attachUpdateEvents();
|
15
|
+
this._setFocus();
|
16
|
+
},
|
17
|
+
|
18
|
+
show: function(){
|
19
|
+
this.element.empty();
|
20
|
+
this._buildContent.apply(this, arguments);
|
21
|
+
|
22
|
+
this.element.show();
|
23
|
+
this._resize();
|
24
|
+
this._relocate();
|
25
|
+
|
26
|
+
this.fireEvent('show');
|
27
|
+
|
28
|
+
return this;
|
29
|
+
},
|
30
|
+
|
31
|
+
hide: function(){
|
32
|
+
this.element.hide();
|
33
|
+
this.fireEvent('hide');
|
34
|
+
return this;
|
35
|
+
},
|
36
|
+
|
37
|
+
destroy: function(){
|
38
|
+
this.fireEvent('destroy');
|
39
|
+
this._detachEvents();
|
40
|
+
this.element.destroy();
|
41
|
+
return this;
|
42
|
+
},
|
43
|
+
|
44
|
+
wait: function(content){
|
45
|
+
content = content || "<p>Please wait ...</p>"
|
46
|
+
this.element.getChildren().hide();
|
47
|
+
Elements.from(content).inject(this.element);
|
48
|
+
return this;
|
49
|
+
},
|
50
|
+
|
51
|
+
toElement: function (){
|
52
|
+
return this.element;
|
53
|
+
},
|
54
|
+
|
55
|
+
//
|
56
|
+
// Protected methods
|
57
|
+
//
|
58
|
+
_relocate: function(){
|
59
|
+
var windowSize = window.getSize(),
|
60
|
+
scrollSize = window.getScroll(),
|
61
|
+
elementSize = this.element.getSize();
|
62
|
+
this.element.setStyles({
|
63
|
+
left: scrollSize.x + ((windowSize.x - elementSize.x) / 2),
|
64
|
+
top: scrollSize.y + ((windowSize.y - elementSize.y) / 3)
|
65
|
+
});
|
66
|
+
return this;
|
67
|
+
},
|
68
|
+
|
69
|
+
_resize: function(){
|
70
|
+
},
|
71
|
+
|
72
|
+
_buildElement: function(){
|
73
|
+
this.element = new Element('div', {'class': 'simple_dialog', styles: {'display': 'none'}});
|
74
|
+
this.element.inject(document.body);
|
75
|
+
},
|
76
|
+
|
77
|
+
_buildContent: function(html){
|
78
|
+
Elements.from(html).inject(this.element);
|
79
|
+
},
|
80
|
+
|
81
|
+
_setFocus: function(){
|
82
|
+
(function(){
|
83
|
+
this.element.setAttribute('tabIndex',0);
|
84
|
+
this.element.focus();
|
85
|
+
}).bind(this).delay(10);
|
86
|
+
},
|
87
|
+
|
88
|
+
_attachKeyEvents: function(){
|
89
|
+
this.keyEvent = function(e){
|
90
|
+
if(this.options.keys[e.key]) this.options.keys[e.key].call(this);
|
91
|
+
}.bind(this);
|
92
|
+
this.element.addEvent('keyup', this.keyEvent);
|
93
|
+
},
|
94
|
+
|
95
|
+
_attachUpdateEvents: function(){
|
96
|
+
this.updateEvent = function(e){
|
97
|
+
this._resize();
|
98
|
+
this._relocate();
|
99
|
+
}.bind(this);
|
100
|
+
window.addEvent('resize', this.updateEvent);
|
101
|
+
window.addEvent('scroll', this.updateEvent);
|
102
|
+
window.addEvent('updateStyle', this.updateEvent);
|
103
|
+
},
|
104
|
+
|
105
|
+
_detachEvents: function(){
|
106
|
+
if(this.keyEvent) this.element.removeEvent('keyup', this.keyEvent);
|
107
|
+
if(this.updateEvent){
|
108
|
+
window.removeEvent('resize', this.updateEvent);
|
109
|
+
window.removeEvent('scroll', this.updateEvent);
|
110
|
+
window.removeEvent('updateStyle', this.updateEvent);
|
111
|
+
}
|
112
|
+
}
|
113
|
+
});
|
114
|
+
|
115
|
+
|
116
|
+
//
|
117
|
+
// Autodestroy - closes element if user clicks on element or anywhere on the document body.
|
118
|
+
//
|
119
|
+
SimpleDialog.Autodestroy = new Class({
|
120
|
+
autodestroy: function(){
|
121
|
+
SimpleDialog.Autodestroy.elements.add(this);
|
122
|
+
this.addEvent('click', function(){
|
123
|
+
this.close();
|
124
|
+
}.bind(this));
|
125
|
+
}
|
126
|
+
});
|
127
|
+
|
128
|
+
SimpleDialog.Autodestroy.extend({
|
129
|
+
elements: [],
|
130
|
+
close: function(){
|
131
|
+
this.elements.invoke('destroy');
|
132
|
+
this.elements.clear();
|
133
|
+
|
134
|
+
}
|
135
|
+
});
|
136
|
+
|
137
|
+
document.body.addEvent('click', function(){
|
138
|
+
SimpleDialog.Autodestroy.close();
|
139
|
+
});
|
140
|
+
|
141
|
+
|
142
|
+
//
|
143
|
+
// OnlyOne, allows only one instance of element to be active, closes all other elements when a new one is created.
|
144
|
+
//
|
145
|
+
SimpleDialog.OnlyOne = new Class({
|
146
|
+
onlyOne: function(element){
|
147
|
+
SimpleDialog.OnlyOne.onlyOne(element);
|
148
|
+
}
|
149
|
+
});
|
150
|
+
|
151
|
+
SimpleDialog.OnlyOne.extend({
|
152
|
+
elements: [],
|
153
|
+
onlyOne: function(element){
|
154
|
+
this.elements.invoke('destroy');
|
155
|
+
this.elements.clear();
|
156
|
+
this.elements.add(element);
|
157
|
+
}
|
158
|
+
});
|
@@ -0,0 +1,33 @@
|
|
1
|
+
//
|
2
|
+
// Support AJAX file uploading
|
3
|
+
//
|
4
|
+
Rad.implement({
|
5
|
+
submitFormViaIFrame: function(form, data, callback){
|
6
|
+
callback = callback || function(){};
|
7
|
+
request = new iFrameFormRequest(form, {
|
8
|
+
onComplete: function(response){
|
9
|
+
Browser.exec(response);
|
10
|
+
callback.call();
|
11
|
+
window.fireEvent('updated');
|
12
|
+
window.fireEvent('updateStyle');
|
13
|
+
},
|
14
|
+
onFailure: function(){
|
15
|
+
callback.call();
|
16
|
+
console.log("invalid iFrame request!");
|
17
|
+
window.fireEvent('updated');
|
18
|
+
window.fireEvent('updateStyle');
|
19
|
+
}
|
20
|
+
}).send();
|
21
|
+
},
|
22
|
+
|
23
|
+
submitForm: function(form, data, callback){
|
24
|
+
var hasFile = form.getElements('input[type=file]').any(function(input){
|
25
|
+
return !input.get('value').blank();
|
26
|
+
});
|
27
|
+
if(hasFile){
|
28
|
+
this.submitFormViaIFrame(form, data, callback);
|
29
|
+
}else{
|
30
|
+
this.submitFormViaXhr(form, data, callback);
|
31
|
+
}
|
32
|
+
}
|
33
|
+
});
|
@@ -0,0 +1,127 @@
|
|
1
|
+
/*
|
2
|
+
Copyright (c) 2008, Yahoo! Inc. All rights reserved.
|
3
|
+
Code licensed under the BSD License:
|
4
|
+
http://developer.yahoo.net/yui/license.txt
|
5
|
+
version: 3.0.0pr1
|
6
|
+
*/
|
7
|
+
|
8
|
+
/*html {
|
9
|
+
color: #000;
|
10
|
+
background: #FFF; }*/
|
11
|
+
|
12
|
+
body, div, dl, dt, dd, ul, ol, li, h1, h2, h3, h4, h5, h6, pre, code, form, fieldset, legend, input, textarea, p, blockquote, th, td {
|
13
|
+
margin: 0;
|
14
|
+
padding: 0; }
|
15
|
+
|
16
|
+
table {
|
17
|
+
border-collapse: collapse;
|
18
|
+
border-spacing: 0; }
|
19
|
+
|
20
|
+
fieldset, img {
|
21
|
+
border: 0; }
|
22
|
+
|
23
|
+
address, caption, cite, code, dfn, em, strong, th, var {
|
24
|
+
font-style: normal;
|
25
|
+
font-weight: normal; }
|
26
|
+
|
27
|
+
li {
|
28
|
+
list-style: none; }
|
29
|
+
|
30
|
+
caption, th {
|
31
|
+
text-align: left; }
|
32
|
+
|
33
|
+
h1, h2, h3, h4, h5, h6 {
|
34
|
+
font-size: 100%;
|
35
|
+
font-weight: normal; }
|
36
|
+
|
37
|
+
q:before, q:after {
|
38
|
+
content: ''; }
|
39
|
+
|
40
|
+
abbr, acronym {
|
41
|
+
border: 0;
|
42
|
+
font-variant: normal; }
|
43
|
+
|
44
|
+
sup {
|
45
|
+
vertical-align: text-top; }
|
46
|
+
|
47
|
+
sub {
|
48
|
+
vertical-align: text-bottom; }
|
49
|
+
|
50
|
+
input, textarea, select {
|
51
|
+
font-family: inherit;
|
52
|
+
font-size: inherit;
|
53
|
+
font-weight: inherit; }
|
54
|
+
|
55
|
+
input, textarea, select {
|
56
|
+
*font-size: 100%; }
|
57
|
+
|
58
|
+
legend {
|
59
|
+
color: #000; }
|
60
|
+
|
61
|
+
h1 {
|
62
|
+
font-size: 138.5%; }
|
63
|
+
|
64
|
+
h2 {
|
65
|
+
font-size: 123.1%; }
|
66
|
+
|
67
|
+
h3 {
|
68
|
+
font-size: 108%; }
|
69
|
+
|
70
|
+
h1, h2, h3 {
|
71
|
+
margin: 1em 0; }
|
72
|
+
|
73
|
+
h1, h2, h3, h4, h5, h6, strong {
|
74
|
+
font-weight: bold; }
|
75
|
+
|
76
|
+
abbr, acronym {
|
77
|
+
border-bottom: 1px dotted #000;
|
78
|
+
cursor: help; }
|
79
|
+
|
80
|
+
em {
|
81
|
+
font-style: italic; }
|
82
|
+
|
83
|
+
blockquote, ul, ol, dl {
|
84
|
+
margin: 1em; }
|
85
|
+
|
86
|
+
ol, ul, dl {
|
87
|
+
margin-left: 2em; }
|
88
|
+
|
89
|
+
ol li {
|
90
|
+
list-style: decimal outside; }
|
91
|
+
|
92
|
+
ul li {
|
93
|
+
list-style: disc outside; }
|
94
|
+
|
95
|
+
dl dd {
|
96
|
+
margin-left: 1em; }
|
97
|
+
|
98
|
+
th {
|
99
|
+
font-weight: bold;
|
100
|
+
text-align: center; }
|
101
|
+
|
102
|
+
caption {
|
103
|
+
margin-bottom: .5em;
|
104
|
+
text-align: center; }
|
105
|
+
|
106
|
+
p, fieldset, table, pre {
|
107
|
+
margin-bottom: 1em; }
|
108
|
+
|
109
|
+
input[type=text], input[type=password], textarea {
|
110
|
+
width: 12.25em;
|
111
|
+
*width: 11.9em; }
|
112
|
+
|
113
|
+
body {
|
114
|
+
font: 13px/1.231 arial,helvetica,clean,sans-serif;
|
115
|
+
*font-size: small;
|
116
|
+
*font: x-small; }
|
117
|
+
|
118
|
+
select, input, button, textarea {
|
119
|
+
font: 99% arial,helvetica,clean,sans-serif; }
|
120
|
+
|
121
|
+
table {
|
122
|
+
font-size: inherit;
|
123
|
+
font: 100%; }
|
124
|
+
|
125
|
+
pre, code, kbd, samp, tt {
|
126
|
+
font-family: monospace;
|
127
|
+
*font-size: 108%; }
|
@@ -0,0 +1,51 @@
|
|
1
|
+
// the_layout
|
2
|
+
body {
|
3
|
+
> .css_box {max-width: @max_width; margin-left: auto; margin-right: auto;
|
4
|
+
> table.css_table {
|
5
|
+
> tbody {
|
6
|
+
> tr {
|
7
|
+
> td.css_td1 {}
|
8
|
+
> td.css_td2 {width: @tools_width;}}}}
|
9
|
+
> .css_box {}}}
|
10
|
+
|
11
|
+
|
12
|
+
.the_content {}
|
13
|
+
|
14
|
+
|
15
|
+
.the_aspects {}
|
16
|
+
|
17
|
+
|
18
|
+
.the_tools {.s_box; .s_border; .s_round;}
|
19
|
+
|
20
|
+
.panel_t () {.t_toolbar;
|
21
|
+
.css_box {max-width: @max_width; margin-left: auto; margin-right: auto;}}
|
22
|
+
.panel_s {.s_toolbar; .s_small_text;
|
23
|
+
.css_box {
|
24
|
+
.l_left {// padding-left: @normal + @small + @normal;
|
25
|
+
.l_logo {font-weight: bold;}
|
26
|
+
.l_item {}}
|
27
|
+
.l_right {// padding-right: @normal + @small + @normal;
|
28
|
+
.l_item {}}}}
|
29
|
+
|
30
|
+
.the_top_panel {.panel_t; .panel_s; background: @light_color;
|
31
|
+
.css_box {
|
32
|
+
.l_left {
|
33
|
+
.l_item {}
|
34
|
+
.l_logo {font-weight: bold;}}
|
35
|
+
.l_right {
|
36
|
+
.l_item {}}}}
|
37
|
+
|
38
|
+
|
39
|
+
.the_bottom_panel {.panel_t; .panel_s; background-color: @light_color; padding-top: @big; padding-bottom: @big;}
|
40
|
+
|
41
|
+
|
42
|
+
.the_navigation {.panel_t; .panel_s;
|
43
|
+
.css_box {
|
44
|
+
.l_active {font-weight: bold; background-color: @light_color; .s_round_bl(@small_radius); .s_round_br(@small_radius);}}}
|
45
|
+
|
46
|
+
/*.the_navigation_t {.t_tabs;
|
47
|
+
> .css_box {.t_max_width;}}
|
48
|
+
.the_navigation {.the_navigation_t; .s_tabs; .s_small_text; padding-left: 0; padding-right: 0;
|
49
|
+
> .css_box {
|
50
|
+
.l_item:first-child {margin-left: @normal + @small;}
|
51
|
+
.l_active {.s_round_bl(@small_radius); .s_round_br(@small_radius);}}}*/
|
@@ -0,0 +1,15 @@
|
|
1
|
+
.the_controls {.s_controls;}
|
2
|
+
|
3
|
+
|
4
|
+
.the_details {}
|
5
|
+
|
6
|
+
|
7
|
+
.the_discussion_t () {
|
8
|
+
> .l_controls {float: right;}}
|
9
|
+
.the_discussion {.the_discussion_t;
|
10
|
+
> .l_controls {.s_box; .s_controls;}}
|
11
|
+
|
12
|
+
|
13
|
+
.the_paginator {.s_link; .s_box;
|
14
|
+
> * {margin-right: @normal;}
|
15
|
+
.l_active {font-weight: bold;}}
|
@@ -0,0 +1,49 @@
|
|
1
|
+
.the_more {.m_tiny; .s_a_link;}
|
2
|
+
|
3
|
+
|
4
|
+
.the_narrow {margin-left: 20%; margin-right: 20%;}
|
5
|
+
|
6
|
+
|
7
|
+
.the_tabs {
|
8
|
+
> .l_panel {.t_tabs; .s_tabs; border-bottom: @small solid @light_color;
|
9
|
+
.l_active {.s_round_tl(@small_radius); .s_round_tr(@small_radius); cursor: text;
|
10
|
+
a {cursor: text;}}
|
11
|
+
a {outline: none;}}
|
12
|
+
> .l_content{}}
|
13
|
+
|
14
|
+
|
15
|
+
.the_basic_list {.t_list; .s_list;
|
16
|
+
.l_item {.s_link;
|
17
|
+
.l_check_box {}
|
18
|
+
.l_content {}}}
|
19
|
+
|
20
|
+
|
21
|
+
.the_info_message {.s_box; .s_round; .s_narrow; .s_link; background: @light_yellow_color;}
|
22
|
+
.the_error_message {.s_box; .s_round; .s_narrow; .s_link; background: @light_red_color;}
|
23
|
+
|
24
|
+
|
25
|
+
.the_divider_t () {.s_box; clear: both;}
|
26
|
+
.the_divider {.the_divider_t; .s_normal_text; text-align: right; border-bottom: @small solid @color;}
|
27
|
+
|
28
|
+
|
29
|
+
.the_table_t () {width: 100%;}
|
30
|
+
.the_table {.the_table_t; .s_link;
|
31
|
+
thead {
|
32
|
+
tr {
|
33
|
+
th {background: @light_color; .s_normal_text; text-align: left; padding: @normal;
|
34
|
+
&:first-child {.s_round_tl;}
|
35
|
+
&:last-child {.s_round_tr;}}}}
|
36
|
+
tbody {
|
37
|
+
tr {
|
38
|
+
td {padding: @normal;}}
|
39
|
+
.l_even {background: @very_light_color;}}}
|
40
|
+
|
41
|
+
|
42
|
+
.the_toolbar {.t_toolbar; .s_toolbar; .s_link;
|
43
|
+
.l_left {
|
44
|
+
.l_item {}}
|
45
|
+
.l_right {
|
46
|
+
.l_item {}}}
|
47
|
+
|
48
|
+
|
49
|
+
.the_title {.s_box}
|
@@ -0,0 +1,34 @@
|
|
1
|
+
.the_form_t () {
|
2
|
+
.l_field {
|
3
|
+
> table.css_table {
|
4
|
+
> tbody {
|
5
|
+
> tr {
|
6
|
+
> td.css_td1 {width: 30%;}
|
7
|
+
> td.css_td2 {}}}}}
|
8
|
+
.l_line {.t_tabs;}}
|
9
|
+
|
10
|
+
.the_form {.the_form_t; // .s_box; .s_border; .s_round;
|
11
|
+
.l_errors {
|
12
|
+
.l_error {.s_small_text; color: @red_color;}}
|
13
|
+
.l_field {.s_vbox(@small); .s_link;
|
14
|
+
.l_required {font-weight: bold;}
|
15
|
+
.l_label {}
|
16
|
+
.l_input {
|
17
|
+
|
18
|
+
select {min-width: 30%}
|
19
|
+
input, textarea {width: 100%;}
|
20
|
+
textarea {min-height: @textarea_height !important;}
|
21
|
+
input[type=checkbox] {width: auto;}
|
22
|
+
input[type=radio] {width: auto;}
|
23
|
+
label {margin-left: @normal; margin-right: @big;}}
|
24
|
+
|
25
|
+
.l_description {.s_small_text; color: @light_color;}
|
26
|
+
.l_errors {}}
|
27
|
+
.l_line {.s_tabs; .s_vbox; .s_link;
|
28
|
+
.l_item {
|
29
|
+
a {padding: 3px 0px 4px; display: block;}}}} // to be the same size as button in formalize.css
|
30
|
+
|
31
|
+
|
32
|
+
// special cases
|
33
|
+
.the_form {
|
34
|
+
.the_more {float: right;}}
|