<?php

final class ExtensionStoreBrowseHomeController
  extends ExtensionStoreBrowseBaseController {

  public function handleRequest(AphrontRequest $request) {

    $crumbs = $this->buildApplicationCrumbs();
    $crumbs->addTextCrumb(pht('Landing Page'));
    $crumbs->setBorder(true);

    $box = id(new PHUIObjectBoxView())
      ->setHeaderText(pht('Extension Store'))
      ->setBackground(PHUIObjectBoxView::WHITE_CONFIG)
      ->appendChild(
        pht(
          'This is the landing page for the Store - both logged-in '.
          '(`/extensionstore/view/`) and logged-out (dedicated domain). '.
          'This page should probably hold a list of extensions sorted by '.
          'fanciness.'))
      ->setObjectList(null);

    $launcher_view = id(new PHUILauncherView())
      ->appendChild($box);

    $view = new PHUITwoColumnView()
      ->setFooter($launcher_view);

    return $this->newPage()
      ->setTitle(pht('Extension Store'))
      ->setCrumbs($crumbs)
      ->setNavigation($this->buildSideNavView())
      ->appendChild($view);
  }


}
