mercury-rails 0.1.0
Sign up to get free protection for your applications and to get access to all the features.
- data/LICENSE +20 -0
- data/README.rdoc +152 -0
- data/VERSION +1 -0
- data/app/assets/images/mercury/button.png +0 -0
- data/app/assets/images/mercury/clippy.png +0 -0
- data/app/assets/images/mercury/default-snippet.png +0 -0
- data/app/assets/images/mercury/loading-dark.gif +0 -0
- data/app/assets/images/mercury/loading-light.gif +0 -0
- data/app/assets/images/mercury/search-icon.png +0 -0
- data/app/assets/images/mercury/toolbar/editable/buttons.png +0 -0
- data/app/assets/images/mercury/toolbar/markupable/buttons.png +0 -0
- data/app/assets/images/mercury/toolbar/primary/_expander.png +0 -0
- data/app/assets/images/mercury/toolbar/primary/_pressed.png +0 -0
- data/app/assets/images/mercury/toolbar/primary/historypanel.png +0 -0
- data/app/assets/images/mercury/toolbar/primary/insertcharacter.png +0 -0
- data/app/assets/images/mercury/toolbar/primary/insertlink.png +0 -0
- data/app/assets/images/mercury/toolbar/primary/insertmedia.png +0 -0
- data/app/assets/images/mercury/toolbar/primary/inserttable.png +0 -0
- data/app/assets/images/mercury/toolbar/primary/inspectorpanel.png +0 -0
- data/app/assets/images/mercury/toolbar/primary/notespanel.png +0 -0
- data/app/assets/images/mercury/toolbar/primary/objectspanel.png +0 -0
- data/app/assets/images/mercury/toolbar/primary/preview.png +0 -0
- data/app/assets/images/mercury/toolbar/primary/redo.png +0 -0
- data/app/assets/images/mercury/toolbar/primary/save.png +0 -0
- data/app/assets/images/mercury/toolbar/primary/todospanel.png +0 -0
- data/app/assets/images/mercury/toolbar/primary/undo.png +0 -0
- data/app/assets/images/mercury/toolbar/snippetable/buttons.png +0 -0
- data/app/assets/javascripts/mercury.js +30 -0
- data/app/assets/javascripts/mercury/dialog.js.coffee +75 -0
- data/app/assets/javascripts/mercury/dialogs/backcolor.js.coffee +6 -0
- data/app/assets/javascripts/mercury/dialogs/forecolor.js.coffee +6 -0
- data/app/assets/javascripts/mercury/dialogs/formatblock.js.coffee +4 -0
- data/app/assets/javascripts/mercury/dialogs/objectspanel.js.coffee +10 -0
- data/app/assets/javascripts/mercury/dialogs/style.js.coffee +4 -0
- data/app/assets/javascripts/mercury/history_buffer.js.coffee +30 -0
- data/app/assets/javascripts/mercury/mercury.js.coffee +293 -0
- data/app/assets/javascripts/mercury/modal.js.coffee +177 -0
- data/app/assets/javascripts/mercury/modals/htmleditor.js.coffee +10 -0
- data/app/assets/javascripts/mercury/modals/insertcharacter.js.coffee +4 -0
- data/app/assets/javascripts/mercury/modals/insertlink.js.coffee +92 -0
- data/app/assets/javascripts/mercury/modals/insertmedia.js.coffee +72 -0
- data/app/assets/javascripts/mercury/modals/insertsnippet.js.coffee +11 -0
- data/app/assets/javascripts/mercury/modals/inserttable.js.coffee +56 -0
- data/app/assets/javascripts/mercury/native_extensions.js.coffee +47 -0
- data/app/assets/javascripts/mercury/page_editor.js.coffee +139 -0
- data/app/assets/javascripts/mercury/palette.js.coffee +29 -0
- data/app/assets/javascripts/mercury/panel.js.coffee +97 -0
- data/app/assets/javascripts/mercury/region.js.coffee +103 -0
- data/app/assets/javascripts/mercury/regions/editable.js.coffee +546 -0
- data/app/assets/javascripts/mercury/regions/markupable.js.coffee +380 -0
- data/app/assets/javascripts/mercury/regions/snippetable.js.coffee +127 -0
- data/app/assets/javascripts/mercury/select.js.coffee +40 -0
- data/app/assets/javascripts/mercury/snippet.js.coffee +92 -0
- data/app/assets/javascripts/mercury/snippet_toolbar.js.coffee +69 -0
- data/app/assets/javascripts/mercury/statusbar.js.coffee +25 -0
- data/app/assets/javascripts/mercury/table_editor.js.coffee +266 -0
- data/app/assets/javascripts/mercury/toolbar.button.js.coffee +152 -0
- data/app/assets/javascripts/mercury/toolbar.button_group.js.coffee +42 -0
- data/app/assets/javascripts/mercury/toolbar.expander.js.coffee +56 -0
- data/app/assets/javascripts/mercury/toolbar.js.coffee +72 -0
- data/app/assets/javascripts/mercury/tooltip.js.coffee +67 -0
- data/app/assets/javascripts/mercury/uploader.js.coffee +213 -0
- data/app/assets/javascripts/mercury/websocket.js.coffee +34 -0
- data/app/assets/stylesheets/mercury.css +31 -0
- data/app/assets/stylesheets/mercury/dialog.scss +178 -0
- data/app/assets/stylesheets/mercury/mercury.scss +119 -0
- data/app/assets/stylesheets/mercury/modal.scss +192 -0
- data/app/assets/stylesheets/mercury/statusbar.scss +23 -0
- data/app/assets/stylesheets/mercury/toolbar.scss +417 -0
- data/app/assets/stylesheets/mercury/tooltip.scss +26 -0
- data/app/assets/stylesheets/mercury/uploader.scss +109 -0
- data/app/controllers/images_controller.rb +19 -0
- data/app/controllers/mercury_controller.rb +20 -0
- data/app/models/image.rb +14 -0
- data/app/views/layouts/mercury.html.haml +12 -0
- data/app/views/mercury/modals/character.html.haml +252 -0
- data/app/views/mercury/modals/htmleditor.html.haml +8 -0
- data/app/views/mercury/modals/link.html.haml +31 -0
- data/app/views/mercury/modals/media.html.haml +33 -0
- data/app/views/mercury/modals/sanitizer.html.haml +4 -0
- data/app/views/mercury/modals/table.html.haml +49 -0
- data/app/views/mercury/palettes/backcolor.html.haml +79 -0
- data/app/views/mercury/palettes/forecolor.html.haml +79 -0
- data/app/views/mercury/panels/history.html.haml +0 -0
- data/app/views/mercury/panels/notes.html.haml +0 -0
- data/app/views/mercury/panels/snippets.html.haml +10 -0
- data/app/views/mercury/selects/formatblock.html.haml +10 -0
- data/app/views/mercury/selects/style.html.haml +4 -0
- data/app/views/mercury/snippets/example.html.haml +2 -0
- data/app/views/mercury/snippets/example_options.html.haml +16 -0
- data/config/engine.rb +6 -0
- data/config/routes.rb +15 -0
- data/db/migrate/20110526035601_create_images.rb +11 -0
- data/features/editing/basic.feature +11 -0
- data/features/step_definitions/debug_steps.rb +14 -0
- data/features/step_definitions/web_steps.rb +211 -0
- data/features/support/env.rb +46 -0
- data/features/support/paths.rb +35 -0
- data/features/support/selectors.rb +42 -0
- data/lib/mercury-rails.rb +4 -0
- data/log/.gitkeep +0 -0
- data/mercury-rails.gemspec +230 -0
- data/spec/javascripts/mercury/dialog_spec.js.coffee +258 -0
- data/spec/javascripts/mercury/history_buffer_spec.js.coffee +79 -0
- data/spec/javascripts/mercury/mercury_spec.js.coffee +52 -0
- data/spec/javascripts/mercury/native_extensions_spec.js.coffee +66 -0
- data/spec/javascripts/mercury/page_editor_spec.js.coffee +435 -0
- data/spec/javascripts/mercury/palette_spec.js.coffee +51 -0
- data/spec/javascripts/mercury/panel_spec.js.coffee +147 -0
- data/spec/javascripts/mercury/region_spec.js.coffee +261 -0
- data/spec/javascripts/mercury/regions/_editable_.js.coffee +0 -0
- data/spec/javascripts/mercury/regions/_markupable_.js.coffee +0 -0
- data/spec/javascripts/mercury/regions/snippetable_spec.js.coffee +368 -0
- data/spec/javascripts/mercury/select_spec.js.coffee +51 -0
- data/spec/javascripts/mercury/snippet_spec.js.coffee +246 -0
- data/spec/javascripts/mercury/snippet_toolbar_spec.js.coffee +186 -0
- data/spec/javascripts/mercury/statusbar_spec.js.coffee +78 -0
- data/spec/javascripts/mercury/table_editor_spec.js.coffee +192 -0
- data/spec/javascripts/mercury/toolbar.button_group_spec.js.coffee +92 -0
- data/spec/javascripts/mercury/toolbar.button_spec.js.coffee +341 -0
- data/spec/javascripts/mercury/toolbar.expander_spec.js.coffee +120 -0
- data/spec/javascripts/mercury/toolbar_spec.js.coffee +152 -0
- data/spec/javascripts/mercury/tooltip_spec.js.coffee +188 -0
- data/spec/javascripts/mercury/uploader_spec.js.coffee +512 -0
- data/spec/javascripts/responses/blank.html +1 -0
- data/spec/javascripts/spec_helper.js +513 -0
- data/spec/javascripts/templates/mercury/dialog.html +2 -0
- data/spec/javascripts/templates/mercury/page_editor.html +24 -0
- data/spec/javascripts/templates/mercury/palette.html +16 -0
- data/spec/javascripts/templates/mercury/panel.html +16 -0
- data/spec/javascripts/templates/mercury/region.html +2 -0
- data/spec/javascripts/templates/mercury/regions/snippetable.html +4 -0
- data/spec/javascripts/templates/mercury/select.html +16 -0
- data/spec/javascripts/templates/mercury/snippet.html +1 -0
- data/spec/javascripts/templates/mercury/snippet_toolbar.html +16 -0
- data/spec/javascripts/templates/mercury/statusbar.html +7 -0
- data/spec/javascripts/templates/mercury/table_editor.html +65 -0
- data/spec/javascripts/templates/mercury/toolbar.button.html +64 -0
- data/spec/javascripts/templates/mercury/toolbar.button_group.html +9 -0
- data/spec/javascripts/templates/mercury/toolbar.expander.html +18 -0
- data/spec/javascripts/templates/mercury/toolbar.html +10 -0
- data/spec/javascripts/templates/mercury/tooltip.html +12 -0
- data/spec/javascripts/templates/mercury/uploader.html +11 -0
- data/vendor/assets/javascripts/jquery-1.6.js +8865 -0
- data/vendor/assets/javascripts/jquery-ui-1.8.13.custom.min.js +249 -0
- data/vendor/assets/javascripts/jquery-ui-1.8.13.sortable.custom.js +1078 -0
- data/vendor/assets/javascripts/jquery.easing.js +173 -0
- data/vendor/assets/javascripts/jquery.json2.js +178 -0
- data/vendor/assets/javascripts/jquery.serialize_object.js +16 -0
- data/vendor/assets/javascripts/jquery.ujs.js +289 -0
- data/vendor/assets/javascripts/liquidmetal.js +88 -0
- data/vendor/assets/javascripts/showdown.js +1362 -0
- metadata +364 -0
@@ -0,0 +1,34 @@
|
|
1
|
+
#Mercury.websocket =
|
2
|
+
#
|
3
|
+
# websocket: $.websocket("ws://#{$.uri(window.location.href).host}:8081")
|
4
|
+
#
|
5
|
+
#
|
6
|
+
# send: (eventName, options) ->
|
7
|
+
# package = {}
|
8
|
+
# package[eventName] = options
|
9
|
+
# @websocket.send(package)
|
10
|
+
#
|
11
|
+
#
|
12
|
+
# bind: (eventName, callback) ->
|
13
|
+
# # todo: this will override any that are already set -- callbacks should be an array that we can push onto
|
14
|
+
# $.websocketSettings[eventName] = callback
|
15
|
+
|
16
|
+
#window.socket = $.websocket(, {
|
17
|
+
# lock: (element) ->
|
18
|
+
# $('#' + element).attr('disabled', true);
|
19
|
+
#
|
20
|
+
# unlock: (element) ->
|
21
|
+
# $('#' + element).attr('disabled', false);
|
22
|
+
#
|
23
|
+
# chat: (element) ->
|
24
|
+
# $('#chat').get(0).innerHTML += message + "<br/>";
|
25
|
+
#});
|
26
|
+
#
|
27
|
+
#$(document).ready ->
|
28
|
+
#
|
29
|
+
# $('.shared').bind 'focus', -> window.socket.send({"lock": this.id})
|
30
|
+
#
|
31
|
+
# $('.shared').bind 'blur', -> window.socket.send({"unlock": this.id})
|
32
|
+
#
|
33
|
+
# $('.shared').bind 'keypress', (e) ->
|
34
|
+
# window.socket.send({chat: $(this).val()}) if (e.charCode == 13)
|
@@ -0,0 +1,31 @@
|
|
1
|
+
/*!
|
2
|
+
* Mercury Editor is a Coffeescript and jQuery based WYSIWYG editor. Mercury Editor utilizes the HTML5 ContentEditable
|
3
|
+
* spec to allow editing sections of a given page (instead of using iframes) and provides an editing experience that's as
|
4
|
+
* realistic as possible. By not using iframes for editable regions it allows CSS to behave naturally.
|
5
|
+
*
|
6
|
+
* Mercury Editor was written for the future, and doesn't attempt to support legacy implementations of document editing.
|
7
|
+
*
|
8
|
+
* Currently supported browsers are
|
9
|
+
* - Firefox 4+
|
10
|
+
* - Chrome 10+
|
11
|
+
* - Safari 5+
|
12
|
+
*
|
13
|
+
* Copyright (c) 2011 Jeremy Jackson
|
14
|
+
*
|
15
|
+
* Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated
|
16
|
+
* documentation files (the "Software"), to deal in the Software without restriction, including without limitation the
|
17
|
+
* rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit
|
18
|
+
* persons to whom the Software is furnished to do so, subject to the following conditions:
|
19
|
+
*
|
20
|
+
* The above copyright notice and this permission notice shall be included in all copies or substantial portions of the
|
21
|
+
* Software.
|
22
|
+
*
|
23
|
+
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE
|
24
|
+
* WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
|
25
|
+
* COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR
|
26
|
+
* OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
27
|
+
*
|
28
|
+
*= require_self
|
29
|
+
*= require mercury/mercury
|
30
|
+
*/
|
31
|
+
|
@@ -0,0 +1,178 @@
|
|
1
|
+
/*
|
2
|
+
* Dialogs
|
3
|
+
*----------------------------------------------------------------------------*/
|
4
|
+
.mercury-dialog,
|
5
|
+
.mercury-select,
|
6
|
+
.mercury-palette {
|
7
|
+
-webkit-user-select: none;
|
8
|
+
-moz-user-select: none;
|
9
|
+
user-select: none;
|
10
|
+
position: absolute;
|
11
|
+
z-index: 10012;
|
12
|
+
width: 30px;
|
13
|
+
height: 30px;
|
14
|
+
border: 1px solid #727272;
|
15
|
+
border-radius: 2px;
|
16
|
+
-moz-border-radius: 2px;
|
17
|
+
margin-top: -1px;
|
18
|
+
background-color: #E2E1E2;
|
19
|
+
box-shadow: 1px 1px 4px rgba(0,0,0, .5);
|
20
|
+
-moz-box-shadow: 1px 1px 4px rgba(0,0,0, .5);
|
21
|
+
font-family: Helvetica, Tahoma, Arial, sans-serif;
|
22
|
+
font-size: 8.5pt;
|
23
|
+
&.loading {
|
24
|
+
background-image: url(/assets/mercury/loading-light.gif);
|
25
|
+
background-repeat: no-repeat;
|
26
|
+
background-position: center;
|
27
|
+
}
|
28
|
+
}
|
29
|
+
/*
|
30
|
+
* Selects
|
31
|
+
*----------------------------------------------------------------------------*/
|
32
|
+
.mercury-select {
|
33
|
+
border-radius: 4px;
|
34
|
+
-moz-border-radius: 4px;
|
35
|
+
overflow: auto;
|
36
|
+
background-color: #FFF;
|
37
|
+
}
|
38
|
+
/*
|
39
|
+
* Panels
|
40
|
+
*----------------------------------------------------------------------------*/
|
41
|
+
.mercury-panel {
|
42
|
+
position: absolute;
|
43
|
+
z-index: 10011;
|
44
|
+
background-color: #111;
|
45
|
+
opacity: .9;
|
46
|
+
box-shadow: 1px 1px 4px rgba(0,0,0, .5);
|
47
|
+
-moz-box-shadow: 1px 1px 4px rgba(0,0,0, .5);
|
48
|
+
border-radius: 4px;
|
49
|
+
-moz-border-radius: 4px;
|
50
|
+
color: #FFF;
|
51
|
+
font-family: Helvetica, Tahoma, Arial, sans-serif;
|
52
|
+
font-size: 9.5pt;
|
53
|
+
max-width: 500px;
|
54
|
+
&.loading {
|
55
|
+
background-image: url(/assets/mercury/loading-dark.gif);
|
56
|
+
background-repeat: no-repeat;
|
57
|
+
background-position: center;
|
58
|
+
}
|
59
|
+
h1,
|
60
|
+
h3 {
|
61
|
+
font-size: 9pt;
|
62
|
+
padding: 10px 15px 8px;
|
63
|
+
margin: 0;
|
64
|
+
background: #333;
|
65
|
+
white-space: nowrap;
|
66
|
+
}
|
67
|
+
h1 {
|
68
|
+
-webkit-user-select: none;
|
69
|
+
-moz-user-select: none;
|
70
|
+
user-select: none;
|
71
|
+
font-size: 10pt;
|
72
|
+
-moz-border-radius-topleft: 4px;
|
73
|
+
-moz-border-radius-topright: 4px;
|
74
|
+
border-top-left-radius: 4px;
|
75
|
+
border-top-right-radius: 4px;
|
76
|
+
height: 15px;
|
77
|
+
cursor: move;
|
78
|
+
text-shadow: 1px 1px 2px rgba(0,0,0, .9);
|
79
|
+
}
|
80
|
+
h4, h5, h6 {
|
81
|
+
margin: 0;
|
82
|
+
}
|
83
|
+
.mercury-panel-pane {
|
84
|
+
box-sizing: border-box;
|
85
|
+
-moz-box-sizing: border-box;
|
86
|
+
padding: 15px;
|
87
|
+
overflow-y: auto;
|
88
|
+
overflow-x: hidden;
|
89
|
+
width: 100%;
|
90
|
+
h3 {
|
91
|
+
margin: 10px -15px;
|
92
|
+
font-size: 9.5pt;
|
93
|
+
font-weight: normal;
|
94
|
+
padding: 8px 14px;
|
95
|
+
}
|
96
|
+
}
|
97
|
+
}
|
98
|
+
/*
|
99
|
+
* Specific Dialogs (eg. color palettes, selects)
|
100
|
+
*----------------------------------------------------------------------------*/
|
101
|
+
.mercury-color-picker {
|
102
|
+
width: 170px;
|
103
|
+
height: auto;
|
104
|
+
padding: 1px;
|
105
|
+
cursor: default;
|
106
|
+
.picker {
|
107
|
+
float: left;
|
108
|
+
width: 15px;
|
109
|
+
height: 15px;
|
110
|
+
margin: 1px;
|
111
|
+
&:hover {
|
112
|
+
outline: 1px solid #333;
|
113
|
+
}
|
114
|
+
}
|
115
|
+
.last-picked {
|
116
|
+
position: relative;
|
117
|
+
top: 1px;
|
118
|
+
width: 166px;
|
119
|
+
border: 1px solid #333;
|
120
|
+
border-radius: 2px;
|
121
|
+
margin: 1px 1px 2px 1px;
|
122
|
+
-moz-border-radius: 2px;
|
123
|
+
clear: left;
|
124
|
+
text-align: center;
|
125
|
+
}
|
126
|
+
}
|
127
|
+
.mercury-select-options {
|
128
|
+
margin: 10px 0;
|
129
|
+
white-space: nowrap;
|
130
|
+
* {
|
131
|
+
cursor: default;
|
132
|
+
padding: 0 10px;
|
133
|
+
margin: 0;
|
134
|
+
line-height: 1.6em;
|
135
|
+
}
|
136
|
+
*:hover {
|
137
|
+
background-color: #E2E1E2 !important;
|
138
|
+
color: #000 !important;
|
139
|
+
}
|
140
|
+
div[data-tag=pre] {
|
141
|
+
font-family: monospace;
|
142
|
+
}
|
143
|
+
}
|
144
|
+
/*
|
145
|
+
* Specific Panels (eg. snippets, notes, todos)
|
146
|
+
*----------------------------------------------------------------------------*/
|
147
|
+
.mercury-snippet-panel {
|
148
|
+
width: 300px;
|
149
|
+
input.filter {
|
150
|
+
outline: none;
|
151
|
+
font-size: 1em;
|
152
|
+
border-radius: 30px;
|
153
|
+
moz-border-radius: 30px;
|
154
|
+
width: 100%;
|
155
|
+
padding-left: 20px;
|
156
|
+
background: #FFF url(/assets/mercury/search-icon.png) no-repeat 4px center;
|
157
|
+
}
|
158
|
+
ul {
|
159
|
+
font-size: .9em;
|
160
|
+
padding: 10px 0 0 0;
|
161
|
+
margin: 0;
|
162
|
+
list-style-type: none;
|
163
|
+
li {
|
164
|
+
clear: both;
|
165
|
+
padding-top: 20px;
|
166
|
+
img {
|
167
|
+
float: left;
|
168
|
+
}
|
169
|
+
h4, .description {
|
170
|
+
float: right;
|
171
|
+
width: 245px;
|
172
|
+
}
|
173
|
+
h4 {
|
174
|
+
margin-bottom: 5px;
|
175
|
+
}
|
176
|
+
}
|
177
|
+
}
|
178
|
+
}
|
@@ -0,0 +1,119 @@
|
|
1
|
+
/*
|
2
|
+
*= require_self
|
3
|
+
*= require ./dialog
|
4
|
+
*= require ./modal
|
5
|
+
*= require ./statusbar
|
6
|
+
*= require ./toolbar
|
7
|
+
*= require ./tooltip
|
8
|
+
*= require ./uploader
|
9
|
+
*/
|
10
|
+
|
11
|
+
|
12
|
+
html, body {
|
13
|
+
margin: 0;
|
14
|
+
padding: 0;
|
15
|
+
overflow: hidden;
|
16
|
+
}
|
17
|
+
|
18
|
+
|
19
|
+
/*
|
20
|
+
* Forms
|
21
|
+
*---------------------------------------------------------------------------*/
|
22
|
+
form, form ul, form ol, form li, form fieldset, form p, .filter {
|
23
|
+
margin: 0;
|
24
|
+
padding: 0;
|
25
|
+
abbr {
|
26
|
+
border: 0;
|
27
|
+
font-variant: normal;
|
28
|
+
}
|
29
|
+
fieldset {
|
30
|
+
margin-bottom: 10px;
|
31
|
+
background: #F6F6F6;
|
32
|
+
border: 1px solid #CCC;
|
33
|
+
border-radius: 7px;
|
34
|
+
-moz-border-radius: 7px;
|
35
|
+
&:last-child {
|
36
|
+
margin-bottom: 0;
|
37
|
+
}
|
38
|
+
legend {
|
39
|
+
font-weight: bold;
|
40
|
+
margin-left: 10px;
|
41
|
+
margin-bottom: -4px;
|
42
|
+
}
|
43
|
+
ol {
|
44
|
+
margin: 12px 9px;
|
45
|
+
li {
|
46
|
+
display: block;
|
47
|
+
margin-bottom: 10px;
|
48
|
+
}
|
49
|
+
}
|
50
|
+
}
|
51
|
+
label {
|
52
|
+
display: block;
|
53
|
+
float: left;
|
54
|
+
width: 23%;
|
55
|
+
margin-right: 9px;
|
56
|
+
text-align: right;
|
57
|
+
line-height: 27px;
|
58
|
+
font-size: 1.1em;
|
59
|
+
input {
|
60
|
+
width: auto !important;
|
61
|
+
margin: 0 5px 0 -20px !important;
|
62
|
+
}
|
63
|
+
}
|
64
|
+
select,
|
65
|
+
input[type=text],
|
66
|
+
input[type=password],
|
67
|
+
textarea,
|
68
|
+
input.text {
|
69
|
+
margin: 0;
|
70
|
+
border: 2px solid #CCC;
|
71
|
+
padding: 2px 4px;
|
72
|
+
font-family: Arial, Geneva, sans-serif;
|
73
|
+
font-size: 1.5em;
|
74
|
+
width: 74%;
|
75
|
+
box-sizing: border-box;
|
76
|
+
-moz-box-sizing: border-box;
|
77
|
+
}
|
78
|
+
fieldset.buttons {
|
79
|
+
clear: both;
|
80
|
+
padding: 0;
|
81
|
+
background: none;
|
82
|
+
border: none;
|
83
|
+
text-align: left;
|
84
|
+
ol {
|
85
|
+
margin: 0 -2px 0 0;
|
86
|
+
float: right;
|
87
|
+
li {
|
88
|
+
float: left;
|
89
|
+
padding-left: 0.5em;
|
90
|
+
padding-right: 0;
|
91
|
+
}
|
92
|
+
}
|
93
|
+
.commit {
|
94
|
+
margin: 0;
|
95
|
+
input {
|
96
|
+
padding: 8px 14px 9px !important;
|
97
|
+
font-family: 'HelveticaNeue-Light', 'Helvetica Neue Light', 'Helvetica Neue', sans-serif;
|
98
|
+
font-size: 1.3em;
|
99
|
+
background: #222 url(/assets/mercury/button.png) repeat-x;
|
100
|
+
display: inline-block;
|
101
|
+
color: #FFF;
|
102
|
+
text-decoration: none;
|
103
|
+
-moz-border-radius: 5px;
|
104
|
+
-webkit-border-radius: 5px;
|
105
|
+
-moz-box-shadow: 0 1px 3px rgba(0, 0, 0, 0.5);
|
106
|
+
-webkit-box-shadow: 0 1px 3px rgba(0, 0, 0, 0.5);
|
107
|
+
text-shadow: 0 -1px 1px rgba(0, 0, 0, 0.25);
|
108
|
+
border: 0;
|
109
|
+
border-bottom: 1px solid rgba(0, 0, 0, 0.25);
|
110
|
+
position: relative;
|
111
|
+
cursor: pointer;
|
112
|
+
line-height: normal;
|
113
|
+
&:hover {
|
114
|
+
background-color: #000;
|
115
|
+
}
|
116
|
+
}
|
117
|
+
}
|
118
|
+
}
|
119
|
+
}
|
@@ -0,0 +1,192 @@
|
|
1
|
+
/*
|
2
|
+
* Modal
|
3
|
+
*----------------------------------------------------------------------------*/
|
4
|
+
.mercury-modal-overlay {
|
5
|
+
position: absolute;
|
6
|
+
z-index: 10040;
|
7
|
+
top: 0;
|
8
|
+
left: 0;
|
9
|
+
width: 100%;
|
10
|
+
height: 100%;
|
11
|
+
opacity: 0;
|
12
|
+
display: none;
|
13
|
+
background: rgba(0,0,0, .65);
|
14
|
+
}
|
15
|
+
.mercury-modal {
|
16
|
+
position: absolute;
|
17
|
+
z-index: 10050;
|
18
|
+
top: 0;
|
19
|
+
width: 500px;
|
20
|
+
overflow: hidden;
|
21
|
+
padding: 0 0 10px;
|
22
|
+
background: #EFEFEF;
|
23
|
+
-webkit-border-bottom-left-radius: 4px;
|
24
|
+
-webkit-border-bottom-right-radius: 4px;
|
25
|
+
-moz-border-radius-bottomleft: 4px;
|
26
|
+
-moz-border-radius-bottomright: 4px;
|
27
|
+
border-bottom-left-radius: 4px;
|
28
|
+
border-bottom-right-radius: 4px;
|
29
|
+
-moz-box-shadow: 0 0 40px rgba(0, 0, 0, .9);
|
30
|
+
box-shadow: 0 0 40px rgba(0, 0, 0, .9);
|
31
|
+
font: normal normal normal 12px/normal Helvetica, Tahoma, Arial, sans-serif;
|
32
|
+
&.loading .mercury-modal-content-container {
|
33
|
+
background: #EFEFEF url(/assets/mercury/loading-light.gif) no-repeat center;
|
34
|
+
}
|
35
|
+
h1.mercury-modal-title {
|
36
|
+
-webkit-user-select: none;
|
37
|
+
-moz-user-select: none;
|
38
|
+
user-select: none;
|
39
|
+
margin: 0;
|
40
|
+
padding: 2px 10px 0 10px;
|
41
|
+
background: #DDD;
|
42
|
+
border-bottom: 1px solid #CCC;
|
43
|
+
white-space: nowrap;
|
44
|
+
font-size: 14px;
|
45
|
+
line-height: 23px;
|
46
|
+
overflow: hidden;
|
47
|
+
&:after {
|
48
|
+
content: '\00a0';
|
49
|
+
display: block;
|
50
|
+
visibility: hidden;
|
51
|
+
clear: both;
|
52
|
+
height: 0;
|
53
|
+
}
|
54
|
+
span {
|
55
|
+
float: left;
|
56
|
+
color: #000;
|
57
|
+
text-shadow: #EEE 1px 1px 0;
|
58
|
+
}
|
59
|
+
a {
|
60
|
+
display: block;
|
61
|
+
float: right;
|
62
|
+
font-size: 10px;
|
63
|
+
cursor: pointer;
|
64
|
+
color: #666;
|
65
|
+
padding: 0 4px;
|
66
|
+
line-height: 23px;
|
67
|
+
&:hover {
|
68
|
+
color: #333;
|
69
|
+
}
|
70
|
+
}
|
71
|
+
}
|
72
|
+
.mercury-modal-content-container {
|
73
|
+
float: left;
|
74
|
+
width: 100%;
|
75
|
+
}
|
76
|
+
.mercury-modal-content {
|
77
|
+
position: relative;
|
78
|
+
overflow: auto;
|
79
|
+
float: left;
|
80
|
+
-moz-box-sizing: border-box;
|
81
|
+
box-sizing: border-box;
|
82
|
+
padding: 20px 20px 10px;
|
83
|
+
font-family: Helvetica, Tahoma, Arial, sans-serif;
|
84
|
+
color: #000;
|
85
|
+
&:after {
|
86
|
+
display: block;
|
87
|
+
clear: both;
|
88
|
+
content: '\00a0';
|
89
|
+
visibility: hidden;
|
90
|
+
overflow: hidden;
|
91
|
+
height: 0;
|
92
|
+
}
|
93
|
+
}
|
94
|
+
.mercury-modal-pane-container {
|
95
|
+
overflow: auto;
|
96
|
+
margin: -20px -20px 0;
|
97
|
+
padding: 20px 20px 10px;
|
98
|
+
.mercury-modal-pane {
|
99
|
+
float: left;
|
100
|
+
}
|
101
|
+
}
|
102
|
+
.mercury-modal-controls {
|
103
|
+
padding: 15px 0 0;
|
104
|
+
border-top: 1px solid #CCC;
|
105
|
+
text-align: right;
|
106
|
+
}
|
107
|
+
textarea {
|
108
|
+
resize: none;
|
109
|
+
padding: 0;
|
110
|
+
box-sizing: border-box;
|
111
|
+
-moz-box-sizing: border-box;
|
112
|
+
}
|
113
|
+
}
|
114
|
+
/*
|
115
|
+
* Specific Modals (eg. htmleditor)
|
116
|
+
*----------------------------------------------------------------------------*/
|
117
|
+
/* htmleditor */
|
118
|
+
#mercury_htmleditor {
|
119
|
+
textarea {
|
120
|
+
margin: 0 0 -2px 0;
|
121
|
+
padding: 0;
|
122
|
+
border: 2px solid #CCC;
|
123
|
+
width: 100%;
|
124
|
+
}
|
125
|
+
.mercury-modal-controls {
|
126
|
+
border: 0;
|
127
|
+
margin-top: -2px;
|
128
|
+
}
|
129
|
+
}
|
130
|
+
/* html sanitizer (when pasting from msword) */
|
131
|
+
#mercury_sanitizer {
|
132
|
+
.information {
|
133
|
+
background: url(/assets/mercury/clippy.png) no-repeat top left;
|
134
|
+
min-height: 65px;
|
135
|
+
padding-left: 50px;
|
136
|
+
margin-bottom: 10px;
|
137
|
+
}
|
138
|
+
textarea {
|
139
|
+
width: 100%;
|
140
|
+
font-family: monospace;
|
141
|
+
white-space: pre;
|
142
|
+
}
|
143
|
+
}
|
144
|
+
/* insertcharacter */
|
145
|
+
#mercury_insertcharacter {
|
146
|
+
.character {
|
147
|
+
float: left;
|
148
|
+
width: 20px;
|
149
|
+
height: 20px;
|
150
|
+
border: 1px solid #999;
|
151
|
+
background: #FFF;
|
152
|
+
margin: 0 2px 2px 0;
|
153
|
+
text-align: center;
|
154
|
+
font-size: 11pt;
|
155
|
+
line-height: 23px;
|
156
|
+
cursor: pointer;
|
157
|
+
&:hover {
|
158
|
+
position: relative;
|
159
|
+
margin: -11px -5px 1px -5px;
|
160
|
+
width: 32px;
|
161
|
+
height: 32px;
|
162
|
+
font-size: 19pt;
|
163
|
+
line-height: 35px;
|
164
|
+
background: #DDD;
|
165
|
+
}
|
166
|
+
}
|
167
|
+
}
|
168
|
+
/* table */
|
169
|
+
#mercury_table {
|
170
|
+
#table_display {
|
171
|
+
width: 285px;
|
172
|
+
height: 285px;
|
173
|
+
float: left;
|
174
|
+
padding: 10px;
|
175
|
+
background: #F6F6F6;
|
176
|
+
border: 1px solid #CCC;
|
177
|
+
border-radius: 7px;
|
178
|
+
-moz-border-radius: 7px;
|
179
|
+
table {
|
180
|
+
width: 100%;
|
181
|
+
height: 100%;
|
182
|
+
}
|
183
|
+
td.selected {
|
184
|
+
background: #09F;
|
185
|
+
}
|
186
|
+
}
|
187
|
+
#table_options {
|
188
|
+
width: 383px;
|
189
|
+
float: left;
|
190
|
+
margin-left: 10px;
|
191
|
+
}
|
192
|
+
}
|