@ya-accelerators/nextjs-framework 0.0.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.
Files changed (318) hide show
  1. package/@types/general.d.ts +1 -0
  2. package/@types/image.d.ts +8 -0
  3. package/@types/next-auth.d.ts +18 -0
  4. package/dist/env.client.d.ts +3 -0
  5. package/dist/env.client.js +9 -0
  6. package/dist/env.client.js.map +1 -0
  7. package/dist/env.d.ts +6 -0
  8. package/dist/env.js +18 -0
  9. package/dist/env.js.map +1 -0
  10. package/dist/hooks/date/index.d.ts +11 -0
  11. package/dist/hooks/date/index.js +14 -0
  12. package/dist/hooks/date/index.js.map +1 -0
  13. package/dist/hooks/dispatch/index.d.ts +9 -0
  14. package/dist/hooks/dispatch/index.jsx +25 -0
  15. package/dist/hooks/dispatch/index.jsx.map +1 -0
  16. package/dist/hooks/index.d.ts +6 -0
  17. package/dist/hooks/index.js +7 -0
  18. package/dist/hooks/index.js.map +1 -0
  19. package/dist/hooks/loading/index.d.ts +10 -0
  20. package/dist/hooks/loading/index.jsx +22 -0
  21. package/dist/hooks/loading/index.jsx.map +1 -0
  22. package/dist/hooks/localStorage/index.d.ts +1 -0
  23. package/dist/hooks/localStorage/index.js +53 -0
  24. package/dist/hooks/localStorage/index.js.map +1 -0
  25. package/dist/hooks/modal/index.d.ts +26 -0
  26. package/dist/hooks/modal/index.jsx +63 -0
  27. package/dist/hooks/modal/index.jsx.map +1 -0
  28. package/dist/hooks/toast/index.d.ts +15 -0
  29. package/dist/hooks/toast/index.jsx +39 -0
  30. package/dist/hooks/toast/index.jsx.map +1 -0
  31. package/dist/i18n/index.d.ts +3 -0
  32. package/dist/i18n/index.js +40 -0
  33. package/dist/i18n/index.js.map +1 -0
  34. package/dist/i18n/strings/en-US.json +18 -0
  35. package/dist/i18n/strings/ja-JP.json +37 -0
  36. package/dist/index.d.ts +7 -0
  37. package/dist/index.js +8 -0
  38. package/dist/index.js.map +1 -0
  39. package/dist/lib/cookie/index.d.ts +9 -0
  40. package/dist/lib/cookie/index.js +66 -0
  41. package/dist/lib/cookie/index.js.map +1 -0
  42. package/dist/lib/index.d.ts +10 -0
  43. package/dist/lib/index.js +11 -0
  44. package/dist/lib/index.js.map +1 -0
  45. package/dist/lib/next-auth/index.d.ts +2 -0
  46. package/dist/lib/next-auth/index.js +62 -0
  47. package/dist/lib/next-auth/index.js.map +1 -0
  48. package/dist/lib/s3/index.d.ts +2 -0
  49. package/dist/lib/s3/index.js +17 -0
  50. package/dist/lib/s3/index.js.map +1 -0
  51. package/dist/lib/trpc/index.d.ts +8 -0
  52. package/dist/lib/trpc/index.js +32 -0
  53. package/dist/lib/trpc/index.js.map +1 -0
  54. package/dist/styles/globals.css +26 -0
  55. package/dist/styles/tailwind.config.d.ts +577 -0
  56. package/dist/styles/tailwind.config.js +671 -0
  57. package/dist/styles/tailwind.config.js.map +1 -0
  58. package/dist/styles/tailwind.config.ts +672 -0
  59. package/dist/tsconfig.tsbuildinfo +1 -0
  60. package/dist/ui/component/button/base.d.ts +27 -0
  61. package/dist/ui/component/button/base.jsx +54 -0
  62. package/dist/ui/component/button/base.jsx.map +1 -0
  63. package/dist/ui/component/button/colored/index.d.ts +11 -0
  64. package/dist/ui/component/button/colored/index.jsx +7 -0
  65. package/dist/ui/component/button/colored/index.jsx.map +1 -0
  66. package/dist/ui/component/button/image/index.d.ts +4 -0
  67. package/dist/ui/component/button/image/index.jsx +5 -0
  68. package/dist/ui/component/button/image/index.jsx.map +1 -0
  69. package/dist/ui/component/button/index.d.ts +18 -0
  70. package/dist/ui/component/button/index.jsx +25 -0
  71. package/dist/ui/component/button/index.jsx.map +1 -0
  72. package/dist/ui/component/button/text/index.d.ts +11 -0
  73. package/dist/ui/component/button/text/index.jsx +8 -0
  74. package/dist/ui/component/button/text/index.jsx.map +1 -0
  75. package/dist/ui/component/card/index.d.ts +12 -0
  76. package/dist/ui/component/card/index.jsx +20 -0
  77. package/dist/ui/component/card/index.jsx.map +1 -0
  78. package/dist/ui/component/icon/index.d.ts +7 -0
  79. package/dist/ui/component/icon/index.jsx +3 -0
  80. package/dist/ui/component/icon/index.jsx.map +1 -0
  81. package/dist/ui/component/index.d.ts +95 -0
  82. package/dist/ui/component/index.js +15 -0
  83. package/dist/ui/component/index.js.map +1 -0
  84. package/dist/ui/component/loading/index.d.ts +5 -0
  85. package/dist/ui/component/loading/index.jsx +27 -0
  86. package/dist/ui/component/loading/index.jsx.map +1 -0
  87. package/dist/ui/component/ssr/index.d.ts +5 -0
  88. package/dist/ui/component/ssr/index.jsx +11 -0
  89. package/dist/ui/component/ssr/index.jsx.map +1 -0
  90. package/dist/ui/component/typography/H1/index.d.ts +7 -0
  91. package/dist/ui/component/typography/H1/index.jsx +13 -0
  92. package/dist/ui/component/typography/H1/index.jsx.map +1 -0
  93. package/dist/ui/component/typography/H2/index.d.ts +7 -0
  94. package/dist/ui/component/typography/H2/index.jsx +13 -0
  95. package/dist/ui/component/typography/H2/index.jsx.map +1 -0
  96. package/dist/ui/component/typography/H3/index.d.ts +7 -0
  97. package/dist/ui/component/typography/H3/index.jsx +13 -0
  98. package/dist/ui/component/typography/H3/index.jsx.map +1 -0
  99. package/dist/ui/component/typography/H4/index.d.ts +7 -0
  100. package/dist/ui/component/typography/H4/index.jsx +13 -0
  101. package/dist/ui/component/typography/H4/index.jsx.map +1 -0
  102. package/dist/ui/component/typography/H5/index.d.ts +7 -0
  103. package/dist/ui/component/typography/H5/index.jsx +13 -0
  104. package/dist/ui/component/typography/H5/index.jsx.map +1 -0
  105. package/dist/ui/component/typography/H6/index.d.ts +7 -0
  106. package/dist/ui/component/typography/H6/index.jsx +13 -0
  107. package/dist/ui/component/typography/H6/index.jsx.map +1 -0
  108. package/dist/ui/component/typography/Label/index.d.ts +7 -0
  109. package/dist/ui/component/typography/Label/index.jsx +13 -0
  110. package/dist/ui/component/typography/Label/index.jsx.map +1 -0
  111. package/dist/ui/component/typography/LinkText/index.d.ts +8 -0
  112. package/dist/ui/component/typography/LinkText/index.jsx +14 -0
  113. package/dist/ui/component/typography/LinkText/index.jsx.map +1 -0
  114. package/dist/ui/component/typography/P/index.d.ts +7 -0
  115. package/dist/ui/component/typography/P/index.jsx +13 -0
  116. package/dist/ui/component/typography/P/index.jsx.map +1 -0
  117. package/dist/ui/component/typography/Pre/index.d.ts +7 -0
  118. package/dist/ui/component/typography/Pre/index.jsx +13 -0
  119. package/dist/ui/component/typography/Pre/index.jsx.map +1 -0
  120. package/dist/ui/component/typography/index.d.ts +54 -0
  121. package/dist/ui/component/typography/index.jsx +23 -0
  122. package/dist/ui/component/typography/index.jsx.map +1 -0
  123. package/dist/ui/composite/button/index.d.ts +8 -0
  124. package/dist/ui/composite/button/index.jsx +45 -0
  125. package/dist/ui/composite/button/index.jsx.map +1 -0
  126. package/dist/ui/composite/dropdown/index.d.ts +12 -0
  127. package/dist/ui/composite/dropdown/index.jsx +102 -0
  128. package/dist/ui/composite/dropdown/index.jsx.map +1 -0
  129. package/dist/ui/composite/index.d.ts +342 -0
  130. package/dist/ui/composite/index.js +13 -0
  131. package/dist/ui/composite/index.js.map +1 -0
  132. package/dist/ui/composite/input/address/index.d.ts +33 -0
  133. package/dist/ui/composite/input/address/index.jsx +132 -0
  134. package/dist/ui/composite/input/address/index.jsx.map +1 -0
  135. package/dist/ui/composite/input/address/map.d.ts +64 -0
  136. package/dist/ui/composite/input/address/map.jsx +111 -0
  137. package/dist/ui/composite/input/address/map.jsx.map +1 -0
  138. package/dist/ui/composite/input/address/utils.d.ts +23 -0
  139. package/dist/ui/composite/input/address/utils.js +63 -0
  140. package/dist/ui/composite/input/address/utils.js.map +1 -0
  141. package/dist/ui/composite/input/checkbox/index.d.ts +22 -0
  142. package/dist/ui/composite/input/checkbox/index.jsx +38 -0
  143. package/dist/ui/composite/input/checkbox/index.jsx.map +1 -0
  144. package/dist/ui/composite/input/datePicker/index.d.ts +19 -0
  145. package/dist/ui/composite/input/datePicker/index.jsx +100 -0
  146. package/dist/ui/composite/input/datePicker/index.jsx.map +1 -0
  147. package/dist/ui/composite/input/dateRange/index.d.ts +14 -0
  148. package/dist/ui/composite/input/dateRange/index.jsx +46 -0
  149. package/dist/ui/composite/input/dateRange/index.jsx.map +1 -0
  150. package/dist/ui/composite/input/dateTimePicker/index.d.ts +15 -0
  151. package/dist/ui/composite/input/dateTimePicker/index.jsx +74 -0
  152. package/dist/ui/composite/input/dateTimePicker/index.jsx.map +1 -0
  153. package/dist/ui/composite/input/dateTimeRange/index.d.ts +14 -0
  154. package/dist/ui/composite/input/dateTimeRange/index.jsx +88 -0
  155. package/dist/ui/composite/input/dateTimeRange/index.jsx.map +1 -0
  156. package/dist/ui/composite/input/index.d.ts +216 -0
  157. package/dist/ui/composite/input/index.js +35 -0
  158. package/dist/ui/composite/input/index.js.map +1 -0
  159. package/dist/ui/composite/input/list/index.d.ts +20 -0
  160. package/dist/ui/composite/input/list/index.jsx +30 -0
  161. package/dist/ui/composite/input/list/index.jsx.map +1 -0
  162. package/dist/ui/composite/input/radio/index.d.ts +14 -0
  163. package/dist/ui/composite/input/radio/index.jsx +34 -0
  164. package/dist/ui/composite/input/radio/index.jsx.map +1 -0
  165. package/dist/ui/composite/input/search/index.d.ts +5 -0
  166. package/dist/ui/composite/input/search/index.jsx +38 -0
  167. package/dist/ui/composite/input/search/index.jsx.map +1 -0
  168. package/dist/ui/composite/input/select/ClearIndicator/index.d.ts +4 -0
  169. package/dist/ui/composite/input/select/ClearIndicator/index.jsx +8 -0
  170. package/dist/ui/composite/input/select/ClearIndicator/index.jsx.map +1 -0
  171. package/dist/ui/composite/input/select/Control/index.d.ts +4 -0
  172. package/dist/ui/composite/input/select/Control/index.jsx +23 -0
  173. package/dist/ui/composite/input/select/Control/index.jsx.map +1 -0
  174. package/dist/ui/composite/input/select/DropdownIndicator/index.d.ts +4 -0
  175. package/dist/ui/composite/input/select/DropdownIndicator/index.jsx +8 -0
  176. package/dist/ui/composite/input/select/DropdownIndicator/index.jsx.map +1 -0
  177. package/dist/ui/composite/input/select/GroupHeading/index.d.ts +4 -0
  178. package/dist/ui/composite/input/select/GroupHeading/index.jsx +9 -0
  179. package/dist/ui/composite/input/select/GroupHeading/index.jsx.map +1 -0
  180. package/dist/ui/composite/input/select/Input/index.d.ts +4 -0
  181. package/dist/ui/composite/input/select/Input/index.jsx +7 -0
  182. package/dist/ui/composite/input/select/Input/index.jsx.map +1 -0
  183. package/dist/ui/composite/input/select/Menu/index.d.ts +4 -0
  184. package/dist/ui/composite/input/select/Menu/index.jsx +19 -0
  185. package/dist/ui/composite/input/select/Menu/index.jsx.map +1 -0
  186. package/dist/ui/composite/input/select/MultiValue/index.d.ts +4 -0
  187. package/dist/ui/composite/input/select/MultiValue/index.jsx +15 -0
  188. package/dist/ui/composite/input/select/MultiValue/index.jsx.map +1 -0
  189. package/dist/ui/composite/input/select/Option/index.d.ts +4 -0
  190. package/dist/ui/composite/input/select/Option/index.jsx +79 -0
  191. package/dist/ui/composite/input/select/Option/index.jsx.map +1 -0
  192. package/dist/ui/composite/input/select/Placeholder/index.d.ts +4 -0
  193. package/dist/ui/composite/input/select/Placeholder/index.jsx +7 -0
  194. package/dist/ui/composite/input/select/Placeholder/index.jsx.map +1 -0
  195. package/dist/ui/composite/input/select/SelectContainer/index.d.ts +4 -0
  196. package/dist/ui/composite/input/select/SelectContainer/index.jsx +40 -0
  197. package/dist/ui/composite/input/select/SelectContainer/index.jsx.map +1 -0
  198. package/dist/ui/composite/input/select/SingleValue/index.d.ts +4 -0
  199. package/dist/ui/composite/input/select/SingleValue/index.jsx +17 -0
  200. package/dist/ui/composite/input/select/SingleValue/index.jsx.map +1 -0
  201. package/dist/ui/composite/input/select/index.d.ts +37 -0
  202. package/dist/ui/composite/input/select/index.jsx +242 -0
  203. package/dist/ui/composite/input/select/index.jsx.map +1 -0
  204. package/dist/ui/composite/input/select/types.d.ts +16 -0
  205. package/dist/ui/composite/input/select/types.js +6 -0
  206. package/dist/ui/composite/input/select/types.js.map +1 -0
  207. package/dist/ui/composite/input/text/index.d.ts +15 -0
  208. package/dist/ui/composite/input/text/index.jsx +40 -0
  209. package/dist/ui/composite/input/text/index.jsx.map +1 -0
  210. package/dist/ui/composite/input/textarea/index.d.ts +11 -0
  211. package/dist/ui/composite/input/textarea/index.jsx +62 -0
  212. package/dist/ui/composite/input/textarea/index.jsx.map +1 -0
  213. package/dist/ui/composite/input/timePicker/index.d.ts +13 -0
  214. package/dist/ui/composite/input/timePicker/index.jsx +36 -0
  215. package/dist/ui/composite/input/timePicker/index.jsx.map +1 -0
  216. package/dist/ui/composite/input/timeRange/index.d.ts +16 -0
  217. package/dist/ui/composite/input/timeRange/index.jsx +54 -0
  218. package/dist/ui/composite/input/timeRange/index.jsx.map +1 -0
  219. package/dist/ui/composite/input/weekDaysSelector/index.d.ts +11 -0
  220. package/dist/ui/composite/input/weekDaysSelector/index.jsx +39 -0
  221. package/dist/ui/composite/input/weekDaysSelector/index.jsx.map +1 -0
  222. package/dist/ui/composite/input/weekdayPicker/index.d.ts +13 -0
  223. package/dist/ui/composite/input/weekdayPicker/index.jsx +49 -0
  224. package/dist/ui/composite/input/weekdayPicker/index.jsx.map +1 -0
  225. package/dist/ui/composite/label/index.d.ts +11 -0
  226. package/dist/ui/composite/label/index.jsx +18 -0
  227. package/dist/ui/composite/label/index.jsx.map +1 -0
  228. package/dist/ui/composite/pageTitle/index.d.ts +18 -0
  229. package/dist/ui/composite/pageTitle/index.jsx +62 -0
  230. package/dist/ui/composite/pageTitle/index.jsx.map +1 -0
  231. package/dist/ui/functional/index.d.ts +10 -0
  232. package/dist/ui/functional/index.js +9 -0
  233. package/dist/ui/functional/index.js.map +1 -0
  234. package/dist/ui/functional/notFound/index.d.ts +1 -0
  235. package/dist/ui/functional/notFound/index.jsx +13 -0
  236. package/dist/ui/functional/notFound/index.jsx.map +1 -0
  237. package/dist/ui/functional/signInForm/index.d.ts +4 -0
  238. package/dist/ui/functional/signInForm/index.jsx +45 -0
  239. package/dist/ui/functional/signInForm/index.jsx.map +1 -0
  240. package/dist/ui/functional/signOutForm/index.d.ts +3 -0
  241. package/dist/ui/functional/signOutForm/index.jsx +29 -0
  242. package/dist/ui/functional/signOutForm/index.jsx.map +1 -0
  243. package/dist/ui/index.d.ts +6 -0
  244. package/dist/ui/index.js +7 -0
  245. package/dist/ui/index.js.map +1 -0
  246. package/dist/ui/layout/app/component.d.ts +59 -0
  247. package/dist/ui/layout/app/component.jsx +224 -0
  248. package/dist/ui/layout/app/component.jsx.map +1 -0
  249. package/dist/ui/layout/app/content/index.d.ts +9 -0
  250. package/dist/ui/layout/app/content/index.jsx +18 -0
  251. package/dist/ui/layout/app/content/index.jsx.map +1 -0
  252. package/dist/ui/layout/app/index.d.ts +18 -0
  253. package/dist/ui/layout/app/index.jsx +40 -0
  254. package/dist/ui/layout/app/index.jsx.map +1 -0
  255. package/dist/ui/layout/form/index.d.ts +68 -0
  256. package/dist/ui/layout/form/index.jsx +558 -0
  257. package/dist/ui/layout/form/index.jsx.map +1 -0
  258. package/dist/ui/layout/index.d.ts +356 -0
  259. package/dist/ui/layout/index.js +19 -0
  260. package/dist/ui/layout/index.js.map +1 -0
  261. package/dist/ui/layout/modal/index.d.ts +7 -0
  262. package/dist/ui/layout/modal/index.jsx +11 -0
  263. package/dist/ui/layout/modal/index.jsx.map +1 -0
  264. package/dist/ui/layout/object/index.d.ts +30 -0
  265. package/dist/ui/layout/object/index.jsx +145 -0
  266. package/dist/ui/layout/object/index.jsx.map +1 -0
  267. package/dist/ui/layout/root/index.d.ts +10 -0
  268. package/dist/ui/layout/root/index.jsx +31 -0
  269. package/dist/ui/layout/root/index.jsx.map +1 -0
  270. package/dist/ui/layout/root/provider/index.d.ts +7 -0
  271. package/dist/ui/layout/root/provider/index.jsx +26 -0
  272. package/dist/ui/layout/root/provider/index.jsx.map +1 -0
  273. package/dist/ui/layout/tab/component.d.ts +4 -0
  274. package/dist/ui/layout/tab/component.jsx +16 -0
  275. package/dist/ui/layout/tab/component.jsx.map +1 -0
  276. package/dist/ui/layout/tab/content/index.d.ts +8 -0
  277. package/dist/ui/layout/tab/content/index.jsx +8 -0
  278. package/dist/ui/layout/tab/content/index.jsx.map +1 -0
  279. package/dist/ui/layout/tab/index.d.ts +11 -0
  280. package/dist/ui/layout/tab/index.jsx +25 -0
  281. package/dist/ui/layout/tab/index.jsx.map +1 -0
  282. package/dist/ui/layout/table/index.d.ts +33 -0
  283. package/dist/ui/layout/table/index.jsx +283 -0
  284. package/dist/ui/layout/table/index.jsx.map +1 -0
  285. package/dist/ui/layout/toast/index.d.ts +7 -0
  286. package/dist/ui/layout/toast/index.jsx +18 -0
  287. package/dist/ui/layout/toast/index.jsx.map +1 -0
  288. package/dist/ui/theme/border/index.d.ts +28 -0
  289. package/dist/ui/theme/border/index.js +67 -0
  290. package/dist/ui/theme/border/index.js.map +1 -0
  291. package/dist/ui/theme/color/index.d.ts +32 -0
  292. package/dist/ui/theme/color/index.js +106 -0
  293. package/dist/ui/theme/color/index.js.map +1 -0
  294. package/dist/ui/theme/index.d.ts +4 -0
  295. package/dist/ui/theme/index.js +5 -0
  296. package/dist/ui/theme/index.js.map +1 -0
  297. package/dist/ui/theme/rounded/index.d.ts +9 -0
  298. package/dist/ui/theme/rounded/index.js +14 -0
  299. package/dist/ui/theme/rounded/index.js.map +1 -0
  300. package/dist/ui/theme/size/index.d.ts +15 -0
  301. package/dist/ui/theme/size/index.js +55 -0
  302. package/dist/ui/theme/size/index.js.map +1 -0
  303. package/dist/ui/types/index.d.ts +113 -0
  304. package/dist/ui/types/index.js +33 -0
  305. package/dist/ui/types/index.js.map +1 -0
  306. package/dist/util/client.d.ts +2 -0
  307. package/dist/util/client.js +4 -0
  308. package/dist/util/client.js.map +1 -0
  309. package/dist/util/date/impl.d.ts +7 -0
  310. package/dist/util/date/impl.js +22 -0
  311. package/dist/util/date/impl.js.map +1 -0
  312. package/dist/util/date/index.d.ts +17 -0
  313. package/dist/util/date/index.js +16 -0
  314. package/dist/util/date/index.js.map +1 -0
  315. package/dist/util/index.d.ts +17 -0
  316. package/dist/util/index.js +143 -0
  317. package/dist/util/index.js.map +1 -0
  318. package/package.json +62 -0
