mirror of
https://github.com/vale981/Vulcan
synced 2025-03-05 17:41:43 -05:00
Make static text work for empty values and numbers
This commit is contained in:
parent
48092c171e
commit
84ea6d8789
1 changed files with 1 additions and 1 deletions
|
@ -2,7 +2,7 @@ import React from 'react';
|
|||
import { registerComponent } from 'meteor/vulcan:core';
|
||||
|
||||
const parseUrl = value => {
|
||||
return value.slice(0,4) === 'http' ? <a href={value} target="_blank">{value}</a> : value;
|
||||
return value && value.toString().slice(0,4) === 'http' ? <a href={value} target="_blank">{value}</a> : value;
|
||||
}
|
||||
|
||||
const StaticComponent = ({ value, label }) => (
|
||||
|
|
Loading…
Add table
Reference in a new issue