index.jsx 2.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778
  1. import {TextGroup} from '@components';
  2. import {Text, View} from '@tarojs/components';
  3. import classNames from 'classnames';
  4. import {Button} from '@nutui/nutui-react-taro';
  5. import {usePreview} from './hooks';
  6. export default function List() {
  7. const onClick = usePreview();
  8. return (
  9. <View className='h-screen overflow-auto bg-gray-200 py-4'>
  10. <View className='bg-white mx-4 rounded-lg px-3 py-4'>
  11. <View
  12. className={classNames(
  13. 'flex items-center overflow-hidden border-0 border-b border-gray-200 border-solid',
  14. 'pb-3',
  15. )}
  16. >
  17. <Text className='flex-1 text-over text-[#333] mr-2 text-sm'>
  18. TSDFSDFTSDF
  19. </Text>
  20. <View className='text-center w-16 h-7 leading-7 text-sm text-white bg-primary rounded-md'>
  21. 已送达
  22. </View>
  23. </View>
  24. <View className='mt-4 overflow-hidden border-0 border-b border-dashed border-gray-200 pb-4'>
  25. <View className='flex overflow-hidden text-sm text-gray-500'>
  26. <Text className='flex-1 block text-over mr-2'>品号</Text>
  27. <Text className='w-[7em]'>数量</Text>
  28. </View>
  29. <View className='flex overflow-hidden text-sm mt-2'>
  30. <Text className='flex-1 block text-over mr-2'>12312</Text>
  31. <Text className='w-[7em]'>9871876</Text>
  32. </View>
  33. <View className='flex overflow-hidden text-sm mt-2'>
  34. <Text className='flex-1 block text-over mr-2'>12312</Text>
  35. <Text className='w-[7em]'>9871876</Text>
  36. </View>
  37. <View className='flex overflow-hidden text-sm mt-2'>
  38. <Text className='flex-1 block text-over mr-2'>12312</Text>
  39. <Text className='w-[7em]'>9871876</Text>
  40. </View>
  41. </View>
  42. <View className='mt-4'>
  43. <TextGroup title='卡车号' content='123' className='py-0' />
  44. <TextGroup title='客户编号' content='123555' className='py-0 mt-2' />
  45. <TextGroup
  46. title='发货时间'
  47. content='2020-12-22'
  48. className='py-0 mt-2'
  49. />
  50. <TextGroup
  51. title='送达时间'
  52. content='2020-12-23'
  53. className='py-0 mt-2'
  54. />
  55. </View>
  56. <View className='flex justify-end mt-2'>
  57. <Button
  58. className='!h-9 !text-sm'
  59. onClick={onClick([
  60. 'https://picsum.photos/id/1/800/600',
  61. 'https://picsum.photos/id/2/800/600',
  62. 'https://picsum.photos/id/3/800/600',
  63. 'https://picsum.photos/id/4/800/600',
  64. 'https://picsum.photos/id/5/800/600',
  65. ])}
  66. >
  67. 查看图片
  68. </Button>
  69. </View>
  70. </View>
  71. </View>
  72. );
  73. }