You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

1 line
15 KiB

  1. {"ast":null,"code":"var __jsx = React.createElement;\n\nfunction _objectWithoutProperties(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }\n\nfunction _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }\n\nimport React from \"react\";\nimport classNames from \"classnames\";\nimport { makeStyles } from \"@material-ui/core/styles\";\nimport GridContainer from \"components/Grid/GridContainer.js\";\nimport GridItem from \"components/Grid/GridItem.js\";\nimport NavPills from \"components/NavPills/NavPills.js\";\nimport Card from \"components/Card/Card.js\";\nimport CardBody from \"components/Card/CardBody.js\";\nimport CardHeader from \"components/Card/CardHeader.js\";\nimport Button from \"components/CustomButtons/Button.js\";\nimport styles from \"assets/jss/nextjs-material-kit/pages/profilePage.js\";\nimport Icon from \"@material-ui/core/Icon\";\nimport { Motorcycle } from \"@material-ui/icons\";\nimport NumberFormat from 'react-number-format';\nconst useStyles = makeStyles(styles);\n\nconst DataProduct = function (_ref) {\n let {\n backend,\n maxi,\n matic,\n naked,\n sport,\n offroad,\n moped,\n monsterenergy,\n cbu,\n product\n } = _ref,\n props = _objectWithoutProperties(_ref, [\"backend\", \"maxi\", \"matic\", \"naked\", \"sport\", \"offroad\", \"moped\", \"monsterenergy\", \"cbu\", \"product\"]);\n\n const classes = useStyles();\n const rest = Object.assign({}, props);\n const imageClasses = classNames(classes.imgRaised, classes.imgRoundedCircle, classes.imgFluid);\n const navImageClasses = classNames(classes.imgRounded, classes.imgGallery);\n const Product = product.map(data => {\n return __jsx(\"div\", {\n style: {\n padding: \"10px\",\n marginTop: \"-40px\"\n }\n }, __jsx(Card, {\n className: classes.textCenter,\n align: \"center\",\n style: {\n width: \"300px\"\n }\n }, __jsx(CardBody, null, __jsx(\"div\", null, __jsx(\"img\", {\n style: {\n width: \"200px\",\n display: \"block\"\n },\n src: `${backend}${data.img[0][\"url\"]}`,\n className: navImageClasses\n }), __jsx(\"div\", {\n align: \"center\"\n }, __jsx(\"h6\", null, __jsx(\"b\", null, data.name)), __jsx(\"h6\", null, __jsx(\"b\", null, __jsx(NumberFormat, {\n value: data.price,\n displayType: 'text',\n thousandSeparator: true,\n prefix: 'Rp.'\n }), \" s/d \", __jsx(NumberFormat, {\n value: data.price2,\n displayType: 'text',\n thousandSeparator: true,\n prefix: 'Rp.'\n }))), __jsx(Button, {\n color: \"info\",\n round: true,\n href: \"/yamaha/product/product_detail?s=\" + data.id\n }, __jsx(Icon, {\n className: classes.icons\n }, \"open_in_new\"), \"Detail Product\"), __jsx(Button, {\n color: \"info\",\n round: true,\n href: \"/yamaha/cart/checkout?s=\" + data.id\n }, __jsx(Icon, {\n className: classes.icons\n }, \"shopping_cart\"), \"Add to Cart\"))))));\n });\n const Productmaxi = maxi.map(data => {\n return __jsx(\"div\", {\n style: {\n padding: \"20px\",\n marginTop: \"-40px\"\n }\n }, __jsx(Card, {\n className: classes.textCenter,\n align: \"center\",\n style: {\n width: \"350px\"\n }\n }, __jsx(CardBody, null, __jsx(\"div\", {\n style: {\n padding: \"10px\"\n }\n }, __jsx(\"img\", {\n style: {\n width: \"250px\",\n display: \"block\"\n },\n src: `${backend}${data.img[0][\"url\"]}`,\n className: navImageClasses\n }), __jsx(\"div\", {\n align: \"center\"\n }, __jsx(\"h5\", null, __jsx(\"b\", null, data.name)), __jsx(\"h5\", null, __jsx(\"b\", null, __jsx(NumberFormat, {\n value: data.price,\n displayType: 'text',\n thousandSeparator: true,\n prefix: 'Rp.'\n }))), __jsx(Button, {\n color: \"info\",\n round: true,\n href: \"/yamaha/product/product_detail?s=\" + data.id\n }, __jsx(Icon, {\n className: classes.icons\n }, \"open_in_new\"), \"Detail Product\"), __jsx(Button, {\n color: \"info\",\n round: true,\n href: \"/yamaha/cart/checkout?s=\" + data.id\n }, __jsx(Icon, {\n className: classes.icons\n }, \"shopping_cart\"), \"Add to Cart\"))))));\n });\n const Productmatic = matic.map(data => {\n return __jsx(\"div\", {\n style: {\n padding: \"20px\",\n marginTop: \"-40px\"\n }\n }, __jsx(Card, {\n className: classes.textCenter,\n align: \"center\",\n style: {\n width: \"350px\"\n }\n }, __jsx(CardBody, null, __jsx(\"div\", {\n style: {\n padding: \"10px\"\n }\n }, __jsx(\"img\", {\n style: {\n width: \"250px\",\n display: \"block\"\n },\n src: `${backend}${data.img[0][\"url\"]}`,\n className: navImageClasses\n }), __jsx(\"div\", {\n align: \"center\"\n }, __jsx(\"h5\", null, __jsx(\"b\", null, data.name)), __jsx(\"h5\", null, __jsx(\"b\", null, __jsx(NumberFormat, {\n value: data.price,\n displayType: 'text',\n thousandSeparator: true,\n prefix: 'Rp.'\n }))), __jsx(Button, {\n color: \"info\",\n round: true,\n href: \"/yamaha/product/product_detail?s=\" + data.id\n }, __jsx(Icon, {\n className: classes.icons\n }, \"open_in_new\"), \"Detail Product\"))))));\n });\n const Productnaked = naked.map(data => {\n return __jsx(\"div\", {\n style: {\n padding: \"20px\",\n marginTop: \"-40px\"\n }\n }, __jsx(Card, {\n className: classes.textCenter,\n align: \"center\",\n style: {\n width: \"350px\"\n }\n }, __jsx(CardBody, null, __jsx(\"div\", {\n style: {\n padding: \"10px\"\n }\n }, __jsx(\"img\", {\n style: {\n width: \"250px\",\n display: \"block\"\n },\n src: `${backend}${data.img[0][\"url\"]}`,\n className: navImageClasses\n }), __jsx(\"div\", {\n align: \"center\"\n }, __jsx(\"h5\", null, __jsx(\"b\", null, data.name)), __jsx(\"h5\", null, __jsx(\"b\", null, __jsx(NumberFormat, {\n value: data.price,\n displayType: 'text',\n thousandSeparator: true,\n prefix: 'Rp.'\n }))), __jsx(Button, {\n color: \"info\",\n round: true,\n href: \"/yamaha/product/product_detail?s=\" + data.id\n }, __jsx(Icon, {\n className: classes.icons\n }, \"open_in_new\"), \"Detail Product\"))))));\n });\n const Productsport = sport.map(data => {\n return __jsx(\"div\", {\n style: {\n padding: \"20px\",\n marginTop: \"-40px\"\n }\n }, __jsx(Card, {\n className: classes.textCenter,\n align: \"center\",\n style: {\n width: \"350px\"\n }\n }, __jsx(CardBody, null, __jsx(\"div\", {\n style: {\n padding: \"10px\"\n }\n }, __jsx(\"img\", {\n style: {\n width: \"250px\",\n display: \"block\"\n },\n src: `${backend}${data.img[0][\"url\"]}`,\n className: navImageClasses\n }), __jsx(\"div\", {\n align: \"center\"\n }, __jsx(\"h5\", null, __jsx(\"b\", null, data.name)), __jsx(\"h5\", null, __jsx(\"b\", null, __jsx(NumberFormat, {\n value: data.price,\n displayType: 'text',\n thousandSeparator: true,\n prefix: 'Rp.'\n }))), __jsx(Button, {\n color: \"info\",\n round: true,\n href: \"/yamaha/product/product_detail?s=\" + data.id\n }, __jsx(Icon, {\n className: classes.icons\n }, \"open_in_new\"), \"Detail Product\"))))));\n });\n const Productoffroad = offroad.map(data => {\n return __jsx(\"div\", {\n style: {\n padding: \"20px\",\n marginTop: \"-40px\"\n }\n }, __jsx(Card, {\n className: classes.textCenter,\n align: \"center\",\n style: {\n width: \"350px\"\n }\n }, __jsx(CardBody, null, __jsx(\"div\", {\n style: {\n padding: \"10px\"\n }\n }, __jsx(\"img\", {\n style: {\n width: \"250px\",\n display: \"block\"\n },\n src: `${backend}${data.img[0][\"url\"]}`,\n className: navImageClasses\n }), __jsx(\"div\", {\n align: \"center\"\n }, __jsx(\"h5\", null, __jsx(\"b\", null, data.name)), __jsx(\"h5\", null, __jsx(\"b\", null, __jsx(NumberFormat, {\n value: data.price,\n displayType: 'text',\n thousandSeparator: true,\n prefix: 'Rp.'\n }))), __jsx(Button, {\n color: \"info\",\n round: true,\n href: \"/yamaha/product/product_detail?s=\" + data.id\n }, __jsx(Icon, {\n className: classes.icons\n }, \"open_in_new\"), \"Detail Product\"))))));\n });\n const Productmoped = moped.map(data => {\n return __jsx(\"div\", {\n style: {\n padding: \"20px\",\n marginTop: \"-40px\"\n }\n }, __jsx(Card, {\n className: classes.textCenter,\n align: \"center\",\n style: {\n width: \"350px\"\n }\n }, __jsx(CardBody, null, __jsx(\"div\", {\n style: {\n padding: \"10px\"\n }\n }, __jsx(\"img\", {\n style: {\n width: \"250px\",\n display: \"block\"\n },\n src: `${backend}${data.img[0][\"url\"]}`,\n className: navImageClasses\n }), __jsx(\"div\", {\n align: \"center\"\n }, __jsx(\"h5\", null, __jsx(\"b\", null, data.name)), __jsx(\"h5\", null, __jsx(\"b\", null, __jsx(NumberFormat, {\n value: data.price,\n displayType: 'text',\n thousandSeparator: true,\n prefix: 'Rp.'\n }))), __jsx(Button, {\n color: \"info\",\n round: true,\n href: \"/yamaha/product/product_detail?s=\" + data.id\n }, __jsx(Icon, {\n className: classes.icons\n }, \"open_in_new\"), \"Detail Product\"))))));\n });\n const Productmonsterenergy = monsterenergy.map(data => {\n return __jsx(\"div\", {\n style: {\n padding: \"20px\",\n marginTop: \"-40px\"\n }\n }, __jsx(Card, {\n className: classes.textCenter,\n align: \"center\",\n style: {\n width: \"350px\"\n }\n }, __jsx(CardBody, null, __jsx(\"div\", {\n style: {\n padding: \"10px\"\n }\n }, __jsx(\"img\", {\n style: {\n width: \"250px\",\n display: \"block\"\n },\n src: `${backend}${data.img[0][\"url\"]}`,\n className: navImageClasses\n }), __jsx(\"div\", {\n align: \"center\"\n }, __jsx(\"h5\", null, __jsx(\"b\", null, data.name)), __jsx(\"h5\", null, __jsx(\"b\", null, __jsx(NumberFormat, {\n value: data.price,\n displayType: 'text',\n thousandSeparator: true,\n prefix: 'Rp.'\n }))), __jsx(Button, {\n color: \"info\",\n round: true,\n href: \"/yamaha/product/product_detail?s=\" + data.id\n }, __jsx(Icon, {\n className: classes.icons\n }, \"open_in_new\"), \"Detail Product\"))))));\n });\n const Productcbu = cbu.map(data => {\n return __jsx(\"div\", {\n style: {\n padding: \"20px\",\n marginTop: \"-40px\"\n }\n }, __jsx(Card, {\n className: classes.textCenter,\n align: \"center\",\n style: {\n width: \"350px\"\n }\n }, __jsx(CardBody, null, __jsx(\"div\", {\n style: {\n padding: \"10px\"\n }\n }, __jsx(\"img\", {\n style: {\n width: \"250px\",\n display: \"block\"\n },\n src: `${backend}${data.img[0][\"url\"]}`,\n className: navImageClasses\n }), __jsx(\"div\", {\n align: \"center\"\n }, __jsx(\"h5\", null, __jsx(\"b\", null, data.name)), __jsx(\"h5\", null, __jsx(\"b\", null, __jsx(NumberFormat, {\n value: data.price,\n displayType: 'text',\n thousandSeparator: true,\n prefix: 'Rp.'\n }))), __jsx(Button, {\n color: \"info\",\n round: true,\n href: \"/yamaha/product/product_detail?s=\" + data.id\n }, __jsx(Icon, {\n className: classes.icons\n }, \"open_in_new\"), \"Detail Product\"))))));\n });\n return __jsx(Card, {\n className: classes.textCenter\n }, __jsx(\"div\", {\n align: \"center\"\n }, __jsx(CardHeader, {\n color: \"info\"\n }, \"Product\")), __jsx(CardBody, null, __jsx(\"div\", {\n align: \"center\"\n }, __jsx(\"h2\", null, __jsx(\"b\", null, \"Product & Facilities\"))), __jsx(GridContainer, {\n justify: \"center\"\n }, __jsx(GridItem, null, __jsx(NavPills, {\n alignCenter: true,\n color: \"primary\",\n tabs: [{\n tabButton: \"Motor Product\",\n tabIcon: Motorcycle,\n tabContent: __jsx(GridContainer, {\n justify: \"center\"\n }, Product)\n } //{\n // tabButton: \"Matic\",\n // tabIcon: Motorcycle,\n // tabContent: (\n // <GridContainer justify=\"center\">\n // {Productmatic}\n // </GridContainer>\n // ),\n // },\n // {\n // tabButton: \"Naked Bike\",\n // tabIcon: Motorcycle,\n // tabContent: (\n // <GridContainer justify=\"center\">\n // {Productnaked}\n // </GridContainer>\n // ),\n // },\n // {\n // tabButton: \"Sport\",\n // tabIcon: Motorcycle,\n // tabContent: (\n // <GridContainer justify=\"center\">\n // {Productsport}\n // </GridContainer>\n // ),\n // },\n // {\n // tabButton: \"Off Road\",\n // tabIcon: Motorcycle,\n // tabContent: (\n // <GridContainer justify=\"center\">\n // {Productoffroad}\n // </GridContainer>\n // ),\n // },\n // {\n // tabButton: \"Moped\",\n // tabIcon: Motorcycle,\n // tabContent: (\n // <GridContainer justify=\"center\">\n // {Productmoped}\n // </GridContainer>\n // ),\n // },\n // {\n // tabButton: \"Monster Energy MotoGP\",\n // tabIcon: Motorcycle,\n // tabContent: (\n // <GridContainer justify=\"center\">\n // {Productmonsterenergy}\n // </GridContainer>\n // ),\n // },\n // {\n // tabButton: \"CBU\",\n // tabIcon: Motorcycle,\n // tabContent: (\n // <GridContainer justify=\"center\">\n // {Productcbu}\n // </GridContainer>\n // ),\n // },\n // {\n // tabButton: \"ATV\",\n // tabIcon: Motorcycle,\n // tabContent: (\n // <GridContainer justify=\"center\">\n // {Productcbu}\n // </GridContainer>\n // ),\n // },\n ]\n })))));\n};\n\nexport default DataProduct;","map":null,"metadata":{},"sourceType":"module"}