Plots2: Implement Access token modal like Link social modal

Created on 5 Jan 2019  ·  4Comments  ·  Source: publiclab/plots2

link_social_modal

This is social media linking modal which is integrated using simple HTML - https://github.com/publiclab/plots2/blob/master/app/views/users/profile.html.erb#L206-L223

access_token_modal
This is access token modal which is integrated using JavaScript - https://github.com/publiclab/plots2/blob/master/app/views/users/_token.html.erb which is complicated as token modal can be implemented similar to the social modal.

Make the token modal appear without using the JavaScript code present in file _token.html.erb and implement it just like social media modal i.e., normal bootstrap modal called on button press.

Thanks!

CSS HTML JavaScript design fto-candidate refactorization

Most helpful comment

@gauravano I went ahead and moved all the scripting to the profile.html.erb file. I can make additional changes as needed! I know there was some css I wanted to look at for mobile devices that needed some updating. I am going to go ahead and push my changes and commit for now.

All 4 comments

Hi @gauravano, I am going to try and work on this for a bit and see if I can get it. It's my first project outside of basic coursework so bear with me!

@gauravano In order to copy to clipboard via the button, the JavaScript is a necessity in some shape or form. I adjusted the code to allow removal of all other JavaScript in the file though. Would you prefer to try and have the copy function in the profile file and remove the token file completely or just leave the copy function by itself in the token file?

@gauravano I went ahead and moved all the scripting to the profile.html.erb file. I can make additional changes as needed! I know there was some css I wanted to look at for mobile devices that needed some updating. I am going to go ahead and push my changes and commit for now.

Welcome to Public Lab @trompj and happy to see your energy. As you have opened your PR, we can have further discussion there only.

Reviewing your PR now.Thanks!

Was this page helpful?
0 / 5 - 0 ratings

Related issues

first-timers[bot] picture first-timers[bot]  ·  3Comments

grvsachdeva picture grvsachdeva  ·  3Comments

first-timers[bot] picture first-timers[bot]  ·  3Comments

ebarry picture ebarry  ·  3Comments

first-timers[bot] picture first-timers[bot]  ·  3Comments