@@ -126,6 +126,37 @@ export class UUIPaginationElement extends LitElement {
126126 @property ( { reflect : true , attribute : 'aria-label' } )
127127 ariaLabel = '' ;
128128
129+ /**
130+ * This property is used to generate the name of the first button
131+ * @type {string }
132+ * @attr
133+ */
134+ @property ( )
135+ firstLabel : string = 'First' ;
136+
137+ /**
138+ * This property is used to generate the name of the previous button
139+ * @type {string }
140+ * @attr
141+ */
142+ @property ( )
143+ previousLabel : string = 'Previous' ;
144+
145+ /**
146+ * This property is used to generate the name of the next button
147+ * @type {string }
148+ * @attr
149+ */
150+ @property ( )
151+ nextLabel : string = 'Next' ;
152+ /**
153+ * This property is used to generate the name of the last button
154+ * @type {string }
155+ * @attr
156+ */
157+ @property ( )
158+ lastLabel : string = 'Last' ;
159+
129160 private _total = 100 ;
130161
131162 /**
@@ -214,11 +245,9 @@ export class UUIPaginationElement extends LitElement {
214245 look= "outline"
215246 class = "nav"
216247 role = "listitem"
217- label = "Go to first page"
248+ label = ${ this . firstLabel }
218249 ?dis abled= ${ this . _current === 1 }
219- @click = ${ ( ) => this . goToPage ( 1 ) } >
220- First
221- </ uui- butto n> ` ;
250+ @click = ${ ( ) => this . goToPage ( 1 ) } > </ uui- butto n> ` ;
222251 }
223252
224253 protected renderPrevious ( ) {
@@ -227,11 +256,9 @@ export class UUIPaginationElement extends LitElement {
227256 look= "outline"
228257 class = "nav"
229258 role = "listitem"
230- label = "Go to previous page"
259+ label = ${ this . previousLabel }
231260 ?dis abled= ${ this . _current === 1 }
232- @click = ${ this . goToPreviousPage } >
233- Previous
234- </ uui- butto n> ` ;
261+ @click = ${ this . goToPreviousPage } > </ uui- butto n> ` ;
235262 }
236263
237264 protected renderNext ( ) {
@@ -240,11 +267,9 @@ export class UUIPaginationElement extends LitElement {
240267 look= "outline"
241268 role = "listitem"
242269 class = "nav"
243- label = "Go to next page"
270+ label = ${ this . nextLabel }
244271 ?dis abled= ${ this . _current === this . total }
245- @click = ${ this . goToNextPage } >
246- Next
247- </ uui- butto n> ` ;
272+ @click = ${ this . goToNextPage } > </ uui- butto n> ` ;
248273 }
249274
250275 protected renderLast ( ) {
@@ -254,11 +279,9 @@ export class UUIPaginationElement extends LitElement {
254279 look= "outline"
255280 role = "listitem"
256281 class = "nav"
257- label = "Go to last page"
282+ label = ${ this . lastLabel }
258283 ?dis abled= ${ this . total === this . _current }
259- @click = ${ ( ) => this . goToPage ( this . total ) } >
260- Last
261- </ uui- butto n>
284+ @click = ${ ( ) => this . goToPage ( this . total ) } > </ uui- butto n>
262285 ` ;
263286 }
264287
0 commit comments