@fctc/widget-logic 1.1.8 → 1.1.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/index.d.mts CHANGED
@@ -3,9 +3,6 @@ export { CloseIcon, EyeIcon, LoadingIcon } from './icons.mjs';
3
3
  import { IInputFieldProps, ValuePropsType } from './types.mjs';
4
4
  import * as react from 'react';
5
5
  import { ChangeEvent } from 'react';
6
- import day from 'react-datepicker/dist/day';
7
- import month from 'react-datepicker/dist/month';
8
- import year from 'react-datepicker/dist/year';
9
6
  import moment from 'moment';
10
7
  export { API_APP_URL, API_PRESCHOOL_URL, STORAGES, combineContexts, convertFieldsToArray, countSum, getDateRange, languages, mergeButtons, setStorageItemAsync, useGetRowIds, useStorageState } from './utils.mjs';
11
8
  import '@tanstack/react-query';
@@ -187,9 +184,6 @@ declare const dateFieldController: (props: IDateFieldProps) => {
187
184
  customValidateMinMax: (date: any) => string | false;
188
185
  minNowValue: boolean | moment.Moment | null;
189
186
  maxNowValue: boolean | moment.Moment | null;
190
- year: typeof year;
191
- month: typeof month;
192
- day: typeof day;
193
187
  };
194
188
 