@@ -0,0 +1,342 @@
1
+ import * as button from './button';
2
+ export declare const Composite: {
3
+ PageTitle: ({ routes, title, actions, back, keepRoutesSpace, showTitle, className, }: {
4
+ routes?: {
5
+ label: string;
6
+ href: string;
7
+ }[];
8
+ title: string;
9
+ actions?: {
10
+ path: string;
11
+ button?: import("react").ComponentProps<typeof button.Button>;
12
+ content?: import("react").ReactNode;
13
+ }[];
14
+ back?: boolean;
15
+ keepRoutesSpace?: boolean;
16
+ showTitle?: boolean;
17
+ className?: string;
18
+ }) => import("react").JSX.Element;
19
+ Label: ({ color, size, rounded, border, label, icon, className, ...props }: {
20
+ color: import("..").ColorTypes;
21
+ size?: import("..").ControlSize;
22
+ rounded?: import("..").Rounded;
23
+ border?: import("..").BorderProps;
24
+ label?: string;
25
+ icon?: import("..").IconType;
26
+ } & Omit<import("react").ComponentProps<"label">, "color">) => import("react").JSX.Element;
27
+ Input: {
28
+ WeekDaysSelector: ({ name, short, defaultValue, onChange, disabled, className, error, }: {
29
+ name: string;
30
+ short?: boolean;
31
+ defaultValue?: import("../..").Weekday | import("../..").Weekday[] | null;
32
+ onChange?: (value: import("../..").Weekday | import("../..").Weekday[]) => void;
33
+ disabled?: boolean;
34
+ className?: string;
35
+ error?: boolean;
36
+ }) => import("react").JSX.Element;
37
+ WeekdayPicker: ({ name, short, defaultValue, onChange, disabled, className, required, multiSelect, error, ...props }: {
38
+ name: string;
39
+ short?: boolean;
40
+ defaultValue?: import("../..").Weekday | import("../..").Weekday[] | null;
41
+ onChange?: (value: import("../..").Weekday | import("../..").Weekday[]) => void;
42
+ disabled?: boolean;
43
+ className?: string;
44
+ required?: boolean;
45
+ multiSelect?: boolean;
46
+ error?: boolean;
47
+ }) => import("react").JSX.Element;
48
+ TimeRange: ({ defaultValue, name, disabled, error, required, stepMinutes, onChange, ...props }: Omit<import("react").ComponentProps<typeof import("./input/timePicker").TimePicker>, "defaultValue" | "onChange"> & {
49
+ defaultValue?: {
50
+ start?: string | null;
51
+ end?: string | null;
52
+ };
53
+ error?: boolean;
54
+ required?: boolean;
55
+ disabled?: boolean;
56
+ stepMinutes?: number;
57
+ onChange?: (value: {
58
+ start?: string | null;
59
+ end?: string | null;
60
+ }) => void;
61
+ }) => import("react").JSX.Element;
62
+ TimePicker: ({ min, max, stepMinutes, defaultValue, value, selectRef, ...props }: {
63
+ min?: string | null;
64
+ max?: string | null;
65
+ stepMinutes?: number;
66
+ defaultValue?: string | null;
67
+ value?: string | null;
68
+ selectRef?: React.RefObject<import("react-select").SelectInstance<import("./input/select/types").SelectOption, boolean> | null>;
69
+ } & Omit<import("react").ComponentProps<typeof import("./input/select").Select>, "options" | "defaultValue">) => import("react").JSX.Element;
70
+ TextArea: ({ name, color, rounded, disabled, className, required, defaultValue, error, rows, ...props }: {
71
+ name: string;
72
+ color?: import("..").TextColorTypes;
73
+ rounded?: import("..").Rounded;
74
+ required?: boolean;
75
+ defaultValue?: string | number | readonly string[] | undefined | null;
76
+ error?: boolean;
77
+ } & Omit<import("react").ComponentProps<"textarea">, "name" | "color" | "defaultValue">) => import("react").JSX.Element;
78
+ Text: ({ name, rounded, focused, color, icon, className, defaultValue, error, inputClassName, isClearable, ...props }: {
79
+ name: string;
80
+ rounded?: import("..").Rounded;
81
+ focused?: boolean;
82
+ color?: import("..").TextColorTypes;
83
+ icon?: import("..").IconType;
84
+ defaultValue?: string | number | readonly string[] | undefined | null;
85
+ error?: boolean;
86
+ inputClassName?: string;
87
+ isClearable?: boolean;
88
+ } & Omit<import("react").ComponentProps<"input">, "name" | "color" | "defaultValue">) => import("react").JSX.Element;
89
+ useScrollToSelectedOnOpen: (args: {
90
+ menuOpen: boolean;
91
+ portalEl?: HTMLElement;
92
+ instanceId: string;
93
+ }) => void;
94
+ Select: import("react").ForwardRefExoticComponent<{
95
+ name: string;
96
+ className?: string;
97
+ options: import("react-select").OptionsOrGroups<import("./input/select/types").SelectOption, import("react-select").GroupBase<import("./input/select/types").SelectOption>>;
98
+ defaultValue?: string | number | readonly string[] | undefined | null;
99
+ value?: string;
100
+ onChange?: (value: string) => void;
101
+ disabled?: boolean;
102
+ required?: boolean;
103
+ isMulti?: boolean;
104
+ isSearchable?: boolean;
105
+ isClearable?: boolean;
106
+ placeholder?: string;
107
+ noOptionsMessage?: string;
108
+ showDividerBetweenOptions?: boolean;
109
+ indentPadding?: number;
110
+ autoFocus?: boolean;
111
+ rounded?: import("..").Rounded;
112
+ error?: boolean;
113
+ } & import("react").RefAttributes<import("react-select").SelectInstance<import("./input/select/types").SelectOption, boolean>>>;
114
+ Search: ({ value, onUpdate, className, }: {
115
+ value?: string;
116
+ onUpdate: (value: string) => void;
117
+ className?: string;
118
+ }) => import("react").JSX.Element;
119
+ Radio: ({ orientation, name, options, value, defaultValue, onChange, disabled, required, }: {
120
+ orientation: "horizontal" | "vertical";
121
+ name: string;
122
+ options: {
123
+ value: string;
124
+ label: string;
125
+ disabled?: boolean;
126
+ }[];
127
+ value?: string;
128
+ defaultValue?: string | null;
129
+ onChange?: (value: string) => void;
130
+ disabled?: boolean;
131
+ required?: boolean;
132
+ }) => import("react").JSX.Element;
133
+ List: ({ name, rounded, defaultList, minListLength, maxListLength, valueLength, isFirstItem, input, }: {
134
+ name: string;
135
+ rounded?: import("..").Rounded;
136
+ defaultList: string[][];
137
+ minListLength?: number;
138
+ maxListLength?: number;
139
+ valueLength: number;
140
+ isFirstItem: boolean;
141
+ input: (props: {
142
+ name: string;
143
+ autoFocus: boolean;
144
+ values: string[];
145
+ onChange: (index: number, value: string) => void;
146
+ }) => {
147
+ node: import("react").ReactNode;
148
+ disabled?: boolean;
149
+ };
150
+ }) => import("react").JSX.Element;
151
+ DateTimeRange: ({ defaultValue, name, disabled, error, stepMinutes, onChange, ...props }: Omit<import("react").ComponentProps<typeof import("./input/dateTimePicker").DateTimePicker>, "defaultValue" | "onChange"> & {
152
+ defaultValue?: {
153
+ start?: Date;
154
+ end?: Date;
155
+ };
156
+ error?: boolean;
157
+ stepMinutes?: number;
158
+ onChange?: (value: {
159
+ start?: Date;
160
+ end?: Date;
161
+ }) => void;
162
+ }) => import("react").JSX.Element;
163
+ DateTimePicker: ({ name, defaultValue, value, min, max, onChange, disabled, required, error, stepMinutes, timeSelectRef, }: {
164
+ name: string;
165
+ defaultValue?: Date;
166
+ value?: Date;
167
+ min?: Date;
168
+ max?: Date;
169
+ onChange?: (value: Date) => void;
170
+ disabled?: boolean;
171
+ required?: boolean;
172
+ error?: boolean;
173
+ stepMinutes?: number;
174
+ timeSelectRef?: React.RefObject<import("react-select").SelectInstance<import("./input/select/types").SelectOption, boolean> | null>;
175
+ }) => import("react").JSX.Element;
176
+ DateRange: ({ defaultValue, name, disabled, error, stepDays, onChange, ...props }: Omit<import("react").ComponentProps<typeof import("./input/datePicker").DatePicker>, "defaultValue" | "onChange"> & {
177
+ defaultValue?: {
178
+ start?: Date;
179
+ end?: Date;
180
+ };
181
+ error?: boolean;
182
+ stepDays?: number;
183
+ onChange?: (value: {
184
+ start?: Date;
185
+ end?: Date;
186
+ }) => void;
187
+ }) => import("react").JSX.Element;
188
+ DatePicker: (props: Parameters<({ name, rounded, placement, defaultValue, value, min, max, onChange, disabled, className, required, error, autoFocus, }: {
189
+ name: string;
190
+ rounded?: import("..").Rounded;
191
+ placement?: "top" | "right" | "bottom" | "left" | "top-start" | "top-end" | "right-start" | "right-end" | "bottom-start" | "bottom-end" | "left-start" | "left-end";
192
+ defaultValue?: Date;
193
+ value?: Date;
194
+ min?: Date;
195
+ max?: Date;
196
+ onChange?: (value?: Date) => void;
197
+ disabled?: boolean;
198
+ className?: string;
199
+ required?: boolean;
200
+ error?: boolean;
201
+ autoFocus?: boolean;
202
+ }) => import("react").JSX.Element>[0]) => import("react").JSX.Element;
203
+ Checkbox: ({ orientation, name, options, defaultValue, onChange, disabled, error, }: {
204
+ orientation: "horizontal" | "vertical";
205
+ name: string;
206
+ options: {
207
+ value: string;
208
+ label: string;
209
+ disabled?: boolean;
210
+ }[];
211
+ defaultValue?: string[] | null;
212
+ onChange?: (values: string[]) => void;
213
+ disabled?: boolean;
214
+ error?: boolean;
215
+ }) => import("react").JSX.Element;
216
+ CheckboxItem: ({ name, checked, onClick, value, label, disabled, error, }: {
217
+ name: string;
218
+ checked: boolean;
219
+ onClick: () => void;
220
+ value: string;
221
+ label: string;
222
+ disabled?: boolean;
223
+ error?: boolean;
224
+ }) => import("react").JSX.Element;
225
+ Address: ({ name, rounded, defaultValue, countryCode, onSearch, onChange, disabled, required, className, googleMapsApiKey, }: {
226
+ name: string;
227
+ rounded?: import("..").Rounded;
228
+ defaultValue?: import("./input/address").AddressValue | null;
229
+ countryCode?: string;
230
+ onSearch?: (result: import("./input/address").AddressValue | null) => void;
231
+ onChange?: (value: import("./input/address").AddressValue) => void;
232
+ disabled?: boolean;
233
+ required?: boolean;
234
+ className?: string;
235
+ googleMapsApiKey?: string;
236
+ }) => import("react").JSX.Element;
237
+ };
238
+ DropDown: ({ button, content, position, menuRounded, menuClassName, disabled, }: {
239
+ button: import("react").ComponentProps<({ variant, ...props }: ({
240
+ variant: "colored";
241
+ } & import("react").ComponentProps<typeof import("../component/button/colored").Colored>) | ({
242
+ variant: "text";
243
+ } & import("react").ComponentProps<typeof import("../component/button/text").Text>) | ({
244
+ variant: "image";
245
+ } & import("react").ComponentProps<typeof import("../component/button/image").Imaged>)) => import("react").JSX.Element>;
246
+ content: import("react").ReactNode | (import("react").ComponentProps<typeof import("./button").Button> | "divider")[];
247
+ position: "left" | "center" | "right";
248
+ menuRounded?: import("..").Rounded;
249
+ menuClassName?: string;
250
+ disabled?: boolean;
251
+ }) => import("react").JSX.Element | null;
252
+ Button: (buttonProps: ({
253
+ variant: "colored";
254
+ } & {
255
+ color: import("..").ColorTypes;
256
+ container?: boolean;
257
+ } & Omit<{
258
+ size?: import("..").ControlSize;
259
+ rounded?: import("..").Rounded;
260
+ border?: import("..").BorderProps;
261
+ label?: string;
262
+ icon?: import("..").IconType;
263
+ image?: Omit<import("react").ComponentProps<typeof import("next/image").default>, "alt" | "fill" | "width" | "height"> & {
264
+ square?: boolean;
265
+ };
266
+ disabled?: boolean;
267
+ } & Omit<Omit<import("react").AnchorHTMLAttributes<HTMLAnchorElement>, keyof import("next/link").LinkProps<any>> & import("next/link").LinkProps<any> & {
268
+ children?: React.ReactNode | undefined;
269
+ } & import("react").RefAttributes<HTMLAnchorElement>, "color" | "disabled" | "children" | "onClick">, "image">) | ({
270
+ variant: "text";
271
+ } & {
272
+ color?: import("..").TextColorTypes;
273
+ container?: boolean;
274
+ } & Omit<{
275
+ size?: import("..").ControlSize;
276
+ rounded?: import("..").Rounded;
277
+ border?: import("..").BorderProps;
278
+ label?: string;
279
+ icon?: import("..").IconType;
280
+ image?: Omit<import("react").ComponentProps<typeof import("next/image").default>, "alt" | "fill" | "width" | "height"> & {
281
+ square?: boolean;
282
+ };
283
+ disabled?: boolean;
284
+ } & Omit<Omit<import("react").AnchorHTMLAttributes<HTMLAnchorElement>, keyof import("next/link").LinkProps<any>> & import("next/link").LinkProps<any> & {
285
+ children?: React.ReactNode | undefined;
286
+ } & import("react").RefAttributes<HTMLAnchorElement>, "color" | "disabled" | "children" | "onClick">, "image">) | ({
287
+ variant: "image";
288
+ } & Omit<{
289
+ size?: import("..").ControlSize;
290
+ rounded?: import("..").Rounded;
291
+ border?: import("..").BorderProps;
292
+ label?: string;
293
+ icon?: import("..").IconType;
294
+ image?: Omit<import("react").ComponentProps<typeof import("next/image").default>, "alt" | "fill" | "width" | "height"> & {
295
+ square?: boolean;
296
+ };
297
+ disabled?: boolean;
298
+ } & Omit<Omit<import("react").AnchorHTMLAttributes<HTMLAnchorElement>, keyof import("next/link").LinkProps<any>> & import("next/link").LinkProps<any> & {
299
+ children?: React.ReactNode | undefined;
300
+ } & import("react").RefAttributes<HTMLAnchorElement>, "color" | "disabled" | "children" | "onClick">, "icon">) | ((({
301
+ variant: "colored";
302
+ } & {
303
+ color: import("..").ColorTypes;
304
+ container?: boolean;
305
+ } & Omit<{
306
+ size?: import("..").ControlSize;
307
+ rounded?: import("..").Rounded;
308
+ border?: import("..").BorderProps;
309
+ label?: string;
310
+ icon?: import("..").IconType;
311
+ image?: Omit<import("react").ComponentProps<typeof import("next/image").default>, "alt" | "fill" | "width" | "height"> & {
312
+ square?: boolean;
313
+ };
314
+ } & Omit<import("react").DetailedHTMLProps<import("react").ButtonHTMLAttributes<HTMLButtonElement>, HTMLButtonElement>, "color" | "children">, "image">) | ({
315
+ variant: "text";
316
+ } & {
317
+ color?: import("..").TextColorTypes;
318
+ container?: boolean;
319
+ } & Omit<{
320
+ size?: import("..").ControlSize;
321
+ rounded?: import("..").Rounded;
322
+ border?: import("..").BorderProps;
323
+ label?: string;
324
+ icon?: import("..").IconType;
325
+ image?: Omit<import("react").ComponentProps<typeof import("next/image").default>, "alt" | "fill" | "width" | "height"> & {
326
+ square?: boolean;
327
+ };
328
+ } & Omit<import("react").DetailedHTMLProps<import("react").ButtonHTMLAttributes<HTMLButtonElement>, HTMLButtonElement>, "color" | "children">, "image">) | ({
329
+ variant: "image";
330
+ } & Omit<{
331
+ size?: import("..").ControlSize;
332
+ rounded?: import("..").Rounded;
333
+ border?: import("..").BorderProps;
334
+ label?: string;
335
+ icon?: import("..").IconType;
336
+ image?: Omit<import("react").ComponentProps<typeof import("next/image").default>, "alt" | "fill" | "width" | "height"> & {
337
+ square?: boolean;
338
+ };
339
+ } & Omit<import("react").DetailedHTMLProps<import("react").ButtonHTMLAttributes<HTMLButtonElement>, HTMLButtonElement>, "color" | "children">, "icon">)) & {
340
+ action?: import("../..").ModalProps;
341
+ })) => import("react").JSX.Element;
342
+ };
@@ -0,0 +1,13 @@
1
+ import * as button from './button';
2
+ import * as dropdown from './dropdown';
3
+ import * as input from './input';
4
+ import * as label from './label';
5
+ import * as pageTitle from './pageTitle';
6
+ export const Composite = {
7
+ ...button,
8
+ ...dropdown,
9
+ ...input,
10
+ ...label,
11
+ ...pageTitle,
12
+ };
13
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/ui/composite/index.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,MAAM,UAAU,CAAA;AAClC,OAAO,KAAK,QAAQ,MAAM,YAAY,CAAA;AACtC,OAAO,KAAK,KAAK,MAAM,SAAS,CAAA;AAChC,OAAO,KAAK,KAAK,MAAM,SAAS,CAAA;AAChC,OAAO,KAAK,SAAS,MAAM,aAAa,CAAA;AAExC,MAAM,CAAC,MAAM,SAAS,GAAG;IACvB,GAAG,MAAM;IACT,GAAG,QAAQ;IACX,GAAG,KAAK;IACR,GAAG,KAAK;IACR,GAAG,SAAS;CACb,CAAA"}
@@ -0,0 +1,33 @@
1
+ import { Rounded } from '../../../theme';
2
+ export interface AddressValue {
3
+ /** ID */
4
+ id?: string | null;
5
+ /** ZipCode */
6
+ zipCode: string;
7
+ /** Region (都道府県 in Japan) */
8
+ region: string;
9
+ /** City (市区町村 in Japan) */
10
+ city: string;
11
+ /** Address Line1 (町名・番地 in Japan) */
12
+ line1: string;
13
+ /** Address Line2 (建物名・部屋番号 in Japan) */
14
+ line2?: string | null;
15
+ /** Address Line3 */
16
+ line3?: string | null;
17
+ /** Latitude */
18
+ lat?: number | null;
19
+ /** Longitude */
20
+ lng?: number | null;
21
+ }
22
+ export declare const Address: ({ name, rounded, defaultValue, countryCode, onSearch, onChange, disabled, required, className, googleMapsApiKey, }: {
23
+ name: string;
24
+ rounded?: Rounded;
25
+ defaultValue?: AddressValue | null;
26
+ countryCode?: string;
27
+ onSearch?: (result: AddressValue | null) => void;
28
+ onChange?: (value: AddressValue) => void;
29
+ disabled?: boolean;
30
+ required?: boolean;
31
+ className?: string;
32
+ googleMapsApiKey?: string;
33
+ }) => import("react").JSX.Element;
@@ -0,0 +1,132 @@
1
+ 'use client';
2
+ import SearchIcon from '@mui/icons-material/Search';
3
+ import classNames from 'classnames';
4
+ import { useTranslations } from 'next-intl';
5
+ import { useEffect, useState } from 'react';
6
+ import { Component } from '../../../component';
7
+ import { ColorTypes, Rounded, TextColorTypes } from '../../../theme';
8
+ import { Text } from '../text';
9
+ import { GoogleMapPicker } from './map';
10
+ import { getCountryAddressFormat, lookupInternationalAddress } from './utils';
11
+ export const Address = ({ name, rounded = Rounded.m, defaultValue, countryCode = 'JP', onSearch, onChange, disabled, required, className, googleMapsApiKey, }) => {
12
+ const [values, setValues] = useState(defaultValue ?? {
13
+ zipCode: '',
14
+ region: '',
15
+ city: '',
16
+ line1: '',
17
+ line2: '',
18
+ line3: '',
19
+ });
20
+ const t = useTranslations();
21
+ const [isSearching, setIsSearching] = useState(false);
22
+ const format = getCountryAddressFormat(countryCode, t);
23
+ useEffect(() => {
24
+ onChange?.(values);
25
+ }, [values, onChange]);
26
+ useEffect(() => {
27
+ if (googleMapsApiKey) {
28
+ return;
29
+ }
30
+ const geocodeAddress = async () => {
31
+ if (!values.zipCode || !values.region || !values.city || !values.line1) {
32
+ return;
33
+ }
34
+ try {
35
+ const addressString = `${values.zipCode} ${values.region}${values.city}${values.line1}`;
36
+ const response = await fetch(`https://maps.googleapis.com/maps/api/geocode/json?address=${encodeURIComponent(addressString)}&key=${googleMapsApiKey}`);
37
+ const data = await response.json();
38
+ if (data.results && data.results.length > 0) {
39
+ const location = data.results[0].geometry.location;
40
+ handleChange('lat', location.lat);
41
+ handleChange('lng', location.lng);
42
+ }
43
+ }
44
+ catch (error) {
45
+ console.error('Error geocoding address:', error);
46
+ }
47
+ };
48
+ geocodeAddress();
49
+ }, [values.zipCode, values.region, values.city, values.line1, googleMapsApiKey]);
50
+ const handleSearch = async () => {
51
+ if (!values.zipCode)
52
+ return;
53
+ setIsSearching(true);
54
+ try {
55
+ const result = await lookupInternationalAddress(values.zipCode, countryCode);
56
+ if (result) {
57
+ const updatedValues = {
58
+ ...values,
59
+ region: result.region,
60
+ city: result.city,
61
+ line1: result.line1,
62
+ lat: result.lat,
63
+ lng: result.lng,
64
+ };
65
+ setValues(updatedValues);
66
+ onSearch?.(updatedValues);
67
+ }
68
+ else {
69
+ onSearch?.(null);
70
+ }
71
+ }
72
+ catch (error) {
73
+ console.error('Error during address lookup:', error);
74
+ onSearch?.(null);
75
+ }
76
+ finally {
77
+ setIsSearching(false);
78
+ }
79
+ };
80
+ const handleChange = (field, value) => {
81
+ setValues((prev) => ({ ...prev, [field]: value }));
82
+ };
83
+ const isFieldRequired = (field) => {
84
+ if (!required)
85
+ return false;
86
+ return format.required.includes(field);
87
+ };
88
+ return (<div className={classNames('gap-control-padding-sm flex w-full flex-col', className)}>
89
+ {/* 郵便番号と検索ボタン */}
90
+ <div className='gap-control-padding-base flex items-start'>
91
+ <div className='gap-base flex w-full'>
92
+ <div className='gap-control-padding-sm flex w-[140px] items-center'>
93
+ <Component.Typography.Label container={true}>{format.labels.zipCode}</Component.Typography.Label>
94
+ {isFieldRequired('zipCode') && (<Component.Typography.P color={TextColorTypes.error} container={true}>
95
+ *
96
+ </Component.Typography.P>)}
97
+ </div>
98
+ <Text name={`${name}.zipCode`} rounded={rounded} value={values.zipCode} onChange={(e) => handleChange('zipCode', e.target.value)} required={isFieldRequired('zipCode')} disabled={disabled}/>
99
+ </div>
100
+ <Component.Button variant='colored' color={ColorTypes.primary} rounded={rounded} onClick={handleSearch} disabled={!values.zipCode || isSearching || disabled} icon={SearchIcon}/>
101
+ </div>
102
+
103
+ {/* 住所フィールド - 国別フォーマットに従って表示 */}
104
+ {format.order.map((field) => {
105
+ if (field === 'zipCode')
106
+ return null; // 郵便番号は上部に表示済み
107
+ return (<div key={field} className='mt-control-padding-base flex'>
108
+ <div className='gap-control-padding-sm flex w-[160px] items-center'>
109
+ <Component.Typography.Label container={true}>{format.labels[field]}</Component.Typography.Label>
110
+ {isFieldRequired(field) && (<Component.Typography.P color={TextColorTypes.error} container={true}>
111
+ *
112
+ </Component.Typography.P>)}
113
+ </div>
114
+ <Text name={`${name}.${field}`} rounded={rounded} value={values[field] || ''} onChange={(e) => handleChange(field, e.target.value)} required={isFieldRequired(field)} disabled={disabled}/>
115
+ </div>);
116
+ })}
117
+
118
+ {/* Google Maps による位置選択 */}
119
+ {googleMapsApiKey && (<div className='mt-control-padding-base'>
120
+ <GoogleMapPicker apiKey={googleMapsApiKey} initialLat={values.lat ?? undefined} initialLng={values.lng ?? undefined} rounded={rounded} disabled={disabled} onLocationSelect={(lat, lng) => {
121
+ handleChange('lat', lat);
122
+ handleChange('lng', lng);
123
+ }}/>
124
+ </div>)}
125
+
126
+ {/* 緯度・経度の非表示フィールド */}
127
+ <input type='hidden' name={`${name}.lat`} value={values.lat?.toString() || ''}/>
128
+ <input type='hidden' name={`${name}.lng`} value={values.lng?.toString() || ''}/>
129
+ {values.id && <input type='hidden' name={`${name}.id`} value={values.id}/>}
130
+ </div>);
131
+ };
132
+ //# sourceMappingURL=index.jsx.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.jsx","sourceRoot":"","sources":["../../../../../../src/ui/composite/input/address/index.tsx"],"names":[],"mappings":"AAAA,YAAY,CAAA;AAEZ,OAAO,UAAU,MAAM,4BAA4B,CAAA;AACnD,OAAO,UAAU,MAAM,YAAY,CAAA;AACnC,OAAO,EAAE,eAAe,EAAE,MAAM,WAAW,CAAA;AAC3C,OAAO,EAAE,SAAS,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAA;AAE3C,OAAO,EAAE,SAAS,EAAE,MAAM,oBAAoB,CAAA;AAC9C,OAAO,EAAE,UAAU,EAAE,OAAO,EAAE,cAAc,EAAE,MAAM,gBAAgB,CAAA;AACpE,OAAO,EAAE,IAAI,EAAE,MAAM,SAAS,CAAA;AAC9B,OAAO,EAAE,eAAe,EAAE,MAAM,OAAO,CAAA;AACvC,OAAO,EAAE,uBAAuB,EAAE,0BAA0B,EAAE,MAAM,SAAS,CAAA;AAuB7E,MAAM,CAAC,MAAM,OAAO,GAAG,CAAC,EACtB,IAAI,EACJ,OAAO,GAAG,OAA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,CACpC,OAAO,CAAC,CAAC,OAAO,CAAC,CACjB,QAAQ,CAAC,CAAC,QAAQ,CAAC,CACnB,gBAAgB,CAAC,CAAC,CAAC,GAAG,EAAE,GAAG,EAAE,EAAE;gBAC7B,YAAY,CAAC,KAAK,EAAE,GAAG,CAAC,CAAA;gBACxB,YAAY,CAAC,KAAK,EAAE,GAAG,CAAC,CAAA;YAC1B,CAAC,CAAC,EAEN;QAAA,EAAE,GAAG,CAAC,CACP,CAED;;MAAA,CAAC,oBAAoB,CACrB;MAAA,CAAC,KAAK,CAAC,IAAI,CAAC,QAAQ,CAAC,IAAI,CAAC,CAAC,GAAG,IAAI,MAAM,CAAC,CAAC,KAAK,CAAC,CAAC,MAAM,CAAC,GAAG,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC,EAC9E;MAAA,CAAC,KAAK,CAAC,IAAI,CAAC,QAAQ,CAAC,IAAI,CAAC,CAAC,GAAG,IAAI,MAAM,CAAC,CAAC,KAAK,CAAC,CAAC,MAAM,CAAC,GAAG,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC,EAC9E;MAAA,CAAC,MAAM,CAAC,EAAE,IAAI,CAAC,KAAK,CAAC,IAAI,CAAC,QAAQ,CAAC,IAAI,CAAC,CAAC,GAAG,IAAI,KAAK,CAAC,CAAC,KAAK,CAAC,CAAC,MAAM,CAAC,EAAE,CAAC,EAAG,CAC7E;IAAA,EAAE,GAAG,CAAC,CACP,CAAA;AACH,CAAC,CAAA"}
@@ -0,0 +1,64 @@
1
+ import { Rounded } from '../../../theme';
2
+ declare global {
3
+ interface Window {
4
+ google: {
5
+ maps: {
6
+ Map: new (element: HTMLElement, options: GoogleMapOptions) => GoogleMap;
7
+ Marker: new (options: GoogleMarkerOptions) => GoogleMarker;
8
+ LatLng: new (lat: number, lng: number) => GoogleLatLng;
9
+ event: {
10
+ addListener: (instance: GoogleMap | GoogleMarker, eventName: string, handler: (e: GoogleMapEvent) => void) => void;
11
+ };
12
+ };
13
+ };
14
+ }
15
+ }
16
+ interface GoogleMapOptions {
17
+ center: {
18
+ lat: number;
19
+ lng: number;
20
+ };
21
+ zoom: number;
22
+ mapTypeControl: boolean;
23
+ streetViewControl: boolean;
24
+ fullscreenControl: boolean;
25
+ }
26
+ interface GoogleMarkerOptions {
27
+ position: {
28
+ lat: number;
29
+ lng: number;
30
+ };
31
+ map: GoogleMap;
32
+ draggable: boolean;
33
+ }
34
+ interface GoogleMap {
35
+ setCenter: (position: {
36
+ lat: number;
37
+ lng: number;
38
+ }) => void;
39
+ }
40
+ interface GoogleMarker {
41
+ setPosition: (position: {
42
+ lat: number;
43
+ lng: number;
44
+ }) => void;
45
+ getPosition: () => GoogleLatLng;
46
+ }
47
+ interface GoogleLatLng {
48
+ lat: () => number;
49
+ lng: () => number;
50
+ }
51
+ interface GoogleMapEvent {
52
+ latLng: GoogleLatLng;
53
+ }
54
+ interface GoogleMapProps {
55
+ apiKey?: string;
56
+ initialLat?: number;
57
+ initialLng?: number;
58
+ onLocationSelect: (lat: number, lng: number) => void;
59
+ rounded?: Rounded;
60
+ disabled?: boolean;
61
+ className?: string;
62
+ }
63
+ export declare const GoogleMapPicker: ({ apiKey, initialLat, initialLng, onLocationSelect, rounded, disabled, className, }: GoogleMapProps) => import("react").JSX.Element;
64
+ export {};