@bbn/bbn 1.0.103 → 1.0.105
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/bundle.js +2 -10
- package/dist/fn/datetime/calendar.js +2 -10
- package/package.json +2 -2
package/dist/bundle.js
CHANGED
|
@@ -3691,11 +3691,10 @@
|
|
|
3691
3691
|
};
|
|
3692
3692
|
exports.fdate = fdate;
|
|
3693
3693
|
});
|
|
3694
|
-
define("fn/datetime/calendar", ["require", "exports", "fn/datetime/fdate", "fn/datetime/date", "fn/type/isDate", "fn/type/isString"
|
|
3694
|
+
define("fn/datetime/calendar", ["require", "exports", "../../../node_modules/dayjs/dayjs.min.js", "fn/datetime/fdate", "fn/datetime/date", "fn/type/isDate", "fn/type/isString"], function (require, exports, dayjs_min_js_1, fdate_js_1, date_js_3, isDate_js_5, isString_js_8) {
|
|
3695
3695
|
"use strict";
|
|
3696
3696
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3697
3697
|
exports.calendar = void 0;
|
|
3698
|
-
dayjs_min_js_1.default.extend(window['dayjs_plugin_calendar']);
|
|
3699
3698
|
const calendar = function (d, wrong_result = false) {
|
|
3700
3699
|
if (undefined === dayjs_min_js_1.default) {
|
|
3701
3700
|
return (0, fdate_js_1.fdate)(d, wrong_result);
|
|
@@ -3704,14 +3703,7 @@
|
|
|
3704
3703
|
if (!(0, isDate_js_5.isDate)(r)) {
|
|
3705
3704
|
return wrong_result && (0, isString_js_8.isString)(wrong_result) ? wrong_result : '';
|
|
3706
3705
|
}
|
|
3707
|
-
return
|
|
3708
|
-
sameDay: '[' + bbn._('Today') + ']',
|
|
3709
|
-
nextDay: '[' + bbn._('Tomorrow') + ']',
|
|
3710
|
-
nextWeek: 'ddd D',
|
|
3711
|
-
lastDay: '[' + bbn._('Yesterday') + ']',
|
|
3712
|
-
lastWeek: 'ddd D',
|
|
3713
|
-
sameElse: 'L',
|
|
3714
|
-
});
|
|
3706
|
+
return '';
|
|
3715
3707
|
};
|
|
3716
3708
|
exports.calendar = calendar;
|
|
3717
3709
|
});
|
|
@@ -1,9 +1,8 @@
|
|
|
1
|
+
import dayjs from '../../../node_modules/dayjs/dayjs.min.js';
|
|
1
2
|
import { fdate } from "./fdate.js";
|
|
2
3
|
import { date } from "./date.js";
|
|
3
4
|
import { isDate } from "../type/isDate.js";
|
|
4
5
|
import { isString } from "../type/isString.js";
|
|
5
|
-
import dayjs from '../../../node_modules/dayjs/dayjs.min.js';
|
|
6
|
-
dayjs.extend(window['dayjs_plugin_calendar']);
|
|
7
6
|
const calendar = function (d, wrong_result = false) {
|
|
8
7
|
if (undefined === dayjs) {
|
|
9
8
|
return fdate(d, wrong_result);
|
|
@@ -12,13 +11,6 @@ const calendar = function (d, wrong_result = false) {
|
|
|
12
11
|
if (!isDate(r)) {
|
|
13
12
|
return wrong_result && isString(wrong_result) ? wrong_result : '';
|
|
14
13
|
}
|
|
15
|
-
return
|
|
16
|
-
sameDay: '[' + bbn._('Today') + ']',
|
|
17
|
-
nextDay: '[' + bbn._('Tomorrow') + ']',
|
|
18
|
-
nextWeek: 'ddd D',
|
|
19
|
-
lastDay: '[' + bbn._('Yesterday') + ']',
|
|
20
|
-
lastWeek: 'ddd D',
|
|
21
|
-
sameElse: 'L',
|
|
22
|
-
});
|
|
14
|
+
return '';
|
|
23
15
|
};
|
|
24
16
|
export { calendar };
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@bbn/bbn",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.105",
|
|
4
4
|
"description": "Javascript toolkit",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"types": "dist/index.d.ts",
|
|
@@ -10,7 +10,7 @@
|
|
|
10
10
|
"type": "module",
|
|
11
11
|
"scripts": {
|
|
12
12
|
"bbn": "tsc && tsc-bundle tsconfig.json && git stage ./src/* && git stage ./*.ts && git stage ./*.json && git stage -f ./dist/* && git stage ./test/* && git commit -m \"Latest changes\" && git push && npm version patch && npm publish",
|
|
13
|
-
"test": "./node_modules/.bin/mocha",
|
|
13
|
+
"test": "./node_modules/.bin/mocha -r jsdom-global/register",
|
|
14
14
|
"wtf": "echo \"Error: no test specified\" && exit 1"
|
|
15
15
|
},
|
|
16
16
|
"keywords": [
|