1
0
Fork 0
mirror of https://we.phorge.it/source/phorge.git synced 2024-11-27 01:02:42 +01:00
phorge-phorge/webroot/rsrc/css/phui
epriestley fce0109822 When dragging nodes, clone them
Summary:
Ref T5240. Currently, when dragging nodes, we leave them where they are in the document and apply "position: relative;" so we can move them around on screen.

  - Pros: All the CSS still works.
  - Cons: Can't drag them outside the nearest containing element with "overflow: hidden;", many subtle positioning bugs with scrollable containers.

Instead, this diff leaves the thing we're dragging exactly where it is, clones it, and drags the clone instead.

  - Pros: You can drag it anywhere. Seems to fix all the scrolling container problems.
  - Cons: CSS which depends on a container class no longer works.

The CSS thing is bad, but doesn't seem too unreasonable to fix. Basically, we just need to put some `phui-this-is-a-workboard-card` class on the cards, and use that to style them instead of `phui-workboard-view`, and then do something similar for draggable lists.

Although we no longer need to drag cards to tabs with the current design, I think there's a reasonable chance we'll revisit that later. The current design also calls for scrollable columns, but there would be no way to drag cards outside of their current column with the current approach.

NOTE: This does not attempt to fix the CSS, so dragging is pretty rough, since the "clone" loses a number of container classes and thus a number of rules. I'll clean up the CSS in the next change.

Test Plan:
  - Dragged stuff around on task lists, workboards, and sort lists (e.g., pinned applications) in Safari, Firefox and Chrome.
  - Scrolled window and containers (workboards) during drag.
  - Dragged stuff out of the workboard.
  - Dragged stuff offscreen.
  - CSS is funky, but I can no longer find any positioning or layout issues in any browser.

Reviewers: chad

Reviewed By: chad

Maniphest Tasks: T5240

Differential Revision: https://secure.phabricator.com/D15160
2016-02-01 18:48:19 -08:00
..
calendar Clicking in day view should create new event 2015-05-24 11:22:33 -07:00
workboards Add ownerheads to workboard cards 2016-02-01 16:27:49 -08:00
phui-action-list.css [Redesign] Normalize menus and lists 2015-07-01 15:17:44 -07:00
phui-action-panel.css Usability updates to ActionPanel 2015-09-17 08:22:23 -07:00
phui-badge.css Prevent long text from breaking Badges 2015-07-27 07:55:09 -07:00
phui-big-info-view.css Add more NUX states 2015-12-21 11:15:54 -08:00
phui-box.css Extend PHUITheme to include Profile Nav 2016-01-27 13:56:04 -08:00
phui-button.css First cut of new Project Home 2016-01-23 16:11:45 -08:00
phui-chart.css Swap charts from gRaphael to D3 2016-02-01 10:36:59 -08:00
phui-crumbs-view.css Add Can Create Policy Capability to Phame Blogs 2015-11-08 07:00:18 -08:00
phui-document-pro.css Add Next and Previous UI to PhamePostView 2015-12-31 13:09:59 -08:00
phui-document-summary.css Add a Read More link to PHUIDocumentSummaryView 2015-12-19 12:49:23 -08:00
phui-document.css Move code examples in remarkup to grey backgrounds 2016-01-29 12:31:34 -08:00
phui-feed-story.css Tighten up spacing on feed stories 2016-01-31 12:35:03 -08:00
phui-fontkit.css Update Phriction for PHUIDocumentViewPro 2015-11-22 13:11:20 -08:00
phui-form-view.css Allow users to swipe away stacked actions on mobile 2015-12-22 19:17:11 -08:00
phui-form.css Give custom controls passable disabled states 2015-12-17 15:13:28 -08:00
phui-header-view.css Add an edit link on hover for Project profile images 2016-01-24 13:20:54 -08:00
phui-icon-set-selector.css Allow installs to customize project icons 2016-01-08 14:01:53 -08:00
phui-icon.css PHUIIconCircleView 2016-01-18 09:02:58 -08:00
phui-image-mask.css CSS polish, Pholio 2014-06-19 11:28:01 -07:00
phui-info-panel.css PHUIInfoPanel 2013-10-25 11:09:06 -07:00
phui-info-view.css PHUIDocumentViewPro tweaks 2015-11-03 13:43:26 -08:00
phui-list.css Straighten out reorder permissions on form configurations 2015-12-19 07:36:00 -08:00
phui-object-box.css Fix Calendar/Double Panel Headers 2015-07-16 17:15:27 -07:00
phui-object-item-list-view.css When dragging nodes, clone them 2016-02-01 18:48:19 -08:00
phui-pager.css [Redesign] PHUIPagerView 2015-06-02 14:34:04 -07:00
phui-pinboard-view.css [Redesign] Larger Font PostProcessor 2015-06-26 09:33:03 -07:00
phui-profile-menu.css Extend PHUITheme to include Profile Nav 2016-01-27 13:56:04 -08:00
phui-property-list-view.css Widen PHUIPropertyListView when ActionList isn't attached 2015-10-28 11:19:42 -07:00
phui-remarkup-preview.css Use new DocumentView for Legalpad previews 2015-11-24 10:07:39 -08:00
phui-spacing.css PHUIButtonView class 2013-06-12 18:23:35 -07:00
phui-status.css Remove negative margin in phui-status 2014-10-16 13:12:03 -07:00
phui-tag-view.css Make PHUITags not break/wrap 2016-01-31 20:08:13 +00:00
phui-timeline-view.css Link Timeline image to profile 2015-10-14 16:28:10 -07:00
phui-two-column-view.css First cut of new Project Home 2016-01-23 16:11:45 -08:00