SlideShare a Scribd company logo
CSS Pseudo Elements.
A CSS Pseudo element is a keyword added to a selector that lets you style a specific part of
the selected elements.
For Example, it can be used to:
● Style the first letter, or line, of an element
● inserts content before, or after, the content of an element
Syntax
You can use only one pseudo-element in a selector. it must appear after the simple selectors
in the statement.
Instagram - @the_coding_
@happy_coding_life
: before - Creaters A pseudo-element that is the first child of the selected element. it is inline
by default.
: after - Creaters a pseudo-element that is the last child of the selected element. It is inline
by default.
:: first-letter - Applies styles to the first letter of the first line of a block-level element.
:: first-line - Applies styles to the first line of a block-level element.
:: placeholder - Represents the placeholder text in an <input> or <textarea> element.
:: file-selector-button - Represents the button of an <input> of type="file".
:: maker - Selects the marker box of a list item, which contains a bullet or number.
:: selection - Applies style to the part of a document that has been highlighted by the user (
such as clicking and dragging ).
:: cue - Matches WebVTT cues within a selected element. This can be used to style
captions and other cues. This can be used to style captions and other cues in media with
VTT tracks.
:: backdrop - Creators a backdrop that covers the entire viewport and is rendered
immediately below a <dialog> or ant element that enters fullscreen mode using the
full-screen API.
:: part() - Represents any element within a shadow tree that has a matching part attribute.
● Minimum CSS Every Developer Must Know
● Want to Improve Your Problem-solving
skills?
● 5 Automations For Developers Out There.
● Programming Skill Student Should Know
● How You center a Div
● 8 Great React Books For Beginners
● 7 APIs Frontend Developers Should Know
● Free IIIT Madras Free Courses With
Certificate With Also Free Goodies and
Prizes 2022
CSS Pseudo Elements.pdf

More Related Content

PPTX
Types of Selectors (HTML)
PDF
The power of CSS pseudo-elements
PPTX
Introduction to Html5, css, Javascript and Jquery
PDF
Learn css3
PDF
Web 2 | CSS - Cascading Style Sheets
PPTX
Web Dev Intro Crash Course
PDF
CSS3 and Selectors
ODP
CSS memo
Types of Selectors (HTML)
The power of CSS pseudo-elements
Introduction to Html5, css, Javascript and Jquery
Learn css3
Web 2 | CSS - Cascading Style Sheets
Web Dev Intro Crash Course
CSS3 and Selectors
CSS memo

Similar to CSS Pseudo Elements.pdf (20)

PPT
Css class-02
PPTX
JAVAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA
PPTX
HTML and CSS part 2
PDF
CSS Selectors
PDF
PPTX
PPTX
Css selectors
PPTX
Less css
PDF
Web Design & Development - Session 2
PPTX
Client Building Functional webapps.
PDF
Pseudo CSS Selectors
PDF
Modern Web UI - Web components
PDF
Cmsc 100 xhtml and css
PPTX
Lab#1 - Front End Development
PPTX
CSS Fundamentals: selectors and Properties
PPTX
PDF
Professional Css
PPTX
Introduction to HTML+CSS+Javascript.pptx
PPTX
Introduction to HTML+CSS+Javascript.pptx
PDF
BYOWHC823
Css class-02
JAVAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA
HTML and CSS part 2
CSS Selectors
Css selectors
Less css
Web Design & Development - Session 2
Client Building Functional webapps.
Pseudo CSS Selectors
Modern Web UI - Web components
Cmsc 100 xhtml and css
Lab#1 - Front End Development
CSS Fundamentals: selectors and Properties
Professional Css
Introduction to HTML+CSS+Javascript.pptx
Introduction to HTML+CSS+Javascript.pptx
BYOWHC823
Ad

Recently uploaded (20)

