@prosopo/procaptcha-react 0.2.41 → 0.3.2

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 (72) hide show
  1. package/README.md +3 -9
  2. package/dist/cjs/components/Button.cjs +2 -1
  3. package/dist/cjs/components/CaptchaComponent.cjs +2 -1
  4. package/dist/cjs/components/CaptchaWidget.cjs +2 -1
  5. package/dist/cjs/components/ExtensionAccountSelect.cjs +1 -2
  6. package/dist/cjs/components/Modal.cjs +0 -1
  7. package/dist/cjs/components/Procaptcha.cjs +2 -1
  8. package/dist/cjs/components/ProcaptchaWidget.cjs +82 -143
  9. package/dist/cjs/components/collector.cjs +4 -3
  10. package/dist/cjs/index.cjs +2 -2
  11. package/dist/cjs/web-components/dist/CaptchaPlaceholder.cjs +39 -0
  12. package/dist/cjs/web-components/dist/Checkbox.cjs +55 -0
  13. package/dist/cjs/web-components/dist/Containers.cjs +42 -0
  14. package/dist/cjs/{components → web-components/dist}/LoadingSpinner.cjs +5 -1
  15. package/dist/cjs/web-components/dist/Logo.cjs +16 -0
  16. package/dist/cjs/web-components/dist/LogoWithText.cjs +10 -0
  17. package/dist/cjs/web-components/dist/LogoWithoutText.cjs +10 -0
  18. package/dist/cjs/web-components/dist/WidgetConstants.cjs +12 -0
  19. package/dist/cjs/web-components/dist/index.cjs +22 -0
  20. package/dist/components/Button.d.ts.map +1 -1
  21. package/dist/components/Button.js +1 -1
  22. package/dist/components/Button.js.map +1 -1
  23. package/dist/components/CaptchaComponent.js +1 -1
  24. package/dist/components/CaptchaComponent.js.map +1 -1
  25. package/dist/components/CaptchaWidget.d.ts +1 -1
  26. package/dist/components/CaptchaWidget.d.ts.map +1 -1
  27. package/dist/components/CaptchaWidget.js +1 -1
  28. package/dist/components/CaptchaWidget.js.map +1 -1
  29. package/dist/components/ExtensionAccountSelect.d.ts +0 -1
  30. package/dist/components/ExtensionAccountSelect.d.ts.map +1 -1
  31. package/dist/components/ExtensionAccountSelect.js +0 -1
  32. package/dist/components/ExtensionAccountSelect.js.map +1 -1
  33. package/dist/components/Modal.d.ts.map +1 -1
  34. package/dist/components/Modal.js +0 -1
  35. package/dist/components/Modal.js.map +1 -1
  36. package/dist/components/Procaptcha.d.ts.map +1 -1
  37. package/dist/components/Procaptcha.js +1 -1
  38. package/dist/components/Procaptcha.js.map +1 -1
  39. package/dist/components/ProcaptchaWidget.d.ts +2 -2
  40. package/dist/components/ProcaptchaWidget.d.ts.map +1 -1
  41. package/dist/components/ProcaptchaWidget.js +27 -79
  42. package/dist/components/ProcaptchaWidget.js.map +1 -1
  43. package/dist/components/collector.d.ts +3 -2
  44. package/dist/components/collector.d.ts.map +1 -1
  45. package/dist/components/collector.js +4 -3
  46. package/dist/components/collector.js.map +1 -1
  47. package/dist/components/index.d.ts +1 -1
  48. package/dist/components/index.d.ts.map +1 -1
  49. package/dist/components/index.js +1 -1
  50. package/dist/components/index.js.map +1 -1
  51. package/package.json +8 -7
  52. package/typedoc.config.js +19 -0
  53. package/vite.cjs.config.ts +13 -0
  54. package/dist/cjs/components/CaptchaPlaceholder.cjs +0 -132
  55. package/dist/cjs/components/Checkbox.cjs +0 -56
  56. package/dist/components/CaptchaPlaceholder.d.ts +0 -6
  57. package/dist/components/CaptchaPlaceholder.d.ts.map +0 -1
  58. package/dist/components/CaptchaPlaceholder.js +0 -77
  59. package/dist/components/CaptchaPlaceholder.js.map +0 -1
  60. package/dist/components/Checkbox.d.ts +0 -9
  61. package/dist/components/Checkbox.d.ts.map +0 -1
  62. package/dist/components/Checkbox.js +0 -43
  63. package/dist/components/Checkbox.js.map +0 -1
  64. package/dist/components/LoadingSpinner.d.ts +0 -6
  65. package/dist/components/LoadingSpinner.d.ts.map +0 -1
  66. package/dist/components/LoadingSpinner.js +0 -28
  67. package/dist/components/LoadingSpinner.js.map +0 -1
  68. package/dist/components/theme.d.ts +0 -51
  69. package/dist/components/theme.d.ts.map +0 -1
  70. package/dist/components/theme.js +0 -41
  71. package/dist/components/theme.js.map +0 -1
  72. /package/dist/cjs/{components → web-components/dist}/theme.cjs +0 -0
@@ -1,3 +1,16 @@
1
+ // Copyright 2021-2024 Prosopo (UK) Ltd.
2
+ //
3
+ // Licensed under the Apache License, Version 2.0 (the "License");
4
+ // you may not use this file except in compliance with the License.
5
+ // You may obtain a copy of the License at
6
+ //
7
+ // http://www.apache.org/licenses/LICENSE-2.0
8
+ //
9
+ // Unless required by applicable law or agreed to in writing, software
10
+ // distributed under the License is distributed on an "AS IS" BASIS,
11
+ // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12
+ // See the License for the specific language governing permissions and
13
+ // limitations under the License.
1
14
  import { ViteCommonJSConfig } from '@prosopo/config'
2
15
  import path from 'path'
3
16
 
