spee.ch/react/components/PublishUrlMiddle.jsx

17 lines
680 B
React
Raw Normal View History

2018-01-10 03:25:38 +01:00
import React from 'react';
function UrlMiddle ({publishInChannel, loggedInChannelName, loggedInChannelShortId}) {
if (publishInChannel) {
2018-01-10 03:25:38 +01:00
if (loggedInChannelName) {
return <span id="url-channel" className="url-text--secondary">{loggedInChannelName}:{loggedInChannelShortId} /</span>;
}
return <span id="url-channel-placeholder" className="url-text--secondary tooltip">@channel<span
className="tooltip-text">Select a channel below</span> /</span>;
}
return (
<span id="url-no-channel-placeholder" className="url-text--secondary tooltip">xyz<span className="tooltip-text">This will be a random id</span> /</span>
);
}
export default UrlMiddle;