|
| 1 | +:host { |
| 2 | + display: block; |
| 3 | + width: var(--hello-size, 8rem); |
| 4 | + height: var(--hello-size, 8rem); |
| 5 | + background-color: cyan; |
| 6 | + border-radius: 50%; |
| 7 | + margin: 0.25rem; |
| 8 | + box-sizing: border-box; |
| 9 | + transition-duration: 250ms; |
| 10 | + transition-timing-function: cubic-bezier(0.77, 0, 0.175, 1); |
| 11 | + transition-property: transform, border; |
| 12 | + will-change: transform; |
| 13 | + cursor: pointer; |
| 14 | +} |
| 15 | + |
| 16 | +#container { |
| 17 | + display: flex; |
| 18 | + align-items: center; |
| 19 | + justify-content: center; |
| 20 | + height: 100%; |
| 21 | + font-size: calc(var(--hello-size, 8rem) * calc(5/11)); |
| 22 | +} |
| 23 | + |
| 24 | +:host([rank="\2655"]) { |
| 25 | + border: 4px dotted hsl(120, 100%, 50%); |
| 26 | + background-color: yellow; |
| 27 | + transform: rotateX(15deg) rotateY(15deg); |
| 28 | +} |
| 29 | + |
| 30 | +:host([rank="\2654"]) { |
| 31 | + border: 3px solid hsl(270, 100%, 50%); |
| 32 | + background-color: magenta; |
| 33 | + color: blue; |
| 34 | + transform: rotateX(-10deg) rotateY(-15deg); |
| 35 | +} |
| 36 | + |
| 37 | +:host(:not([rank])), |
| 38 | +:host([rank=""]) { |
| 39 | + background-color: #ccc; |
| 40 | +} |
| 41 | + |
| 42 | +:host(:hover) { |
| 43 | + border: 3px solid hsl(180, 100%, 50%); |
| 44 | + transform: translateZ(-25px); |
| 45 | +} |
| 46 | + |
| 47 | +:host(:focus) { |
| 48 | + border: 12px solid hsl(90, 100%, 50%); |
| 49 | + outline: none; |
| 50 | +} |
| 51 | + |
| 52 | +#container:empty::before { |
| 53 | + content: '\265F'; |
| 54 | +} |
0 commit comments