@@ -75,14 +75,14 @@ const positionStyles = (position: ArrowPosition, size: string, inset: string) =>
7575 }
7676
7777 /**
78- * 1. Arrow positioning on the base element .
79- * 2. Rotate the clipping mask depending on arrow position .
78+ * 1. Rotate the clipping mask depending on arrow position .
79+ * 2. Arrow positioning on the base element .
8080 */
8181 return css `
8282 & ::before ,
8383 & ::after {
84- transform: ${ transform } ; /* [2 ] */
85- ${ positionCss } ; /* [1 ] */
84+ transform: ${ transform } ; /* [1 ] */
85+ ${ positionCss } ; /* [2 ] */
8686 }
8787 ` ;
8888} ;
@@ -130,10 +130,10 @@ export default function arrowStyles(position: ArrowPosition, options: ArrowOptio
130130 * 1. Set base positioning for an element with an arrow.
131131 * 2. Apply shared properties to ::before and ::after.
132132 * 3. Display border with inherited border-color
133- * 4. Clip the inner square forming the arrow body into a triangle so that it
134- * doesn't interfere with container content.
135- * 5. Clip the outer square forming the arrow border into a triangle so that the
133+ * 4. Clip the outer square forming the arrow border into a triangle so that the
136134 * border merge with the container's.
135+ * 5. Clip the inner square forming the arrow body into a triangle so that it
136+ * doesn't interfere with container content.
137137 */
138138 return css `
139139 position : relative; /* [1] */
@@ -153,14 +153,14 @@ export default function arrowStyles(position: ArrowPosition, options: ArrowOptio
153153 & ::before {
154154 border-color : inherit; /* [3] */
155155 background-color : transparent;
156- clip-path : polygon (100% ${ beforeOffset } px, ${ beforeOffset } px 100% , 100% 100% ); /* [5 ] */
156+ clip-path : polygon (100% ${ beforeOffset } px, ${ beforeOffset } px 100% , 100% 100% ); /* [4 ] */
157157 }
158158
159159 & ::after {
160160 border-color : transparent;
161161 background-clip : content-box;
162162 background-color : inherit;
163- clip-path : polygon (100% ${ afterOffset } px, ${ afterOffset } px 100% , 100% 100% ); /* [4 ] */
163+ clip-path : polygon (100% ${ afterOffset } px, ${ afterOffset } px 100% , 100% 100% ); /* [5 ] */
164164 }
165165
166166 ${ positionStyles ( position , squareSize , inset ) } ;
0 commit comments