victorsoftart / hiera-pdf-api

HIERA PDF API
0 stars 0 forks source link

Update style #1

Open victorsoftart opened 4 years ago

victorsoftart commented 4 years ago

http://localhost:5101/pdf Request Body: { "title": "$13B in gains and $11B in losses for January. ", "body": "*Capital Markets - February 2020.* ##*Chinese education stocks, powered for the most part by digital solutions, are the strong performers amidst COVID-19 concerns. Publishers & student accommodation providers are taking hits.*##*Chinese stocks dominating the top performers.*##Chinese education stocks are, for the most part focused on technology enhanced delivery, so it's perhaps not surprising that amid the COVID-19 outbreak in China as schools and universities are being closed, that stocks are fairing well. Outside China, IDP (Australia) and 2U (USA), were also among the top performing education stocks this month.##*Publishing companies continue a horror run*##Publishing stocks continue see declining market caps with Informa, Wiley and Pearson again in the bottom performers for the month. In the UK, Informa closed 15% down (10% down last month) & Pearson 6% down (12% down last month) while US publisher, Wiley, closed 15% down (10% down last month).##UK-based student accommodation provider Unite posted a 14% decline in market cap for the month, likely to be a result of restricted travel for international students and university closures resulting from COVID-19.##*Cornerstone on Demand to acquire Saba* ##The enterprise LMS giant, Cornerstone on Demand announced the acquisition of competitor, Saba, this month in a transaction worth $1.4 billion bringing Cornerstone an additional 1,000+ enterprise-class customers.##*Digital credentialing acquisitions*##This month saw two acquisitions in the digital credentialing space with Parchment, a digital credential service acquired by PE firm Brentwood Associates and Learning Machine, which issues digital credentials based on blockchain technology was acquired by general technology services company Hyland.", "minutes": 2, "date": "2020-03-10T00:00:00.000Z", "author": null, "team_tags": [ "Capital Markets", "China", "LMS", "Credentials" ], "hiq_tags": [ "Capital Markets", "China", "LMS", "Credentials" ] }

victorsoftart commented 4 years ago

First priority is getting the structure you had. A cover page with nice title and sub title. Then a second and further pages with the body text.

Once that is done we can move to formatting the body text

Please send a PDF output with the new code but your styling for cover and body and then I will share instructions on styling

victorsoftart commented 4 years ago

"body": "*Capital Markets - February 2020.* ##*Chinese education stocks, powered for the most part by digital solutions, are the strong performers amidst COVID-19 concerns. Publishers & student accommodation providers are taking hits.*##*Chinese stocks dominating the top performers.*##Chinese education stocks are, for the most part focused on technology enhanced delivery, so it's perhaps not surprising that amid the COVID-19 outbreak in China as schools and universities are being closed, that stocks are fairing well. Outside China, IDP (Australia) and 2U (USA), were also among the top performing education stocks this month.##*Publishing companies continue a horror run*##Publishing stocks continue see declining market caps with Informa, Wiley and Pearson again in the bottom performers for the month. In the UK, Informa closed 15% down (10% down last month) & Pearson 6% down (12% down last month) while US publisher, Wiley, closed 15% down (10% down last month).##UK-based student accommodation provider Unite posted a 14% decline in market cap for the month, likely to be a result of restricted travel for international students and university closures resulting from COVID-19.##*Cornerstone on Demand to acquire Saba* ##The enterprise LMS giant, Cornerstone on Demand announced the acquisition of competitor, Saba, this month in a transaction worth $1.4 billion bringing Cornerstone an additional 1,000+ enterprise-class customers.##*Digital credentialing acquisitions*##This month saw two acquisitions in the digital credentialing space with Parchment, a digital credential service acquired by PE firm Brentwood Associates and Learning Machine, which issues digital credentials based on blockchain technology was acquired by general technology services company Hyland."

victorsoftart commented 4 years ago
const contents = contentBody.split('#');
console.log(contents)

