Skip to content

Commit

Permalink
Merge pull request patternfly#575 from dlabrecq/list-view-dnd-branch-…
Browse files Browse the repository at this point in the history
…4.0-dev

ListView drag and drop for 4.0.0-alpha.x
  • Loading branch information
dtaylor113 authored Jan 30, 2017
2 parents dd68dbe + 51bdbf7 commit db5c3b7
Show file tree
Hide file tree
Showing 2 changed files with 54 additions and 0 deletions.
53 changes: 53 additions & 0 deletions src/less/list-view-dnd.less
Original file line number Diff line number Diff line change
@@ -0,0 +1,53 @@
//
// List View Drag and Drop
// See: https://github.com/marceljuenemann/angular-drag-and-drop-lists
// --------------------------------------------------

.list-view-pf-dnd {
// Override dnd styles
.dndDragging {
&.drag-original {
display: none;
// Show when dragging original list items
.list-view-pf-dnd-original-items {
display: block;
}
}
// Show dragable list items during move operation
.list-view-pf-dnd-drag-items {
display: inline-block;
}
// Hide original list items during dnd move operation
.list-view-pf-dnd-original-items {
display: none;
}
}
// Override dnd placeholder element for dragging list items to
.dndPlaceholder {
background-color: @color-pf-black-200;
padding: 20px 0;
}
// A handle decoration shown to left of each list items row
.list-group-item-header {
margin-left: -10px;
&:before {
background-image: linear-gradient(to bottom, @color-pf-blue-400 60%, @color-pf-white 0%);
background-position: left;
background-repeat: repeat-y;
background-size: 2px 5px;
border: 4px solid @color-pf-blue-400;
border-color: @color-pf-blue-500;
content: "";
height: 55px;
left: 4px;
position: absolute;
top: 5px;
width: 10px;
}
}
}

// Always hide dragable list items until shown during dnd move operation
.list-view-pf-dnd-drag-items {
display: none;
}
1 change: 1 addition & 0 deletions src/less/patternfly-additions.less
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,7 @@
@import "layouts.less";
@import "links.less";
@import "list-view.less";
@import "list-view-dnd.less";
@import "login.less";
@import "navbar.less";
@import "navbar-alt.less";
Expand Down

0 comments on commit db5c3b7

Please sign in to comment.