Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Help chat #7151

Merged
merged 34 commits into from
Jul 18, 2023
Merged

Help chat #7151

merged 34 commits into from
Jul 18, 2023

Conversation

somebody1234
Copy link
Collaborator

@somebody1234 somebody1234 commented Jun 28, 2023

Pull Request Description

Closes #6610

Important Notes

Screencasts

screen-recorder-mon-jul-03-2023-20-29-41.webm

Checklist

Please ensure that the following checklist has been satisfied before submitting the PR:

  • The documentation has been updated, if necessary.
  • Screenshots/screencasts have been attached, if there are any visual changes. For interactive or animated visual changes, a screencast is preferred.
  • All code follows the
    Scala,
    Java,
    and
    Rust
    style guides. In case you are using a language not listed above, follow the Rust style guide.
  • All code has been tested:
    • Unit tests have been written where possible.
    • If GUI codebase was changed, the GUI was tested when built using ./run ide build.

@somebody1234 somebody1234 marked this pull request as ready for review July 3, 2023 10:34
Copy link
Member

@wdanilo wdanilo left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is super cool! A few questions:

  1. Where is server implementation? We should keep it in our repo as well.
  2. The design is not exactly as in Figma, do we plan to fix it in this PR or in a separate one?
  3. Where on Discord the user messages land? Do we have access to it, or it is in a test server for now?

// =============

/** All possible reaction emojis. */
type ReactionSymbol = '❤️' | '🎉' | '👀' | '👍' | '👎' | '😀' | '🙁'
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this is a repeated code - above we have the same. Can we refactor it, please?

// === Message Types ===
// =====================

// FIXME[sb]: Consider deduplicating.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This should be part of cleaning this PR if its about code deduplication :) if its about anything else, it needs better docs.

}