PDF
Abdominal Access Techniques with Prof. Dr. R K Mishra
PDF
O7-L3 Supply Chain Operations - ICLT Program
PDF
Classroom Observation Tools for Teachers
PDF
01-Introduction-to-Information-Management.pdf
PDF
Computing-Curriculum for Schools in Ghana
PDF
A systematic review of self-coping strategies used by university students to ...
PDF
Complications of Minimal Access Surgery at WLH
PDF
Module 4: Burden of Disease Tutorial Slides S2 2025
PDF
Chapter 2 Heredity, Prenatal Development, and Birth.pdf
PDF
Yogi Goddess Pres Conference Studio Updates
PDF
3rd Neelam Sanjeevareddy Memorial Lecture.pdf
PDF
The Lost Whites of Pakistan by Jahanzaib Mughal.pdf
PDF
GENETICS IN BIOLOGY IN SECONDARY LEVEL FORM 3
PPTX
school management -TNTEU- B.Ed., Semester II Unit 1.pptx
PDF
A GUIDE TO GENETICS FOR UNDERGRADUATE MEDICAL STUDENTS
PPTX
Lesson notes of climatology university.
PPTX
Tissue processing ( HISTOPATHOLOGICAL TECHNIQUE
PDF
Microbial disease of the cardiovascular and lymphatic systems
PPTX
202450812 BayCHI UCSC-SV 20250812 v17.pptx
PPTX
Pharma ospi slides which help in ospi learning
Abdominal Access Techniques with Prof. Dr. R K Mishra
O7-L3 Supply Chain Operations - ICLT Program
Classroom Observation Tools for Teachers
01-Introduction-to-Information-Management.pdf
Computing-Curriculum for Schools in Ghana
A systematic review of self-coping strategies used by university students to ...
Complications of Minimal Access Surgery at WLH
Module 4: Burden of Disease Tutorial Slides S2 2025
Chapter 2 Heredity, Prenatal Development, and Birth.pdf
Yogi Goddess Pres Conference Studio Updates
3rd Neelam Sanjeevareddy Memorial Lecture.pdf
The Lost Whites of Pakistan by Jahanzaib Mughal.pdf
GENETICS IN BIOLOGY IN SECONDARY LEVEL FORM 3
school management -TNTEU- B.Ed., Semester II Unit 1.pptx
A GUIDE TO GENETICS FOR UNDERGRADUATE MEDICAL STUDENTS
Lesson notes of climatology university.
Tissue processing ( HISTOPATHOLOGICAL TECHNIQUE
Microbial disease of the cardiovascular and lymphatic systems
202450812 BayCHI UCSC-SV 20250812 v17.pptx
Pharma ospi slides which help in ospi learning
Ad

CSS Pseudo Elements.pdf

  • 1. CSS Pseudo Elements. A CSS Pseudo element is a keyword added to a selector that lets you style a specific part of the selected elements. For Example, it can be used to: ● Style the first letter, or line, of an element ● inserts content before, or after, the content of an element Syntax You can use only one pseudo-element in a selector. it must appear after the simple selectors in the statement. Instagram - @the_coding_ @happy_coding_life
  • 2. : before - Creaters A pseudo-element that is the first child of the selected element. it is inline by default.
  • 3. : after - Creaters a pseudo-element that is the last child of the selected element. It is inline by default.
  • 4. :: first-letter - Applies styles to the first letter of the first line of a block-level element.
  • 5. :: first-line - Applies styles to the first line of a block-level element.
  • 6. :: placeholder - Represents the placeholder text in an <input> or <textarea> element.
  • 7. :: file-selector-button - Represents the button of an <input> of type="file".
  • 8. :: maker - Selects the marker box of a list item, which contains a bullet or number. :: selection - Applies style to the part of a document that has been highlighted by the user ( such as clicking and dragging ).
  • 9. :: cue - Matches WebVTT cues within a selected element. This can be used to style captions and other cues. This can be used to style captions and other cues in media with VTT tracks. :: backdrop - Creators a backdrop that covers the entire viewport and is rendered immediately below a <dialog> or ant element that enters fullscreen mode using the full-screen API. :: part() - Represents any element within a shadow tree that has a matching part attribute. ● Minimum CSS Every Developer Must Know ● Want to Improve Your Problem-solving skills? ● 5 Automations For Developers Out There. ● Programming Skill Student Should Know ● How You center a Div ● 8 Great React Books For Beginners ● 7 APIs Frontend Developers Should Know ● Free IIIT Madras Free Courses With Certificate With Also Free Goodies and Prizes 2022