telescopic.js 617 B

123456789101112131415161718192021222324252627
  1. Page({
  2. data: {
  3. theme: 'light',
  4. },
  5. onLoad() {
  6. this.setData({
  7. theme: wx.getSystemInfoSync().theme || 'light'
  8. })
  9. if (wx.onThemeChange) {
  10. wx.onThemeChange(({theme}) => {
  11. this.setData({theme})
  12. })
  13. }
  14. // wx.showModal({
  15. // content: '暂不支持该功能,可在windows版微信(2.9.5及以上版本)中拖动窗口大小查看效果',
  16. // showCancel: false,
  17. // confirmText: '我知道了'
  18. // })
  19. },
  20. onShareAppMessage() {
  21. return {
  22. title: '左右伸缩',
  23. path: 'packageExtend/pages/adapt/telescopic/telescopic'
  24. }
  25. },
  26. })