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

Allow input value to be copied to selected rows instead of all rows #2320

Closed
RFSH opened this issue Jun 7, 2023 · 2 comments · Fixed by #2345
Closed

Allow input value to be copied to selected rows instead of all rows #2320

RFSH opened this issue Jun 7, 2023 · 2 comments · Fixed by #2345
Assignees
Labels
help wanted Intended for internal use for student workers

Comments

@RFSH
Copy link
Member

RFSH commented Jun 7, 2023

We can set the value for all the forms with the "set all" button in recordedit. In this issue, we want to allow users to set values for specific rows.

This is how it could be done:

  • User clicks on the pencil button to open the "set all" UI.
  • User selects the value the same way that they currently do.
  • We should allow users to select the specific row to which they want the data to be applied. This requires exploration. Since we're disabling the inputs, we could allow users to click on each input to select the row that we want the data to be applied to.

Code details

This is the callback that will set the value of all the inputs. Instead of doing this for all "forms", you would have to selectively do this for the forms that user has selected.

@RFSH RFSH added the help wanted Intended for internal use for student workers label Jun 7, 2023
@PoornimaVKrishnan
Copy link
Contributor

Action points from the meeting:

  1. Implement two Radio Buttons Select All and Select None and a button Apply to apply the changes. Select All will select all the forms and we can deselect from it if we don't want to apply the change to that particular form. Select None is to deselect all the forms.

Questions: By default should we have all selected or none selected?

  1. Figure out a way to know the form is clickable

  2. Experiment Clear All button to clear the text from forms

Question: Should we clear text from selected forms or from all forms?

@PoornimaVKrishnan
Copy link
Contributor

PoornimaVKrishnan commented Jul 28, 2023

@RFSH
MOM from todays scrum call:

  • Move the i icon close to the checkbox label as we are explaining more on how the selection and deselection works
  • On resize of the textarea the controls on the top(i.e the buttons and checkbox) should also move
  • Tooltip for checkbox and label should not show once an interaction(i.e a click on checkbox) is made.
  • Also, in facets we are not making the checkbox label also clickable but in github it is clickable. We have to decide whether we should make it consistent with github or the chaise app
  • Where should the tooltip be aligned to in all cases(top, bottom, right, left)?

Pending items:

  • Updating the selection on removing form
  • Above items from the meeting
  • A bug which I found: On load one form is selected by default, one deselect of that checkbox is in indeterminate state instead of empty with Select All text

Also please check the tooltip text:

const renderHelpTooltip = () => {
    const splitLine1 = 'You can click on the form to select it and apply changes to it. '+ 
    'You can use the checkbox to select and deselect all records'
    const splitLine2 = 'By default, if there is no previous selection, the first form will be selected. '
    const splitLine4 = 'After the forms are selected, ' + 'you can click Apply button to apply the changes to selected records.'
    const splitLine3 = 'You can also clear the values for selected records by clicking ' +
     'on Clear button.'
  
    return (<>
      <p>{splitLine1}</p>
      <p>{splitLine2}</p>
      <p>{splitLine3}</p>
    </>)
  }

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
help wanted Intended for internal use for student workers
Projects
None yet
2 participants