Normal paste CSS

I made this bundlrs to show everyone some basics on CSS for normal pastes!!! It's basically the same thing as its brother, /normalpaste on SNTRY but with a few tweaks to match the differences with bundlrs. Don’t try and use this to learn CSS, this is just for help with basic things specifically for styling your bundlrs page. If you really want to learn CSS I recommend W3schools or Mozilla.

some notes to remember:

Selectors

a selector is basically what you use to ‘select’ certain elements. One you might be familiar with is a, which you use to select all links. for example:

a {
  color: #ffffff;
}

but links arent the only thing you can customize!

Body selectors

body selects the part outside of the paste. basically the backdrop behind it, or technically the entire page. You can make it a custom color, image, gif, and whatnot.

main selects the entire paste, including buttons and all. NOT the same as body.

.tab-container selects just the main part of the paste. this is useful for applying a border, background, and such.

.editor-tab is exactly what it is in the name, it’s all the content of the page. this isnt that useful but you can use it to select only elements that are inside of the paste.

photo example:

outlined in red: body
outlined in orange: main
outlined in purple: .tab-container
outlined in green: .editor-tab

a photo depicting a basic normal paste, with several parts of it being outlined in different colors.

Text selectors

p selects all text in the paste.
a selects all links.
r selects anything that is aligned using arrows.
rf selects anything that is aligned using double headed arrows.
img selects all images.
strong selects all bold text.
em selects all italicized text.
h1, h2, h3, and so forth up to h6 select all different types of headers.
.highlight selects all highlighted text.
del selects all text with strikethrough.
code selects all single code blocks.
pre selects all fenced code blocks.
[role="animation"] selects all elements with animations.
[role="underline"] selects all underlined text.
.note-note, .note-info, .note-error, .note-warn select their corresponding admonitions. .mdnote selects all types of admonitions.

Pseudo classes and elements

if you want to get even more specific with what you select, you can use pseudo classes and pseudo elements. Pseudo classes allow you to select elements that are in a specific state, such as being hovered over. pseudo elements act as though you added a whole new element.

read more about pseudo-classes and pseudo-elements here (click me!)

Custom IDs and classes

Custom IDs and classes allow you to select objects by using a special ID/class that is applied to them. IDs should only be used for ONE element and one class can be applied to many elements. The names of IDs and classes can be whatever you want! You can set custom IDs and classes in normal pastes by doing the following:

for IDs


I have the ID ‘customid’ applied to me now!

HTML alternative:

I have the ID ‘customid’ applied to me now!!

you can replace div with any HTML tag you want to use

for classes


I have the class ‘customclass’ applied to me now!

HTML alternative:

I have the class ‘customclass’ applied to me now!

you can replace div with any HTML tag you want to use

How to use this

The way to declare something using CSS is like the following:

selector {
  property: value;
}

So, let’s say I want to make all my text with strikethrough blue.

del {
  color: blue;
}

To select IDs, you have to select it by putting a # and then the ID name.

#customid {
  color: #cfcfcf;
}

To select classes, you have to select it by putting a . and then the class name.

.customclass {
  color: #cfcfcf;
}

Some basic properties are color, which changes the color of text, border, which can be used to apply a border, margin, which is used to set margins, and many more. If you want to learn about more properties, I recommend you go through this (click me!)

Sometimes it might be necessary to put !important at the end of your value right before the semicolon. This overrides all other values of the same property that are applied to the selected object. To know when you need to use this, just check if your code works. If it doesn’t and you’re sure everything is correct, then try applying !important.

another important thing to learn about, combinator selectors (click me!)

Pub: 1707436166109 Edit: 1709496509225 Owner: ángel Views: 73