qvem 0.0.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,56 @@
1
+ #= require 'jquery.qtip2.min'
2
+ #= require 'jquery.validate'
3
+
4
+ @remove_errors = (form) ->
5
+ $("span.error",form).remove()
6
+ $(".error", form).removeClass("error")
7
+ $("input").qtip("destroy")
8
+
9
+ @set_error_qtip = (elem) ->
10
+ elem.qtip
11
+ content:
12
+ attr: "data-error"
13
+ position:
14
+ my: "bottom right"
15
+ at: "top right"
16
+
17
+ $(window).bind "load", ->
18
+ $("span[data-error]").each (v)->
19
+ ths = $(this)
20
+ error = ths.data('error')
21
+ if ($.trim(error).length > 0)
22
+ $("span.mceEditor", ths).addClass("error")
23
+ $("input, textarea, select, span.mceEditor", ths).qtip({
24
+ content:
25
+ text: error
26
+ position:
27
+ my: "bottom right"
28
+ at: "top right"
29
+ })
30
+ $ ->
31
+ $.validator.setDefaults({
32
+ errorPlacement: (error, element) ->
33
+ a = $.map error, (v) -> $(v).html()
34
+ #$.each a, (i,v) ->
35
+ # a[i] = v + $(element).data("fieldname").split("_").join(" ") if v=="Please enter "
36
+ $(element).attr("data-error",a.join())
37
+ $(element).qtip({
38
+ content:
39
+ attr: 'data-error'
40
+ position:
41
+ my: "bottom right"
42
+ at: "top right"
43
+ style:
44
+ width: 140
45
+ padding: 2
46
+ marginBottom: 5
47
+ background: "#444"
48
+ font: 10
49
+ color: "#fff"
50
+ textAlign: "center"
51
+ tip: "bottomRight"
52
+ border:
53
+ radius: 5,
54
+ color: "#222"
55
+ })
56
+ });
@@ -0,0 +1,623 @@
1
+ /*!
2
+ * qTip2 - Pretty powerful tooltips -
3
+ * http://qtip2.com
4
+ *
5
+ * Copyright (c) 2013 Craig Michael Thompson
6
+ * Released under the MIT, GPL licenses
7
+ * http://jquery.org/license
8
+ *
9
+ * Date: Mon Jun 24 2013 07:20 UTC+0000
10
+ * Plugins: svg ajax tips modal viewport imagemap ie6
11
+ * Styles: basic css3
12
+ */
13
+
14
+ /* Core qTip styles */
15
+ .qtip, .qtip{
16
+ position: absolute;
17
+ display: none;
18
+ border-radius: 5px
19
+
20
+ /*max-width: 280px;*/
21
+ /*min-width: 50px;*/
22
+
23
+ /*font-size: 10.5px;*/
24
+ /*line-height: 12px;*/
25
+
26
+ /*width: 200;*/
27
+ /*padding: 2;*/
28
+ /*margin-bottom: 5;*/
29
+ /*background: "#444";*/
30
+ /*font: 10;*/
31
+ /*color: "#fff";*/
32
+ /*text-align: "center";*/
33
+ /*tip: "bottomLeft";*/
34
+ /*border-color: "#222";*/
35
+ /*border-radius: 2;*/
36
+ /*direction: ltr;*/
37
+
38
+ }
39
+
40
+ .qtip-content{
41
+ position: relative;
42
+ padding: 0px 9px;
43
+ overflow: hidden;
44
+ font-size:12px;
45
+ text-align: left;
46
+ word-wrap: break-word;
47
+ }
48
+
49
+ .qtip-titlebar{
50
+ position: relative;
51
+ padding: 5px 35px 5px 10px;
52
+ overflow: hidden;
53
+
54
+ border-width: 0 0 1px;
55
+ font-weight: bold;
56
+ }
57
+
58
+ .qtip-titlebar + .qtip-content{ border-top-width: 0 !important; }
59
+
60
+ /* Default close button class */
61
+ .qtip-close{
62
+ position: absolute;
63
+ right: -9px; top: -9px;
64
+
65
+ cursor: pointer;
66
+ outline: medium none;
67
+
68
+ border-width: 1px;
69
+ border-style: solid;
70
+ border-color: transparent;
71
+ }
72
+
73
+ .qtip-titlebar .qtip-close{
74
+ right: 4px; top: 50%;
75
+ margin-top: -9px;
76
+ }
77
+
78
+ * html .qtip-titlebar .qtip-close{ top: 16px; } /* IE fix */
79
+
80
+ .qtip-titlebar .ui-icon,
81
+ .qtip-icon .ui-icon{
82
+ display: block;
83
+ text-indent: -1000em;
84
+ direction: ltr;
85
+ vertical-align: middle;
86
+ }
87
+
88
+ .qtip-icon, .qtip-icon .ui-icon{
89
+ -moz-border-radius: 3px;
90
+ -webkit-border-radius: 3px;
91
+ border-radius: 3px;
92
+ text-decoration: none;
93
+ }
94
+
95
+ .qtip-icon .ui-icon{
96
+ width: 18px;
97
+ height: 14px;
98
+
99
+ text-align: center;
100
+ text-indent: 0;
101
+ font: normal bold 10px/13px Tahoma,sans-serif;
102
+
103
+ color: inherit;
104
+ background: transparent none no-repeat -100em -100em;
105
+ }
106
+
107
+
108
+ /* Applied to 'focused' tooltips e.g. most recently displayed/interacted with */
109
+ .qtip-focus{}
110
+
111
+ /* Applied on hover of tooltips i.e. added/removed on mouseenter/mouseleave respectively */
112
+ .qtip-hover{}
113
+
114
+ /* Default tooltip style */
115
+ .qtip-default{
116
+ border-width: 1px;
117
+ border-style: solid;
118
+ /*border-color: #F1D031;*/
119
+ border-color: #222;
120
+ background-color: #444;
121
+ /*background-color: #FFFFA3;*/
122
+ color: #fff;
123
+
124
+ }
125
+ .qtip-default .qtip-titlebar{
126
+ background-color: #FFEF93;
127
+ }
128
+
129
+ .qtip-default .qtip-icon{
130
+ border-color: #CCC;
131
+ background: #F1F1F1;
132
+ color: #777;
133
+ }
134
+
135
+ .qtip-default .qtip-titlebar .qtip-close{
136
+ border-color: #AAA;
137
+ color: #111;
138
+ }
139
+
140
+
141
+ /*! Light tooltip style */
142
+ .qtip-light{
143
+ background-color: white;
144
+ border-color: #E2E2E2;
145
+ color: #454545;
146
+ }
147
+
148
+ .qtip-light .qtip-titlebar{
149
+ background-color: #f1f1f1;
150
+ }
151
+
152
+
153
+ /*! Dark tooltip style */
154
+ .qtip-dark{
155
+ background-color: #505050;
156
+ border-color: #303030;
157
+ color: #f3f3f3;
158
+ }
159
+
160
+ .qtip-dark .qtip-titlebar{
161
+ background-color: #404040;
162
+ }
163
+
164
+ .qtip-dark .qtip-icon{
165
+ border-color: #444;
166
+ }
167
+
168
+ .qtip-dark .qtip-titlebar .ui-state-hover{
169
+ border-color: #303030;
170
+ }
171
+
172
+
173
+ /*! Cream tooltip style */
174
+ .qtip-cream{
175
+ background-color: #FBF7AA;
176
+ border-color: #F9E98E;
177
+ color: #A27D35;
178
+ }
179
+
180
+ .qtip-cream .qtip-titlebar{
181
+ background-color: #F0DE7D;
182
+ }
183
+
184
+ .qtip-cream .qtip-close .qtip-icon{
185
+ background-position: -82px 0;
186
+ }
187
+
188
+
189
+ /*! Red tooltip style */
190
+ .qtip-red{
191
+ background-color: #F78B83;
192
+ border-color: #D95252;
193
+ color: #912323;
194
+ }
195
+
196
+ .qtip-red .qtip-titlebar{
197
+ background-color: #F06D65;
198
+ }
199
+
200
+ .qtip-red .qtip-close .qtip-icon{
201
+ background-position: -102px 0;
202
+ }
203
+
204
+ .qtip-red .qtip-icon{
205
+ border-color: #D95252;
206
+ }
207
+
208
+ .qtip-red .qtip-titlebar .ui-state-hover{
209
+ border-color: #D95252;
210
+ }
211
+
212
+
213
+ /*! Green tooltip style */
214
+ .qtip-green{
215
+ background-color: #CAED9E;
216
+ border-color: #90D93F;
217
+ color: #3F6219;
218
+ }
219
+
220
+ .qtip-green .qtip-titlebar{
221
+ background-color: #B0DE78;
222
+ }
223
+
224
+ .qtip-green .qtip-close .qtip-icon{
225
+ background-position: -42px 0;
226
+ }
227
+
228
+
229
+ /*! Blue tooltip style */
230
+ .qtip-blue{
231
+ background-color: #E5F6FE;
232
+ border-color: #ADD9ED;
233
+ color: #5E99BD;
234
+ }
235
+
236
+ .qtip-blue .qtip-titlebar{
237
+ background-color: #D0E9F5;
238
+ }
239
+
240
+ .qtip-blue .qtip-close .qtip-icon{
241
+ background-position: -2px 0;
242
+ }
243
+
244
+
245
+ /* Add shadows to your tooltips in: FF3+, Chrome 2+, Opera 10.6+, IE9+, Safari 2+ */
246
+ .qtip-shadow{
247
+ -webkit-box-shadow: 1px 1px 3px 1px rgba(0, 0, 0, 0.15);
248
+ -moz-box-shadow: 1px 1px 3px 1px rgba(0, 0, 0, 0.15);
249
+ box-shadow: 1px 1px 3px 1px rgba(0, 0, 0, 0.15);
250
+ }
251
+
252
+ /* Add rounded corners to your tooltips in: FF3+, Chrome 2+, Opera 10.6+, IE9+, Safari 2+ */
253
+ .qtip-rounded,
254
+ .qtip-tipsy,
255
+ .qtip-bootstrap{
256
+ -moz-border-radius: 5px;
257
+ -webkit-border-radius: 5px;
258
+ border-radius: 5px;
259
+ }
260
+
261
+ /* Youtube tooltip style */
262
+ .qtip-youtube{
263
+ -moz-border-radius: 2px;
264
+ -webkit-border-radius: 2px;
265
+ border-radius: 2px;
266
+
267
+ -webkit-box-shadow: 0 0 3px #333;
268
+ -moz-box-shadow: 0 0 3px #333;
269
+ box-shadow: 0 0 3px #333;
270
+
271
+ color: white;
272
+ border-width: 0;
273
+
274
+ background: #4A4A4A;
275
+ background-image: -webkit-gradient(linear,left top,left bottom,color-stop(0,#4A4A4A),color-stop(100%,black));
276
+ background-image: -webkit-linear-gradient(top,#4A4A4A 0,black 100%);
277
+ background-image: -moz-linear-gradient(top,#4A4A4A 0,black 100%);
278
+ background-image: -ms-linear-gradient(top,#4A4A4A 0,black 100%);
279
+ background-image: -o-linear-gradient(top,#4A4A4A 0,black 100%);
280
+ }
281
+
282
+ .qtip-youtube .qtip-titlebar{
283
+ background-color: #4A4A4A;
284
+ background-color: rgba(0,0,0,0);
285
+ }
286
+
287
+ .qtip-youtube .qtip-content{
288
+ padding: .75em;
289
+ font: 12px arial,sans-serif;
290
+
291
+ filter: progid:DXImageTransform.Microsoft.Gradient(GradientType=0,StartColorStr=#4a4a4a,EndColorStr=#000000);
292
+ -ms-filter: "progid:DXImageTransform.Microsoft.Gradient(GradientType=0,StartColorStr=#4a4a4a,EndColorStr=#000000);";
293
+ }
294
+
295
+ .qtip-youtube .qtip-icon{
296
+ border-color: #222;
297
+ }
298
+
299
+ .qtip-youtube .qtip-titlebar .ui-state-hover{
300
+ border-color: #303030;
301
+ }
302
+
303
+
304
+ /* jQuery TOOLS Tooltip style */
305
+ .qtip-jtools{
306
+ background: #232323;
307
+ background: rgba(0, 0, 0, 0.7);
308
+ background-image: -webkit-gradient(linear, left top, left bottom, from(#717171), to(#232323));
309
+ background-image: -moz-linear-gradient(top, #717171, #232323);
310
+ background-image: -webkit-linear-gradient(top, #717171, #232323);
311
+ background-image: -ms-linear-gradient(top, #717171, #232323);
312
+ background-image: -o-linear-gradient(top, #717171, #232323);
313
+
314
+ border: 2px solid #ddd;
315
+ border: 2px solid rgba(241,241,241,1);
316
+
317
+ -moz-border-radius: 2px;
318
+ -webkit-border-radius: 2px;
319
+ border-radius: 2px;
320
+
321
+ -webkit-box-shadow: 0 0 12px #333;
322
+ -moz-box-shadow: 0 0 12px #333;
323
+ box-shadow: 0 0 12px #333;
324
+ }
325
+
326
+ /* IE Specific */
327
+ .qtip-jtools .qtip-titlebar{
328
+ background-color: transparent;
329
+ filter:progid:DXImageTransform.Microsoft.gradient(startColorstr=#717171,endColorstr=#4A4A4A);
330
+ -ms-filter: "progid:DXImageTransform.Microsoft.gradient(startColorstr=#717171,endColorstr=#4A4A4A)";
331
+ }
332
+ .qtip-jtools .qtip-content{
333
+ filter:progid:DXImageTransform.Microsoft.gradient(startColorstr=#4A4A4A,endColorstr=#232323);
334
+ -ms-filter: "progid:DXImageTransform.Microsoft.gradient(startColorstr=#4A4A4A,endColorstr=#232323)";
335
+ }
336
+
337
+ .qtip-jtools .qtip-titlebar,
338
+ .qtip-jtools .qtip-content{
339
+ background: transparent;
340
+ color: white;
341
+ border: 0 dashed transparent;
342
+ }
343
+
344
+ .qtip-jtools .qtip-icon{
345
+ border-color: #555;
346
+ }
347
+
348
+ .qtip-jtools .qtip-titlebar .ui-state-hover{
349
+ border-color: #333;
350
+ }
351
+
352
+
353
+ /* Cluetip style */
354
+ .qtip-cluetip{
355
+ -webkit-box-shadow: 4px 4px 5px rgba(0, 0, 0, 0.4);
356
+ -moz-box-shadow: 4px 4px 5px rgba(0, 0, 0, 0.4);
357
+ box-shadow: 4px 4px 5px rgba(0, 0, 0, 0.4);
358
+
359
+ background-color: #D9D9C2;
360
+ color: #111;
361
+ border: 0 dashed transparent;
362
+ }
363
+
364
+ .qtip-cluetip .qtip-titlebar{
365
+ background-color: #87876A;
366
+ color: white;
367
+ border: 0 dashed transparent;
368
+ }
369
+
370
+ .qtip-cluetip .qtip-icon{
371
+ border-color: #808064;
372
+ }
373
+
374
+ .qtip-cluetip .qtip-titlebar .ui-state-hover{
375
+ border-color: #696952;
376
+ color: #696952;
377
+ }
378
+
379
+
380
+ /* Tipsy style */
381
+ .qtip-tipsy{
382
+ background: black;
383
+ background: rgba(0, 0, 0, .87);
384
+
385
+ color: white;
386
+ border: 0 solid transparent;
387
+
388
+ font-size: 11px;
389
+ font-family: 'Lucida Grande', sans-serif;
390
+ font-weight: bold;
391
+ line-height: 16px;
392
+ text-shadow: 0 1px black;
393
+ }
394
+
395
+ .qtip-tipsy .qtip-titlebar{
396
+ padding: 6px 35px 0 10;
397
+ background-color: transparent;
398
+ }
399
+
400
+ .qtip-tipsy .qtip-content{
401
+ padding: 6px 10;
402
+ }
403
+
404
+ .qtip-tipsy .qtip-icon{
405
+ border-color: #222;
406
+ text-shadow: none;
407
+ }
408
+
409
+ .qtip-tipsy .qtip-titlebar .ui-state-hover{
410
+ border-color: #303030;
411
+ }
412
+
413
+
414
+ /* Tipped style */
415
+ .qtip-tipped{
416
+ border: 3px solid #959FA9;
417
+
418
+ -moz-border-radius: 3px;
419
+ -webkit-border-radius: 3px;
420
+ border-radius: 3px;
421
+
422
+ background-color: #F9F9F9;
423
+ color: #454545;
424
+
425
+ font-weight: normal;
426
+ font-family: serif;
427
+ }
428
+
429
+ .qtip-tipped .qtip-titlebar{
430
+ border-bottom-width: 0;
431
+
432
+ color: white;
433
+ background: #3A79B8;
434
+ background-image: -webkit-gradient(linear, left top, left bottom, from(#3A79B8), to(#2E629D));
435
+ background-image: -webkit-linear-gradient(top, #3A79B8, #2E629D);
436
+ background-image: -moz-linear-gradient(top, #3A79B8, #2E629D);
437
+ background-image: -ms-linear-gradient(top, #3A79B8, #2E629D);
438
+ background-image: -o-linear-gradient(top, #3A79B8, #2E629D);
439
+ filter:progid:DXImageTransform.Microsoft.gradient(startColorstr=#3A79B8,endColorstr=#2E629D);
440
+ -ms-filter: "progid:DXImageTransform.Microsoft.gradient(startColorstr=#3A79B8,endColorstr=#2E629D)";
441
+ }
442
+
443
+ .qtip-tipped .qtip-icon{
444
+ border: 2px solid #285589;
445
+ background: #285589;
446
+ }
447
+
448
+ .qtip-tipped .qtip-icon .ui-icon{
449
+ background-color: #FBFBFB;
450
+ color: #555;
451
+ }
452
+
453
+
454
+ /**
455
+ * Twitter Bootstrap style.
456
+ *
457
+ * Tested with IE 8, IE 9, Chrome 18, Firefox 9, Opera 11.
458
+ * Does not work with IE 7.
459
+ */
460
+ .qtip-bootstrap{
461
+ /** Taken from Bootstrap body */
462
+ font-size: 14px;
463
+ line-height: 20px;
464
+ color: #333333;
465
+
466
+ /** Taken from Bootstrap .popover */
467
+ padding: 1px;
468
+ background-color: #ffffff;
469
+ border: 1px solid #ccc;
470
+ border: 1px solid rgba(0, 0, 0, 0.2);
471
+ -webkit-border-radius: 6px;
472
+ -moz-border-radius: 6px;
473
+ border-radius: 6px;
474
+ -webkit-box-shadow: 0 5px 10px rgba(0, 0, 0, 0.2);
475
+ -moz-box-shadow: 0 5px 10px rgba(0, 0, 0, 0.2);
476
+ box-shadow: 0 5px 10px rgba(0, 0, 0, 0.2);
477
+ -webkit-background-clip: padding-box;
478
+ -moz-background-clip: padding;
479
+ background-clip: padding-box;
480
+ }
481
+
482
+ .qtip-bootstrap .qtip-titlebar{
483
+ /** Taken from Bootstrap .popover-title */
484
+ padding: 8px 14px;
485
+ margin: 0;
486
+ font-size: 14px;
487
+ font-weight: normal;
488
+ line-height: 18px;
489
+ background-color: #f7f7f7;
490
+ border-bottom: 1px solid #ebebeb;
491
+ -webkit-border-radius: 5px 5px 0 0;
492
+ -moz-border-radius: 5px 5px 0 0;
493
+ border-radius: 5px 5px 0 0;
494
+ }
495
+
496
+ .qtip-bootstrap .qtip-titlebar .qtip-close{
497
+ /**
498
+ * Overrides qTip2:
499
+ * .qtip-titlebar .qtip-close{
500
+ * [...]
501
+ * right: 4px;
502
+ * top: 50%;
503
+ * [...]
504
+ * border-style: solid;
505
+ * }
506
+ */
507
+ right: 11px;
508
+ top: 45%;
509
+ border-style: none;
510
+ }
511
+
512
+ .qtip-bootstrap .qtip-content{
513
+ /** Taken from Bootstrap .popover-content */
514
+ padding: 9px 14px;
515
+ }
516
+
517
+ .qtip-bootstrap .qtip-icon{
518
+ /**
519
+ * Overrides qTip2:
520
+ * .qtip-default .qtip-icon {
521
+ * border-color: #CCC;
522
+ * background: #F1F1F1;
523
+ * color: #777;
524
+ * }
525
+ */
526
+ background: transparent;
527
+ }
528
+
529
+ .qtip-bootstrap .qtip-icon .ui-icon{
530
+ /**
531
+ * Overrides qTip2:
532
+ * .qtip-icon .ui-icon{
533
+ * width: 18px;
534
+ * height: 14px;
535
+ * }
536
+ */
537
+ width: auto;
538
+ height: auto;
539
+
540
+ /* Taken from Bootstrap .close */
541
+ float: right;
542
+ font-size: 20px;
543
+ font-weight: bold;
544
+ line-height: 18px;
545
+ color: #000000;
546
+ text-shadow: 0 1px 0 #ffffff;
547
+ opacity: 0.2;
548
+ filter: alpha(opacity=20);
549
+ }
550
+
551
+ .qtip-bootstrap .qtip-icon .ui-icon:hover{
552
+ /* Taken from Bootstrap .close:hover */
553
+ color: #000000;
554
+ text-decoration: none;
555
+ cursor: pointer;
556
+ opacity: 0.4;
557
+ filter: alpha(opacity=40);
558
+ }
559
+
560
+
561
+ /* IE9 fix - removes all filters */
562
+ .qtip:not(.ie9haxors) div.qtip-content,
563
+ .qtip:not(.ie9haxors) div.qtip-titlebar{
564
+ filter: none;
565
+ -ms-filter: none;
566
+ }
567
+
568
+
569
+ /* Tips plugin */
570
+ .qtip .qtip-tip{
571
+ margin: 0 auto;
572
+ overflow: hidden;
573
+ z-index: 10;
574
+ }
575
+
576
+ .qtip .qtip-tip,
577
+ .qtip .qtip-tip .qtip-vml{
578
+ position: absolute;
579
+
580
+ color: #123456;
581
+ background: transparent;
582
+ border: 0 dashed transparent;
583
+ }
584
+
585
+ .qtip .qtip-tip canvas{ top: -1px; left: 0; position: absolute }
586
+
587
+ .qtip .qtip-tip .qtip-vml{
588
+ behavior: url(#default#VML);
589
+ display: inline-block;
590
+ visibility: visible;
591
+ }
592
+ /* Modal plugin */
593
+ #qtip-overlay{
594
+ position: fixed;
595
+ left: -10000em;
596
+ top: -10000em;
597
+ }
598
+
599
+ /* Applied to modals with show.modal.blur set to true */
600
+ #qtip-overlay.blurs{ cursor: pointer; }
601
+
602
+ /* Change opacity of overlay here */
603
+ #qtip-overlay div{
604
+ position: absolute;
605
+ left: 0; top: 0;
606
+ width: 100%; height: 100%;
607
+
608
+ background-color: black;
609
+
610
+ opacity: 0.7;
611
+ filter:alpha(opacity=70);
612
+ -ms-filter:"progid:DXImageTransform.Microsoft.Alpha(Opacity=70)";
613
+ }
614
+
615
+
616
+ /* IE6 Modal plugin fix */
617
+ .qtipmodal-ie6fix{
618
+ position: absolute !important;
619
+ }
620
+
621
+ .field_with_error input, .field_with_error textarea, input.error, textarea.error{
622
+ border: 1px solid red;
623
+ }