pat-shared-components 0.1.0-beta.1
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/LICENSE +21 -0
- package/README.md +52 -0
- package/dist/favicon.ico +0 -0
- package/dist/index.es.js +54827 -0
- package/dist/index.umd.js +407 -0
- package/dist/style.css +1 -0
- package/dist/types/components/BasePlayground.vue.d.ts +2 -0
- package/dist/types/components/Shared/LoadingSkeleton.vue.d.ts +2 -0
- package/dist/types/components/Shared/NoItemsFound.vue.d.ts +36 -0
- package/dist/types/components/Shared/index.d.ts +2 -0
- package/dist/types/components/TestResult/CallUsFilledButton.vue.d.ts +2 -0
- package/dist/types/components/TestResult/CheckAnotherResultButton.vue.d.ts +4 -0
- package/dist/types/components/TestResult/CtaButton.vue.d.ts +22 -0
- package/dist/types/components/TestResult/Desktop/CallUsTextButton.vue.d.ts +2 -0
- package/dist/types/components/TestResult/Desktop/ResultReady.vue.d.ts +15 -0
- package/dist/types/components/TestResult/Mobile/BookingTab/BookingDetail/BookingDetail.vue.d.ts +25 -0
- package/dist/types/components/TestResult/Mobile/BookingTab/BookingDetail/BookingNumber.vue.d.ts +2 -0
- package/dist/types/components/TestResult/Mobile/BookingTab/BookingDetail/BookingPrescription.vue.d.ts +2 -0
- package/dist/types/components/TestResult/Mobile/BookingTab/BookingDetail/BookingSupport.vue.d.ts +2 -0
- package/dist/types/components/TestResult/Mobile/BookingTab/BookingDetail/DiagLogo.vue.d.ts +28 -0
- package/dist/types/components/TestResult/Mobile/BookingTab/BookingDetail/GetToDiag.vue.d.ts +4 -0
- package/dist/types/components/TestResult/Mobile/BookingTab/BookingDetail/PatientInfo.vue.d.ts +2 -0
- package/dist/types/components/TestResult/Mobile/BookingTab/BookingList.vue.d.ts +29 -0
- package/dist/types/components/TestResult/Mobile/BookingTab/BookingListItem.vue.d.ts +23 -0
- package/dist/types/components/TestResult/Mobile/MyProfile.vue.d.ts +25 -0
- package/dist/types/components/TestResult/Mobile/ResultTab/TestResultDetail/DoctorNote.vue.d.ts +28 -0
- package/dist/types/components/TestResult/Mobile/ResultTab/TestResultDetail/ResultOverview.vue.d.ts +23 -0
- package/dist/types/components/TestResult/Mobile/ResultTab/TestResultDetail/ResultReadyV2.vue.d.ts +23 -0
- package/dist/types/components/TestResult/Mobile/ResultTab/TestResultDetail/TestResultDetail.vue.d.ts +39 -0
- package/dist/types/components/TestResult/Mobile/ResultTab/TestResultList.vue.d.ts +30 -0
- package/dist/types/components/TestResult/Mobile/ResultTab/TestResultListItem.vue.d.ts +29 -0
- package/dist/types/components/TestResult/PatientFullInfo.vue.d.ts +27 -0
- package/dist/types/components/TestResult/PatientShortInfo.vue.d.ts +27 -0
- package/dist/types/components/TestResult/PatientShortInfoV2.vue.d.ts +22 -0
- package/dist/types/components/TestResult/PendingResult.vue.d.ts +11 -0
- package/dist/types/components/TestResult/RejectedResult.vue.d.ts +11 -0
- package/dist/types/components/TestResult/TestResultHistoryDetail.vue.d.ts +23 -0
- package/dist/types/components/TestResult/TestResultHistoryDetailModal.vue.d.ts +28 -0
- package/dist/types/components/TestResult/index.d.ts +19 -0
- package/dist/types/composables/Booking.d.ts +5 -0
- package/dist/types/constants/Common.d.ts +2 -0
- package/dist/types/constants/Enums.d.ts +10 -0
- package/dist/types/helpers/ComponentHelper.d.ts +2 -0
- package/dist/types/index.d.ts +11 -0
- package/dist/types/types/Booking.d.ts +73 -0
- package/dist/types/types/Common.d.ts +5 -0
- package/dist/types/types/TestResult.d.ts +8 -0
- package/dist/types/types/TestResultHistory.d.ts +22 -0
- package/dist/types/types/index.d.ts +4 -0
- package/package.json +79 -0
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import 'pat-design-system/style.css';
|
|
2
|
+
import 'diag-shared-business-components/dist/index.css';
|
|
3
|
+
export * from './types';
|
|
4
|
+
export * from './components/Shared';
|
|
5
|
+
export * from './components/TestResult';
|
|
6
|
+
export * from './constants/Common';
|
|
7
|
+
export * from './constants/Enums';
|
|
8
|
+
import './assets/styles/main.scss';
|
|
9
|
+
import './assets/icons/style.css';
|
|
10
|
+
export { default as vi } from './locales/vi.json';
|
|
11
|
+
export { default as en } from './locales/en.json';
|
|
@@ -0,0 +1,73 @@
|
|
|
1
|
+
import type { Gender } from 'diag-shared-business-components';
|
|
2
|
+
import type { BookingStatus, PaymentStatus } from '..';
|
|
3
|
+
export interface BookingCompact {
|
|
4
|
+
booking_code: string;
|
|
5
|
+
booking_status: BookingStatus;
|
|
6
|
+
created_at: string;
|
|
7
|
+
date_of_birth: string;
|
|
8
|
+
document_number: any;
|
|
9
|
+
document_type: string;
|
|
10
|
+
email: string;
|
|
11
|
+
first_name: string;
|
|
12
|
+
gender: Gender;
|
|
13
|
+
is_pay_online: boolean;
|
|
14
|
+
key: string;
|
|
15
|
+
note: string;
|
|
16
|
+
payment_status: PaymentStatus;
|
|
17
|
+
phone_number: string;
|
|
18
|
+
total_amount: number;
|
|
19
|
+
transaction: any;
|
|
20
|
+
}
|
|
21
|
+
export interface Booking {
|
|
22
|
+
booking_code: string;
|
|
23
|
+
booking_status: BookingStatus;
|
|
24
|
+
created_at: string;
|
|
25
|
+
date_of_birth: string;
|
|
26
|
+
document_number?: number;
|
|
27
|
+
document_type: string;
|
|
28
|
+
email?: string;
|
|
29
|
+
first_name: string;
|
|
30
|
+
note?: string;
|
|
31
|
+
gender: Gender;
|
|
32
|
+
is_pay_online: boolean;
|
|
33
|
+
key: string;
|
|
34
|
+
payment_status: PaymentStatus;
|
|
35
|
+
phone_number: string;
|
|
36
|
+
transaction?: {
|
|
37
|
+
transaction_id: string;
|
|
38
|
+
transaction_time: string;
|
|
39
|
+
transaction_status: string;
|
|
40
|
+
booking_id: number;
|
|
41
|
+
order_cash: string;
|
|
42
|
+
order_status: number;
|
|
43
|
+
payment_method: number;
|
|
44
|
+
bank_name: string;
|
|
45
|
+
};
|
|
46
|
+
created_by: any;
|
|
47
|
+
company_patient: any;
|
|
48
|
+
metadata: {
|
|
49
|
+
participant: {
|
|
50
|
+
actor: any;
|
|
51
|
+
};
|
|
52
|
+
};
|
|
53
|
+
account: any;
|
|
54
|
+
services: Array<BookingService>;
|
|
55
|
+
total_amount: number;
|
|
56
|
+
}
|
|
57
|
+
export interface BookingService {
|
|
58
|
+
service: {
|
|
59
|
+
test_code: string;
|
|
60
|
+
group: string;
|
|
61
|
+
test_name_en: string;
|
|
62
|
+
test_name_vi: string;
|
|
63
|
+
simple_name_en: string | null;
|
|
64
|
+
simple_name_vi: string | null;
|
|
65
|
+
walkin_price: number;
|
|
66
|
+
simple_cate_en: string;
|
|
67
|
+
simple_cate_vi: string;
|
|
68
|
+
is_group: boolean;
|
|
69
|
+
is_service: boolean;
|
|
70
|
+
is_package: boolean;
|
|
71
|
+
is_imaging: boolean;
|
|
72
|
+
};
|
|
73
|
+
}
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import type { TestResultConclusion } from 'diag-shared-business-components';
|
|
2
|
+
export interface TestResultHistoryCompact {
|
|
3
|
+
test_code: string;
|
|
4
|
+
min_test_value: number;
|
|
5
|
+
max_test_value: number;
|
|
6
|
+
uom_code: string;
|
|
7
|
+
test_name: string;
|
|
8
|
+
latest_test_value: number;
|
|
9
|
+
}
|
|
10
|
+
export interface TestResultHistory {
|
|
11
|
+
test_code: string;
|
|
12
|
+
test_name: string;
|
|
13
|
+
uom_code: string;
|
|
14
|
+
purpose: string;
|
|
15
|
+
charts: HistoryChartDataItem[] | Record<number, HistoryChartDataItem>;
|
|
16
|
+
}
|
|
17
|
+
export interface HistoryChartDataItem {
|
|
18
|
+
value: number;
|
|
19
|
+
order_date: string;
|
|
20
|
+
is_abnormal: TestResultConclusion;
|
|
21
|
+
reference_range: string;
|
|
22
|
+
}
|
package/package.json
ADDED
|
@@ -0,0 +1,79 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "pat-shared-components",
|
|
3
|
+
"version": "0.1.0-beta.1",
|
|
4
|
+
"files": [
|
|
5
|
+
"dist/**/*"
|
|
6
|
+
],
|
|
7
|
+
"types": "./dist/types/index.d.ts",
|
|
8
|
+
"main": "./dist/index.umd.js",
|
|
9
|
+
"module": "./dist/index.es.js",
|
|
10
|
+
"exports": {
|
|
11
|
+
".": {
|
|
12
|
+
"import": "./dist/index.es.js",
|
|
13
|
+
"require": "./dist/index.umd.js"
|
|
14
|
+
},
|
|
15
|
+
"./style.css": {
|
|
16
|
+
"import": "./dist/style.css",
|
|
17
|
+
"require": "./dist/style.css"
|
|
18
|
+
}
|
|
19
|
+
},
|
|
20
|
+
"scripts": {
|
|
21
|
+
"dev": "vite",
|
|
22
|
+
"dev:host": "npm run dev -- --host",
|
|
23
|
+
"preview": "vite preview",
|
|
24
|
+
"build:stag": "run-p type-check build-only:stag",
|
|
25
|
+
"build:prod": "run-p type-check build-only:prod",
|
|
26
|
+
"build-only:stag": "vite build --mode staging",
|
|
27
|
+
"build-only:prod": "vite build --mode production",
|
|
28
|
+
"publish-package": "npm run build && npm publish",
|
|
29
|
+
"build": "vite build && npm run build:types",
|
|
30
|
+
"build:types": "vue-tsc --project tsconfig.build-types.json --declaration --emitDeclarationOnly --outDir dist/types ",
|
|
31
|
+
"typecheck": "vue-tsc --noEmit -p tsconfig.vitest.json --composite false",
|
|
32
|
+
"test:unit": "vitest --environment jsdom --root src/",
|
|
33
|
+
"lint": "eslint . --ext .vue,.js,.jsx,.cjs,.mjs,.ts,.tsx,.cts,.mts --fix --ignore-path .gitignore",
|
|
34
|
+
"format": "prettier . --write"
|
|
35
|
+
},
|
|
36
|
+
"dependencies": {
|
|
37
|
+
"@babel/core": "^7.20.5",
|
|
38
|
+
"air-datepicker": "^3.3.3",
|
|
39
|
+
"chart.js": "^4.1.2",
|
|
40
|
+
"diag-shared-business-components": "^0.6.0-beta.5",
|
|
41
|
+
"imask": "^6.4.3",
|
|
42
|
+
"lodash": "^4.17.21",
|
|
43
|
+
"moment-mini": "^2.29.4",
|
|
44
|
+
"pat-design-system": "^0.2.0-beta.9",
|
|
45
|
+
"postcss-preset-env": "^7.8.3",
|
|
46
|
+
"uuid": "^8.3.2",
|
|
47
|
+
"vue": "^3.2.37",
|
|
48
|
+
"vue-i18n": "^9.2.2"
|
|
49
|
+
},
|
|
50
|
+
"devDependencies": {
|
|
51
|
+
"@intlify/eslint-plugin-vue-i18n": "^2.0.0",
|
|
52
|
+
"@rushstack/eslint-patch": "^1.1.4",
|
|
53
|
+
"@tailwindcss/line-clamp": "^0.4.2",
|
|
54
|
+
"@types/jsdom": "^20.0.0",
|
|
55
|
+
"@types/lodash": "^4.14.188",
|
|
56
|
+
"@types/uuid": "^8.3.4",
|
|
57
|
+
"@typescript-eslint/eslint-plugin": "^5.42.0",
|
|
58
|
+
"@typescript-eslint/parser": "^5.42.0",
|
|
59
|
+
"@vitejs/plugin-vue": "^3.1.2",
|
|
60
|
+
"@vue/eslint-config-prettier": "^7.0.0",
|
|
61
|
+
"@vue/eslint-config-typescript": "^11.0.0",
|
|
62
|
+
"@vue/test-utils": "^2.1.0",
|
|
63
|
+
"@vue/tsconfig": "^0.1.3",
|
|
64
|
+
"autoprefixer": "^10.4.13",
|
|
65
|
+
"eslint": "^8.22.0",
|
|
66
|
+
"eslint-plugin-vue": "^9.3.0",
|
|
67
|
+
"jsdom": "^20.0.1",
|
|
68
|
+
"npm-run-all": "^4.1.5",
|
|
69
|
+
"postcss": "^8.4.19",
|
|
70
|
+
"prettier": "^2.7.1",
|
|
71
|
+
"sass": "^1.56.0",
|
|
72
|
+
"tailwindcss": "^3.2.2",
|
|
73
|
+
"typescript": "~4.7.4",
|
|
74
|
+
"vite": "^3.1.8",
|
|
75
|
+
"vitest": "^0.24.3",
|
|
76
|
+
"vue-eslint-parser": "^9.1.0",
|
|
77
|
+
"vue-tsc": "^1.0.11"
|
|
78
|
+
}
|
|
79
|
+
}
|