Nevar pievienot vairāk kā 25 tēmas Tēmai ir jāsākas ar burtu vai ciparu, tā var saturēt domu zīmes ('-') un var būt līdz 35 simboliem gara.
 
 

1 rinda
3.3 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 { makeStyles } from \"@material-ui/core/styles\";\nimport styles from \"assets/jss/nextjs-material-kit/pages/profilePage.js\";\nimport Grid from '@material-ui/core/Grid';\nimport GridContainer from \"components/Grid/GridContainer.js\";\nimport GridItem from \"components/Grid/GridItem.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 Paginations from \"components/Pagination/Pagination.js\";\nimport Icon from \"@material-ui/core/Icon\";\nconst useStyles = makeStyles(styles);\n\nconst DataLatestNews = function (_ref) {\n let {\n backend,\n sales\n } = _ref,\n props = _objectWithoutProperties(_ref, [\"backend\", \"sales\"]);\n\n const classes = useStyles();\n const Sales = sales.map(data => {\n return __jsx(Grid, {\n align: \"center\",\n style: {\n padding: \"30px\",\n marginTop: \"-50px\"\n }\n }, __jsx(Card, {\n style: {\n width: \"20rem\"\n }\n }, __jsx(\"img\", {\n style: {\n height: \"180px\",\n width: \"100%\",\n display: \"block\"\n },\n className: classes.imgCardTop,\n src: `${backend}${data.foto[\"url\"]}`\n }), __jsx(CardBody, null, __jsx(\"p\", null, __jsx(\"b\", null, data.name)), __jsx(\"p\", null, __jsx(\"b\", null, data.job_title)), __jsx(Button, {\n color: \"info\",\n round: true,\n href: \"/sales/sales_detail?s=\" + data.id\n }, __jsx(Icon, {\n className: classes.icons\n }, \"open_in_new\"), \"Read More\"))));\n });\n return __jsx(Card, {\n className: classes.textCenter\n }, __jsx(\"div\", {\n align: \"center\"\n }, __jsx(CardHeader, {\n color: \"info\"\n }, __jsx(\"b\", null, \"Sales\"))), __jsx(CardBody, null, __jsx(\"div\", {\n align: \"center\"\n }, __jsx(\"h2\", null, __jsx(\"b\", null, \"Latest News\"))), __jsx(GridContainer, {\n justify: \"center\"\n }, Sales)), __jsx(\"div\", {\n align: \"center\"\n }, __jsx(Paginations, {\n pages: [{\n text: \"PREV\"\n }, {\n text: 1\n }, {\n text: 2\n }, {\n active: true,\n text: 3\n }, {\n text: 4\n }, {\n text: 5\n }, {\n text: \"NEXT\"\n }],\n color: \"info\"\n })));\n};\n\nexport default DataLatestNews;","map":null,"metadata":{},"sourceType":"module"}