Skip to content

Commit 0c923cc

Browse files
committed
Updates build files
1 parent 8a6b379 commit 0c923cc

3 files changed

Lines changed: 109 additions & 5 deletions

File tree

public/cui.js

Lines changed: 20 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -43079,7 +43079,7 @@ CUI.DateTimeRangeGrammar = (function() {
4307943079
};
4308043080

4308143081
DateTimeRangeGrammar.stringToDateRange = function(input, locale) {
43082-
var _, extraArguments, from, grammar, grammars, i, j, len, len1, method, methodArguments, output, ref, ref1, ref2, s, stringToParse, to, tokenPositions, tokens, type, value;
43082+
var _, extraArguments, from, grammar, grammars, i, j, len, len1, method, methodArguments, monthIndex, output, ref, ref1, ref2, s, stringToParse, to, tokenPositions, tokens, type, value;
4308343083
if (locale == null) {
4308443084
locale = CUI.DateTime.getLocale();
4308543085
}
@@ -43108,10 +43108,10 @@ CUI.DateTimeRangeGrammar = (function() {
4310843108
value = s.split(".")[0];
4310943109
} else if (CUI.DateTimeRangeGrammar.REGEXP_CENTURY.test(s)) {
4311043110
type = CUI.DateTimeRangeGrammar.TYPE_CENTURY;
43111-
value = s.split("th")[0];
43112-
} else if (indexOf.call(CUI.DateTimeRangeGrammar.MONTHS[locale], value) >= 0) {
43111+
value = s.split(/th/i)[0];
43112+
} else if ((monthIndex = CUI.DateTimeRangeGrammar.__findMonthIndex(s, locale)) >= 0) {
4311343113
type = CUI.DateTimeRangeGrammar.TYPE_MONTH;
43114-
value = CUI.DateTimeRangeGrammar.MONTHS[locale].indexOf(value);
43114+
value = monthIndex;
4311543115
} else {
4311643116
type = s;
4311743117
}
@@ -43432,6 +43432,22 @@ CUI.DateTimeRangeGrammar = (function() {
4343243432
return "-" + inputString;
4343343433
};
4343443434

43435+
DateTimeRangeGrammar.__findMonthIndex = function(value, locale) {
43436+
var i, index, len, lowerValue, month, months;
43437+
lowerValue = value.toLowerCase();
43438+
months = CUI.DateTimeRangeGrammar.MONTHS[locale];
43439+
if (!months) {
43440+
return -1;
43441+
}
43442+
for (index = i = 0, len = months.length; i < len; index = ++i) {
43443+
month = months[index];
43444+
if (month.toLowerCase() === lowerValue) {
43445+
return index;
43446+
}
43447+
}
43448+
return -1;
43449+
};
43450+
4343543451
return DateTimeRangeGrammar;
4343643452

4343743453
})();

public/cui.min.js

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

public/cui_fylr.css

Lines changed: 88 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)