Re-placed alphabet navigation as horizontal. Fixed several problems in NarrativeWeb, and some changes to WebCal.
svn: r13231
This commit is contained in:
parent
2e3ba0d954
commit
52d573eba8
@ -32,7 +32,6 @@ see <http://www.gnu.org/licenses/>.
|
|||||||
--------------------------------------------------------------------------------------------------
|
--------------------------------------------------------------------------------------------------
|
||||||
Color Palette
|
Color Palette
|
||||||
--------------------------------------------------------------------------------------------------
|
--------------------------------------------------------------------------------------------------
|
||||||
brown darkest #453619
|
|
||||||
brown dark #542
|
brown dark #542
|
||||||
brown light #C1B398
|
brown light #C1B398
|
||||||
gray #696969
|
gray #696969
|
||||||
@ -50,18 +49,10 @@ Females Web_Gender_Female.png
|
|||||||
|
|
||||||
# $Id$
|
# $Id$
|
||||||
|
|
||||||
NarrativeWeb Styles
|
|
||||||
--------------------------------------------------------------------------------------------
|
|
||||||
|
|
||||||
General Elements
|
General Elements
|
||||||
----------------------------------------------------- */
|
----------------------------------------------------- */
|
||||||
|
|
||||||
body {
|
body {
|
||||||
color: #000;
|
|
||||||
margin: 0;
|
|
||||||
padding: 130px 0px 0px 0px;
|
|
||||||
background-color: #FFF;
|
background-color: #FFF;
|
||||||
font-family: Arial, sans, sans-serif, Helvetica;
|
|
||||||
}
|
}
|
||||||
div {
|
div {
|
||||||
margin:0;
|
margin:0;
|
||||||
@ -136,7 +127,7 @@ h4 {
|
|||||||
color: #FFF;
|
color: #FFF;
|
||||||
margin-top: .3cm;
|
margin-top: .3cm;
|
||||||
padding:.2em 0 .2em 20px;
|
padding:.2em 0 .2em 20px;
|
||||||
background-color: #453619;
|
background-color: #000;
|
||||||
border-bottom:solid 4px #5D835F;
|
border-bottom:solid 4px #5D835F;
|
||||||
}
|
}
|
||||||
h5, h6 {
|
h5, h6 {
|
||||||
@ -144,6 +135,17 @@ h5, h6 {
|
|||||||
font-style:italic;
|
font-style:italic;
|
||||||
margin:1.3em 0 .5em 1em;
|
margin:1.3em 0 .5em 1em;
|
||||||
}
|
}
|
||||||
|
a {
|
||||||
|
color: #542;
|
||||||
|
}
|
||||||
|
a:visited {
|
||||||
|
color: #542;
|
||||||
|
}
|
||||||
|
a:hover {
|
||||||
|
color: #000;
|
||||||
|
background-color: #C1B398;
|
||||||
|
text-decoration:underline;
|
||||||
|
}
|
||||||
p#description {
|
p#description {
|
||||||
max-width:800px;
|
max-width:800px;
|
||||||
margin:0;
|
margin:0;
|
||||||
@ -153,10 +155,6 @@ p#description:first-letter {
|
|||||||
color: #228A22;
|
color: #228A22;
|
||||||
font-size:xx-large;
|
font-size:xx-large;
|
||||||
}
|
}
|
||||||
p a {
|
|
||||||
color: #FFF;
|
|
||||||
text-decoration:underline;
|
|
||||||
}
|
|
||||||
sup {
|
sup {
|
||||||
line-height:0;
|
line-height:0;
|
||||||
}
|
}
|
||||||
@ -173,17 +171,6 @@ ol li a {
|
|||||||
ol li a:hover {
|
ol li a:hover {
|
||||||
text-decoration:underline;
|
text-decoration:underline;
|
||||||
}
|
}
|
||||||
a {
|
|
||||||
color: #542;
|
|
||||||
}
|
|
||||||
a:visited {
|
|
||||||
color: #542;
|
|
||||||
}
|
|
||||||
a:hover {
|
|
||||||
color: #000;
|
|
||||||
background-color: #C1B398;
|
|
||||||
text-decoration:underline;
|
|
||||||
}
|
|
||||||
span.preposition {
|
span.preposition {
|
||||||
padding-left:1em;
|
padding-left:1em;
|
||||||
padding-right:1em;
|
padding-right:1em;
|
||||||
@ -197,7 +184,8 @@ span.preposition {
|
|||||||
----------------------------------------------------- */
|
----------------------------------------------------- */
|
||||||
#header {
|
#header {
|
||||||
position: fixed;
|
position: fixed;
|
||||||
top: 0;
|
top: 0px;
|
||||||
|
left: 0px;
|
||||||
overflow: auto;
|
overflow: auto;
|
||||||
width: 100%;
|
width: 100%;
|
||||||
height: 90px;
|
height: 90px;
|
||||||
@ -205,16 +193,13 @@ span.preposition {
|
|||||||
background-color: #542;
|
background-color: #542;
|
||||||
border-bottom: solid 8px #5D835F;
|
border-bottom: solid 8px #5D835F;
|
||||||
}
|
}
|
||||||
body#WebCal #header, body#fullyearlinked #header {
|
|
||||||
width: 100%;
|
|
||||||
height; 90px;
|
|
||||||
}
|
|
||||||
#SiteTitle {
|
#SiteTitle {
|
||||||
margin:0;
|
margin:0;
|
||||||
padding:.5em 0 0.5em 10px;
|
padding:.5em 0 0.5em 10px;
|
||||||
font-size: 40px;
|
font-size: 36px;
|
||||||
|
font-weight: bold;
|
||||||
color: #FFF;
|
color: #FFF;
|
||||||
font-style:italic;
|
font-style: italic;
|
||||||
}
|
}
|
||||||
p#user_header {
|
p#user_header {
|
||||||
font-size:1.3em;
|
font-size:1.3em;
|
||||||
@ -278,60 +263,38 @@ p#user_header {
|
|||||||
padding:0;
|
padding:0;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Alphabet Navigation
|
|
||||||
----------------------------------------------------- */
|
|
||||||
div#alphabet {
|
|
||||||
padding:0;
|
|
||||||
margin:0;
|
|
||||||
}
|
|
||||||
div#alphabet ul {
|
|
||||||
list-style:none;
|
|
||||||
min-width:770px;
|
|
||||||
height:24px;
|
|
||||||
margin:0;
|
|
||||||
padding:0 0 0 9px;
|
|
||||||
border-top:solid 2px #000;
|
|
||||||
border-bottom:solid 4px #000;
|
|
||||||
background-color: #6AF364;
|
|
||||||
}
|
|
||||||
div#alphabet ul li:after {
|
|
||||||
content:" |";
|
|
||||||
}
|
|
||||||
div#alphabet ul li:first-child {
|
|
||||||
content: " |";
|
|
||||||
}
|
|
||||||
div#alphabet ul li.letters {
|
|
||||||
margin:0;
|
|
||||||
float:left;
|
|
||||||
}
|
|
||||||
div#alphabet ul li.letters a {
|
|
||||||
display:block;
|
|
||||||
float:left;
|
|
||||||
font:bold 16px/100% sans;
|
|
||||||
color: #000;
|
|
||||||
margin:0;
|
|
||||||
padding:5px 5px;
|
|
||||||
text-decoration:none;
|
|
||||||
}
|
|
||||||
div#alphabet ul li.letters a:hover {
|
|
||||||
background-color: #000;
|
|
||||||
color: #FFF;
|
|
||||||
}
|
|
||||||
|
|
||||||
/* Navigation
|
/* Navigation
|
||||||
----------------------------------------------------- */
|
----------------------------------------------------- */
|
||||||
#navigation {
|
div#nnavigation, div#subnavigation {
|
||||||
|
width: 100%;
|
||||||
|
height: 32px;
|
||||||
|
}
|
||||||
|
body#NarrativeWeb #navigation {
|
||||||
position: fixed;
|
position: fixed;
|
||||||
top: 104px;
|
top: 104px;
|
||||||
width: 100%;
|
left: 0px;
|
||||||
height: 52px;
|
|
||||||
}
|
}
|
||||||
body#WebCal #navigation, body#fullyearlinked #navigation {
|
body#WebCal #navigation {
|
||||||
width: 100%;
|
position: fixed;
|
||||||
height: 52px;
|
top: 140px;
|
||||||
|
left: 24px;
|
||||||
|
right: 20px;
|
||||||
}
|
}
|
||||||
#subnavigation {
|
body#fullyearlinked #navigation, body#OneDay #navigation {
|
||||||
width: 100%;
|
position: fixed;
|
||||||
|
top: 140px;
|
||||||
|
left: 0px;
|
||||||
|
}
|
||||||
|
body#WebCal #subnavigation {
|
||||||
|
position: fixed;
|
||||||
|
top: 98px;
|
||||||
|
left: 24px;
|
||||||
|
right: 20px;
|
||||||
|
}
|
||||||
|
body#fullyearlinked #subnavigation, body#OneDay #subnavigation {
|
||||||
|
position: fixed;
|
||||||
|
top: 98px;
|
||||||
|
left: 0px;
|
||||||
}
|
}
|
||||||
#navigation ul, #subnavigation ul {
|
#navigation ul, #subnavigation ul {
|
||||||
list-style:none;
|
list-style:none;
|
||||||
@ -339,45 +302,49 @@ body#WebCal #navigation, body#fullyearlinked #navigation {
|
|||||||
height:32px;
|
height:32px;
|
||||||
margin:0;
|
margin:0;
|
||||||
padding:0 0 0 20px;
|
padding:0 0 0 20px;
|
||||||
background-color: #FFF;
|
border-bottom:solid 2px #5D835F;
|
||||||
border-bottom:solid 2px #000;
|
|
||||||
}
|
}
|
||||||
#navigation ul li, #subnavigation ul li {
|
#navigation ul li, #subnavigation ul li {
|
||||||
margin:0;
|
margin:0;
|
||||||
float:left;
|
float:left;
|
||||||
}
|
}
|
||||||
#navigation ul li a, #subnavigation ul li a {
|
#navigation ul li a, #subnavigation ul li a {
|
||||||
|
padding: 6px 10px 8px 1px;
|
||||||
display:block;
|
display:block;
|
||||||
float:left;
|
float:left;
|
||||||
font:normal 16px/100% serif;
|
font:normal 16px/100% serif;
|
||||||
color: #000;
|
color: #000;
|
||||||
text-decoration:none;
|
text-decoration:none;
|
||||||
margin:0;
|
margin:0;
|
||||||
padding:5px 5px;
|
}
|
||||||
|
body#WebCal #navigation ul li a, body#fullyearlinked #navigation ul li a,
|
||||||
|
body#WebCal #subnavigation ul li a {
|
||||||
|
color: #FFF;
|
||||||
|
}
|
||||||
|
body#fullyearlinked #subnavigation ul li a {
|
||||||
|
color: #000;
|
||||||
}
|
}
|
||||||
#navigation ul li a:hover, #subnavigation ul li a:hover {
|
#navigation ul li a:hover, #subnavigation ul li a:hover {
|
||||||
|
margin-top: -6px;
|
||||||
|
padding: 11px 10px 12px 1px;
|
||||||
background-color: #C1B398;
|
background-color: #C1B398;
|
||||||
color: #000;
|
color: #000;
|
||||||
border-top:solid 3px #C1B398;
|
|
||||||
border-bottom:solid 8px #C1B398;
|
|
||||||
}
|
}
|
||||||
#navigation ul li.CurrentSection a, #subnavigation ul li.CurrentSection a {
|
#navigation ul li.CurrentSection a, #subnavigation ul li.CurrentSection a {
|
||||||
font-weight:bold;
|
font-weight:bold;
|
||||||
font-size:16px;
|
font-style: italic;
|
||||||
margin-top:-6px;
|
margin-top:-6px;
|
||||||
padding-top:11px;
|
padding: 11px 10px 12px 1px;
|
||||||
padding-bottom:8px;
|
|
||||||
background-color: #CCC;
|
background-color: #CCC;
|
||||||
color: #000;
|
color: #000;
|
||||||
border-bottom:solid 4px #CCC;
|
|
||||||
}
|
}
|
||||||
#navigation ul li.CurrentSection a:hover {
|
#navigation ul li.CurrentSection a:hover {
|
||||||
background-color: #000;
|
background-color: #000;
|
||||||
color: #FFF;
|
color: #FFF;
|
||||||
}
|
}
|
||||||
#subnavigation ul li.CurrentSection a {
|
#subnavigation ul li.CurrentSection a {
|
||||||
border-width:0 0 1px 0;
|
border-width: 0px 0px 2px 0px;
|
||||||
|
border-color: #FFF;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Main Table
|
/* Main Table
|
||||||
@ -389,12 +356,13 @@ table.infolist {
|
|||||||
font-size: 12px;
|
font-size: 12px;
|
||||||
}
|
}
|
||||||
table.infolist thead tr th {
|
table.infolist thead tr th {
|
||||||
font:normal 1.1em/1.2em serif;
|
font:bold 1.1em/1.2em serif;
|
||||||
|
text-transform: uppercase;
|
||||||
color: #000;
|
color: #000;
|
||||||
margin:0;
|
margin:0;
|
||||||
padding:.2em 10px;
|
padding:.2em 10px;
|
||||||
background-color: #6AF364;
|
background-color: #6AF364;
|
||||||
border: solid 1px #5D835F;
|
border: solid 1px #000;
|
||||||
}
|
}
|
||||||
table.infolist thead tr th a {
|
table.infolist thead tr th a {
|
||||||
background-color: #6AF364;
|
background-color: #6AF364;
|
||||||
@ -414,7 +382,7 @@ table.infolist tr td a {
|
|||||||
color: #000;
|
color: #000;
|
||||||
}
|
}
|
||||||
table.infolist tr.BeginLetter td, table.infolist tr.BeginSurname td {
|
table.infolist tr.BeginLetter td, table.infolist tr.BeginSurname td {
|
||||||
border-top:solid 1px #453619;
|
border-top:solid 1px #000;
|
||||||
}
|
}
|
||||||
table.infolist tr td.ColumnLetter {
|
table.infolist tr td.ColumnLetter {
|
||||||
width:3%;
|
width:3%;
|
||||||
@ -458,6 +426,55 @@ table.infolist tbody tr td.ColumnParents span.mother:before {
|
|||||||
content:"+ ";
|
content:"+ ";
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/*
|
||||||
|
NarrativeWeb
|
||||||
|
----------------------------------------------------- */
|
||||||
|
body#NarrativeWeb {
|
||||||
|
color: #000;
|
||||||
|
margin: 0;
|
||||||
|
padding: 160px 0px 0px 4px;
|
||||||
|
background-color: #FFF;
|
||||||
|
font-family: Arial, sans, sans-serif, Helvetica;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Alphabet Navigation
|
||||||
|
----------------------------------------------------- */
|
||||||
|
div#alphabet {
|
||||||
|
position: fixed;
|
||||||
|
top: 136px;
|
||||||
|
left: 4px;
|
||||||
|
width: 100%;
|
||||||
|
height: 32px;
|
||||||
|
overflow: auto;
|
||||||
|
border-width: 2px 4px 2px 4px;
|
||||||
|
border-style: solid;
|
||||||
|
border-color: #5D835F;
|
||||||
|
background-color: #6AF364;
|
||||||
|
}
|
||||||
|
div#alphabet ul {
|
||||||
|
display: block;
|
||||||
|
list-style: none;
|
||||||
|
margin: 0;
|
||||||
|
padding: 0px 0px 0px 20px;
|
||||||
|
}
|
||||||
|
div#alphabet ul li {
|
||||||
|
display: block;
|
||||||
|
padding: 6px 0px 6px 16px;
|
||||||
|
font: bold 16px/100% sans;
|
||||||
|
margin:0;
|
||||||
|
float: left;
|
||||||
|
}
|
||||||
|
div#alphabet ul li:before {
|
||||||
|
content: "| ";
|
||||||
|
}
|
||||||
|
div#alphabet ul li a {
|
||||||
|
text-decoration: none;
|
||||||
|
}
|
||||||
|
div#alphabet ul li a:hover {
|
||||||
|
padding: 20px 8px 10px 4px;
|
||||||
|
background-color: #C1B398;
|
||||||
|
}
|
||||||
|
|
||||||
/* Surnames
|
/* Surnames
|
||||||
----------------------------------------------------- */
|
----------------------------------------------------- */
|
||||||
#Surnames { }
|
#Surnames { }
|
||||||
@ -487,6 +504,9 @@ table.surnamelist thead tr th.ColumnLetter {
|
|||||||
table.surnamelist tbody tr td {
|
table.surnamelist tbody tr td {
|
||||||
background-color: #D8F3D6;
|
background-color: #D8F3D6;
|
||||||
}
|
}
|
||||||
|
table.surnamelist tbody tr td.ColumnLetter a {
|
||||||
|
background: none;
|
||||||
|
}
|
||||||
table.surnamelist tbody tr td.ColumnSurname {
|
table.surnamelist tbody tr td.ColumnSurname {
|
||||||
background-color: #FFF;
|
background-color: #FFF;
|
||||||
}
|
}
|
||||||
@ -514,30 +534,30 @@ table.surnamelist tbody tr td.ColumnSurname:hover,
|
|||||||
table.surname {
|
table.surname {
|
||||||
border-bottom:solid 1px #000;
|
border-bottom:solid 1px #000;
|
||||||
}
|
}
|
||||||
table.surname tbody tr td {
|
|
||||||
border-bottom:dashed 1px #000;
|
|
||||||
}
|
|
||||||
table.surname thead tr th.ColumnName {
|
table.surname thead tr th.ColumnName {
|
||||||
width:20%;
|
width:20%;
|
||||||
padding-left:20px;
|
padding-left:20px;
|
||||||
}
|
}
|
||||||
table.surname tbody tr td.ColumnName {
|
table.surname tbody tr td {
|
||||||
background-color: #FFF;
|
border-bottom: dashed 1px #000;
|
||||||
width:20%;
|
background-color: #D8F3D6;
|
||||||
padding:0;
|
|
||||||
}
|
}
|
||||||
table.surname tbody tr td.ColumnName a {
|
table.surname tbody tr td a {
|
||||||
display:block;
|
display: block;
|
||||||
padding:.6em 10px .6em 20px;
|
padding: .6em 10px .6em 20px;
|
||||||
|
background-color: #FFF;
|
||||||
|
}
|
||||||
|
table.surname tbody tr td a:hover {
|
||||||
|
background-color: #C1B398;
|
||||||
|
}
|
||||||
|
table.surname tbody tr td.ColumnName {
|
||||||
|
width:20%;
|
||||||
}
|
}
|
||||||
table.surname tbody tr td.ColumnName a span.grampsid { }
|
table.surname tbody tr td.ColumnName a span.grampsid { }
|
||||||
|
|
||||||
table.surname tbody tr td.ColumnName:hover {
|
table.surname tbody tr td.ColumnName:hover {
|
||||||
background-color: #C1B398;
|
background-color: #C1B398;
|
||||||
}
|
}
|
||||||
table.surname tbody tr td.ColumnPartner {
|
|
||||||
background-color: #FFF;
|
|
||||||
}
|
|
||||||
table.surname thead tr th.ColumnParents,
|
table.surname thead tr th.ColumnParents,
|
||||||
table.surname tbody tr td.ColumnParents {
|
table.surname tbody tr td.ColumnParents {
|
||||||
width:25%;
|
width:25%;
|
||||||
@ -548,12 +568,19 @@ table.surname tbody tr td.ColumnParents {
|
|||||||
#Individuals { }
|
#Individuals { }
|
||||||
|
|
||||||
#Individuals table.individuallist {
|
#Individuals table.individuallist {
|
||||||
border-bottom:solid 1px #453619;
|
border-bottom:solid 1px #5D835F;
|
||||||
}
|
}
|
||||||
#Individuals table.individuallist tbody tr td {
|
#Individuals table.individuallist tbody tr td {
|
||||||
border-bottom:dashed 1px #453619;
|
border-bottom: dashed 1px #000;
|
||||||
|
background-color: #D8F3D6;
|
||||||
|
}
|
||||||
|
#Individuals table.individuallist tbody tr td a {
|
||||||
|
background-color: #FFF;
|
||||||
|
display: block;
|
||||||
|
padding: .6em 10px;
|
||||||
}
|
}
|
||||||
#Individuals table.individuallist tbody tr td a:hover {
|
#Individuals table.individuallist tbody tr td a:hover {
|
||||||
|
background-color: #C1B398;
|
||||||
text-decoration:none;
|
text-decoration:none;
|
||||||
}
|
}
|
||||||
table.individuallist tbody tr td.ColumnSurname a:hover,
|
table.individuallist tbody tr td.ColumnSurname a:hover,
|
||||||
@ -564,25 +591,9 @@ table.individuallist tbody tr td.ColumnSurname a:active {
|
|||||||
}
|
}
|
||||||
table.individuallist tbody tr td.ColumnName {
|
table.individuallist tbody tr td.ColumnName {
|
||||||
padding:0;
|
padding:0;
|
||||||
background-color: #FFF;
|
|
||||||
}
|
}
|
||||||
table.individuallist tbody tr td.ColumnName a {
|
|
||||||
display:block;
|
|
||||||
padding:.6em 10px;
|
|
||||||
vertical-align:middle;
|
|
||||||
}
|
|
||||||
table.individuallist tbody tr td.ColumnName a:hover { }
|
|
||||||
|
|
||||||
table.individuallist tbody tr td.ColumnPartner {
|
table.individuallist tbody tr td.ColumnPartner {
|
||||||
padding:0;
|
padding:0;
|
||||||
background-color: #FFF;
|
|
||||||
}
|
|
||||||
table.individuallist tbody tr td.ColumnPartner a {
|
|
||||||
display:block;
|
|
||||||
padding:.6em 10px;
|
|
||||||
vertical-align:middle;
|
|
||||||
}
|
|
||||||
table.individuallist tbody tr td.ColumnPartner a:hover {
|
|
||||||
}
|
}
|
||||||
#Individuals div table.infolist tr td p {
|
#Individuals div table.infolist tr td p {
|
||||||
font:normal .9em/1.2em sans-serif;
|
font:normal .9em/1.2em sans-serif;
|
||||||
@ -592,8 +603,6 @@ table.individuallist tbody tr td.ColumnPartner a:hover {
|
|||||||
display:inline;
|
display:inline;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* IndividualDetail
|
|
||||||
------------------------------------------------------ */
|
|
||||||
#IndividualDetail { }
|
#IndividualDetail { }
|
||||||
|
|
||||||
#IndividualDetail div table.infolist tr td {
|
#IndividualDetail div table.infolist tr td {
|
||||||
@ -640,31 +649,39 @@ table.eventlist tbody tr td {
|
|||||||
background-color: #D8F3D6;
|
background-color: #D8F3D6;
|
||||||
padding: 4px 0px 4px 0px;
|
padding: 4px 0px 4px 0px;
|
||||||
}
|
}
|
||||||
|
table.eventlist tbody tr td a {
|
||||||
|
display: block;
|
||||||
|
padding: .3em 30px .4em 0px;
|
||||||
|
}
|
||||||
|
table.eventlist tbody tr td a:hover {
|
||||||
|
background-color: #C1B398;
|
||||||
|
}
|
||||||
table.eventlist tbody tr td.ColumnType {
|
table.eventlist tbody tr td.ColumnType {
|
||||||
background-color: #FFF;
|
|
||||||
border-top: solid 1px #5D835F;
|
border-top: solid 1px #5D835F;
|
||||||
width: 20%;
|
width: 20%;
|
||||||
}
|
}
|
||||||
|
table.eventlist tbody tr td.ColumnType a {
|
||||||
|
background-color: #FFF;
|
||||||
|
}
|
||||||
table.eventlist tbody tr td.ColumnDate {
|
table.eventlist tbody tr td.ColumnDate {
|
||||||
width: 16%;
|
width: 16%;
|
||||||
}
|
}
|
||||||
table.eventlist tbody tr td.ColumnPlace {
|
table.eventlist tbody tr td.ColumnPlace {
|
||||||
background-color: #FFF;
|
|
||||||
width: 35%;
|
width: 35%;
|
||||||
}
|
}
|
||||||
table.eventlist tbody tr td.ColumnSources {
|
table.eventlist tbody tr td.ColumnSources {
|
||||||
background-color: #FFF;
|
|
||||||
width: 12%;
|
width: 12%;
|
||||||
}
|
}
|
||||||
|
table.eventlist tbody tr td.ColumnSources sup {
|
||||||
|
margin-top: 1em;
|
||||||
|
}
|
||||||
table.eventlist tbody tr td.ColumnNotes {
|
table.eventlist tbody tr td.ColumnNotes {
|
||||||
width: 25%;
|
width: 25%;
|
||||||
}
|
}
|
||||||
table.eventlist tbody tr td.ColumnPerson {
|
table.eventlist tbody tr td.ColumnPerson {
|
||||||
background-color: #FFF;
|
|
||||||
width: 35%;
|
width: 35%;
|
||||||
}
|
}
|
||||||
table.eventlist tbody tr td.ColumnPartner {
|
table.eventlist tbody tr td.ColumnPartner {
|
||||||
background-color: #FFF;
|
|
||||||
width: 35%;
|
width: 35%;
|
||||||
}
|
}
|
||||||
div#EventDetail h3 {
|
div#EventDetail h3 {
|
||||||
@ -713,7 +730,7 @@ div#EventDetail table.eventlist tbody tr td.ColumnType {
|
|||||||
#GalleryNav a {
|
#GalleryNav a {
|
||||||
font-weight:bold;
|
font-weight:bold;
|
||||||
text-decoration:none;
|
text-decoration:none;
|
||||||
border:solid 1px #453619;
|
border:solid 1px #5D835F;
|
||||||
}
|
}
|
||||||
#GalleryNav a:hover { }
|
#GalleryNav a:hover { }
|
||||||
|
|
||||||
@ -738,7 +755,7 @@ div#EventDetail table.eventlist tbody tr td.ColumnType {
|
|||||||
position:relative;
|
position:relative;
|
||||||
overflow:hidden;
|
overflow:hidden;
|
||||||
text-align:center;
|
text-align:center;
|
||||||
border:solid 1px #453619;
|
border:solid 1px #5D835F;
|
||||||
}
|
}
|
||||||
#GalleryDisplay img {
|
#GalleryDisplay img {
|
||||||
margin:0 auto;
|
margin:0 auto;
|
||||||
@ -777,7 +794,7 @@ table.exiflist tr td.ColumnValue {
|
|||||||
width:500px;
|
width:500px;
|
||||||
margin:0 auto;
|
margin:0 auto;
|
||||||
padding:3em;
|
padding:3em;
|
||||||
border:double 4px #453619;
|
border:double 4px #5D835F;
|
||||||
}
|
}
|
||||||
#Contact #summaryarea img {
|
#Contact #summaryarea img {
|
||||||
float:right;
|
float:right;
|
||||||
@ -970,17 +987,16 @@ div#events h4 {
|
|||||||
padding-left:20px;
|
padding-left:20px;
|
||||||
}
|
}
|
||||||
#IndividualDetail div#events table.infolist tbody tr td {
|
#IndividualDetail div#events table.infolist tbody tr td {
|
||||||
padding-top:.4em;
|
padding: .4em 0 .8em 0;
|
||||||
padding-bottom:.8em;
|
|
||||||
}
|
}
|
||||||
#IndividualDetail div#events table.infolist tbody tr td.ColumnAttribute {
|
#IndividualDetail div#events table.infolist tbody tr td.ColumnAttribute {
|
||||||
border-bottom:solid 1px #453619;
|
border-bottom:solid 1px #5D835F;
|
||||||
}
|
}
|
||||||
#IndividualDetail div#events table.infolist tbody tr td.ColumnValue {
|
#IndividualDetail div#events table.infolist tbody tr td.ColumnValue {
|
||||||
border-bottom:solid 1px #000;
|
border-bottom:solid 1px #5D835F;
|
||||||
}
|
}
|
||||||
table.infolist tbody tr td.ColumnValue p {
|
table.infolist tbody tr td.ColumnValue p {
|
||||||
font-family:sans-serif;
|
font-family: sans-serif;
|
||||||
color: #696969;
|
color: #696969;
|
||||||
margin:.2em 0 0 2em;
|
margin:.2em 0 0 2em;
|
||||||
}
|
}
|
||||||
@ -1297,7 +1313,7 @@ div#pedigree {
|
|||||||
margin-top:-25px;
|
margin-top:-25px;
|
||||||
margin-left:16px;
|
margin-left:16px;
|
||||||
background-color: #FFF;
|
background-color: #FFF;
|
||||||
border:solid 1px #453619;
|
border:solid 1px #5D835F;
|
||||||
}
|
}
|
||||||
#treeContainer div.boxbg a:hover {
|
#treeContainer div.boxbg a:hover {
|
||||||
position:relative;
|
position:relative;
|
||||||
@ -1308,7 +1324,7 @@ div#pedigree {
|
|||||||
width:190px;
|
width:190px;
|
||||||
margin-left:-20px;
|
margin-left:-20px;
|
||||||
padding:10px 25px 12px 25px;
|
padding:10px 25px 12px 25px;
|
||||||
border:solid 2px #453619;
|
border:solid 2px #5D835F;
|
||||||
}
|
}
|
||||||
#treeContainer div.boxbg a:hover,
|
#treeContainer div.boxbg a:hover,
|
||||||
#treeContainer div.AncCol3 a:hover,
|
#treeContainer div.AncCol3 a:hover,
|
||||||
@ -1372,7 +1388,7 @@ div#pedigree {
|
|||||||
height:1px;
|
height:1px;
|
||||||
margin:0 0 0 16px;
|
margin:0 0 0 16px;
|
||||||
padding:0;
|
padding:0;
|
||||||
background-color: #453619;
|
background-color: #000;
|
||||||
}
|
}
|
||||||
#tree div div.bhline {
|
#tree div div.bhline {
|
||||||
position:absolute;
|
position:absolute;
|
||||||
@ -1380,7 +1396,7 @@ div#pedigree {
|
|||||||
width:1px;
|
width:1px;
|
||||||
margin:0 0 0 16px;
|
margin:0 0 0 16px;
|
||||||
padding:0;
|
padding:0;
|
||||||
background-color: #453619;
|
background-color: #000;
|
||||||
}
|
}
|
||||||
.ghline, .gvline {
|
.ghline, .gvline {
|
||||||
display:none;
|
display:none;
|
||||||
@ -1390,7 +1406,7 @@ div#pedigree {
|
|||||||
-------------------------------------------------------------------------------------------- */
|
-------------------------------------------------------------------------------------------- */
|
||||||
/* Calendar : General */
|
/* Calendar : General */
|
||||||
body#WebCal {
|
body#WebCal {
|
||||||
padding: 98px 14px 0px 14px;
|
padding: 170px 14px 0px 14px;
|
||||||
background-color: #542;
|
background-color: #542;
|
||||||
}
|
}
|
||||||
.calendar {
|
.calendar {
|
||||||
@ -1437,13 +1453,13 @@ body#WebCal {
|
|||||||
font-style:italic;
|
font-style:italic;
|
||||||
color: #000;
|
color: #000;
|
||||||
background-color: #6AF364;
|
background-color: #6AF364;
|
||||||
border:solid 2px #453619;
|
border:solid 2px #5D835F;
|
||||||
}
|
}
|
||||||
.calendar tfoot tr td {
|
.calendar tfoot tr td {
|
||||||
padding:.7em 5% 1em 5%;
|
padding:.7em 5% 1em 5%;
|
||||||
border-top:solid 2px #000;
|
border-top:solid 2px #000;
|
||||||
vertical-align:middle;
|
vertical-align:middle;
|
||||||
color: #453619;
|
color: #000;
|
||||||
background-color: #D8F3D6;
|
background-color: #D8F3D6;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -1468,7 +1484,7 @@ body#WebCal {
|
|||||||
padding:0;
|
padding:0;
|
||||||
border-width:1px 0 0 1px;
|
border-width:1px 0 0 1px;
|
||||||
border-style:solid;
|
border-style:solid;
|
||||||
border-color: #453619;
|
border-color: #5D835F;
|
||||||
}
|
}
|
||||||
.calendar tbody tr td.weekday {
|
.calendar tbody tr td.weekday {
|
||||||
background-color: #FFF;
|
background-color: #FFF;
|
||||||
@ -1477,13 +1493,13 @@ body#WebCal {
|
|||||||
background-color: #D8F3D6;
|
background-color: #D8F3D6;
|
||||||
}
|
}
|
||||||
.calendar tbody tr td.saturday {
|
.calendar tbody tr td.saturday {
|
||||||
border-right:solid 1px #453619;
|
border-right:solid 1px #5D835F;
|
||||||
}
|
}
|
||||||
.calendar tbody tr td.sunday {
|
.calendar tbody tr td.sunday {
|
||||||
border-left:solid 1px #453619;
|
border-left:solid 1px #5D835F;
|
||||||
}
|
}
|
||||||
.calendar tbody tr td:first-child {
|
.calendar tbody tr td:first-child {
|
||||||
border-left:solid 1px #453619;
|
border-left:solid 1px #5D835F;
|
||||||
}
|
}
|
||||||
.calendar tbody tr:first-child td {
|
.calendar tbody tr:first-child td {
|
||||||
border-top:none;
|
border-top:none;
|
||||||
@ -1502,7 +1518,7 @@ body#WebCal {
|
|||||||
width:92%;
|
width:92%;
|
||||||
margin:0 4%;
|
margin:0 4%;
|
||||||
padding:.2em 0 .3em 0;
|
padding:.2em 0 .3em 0;
|
||||||
border-top:dashed 1px #453619;
|
border-top:dashed 1px #000;
|
||||||
}
|
}
|
||||||
.calendar tbody tr td ul li:first-child {
|
.calendar tbody tr td ul li:first-child {
|
||||||
border:none;
|
border:none;
|
||||||
@ -1514,7 +1530,7 @@ body#WebCal {
|
|||||||
color: #0A65B5;
|
color: #0A65B5;
|
||||||
}
|
}
|
||||||
.calendar tbody tr td ul li span.yearsmarried em {
|
.calendar tbody tr td ul li span.yearsmarried em {
|
||||||
color: #453619;
|
color: #000;
|
||||||
}
|
}
|
||||||
.calendar tbody tr td.highlight { }
|
.calendar tbody tr td.highlight { }
|
||||||
|
|
||||||
@ -1534,7 +1550,7 @@ body#WebCal {
|
|||||||
|
|
||||||
/* Calendar : Full Year */
|
/* Calendar : Full Year */
|
||||||
body#fullyearlinked {
|
body#fullyearlinked {
|
||||||
padding: 98px 14px 0px 14px;
|
padding: 170px 0px 0px 0px;
|
||||||
}
|
}
|
||||||
body#fullyearlinked div.content {
|
body#fullyearlinked div.content {
|
||||||
width:963px;
|
width:963px;
|
||||||
@ -1545,7 +1561,7 @@ body#fullyearlinked table.calendar {
|
|||||||
float:left;
|
float:left;
|
||||||
width:320px;
|
width:320px;
|
||||||
height:18em;
|
height:18em;
|
||||||
border:solid 1px #453619;
|
border:solid 1px #5D835F;
|
||||||
}
|
}
|
||||||
body#fullyearlinked table.calendar thead tr th {
|
body#fullyearlinked table.calendar thead tr th {
|
||||||
height:2em;
|
height:2em;
|
||||||
@ -1563,3 +1579,8 @@ body#fullyearlinked table.calendar tbody tr td.saturday {
|
|||||||
body#fullyearlinked able.calendar tbody tr td.sunday {
|
body#fullyearlinked able.calendar tbody tr td.sunday {
|
||||||
border:solid 2px #000;
|
border:solid 2px #000;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/* Calendar : One Day */
|
||||||
|
body#OneDay {
|
||||||
|
padding: 170px 0px 0px 0px;
|
||||||
|
}
|
||||||
|
@ -255,6 +255,7 @@ class BasePage(object):
|
|||||||
self.noid = report.options['nogid']
|
self.noid = report.options['nogid']
|
||||||
self.linkhome = report.options['linkhome']
|
self.linkhome = report.options['linkhome']
|
||||||
self.create_media = report.options['gallery']
|
self.create_media = report.options['gallery']
|
||||||
|
self.inc_events = report.options['inc_events']
|
||||||
|
|
||||||
def dump_attribute(self, attr, showsrc):
|
def dump_attribute(self, attr, showsrc):
|
||||||
"""
|
"""
|
||||||
@ -271,7 +272,7 @@ class BasePage(object):
|
|||||||
("Value", attr.get_value() ) ]
|
("Value", attr.get_value() ) ]
|
||||||
|
|
||||||
if showsrc:
|
if showsrc:
|
||||||
srcrefs = self.get_citation_links(attr.get_source_references() )
|
srcrefs = self.get_citation_links(attr.get_source_references() ) or " "
|
||||||
source_row = ("Sources", srcrefs)
|
source_row = ("Sources", srcrefs)
|
||||||
attr_data_row.append(source_row)
|
attr_data_row.append(source_row)
|
||||||
|
|
||||||
@ -404,8 +405,7 @@ class BasePage(object):
|
|||||||
# return unordered note list to its callers
|
# return unordered note list to its callers
|
||||||
return unordered
|
return unordered
|
||||||
|
|
||||||
def display_event_row(self, evt, evt_ref, showplc, showdescr, showsrc,
|
def display_event_row(self, evt, evt_ref, showplc, showdescr, showsrc, shownote, subdirs, hyp):
|
||||||
shownote, subdirs, hyp):
|
|
||||||
"""
|
"""
|
||||||
display the event row for class IndividualPage
|
display the event row for class IndividualPage
|
||||||
|
|
||||||
@ -436,8 +436,7 @@ class BasePage(object):
|
|||||||
"""
|
"""
|
||||||
for more information: see get_event_data()
|
for more information: see get_event_data()
|
||||||
"""
|
"""
|
||||||
event_data = self.get_event_data(evt, evt_ref, showplc, showdescr, showsrc,
|
event_data = self.get_event_data(evt, evt_ref, showplc, showdescr, showsrc, shownote, subdirs, hyp)
|
||||||
shownote, subdirs, hyp)
|
|
||||||
|
|
||||||
for (label, colclass, data) in event_data:
|
for (label, colclass, data) in event_data:
|
||||||
data = data or " "
|
data = data or " "
|
||||||
@ -456,16 +455,21 @@ class BasePage(object):
|
|||||||
url = self.report.build_url_fname_html(handle, 'evt', up)
|
url = self.report.build_url_fname_html(handle, 'evt', up)
|
||||||
|
|
||||||
|
|
||||||
evt_hyper = Html('a', eventtype, href=url, title=eventtype)
|
# if event pages are being created, then hyperlink the event type
|
||||||
if not self.noid and gid:
|
if self.inc_events:
|
||||||
evt_hyper += Html('span', ' [%s] ' % gid, class_ = "grampsid",
|
evt_hyper = Html('a', eventtype, href=url, title=eventtype)
|
||||||
inline = True)
|
if not self.noid and gid:
|
||||||
|
evt_hyper += Html('span', ' [%s] ' % gid, class_ = "grampsid",
|
||||||
|
inline = True)
|
||||||
|
|
||||||
# return event hyper link to its callers
|
# return event hyper link to its callers
|
||||||
return evt_hyper
|
return evt_hyper
|
||||||
|
|
||||||
def get_event_data(self, evt, evt_ref, showplc, showdescr, showsrc, shownote,
|
# return just the eventtype
|
||||||
subdirs, hyper, gid=None):
|
else:
|
||||||
|
return eventtype
|
||||||
|
|
||||||
|
def get_event_data(self, evt, evt_ref, showplc, showdescr, showsrc, shownote, subdirs, hyp, gid=None):
|
||||||
"""
|
"""
|
||||||
retrieve event data from event and evt_ref
|
retrieve event data from event and evt_ref
|
||||||
|
|
||||||
@ -476,7 +480,7 @@ class BasePage(object):
|
|||||||
@param: showsrc = to show the event source references or not?
|
@param: showsrc = to show the event source references or not?
|
||||||
@param: shownote = show notes or not?
|
@param: shownote = show notes or not?
|
||||||
@param: subdirs = either True or False
|
@param: subdirs = either True or False
|
||||||
@param: hyper = to hyperlink the event type or not?
|
@param: hyp = to hyperlink the event type or not?
|
||||||
"""
|
"""
|
||||||
db = self.report.database
|
db = self.report.database
|
||||||
|
|
||||||
@ -484,7 +488,7 @@ class BasePage(object):
|
|||||||
evt_type = get_event_type(evt, evt_ref)
|
evt_type = get_event_type(evt, evt_ref)
|
||||||
|
|
||||||
# get hyperlink or not?
|
# get hyperlink or not?
|
||||||
if hyper:
|
if hyp:
|
||||||
evt_hyper = self.event_link(evt_type, evt_ref.ref, gid, subdirs)
|
evt_hyper = self.event_link(evt_type, evt_ref.ref, gid, subdirs)
|
||||||
else:
|
else:
|
||||||
evt_hyper = evt_type
|
evt_hyper = evt_type
|
||||||
@ -516,13 +520,14 @@ class BasePage(object):
|
|||||||
info.append(descr_row)
|
info.append(descr_row)
|
||||||
|
|
||||||
if showsrc:
|
if showsrc:
|
||||||
srcrefs = evt.get_source_references()
|
srcrefs = self.get_citation_links( evt.get_source_references() ) or " "
|
||||||
source_row = [SHEAD, 'Sources', srcrefs]
|
source_row = [SHEAD, 'Sources', srcrefs]
|
||||||
info.append(source_row)
|
info.append(source_row)
|
||||||
|
|
||||||
if shownote:
|
if shownote:
|
||||||
notelist = evt.get_note_list()
|
notelist = evt.get_note_list()
|
||||||
notelist.extend(evt_ref.get_note_list() )
|
notelist.extend(evt_ref.get_note_list() )
|
||||||
|
notelist = self.dump_notes(notelist)
|
||||||
note_row = [NHEAD, 'Notes', notelist]
|
note_row = [NHEAD, 'Notes', notelist]
|
||||||
info.append(note_row)
|
info.append(note_row)
|
||||||
|
|
||||||
@ -681,11 +686,10 @@ class BasePage(object):
|
|||||||
addr_header.append([SHEAD, 'Sources'])
|
addr_header.append([SHEAD, 'Sources'])
|
||||||
|
|
||||||
for (label, colclass) in addr_header:
|
for (label, colclass) in addr_header:
|
||||||
trow += Html("th", label, class_ = "Column%s" % colclass,
|
trow += Html("th", label, class_ = "Column%s" % colclass, inline = True)
|
||||||
inline = True)
|
|
||||||
|
|
||||||
# return table header row back to module
|
# return table header row back to module
|
||||||
return trow, addr_header
|
return trow
|
||||||
|
|
||||||
# begin summaryarea division
|
# begin summaryarea division
|
||||||
with Html("div", id="summaryarea") as summaryarea:
|
with Html("div", id="summaryarea") as summaryarea:
|
||||||
@ -703,8 +707,7 @@ class BasePage(object):
|
|||||||
table += thead
|
table += thead
|
||||||
|
|
||||||
# add header row
|
# add header row
|
||||||
header_row, addr_header = write_address_header(showsrc)
|
thead += write_address_header(showsrc)
|
||||||
thead += header_row
|
|
||||||
|
|
||||||
# begin table body
|
# begin table body
|
||||||
tbody = Html("tbody")
|
tbody = Html("tbody")
|
||||||
@ -717,30 +720,26 @@ class BasePage(object):
|
|||||||
tbody += trow
|
tbody += trow
|
||||||
|
|
||||||
addr_data_row = [
|
addr_data_row = [
|
||||||
[_dd.display(address.get_date_object() )],
|
["Date", _dd.display(address.get_date_object() )],
|
||||||
[address.get_street()],
|
["Streetaddress", address.get_street()],
|
||||||
[address.get_city()],
|
["City", address.get_city()],
|
||||||
[address.get_county()],
|
["County", address.get_county()],
|
||||||
[address.get_state()],
|
["State/ Province", address.get_state()],
|
||||||
[address.get_country()],
|
["Cntry", address.get_country()],
|
||||||
[address.get_postal_code()],
|
["Postslcode", address.get_postal_code()],
|
||||||
[address.get_phone()] ]
|
["Phone", address.get_phone()] ]
|
||||||
|
|
||||||
# get source citation list
|
# get source citation list
|
||||||
if showsrc:
|
if showsrc:
|
||||||
addr_data_row.append([self.get_citation_links(
|
addr_data_row.append(["Sources", self.get_citation_links(
|
||||||
address.get_source_references() )])
|
address.get_source_references() )])
|
||||||
|
|
||||||
index = 0
|
for (colclass, value) in addr_data_row:
|
||||||
for value in addr_data_row:
|
|
||||||
colclass = addr_header[index][1]
|
|
||||||
value = value or " "
|
value = value or " "
|
||||||
|
|
||||||
trow += Html("td", value, class_ = "Column%s" % colclass,
|
trow += Html("td", value, class_ = "Column%s" % colclass, inline = True)
|
||||||
inline = True)
|
|
||||||
index += 1
|
|
||||||
|
|
||||||
# address: note list
|
# address: notelist
|
||||||
notelist = self.display_note_list(address.get_note_list())
|
notelist = self.display_note_list(address.get_note_list())
|
||||||
if notelist is not None:
|
if notelist is not None:
|
||||||
summaryarea += notelist
|
summaryarea += notelist
|
||||||
@ -924,8 +923,10 @@ class BasePage(object):
|
|||||||
page, head, body = Html.page('%s - %s' %
|
page, head, body = Html.page('%s - %s' %
|
||||||
(html_escape(self.title_str),
|
(html_escape(self.title_str),
|
||||||
html_escape(title)),
|
html_escape(title)),
|
||||||
self.report.encoding, xmllang
|
self.report.encoding, xmllang )
|
||||||
)
|
|
||||||
|
# add narrative specific body id
|
||||||
|
body.attr = 'id="NarrativeWeb" '
|
||||||
|
|
||||||
# create additional meta tags
|
# create additional meta tags
|
||||||
meta = (Html('meta', attr = _META1) +
|
meta = (Html('meta', attr = _META1) +
|
||||||
@ -1381,23 +1382,6 @@ class BasePage(object):
|
|||||||
# return hyperlink to its caller
|
# return hyperlink to its caller
|
||||||
return hyper
|
return hyper
|
||||||
|
|
||||||
def individual_link(self, url, person):
|
|
||||||
"""
|
|
||||||
creates a hyperlink for a partner in IndividualListPage, and SurnameListPage
|
|
||||||
with no image class attached to it.
|
|
||||||
|
|
||||||
@param: url = hyperlink to person
|
|
||||||
@param: person = person to be hyperlinked
|
|
||||||
"""
|
|
||||||
|
|
||||||
person_name = self.get_name(person)
|
|
||||||
|
|
||||||
# 1. start building link to image or person
|
|
||||||
hyper = Html('a', person_name, href=url, title=html_escape(person_name))
|
|
||||||
|
|
||||||
# return hyperlink to its caller
|
|
||||||
return hyper
|
|
||||||
|
|
||||||
# TODO. Check img_url of callers
|
# TODO. Check img_url of callers
|
||||||
def media_link(self, handle, img_url, name, up, usedescr=True):
|
def media_link(self, handle, img_url, name, up, usedescr=True):
|
||||||
url = self.report.build_url_fname_html(handle, 'img', up)
|
url = self.report.build_url_fname_html(handle, 'img', up)
|
||||||
@ -1499,23 +1483,23 @@ class IndividualListPage(BasePage):
|
|||||||
indlistpage, body = self.write_header(_('Individuals'))
|
indlistpage, body = self.write_header(_('Individuals'))
|
||||||
|
|
||||||
# begin Individuals division
|
# begin Individuals division
|
||||||
with Html("div", class_ = "content", id="Individuals") as section:
|
with Html("div", class_ = "content", id="Individuals") as individuallist:
|
||||||
body += section
|
body += individuallist
|
||||||
|
|
||||||
# Individual List description
|
# add alphabet navigation
|
||||||
|
alpha_nav = alphabet_navigation(db, person_handle_list, _PERSON)
|
||||||
|
if alpha_nav is not None:
|
||||||
|
individuallist += alpha_nav
|
||||||
|
|
||||||
|
# Individual List page message
|
||||||
msg = _("This page contains an index of all the individuals in the "
|
msg = _("This page contains an index of all the individuals in the "
|
||||||
"database, sorted by their last names. Selecting the person’s "
|
"database, sorted by their last names. Selecting the person’s "
|
||||||
"name will take you to that person’s individual page.")
|
"name will take you to that person’s individual page.")
|
||||||
section += Html('p', msg, id='description')
|
individuallist += Html('p', msg, id='description')
|
||||||
|
|
||||||
# add alphabet navigation after page msg
|
|
||||||
alpha_nav = alphabet_navigation(db, person_handle_list, _PERSON)
|
|
||||||
if alpha_nav is not None:
|
|
||||||
section += alpha_nav
|
|
||||||
|
|
||||||
# begin table and table head
|
# begin table and table head
|
||||||
with Html("table", class_ = "infolist IndividualList") as table:
|
with Html("table", class_ = "infolist IndividualList") as table:
|
||||||
section += table
|
individuallist += table
|
||||||
thead = Html("thead")
|
thead = Html("thead")
|
||||||
table += thead
|
table += thead
|
||||||
|
|
||||||
@ -1547,9 +1531,7 @@ class IndividualListPage(BasePage):
|
|||||||
tbody = Html("tbody")
|
tbody = Html("tbody")
|
||||||
table += tbody
|
table += tbody
|
||||||
|
|
||||||
# list of person handles for this report
|
|
||||||
person_handle_list = sort_people(db, person_handle_list)
|
person_handle_list = sort_people(db, person_handle_list)
|
||||||
|
|
||||||
for (surname, handle_list) in person_handle_list:
|
for (surname, handle_list) in person_handle_list:
|
||||||
first = True
|
first = True
|
||||||
if surname:
|
if surname:
|
||||||
@ -1565,20 +1547,20 @@ class IndividualListPage(BasePage):
|
|||||||
|
|
||||||
# surname column
|
# surname column
|
||||||
trow = Html("tr")
|
trow = Html("tr")
|
||||||
|
tbody += trow
|
||||||
tcell = Html("td", class_ = "ColumnSurname", inline = True)
|
tcell = Html("td", class_ = "ColumnSurname", inline = True)
|
||||||
|
trow += tcell
|
||||||
if first:
|
if first:
|
||||||
trow.attr = 'class="BeginSurname"'
|
trow.attr = 'class="BeginSurname"'
|
||||||
if surname:
|
if surname:
|
||||||
tcell += Html('a', surname, name=letter, title='Letter %s' % letter,
|
tcell += Html('a', surname, name=letter,
|
||||||
inline = True)
|
title='Surnames starting with letter %s' % letter)
|
||||||
else:
|
else:
|
||||||
tcell += " "
|
tcell += " "
|
||||||
else:
|
else:
|
||||||
tcell += " "
|
tcell += " "
|
||||||
tbody += trow
|
|
||||||
trow += tcell
|
|
||||||
|
|
||||||
first = False
|
first = False
|
||||||
|
|
||||||
# firstname column
|
# firstname column
|
||||||
tcell = Html("td", class_ = "ColumnName")
|
tcell = Html("td", class_ = "ColumnName")
|
||||||
trow += tcell
|
trow += tcell
|
||||||
@ -1588,6 +1570,8 @@ class IndividualListPage(BasePage):
|
|||||||
# birth column
|
# birth column
|
||||||
if showbirth:
|
if showbirth:
|
||||||
tcell = Html("td", class_ = "ColumnBirth", inline = True)
|
tcell = Html("td", class_ = "ColumnBirth", inline = True)
|
||||||
|
trow += tcell
|
||||||
|
|
||||||
birth = ReportUtils.get_birth_or_fallback(db, person)
|
birth = ReportUtils.get_birth_or_fallback(db, person)
|
||||||
if birth:
|
if birth:
|
||||||
birth_date = _dd.display(birth.get_date_object())
|
birth_date = _dd.display(birth.get_date_object())
|
||||||
@ -1597,11 +1581,12 @@ class IndividualListPage(BasePage):
|
|||||||
tcell += Html('em', birth_date)
|
tcell += Html('em', birth_date)
|
||||||
else:
|
else:
|
||||||
tcell += " "
|
tcell += " "
|
||||||
trow += tcell
|
|
||||||
|
|
||||||
# death column
|
# death column
|
||||||
if showdeath:
|
if showdeath:
|
||||||
tcell = Html("td", class_ = "ColumnDeath", inline = True)
|
tcell = Html("td", class_ = "ColumnDeath", inline = True)
|
||||||
|
trow += tcell
|
||||||
|
|
||||||
death = ReportUtils.get_death_or_fallback(db, person)
|
death = ReportUtils.get_death_or_fallback(db, person)
|
||||||
if death:
|
if death:
|
||||||
death_date = _dd.display(death.get_date_object())
|
death_date = _dd.display(death.get_date_object())
|
||||||
@ -1611,11 +1596,12 @@ class IndividualListPage(BasePage):
|
|||||||
tcell += Html('em', death_date)
|
tcell += Html('em', death_date)
|
||||||
else:
|
else:
|
||||||
tcell += " "
|
tcell += " "
|
||||||
trow += tcell
|
|
||||||
|
|
||||||
# partner column
|
# partner column
|
||||||
if showpartner:
|
if showpartner:
|
||||||
tcell = Html("td", class_ = "ColumnPartner")
|
tcell = Html("td", class_ = "ColumnPartner")
|
||||||
|
trow += tcell
|
||||||
|
|
||||||
family_list = person.get_family_handle_list()
|
family_list = person.get_family_handle_list()
|
||||||
first_family = True
|
first_family = True
|
||||||
partner_name = None
|
partner_name = None
|
||||||
@ -1630,7 +1616,7 @@ class IndividualListPage(BasePage):
|
|||||||
tcell += ', '
|
tcell += ', '
|
||||||
if partner_handle in report_handle_list:
|
if partner_handle in report_handle_list:
|
||||||
url = self.report.build_url_fname_html(partner_handle, 'ppl')
|
url = self.report.build_url_fname_html(partner_handle, 'ppl')
|
||||||
tcell += self.individual_link(url, partner)
|
tcell += self.person_link(url, partner, True, partner.gramps_id)
|
||||||
else:
|
else:
|
||||||
tcell += partner_name
|
tcell += partner_name
|
||||||
first_family = False
|
first_family = False
|
||||||
@ -1638,11 +1624,12 @@ class IndividualListPage(BasePage):
|
|||||||
tcell += " "
|
tcell += " "
|
||||||
else:
|
else:
|
||||||
tcell += " "
|
tcell += " "
|
||||||
trow += tcell
|
|
||||||
|
|
||||||
# parents column
|
# parents column
|
||||||
if showparents:
|
if showparents:
|
||||||
tcell = Html("td", class_ = "ColumnParents")
|
tcell = Html("td", class_ = "ColumnParents")
|
||||||
|
trow += tcell
|
||||||
|
|
||||||
parent_handle_list = person.get_parent_family_handle_list()
|
parent_handle_list = person.get_parent_family_handle_list()
|
||||||
if parent_handle_list:
|
if parent_handle_list:
|
||||||
parent_handle = parent_handle_list[0]
|
parent_handle = parent_handle_list[0]
|
||||||
@ -1656,8 +1643,7 @@ class IndividualListPage(BasePage):
|
|||||||
if mother:
|
if mother:
|
||||||
mother_name = self.get_name(mother)
|
mother_name = self.get_name(mother)
|
||||||
if mother and father:
|
if mother and father:
|
||||||
fathercell = Html('span', father_name,
|
fathercell = Html('span', father_name, class_ = "father fatherNmother")
|
||||||
class_ = "father fatherNmother")
|
|
||||||
mothercell = Html('span', mother_name, class_ = "mother")
|
mothercell = Html('span', mother_name, class_ = "mother")
|
||||||
tcell += (fathercell, mothercell)
|
tcell += (fathercell, mothercell)
|
||||||
elif mother:
|
elif mother:
|
||||||
@ -1666,7 +1652,6 @@ class IndividualListPage(BasePage):
|
|||||||
tcell += Html('span', father_name, class_ = "father")
|
tcell += Html('span', father_name, class_ = "father")
|
||||||
else:
|
else:
|
||||||
tcell += " "
|
tcell += " "
|
||||||
trow += tcell
|
|
||||||
|
|
||||||
# create clear line for proper styling
|
# create clear line for proper styling
|
||||||
# create footer section
|
# create footer section
|
||||||
@ -1786,7 +1771,7 @@ class SurnamePage(BasePage):
|
|||||||
tcell += ','
|
tcell += ','
|
||||||
if partner_handle in report_handle_list:
|
if partner_handle in report_handle_list:
|
||||||
url = self.report.build_url_fname_html(partner_handle, 'ppl', True)
|
url = self.report.build_url_fname_html(partner_handle, 'ppl', True)
|
||||||
tcell += self.individual_link(url, partner)
|
tcell += self.person_link(url, partner, True, partner.gramps_id)
|
||||||
else:
|
else:
|
||||||
tcell += partner_name
|
tcell += partner_name
|
||||||
else:
|
else:
|
||||||
@ -1844,22 +1829,23 @@ class PlaceListPage(BasePage):
|
|||||||
placelistpage, body = self.write_header(_('Places'))
|
placelistpage, body = self.write_header(_('Places'))
|
||||||
|
|
||||||
# begin places division
|
# begin places division
|
||||||
with Html("div", class_ = "content", id="Places") as section:
|
with Html("div", class_ = "content", id="Places") as placelist:
|
||||||
body += section
|
body += placelist
|
||||||
|
|
||||||
msg = _("This page contains an index of all the places in the "
|
|
||||||
"database, sorted by their title. Clicking on a place’s "
|
|
||||||
"title will take you to that place’s page.")
|
|
||||||
section += Html('p', msg, id='description')
|
|
||||||
|
|
||||||
# begin alphabet navigation
|
# begin alphabet navigation
|
||||||
alpha_nav = alphabet_navigation(db, place_handles, _PLACE)
|
alpha_nav = alphabet_navigation(db, place_handles, _PLACE)
|
||||||
if alpha_nav is not None:
|
if alpha_nav is not None:
|
||||||
section += alpha_nav
|
placelist += alpha_nav
|
||||||
|
|
||||||
|
# place list page message
|
||||||
|
msg = _("This page contains an index of all the places in the "
|
||||||
|
"database, sorted by their title. Clicking on a place’s "
|
||||||
|
"title will take you to that place’s page.")
|
||||||
|
placelist += Html('p', msg, id='description')
|
||||||
|
|
||||||
# begin places table and table head
|
# begin places table and table head
|
||||||
with Html("table", class_ = "infolist placelist") as table:
|
with Html("table", class_ = "infolist placelist") as table:
|
||||||
section += table
|
placelist += table
|
||||||
|
|
||||||
# begin table head
|
# begin table head
|
||||||
thead = Html("thead")
|
thead = Html("thead")
|
||||||
@ -1892,22 +1878,21 @@ class PlaceListPage(BasePage):
|
|||||||
if lang_country == "sv_SE" and ( letter == u'W' or letter == u'V' ):
|
if lang_country == "sv_SE" and ( letter == u'W' or letter == u'V' ):
|
||||||
letter = u'V,W'
|
letter = u'V,W'
|
||||||
|
|
||||||
|
trow = Html("tr")
|
||||||
|
tbody += trow
|
||||||
if letter != last_letter:
|
if letter != last_letter:
|
||||||
last_letter = letter
|
last_letter = letter
|
||||||
trow = Html("tr", class_ = "BeginLetter")
|
trow.attr = 'class = "BeginLetter" '
|
||||||
tbody += trow
|
|
||||||
tcell = Html("td", class_ = "olumnLetter", inline = True) + (
|
tcell = Html("td", class_ = "olumnLetter", inline = True) + (
|
||||||
Html('a', last_letter, name=last_letter,
|
Html('a', last_letter, name=last_letter,
|
||||||
title="Letter %s" % last_letter)
|
title="Places beginning with letter %s" % last_letter)
|
||||||
)
|
)
|
||||||
else:
|
else:
|
||||||
trow = Html("tr")
|
|
||||||
tbody += trow
|
|
||||||
tcell = Html("td", " ", class_ = "ColumnLetter", inline = True)
|
tcell = Html("td", " ", class_ = "ColumnLetter", inline = True)
|
||||||
trow += tcell
|
trow += tcell
|
||||||
|
|
||||||
tcell = Html("td", class_ = "ColumnName") + \
|
tcell = Html("td", class_ = "ColumnName") + \
|
||||||
self.place_link(place.handle, place_title, place.gramps_id)
|
self.place_link(place.handle, place_title, place.gramps_id)
|
||||||
trow += tcell
|
trow += tcell
|
||||||
|
|
||||||
# add clearline for proper styling
|
# add clearline for proper styling
|
||||||
@ -2628,20 +2613,20 @@ class SurnameListPage(BasePage):
|
|||||||
with Html("div", class_ = "content", id="surnames") as surnamelist:
|
with Html("div", class_ = "content", id="surnames") as surnamelist:
|
||||||
body += surnamelist
|
body += surnamelist
|
||||||
|
|
||||||
# page description
|
# add alphabet navigation...
|
||||||
msg = _( 'This page contains an index of all the '
|
|
||||||
'surnames in the database. Selecting a link '
|
|
||||||
'will lead to a list of individuals in the '
|
|
||||||
'database with this same surname.')
|
|
||||||
surnamelist += Html('p', msg, id='description')
|
|
||||||
|
|
||||||
# add alphabet navigation after page msg
|
|
||||||
# only if surname list not surname count
|
# only if surname list not surname count
|
||||||
if order_by == self.ORDER_BY_NAME:
|
if order_by == self.ORDER_BY_NAME:
|
||||||
alpha_nav = alphabet_navigation(db, person_handle_list, _PERSON)
|
alpha_nav = alphabet_navigation(db, person_handle_list, _PERSON)
|
||||||
if alpha_nav is not None:
|
if alpha_nav is not None:
|
||||||
surnamelist += alpha_nav
|
surnamelist += alpha_nav
|
||||||
|
|
||||||
|
# page message
|
||||||
|
msg = _( 'This page contains an index of all the '
|
||||||
|
'surnames in the database. Selecting a link '
|
||||||
|
'will lead to a list of individuals in the '
|
||||||
|
'database with this same surname.')
|
||||||
|
surnamelist += Html('p', msg, id='description')
|
||||||
|
|
||||||
if order_by == self.ORDER_BY_COUNT:
|
if order_by == self.ORDER_BY_COUNT:
|
||||||
table_id = 'SortByCount'
|
table_id = 'SortByCount'
|
||||||
else:
|
else:
|
||||||
@ -2711,8 +2696,8 @@ class SurnameListPage(BasePage):
|
|||||||
trow.attr = ' class="BeginLetter" '
|
trow.attr = ' class="BeginLetter" '
|
||||||
|
|
||||||
tcell = Html("td", class_ = "ColumnLetter", inline = True) + (
|
tcell = Html("td", class_ = "ColumnLetter", inline = True) + (
|
||||||
Html('a', last_letter, name=last_letter)
|
Html('a', last_letter, name=last_letter,
|
||||||
)
|
title="Surnames starting with letter %s" % last_letter) )
|
||||||
trow += tcell
|
trow += tcell
|
||||||
|
|
||||||
tcell = Html("td", class_ = "ColumnSurname") + \
|
tcell = Html("td", class_ = "ColumnSurname") + \
|
||||||
@ -2911,41 +2896,45 @@ class SourcePage(BasePage):
|
|||||||
section += thumbnail
|
section += thumbnail
|
||||||
|
|
||||||
# add section title
|
# add section title
|
||||||
section += Html('h3', html_escape(self.page_title.strip()), inline = True)
|
section += Html('h3', html_escape(source.get_title()), inline = True)
|
||||||
|
|
||||||
# begin sources table
|
# begin sources table
|
||||||
with Html("table", class_ = "infolist source") as table:
|
with Html("table", class_ = "infolist source") as table:
|
||||||
section += table
|
section += table
|
||||||
|
|
||||||
|
tbody = Html("tbody")
|
||||||
|
table += tbody
|
||||||
|
|
||||||
grampsid = None
|
grampsid = None
|
||||||
if not self.noid:
|
if not self.noid:
|
||||||
grampsid = source.gramps_id
|
grampsid = source.gramps_id
|
||||||
|
|
||||||
for (label, val) in [(_('GRAMPS ID'), grampsid),
|
for (label, val) in [(_('GRAMPS ID'), grampsid),
|
||||||
(_('Author'), source.author),
|
(_('Author'), source.author),
|
||||||
(_('Publication information'), source.pubinfo),
|
(_('Publication information'), source.pubinfo),
|
||||||
(_('Abbreviation'), source.abbrev)]:
|
(_('Abbreviation'), source.abbrev)]:
|
||||||
if val:
|
if val:
|
||||||
trow = Html("tr") + (
|
trow = Html("tr") + (
|
||||||
Html("td", label, class_ = "ColumnAttribute"),
|
Html("td", label, class_ = "ColumnAttribute"),
|
||||||
Html("td", val, class_ = "ColumnValue")
|
Html("td", val, class_ = "ColumnValue")
|
||||||
)
|
)
|
||||||
table += trow
|
tbody += trow
|
||||||
|
|
||||||
# additional media
|
# additional media
|
||||||
sourcegallery = self.display_additional_images_as_gallery(media_list)
|
sourcemedia = self.display_additional_images_as_gallery(media_list)
|
||||||
if sourcegallery is not None:
|
if sourcemedia is not None:
|
||||||
section += sourcegallery
|
section += sourcemedia
|
||||||
|
|
||||||
# additional notes
|
# additional notes
|
||||||
sourcenotes = self.display_note_list(source.get_note_list())
|
notelist = source.get_note_list()
|
||||||
if sourcenotes is not None:
|
if notelist:
|
||||||
section += sourcenotes
|
notelist = self.display_note_list(notelist)
|
||||||
|
section += notelist
|
||||||
|
|
||||||
# references
|
# references
|
||||||
source_references = self.display_references(src_list[source.handle])
|
src_references = self.display_references(src_list[source.handle])
|
||||||
if source_references is not None:
|
if src_references is not None:
|
||||||
section += source_references
|
section += src_references
|
||||||
|
|
||||||
# add clearline for proper styling
|
# add clearline for proper styling
|
||||||
# add footer section
|
# add footer section
|
||||||
@ -4348,7 +4337,7 @@ class IndividualPage(BasePage):
|
|||||||
event_header_row.append(descr_row)
|
event_header_row.append(descr_row)
|
||||||
|
|
||||||
if showsrc:
|
if showsrc:
|
||||||
source_row = (SHEAD, 'Sources')
|
source_row = (SHEAD, 'Sources')
|
||||||
event_header_row.append(source_row)
|
event_header_row.append(source_row)
|
||||||
|
|
||||||
if shownote:
|
if shownote:
|
||||||
@ -5750,23 +5739,32 @@ def alphabet_navigation(db, handle_list, key):
|
|||||||
num_ltrs = len(sorted_alpha_index)
|
num_ltrs = len(sorted_alpha_index)
|
||||||
nrows = (num_ltrs / 35) + 1
|
nrows = (num_ltrs / 35) + 1
|
||||||
index = 0
|
index = 0
|
||||||
|
|
||||||
|
first_letter = True
|
||||||
for rows in xrange(nrows):
|
for rows in xrange(nrows):
|
||||||
unordered = Html('ul')
|
unordered = Html('ul')
|
||||||
section += unordered
|
section += unordered
|
||||||
|
|
||||||
cols = 0
|
cols = 0
|
||||||
while (cols <= 35 and index < num_ltrs):
|
while (cols <= 35 and index < num_ltrs):
|
||||||
|
list = Html("li", inline = True)
|
||||||
|
unordered += list
|
||||||
|
|
||||||
|
if first_letter:
|
||||||
|
list.attr = 'class = "CurrentSection" '
|
||||||
|
|
||||||
ltr = sorted_alpha_index[index]
|
ltr = sorted_alpha_index[index]
|
||||||
title_str = _('Surnames') if key == 0 else _('Places')
|
title_str = _('Surnames') if key == 0 else _('Places')
|
||||||
if lang_country == "sv_SE" and ltr == u'V':
|
if lang_country == "sv_SE" and ltr == u'V':
|
||||||
title_str += _(' starting with %s') % "V,W"
|
title_str += _(' starting with %s') % "V,W"
|
||||||
unordered += (Html('li', class_ = "letters", inline = True) +
|
hyper = Html('a', "V,W", href="#V,W")
|
||||||
Html('a', "V,W", href="#V,W", title=title_str)
|
|
||||||
)
|
|
||||||
else:
|
else:
|
||||||
title_str += _(' starting with %s') % ltr
|
title_str += _(' starting with %s') % ltr
|
||||||
unordered += Html('li', class_ = "letters", inline = True) + (
|
hyper = Html('a', ltr, href='#%s' % ltr)
|
||||||
Html('a', ltr, href='#%s' % ltr, title=title_str)
|
hyper.attr += "title = %s" % title_str
|
||||||
)
|
list += hyper
|
||||||
|
|
||||||
|
first_letter = False
|
||||||
cols += 1
|
cols += 1
|
||||||
index += 1
|
index += 1
|
||||||
|
|
||||||
|
@ -432,10 +432,6 @@ class WebCalReport(Report):
|
|||||||
currentsection = proper styling of this navigation bar
|
currentsection = proper styling of this navigation bar
|
||||||
"""
|
"""
|
||||||
|
|
||||||
# creating more than one year
|
|
||||||
if not self.multiyear:
|
|
||||||
return
|
|
||||||
|
|
||||||
num_years = (self.end_year - self.start_year)
|
num_years = (self.end_year - self.start_year)
|
||||||
cal_year = self.start_year
|
cal_year = self.start_year
|
||||||
|
|
||||||
@ -443,49 +439,43 @@ class WebCalReport(Report):
|
|||||||
# otherwise, 18 years in a row
|
# otherwise, 18 years in a row
|
||||||
years_in_row = 22 if self.css is not 'Web_Visually.css' else 18
|
years_in_row = 22 if self.css is not 'Web_Visually.css' else 18
|
||||||
|
|
||||||
# figure out number of rows
|
|
||||||
nrows = get_num_of_rows(num_years, years_in_row)
|
|
||||||
|
|
||||||
# begin year division
|
# begin year division
|
||||||
yearnav = Html("div", id="navigation")
|
with Html("div", id = "navigation") as section:
|
||||||
|
|
||||||
for row in range(0, (num_years // years_in_row)):
|
for row in xrange((num_years // years_in_row) + 1):
|
||||||
|
|
||||||
unordered = Html("ul")
|
unordered = Html("ul")
|
||||||
yearnav += unordered
|
section += unordered
|
||||||
cols = 1
|
|
||||||
while (cols <= years_in_row and cal_year <= self.end_year):
|
|
||||||
url = ''
|
|
||||||
|
|
||||||
# begin subdir level
|
cols = 1
|
||||||
subdirs = ['..'] * nr_up
|
while (cols <= years_in_row and cal_year <= self.end_year):
|
||||||
subdirs.append(str(cal_year))
|
url = ''
|
||||||
|
|
||||||
# each year will link to current month.
|
# begin subdir level
|
||||||
# this will always need an extension added
|
subdirs = ['..'] * nr_up
|
||||||
full_month_name = get_full_month_name(self.today.get_month())
|
subdirs.append(str(cal_year))
|
||||||
|
|
||||||
# Note. We use '/' here because it is a URL, not a OS dependent
|
# each year will link to current month.
|
||||||
# pathname.
|
# this will always need an extension added
|
||||||
url = os.path.join(subdirs, full_month_name) + self.ext
|
full_month_name = get_full_month_name(self.today.get_month())
|
||||||
# url = '/'.join(subdirs + [full_month_name]) + self.ext
|
|
||||||
|
|
||||||
# Figure out if we need <li class="CurrentSection"> or just plain <li>
|
# Note. We use '/' here because it is a URL, not a OS dependent
|
||||||
cs = str(cal_year) == currentsection and 'class="CurrentSection"' or ''
|
# pathname.
|
||||||
unordered += Html("li", attr=cs , inline = True) + (
|
url = '/'.join(subdirs + [full_month_name]) + self.ext
|
||||||
|
|
||||||
# create hyperlink
|
# Figure out if we need <li class="CurrentSection"> or just plain <li>
|
||||||
Html("a", str(cal_year), href = url, inline = True)
|
cs = str(cal_year) == currentsection and 'class="CurrentSection"' or ''
|
||||||
)
|
unordered += Html("li", attr=cs , inline = True) + (
|
||||||
|
|
||||||
# increase columns
|
# create hyperlink
|
||||||
cols += 1
|
Html("a", str(cal_year), href = url, title=str(cal_year), inline = True)
|
||||||
|
)
|
||||||
|
|
||||||
# increase calendar year
|
cols += 1
|
||||||
cal_year += 1
|
cal_year += 1
|
||||||
|
|
||||||
# return yearnav to its caller
|
# return yearnav to its caller
|
||||||
return yearnav
|
return section
|
||||||
|
|
||||||
# ---------------------------------------------------------------------------------------
|
# ---------------------------------------------------------------------------------------
|
||||||
#
|
#
|
||||||
@ -516,49 +506,49 @@ class WebCalReport(Report):
|
|||||||
# Add a link for year_glance() if requested
|
# Add a link for year_glance() if requested
|
||||||
navs.append(('fullyearlinked', _('Year Glance'), self.fullyear))
|
navs.append(('fullyearlinked', _('Year Glance'), self.fullyear))
|
||||||
|
|
||||||
monthnav = Html("div", id="subnavigation")
|
# begin month subnavigation
|
||||||
ul = Html("ul")
|
with Html("div", id = "subnavigation") as section:
|
||||||
|
|
||||||
navs = [(u, n) for u, n, c in navs if c]
|
unordered = Html("ul")
|
||||||
for url_fname, nav_text in navs:
|
section += unordered
|
||||||
|
|
||||||
if type(url_fname) == int:
|
navs = [(u, n) for u, n, c in navs if c]
|
||||||
url_fname = get_full_month_name(url_fname)
|
for url_fname, nav_text in navs:
|
||||||
|
|
||||||
if type(nav_text) == int:
|
if type(url_fname) == int:
|
||||||
nav_text = get_short_month_name(nav_text)
|
url_fname = get_full_month_name(url_fname)
|
||||||
|
|
||||||
# Note. We use '/' here because it is a URL, not a OS dependent pathname
|
if type(nav_text) == int:
|
||||||
# need to leave home link alone, so look for it ...
|
nav_text = get_short_month_name(nav_text)
|
||||||
url = url_fname
|
|
||||||
add_subdirs = True
|
# Note. We use '/' here because it is a URL, not a OS dependent pathname
|
||||||
if not (url.startswith('http:') or url.startswith('/')):
|
# need to leave home link alone, so look for it ...
|
||||||
for ext in _WEB_EXT:
|
url = url_fname
|
||||||
if url_fname.endswith(ext):
|
add_subdirs = True
|
||||||
add_subdirs = False
|
if not (url.startswith('http:') or url.startswith('/')):
|
||||||
|
for ext in _WEB_EXT:
|
||||||
|
if url_fname.endswith(ext):
|
||||||
|
add_subdirs = False
|
||||||
|
|
||||||
# whether to add subdirs or not???
|
# whether to add subdirs or not???
|
||||||
if add_subdirs:
|
if add_subdirs:
|
||||||
subdirs = ['..'] * nr_up
|
subdirs = ['..'] * nr_up
|
||||||
subdirs.append(str(year))
|
subdirs.append(str(year))
|
||||||
url = '/'.join(subdirs + [url_fname])
|
url = '/'.join(subdirs + [url_fname])
|
||||||
|
|
||||||
if not _has_webpage_extension(url):
|
if not _has_webpage_extension(url):
|
||||||
url += self.ext
|
url += self.ext
|
||||||
|
|
||||||
# Figure out if we need <li class="CurrentSection"> or just plain <li>
|
# Figure out if we need <li class="CurrentSection"> or just plain <li>
|
||||||
cs = url_fname == currentsection and 'class="CurrentSection"' or ''
|
cs = url_fname == currentsection and 'class="CurrentSection"' or ''
|
||||||
ul += Html("li", attr = cs, inline = True) + (
|
unordered += Html("li", attr = cs, inline = True) + (
|
||||||
|
|
||||||
# create hyperlink
|
# create hyperlink
|
||||||
Html("a", nav_text, href = url, inline = True)
|
Html("a", nav_text, href = url, title=url_fname, inline = True)
|
||||||
)
|
)
|
||||||
|
|
||||||
# add ul to monthnav
|
|
||||||
monthnav += ul
|
|
||||||
|
|
||||||
# return monthnav to its caller
|
# return monthnav to its caller
|
||||||
return monthnav
|
return section
|
||||||
|
|
||||||
# ---------------------------------------------------------------------------------------
|
# ---------------------------------------------------------------------------------------
|
||||||
#
|
#
|
||||||
|
Loading…
Reference in New Issue
Block a user