@tellescope/react-components 1.230.0 → 1.230.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.
Files changed (43) hide show
  1. package/lib/cjs/Forms/forms.v2.d.ts.map +1 -1
  2. package/lib/cjs/Forms/forms.v2.js +3 -1
  3. package/lib/cjs/Forms/forms.v2.js.map +1 -1
  4. package/lib/cjs/Forms/index.d.ts +1 -0
  5. package/lib/cjs/Forms/index.d.ts.map +1 -1
  6. package/lib/cjs/Forms/index.js +3 -1
  7. package/lib/cjs/Forms/index.js.map +1 -1
  8. package/lib/cjs/Forms/inputs.js +2 -2
  9. package/lib/cjs/Forms/inputs.js.map +1 -1
  10. package/lib/cjs/Forms/inputs.v2.d.ts.map +1 -1
  11. package/lib/cjs/Forms/inputs.v2.js +5 -3
  12. package/lib/cjs/Forms/inputs.v2.js.map +1 -1
  13. package/lib/esm/CMS/components.d.ts +1 -0
  14. package/lib/esm/CMS/components.d.ts.map +1 -1
  15. package/lib/esm/Forms/form_responses.d.ts +1 -0
  16. package/lib/esm/Forms/form_responses.d.ts.map +1 -1
  17. package/lib/esm/Forms/forms.d.ts +3 -3
  18. package/lib/esm/Forms/forms.v2.d.ts +3 -3
  19. package/lib/esm/Forms/forms.v2.d.ts.map +1 -1
  20. package/lib/esm/Forms/forms.v2.js +3 -1
  21. package/lib/esm/Forms/forms.v2.js.map +1 -1
  22. package/lib/esm/Forms/hooks.d.ts +1 -0
  23. package/lib/esm/Forms/hooks.d.ts.map +1 -1
  24. package/lib/esm/Forms/index.d.ts +1 -0
  25. package/lib/esm/Forms/index.d.ts.map +1 -1
  26. package/lib/esm/Forms/index.js +1 -0
  27. package/lib/esm/Forms/index.js.map +1 -1
  28. package/lib/esm/Forms/inputs.js +3 -3
  29. package/lib/esm/Forms/inputs.js.map +1 -1
  30. package/lib/esm/Forms/inputs.v2.d.ts.map +1 -1
  31. package/lib/esm/Forms/inputs.v2.js +6 -4
  32. package/lib/esm/Forms/inputs.v2.js.map +1 -1
  33. package/lib/esm/controls.d.ts +2 -2
  34. package/lib/esm/inputs.d.ts +1 -1
  35. package/lib/esm/inputs.native.d.ts +1 -0
  36. package/lib/esm/inputs.native.d.ts.map +1 -1
  37. package/lib/esm/state.d.ts +40 -40
  38. package/lib/tsconfig.tsbuildinfo +1 -1
  39. package/package.json +9 -9
  40. package/src/Forms/forms.v2.tsx +18 -2
  41. package/src/Forms/index.ts +2 -1
  42. package/src/Forms/inputs.tsx +2 -2
  43. package/src/Forms/inputs.v2.tsx +5 -3
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@tellescope/react-components",
3
- "version": "1.230.0",
3
+ "version": "1.230.1",
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.230.0",
51
- "@tellescope/sdk": "1.230.0",
52
- "@tellescope/types-client": "1.230.0",
53
- "@tellescope/types-models": "1.230.0",
54
- "@tellescope/types-utilities": "1.230.0",
55
- "@tellescope/utilities": "1.230.0",
56
- "@tellescope/validation": "1.230.0",
50
+ "@tellescope/constants": "1.230.1",
51
+ "@tellescope/sdk": "1.230.1",
52
+ "@tellescope/types-client": "1.230.1",
53
+ "@tellescope/types-models": "1.230.1",
54
+ "@tellescope/types-utilities": "1.230.1",
55
+ "@tellescope/utilities": "1.230.1",
56
+ "@tellescope/validation": "1.230.1",
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",
@@ -83,7 +83,7 @@
83
83
  "react-dom": "^16.8.0 || ^17.0.0 || ^18.0.0 || ^19.0.0",
