@wcardinal/wcardinal-ui 0.407.2 → 0.408.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -141,16 +141,56 @@ export declare class DPagination<THEME extends DThemePagination = DThemePaginati
141
141
  protected get buttonLast(): DButton<string> | null;
142
142
  protected newButtonLast(): DButton<string> | null;
143
143
  protected onButtonLastActive(): void;
144
- protected moveTo(index: number): void;
144
+ /**
145
+ * Goes to the last page.
146
+ * Unlike {@link #value}, this method emits the change event if silently is not true.
147
+ *
148
+ * @param silently true to suppress the change event
149
+ * @returns true if succeeded.
150
+ */
151
+ goToLast(silently?: boolean): boolean;
152
+ /**
153
+ * Goes to the given page.
154
+ * Unlike {@link #value}, this method emits the change event if silently is not true.
155
+ *
156
+ * @param index a page index
157
+ * @param silently true to suppress the change event
158
+ * @returns this
159
+ */
160
+ goTo(index: number, silently?: boolean): boolean;
145
161
  protected get buttonNext(): DButton<string> | null;
146
162
  protected newButtonNext(): DButton<string> | null;
147
163
  protected onButtonNextActive(): void;
164
+ /**
165
+ * Goes to the next page.
166
+ * Unlike {@link #value}, this method emits the change event if silently is not true.
167
+ *
168
+ * @param silently true to suppress the change event
169
+ * @returns true if succeeded.
170
+ */
171
+ goToNext(silently?: boolean): boolean;
148
172
  protected get buttonPrevious(): DButton<string> | null;
149
173
  protected newButtonPrevious(): DButton<string> | null;
150
174
  protected onButtonPreviousActive(): void;
175
+ /**
176
+ * Goes to the previous page.
177
+ * Unlike {@link #value}, this method emits the change event if silently is not true.
178
+ *
179
+ * @param silently true to suppress the change event
180
+ * @returns true if succeeded.
181
+ */
182
+ goToPrevious(silently?: boolean): boolean;
151
183
  protected get buttonTop(): DButton<string> | null;
152
184
  protected newButtonTop(): DButton<string> | null;
153
185
  protected onButtonTopActive(): void;
186
+ /**
187
+ * Goes to the top page.
188
+ * Unlike {@link #value}, this method emits the change event if silently is not true.
189
+ *
190
+ * @param silently true to suppress the change event
191
+ * @returns true if succeeded.
192
+ */
193
+ goToTop(silently?: boolean): boolean;
154
194
  protected newButtonPage(): DButton<number>;
155
195
  protected get buttonPages0(): DButton<number>[];
156
196
  protected newButtonPages0(): DButton<number>[];
