JustCarmen / webtrees-fancy-treeview

Fancy Treeview Module for webtrees

Home Page:http://justcarmen.nl

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

feature request : possibility to display note

Fa10175 opened this issue · comments

in the future, having the ability to view the notes would be a plus
I know it's a lot of work.
thank you

What kind of notes are you talking about?

There are level 1, 2 and 3 notes
There are inline notes and shared notes

Some notes can contain quite a lot of text. I am not sure if we want those on the Fancy Treeview page (or tab).

the notes I would like to see would be "inline notes".
Some notes can contain quite a lot of text, this is true.

the consultation for me would be only on the screen.

see
Screenshot 2022-12-27 at 10-59-17 King George V 1865–1936 – webtrees

I just tested this locally.
It works well for me.
Great
thanks

just for your information adding the notes is correct but in this version of the file "at the age of" is not translate

if I replace
near line 1388

   $html     = '';
    if ($bdate->isOK() && $ddate->isOK() && $this->isDateDMY($bfact) && $this->isDateDMY($dfact)) {
        $ageAtDeath = new Age($bdate, $ddate);
        $html .= ' ' . /* I18N: %s is a string e.g. 2 days/months/years */ I18N::translate('at the age of %s', $ageAtDeath);
    }
    return $html;

by

    if ($bdate->isOK() && $ddate->isOK() && $this->isDateDMY($bfact) && $this->isDateDMY($dfact)) {
        $ageAtDeath = (string) new Age($bdate, $ddate);
        if ($ageAtDeath < 2) {
            $html .= ' ' . /* I18N: %s is the age of death in days/months; %s is a string, e.g. at the age of 2 months */ I18N::translateContext('age in days/months', 'at the age of %s', $ageAtDeath);
        } else {
            $html .= ' ' . /* I18N: %s is the age of death in years; %s is a number, e.g. at the age of 40. If necessary add the term 'years' (always plural) to the string */ I18N::translateContext('age in years', 'at the age of %s', filter_var($ageAtDeath, FILTER_SANITIZE_NUMBER_INT));
        }
    }
    return $html;

it's ok

commented

This is caused by commit #117. I've fixed a bug regarding age calculation. Due to this change a new language string is introduced. I haven't updated the language files yet, so that is why you see an untranslated string.