Search
Search

Transaction: Hgma8Wi...uv8U

Signed by
Receiver
Status
Succeeded
Transaction Fee
0.0008 
Deposit Value
0 
Gas Used
8 Tgas
Attached Gas
100 Tgas
Created
October 11, 2023 at 6:40:45pm
Hash
Hgma8WiWDvc2h1cobQWk22C1YjcCwUutjwgPsMokuv8U

Actions

Called method: 'set' in contract: social.near
Arguments:
{ "data": { "andyh.near": { "widget": { "HooksDemo": { "": "const [value, setValue] = useState(0);\nconst [message, setMessage] = useState(\"\");\nconst [sentMessages, setSentMessages] = useState([]);\nconst [isInit, setIsInit] = useState(false);\n// const [value, setValue] = [4, console.log];\n// const textRef = useRef(null);\n\nuseEffect(() => {\n console.log({ isInit });\n if (!isInit) {\n setTimeout(() => setValue(500), 5000);\n setIsInit(true);\n }\n}, [isInit]);\n\nuseEffect(() => {\n const interval = setInterval(() => {\n const updatedMessages = [...sentMessages];\n updatedMessages.pop();\n setSentMessages(updatedMessages);\n }, 5000);\n return () => clearInterval(interval);\n}, []);\n\n// useEffect(() => {\n// console.log({ textRef: textRef.current });\n// textRef.current?.focus();\n// }, [textRef.current]);\n\nreturn (\n <>\n <h3>Send a message to the Future</h3>\n\n <div className=\"mb-3\">\n <ul>\n {sentMessages.map((msg) => (\n <li key={msg}>{msg}</li>\n ))}\n </ul>\n </div>\n <div className=\"input-group mb-3\">\n <label className=\"input-group-text\" htmlFor=\"inputGroupSelect0\">\n Message\n </label>\n <input\n type=\"text\"\n className=\"form-control\"\n placeholder=\"\"\n value={message}\n onChange={(e) => setMessage(e.target.value)}\n aria-label=\"Example text with button addon\"\n aria-describedby=\"button-addon1\"\n />\n </div>\n\n <div className=\"input-group mb-3\">\n <label className=\"input-group-text\" htmlFor=\"inputGroupSelect01\">\n Delay\n </label>\n <select className=\"form-select\" id=\"inputGroupSelect01\">\n <option value=\"0\">Instant</option>\n <option value=\"100\">0.1 seconds</option>\n <option value=\"500\">0.5 seconds</option>\n <option value=\"1000\">1 second</option>\n </select>\n </div>\n <div className=\"d-grid gap-2\">\n <button\n className=\"btn btn-primary\"\n type=\"button\"\n onClick={() => {\n const updatedMessages = [...sentMessages];\n updatedMessages.push(message);\n setSentMessages(updatedMessages);\n setMessage(\"\");\n }}\n >\n Send Message\n </button>\n </div>\n </>\n);\n" } } } } }

Transaction Execution Plan

Convert Transaction To Receipt
Gas Burned:
2 Tgas
Tokens Burned:
0.00024 
Receipt:
Predecessor ID:
Receiver ID:
Gas Burned:
5 Tgas
Tokens Burned:
0.00056 
Called method: 'set' in contract: social.near
Arguments:
{ "data": { "andyh.near": { "widget": { "HooksDemo": { "": "const [value, setValue] = useState(0);\nconst [message, setMessage] = useState(\"\");\nconst [sentMessages, setSentMessages] = useState([]);\nconst [isInit, setIsInit] = useState(false);\n// const [value, setValue] = [4, console.log];\n// const textRef = useRef(null);\n\nuseEffect(() => {\n console.log({ isInit });\n if (!isInit) {\n setTimeout(() => setValue(500), 5000);\n setIsInit(true);\n }\n}, [isInit]);\n\nuseEffect(() => {\n const interval = setInterval(() => {\n const updatedMessages = [...sentMessages];\n updatedMessages.pop();\n setSentMessages(updatedMessages);\n }, 5000);\n return () => clearInterval(interval);\n}, []);\n\n// useEffect(() => {\n// console.log({ textRef: textRef.current });\n// textRef.current?.focus();\n// }, [textRef.current]);\n\nreturn (\n <>\n <h3>Send a message to the Future</h3>\n\n <div className=\"mb-3\">\n <ul>\n {sentMessages.map((msg) => (\n <li key={msg}>{msg}</li>\n ))}\n </ul>\n </div>\n <div className=\"input-group mb-3\">\n <label className=\"input-group-text\" htmlFor=\"inputGroupSelect0\">\n Message\n </label>\n <input\n type=\"text\"\n className=\"form-control\"\n placeholder=\"\"\n value={message}\n onChange={(e) => setMessage(e.target.value)}\n aria-label=\"Example text with button addon\"\n aria-describedby=\"button-addon1\"\n />\n </div>\n\n <div className=\"input-group mb-3\">\n <label className=\"input-group-text\" htmlFor=\"inputGroupSelect01\">\n Delay\n </label>\n <select className=\"form-select\" id=\"inputGroupSelect01\">\n <option value=\"0\">Instant</option>\n <option value=\"100\">0.1 seconds</option>\n <option value=\"500\">0.5 seconds</option>\n <option value=\"1000\">1 second</option>\n </select>\n </div>\n <div className=\"d-grid gap-2\">\n <button\n className=\"btn btn-primary\"\n type=\"button\"\n onClick={() => {\n const updatedMessages = [...sentMessages];\n updatedMessages.push(message);\n setSentMessages(updatedMessages);\n setMessage(\"\");\n }}\n >\n Send Message\n </button>\n </div>\n </>\n);\n" } } } } }
Empty result
No logs
Receipt:
Predecessor ID:
Receiver ID:
Gas Burned:
223 Ggas
Tokens Burned:
0 
Transferred 0.0185  to andyh.near
Empty result
No logs