Skip to content
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

Cleanup for storytable wiki markup #8

Open
Ylimegirl opened this issue Sep 23, 2021 · 1 comment
Open

Cleanup for storytable wiki markup #8

Ylimegirl opened this issue Sep 23, 2021 · 1 comment

Comments

@Ylimegirl
Copy link

Site skin CSS now always makes storytables have 100% width and left-aligned text, so the code for the top of each table could just be simplified to

{| class="storytable imgfit"

Additionally, since the top title for a story doesn't have any images or multiple columns, it doesn't need the imgfit class or colspan and that code could instead just be

{| class="storytable"
|- id="Top"
! Story Title Here
|}

Additionally additionally, there's no need for row separators at the beginning or end of a table if they don't have any special inline code on them (such as id="Top"). So

{| class="storytable imgfit" width="100%" style="text-align:left"
|-
| colspan="3" |[[File:Bg 64207.png]]
...

Can just become

{| class="storytable imgfit"
| colspan="3" |[[File:Bg 64207.png]]
...

And

...
|-
| colspan="3" class="bottomnav" |✦ [[Ace Trappola/Personal Story|Main]] ✦
|-
| colspan="3" style="text-align:center;" |[[#Top|Jump to top]]
|-
|}

Can just be

...
|-
| colspan="3" class="bottomnav" |✦ [[Ace Trappola/Personal Story|Main]] ✦
|-
| colspan="3" style="text-align:center;" |[[#Top|Jump to top]]
|}

(Having these excess |- doesn't actually negatively affect the output it any way, it just makes it look cleaner on the wiki markup end, so if it's too much of a pain to change the code to remove those from the output that's fine.)

Also this is probably way too specific to fix, but there's no reason to have the title part of the story be kept separate from the main body of the story if the story isn't split up into multiple parts. So if there's no tabber needed, instead of this:

{| class="storytable"
|- id="Top"
! Story Title Here
|}
{| class="storytable imgfit"
|-
| colspan="3" |[[File:Bg 64207.png]]

The code could just be this:

{| class="storytable imgfit"
|- id="Top"
! Story Title Here
|-
| colspan="3" |[[File:Bg 64207.png]]

But the good news is that the majority of these issues are automatically caught by my bot when I have it do its rounds and it gets cleaned up anyways, but I thought it might be useful to maybe fix these minor issues at the source if possible, yknow?

@myang5
Copy link
Owner

myang5 commented Oct 4, 2021

In terms of removing the row separator from the top of the table

{| class="storytable imgfit"
|- // remove this
| colspan="3" |[[File:Bg 64207.png]]
...

That's going to take more time since the row separator is part of the templates for each type of line, so I'd need to refactor the code a bit to conditionally not include the row separator. I want to clean up the code in that area anyway so I'll include this as a followup after the current PR

@myang5 myang5 mentioned this issue Oct 4, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants