-
Notifications
You must be signed in to change notification settings - Fork 44
[FINNA-2600] Add tooltips + pre & post additions templates to my account pages #3392
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
base: dev
Are you sure you want to change the base?
Conversation
…nna-2600 # Conflicts: # themes/finna2/templates/checkouts/history.phtml # themes/finna2/templates/holds/list.phtml # themes/finna2/templates/librarycards/home.phtml # themes/finna2/templates/myresearch/checkedout.phtml # themes/finna2/templates/myresearch/fines.phtml # themes/finna2/templates/myresearch/illrequests.phtml # themes/finna2/templates/myresearch/mylist.phtml # themes/finna2/templates/myresearch/profile.phtml # themes/finna2/templates/myresearch/storageretrievalrequests.phtml
…s + fixes for additions
|
Jos upstreamista oli tulossa merge, niin voi huikata ja teen PR:lle mergen sen upstreamin mergen valmistuttua. |
|
@tmikkonen Merge tuli, voipi tehdä tänne kans. |
…nna-2600 # Conflicts: # themes/finna2/templates/ratings/userlist.phtml
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Tyhjiä Additions-sivupohjia ei kannata lisätä valmiiksi, kun ne sitten rendataan, vaikkei olisi mitään sisältöä.
| </div> | ||
| <div id="useraccount-content-heading" class="useraccount-header"> | ||
| <?=$this->component('page-title', ['title' => $this->translate('Loan History') . " ($recordCount)", 'headTitle' => $this->translate('Loan History')]);?> | ||
| <?php if (!$this->translationEmpty('tooltip_myaccount_checkouts_history_html')): ?> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Tämän voisi upottaa laajennettuun page-title -komponenttiin (vaikka page-title-with-tip) optioksi niin, että sille voi antaa vaikka tip-parametrin, ja jos sillä löytyy käännös, niin se tekee tuon nappulankin saman tien. Sillä voisi välttää paljon toistoa.
| <li class="nav-item" role="presentation" id="user-content-<?=$this->escapeHtmlAttr($tab)?>" data-tab="<?=$this->escapeHtmlAttr($tab)?>"><a class="<?='comments' === $tab ? 'active' : ''?> nav-link" href="<?=$this->url($tab . '-' . 'userlist')?>"><?=$this->transEsc($title)?></a></li> | ||
| <?php endforeach; ?> | ||
| </ul> | ||
| <?php if ($template = $this->content()->findTemplateForLng('content/Additions/comments-pre-list')): ?> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Näistäkin voisi tehdä komponentin, jolloin voisi rendata yhdellä rivillä, esim.
<?=$this->component('addition-template', ['class' => 'comments-pre', 'template' => 'comments-pre-list'])?>
Additions-pohjia tuli kieliversioineen iso läjä. Näitä oli organisaatioilta toivottu, mutta jos olisi huono asia lisätä pohjat valmiiksi, niin toinen vaihtoehto voisi olla jättää templaattitiedostot pois, mutta tehdä Finna-ohjeisiin lista, millä nimellä tiedostot tulee itse lisätä, jos niitä haluaa käyttää.
Additions-tiedostojen liittämisessä menty valmiina olleen tavan mukaan:
Nimeämisissä on pieniä epäloogisuuksia, joihin en puuttunut, koska osalla kirjastoja on jo käytössä:
Lisäksi valmiina olleissa post-list-pohjissa oli pieniä eroavaisuuksia sivutuksen kohdalla eli jossain
post-lista oli paginaattoria ennen, jossain sen jälkeen. En muuttanut siltä varalta, että tähän oli joku syy - voin yhtenäistää kaikki jompaan kumpaan tapaan, jos on parempi.