source: content/digarden/20220202144214-css.org@ 5a2b670

Last change on this file since 5a2b670 was 5a2b670, checked in by Mikhail Kirillov <w96k@…>, on Oct 6, 2022 at 12:37:40 PM

Add digital garden

  • Property mode set to 100644
File size: 673 bytes
Line 
1:PROPERTIES:
2:ID: 31e25f4a-008f-442d-9bb1-594d75303c84
3:END:
4#+title: CSS
5
6* Селектор html атрибута
7#+begin_src css
8 /* <a> elements with a title attribute */
9 a[title] {
10 color: purple;
11 }
12
13 /* <a> elements with an href matching "https://example.org" */
14 a[href="https://example.org"] {
15 color: green;
16 }
17
18 /* <a> elements with an href containing "example" */
19 a[href*="example"] {
20 font-size: 2em;
21 }
22
23 /* <a> elements with an href ending ".org" */
24 a[href$=".org"] {
25 font-style: italic;
26 }
27
28 /* <a> elements whose class attribute contains the word "logo" */
29 a[class~="logo"] {
30 padding: 2px;
31 }
32
33#+end_src
Note: See TracBrowser for help on using the repository browser.