@@ -1,132 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
3
- const jsxRuntime = require("@emotion/react/jsx-runtime");
4
- const LoadingSpinner = require("./LoadingSpinner.cjs");
5
- const react = require("@emotion/react");
6
- const theme = require("./theme.cjs");
7
- const React = require("react");
8
- const logoStyle = react.css`
9
- align-items: center;
10
- justify-content: flex-end;
11
- display: flex;
12
- padding: 8px;
13
-
14
- @media (max-width: 245px) {
15
- &:nth-of-type(1),
16
- &:nth-of-type(2) {
17
- display: none;
18
- } /* Both logos hidden */
19
- }
20
-
21
- @media (min-width: 245px) and (max-width: 400px) {
22
- &:nth-of-type(1) {
23
- display: flex;
24
- } /* logoWithText */
25
- &:nth-of-type(2) {
26
- display: none;
27
- } /* logoWithoutText */
28
- }
29
-
30
- @media (min-width: 401px) {
31
- &:nth-of-type(1) {
32
- display: none;
33
- } /* logoWithText */
34
- &:nth-of-type(2) {
35
- display: flex;
36
- } /* logoWithoutText */
37
- }
38
- `;
39
- const ProcaptchaPlaceholder = (props) => {
40
- const darkMode = props.darkMode;
41
- const styleWidth = { maxWidth: "400px", minWidth: "200px", margin: "8px" };
42
- const themeColor = darkMode ? "light" : "dark";
43
- const theme$1 = React.useMemo(() => darkMode === "light" ? theme.lightTheme : theme.darkTheme, [darkMode]);
44
- return /* @__PURE__ */ jsxRuntime.jsx("div", { children: /* @__PURE__ */ jsxRuntime.jsx("div", { style: { maxWidth: "100%", maxHeight: "100%", overflowX: "auto" }, children: /* @__PURE__ */ jsxRuntime.jsxs("div", { style: styleWidth, "data-cy": "button-human", children: [
45
- " ",
46
- /* @__PURE__ */ jsxRuntime.jsxs(
47
- "div",
48
- {
49
- style: {
50
- padding: "8px",
51
- border: "1px solid",
52
- backgroundColor: theme$1.palette.background.default,
53
- borderColor: theme$1.palette.grey[300],
54
- borderRadius: "8px",
55
- display: "flex",
56
- justifyContent: "space-between",
57
- alignItems: "center",
58
- flexWrap: "wrap"
59
- },
60
- children: [
61
- /* @__PURE__ */ jsxRuntime.jsx("div", { style: { display: "flex", flexDirection: "column" }, children: /* @__PURE__ */ jsxRuntime.jsx(
62
- "div",
63
- {
64
- style: {
65
- display: "flex",
66
- justifyContent: "flex-start",
67
- alignItems: "center",
68
- flexWrap: "wrap"
69
- },
70
- children: /* @__PURE__ */ jsxRuntime.jsx(
71
- "div",
72
- {
73
- style: {
74
- height: "50px",
75
- width: "50px",
76
- display: "flex",
77
- alignItems: "center",
78
- justifyContent: "center",
79
- flexDirection: "column",
80
- verticalAlign: "middle"
81
- },
82
- children: /* @__PURE__ */ jsxRuntime.jsx(
83
- "div",
84
- {
85
- style: {
86
- display: "flex"
87
- },
88
- children: /* @__PURE__ */ jsxRuntime.jsx("div", { style: { flex: 1 }, children: /* @__PURE__ */ jsxRuntime.jsx(LoadingSpinner.LoadingSpinner, { themeColor }) })
89
- }
90
- )
91
- }
92
- )
93
- }
94
- ) }),
95
- /* @__PURE__ */ jsxRuntime.jsx("div", { children: /* @__PURE__ */ jsxRuntime.jsx(
96
- "a",
97
- {
98
- href: "https://www.prosopo.io/#features?ref=accounts.prosopo.io&utm_campaign=widget&utm_medium=checkbox",
99
- target: "_blank",
100
- "aria-label": "Visit prosopo.io to learn more about the service and its accessibility options.",
101
- children: /* @__PURE__ */ jsxRuntime.jsx("div", { children: /* @__PURE__ */ jsxRuntime.jsxs("div", { children: [
102
- /* @__PURE__ */ jsxRuntime.jsx(
103
- "div",
104
- {
105
- css: logoStyle,
106
- dangerouslySetInnerHTML: {
107
- __html: darkMode === "light" ? logoWithoutTextBlack : logoWithoutTextWhite
108
- }
109
- }
110
- ),
111
- /* @__PURE__ */ jsxRuntime.jsx(
112
- "div",
113
- {
114
- css: logoStyle,
115
- dangerouslySetInnerHTML: {
116
- __html: darkMode === "light" ? logoWithTextBlack : logoWithTextWhite
117
- }
118
- }
119
- )
120
- ] }) })
121
- }
122
- ) })
123
- ]
124
- }
125
- )
126
- ] }) }) });
127
- };
128
- const logoWithTextBlack = '<svg id="Layer_1" data-name="Layer 1" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 2062.63 468.67" height="35px" width="140px"><defs><style>.cls-1{fill:#1d1d1b;}</style></defs><title>Prosopo Logo Black</title><path class="cls-1" d="M335.55,1825.19A147.75,147.75,0,0,1,483.3,1972.94h50.5c0-109.49-88.76-198.25-198.25-198.25v50.5Z" transform="translate(-215.73 -1774.69)"/><path class="cls-1" d="M269.36,1891.39A147.74,147.74,0,0,1,417.1,2039.13h50.5c0-109.49-88.75-198.24-198.24-198.24v50.5Z" transform="translate(-215.73 -1774.69)"/><path class="cls-1" d="M414,2157.17a147.75,147.75,0,0,1-147.74-147.74h-50.5c0,109.49,88.75,198.24,198.24,198.24v-50.5Z" transform="translate(-215.73 -1774.69)"/><path class="cls-1" d="M480.17,2091a147.74,147.74,0,0,1-147.74-147.75H281.92c0,109.49,88.76,198.25,198.25,198.25V2091Z" transform="translate(-215.73 -1774.69)"/><path class="cls-1" d="M862.8,2017.5q-27.39,22.86-78.25,22.86h-65v112.19H654.82v-312h134q46.32,0,73.86,24.13t27.55,74.72Q890.2,1994.64,862.8,2017.5ZM813,1905.1q-12.37-10.36-34.7-10.38H719.59v91.87h58.75q22.32,0,34.7-11.22t12.39-35.56Q825.43,1915.48,813,1905.1Z" transform="translate(-215.73 -1774.69)"/><path class="cls-1" d="M1045.69,1916.42c.78.08,2.51.19,5.19.32v61.81c-3.81-.42-7.2-.71-10.16-.85s-5.36-.21-7.2-.21q-36.4,0-48.89,23.71-7,13.33-7,41.06v110.29H916.89V1921.82h57.58V1962q14-23.07,24.34-31.54,16.94-14.18,44-14.18C1044,1916.32,1044.92,1916.35,1045.69,1916.42Z" transform="translate(-215.73 -1774.69)"/><path class="cls-1" d="M1265.64,2124.32q-29.21,36.06-88.69,36.06t-88.69-36.06Q1059,2088.26,1059,2037.5q0-49.9,29.22-86.5t88.69-36.59q59.47,0,88.69,36.59t29.21,86.5Q1294.85,2088.26,1265.64,2124.32ZM1217.38,2091q14.17-18.81,14.18-53.48t-14.18-53.37q-14.19-18.7-40.64-18.71T1136,1984.13q-14.29,18.72-14.29,53.37T1136,2091q14.28,18.81,40.75,18.81T1217.38,2091Z" transform="translate(-215.73 -1774.69)"/><path class="cls-1" d="M1371.81,2078.88q1.92,16.1,8.29,22.87,11.28,12.06,41.7,12.06,17.85,0,28.39-5.29t10.53-15.88a17.12,17.12,0,0,0-8.48-15.45q-8.49-5.28-63.12-18.2-39.33-9.73-55.41-24.35-16.08-14.39-16.09-41.49,0-32,25.14-54.93t70.75-23q43.26,0,70.53,17.25t31.29,59.59H1455q-1.27-11.64-6.58-18.42-10-12.27-34-12.28-19.74,0-28.13,6.14t-8.38,14.4c0,6.91,3,11.93,8.92,15q8.89,4.89,63,16.73,36,8.46,54.05,25.61,17.77,17.35,17.78,43.39,0,34.3-25.56,56t-79,21.7q-54.51,0-80.49-23t-26-58.53Z" transform="translate(-215.73 -1774.69)"/><path class="cls-1" d="M1745.54,2124.32q-29.22,36.06-88.7,36.06t-88.69-36.06q-29.2-36.06-29.21-86.82,0-49.9,29.21-86.5t88.69-36.59q59.49,0,88.7,36.59t29.21,86.5Q1774.75,2088.26,1745.54,2124.32ZM1697.27,2091q14.19-18.81,14.19-53.48t-14.19-53.37q-14.18-18.7-40.64-18.71t-40.75,18.71q-14.28,18.72-14.28,53.37t14.28,53.48q14.3,18.81,40.75,18.81T1697.27,2091Z" transform="translate(-215.73 -1774.69)"/><path class="cls-1" d="M1992.75,1946.59q28.24,29.84,28.23,87.63,0,61-27.58,92.93t-71.06,32q-27.69,0-46-13.76-10-7.62-19.6-22.23v120.24H1797V1921.82h57.79v34.08q9.79-15,20.88-23.71,20.23-15.43,48.15-15.45Q1964.53,1916.74,1992.75,1946.59Zm-46.3,43.39q-12.3-20.52-39.88-20.53-33.15,0-45.54,31.11-6.43,16.51-6.42,41.92,0,40.21,21.58,56.51,12.82,9.53,30.37,9.53,25.45,0,38.83-19.48t13.36-51.86Q1958.75,2010.51,1946.45,1990Z" transform="translate(-215.73 -1774.69)"/><path class="cls-1" d="M2249.14,2124.32q-29.2,36.06-88.69,36.06t-88.69-36.06q-29.22-36.06-29.21-86.82,0-49.9,29.21-86.5t88.69-36.59q59.49,0,88.69,36.59t29.22,86.5Q2278.36,2088.26,2249.14,2124.32ZM2200.88,2091q14.19-18.81,14.18-53.48t-14.18-53.37q-14.18-18.7-40.64-18.71t-40.75,18.71q-14.28,18.72-14.29,53.37t14.29,53.48q14.3,18.81,40.75,18.81T2200.88,2091Z" transform="translate(-215.73 -1774.69)"/></svg>';
129
- const logoWithTextWhite = '<svg id="Layer_1" data-name="Layer 1" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 2062.63 468.67" height="35px" width="140px"><defs><style>.cls-1{fill:#fff;}</style></defs><title>Prosopo Logo Black</title><path class="cls-1" d="M335.55,1825.19A147.75,147.75,0,0,1,483.3,1972.94h50.5c0-109.49-88.76-198.25-198.25-198.25v50.5Z" transform="translate(-215.73 -1774.69)"/><path class="cls-1" d="M269.36,1891.39A147.74,147.74,0,0,1,417.1,2039.13h50.5c0-109.49-88.75-198.24-198.24-198.24v50.5Z" transform="translate(-215.73 -1774.69)"/><path class="cls-1" d="M414,2157.17a147.75,147.75,0,0,1-147.74-147.74h-50.5c0,109.49,88.75,198.24,198.24,198.24v-50.5Z" transform="translate(-215.73 -1774.69)"/><path class="cls-1" d="M480.17,2091a147.74,147.74,0,0,1-147.74-147.75H281.92c0,109.49,88.76,198.25,198.25,198.25V2091Z" transform="translate(-215.73 -1774.69)"/><path class="cls-1" d="M862.8,2017.5q-27.39,22.86-78.25,22.86h-65v112.19H654.82v-312h134q46.32,0,73.86,24.13t27.55,74.72Q890.2,1994.64,862.8,2017.5ZM813,1905.1q-12.37-10.36-34.7-10.38H719.59v91.87h58.75q22.32,0,34.7-11.22t12.39-35.56Q825.43,1915.48,813,1905.1Z" transform="translate(-215.73 -1774.69)"/><path class="cls-1" d="M1045.69,1916.42c.78.08,2.51.19,5.19.32v61.81c-3.81-.42-7.2-.71-10.16-.85s-5.36-.21-7.2-.21q-36.4,0-48.89,23.71-7,13.33-7,41.06v110.29H916.89V1921.82h57.58V1962q14-23.07,24.34-31.54,16.94-14.18,44-14.18C1044,1916.32,1044.92,1916.35,1045.69,1916.42Z" transform="translate(-215.73 -1774.69)"/><path class="cls-1" d="M1265.64,2124.32q-29.21,36.06-88.69,36.06t-88.69-36.06Q1059,2088.26,1059,2037.5q0-49.9,29.22-86.5t88.69-36.59q59.47,0,88.69,36.59t29.21,86.5Q1294.85,2088.26,1265.64,2124.32ZM1217.38,2091q14.17-18.81,14.18-53.48t-14.18-53.37q-14.19-18.7-40.64-18.71T1136,1984.13q-14.29,18.72-14.29,53.37T1136,2091q14.28,18.81,40.75,18.81T1217.38,2091Z" transform="translate(-215.73 -1774.69)"/><path class="cls-1" d="M1371.81,2078.88q1.92,16.1,8.29,22.87,11.28,12.06,41.7,12.06,17.85,0,28.39-5.29t10.53-15.88a17.12,17.12,0,0,0-8.48-15.45q-8.49-5.28-63.12-18.2-39.33-9.73-55.41-24.35-16.08-14.39-16.09-41.49,0-32,25.14-54.93t70.75-23q43.26,0,70.53,17.25t31.29,59.59H1455q-1.27-11.64-6.58-18.42-10-12.27-34-12.28-19.74,0-28.13,6.14t-8.38,14.4c0,6.91,3,11.93,8.92,15q8.89,4.89,63,16.73,36,8.46,54.05,25.61,17.77,17.35,17.78,43.39,0,34.3-25.56,56t-79,21.7q-54.51,0-80.49-23t-26-58.53Z" transform="translate(-215.73 -1774.69)"/><path class="cls-1" d="M1745.54,2124.32q-29.22,36.06-88.7,36.06t-88.69-36.06q-29.2-36.06-29.21-86.82,0-49.9,29.21-86.5t88.69-36.59q59.49,0,88.7,36.59t29.21,86.5Q1774.75,2088.26,1745.54,2124.32ZM1697.27,2091q14.19-18.81,14.19-53.48t-14.19-53.37q-14.18-18.7-40.64-18.71t-40.75,18.71q-14.28,18.72-14.28,53.37t14.28,53.48q14.3,18.81,40.75,18.81T1697.27,2091Z" transform="translate(-215.73 -1774.69)"/><path class="cls-1" d="M1992.75,1946.59q28.24,29.84,28.23,87.63,0,61-27.58,92.93t-71.06,32q-27.69,0-46-13.76-10-7.62-19.6-22.23v120.24H1797V1921.82h57.79v34.08q9.79-15,20.88-23.71,20.23-15.43,48.15-15.45Q1964.53,1916.74,1992.75,1946.59Zm-46.3,43.39q-12.3-20.52-39.88-20.53-33.15,0-45.54,31.11-6.43,16.51-6.42,41.92,0,40.21,21.58,56.51,12.82,9.53,30.37,9.53,25.45,0,38.83-19.48t13.36-51.86Q1958.75,2010.51,1946.45,1990Z" transform="translate(-215.73 -1774.69)"/><path class="cls-1" d="M2249.14,2124.32q-29.2,36.06-88.69,36.06t-88.69-36.06q-29.22-36.06-29.21-86.82,0-49.9,29.21-86.5t88.69-36.59q59.49,0,88.69,36.59t29.22,86.5Q2278.36,2088.26,2249.14,2124.32ZM2200.88,2091q14.19-18.81,14.18-53.48t-14.18-53.37q-14.18-18.7-40.64-18.71t-40.75,18.71q-14.28,18.72-14.29,53.37t14.29,53.48q14.3,18.81,40.75,18.81T2200.88,2091Z" transform="translate(-215.73 -1774.69)"/></svg>';
130
- const logoWithoutTextWhite = '<svg id="Layer_1" data-name="Layer 1" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 260 348" height="35px"><path id="Vector" d="M95.7053 40.2707C127.005 40.2707 157.022 52.6841 179.154 74.78C201.286 96.8759 213.719 126.844 213.719 158.093H254.056C254.056 70.7808 183.16 -4.57764e-05 95.7053 -4.57764e-05V40.2707Z" fill="#fff"/><path id="Vector_2" d="M42.8365 93.0614C58.3333 93.0614 73.6784 96.1087 87.9955 102.029C102.313 107.95 115.322 116.628 126.279 127.568C137.237 138.508 145.93 151.496 151.86 165.79C157.79 180.084 160.843 195.404 160.843 210.875H201.179C201.179 123.564 130.291 52.7906 42.8365 52.7906V93.0614Z" fill="#fff"/><path id="Vector_3" d="M158.367 305.005C127.07 305.003 97.056 292.59 74.926 270.496C52.796 248.402 40.3626 218.437 40.3604 187.191H0.0239563C0.0239563 274.503 70.9123 345.276 158.367 345.276V305.005Z" fill="#fff"/><path id="Vector_4" d="M211.219 252.239C195.722 252.239 180.376 249.191 166.059 243.27C151.741 237.349 138.732 228.67 127.774 217.729C116.816 206.788 108.123 193.799 102.194 179.505C96.2637 165.21 93.2121 149.889 93.2132 134.417H52.8687C52.8687 221.729 123.765 292.509 211.219 292.509V252.239Z" fill="#fff"/></g><defs><clipPath id="clip0_1_2"><rect width="254" height="345" fill="white"/></clipPath></defs></svg>';
131
- const logoWithoutTextBlack = '<svg id="Layer_1" data-name="Layer 1" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 260 348" height="35px"><path id="Vector" d="M95.7053 40.2707C127.005 40.2707 157.022 52.6841 179.154 74.78C201.286 96.8759 213.719 126.844 213.719 158.093H254.056C254.056 70.7808 183.16 -4.57764e-05 95.7053 -4.57764e-05V40.2707Z" fill="#000000"/><path id="Vector_2" d="M42.8365 93.0614C58.3333 93.0614 73.6784 96.1087 87.9955 102.029C102.313 107.95 115.322 116.628 126.279 127.568C137.237 138.508 145.93 151.496 151.86 165.79C157.79 180.084 160.843 195.404 160.843 210.875H201.179C201.179 123.564 130.291 52.7906 42.8365 52.7906V93.0614Z" fill="#000000"/><path id="Vector_3" d="M158.367 305.005C127.07 305.003 97.056 292.59 74.926 270.496C52.796 248.402 40.3626 218.437 40.3604 187.191H0.0239563C0.0239563 274.503 70.9123 345.276 158.367 345.276V305.005Z" fill="#000000"/><path id="Vector_4" d="M211.219 252.239C195.722 252.239 180.376 249.191 166.059 243.27C151.741 237.349 138.732 228.67 127.774 217.729C116.816 206.788 108.123 193.799 102.194 179.505C96.2637 165.21 93.2121 149.889 93.2132 134.417H52.8687C52.8687 221.729 123.765 292.509 211.219 292.509V252.239Z" fill="#000000"/></g><defs><clipPath id="clip0_1_2"><rect width="254" height="345" fill="white"/></clipPath></defs></svg>';
132
- exports.ProcaptchaPlaceholder = ProcaptchaPlaceholder;
@@ -1,56 +0,0 @@
1
- "use strict";
2
- const jsxRuntime = require("@emotion/react/jsx-runtime");
3
- const react = require("@emotion/react");
4
- const theme = require("./theme.cjs");
5
- const React = require("react");
6
- const checkboxBefore = react.css`{
7
- &:before {
8
- content: '""';
9
- position: absolute;
10
- height: 100%;
11
- width: 100%;
12
- }
13
- }`;
14
- const baseStyle = {
15
- width: "2.2em",
16
- height: "2.2em",
17
- top: "auto",
18
- left: "auto",
19
- opacity: "1",
20
- borderRadius: "12.5%",
21
- appearance: "none",
22
- cursor: "pointer",
23
- margin: "0",
24
- borderStyle: "solid",
25
- borderWidth: "1px"
26
- };
27
- const Checkbox = ({ themeColor, onChange, checked }) => {
28
- const theme$1 = React.useMemo(() => themeColor === "light" ? theme.lightTheme : theme.darkTheme, [themeColor]);
29
- const checkboxStyleBase = {
30
- ...baseStyle,
31
- border: `1px solid ${theme$1.palette.background.contrastText}`
32
- };
33
- const [hover, setHover] = React.useState(false);
34
- const checkboxStyle = React.useMemo(() => {
35
- return {
36
- ...checkboxStyleBase,
37
- borderColor: hover ? theme$1.palette.background.contrastText : theme$1.palette.grey[400],
38
- appearance: checked ? "auto" : "none"
39
- };
40
- }, [hover, theme$1, checked]);
41
- return /* @__PURE__ */ jsxRuntime.jsx(
42
- "input",
43
- {
44
- onMouseEnter: () => setHover(true),
45
- onMouseLeave: () => setHover(false),
46
- css: checkboxBefore,
47
- type: "checkbox",
48
- "aria-live": "assertive",
49
- "aria-haspopup": "true",
50
- onChange,
51
- checked,
52
- style: checkboxStyle
53
- }
54
- );
55
- };
56
- module.exports = Checkbox;
@@ -1,6 +0,0 @@
1
- type PlaceholderProps = {
2
- darkMode: 'light' | 'dark' | undefined;
3
- };
4
- export declare const ProcaptchaPlaceholder: (props: PlaceholderProps) => import("@emotion/react/jsx-runtime").JSX.Element;
5
- export {};
6
- //# sourceMappingURL=CaptchaPlaceholder.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"CaptchaPlaceholder.d.ts","sourceRoot":"","sources":["../../src/components/CaptchaPlaceholder.tsx"],"names":[],"mappings":"AAmDA,KAAK,gBAAgB,GAAG;IAAE,QAAQ,EAAE,OAAO,GAAG,MAAM,GAAG,SAAS,CAAA;CAAE,CAAA;AAElE,eAAO,MAAM,qBAAqB,UAAW,gBAAgB,qDAqF5D,CAAA"}
@@ -1,77 +0,0 @@
1
- import { jsx as _jsx, jsxs as _jsxs } from "@emotion/react/jsx-runtime";
2
- import { LoadingSpinner } from './LoadingSpinner.js';
3
- import { css } from '@emotion/react';
4
- import { darkTheme, lightTheme } from './theme.js';
5
- import { useMemo } from 'react';
6
- const logoStyle = css `
7
- align-items: center;
8
- justify-content: flex-end;
9
- display: flex;
10
- padding: 8px;
11
-
12
- @media (max-width: 245px) {
13
- &:nth-of-type(1),
14
- &:nth-of-type(2) {
15
- display: none;
16
- } /* Both logos hidden */
17
- }
18
-
19
- @media (min-width: 245px) and (max-width: 400px) {
20
- &:nth-of-type(1) {
21
- display: flex;
22
- } /* logoWithText */
23
- &:nth-of-type(2) {
24
- display: none;
25
- } /* logoWithoutText */
26
- }
27
-
28
- @media (min-width: 401px) {
29
- &:nth-of-type(1) {
30
- display: none;
31
- } /* logoWithText */
32
- &:nth-of-type(2) {
33
- display: flex;
34
- } /* logoWithoutText */
35
- }
36
- `;
37
- export const ProcaptchaPlaceholder = (props) => {
38
- const darkMode = props.darkMode;
39
- const styleWidth = { maxWidth: '400px', minWidth: '200px', margin: '8px' };
40
- const themeColor = darkMode ? 'light' : 'dark';
41
- const theme = useMemo(() => (darkMode === 'light' ? lightTheme : darkTheme), [darkMode]);
42
- return (_jsx("div", { children: _jsx("div", { style: { maxWidth: '100%', maxHeight: '100%', overflowX: 'auto' }, children: _jsxs("div", { style: styleWidth, "data-cy": 'button-human', children: [' ', _jsxs("div", { style: {
43
- padding: '8px',
44
- border: '1px solid',
45
- backgroundColor: theme.palette.background.default,
46
- borderColor: theme.palette.grey[300],
47
- borderRadius: '8px',
48
- display: 'flex',
49
- justifyContent: 'space-between',
50
- alignItems: 'center',
51
- flexWrap: 'wrap',
52
- }, children: [_jsx("div", { style: { display: 'flex', flexDirection: 'column' }, children: _jsx("div", { style: {
53
- display: 'flex',
54
- justifyContent: 'flex-start',
55
- alignItems: 'center',
56
- flexWrap: 'wrap',
57
- }, children: _jsx("div", { style: {
58
- height: '50px',
59
- width: '50px',
60
- display: 'flex',
61
- alignItems: 'center',
62
- justifyContent: 'center',
63
- flexDirection: 'column',
64
- verticalAlign: 'middle',
65
- }, children: _jsx("div", { style: {
66
- display: 'flex',
67
- }, children: _jsx("div", { style: { flex: 1 }, children: _jsx(LoadingSpinner, { themeColor: themeColor }) }) }) }) }) }), _jsx("div", { children: _jsx("a", { href: "https://www.prosopo.io/#features?ref=accounts.prosopo.io&utm_campaign=widget&utm_medium=checkbox", target: "_blank", "aria-label": "Visit prosopo.io to learn more about the service and its accessibility options.", children: _jsx("div", { children: _jsxs("div", { children: [_jsx("div", { css: logoStyle, dangerouslySetInnerHTML: {
68
- __html: darkMode === 'light' ? logoWithoutTextBlack : logoWithoutTextWhite,
69
- } }), _jsx("div", { css: logoStyle, dangerouslySetInnerHTML: {
70
- __html: darkMode === 'light' ? logoWithTextBlack : logoWithTextWhite,
71
- } })] }) }) }) })] })] }) }) }));
72
- };
73
- const logoWithTextBlack = '<svg id="Layer_1" data-name="Layer 1" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 2062.63 468.67" height="35px" width="140px"><defs><style>.cls-1{fill:#1d1d1b;}</style></defs><title>Prosopo Logo Black</title><path class="cls-1" d="M335.55,1825.19A147.75,147.75,0,0,1,483.3,1972.94h50.5c0-109.49-88.76-198.25-198.25-198.25v50.5Z" transform="translate(-215.73 -1774.69)"/><path class="cls-1" d="M269.36,1891.39A147.74,147.74,0,0,1,417.1,2039.13h50.5c0-109.49-88.75-198.24-198.24-198.24v50.5Z" transform="translate(-215.73 -1774.69)"/><path class="cls-1" d="M414,2157.17a147.75,147.75,0,0,1-147.74-147.74h-50.5c0,109.49,88.75,198.24,198.24,198.24v-50.5Z" transform="translate(-215.73 -1774.69)"/><path class="cls-1" d="M480.17,2091a147.74,147.74,0,0,1-147.74-147.75H281.92c0,109.49,88.76,198.25,198.25,198.25V2091Z" transform="translate(-215.73 -1774.69)"/><path class="cls-1" d="M862.8,2017.5q-27.39,22.86-78.25,22.86h-65v112.19H654.82v-312h134q46.32,0,73.86,24.13t27.55,74.72Q890.2,1994.64,862.8,2017.5ZM813,1905.1q-12.37-10.36-34.7-10.38H719.59v91.87h58.75q22.32,0,34.7-11.22t12.39-35.56Q825.43,1915.48,813,1905.1Z" transform="translate(-215.73 -1774.69)"/><path class="cls-1" d="M1045.69,1916.42c.78.08,2.51.19,5.19.32v61.81c-3.81-.42-7.2-.71-10.16-.85s-5.36-.21-7.2-.21q-36.4,0-48.89,23.71-7,13.33-7,41.06v110.29H916.89V1921.82h57.58V1962q14-23.07,24.34-31.54,16.94-14.18,44-14.18C1044,1916.32,1044.92,1916.35,1045.69,1916.42Z" transform="translate(-215.73 -1774.69)"/><path class="cls-1" d="M1265.64,2124.32q-29.21,36.06-88.69,36.06t-88.69-36.06Q1059,2088.26,1059,2037.5q0-49.9,29.22-86.5t88.69-36.59q59.47,0,88.69,36.59t29.21,86.5Q1294.85,2088.26,1265.64,2124.32ZM1217.38,2091q14.17-18.81,14.18-53.48t-14.18-53.37q-14.19-18.7-40.64-18.71T1136,1984.13q-14.29,18.72-14.29,53.37T1136,2091q14.28,18.81,40.75,18.81T1217.38,2091Z" transform="translate(-215.73 -1774.69)"/><path class="cls-1" d="M1371.81,2078.88q1.92,16.1,8.29,22.87,11.28,12.06,41.7,12.06,17.85,0,28.39-5.29t10.53-15.88a17.12,17.12,0,0,0-8.48-15.45q-8.49-5.28-63.12-18.2-39.33-9.73-55.41-24.35-16.08-14.39-16.09-41.49,0-32,25.14-54.93t70.75-23q43.26,0,70.53,17.25t31.29,59.59H1455q-1.27-11.64-6.58-18.42-10-12.27-34-12.28-19.74,0-28.13,6.14t-8.38,14.4c0,6.91,3,11.93,8.92,15q8.89,4.89,63,16.73,36,8.46,54.05,25.61,17.77,17.35,17.78,43.39,0,34.3-25.56,56t-79,21.7q-54.51,0-80.49-23t-26-58.53Z" transform="translate(-215.73 -1774.69)"/><path class="cls-1" d="M1745.54,2124.32q-29.22,36.06-88.7,36.06t-88.69-36.06q-29.2-36.06-29.21-86.82,0-49.9,29.21-86.5t88.69-36.59q59.49,0,88.7,36.59t29.21,86.5Q1774.75,2088.26,1745.54,2124.32ZM1697.27,2091q14.19-18.81,14.19-53.48t-14.19-53.37q-14.18-18.7-40.64-18.71t-40.75,18.71q-14.28,18.72-14.28,53.37t14.28,53.48q14.3,18.81,40.75,18.81T1697.27,2091Z" transform="translate(-215.73 -1774.69)"/><path class="cls-1" d="M1992.75,1946.59q28.24,29.84,28.23,87.63,0,61-27.58,92.93t-71.06,32q-27.69,0-46-13.76-10-7.62-19.6-22.23v120.24H1797V1921.82h57.79v34.08q9.79-15,20.88-23.71,20.23-15.43,48.15-15.45Q1964.53,1916.74,1992.75,1946.59Zm-46.3,43.39q-12.3-20.52-39.88-20.53-33.15,0-45.54,31.11-6.43,16.51-6.42,41.92,0,40.21,21.58,56.51,12.82,9.53,30.37,9.53,25.45,0,38.83-19.48t13.36-51.86Q1958.75,2010.51,1946.45,1990Z" transform="translate(-215.73 -1774.69)"/><path class="cls-1" d="M2249.14,2124.32q-29.2,36.06-88.69,36.06t-88.69-36.06q-29.22-36.06-29.21-86.82,0-49.9,29.21-86.5t88.69-36.59q59.49,0,88.69,36.59t29.22,86.5Q2278.36,2088.26,2249.14,2124.32ZM2200.88,2091q14.19-18.81,14.18-53.48t-14.18-53.37q-14.18-18.7-40.64-18.71t-40.75,18.71q-14.28,18.72-14.29,53.37t14.29,53.48q14.3,18.81,40.75,18.81T2200.88,2091Z" transform="translate(-215.73 -1774.69)"/></svg>';
74
- const logoWithTextWhite = '<svg id="Layer_1" data-name="Layer 1" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 2062.63 468.67" height="35px" width="140px"><defs><style>.cls-1{fill:#fff;}</style></defs><title>Prosopo Logo Black</title><path class="cls-1" d="M335.55,1825.19A147.75,147.75,0,0,1,483.3,1972.94h50.5c0-109.49-88.76-198.25-198.25-198.25v50.5Z" transform="translate(-215.73 -1774.69)"/><path class="cls-1" d="M269.36,1891.39A147.74,147.74,0,0,1,417.1,2039.13h50.5c0-109.49-88.75-198.24-198.24-198.24v50.5Z" transform="translate(-215.73 -1774.69)"/><path class="cls-1" d="M414,2157.17a147.75,147.75,0,0,1-147.74-147.74h-50.5c0,109.49,88.75,198.24,198.24,198.24v-50.5Z" transform="translate(-215.73 -1774.69)"/><path class="cls-1" d="M480.17,2091a147.74,147.74,0,0,1-147.74-147.75H281.92c0,109.49,88.76,198.25,198.25,198.25V2091Z" transform="translate(-215.73 -1774.69)"/><path class="cls-1" d="M862.8,2017.5q-27.39,22.86-78.25,22.86h-65v112.19H654.82v-312h134q46.32,0,73.86,24.13t27.55,74.72Q890.2,1994.64,862.8,2017.5ZM813,1905.1q-12.37-10.36-34.7-10.38H719.59v91.87h58.75q22.32,0,34.7-11.22t12.39-35.56Q825.43,1915.48,813,1905.1Z" transform="translate(-215.73 -1774.69)"/><path class="cls-1" d="M1045.69,1916.42c.78.08,2.51.19,5.19.32v61.81c-3.81-.42-7.2-.71-10.16-.85s-5.36-.21-7.2-.21q-36.4,0-48.89,23.71-7,13.33-7,41.06v110.29H916.89V1921.82h57.58V1962q14-23.07,24.34-31.54,16.94-14.18,44-14.18C1044,1916.32,1044.92,1916.35,1045.69,1916.42Z" transform="translate(-215.73 -1774.69)"/><path class="cls-1" d="M1265.64,2124.32q-29.21,36.06-88.69,36.06t-88.69-36.06Q1059,2088.26,1059,2037.5q0-49.9,29.22-86.5t88.69-36.59q59.47,0,88.69,36.59t29.21,86.5Q1294.85,2088.26,1265.64,2124.32ZM1217.38,2091q14.17-18.81,14.18-53.48t-14.18-53.37q-14.19-18.7-40.64-18.71T1136,1984.13q-14.29,18.72-14.29,53.37T1136,2091q14.28,18.81,40.75,18.81T1217.38,2091Z" transform="translate(-215.73 -1774.69)"/><path class="cls-1" d="M1371.81,2078.88q1.92,16.1,8.29,22.87,11.28,12.06,41.7,12.06,17.85,0,28.39-5.29t10.53-15.88a17.12,17.12,0,0,0-8.48-15.45q-8.49-5.28-63.12-18.2-39.33-9.73-55.41-24.35-16.08-14.39-16.09-41.49,0-32,25.14-54.93t70.75-23q43.26,0,70.53,17.25t31.29,59.59H1455q-1.27-11.64-6.58-18.42-10-12.27-34-12.28-19.74,0-28.13,6.14t-8.38,14.4c0,6.91,3,11.93,8.92,15q8.89,4.89,63,16.73,36,8.46,54.05,25.61,17.77,17.35,17.78,43.39,0,34.3-25.56,56t-79,21.7q-54.51,0-80.49-23t-26-58.53Z" transform="translate(-215.73 -1774.69)"/><path class="cls-1" d="M1745.54,2124.32q-29.22,36.06-88.7,36.06t-88.69-36.06q-29.2-36.06-29.21-86.82,0-49.9,29.21-86.5t88.69-36.59q59.49,0,88.7,36.59t29.21,86.5Q1774.75,2088.26,1745.54,2124.32ZM1697.27,2091q14.19-18.81,14.19-53.48t-14.19-53.37q-14.18-18.7-40.64-18.71t-40.75,18.71q-14.28,18.72-14.28,53.37t14.28,53.48q14.3,18.81,40.75,18.81T1697.27,2091Z" transform="translate(-215.73 -1774.69)"/><path class="cls-1" d="M1992.75,1946.59q28.24,29.84,28.23,87.63,0,61-27.58,92.93t-71.06,32q-27.69,0-46-13.76-10-7.62-19.6-22.23v120.24H1797V1921.82h57.79v34.08q9.79-15,20.88-23.71,20.23-15.43,48.15-15.45Q1964.53,1916.74,1992.75,1946.59Zm-46.3,43.39q-12.3-20.52-39.88-20.53-33.15,0-45.54,31.11-6.43,16.51-6.42,41.92,0,40.21,21.58,56.51,12.82,9.53,30.37,9.53,25.45,0,38.83-19.48t13.36-51.86Q1958.75,2010.51,1946.45,1990Z" transform="translate(-215.73 -1774.69)"/><path class="cls-1" d="M2249.14,2124.32q-29.2,36.06-88.69,36.06t-88.69-36.06q-29.22-36.06-29.21-86.82,0-49.9,29.21-86.5t88.69-36.59q59.49,0,88.69,36.59t29.22,86.5Q2278.36,2088.26,2249.14,2124.32ZM2200.88,2091q14.19-18.81,14.18-53.48t-14.18-53.37q-14.18-18.7-40.64-18.71t-40.75,18.71q-14.28,18.72-14.29,53.37t14.29,53.48q14.3,18.81,40.75,18.81T2200.88,2091Z" transform="translate(-215.73 -1774.69)"/></svg>';
75
- const logoWithoutTextWhite = '<svg id="Layer_1" data-name="Layer 1" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 260 348" height="35px"><path id="Vector" d="M95.7053 40.2707C127.005 40.2707 157.022 52.6841 179.154 74.78C201.286 96.8759 213.719 126.844 213.719 158.093H254.056C254.056 70.7808 183.16 -4.57764e-05 95.7053 -4.57764e-05V40.2707Z" fill="#fff"/><path id="Vector_2" d="M42.8365 93.0614C58.3333 93.0614 73.6784 96.1087 87.9955 102.029C102.313 107.95 115.322 116.628 126.279 127.568C137.237 138.508 145.93 151.496 151.86 165.79C157.79 180.084 160.843 195.404 160.843 210.875H201.179C201.179 123.564 130.291 52.7906 42.8365 52.7906V93.0614Z" fill="#fff"/><path id="Vector_3" d="M158.367 305.005C127.07 305.003 97.056 292.59 74.926 270.496C52.796 248.402 40.3626 218.437 40.3604 187.191H0.0239563C0.0239563 274.503 70.9123 345.276 158.367 345.276V305.005Z" fill="#fff"/><path id="Vector_4" d="M211.219 252.239C195.722 252.239 180.376 249.191 166.059 243.27C151.741 237.349 138.732 228.67 127.774 217.729C116.816 206.788 108.123 193.799 102.194 179.505C96.2637 165.21 93.2121 149.889 93.2132 134.417H52.8687C52.8687 221.729 123.765 292.509 211.219 292.509V252.239Z" fill="#fff"/></g><defs><clipPath id="clip0_1_2"><rect width="254" height="345" fill="white"/></clipPath></defs></svg>';
76
- const logoWithoutTextBlack = '<svg id="Layer_1" data-name="Layer 1" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 260 348" height="35px"><path id="Vector" d="M95.7053 40.2707C127.005 40.2707 157.022 52.6841 179.154 74.78C201.286 96.8759 213.719 126.844 213.719 158.093H254.056C254.056 70.7808 183.16 -4.57764e-05 95.7053 -4.57764e-05V40.2707Z" fill="#000000"/><path id="Vector_2" d="M42.8365 93.0614C58.3333 93.0614 73.6784 96.1087 87.9955 102.029C102.313 107.95 115.322 116.628 126.279 127.568C137.237 138.508 145.93 151.496 151.86 165.79C157.79 180.084 160.843 195.404 160.843 210.875H201.179C201.179 123.564 130.291 52.7906 42.8365 52.7906V93.0614Z" fill="#000000"/><path id="Vector_3" d="M158.367 305.005C127.07 305.003 97.056 292.59 74.926 270.496C52.796 248.402 40.3626 218.437 40.3604 187.191H0.0239563C0.0239563 274.503 70.9123 345.276 158.367 345.276V305.005Z" fill="#000000"/><path id="Vector_4" d="M211.219 252.239C195.722 252.239 180.376 249.191 166.059 243.27C151.741 237.349 138.732 228.67 127.774 217.729C116.816 206.788 108.123 193.799 102.194 179.505C96.2637 165.21 93.2121 149.889 93.2132 134.417H52.8687C52.8687 221.729 123.765 292.509 211.219 292.509V252.239Z" fill="#000000"/></g><defs><clipPath id="clip0_1_2"><rect width="254" height="345" fill="white"/></clipPath></defs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J,GACJ,GACJ,CACT,CAAA;AACL,CAAC,CAAA;AAED,MAAM,iBAAiB,GACnB,olHAAolH,CAAA;AAExlH,MAAM,iBAAiB,GACnB,ilHAAilH,CAAA;AAErlH,MAAM,oBAAoB,GACtB,+uCAA+uC,CAAA;AAEnvC,MAAM,oBAAoB,GACtB,2vCAA2vC,CAAA"}
@@ -1,9 +0,0 @@
1
- import React, { ButtonHTMLAttributes } from 'react';
2
- interface CheckboxProps extends ButtonHTMLAttributes<HTMLButtonElement> {
3
- themeColor: 'light' | 'dark';
4
- checked: boolean;
5
- onChange: () => void;
6
- }
7
- declare const Checkbox: React.FC<CheckboxProps>;
8
- export default Checkbox;
9
- //# sourceMappingURL=Checkbox.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"Checkbox.d.ts","sourceRoot":"","sources":["../../src/components/Checkbox.tsx"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,EAAE,oBAAoB,EAAoC,MAAM,OAAO,CAAA;AAErF,UAAU,aAAc,SAAQ,oBAAoB,CAAC,iBAAiB,CAAC;IACnE,UAAU,EAAE,OAAO,GAAG,MAAM,CAAA;IAC5B,OAAO,EAAE,OAAO,CAAA;IAChB,QAAQ,EAAE,MAAM,IAAI,CAAA;CACvB;AAyBD,QAAA,MAAM,QAAQ,EAAE,KAAK,CAAC,EAAE,CAAC,aAAa,CA8BrC,CAAA;AACD,eAAe,QAAQ,CAAA"}
@@ -1,43 +0,0 @@
1
- import { jsx as _jsx } from "@emotion/react/jsx-runtime";
2
- import { css } from '@emotion/react';
3
- import { darkTheme, lightTheme } from './theme.js';
4
- import { useMemo, useState } from 'react';
5
- const checkboxBefore = css `{
6
- &:before {
7
- content: '""';
8
- position: absolute;
9
- height: 100%;
10
- width: 100%;
11
- }
12
- }`;
13
- const baseStyle = {
14
- width: '2.2em',
15
- height: '2.2em',
16
- top: 'auto',
17
- left: 'auto',
18
- opacity: '1',
19
- borderRadius: '12.5%',
20
- appearance: 'none',
21
- cursor: 'pointer',
22
- margin: '0',
23
- borderStyle: 'solid',
24
- borderWidth: '1px',
25
- };
26
- const Checkbox = ({ themeColor, onChange, checked }) => {
27
- const theme = useMemo(() => (themeColor === 'light' ? lightTheme : darkTheme), [themeColor]);
28
- const checkboxStyleBase = {
29
- ...baseStyle,
30
- border: `1px solid ${theme.palette.background.contrastText}`,
31
- };
32
- const [hover, setHover] = useState(false);
33
- const checkboxStyle = useMemo(() => {
34
- return {
35
- ...checkboxStyleBase,
36
- borderColor: hover ? theme.palette.background.contrastText : theme.palette.grey[400],
37
- appearance: checked ? 'auto' : 'none',
38
- };
39
- }, [hover, theme, checked]);
40
- return (_jsx("input", { onMouseEnter: () => setHover(true), onMouseLeave: () => setHover(false), css: checkboxBefore, type: 'checkbox', "aria-live": 'assertive', "aria-haspopup": 'true', onChange: onChange, checked: checked, style: checkboxStyle }));
41
- };
42
- export default Checkbox;
43
- //# sourceMappingURL=Checkbox.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"Checkbox.js","sourceRoot":"","sources":["../../src/components/Checkbox.tsx"],"names":[],"mappings":";AAEA,OAAO,EAAE,GAAG,EAAE,MAAM,gBAAgB,CAAA;AACpC,OAAO,EAAE,SAAS,EAAE,UAAU,EAAE,MAAM,YAAY,CAAA;AAClD,OAAc,EAAuC,OAAO,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAA;AAQrF,MAAM,cAAc,GAAG,GAAG,CAAA;;;;;;;EAOxB,CAAA;AAEF,MAAM,SAAS,GAAkB;IAC7B,KAAK,EAAE,OAAO;IACd,MAAM,EAAE,OAAO;IACf,GAAG,EAAE,MAAM;IACX,IAAI,EAAE,MAAM;IACZ,OAAO,EAAE,GAAG;IACZ,YAAY,EAAE,OAAO;IACrB,UAAU,EAAE,MAAM;IAClB,MAAM,EAAE,SAAS;IACjB,MAAM,EAAE,GAAG;IACX,WAAW,EAAE,OAAO;IACpB,WAAW,EAAE,KAAK;CACrB,CAAA;AAED,MAAM,QAAQ,GAA4B,C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: 'light' | 'dark';
3
- }
4
- export declare const LoadingSpinner: ({ themeColor }: LoadingSpinnerComponentProps) => import("@emotion/react/jsx-runtime").JSX.Element;
5
- export default LoadingSpinner;
6
- //# sourceMappingURL=LoadingSpinner.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"LoadingSpinner.d.ts","sourceRoot":"","sources":["../../src/components/LoadingSpinner.tsx"],"names":[],"mappings":"AAMA,MAAM,WAAW,4BAA4B;IACzC,UAAU,EAAE,OAAO,GAAG,MAAM,CAAA;CAC/B;AAED,eAAO,MAAM,cAAc,mBAAoB,4BAA4B,qDAqB1E,CAAA;AAED,eAAe,cAAc,CAAA"}
@@ -1,28 +0,0 @@
1
- import { jsx as _jsx } from "@emotion/react/jsx-runtime";
2
- import { darkTheme, lightTheme } from './theme.js';
3
- import { useMemo } from 'react';
4
- import styled from '@emotion/styled';
5
- export const LoadingSpinner = ({ themeColor }) => {
6
- const theme = useMemo(() => (themeColor === 'light' ? lightTheme : darkTheme), [themeColor]);
7
- const StyledDiv = styled.div `
8
- width: 2em;
9
- height: 2em;
10
- border: 4px solid ${theme.palette.background.contrastText};
11
- border-bottom-color: transparent;
12
- border-radius: 50%;
13
- display: inherit;
14
- box-sizing: border-box;
15
- animation: rotation 1s linear infinite;
16
- @keyframes rotation {
17
- 0% {
18
- transform: rotate(0deg);
19
- }
20
- 100% {
21
- transform: rotate(360deg);
22
- }
23
- }
24
- `;
25
- return _jsx(StyledDiv, {});
26
- };
27
- export default LoadingSpinner;
28
- //# sourceMappingURL=LoadingSpinner.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"LoadingSpinner.js","sourceRoot":"","sources":["../../src/components/LoadingSpinner.tsx"],"names":[],"mappings":";AAEA,OAAO,EAAE,SAAS,EAAE,UAAU,EAAE,MAAM,YAAY,CAAA;AAClD,OAAO,EAAE,OAAO,EAAE,MAAM,OAAO,CAAA;AAC/B,OAAO,MAAM,MAAM,iBAAiB,CAAA;AAMpC,MAAM,CAAC,MAAM,cAAc,GAAG,CAAC,EAAE,UAAU,EAAgC,EAAE,EAAE;IAC3E,MAAM,KAAK,GAAG,OAAO,CAAC,GAAG,EAAE,CAAC,CAAC,UAAU,KAAK,OAAO,CAAC,CAAC,CAAC,UAAU,CAAC,CAAC,CAAC,SAAS,CAAC,EAAE,CAAC,UAAU,CAAC,CAAC,CAAA;IAC5F,MAAM,SAAS,GAAG,MAAM,CAAC,GAAG,CAAA;;;4BAGJ,KAAK,CAAC,OAAO,CAAC,UAAU,CAAC,YAAY;;;;;;;;;;;;;;KAc5D,CAAA;IACD,OAAO,KAAC,SAAS,KAAa,CAAA;AAClC,CAAC,CAAA;AAED,eAAe,cAAc,CAAA"}
@@ -1,51 +0,0 @@
1
- export declare const lightTheme: {
2
- palette: {
3
- mode: string;
4
- primary: {
5
- main: string;
6
- contrastText: string;
7
- };
8
- background: {
9
- default: string;
10
- contrastText: string;
11
- };
12
- grey: {
13
- 0: string;
14
- 100: string;
15
- 200: string;
16
- 300: string;
17
- 400: string;
18
- 500: string;
19
- 600: string;
20
- 700: string;
21
- 800: string;
22
- 900: string;
23
- };
24
- };
25
- };
26
- export declare const darkTheme: {
27
- palette: {
28
- mode: string;
29
- primary: {
30
- main: string;
31
- contrastText: string;
32
- };
33
- background: {
34
- default: string;
35
- contrastText: string;
36
- };
37
- grey: {
38
- 0: string;
39
- 100: string;
40
- 200: string;
41
- 300: string;
42
- 400: string;
43
- 500: string;
44
- 600: string;
45
- 700: string;
46
- 800: string;
47
- 900: string;
48
- };
49
- };
50
- };
51
- //# sourceMappingURL=theme.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"theme.d.ts","sourceRoot":"","sources":["../../src/components/theme.ts"],"names":[],"mappings":"AA2BA,eAAO,MAAM,UAAU;;;;;;;;;;;;;;;;;;;;;;;;CAatB,CAAA;AAED,eAAO,MAAM,SAAS;;;;;;;;;;;;;;;;;;;;;;;;CAarB,CAAA"}
@@ -1,41 +0,0 @@
1
- const grey = {
2
- 0: '#fff',
3
- 100: '#f5f5f5',
4
- 200: '#eeeeee',
5
- 300: '#e0e0e0',
6
- 400: '#bdbdbd',
7
- 500: '#9e9e9e',
8
- 600: '#757575',
9
- 700: '#616161',
10
- 800: '#424242',
11
- 900: '#212121',
12
- };
13
- export const lightTheme = {
14
- palette: {
15
- mode: 'light',
16
- primary: {
17
- main: '#487DFA',
18
- contrastText: '#fff',
19
- },
20
- background: {
21
- default: '#fff',
22
- contrastText: '#000',
23
- },
24
- grey,
25
- },
26
- };
27
- export const darkTheme = {
28
- palette: {
29
- mode: 'dark',
30
- primary: {
31
- main: '#487DFA',
32
- contrastText: '#fff',
33
- },
34
- background: {
35
- default: '#303030',
36
- contrastText: '#fff',
37
- },
38
- grey,
39
- },
40
- };
41
- //# sourceMappingURL=theme.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"theme.js","sourceRoot":"","sources":["../../src/components/theme.ts"],"names":[],"mappings":"AAcA,MAAM,IAAI,GAAG;IACT,CAAC,EAAE,MAAM;IACT,GAAG,EAAE,SAAS;IACd,GAAG,EAAE,SAAS;IACd,GAAG,EAAE,SAAS;IACd,GAAG,EAAE,SAAS;IACd,GAAG,EAAE,SAAS;IACd,GAAG,EAAE,SAAS;IACd,GAAG,EAAE,SAAS;IACd,GAAG,EAAE,SAAS;IACd,GAAG,EAAE,SAAS;CACjB,CAAA;AAED,MAAM,CAAC,MAAM,UAAU,GAAG;IACtB,OAAO,EAAE;QACL,IAAI,EAAE,OAAO;QACb,OAAO,EAAE;YACL,IAAI,EAAE,SAAS;YACf,YAAY,EAAE,MAAM;SACvB;QACD,UAAU,EAAE;YACR,OAAO,EAAE,MAAM;YACf,YAAY,EAAE,MAAM;SACvB;QACD,IAAI;KACP;CACJ,CAAA;AAED,MAAM,CAAC,MAAM,SAAS,GAAG;IACrB,OAAO,EAAE;QACL,IAAI,EAAE,MAAM;QACZ,OAAO,EAAE;YACL,IAAI,EAAE,SAAS;YACf,YAAY,EAAE,MAAM;SACvB;QACD,UAAU,EAAE;YACR,OAAO,EAAE,SAAS;YAClB,YAAY,EAAE,MAAM;SACvB;QACD,IAAI;KACP;CACJ,CAAA"}