@tellescope/react-components 1.163.0 → 1.165.0
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/lib/cjs/Forms/inputs.d.ts +1 -0
- package/lib/cjs/Forms/inputs.d.ts.map +1 -1
- package/lib/cjs/Forms/inputs.js +19 -4
- package/lib/cjs/Forms/inputs.js.map +1 -1
- package/lib/cjs/inputs.js +1 -1
- package/lib/cjs/inputs.js.map +1 -1
- package/lib/cjs/inputs_shared.d.ts +4 -1
- package/lib/cjs/inputs_shared.d.ts.map +1 -1
- package/lib/cjs/inputs_shared.js +7 -1
- package/lib/cjs/inputs_shared.js.map +1 -1
- package/lib/cjs/state.d.ts +116 -0
- package/lib/cjs/state.d.ts.map +1 -1
- package/lib/cjs/state.js +19 -3
- package/lib/cjs/state.js.map +1 -1
- package/lib/esm/Forms/inputs.d.ts +1 -0
- package/lib/esm/Forms/inputs.d.ts.map +1 -1
- package/lib/esm/Forms/inputs.js +17 -3
- package/lib/esm/Forms/inputs.js.map +1 -1
- package/lib/esm/inputs.js +1 -1
- package/lib/esm/inputs.js.map +1 -1
- package/lib/esm/inputs_shared.d.ts +4 -1
- package/lib/esm/inputs_shared.d.ts.map +1 -1
- package/lib/esm/inputs_shared.js +6 -1
- package/lib/esm/inputs_shared.js.map +1 -1
- package/lib/esm/state.d.ts +116 -0
- package/lib/esm/state.d.ts.map +1 -1
- package/lib/esm/state.js +15 -0
- package/lib/esm/state.js.map +1 -1
- package/lib/tsconfig.tsbuildinfo +1 -1
- package/package.json +9 -9
- package/src/Forms/inputs.tsx +39 -1
- package/src/inputs.tsx +1 -1
- package/src/inputs_shared.tsx +13 -2
- package/src/state.tsx +22 -0
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@tellescope/react-components",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.165.0",
|
|
4
4
|
"description": "",
|
|
5
5
|
"main": "./lib/cjs/index.js",
|
|
6
6
|
"module": "./lib/esm/index.js",
|
|
@@ -47,13 +47,13 @@
|
|
|
47
47
|
"@reduxjs/toolkit": "^1.6.2",
|
|
48
48
|
"@stripe/react-stripe-js": "^2.9.0",
|
|
49
49
|
"@stripe/stripe-js": "^1.52.1",
|
|
50
|
-
"@tellescope/constants": "^1.
|
|
51
|
-
"@tellescope/sdk": "^1.
|
|
52
|
-
"@tellescope/types-client": "^1.
|
|
53
|
-
"@tellescope/types-models": "^1.
|
|
54
|
-
"@tellescope/types-utilities": "^1.
|
|
55
|
-
"@tellescope/utilities": "^1.
|
|
56
|
-
"@tellescope/validation": "^1.
|
|
50
|
+
"@tellescope/constants": "^1.165.0",
|
|
51
|
+
"@tellescope/sdk": "^1.165.0",
|
|
52
|
+
"@tellescope/types-client": "^1.165.0",
|
|
53
|
+
"@tellescope/types-models": "^1.165.0",
|
|
54
|
+
"@tellescope/types-utilities": "^1.165.0",
|
|
55
|
+
"@tellescope/utilities": "^1.165.0",
|
|
56
|
+
"@tellescope/validation": "^1.165.0",
|
|
57
57
|
"@typescript-eslint/eslint-plugin": "^4.33.0",
|
|
58
58
|
"@typescript-eslint/parser": "^4.33.0",
|
|
59
59
|
"css-to-react-native": "^3.0.0",
|
|
@@ -80,7 +80,7 @@
|
|
|
80
80
|
"react-dom": "^16.8.0 || ^17.0.0 || ^18.0.0",
|
|
81
81
|
"react-native": "^0.65.0 || ^0.66.0 || ^0.67.0 || ^0.68.0 || ^0.71.0"
|
|
82
82
|
},
|
|
83
|
-
"gitHead": "
|
|
83
|
+
"gitHead": "7950d3c787ac268cde52ecb71e4cc882fd9d2b54",
|
|
84
84
|
"publishConfig": {
|
|
85
85
|
"access": "public"
|
|
86
86
|
}
|
package/src/Forms/inputs.tsx
CHANGED
|
@@ -1045,6 +1045,44 @@ export const AddressInput = ({ field, form, value, onChange, ...props }: FormInp
|
|
|
1045
1045
|
)
|
|
1046
1046
|
)
|
|
1047
1047
|
|
|
1048
|
+
export const ESignatureTerms = () => {
|
|
1049
|
+
let companyName = 'Tellescope'
|
|
1050
|
+
try {
|
|
1051
|
+
const indexOfName = window.location.href.indexOf('name=')
|
|
1052
|
+
if (indexOfName !== -1) {
|
|
1053
|
+
companyName = (
|
|
1054
|
+
decodeURIComponent(window.location.href.substring(indexOfName + 5))
|
|
1055
|
+
|| companyName
|
|
1056
|
+
)
|
|
1057
|
+
}
|
|
1058
|
+
} catch(err) {
|
|
1059
|
+
console.error(err)
|
|
1060
|
+
}
|
|
1061
|
+
|
|
1062
|
+
return (
|
|
1063
|
+
<div style={{paddingLeft: 10}}>
|
|
1064
|
+
<h1>{companyName} Electronic Signature Terms</h1>
|
|
1065
|
+
|
|
1066
|
+
<p>
|
|
1067
|
+
By selecting the "I consent to use electronic signatures" checkbox,
|
|
1068
|
+
you are signing this Agreement electronically.
|
|
1069
|
+
You agree your electronic signature is the legal
|
|
1070
|
+
equivalent of your manual/handwritten signature on this Agreement.
|
|
1071
|
+
By selecting "I consent to use electronic signatures" using any device, means or action, you consent to the
|
|
1072
|
+
legally binding terms and conditions of this Agreement.
|
|
1073
|
+
You further agree that your signature on this document (hereafter referred to as your "E-Signature")
|
|
1074
|
+
is as valid as if you signed the document in writing.
|
|
1075
|
+
You also agree that no certification authority or other third party
|
|
1076
|
+
verification is necessary to validate your E-Signature,
|
|
1077
|
+
and that the lack of such certification or third party verification will
|
|
1078
|
+
not in any way affect the enforceability
|
|
1079
|
+
of your E-Signature or any resulting agreement between you and
|
|
1080
|
+
{companyName} or between you and a customer of {companyName}.
|
|
1081
|
+
</p>
|
|
1082
|
+
</div>
|
|
1083
|
+
)
|
|
1084
|
+
}
|
|
1085
|
+
|
|
1048
1086
|
export const SignatureInput = ({ value, field, autoFocus=true, enduser, onChange }: FormInputProps<'signature'>) => {
|
|
1049
1087
|
const prefill = (
|
|
1050
1088
|
field.options?.prefillSignature && enduser?.fname && enduser.lname
|
|
@@ -1103,7 +1141,7 @@ export const SignatureInput = ({ value, field, autoFocus=true, enduser, onChange
|
|
|
1103
1141
|
/>
|
|
1104
1142
|
<Typography component="span" style={{ position: 'relative', top: 5, left: 2 }}>
|
|
1105
1143
|
I consent to
|
|
1106
|
-
use <a href=
|
|
1144
|
+
use <a href={`/e-signature-terms?name=${field.options?.esignatureTermsCompanyName || ''}`} target="_blank" rel="noopener noreferrer"> electronic signatures </a>
|
|
1107
1145
|
</Typography>
|
|
1108
1146
|
</Grid>
|
|
1109
1147
|
|
package/src/inputs.tsx
CHANGED
package/src/inputs_shared.tsx
CHANGED
|
@@ -5,8 +5,8 @@ import { LoadFunction, LoadFunctionArguments } from "@tellescope/sdk"
|
|
|
5
5
|
import { ALL_ACCESS, UNSEARCHABLE_FIELDS } from "@tellescope/constants"
|
|
6
6
|
import { SearchAPIProps, useSearchAPI } from "./hooks"
|
|
7
7
|
import { TextFieldProps } from "./mui"
|
|
8
|
-
import { AllergyCode, AppointmentBookingPage, AppointmentLocation, AutomationTrigger, CalendarEventTemplate, CallHoldQueue, ChatRoom, Database, DatabaseRecord, DiagnosisCode, Enduser, EnduserOrder, FaxLog, File, Form, FormGroup, Forum, Journey, ManagedContentRecord, MessageTemplateSnippet, Organization, PrescriptionRoute, SuggestedContact, Template, Ticket, TicketQueue, User, UserNotification } from "@tellescope/types-client"
|
|
9
|
-
import { Button, Checkbox, Flex, HoverPaper, LoadingButton, LoadingData, LoadingLinear, ScrollingList, SearchTextInput, Typography, useAllergyCodes, useAppointmentBookingPages, useAppointmentLocations, useAutomationTriggers, useCalendarEventTemplates, useCallHoldQueues, useChatRooms, useDatabaseRecords, useDatabases, useDiagnosisCodes, useEnduserOrders, useEndusers, useFaxLogs, useFiles, useFormGroups, useForms, useForums, useJourneys, useManagedContentRecords, useMessageTemplateSnippets, useNotifications, useOrganization, useOrganizations, usePrescriptionRoutes, useResolvedSession, useSession, useSuggestedContacts, useTemplates, useTicketQueues, useTickets, useUsers, value_is_loaded } from "."
|
|
8
|
+
import { AgentRecord, AllergyCode, AppointmentBookingPage, AppointmentLocation, AutomationTrigger, CalendarEventTemplate, CallHoldQueue, ChatRoom, Database, DatabaseRecord, DiagnosisCode, Enduser, EnduserOrder, FaxLog, File, Form, FormGroup, Forum, Journey, ManagedContentRecord, MessageTemplateSnippet, Organization, PrescriptionRoute, SuggestedContact, Template, Ticket, TicketQueue, User, UserNotification } from "@tellescope/types-client"
|
|
9
|
+
import { Button, Checkbox, Flex, HoverPaper, LoadingButton, LoadingData, LoadingLinear, ScrollingList, SearchTextInput, Typography, useAgentRecords, useAllergyCodes, useAppointmentBookingPages, useAppointmentLocations, useAutomationTriggers, useCalendarEventTemplates, useCallHoldQueues, useChatRooms, useDatabaseRecords, useDatabases, useDiagnosisCodes, useEnduserOrders, useEndusers, useFaxLogs, useFiles, useFormGroups, useForms, useForums, useJourneys, useManagedContentRecords, useMessageTemplateSnippets, useNotifications, useOrganization, useOrganizations, usePrescriptionRoutes, useResolvedSession, useSession, useSuggestedContacts, useTemplates, useTicketQueues, useTickets, useUsers, value_is_loaded } from "."
|
|
10
10
|
import { SxProps } from "@mui/material"
|
|
11
11
|
import { AccessPermissions } from "@tellescope/types-models"
|
|
12
12
|
|
|
@@ -618,6 +618,17 @@ export const SuggestedContactSearch = (props: Omit<GenericSearchProps<SuggestedC
|
|
|
618
618
|
)
|
|
619
619
|
}
|
|
620
620
|
|
|
621
|
+
export const AgentRecordSearch = (props: Omit<GenericSearchProps<AgentRecord>, 'filterKey'> & { filterKey?: string }) => {
|
|
622
|
+
const session = useSession()
|
|
623
|
+
const [, { addLocalElements }] = useAgentRecords({ dontFetch: true })
|
|
624
|
+
return (
|
|
625
|
+
<ModelSearchInput filterKey="agent-record" {...props}
|
|
626
|
+
searchAPI={session.api.agent_records.getSome}
|
|
627
|
+
onLoad={addLocalElements}
|
|
628
|
+
/>
|
|
629
|
+
)
|
|
630
|
+
}
|
|
631
|
+
|
|
621
632
|
export const AllergyCodeSearch = (props: Omit<GenericSearchProps<AllergyCode>, 'filterKey'> & { filterKey?: string }) => {
|
|
622
633
|
const session = useSession()
|
|
623
634
|
const [, { addLocalElements }] = useAllergyCodes({ dontFetch: true })
|
package/src/state.tsx
CHANGED
|
@@ -97,6 +97,7 @@ import {
|
|
|
97
97
|
AllergyCode,
|
|
98
98
|
IntegrationLog,
|
|
99
99
|
EnduserEligibilityResult,
|
|
100
|
+
AgentRecord,
|
|
100
101
|
} from "@tellescope/types-client"
|
|
101
102
|
|
|
102
103
|
import {
|
|
@@ -361,6 +362,7 @@ const diagnosisCodesSlice = createSliceForList<DiagnosisCode, 'diagnosis_codes'>
|
|
|
361
362
|
const allergyCodesSlice = createSliceForList<AllergyCode, 'allergy_codes'>('allergy_codes')
|
|
362
363
|
const integrationLogsSlice = createSliceForList<IntegrationLog, 'integration_logs'>('integration_logs')
|
|
363
364
|
const enduserEligibilityResultsSlice = createSliceForList<EnduserEligibilityResult, 'enduser_eligibility_results'>('enduser_eligibility_results')
|
|
365
|
+
const agentRecordsSlice = createSliceForList<AgentRecord, 'agent_records'>('agent_records')
|
|
364
366
|
|
|
365
367
|
const roleBasedAccessPermissionsSlice = createSliceForList<RoleBasedAccessPermission, 'role_based_access_permissions'>('role_based_access_permissions')
|
|
366
368
|
|
|
@@ -369,6 +371,7 @@ const userLogsSlice = createSliceForList<UserLog, 'user_logs'>('user_logs')
|
|
|
369
371
|
|
|
370
372
|
export const sharedConfig = {
|
|
371
373
|
reducer: {
|
|
374
|
+
agent_records: agentRecordsSlice.reducer,
|
|
372
375
|
enduser_eligibility_results: enduserEligibilityResultsSlice.reducer,
|
|
373
376
|
integration_logs: integrationLogsSlice.reducer,
|
|
374
377
|
ticket_queues: ticketQueuesSlice.reducer,
|
|
@@ -1214,6 +1217,25 @@ export const useEnduserEligibilityResults = (options={} as HookOptions<EnduserEl
|
|
|
1214
1217
|
)
|
|
1215
1218
|
}
|
|
1216
1219
|
|
|
1220
|
+
export const useAgentRecords = (options={} as HookOptions<AgentRecord>) => {
|
|
1221
|
+
const session = useSession()
|
|
1222
|
+
|
|
1223
|
+
return useListStateHook('agent_records', useTypedSelector(s => s.agent_records), session, agentRecordsSlice,
|
|
1224
|
+
{
|
|
1225
|
+
loadQuery: session.api.agent_records.getSome,
|
|
1226
|
+
findOne: session.api.agent_records.getOne,
|
|
1227
|
+
findByIds: session.api.agent_records.getByIds,
|
|
1228
|
+
addOne: session.api.agent_records.createOne,
|
|
1229
|
+
addSome: session.api.agent_records.createSome,
|
|
1230
|
+
deleteOne: session.api.agent_records.deleteOne,
|
|
1231
|
+
updateOne: session.api.agent_records.updateOne,
|
|
1232
|
+
},
|
|
1233
|
+
{
|
|
1234
|
+
...options,
|
|
1235
|
+
},
|
|
1236
|
+
)
|
|
1237
|
+
}
|
|
1238
|
+
|
|
1217
1239
|
export const useSuggestedContacts = (options={} as HookOptions<SuggestedContact>) => {
|
|
1218
1240
|
const session = useSession()
|
|
1219
1241
|
|