gcg-website/static/admin/previews/field-previews/draft-preview.js

22 lines
441 B
JavaScript
Raw Normal View History

const DraftPreview = ({ value }) =>
h(
"div",
{
style: {
backgroundColor: value === true ? "rgb(37 99 235)" : "rgb(22 163 74)",
color: "white",
border: "none",
padding: "2px 6px",
textAlign: "center",
textDecoration: "none",
display: "inline-block",
cursor: "pointer",
borderRadius: "4px",
fontSize: "14px",
},
},
value ? "Entwurf" : "Veröffentlicht"
);
export default DraftPreview;