* move inline CSS in patron editor to a file
authorphasefx <phasefx@dcc99617-32d9-48b4-a31d-7c20da2025e4>
Wed, 8 Sep 2010 16:17:48 +0000 (16:17 +0000)
committerphasefx <phasefx@dcc99617-32d9-48b4-a31d-7c20da2025e4>
Wed, 8 Sep 2010 16:17:48 +0000 (16:17 +0000)
* hook for custom CSS file to override patron editor styling

So for example, you can create /openils/var/web/css/skin/default/register_custom.css and have it contain CSS like this:

TR[fmfield=ident_type] { display: none; } /* dangerous if the widget is required and doesn't have a default */
TR[fmfield=ident_value2] > TD { font-size: x-large; }
TR[fmfield=barred] { display: none; }
TR[fmfield=country] { display: none; } /* dangerous if the widget is required and doesn't have a default */
TR[fmfield=master_account] { display: none; }
TR[fmfield=alert_message] { display: none; }

git-svn-id: svn://svn.open-ils.org/ILS/trunk@17516 dcc99617-32d9-48b4-a31d-7c20da2025e4

Open-ILS/web/css/skin/default/register.css [new file with mode: 0644]
Open-ILS/web/templates/default/actor/user/register.tt2

diff --git a/Open-ILS/web/css/skin/default/register.css b/Open-ILS/web/css/skin/default/register.css
new file mode 100644 (file)
index 0000000..2aa2e14
--- /dev/null
@@ -0,0 +1,83 @@
+@import url("register_custom.css");
+
+/* XXX Move me into the CSS tree XXX */
+
+#uedit-tbody tr td {
+    padding: 5px;
+    text-align: left;
+}
+
+
+#uedit-save-div {
+    position: fixed;
+    top:40px;
+    right:30px;
+    width:300px;
+    border:2px solid #d9e8f9;
+    -moz-border-radius: 10px;
+    font-weight: bold;
+    padding: 12px;
+    text-align:center;
+    vertical-align:middle;
+}
+
+#uedit-help-div {
+    position: fixed;
+    top:124px;
+    right:30px;
+    width:300px;
+    border:2px dashed #d9e8f9;
+    -moz-border-radius: 10px;
+    font-weight: bold;
+    padding: 20px;
+}
+
+#uedit-dupe-div {
+    position: fixed;
+    top:124px;
+    right:30px;
+    width:300px;
+    border:2px dashed #d9e8f9;
+    -moz-border-radius: 10px;
+    font-weight: bold;
+    padding: 20px;
+}
+
+.uedit-help {
+    width: 25px;
+    border:1px solid #e0e0e0;
+    text-align:center;
+    vertical-align:middle;
+}
+.divider td {
+    min-height:10px;
+    background-color: #e0e0e0;
+}
+
+.divider span { padding: 0px 5px 0px 5px; }
+
+.newaddr-row td {
+    text-align: right;
+    border-top:1px dashed #d9e8f9;
+}
+.newaddr-row td:last-child {
+    border-right:1px dashed #d9e8f9;
+}
+
+.pending-addr-row td { border:1px solid #aaa; }
+
+.uedit-addr-del-button {margin-left: 10px; color:red;}
+
+.dijitTextBoxFocused, .dijitFocused { border:1px dashed #3e3e3e; color: #303030; font-weight:bold;}
+
+.hide-non-required tr:not([required]) {
+    visibility:hidden;
+    display:none;
+}
+
+#require-toggle {
+    margin-top:10px;
+    margin-bottom:-5px;
+}
+
+
index a3ad7d7..b843e8c 100644 (file)
@@ -1,90 +1,7 @@
 [% ctx.page_title = 'User Editor' %]
 [% WRAPPER default/base.tt2 %]
 <script type="text/javascript" src='[% ctx.media_prefix %]/js/ui/default/actor/user/register.js'></script>
-
-<style type="text/css">
-
-    /* XXX Move me into the CSS tree XXX */
-
-    #uedit-tbody tr td {
-        padding: 5px;
-        text-align: left;
-    }
-
-
-    #uedit-save-div {
-        position: fixed;
-        top:40px;
-        right:30px;
-        width:300px;
-        border:2px solid #d9e8f9;
-        -moz-border-radius: 10px;
-        font-weight: bold;
-        padding: 12px;
-        text-align:center;
-        vertical-align:middle;
-    }
-
-    #uedit-help-div {
-        position: fixed;
-        top:124px;
-        right:30px;
-        width:300px;
-        border:2px dashed #d9e8f9;
-        -moz-border-radius: 10px;
-        font-weight: bold;
-        padding: 20px;
-    }
-
-    #uedit-dupe-div {
-        position: fixed;
-        top:124px;
-        right:30px;
-        width:300px;
-        border:2px dashed #d9e8f9;
-        -moz-border-radius: 10px;
-        font-weight: bold;
-        padding: 20px;
-    }
-
-    .uedit-help {
-        width: 25px;
-        border:1px solid #e0e0e0;
-        text-align:center;
-        vertical-align:middle;
-    }
-    .divider td {
-        min-height:10px;
-        background-color: #e0e0e0;
-    }
-
-    .divider span { padding: 0px 5px 0px 5px; }
-
-    .newaddr-row td {
-        text-align: right;
-        border-top:1px dashed #d9e8f9;
-    }
-    .newaddr-row td:last-child {
-        border-right:1px dashed #d9e8f9;
-    }
-
-    .pending-addr-row td { border:1px solid #aaa; }
-
-    .uedit-addr-del-button {margin-left: 10px; color:red;}
-
-    .dijitTextBoxFocused, .dijitFocused { border:1px dashed #3e3e3e; color: #303030; font-weight:bold;}
-
-    .hide-non-required tr:not([required]) {
-        visibility:hidden;
-        display:none;
-    }
-
-    #require-toggle {
-        margin-top:10px;
-        margin-bottom:-5px;
-    }
-
-</style>
+<link rel="stylesheet" type="text/css" href="[% ctx.media_prefix %]/css/skin/[% ctx.skin %]/register.css" />
 
 <div dojoType="dijit.form.Form" id="myForm" jsId="myForm" encType="multipart/form-data" action="" method="">
     <script type="dojo/method" event="onSubmit">