Skip to content

Commit f77e210

Browse files
author
pipeline
committed
v24.2.3 is released
1 parent 6c06881 commit f77e210

File tree

224 files changed

+4321
-1075
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

224 files changed

+4321
-1075
lines changed

controls/barcodegenerator/CHANGELOG.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
## [Unreleased]
44

5-
## 24.1.47 (2024-01-23)
5+
## 24.2.3 (2024-01-31)
66

77
### Barcode
88

controls/base/CHANGELOG.md

+14
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,20 @@
22

33
## [Unreleased]
44

5+
## 24.2.3 (2024-01-31)
6+
7+
### Common
8+
9+
#### Bug Fixes
10+
11+
- `#I547507` - The issue with "rendering the new line in the html template string" has been resolved.
12+
13+
### Common
14+
15+
#### Bug Fixes
16+
17+
- `#I541838` - Resolved issue with time picker designator "pm" is automatically flips to "am".
18+
519
## 24.1.46 (2024-01-17)
620

721
### Common

controls/base/releasenotes/README.md

-183
This file was deleted.

controls/base/spec/base.spec.ts

+19-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
/**
22
* Library Spec
33
*/
4-
import { Base, getComponent, removeChildInstance } from '../src/base';
4+
import { Base, getComponent, removeChildInstance, DomElements, setProxyToRaw } from '../src/base';
55
import { NotifyPropertyChanges, INotifyPropertyChanged, Event, Property } from '../src/notify-property-change';
66
import { createElement } from '../src/dom';
77
import { Touch } from '../src/touch';
@@ -86,6 +86,24 @@ describe('Library', (): void => {
8686
obj.destroy();
8787
expect(obj.isDestroyed).toEqual(true);
8888
});
89+
it('destroy Vue instance', () => {
90+
let vueEle: HTMLElement = createElement('div', { id: 'singleEle', styles: 'height:100px;width:100px;' });
91+
let reactive = function (instance: DemoClass) {
92+
instance['__reactive'] = true;
93+
return instance;
94+
}
95+
let toRaw = function (instance: DemoClass) {
96+
delete instance['__reactive'];
97+
return instance;
98+
}
99+
setProxyToRaw(toRaw);
100+
let vueObj: DemoClass = reactive(new DemoClass(vueEle));
101+
expect((<DomElements>vueObj.element).ej2_instances.length).toEqual(1);
102+
expect(vueObj.isDestroyed).toEqual(false);
103+
vueObj.destroy();
104+
expect(vueObj.isDestroyed).toEqual(true);
105+
expect((<DomElements>vueObj.element).ej2_instances.length).toEqual(0);
106+
});
89107
});
90108

