App.vue 1.5 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273
  1. <script>
  2. export default {
  3. globalData: {
  4. navHeight: "",
  5. },
  6. onLaunch: function() {
  7. console.warn('当前组件仅支持 uni_modules 目录结构 ,请升级 HBuilderX 到 3.1.0 版本以上!')
  8. console.log('App Launch')
  9. wx.getSystemInfo({
  10. success: res => {
  11. this.globalData.navHeight = res.statusBarHeight + 52 + "px"; // 赋值导航高度
  12. },
  13. fail(err) {
  14. console.log(err);
  15. }
  16. })
  17. },
  18. onShow: function() {
  19. console.log('App Show')
  20. },
  21. onHide: function() {
  22. console.log('App Hide')
  23. }
  24. }
  25. </script>
  26. <style>
  27. /*每个页面公共css */
  28. /* 解决头条小程序组件内引入字体不生效的问题 */
  29. /* #ifdef MP-TOUTIAO */
  30. @font-face {
  31. font-family: uniicons;
  32. src: url("/static/uni.ttf");
  33. }
  34. /* #endif */
  35. .home {
  36. width: 97%;
  37. margin: 0 auto;
  38. /* padding-top: 23%; */
  39. }
  40. /deep/ textarea{
  41. width: auto;
  42. }
  43. /deep/ .uni-forms-item__content {
  44. display: flex !important;
  45. align-items: center !important;
  46. /* justify-content: space-between; */
  47. }
  48. p {
  49. word-break: break-all;
  50. }
  51. text {
  52. word-break: break-all;
  53. }
  54. /deep/.uni-forms-item__inner {
  55. padding-bottom: 0rpx !important;
  56. margin-bottom: 30rpx !important;
  57. border-bottom: 0.5rpx solid #CCCCCC !important;
  58. }
  59. /* /deep/ .share .uni-popup .uni-popup__wrapper{
  60. width: 70% !important;
  61. border-radius: 15rpx !important;
  62. }
  63. /deep/ .share1 .uni-popup .uni-popup__wrapper{
  64. width: 85% !important;
  65. } */
  66. </style>