84
84
  "react-native": "^0.65.0 || ^0.66.0 || ^0.67.0 || ^0.68.0 || ^0.71.0"
85
85
  },
86
- "gitHead": "1b1aa59aee4b8ee1610bc292143e2a2cd08f6ed3",
86
+ "gitHead": "0dca02b5fe32a3244d8e0a5a31ed1dd6652341c8",
87
87
  "publishConfig": {
88
88
  "access": "public"
89
89
  }
@@ -44,8 +44,24 @@ const TellescopeFormContainerWithThemeV2: typeof TellescopeFormContainerV2 = ({
44
44
  const finalBgColor = shouldUseCustomBg ? backgroundColor : '#F4F3FA'
45
45
 
46
46
  return (
47
- <Flex flex={1} column alignItems="center" style={{ backgroundColor: finalBgColor, overflow: 'hidden', paddingTop: 40, paddingBottom: 40, ...style }}>
48
- <Flex flex={1} column style={{ padding: '0 20px', maxWidth: maxWidth ?? 650, minWidth: 250, width: '100%', height: '100%' }}>
47
+ <Flex flex={1} column alignItems="center" style={{
48
+ backgroundColor: finalBgColor,
49
+ overflow: 'auto',
50
+ paddingTop: window.innerWidth < 600 ? 20 : 40,
51
+ paddingBottom: window.innerWidth < 600 ? 20 : 40,
52
+ ...style
53
+ }}>
54
+ <Flex flex={1} column style={{
55
+ padding: window.innerWidth < 600 ? '0 12px' : '0 20px',
56
+ maxWidth: maxWidth ?? 650,
57
+ minWidth: 250,
58
+ width: '100%',
59
+ height: '100%',
60
+ boxSizing: 'border-box',
61
+ ...(window.innerWidth < 600 ? {
62
+ paddingBottom: '80px' // Extra bottom padding on mobile to keep button above Safari navigation
63
+ } : {})
64
+ }}>
49
65
  {language && onChangeLanguage &&
50
66
  <Flex style={{ marginTop: 22 }}>
51
67
  <LanguageSelect value={language} onChange={onChangeLanguage} />
@@ -6,4 +6,5 @@ export * from "./types";
6
6
  export * from "./localization";
7
7
 
8
8
  // V2 Forms exports
9
- export { TellescopeFormV2, TellescopeFormContainerV2, TellescopeSingleQuestionFlowV2 } from "./forms.v2";
9
+ export { TellescopeFormV2, TellescopeFormContainerV2, TellescopeSingleQuestionFlowV2 } from "./forms.v2";
10
+ export { defaultInputProps as inputPropsV2 } from "./inputs.v2";
@@ -4,7 +4,7 @@ import { Autocomplete, Box, Button, Checkbox, Chip, Collapse, Divider, FormContr
4
4
  import { FormInputProps } from "./types"
5
5
  import { useDropzone } from "react-dropzone"
6
6
  import { CANVAS_TITLE, EMOTII_TITLE, INSURANCE_RELATIONSHIPS, INSURANCE_RELATIONSHIPS_CANVAS, PRIMARY_HEX, RELATIONSHIP_TYPES, TELLESCOPE_GENDERS } from "@tellescope/constants"
7
- import { MM_DD_YYYY_to_YYYY_MM_DD, capture_is_supported, downloadFile, emit_gtm_event, first_letter_capitalized, form_response_value_to_string, getLocalTimezone, getPublicFileURL, mm_dd_yyyy, replace_enduser_template_values, truncate_string, update_local_storage, user_display_name } from "@tellescope/utilities"
7
+ import { MM_DD_YYYY_to_YYYY_MM_DD, capture_is_supported, downloadFile, emit_gtm_event, first_letter_capitalized, form_response_value_to_string, format_stripe_subscription_interval, getLocalTimezone, getPublicFileURL, mm_dd_yyyy, replace_enduser_template_values, truncate_string, update_local_storage, user_display_name } from "@tellescope/utilities"
8
8
  import { Address, DatabaseSelectResponse, Enduser, EnduserRelationship, FormResponseValue, InsuranceRelationship, MedicationResponse, MultipleChoiceOptions, FormFieldOptionDetails, TellescopeGender, TIMEZONES_USA } from "@tellescope/types-models"
9
9
  import { VALID_STATES, emailValidator, phoneValidator } from "@tellescope/validation"
10
10
  import Slider from '@mui/material/Slider';
@@ -1898,7 +1898,7 @@ export const StripeInput = ({ field, value, onChange, setCustomerId, enduserId }
1898
1898
  ${(priceAmount / 100).toFixed(2)} {priceCurrency.toUpperCase()}
1899
1899
  {product.currentPrice?.isSubscription && (
1900
1900
  <Typography component="span" variant="caption" sx={{ ml: 0.5 }}>
1901
- /month
1901
+ {format_stripe_subscription_interval(product.currentPrice?.interval, product.currentPrice?.interval_count)}
1902
1902
  </Typography>
1903
1903
  )}
1904
1904
  </Typography>
@@ -4,7 +4,7 @@ import { Autocomplete, Box, Button, Checkbox, Chip, Collapse, Divider, FormContr
4
4
  import { FormInputProps } from "./types"
5
5
  import { useDropzone } from "react-dropzone"
6
6
  import { CANVAS_TITLE, EMOTII_TITLE, INSURANCE_RELATIONSHIPS, INSURANCE_RELATIONSHIPS_CANVAS, PRIMARY_HEX, RELATIONSHIP_TYPES, TELLESCOPE_GENDERS } from "@tellescope/constants"
7
- import { MM_DD_YYYY_to_YYYY_MM_DD, capture_is_supported, downloadFile, emit_gtm_event, first_letter_capitalized, form_response_value_to_string, getLocalTimezone, getPublicFileURL, mm_dd_yyyy, replace_enduser_template_values, truncate_string, update_local_storage, user_display_name } from "@tellescope/utilities"
7
+ import { MM_DD_YYYY_to_YYYY_MM_DD, capture_is_supported, downloadFile, emit_gtm_event, first_letter_capitalized, form_response_value_to_string, format_stripe_subscription_interval, getLocalTimezone, getPublicFileURL, mm_dd_yyyy, replace_enduser_template_values, truncate_string, update_local_storage, user_display_name } from "@tellescope/utilities"
8
8
  import { Address, DatabaseSelectResponse, Enduser, EnduserRelationship, FormResponseValue, InsuranceRelationship, MedicationResponse, MultipleChoiceOptions, FormFieldOptionDetails, TellescopeGender, TIMEZONES_USA } from "@tellescope/types-models"
9
9
  import { VALID_STATES, emailValidator, phoneValidator } from "@tellescope/validation"
10
10
  import Slider from '@mui/material/Slider';
@@ -1561,6 +1561,7 @@ export const MultipleChoiceInput = ({ field, form, value: _value, onChange }: Fo
1561
1561
  marginBottom: '12px',
1562
1562
  cursor: 'pointer',
1563
1563
  backgroundColor: 'transparent',
1564
+ boxSizing: 'border-box',
1564
1565
  '&:hover': {
1565
1566
  backgroundColor: (theme: any) => `${theme.palette.primary.main}14`,
1566
1567
  },
@@ -1614,7 +1615,8 @@ export const MultipleChoiceInput = ({ field, form, value: _value, onChange }: Fo
1614
1615
  display: 'flex',
1615
1616
  alignItems: 'center',
1616
1617
  cursor: 'pointer',
1617
- width: '100%'
1618
+ width: '100%',
1619
+ boxSizing: 'border-box'
1618
1620
  }}
1619
1621
  onClick={(e) => {
1620
1622
  // Don't trigger selection if clicking on the expand button
@@ -1911,7 +1913,7 @@ export const StripeInput = ({ field, value, onChange, setCustomerId, enduserId }
1911
1913
  ${(priceAmount / 100).toFixed(2)} {priceCurrency.toUpperCase()}
1912
1914
  {product.currentPrice?.isSubscription && (
1913
1915
  <Typography component="span" variant="caption" sx={{ ml: 0.5 }}>
1914
- /month
1916
+ {format_stripe_subscription_interval(product.currentPrice?.interval, product.currentPrice?.interval_count)}
1915
1917
  </Typography>
1916
1918
  )}
1917
1919
  </Typography>