webstaff: style file input buttons more nicely
authorGalen Charlton <gmc@esilibrary.com>
Mon, 25 Jan 2016 20:41:52 +0000 (15:41 -0500)
committerKathy Lussier <klussier@masslnc.org>
Tue, 2 Feb 2016 19:58:53 +0000 (14:58 -0500)
Using technique devised by Cory LaViska per
http://www.abeautifulsite.net/whipping-file-inputs-into-shape-with-bootstrap-3/

Signed-off-by: Galen Charlton <gmc@esilibrary.com>
Signed-off-by: Kathy Lussier <klussier@masslnc.org>
Open-ILS/src/templates/staff/css/style.css.tt2

index 80fb47a..0c21913 100644 (file)
@@ -132,6 +132,29 @@ table.list tr.selected td { /* deprecated? */
   margin-left: 10px;
 }
 
+/* button styling by Cory LaViska from
+   http://www.abeautifulsite.net/whipping-file-inputs-into-shape-with-bootstrap-3/
+*/
+.btn-file {
+    position: relative;
+    overflow: hidden;
+}
+.btn-file input[type=file] {
+    position: absolute;
+    top: 0;
+    right: 0;
+    min-width: 100%;
+    min-height: 100%;
+    font-size: 100px;
+    text-align: right;
+    filter: alpha(opacity=0);
+    opacity: 0;
+    outline: none;
+    background: white;
+    cursor: inherit;
+    display: block;
+}
+
 .strong-text {
   font-weight: bold;
 }