border-right-style
Baseline
Widely available
This feature is well established and works across many devices and browser versions. Itâs been available across browsers since â¨2015å¹´7æâ©.
border-right-style æ¯ border ä¸çä¸ä¸ª CSS å屿§ï¼æè¿°çæ¯å³è¾¹æ¡çæ ·å¼ border.
å°è¯ä¸ä¸
border-right-style: none;
border-right-style: dotted;
border-right-style: dashed;
border-right-style: solid;
border-right-style: groove;
border-right-style: inset;
<section id="default-example">
<div class="transition-all" id="example-element">
This is a box with a border around it.
</div>
</section>
#example-element {
background-color: #eee;
color: #000;
border: 0.75em solid;
padding: 0.75em;
width: 80%;
height: 100px;
}
body {
background-color: #fff;
}
夿³¨ï¼è¿ä¸ª css 没æå®ä¹ä¸åæ ·å¼çè¾¹çä¹é´å¦ä½æ¼æ¥ã
Syntax
css
/* å¯ç¨çå¼ */
border-right-style: none;
border-right-style: hidden;
border-right-style: dotted;
border-right-style: dashed;
border-right-style: solid;
border-right-style: double;
border-right-style: groove;
border-right-style: ridge;
border-right-style: inset;
border-right-style: outset;
/* å
¨å±å¯ç¨çå¼ */
border-right-style: inherit;
border-right-style: initial;
border-right-style: unset;
The border-right-style property is specified as a single keyword chosen from those available for the border-style property.
è¯æ³æ ¼å¼
border-right-style =
<line-style>
<line-style> =
none |
hidden |
dotted |
dashed |
solid |
double |
groove |
ridge |
inset |
outset
示ä¾
HTML
html
<table>
<tr>
<td class="b1">none</td>
<td class="b2">hidden</td>
<td class="b3">dotted</td>
<td class="b4">dashed</td>
</tr>
<tr>
<td class="b5">solid</td>
<td class="b6">double</td>
<td class="b7">groove</td>
<td class="b8">ridge</td>
</tr>
<tr>
<td class="b9">inset</td>
<td class="b10">outset</td>
</tr>
</table>
CSS
css
/* Define look of the table */
table {
border-width: 2px;
background-color: #52e385;
}
tr,
td {
padding: 3px;
}
/* border-right-style example classes */
.b1 {
border-right-style: none;
}
.b2 {
border-right-style: hidden;
}
.b3 {
border-right-style: dotted;
}
.b4 {
border-right-style: dashed;
}
.b5 {
border-right-style: solid;
}
.b6 {
border-right-style: double;
}
.b7 {
border-right-style: groove;
}
.b8 {
border-right-style: ridge;
}
.b9 {
border-right-style: inset;
}
.b10 {
border-right-style: outset;
}
ç»æ
è§è
| Specification |
|---|
| CSS Backgrounds and Borders Module Level 3 > # border-style > |
| åå§å¼ | none |
|---|---|
| éç¨å ç´ | ææå
ç´ . It also applies to ::first-letter. |
| æ¯å¦æ¯ç»§æ¿å±æ§ | å¦ |
| 计ç®å¼ | as specified |
| å¨ç»ç±»å | 离æ£å¼ |
æµè§å¨å ¼å®¹æ§
åè
- å
¶ä»æ ·å¼ç¸å
³è¾¹æ¡å±æ§ï¼
border-bottom-style,border-left-style,border-top-style, andborder-style. - å
¶ä» bottom-border-related 屿§ï¼
border-right,border-right-color, andborder-right-width.