Construction.vue 1.3 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455
  1. <template>
  2. <view class="construction-frame">
  3. <slot>
  4. <view class="construction-inner">
  5. <FlexCol center :gap="16" :padding="[40, 32]">
  6. <Icon icon="warning-filling" :size="56" color="#f5c518" />
  7. <Text :text="title" fontConfig="title" textAlign="center" bold />
  8. <Text :text="text" fontConfig="subText" textAlign="center" color="text.second" />
  9. <slot />
  10. </FlexCol>
  11. </view>
  12. </slot>
  13. </view>
  14. </template>
  15. <script setup lang="ts">
  16. import Icon from '@/components/basic/Icon.vue';
  17. import Text from '@/components/basic/Text.vue';
  18. import FlexCol from '@/components/layout/FlexCol.vue';
  19. withDefaults(defineProps<{
  20. /** 说明文字 */
  21. text?: string;
  22. /** 标题 */
  23. title?: string;
  24. }>(), {
  25. text: '此功能正在开发中,敬请期待',
  26. title: '开发建设中',
  27. });
  28. </script>
  29. <style lang="scss" scoped>
  30. .construction-frame {
  31. width: 100%;
  32. max-width: 640rpx;
  33. padding: 10rpx;
  34. border-radius: 20rpx;
  35. background-color: #f5c518;
  36. background-image: repeating-linear-gradient(
  37. -45deg,
  38. #1a1a1a 0,
  39. #1a1a1a 18rpx,
  40. #f5c518 18rpx,
  41. #f5c518 36rpx
  42. );
  43. box-shadow: 0 8rpx 24rpx rgba(0, 0, 0, 0.08);
  44. }
  45. .construction-inner {
  46. border-radius: 14rpx;
  47. background: #fff;
  48. overflow: hidden;
  49. }
  50. </style>