Refactor #3965 - For Accordion

This commit is contained in:
mertsincan 2023-05-24 00:40:14 +01:00
parent 78552d81cf
commit e58fc57621
7 changed files with 175 additions and 112 deletions

View file

@ -80,10 +80,6 @@ export default {
}
},
isFunction(obj) {
return !!(obj && obj.constructor && obj.call && obj.apply);
},
getItemValue(obj, ...params) {
return this.isFunction(obj) ? obj(...params) : obj;
},
@ -218,6 +214,22 @@ export default {
return !this.isEmpty(value);
},
isFunction(value) {
return !!(value && value.constructor && value.call && value.apply);
},
isObject(value) {
return value !== null && value instanceof Object && value.constructor === Object;
},
isDate(value) {
return value !== null && value instanceof Date && value.constructor === Date;
},
isArray(value) {
return value !== null && Array.isArray(value);
},
isPrintableCharacter(char = '') {
return this.isNotEmpty(char) && char.length === 1 && char.match(/\S| /);
},