Page Menu
Home
GnuPG
Search
Configure Global Search
Log In
Files
F29935092
PHUICMSView.php
No One
Temporary
Actions
Download File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Size
2 KB
Subscribers
None
PHUICMSView.php
View Options
<?php
final
class
PHUICMSView
extends
AphrontTagView
{
private
$header
;
private
$nav
;
private
$crumbs
;
private
$content
;
private
$toc
;
private
$comments
;
public
function
setHeader
(
PHUIHeaderView
$header
)
{
$this
->
header
=
$header
;
return
$this
;
}
public
function
setNavigation
(
AphrontSideNavFilterView
$nav
)
{
$this
->
nav
=
$nav
;
return
$this
;
}
public
function
setCrumbs
(
PHUICrumbsView
$crumbs
)
{
$this
->
crumbs
=
$crumbs
;
return
$this
;
}
public
function
setContent
(
$content
)
{
$this
->
content
=
$content
;
return
$this
;
}
public
function
setToc
(
$toc
)
{
$this
->
toc
=
$toc
;
return
$this
;
}
public
function
setComments
(
$comments
)
{
$this
->
comments
=
$comments
;
}
protected
function
getTagName
()
{
return
'div'
;
}
protected
function
getTagAttributes
()
{
require_celerity_resource
(
'phui-cms-css'
);
$classes
=
array
();
$classes
[]
=
'phui-cms-view'
;
if
(
$this
->
comments
)
{
$classes
[]
=
'phui-cms-has-comments'
;
}
return
array
(
'class'
=>
implode
(
' '
,
$classes
),
);
}
protected
function
getTagContent
()
{
$content
=
phutil_tag
(
'div'
,
array
(
'class'
=>
'phui-cms-page-content'
,
),
array
(
$this
->
header
,
$this
->
content
,
));
$comments
=
null
;
if
(
$this
->
comments
)
{
$comments
=
phutil_tag
(
'div'
,
array
(
'class'
=>
'phui-cms-comments'
,
),
array
(
$this
->
comments
,
));
}
$navigation
=
$this
->
nav
;
$navigation
->
appendChild
(
$content
);
$navigation
->
appendChild
(
$comments
);
$page
=
phutil_tag
(
'div'
,
array
(
'class'
=>
'phui-cms-inner'
,
),
array
(
$navigation
,
));
$cms_view
=
phutil_tag
(
'div'
,
array
(
'class'
=>
'phui-cms-wrap'
,
),
array
(
$this
->
crumbs
,
$page
,
));
$classes
=
array
();
$classes
[]
=
'phui-cms-page'
;
return
phutil_tag
(
'div'
,
array
(
'class'
=>
implode
(
' '
,
$classes
),
),
$cms_view
);
}
}
File Metadata
Details
Attached
Mime Type
text/x-php
Expires
Fri, Oct 17, 7:58 AM (20 h, 58 m)
Storage Engine
local-disk
Storage Format
Raw Data
Storage Handle
fb/68/93b8f823f8353d6a0adf3d63ad28
Attached To
rPHAB Phabricator
Event Timeline
Log In to Comment