@bbn/bbn 2.0.69 → 2.0.70
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.
- package/dist/bbn.js +1 -1
- package/dist/bbn.js.map +1 -1
- package/dist/dt/classes/dt.d.ts +1 -0
- package/dist/dt/classes/dt.js +7 -0
- package/package.json +1 -1
package/dist/dt/classes/dt.d.ts
CHANGED
|
@@ -84,6 +84,7 @@ export declare abstract class bbnDt<TValue extends bbnDtTemporal> {
|
|
|
84
84
|
get WW(): string;
|
|
85
85
|
get W(): string;
|
|
86
86
|
format(format?: string): string;
|
|
87
|
+
getWeekday(mode?: string, locale?: string): string;
|
|
87
88
|
/**
|
|
88
89
|
* Returns a NEW date that is the next (or previous if past=true)
|
|
89
90
|
* occurrence of the given weekday, starting from this.#value.
|
package/dist/dt/classes/dt.js
CHANGED
|
@@ -521,6 +521,13 @@ export class bbnDt {
|
|
|
521
521
|
}
|
|
522
522
|
return str;
|
|
523
523
|
}
|
|
524
|
+
getWeekday(mode = 'long', locale) {
|
|
525
|
+
const wd = this.weekday();
|
|
526
|
+
if (typeof wd === 'number') {
|
|
527
|
+
return getWeekday(wd, mode, locale);
|
|
528
|
+
}
|
|
529
|
+
return undefined;
|
|
530
|
+
}
|
|
524
531
|
/**
|
|
525
532
|
* Returns a NEW date that is the next (or previous if past=true)
|
|
526
533
|
* occurrence of the given weekday, starting from this.#value.
|