diff --git a/src/components/tooltip/Tooltip.js b/src/components/tooltip/Tooltip.js index 28d378723..fbff4e0e9 100755 --- a/src/components/tooltip/Tooltip.js +++ b/src/components/tooltip/Tooltip.js @@ -1,4 +1,4 @@ -import {UniqueComponentId,DomHandler,ConnectedOverlayScrollHandler,ZIndexUtils} from 'primevue/utils'; +import {UniqueComponentId,DomHandler,ObjectUtils,ConnectedOverlayScrollHandler,ZIndexUtils} from 'primevue/utils'; function bindEvents(el) { const modifiers = el.$_ptooltipModifiers; @@ -300,7 +300,7 @@ const Tooltip = { target.$_ptooltipFitContent = true; } else if (typeof options.value === 'object' && options.value) { - if (options.value.value === undefined || options.value.value === null || options.value.value.trim() === '') return; + if (ObjectUtils.isEmpty(options.value.value)) return; else { /* eslint-disable */ target.$_ptooltipValue = options.value.value; @@ -338,7 +338,7 @@ const Tooltip = { target.$_ptooltipClass = null; } else if (typeof options.value === 'object' && options.value) { - if (options.value.value === undefined || options.value.value === null || options.value.value.trim() === '') return; + if (ObjectUtils.isEmpty(options.value.value)) return; else { /* eslint-disable */ target.$_ptooltipValue = options.value.value;