@@ -21,7 +21,7 @@ import { h } from '/js/src/index.js';
2121 * @return {vnode } A collection of links seperated by commas
2222 */
2323const linksContainer = ( links , properties , textKey ) => links . length > 0
24- ? h ( '.flex-wrap' , links . map ( ( link , index ) => h ( '.flex-row' , [
24+ ? h ( '.flex-wrap' , { style : 'word-break: break-all' } , links . map ( ( link , index ) => h ( '.flex-row' , [
2525 h ( 'a' , properties ( link ) , link [ textKey ] ) ,
2626 index + 1 < links . length ? h ( '' , { style : 'white-space: pre;' } , ', ' ) : null ,
2727 ] ) ) )
@@ -86,9 +86,7 @@ const activeFields = (model) => ({
8686 */
8787const replyButton = ( model , post ) => h ( 'a.btn.btn-primary' , {
8888 id : `reply-to-${ post . id } ` ,
89- style : {
90- float : 'right' ,
91- } ,
89+ style : 'float: right;' ,
9290 onclick : ( e ) => model . router . handleLinkEvent ( e ) ,
9391 href : `?page=create-log-entry&parentLogId=${ post . id } ` ,
9492} , 'Reply' ) ;
@@ -105,24 +103,17 @@ const replyButton = (model, post) => h('a.btn.btn-primary', {
105103const entry = ( model , post , index , highlight ) => {
106104 const postFields = activeFields ( model ) ;
107105
108- return h ( '.w-100.flex-row.shadow-level1' , {
109- id : `post${ index } ` ,
110- style : {
111- margin : '5px' ,
112- } ,
113- } , [
114- h ( `.w-20.shadow-level1${ highlight ? '.bg-gray-light' : '' } ` , {
115- style : { padding : '10px' } ,
116- } , [
106+ return h ( `#post${ index } .w-100.flex-row.m1.shadow-level1` , [
107+ h ( `.w-20.p2.shadow-level1${ highlight ? '.bg-gray-light' : '' } ` , [
117108 h ( 'table' , [
118109 h ( 'tbody' , Object . entries ( postFields )
119110 . map ( ( [ key , { name, format, visible } ] ) => visible && h ( `tr#post${ index } -${ key } ` , [
120- h ( 'td' , { style : { 'text-align' : 'right' , ' font-weight' : ' bold' } } , `${ name } :` ) ,
111+ h ( 'td.text-right ' , { style : ' font-weight: bold' } , `${ name } :` ) ,
121112 h ( 'td' , post [ key ] && format ? format ( post [ key ] ) : post [ key ] || 'None' ) ,
122113 ] ) ) ) ,
123114 ] ) ,
124115 ] ) ,
125- h ( '.w-80.shadow-level1' , { style : { padding : '10px' } } , [
116+ h ( '.w-80.p2. shadow-level1' , [
126117 h ( 'h4' , post . title , replyButton ( model , post ) ) ,
127118 h ( `textarea.w-100#post-content${ index } ` , {
128119 oninit : ( ) => {
0 commit comments