@soul-refiner/design-system 2.14.109 → 2.14.110
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.
- package/dist/components/card/learning-course/learning-course.js +2 -2
- package/dist/components/card/simple-course/simple-course.js +4 -4
- package/dist/src/components/card/learning-course/learning-course.d.ts.map +1 -1
- package/dist/src/components/card/simple-course/simple-course.d.ts.map +1 -1
- package/package.json +1 -1
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
"use client";
|
|
2
|
-
"use strict";var e=require("react/jsx-runtime"),i=require("next/image"),r=require("styled-components"),o=require("../../atoms/box/box.js"),
|
|
2
|
+
"use strict";var e=require("react/jsx-runtime"),i=require("next/image"),r=require("styled-components"),o=require("../../atoms/box/box.js"),t=require("../../atoms/typography/paragraph.js"),s=require("../../../icons/basic/video.js");function n(e){return e&&"object"==typeof e&&"default"in e?e:{default:e}}var a=n(i);const l=r.styled.div`
|
|
3
3
|
cursor: pointer;
|
|
4
4
|
display: inline-block;
|
|
5
5
|
position: relative;
|
|
@@ -115,4 +115,4 @@
|
|
|
115
115
|
display: inline-flex;
|
|
116
116
|
align-items: center;
|
|
117
117
|
gap: 4px;
|
|
118
|
-
`;exports.LearningCourseCard=({content:i,href:r,image:n,creatorName:g,supportLabel:b,supportIcon:f=e.jsx(
|
|
118
|
+
`;exports.LearningCourseCard=({content:i,href:r,image:n,creatorName:g,supportLabel:b,supportIcon:f=e.jsx(s.Video,{size:16,color:"white"}),title:w,onCardClick:v,progress:y,duration:j,watchedPercentage:m,sx:$})=>{const k=!!i,z=!!r,C=e.jsx(e.Fragment,{children:e.jsxs(d,{className:"normal-card",onClick:v,children:[e.jsx(c,{children:e.jsx(a.default,{alt:"",height:191,quality:100,src:n,width:339})}),e.jsx(x,{children:e.jsxs(p,{children:[e.jsxs(o.Box,{$dir:"column",$gap:8,children:[e.jsx(t.P,{sx:"font-size: 18px; font-style: normal; font-weight: 700; line-height: 26px; letter-spacing: -0.252px; color: var(--color-grey-2); text-overflow: ellipsis;overflow: hidden;",$textClampLines:2,dangerouslySetInnerHTML:{__html:w}}),e.jsxs(o.Box,{$dir:"row",$justify:"space-between",children:[e.jsxs(o.Box,{$dir:"row",$gap:5,children:[e.jsx(t.P,{$fontSize:12,$italic:!0,$lineHeight:16,$color:"grey-4",children:"by"}),e.jsx(t.P,{$color:"grey-4",$fontSize:12,$lineHeight:16,children:g})]}),b&&e.jsxs(u,{children:[f,e.jsx(t.P,{$color:"white",$fontSize:10,$lineHeight:14,sx:"font-weight:500",children:b})]})]})]}),e.jsxs(o.Box,{$dir:"column",$justify:"space-between",$gap:10,children:[e.jsx(h,{progressPercent:y/j}),e.jsxs(t.P,{$fontSize:12,$lineHeight:16,sx:"font-weight: 400;line-height: 16px;",children:[Math.round(m),"% Complete"]})]})]})})]})});return e.jsx(l,{as:"div",$sx:$,$hasContent:k,$isClickable:z,children:C})};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
"use client";
|
|
2
|
-
"use strict";var e=require("react/jsx-runtime"),r=require("react"),o=require("next/image"),i=require("styled-components"),n=require("../../atoms/box/box.js"),t=require("../../atoms/typography/heading.js"),s=require("../../atoms/typography/paragraph.js"),l=require("../../actions/rate/rate.js"),a=require("../../feedback/tooltip/tooltip.js"),d=require("../../../icons/basic/video.js"),c=require("../../../icons/basic/pencil.js");require("../../iconography/icon/icon.js");var p=require("../../../icons/arrow/forward_bold.js"),x=require("../../../icons/audio_video/trailer.js");function h(e){return e&&"object"==typeof e&&"default"in e?e:{default:e}}require("../../../icons/basic/subtask.js"),require("../../../common/colors.js");var g=h(r),
|
|
2
|
+
"use strict";var e=require("react/jsx-runtime"),r=require("react"),o=require("next/image"),i=require("styled-components"),n=require("../../atoms/box/box.js"),t=require("../../atoms/typography/heading.js"),s=require("../../atoms/typography/paragraph.js"),l=require("../../actions/rate/rate.js"),a=require("../../feedback/tooltip/tooltip.js"),d=require("../../../icons/basic/video.js"),c=require("../../../icons/basic/pencil.js");require("../../iconography/icon/icon.js");var p=require("../../../icons/arrow/forward_bold.js"),x=require("../../../icons/audio_video/trailer.js");function h(e){return e&&"object"==typeof e&&"default"in e?e:{default:e}}require("../../../icons/basic/subtask.js"),require("../../../common/colors.js");var g=h(r),u=h(o);const b={draft:{label:"Draft",bgColor:"var(--color-grey-9)",dotColor:"var(--color-grey-4)"},published:{label:"Published",bgColor:"var(--color-green-9)",dotColor:"var(--color-green-5)"},"pending-review":{label:"Pending Review",bgColor:"rgba(255, 255, 255, 0.9)",dotColor:"#F59E0B"},"in-review":{label:"In Review",bgColor:"rgba(255, 255, 255, 0.9)",dotColor:"#3B82F6"},"change-required":{label:"Change Required",bgColor:"#FEE2E2",dotColor:"#EF4444"},edited:{label:"Edited",bgColor:"rgba(255, 255, 255, 0.9)",dotColor:"#22C55E"}},f=i.styled.div`
|
|
3
3
|
cursor: pointer;
|
|
4
4
|
display: inline-block;
|
|
5
5
|
position: relative;
|
|
@@ -102,7 +102,7 @@
|
|
|
102
102
|
border-radius: 16px 16px 0 0;
|
|
103
103
|
background-color: var(--color-page-bg);
|
|
104
104
|
}
|
|
105
|
-
|
|
105
|
+
`,v=i.styled.video`
|
|
106
106
|
width: 100%;
|
|
107
107
|
height: 100%;
|
|
108
108
|
object-fit: cover;
|
|
@@ -110,7 +110,7 @@
|
|
|
110
110
|
border: none;
|
|
111
111
|
outline: none;
|
|
112
112
|
background-color: var(--color-white);
|
|
113
|
-
|
|
113
|
+
`,$=i.styled.div`
|
|
114
114
|
position: absolute;
|
|
115
115
|
bottom: 0;
|
|
116
116
|
left: 0;
|
|
@@ -222,4 +222,4 @@
|
|
|
222
222
|
&:hover {
|
|
223
223
|
background-color: var(--color-white);
|
|
224
224
|
}
|
|
225
|
-
`;exports.SimpleCourseCard=({actions:r,content:o,href:i,image:h,numRating:B,priceText:T,price:
|
|
225
|
+
`;exports.SimpleCourseCard=({actions:r,content:o,href:i,image:h,numRating:B,priceText:T,price:_,rating:E,subtitle:L,supportLabel:F,supportIcon:I=e.jsx(d.Video,{size:16,color:"white"}),sx:M,title:R,additionalIcons:D,onHoverCardClick:A,trailerUrl:N,onTrailerClick:U,onShareClick:V,status:G,onEditClick:J})=>{const K=!!o,O=!!i,[Q,W]=g.default.useState(!1),X=g.default.useRef(null),Y=e=>{Q&&A&&(e.preventDefault(),A())},Z=()=>{K&&O&&(W(!0),X.current&&N&&X.current.play())},ee=()=>{W(!1),X.current&&(X.current.pause(),X.current.currentTime=0)},re=!i&&(G||J),oe=e.jsxs(e.Fragment,{children:[e.jsxs(y,{className:"normal-card",children:[e.jsxs(j,{children:[e.jsx(u.default,{alt:"",height:191,quality:100,src:h,width:339}),re&&e.jsxs(S,{children:[G&&e.jsxs(q,{$bgColor:b[G].bgColor,$dotColor:b[G].dotColor,children:[e.jsx(H,{$color:b[G].dotColor}),e.jsx(s.P,{$color:"grey-2",sx:"font-weight:500",$fontSize:12,$lineHeight:16,children:b[G].label})]}),J&&e.jsx(a.Tooltip,{content:"Edit Course",place:"top",children:e.jsx(P,{onClick:e=>{e.preventDefault(),e.stopPropagation(),J()},children:e.jsx(c.Pencil,{size:16,color:"grey-3"})})})]})]}),e.jsx(m,{children:e.jsxs(w,{children:[e.jsxs(n.Box,{$dir:"column",$gap:8,children:[e.jsx(t.H,{$color:"grey-2",$textClampLines:2,sx:"font-size: 18px !important; font-style: normal; font-weight: 700; line-height: 26px; letter-spacing: -0.252px;",dangerouslySetInnerHTML:{__html:R}}),e.jsx(s.P,{$color:"grey-4",sx:"font-size: 12px !important; font-style: normal; font-weight: 400; line-height: 16px;",dangerouslySetInnerHTML:{__html:L}})]}),e.jsxs(n.Box,{$dir:"row",$justify:"space-between",children:[e.jsxs(n.Box,{$align:"center",$dir:"row",$gap:4,children:[F&&e.jsxs(C,{children:[I,e.jsx(s.P,{$color:"white",$fontSize:10,$lineHeight:14,sx:"font-weight:500",children:F})]}),void 0!==E&&e.jsxs(e.Fragment,{children:[e.jsx(s.P,{$color:"grey-4",$fontSize:12,$lineHeight:16,children:E/20}),e.jsx(l.Rate,{isRateable:!1,percent:E,size:"small"})]}),void 0!==B&&e.jsxs(s.P,{$color:"grey-4",$fontSize:12,$lineHeight:16,children:["(",B,")"]})]}),e.jsx(n.Box,{children:e.jsx(s.P,{$color:"grey-3",sx:"font-size: 14px; font-style: normal; font-weight: 700; line-height: 20px;",children:_})})]})]})})]}),K&&N&&e.jsxs(y,{className:"hover-card",children:[e.jsxs(j,{children:[e.jsx(v,{ref:X,muted:!0,loop:!0,playsInline:!0,preload:"auto",children:Array.isArray(N)?N.map((r,o)=>e.jsx("source",{src:r},o)):e.jsx("source",{src:N,type:"video/mp4"})}),e.jsx($,{})]}),e.jsx(m,{children:e.jsxs(k,{children:[e.jsxs(n.Box,{$align:"center",$dir:"row",$justify:"space-between",$gap:8,children:[e.jsxs(s.P,{$color:"primary-blue-2",$fontSize:16,$lineHeight:24,$bold:!0,children:[T," ",_]}),r&&e.jsx(n.Box,{onClick:e=>{e.preventDefault(),e.stopPropagation()},children:r})]}),e.jsxs(n.Box,{$dir:"column",$gap:4,children:[e.jsx(t.H,{$color:"grey-2",$textClampLines:2,$semiBold:!0,$fontSize:16,$lineHeight:26,dangerouslySetInnerHTML:{__html:R}}),e.jsx(s.P,{$color:"grey-4",$fontSize:12,$lineHeight:16,dangerouslySetInnerHTML:{__html:L}})]}),e.jsx(s.P,{$color:"grey-3",$fontSize:14,$lineHeight:20,$textClampLines:2,dangerouslySetInnerHTML:{__html:o}}),e.jsxs(n.Box,{$align:"center",$dir:"row",$justify:"space-between",children:[e.jsxs(n.Box,{$align:"center",$dir:"row",$gap:8,children:[F&&e.jsxs(C,{children:[I,e.jsx(s.P,{$color:"white",$fontSize:10,$lineHeight:14,sx:"font-weight:500",children:F})]}),void 0!==E&&e.jsxs(e.Fragment,{children:[e.jsx(s.P,{$color:"grey-4",$fontSize:12,$lineHeight:16,children:E/20}),e.jsx(l.Rate,{isRateable:!1,percent:E,size:"small"})]}),void 0!==B&&e.jsxs(s.P,{$color:"grey-4",$fontSize:12,$lineHeight:16,children:["(",B,")"]})]}),e.jsxs(n.Box,{$align:"center",$dir:"row",$gap:8,children:[U&&e.jsx(a.Tooltip,{content:"Trailer",place:"top",children:e.jsx(z,{onClick:e=>{e.preventDefault(),e.stopPropagation(),U()},children:e.jsx(x.Trailer,{size:16})})}),V&&e.jsx(a.Tooltip,{content:"Share",place:"top",children:e.jsx(z,{onClick:e=>{e.preventDefault(),e.stopPropagation(),V()},children:e.jsx(p.ForwardBold,{size:16})})}),D&&D.length>0&&e.jsx(e.Fragment,{children:g.default.Children.toArray(D)})]})]})]})})]})]});return i?e.jsx(f,{as:"a",$sx:M,href:i,$hasContent:K,$isClickable:O,onClick:Y,onMouseEnter:Z,onMouseLeave:ee,children:oe}):e.jsx(f,{as:"div",$sx:M,$hasContent:K,$isClickable:O,onMouseEnter:Z,onMouseLeave:ee,children:oe})};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"learning-course.d.ts","sourceRoot":"","sources":["../../../../../src/components/card/learning-course/learning-course.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,MAAM,OAAO,CAAC;AAQ1B,MAAM,MAAM,YAAY,GACpB,OAAO,GACP,WAAW,GACX,gBAAgB,GAChB,WAAW,GACX,iBAAiB,GACjB,QAAQ,CAAC;AAEb,MAAM,WAAW,uBAAuB;IACtC,OAAO,CAAC,EAAE,KAAK,CAAC,YAAY,CAAC;IAC7B,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,KAAK,EAAE,MAAM,CAAC;IAEd,WAAW,EAAE,MAAM,CAAC;IACpB,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,WAAW,CAAC,EAAE,KAAK,CAAC,YAAY,CAAC;IAEjC,KAAK,EAAE,MAAM,CAAC;IACd,eAAe,CAAC,EAAE,KAAK,CAAC,YAAY,EAAE,CAAC;IACvC,WAAW,CAAC,EAAE,MAAM,IAAI,CAAC;IACzB,iBAAiB,EAAE,MAAM,CAAC;IAC1B,QAAQ,EAAE,MAAM,CAAC;IACjB,QAAQ,EAAE,MAAM,CAAC;IACjB,EAAE,CAAC,EAAE,MAAM,CAAC;CACb;AAED,eAAO,MAAM,kBAAkB,qIAa5B,uBAAuB,
|
|
1
|
+
{"version":3,"file":"learning-course.d.ts","sourceRoot":"","sources":["../../../../../src/components/card/learning-course/learning-course.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,MAAM,OAAO,CAAC;AAQ1B,MAAM,MAAM,YAAY,GACpB,OAAO,GACP,WAAW,GACX,gBAAgB,GAChB,WAAW,GACX,iBAAiB,GACjB,QAAQ,CAAC;AAEb,MAAM,WAAW,uBAAuB;IACtC,OAAO,CAAC,EAAE,KAAK,CAAC,YAAY,CAAC;IAC7B,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,KAAK,EAAE,MAAM,CAAC;IAEd,WAAW,EAAE,MAAM,CAAC;IACpB,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,WAAW,CAAC,EAAE,KAAK,CAAC,YAAY,CAAC;IAEjC,KAAK,EAAE,MAAM,CAAC;IACd,eAAe,CAAC,EAAE,KAAK,CAAC,YAAY,EAAE,CAAC;IACvC,WAAW,CAAC,EAAE,MAAM,IAAI,CAAC;IACzB,iBAAiB,EAAE,MAAM,CAAC;IAC1B,QAAQ,EAAE,MAAM,CAAC;IACjB,QAAQ,EAAE,MAAM,CAAC;IACjB,EAAE,CAAC,EAAE,MAAM,CAAC;CACb;AAED,eAAO,MAAM,kBAAkB,qIAa5B,uBAAuB,4CAqEzB,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"simple-course.d.ts","sourceRoot":"","sources":["../../../../../src/components/card/simple-course/simple-course.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,MAAM,OAAO,CAAC;AAY1B,MAAM,MAAM,YAAY,GACpB,OAAO,GACP,WAAW,GACX,gBAAgB,GAChB,WAAW,GACX,iBAAiB,GACjB,QAAQ,CAAC;AAEb,MAAM,WAAW,qBAAqB;IACpC,OAAO,CAAC,EAAE,KAAK,CAAC,YAAY,CAAC;IAC7B,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,KAAK,EAAE,MAAM,CAAC;IACd,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,SAAS,EAAE,MAAM,CAAC;IAClB,KAAK,EAAE,MAAM,CAAC;IACd,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,QAAQ,EAAE,MAAM,CAAC;IACjB,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,WAAW,CAAC,EAAE,KAAK,CAAC,YAAY,CAAC;IACjC,EAAE,CAAC,EAAE,MAAM,CAAC;IACZ,KAAK,EAAE,MAAM,CAAC;IACd,eAAe,CAAC,EAAE,KAAK,CAAC,YAAY,EAAE,CAAC;IACvC,gBAAgB,CAAC,EAAE,MAAM,IAAI,CAAC;IAC9B,UAAU,CAAC,EAAE,MAAM,GAAG,MAAM,EAAE,CAAC;IAC/B,cAAc,CAAC,EAAE,MAAM,IAAI,CAAC;IAC5B,YAAY,CAAC,EAAE,MAAM,IAAI,CAAC;IAC1B,MAAM,CAAC,EAAE,YAAY,CAAC;IACtB,WAAW,CAAC,EAAE,MAAM,IAAI,CAAC;CAC1B;AAsCD,eAAO,MAAM,gBAAgB,8NAqB1B,qBAAqB,
|
|
1
|
+
{"version":3,"file":"simple-course.d.ts","sourceRoot":"","sources":["../../../../../src/components/card/simple-course/simple-course.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,MAAM,OAAO,CAAC;AAY1B,MAAM,MAAM,YAAY,GACpB,OAAO,GACP,WAAW,GACX,gBAAgB,GAChB,WAAW,GACX,iBAAiB,GACjB,QAAQ,CAAC;AAEb,MAAM,WAAW,qBAAqB;IACpC,OAAO,CAAC,EAAE,KAAK,CAAC,YAAY,CAAC;IAC7B,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,KAAK,EAAE,MAAM,CAAC;IACd,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,SAAS,EAAE,MAAM,CAAC;IAClB,KAAK,EAAE,MAAM,CAAC;IACd,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,QAAQ,EAAE,MAAM,CAAC;IACjB,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,WAAW,CAAC,EAAE,KAAK,CAAC,YAAY,CAAC;IACjC,EAAE,CAAC,EAAE,MAAM,CAAC;IACZ,KAAK,EAAE,MAAM,CAAC;IACd,eAAe,CAAC,EAAE,KAAK,CAAC,YAAY,EAAE,CAAC;IACvC,gBAAgB,CAAC,EAAE,MAAM,IAAI,CAAC;IAC9B,UAAU,CAAC,EAAE,MAAM,GAAG,MAAM,EAAE,CAAC;IAC/B,cAAc,CAAC,EAAE,MAAM,IAAI,CAAC;IAC5B,YAAY,CAAC,EAAE,MAAM,IAAI,CAAC;IAC1B,MAAM,CAAC,EAAE,YAAY,CAAC;IACtB,WAAW,CAAC,EAAE,MAAM,IAAI,CAAC;CAC1B;AAsCD,eAAO,MAAM,gBAAgB,8NAqB1B,qBAAqB,4CAoSvB,CAAC"}
|