lib/components/web/widgets/grid/LinkPager.php
protected function renderPageButton($label, $page, $class, $disabled, $active)
    {
        if ($active) {
            $class .= ' ' . $this->activePageCssClass;
        }
        if ($disabled) {
            $class .= ' ' . $this->disabledPageCssClass;
        }
        $state = $this->getState();
        $state['page'] = $page + 1;
        $jsonState = json_encode($state);

        $class .= ' stateful';
        $class = trim($class);
        $options = ['data-state' => $jsonState, 'class' => $class === '' ? null : $class];

        return Html::tag('li', Html::a($label, $this->pagination->createUrl($page), ['data-page' => $page]), $options);
    }
protected function renderPageButton($label, $page, $class, $disabled, $active)
    {
        if ($active) {
            $class .= ' ' . $this->activePageCssClass;
        }
        if ($disabled) {
            $class .= ' ' . $this->disabledPageCssClass;
        }
        $state = $this->getState();
        $state['page'] = $page + 1;
        $jsonState = json_encode($state);

        $class .= ' stateful';
        $class = trim($class);
        $options = ['data-state' => $jsonState, 'class' => $class === '' ? null : $class];

        return Html::tag('li', Html::a($label, $this->pagination->createUrl($page), ['data-page' => $page]), $options);
    }
Renders a page button.
You may override this method to customize the generation of page buttons.

@param string  $label    the text label for the button
@param integer $page     the page number
@param string  $class    the CSS class for the page button.
@param boolean $disabled whether this page button is disabled
@param boolean $active   whether this page button is active

@return string the rendering result