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

Fix for untitled projects in picker tile sizes #2429

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

ifeLawal
Copy link

@ifeLawal ifeLawal commented Dec 29, 2020

I saw this open in the good first issue and thought it would be a good first tackle as a relatively new programmer.

My approach was to adjust the empty string fallback that gets returned from the generateTextPreview() method. I had 2 possible thoughts

  • Make the fallback "Page Title", since this is the starting page title for the new page
  • Use a space regular expression, "\b" or "\s" as the fallback so it keeps the empty look but fills the space where text would exist

I went with the regular expression approach since it looks empty, which matches what would be in a students <Title> tag in the html on Popcode. I used the same approach for the time section in the tile, but I was not sure how to reproduce the time actually being an empty string so any feedback on your thoughts on reproducing this, as well as if the regular expression approach makes sense, would be super helpful.

Closes #2102

@ifeLawal ifeLawal changed the title Fix to issue #2012 Fix for untitled projects in picker tile sizes Dec 29, 2020
@ifeLawal ifeLawal marked this pull request as ready for review December 29, 2020 02:20
@ifeLawal ifeLawal marked this pull request as draft December 29, 2020 02:22
@ifeLawal
Copy link
Author

@outoftime Sorry I don't see the + next to Reviewers to add you as a reviewer

@ifeLawal ifeLawal marked this pull request as ready for review December 29, 2020 02:25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Untitled Project in Project Picker
1 participant