Guide to CSS: Beginner to Expert
Forum Index > PokéFarm > Guides >
As long as either they are not used in the template at all OR are unaffected by the code you have created, then no, you don't have to style it as well. Oftentimes though, links will show the same colour as what you have set to the template which will change the colour but not the background of the pkmnpanel and that would make it illegible on some skins as a result, so just be careful and test it to make sure they are not affected. I can update this post tomorrow with a way to make it not updated for links but am on mobile atm about to rest.
Buying:
BSDs 20 ZC
Prisms 70 ZC
by Kaede
I used the following code for tables being too wide;
table {
display: flex;
width: 100%;
overflow-x: auto;
}
but it does this to my tables? is there any way to fix that? or are my thicc tables perpetually grossly spaced/aligned?
The problem is the flex display. Tables have unique display properties that you're overriding with that line. The rest is correct, so just remove that line.
Note: While scrolling is allowed on tables when necessary, if there's any way to reformat your data to not require such wide tables, you may want to do that.
so admittedly im brand new to css but how exactly do i do the @ import? how does it work, where does it go if youre trying to use it in a post? im definitely missing something but to be fair im skipping a lot of steps. ill read through some more in depth beginner guides later so i know the basics better but for now: how do i get the import to work??
also, im not sure where to put the style code to hide box shadows for tabs? i cant get it to work for tabs at all :/
Thank you so much for making this guide! It helps a lot as someone trying to learn more about CSS :DD
(totally not a post to keep the thread from not being deleted nope who said that)
parker !! - he/they - minor
background & signature
avatar is offical hypmic art
Currently trying to edit some Pokemon panel code to go with some of my freebie templates. But I'm having a heck of a time keeping my progress bar coding from further up in my coding from messing with the coding for the progress/exp bar on the Pokemon panel. Can anyone give me a hand? This is what my current style code for those two parts looks like for the template itself.
code
//normal progress bar codes//
.expbar {background:#000000; border:1px dotted #627EA0; width:50%; height: 11pt;margin-top:-10px;}
.expbar>div {background: #0F1125; border:none;}
.expbar>span {color:#ffffff; font-size:11pt;}
//pkmnpanel code//
.party > div > .action > .berrybuttons[data-up='sour'] > [data-berry='aspear'], .party > div > .action > .berrybuttons[data-up='spicy'] > [data-berry='cheri'], .party > div > .action > .berrybuttons[data-up='dry'] > [data-berry='chesto'], .party > div > .action > .berrybuttons[data-up='sweet'] > [data-berry='pecha'], .party > div > .action > .berrybuttons[data-up='bitter'] > [data-berry='rawst']
{
background: #8ccce9;
}
.party>div>.action>.berrybuttons[data-down='sour']>[data-berry='aspear'], .party>div>.action>.berrybuttons[data-down='spicy']>[data-berry='cheri'], .party>div>.action>.berrybuttons[data-down='dry']>[data-berry='chesto'], .party>div>.action>.berrybuttons[data-down='sweet']>[data-berry='pecha'], .party>div>.action>.berrybuttons[data-down='bitter']>[data-berry='rawst'] {
background: #0f1125;
}
.party>div>.action a[data-berry]:after
{
border: 1px dotted #696969;
}
.party > div
{
background: #000;
color: #8ccce9;
border: 1px dotted #696969;
box-shadow: none;
a:link, a:visited
{
color: #8ccce9;
}
}
.party > div > .pkmn:before
{
border: 1px solid #696969;
background-color: #000;
}
.party > div > .expbar {background:#000000; border:1px dotted #627EA0; height: 15pt;margin-top:5px;
>div {background: #0F1125; border:none;}
.expbar>span {color:#ffffff; font-size:11pt;}
}
div.tooltip_content
{
background: #000;
color: #8ccce9;
border: 1px dotted #696969;
}
.bbcode_tooltip
{
border-bottom: 1px dotted #696969;
}
"There's not a cup of tea big enough or a book long enough to suit me." - C.S. Lewis
| Avatar credits | ©
signature by emberlynn; official 1D fragrance commercial gifs
QUOTE originally posted by Emberlynn
Currently trying to edit some Pokemon panel code to go with some of my freebie templates. But I'm having a heck of a time keeping my progress bar coding from further up in my coding from messing with the coding for the progress/exp bar on the Pokemon panel. Can anyone give me a hand? This is what my current style code for those two parts looks like for the template itself.
code
//normal progress bar codes//
.expbar {background:#000000; border:1px dotted #627EA0; width:50%; height: 11pt;margin-top:-10px;}
.expbar>div {background: #0F1125; border:none;}
.expbar>span {color:#ffffff; font-size:11pt;}
//pkmnpanel code//
.party > div > .action > .berrybuttons[data-up='sour'] > [data-berry='aspear'], .party > div > .action > .berrybuttons[data-up='spicy'] > [data-berry='cheri'], .party > div > .action > .berrybuttons[data-up='dry'] > [data-berry='chesto'], .party > div > .action > .berrybuttons[data-up='sweet'] > [data-berry='pecha'], .party > div > .action > .berrybuttons[data-up='bitter'] > [data-berry='rawst']
{
background: #8ccce9;
}
.party>div>.action>.berrybuttons[data-down='sour']>[data-berry='aspear'], .party>div>.action>.berrybuttons[data-down='spicy']>[data-berry='cheri'], .party>div>.action>.berrybuttons[data-down='dry']>[data-berry='chesto'], .party>div>.action>.berrybuttons[data-down='sweet']>[data-berry='pecha'], .party>div>.action>.berrybuttons[data-down='bitter']>[data-berry='rawst'] {
background: #0f1125;
}
.party>div>.action a[data-berry]:after
{
border: 1px dotted #696969;
}
.party > div
{
background: #000;
color: #8ccce9;
border: 1px dotted #696969;
box-shadow: none;
a:link, a:visited
{
color: #8ccce9;
}
}
.party > div > .pkmn:before
{
border: 1px solid #696969;
background-color: #000;
}
.party > div > .expbar {background:#000000; border:1px dotted #627EA0; height: 15pt;margin-top:5px;
>div {background: #0F1125; border:none;}
.expbar>span {color:#ffffff; font-size:11pt;}
}
div.tooltip_content
{
background: #000;
color: #8ccce9;
border: 1px dotted #696969;
}
.bbcode_tooltip
{
border-bottom: 1px dotted #696969;
}
Example Code for extra clarification >:D
//general expbar//
.expbar {background:#000000; border:1px dotted #627EA0; width:50%; height: 11pt;margin-top:-10px;}
.expbar>div {background: #0F1125; border:none;}
.expbar>span {color:#ffffff; font-size:11pt;}
//panel//
.pkpanel {
//panel expbar//
.expbar {background:#000000; border:1px dotted #627EA0; width:50%; height: 11pt;margin-top:-10px;}
.expbar>div {background: #0F1125; border:none;}
.expbar>span {color:#ffffff; font-size:11pt;}
//actual panel code//
.party > div > .action > .berrybuttons[data-up='sour'] > [data-berry='aspear'], .party > div > .action > .berrybuttons[data-up='spicy'] > [data-berry='cheri'], .party > div > .action > .berrybuttons[data-up='dry'] > [data-berry='chesto'], .party > div > .action > .berrybuttons[data-up='sweet'] > [data-berry='pecha'], .party > div > .action > .berrybuttons[data-up='bitter'] > [data-berry='rawst']
{
background: #8ccce9;
}
.party>div>.action>.berrybuttons[data-down='sour']>[data-berry='aspear'], .party>div>.action>.berrybuttons[data-down='spicy']>[data-berry='cheri'], .party>div>.action>.berrybuttons[data-down='dry']>[data-berry='chesto'], .party>div>.action>.berrybuttons[data-down='sweet']>[data-berry='pecha'], .party>div>.action>.berrybuttons[data-down='bitter']>[data-berry='rawst'] {
background: #0f1125;
}
.party>div>.action a[data-berry]:after
{
border: 1px dotted #696969;
}
.party > div
{
background: #000;
color: #8ccce9;
border: 1px dotted #696969;
box-shadow: none;
a:link, a:visited
{
color: #8ccce9;
}
}
.party > div > .pkmn:before
{
border: 1px solid #696969;
background-color: #000;
}
.party > div > .expbar {background:#000000; border:1px dotted #627EA0; height: 15pt;margin-top:5px;
>div {background: #0F1125; border:none;}
.expbar>span {color:#ffffff; font-size:11pt;}
}
div.tooltip_content
{
background: #000;
color: #8ccce9;
border: 1px dotted #696969;
}
.bbcode_tooltip
{
border-bottom: 1px dotted #696969;
}
}
Ah that's what I was afraid of, doesn't make it super user friendly if I have to do it that way for my freebies. Guess I'll just have to stick with my hodge-podge code that kinda works.
Thank you though Patch, much appreciated even it isn't something I'm able to use.
@Emberlynn:
I think you had some errors in your code that may have been affecting this? Specifically, in your party expbar section, you had .expbar>span *inside* your .expbar block, so it wouldn't have worked right. Other than that I think you have the right idea - the more specific code (the expbar inside the .panel) will override the less specific code (general expbars)
I ran your code through a formatter so I could read it more easily, and changed the colors to make the differences more obvious. Is this kind of what you were going for?
Edit: A code diff of what I changed, if that helps:
Uhhh, also, idk if those are your final color choices, but on my mediocre monitor with my night time color shift on, I really can't tell the difference in the progress bar colors at all without squinting... might want to add more contrast for readability? (just checked and it's even worse on my phone, even with daytime colors and brightness)
ive been trying my absolute best to try and figure out a way to code a 2x3 grid made up of images but i cant figure it out. i also want the boxes of each part of the grid to be separated a little bit, like a 1 or 2px gap in between each. this is what i have so far. any help would be greatly appreciated, im really stuck here ^^; it's for an about code if that helps.
code
.pkmn {
display: inline-grid;
grid-template-columns: 63px 63px 63px;
grid-template-rows: 34px 34px;
border: 1px solid black;
grid-gap: 1px;
background-color: black;
}
.item {
background-color: white;
padding: 15px;
text-align: center;
}
what that makes
- 🪪
- 📋
- 🔗
sapphire/they/23
Tournament Token (Ruby)
Event Item
(: 0)
[LEGACY] A token earned from Weekly Tournaments Season 10 but it is too old to be valid.
Legacy items are old items that no longer serve a purpose and are only good for collecting.
Sells for 10,000
Likes:
Dry food
MAX
Quiet nature
495 eggs
Score: 0
credits
credits
- Code @Neonyan
- Pkmnpanel @Mirzam+modified by @Neonyan
- Background+Tab Icons @Pokemon
- Pagedoll @pkspsapphire
- TR code LycanKai+Hakano Riku
Cannot post: Please log in to post