pat-shared-components 1.3.2 → 1.3.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/src/components/TestResult/Desktop/TestResultDetailDesktop.vue.js +1 -1
- package/dist/src/components/TestResult/Desktop/TestResultDetailDesktop.vue.js.map +1 -1
- package/dist/src/components/TestResult/Desktop/TestResultDetailDesktop.vue.mjs +111 -92
- package/dist/src/components/TestResult/Desktop/TestResultDetailDesktop.vue.mjs.map +1 -1
- package/dist/src/components/TestResult/Mobile/ResultTab/TestResultDetail.vue.js +1 -1
- package/dist/src/components/TestResult/Mobile/ResultTab/TestResultDetail.vue.js.map +1 -1
- package/dist/src/components/TestResult/Mobile/ResultTab/TestResultDetail.vue.mjs +102 -83
- package/dist/src/components/TestResult/Mobile/ResultTab/TestResultDetail.vue.mjs.map +1 -1
- package/dist/src/components/TestResult/Shared/ResultInsightCards.vue.js +1 -1
- package/dist/src/components/TestResult/Shared/ResultInsightCards.vue.js.map +1 -1
- package/dist/src/components/TestResult/Shared/ResultInsightCards.vue.mjs +15 -21
- package/dist/src/components/TestResult/Shared/ResultInsightCards.vue.mjs.map +1 -1
- package/dist/src/locales/vi.json.js +1 -1
- package/dist/src/locales/vi.json.mjs +1 -1
- package/dist/style.css +1 -1
- package/dist/types/components/TestResult/Desktop/TestResultDetailDesktop.vue.d.ts +3 -0
- package/dist/types/components/TestResult/Mobile/ResultTab/TestResultDetail.vue.d.ts +3 -0
- package/dist/types/components/TestResult/Shared/ResultInsightCards.vue.d.ts +6 -26
- package/package.json +1 -1
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";const e=require("vue"),g=require("../../../composables/TestResult.js"),
|
|
1
|
+
"use strict";const e=require("vue"),g=require("../../../composables/TestResult.js"),x=require("../../Shared/PatientName.vue.js"),N=require("../Shared/ResultReadyV2.vue.js"),V=require("../Shared/RejectedResult.vue.js"),_=require("../Shared/BookAppointment.vue.js"),w=require("../Shared/ResultInsightCards.vue.js"),q=require("../HealthSummary/HealthSummary.vue.js"),n=require("../Shared/TestResultSection.vue.js"),T=require("../Shared/CallUsFilledButton.vue.js"),D=require("../Shared/DoctorNote.vue.js"),E=require("../Shared/DoctorNoteDetail.vue.js"),$=require("../Shared/UpcomingAppointment.vue.js"),A=require("../Shared/TestResultDetailSkeleton/TestResultDetailDesktopSkeleton.vue.js"),r=require("../../../helpers/SurveyHelper.js"),P=require("../../../composables/useSurveyConfig.js"),F=l=>Object.freeze(Object.defineProperty({__proto__:null,default:l},Symbol.toStringTag,{value:"Module"})),I={key:0,class:"psc-flex psc-items-start"},j={class:"-psc-ml-4 psc-mr-16 psc-w-[480px] psc-shrink-0 psc-grow-0"},O={class:"psc-sticky psc-top-[154px] psc-max-h-[calc(100vh-154px)] psc-overflow-y-auto"},H={class:"psc-min-w-0 psc-flex-1"},U={class:"psc-sticky psc-top-[154px] psc-max-h-[calc(100vh-154px)] psc-overflow-y-auto"},z=e.defineComponent({__name:"TestResultDetailDesktop",props:{testResult:null,loading:{type:Boolean},hidePatientInfo:{type:Boolean,default:!1},hideSummary:{type:Boolean,default:!1},enableBookingFeature:{type:Boolean,default:!1},timeline:{default:void 0},listActionEvent:{default:void 0},showResultReport:{type:Boolean,default:!1}},emits:["click:book-appointment","click:appointment-booking","click:result-report"],setup(l,{emit:u}){const t=l,m=e.defineAsyncComponent(()=>Promise.resolve().then(()=>F(require("../Shared/TakeSurvey.vue2.js")))),{healthSummaryItems:k,hideContent:y,isViewable:v,visible:c}=g.useTestResult({testResult:e.toRef(t,"testResult"),hidePatientInfo:e.toRef(t,"hidePatientInfo"),hideSummary:e.toRef(t,"hideSummary")}),{surveyConfig:i}=P.useSurveyConfig(),p=e.ref(!1),f=e.computed(()=>r.buildTestResultSurveyContext(t.testResult,"doctor-note")),B=e.computed(()=>r.getSurveySlug(t.testResult.collection_channel,t.testResult.is_free_consultant,i.value)),R=e.computed(()=>r.buildTestResultSurveyContext(t.testResult)),b=e.computed(()=>!!t.testResult.doctor_note_detail&&t.testResult.doctor_note_detail.length>0),S=e.computed(()=>r.isSurveyEnabledForTestResult(t.testResult.nps_test_result,t.testResult.collection_channel,t.testResult.is_free_consultant,i.value)),h=e.useSlots(),d=e.computed(()=>!!t.testResult.is_free_consultant||!!h["book-appointment-box"]),C=e.computed(()=>r.isTeledocSurveyEnabled(t.testResult.nps_doctor_consult,i.value));return(o,s)=>t.loading?(e.openBlock(),e.createBlock(A,{key:0})):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.unref(v)?(e.openBlock(),e.createElementBlock("div",I,[e.createElementVNode("div",j,[e.createElementVNode("div",O,[e.unref(c).patientName?(e.openBlock(),e.createBlock(x,{key:0,"first-name":t.testResult.first_name,class:"psc-px-4 psc-pb-2"},null,8,["first-name"])):e.createCommentVNode("",!0),e.createVNode(N,{"test-result":t.testResult,timeline:t.timeline,"list-action-event":t.listActionEvent,class:"psc-px-4 psc-pb-4"},null,8,["test-result","timeline","list-action-event"]),e.unref(c).healthSummary?(e.openBlock(),e.createBlock(n,{key:1},{default:e.withCtx(()=>[e.createVNode(q,{items:e.unref(k)},null,8,["items"])]),_:1})):e.createCommentVNode("",!0),t.showResultReport?(e.openBlock(),e.createBlock(w,{key:2,"onClick:report":s[1]||(s[1]=a=>u("click:result-report"))},e.createSlots({_:2},[e.unref(d)?{name:"book-appointment-box",fn:e.withCtx(()=>[o.$slots["book-appointment-box"]?e.renderSlot(o.$slots,"book-appointment-box",{key:0,compact:!0}):(e.openBlock(),e.createBlock(_,{key:1,compact:"","onClick:book":s[0]||(s[0]=a=>u("click:book-appointment"))}))]),key:"0"}:void 0]),1024)):e.unref(d)?(e.openBlock(),e.createBlock(n,{key:3},{default:e.withCtx(()=>[o.$slots["book-appointment-box"]?e.renderSlot(o.$slots,"book-appointment-box",{key:0,compact:!1}):(e.openBlock(),e.createBlock(_,{key:1,"onClick:book":s[2]||(s[2]=()=>{p.value=!0,u("click:book-appointment")})},e.createSlots({_:2},[l.enableBookingFeature&&p.value?{name:"content",fn:e.withCtx(()=>[e.renderSlot(o.$slots,"book-appointment")]),key:"0"}:void 0]),1024))]),_:3})):e.createCommentVNode("",!0),e.unref(c).doctorNote?(e.openBlock(),e.createBlock(n,{key:4},{default:e.withCtx(()=>[e.createVNode(D,{"doctor-note":t.testResult.doctor_note},null,8,["doctor-note"])]),_:1})):e.createCommentVNode("",!0),e.unref(b)?(e.openBlock(),e.createBlock(n,{key:5},{default:e.withCtx(()=>[e.createVNode(E,{"doctor-note-detail":l.testResult.doctor_note_detail,"survey-context":e.unref(C)?e.unref(f):void 0,"onClick:appointmentBooking":s[3]||(s[3]=a=>u("click:appointment-booking",a))},null,8,["doctor-note-detail","survey-context"])]),_:1})):e.createCommentVNode("",!0),e.unref(S)?(e.openBlock(),e.createBlock(n,{key:6},{default:e.withCtx(()=>[e.createVNode(e.unref(m),{variant:"bar","survey-slug":e.unref(B),context:e.unref(R),text:o.$t("psc.test_result_take_survey_button")},null,8,["survey-slug","context","text"])]),_:1})):e.createCommentVNode("",!0),e.unref(c).upcomingAppointment?(e.openBlock(),e.createBlock(n,{key:7},{default:e.withCtx(()=>[e.createVNode($,{"time-slot":t.testResult.consult_time},null,8,["time-slot"])]),_:1})):e.createCommentVNode("",!0)])]),e.createElementVNode("div",H,[e.createElementVNode("div",U,[e.renderSlot(o.$slots,"header"),e.unref(y)?e.createCommentVNode("",!0):e.renderSlot(o.$slots,"default",{key:0}),e.renderSlot(o.$slots,"footer")])])])):(e.openBlock(),e.createBlock(V,{key:1,class:"psc-px-4"},{"body-append":e.withCtx(()=>[e.createVNode(T,{class:"psc-mt-6"})]),_:1}))],64))}});module.exports=z;
|
|
2
2
|
//# sourceMappingURL=TestResultDetailDesktop.vue.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"TestResultDetailDesktop.vue.js","sources":["../../../../../src/components/TestResult/Desktop/TestResultDetailDesktop.vue?vue&type=script&setup=true&lang.ts"],"sourcesContent":["import { defineComponent as _defineComponent } from 'vue'\nimport { openBlock as _openBlock, createBlock as _createBlock, createCommentVNode as _createCommentVNode, unref as _unref, createVNode as _createVNode, withCtx as _withCtx, renderSlot as _renderSlot, createSlots as _createSlots, createElementVNode as _createElementVNode, createElementBlock as _createElementBlock, Fragment as _Fragment } from \"vue\"\n\nconst _hoisted_1 = {\n key: 0,\n class: \"psc-flex psc-items-start\"\n}\nconst _hoisted_2 = { class: \"-psc-ml-4 psc-mr-16 psc-w-[480px] psc-shrink-0 psc-grow-0\" }\nconst _hoisted_3 = { class: \"psc-sticky psc-top-[154px] psc-max-h-[calc(100vh-154px)] psc-overflow-y-auto\" }\nconst _hoisted_4 = { class: \"psc-min-w-0 psc-flex-1\" }\nconst _hoisted_5 = { class: \"psc-sticky psc-top-[154px] psc-max-h-[calc(100vh-154px)] psc-overflow-y-auto\" }\n\nimport { useTestResult } from '@/composables/TestResult';\nimport PatientName from '../../Shared/PatientName.vue';\nimport ResultReadyV2 from '../Shared/ResultReadyV2.vue';\nimport RejectedResult from '../Shared/RejectedResult.vue';\nimport BookAppointment from '../Shared/BookAppointment.vue';\nimport ResultInsightCards from '../Shared/ResultInsightCards.vue';\nimport HealthSummary from '../HealthSummary/HealthSummary.vue';\nimport TestResultSection from '../Shared/TestResultSection.vue';\nimport CallUsFilledButton from '../Shared/CallUsFilledButton.vue';\nimport DoctorNote from '../Shared/DoctorNote.vue';\nimport DoctorNoteDetail from '../Shared/DoctorNoteDetail.vue';\nimport type { TestResult } from '@/types';\nimport UpcomingAppointment from '../Shared/UpcomingAppointment.vue';\nimport { computed, defineAsyncComponent, ref, toRef } from 'vue';\nimport TestResultDetailDesktopSkeleton from '../Shared/TestResultDetailSkeleton/TestResultDetailDesktopSkeleton.vue';\nimport type { TimelineEvent } from '../Shared/ResultReadyV2.vue';\nimport {\n buildTestResultSurveyContext,\n getSurveySlug,\n isSurveyEnabledForTestResult,\n isTeledocSurveyEnabled,\n} from '@/helpers/SurveyHelper';\nimport { useSurveyConfig } from '@/composables/useSurveyConfig';\n\nexport interface Props {\n testResult: TestResult;\n loading: boolean;\n hidePatientInfo?: boolean;\n hideSummary?: boolean;\n enableBookingFeature?: boolean;\n timeline?: TimelineEvent[];\n listActionEvent?: Record<string, string>;\n showResultReport?: boolean;\n}\n\nexport default /*#__PURE__*/_defineComponent({\n __name: 'TestResultDetailDesktop',\n props: {\n testResult: null,\n loading: { type: Boolean },\n hidePatientInfo: { type: Boolean, default: false },\n hideSummary: { type: Boolean, default: false },\n enableBookingFeature: { type: Boolean, default: false },\n timeline: { default: undefined },\n listActionEvent: { default: undefined },\n showResultReport: { type: Boolean, default: false }\n },\n emits: [\n 'click:book-appointment',\n 'click:appointment-booking',\n 'click:result-report',\n],\n setup(__props: any, { emit }) {\n\nconst props = __props as { testResult: TestResult, loading: boolean, hidePatientInfo: boolean, hideSummary: boolean, enableBookingFeature: boolean, timeline: TimelineEvent[], listActionEvent: Record<string, string>, showResultReport: boolean };\n\n\n\nconst TakeSurvey = defineAsyncComponent(\n () => import('../Shared/TakeSurvey.vue')\n);\n\n\n\nconst { healthSummaryItems, hideContent, isViewable, visible } = useTestResult({\n testResult: toRef(props, 'testResult'),\n hidePatientInfo: toRef(props, 'hidePatientInfo'),\n hideSummary: toRef(props, 'hideSummary'),\n});\n\nconst { surveyConfig } = useSurveyConfig();\n\nconst isDisplayBook = ref(false);\n\nconst doctorNoteSurveyContext = computed(() =>\n buildTestResultSurveyContext(props.testResult, 'doctor-note')\n);\n\nconst testSurveySlug = computed(() =>\n getSurveySlug(\n props.testResult.collection_channel,\n props.testResult.is_free_consultant,\n surveyConfig.value\n )\n);\n\nconst testSurveyContext = computed(() =>\n buildTestResultSurveyContext(props.testResult)\n);\n\nconst hasDoctorNoteDetail = computed(\n () =>\n !!props.testResult.doctor_note_detail &&\n props.testResult.doctor_note_detail.length > 0\n);\n\nconst isSurveyEnabled = computed(() =>\n isSurveyEnabledForTestResult(\n props.testResult.nps_test_result,\n props.testResult.collection_channel,\n props.testResult.is_free_consultant,\n surveyConfig.value\n )\n);\n\nconst isTeledocSurveyVisible = computed(() =>\n isTeledocSurveyEnabled(\n props.testResult.nps_doctor_consult,\n surveyConfig.value\n )\n);\n\nreturn (_ctx: any,_cache: any) => {\n return (props.loading)\n ? (_openBlock(), _createBlock(TestResultDetailDesktopSkeleton, { key: 0 }))\n : (_openBlock(), _createElementBlock(_Fragment, { key: 1 }, [\n (_unref(isViewable))\n ? (_openBlock(), _createElementBlock(\"div\", _hoisted_1, [\n _createElementVNode(\"div\", _hoisted_2, [\n _createElementVNode(\"div\", _hoisted_3, [\n (_unref(visible).patientName)\n ? (_openBlock(), _createBlock(PatientName, {\n key: 0,\n \"first-name\": props.testResult.first_name,\n class: \"psc-px-4 psc-pb-2\"\n }, null, 8, [\"first-name\"]))\n : _createCommentVNode(\"\", true),\n _createVNode(ResultReadyV2, {\n \"test-result\": props.testResult,\n timeline: props.timeline,\n \"list-action-event\": props.listActionEvent,\n class: \"psc-px-4 psc-pb-4\"\n }, null, 8, [\"test-result\", \"timeline\", \"list-action-event\"]),\n (_unref(visible).healthSummary)\n ? (_openBlock(), _createBlock(TestResultSection, { key: 1 }, {\n default: _withCtx(() => [\n _createVNode(HealthSummary, { items: _unref(healthSummaryItems) }, null, 8, [\"items\"])\n ]),\n _: 1\n }))\n : _createCommentVNode(\"\", true),\n (props.showResultReport)\n ? (_openBlock(), _createBlock(ResultInsightCards, {\n key: 2,\n \"show-book-appointment\": __props.testResult.is_free_consultant,\n \"onClick:report\": _cache[0] || (_cache[0] = ($event: any) => (emit('click:result-report'))),\n \"onClick:book\": _cache[1] || (_cache[1] = ($event: any) => (emit('click:book-appointment')))\n }, null, 8, [\"show-book-appointment\"]))\n : (__props.testResult.is_free_consultant)\n ? (_openBlock(), _createBlock(TestResultSection, { key: 3 }, {\n default: _withCtx(() => [\n _createVNode(BookAppointment, {\n \"onClick:book\": _cache[2] || (_cache[2] = \n () => {\n isDisplayBook.value = true;\n emit('click:book-appointment');\n }\n )\n }, _createSlots({ _: 2 }, [\n (__props.enableBookingFeature && isDisplayBook.value)\n ? {\n name: \"content\",\n fn: _withCtx(() => [\n _renderSlot(_ctx.$slots, \"book-appointment\")\n ]),\n key: \"0\"\n }\n : undefined\n ]), 1024)\n ]),\n _: 3\n }))\n : _createCommentVNode(\"\", true),\n (_unref(visible).doctorNote)\n ? (_openBlock(), _createBlock(TestResultSection, { key: 4 }, {\n default: _withCtx(() => [\n _createVNode(DoctorNote, {\n \"doctor-note\": props.testResult.doctor_note\n }, null, 8, [\"doctor-note\"])\n ]),\n _: 1\n }))\n : _createCommentVNode(\"\", true),\n (_unref(hasDoctorNoteDetail))\n ? (_openBlock(), _createBlock(TestResultSection, { key: 5 }, {\n default: _withCtx(() => [\n _createVNode(DoctorNoteDetail, {\n \"doctor-note-detail\": __props.testResult.doctor_note_detail!,\n \"survey-context\": \n _unref(isTeledocSurveyVisible) ? _unref(doctorNoteSurveyContext) : undefined\n ,\n \"onClick:appointmentBooking\": _cache[3] || (_cache[3] = ($event: any) => (\n emit('click:appointment-booking', $event)\n ))\n }, null, 8, [\"doctor-note-detail\", \"survey-context\"])\n ]),\n _: 1\n }))\n : _createCommentVNode(\"\", true),\n (_unref(isSurveyEnabled))\n ? (_openBlock(), _createBlock(TestResultSection, { key: 6 }, {\n default: _withCtx(() => [\n _createVNode(_unref(TakeSurvey), {\n variant: \"bar\",\n \"survey-slug\": _unref(testSurveySlug),\n context: _unref(testSurveyContext),\n text: _ctx.$t('psc.test_result_take_survey_button')\n }, null, 8, [\"survey-slug\", \"context\", \"text\"])\n ]),\n _: 1\n }))\n : _createCommentVNode(\"\", true),\n (_unref(visible).upcomingAppointment)\n ? (_openBlock(), _createBlock(TestResultSection, { key: 7 }, {\n default: _withCtx(() => [\n _createVNode(UpcomingAppointment, {\n \"time-slot\": props.testResult.consult_time!\n }, null, 8, [\"time-slot\"])\n ]),\n _: 1\n }))\n : _createCommentVNode(\"\", true)\n ])\n ]),\n _createElementVNode(\"div\", _hoisted_4, [\n _createElementVNode(\"div\", _hoisted_5, [\n _renderSlot(_ctx.$slots, \"header\"),\n (!_unref(hideContent))\n ? _renderSlot(_ctx.$slots, \"default\", { key: 0 })\n : _createCommentVNode(\"\", true),\n _renderSlot(_ctx.$slots, \"footer\")\n ])\n ])\n ]))\n : (_openBlock(), _createBlock(RejectedResult, {\n key: 1,\n class: \"psc-px-4\"\n }, {\n \"body-append\": _withCtx(() => [\n _createVNode(CallUsFilledButton, { class: \"psc-mt-6\" })\n ]),\n _: 1\n }))\n ], 64))\n}\n}\n\n})"],"names":["_hoisted_1","_hoisted_2","_hoisted_3","_hoisted_4","_hoisted_5","_sfc_main","_defineComponent","__props","emit","props","TakeSurvey","defineAsyncComponent","_interopNamespaceDefaultOnly","healthSummaryItems","hideContent","isViewable","visible","useTestResult","toRef","surveyConfig","useSurveyConfig","isDisplayBook","ref","doctorNoteSurveyContext","computed","buildTestResultSurveyContext","testSurveySlug","getSurveySlug","testSurveyContext","hasDoctorNoteDetail","isSurveyEnabled","isSurveyEnabledForTestResult","isTeledocSurveyVisible","isTeledocSurveyEnabled","_ctx","_cache","_openBlock","_createBlock","TestResultDetailDesktopSkeleton","_createElementBlock","_Fragment","_unref","_createElementVNode","PatientName","_createCommentVNode","_createVNode","ResultReadyV2","TestResultSection","_withCtx","HealthSummary","ResultInsightCards","$event","BookAppointment","_createSlots","_renderSlot","DoctorNote","DoctorNoteDetail","UpcomingAppointment","RejectedResult","CallUsFilledButton"],"mappings":"23BAGMA,EAAa,CACjB,IAAK,EACL,MAAO,0BACT,EACMC,EAAa,CAAE,MAAO,6DACtBC,EAAa,CAAE,MAAO,gFACtBC,EAAa,CAAE,MAAO,0BACtBC,EAAa,CAAE,MAAO,gFAqCAC,EAAiBC,kBAAA,CAC3C,OAAQ,0BACR,MAAO,CACL,WAAY,KACZ,QAAS,CAAE,KAAM,OAAQ,EACzB,gBAAiB,CAAE,KAAM,QAAS,QAAS,EAAM,EACjD,YAAa,CAAE,KAA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AE,EAEX,CAEA,CAAC"}
|
|
1
|
+
{"version":3,"file":"TestResultDetailDesktop.vue.js","sources":["../../../../../src/components/TestResult/Desktop/TestResultDetailDesktop.vue?vue&type=script&setup=true&lang.ts"],"sourcesContent":["import { defineComponent as _defineComponent } from 'vue'\nimport { openBlock as _openBlock, createBlock as _createBlock, createCommentVNode as _createCommentVNode, unref as _unref, createVNode as _createVNode, withCtx as _withCtx, renderSlot as _renderSlot, createSlots as _createSlots, createElementVNode as _createElementVNode, createElementBlock as _createElementBlock, Fragment as _Fragment } from \"vue\"\n\nconst _hoisted_1 = {\n key: 0,\n class: \"psc-flex psc-items-start\"\n}\nconst _hoisted_2 = { class: \"-psc-ml-4 psc-mr-16 psc-w-[480px] psc-shrink-0 psc-grow-0\" }\nconst _hoisted_3 = { class: \"psc-sticky psc-top-[154px] psc-max-h-[calc(100vh-154px)] psc-overflow-y-auto\" }\nconst _hoisted_4 = { class: \"psc-min-w-0 psc-flex-1\" }\nconst _hoisted_5 = { class: \"psc-sticky psc-top-[154px] psc-max-h-[calc(100vh-154px)] psc-overflow-y-auto\" }\n\nimport { useTestResult } from '@/composables/TestResult';\nimport PatientName from '../../Shared/PatientName.vue';\nimport ResultReadyV2 from '../Shared/ResultReadyV2.vue';\nimport RejectedResult from '../Shared/RejectedResult.vue';\nimport BookAppointment from '../Shared/BookAppointment.vue';\nimport ResultInsightCards from '../Shared/ResultInsightCards.vue';\nimport HealthSummary from '../HealthSummary/HealthSummary.vue';\nimport TestResultSection from '../Shared/TestResultSection.vue';\nimport CallUsFilledButton from '../Shared/CallUsFilledButton.vue';\nimport DoctorNote from '../Shared/DoctorNote.vue';\nimport DoctorNoteDetail from '../Shared/DoctorNoteDetail.vue';\nimport type { TestResult } from '@/types';\nimport UpcomingAppointment from '../Shared/UpcomingAppointment.vue';\nimport { computed, defineAsyncComponent, ref, toRef, useSlots } from 'vue';\nimport TestResultDetailDesktopSkeleton from '../Shared/TestResultDetailSkeleton/TestResultDetailDesktopSkeleton.vue';\nimport type { TimelineEvent } from '../Shared/ResultReadyV2.vue';\nimport {\n buildTestResultSurveyContext,\n getSurveySlug,\n isSurveyEnabledForTestResult,\n isTeledocSurveyEnabled,\n} from '@/helpers/SurveyHelper';\nimport { useSurveyConfig } from '@/composables/useSurveyConfig';\n\nexport interface Props {\n testResult: TestResult;\n loading: boolean;\n hidePatientInfo?: boolean;\n hideSummary?: boolean;\n enableBookingFeature?: boolean;\n timeline?: TimelineEvent[];\n listActionEvent?: Record<string, string>;\n showResultReport?: boolean;\n}\n\nexport default /*#__PURE__*/_defineComponent({\n __name: 'TestResultDetailDesktop',\n props: {\n testResult: null,\n loading: { type: Boolean },\n hidePatientInfo: { type: Boolean, default: false },\n hideSummary: { type: Boolean, default: false },\n enableBookingFeature: { type: Boolean, default: false },\n timeline: { default: undefined },\n listActionEvent: { default: undefined },\n showResultReport: { type: Boolean, default: false }\n },\n emits: [\n 'click:book-appointment',\n 'click:appointment-booking',\n 'click:result-report',\n],\n setup(__props: any, { emit }) {\n\nconst props = __props as { testResult: TestResult, loading: boolean, hidePatientInfo: boolean, hideSummary: boolean, enableBookingFeature: boolean, timeline: TimelineEvent[], listActionEvent: Record<string, string>, showResultReport: boolean };\n\n\n\nconst TakeSurvey = defineAsyncComponent(\n () => import('../Shared/TakeSurvey.vue')\n);\n\n\n\nconst { healthSummaryItems, hideContent, isViewable, visible } = useTestResult({\n testResult: toRef(props, 'testResult'),\n hidePatientInfo: toRef(props, 'hidePatientInfo'),\n hideSummary: toRef(props, 'hideSummary'),\n});\n\nconst { surveyConfig } = useSurveyConfig();\n\nconst isDisplayBook = ref(false);\n\nconst doctorNoteSurveyContext = computed(() =>\n buildTestResultSurveyContext(props.testResult, 'doctor-note')\n);\n\nconst testSurveySlug = computed(() =>\n getSurveySlug(\n props.testResult.collection_channel,\n props.testResult.is_free_consultant,\n surveyConfig.value\n )\n);\n\nconst testSurveyContext = computed(() =>\n buildTestResultSurveyContext(props.testResult)\n);\n\nconst hasDoctorNoteDetail = computed(\n () =>\n !!props.testResult.doctor_note_detail &&\n props.testResult.doctor_note_detail.length > 0\n);\n\nconst isSurveyEnabled = computed(() =>\n isSurveyEnabledForTestResult(\n props.testResult.nps_test_result,\n props.testResult.collection_channel,\n props.testResult.is_free_consultant,\n surveyConfig.value\n )\n);\n\n// DPT-8995: the host's `book-appointment-box` slot replaces BookAppointment and is not\n// gated by is_free_consultant.\nconst slots = useSlots();\nconst showBookAppointmentBox = computed(\n () => !!props.testResult.is_free_consultant || !!slots['book-appointment-box']\n);\n\nconst isTeledocSurveyVisible = computed(() =>\n isTeledocSurveyEnabled(\n props.testResult.nps_doctor_consult,\n surveyConfig.value\n )\n);\n\nreturn (_ctx: any,_cache: any) => {\n return (props.loading)\n ? (_openBlock(), _createBlock(TestResultDetailDesktopSkeleton, { key: 0 }))\n : (_openBlock(), _createElementBlock(_Fragment, { key: 1 }, [\n (_unref(isViewable))\n ? (_openBlock(), _createElementBlock(\"div\", _hoisted_1, [\n _createElementVNode(\"div\", _hoisted_2, [\n _createElementVNode(\"div\", _hoisted_3, [\n (_unref(visible).patientName)\n ? (_openBlock(), _createBlock(PatientName, {\n key: 0,\n \"first-name\": props.testResult.first_name,\n class: \"psc-px-4 psc-pb-2\"\n }, null, 8, [\"first-name\"]))\n : _createCommentVNode(\"\", true),\n _createVNode(ResultReadyV2, {\n \"test-result\": props.testResult,\n timeline: props.timeline,\n \"list-action-event\": props.listActionEvent,\n class: \"psc-px-4 psc-pb-4\"\n }, null, 8, [\"test-result\", \"timeline\", \"list-action-event\"]),\n (_unref(visible).healthSummary)\n ? (_openBlock(), _createBlock(TestResultSection, { key: 1 }, {\n default: _withCtx(() => [\n _createVNode(HealthSummary, { items: _unref(healthSummaryItems) }, null, 8, [\"items\"])\n ]),\n _: 1\n }))\n : _createCommentVNode(\"\", true),\n (props.showResultReport)\n ? (_openBlock(), _createBlock(ResultInsightCards, {\n key: 2,\n \"onClick:report\": _cache[1] || (_cache[1] = ($event: any) => (emit('click:result-report')))\n }, _createSlots({ _: 2 }, [\n (_unref(showBookAppointmentBox))\n ? {\n name: \"book-appointment-box\",\n fn: _withCtx(() => [\n (_ctx.$slots['book-appointment-box'])\n ? _renderSlot(_ctx.$slots, \"book-appointment-box\", {\n key: 0,\n compact: true\n })\n : (_openBlock(), _createBlock(BookAppointment, {\n key: 1,\n compact: \"\",\n \"onClick:book\": _cache[0] || (_cache[0] = ($event: any) => (emit('click:book-appointment')))\n }))\n ]),\n key: \"0\"\n }\n : undefined\n ]), 1024))\n : (_unref(showBookAppointmentBox))\n ? (_openBlock(), _createBlock(TestResultSection, { key: 3 }, {\n default: _withCtx(() => [\n (_ctx.$slots['book-appointment-box'])\n ? _renderSlot(_ctx.$slots, \"book-appointment-box\", {\n key: 0,\n compact: false\n })\n : (_openBlock(), _createBlock(BookAppointment, {\n key: 1,\n \"onClick:book\": _cache[2] || (_cache[2] = \n () => {\n isDisplayBook.value = true;\n emit('click:book-appointment');\n }\n )\n }, _createSlots({ _: 2 }, [\n (__props.enableBookingFeature && isDisplayBook.value)\n ? {\n name: \"content\",\n fn: _withCtx(() => [\n _renderSlot(_ctx.$slots, \"book-appointment\")\n ]),\n key: \"0\"\n }\n : undefined\n ]), 1024))\n ]),\n _: 3\n }))\n : _createCommentVNode(\"\", true),\n (_unref(visible).doctorNote)\n ? (_openBlock(), _createBlock(TestResultSection, { key: 4 }, {\n default: _withCtx(() => [\n _createVNode(DoctorNote, {\n \"doctor-note\": props.testResult.doctor_note\n }, null, 8, [\"doctor-note\"])\n ]),\n _: 1\n }))\n : _createCommentVNode(\"\", true),\n (_unref(hasDoctorNoteDetail))\n ? (_openBlock(), _createBlock(TestResultSection, { key: 5 }, {\n default: _withCtx(() => [\n _createVNode(DoctorNoteDetail, {\n \"doctor-note-detail\": __props.testResult.doctor_note_detail!,\n \"survey-context\": \n _unref(isTeledocSurveyVisible) ? _unref(doctorNoteSurveyContext) : undefined\n ,\n \"onClick:appointmentBooking\": _cache[3] || (_cache[3] = ($event: any) => (\n emit('click:appointment-booking', $event)\n ))\n }, null, 8, [\"doctor-note-detail\", \"survey-context\"])\n ]),\n _: 1\n }))\n : _createCommentVNode(\"\", true),\n (_unref(isSurveyEnabled))\n ? (_openBlock(), _createBlock(TestResultSection, { key: 6 }, {\n default: _withCtx(() => [\n _createVNode(_unref(TakeSurvey), {\n variant: \"bar\",\n \"survey-slug\": _unref(testSurveySlug),\n context: _unref(testSurveyContext),\n text: _ctx.$t('psc.test_result_take_survey_button')\n }, null, 8, [\"survey-slug\", \"context\", \"text\"])\n ]),\n _: 1\n }))\n : _createCommentVNode(\"\", true),\n (_unref(visible).upcomingAppointment)\n ? (_openBlock(), _createBlock(TestResultSection, { key: 7 }, {\n default: _withCtx(() => [\n _createVNode(UpcomingAppointment, {\n \"time-slot\": props.testResult.consult_time!\n }, null, 8, [\"time-slot\"])\n ]),\n _: 1\n }))\n : _createCommentVNode(\"\", true)\n ])\n ]),\n _createElementVNode(\"div\", _hoisted_4, [\n _createElementVNode(\"div\", _hoisted_5, [\n _renderSlot(_ctx.$slots, \"header\"),\n (!_unref(hideContent))\n ? _renderSlot(_ctx.$slots, \"default\", { key: 0 })\n : _createCommentVNode(\"\", true),\n _renderSlot(_ctx.$slots, \"footer\")\n ])\n ])\n ]))\n : (_openBlock(), _createBlock(RejectedResult, {\n key: 1,\n class: \"psc-px-4\"\n }, {\n \"body-append\": _withCtx(() => [\n _createVNode(CallUsFilledButton, { class: \"psc-mt-6\" })\n ]),\n _: 1\n }))\n ], 64))\n}\n}\n\n})"],"names":["_hoisted_1","_hoisted_2","_hoisted_3","_hoisted_4","_hoisted_5","_sfc_main","_defineComponent","__props","emit","props","TakeSurvey","defineAsyncComponent","_interopNamespaceDefaultOnly","healthSummaryItems","hideContent","isViewable","visible","useTestResult","toRef","surveyConfig","useSurveyConfig","isDisplayBook","ref","doctorNoteSurveyContext","computed","buildTestResultSurveyContext","testSurveySlug","getSurveySlug","testSurveyContext","hasDoctorNoteDetail","isSurveyEnabled","isSurveyEnabledForTestResult","slots","useSlots","showBookAppointmentBox","isTeledocSurveyVisible","isTeledocSurveyEnabled","_ctx","_cache","_openBlock","_createBlock","TestResultDetailDesktopSkeleton","_createElementBlock","_Fragment","_unref","_createElementVNode","PatientName","_createCommentVNode","_createVNode","ResultReadyV2","TestResultSection","_withCtx","HealthSummary","ResultInsightCards","$event","_createSlots","_renderSlot","BookAppointment","DoctorNote","DoctorNoteDetail","UpcomingAppointment","RejectedResult","CallUsFilledButton"],"mappings":"23BAGMA,EAAa,CACjB,IAAK,EACL,MAAO,0BACT,EACMC,EAAa,CAAE,MAAO,6DACtBC,EAAa,CAAE,MAAO,gFACtBC,EAAa,CAAE,MAAO,0BACtBC,EAAa,CAAE,MAAO,gFAqCAC,EAAiBC,kBAAA,CAC3C,OAAQ,0BACR,MAAO,CACL,WAAY,KACZ,QAAS,CAAE,KAAM,OAAQ,EACzB,gBAAiB,CAAE,KAAM,QAAS,QAAS,EAAM,EACjD,YAAa,CAAE,KAAM,QAAS,QAAS,EAAM,EAC7C,qBAAsB,CAAE,KAAM,QAAS,QAAS,EAAM,EACtD,SAAU,CAAE,QAAS,MAAU,EAC/B,gBAAiB,CAAE,QAAS,MAAU,EACtC,iBAAkB,CAAE,KAAM,QAAS,QAAS,EAAM,CACpD,EACA,MAAO,CACP,yBACA,4BACA,qBACF,EACE,MAAMC,EAAc,CAAE,KAAAC,GAAQ,CAEhC,MAAMC,EAAQF,EAIRG,EAAaC,EAAA,qBACjB,IAAM,QAAO,QAAA,EAAA,KAAA,IAAAC,EAAA,QAAA,8BAA0B,CAAA,CAAA,CAAA,EAKnC,CAAE,mBAAAC,EAAoB,YAAAC,EAAa,WAAAC,EAAY,QAAAC,CAAA,EAAYC,EAAAA,cAAc,CAC7E,WAAYC,EAAAA,MAAMT,EAAO,YAAY,EACrC,gBAAiBS,EAAAA,MAAMT,EAAO,iBAAiB,EAC/C,YAAaS,EAAAA,MAAMT,EAAO,aAAa,CAAA,CACxC,EA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Component as
|
|
2
|
-
import { useTestResult as
|
|
3
|
-
import
|
|
4
|
-
import
|
|
5
|
-
import
|
|
6
|
-
import
|
|
7
|
-
import
|
|
8
|
-
import
|
|
9
|
-
import
|
|
10
|
-
import
|
|
11
|
-
import
|
|
12
|
-
import
|
|
13
|
-
import
|
|
14
|
-
import
|
|
15
|
-
import { buildTestResultSurveyContext as
|
|
16
|
-
import { useSurveyConfig as
|
|
17
|
-
const
|
|
1
|
+
import { defineComponent as I, defineAsyncComponent as P, toRef as v, ref as j, computed as a, useSlots as q, openBlock as o, createBlock as s, createElementBlock as h, Fragment as z, unref as e, createElementVNode as f, createCommentVNode as r, createVNode as c, withCtx as l, createSlots as x, renderSlot as u } from "vue";
|
|
2
|
+
import { useTestResult as G } from "../../../composables/TestResult.mjs";
|
|
3
|
+
import H from "../../Shared/PatientName.vue.mjs";
|
|
4
|
+
import J from "../Shared/ResultReadyV2.vue.mjs";
|
|
5
|
+
import K from "../Shared/RejectedResult.vue.mjs";
|
|
6
|
+
import S from "../Shared/BookAppointment.vue.mjs";
|
|
7
|
+
import L from "../Shared/ResultInsightCards.vue.mjs";
|
|
8
|
+
import M from "../HealthSummary/HealthSummary.vue.mjs";
|
|
9
|
+
import p from "../Shared/TestResultSection.vue.mjs";
|
|
10
|
+
import O from "../Shared/CallUsFilledButton.vue.mjs";
|
|
11
|
+
import Q from "../Shared/DoctorNote.vue.mjs";
|
|
12
|
+
import U from "../Shared/DoctorNoteDetail.vue.mjs";
|
|
13
|
+
import W from "../Shared/UpcomingAppointment.vue.mjs";
|
|
14
|
+
import X from "../Shared/TestResultDetailSkeleton/TestResultDetailDesktopSkeleton.vue.mjs";
|
|
15
|
+
import { buildTestResultSurveyContext as $, getSurveySlug as Y, isSurveyEnabledForTestResult as Z, isTeledocSurveyEnabled as tt } from "../../../helpers/SurveyHelper.mjs";
|
|
16
|
+
import { useSurveyConfig as et } from "../../../composables/useSurveyConfig.mjs";
|
|
17
|
+
const ot = {
|
|
18
18
|
key: 0,
|
|
19
19
|
class: "psc-flex psc-items-start"
|
|
20
|
-
},
|
|
20
|
+
}, st = { class: "-psc-ml-4 psc-mr-16 psc-w-[480px] psc-shrink-0 psc-grow-0" }, nt = { class: "psc-sticky psc-top-[154px] psc-max-h-[calc(100vh-154px)] psc-overflow-y-auto" }, lt = { class: "psc-min-w-0 psc-flex-1" }, it = { class: "psc-sticky psc-top-[154px] psc-max-h-[calc(100vh-154px)] psc-overflow-y-auto" }, St = /* @__PURE__ */ I({
|
|
21
21
|
__name: "TestResultDetailDesktop",
|
|
22
22
|
props: {
|
|
23
23
|
testResult: null,
|
|
@@ -34,134 +34,153 @@ const Z = {
|
|
|
34
34
|
"click:appointment-booking",
|
|
35
35
|
"click:result-report"
|
|
36
36
|
],
|
|
37
|
-
setup(
|
|
38
|
-
const t =
|
|
37
|
+
setup(k, { emit: m }) {
|
|
38
|
+
const t = k, g = P(
|
|
39
39
|
() => import("../Shared/TakeSurvey.vue2.mjs")
|
|
40
|
-
), { healthSummaryItems:
|
|
40
|
+
), { healthSummaryItems: B, hideContent: C, isViewable: w, visible: d } = G({
|
|
41
41
|
testResult: v(t, "testResult"),
|
|
42
42
|
hidePatientInfo: v(t, "hidePatientInfo"),
|
|
43
43
|
hideSummary: v(t, "hideSummary")
|
|
44
|
-
}), { surveyConfig:
|
|
45
|
-
() =>
|
|
46
|
-
),
|
|
47
|
-
() =>
|
|
44
|
+
}), { surveyConfig: y } = et(), b = j(!1), T = a(
|
|
45
|
+
() => $(t.testResult, "doctor-note")
|
|
46
|
+
), E = a(
|
|
47
|
+
() => Y(
|
|
48
48
|
t.testResult.collection_channel,
|
|
49
49
|
t.testResult.is_free_consultant,
|
|
50
|
-
|
|
50
|
+
y.value
|
|
51
51
|
)
|
|
52
|
-
),
|
|
53
|
-
() =>
|
|
54
|
-
),
|
|
52
|
+
), N = a(
|
|
53
|
+
() => $(t.testResult)
|
|
54
|
+
), V = a(
|
|
55
55
|
() => !!t.testResult.doctor_note_detail && t.testResult.doctor_note_detail.length > 0
|
|
56
|
-
),
|
|
57
|
-
() =>
|
|
56
|
+
), A = a(
|
|
57
|
+
() => Z(
|
|
58
58
|
t.testResult.nps_test_result,
|
|
59
59
|
t.testResult.collection_channel,
|
|
60
60
|
t.testResult.is_free_consultant,
|
|
61
|
-
|
|
61
|
+
y.value
|
|
62
62
|
)
|
|
63
|
-
),
|
|
64
|
-
() =>
|
|
63
|
+
), D = q(), R = a(
|
|
64
|
+
() => !!t.testResult.is_free_consultant || !!D["book-appointment-box"]
|
|
65
|
+
), F = a(
|
|
66
|
+
() => tt(
|
|
65
67
|
t.testResult.nps_doctor_consult,
|
|
66
|
-
|
|
68
|
+
y.value
|
|
67
69
|
)
|
|
68
70
|
);
|
|
69
|
-
return (
|
|
70
|
-
e(
|
|
71
|
-
f("div",
|
|
72
|
-
f("div",
|
|
73
|
-
e(d).patientName ? (o(), s(
|
|
71
|
+
return (n, i) => t.loading ? (o(), s(X, { key: 0 })) : (o(), h(z, { key: 1 }, [
|
|
72
|
+
e(w) ? (o(), h("div", ot, [
|
|
73
|
+
f("div", st, [
|
|
74
|
+
f("div", nt, [
|
|
75
|
+
e(d).patientName ? (o(), s(H, {
|
|
74
76
|
key: 0,
|
|
75
77
|
"first-name": t.testResult.first_name,
|
|
76
78
|
class: "psc-px-4 psc-pb-2"
|
|
77
|
-
}, null, 8, ["first-name"])) :
|
|
78
|
-
|
|
79
|
+
}, null, 8, ["first-name"])) : r("", !0),
|
|
80
|
+
c(J, {
|
|
79
81
|
"test-result": t.testResult,
|
|
80
82
|
timeline: t.timeline,
|
|
81
83
|
"list-action-event": t.listActionEvent,
|
|
82
84
|
class: "psc-px-4 psc-pb-4"
|
|
83
85
|
}, null, 8, ["test-result", "timeline", "list-action-event"]),
|
|
84
|
-
e(d).healthSummary ? (o(), s(
|
|
85
|
-
default:
|
|
86
|
-
|
|
86
|
+
e(d).healthSummary ? (o(), s(p, { key: 1 }, {
|
|
87
|
+
default: l(() => [
|
|
88
|
+
c(M, { items: e(B) }, null, 8, ["items"])
|
|
87
89
|
]),
|
|
88
90
|
_: 1
|
|
89
|
-
})) :
|
|
90
|
-
t.showResultReport ? (o(), s(
|
|
91
|
+
})) : r("", !0),
|
|
92
|
+
t.showResultReport ? (o(), s(L, {
|
|
91
93
|
key: 2,
|
|
92
|
-
"
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
94
|
+
"onClick:report": i[1] || (i[1] = (_) => m("click:result-report"))
|
|
95
|
+
}, x({ _: 2 }, [
|
|
96
|
+
e(R) ? {
|
|
97
|
+
name: "book-appointment-box",
|
|
98
|
+
fn: l(() => [
|
|
99
|
+
n.$slots["book-appointment-box"] ? u(n.$slots, "book-appointment-box", {
|
|
100
|
+
key: 0,
|
|
101
|
+
compact: !0
|
|
102
|
+
}) : (o(), s(S, {
|
|
103
|
+
key: 1,
|
|
104
|
+
compact: "",
|
|
105
|
+
"onClick:book": i[0] || (i[0] = (_) => m("click:book-appointment"))
|
|
106
|
+
}))
|
|
107
|
+
]),
|
|
108
|
+
key: "0"
|
|
109
|
+
} : void 0
|
|
110
|
+
]), 1024)) : e(R) ? (o(), s(p, { key: 3 }, {
|
|
111
|
+
default: l(() => [
|
|
112
|
+
n.$slots["book-appointment-box"] ? u(n.$slots, "book-appointment-box", {
|
|
113
|
+
key: 0,
|
|
114
|
+
compact: !1
|
|
115
|
+
}) : (o(), s(S, {
|
|
116
|
+
key: 1,
|
|
117
|
+
"onClick:book": i[2] || (i[2] = () => {
|
|
118
|
+
b.value = !0, m("click:book-appointment");
|
|
100
119
|
})
|
|
101
|
-
},
|
|
102
|
-
|
|
120
|
+
}, x({ _: 2 }, [
|
|
121
|
+
k.enableBookingFeature && b.value ? {
|
|
103
122
|
name: "content",
|
|
104
|
-
fn:
|
|
105
|
-
|
|
123
|
+
fn: l(() => [
|
|
124
|
+
u(n.$slots, "book-appointment")
|
|
106
125
|
]),
|
|
107
126
|
key: "0"
|
|
108
127
|
} : void 0
|
|
109
|
-
]), 1024)
|
|
128
|
+
]), 1024))
|
|
110
129
|
]),
|
|
111
130
|
_: 3
|
|
112
|
-
})) :
|
|
113
|
-
e(d).doctorNote ? (o(), s(
|
|
114
|
-
default:
|
|
115
|
-
|
|
131
|
+
})) : r("", !0),
|
|
132
|
+
e(d).doctorNote ? (o(), s(p, { key: 4 }, {
|
|
133
|
+
default: l(() => [
|
|
134
|
+
c(Q, {
|
|
116
135
|
"doctor-note": t.testResult.doctor_note
|
|
117
136
|
}, null, 8, ["doctor-note"])
|
|
118
137
|
]),
|
|
119
138
|
_: 1
|
|
120
|
-
})) :
|
|
121
|
-
e(
|
|
122
|
-
default:
|
|
123
|
-
|
|
124
|
-
"doctor-note-detail":
|
|
125
|
-
"survey-context": e(
|
|
126
|
-
"onClick:appointmentBooking":
|
|
139
|
+
})) : r("", !0),
|
|
140
|
+
e(V) ? (o(), s(p, { key: 5 }, {
|
|
141
|
+
default: l(() => [
|
|
142
|
+
c(U, {
|
|
143
|
+
"doctor-note-detail": k.testResult.doctor_note_detail,
|
|
144
|
+
"survey-context": e(F) ? e(T) : void 0,
|
|
145
|
+
"onClick:appointmentBooking": i[3] || (i[3] = (_) => m("click:appointment-booking", _))
|
|
127
146
|
}, null, 8, ["doctor-note-detail", "survey-context"])
|
|
128
147
|
]),
|
|
129
148
|
_: 1
|
|
130
|
-
})) :
|
|
131
|
-
e(
|
|
132
|
-
default:
|
|
133
|
-
|
|
149
|
+
})) : r("", !0),
|
|
150
|
+
e(A) ? (o(), s(p, { key: 6 }, {
|
|
151
|
+
default: l(() => [
|
|
152
|
+
c(e(g), {
|
|
134
153
|
variant: "bar",
|
|
135
|
-
"survey-slug": e(
|
|
136
|
-
context: e(
|
|
137
|
-
text:
|
|
154
|
+
"survey-slug": e(E),
|
|
155
|
+
context: e(N),
|
|
156
|
+
text: n.$t("psc.test_result_take_survey_button")
|
|
138
157
|
}, null, 8, ["survey-slug", "context", "text"])
|
|
139
158
|
]),
|
|
140
159
|
_: 1
|
|
141
|
-
})) :
|
|
142
|
-
e(d).upcomingAppointment ? (o(), s(
|
|
143
|
-
default:
|
|
144
|
-
|
|
160
|
+
})) : r("", !0),
|
|
161
|
+
e(d).upcomingAppointment ? (o(), s(p, { key: 7 }, {
|
|
162
|
+
default: l(() => [
|
|
163
|
+
c(W, {
|
|
145
164
|
"time-slot": t.testResult.consult_time
|
|
146
165
|
}, null, 8, ["time-slot"])
|
|
147
166
|
]),
|
|
148
167
|
_: 1
|
|
149
|
-
})) :
|
|
168
|
+
})) : r("", !0)
|
|
150
169
|
])
|
|
151
170
|
]),
|
|
152
|
-
f("div",
|
|
153
|
-
f("div",
|
|
154
|
-
|
|
155
|
-
e(
|
|
156
|
-
|
|
171
|
+
f("div", lt, [
|
|
172
|
+
f("div", it, [
|
|
173
|
+
u(n.$slots, "header"),
|
|
174
|
+
e(C) ? r("", !0) : u(n.$slots, "default", { key: 0 }),
|
|
175
|
+
u(n.$slots, "footer")
|
|
157
176
|
])
|
|
158
177
|
])
|
|
159
|
-
])) : (o(), s(
|
|
178
|
+
])) : (o(), s(K, {
|
|
160
179
|
key: 1,
|
|
161
180
|
class: "psc-px-4"
|
|
162
181
|
}, {
|
|
163
|
-
"body-append":
|
|
164
|
-
|
|
182
|
+
"body-append": l(() => [
|
|
183
|
+
c(O, { class: "psc-mt-6" })
|
|
165
184
|
]),
|
|
166
185
|
_: 1
|
|
167
186
|
}))
|
|
@@ -169,6 +188,6 @@ const Z = {
|
|
|
169
188
|
}
|
|
170
189
|
});
|
|
171
190
|
export {
|
|
172
|
-
|
|
191
|
+
St as default
|
|
173
192
|
};
|
|
174
193
|
//# sourceMappingURL=TestResultDetailDesktop.vue.mjs.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"TestResultDetailDesktop.vue.mjs","sources":["../../../../../src/components/TestResult/Desktop/TestResultDetailDesktop.vue?vue&type=script&setup=true&lang.ts"],"sourcesContent":["import { defineComponent as _defineComponent } from 'vue'\nimport { openBlock as _openBlock, createBlock as _createBlock, createCommentVNode as _createCommentVNode, unref as _unref, createVNode as _createVNode, withCtx as _withCtx, renderSlot as _renderSlot, createSlots as _createSlots, createElementVNode as _createElementVNode, createElementBlock as _createElementBlock, Fragment as _Fragment } from \"vue\"\n\nconst _hoisted_1 = {\n key: 0,\n class: \"psc-flex psc-items-start\"\n}\nconst _hoisted_2 = { class: \"-psc-ml-4 psc-mr-16 psc-w-[480px] psc-shrink-0 psc-grow-0\" }\nconst _hoisted_3 = { class: \"psc-sticky psc-top-[154px] psc-max-h-[calc(100vh-154px)] psc-overflow-y-auto\" }\nconst _hoisted_4 = { class: \"psc-min-w-0 psc-flex-1\" }\nconst _hoisted_5 = { class: \"psc-sticky psc-top-[154px] psc-max-h-[calc(100vh-154px)] psc-overflow-y-auto\" }\n\nimport { useTestResult } from '@/composables/TestResult';\nimport PatientName from '../../Shared/PatientName.vue';\nimport ResultReadyV2 from '../Shared/ResultReadyV2.vue';\nimport RejectedResult from '../Shared/RejectedResult.vue';\nimport BookAppointment from '../Shared/BookAppointment.vue';\nimport ResultInsightCards from '../Shared/ResultInsightCards.vue';\nimport HealthSummary from '../HealthSummary/HealthSummary.vue';\nimport TestResultSection from '../Shared/TestResultSection.vue';\nimport CallUsFilledButton from '../Shared/CallUsFilledButton.vue';\nimport DoctorNote from '../Shared/DoctorNote.vue';\nimport DoctorNoteDetail from '../Shared/DoctorNoteDetail.vue';\nimport type { TestResult } from '@/types';\nimport UpcomingAppointment from '../Shared/UpcomingAppointment.vue';\nimport { computed, defineAsyncComponent, ref, toRef } from 'vue';\nimport TestResultDetailDesktopSkeleton from '../Shared/TestResultDetailSkeleton/TestResultDetailDesktopSkeleton.vue';\nimport type { TimelineEvent } from '../Shared/ResultReadyV2.vue';\nimport {\n buildTestResultSurveyContext,\n getSurveySlug,\n isSurveyEnabledForTestResult,\n isTeledocSurveyEnabled,\n} from '@/helpers/SurveyHelper';\nimport { useSurveyConfig } from '@/composables/useSurveyConfig';\n\nexport interface Props {\n testResult: TestResult;\n loading: boolean;\n hidePatientInfo?: boolean;\n hideSummary?: boolean;\n enableBookingFeature?: boolean;\n timeline?: TimelineEvent[];\n listActionEvent?: Record<string, string>;\n showResultReport?: boolean;\n}\n\nexport default /*#__PURE__*/_defineComponent({\n __name: 'TestResultDetailDesktop',\n props: {\n testResult: null,\n loading: { type: Boolean },\n hidePatientInfo: { type: Boolean, default: false },\n hideSummary: { type: Boolean, default: false },\n enableBookingFeature: { type: Boolean, default: false },\n timeline: { default: undefined },\n listActionEvent: { default: undefined },\n showResultReport: { type: Boolean, default: false }\n },\n emits: [\n 'click:book-appointment',\n 'click:appointment-booking',\n 'click:result-report',\n],\n setup(__props: any, { emit }) {\n\nconst props = __props as { testResult: TestResult, loading: boolean, hidePatientInfo: boolean, hideSummary: boolean, enableBookingFeature: boolean, timeline: TimelineEvent[], listActionEvent: Record<string, string>, showResultReport: boolean };\n\n\n\nconst TakeSurvey = defineAsyncComponent(\n () => import('../Shared/TakeSurvey.vue')\n);\n\n\n\nconst { healthSummaryItems, hideContent, isViewable, visible } = useTestResult({\n testResult: toRef(props, 'testResult'),\n hidePatientInfo: toRef(props, 'hidePatientInfo'),\n hideSummary: toRef(props, 'hideSummary'),\n});\n\nconst { surveyConfig } = useSurveyConfig();\n\nconst isDisplayBook = ref(false);\n\nconst doctorNoteSurveyContext = computed(() =>\n buildTestResultSurveyContext(props.testResult, 'doctor-note')\n);\n\nconst testSurveySlug = computed(() =>\n getSurveySlug(\n props.testResult.collection_channel,\n props.testResult.is_free_consultant,\n surveyConfig.value\n )\n);\n\nconst testSurveyContext = computed(() =>\n buildTestResultSurveyContext(props.testResult)\n);\n\nconst hasDoctorNoteDetail = computed(\n () =>\n !!props.testResult.doctor_note_detail &&\n props.testResult.doctor_note_detail.length > 0\n);\n\nconst isSurveyEnabled = computed(() =>\n isSurveyEnabledForTestResult(\n props.testResult.nps_test_result,\n props.testResult.collection_channel,\n props.testResult.is_free_consultant,\n surveyConfig.value\n )\n);\n\nconst isTeledocSurveyVisible = computed(() =>\n isTeledocSurveyEnabled(\n props.testResult.nps_doctor_consult,\n surveyConfig.value\n )\n);\n\nreturn (_ctx: any,_cache: any) => {\n return (props.loading)\n ? (_openBlock(), _createBlock(TestResultDetailDesktopSkeleton, { key: 0 }))\n : (_openBlock(), _createElementBlock(_Fragment, { key: 1 }, [\n (_unref(isViewable))\n ? (_openBlock(), _createElementBlock(\"div\", _hoisted_1, [\n _createElementVNode(\"div\", _hoisted_2, [\n _createElementVNode(\"div\", _hoisted_3, [\n (_unref(visible).patientName)\n ? (_openBlock(), _createBlock(PatientName, {\n key: 0,\n \"first-name\": props.testResult.first_name,\n class: \"psc-px-4 psc-pb-2\"\n }, null, 8, [\"first-name\"]))\n : _createCommentVNode(\"\", true),\n _createVNode(ResultReadyV2, {\n \"test-result\": props.testResult,\n timeline: props.timeline,\n \"list-action-event\": props.listActionEvent,\n class: \"psc-px-4 psc-pb-4\"\n }, null, 8, [\"test-result\", \"timeline\", \"list-action-event\"]),\n (_unref(visible).healthSummary)\n ? (_openBlock(), _createBlock(TestResultSection, { key: 1 }, {\n default: _withCtx(() => [\n _createVNode(HealthSummary, { items: _unref(healthSummaryItems) }, null, 8, [\"items\"])\n ]),\n _: 1\n }))\n : _createCommentVNode(\"\", true),\n (props.showResultReport)\n ? (_openBlock(), _createBlock(ResultInsightCards, {\n key: 2,\n \"show-book-appointment\": __props.testResult.is_free_consultant,\n \"onClick:report\": _cache[0] || (_cache[0] = ($event: any) => (emit('click:result-report'))),\n \"onClick:book\": _cache[1] || (_cache[1] = ($event: any) => (emit('click:book-appointment')))\n }, null, 8, [\"show-book-appointment\"]))\n : (__props.testResult.is_free_consultant)\n ? (_openBlock(), _createBlock(TestResultSection, { key: 3 }, {\n default: _withCtx(() => [\n _createVNode(BookAppointment, {\n \"onClick:book\": _cache[2] || (_cache[2] = \n () => {\n isDisplayBook.value = true;\n emit('click:book-appointment');\n }\n )\n }, _createSlots({ _: 2 }, [\n (__props.enableBookingFeature && isDisplayBook.value)\n ? {\n name: \"content\",\n fn: _withCtx(() => [\n _renderSlot(_ctx.$slots, \"book-appointment\")\n ]),\n key: \"0\"\n }\n : undefined\n ]), 1024)\n ]),\n _: 3\n }))\n : _createCommentVNode(\"\", true),\n (_unref(visible).doctorNote)\n ? (_openBlock(), _createBlock(TestResultSection, { key: 4 }, {\n default: _withCtx(() => [\n _createVNode(DoctorNote, {\n \"doctor-note\": props.testResult.doctor_note\n }, null, 8, [\"doctor-note\"])\n ]),\n _: 1\n }))\n : _createCommentVNode(\"\", true),\n (_unref(hasDoctorNoteDetail))\n ? (_openBlock(), _createBlock(TestResultSection, { key: 5 }, {\n default: _withCtx(() => [\n _createVNode(DoctorNoteDetail, {\n \"doctor-note-detail\": __props.testResult.doctor_note_detail!,\n \"survey-context\": \n _unref(isTeledocSurveyVisible) ? _unref(doctorNoteSurveyContext) : undefined\n ,\n \"onClick:appointmentBooking\": _cache[3] || (_cache[3] = ($event: any) => (\n emit('click:appointment-booking', $event)\n ))\n }, null, 8, [\"doctor-note-detail\", \"survey-context\"])\n ]),\n _: 1\n }))\n : _createCommentVNode(\"\", true),\n (_unref(isSurveyEnabled))\n ? (_openBlock(), _createBlock(TestResultSection, { key: 6 }, {\n default: _withCtx(() => [\n _createVNode(_unref(TakeSurvey), {\n variant: \"bar\",\n \"survey-slug\": _unref(testSurveySlug),\n context: _unref(testSurveyContext),\n text: _ctx.$t('psc.test_result_take_survey_button')\n }, null, 8, [\"survey-slug\", \"context\", \"text\"])\n ]),\n _: 1\n }))\n : _createCommentVNode(\"\", true),\n (_unref(visible).upcomingAppointment)\n ? (_openBlock(), _createBlock(TestResultSection, { key: 7 }, {\n default: _withCtx(() => [\n _createVNode(UpcomingAppointment, {\n \"time-slot\": props.testResult.consult_time!\n }, null, 8, [\"time-slot\"])\n ]),\n _: 1\n }))\n : _createCommentVNode(\"\", true)\n ])\n ]),\n _createElementVNode(\"div\", _hoisted_4, [\n _createElementVNode(\"div\", _hoisted_5, [\n _renderSlot(_ctx.$slots, \"header\"),\n (!_unref(hideContent))\n ? _renderSlot(_ctx.$slots, \"default\", { key: 0 })\n : _createCommentVNode(\"\", true),\n _renderSlot(_ctx.$slots, \"footer\")\n ])\n ])\n ]))\n : (_openBlock(), _createBlock(RejectedResult, {\n key: 1,\n class: \"psc-px-4\"\n }, {\n \"body-append\": _withCtx(() => [\n _createVNode(CallUsFilledButton, { class: \"psc-mt-6\" })\n ]),\n _: 1\n }))\n ], 64))\n}\n}\n\n})"],"names":["_hoisted_1","_hoisted_2","_hoisted_3","_hoisted_4","_hoisted_5","_sfc_main","_defineComponent","__props","emit","props","TakeSurvey","defineAsyncComponent","healthSummaryItems","hideContent","isViewable","visible","useTestResult","toRef","surveyConfig","useSurveyConfig","isDisplayBook","ref","doctorNoteSurveyContext","computed","buildTestResultSurveyContext","testSurveySlug","getSurveySlug","testSurveyContext","hasDoctorNoteDetail","isSurveyEnabled","isSurveyEnabledForTestResult","isTeledocSurveyVisible","isTeledocSurveyEnabled","_ctx","_cache","_openBlock","_createBlock","TestResultDetailDesktopSkeleton","_createElementBlock","_Fragment","_unref","_createElementVNode","PatientName","_createCommentVNode","_createVNode","ResultReadyV2","TestResultSection","_withCtx","HealthSummary","ResultInsightCards","$event","BookAppointment","_createSlots","_renderSlot","DoctorNote","DoctorNoteDetail","UpcomingAppointment","RejectedResult","CallUsFilledButton"],"mappings":";;;;;;;;;;;;;;;;AAGA,MAAMA,IAAa;AAAA,EACjB,KAAK;AAAA,EACL,OAAO;AACT,GACMC,KAAa,EAAE,OAAO,+DACtBC,KAAa,EAAE,OAAO,kFACtBC,KAAa,EAAE,OAAO,4BACtBC,KAAa,EAAE,OAAO,kFAqCAC,KAAiBC,gBAAAA,EAAA;AAAA,EAC3C,QAAQ;AAAA,EACR,OAAO;AAAA,IACL,YAAY;AAAA,IACZ,SAAS,EAAE,MAAM,QAAQ;AAAA,IACzB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AoB,OAAOrC,IAAY;AAAA,YACrCiD,EAAYpB,EAAK,QAAQ,QAAQ;AAAA,YAC/BO,EAAO3B,CAAW,IAEhB8B,EAAoB,IAAI,EAAI,IAD5BU,EAAYpB,EAAK,QAAQ,WAAW,EAAE,KAAK,EAAG,CAAA;AAAA,YAElDoB,EAAYpB,EAAK,QAAQ,QAAQ;AAAA,UAAA,CAClC;AAAA,QAAA,CACF;AAAA,MACF,CAAA,MACAE,EAAW,GAAGC,EAAaqB,GAAgB;AAAA,QAC1C,KAAK;AAAA,QACL,OAAO;AAAA,MAAA,GACN;AAAA,QACD,eAAeV,EAAS,MAAM;AAAA,UAC5BH,EAAac,GAAoB,EAAE,OAAO,YAAY;AAAA,QAAA,CACvD;AAAA,QACD,GAAG;AAAA,MAAA,CACJ;AAAA,IAAA,GACJ,EAAE;AAAA,EAEX;AAEA,CAAC;"}
|
|
1
|
+
{"version":3,"file":"TestResultDetailDesktop.vue.mjs","sources":["../../../../../src/components/TestResult/Desktop/TestResultDetailDesktop.vue?vue&type=script&setup=true&lang.ts"],"sourcesContent":["import { defineComponent as _defineComponent } from 'vue'\nimport { openBlock as _openBlock, createBlock as _createBlock, createCommentVNode as _createCommentVNode, unref as _unref, createVNode as _createVNode, withCtx as _withCtx, renderSlot as _renderSlot, createSlots as _createSlots, createElementVNode as _createElementVNode, createElementBlock as _createElementBlock, Fragment as _Fragment } from \"vue\"\n\nconst _hoisted_1 = {\n key: 0,\n class: \"psc-flex psc-items-start\"\n}\nconst _hoisted_2 = { class: \"-psc-ml-4 psc-mr-16 psc-w-[480px] psc-shrink-0 psc-grow-0\" }\nconst _hoisted_3 = { class: \"psc-sticky psc-top-[154px] psc-max-h-[calc(100vh-154px)] psc-overflow-y-auto\" }\nconst _hoisted_4 = { class: \"psc-min-w-0 psc-flex-1\" }\nconst _hoisted_5 = { class: \"psc-sticky psc-top-[154px] psc-max-h-[calc(100vh-154px)] psc-overflow-y-auto\" }\n\nimport { useTestResult } from '@/composables/TestResult';\nimport PatientName from '../../Shared/PatientName.vue';\nimport ResultReadyV2 from '../Shared/ResultReadyV2.vue';\nimport RejectedResult from '../Shared/RejectedResult.vue';\nimport BookAppointment from '../Shared/BookAppointment.vue';\nimport ResultInsightCards from '../Shared/ResultInsightCards.vue';\nimport HealthSummary from '../HealthSummary/HealthSummary.vue';\nimport TestResultSection from '../Shared/TestResultSection.vue';\nimport CallUsFilledButton from '../Shared/CallUsFilledButton.vue';\nimport DoctorNote from '../Shared/DoctorNote.vue';\nimport DoctorNoteDetail from '../Shared/DoctorNoteDetail.vue';\nimport type { TestResult } from '@/types';\nimport UpcomingAppointment from '../Shared/UpcomingAppointment.vue';\nimport { computed, defineAsyncComponent, ref, toRef, useSlots } from 'vue';\nimport TestResultDetailDesktopSkeleton from '../Shared/TestResultDetailSkeleton/TestResultDetailDesktopSkeleton.vue';\nimport type { TimelineEvent } from '../Shared/ResultReadyV2.vue';\nimport {\n buildTestResultSurveyContext,\n getSurveySlug,\n isSurveyEnabledForTestResult,\n isTeledocSurveyEnabled,\n} from '@/helpers/SurveyHelper';\nimport { useSurveyConfig } from '@/composables/useSurveyConfig';\n\nexport interface Props {\n testResult: TestResult;\n loading: boolean;\n hidePatientInfo?: boolean;\n hideSummary?: boolean;\n enableBookingFeature?: boolean;\n timeline?: TimelineEvent[];\n listActionEvent?: Record<string, string>;\n showResultReport?: boolean;\n}\n\nexport default /*#__PURE__*/_defineComponent({\n __name: 'TestResultDetailDesktop',\n props: {\n testResult: null,\n loading: { type: Boolean },\n hidePatientInfo: { type: Boolean, default: false },\n hideSummary: { type: Boolean, default: false },\n enableBookingFeature: { type: Boolean, default: false },\n timeline: { default: undefined },\n listActionEvent: { default: undefined },\n showResultReport: { type: Boolean, default: false }\n },\n emits: [\n 'click:book-appointment',\n 'click:appointment-booking',\n 'click:result-report',\n],\n setup(__props: any, { emit }) {\n\nconst props = __props as { testResult: TestResult, loading: boolean, hidePatientInfo: boolean, hideSummary: boolean, enableBookingFeature: boolean, timeline: TimelineEvent[], listActionEvent: Record<string, string>, showResultReport: boolean };\n\n\n\nconst TakeSurvey = defineAsyncComponent(\n () => import('../Shared/TakeSurvey.vue')\n);\n\n\n\nconst { healthSummaryItems, hideContent, isViewable, visible } = useTestResult({\n testResult: toRef(props, 'testResult'),\n hidePatientInfo: toRef(props, 'hidePatientInfo'),\n hideSummary: toRef(props, 'hideSummary'),\n});\n\nconst { surveyConfig } = useSurveyConfig();\n\nconst isDisplayBook = ref(false);\n\nconst doctorNoteSurveyContext = computed(() =>\n buildTestResultSurveyContext(props.testResult, 'doctor-note')\n);\n\nconst testSurveySlug = computed(() =>\n getSurveySlug(\n props.testResult.collection_channel,\n props.testResult.is_free_consultant,\n surveyConfig.value\n )\n);\n\nconst testSurveyContext = computed(() =>\n buildTestResultSurveyContext(props.testResult)\n);\n\nconst hasDoctorNoteDetail = computed(\n () =>\n !!props.testResult.doctor_note_detail &&\n props.testResult.doctor_note_detail.length > 0\n);\n\nconst isSurveyEnabled = computed(() =>\n isSurveyEnabledForTestResult(\n props.testResult.nps_test_result,\n props.testResult.collection_channel,\n props.testResult.is_free_consultant,\n surveyConfig.value\n )\n);\n\n// DPT-8995: the host's `book-appointment-box` slot replaces BookAppointment and is not\n// gated by is_free_consultant.\nconst slots = useSlots();\nconst showBookAppointmentBox = computed(\n () => !!props.testResult.is_free_consultant || !!slots['book-appointment-box']\n);\n\nconst isTeledocSurveyVisible = computed(() =>\n isTeledocSurveyEnabled(\n props.testResult.nps_doctor_consult,\n surveyConfig.value\n )\n);\n\nreturn (_ctx: any,_cache: any) => {\n return (props.loading)\n ? (_openBlock(), _createBlock(TestResultDetailDesktopSkeleton, { key: 0 }))\n : (_openBlock(), _createElementBlock(_Fragment, { key: 1 }, [\n (_unref(isViewable))\n ? (_openBlock(), _createElementBlock(\"div\", _hoisted_1, [\n _createElementVNode(\"div\", _hoisted_2, [\n _createElementVNode(\"div\", _hoisted_3, [\n (_unref(visible).patientName)\n ? (_openBlock(), _createBlock(PatientName, {\n key: 0,\n \"first-name\": props.testResult.first_name,\n class: \"psc-px-4 psc-pb-2\"\n }, null, 8, [\"first-name\"]))\n : _createCommentVNode(\"\", true),\n _createVNode(ResultReadyV2, {\n \"test-result\": props.testResult,\n timeline: props.timeline,\n \"list-action-event\": props.listActionEvent,\n class: \"psc-px-4 psc-pb-4\"\n }, null, 8, [\"test-result\", \"timeline\", \"list-action-event\"]),\n (_unref(visible).healthSummary)\n ? (_openBlock(), _createBlock(TestResultSection, { key: 1 }, {\n default: _withCtx(() => [\n _createVNode(HealthSummary, { items: _unref(healthSummaryItems) }, null, 8, [\"items\"])\n ]),\n _: 1\n }))\n : _createCommentVNode(\"\", true),\n (props.showResultReport)\n ? (_openBlock(), _createBlock(ResultInsightCards, {\n key: 2,\n \"onClick:report\": _cache[1] || (_cache[1] = ($event: any) => (emit('click:result-report')))\n }, _createSlots({ _: 2 }, [\n (_unref(showBookAppointmentBox))\n ? {\n name: \"book-appointment-box\",\n fn: _withCtx(() => [\n (_ctx.$slots['book-appointment-box'])\n ? _renderSlot(_ctx.$slots, \"book-appointment-box\", {\n key: 0,\n compact: true\n })\n : (_openBlock(), _createBlock(BookAppointment, {\n key: 1,\n compact: \"\",\n \"onClick:book\": _cache[0] || (_cache[0] = ($event: any) => (emit('click:book-appointment')))\n }))\n ]),\n key: \"0\"\n }\n : undefined\n ]), 1024))\n : (_unref(showBookAppointmentBox))\n ? (_openBlock(), _createBlock(TestResultSection, { key: 3 }, {\n default: _withCtx(() => [\n (_ctx.$slots['book-appointment-box'])\n ? _renderSlot(_ctx.$slots, \"book-appointment-box\", {\n key: 0,\n compact: false\n })\n : (_openBlock(), _createBlock(BookAppointment, {\n key: 1,\n \"onClick:book\": _cache[2] || (_cache[2] = \n () => {\n isDisplayBook.value = true;\n emit('click:book-appointment');\n }\n )\n }, _createSlots({ _: 2 }, [\n (__props.enableBookingFeature && isDisplayBook.value)\n ? {\n name: \"content\",\n fn: _withCtx(() => [\n _renderSlot(_ctx.$slots, \"book-appointment\")\n ]),\n key: \"0\"\n }\n : undefined\n ]), 1024))\n ]),\n _: 3\n }))\n : _createCommentVNode(\"\", true),\n (_unref(visible).doctorNote)\n ? (_openBlock(), _createBlock(TestResultSection, { key: 4 }, {\n default: _withCtx(() => [\n _createVNode(DoctorNote, {\n \"doctor-note\": props.testResult.doctor_note\n }, null, 8, [\"doctor-note\"])\n ]),\n _: 1\n }))\n : _createCommentVNode(\"\", true),\n (_unref(hasDoctorNoteDetail))\n ? (_openBlock(), _createBlock(TestResultSection, { key: 5 }, {\n default: _withCtx(() => [\n _createVNode(DoctorNoteDetail, {\n \"doctor-note-detail\": __props.testResult.doctor_note_detail!,\n \"survey-context\": \n _unref(isTeledocSurveyVisible) ? _unref(doctorNoteSurveyContext) : undefined\n ,\n \"onClick:appointmentBooking\": _cache[3] || (_cache[3] = ($event: any) => (\n emit('click:appointment-booking', $event)\n ))\n }, null, 8, [\"doctor-note-detail\", \"survey-context\"])\n ]),\n _: 1\n }))\n : _createCommentVNode(\"\", true),\n (_unref(isSurveyEnabled))\n ? (_openBlock(), _createBlock(TestResultSection, { key: 6 }, {\n default: _withCtx(() => [\n _createVNode(_unref(TakeSurvey), {\n variant: \"bar\",\n \"survey-slug\": _unref(testSurveySlug),\n context: _unref(testSurveyContext),\n text: _ctx.$t('psc.test_result_take_survey_button')\n }, null, 8, [\"survey-slug\", \"context\", \"text\"])\n ]),\n _: 1\n }))\n : _createCommentVNode(\"\", true),\n (_unref(visible).upcomingAppointment)\n ? (_openBlock(), _createBlock(TestResultSection, { key: 7 }, {\n default: _withCtx(() => [\n _createVNode(UpcomingAppointment, {\n \"time-slot\": props.testResult.consult_time!\n }, null, 8, [\"time-slot\"])\n ]),\n _: 1\n }))\n : _createCommentVNode(\"\", true)\n ])\n ]),\n _createElementVNode(\"div\", _hoisted_4, [\n _createElementVNode(\"div\", _hoisted_5, [\n _renderSlot(_ctx.$slots, \"header\"),\n (!_unref(hideContent))\n ? _renderSlot(_ctx.$slots, \"default\", { key: 0 })\n : _createCommentVNode(\"\", true),\n _renderSlot(_ctx.$slots, \"footer\")\n ])\n ])\n ]))\n : (_openBlock(), _createBlock(RejectedResult, {\n key: 1,\n class: \"psc-px-4\"\n }, {\n \"body-append\": _withCtx(() => [\n _createVNode(CallUsFilledButton, { class: \"psc-mt-6\" })\n ]),\n _: 1\n }))\n ], 64))\n}\n}\n\n})"],"names":["_hoisted_1","_hoisted_2","_hoisted_3","_hoisted_4","_hoisted_5","_sfc_main","_defineComponent","__props","emit","props","TakeSurvey","defineAsyncComponent","healthSummaryItems","hideContent","isViewable","visible","useTestResult","toRef","surveyConfig","useSurveyConfig","isDisplayBook","ref","doctorNoteSurveyContext","computed","buildTestResultSurveyContext","testSurveySlug","getSurveySlug","testSurveyContext","hasDoctorNoteDetail","isSurveyEnabled","isSurveyEnabledForTestResult","slots","useSlots","showBookAppointmentBox","isTeledocSurveyVisible","isTeledocSurveyEnabled","_ctx","_cache","_openBlock","_createBlock","TestResultDetailDesktopSkeleton","_createElementBlock","_Fragment","_unref","_createElementVNode","PatientName","_createCommentVNode","_createVNode","ResultReadyV2","TestResultSection","_withCtx","HealthSummary","ResultInsightCards","$event","_createSlots","_renderSlot","BookAppointment","DoctorNote","DoctorNoteDetail","UpcomingAppointment","RejectedResult","CallUsFilledButton"],"mappings":";;;;;;;;;;;;;;;;AAGA,MAAMA,KAAa;AAAA,EACjB,KAAK;AAAA,EACL,OAAO;AACT,GACMC,KAAa,EAAE,OAAO,+DACtBC,KAAa,EAAE,OAAO,kFACtBC,KAAa,EAAE,OAAO,4BACtBC,KAAa,EAAE,OAAO,kFAqCAC,KAAiBC,gBAAAA,EAAA;AAAA,EAC3C,QAAQ;AAAA,EACR,OAAO;AAAA,IACL,YAAY;AAAA,IACZ,SAAS,EAAE,MAAM,QAAQ;AAAA,IACzB,iBAAiB,EAAE,MAAM,SAAS,SAAS,GAAM;AAAA,IACjD,aAAa,EAAE,MAAM,SAAS,SAAS,GAAM;AAAA,IA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gBAAA,GACjD,MAAM,GAAG,CAAC,eAAe,WAAW,MAAM,CAAC;AAAA,cAAA,CAC/C;AAAA,cACD,GAAG;AAAA,YAAA,CACJ,KACDU,EAAoB,IAAI,EAAI;AAAA,YAC/BH,EAAO5B,CAAO,EAAE,uBACZuB,EAAA,GAAcC,EAAaU,GAAmB,EAAE,KAAK,KAAK;AAAA,cACzD,SAASC,EAAS,MAAM;AAAA,gBACtBH,EAAaY,GAAqB;AAAA,kBAChC,aAAalD,EAAM,WAAW;AAAA,gBAC7B,GAAA,MAAM,GAAG,CAAC,WAAW,CAAC;AAAA,cAAA,CAC1B;AAAA,cACD,GAAG;AAAA,YAAA,CACJ,KACDqC,EAAoB,IAAI,EAAI;AAAA,UAAA,CACjC;AAAA,QAAA,CACF;AAAA,QACDF,EAAoB,OAAOzC,IAAY;AAAA,UACrCyC,EAAoB,OAAOxC,IAAY;AAAA,YACrCmD,EAAYnB,EAAK,QAAQ,QAAQ;AAAA,YAC/BO,EAAO9B,CAAW,IAEhBiC,EAAoB,IAAI,EAAI,IAD5BS,EAAYnB,EAAK,QAAQ,WAAW,EAAE,KAAK,EAAG,CAAA;AAAA,YAElDmB,EAAYnB,EAAK,QAAQ,QAAQ;AAAA,UAAA,CAClC;AAAA,QAAA,CACF;AAAA,MACF,CAAA,MACAE,EAAW,GAAGC,EAAaqB,GAAgB;AAAA,QAC1C,KAAK;AAAA,QACL,OAAO;AAAA,MAAA,GACN;AAAA,QACD,eAAeV,EAAS,MAAM;AAAA,UAC5BH,EAAac,GAAoB,EAAE,OAAO,YAAY;AAAA,QAAA,CACvD;AAAA,QACD,GAAG;AAAA,MAAA,CACJ;AAAA,IAAA,GACJ,EAAE;AAAA,EAEX;AAEA,CAAC;"}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";const e=require("vue"),
|
|
1
|
+
"use strict";const e=require("vue"),g=require("../../../Shared/PatientName.vue.js"),N=require("../../Shared/ResultReadyV2.vue.js"),h=require("../../Shared/RejectedResult.vue.js"),d=require("../../Shared/BookAppointment.vue.js"),x=require("../../Shared/ResultInsightCards.vue.js"),V=require("../../Shared/DoctorNote.vue.js"),q=require("../../Shared/DoctorNoteDetail.vue.js"),w=require("../../Shared/UpcomingAppointment.vue.js"),T=require("../../Shared/CallUsFilledButton.vue.js"),$=require("../../Shared/TestResultDetailSkeleton/TestResultDetailSkeleton.vue.js"),E=require("../../HealthSummary/HealthSummary.vue.js"),s=require("../../Shared/TestResultSection.vue.js"),A=require("../../../../composables/TestResult.js"),c=require("../../../../helpers/SurveyHelper.js"),D=require("../../../../composables/useSurveyConfig.js"),P=i=>Object.freeze(Object.defineProperty({__proto__:null,default:i},Symbol.toStringTag,{value:"Module"})),I={key:0,class:"consumer-test-result__ready"},j={class:"psc-px-4"},F=e.defineComponent({__name:"TestResultDetail",props:{testResult:null,loading:{type:Boolean},hidePatientInfo:{type:Boolean,default:!1},hideSummary:{type:Boolean,default:!1},timeline:{default:void 0},listActionEvent:{default:void 0},showResultReport:{type:Boolean,default:!1}},emits:["click:book-appointment","click:appointment-booking","click:result-report"],setup(i,{emit:l}){const t=i,_=e.defineAsyncComponent(()=>Promise.resolve().then(()=>P(require("../../Shared/TakeSurvey.vue2.js")))),{healthSummaryItems:m,hideContent:k,isViewable:y,visible:u}=A.useTestResult({testResult:e.toRef(t,"testResult"),hidePatientInfo:e.toRef(t,"hidePatientInfo"),hideSummary:e.toRef(t,"hideSummary")}),{surveyConfig:a}=D.useSurveyConfig(),v=e.computed(()=>c.buildTestResultSurveyContext(t.testResult,"doctor-note")),f=e.computed(()=>c.getSurveySlug(t.testResult.collection_channel,t.testResult.is_free_consultant,a.value)),B=e.computed(()=>c.buildTestResultSurveyContext(t.testResult)),b=e.computed(()=>!!t.testResult.doctor_note_detail&&t.testResult.doctor_note_detail.length>0),R=e.computed(()=>c.isSurveyEnabledForTestResult(t.testResult.nps_test_result,t.testResult.collection_channel,t.testResult.is_free_consultant,a.value)),C=e.useSlots(),p=e.computed(()=>u.value.bookAppointment||!!C["book-appointment-box"]),S=e.computed(()=>c.isTeledocSurveyEnabled(t.testResult.nps_doctor_consult,a.value));return(n,o)=>(e.openBlock(),e.createElementBlock("div",null,[t.loading?(e.openBlock(),e.createBlock($,{key:0})):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.unref(y)?(e.openBlock(),e.createElementBlock("div",I,[e.createElementVNode("div",null,[e.unref(u).patientName?(e.openBlock(),e.createBlock(g,{key:0,"first-name":t.testResult.first_name,class:"psc-px-4 psc-pb-2"},null,8,["first-name"])):e.createCommentVNode("",!0),e.createVNode(N,{"test-result":t.testResult,timeline:t.timeline,"list-action-event":t.listActionEvent,class:"psc-px-4 psc-pb-4"},null,8,["test-result","timeline","list-action-event"]),e.unref(u).healthSummary?(e.openBlock(),e.createBlock(s,{key:1},{default:e.withCtx(()=>[e.createVNode(E,{items:e.unref(m),"cta-button":t.testResult.is_free_consultant,"onClick:ctaButton":o[0]||(o[0]=r=>l("click:book-appointment"))},null,8,["items","cta-button"])]),_:1})):e.createCommentVNode("",!0),t.showResultReport?(e.openBlock(),e.createBlock(x,{key:2,"onClick:report":o[2]||(o[2]=r=>l("click:result-report"))},e.createSlots({_:2},[e.unref(p)?{name:"book-appointment-box",fn:e.withCtx(()=>[n.$slots["book-appointment-box"]?e.renderSlot(n.$slots,"book-appointment-box",{key:0,compact:!0}):(e.openBlock(),e.createBlock(d,{key:1,compact:"","onClick:book":o[1]||(o[1]=r=>l("click:book-appointment"))}))]),key:"0"}:void 0]),1024)):e.unref(p)?(e.openBlock(),e.createBlock(s,{key:3},{default:e.withCtx(()=>[n.$slots["book-appointment-box"]?e.renderSlot(n.$slots,"book-appointment-box",{key:0,compact:!1}):(e.openBlock(),e.createBlock(d,{key:1,"onClick:book":o[3]||(o[3]=r=>l("click:book-appointment"))}))]),_:3})):e.createCommentVNode("",!0),e.unref(u).doctorNote?(e.openBlock(),e.createBlock(s,{key:4},{default:e.withCtx(()=>[e.createVNode(V,{"doctor-note":t.testResult.doctor_note},null,8,["doctor-note"])]),_:1})):e.createCommentVNode("",!0),e.unref(b)?(e.openBlock(),e.createBlock(s,{key:5},{default:e.withCtx(()=>[e.createVNode(q,{"doctor-note-detail":i.testResult.doctor_note_detail,"survey-context":e.unref(S)?e.unref(v):void 0,"onClick:appointmentBooking":o[4]||(o[4]=r=>l("click:appointment-booking",r))},null,8,["doctor-note-detail","survey-context"])]),_:1})):e.createCommentVNode("",!0),e.unref(R)?(e.openBlock(),e.createBlock(s,{key:6},{default:e.withCtx(()=>[e.createVNode(e.unref(_),{variant:"bar","survey-slug":e.unref(f),context:e.unref(B),text:n.$t("psc.test_result_take_survey_button")},null,8,["survey-slug","context","text"])]),_:1})):e.createCommentVNode("",!0),e.unref(u).upcomingAppointment?(e.openBlock(),e.createBlock(s,{key:7},{default:e.withCtx(()=>[e.createVNode(w,{"time-slot":t.testResult.consult_time},null,8,["time-slot"])]),_:1})):e.createCommentVNode("",!0)]),e.createElementVNode("div",j,[e.renderSlot(n.$slots,"header"),e.unref(k)?e.createCommentVNode("",!0):e.renderSlot(n.$slots,"default",{key:0}),e.renderSlot(n.$slots,"footer")])])):(e.openBlock(),e.createBlock(h,{key:1,class:"psc-px-4"},{"body-append":e.withCtx(()=>[e.createVNode(T,{class:"psc-mt-6"})]),_:1}))],64))]))}});module.exports=F;
|
|
2
2
|
//# sourceMappingURL=TestResultDetail.vue.js.map
|