195
189
  declare const copyLinkButtonController: (props: IInputFieldProps) => {
package/dist/index.d.ts CHANGED
@@ -3,9 +3,6 @@ export { CloseIcon, EyeIcon, LoadingIcon } from './icons.js';
3
3
  import { IInputFieldProps, ValuePropsType } from './types.js';
4
4
  import * as react from 'react';
5
5
  import { ChangeEvent } from 'react';
6
- import day from 'react-datepicker/dist/day';
7
- import month from 'react-datepicker/dist/month';
8
- import year from 'react-datepicker/dist/year';
9
6
  import moment from 'moment';
10
7
  export { API_APP_URL, API_PRESCHOOL_URL, STORAGES, combineContexts, convertFieldsToArray, countSum, getDateRange, languages, mergeButtons, setStorageItemAsync, useGetRowIds, useStorageState } from './utils.js';
11
8
  import '@tanstack/react-query';
@@ -187,9 +184,6 @@ declare const dateFieldController: (props: IDateFieldProps) => {
187
184
  customValidateMinMax: (date: any) => string | false;
188
185
  minNowValue: boolean | moment.Moment | null;
189
186
  maxNowValue: boolean | moment.Moment | null;
190
- year: typeof year;
191
- month: typeof month;
192
- day: typeof day;
193
187
  };
194
188
 
195
189
  declare const copyLinkButtonController: (props: IInputFieldProps) => {
package/dist/index.js CHANGED
@@ -641,8 +641,8 @@ var require_moment = __commonJS({
641
641
  tokens[token2](input, config._a, config, token2);
642
642
  }
643
643
  }
644
- function isLeapYear(year2) {
645
- return year2 % 4 === 0 && year2 % 100 !== 0 || year2 % 400 === 0;
644
+ function isLeapYear(year) {
645
+ return year % 4 === 0 && year % 100 !== 0 || year % 400 === 0;
646
646
  }
647
647
  var YEAR = 0, MONTH = 1, DATE = 2, HOUR = 3, MINUTE = 4, SECOND = 5, MILLISECOND = 6, WEEK = 7, WEEKDAY = 8;
648
648
  addFormatToken("Y", 0, 0, function() {
@@ -670,8 +670,8 @@ var require_moment = __commonJS({
670
670
  addParseToken("Y", function(input, array) {
671
671
  array[YEAR] = parseInt(input, 10);
672
672
  });
673
- function daysInYear(year2) {
674
- return isLeapYear(year2) ? 366 : 365;
673
+ function daysInYear(year) {
674
+ return isLeapYear(year) ? 366 : 365;
675
675
  }
676
676
  hooks.parseTwoDigitYear = function(input) {
677
677
  return toInt(input) + (toInt(input) > 68 ? 1900 : 2e3);
@@ -718,7 +718,7 @@ var require_moment = __commonJS({
718
718
  }
719
719
  }
720
720
  function set$1(mom, unit, value) {
721
- var d, isUTC, year2, month2, date;
721
+ var d, isUTC, year, month, date;
722
722
  if (!mom.isValid() || isNaN(value)) {
723
723
  return;
724
724
  }
@@ -745,11 +745,11 @@ var require_moment = __commonJS({
745
745
  default:
746
746
  return;
747
747
  }
748
- year2 = value;
749
- month2 = mom.month();
748
+ year = value;
749
+ month = mom.month();
750
750
  date = mom.date();
751
- date = date === 29 && month2 === 1 && !isLeapYear(year2) ? 28 : date;
752
- void (isUTC ? d.setUTCFullYear(year2, month2, date) : d.setFullYear(year2, month2, date));
751
+ date = date === 29 && month === 1 && !isLeapYear(year) ? 28 : date;
752
+ void (isUTC ? d.setUTCFullYear(year, month, date) : d.setFullYear(year, month, date));
753
753
  }
754
754
  function stringGet(units) {
755
755
  units = normalizeUnits(units);
@@ -790,13 +790,13 @@ var require_moment = __commonJS({
790
790
  return -1;
791
791
  };
792
792
  }
793
- function daysInMonth(year2, month2) {
794
- if (isNaN(year2) || isNaN(month2)) {
793
+ function daysInMonth(year, month) {
794
+ if (isNaN(year) || isNaN(month)) {
795
795
  return NaN;
796
796
  }
797
- var modMonth = mod(month2, 12);
798
- year2 += (month2 - modMonth) / 12;
799
- return modMonth === 1 ? isLeapYear(year2) ? 29 : 28 : 31 - modMonth % 7 % 2;
797
+ var modMonth = mod(month, 12);
798
+ year += (month - modMonth) / 12;
799
+ return modMonth === 1 ? isLeapYear(year) ? 29 : 28 : 31 - modMonth % 7 % 2;
800
800
  }
801
801
  addFormatToken("M", ["MM", 2], "Mo", function() {
802
802
  return this.month() + 1;
@@ -819,9 +819,9 @@ var require_moment = __commonJS({
819
819
  array[MONTH] = toInt(input) - 1;
820
820
  });
821
821
  addParseToken(["MMM", "MMMM"], function(input, array, config, token2) {
822
- var month2 = config._locale.monthsParse(input, token2, config._strict);
823
- if (month2 != null) {
824
- array[MONTH] = month2;
822
+ var month = config._locale.monthsParse(input, token2, config._strict);
823
+ if (month != null) {
824
+ array[MONTH] = month;
825
825
  } else {
826
826
  getParsingFlags(config).invalidMonth = input;
827
827
  }
@@ -931,9 +931,9 @@ var require_moment = __commonJS({
931
931
  }
932
932
  }
933
933
  }
934
- var month2 = value, date = mom.date();
935
- date = date < 29 ? date : Math.min(date, daysInMonth(mom.year(), month2));
936
- void (mom._isUTC ? mom._d.setUTCMonth(month2, date) : mom._d.setMonth(month2, date));
934
+ var month = value, date = mom.date();
935
+ date = date < 29 ? date : Math.min(date, daysInMonth(mom.year(), month));
936
+ void (mom._isUTC ? mom._d.setUTCMonth(month, date) : mom._d.setMonth(month, date));
937
937
  return mom;
938
938
  }
939
939
  function getSetMonth(value) {
@@ -1036,20 +1036,20 @@ var require_moment = __commonJS({
1036
1036
  }
1037
1037
  return date;
1038
1038
  }
1039
- function firstWeekOffset(year2, dow, doy) {
1040
- var fwd = 7 + dow - doy, fwdlw = (7 + createUTCDate(year2, 0, fwd).getUTCDay() - dow) % 7;
1039
+ function firstWeekOffset(year, dow, doy) {
1040
+ var fwd = 7 + dow - doy, fwdlw = (7 + createUTCDate(year, 0, fwd).getUTCDay() - dow) % 7;
1041
1041
  return -fwdlw + fwd - 1;
1042
1042
  }
1043
- function dayOfYearFromWeeks(year2, week, weekday, dow, doy) {
1044
- var localWeekday = (7 + weekday - dow) % 7, weekOffset = firstWeekOffset(year2, dow, doy), dayOfYear = 1 + 7 * (week - 1) + localWeekday + weekOffset, resYear, resDayOfYear;
1043
+ function dayOfYearFromWeeks(year, week, weekday, dow, doy) {
1044
+ var localWeekday = (7 + weekday - dow) % 7, weekOffset = firstWeekOffset(year, dow, doy), dayOfYear = 1 + 7 * (week - 1) + localWeekday + weekOffset, resYear, resDayOfYear;
1045
1045
  if (dayOfYear <= 0) {
1046
- resYear = year2 - 1;
1046
+ resYear = year - 1;
1047
1047
  resDayOfYear = daysInYear(resYear) + dayOfYear;
1048
- } else if (dayOfYear > daysInYear(year2)) {
1049
- resYear = year2 + 1;
1050
- resDayOfYear = dayOfYear - daysInYear(year2);
1048
+ } else if (dayOfYear > daysInYear(year)) {
1049
+ resYear = year + 1;
1050
+ resDayOfYear = dayOfYear - daysInYear(year);
1051
1051
  } else {
1052
- resYear = year2;
1052
+ resYear = year;
1053
1053
  resDayOfYear = dayOfYear;
1054
1054
  }
1055
1055
  return {
@@ -1074,9 +1074,9 @@ var require_moment = __commonJS({
1074
1074
  year: resYear
1075
1075
  };
1076
1076
  }
1077
- function weeksInYear(year2, dow, doy) {
1078
- var weekOffset = firstWeekOffset(year2, dow, doy), weekOffsetNext = firstWeekOffset(year2 + 1, dow, doy);
1079
- return (daysInYear(year2) - weekOffset + weekOffsetNext) / 7;
1077
+ function weeksInYear(year, dow, doy) {
1078
+ var weekOffset = firstWeekOffset(year, dow, doy), weekOffsetNext = firstWeekOffset(year + 1, dow, doy);
1079
+ return (daysInYear(year) - weekOffset + weekOffsetNext) / 7;
1080
1080
  }
1081
1081
  addFormatToken("w", ["ww", 2], "wo", "week");
1082
1082
  addFormatToken("W", ["WW", 2], "Wo", "isoWeek");
@@ -1294,12 +1294,12 @@ var require_moment = __commonJS({
1294
1294
  if (!this.isValid()) {
1295
1295
  return input != null ? this : NaN;
1296
1296
  }
1297
- var day2 = get(this, "Day");
1297
+ var day = get(this, "Day");
1298
1298
  if (input != null) {
1299
1299
  input = parseWeekday(input, this.localeData());
1300
- return this.add(input - day2, "d");
1300
+ return this.add(input - day, "d");
1301
1301
  } else {
1302
- return day2;
1302
+ return day;
1303
1303
  }
1304
1304
  }
1305
1305
  function getSetLocaleDayOfWeek(input) {
@@ -1796,13 +1796,13 @@ var require_moment = __commonJS({
1796
1796
  return result;
1797
1797
  }
1798
1798
  function untruncateYear(yearStr) {
1799
- var year2 = parseInt(yearStr, 10);
1800
- if (year2 <= 49) {
1801
- return 2e3 + year2;
1802
- } else if (year2 <= 999) {
1803
- return 1900 + year2;
1799
+ var year = parseInt(yearStr, 10);
1800
+ if (year <= 49) {
1801
+ return 2e3 + year;
1802
+ } else if (year <= 999) {
1803
+ return 1900 + year;
1804
1804
  }
1805
- return year2;
1805
+ return year;
1806
1806
  }
1807
1807
  function preprocessRFC2822(s) {
1808
1808
  return s.replace(/\([^()]*\)|[\n\t]/g, " ").replace(/(\s\s+)/g, " ").replace(/^\s\s*/, "").replace(/\s\s*$/, "");
@@ -2836,16 +2836,16 @@ var require_moment = __commonJS({
2836
2836
  if (!this.isValid()) {
2837
2837
  return "moment.invalid(/* " + this._i + " */)";
2838
2838
  }
2839
- var func = "moment", zone = "", prefix, year2, datetime, suffix;
2839
+ var func = "moment", zone = "", prefix, year, datetime, suffix;
2840
2840
  if (!this.isLocal()) {
2841
2841
  func = this.utcOffset() === 0 ? "moment.utc" : "moment.parseZone";
2842
2842
  zone = "Z";
2843
2843
  }
2844
2844
  prefix = "[" + func + '("]';
2845
- year2 = 0 <= this.year() && this.year() <= 9999 ? "YYYY" : "YYYYYY";
2845
+ year = 0 <= this.year() && this.year() <= 9999 ? "YYYY" : "YYYYYY";
2846
2846
  datetime = "-MM-DD[T]HH:mm:ss.SSS";
2847
2847
  suffix = zone + '[")]';
2848
- return this.format(prefix + year2 + datetime + suffix);
2848
+ return this.format(prefix + year + datetime + suffix);
2849
2849
  }
2850
2850
  function format(inputString) {
2851
2851
  if (!inputString) {
@@ -3184,12 +3184,12 @@ var require_moment = __commonJS({
3184
3184
  }
3185
3185
  }
3186
3186
  }
3187
- function localeErasConvertYear(era, year2) {
3187
+ function localeErasConvertYear(era, year) {
3188
3188
  var dir = era.since <= era.until ? 1 : -1;
3189
- if (year2 === void 0) {
3189
+ if (year === void 0) {
3190
3190
  return hooks(era.since).year();
3191
3191
  } else {
3192
- return hooks(era.since).year() + (year2 - era.offset) * dir;
3192
+ return hooks(era.since).year() + (year - era.offset) * dir;
3193
3193
  }
3194
3194
  }
3195
3195
  function getEraName() {
@@ -6037,9 +6037,6 @@ var downLoadBinaryController = (props) => {
6037
6037
  };
6038
6038
 
6039
6039
  // src/widget/basic/date-field/controller.ts
6040
- var import_day = __toESM(require("react-datepicker/dist/day"));
6041
- var import_month = __toESM(require("react-datepicker/dist/month"));
6042
- var import_year = __toESM(require("react-datepicker/dist/year"));
6043
6040
  var import_moment = __toESM(require_moment());
6044
6041
  var DURATIONS = {
6045
6042
  PAST: "past",
@@ -6147,10 +6144,7 @@ var dateFieldController = (props) => {
6147
6144
  months_en,
6148
6145
  customValidateMinMax,
6149
6146
  minNowValue,
6150
- maxNowValue,
6151
- year: import_year.default,
6152
- month: import_month.default,
6153
- day: import_day.default
6147
+ maxNowValue
6154
6148
  };
6155
6149
  };
6156
6150
 
package/dist/index.mjs CHANGED
@@ -641,8 +641,8 @@ var require_moment = __commonJS({
641
641
  tokens[token2](input, config._a, config, token2);
642
642
  }
643
643
  }
644
- function isLeapYear(year2) {
645
- return year2 % 4 === 0 && year2 % 100 !== 0 || year2 % 400 === 0;
644
+ function isLeapYear(year) {
645
+ return year % 4 === 0 && year % 100 !== 0 || year % 400 === 0;
646
646
  }
647
647
  var YEAR = 0, MONTH = 1, DATE = 2, HOUR = 3, MINUTE = 4, SECOND = 5, MILLISECOND = 6, WEEK = 7, WEEKDAY = 8;
648
648
  addFormatToken("Y", 0, 0, function() {
@@ -670,8 +670,8 @@ var require_moment = __commonJS({
670
670
  addParseToken("Y", function(input, array) {
671
671
  array[YEAR] = parseInt(input, 10);
672
672
  });
673
- function daysInYear(year2) {
674
- return isLeapYear(year2) ? 366 : 365;
673
+ function daysInYear(year) {
674
+ return isLeapYear(year) ? 366 : 365;
675
675
  }
676
676
  hooks.parseTwoDigitYear = function(input) {
677
677
  return toInt(input) + (toInt(input) > 68 ? 1900 : 2e3);
@@ -718,7 +718,7 @@ var require_moment = __commonJS({
718
718
  }
719
719
  }
720
720
  function set$1(mom, unit, value) {
721
- var d, isUTC, year2, month2, date;
721
+ var d, isUTC, year, month, date;
722
722
  if (!mom.isValid() || isNaN(value)) {
723
723
  return;
724
724
  }
@@ -745,11 +745,11 @@ var require_moment = __commonJS({
745
745
  default:
746
746
  return;
747
747
  }
748
- year2 = value;
749
- month2 = mom.month();
748
+ year = value;
749
+ month = mom.month();
750
750
  date = mom.date();
751
- date = date === 29 && month2 === 1 && !isLeapYear(year2) ? 28 : date;
752
- void (isUTC ? d.setUTCFullYear(year2, month2, date) : d.setFullYear(year2, month2, date));
751
+ date = date === 29 && month === 1 && !isLeapYear(year) ? 28 : date;
752
+ void (isUTC ? d.setUTCFullYear(year, month, date) : d.setFullYear(year, month, date));
753
753
  }
754
754
  function stringGet(units) {
755
755
  units = normalizeUnits(units);
@@ -790,13 +790,13 @@ var require_moment = __commonJS({
790
790
  return -1;
791
791
  };
792
792
  }
793
- function daysInMonth(year2, month2) {
794
- if (isNaN(year2) || isNaN(month2)) {
793
+ function daysInMonth(year, month) {
794
+ if (isNaN(year) || isNaN(month)) {
795
795
  return NaN;
796
796
  }
797
- var modMonth = mod(month2, 12);
798
- year2 += (month2 - modMonth) / 12;
799
- return modMonth === 1 ? isLeapYear(year2) ? 29 : 28 : 31 - modMonth % 7 % 2;
797
+ var modMonth = mod(month, 12);
798
+ year += (month - modMonth) / 12;
799
+ return modMonth === 1 ? isLeapYear(year) ? 29 : 28 : 31 - modMonth % 7 % 2;
800
800
  }
801
801
  addFormatToken("M", ["MM", 2], "Mo", function() {
802
802
  return this.month() + 1;
@@ -819,9 +819,9 @@ var require_moment = __commonJS({
819
819
  array[MONTH] = toInt(input) - 1;
820
820
  });
821
821
  addParseToken(["MMM", "MMMM"], function(input, array, config, token2) {
822
- var month2 = config._locale.monthsParse(input, token2, config._strict);
823
- if (month2 != null) {
824
- array[MONTH] = month2;
822
+ var month = config._locale.monthsParse(input, token2, config._strict);
823
+ if (month != null) {
824
+ array[MONTH] = month;
825
825
  } else {
826
826
  getParsingFlags(config).invalidMonth = input;
827
827
  }
@@ -931,9 +931,9 @@ var require_moment = __commonJS({
931
931
  }
932
932
  }
933
933
  }
934
- var month2 = value, date = mom.date();
935
- date = date < 29 ? date : Math.min(date, daysInMonth(mom.year(), month2));
936
- void (mom._isUTC ? mom._d.setUTCMonth(month2, date) : mom._d.setMonth(month2, date));
934
+ var month = value, date = mom.date();
935
+ date = date < 29 ? date : Math.min(date, daysInMonth(mom.year(), month));
936
+ void (mom._isUTC ? mom._d.setUTCMonth(month, date) : mom._d.setMonth(month, date));
937
937
  return mom;
938
938
  }
939
939
  function getSetMonth(value) {
@@ -1036,20 +1036,20 @@ var require_moment = __commonJS({
1036
1036
  }
1037
1037
  return date;
1038
1038
  }
1039
- function firstWeekOffset(year2, dow, doy) {
1040
- var fwd = 7 + dow - doy, fwdlw = (7 + createUTCDate(year2, 0, fwd).getUTCDay() - dow) % 7;
1039
+ function firstWeekOffset(year, dow, doy) {
1040
+ var fwd = 7 + dow - doy, fwdlw = (7 + createUTCDate(year, 0, fwd).getUTCDay() - dow) % 7;
1041
1041
  return -fwdlw + fwd - 1;
1042
1042
  }
1043
- function dayOfYearFromWeeks(year2, week, weekday, dow, doy) {
1044
- var localWeekday = (7 + weekday - dow) % 7, weekOffset = firstWeekOffset(year2, dow, doy), dayOfYear = 1 + 7 * (week - 1) + localWeekday + weekOffset, resYear, resDayOfYear;
1043
+ function dayOfYearFromWeeks(year, week, weekday, dow, doy) {
1044
+ var localWeekday = (7 + weekday - dow) % 7, weekOffset = firstWeekOffset(year, dow, doy), dayOfYear = 1 + 7 * (week - 1) + localWeekday + weekOffset, resYear, resDayOfYear;
1045
1045
  if (dayOfYear <= 0) {
1046
- resYear = year2 - 1;
1046
+ resYear = year - 1;
1047
1047
  resDayOfYear = daysInYear(resYear) + dayOfYear;
1048
- } else if (dayOfYear > daysInYear(year2)) {
1049
- resYear = year2 + 1;
1050
- resDayOfYear = dayOfYear - daysInYear(year2);
1048
+ } else if (dayOfYear > daysInYear(year)) {
1049
+ resYear = year + 1;
1050
+ resDayOfYear = dayOfYear - daysInYear(year);
1051
1051
  } else {
1052
- resYear = year2;
1052
+ resYear = year;
1053
1053
  resDayOfYear = dayOfYear;
1054
1054
  }
1055
1055
  return {
@@ -1074,9 +1074,9 @@ var require_moment = __commonJS({
1074
1074
  year: resYear
1075
1075
  };
1076
1076
  }
1077
- function weeksInYear(year2, dow, doy) {
1078
- var weekOffset = firstWeekOffset(year2, dow, doy), weekOffsetNext = firstWeekOffset(year2 + 1, dow, doy);
1079
- return (daysInYear(year2) - weekOffset + weekOffsetNext) / 7;
1077
+ function weeksInYear(year, dow, doy) {
1078
+ var weekOffset = firstWeekOffset(year, dow, doy), weekOffsetNext = firstWeekOffset(year + 1, dow, doy);
1079
+ return (daysInYear(year) - weekOffset + weekOffsetNext) / 7;
1080
1080
  }
1081
1081
  addFormatToken("w", ["ww", 2], "wo", "week");
1082
1082
  addFormatToken("W", ["WW", 2], "Wo", "isoWeek");
@@ -1294,12 +1294,12 @@ var require_moment = __commonJS({
1294
1294
  if (!this.isValid()) {
1295
1295
  return input != null ? this : NaN;
1296
1296
  }
1297
- var day2 = get(this, "Day");
1297
+ var day = get(this, "Day");
1298
1298
  if (input != null) {
1299
1299
  input = parseWeekday(input, this.localeData());
1300
- return this.add(input - day2, "d");
1300
+ return this.add(input - day, "d");
1301
1301
  } else {
1302
- return day2;
1302
+ return day;
1303
1303
  }
1304
1304
  }
1305
1305
  function getSetLocaleDayOfWeek(input) {
@@ -1796,13 +1796,13 @@ var require_moment = __commonJS({
1796
1796
  return result;
1797
1797
  }
1798
1798
  function untruncateYear(yearStr) {
1799
- var year2 = parseInt(yearStr, 10);
1800
- if (year2 <= 49) {
1801
- return 2e3 + year2;
1802
- } else if (year2 <= 999) {
1803
- return 1900 + year2;
1799
+ var year = parseInt(yearStr, 10);
1800
+ if (year <= 49) {
1801
+ return 2e3 + year;
1802
+ } else if (year <= 999) {
1803
+ return 1900 + year;
1804
1804
  }
1805
- return year2;
1805
+ return year;
1806
1806
  }
1807
1807
  function preprocessRFC2822(s) {
1808
1808
  return s.replace(/\([^()]*\)|[\n\t]/g, " ").replace(/(\s\s+)/g, " ").replace(/^\s\s*/, "").replace(/\s\s*$/, "");
@@ -2836,16 +2836,16 @@ var require_moment = __commonJS({
2836
2836
  if (!this.isValid()) {
2837
2837
  return "moment.invalid(/* " + this._i + " */)";
2838
2838
  }
2839
- var func = "moment", zone = "", prefix, year2, datetime, suffix;
2839
+ var func = "moment", zone = "", prefix, year, datetime, suffix;
2840
2840
  if (!this.isLocal()) {
2841
2841
  func = this.utcOffset() === 0 ? "moment.utc" : "moment.parseZone";
2842
2842
  zone = "Z";
2843
2843
  }
2844
2844
  prefix = "[" + func + '("]';
2845
- year2 = 0 <= this.year() && this.year() <= 9999 ? "YYYY" : "YYYYYY";
2845
+ year = 0 <= this.year() && this.year() <= 9999 ? "YYYY" : "YYYYYY";
2846
2846
  datetime = "-MM-DD[T]HH:mm:ss.SSS";
2847
2847
  suffix = zone + '[")]';
2848
- return this.format(prefix + year2 + datetime + suffix);
2848
+ return this.format(prefix + year + datetime + suffix);
2849
2849
  }
2850
2850
  function format(inputString) {
2851
2851
  if (!inputString) {
@@ -3184,12 +3184,12 @@ var require_moment = __commonJS({
3184
3184
  }
3185
3185
  }
3186
3186
  }
3187
- function localeErasConvertYear(era, year2) {
3187
+ function localeErasConvertYear(era, year) {
3188
3188
  var dir = era.since <= era.until ? 1 : -1;
3189
- if (year2 === void 0) {
3189
+ if (year === void 0) {
3190
3190
  return hooks(era.since).year();
3191
3191
  } else {
3192
- return hooks(era.since).year() + (year2 - era.offset) * dir;
3192
+ return hooks(era.since).year() + (year - era.offset) * dir;
3193
3193
  }
3194
3194
  }
3195
3195
  function getEraName() {
@@ -6063,9 +6063,6 @@ var downLoadBinaryController = (props) => {
6063
6063
 
6064
6064
  // src/widget/basic/date-field/controller.ts
6065
6065
  var import_moment = __toESM(require_moment());
6066
- import day from "react-datepicker/dist/day";
6067
- import month from "react-datepicker/dist/month";
6068
- import year from "react-datepicker/dist/year";
6069
6066
  var DURATIONS = {
6070
6067
  PAST: "past",
6071
6068
  NOW: "now",
@@ -6172,10 +6169,7 @@ var dateFieldController = (props) => {
6172
6169
  months_en,
6173
6170
  customValidateMinMax,
6174
6171
  minNowValue,
6175
- maxNowValue,
6176
- year,
6177
- month,
6178
- day
6172
+ maxNowValue
6179
6173
  };
6180
6174
  };
6181
6175
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@fctc/widget-logic",
3
- "version": "1.1.8",
3
+ "version": "1.1.9",
4
4
  "types": "dist/index.d.ts",
5
5
  "main": "dist/index.cjs",
6
6
  "module": "dist/index.mjs",
@@ -50,7 +50,6 @@
50
50
  "@types/react-dom": "^19.1.7",
51
51
  "i18next": "^25.3.2",
52
52
  "i18next-browser-languagedetector": "^8.2.0",
53
- "react-datepicker": "^8.4.0",
54
53
  "react-dom": "^19.1.1",
55
54
  "react-i18next": "^15.6.1",
56
55
  "react-tooltip": "^5.29.1"