0: "*Capital Markets - February 2020.* " 1: "" 2: "*Chinese education stocks, powered for the most part by digital solutions, are the strong performers amidst COVID-19 concerns. Publishers & student accommodation providers are taking hits.*" 3: "" 4: "*Chinese stocks dominating the top performers.*" 5: "" 6: "Chinese education stocks are, for the most part focused on technology enhanced delivery, so it's perhaps not surprising that amid the COVID-19 outbreak in China as schools and universities are being closed, that stocks are fairing well. Outside China, IDP (Australia) and 2U (USA), were also among the top performing education stocks this month." 7: "" 8: "*Publishing companies continue a horror run*" 9: "" 10: "Publishing stocks continue see declining market caps with Informa, Wiley and Pearson again in the bottom performers for the month. In the UK, Informa closed 15% down (10% down last month) & Pearson 6% down (12% down last month) while US publisher, Wiley, closed 15% down (10% down last month)." 11: "" 12: "UK-based student accommodation provider Unite posted a 14% decline in market cap for the month, likely to be a result of restricted travel for international students and university closures resulting from COVID-19." 13: "" 14: "*Cornerstone on Demand to acquire Saba* " 15: "" 16: "The enterprise LMS giant, Cornerstone on Demand announced the acquisition of competitor, Saba, this month in a transaction worth $1.4 billion bringing Cornerstone an additional 1,000+ enterprise-class customers." 17: "" 18: "*Digital credentialing acquisitions*" 19: "" 20: "This month saw two acquisitions in the digital credentialing space with Parchment, a digital credential service acquired by PE firm Brentwood Associates and Learning Machine, which issues digital credentials based on blockchain technology was acquired by general technology services company Hyland."

victorsoftart commented 4 years ago
const splited = contents[i].split('*');
console.log(splited)

["", "Capital Markets - February 2020. ", ""] [""] ["", "Chinese education stocks, powered for the most par… student accommodation providers are taking hits.", ""] [""] ["", "Chinese stocks dominating the top performers.", ""] [""] ["Chinese education stocks are, for the most part fo…g the top performing education stocks this month."] [""] ["", "Publishing companies continue a horror run", ""] [""] ["Publishing stocks continue see declining market ca…er, Wiley, closed 15% down (10% down last month)."] [""] ["UK-based student accommodation provider Unite post… and university closures resulting from COVID-19."] [""] ["", "Cornerstone on Demand to acquire Saba", " "] [""] ["The enterprise LMS giant, Cornerstone on Demand an… an additional 1,000+ enterprise-class customers."] [""] ["", "Digital credentialing acquisitions", ""] [""] ["This month saw two acquisitions in the digital cre…ed by general technology services company Hyland."]

victorsoftart commented 4 years ago

var content= handleParseContent(body);

    <h3><span>  </span>
    <strong> Capital Markets - February 2020.</strong>
    <span>   </span></h3>

    <h3><span>  </span></h3>

    <h3><span>  </span>
    <strong> Chinese education stocks, powered for the most part by digital solutions, are the strong performers amidst COVID-19 concerns. Publishers & student accommodation providers are taking hits.</strong>
    <span>  </span></h3>

    <h3><span>  </span></h3>

    <h3><span>  </span>
    <strong> Chinese stocks dominating the top performers.</strong>
    <span>  </span></h3>

    <h3><span>  </span></h3>

    <h3><span> Chinese education stocks are, for the most part focused on technology enhanced delivery, so it's perhaps not surprising that amid the COVID-19 outbreak in China as schools and universities are being closed, that stocks are fairing well. Outside China, IDP (Australia) and 2U (USA), were also among the top performing education stocks this month. </span></h3>

    <h3><span>  </span></h3>

    <h3><span>  </span>
    <strong> Publishing companies continue a horror run</strong>
    <span>  </span></h3>

    <h3><span>  </span></h3>

    <h3><span> Publishing stocks continue see declining market caps with Informa, Wiley and Pearson again in the bottom performers for the month. In the UK, Informa closed 15% down (10% down last month) & Pearson 6% down (12% down last month) while US publisher, Wiley, closed 15% down (10% down last month). </span></h3>

    <h3><span>  </span></h3>

    <h3><span> UK-based student accommodation provider Unite posted a 14% decline in market cap for the month, likely to be a result of restricted travel for international students and university closures resulting from COVID-19. </span></h3>

    <h3><span>  </span></h3>

    <h3><span>  </span>
    <strong> Cornerstone on Demand to acquire Saba</strong>
    <span>   </span></h3>

    <h3><span>  </span></h3>

    <h3><span> The enterprise LMS giant, Cornerstone on Demand announced the acquisition of competitor, Saba, this month in a transaction worth $1.4 billion bringing Cornerstone an additional 1,000+ enterprise-class customers. </span></h3>

    <h3><span>  </span></h3>

    <h3><span>  </span>
    <strong> Digital credentialing acquisitions</strong>
    <span>  </span></h3>

    <h3><span>  </span></h3>

    <h3><span> This month saw two acquisitions in the digital credentialing space with Parchment, a digital credential service acquired by PE firm Brentwood Associates and Learning Machine, which issues digital credentials based on blockchain technology was acquired by general technology services company Hyland. </span></h3>