Task #873
closedFE: UiUtils - improve methods for substring
100%
Description
Methods 'substringBegin', 'substringEnd' and 'substringByWord' in UiUtils on frontend can append suffix ' ...', when given text is shortened.
Example:
'Long long text' => 'Long long ...'
Add optional parameter into methods with suffix - null as default. Add frontend tests.
Related issues
Updated by Radek Tomiška over 6 years ago
- Related to Task #784: Component NotificationTemplateInfo - implement full and popover decorator added
Updated by Ondřej Kopr over 6 years ago
- Assignee changed from Radek Tomiška to Patrik Stloukal
Updated by Marcel Poul about 6 years ago
- Assignee changed from Patrik Stloukal to Petr Adamec
Updated by Petr Adamec about 6 years ago
- Status changed from New to Resolved
- % Done changed from 0 to 100
Solution of this task is commited to branch adamecp/873-improve-methods-for-substring
Updated by Petr Adamec about 6 years ago
- Status changed from Resolved to Needs feedback
- Assignee changed from Petr Adamec to Ondřej Kopr
Updated by Ondřej Kopr about 6 years ago
- Status changed from Needs feedback to In Progress
- Assignee changed from Ondřej Kopr to Petr Adamec
- % Done changed from 100 to 80
I made first feedback (good job, you will commit first new feature into our product :) )
- I'm not able start FE application:
**CzechIdMng/Realization/frontend/czechidm-core/src/components/basic/ShortText/ShortText.js 29:69 error A space is required after ',' comma-spacing 29:70 error Strings must use singlequote quotes 31:67 error A space is required after ',' comma-spacing 31:68 error Strings must use singlequote quotes **CzechIdMng/Realization/frontend/czechidm-core/src/utils/UiUtils.js 187:9 error Keyword "if" must be followed by whitespace space-after-keywords 187:35 error Missing space before opening brace space-before-blocks 188:18 error Strings must use singlequote quotes 217:9 error Keyword "if" must be followed by whitespace space-after-keywords 217:35 error Missing space before opening brace space-before-blocks 218:18 error Strings must use singlequote quotes
you don't probably set up eslint validation in your IDE, try check this guide: https://wiki.czechidm.com/7.6/dev/quickstart/ide/atom atom is good IDE for developing our FE devstack, or try something else with eslint plugin eg: sublimetext.
- change czech language in test to english (if you find some czech words in test, feel free to update it into english :)
after you fix eslint issues and czech words give me this ticket back I will continue with feedback.
Updated by Petr Adamec about 6 years ago
- Status changed from In Progress to Needs feedback
- Assignee changed from Petr Adamec to Ondřej Kopr
- % Done changed from 80 to 100
add space after comma, change czech words
Updated by Ondřej Kopr about 6 years ago
- % Done changed from 100 to 90
I made second review, all these things are already fixed:
- parameter suffix should be null as describes Radek in the task, but I'm ok with your solution,
- you missed still some czech words in comments.
Thank you for change these methods.
One think for next time, when you add some ticket to review set it 90% not 100% and please add some information about commits and branch, where I find your solution :)
my commit: https://github.com/bcvsolutions/CzechIdMng/commit/040b045527e8dd98e99f9258a2e4e0dcc8f721fc
pull request: https://github.com/bcvsolutions/CzechIdMng/pull/14
Please Radek could you check his solution?
Updated by Ondřej Kopr about 6 years ago
- Assignee changed from Ondřej Kopr to Radek Tomiška
Updated by Radek Tomiška about 6 years ago
- Status changed from Needs feedback to Closed
- Assignee changed from Radek Tomiška to Petr Adamec
- Target version set to Garnet (7.7.0)
I fixed short methods, when empty string is given. Thx for methods improving. I fixed short methods, when empty string is given. Thx for methods improving. I added these methods on all places in app (where todos were).