@@ -219,16 +219,38 @@ var DPagination = /** @class */ (function (_super) {
219
219
  return null;
220
220
  };
221
221
  DPagination.prototype.onButtonLastActive = function () {
222
- this.moveTo(this._size - 1);
222
+ this.goToLast();
223
223
  };
224
- DPagination.prototype.moveTo = function (index) {
224
+ /**
225
+ * Goes to the last page.
226
+ * Unlike {@link #value}, this method emits the change event if silently is not true.
227
+ *
228
+ * @param silently true to suppress the change event
229
+ * @returns true if succeeded.
230
+ */
231
+ DPagination.prototype.goToLast = function (silently) {
232
+ return this.goTo(this._size - 1, silently);
233
+ };
234
+ /**
235
+ * Goes to the given page.
236
+ * Unlike {@link #value}, this method emits the change event if silently is not true.
237
+ *
238
+ * @param index a page index
239
+ * @param silently true to suppress the change event
240
+ * @returns this
241
+ */
242
+ DPagination.prototype.goTo = function (index, silently) {
225
243
  if (0 <= index && index < this._size && this._value !== index) {
226
244
  var oldIndex = this._value;
227
245
  this._value = index;
228
- this.emit("change", index, oldIndex, this);
246
+ if (silently !== true) {
247
+ this.emit("change", index, oldIndex, this);
248
+ }
229
249
  this.toDirty();
230
250
  DApplications.update(this);
251
+ return true;
231
252
  }
253
+ return false;
232
254
  };
233
255
  Object.defineProperty(DPagination.prototype, "buttonNext", {
234
256
  get: function () {
@@ -256,7 +278,17 @@ var DPagination = /** @class */ (function (_super) {
256
278
  return null;
257
279
  };
258
280
  DPagination.prototype.onButtonNextActive = function () {
259
- this.moveTo(this._value + 1);
281
+ this.goToNext();
282
+ };
283
+ /**
284
+ * Goes to the next page.
285
+ * Unlike {@link #value}, this method emits the change event if silently is not true.
286
+ *
287
+ * @param silently true to suppress the change event
288
+ * @returns true if succeeded.
289
+ */
290
+ DPagination.prototype.goToNext = function (silently) {
291
+ return this.goTo(this._value + 1, silently);
260
292
  };
261
293
  Object.defineProperty(DPagination.prototype, "buttonPrevious", {
262
294
  get: function () {
@@ -284,7 +316,17 @@ var DPagination = /** @class */ (function (_super) {
284
316
  return null;
285
317
  };
286
318
  DPagination.prototype.onButtonPreviousActive = function () {
287
- this.moveTo(this._value - 1);
319
+ this.goToPrevious();
320
+ };
321
+ /**
322
+ * Goes to the previous page.
323
+ * Unlike {@link #value}, this method emits the change event if silently is not true.
324
+ *
325
+ * @param silently true to suppress the change event
326
+ * @returns true if succeeded.
327
+ */
328
+ DPagination.prototype.goToPrevious = function (silently) {
329
+ return this.goTo(this._value - 1, silently);
288
330
  };
289
331
  Object.defineProperty(DPagination.prototype, "buttonTop", {
290
332
  get: function () {
@@ -312,7 +354,17 @@ var DPagination = /** @class */ (function (_super) {
312
354
  return null;
313
355
  };
314
356
  DPagination.prototype.onButtonTopActive = function () {
315
- this.moveTo(0);
357
+ this.goToTop();
358
+ };
359
+ /**
360
+ * Goes to the top page.
361
+ * Unlike {@link #value}, this method emits the change event if silently is not true.
362
+ *
363
+ * @param silently true to suppress the change event
364
+ * @returns true if succeeded.
365
+ */
366
+ DPagination.prototype.goToTop = function (silently) {
367
+ return this.goTo(0, silently);
316
368
  };
317
369
  DPagination.prototype.newButtonPage = function () {
318
370
  var _this = this;
@@ -402,7 +454,7 @@ var DPagination = /** @class */ (function (_super) {
402
454
  DPagination.prototype.onButtonPageActive = function (button) {
403
455
  var text = button.text.value;
404
456
  if (isNumber(text)) {
405
- this.moveTo(text - 1);
457
+ this.goTo(text - 1);
406
458
  if (button.state.isFocused) {
407
459
  button.state.isHovered = false;
408
460
  this.page.focus();
@@ -1 +1 @@
1
- {"version":3,"file":"d-pagination.js","sourceRoot":"","sources":["../../../src/main/typescript/wcardinal/ui/d-pagination.ts"],"names":[],"mappings":"AAAA;;;GAGG;;AAGH,OAAO,EACN,iBAAiB,EAGjB,MAAM,uBAAuB,CAAC;AAC/B,OAAO,EAAE,eAAe,EAAE,MAAM,qBAAqB,CAAC;AACtD,OAAO,EA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C,GAAG,IAAI,EAAE,EAAE,CAAC,EAAE;oBAC1D,IAAI,CAAC,QAAQ,CAAC,YAAY,CAAC,CAAC,CAAC,CAAC,CAAC;iBAC/B;gBACD,IAAI,CAAC,QAAQ,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC;gBAC1B,MAAM;SACP;QAED,IAAM,UAAU,GAAG,IAAI,CAAC,UAAU,CAAC;QACnC,IAAI,UAAU,IAAI,IAAI,EAAE;YACvB,UAAU,CAAC,KAAK,CAAC,SAAS,GAAG,KAAK,GAAG,IAAI,GAAG,CAAC,CAAC;SAC9C;QACD,IAAM,UAAU,GAAG,IAAI,CAAC,UAAU,CAAC;QACnC,IAAI,UAAU,IAAI,IAAI,EAAE;YACvB,UAAU,CAAC,KAAK,CAAC,SAAS,GAAG,KAAK,GAAG,IAAI,GAAG,CAAC,CAAC;SAC9C;IACF,CAAC;IAES,8BAAQ,GAAlB,UAAmB,MAA0B,EAAE,KAAa;QAC3D,MAAM,CAAC,IAAI,GAAG,KAAK,GAAG,CAAC,CAAC;QACxB,MAAM,CAAC,IAAI,EAAE,CAAC;IACf,CAAC;IAES,8BAAQ,GAAlB,UAAmB,MAA0B;QAC5C,MAAM,CAAC,IAAI,EAAE,CAAC;IACf,CAAC;IAES,8BAAQ,GAAlB,UAAmB,IAAqB,EAAE,IAAY,EAAE,EAAU;QACjE,IAAI,CAAC,IAAI,EAAE,CAAC;IACb,CAAC;IAES,8BAAQ,GAAlB,UAAmB,IAAqB;QACvC,IAAI,CAAC,IAAI,EAAE,CAAC;IACb,CAAC;IAES,6BAAO,GAAjB;QACC,OAAO,aAAa,CAAC;IACtB,CAAC;IACF,kBAAC;AAAD,CAAC,AAxxBD,CAGU,iBAAiB,GAqxB1B","sourcesContent":["/*\n * Copyright (C) 2019 Toshiba Corporation\n * SPDX-License-Identifier: Apache-2.0\n */\n\nimport { DButton } from \"./d-button\";\nimport {\n\tDLayoutHorizontal,\n\tDLayoutHorizontalOptions,\n\tDThemeLayoutHorizontal\n} from \"./d-layout-horizontal\";\nimport { DPaginationDots } from \"./d-pagination-dots\";\nimport { DPaginationButtonLast, DPaginationButtonLastOptions } from \"./d-pagination-button-last\";\nimport { DPaginationButtonNext, DPaginationButtonNextOptions } from \"./d-pagination-button-next\";\nimport { DPaginationButtonPage, DPaginationButtonPageOptions } from \"./d-pagination-button-page\";\nimport {\n\tDPaginationButtonPrevious,\n\tDPaginationButtonPreviousOptions\n} from \"./d-pagination-button-previous\";\nimport { DPaginationButtonTop, DPaginationButtonTopOptions } from \"./d-pagination-button-top\";\nimport { isNumber } from \"./util/is-number\";\nimport { DPaginationPage, DPaginationPageOptions } from \"./d-pagination-page\";\nimport { DLayoutSpace, DLayoutSpaceOptions } from \"./d-layout-space\";\nimport { DImageBase } from \"./d-image-base\";\nimport { DApplications } from \"./d-applications\";\n\nexport interface DPaginationButtonOptions {\n\t/**\n\t * {@link DPagination} top button options.\n\t */\n\ttop?: DPaginationButtonTopOptions | boolean | null;\n\n\t/**\n\t * {@link DPagination} previous button options.\n\t */\n\tprevious?: DPaginationButtonPreviousOptions | boolean | null;\n\n\t/**\n\t * {@link DPagination} page button options.\n\t */\n\tpage?: DPaginationButtonPageOptions;\n\n\t/**\n\t * {@link DPagination} next button options.\n\t */\n\tnext?: DPaginationButtonNextOptions | boolean | null;\n\n\t/**\n\t * {@link DPagination} last button options.\n\t */\n\tlast?: DPaginationButtonLastOptions | boolean | null;\n\n\t/**\n\t * A space between page buttons and next / previous buttons.\n\t */\n\tspace?: DLayoutSpaceOptions | boolean | number | null;\n}\n\nexport interface DPaginationOptions<THEME extends DThemePagination>\n\textends DLayoutHorizontalOptions<THEME> {\n\t/**\n\t * An index number of a selected page.\n\t */\n\tvalue?: number;\n\n\t/**\n\t * An index number of a selected page.\n\t *\n\t * @deprecated in favor of {@link value}.\n\t */\n\tselected?: number;\n\n\t/**\n\t * A total number of pages.\n\t */\n\tsize?: number;\n\n\t/**\n\t * A total number of pages.\n\t *\n\t * @deprecated in favor of {@link size};\n\t */\n\ttotal?: number;\n\n\t/**\n\t * {@link DPagination} button options.\n\t */\n\tbutton?: DPaginationButtonOptions;\n\n\t/**\n\t * {@link DPagination} page options.\n\t */\n\tpage?: DPaginationPageOptions;\n}\n\nexport interface DThemePagination extends DThemeLayoutHorizontal {\n\tgetButtonSpace(): number;\n}\n\nexport class DPagination<\n\tTHEME extends DThemePagination = DThemePagination,\n\tOPTIONS extends DPaginationOptions<THEME> = DPaginationOptions<THEME>\n> extends DLayoutHorizontal<THEME, OPTIONS> {\n\tprotected _size: number;\n\tprotected _value: number;\n\n\tprotected _buttonTop?: DButton<string> | null;\n\tprotected _buttonPrevious?: DButton<string> | null;\n\tprotected _spaceLeft?: DLayoutSpace | null;\n\tprotected _dots0?: DPaginationDots;\n\tprotected _buttonPages0?: DButton<number>[];\n\tprotected _page?: DPaginationPage;\n\tprotected _buttonPages1?: DButton<number>[];\n\tprotected _dots1?: DPaginationDots;\n\tprotected _spaceRight?: DLayoutSpace | null;\n\tprotected _buttonNext?: DButton<string> | null;\n\tprotected _buttonLast?: DButton<string> | null;\n\n\tconstructor(options?: OPTIONS) {\n\t\tsuper(options);\n\n\t\tif (options != null) {\n\t\t\tthis._size = options.size ?? options.total ?? 10;\n\t\t\tthis._value = options.value ?? options.selected ?? 0;\n\t\t} else {\n\t\t\tthis._size = 10;\n\t\t\tthis._value = 0;\n\t\t}\n\n\t\tconst buttonTop = this.buttonTop;\n\t\tif (buttonTop != null) {\n\t\t\tthis.addChild(buttonTop);\n\t\t}\n\t\tconst buttonPrevious = this.buttonPrevious;\n\t\tif (buttonPrevious != null) {\n\t\t\tthis.addChild(buttonPrevious);\n\t\t}\n\t\tconst spaceLeft = this.spaceLeft;\n\t\tif (spaceLeft != null) {\n\t\t\tthis.addChild(spaceLeft);\n\t\t}\n\t\tconst buttonPages0 = this.buttonPages0;\n\t\tconst buttonPages0Length = buttonPages0.length;\n\t\tthis.addChild(buttonPages0[0]);\n\t\tthis.addChild(this.dots0);\n\t\tfor (let i = 1; i < buttonPages0Length; ++i) {\n\t\t\tthis.addChild(buttonPages0[i]);\n\t\t}\n\t\tthis.addChild(this.page);\n\t\tconst buttonPages1 = this.buttonPages1;\n\t\tconst buttonPages1Length = buttonPages1.length;\n\t\tfor (let i = 0, imax = buttonPages1Length - 1; i < imax; ++i) {\n\t\t\tthis.addChild(buttonPages1[i]);\n\t\t}\n\t\tthis.addChild(this.dots1);\n\t\tthis.addChild(buttonPages1[buttonPages1Length - 1]);\n\t\tconst spaceRight = this.spaceRight;\n\t\tif (spaceRight != null) {\n\t\t\tthis.addChild(spaceRight);\n\t\t}\n\t\tconst buttonNext = this.buttonNext;\n\t\tif (buttonNext != null) {\n\t\t\tthis.addChild(buttonNext);\n\t\t}\n\t\tconst buttonLast = this.buttonLast;\n\t\tif (buttonLast != null) {\n\t\t\tthis.addChild(buttonLast);\n\t\t}\n\t}\n\n\t/**\n\t * Sets a value that is an index of a current page.\n\t *\n\t * @param value a value that is an index of a page\n\t */\n\tset value(value: number) {\n\t\tif (0 <= value && value < this._size && this._value !== value) {\n\t\t\tthis._value = value;\n\t\t\tthis.toDirty();\n\t\t\tDApplications.update(this);\n\t\t}\n\t}\n\n\t/**\n\t * Returns a value that is an index of a current page.\n\t *\n\t * @returns a value that is an index of a selected page.\n\t */\n\tget value(): number {\n\t\treturn this._value;\n\t}\n\n\t/**\n\t * Selects a page.\n\t *\n\t * @param index an index of a page\n\t * @deprecated in favor of {@link value}.\n\t */\n\tset selected(index: number) {\n\t\tthis.value = index;\n\t}\n\n\t/**\n\t * Returns an index of the selected page.\n\t *\n\t * @returns an index of the selected page.\n\t * @deprecated in favor of {@link value}.\n\t */\n\tget selected(): number {\n\t\treturn this.value;\n\t}\n\n\t/**\n\t * Sets a number of total pages.\n\t *\n\t * @param size a number of pages\n\t */\n\tset size(size: number) {\n\t\tif (0 <= size && this._size !== size) {\n\t\t\tthis._size = size;\n\t\t\tif (size === 0) {\n\t\t\t\tthis._value = -1;\n\t\t\t} else {\n\t\t\t\tthis._value = Math.max(0, Math.min(this._size - 1, this._value));\n\t\t\t}\n\t\t\tthis.toDirty();\n\t\t\tDApplications.update(this);\n\t\t}\n\t}\n\n\t/**\n\t * Returns a number of total pages.\n\t *\n\t * @returns a number of total pages.\n\t */\n\tget size(): number {\n\t\treturn this._size;\n\t}\n\n\t/**\n\t * Sets a number of total pages.\n\t *\n\t * @param total a number of pages\n\t * @deprecated in favor of {@link size}\n\t */\n\tset total(total: number) {\n\t\tthis.size = total;\n\t}\n\n\t/**\n\t * Returns a number of total pages.\n\t *\n\t * @returns a number of total pages.\n\t * @deprecated in favor of {@link size}\n\t */\n\tget total(): number {\n\t\treturn this.size;\n\t}\n\n\tprotected get dots0(): DPaginationDots {\n\t\tlet result = this._dots0;\n\t\tif (result == null) {\n\t\t\tresult = this.newDots();\n\t\t\tthis._dots0 = result;\n\t\t}\n\t\treturn result;\n\t}\n\n\tprotected get dots1(): DPaginationDots {\n\t\tlet result = this._dots1;\n\t\tif (result == null) {\n\t\t\tresult = this.newDots();\n\t\t\tthis._dots1 = result;\n\t\t}\n\t\treturn result;\n\t}\n\n\tprotected newDots(): DPaginationDots {\n\t\treturn new DPaginationDots();\n\t}\n\n\tprotected get buttonLast(): DButton<string> | null {\n\t\tlet result = this._buttonLast;\n\t\tif (result === undefined) {\n\t\t\tresult = this.newButtonLast();\n\t\t\tthis._buttonLast = result;\n\t\t}\n\t\treturn result;\n\t}\n\n\tprotected newButtonLast(): DButton<string> | null {\n\t\tconst last = this._options?.button?.last;\n\t\tif (last !== null && last !== false && last !== undefined) {\n\t\t\tconst result = new DPaginationButtonLast(last !== true ? last : undefined);\n\t\t\tresult.on(\"active\", () => {\n\t\t\t\tthis.onButtonLastActive();\n\t\t\t});\n\t\t\treturn result;\n\t\t}\n\t\treturn null;\n\t}\n\n\tprotected onButtonLastActive(): void {\n\t\tthis.moveTo(this._size - 1);\n\t}\n\n\tprotected moveTo(index: number): void {\n\t\tif (0 <= index && index < this._size && this._value !== index) {\n\t\t\tconst oldIndex = this._value;\n\t\t\tthis._value = index;\n\t\t\tthis.emit(\"change\", index, oldIndex, this);\n\t\t\tthis.toDirty();\n\t\t\tDApplications.update(this);\n\t\t}\n\t}\n\n\tprotected get buttonNext(): DButton<string> | null {\n\t\tlet result = this._buttonNext;\n\t\tif (result === undefined) {\n\t\t\tresult = this.newButtonNext();\n\t\t\tthis._buttonNext = result;\n\t\t}\n\t\treturn result;\n\t}\n\n\tprotected newButtonNext(): DButton<string> | null {\n\t\tconst next = this._options?.button?.next;\n\t\tif (next !== null && next !== false) {\n\t\t\tconst result = new DPaginationButtonNext(next !== true ? next : undefined);\n\t\t\tresult.on(\"active\", (): void => {\n\t\t\t\tthis.onButtonNextActive();\n\t\t\t});\n\t\t\treturn result;\n\t\t}\n\t\treturn null;\n\t}\n\n\tprotected onButtonNextActive(): void {\n\t\tthis.moveTo(this._value + 1);\n\t}\n\n\tprotected get buttonPrevious(): DButton<string> | null {\n\t\tlet result = this._buttonPrevious;\n\t\tif (result === undefined) {\n\t\t\tresult = this.newButtonPrevious();\n\t\t\tthis._buttonPrevious = result;\n\t\t}\n\t\treturn result;\n\t}\n\n\tprotected newButtonPrevious(): DButton<string> | null {\n\t\tconst previous = this._options?.button?.previous;\n\t\tif (previous !== null && previous !== false) {\n\t\t\tconst result = new DPaginationButtonPrevious(previous !== true ? previous : undefined);\n\t\t\tresult.on(\"active\", (): void => {\n\t\t\t\tthis.onButtonPreviousActive();\n\t\t\t});\n\t\t\treturn result;\n\t\t}\n\t\treturn null;\n\t}\n\n\tprotected onButtonPreviousActive(): void {\n\t\tthis.moveTo(this._value - 1);\n\t}\n\n\tprotected get buttonTop(): DButton<string> | null {\n\t\tlet result = this._buttonTop;\n\t\tif (result === undefined) {\n\t\t\tresult = this.newButtonTop();\n\t\t\tthis._buttonTop = result;\n\t\t}\n\t\treturn result;\n\t}\n\n\tprotected newButtonTop(): DButton<string> | null {\n\t\tconst top = this._options?.button?.top;\n\t\tif (top !== null && top !== false && top !== undefined) {\n\t\t\tconst result = new DPaginationButtonTop(top !== true ? top : undefined);\n\t\t\tresult.on(\"active\", (): void => {\n\t\t\t\tthis.onButtonTopActive();\n\t\t\t});\n\t\t\treturn result;\n\t\t}\n\t\treturn null;\n\t}\n\n\tprotected onButtonTopActive(): void {\n\t\tthis.moveTo(0);\n\t}\n\n\tprotected newButtonPage(): DButton<number> {\n\t\tconst result = new DPaginationButtonPage(this._options?.button?.page);\n\t\tresult.on(\"active\", (): void => {\n\t\t\tthis.onButtonPageActive(result);\n\t\t});\n\t\treturn result;\n\t}\n\n\tprotected get buttonPages0(): DButton<number>[] {\n\t\tlet result = this._buttonPages0;\n\t\tif (result == null) {\n\t\t\tresult = this.newButtonPages0();\n\t\t\tthis._buttonPages0 = result;\n\t\t}\n\t\treturn result;\n\t}\n\n\tprotected newButtonPages0(): DButton<number>[] {\n\t\treturn [\n\t\t\tthis.newButtonPage(),\n\t\t\tthis.newButtonPage(),\n\t\t\tthis.newButtonPage(),\n\t\t\tthis.newButtonPage()\n\t\t];\n\t}\n\n\tprotected allocButtonPages0(size: number): void {\n\t\tconst buttonPages0 = this.buttonPages0;\n\t\tconst buttonPages0Length = buttonPages0.length;\n\t\tconst index = this.getChildIndex(buttonPages0[buttonPages0Length - 1]) + 1;\n\t\tfor (let i = 0, imax = size - buttonPages0Length; i < imax; ++i) {\n\t\t\tconst buttonPage = this.newButtonPage();\n\t\t\tthis.addChildAt(buttonPage, index + i);\n\t\t\tbuttonPages0.push(buttonPage);\n\t\t}\n\t}\n\n\tprotected get buttonPages1(): DButton<number>[] {\n\t\tlet result = this._buttonPages1;\n\t\tif (result == null) {\n\t\t\tresult = this.newButtonPages1();\n\t\t\tthis._buttonPages1 = result;\n\t\t}\n\t\treturn result;\n\t}\n\n\tprotected newButtonPages1(): DButton<number>[] {\n\t\treturn [\n\t\t\tthis.newButtonPage(),\n\t\t\tthis.newButtonPage(),\n\t\t\tthis.newButtonPage(),\n\t\t\tthis.newButtonPage()\n\t\t];\n\t}\n\n\tprotected allocButtonPages1(size: number): void {\n\t\tconst buttonPages1 = this.buttonPages1;\n\t\tconst buttonPages1Length = buttonPages1.length;\n\t\tconst index = this.getChildIndex(buttonPages1[0]);\n\t\tfor (let i = 0, imax = size - buttonPages1Length; i < imax; ++i) {\n\t\t\tconst buttonPage = this.newButtonPage();\n\t\t\tthis.addChildAt(buttonPage, index);\n\t\t\tbuttonPages1.unshift(buttonPage);\n\t\t}\n\t}\n\n\tprotected get page(): DPaginationPage {\n\t\tlet result = this._page;\n\t\tif (result == null) {\n\t\t\tresult = this.newPage();\n\t\t\tthis._page = result;\n\t\t}\n\t\treturn result;\n\t}\n\n\tprotected newPage(): DPaginationPage {\n\t\treturn new DPaginationPage(this._options?.page);\n\t}\n\n\tprotected onButtonPageActive(button: DButton<number>): void {\n\t\tconst text = button.text.value;\n\t\tif (isNumber(text)) {\n\t\t\tthis.moveTo(text - 1);\n\t\t\tif (button.state.isFocused) {\n\t\t\t\tbutton.state.isHovered = false;\n\t\t\t\tthis.page.focus();\n\t\t\t}\n\t\t}\n\t}\n\n\tprotected get spaceLeft(): DLayoutSpace | null {\n\t\tlet result = this._spaceLeft;\n\t\tif (result === undefined) {\n\t\t\tresult = this.newSpaceLeft();\n\t\t\tthis._spaceLeft = result;\n\t\t}\n\t\treturn result;\n\t}\n\n\tprotected newSpaceLeft(): DLayoutSpace | null {\n\t\tif (this.buttonTop != null || this.buttonPrevious != null) {\n\t\t\treturn this.newSpace();\n\t\t}\n\t\treturn null;\n\t}\n\n\tprotected get spaceRight(): DLayoutSpace | null {\n\t\tlet result = this._spaceRight;\n\t\tif (result === undefined) {\n\t\t\tresult = this.newSpaceRight();\n\t\t\tthis._spaceRight = result;\n\t\t}\n\t\treturn result;\n\t}\n\n\tprotected newSpaceRight(): DLayoutSpace | null {\n\t\tif (this.buttonLast != null || this.buttonNext != null) {\n\t\t\treturn this.newSpace();\n\t\t}\n\t\treturn null;\n\t}\n\n\tprotected newSpace(): DLayoutSpace | null {\n\t\tconst space = this._options?.button?.space;\n\t\tif (space !== null && space !== false) {\n\t\t\tif (space === true || space === undefined) {\n\t\t\t\treturn new DLayoutSpace({\n\t\t\t\t\tweight: 1\n\t\t\t\t});\n\t\t\t} else if (isNumber(space)) {\n\t\t\t\treturn new DLayoutSpace({\n\t\t\t\t\twidth: space\n\t\t\t\t});\n\t\t\t} else {\n\t\t\t\treturn new DLayoutSpace(space);\n\t\t\t}\n\t\t}\n\t\treturn null;\n\t}\n\n\tprotected onReflow(): void {\n\t\tthis.update();\n\t\tsuper.onReflow();\n\t}\n\n\tprotected update(): void {\n\t\tconst size = this._size;\n\t\tconst value = this._value;\n\t\tif (size <= 0) {\n\t\t\tthis.doUpdate0(value, size);\n\t\t} else {\n\t\t\tif (this._auto.width.isOn) {\n\t\t\t\tthis.doUpdate2(value, size, 0, 0, 0, 0);\n\t\t\t} else {\n\t\t\t\tthis.doUpdate1(value, size);\n\t\t\t}\n\t\t}\n\t}\n\n\tprotected doUpdate0(value: number, size: number): void {\n\t\tconst buttonTop = this.buttonTop;\n\t\tif (buttonTop != null) {\n\t\t\tbuttonTop.state.isEnabled = false;\n\t\t}\n\t\tconst buttonPrevious = this.buttonPrevious;\n\t\tif (buttonPrevious != null) {\n\t\t\tbuttonPrevious.state.isEnabled = false;\n\t\t}\n\n\t\tthis.hideDots(this.dots0);\n\n\t\tconst buttonPages0 = this.buttonPages0;\n\t\tfor (let i = 0, imax = buttonPages0.length; i < imax; ++i) {\n\t\t\tthis.hidePage(buttonPages0[i]);\n\t\t}\n\n\t\tthis.hidePage(this.page);\n\n\t\tconst buttonPages1 = this.buttonPages1;\n\t\tfor (let i = 0, imax = buttonPages1.length; i < imax; ++i) {\n\t\t\tthis.hidePage(buttonPages1[i]);\n\t\t}\n\n\t\tthis.hideDots(this.dots1);\n\n\t\tconst buttonNext = this.buttonNext;\n\t\tif (buttonNext != null) {\n\t\t\tbuttonNext.state.isEnabled = false;\n\t\t}\n\t\tconst buttonLast = this.buttonLast;\n\t\tif (buttonLast) {\n\t\t\tbuttonLast.state.isEnabled = false;\n\t\t}\n\t}\n\n\tprotected doUpdate1(value: number, size: number): void {\n\t\tlet required = 0;\n\t\tlet nrequired = 0;\n\n\t\tconst buttonTop = this.buttonTop;\n\t\tif (buttonTop != null) {\n\t\t\trequired += buttonTop.width;\n\t\t\tnrequired += 1;\n\t\t}\n\t\tconst buttonPrevious = this.buttonPrevious;\n\t\tif (buttonPrevious != null) {\n\t\t\trequired += buttonPrevious.width;\n\t\t\tnrequired += 1;\n\t\t}\n\n\t\tconst spaceLeft = this.spaceLeft;\n\t\tif (spaceLeft != null) {\n\t\t\tif (spaceLeft.weight < 0) {\n\t\t\t\trequired += spaceLeft.width;\n\t\t\t}\n\t\t\tnrequired += 1;\n\t\t}\n\n\t\tconst page = this.page;\n\t\trequired += page.width;\n\t\tnrequired += 1;\n\n\t\tconst spaceRight = this.spaceRight;\n\t\tif (spaceRight != null) {\n\t\t\tif (spaceRight.weight < 0) {\n\t\t\t\trequired += spaceRight.width;\n\t\t\t}\n\t\t\tnrequired += 1;\n\t\t}\n\n\t\tconst buttonNext = this.buttonNext;\n\t\tif (buttonNext != null) {\n\t\t\trequired += buttonNext.width;\n\t\t\tnrequired += 1;\n\t\t}\n\t\tconst buttonLast = this.buttonLast;\n\t\tif (buttonLast) {\n\t\t\trequired += buttonLast.width;\n\t\t\tnrequired += 1;\n\t\t}\n\n\t\tconst marginHorizontal = this._margin.horizontal;\n\t\tif (2 <= nrequired) {\n\t\t\trequired += (nrequired - 1) * marginHorizontal;\n\t\t}\n\n\t\tconst padding = this.padding;\n\t\tconst space = this.width - (padding.getLeft() + padding.getRight());\n\t\tif (space <= required) {\n\t\t\tthis.doUpdate2(value, size, 4, 4, 0, 0);\n\t\t} else {\n\t\t\tconst buttonPages0 = this.buttonPages0;\n\t\t\tconst buttonPage0Width = buttonPages0[0].width;\n\t\t\tconst nrequired0 = value;\n\t\t\tconst required0 = nrequired0 * (buttonPage0Width + marginHorizontal);\n\n\t\t\tconst buttonPages1 = this.buttonPages1;\n\t\t\tconst buttonPage1Width = buttonPages1[0].width;\n\t\t\tconst nrequired1 = size - (value + 1);\n\t\t\tconst required1 = nrequired1 * (buttonPage1Width + marginHorizontal);\n\n\t\t\tif (required + required0 + required1 <= space) {\n\t\t\t\tthis.doUpdate2(value, size, 0, 0, 0, 0);\n\t\t\t} else {\n\t\t\t\tconst dots1 = this.dots1;\n\t\t\t\tconst dots1Width = dots1.width;\n\t\t\t\tconst dots0 = this.dots0;\n\t\t\t\tconst dots0Width = dots0.width;\n\t\t\t\tconst m0 = marginHorizontal + buttonPage0Width;\n\t\t\t\tconst m1 = marginHorizontal + buttonPage1Width;\n\t\t\t\tconst required0n = dots0Width + m0;\n\t\t\t\tconst required1n = dots1Width + m1;\n\t\t\t\tconst required0m = required0n + m0;\n\t\t\t\tconst required1m = required1n + m1;\n\t\t\t\tif (required0 <= required1) {\n\t\t\t\t\tif (3 <= nrequired1 && required + required0 + required1m <= space) {\n\t\t\t\t\t\tconst l = space - (required + required0 + required1m);\n\t\t\t\t\t\tconst n1 = Math.floor(l / m1);\n\t\t\t\t\t\tthis.doUpdate2(value, size, 0, 1, 0, n1);\n\t\t\t\t\t} else if (\n\t\t\t\t\t\t3 <= nrequired0 &&\n\t\t\t\t\t\t3 <= nrequired1 &&\n\t\t\t\t\t\trequired + required0m + required1m <= space\n\t\t\t\t\t) {\n\t\t\t\t\t\tconst l = space - (required + required0m + required1m);\n\t\t\t\t\t\tconst n1 = Math.floor((l * 0.5) / m1);\n\t\t\t\t\t\tconst n0 = Math.floor((l - n1 * m1) / m0);\n\t\t\t\t\t\tthis.doUpdate2(value, size, 1, 1, n0, n1);\n\t\t\t\t\t} else if (2 <= nrequired1 && required + required0 + required1n <= space) {\n\t\t\t\t\t\tthis.doUpdate2(value, size, 0, 2, 0, 0);\n\t\t\t\t\t} else if (\n\t\t\t\t\t\t3 <= nrequired0 &&\n\t\t\t\t\t\t2 <= nrequired1 &&\n\t\t\t\t\t\trequired + required0m + required1n <= space\n\t\t\t\t\t) {\n\t\t\t\t\t\tconst l = space - (required + required0m + required1n);\n\t\t\t\t\t\tconst n0 = Math.floor(l / m0);\n\t\t\t\t\t\tthis.doUpdate2(value, size, 1, 2, n0, 0);\n\t\t\t\t\t} else if (\n\t\t\t\t\t\t2 <= nrequired0 &&\n\t\t\t\t\t\t2 <= nrequired1 &&\n\t\t\t\t\t\trequired + required0n + required1n <= space\n\t\t\t\t\t) {\n\t\t\t\t\t\tthis.doUpdate2(value, size, 2, 2, 0, 0);\n\t\t\t\t\t} else if (\n\t\t\t\t\t\t1 <= nrequired0 &&\n\t\t\t\t\t\t1 <= nrequired1 &&\n\t\t\t\t\t\trequired + dots0Width + dots1Width <= space\n\t\t\t\t\t) {\n\t\t\t\t\t\tthis.doUpdate2(value, size, 3, 3, 0, 0);\n\t\t\t\t\t} else {\n\t\t\t\t\t\tthis.doUpdate2(value, size, 4, 4, 0, 0);\n\t\t\t\t\t}\n\t\t\t\t} else {\n\t\t\t\t\tif (3 <= nrequired0 && required + required0m + required1 <= space) {\n\t\t\t\t\t\tconst l = space - (required + required0m + required1);\n\t\t\t\t\t\tconst n0 = Math.floor(l / m0);\n\t\t\t\t\t\tthis.doUpdate2(value, size, 1, 0, n0, 0);\n\t\t\t\t\t} else if (\n\t\t\t\t\t\t3 <= nrequired0 &&\n\t\t\t\t\t\t3 <= nrequired1 &&\n\t\t\t\t\t\trequired + required0m + required1m <= space\n\t\t\t\t\t) {\n\t\t\t\t\t\tconst l = space - (required + required0m + required1m);\n\t\t\t\t\t\tconst n0 = Math.floor((l * 0.5) / m0);\n\t\t\t\t\t\tconst n1 = Math.floor((l - n0 * m0) / m1);\n\t\t\t\t\t\tthis.doUpdate2(value, size, 1, 1, n0, n1);\n\t\t\t\t\t} else if (2 <= nrequired0 && required + required0n + required1 <= space) {\n\t\t\t\t\t\tthis.doUpdate2(value, size, 2, 0, 0, 0);\n\t\t\t\t\t} else if (\n\t\t\t\t\t\t2 <= nrequired0 &&\n\t\t\t\t\t\t3 <= nrequired1 &&\n\t\t\t\t\t\trequired + required0n + required1m <= space\n\t\t\t\t\t) {\n\t\t\t\t\t\tconst l = space - (required + required0n + required1m);\n\t\t\t\t\t\tconst n1 = Math.floor(l / m1);\n\t\t\t\t\t\tthis.doUpdate2(value, size, 2, 1, 0, n1);\n\t\t\t\t\t} else if (\n\t\t\t\t\t\t2 <= nrequired0 &&\n\t\t\t\t\t\t2 <= nrequired1 &&\n\t\t\t\t\t\trequired + required0n + required1n <= space\n\t\t\t\t\t) {\n\t\t\t\t\t\tthis.doUpdate2(value, size, 2, 2, 0, 0);\n\t\t\t\t\t} else if (\n\t\t\t\t\t\t1 <= nrequired0 &&\n\t\t\t\t\t\t1 <= nrequired1 &&\n\t\t\t\t\t\trequired + dots0Width + dots1Width <= space\n\t\t\t\t\t) {\n\t\t\t\t\t\tthis.doUpdate2(value, size, 3, 3, 0, 0);\n\t\t\t\t\t} else {\n\t\t\t\t\t\tthis.doUpdate2(value, size, 4, 4, 0, 0);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\tprotected doUpdate2(\n\t\tvalue: number,\n\t\tsize: number,\n\t\tleft: 0 | 1 | 2 | 3 | 4,\n\t\tright: 0 | 1 | 2 | 3 | 4,\n\t\tnleft1: number,\n\t\tnright1: number\n\t): void {\n\t\tconst buttonTop = this.buttonTop;\n\t\tif (buttonTop != null) {\n\t\t\tbuttonTop.state.isEnabled = 0 < value;\n\t\t}\n\t\tconst buttonPrevious = this.buttonPrevious;\n\t\tif (buttonPrevious != null) {\n\t\t\tbuttonPrevious.state.isEnabled = 0 < value;\n\t\t}\n\n\t\tconst buttonPages0 = this.buttonPages0;\n\t\tswitch (left) {\n\t\t\tcase 0:\n\t\t\t\tthis.hideDots(this.dots0);\n\t\t\t\tthis.allocButtonPages0(value);\n\t\t\t\tfor (let i = 0, imax = buttonPages0.length; i < imax; ++i) {\n\t\t\t\t\tif (i < value) {\n\t\t\t\t\t\tthis.showPage(buttonPages0[i], i);\n\t\t\t\t\t} else {\n\t\t\t\t\t\tthis.hidePage(buttonPages0[i]);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\tbreak;\n\t\t\tcase 1:\n\t\t\t\tthis.showDots(this.dots0, 1, value - 2 - nleft1);\n\t\t\t\tthis.allocButtonPages0(2 + nleft1);\n\t\t\t\tthis.showPage(buttonPages0[0], 0);\n\t\t\t\tfor (let i = 1, imax = buttonPages0.length - nleft1 - 1; i < imax; ++i) {\n\t\t\t\t\tthis.hidePage(buttonPages0[i]);\n\t\t\t\t}\n\t\t\t\tfor (let i = 0, imax = 1 + nleft1; i < imax; ++i) {\n\t\t\t\t\tthis.showPage(\n\t\t\t\t\t\tbuttonPages0[buttonPages0.length - imax + i],\n\t\t\t\t\t\tvalue - 1 - (imax - 1) + i\n\t\t\t\t\t);\n\t\t\t\t}\n\t\t\t\tbreak;\n\t\t\tcase 2:\n\t\t\t\tthis.showDots(this.dots0, 0, value - 2);\n\t\t\t\tfor (let i = 0, imax = buttonPages0.length - 1; i < imax; ++i) {\n\t\t\t\t\tthis.hidePage(buttonPages0[i]);\n\t\t\t\t}\n\t\t\t\tthis.showPage(buttonPages0[buttonPages0.length - 1], value - 1);\n\t\t\t\tbreak;\n\t\t\tcase 3:\n\t\t\t\tthis.showDots(this.dots0, 0, value - 1);\n\t\t\t\tfor (let i = 0, imax = buttonPages0.length; i < imax; ++i) {\n\t\t\t\t\tthis.hidePage(buttonPages0[i]);\n\t\t\t\t}\n\t\t\t\tbreak;\n\t\t\tcase 4:\n\t\t\t\tthis.hideDots(this.dots0);\n\t\t\t\tfor (let i = 0, imax = buttonPages0.length; i < imax; ++i) {\n\t\t\t\t\tthis.hidePage(buttonPages0[i]);\n\t\t\t\t}\n\t\t\t\tbreak;\n\t\t}\n\n\t\tthis.showPage(this.page, value);\n\n\t\tconst buttonPages1 = this.buttonPages1;\n\t\tswitch (right) {\n\t\t\tcase 0:\n\t\t\t\tthis.allocButtonPages1(size - (value + 1));\n\t\t\t\tfor (let i = 0, imax = buttonPages1.length; i < imax; ++i) {\n\t\t\t\t\tconst j = value + 1 + i;\n\t\t\t\t\tif (j < size) {\n\t\t\t\t\t\tthis.showPage(buttonPages1[i], j);\n\t\t\t\t\t} else {\n\t\t\t\t\t\tthis.hidePage(buttonPages1[i]);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\tthis.hideDots(this.dots1);\n\t\t\t\tbreak;\n\t\t\tcase 1:\n\t\t\t\tthis.allocButtonPages1(2 + nright1);\n\t\t\t\tfor (let i = 0, imax = 1 + nright1; i < imax; ++i) {\n\t\t\t\t\tthis.showPage(buttonPages1[i], value + 1 + i);\n\t\t\t\t}\n\t\t\t\tfor (let i = 1 + nright1, imax = buttonPages1.length - 1; i < imax; ++i) {\n\t\t\t\t\tthis.hidePage(buttonPages1[i]);\n\t\t\t\t}\n\t\t\t\tthis.showPage(buttonPages1[buttonPages1.length - 1], size - 1);\n\t\t\t\tthis.showDots(this.dots1, value + 2 + nright1, size - 2);\n\t\t\t\tbreak;\n\t\t\tcase 2:\n\t\t\t\tthis.showPage(buttonPages1[0], value + 1);\n\t\t\t\tfor (let i = 1, imax = buttonPages1.length; i < imax; ++i) {\n\t\t\t\t\tthis.hidePage(buttonPages1[i]);\n\t\t\t\t}\n\t\t\t\tthis.showDots(this.dots1, value + 2, size - 1);\n\t\t\t\tbreak;\n\t\t\tcase 3:\n\t\t\t\tfor (let i = 0, imax = buttonPages1.length; i < imax; ++i) {\n\t\t\t\t\tthis.hidePage(buttonPages1[i]);\n\t\t\t\t}\n\t\t\t\tthis.showDots(this.dots1, value + 1, size - 1);\n\t\t\t\tbreak;\n\t\t\tcase 4:\n\t\t\t\tfor (let i = 0, imax = buttonPages1.length; i < imax; ++i) {\n\t\t\t\t\tthis.hidePage(buttonPages1[i]);\n\t\t\t\t}\n\t\t\t\tthis.hideDots(this.dots1);\n\t\t\t\tbreak;\n\t\t}\n\n\t\tconst buttonNext = this.buttonNext;\n\t\tif (buttonNext != null) {\n\t\t\tbuttonNext.state.isEnabled = value < size - 1;\n\t\t}\n\t\tconst buttonLast = this.buttonLast;\n\t\tif (buttonLast != null) {\n\t\t\tbuttonLast.state.isEnabled = value < size - 1;\n\t\t}\n\t}\n\n\tprotected showPage(button: DImageBase<number>, index: number): void {\n\t\tbutton.text = index + 1;\n\t\tbutton.show();\n\t}\n\n\tprotected hidePage(button: DImageBase<number>): void {\n\t\tbutton.hide();\n\t}\n\n\tprotected showDots(dots: DPaginationDots, from: number, to: number): void {\n\t\tdots.show();\n\t}\n\n\tprotected hideDots(dots: DPaginationDots): void {\n\t\tdots.hide();\n\t}\n\n\tprotected getType(): string {\n\t\treturn \"DPagination\";\n\t}\n}\n"]}
1
+ {"version":3,"file":"d-pagination.js","sourceRoot":"","sources":["../../../src/main/typescript/wcardinal/ui/d-pagination.ts"],"names":[],"mappings":"AAAA;;;GAGG;;AAGH,OAAO,EACN,iBAAiB,EAGjB,MAAM,uBAAuB,CAAC;AAC/B,OAAO,EAAE,eAAe,EAAE,MAAM,qBAAqB,CAAC;AACtD,OAAO,EAAE,qBAAqB,EAAgC,MAAM,4BAA4B,CAAC;AACjG,OAAO,EAAE,qBAAqB,EAAgC,MAAM,4BAA4B,CAAC;AACjG,OAAO,EAAE,qBAAqB,EAAgC,MAAM,4BAA4B,CAAC;AACjG,OAAO,EACN,yBAAyB,EAEzB,MAAM,gCAAgC,CAAC;AACxC,OAAO,EAAE,oBAAoB,EAA+B,MAAM,2BAA2B,CAAC;AAC9F,OAAO,EAAE,QAAQ,EAAE,MAAM,kBAAkB,CAAC;AAC5C,OAAO,EAAE,eAAe,EAA0B,MAAM,qBAAqB,CAAC;AAC9E,OAAO,EAAE,YAAY,EAAuB,MAAM,kBAAkB,CAAC;AAErE,OAAO,EAAE,aAAa,EAAE,MAAM,kBAAkB,CAAC;AA2EjD;IAGU,+BAAiC;IAgB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: Apache-2.0\n */\n\nimport { DButton } from \"./d-button\";\nimport {\n\tDLayoutHorizontal,\n\tDLayoutHorizontalOptions,\n\tDThemeLayoutHorizontal\n} from \"./d-layout-horizontal\";\nimport { DPaginationDots } from \"./d-pagination-dots\";\nimport { DPaginationButtonLast, DPaginationButtonLastOptions } from \"./d-pagination-button-last\";\nimport { DPaginationButtonNext, DPaginationButtonNextOptions } from \"./d-pagination-button-next\";\nimport { DPaginationButtonPage, DPaginationButtonPageOptions } from \"./d-pagination-button-page\";\nimport {\n\tDPaginationButtonPrevious,\n\tDPaginationButtonPreviousOptions\n} from \"./d-pagination-button-previous\";\nimport { DPaginationButtonTop, DPaginationButtonTopOptions } from \"./d-pagination-button-top\";\nimport { isNumber } from \"./util/is-number\";\nimport { DPaginationPage, DPaginationPageOptions } from \"./d-pagination-page\";\nimport { DLayoutSpace, DLayoutSpaceOptions } from \"./d-layout-space\";\nimport { DImageBase } from \"./d-image-base\";\nimport { DApplications } from \"./d-applications\";\n\nexport interface DPaginationButtonOptions {\n\t/**\n\t * {@link DPagination} top button options.\n\t */\n\ttop?: DPaginationButtonTopOptions | boolean | null;\n\n\t/**\n\t * {@link DPagination} previous button options.\n\t */\n\tprevious?: DPaginationButtonPreviousOptions | boolean | null;\n\n\t/**\n\t * {@link DPagination} page button options.\n\t */\n\tpage?: DPaginationButtonPageOptions;\n\n\t/**\n\t * {@link DPagination} next button options.\n\t */\n\tnext?: DPaginationButtonNextOptions | boolean | null;\n\n\t/**\n\t * {@link DPagination} last button options.\n\t */\n\tlast?: DPaginationButtonLastOptions | boolean | null;\n\n\t/**\n\t * A space between page buttons and next / previous buttons.\n\t */\n\tspace?: DLayoutSpaceOptions | boolean | number | null;\n}\n\nexport interface DPaginationOptions<THEME extends DThemePagination>\n\textends DLayoutHorizontalOptions<THEME> {\n\t/**\n\t * An index number of a selected page.\n\t */\n\tvalue?: number;\n\n\t/**\n\t * An index number of a selected page.\n\t *\n\t * @deprecated in favor of {@link value}.\n\t */\n\tselected?: number;\n\n\t/**\n\t * A total number of pages.\n\t */\n\tsize?: number;\n\n\t/**\n\t * A total number of pages.\n\t *\n\t * @deprecated in favor of {@link size};\n\t */\n\ttotal?: number;\n\n\t/**\n\t * {@link DPagination} button options.\n\t */\n\tbutton?: DPaginationButtonOptions;\n\n\t/**\n\t * {@link DPagination} page options.\n\t */\n\tpage?: DPaginationPageOptions;\n}\n\nexport interface DThemePagination extends DThemeLayoutHorizontal {\n\tgetButtonSpace(): number;\n}\n\nexport class DPagination<\n\tTHEME extends DThemePagination = DThemePagination,\n\tOPTIONS extends DPaginationOptions<THEME> = DPaginationOptions<THEME>\n> extends DLayoutHorizontal<THEME, OPTIONS> {\n\tprotected _size: number;\n\tprotected _value: number;\n\n\tprotected _buttonTop?: DButton<string> | null;\n\tprotected _buttonPrevious?: DButton<string> | null;\n\tprotected _spaceLeft?: DLayoutSpace | null;\n\tprotected _dots0?: DPaginationDots;\n\tprotected _buttonPages0?: DButton<number>[];\n\tprotected _page?: DPaginationPage;\n\tprotected _buttonPages1?: DButton<number>[];\n\tprotected _dots1?: DPaginationDots;\n\tprotected _spaceRight?: DLayoutSpace | null;\n\tprotected _buttonNext?: DButton<string> | null;\n\tprotected _buttonLast?: DButton<string> | null;\n\n\tconstructor(options?: OPTIONS) {\n\t\tsuper(options);\n\n\t\tif (options != null) {\n\t\t\tthis._size = options.size ?? options.total ?? 10;\n\t\t\tthis._value = options.value ?? options.selected ?? 0;\n\t\t} else {\n\t\t\tthis._size = 10;\n\t\t\tthis._value = 0;\n\t\t}\n\n\t\tconst buttonTop = this.buttonTop;\n\t\tif (buttonTop != null) {\n\t\t\tthis.addChild(buttonTop);\n\t\t}\n\t\tconst buttonPrevious = this.buttonPrevious;\n\t\tif (buttonPrevious != null) {\n\t\t\tthis.addChild(buttonPrevious);\n\t\t}\n\t\tconst spaceLeft = this.spaceLeft;\n\t\tif (spaceLeft != null) {\n\t\t\tthis.addChild(spaceLeft);\n\t\t}\n\t\tconst buttonPages0 = this.buttonPages0;\n\t\tconst buttonPages0Length = buttonPages0.length;\n\t\tthis.addChild(buttonPages0[0]);\n\t\tthis.addChild(this.dots0);\n\t\tfor (let i = 1; i < buttonPages0Length; ++i) {\n\t\t\tthis.addChild(buttonPages0[i]);\n\t\t}\n\t\tthis.addChild(this.page);\n\t\tconst buttonPages1 = this.buttonPages1;\n\t\tconst buttonPages1Length = buttonPages1.length;\n\t\tfor (let i = 0, imax = buttonPages1Length - 1; i < imax; ++i) {\n\t\t\tthis.addChild(buttonPages1[i]);\n\t\t}\n\t\tthis.addChild(this.dots1);\n\t\tthis.addChild(buttonPages1[buttonPages1Length - 1]);\n\t\tconst spaceRight = this.spaceRight;\n\t\tif (spaceRight != null) {\n\t\t\tthis.addChild(spaceRight);\n\t\t}\n\t\tconst buttonNext = this.buttonNext;\n\t\tif (buttonNext != null) {\n\t\t\tthis.addChild(buttonNext);\n\t\t}\n\t\tconst buttonLast = this.buttonLast;\n\t\tif (buttonLast != null) {\n\t\t\tthis.addChild(buttonLast);\n\t\t}\n\t}\n\n\t/**\n\t * Sets a value that is an index of a current page.\n\t *\n\t * @param value a value that is an index of a page\n\t */\n\tset value(value: number) {\n\t\tif (0 <= value && value < this._size && this._value !== value) {\n\t\t\tthis._value = value;\n\t\t\tthis.toDirty();\n\t\t\tDApplications.update(this);\n\t\t}\n\t}\n\n\t/**\n\t * Returns a value that is an index of a current page.\n\t *\n\t * @returns a value that is an index of a selected page.\n\t */\n\tget value(): number {\n\t\treturn this._value;\n\t}\n\n\t/**\n\t * Selects a page.\n\t *\n\t * @param index an index of a page\n\t * @deprecated in favor of {@link value}.\n\t */\n\tset selected(index: number) {\n\t\tthis.value = index;\n\t}\n\n\t/**\n\t * Returns an index of the selected page.\n\t *\n\t * @returns an index of the selected page.\n\t * @deprecated in favor of {@link value}.\n\t */\n\tget selected(): number {\n\t\treturn this.value;\n\t}\n\n\t/**\n\t * Sets a number of total pages.\n\t *\n\t * @param size a number of pages\n\t */\n\tset size(size: number) {\n\t\tif (0 <= size && this._size !== size) {\n\t\t\tthis._size = size;\n\t\t\tif (size === 0) {\n\t\t\t\tthis._value = -1;\n\t\t\t} else {\n\t\t\t\tthis._value = Math.max(0, Math.min(this._size - 1, this._value));\n\t\t\t}\n\t\t\tthis.toDirty();\n\t\t\tDApplications.update(this);\n\t\t}\n\t}\n\n\t/**\n\t * Returns a number of total pages.\n\t *\n\t * @returns a number of total pages.\n\t */\n\tget size(): number {\n\t\treturn this._size;\n\t}\n\n\t/**\n\t * Sets a number of total pages.\n\t *\n\t * @param total a number of pages\n\t * @deprecated in favor of {@link size}\n\t */\n\tset total(total: number) {\n\t\tthis.size = total;\n\t}\n\n\t/**\n\t * Returns a number of total pages.\n\t *\n\t * @returns a number of total pages.\n\t * @deprecated in favor of {@link size}\n\t */\n\tget total(): number {\n\t\treturn this.size;\n\t}\n\n\tprotected get dots0(): DPaginationDots {\n\t\tlet result = this._dots0;\n\t\tif (result == null) {\n\t\t\tresult = this.newDots();\n\t\t\tthis._dots0 = result;\n\t\t}\n\t\treturn result;\n\t}\n\n\tprotected get dots1(): DPaginationDots {\n\t\tlet result = this._dots1;\n\t\tif (result == null) {\n\t\t\tresult = this.newDots();\n\t\t\tthis._dots1 = result;\n\t\t}\n\t\treturn result;\n\t}\n\n\tprotected newDots(): DPaginationDots {\n\t\treturn new DPaginationDots();\n\t}\n\n\tprotected get buttonLast(): DButton<string> | null {\n\t\tlet result = this._buttonLast;\n\t\tif (result === undefined) {\n\t\t\tresult = this.newButtonLast();\n\t\t\tthis._buttonLast = result;\n\t\t}\n\t\treturn result;\n\t}\n\n\tprotected newButtonLast(): DButton<string> | null {\n\t\tconst last = this._options?.button?.last;\n\t\tif (last !== null && last !== false && last !== undefined) {\n\t\t\tconst result = new DPaginationButtonLast(last !== true ? last : undefined);\n\t\t\tresult.on(\"active\", () => {\n\t\t\t\tthis.onButtonLastActive();\n\t\t\t});\n\t\t\treturn result;\n\t\t}\n\t\treturn null;\n\t}\n\n\tprotected onButtonLastActive(): void {\n\t\tthis.goToLast();\n\t}\n\n\t/**\n\t * Goes to the last page.\n\t * Unlike {@link #value}, this method emits the change event if silently is not true.\n\t *\n\t * @param silently true to suppress the change event\n\t * @returns true if succeeded.\n\t */\n\tgoToLast(silently?: boolean): boolean {\n\t\treturn this.goTo(this._size - 1, silently);\n\t}\n\n\t/**\n\t * Goes to the given page.\n\t * Unlike {@link #value}, this method emits the change event if silently is not true.\n\t *\n\t * @param index a page index\n\t * @param silently true to suppress the change event\n\t * @returns this\n\t */\n\tgoTo(index: number, silently?: boolean): boolean {\n\t\tif (0 <= index && index < this._size && this._value !== index) {\n\t\t\tconst oldIndex = this._value;\n\t\t\tthis._value = index;\n\t\t\tif (silently !== true) {\n\t\t\t\tthis.emit(\"change\", index, oldIndex, this);\n\t\t\t}\n\t\t\tthis.toDirty();\n\t\t\tDApplications.update(this);\n\t\t\treturn true;\n\t\t}\n\t\treturn false;\n\t}\n\n\tprotected get buttonNext(): DButton<string> | null {\n\t\tlet result = this._buttonNext;\n\t\tif (result === undefined) {\n\t\t\tresult = this.newButtonNext();\n\t\t\tthis._buttonNext = result;\n\t\t}\n\t\treturn result;\n\t}\n\n\tprotected newButtonNext(): DButton<string> | null {\n\t\tconst next = this._options?.button?.next;\n\t\tif (next !== null && next !== false) {\n\t\t\tconst result = new DPaginationButtonNext(next !== true ? next : undefined);\n\t\t\tresult.on(\"active\", (): void => {\n\t\t\t\tthis.onButtonNextActive();\n\t\t\t});\n\t\t\treturn result;\n\t\t}\n\t\treturn null;\n\t}\n\n\tprotected onButtonNextActive(): void {\n\t\tthis.goToNext();\n\t}\n\n\t/**\n\t * Goes to the next page.\n\t * Unlike {@link #value}, this method emits the change event if silently is not true.\n\t *\n\t * @param silently true to suppress the change event\n\t * @returns true if succeeded.\n\t */\n\tgoToNext(silently?: boolean): boolean {\n\t\treturn this.goTo(this._value + 1, silently);\n\t}\n\n\tprotected get buttonPrevious(): DButton<string> | null {\n\t\tlet result = this._buttonPrevious;\n\t\tif (result === undefined) {\n\t\t\tresult = this.newButtonPrevious();\n\t\t\tthis._buttonPrevious = result;\n\t\t}\n\t\treturn result;\n\t}\n\n\tprotected newButtonPrevious(): DButton<string> | null {\n\t\tconst previous = this._options?.button?.previous;\n\t\tif (previous !== null && previous !== false) {\n\t\t\tconst result = new DPaginationButtonPrevious(previous !== true ? previous : undefined);\n\t\t\tresult.on(\"active\", (): void => {\n\t\t\t\tthis.onButtonPreviousActive();\n\t\t\t});\n\t\t\treturn result;\n\t\t}\n\t\treturn null;\n\t}\n\n\tprotected onButtonPreviousActive(): void {\n\t\tthis.goToPrevious();\n\t}\n\n\t/**\n\t * Goes to the previous page.\n\t * Unlike {@link #value}, this method emits the change event if silently is not true.\n\t *\n\t * @param silently true to suppress the change event\n\t * @returns true if succeeded.\n\t */\n\tgoToPrevious(silently?: boolean): boolean {\n\t\treturn this.goTo(this._value - 1, silently);\n\t}\n\n\tprotected get buttonTop(): DButton<string> | null {\n\t\tlet result = this._buttonTop;\n\t\tif (result === undefined) {\n\t\t\tresult = this.newButtonTop();\n\t\t\tthis._buttonTop = result;\n\t\t}\n\t\treturn result;\n\t}\n\n\tprotected newButtonTop(): DButton<string> | null {\n\t\tconst top = this._options?.button?.top;\n\t\tif (top !== null && top !== false && top !== undefined) {\n\t\t\tconst result = new DPaginationButtonTop(top !== true ? top : undefined);\n\t\t\tresult.on(\"active\", (): void => {\n\t\t\t\tthis.onButtonTopActive();\n\t\t\t});\n\t\t\treturn result;\n\t\t}\n\t\treturn null;\n\t}\n\n\tprotected onButtonTopActive(): void {\n\t\tthis.goToTop();\n\t}\n\n\t/**\n\t * Goes to the top page.\n\t * Unlike {@link #value}, this method emits the change event if silently is not true.\n\t *\n\t * @param silently true to suppress the change event\n\t * @returns true if succeeded.\n\t */\n\tgoToTop(silently?: boolean): boolean {\n\t\treturn this.goTo(0, silently);\n\t}\n\n\tprotected newButtonPage(): DButton<number> {\n\t\tconst result = new DPaginationButtonPage(this._options?.button?.page);\n\t\tresult.on(\"active\", (): void => {\n\t\t\tthis.onButtonPageActive(result);\n\t\t});\n\t\treturn result;\n\t}\n\n\tprotected get buttonPages0(): DButton<number>[] {\n\t\tlet result = this._buttonPages0;\n\t\tif (result == null) {\n\t\t\tresult = this.newButtonPages0();\n\t\t\tthis._buttonPages0 = result;\n\t\t}\n\t\treturn result;\n\t}\n\n\tprotected newButtonPages0(): DButton<number>[] {\n\t\treturn [\n\t\t\tthis.newButtonPage(),\n\t\t\tthis.newButtonPage(),\n\t\t\tthis.newButtonPage(),\n\t\t\tthis.newButtonPage()\n\t\t];\n\t}\n\n\tprotected allocButtonPages0(size: number): void {\n\t\tconst buttonPages0 = this.buttonPages0;\n\t\tconst buttonPages0Length = buttonPages0.length;\n\t\tconst index = this.getChildIndex(buttonPages0[buttonPages0Length - 1]) + 1;\n\t\tfor (let i = 0, imax = size - buttonPages0Length; i < imax; ++i) {\n\t\t\tconst buttonPage = this.newButtonPage();\n\t\t\tthis.addChildAt(buttonPage, index + i);\n\t\t\tbuttonPages0.push(buttonPage);\n\t\t}\n\t}\n\n\tprotected get buttonPages1(): DButton<number>[] {\n\t\tlet result = this._buttonPages1;\n\t\tif (result == null) {\n\t\t\tresult = this.newButtonPages1();\n\t\t\tthis._buttonPages1 = result;\n\t\t}\n\t\treturn result;\n\t}\n\n\tprotected newButtonPages1(): DButton<number>[] {\n\t\treturn [\n\t\t\tthis.newButtonPage(),\n\t\t\tthis.newButtonPage(),\n\t\t\tthis.newButtonPage(),\n\t\t\tthis.newButtonPage()\n\t\t];\n\t}\n\n\tprotected allocButtonPages1(size: number): void {\n\t\tconst buttonPages1 = this.buttonPages1;\n\t\tconst buttonPages1Length = buttonPages1.length;\n\t\tconst index = this.getChildIndex(buttonPages1[0]);\n\t\tfor (let i = 0, imax = size - buttonPages1Length; i < imax; ++i) {\n\t\t\tconst buttonPage = this.newButtonPage();\n\t\t\tthis.addChildAt(buttonPage, index);\n\t\t\tbuttonPages1.unshift(buttonPage);\n\t\t}\n\t}\n\n\tprotected get page(): DPaginationPage {\n\t\tlet result = this._page;\n\t\tif (result == null) {\n\t\t\tresult = this.newPage();\n\t\t\tthis._page = result;\n\t\t}\n\t\treturn result;\n\t}\n\n\tprotected newPage(): DPaginationPage {\n\t\treturn new DPaginationPage(this._options?.page);\n\t}\n\n\tprotected onButtonPageActive(button: DButton<number>): void {\n\t\tconst text = button.text.value;\n\t\tif (isNumber(text)) {\n\t\t\tthis.goTo(text - 1);\n\t\t\tif (button.state.isFocused) {\n\t\t\t\tbutton.state.isHovered = false;\n\t\t\t\tthis.page.focus();\n\t\t\t}\n\t\t}\n\t}\n\n\tprotected get spaceLeft(): DLayoutSpace | null {\n\t\tlet result = this._spaceLeft;\n\t\tif (result === undefined) {\n\t\t\tresult = this.newSpaceLeft();\n\t\t\tthis._spaceLeft = result;\n\t\t}\n\t\treturn result;\n\t}\n\n\tprotected newSpaceLeft(): DLayoutSpace | null {\n\t\tif (this.buttonTop != null || this.buttonPrevious != null) {\n\t\t\treturn this.newSpace();\n\t\t}\n\t\treturn null;\n\t}\n\n\tprotected get spaceRight(): DLayoutSpace | null {\n\t\tlet result = this._spaceRight;\n\t\tif (result === undefined) {\n\t\t\tresult = this.newSpaceRight();\n\t\t\tthis._spaceRight = result;\n\t\t}\n\t\treturn result;\n\t}\n\n\tprotected newSpaceRight(): DLayoutSpace | null {\n\t\tif (this.buttonLast != null || this.buttonNext != null) {\n\t\t\treturn this.newSpace();\n\t\t}\n\t\treturn null;\n\t}\n\n\tprotected newSpace(): DLayoutSpace | null {\n\t\tconst space = this._options?.button?.space;\n\t\tif (space !== null && space !== false) {\n\t\t\tif (space === true || space === undefined) {\n\t\t\t\treturn new DLayoutSpace({\n\t\t\t\t\tweight: 1\n\t\t\t\t});\n\t\t\t} else if (isNumber(space)) {\n\t\t\t\treturn new DLayoutSpace({\n\t\t\t\t\twidth: space\n\t\t\t\t});\n\t\t\t} else {\n\t\t\t\treturn new DLayoutSpace(space);\n\t\t\t}\n\t\t}\n\t\treturn null;\n\t}\n\n\tprotected onReflow(): void {\n\t\tthis.update();\n\t\tsuper.onReflow();\n\t}\n\n\tprotected update(): void {\n\t\tconst size = this._size;\n\t\tconst value = this._value;\n\t\tif (size <= 0) {\n\t\t\tthis.doUpdate0(value, size);\n\t\t} else {\n\t\t\tif (this._auto.width.isOn) {\n\t\t\t\tthis.doUpdate2(value, size, 0, 0, 0, 0);\n\t\t\t} else {\n\t\t\t\tthis.doUpdate1(value, size);\n\t\t\t}\n\t\t}\n\t}\n\n\tprotected doUpdate0(value: number, size: number): void {\n\t\tconst buttonTop = this.buttonTop;\n\t\tif (buttonTop != null) {\n\t\t\tbuttonTop.state.isEnabled = false;\n\t\t}\n\t\tconst buttonPrevious = this.buttonPrevious;\n\t\tif (buttonPrevious != null) {\n\t\t\tbuttonPrevious.state.isEnabled = false;\n\t\t}\n\n\t\tthis.hideDots(this.dots0);\n\n\t\tconst buttonPages0 = this.buttonPages0;\n\t\tfor (let i = 0, imax = buttonPages0.length; i < imax; ++i) {\n\t\t\tthis.hidePage(buttonPages0[i]);\n\t\t}\n\n\t\tthis.hidePage(this.page);\n\n\t\tconst buttonPages1 = this.buttonPages1;\n\t\tfor (let i = 0, imax = buttonPages1.length; i < imax; ++i) {\n\t\t\tthis.hidePage(buttonPages1[i]);\n\t\t}\n\n\t\tthis.hideDots(this.dots1);\n\n\t\tconst buttonNext = this.buttonNext;\n\t\tif (buttonNext != null) {\n\t\t\tbuttonNext.state.isEnabled = false;\n\t\t}\n\t\tconst buttonLast = this.buttonLast;\n\t\tif (buttonLast) {\n\t\t\tbuttonLast.state.isEnabled = false;\n\t\t}\n\t}\n\n\tprotected doUpdate1(value: number, size: number): void {\n\t\tlet required = 0;\n\t\tlet nrequired = 0;\n\n\t\tconst buttonTop = this.buttonTop;\n\t\tif (buttonTop != null) {\n\t\t\trequired += buttonTop.width;\n\t\t\tnrequired += 1;\n\t\t}\n\t\tconst buttonPrevious = this.buttonPrevious;\n\t\tif (buttonPrevious != null) {\n\t\t\trequired += buttonPrevious.width;\n\t\t\tnrequired += 1;\n\t\t}\n\n\t\tconst spaceLeft = this.spaceLeft;\n\t\tif (spaceLeft != null) {\n\t\t\tif (spaceLeft.weight < 0) {\n\t\t\t\trequired += spaceLeft.width;\n\t\t\t}\n\t\t\tnrequired += 1;\n\t\t}\n\n\t\tconst page = this.page;\n\t\trequired += page.width;\n\t\tnrequired += 1;\n\n\t\tconst spaceRight = this.spaceRight;\n\t\tif (spaceRight != null) {\n\t\t\tif (spaceRight.weight < 0) {\n\t\t\t\trequired += spaceRight.width;\n\t\t\t}\n\t\t\tnrequired += 1;\n\t\t}\n\n\t\tconst buttonNext = this.buttonNext;\n\t\tif (buttonNext != null) {\n\t\t\trequired += buttonNext.width;\n\t\t\tnrequired += 1;\n\t\t}\n\t\tconst buttonLast = this.buttonLast;\n\t\tif (buttonLast) {\n\t\t\trequired += buttonLast.width;\n\t\t\tnrequired += 1;\n\t\t}\n\n\t\tconst marginHorizontal = this._margin.horizontal;\n\t\tif (2 <= nrequired) {\n\t\t\trequired += (nrequired - 1) * marginHorizontal;\n\t\t}\n\n\t\tconst padding = this.padding;\n\t\tconst space = this.width - (padding.getLeft() + padding.getRight());\n\t\tif (space <= required) {\n\t\t\tthis.doUpdate2(value, size, 4, 4, 0, 0);\n\t\t} else {\n\t\t\tconst buttonPages0 = this.buttonPages0;\n\t\t\tconst buttonPage0Width = buttonPages0[0].width;\n\t\t\tconst nrequired0 = value;\n\t\t\tconst required0 = nrequired0 * (buttonPage0Width + marginHorizontal);\n\n\t\t\tconst buttonPages1 = this.buttonPages1;\n\t\t\tconst buttonPage1Width = buttonPages1[0].width;\n\t\t\tconst nrequired1 = size - (value + 1);\n\t\t\tconst required1 = nrequired1 * (buttonPage1Width + marginHorizontal);\n\n\t\t\tif (required + required0 + required1 <= space) {\n\t\t\t\tthis.doUpdate2(value, size, 0, 0, 0, 0);\n\t\t\t} else {\n\t\t\t\tconst dots1 = this.dots1;\n\t\t\t\tconst dots1Width = dots1.width;\n\t\t\t\tconst dots0 = this.dots0;\n\t\t\t\tconst dots0Width = dots0.width;\n\t\t\t\tconst m0 = marginHorizontal + buttonPage0Width;\n\t\t\t\tconst m1 = marginHorizontal + buttonPage1Width;\n\t\t\t\tconst required0n = dots0Width + m0;\n\t\t\t\tconst required1n = dots1Width + m1;\n\t\t\t\tconst required0m = required0n + m0;\n\t\t\t\tconst required1m = required1n + m1;\n\t\t\t\tif (required0 <= required1) {\n\t\t\t\t\tif (3 <= nrequired1 && required + required0 + required1m <= space) {\n\t\t\t\t\t\tconst l = space - (required + required0 + required1m);\n\t\t\t\t\t\tconst n1 = Math.floor(l / m1);\n\t\t\t\t\t\tthis.doUpdate2(value, size, 0, 1, 0, n1);\n\t\t\t\t\t} else if (\n\t\t\t\t\t\t3 <= nrequired0 &&\n\t\t\t\t\t\t3 <= nrequired1 &&\n\t\t\t\t\t\trequired + required0m + required1m <= space\n\t\t\t\t\t) {\n\t\t\t\t\t\tconst l = space - (required + required0m + required1m);\n\t\t\t\t\t\tconst n1 = Math.floor((l * 0.5) / m1);\n\t\t\t\t\t\tconst n0 = Math.floor((l - n1 * m1) / m0);\n\t\t\t\t\t\tthis.doUpdate2(value, size, 1, 1, n0, n1);\n\t\t\t\t\t} else if (2 <= nrequired1 && required + required0 + required1n <= space) {\n\t\t\t\t\t\tthis.doUpdate2(value, size, 0, 2, 0, 0);\n\t\t\t\t\t} else if (\n\t\t\t\t\t\t3 <= nrequired0 &&\n\t\t\t\t\t\t2 <= nrequired1 &&\n\t\t\t\t\t\trequired + required0m + required1n <= space\n\t\t\t\t\t) {\n\t\t\t\t\t\tconst l = space - (required + required0m + required1n);\n\t\t\t\t\t\tconst n0 = Math.floor(l / m0);\n\t\t\t\t\t\tthis.doUpdate2(value, size, 1, 2, n0, 0);\n\t\t\t\t\t} else if (\n\t\t\t\t\t\t2 <= nrequired0 &&\n\t\t\t\t\t\t2 <= nrequired1 &&\n\t\t\t\t\t\trequired + required0n + required1n <= space\n\t\t\t\t\t) {\n\t\t\t\t\t\tthis.doUpdate2(value, size, 2, 2, 0, 0);\n\t\t\t\t\t} else if (\n\t\t\t\t\t\t1 <= nrequired0 &&\n\t\t\t\t\t\t1 <= nrequired1 &&\n\t\t\t\t\t\trequired + dots0Width + dots1Width <= space\n\t\t\t\t\t) {\n\t\t\t\t\t\tthis.doUpdate2(value, size, 3, 3, 0, 0);\n\t\t\t\t\t} else {\n\t\t\t\t\t\tthis.doUpdate2(value, size, 4, 4, 0, 0);\n\t\t\t\t\t}\n\t\t\t\t} else {\n\t\t\t\t\tif (3 <= nrequired0 && required + required0m + required1 <= space) {\n\t\t\t\t\t\tconst l = space - (required + required0m + required1);\n\t\t\t\t\t\tconst n0 = Math.floor(l / m0);\n\t\t\t\t\t\tthis.doUpdate2(value, size, 1, 0, n0, 0);\n\t\t\t\t\t} else if (\n\t\t\t\t\t\t3 <= nrequired0 &&\n\t\t\t\t\t\t3 <= nrequired1 &&\n\t\t\t\t\t\trequired + required0m + required1m <= space\n\t\t\t\t\t) {\n\t\t\t\t\t\tconst l = space - (required + required0m + required1m);\n\t\t\t\t\t\tconst n0 = Math.floor((l * 0.5) / m0);\n\t\t\t\t\t\tconst n1 = Math.floor((l - n0 * m0) / m1);\n\t\t\t\t\t\tthis.doUpdate2(value, size, 1, 1, n0, n1);\n\t\t\t\t\t} else if (2 <= nrequired0 && required + required0n + required1 <= space) {\n\t\t\t\t\t\tthis.doUpdate2(value, size, 2, 0, 0, 0);\n\t\t\t\t\t} else if (\n\t\t\t\t\t\t2 <= nrequired0 &&\n\t\t\t\t\t\t3 <= nrequired1 &&\n\t\t\t\t\t\trequired + required0n + required1m <= space\n\t\t\t\t\t) {\n\t\t\t\t\t\tconst l = space - (required + required0n + required1m);\n\t\t\t\t\t\tconst n1 = Math.floor(l / m1);\n\t\t\t\t\t\tthis.doUpdate2(value, size, 2, 1, 0, n1);\n\t\t\t\t\t} else if (\n\t\t\t\t\t\t2 <= nrequired0 &&\n\t\t\t\t\t\t2 <= nrequired1 &&\n\t\t\t\t\t\trequired + required0n + required1n <= space\n\t\t\t\t\t) {\n\t\t\t\t\t\tthis.doUpdate2(value, size, 2, 2, 0, 0);\n\t\t\t\t\t} else if (\n\t\t\t\t\t\t1 <= nrequired0 &&\n\t\t\t\t\t\t1 <= nrequired1 &&\n\t\t\t\t\t\trequired + dots0Width + dots1Width <= space\n\t\t\t\t\t) {\n\t\t\t\t\t\tthis.doUpdate2(value, size, 3, 3, 0, 0);\n\t\t\t\t\t} else {\n\t\t\t\t\t\tthis.doUpdate2(value, size, 4, 4, 0, 0);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\tprotected doUpdate2(\n\t\tvalue: number,\n\t\tsize: number,\n\t\tleft: 0 | 1 | 2 | 3 | 4,\n\t\tright: 0 | 1 | 2 | 3 | 4,\n\t\tnleft1: number,\n\t\tnright1: number\n\t): void {\n\t\tconst buttonTop = this.buttonTop;\n\t\tif (buttonTop != null) {\n\t\t\tbuttonTop.state.isEnabled = 0 < value;\n\t\t}\n\t\tconst buttonPrevious = this.buttonPrevious;\n\t\tif (buttonPrevious != null) {\n\t\t\tbuttonPrevious.state.isEnabled = 0 < value;\n\t\t}\n\n\t\tconst buttonPages0 = this.buttonPages0;\n\t\tswitch (left) {\n\t\t\tcase 0:\n\t\t\t\tthis.hideDots(this.dots0);\n\t\t\t\tthis.allocButtonPages0(value);\n\t\t\t\tfor (let i = 0, imax = buttonPages0.length; i < imax; ++i) {\n\t\t\t\t\tif (i < value) {\n\t\t\t\t\t\tthis.showPage(buttonPages0[i], i);\n\t\t\t\t\t} else {\n\t\t\t\t\t\tthis.hidePage(buttonPages0[i]);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\tbreak;\n\t\t\tcase 1:\n\t\t\t\tthis.showDots(this.dots0, 1, value - 2 - nleft1);\n\t\t\t\tthis.allocButtonPages0(2 + nleft1);\n\t\t\t\tthis.showPage(buttonPages0[0], 0);\n\t\t\t\tfor (let i = 1, imax = buttonPages0.length - nleft1 - 1; i < imax; ++i) {\n\t\t\t\t\tthis.hidePage(buttonPages0[i]);\n\t\t\t\t}\n\t\t\t\tfor (let i = 0, imax = 1 + nleft1; i < imax; ++i) {\n\t\t\t\t\tthis.showPage(\n\t\t\t\t\t\tbuttonPages0[buttonPages0.length - imax + i],\n\t\t\t\t\t\tvalue - 1 - (imax - 1) + i\n\t\t\t\t\t);\n\t\t\t\t}\n\t\t\t\tbreak;\n\t\t\tcase 2:\n\t\t\t\tthis.showDots(this.dots0, 0, value - 2);\n\t\t\t\tfor (let i = 0, imax = buttonPages0.length - 1; i < imax; ++i) {\n\t\t\t\t\tthis.hidePage(buttonPages0[i]);\n\t\t\t\t}\n\t\t\t\tthis.showPage(buttonPages0[buttonPages0.length - 1], value - 1);\n\t\t\t\tbreak;\n\t\t\tcase 3:\n\t\t\t\tthis.showDots(this.dots0, 0, value - 1);\n\t\t\t\tfor (let i = 0, imax = buttonPages0.length; i < imax; ++i) {\n\t\t\t\t\tthis.hidePage(buttonPages0[i]);\n\t\t\t\t}\n\t\t\t\tbreak;\n\t\t\tcase 4:\n\t\t\t\tthis.hideDots(this.dots0);\n\t\t\t\tfor (let i = 0, imax = buttonPages0.length; i < imax; ++i) {\n\t\t\t\t\tthis.hidePage(buttonPages0[i]);\n\t\t\t\t}\n\t\t\t\tbreak;\n\t\t}\n\n\t\tthis.showPage(this.page, value);\n\n\t\tconst buttonPages1 = this.buttonPages1;\n\t\tswitch (right) {\n\t\t\tcase 0:\n\t\t\t\tthis.allocButtonPages1(size - (value + 1));\n\t\t\t\tfor (let i = 0, imax = buttonPages1.length; i < imax; ++i) {\n\t\t\t\t\tconst j = value + 1 + i;\n\t\t\t\t\tif (j < size) {\n\t\t\t\t\t\tthis.showPage(buttonPages1[i], j);\n\t\t\t\t\t} else {\n\t\t\t\t\t\tthis.hidePage(buttonPages1[i]);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\tthis.hideDots(this.dots1);\n\t\t\t\tbreak;\n\t\t\tcase 1:\n\t\t\t\tthis.allocButtonPages1(2 + nright1);\n\t\t\t\tfor (let i = 0, imax = 1 + nright1; i < imax; ++i) {\n\t\t\t\t\tthis.showPage(buttonPages1[i], value + 1 + i);\n\t\t\t\t}\n\t\t\t\tfor (let i = 1 + nright1, imax = buttonPages1.length - 1; i < imax; ++i) {\n\t\t\t\t\tthis.hidePage(buttonPages1[i]);\n\t\t\t\t}\n\t\t\t\tthis.showPage(buttonPages1[buttonPages1.length - 1], size - 1);\n\t\t\t\tthis.showDots(this.dots1, value + 2 + nright1, size - 2);\n\t\t\t\tbreak;\n\t\t\tcase 2:\n\t\t\t\tthis.showPage(buttonPages1[0], value + 1);\n\t\t\t\tfor (let i = 1, imax = buttonPages1.length; i < imax; ++i) {\n\t\t\t\t\tthis.hidePage(buttonPages1[i]);\n\t\t\t\t}\n\t\t\t\tthis.showDots(this.dots1, value + 2, size - 1);\n\t\t\t\tbreak;\n\t\t\tcase 3:\n\t\t\t\tfor (let i = 0, imax = buttonPages1.length; i < imax; ++i) {\n\t\t\t\t\tthis.hidePage(buttonPages1[i]);\n\t\t\t\t}\n\t\t\t\tthis.showDots(this.dots1, value + 1, size - 1);\n\t\t\t\tbreak;\n\t\t\tcase 4:\n\t\t\t\tfor (let i = 0, imax = buttonPages1.length; i < imax; ++i) {\n\t\t\t\t\tthis.hidePage(buttonPages1[i]);\n\t\t\t\t}\n\t\t\t\tthis.hideDots(this.dots1);\n\t\t\t\tbreak;\n\t\t}\n\n\t\tconst buttonNext = this.buttonNext;\n\t\tif (buttonNext != null) {\n\t\t\tbuttonNext.state.isEnabled = value < size - 1;\n\t\t}\n\t\tconst buttonLast = this.buttonLast;\n\t\tif (buttonLast != null) {\n\t\t\tbuttonLast.state.isEnabled = value < size - 1;\n\t\t}\n\t}\n\n\tprotected showPage(button: DImageBase<number>, index: number): void {\n\t\tbutton.text = index + 1;\n\t\tbutton.show();\n\t}\n\n\tprotected hidePage(button: DImageBase<number>): void {\n\t\tbutton.hide();\n\t}\n\n\tprotected showDots(dots: DPaginationDots, from: number, to: number): void {\n\t\tdots.show();\n\t}\n\n\tprotected hideDots(dots: DPaginationDots): void {\n\t\tdots.hide();\n\t}\n\n\tprotected getType(): string {\n\t\treturn \"DPagination\";\n\t}\n}\n"]}
@@ -1,5 +1,5 @@
1
1
  /*
2
- Winter Cardinal UI v0.407.2
2
+ Winter Cardinal UI v0.408.0
3
3
  Copyright (C) 2019 Toshiba Corporation
4
4
  SPDX-License-Identifier: Apache-2.0
5
5
 
@@ -1,5 +1,5 @@
1
1
  /*
2
- Winter Cardinal UI v0.407.2
2
+ Winter Cardinal UI v0.408.0
3
3
  Copyright (C) 2019 Toshiba Corporation
4
4
  SPDX-License-Identifier: Apache-2.0
5
5
 
@@ -1,5 +1,5 @@
1
1
  /*
2
- Winter Cardinal UI v0.407.2
2
+ Winter Cardinal UI v0.408.0
3
3
  Copyright (C) 2019 Toshiba Corporation
4
4
  SPDX-License-Identifier: Apache-2.0
5
5
 
@@ -1,5 +1,5 @@
1
1
  /*
2
- Winter Cardinal UI v0.407.2
2
+ Winter Cardinal UI v0.408.0
3
3
  Copyright (C) 2019 Toshiba Corporation
4
4
  SPDX-License-Identifier: Apache-2.0
5
5
 
@@ -1,5 +1,5 @@
1
1
  /*
2
- Winter Cardinal UI v0.407.2
2
+ Winter Cardinal UI v0.408.0
3
3
  Copyright (C) 2019 Toshiba Corporation
4
4
  SPDX-License-Identifier: Apache-2.0
5
5
 
@@ -1,5 +1,5 @@
1
1
  /*
2
- Winter Cardinal UI v0.407.2
2
+ Winter Cardinal UI v0.408.0
3
3
  Copyright (C) 2019 Toshiba Corporation
4
4
  SPDX-License-Identifier: Apache-2.0
5
5
 
@@ -1,5 +1,5 @@
1
1
  /*
2
- Winter Cardinal UI v0.407.2
2
+ Winter Cardinal UI v0.408.0
3
3
  Copyright (C) 2019 Toshiba Corporation
4
4
  SPDX-License-Identifier: Apache-2.0
5
5
 
@@ -1,5 +1,5 @@
1
1
  /*
2
- Winter Cardinal UI v0.407.2
2
+ Winter Cardinal UI v0.408.0
3
3
  Copyright (C) 2019 Toshiba Corporation
4
4
  SPDX-License-Identifier: Apache-2.0
5
5
 
@@ -1,5 +1,5 @@
1
1
  /*
2
- Winter Cardinal UI v0.407.2
2
+ Winter Cardinal UI v0.408.0
3
3
  Copyright (C) 2019 Toshiba Corporation
4
4
  SPDX-License-Identifier: Apache-2.0
5
5
 
@@ -1,5 +1,5 @@
1
1
  /*
2
- Winter Cardinal UI v0.407.2
2
+ Winter Cardinal UI v0.408.0
3
3
  Copyright (C) 2019 Toshiba Corporation
4
4
  SPDX-License-Identifier: Apache-2.0
5
5
 
@@ -1,5 +1,5 @@
1
1
  /*
2
- Winter Cardinal UI v0.407.2
2
+ Winter Cardinal UI v0.408.0
3
3
  Copyright (C) 2019 Toshiba Corporation
4
4
  SPDX-License-Identifier: Apache-2.0
5
5
 
@@ -1,5 +1,5 @@
1
1
  /*
2
- Winter Cardinal UI v0.407.2
2
+ Winter Cardinal UI v0.408.0
3
3
  Copyright (C) 2019 Toshiba Corporation
4
4
  SPDX-License-Identifier: Apache-2.0
5
5
 
@@ -1,5 +1,5 @@
1
1
  /*
2
- Winter Cardinal UI v0.407.2
2
+ Winter Cardinal UI v0.408.0
3
3
  Copyright (C) 2019 Toshiba Corporation
4
4
  SPDX-License-Identifier: Apache-2.0
5
5
 
@@ -89443,16 +89443,38 @@ var DPagination = /** @class */ (function (_super) {
89443
89443
  return null;
89444
89444
  };
89445
89445
  DPagination.prototype.onButtonLastActive = function () {
89446
- this.moveTo(this._size - 1);
89446
+ this.goToLast();
89447
89447
  };
89448
- DPagination.prototype.moveTo = function (index) {
89448
+ /**
89449
+ * Goes to the last page.
89450
+ * Unlike {@link #value}, this method emits the change event if silently is not true.
89451
+ *
89452
+ * @param silently true to suppress the change event
89453
+ * @returns true if succeeded.
89454
+ */
89455
+ DPagination.prototype.goToLast = function (silently) {
89456
+ return this.goTo(this._size - 1, silently);
89457
+ };
89458
+ /**
89459
+ * Goes to the given page.
89460
+ * Unlike {@link #value}, this method emits the change event if silently is not true.
89461
+ *
89462
+ * @param index a page index
89463
+ * @param silently true to suppress the change event
89464
+ * @returns this
89465
+ */
89466
+ DPagination.prototype.goTo = function (index, silently) {
89449
89467
  if (0 <= index && index < this._size && this._value !== index) {
89450
89468
  var oldIndex = this._value;
89451
89469
  this._value = index;
89452
- this.emit("change", index, oldIndex, this);
89470
+ if (silently !== true) {
89471
+ this.emit("change", index, oldIndex, this);
89472
+ }
89453
89473
  this.toDirty();
89454
89474
  DApplications.update(this);
89475
+ return true;
89455
89476
  }
89477
+ return false;
89456
89478
  };
89457
89479
  Object.defineProperty(DPagination.prototype, "buttonNext", {
89458
89480
  get: function () {
@@ -89480,7 +89502,17 @@ var DPagination = /** @class */ (function (_super) {
89480
89502
  return null;
89481
89503
  };
89482
89504
  DPagination.prototype.onButtonNextActive = function () {
89483
- this.moveTo(this._value + 1);
89505
+ this.goToNext();
89506
+ };
89507
+ /**
89508
+ * Goes to the next page.
89509
+ * Unlike {@link #value}, this method emits the change event if silently is not true.
89510
+ *
89511
+ * @param silently true to suppress the change event
89512
+ * @returns true if succeeded.
89513
+ */
89514
+ DPagination.prototype.goToNext = function (silently) {
89515
+ return this.goTo(this._value + 1, silently);
89484
89516
  };
89485
89517
  Object.defineProperty(DPagination.prototype, "buttonPrevious", {
89486
89518
  get: function () {
@@ -89508,7 +89540,17 @@ var DPagination = /** @class */ (function (_super) {
89508
89540
  return null;
89509
89541
  };
89510
89542
  DPagination.prototype.onButtonPreviousActive = function () {
89511
- this.moveTo(this._value - 1);
89543
+ this.goToPrevious();
89544
+ };
89545
+ /**
89546
+ * Goes to the previous page.
89547
+ * Unlike {@link #value}, this method emits the change event if silently is not true.
89548
+ *
89549
+ * @param silently true to suppress the change event
89550
+ * @returns true if succeeded.
89551
+ */
89552
+ DPagination.prototype.goToPrevious = function (silently) {
89553
+ return this.goTo(this._value - 1, silently);
89512
89554
  };
89513
89555
  Object.defineProperty(DPagination.prototype, "buttonTop", {
89514
89556
  get: function () {
@@ -89536,7 +89578,17 @@ var DPagination = /** @class */ (function (_super) {
89536
89578
  return null;
89537
89579
  };
89538
89580
  DPagination.prototype.onButtonTopActive = function () {
89539
- this.moveTo(0);
89581
+ this.goToTop();
89582
+ };
89583
+ /**
89584
+ * Goes to the top page.
89585
+ * Unlike {@link #value}, this method emits the change event if silently is not true.
89586
+ *
89587
+ * @param silently true to suppress the change event
89588
+ * @returns true if succeeded.
89589
+ */
89590
+ DPagination.prototype.goToTop = function (silently) {
89591
+ return this.goTo(0, silently);
89540
89592
  };
89541
89593
  DPagination.prototype.newButtonPage = function () {
89542
89594
  var _this = this;
@@ -89626,7 +89678,7 @@ var DPagination = /** @class */ (function (_super) {
89626
89678
  DPagination.prototype.onButtonPageActive = function (button) {
89627
89679
  var text = button.text.value;
89628
89680
  if (isNumber(text)) {
89629
- this.moveTo(text - 1);
89681
+ this.goTo(text - 1);
89630
89682
  if (button.state.isFocused) {
89631
89683
  button.state.isHovered = false;
89632
89684
  this.page.focus();