2024-02-13 06:22:45 +00:00
|
|
|
<template>
|
2024-02-20 14:47:55 +00:00
|
|
|
<component
|
|
|
|
v-if="template"
|
|
|
|
:is="template"
|
|
|
|
:index="index"
|
|
|
|
:active="active"
|
|
|
|
:highlighted="highlighted"
|
2024-04-30 14:09:49 +00:00
|
|
|
:class="cx('stepper.itemHeader')"
|
|
|
|
:headerClass="cx('stepper.itemHeader')"
|
|
|
|
:numberClass="cx('stepper.itemNumber')"
|
|
|
|
:titleClass="cx('stepper.itemTitle')"
|
2024-02-20 14:47:55 +00:00
|
|
|
:clickCallback="(event) => clickCallback(event, index)"
|
|
|
|
/>
|
2024-04-30 14:09:49 +00:00
|
|
|
<button v-else :id="id" :class="cx('stepper.itemHeader')" role="tab" :tabindex="disabled ? -1 : undefined" :aria-controls="ariaControls" @click="clickCallback($event, index)" v-bind="getStepPT(stepperpanel, 'itemHeader', index)">
|
|
|
|
<span :class="cx('stepper.itemNumber')" v-bind="getStepPT(stepperpanel, 'itemNumber', index)">{{ index + 1 }}</span>
|
2024-05-08 09:57:59 +00:00
|
|
|
<span :class="cx('stepper.itemTitle')" v-bind="getStepPT(stepperpanel, 'itemTitle', index)">{{ getStepProp(stepperpanel, 'header') }}</span>
|
2024-02-13 06:22:45 +00:00
|
|
|
</button>
|
|
|
|
</template>
|
|
|
|
|
|
|
|
<script>
|
|
|
|
import BaseComponent from 'primevue/basecomponent';
|
|
|
|
|
|
|
|
export default {
|
|
|
|
name: 'StepperHeader',
|
|
|
|
hostName: 'Stepper',
|
|
|
|
extends: BaseComponent,
|
|
|
|
props: {
|
|
|
|
id: null,
|
|
|
|
template: null,
|
|
|
|
stepperpanel: null,
|
|
|
|
index: null,
|
|
|
|
disabled: null,
|
|
|
|
active: null,
|
|
|
|
highlighted: null,
|
|
|
|
ariaControls: null,
|
|
|
|
clickCallback: null,
|
|
|
|
getStepPT: null,
|
|
|
|
getStepProp: null
|
|
|
|
}
|
|
|
|
};
|
|
|
|
</script>
|