102 lines
2.6 KiB
JavaScript
102 lines
2.6 KiB
JavaScript
// Module ID: 3717
|
|
// Function ID: 3718
|
|
// Name: startOfUTCWeekYear
|
|
// Dependencies: [3718, 3477, 3479, 3480, 3481]
|
|
// Exports: default
|
|
|
|
// Module 3717 (startOfUTCWeekYear)
|
|
import getDefaultOptions from "getDefaultOptions" /* 3481 */;
|
|
import getUTCWeekYear from "getUTCWeekYear" /* 3718 */;
|
|
import requiredArgs from "requiredArgs" /* 3477 */;
|
|
import startOfUTCWeek from "startOfUTCWeek" /* 3479 */;
|
|
import toInteger from "toInteger" /* 3480 */;
|
|
|
|
if (!getUTCWeekYear) {
|
|
let obj = { default: null };
|
|
obj[0] = getUTCWeekYear;
|
|
let tmp3 = obj;
|
|
} else {
|
|
tmp3 = getUTCWeekYear;
|
|
}
|
|
getUTCWeekYear = tmp3;
|
|
if (!requiredArgs) {
|
|
obj = { default: null };
|
|
obj[0] = requiredArgs;
|
|
let tmp5 = obj;
|
|
} else {
|
|
tmp5 = requiredArgs;
|
|
}
|
|
requiredArgs = tmp5;
|
|
if (!startOfUTCWeek) {
|
|
obj = { default: null };
|
|
obj[0] = startOfUTCWeek;
|
|
let tmp7 = obj;
|
|
} else {
|
|
tmp7 = startOfUTCWeek;
|
|
}
|
|
startOfUTCWeek = tmp7;
|
|
if (!toInteger) {
|
|
const obj1 = { default: null };
|
|
obj1[0] = toInteger;
|
|
let tmp9 = obj1;
|
|
} else {
|
|
tmp9 = toInteger;
|
|
}
|
|
toInteger = tmp9;
|
|
|
|
export default function startOfUTCWeekYear(arg0, firstWeekContainsDate) {
|
|
requiredArgs.default(1, arguments);
|
|
const defaultOptions = getDefaultOptions.getDefaultOptions();
|
|
let prop;
|
|
if (null != firstWeekContainsDate) {
|
|
prop = firstWeekContainsDate.firstWeekContainsDate;
|
|
}
|
|
if (null === prop) {
|
|
let prop1;
|
|
if (null != firstWeekContainsDate) {
|
|
const locale = firstWeekContainsDate.locale;
|
|
if (null !== locale) {
|
|
if (undefined !== locale) {
|
|
const options = locale.options;
|
|
if (null !== options) {
|
|
if (undefined !== options) {
|
|
prop1 = options.firstWeekContainsDate;
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
prop = prop1;
|
|
}
|
|
if (null === prop) {
|
|
prop = defaultOptions.firstWeekContainsDate;
|
|
}
|
|
if (null === prop) {
|
|
const locale2 = defaultOptions.locale;
|
|
let prop2;
|
|
if (null !== locale2) {
|
|
if (undefined !== locale2) {
|
|
const options2 = locale2.options;
|
|
if (null !== options2) {
|
|
if (undefined !== options2) {
|
|
prop2 = options2.firstWeekContainsDate;
|
|
}
|
|
}
|
|
}
|
|
}
|
|
prop = prop2;
|
|
}
|
|
let num = 1;
|
|
if (null !== prop) {
|
|
num = 1;
|
|
if (undefined !== prop) {
|
|
num = prop;
|
|
}
|
|
}
|
|
const defaultResult1 = toInteger.default(num);
|
|
const date = new Date(0);
|
|
date.setUTCFullYear(getUTCWeekYear.default(arg0, firstWeekContainsDate), 0, defaultResult1);
|
|
date.setUTCHours(0, 0, 0, 0);
|
|
return startOfUTCWeek.default(date, firstWeekContainsDate);
|
|
};
|
|
export default exports.default;
|