Skip to content

Commit 92589bc

Browse files
committed
补充示例css
1 parent c6a7b0c commit 92589bc

File tree

1 file changed

+44
-0
lines changed

1 file changed

+44
-0
lines changed

README.md

Lines changed: 44 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -77,3 +77,47 @@ class InverseOfControl extends Component {
7777
export default InverseOfControl
7878

7979
```
80+
相应的样式为
81+
```css
82+
.ioc-box1 {
83+
width: 100px;
84+
height: 100px;
85+
background: #59c;
86+
}
87+
.ioc-box1.ioc-enter {
88+
opacity: 0;
89+
}
90+
.ioc-box1.ioc-enter-active {
91+
opacity: 1;
92+
transition: all 3s ease-in-out;
93+
}
94+
.ioc-box1.ioc-exit {
95+
opacity: 1;
96+
}
97+
.ioc-box1.ioc-exit-active {
98+
opacity: 0;
99+
transition: all 3s ease-in-out;
100+
}
101+
102+
.ioc-box2 {
103+
position: relative;
104+
width: 100px;
105+
height: 100px;
106+
background: #98c;
107+
}
108+
.ioc-box2.ioc-enter {
109+
left: 3000px;
110+
}
111+
.ioc-box2.ioc-enter-active {
112+
left: 0;
113+
transition: left 3s ease-in-out
114+
}
115+
.ioc-box2.ioc-exit {
116+
left: 0;
117+
}
118+
.ioc-box2.ioc-exit-active {
119+
left: 3000px;
120+
transition: left 3s ease-in-out;
121+
}
122+
123+
```

0 commit comments

Comments
 (0)