Closed jravenel closed 1 year ago
@jravenel please allow me access to Naas Workspace Alpha Program. I need to login for testing chrome extension.
Hello @hassan3kb,
Here is my video answer to your video - Watch Video
I noticed that when using Merlin, if you're not logged in, it takes you to the sign-up page. Only after signing up can you access the extension. I would like your input on this idea.
Just talked about it with @Dr0p42 - let's follow up here. There might be a trick to be done with token/cookies.
@jravenel I cannot experience the login process (because I don't have access)
Please allow me access at ghassanpk@gmail.com
I'll need to look into cookies for checking login status, please give me details about which cookie represents login status.
@hassan3kb you have access now.
Hello @hassan3kb, I hope you are doing great. This information is not stored in a cookie but in the local storage for naas.ai
here is an example
Hello @Dr0p42 , the problem is I cannot access localStorage unless a tab is open (with url naas.ai/*) Is there any other way I can check if the user is logged in?
Hello @hassan3kb, in that case I need to do some testing on my side. We need to find a solution.
@jravenel if the user is already logged in to naas.ai then the extension is good to go.
I've pushed the code to v2
branch. Kindly check it out and give me feedback on this.
I'll update it, once @Dr0p42 finds a way to check login, if the user is not logged the extension will open the login page for the user.
hello @hassan3kb I'm not able to test it, when I load unpacked extension from src file of repo. Maybe I'm doing something wrong. Can you write a short loom video about how to setup?
@hassan3kb you can also come and chat here: https://join.slack.com/t/naas-club/shared_invite/zt-1970s5rie-dXXkigAdEJYc~LPdQIEaLA
Hello @hassan3kb, I think that we should update the code of workspace to allow it to know where it is and what should be done for authentication. I quickly took a look and it seems that on doing a window.location
we get a url starting with chrome-extension://
so we should have a way to display to the user what he should do.
@hassan3kb for the authentication to work what do we need the user to do? Open and login naas.ai in a browser tab?
Hey @Dr0p42 , one way to use cookies, the other way is to allow the top frame to access the website content when it's in an iframe.
Currently, I cannot access iframe.contentWindow
because of some security rules. I think rules need to be updated.
ok thanks @hassan3kb ! so let's try to deploy, test now? @Dr0p42
The idea is to leverage the right panel feature of chrome like this one
and use it as a base to integrate our workspace in it: Reading List becomes Workspace and other tab in dropdown can be 'Options' where we can find the info currently in the extension