/** Chat sidebar. */
function Chat(props: ChatProps) {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this function is 400 lines long! Can we refactor it to several well named functions instead, please?

@somebody1234
Copy link
Collaborator Author

  • server implementation is linked in the original post. can be easily moved into this repo, but thinking about it it might make deploy on commit a bit harder unless the app hosting platform we use supports sparse checkouts... or actually we could use CI to build to a separate repo. thoughts?
  • design not identical to figma - whoops, forgot to bring this up. I don't think i have a link to the figma, and the screenshot seems like it's scaled, likely because of retina displays, so its a bit difficult for me to get the right spacings (etc)
  • the discord messages land in a test server, yes - see the linked PR about the server impl for details
  • deduplication: currently the duplicated code is across two different repos, and that's the part making it hard to deduplicate. if you have any ideas that'd be great
  • repeated code: fair point, originally i refactored it to this to make it consistent with the backend, but yeah the constant can be copied to the backend instead. it won't actually be used in the backend but itll be consistent, and there will be no repetition

@somebody1234
Copy link
Collaborator Author

400 line long function: I'll see whst i can do

@wdanilo
Copy link
Member

wdanilo commented Jul 3, 2023

@somebody1234
Copy link
Collaborator Author

re: using a npm library - it would probably work, but upon some investigation it seems like it's possible to use git dependencies, which is probably more convenient, since it wouldn't require publishing new tags for local development

also, it's not like it should be publicly visible on npm - not that it can't be, but i do think what determines whether something belongs on npm should be an intentional decision, rather than "we have to put it on npm for things to work" - when there are other options, at least

@wdanilo
Copy link
Member

wdanilo commented Jul 3, 2023

Oh, I did not know that nom supports git dependencies. This is way better solution, let's use it! :)

@PabloBuchu
Copy link
Contributor

Please adjust spaces around inputs to match figma

Screenshot 2023-07-06 at 12 23 26

@PabloBuchu
Copy link
Contributor

PabloBuchu commented Jul 7, 2023

@somebody1234

  1. The arrow in threads list is not animated. Should be toggled (down for rolled up; up for expanded)
  2. The emoji menu should be visible only on hover.
  3. Emoji ... at the end with full emoji menu? This one please estimate if its doable at all and how hard would it be.
  4. Creating new thread should append +x to the default name New chat thread 1. Right now renaming threads doesn't work on mac and I can follow only latest thread. Previously created are gone.
    4.a Weirdly threads appeared after restarting enso but creating new ones do not appended them to thread list
  5. No highlighting when moving mouse over the thread list. The current opened should be highlighted but also the one I have my pointer over
  6. Thread renaming. When you hover your mouse over the thread name the mouse pointer should be changed to text and after click name should be changed to input widget with save on enter
  7. Also on thread list we should have 1 additional icon on the left (if its doable):
  • trash for delete
  1. With expanded thread list clicking outside it does not roll it up
  2. padding left / right should be the same as top and down for "New question?" and "Reply"
Screenshot 2023-07-07 at 11 27 14 Screenshot 2023-07-07 at 11 27 55
  1. Bug with opened workspace:
Screenshot 2023-07-07 at 11 35 13
  1. I also have double cursor pointers when working as above (can't show on screenshot)
  2. There is no help chat on workspace view (needed to go back to dashboard and leave opened to have it on project view). I guess this one is not doable without either having it in rust or having header in react right?

@somebody1234
Copy link
Collaborator Author

somebody1234 commented Jul 7, 2023

  1. done locally
  2. not sure how this should work
  3. sounds reasonable, naively it should just be a scrolling div with all the emoji - so like the current reaction bar, just with more emojis. one problem though, would be whether it's needed - i'd imagine some (or many) emojis should be omitted, either because they aren't professional (e.g. the vomiting emoji), or because they are rarely useful (e.g. the regional indicator emojis (🇦-🇿))
  4. will do done locally
  5. done locally
  6. done locally
  7. tbd
  8. done locally
  9. done locally (visually). they actually were the same size - it's because of the rounded corners that it looks like they're different sizes
  10. done locally
  11. cannot repro, i'm assuming fix for 10 has fixed this too
  12. yeah. i think the simplest way is to do things the same way as the "back to ide" event - have rust implement the ui to open it, and then use events to send information back and forth

@PabloBuchu
Copy link
Contributor

still having issues that threads are not appending to the list but only current is visible. now even reopening doesn't help

Screen.Recording.2023-07-07.at.16.00.15.mov

@PabloBuchu
Copy link
Contributor

@somebody1234

  1. lets not add more emojis for now. can we just fix emoji menu on hover? currently you can only like the recent response
  2. can we add a red dot on help chat blue button whenever there is unread message? how hard would it be?

@somebody1234
Copy link
Collaborator Author

  1. will do tomorrow
  2. on it. seems like it's harder than i expected... i'm thinking of using http + polling, because i'd imagine most users would rarely (if ever) use the help chat

@somebody1234
Copy link
Collaborator Author

i just realized, i don't think this works with multiple users in an organization. i'll have to take a look at that sometime

@somebody1234 somebody1234 marked this pull request as draft July 11, 2023 06:49
@PabloBuchu
Copy link
Contributor

i just realized, i don't think this works with multiple users in an organization. i'll have to take a look at that sometime

this one is not obvious. lets fix conflicts and open for review and merge (deploy) this implementation then we see

@somebody1234 somebody1234 marked this pull request as ready for review July 11, 2023 08:54
@PabloBuchu PabloBuchu self-assigned this Jul 14, 2023
@PabloBuchu PabloBuchu added the CI: Clean build required CI runners will be cleaned before and after this PR is built. label Jul 14, 2023
@PabloBuchu PabloBuchu merged commit 457d098 into develop Jul 18, 2023
35 of 36 checks passed
@PabloBuchu PabloBuchu deleted the wip/sb/help-chat branch July 18, 2023 11:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
CI: Clean build required CI runners will be cleaned before and after this PR is built.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Enso Chat
3 participants