MCPcopy Create free account
hub / github.com/UI5/webcomponents / _modifyTimestampBy

Method _modifyTimestampBy

packages/main/src/MonthPicker.ts:349–356  ·  view source on GitHub ↗

* Modifies timestamp by a given amount of months and, * if necessary, loads the prev/next page. * @param amount * @param preserveDate whether to preserve the day of the month (f.e. 15th of March + 1 month = 15th of April) * @private

(amount: number, preserveDate?: boolean)

Source from the content-addressed store, hash-verified

347 * @private
348 */
349 _modifyTimestampBy(amount: number, preserveDate?: boolean) {
350 // Modify the current timestamp
351 this._safelyModifyTimestampBy(amount, "month", preserveDate);
352 this._updateSecondTimestamp();
353
354 // Notify the calendar to update its timestamp
355 this.fireDecoratorEvent("navigate", { timestamp: this.timestamp! });
356 }
357
358 _onkeyup(e: KeyboardEvent) {
359 if (isSpace(e)) {

Callers 3

_onkeydownMethod · 0.95
_showPreviousPageMethod · 0.95
_showNextPageMethod · 0.95

Calls 2

Tested by

no test coverage detected