mozilla / lightbeam-we

Web Extension version of the Firefox Lightbeam add-on
https://addons.mozilla.org/en-GB/firefox/addon/lightbeam/
Mozilla Public License 2.0
179 stars 61 forks source link

add warning when remove all data #197

Closed joanasouza closed 7 years ago

joanasouza commented 7 years ago

Issue #119

princiya commented 7 years ago

I shall create a follow-up issue to add CSS to this confirm dialog box.

jonathanKingston commented 7 years ago

Sorry to be pedantic but can you make a new variable for the confirm string rather than using string concatenation to get under the line limit. If that is still too long you could use a template string also.

Thanks for the patch! Let me know if you need any help with anything else.

On Sun, 3 Sep 2017, 12:18 Joana de Souza notifications@github.com wrote:

@joanasouza commented on this pull request.

In js/lightbeam.js https://github.com/mozilla/lightbeam-we/pull/197#discussion_r136724053:

@@ -142,7 +142,10 @@ const lightbeam = { resetData() { const resetData = document.getElementById('reset-data-button'); resetData.addEventListener('click', async () => {

  • await storeChild.reset();
  • var confirmation = confirm('Pressing OK will delete all'
    • ' Lightbeam information. Are you sure?');
  • if (confirmation == true)
  • await storeChild.reset(); window.location.reload(); });

Thanks, already applied the changes 😄

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/mozilla/lightbeam-we/pull/197#discussion_r136724053, or mute the thread https://github.com/notifications/unsubscribe-auth/AAUsLMiVQCxJgD4MgC3wC3ExY2vwiNGdks5sevuEgaJpZM4PLRA9 .

jonathanKingston commented 7 years ago

I'm going to merge this however some follow up work could be: