This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| const intSize = unsafe.Sizeof(int(0)) | |
| func intToUUID(n int) uuid.UUID { | |
| var u uuid.UUID | |
| intPtr := unsafe.Pointer(&n) | |
| for i := 0; i < int(intSize); i++ { | |
| byteptr := (*byte)(unsafe.Add(intPtr, i)) | |
| u[i] = *byteptr | |
| } | |
| return u |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import { | |
| combine, | |
| createEffect, | |
| createEvent, | |
| createStore, | |
| Effect, | |
| Event, | |
| forward, | |
| sample, | |
| Store, |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import React, { forwardRef, useEffect } from "react"; | |
| import ReCAPTCHA, { ReCAPTCHAProps } from "react-google-recaptcha"; | |
| import { setting } from "../config"; | |
| type CaptchaProps = Omit<ReCAPTCHAProps, "sitekey">; | |
| const CaptchaPlaceholder: React.FC<{ onClick?: () => void }> = ({ | |
| onClick, | |
| }) => { | |
| return ( |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import { createEvent, restore, sample } from "effector"; | |
| export function createConfirmation<Require, Allow>() { | |
| type Confirmed = { require: Require; allow: Allow }; | |
| const require = createEvent<Require>(); | |
| const $payload = restore(require, null); | |
| const allow = createEvent<Allow>(); | |
| const confirmed = createEvent<Confirmed>(); |
NewerOlder