- Services
- Case Studies
- Technologies
- NextJs development
- Flutter development
- NodeJs development
- ReactJs development
- About
- Contact
- Tools
- Blogs
- FAQ
Mastering CSS border-inline-end for Web Design
Enhance your web designs with flexible and responsive borders.
Values
The border-inline-end CSS property allows you to define border width, style, and color in one declaration. Here are the values you can use:
<'border-width'>: Sets the border width. Use keywords likethin,medium, orthick, or specify a length value like1pxor2em.<'border-style'>: Sets the border style. Options includenone,hidden,dotted,dashed,solid,double,groove,ridge,inset, andoutset.<color>: Sets the border color. Use any valid CSS color value, like named colors, hex values, RGB, RGBA, HSL, or HSLA.
Examples:
border-inline-end: 1px;border-inline-end: 2px dashed;border-inline-end: medium dashed blue;Global Values
inherit: Inherits the value from the parent element.initial: Sets the border to its initial value (medium none currentColor).revert: Reverts to the value defined by the user-agent stylesheet.revert-layer: Reverts to the value defined by the next outer CSS layer.unset: Resets to the inherited value if it inherits, or to its initial value if it does not.
Examples
Let’s see how to use border-inline-end in practice.
Basic Usage
HTML:
<div> <p class="exampleText">Example text</p></div>CSS:
.exampleText { border-inline-end: 2px solid red;}In this example, the inline-end border of the paragraph is set to a 2px solid red line.
Different Border Styles
HTML:
<div> <p class="exampleText">Example text</p></div>CSS:
.exampleText { border-inline-end: 2px dashed red;}In this example, the inline-end border of the paragraph is set to a 2px dashed red line.
Combining Multiple Properties
HTML:
<div> <p class="exampleText">Example text</p></div>CSS:
.exampleText { border-inline-end: medium dashed blue;}In this example, the inline-end border of the paragraph is set to a medium-width dashed blue line.
Using Global Values
HTML:
<div class="parent"> <p class="child">Example text with inherited border</p></div>CSS:
.parent { border-inline-end: 3px dashed blue;}
.child { border-inline-end: inherit;}In this example, the child paragraph inherits the border from the parent div.
Formal Syntax
The formal syntax for border-inline-end is:
border-inline-end = <line-width> [||] <line-style> [||] <color>
<line-width> = [<length [0,∞]>] | thin | medium | thick
<line-style> = none | hidden | dotted | dashed | solid | double | groove | ridge | inset | outset<line-width>: Specifies the border width.<line-style>: Defines the border style.<color>: Sets the border color.
Related Properties
border-block-start: Defines the border at the start of the block direction.border-block-end: Defines the border at the end of the block direction.border-inline-start: Defines the border at the start of the inline direction.
These properties help create responsive designs that adapt to different writing modes and text orientations.
Specifications
The border-inline-end property is defined in the CSS Logical Properties and Values Level 1 specification. This specification aims to make styling more intuitive and flexible by using logical properties instead of physical ones, ensuring consistent styles across different languages and writing systems.
CSS Logical Properties and Values Level 1
- Specification Link: CSS Logical Properties and Values Level 1 # border-shorthands
Browser Compatibility
The border-inline-end property is widely supported across major browsers since September 2021. It works seamlessly across many devices and browser versions, making it a reliable choice for web development.
For detailed compatibility information, refer to:
See Also
For further reading and related resources, explore the following topics:
- CSS Logical Properties and Values: Learn more about logical properties and values in CSS.
- Related Properties:
border-top: Defines the top border of an element.border-right: Defines the right border of an element.border-bottom: Defines the bottom border of an element.border-left: Defines the left border of an element.
- Related Logical Properties:
border-block-start: Defines the border at the start of the block direction.border-block-end: Defines the border at the end of the block direction.border-inline-start: Defines the border at the start of the inline direction.
These related properties work together with border-inline-end to provide a complete set of logical borders for elements. By using these properties, you can create designs that are adaptable and responsive to different writing systems and text orientations.
สร้างเว็บไซต์ 1 เว็บ ต้องใช้งบเท่าไหร่? เจาะลึกทุกองค์ประกอบ website development cost อยากสร้างเว็บไซต์แต่ไม่มั่นใจในเรื่องของงบประมาณ อ่านสรุปเจาะลึกตั้งแต่ดีไซน์, ฟังก์ชัน และการดูแล พร้อมตัวอย่างงบจริงจาก Till it’s done ที่แผนชัด งบไม่บานปลายแน่นอน
Next.js สอน 14 ขั้นตอนเบื้องต้น: สร้างโปรเจกต์แรกใน 30 นาที เริ่มต้นกับ Next.js ใน 14 ขั้นตอนเพียงแค่ 30 นาที พร้อม SSR/SSG และ API Routes ด้วยตัวอย่างโค้ดง่าย ๆ อ่านต่อเพื่อสร้างโปรเจ็กต์แรกได้ทันทีที่นี่
วิธีสมัคร Apple Developer Account เพื่อนำแอปขึ้น App Store ทีละขั้นตอน อยากปล่อยแอปบน App Store ระดับโลก มาอ่านคู่มือสมัคร Apple Developer Account พร้อมเคล็ดลับ TestFlight และวิธีอัปโหลดที่ง่ายในบทความเดียวนี้ได้เลย
TypeScript Interface คืออะไร? อธิบายพร้อมวิธีใช้และข้อแตกต่างจาก Type เรียนรู้วิธีใช้ TypeScript Interface เพื่อสร้างโครงสร้างข้อมูลที่ปลอดภัยและเข้าใจง่าย พร้อมเปรียบเทียบข้อดีข้อแตกต่างกับ Type ที่คุณต้องรู้ ถูกรวมเอาไว้ในบทความนี้แล้ว
Material-UI (MUI) คืออะไร อยากสร้าง UI สวยงามและเป็นมืออาชีพในเวลาอันรวดเร็วใช่ไหม มาทำความรู้จักกับ Material-UI (MUI) ที่ช่วยให้คุณพัฒนาแอปพลิเคชันบน React ได้ง่ายและดูดีในทุกอุปกรณ์
เปรียบเทียบ 3 วิธีติดตั้ง install node js บน Ubuntu: NVM vs NodeSource vs Official Repo แบบไหนดีที่สุด? เรียนรู้วิธีติดตั้ง Node.js บน Ubuntu ด้วย NVM, NodeSource หรือ Official Repo เลือกวิธีที่เหมาะกับความต้องการของคุณ พร้อมเปรียบเทียบ เพื่อการพัฒนาที่มีประสิทธิภาพ! พูดคุยกับซีอีโอ
We'll be right here with you every step of the way.
We'll be here, prepared to commence this promising collaboration.
Whether you're curious about features, warranties, or shopping policies, we provide comprehensive answers to assist you.