|
@@ -949,9 +949,11 @@ class Snippet {
|
|
|
const pad =
|
|
const pad =
|
|
|
variable.type() == 'datetime-local' && variable.value().length == 16 ? ':00' : ''; // Chrome drops the seconds from the timestamp when it's at 0 second.
|
|
variable.type() == 'datetime-local' && variable.value().length == 16 ? ':00' : ''; // Chrome drops the seconds from the timestamp when it's at 0 second.
|
|
|
const value = variable.value();
|
|
const value = variable.value();
|
|
|
|
|
+ const isValuePresent = //If value is string there is a need to check whether it is empty
|
|
|
|
|
+ typeof value === 'string' ? value : value !== undefined && value !== null;
|
|
|
return (
|
|
return (
|
|
|
p1 +
|
|
p1 +
|
|
|
- (value !== undefined && value !== null
|
|
|
|
|
|
|
+ (isValuePresent
|
|
|
? value + pad
|
|
? value + pad
|
|
|
: variable.meta.placeholder && variable.meta.placeholder())
|
|
: variable.meta.placeholder && variable.meta.placeholder())
|
|
|
);
|
|
);
|