91109
describe('event binding', (): void => {

controls/base/spec/template.spec.ts

+8
Original file line numberDiff line numberDiff line change
@@ -178,6 +178,14 @@ describe('Template', () => {
178178
expect(templateResult).toEqual(result);
179179
});
180180

181+
it('new line in the template string', () => {
182+
var data = { name: `Aston Martin\n Car Models` };
183+
let templateStr: string = "<div>"+data.name+"</div>";
184+
let getString: any = template.compile(templateStr);
185+
let output: any = getString(templateStr);
186+
expect(output).toEqual("<div>Aston Martin Car Models</div>");
187+
});
188+
181189
it('JSON array input with href value with apostrophe', () => {
182190
let templateStr: string = `<div><a href='https://en.wikipedia.org/wiki/France'>France</a><a href='/Projects/Details?id=VINET'>VINET</a></div>`;
183191
let getString: any = template.compile(templateStr);

controls/base/src/base.ts

+8-1
Original file line numberDiff line numberDiff line change
@@ -284,7 +284,12 @@ export abstract class Base<ElementType extends HTMLElement> {
284284
protected destroy(): void {
285285
// eslint-disable-next-line
286286
(<DomElements>(this.element as HTMLElement)).ej2_instances =
287-
(<DomElements>(this.element as HTMLElement)).ej2_instances ? (<DomElements>(this.element as HTMLElement)).ej2_instances.filter((i: Object) => { return i !== this; })
287+
(<DomElements>(this.element as HTMLElement)).ej2_instances ? (<DomElements>(this.element as HTMLElement)).ej2_instances.filter((i: Object) => {
288+
if (proxyToRaw) {
289+
return proxyToRaw(i) !== proxyToRaw(this);
290+
}
291+
return i !== this;
292+
})
288293
: [];
289294
removeClass([this.element], ['e-' + this.getModuleName()]);
290295
if ((<DomElements>(this.element as HTMLElement)).ej2_instances.length === 0) {
@@ -346,3 +351,5 @@ export function removeChildInstance(element: HTMLElement): void {
346351
}
347352
}
348353
}
354+
355+
export let proxyToRaw: Function, setProxyToRaw = (toRaw: Function): void => { proxyToRaw = toRaw };

controls/base/src/intl/date-parser.ts

+3-1
Original file line numberDiff line numberDiff line change
@@ -366,10 +366,12 @@ export class DateParser {
366366
retOptions[`${prop}`] = val;
367367
}
368368
} else {
369+
const cultureOptions: string[] = ['en-US', 'en-MH', 'en-MP'];
369370
// eslint-disable-next-line
370371
matchString = ((prop === 'month') && (!(<any>parseOptions).isIslamic) && ((<any>parseOptions).culture === 'en' || (<any>parseOptions).culture === 'en-GB' || (<any>parseOptions).culture === 'en-US'))
371372
? matchString[0].toUpperCase() + matchString.substring(1).toLowerCase() : matchString;
372-
matchString = ((prop !== 'month') && (prop === 'designator') && (<any>parseOptions).culture === 'en-GB') ? matchString.toLowerCase() : matchString;
373+
matchString = ((prop !== 'month') && (prop === 'designator') && <any>parseOptions.culture && (<any>parseOptions).culture.indexOf('en-') !== -1 && cultureOptions.indexOf(<any>parseOptions.culture) === -1)
374+
? matchString.toLowerCase() : matchString;
373375
// eslint-disable-next-line
374376
(<any>retOptions)[prop] = (<any>parseOptions)[prop][matchString];
375377
}

controls/base/src/template.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
* Template Engine
33
*/
44

5-
const LINES: RegExp = new RegExp('\\n\\s+|(?<=>)\\s{1,}(?=<)', 'g');
5+
const LINES: RegExp = new RegExp('\\n|\\r|\\s\\s+', 'g');
66
const QUOTES: RegExp = new RegExp(/'|"/g);
77
const IF_STMT: RegExp = new RegExp('if ?\\(');
88
const ELSEIF_STMT: RegExp = new RegExp('else if ?\\(');

controls/buttons/CHANGELOG.md

+9-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,15 @@
22

33
## [Unreleased]
44

5-
## 24.1.47 (2024-01-23)
5+
## 24.2.3 (2024-01-31)
6+
7+
### Switch
8+
9+
#### Bug Fixes
10+
11+
- `#I547814` - The issue with "Script error thrown when using toggle in angular platform" has been resolved.
12+
13+
## 24.1.46 (2024-01-17)
614

715
### Checkbox
816

controls/buttons/package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@syncfusion/ej2-buttons",
3-
"version": "24.1.45",
3+
"version": "24.1.46",
44
"description": "A package of feature-rich Essential JS 2 components such as Button, CheckBox, RadioButton and Switch.",
55
"author": "Syncfusion Inc.",
66
"license": "SEE LICENSE IN license",

controls/buttons/src/switch/switch.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -168,7 +168,7 @@ export class Switch extends Component<HTMLInputElement> implements INotifyProper
168168
const changeEventArgs: ChangeEventArgs = { checked: this.element.checked, event: evt };
169169
this.trigger('change', changeEventArgs);
170170
// eslint-disable-next-line @typescript-eslint/no-explicit-any
171-
if ((this as any).isAngular) {
171+
if ((this as any).isAngular && evt) {
172172
evt.stopPropagation();evt.preventDefault();
173173
}
174174
}

controls/calendars/CHANGELOG.md

+16
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,24 @@
22

33
## [Unreleased]
44

5+
## 24.2.3 (2024-01-31)
6+
7+
### DateTimePicker
8+
9+
#### Bug Fixes
10+
11+
- `#I541657` - Fixed an issue where the change event in the DateTimePicker was firing after the first time losing focus when milliseconds were included.
12+
513
## 24.1.47 (2024-01-23)
614

15+
### DateRangePicker
16+
17+
#### Bug Fixes
18+
19+
- `#I528771` - Fixed an issue where the DateRangePicker in the `Malaysia` region was only returning a single value.
20+
21+
## 24.1.44 (2024-01-03)
22+
723
### TimePicker
824

925
#### Bug Fixes

controls/calendars/package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@syncfusion/ej2-calendars",
3-
"version": "24.1.43",
3+
"version": "24.1.47",
44
"description": "A complete package of date or time components with built-in features such as date formatting, inline editing, multiple (range) selection, range restriction, month and year selection, strict mode, and globalization.",
55
"author": "Syncfusion Inc.",
66
"license": "SEE LICENSE IN license",

controls/calendars/src/datepicker/datepicker.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -1231,7 +1231,7 @@ export class DatePicker extends Calendar implements IInput {
12311231
}
12321232
protected popupUpdate(): void {
12331233
if ((isNullOrUndefined(this.value)) && (!isNullOrUndefined(this.previousDate)) ||
1234-
(+this.value !== +this.previousDate)) {
1234+
(((this.getModuleName() !== 'datetimepicker') && (+this.value !== +this.previousDate)) || ((this.getModuleName() === 'datetimepicker') && (+this.value !== +this.previousDateTime)))) {
12351235
if (this.popupObj) {
12361236
if (this.popupObj.element.querySelectorAll('.' + SELECTED).length > 0) {
12371237
removeClass(this.popupObj.element.querySelectorAll('.' + SELECTED), [SELECTED]);

controls/calendars/src/daterangepicker/daterangepicker.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -4685,7 +4685,7 @@ export class DateRangePicker extends CalendarBase {
46854685
attributes(this.secondHiddenChild, {
46864686
'type': 'text', 'name': this.inputElement.getAttribute('data-name'), 'class' : HIDDENELEMENT
46874687
});
4688-
const format: Object = { type: 'datetime', skeleton: 'yMd' };
4688+
const format: Object = { format: this.formatString, type: 'datetime', skeleton: 'yMd' };
46894689
this.firstHiddenChild.value = this.startDate && this.globalize.formatDate(this.startDate, format);
46904690
this.secondHiddenChild.value = this.endDate && this.globalize.formatDate(this.endDate, format);
46914691
this.inputElement.parentElement.appendChild(this.firstHiddenChild);

0 commit comments

Comments
 (0)