保誠-保戶業務員媒合平台
HelenHuang
2022-01-04 873bb61290fadf81f3ebbe0bab04bb1b0cc82013
PAMapp/components/Ui/UiField.vue
@@ -14,16 +14,33 @@
<script lang="ts">
import { Vue, Component, Prop } from 'vue-property-decorator';
@Component
export default class UiCarousel extends Vue {
import UtilsService from '~/shared/services/utils.service';
  @Prop() span!: number;
  @Prop() icon!: string;
  @Prop() label!: string;
  @Prop() content!: string;
  @Prop() displayDevice!: 'MOBILE' | 'DESKTOP' | 'ALL';
@Component
export default class UiField extends Vue {
  @Prop()
  span!: number;
  @Prop()
  icon!: string;
  @Prop()
  label!: string;
  @Prop()
  content!: string;
  @Prop()
  displayDevice!: 'MOBILE' | 'DESKTOP' | 'ALL';
  currentDevice: 'MOBILE' | 'DESKTOP' = 'MOBILE';
  //////////////////////////////////////////////////////////////////
  mounted(): void {
    this.currentDevice = UtilsService.isMobileDevice() ? 'MOBILE' : 'DESKTOP';
  }
  get fieldSpan(): number {
    return this.span || 24;
@@ -64,6 +81,7 @@
  }
  .pam-field__content {
    padding-top: 10px;
    display: flex;
  }
}
</style>