mirror of
https://we.phorge.it/source/phorge.git
synced 2025-02-21 11:09:02 +01:00
Summary: Ref T13552. The current layout doesn't work particularly well on desktops or devices. We have some device/desktop table layout code, but it isn't generic. We also have property list layout code, but it isn't generic either. Provide generic layout elements ("Fuel", from "Phabricator UI Layout" to "PHUIL"?) and narrowly specialize their display behavior. Then swap the ListItemView stuff to use it. Test Plan: Saw slightly better responsive behavior: {F7637457} Maniphest Tasks: T13552 Differential Revision: https://secure.phabricator.com/D21418
45 lines
704 B
PHP
45 lines
704 B
PHP
<?php
|
|
|
|
final class FuelMapView
|
|
extends FuelComponentView {
|
|
|
|
private $items = array();
|
|
|
|
public function newItem() {
|
|
$item = new FuelMapItemView();
|
|
$this->items[] = $item;
|
|
return $item;
|
|
}
|
|
|
|
public function render() {
|
|
require_celerity_resource('fuel-map-css');
|
|
|
|
$items = $this->items;
|
|
|
|
if (!$items) {
|
|
return null;
|
|
}
|
|
|
|
$body = phutil_tag(
|
|
'div',
|
|
array(
|
|
'class' => 'fuel-map-items',
|
|
),
|
|
$items);
|
|
|
|
$map = phutil_tag(
|
|
'div',
|
|
array(
|
|
'class' => 'fuel-map',
|
|
),
|
|
$body);
|
|
|
|
return $this->newComponentTag(
|
|
'div',
|
|
array(
|
|
'class' => 'fuel-map-component',
|
|
),
|
|
$map);
|
|
}
|
|
|
|
}
|