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

Note display: number of lines vary for Expanded display #235

Closed
davewhitley opened this issue Mar 18, 2016 · 1 comment · Fixed by #1647
Closed

Note display: number of lines vary for Expanded display #235

davewhitley opened this issue Mar 18, 2016 · 1 comment · Fixed by #1647
Labels
bug Something isn't working

Comments

@davewhitley
Copy link
Contributor

Is Expanded 4 lines? I forgot what we decided.

It seem strange that some notes don't have 4 lines even though there is more text.

screen shot 2016-03-18 at 10 15 30 am

@davewhitley davewhitley added the bug Something isn't working label Mar 18, 2016
@davewhitley
Copy link
Contributor Author

Another example

screen shot 2016-03-18 at 10 18 58 am

dmsnell added a commit that referenced this issue Oct 22, 2019
Replaces #1647

fixes: #235

The regex that captures the note list preview was only selecting the first line. This selects the remainder of the note.  That string then gets sliced down to the `previewCharacterLimit`.

This PR also decreases the performance cost of creating the title and preview from 1ms to 0.2ms.

1. Load production
2. Have note that has a few characters per line for a couple of lines
3. Have Settings -> Display -> Note Display set to Expanded
4. Observe only the first line of text is shown
5. Do the same on the this branch
6. Observe that multiple lines are shown up to 300 characters
7. This is the same as the Android app

**Before:**
<img width="331" alt="Screen Shot 2019-10-18 at 10 53 21 AM" src="https://user-images.githubusercontent.com/6817400/67104796-9690bd80-f195-11e9-959a-1edc18f58030.png">
**After:**
<img width="329" alt="Screen Shot 2019-10-18 at 10 53 29 AM" src="https://user-images.githubusercontent.com/6817400/67104797-9690bd80-f195-11e9-9c17-282747d9a7da.png">

Only one developer ais required to review these changes, but anyone can perform the review.

`RELEASE-NOTES.txt` was updated with:

- Fixed bug that only shows the first line of text in note list preview
dmsnell added a commit that referenced this issue Oct 27, 2019
Replaces #1647

fixes: #235

The regex that captures the note list preview was only selecting the first line. This selects the remainder of the note.  That string then gets sliced down to the `previewCharacterLimit`.

This PR also decreases the performance cost of creating the title and preview from 1ms to 0.2ms.

1. Load production
2. Have note that has a few characters per line for a couple of lines
3. Have Settings -> Display -> Note Display set to Expanded
4. Observe only the first line of text is shown
5. Do the same on the this branch
6. Observe that multiple lines are shown up to 300 characters
7. This is the same as the Android app

**Before:**
<img width="331" alt="Screen Shot 2019-10-18 at 10 53 21 AM" src="https://user-images.githubusercontent.com/6817400/67104796-9690bd80-f195-11e9-959a-1edc18f58030.png">
**After:**
<img width="329" alt="Screen Shot 2019-10-18 at 10 53 29 AM" src="https://user-images.githubusercontent.com/6817400/67104797-9690bd80-f195-11e9-9c17-282747d9a7da.png">

Only one developer ais required to review these changes, but anyone can perform the review.

`RELEASE-NOTES.txt` was updated with:

- Fixed bug that only shows the first line of text in note list preview
dmsnell added a commit that referenced this issue Oct 28, 2019
Replaces #1647

fixes: #235

The regex that captures the note list preview was only selecting the first line. This selects the remainder of the note.  That string then gets sliced down to the `previewCharacterLimit`.

This PR also decreases the performance cost of creating the title and preview from 1ms to 0.2ms.

1. Load production
2. Have note that has a few characters per line for a couple of lines
3. Have Settings -> Display -> Note Display set to Expanded
4. Observe only the first line of text is shown
5. Do the same on the this branch
6. Observe that multiple lines are shown up to 300 characters
7. This is the same as the Android app

**Before:**
<img width="331" alt="Screen Shot 2019-10-18 at 10 53 21 AM" src="https://user-images.githubusercontent.com/6817400/67104796-9690bd80-f195-11e9-959a-1edc18f58030.png">
**After:**
<img width="329" alt="Screen Shot 2019-10-18 at 10 53 29 AM" src="https://user-images.githubusercontent.com/6817400/67104797-9690bd80-f195-11e9-9c17-282747d9a7da.png">

Only one developer ais required to review these changes, but anyone can perform the review.

`RELEASE-NOTES.txt` was updated with:

- Fixed bug that only shows the first line of text in note list preview
belcherj added a commit that referenced this issue Oct 31, 2019
fixes: #235

The regex that captures the note list preview was only selecting the first line. This selects the remainder of the note.  That string then gets sliced down to the `previewCharacterLimit`.

This PR also decreases the performance cost of creating the title and preview from 1ms to 0.2ms.

1. Load production
2. Have note that has a few characters per line for a couple of lines
3. Have Settings -> Display -> Note Display set to Expanded
4. Observe only the first line of text is shown
5. Do the same on the this branch
6. Observe that multiple lines are shown up to 300 characters
7. This is the same as the Android app

**Before:**
<img width="331" alt="Screen Shot 2019-10-18 at 10 53 21 AM" src="https://user-images.githubusercontent.com/6817400/67104796-9690bd80-f195-11e9-959a-1edc18f58030.png">
**After:**
<img width="329" alt="Screen Shot 2019-10-18 at 10 53 29 AM" src="https://user-images.githubusercontent.com/6817400/67104797-9690bd80-f195-11e9-9c17-282747d9a7da.png">

Only one developer ais required to review these changes, but anyone can perform the review.

`RELEASE-NOTES.txt` was updated with:

- Fixed bug that only shows the first line of text in note list preview

* Remove some duplicate logic

* Rename variable to better describe its use

* Code review updates
@codebykat codebykat removed the has pr label Oct 21, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants