Gills-Chlorophyll / webfront

Front web face for the project - A few pages for advertising the project
0 stars 0 forks source link

Index pages - blogs, diary need to have paginated viewing #3

Closed kneerunjun closed 1 month ago

kneerunjun commented 1 month ago

Index pages gives aglimpse of whats in the blog, with only a limited items on the page. When cliked on the glimpse it takes you to the actual page

kneerunjun commented 1 month ago

page=0 panics page=4 (beyond the the max number of pages) gives the entire set of blogs - which violates the max page number. This should actually send 404 resource not found While this scenario is unlikely since unless the user gets hold of the url and decides to send an modified url with a page number. But just cause the scenario is ulikely does not mean the server should not handle it.

kneerunjun commented 1 month ago

When currPage == pages - end delimiting the slice of blogs is creating a panic it should not have this delimiting - only the start section

kneerunjun commented 1 month ago

nav-next needs change in how it access the next and prev urls - BaseHref

kneerunjun commented 1 month ago

Top nav Blogs menu should be linked to index of blogs

kneerunjun commented 1 month ago

On the index page its time to put some page navigation buttons on the bottom of the enlisting. Such an array of buttons is agnostic of whethere its diary listings or blog listings

kneerunjun commented 1 month ago

https://github.com/Gills-Chlorophyll/webfront/blob/df2bceeaf3fc60d10eeb03bdfd3761f2ea5e66c8/data.diary.go#L98 When error Result needs to be nil

kneerunjun commented 1 month ago

Current page button needs to be deactivated - indicating its the current page you are on. Else cannot avoid nuisance clicking

kneerunjun commented 1 month ago

After prelim testing - we have found that index of blogs is working fine, also the nav-next on bottom of each blog is working well as well