@e-llm-studio/citation 0.0.87 → 0.0.88
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("../../../node_modules/tslib/tslib.es6.mjs.js"),t=require("react/jsx-runtime"),
|
|
1
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("../../../node_modules/tslib/tslib.es6.mjs.js"),t=require("react/jsx-runtime"),n=require("react"),i={container:{width:"100%"},sectionTitle:{fontSize:"14px",fontWeight:600,color:"#667085",marginBottom:"12px"},detailsContainer:{marginBottom:"24px",fontSize:"14px",fontWeight:400,color:"#64748B",display:"flex",flexDirection:"column",gap:"4px",paddingLeft:"12px"},detailsContainerItem:{margin:"4px 0"},boldText:{fontWeight:"bold"},categoriesContainer:{marginBottom:"24px"},categoriesList:{display:"flex",flexWrap:"wrap",gap:"12px",marginBottom:"8px",paddingLeft:"12px"},category:{backgroundColor:"#ECEEF1",padding:"8px 12px",fontWeight:400,fontSize:"12px",borderRadius:"4px",color:"#64748B",maxWidth:"100%",wordBreak:"break-word"},button:{color:"#5928ED",fontSize:"14px",fontWeight:600,background:"none",border:"none",cursor:"pointer",padding:0,textDecoration:"none",paddingLeft:"12px"},reviewsList:{paddingLeft:"12px"},reviewCard:{border:"1px solid #CBD5E1",borderRadius:"6px",padding:"16px",marginBottom:"12px",backgroundColor:"#F8FAFC"},reviewText:{fontSize:"14px",fontStyle:"italic",fontWeight:400,color:"#475569",marginBottom:"8px"},reviewSource:{fontSize:"10px",color:"#475569",fontWeight:600}};exports.default=function(s){var r,o,l,a,d,c,g,u=s.data,x=n.useState(!1),p=x[0],_=x[1],h=n.useState(!1),b=h[0],f=h[1],y=n.useMemo((function(){return p?u.subjectCategories||[]:(u.subjectCategories||[]).slice(0,10)}),[p,u.subjectCategories]);return t.jsxs("div",e.__assign({style:i.container},{children:[t.jsx("p",e.__assign({style:i.sectionTitle},{children:"Product Details"})),t.jsxs("div",e.__assign({style:i.detailsContainer},{children:[t.jsxs("p",e.__assign({style:i.detailsContainerItem},{children:[t.jsx("span",e.__assign({style:i.boldText},{children:"ISBN:"}))," ",null!==(r=u.isbn)&&void 0!==r?r:"NA"]})),t.jsxs("p",e.__assign({style:i.detailsContainerItem},{children:[t.jsx("span",e.__assign({style:i.boldText},{children:"ISBN 10:"}))," ",null!==(o=u.isbn10)&&void 0!==o?o:"NA"]})),t.jsxs("p",e.__assign({style:i.detailsContainerItem},{children:[t.jsx("span",e.__assign({style:i.boldText},{children:"Imprint:"}))," ",null!==(l=u.imprint)&&void 0!==l?l:"NA"]})),t.jsxs("p",e.__assign({style:i.detailsContainerItem},{children:[t.jsx("span",e.__assign({style:i.boldText},{children:"Publisher:"}))," ",null!==(a=u.publisher)&&void 0!==a?a:"NA"]})),t.jsxs("p",e.__assign({style:i.detailsContainerItem},{children:[t.jsx("span",e.__assign({style:i.boldText},{children:"Publishing Date:"}))," ",null!==(d=u.publishingDate)&&void 0!==d?d:"NA"]})),t.jsxs("p",e.__assign({style:i.detailsContainerItem},{children:[t.jsx("span",e.__assign({style:i.boldText},{children:"Age:"}))," ",null!==(c=u.age)&&void 0!==c?c:"NA"]}))]})),t.jsxs("div",e.__assign({style:i.categoriesContainer},{children:[t.jsx("p",e.__assign({style:i.sectionTitle},{children:"Subject Categories"})),t.jsxs("div",e.__assign({style:i.categoriesList},{children:[y.map((function(n,s){return t.jsx("span",e.__assign({style:i.category},{children:n}),s)})),u.subjectCategories&&u.subjectCategories.length>10&&t.jsx("button",e.__assign({style:i.button,onClick:function(){return _(!p)},onMouseOver:function(e){return e.currentTarget.style.textDecoration="underline"},onMouseOut:function(e){return e.currentTarget.style.textDecoration="none"}},{children:p?"View less":"View more"}))]}))]})),t.jsxs("div",e.__assign({style:i.reviewsContainer},{children:[t.jsx("p",e.__assign({style:i.sectionTitle},{children:"Book Marketing Collateral"})),t.jsxs("div",e.__assign({style:i.reviewsList},{children:[u.reviews&&u.reviews.length>0?(g=u.reviews.filter((function(e){return e.replace(/<[^>]+>/g,"").trim().replace(/&[#A-Za-z0-9]+;/g,"").trim().length>0})),(b?g:g.slice(0,3)).map((function(n,s){return t.jsx("div",e.__assign({style:i.reviewCard},{children:t.jsx("div",{style:i.reviewText,dangerouslySetInnerHTML:{__html:n}})}),s)}))):t.jsx("p",e.__assign({style:i.reviewText},{children:"No Book Marketing Collateral available for this book."})),u.reviews&&u.reviews.length>3&&t.jsx("button",e.__assign({style:i.button,onClick:function(){return f((function(e){return!e}))},onMouseOver:function(e){return e.currentTarget.style.textDecoration="underline"},onMouseOut:function(e){return e.currentTarget.style.textDecoration="none"}},{children:b?"View less":"View more"}))]}))]}))]}))};
|
|
2
2
|
//# sourceMappingURL=BookDetailsCard.js.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{__assign as e}from"../../../node_modules/tslib/tslib.es6.mjs.js";import{jsxs as t,jsx as n}from"react/jsx-runtime";import{useState as i,useMemo as r}from"react";var o={container:{width:"100%"},sectionTitle:{fontSize:"14px",fontWeight:600,color:"#667085",marginBottom:"12px"},detailsContainer:{marginBottom:"24px",fontSize:"14px",fontWeight:400,color:"#64748B",display:"flex",flexDirection:"column",gap:"4px",paddingLeft:"12px"},detailsContainerItem:{margin:"4px 0"},boldText:{fontWeight:"bold"},categoriesContainer:{marginBottom:"24px"},categoriesList:{display:"flex",flexWrap:"wrap",gap:"12px",marginBottom:"8px",paddingLeft:"12px"},category:{backgroundColor:"#ECEEF1",padding:"8px 12px",fontWeight:400,fontSize:"12px",borderRadius:"4px",color:"#64748B",maxWidth:"100%",wordBreak:"break-word"},button:{color:"#5928ED",fontSize:"14px",fontWeight:600,background:"none",border:"none",cursor:"pointer",padding:0,textDecoration:"none",paddingLeft:"12px"},reviewsList:{paddingLeft:"12px"},reviewCard:{border:"1px solid #CBD5E1",borderRadius:"6px",padding:"16px",marginBottom:"12px",backgroundColor:"#F8FAFC"},reviewText:{fontSize:"14px",fontStyle:"italic",fontWeight:400,color:"#475569",marginBottom:"8px"},reviewSource:{fontSize:"10px",color:"#475569",fontWeight:600}},l=function(l){var s,a,d,c,u,p,g=l.data,
|
|
1
|
+
import{__assign as e}from"../../../node_modules/tslib/tslib.es6.mjs.js";import{jsxs as t,jsx as n}from"react/jsx-runtime";import{useState as i,useMemo as r}from"react";var o={container:{width:"100%"},sectionTitle:{fontSize:"14px",fontWeight:600,color:"#667085",marginBottom:"12px"},detailsContainer:{marginBottom:"24px",fontSize:"14px",fontWeight:400,color:"#64748B",display:"flex",flexDirection:"column",gap:"4px",paddingLeft:"12px"},detailsContainerItem:{margin:"4px 0"},boldText:{fontWeight:"bold"},categoriesContainer:{marginBottom:"24px"},categoriesList:{display:"flex",flexWrap:"wrap",gap:"12px",marginBottom:"8px",paddingLeft:"12px"},category:{backgroundColor:"#ECEEF1",padding:"8px 12px",fontWeight:400,fontSize:"12px",borderRadius:"4px",color:"#64748B",maxWidth:"100%",wordBreak:"break-word"},button:{color:"#5928ED",fontSize:"14px",fontWeight:600,background:"none",border:"none",cursor:"pointer",padding:0,textDecoration:"none",paddingLeft:"12px"},reviewsList:{paddingLeft:"12px"},reviewCard:{border:"1px solid #CBD5E1",borderRadius:"6px",padding:"16px",marginBottom:"12px",backgroundColor:"#F8FAFC"},reviewText:{fontSize:"14px",fontStyle:"italic",fontWeight:400,color:"#475569",marginBottom:"8px"},reviewSource:{fontSize:"10px",color:"#475569",fontWeight:600}},l=function(l){var s,a,d,c,u,p,g,x=l.data,h=i(!1),f=h[0],m=h[1],b=i(!1),y=b[0],v=b[1],C=r((function(){return f?x.subjectCategories||[]:(x.subjectCategories||[]).slice(0,10)}),[f,x.subjectCategories]);return t("div",e({style:o.container},{children:[n("p",e({style:o.sectionTitle},{children:"Product Details"})),t("div",e({style:o.detailsContainer},{children:[t("p",e({style:o.detailsContainerItem},{children:[n("span",e({style:o.boldText},{children:"ISBN:"}))," ",null!==(s=x.isbn)&&void 0!==s?s:"NA"]})),t("p",e({style:o.detailsContainerItem},{children:[n("span",e({style:o.boldText},{children:"ISBN 10:"}))," ",null!==(a=x.isbn10)&&void 0!==a?a:"NA"]})),t("p",e({style:o.detailsContainerItem},{children:[n("span",e({style:o.boldText},{children:"Imprint:"}))," ",null!==(d=x.imprint)&&void 0!==d?d:"NA"]})),t("p",e({style:o.detailsContainerItem},{children:[n("span",e({style:o.boldText},{children:"Publisher:"}))," ",null!==(c=x.publisher)&&void 0!==c?c:"NA"]})),t("p",e({style:o.detailsContainerItem},{children:[n("span",e({style:o.boldText},{children:"Publishing Date:"}))," ",null!==(u=x.publishingDate)&&void 0!==u?u:"NA"]})),t("p",e({style:o.detailsContainerItem},{children:[n("span",e({style:o.boldText},{children:"Age:"}))," ",null!==(p=x.age)&&void 0!==p?p:"NA"]}))]})),t("div",e({style:o.categoriesContainer},{children:[n("p",e({style:o.sectionTitle},{children:"Subject Categories"})),t("div",e({style:o.categoriesList},{children:[C.map((function(t,i){return n("span",e({style:o.category},{children:t}),i)})),x.subjectCategories&&x.subjectCategories.length>10&&n("button",e({style:o.button,onClick:function(){return m(!f)},onMouseOver:function(e){return e.currentTarget.style.textDecoration="underline"},onMouseOut:function(e){return e.currentTarget.style.textDecoration="none"}},{children:f?"View less":"View more"}))]}))]})),t("div",e({style:o.reviewsContainer},{children:[n("p",e({style:o.sectionTitle},{children:"Book Marketing Collateral"})),t("div",e({style:o.reviewsList},{children:[x.reviews&&x.reviews.length>0?(g=x.reviews.filter((function(e){return e.replace(/<[^>]+>/g,"").trim().replace(/&[#A-Za-z0-9]+;/g,"").trim().length>0})),(y?g:g.slice(0,3)).map((function(t,i){return n("div",e({style:o.reviewCard},{children:n("div",{style:o.reviewText,dangerouslySetInnerHTML:{__html:t}})}),i)}))):n("p",e({style:o.reviewText},{children:"No Book Marketing Collateral available for this book."})),x.reviews&&x.reviews.length>3&&n("button",e({style:o.button,onClick:function(){return v((function(e){return!e}))},onMouseOver:function(e){return e.currentTarget.style.textDecoration="underline"},onMouseOut:function(e){return e.currentTarget.style.textDecoration="none"}},{children:y?"View less":"View more"}))]}))]}))]}))};export{l as default};
|
|
2
2
|
//# sourceMappingURL=BookDetailsCard.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"BookDetailsCard.d.ts","sourceRoot":"","sources":["../../../../../../src/features/Bookemon/BookDetailsCard/BookDetailsCard.tsx"],"names":[],"mappings":"AACA,OAAO,EAAE,YAAY,EAAE,MAAM,aAAa,CAAC;AAmF3C,KAAK,oBAAoB,GAAG;IAC1B,IAAI,EAAE,YAAY,CAAC;CACpB,CAAC;AACF,QAAA,MAAM,eAAe,aAAc,oBAAoB,
|
|
1
|
+
{"version":3,"file":"BookDetailsCard.d.ts","sourceRoot":"","sources":["../../../../../../src/features/Bookemon/BookDetailsCard/BookDetailsCard.tsx"],"names":[],"mappings":"AACA,OAAO,EAAE,YAAY,EAAE,MAAM,aAAa,CAAC;AAmF3C,KAAK,oBAAoB,GAAG;IAC1B,IAAI,EAAE,YAAY,CAAC;CACpB,CAAC;AACF,QAAA,MAAM,eAAe,aAAc,oBAAoB,4CAgHtD,CAAC;AAEF,eAAe,eAAe,CAAC"}
|