Proyectos de Subversion LeadersLinked - SPA

Rev

Rev 218 | Rev 377 | Ir a la última revisión | Mostrar el archivo completo | | | Autoría | Ultima modificación | Ver Log |

Rev 218 Rev 230
Línea 266... Línea 266...
266
 
266
 
267
const SubmitForm = ({ sendUrl, uploadUrl, onSubmit: onComplete }) => {
267
const SubmitForm = ({ sendUrl, uploadUrl, onSubmit: onComplete }) => {
268
  const [showEmojione, setShowEmojione] = useState(false);
268
  const [showEmojione, setShowEmojione] = useState(false);
269
  const [isShowFileModal, setIsShowFileModal] = useState(false);
269
  const [isShowFileModal, setIsShowFileModal] = useState(false);
270
  const [isSending, setIsSending] = useState(false);
-
 
271
  const inputFile = useRef(null);
270
  const [isSending, setIsSending] = useState(false);
Línea 272... Línea 271...
272
  const dispatch = useDispatch();
271
  const dispatch = useDispatch();
Línea 273... Línea 272...
273
 
272
 
Línea 324... Línea 323...
324
 
323
 
325
  const toggleFileModal = () => {
324
  const toggleFileModal = () => {
326
    setIsShowFileModal(!isShowFileModal);
325
    setIsShowFileModal(!isShowFileModal);
Línea 327... Línea -...
327
  };
-
 
328
 
-
 
329
  const toggleFile = () => {
-
 
330
    inputFile.current?.click();
-
 
331
  };
326
  };
332
 
327
 
333
  const onClickEmoji = (event) => {
328
  const onClickEmoji = (event) => {
334
    const shortname = event.currentTarget.dataset.shortname;
329
    const shortname = event.currentTarget.dataset.shortname;
335
    const currentMessage = getValues("message");
330
    const currentMessage = getValues("message");
Línea 340... Línea 335...
340
 
335
 
341
  return (
336
  return (
342
    <>
337
    <>
343
      <StyledForm onSubmit={onSubmit}>
338
      <StyledForm onSubmit={onSubmit}>
344
        {showEmojione && <Emojione onClickEmoji={onClickEmoji} />}
339
        {showEmojione && <Emojione onClickEmoji={onClickEmoji} />}
345
        <IconButton onClick={toggleFile}>
340
        <IconButton onClick={toggleFileModal}>
346
          <AttachFileIcon />
341
          <AttachFileIcon />
347
        </IconButton>
-
 
348
        <input type="file" ref={inputFile} hidden />
342
        </IconButton>
349
        <IconButton onClick={toggleEmojione}>
343
        <IconButton onClick={toggleEmojione}>
350
          <InsertEmoticonIcon />
344
          <InsertEmoticonIcon />
351
        </IconButton>
345
        </IconButton>
352
        <StyledInput
346
        <StyledInput