@capillarytech/blaze-ui 4.33.7 → 4.33.9
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/CapCollapsibleNavbar/index.js +43 -0
- package/dist/CapCollapsibleNavbar/index.js.map +1 -1
- package/dist/CapCondition/index.js +43 -0
- package/dist/CapCondition/index.js.map +1 -1
- package/dist/CapDatePicker/index.js +43 -0
- package/dist/CapDatePicker/index.js.map +1 -1
- package/dist/CapDateTimePicker/index.js +43 -0
- package/dist/CapDateTimePicker/index.js.map +1 -1
- package/dist/CapDateTimeRangePicker/index.js +43 -0
- package/dist/CapDateTimeRangePicker/index.js.map +1 -1
- package/dist/CapEventCalendar/index.js +43 -0
- package/dist/CapEventCalendar/index.js.map +1 -1
- package/dist/CapLanguageProvider/index.js +43 -0
- package/dist/CapLanguageProvider/index.js.map +1 -1
- package/dist/CapNotificationDropdown/index.js +43 -0
- package/dist/CapNotificationDropdown/index.js.map +1 -1
- package/dist/CapTimePicker/index.js +43 -0
- package/dist/CapTimePicker/index.js.map +1 -1
- package/dist/index.js +43 -0
- package/dist/index.js.map +1 -1
- package/dist/utils/dayjs.d.ts.map +1 -1
- package/package.json +3 -2
|
@@ -4125,6 +4125,49 @@ _dayjs.default.extend(_utc.default);
|
|
|
4125
4125
|
_dayjs.default.extend(_dayjsTimezoneIanaPlugin.default);
|
|
4126
4126
|
_dayjs.default.extend(_dayjsAbbrTimezone.default);
|
|
4127
4127
|
|
|
4128
|
+
// Verify timezone plugin was properly extended immediately after extending
|
|
4129
|
+
// This ensures we catch issues early and helps with webpack bundling
|
|
4130
|
+
const testInstance = (0, _dayjs.default)();
|
|
4131
|
+
if (typeof testInstance.tz !== 'function') {
|
|
4132
|
+
console.error('[dayjs-timezone-iana-plugin] CRITICAL: Plugin not properly extended!', 'dayjs().tz type:', typeof testInstance.tz, 'This indicates the plugin extension failed. Check plugin import and order.');
|
|
4133
|
+
// Try to re-extend as a fallback (shouldn't be necessary, but helps with bundling issues)
|
|
4134
|
+
try {
|
|
4135
|
+
_dayjs.default.extend(_dayjsTimezoneIanaPlugin.default);
|
|
4136
|
+
const retestInstance = (0, _dayjs.default)();
|
|
4137
|
+
if (typeof retestInstance.tz === 'function') {
|
|
4138
|
+
console.warn('[dayjs-timezone-iana-plugin] Plugin extension succeeded on retry.');
|
|
4139
|
+
}
|
|
4140
|
+
} catch (error) {
|
|
4141
|
+
console.error('[dayjs-timezone-iana-plugin] Failed to extend plugin:', error);
|
|
4142
|
+
}
|
|
4143
|
+
}
|
|
4144
|
+
|
|
4145
|
+
// dayjs-timezone-iana-plugin only provides instance method dayjs().tz(), not static dayjs.tz()
|
|
4146
|
+
// Add a static wrapper function to match the API used throughout the codebase
|
|
4147
|
+
// Check if dayjs.tz is callable as a function (it might be an object with setDefault)
|
|
4148
|
+
const tzIsCallable = typeof _dayjs.default.tz === 'function';
|
|
4149
|
+
if (!tzIsCallable) {
|
|
4150
|
+
// Preserve existing properties (like setDefault) if they exist
|
|
4151
|
+
const existingTz = _dayjs.default.tz;
|
|
4152
|
+
const existingSetDefault = existingTz && typeof existingTz.setDefault === 'function' ? existingTz.setDefault : null;
|
|
4153
|
+
|
|
4154
|
+
// Create a static tz function that wraps the instance method
|
|
4155
|
+
// This wrapper ensures dayjs.tz() works even if the instance method is available
|
|
4156
|
+
_dayjs.default.tz = function (date, tzName) {
|
|
4157
|
+
// Verify instance method is available before using it
|
|
4158
|
+
const instance = !date ? (0, _dayjs.default)() : _dayjs.default.isDayjs(date) ? date : (0, _dayjs.default)(date);
|
|
4159
|
+
if (typeof instance.tz !== 'function') {
|
|
4160
|
+
throw new Error('dayjs().tz() is not available. The timezone plugin may not be properly extended. ' + 'Check that dayjs-timezone-iana-plugin is correctly imported and extended.');
|
|
4161
|
+
}
|
|
4162
|
+
return instance.tz(tzName);
|
|
4163
|
+
};
|
|
4164
|
+
|
|
4165
|
+
// Restore setDefault if it existed
|
|
4166
|
+
if (existingSetDefault) {
|
|
4167
|
+
_dayjs.default.tz.setDefault = existingSetDefault;
|
|
4168
|
+
}
|
|
4169
|
+
}
|
|
4170
|
+
|
|
4128
4171
|
// Core functionality plugins
|
|
4129
4172
|
_dayjs.default.extend(_relativeTime.default);
|
|
4130
4173
|
_dayjs.default.extend(_customParseFormat.default);
|