public function panel($class, array $sections)
    {
        $html = '';
        foreach ($sections as $panel => $content) {
            if (!is_numeric($panel)) {
                $panel = substr($panel, 0, 4);
            }
            switch ((string) $panel) {
                case 'head':
                    $html .= '<div class="panel-heading">'.$this->addClass($content, array('h([1-6]){1}' => 'panel-title')).'</div>';
                    break;
                case 'body':
                    $html .= '<div class="panel-body">'.$content.'</div>';
                    break;
                case 'foot':
                    $html .= '<div class="panel-footer">'.$content.'</div>';
                    break;
                default:
                    $html .= $content;
                    break; // a table, or list group, or ...
            }
        }

        return $this->page->tag('div', array(
            'class' => $this->prefixClasses('panel', array('default', 'primary', 'success', 'info', 'warning', 'danger'), $class),
        ), $html);
    }