[Rt-commit] rt branch, 4.6/inline-edit, updated. rt-4.4.1-169-g417568e

Shawn Moore shawn at bestpractical.com
Tue Sep 20 14:03:32 EDT 2016


The branch, 4.6/inline-edit has been updated
       via  417568ebd2b9c615fa482eef82c65722005e196f (commit)
       via  c3d9d405cafc55c17deec9e311de6cc5b5db0311 (commit)
       via  1af29126891e1c835bd48b232e68ebeefa2bcfec (commit)
       via  f865ed1eb1a07db242fe0551d664eca856d7722a (commit)
      from  6d500eabd8e0822a3d3c5408b9445568999cc4c4 (commit)

Summary of changes:
 share/html/Elements/CollectionAsTable/Row |   8 +++-----
 share/html/Elements/CollectionList        |   2 +-
 share/static/css/base/inline-edit.css     |  22 +++++++++++++++-------
 share/static/images/pencil.png            | Bin 0 -> 46158 bytes
 4 files changed, 19 insertions(+), 13 deletions(-)
 create mode 100644 share/static/images/pencil.png

- Log -----------------------------------------------------------------
commit f865ed1eb1a07db242fe0551d664eca856d7722a
Author: Shawn M Moore <shawn at bestpractical.com>
Date:   Tue Sep 20 17:30:51 2016 +0000

    Add pencil.png inline edit indicator icon
    
    This image is in the public domain
    Source: https://thenounproject.com/search/?q=pencil&i=197671

diff --git a/share/static/images/pencil.png b/share/static/images/pencil.png
new file mode 100644
index 0000000..1ca859a
Binary files /dev/null and b/share/static/images/pencil.png differ

commit 1af29126891e1c835bd48b232e68ebeefa2bcfec
Author: Shawn M Moore <shawn at bestpractical.com>
Date:   Tue Sep 20 17:46:10 2016 +0000

    Add CSS class to tables with inline-edit

diff --git a/share/html/Elements/CollectionList b/share/html/Elements/CollectionList
index bbafd9b..5f3abd1 100644
--- a/share/html/Elements/CollectionList
+++ b/share/html/Elements/CollectionList
@@ -117,7 +117,7 @@ if ($Class =~ /::/) { # older passed in value
 }
 
 $m->out('<table cellspacing="0"');
-$m->out(' class="' .  ($Collection->isa('RT::Tickets') ? 'ticket-list' : 'collection') . ' collection-as-table"');
+$m->out(' class="' .  ($Collection->isa('RT::Tickets') ? 'ticket-list' : 'collection') . ($InlineEdit ? ' inline-edit' : '') . ' collection-as-table"');
 $m->out(' data-display-format="' . $m->interp->apply_escapes($DisplayFormat, 'h') . '"');
 $m->out(' data-max-items="' . $maxitems . '"');
 $m->out(' data-class="' . $Collection->RecordClass . '"');

commit c3d9d405cafc55c17deec9e311de6cc5b5db0311
Author: Shawn M Moore <shawn at bestpractical.com>
Date:   Tue Sep 20 17:59:48 2016 +0000

    Clean up paddings on non- and inline-edit cells

diff --git a/share/html/Elements/CollectionAsTable/Row b/share/html/Elements/CollectionAsTable/Row
index 8f252fd..29e6e13 100644
--- a/share/html/Elements/CollectionAsTable/Row
+++ b/share/html/Elements/CollectionAsTable/Row
@@ -169,14 +169,12 @@ foreach my $column (@Format) {
         $m->out($attrs{edit});
         $m->out('<a href="#" class="cancel"><img src="'.RT->Config->Get('WebPath').'/static/images/close.png" alt="'.loc('Cancel').'" title="'.loc('Cancel').'" /></a>');
         $m->out('<span class="loading"><img src="'.RT->Config->Get('WebPath').'/static/images/loading.gif" alt="'.loc('Loading').'" title="'.loc('Loading').'" /></span>');
-        $m->out('</form><div class="value">');
+        $m->out('</form>');
     }
 
+    $m->out('<div class="value">');
     $m->out(@out) if @out;
-
-    if ($attrs{edit}) {
-        $m->out('</div>');
-    }
+    $m->out('</div>');
 
     $m->out( '</td>' . "\n" );
 }
diff --git a/share/static/css/base/inline-edit.css b/share/static/css/base/inline-edit.css
index 8ee2483..615c31b 100644
--- a/share/static/css/base/inline-edit.css
+++ b/share/static/css/base/inline-edit.css
@@ -1,5 +1,16 @@
-td.editable .value {
+table.inline-edit tr.oddline td,
+table.inline-edit tr.evenline td {
+    padding: 0.25em 0.25em 0.125em 0.125em;
+}
+
+table.inline-edit td .value {
     border: 1px dashed transparent;
+    padding: 0.25em 0.25em 0.125em 0.125em;
+}
+
+table.inline-edit tr.oddline td.editable.editing,
+table.inline-edit tr.evenline td.editable.editing {
+    padding: 0.5em 0.5em 0.25em 0.25em;
 }
 
 td.editable .value:hover {
@@ -14,10 +25,6 @@ body.inline-editing td.editable .value:hover {
     cursor: inherit;
 }
 
-td.editable > .value {
-    padding-top: 0;
-}
-
 td.editable > form.editor > .loading > img,
 td.editable > form.editor > .cancel > img {
     height: 1.5em;

commit 417568ebd2b9c615fa482eef82c65722005e196f
Author: Shawn M Moore <shawn at bestpractical.com>
Date:   Tue Sep 20 18:03:16 2016 +0000

    Add pencil icon to inline edit indicator

diff --git a/share/static/css/base/inline-edit.css b/share/static/css/base/inline-edit.css
index 615c31b..7c82b09 100644
--- a/share/static/css/base/inline-edit.css
+++ b/share/static/css/base/inline-edit.css
@@ -14,13 +14,14 @@ table.inline-edit tr.evenline td.editable.editing {
 }
 
 td.editable .value:hover {
-    background-color: #ffd;
+    background: #ffd url(../../../static/images/pencil.png) no-repeat top right;
+    background-size: auto 100%;
     border-color: black;
     cursor: pointer;
 }
 
 body.inline-editing td.editable .value:hover {
-    background-color: inherit;
+    background: inherit;
     border-color: transparent;
     cursor: inherit;
 }

-----------------------------------------------------------------------


More information about the rt-commit mailing list