diff --git a/src/views/Product/Rate/index.js b/src/views/Product/Rate/index.js index ccc0df6..6e3b7b6 100644 --- a/src/views/Product/Rate/index.js +++ b/src/views/Product/Rate/index.js @@ -1,25 +1,30 @@ import React from "react"; +import separate from '../../../utils/separate'; + +//components import StarRating from "../../../components/StarRating"; import Progress from "../../../components/Progress"; + + function Rate({ avarage, all, fields, desktop }) { return ( -
+
{ desktop ? -

+

{avarage}

: - + {avarage} }
- {all} + {separate(all)}
    {fields.map((item, index) => ( diff --git a/src/views/Product/index.js b/src/views/Product/index.js index d76abc5..b16595b 100644 --- a/src/views/Product/index.js +++ b/src/views/Product/index.js @@ -34,7 +34,7 @@ export const Product = ({ const [type, setType] = useState("physical"); const [desktopContentTransform, setDesktopContentTransform] = useState(false); const navigation = useNavigate(); - + useEffect(() => { getInfo({ id: location.getId(), vod: true }); setHeaderOptions(headerOptions); @@ -54,7 +54,7 @@ export const Product = ({ {/* Portrait */} {isMobile ? (
    - {!book && ( + {(!book) && (
    @@ -115,7 +115,7 @@ export const Product = ({ userId ? pushToCart({ @@ -138,7 +138,7 @@ export const Product = ({ userId ? pushToCart({ @@ -152,7 +152,7 @@ export const Product = ({ navigation('/videos/' + book?.idK)} + onClick={() => navigation("/videos/" + book?.id)} />