class BootstrapThreePresenter implements Presenter (View source)

Traits

Properties

protected Paginator $paginator The paginator implementation.
protected array $window The URL window data structure.

Methods

string
getPreviousButton(string $text = '«')

Get the previous page pagination element.

string
getNextButton(string $text = '»')

Get the next page pagination element.

string
getLinks()

Render the actual link slider.

string
getUrlLinks(array $urls)

Get the links for the URLs in the given array.

string
getPageLinkWrapper(string $url, int $page, string|null $rel = null)

Get HTML wrapper for a page link.

void
__construct(Paginator $paginator, UrlWindow $window = null)

Create a new Bootstrap presenter instance.

bool
hasPages()

Determine if the underlying paginator being presented has pages to show.

string
render()

Convert the URL window into Bootstrap HTML.

string
getAvailablePageWrapper(string $url, int $page, string|null $rel = null)

Get HTML wrapper for an available page link.

string
getDisabledTextWrapper(string $text)

Get HTML wrapper for disabled text.

string
getActivePageWrapper(string $text)

Get HTML wrapper for active text.

string
getDots()

Get a pagination "dot" element.

int
currentPage()

Get the current page from the paginator.

int
lastPage()

Get the last page from the paginator.

Details

protected string getPreviousButton(string $text = '«')

Get the previous page pagination element.

Parameters

string $text

Return Value

string

protected string getNextButton(string $text = '»')

Get the next page pagination element.

Parameters

string $text

Return Value

string

Render the actual link slider.

Return Value

string

Get the links for the URLs in the given array.

Parameters

array $urls

Return Value

string

Get HTML wrapper for a page link.

Parameters

string $url
int $page
string|null $rel

Return Value

string

void __construct(Paginator $paginator, UrlWindow $window = null)

Create a new Bootstrap presenter instance.

Parameters

Paginator $paginator
UrlWindow $window

Return Value

void

bool hasPages()

Determine if the underlying paginator being presented has pages to show.

Return Value

bool

string render()

Convert the URL window into Bootstrap HTML.

Return Value

string

protected string getAvailablePageWrapper(string $url, int $page, string|null $rel = null)

Get HTML wrapper for an available page link.

Parameters

string $url
int $page
string|null $rel

Return Value

string

protected string getDisabledTextWrapper(string $text)

Get HTML wrapper for disabled text.

Parameters

string $text

Return Value

string

protected string getActivePageWrapper(string $text)

Get HTML wrapper for active text.

Parameters

string $text

Return Value

string

protected string getDots()

Get a pagination "dot" element.

Return Value

string

protected int currentPage()

Get the current page from the paginator.

Return Value

int

protected int lastPage()

Get the last page from the paginator.

Return Value

int