navigator-back.vue 1.5 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182
  1. <template>
  2. <view class="navigatorback_container">
  3. <view class="sign">
  4. <view class="robot">
  5. <image src="../../static/nav_robot.png" mode="aspectFit"></image>
  6. </view>
  7. <view class="titleText">SmartAssistant</view>
  8. </view>
  9. <view class="backContent">
  10. <view class="back_image" @click="clickToGoback">
  11. <image src="../../static/goback.png" mode="aspectFit"></image>
  12. </view>
  13. </view>
  14. </view>
  15. </template>
  16. <script>
  17. export default {
  18. data() {
  19. return {
  20. }
  21. },
  22. methods: {
  23. clickToGoback() {
  24. uni.navigateBack()
  25. }
  26. }
  27. }
  28. </script>
  29. <style lang="scss">
  30. .navigatorback_container{
  31. display: flex;
  32. box-sizing: border-box;
  33. flex-direction: column;
  34. width: 100%;
  35. height: 120px;
  36. // height: 105px;
  37. background-color: #2A2832;
  38. .sign{
  39. display: flex;
  40. box-sizing: border-box;
  41. height: 50%;
  42. flex-direction: row;
  43. align-items: center;
  44. background: linear-gradient(to right, #303373, #C9A391);
  45. .robot{
  46. flex-shrink: 0;
  47. width: 4%; // 48px;
  48. height: 100%; //48px;
  49. margin-left: 2%; // 15px;
  50. image{
  51. width: 100%;
  52. height: 100%;
  53. }
  54. }
  55. .titleText{
  56. display: flex;
  57. margin-left: 1%; //10px;
  58. font-size: 3vw; //30px;
  59. font-weight: 500;
  60. color: #ffffff;
  61. }
  62. }
  63. .backContent{
  64. display: flex;
  65. width: 100%;
  66. height: 50%;
  67. align-items: center;
  68. .back_image{
  69. margin-left: 2%; //15px;
  70. width: 4%; // 35px;
  71. height: 50%; //25px;
  72. image{
  73. width: 100%;
  74. height: 100%;
  75. }
  76. }
  77. }
  78. }
  79. </style>