zhengyiming
2 天以前 83f7e95067ccca1735043a9a870564003e920e71
packages/components/src/components/Card/OrderCardItem.vue
@@ -1,6 +1,9 @@
<template>
  <div class="order-card-item">
    <div class="order-card-item-label" :style="{ width: labelWidth, textAlign: textAlign }">
  <div class="order-card-item" :class="{ danger }">
    <div
      class="order-card-item-label"
      :style="{ width: Taro.pxTransform(labelWidth), textAlign: textAlign }"
    >
      <slot name="label">{{ label }}</slot>
    </div>
    <div class="order-card-item-value">
@@ -10,19 +13,22 @@
</template>
<script setup lang="ts">
import Taro from '@tarojs/taro';
defineOptions({
  name: 'OrderCardItem',
});
type Props = {
  label: string;
  value: string;
  value: any;
  labelWidth?: any;
  textAlign?: any;
  danger?: boolean;
};
const props = withDefaults(defineProps<Props>(), {
  labelWidth: '80px',
  labelWidth: 140,
  textAlign: 'left',
});
</script>