acdr-ui/dist/dev/mp-weixin/sheep/components/s-share-modal/canvas-poster/poster/groupon.js.map

1 line
5.1 KiB
Plaintext
Raw Normal View History

2024-09-19 07:20:14 +08:00
{"version":3,"file":"groupon.js","sources":["../../../../../../../../src/sheep/components/s-share-modal/canvas-poster/poster/groupon.js"],"sourcesContent":["import sheep from '@/sheep'\r\nimport { formatImageUrlProtocol, getWxaQrcode } from './index'\r\n\r\nconst groupon = async (poster) => {\r\n const width = poster.width\r\n const userInfo = sheep.$store('user').userInfo\r\n const wxa_qrcode = await getWxaQrcode(poster.shareInfo.path, poster.shareInfo.query)\r\n return [\r\n {\r\n type: 'image',\r\n src: formatImageUrlProtocol(\r\n sheep.$url.cdn(sheep.$store('app').platform.share.posterInfo.groupon_bg),\r\n ),\r\n css: {\r\n width,\r\n position: 'fixed',\r\n 'object-fit': 'contain',\r\n top: '0',\r\n left: '0',\r\n zIndex: -1,\r\n },\r\n },\r\n {\r\n type: 'text',\r\n text: userInfo.nickname,\r\n css: {\r\n color: '#333',\r\n fontSize: 16,\r\n fontFamily: 'sans-serif',\r\n position: 'fixed',\r\n top: width * 0.06,\r\n left: width * 0.22,\r\n },\r\n },\r\n {\r\n type: 'image',\r\n src: formatImageUrlProtocol(sheep.$url.cdn(userInfo.avatar)),\r\n css: {\r\n position: 'fixed',\r\n left: width * 0.04,\r\n top: width * 0.04,\r\n width: width * 0.14,\r\n height: width * 0.14,\r\n },\r\n },\r\n {\r\n type: 'image',\r\n src: formatImageUrlProtocol(poster.shareInfo.poster.image),\r\n css: {\r\n position: 'fixed',\r\n left: width * 0.03,\r\n top: width * 0.21,\r\n width: width * 0.94,\r\n height: width * 0.94,\r\n borderRadius: 10,\r\n },\r\n },\r\n {\r\n type: 'text',\r\n text: poster.shareInfo.poster.title,\r\n css: {\r\n color: '#333',\r\n fontSize: 14,\r\n position: 'fixed',\r\n top: width * 1.18,\r\n left: width * 0.04,\r\n maxWidth: width * 0.91,\r\n lineHeight: 5,\r\n },\r\n },\r\n {\r\n type: 'text',\r\n text: '¥' + poster.shareInfo.poster.price,\r\n css: {\r\n color: '#ff0000',\r\n fontSize: 20,\r\n fontFamily: 'OPPOSANS',\r\n position: 'fixed',\r\n top: width * 1.3,\r\n left: width * 0.04,\r\n },\r\n },\r\n {\r\n type: 'text',\r\n text: '2人团',\r\n css: {\r\n color: '#fff',\r\n fontSize: 12,\r\n fontFamily: 'OPPOSANS',\r\n position: 'fixed',\r\n left: width * 0.84,\r\n top: width * 1.3,\r\n },\r\n },\r\n // #ifndef MP-WEIXIN\r\n {\r\n type: 'qrcode',\r\n text: poster.shareInfo.link,\r\n css: {\r\n position: 'fixed',\r\n left: width * 0.5,\r\n top: width * 1.3,\r\n width: width * 0.2,\r\n height: width * 0.2,\r\n },\r\n },\r\n // #endif\r\n // #ifdef MP-WEIXIN\r\n {\r\n type: 'image',\r\n src: wxa_qrcode,\r\n css: {\r\n position: 'fixed',\r\n left: width * 0.75,\r\n top: width * 1.3,\r\n width: width * 0.2,\r\n height: width * 0.2,\r\n },\r\n },\r\n // #endif\r\n ]\r\n}\r\n\r\nexport default groupon\r\n"],"names":["sheep","getWxaQrcode","formatImageUrlProtocol"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;AAGK,MAAC,UAAU,CAAO,WAAW;AAChC,QAAM,QAAQ,OAAO;AACrB,QAAM,WAAWA,YAAK,MAAC,OAAO,MAAM,EAAE;AACtC,QAAM,aAAa,MAAMC,uDAAAA,aAAa,OAAO,UAAU,MAAM,OAAO,UAAU,KAAK;AACnF,SAAO;AAAA,IACL;AAAA,MACE,MAAM;AAAA,MACN,KAAKC,uDAAsB;AAAA,QACzBF,YAAAA,MAAM,KAAK,IAAIA,YAAAA,MAAM,OAAO,KAAK,EAAE,SAAS,MAAM,WAAW,UAAU;AAAA,MACxE;AAAA,MACD,KAAK;AAAA,QACH;AAAA,QACA,UAAU;AAAA,QACV,cAAc;AAAA,QACd,KAAK;AAAA,QACL,MAAM;AAAA,QACN,QAAQ;AAAA,MACT;AAAA,IACF;AAAA,IACD;AAAA,MACE,MAAM;AAAA,MACN,MAAM,SAAS;AAAA,MACf,KAAK;AAAA,QACH,OAAO;AAAA,QACP,UAAU;AAAA,QACV,YAAY;AAAA,QACZ,UAAU;AAAA,QACV,KAAK,QAAQ;AAAA,QACb,MAAM,QAAQ;AAAA,MACf;AAAA,IACF;AAAA,IACD;AAAA,MACE,MAAM;AAAA,MACN,KAAKE,uDAAsB,uBAACF,kBAAM,KAAK,IAAI,SAAS,MAAM,CAAC;AAAA,MAC3D,KAAK;AAAA,QACH,U