import React from "react"; import { render } from "react-dom"; export const getAsDataURI = text => `data:text/html;base64,${window.btoa(text)}`; // Replaces deprecated "noshade" attribute const noshadeStyle = { height: "2px", borderWidth: 0, color: "gray", backgroundColor: "gray" }; // TODO: Move tag out to the string creation step in order // to avoid the warning. const Playlist = props => ( Winamp Generated PlayList

WINAMP

playlist


{/* Added tag */}
{props.numberOfTracks} {" track in playlist, average track length: "} {props.averageTrackLength}
{"Playlist length: "} {props.playlistLengthMinutes} {" minutes "} {props.playlistLengthSeconds} {" second "}
Right-click here to save this HTML file.

Playlist files: {/* Added closing tag here */}


); const createPlaylistHTML = props => { const node = document.createElement("div"); render(, node); return node.innerHTML; }; export const createPlaylistURL = props => getAsDataURI(createPlaylistHTML(props));