Skip to content

Commit 7d343af

Browse files
committed
fix: using css into example
1 parent 0c3a8b6 commit 7d343af

File tree

2 files changed

+229
-0
lines changed

2 files changed

+229
-0
lines changed

example/src/index.css

Lines changed: 228 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,228 @@
1+
html, body {
2+
margin: 0px;
3+
padding: 0px;
4+
min-width: 1024px;
5+
}
6+
.tooltip-example {
7+
background: #1182dd;
8+
height: 550px;
9+
position: relative;
10+
}
11+
.tooltip-example .title {
12+
color: #fff;
13+
padding-top: 50px;
14+
margin-top: 0px;
15+
font-size: 45px;
16+
text-align: center;
17+
margin-bottom: 20px;
18+
font-weight: 700;
19+
}
20+
.demonstration {
21+
width: 600px;
22+
height: 150px;
23+
margin: 10px auto;
24+
background: rgba(0, 0, 0, 0.1);
25+
border-radius: 5px;
26+
box-sizing: border-box;
27+
position: relative;
28+
}
29+
.demonstration a {
30+
display: block;
31+
width: 60px;
32+
height: 60px;
33+
line-height: 60px;
34+
border-radius: 60px;
35+
text-align: center;
36+
color: #222;
37+
background: rgba(255, 255, 255, 1);
38+
position: absolute;
39+
left: 50%;
40+
top: 50%;
41+
margin-left: - 30px;
42+
margin-top: - 15px;
43+
cursor: pointer;
44+
box-shadow: 3px 4px 3px rgba(0, 0, 0, 0.5);
45+
border: 1px solid #333;
46+
}
47+
.demonstration a:after {
48+
content: "hover on me";
49+
text-align: center;
50+
color: rgba(0, 0, 0, 0.25);
51+
position: absolute;
52+
width: 100px;
53+
top: 45px;
54+
left: -18px;
55+
}
56+
.control-panel {
57+
background: rgba(255, 255, 255, 0.4);
58+
border-top: 1px solid rgba(0, 0, 0, 0.2);
59+
position: absolute;
60+
bottom: 0px;
61+
left: 0px;
62+
right: 0px;
63+
width: 100%;
64+
height: 230px;
65+
overflow: auto;
66+
}
67+
.control-panel:after {
68+
content: '';
69+
height: 0px;
70+
display: block;
71+
clear: both;
72+
}
73+
.control-panel .button-group {
74+
box-sizing: border-box;
75+
width: 55%;
76+
float: left;
77+
padding-left: 10px;
78+
}
79+
.control-panel .button-group .item {
80+
padding: 3px 2px;
81+
clear: both;
82+
}
83+
.control-panel .button-group .item p {
84+
margin: 10px 0px 2px;
85+
font-size: 18px;
86+
color: #777;
87+
}
88+
.control-panel .button-group .item a {
89+
border-radius: 3px;
90+
text-align: center;
91+
cursor: pointer;
92+
transition: background 0.25s ease-out;
93+
background: #e8e8e8;
94+
float: left;
95+
margin-right: 8px;
96+
padding: 7px 10px;
97+
font-size: 14px;
98+
}
99+
.control-panel .button-group .item a .mark {
100+
color: #888;
101+
font-size: 13px;
102+
display: inline-block;
103+
padding-left: 3px;
104+
}
105+
.control-panel .button-group .item a.active, .control-panel .button-group .item a:hover {
106+
color: #fff;
107+
background: #1182dd;
108+
}
109+
.control-panel .button-group .item a.active .mark, .control-panel .button-group .item a:hover .mark {
110+
color: rgba(255, 255, 255, 0.6);
111+
}
112+
.control-panel pre {
113+
box-sizing: border-box;
114+
width: 45%;
115+
float: left;
116+
}
117+
.control-panel pre div {
118+
background: rgba(255, 255, 255, 0.8);
119+
margin: 0px 20px;
120+
padding: 8px 12px;
121+
}
122+
.control-panel pre .label {
123+
margin: 10px 0px 2px;
124+
font-size: 18px;
125+
color: #777;
126+
}
127+
.advance .title {
128+
color: #222;
129+
padding-top: 100px;
130+
margin-top: 0px;
131+
font-size: 30px;
132+
text-align: center;
133+
margin-bottom: 20px;
134+
font-weight: 700;
135+
}
136+
.advance .sub-title {
137+
border-bottom: 1px solid rgba(0, 0, 0, 0.4);
138+
color: #666;
139+
font-size: 20px;
140+
padding-bottom: 5px;
141+
}
142+
.advance .section {
143+
width: 800px;
144+
margin: 20px auto;
145+
}
146+
.example-jsx {
147+
padding: 10px 0px;
148+
height: 50px;
149+
}
150+
.example-jsx:after {
151+
content: '';
152+
clear: both;
153+
height: 0;
154+
visibility: hidden;
155+
}
156+
.example-jsx .block {
157+
float: left;
158+
}
159+
.example-jsx .block a {
160+
text-align: center;
161+
width: 55px;
162+
height: 55px;
163+
border: 1px solid #999;
164+
border-radius: 0px;
165+
}
166+
.example-jsx .side {
167+
width: 50%;
168+
float: left;
169+
box-sizing: border-box;
170+
}
171+
.example-jsx a {
172+
text-align: center;
173+
width: 55px;
174+
height: 55px;
175+
line-height: 55px;
176+
border-radius: 55px;
177+
display: block;
178+
margin: auto;
179+
cursor: pointer;
180+
color: #999;
181+
border: 1px solid #999;
182+
font-size: 13px;
183+
}
184+
.example-jsx a:hover {
185+
color: #222;
186+
border: 1px solid #222;
187+
}
188+
.example-jsx p {
189+
margin-bottom: 2px;
190+
padding: 0px;
191+
}
192+
.example-jsx ul {
193+
padding: 0px;
194+
list-style: none;
195+
}
196+
.example-jsx ul li {
197+
padding-left: 10px;
198+
margin: 0px;
199+
text-align: left;
200+
}
201+
.example-pre {
202+
border-radius: 2px;
203+
border: 1px solid rgba(0, 0, 0, 0.2);
204+
box-sizing: border-box;
205+
padding: 10px;
206+
margin-bottom: 60px;
207+
font-size: 14px;
208+
}
209+
.example-pre p {
210+
line-height: 30px;
211+
}
212+
.extraClass {
213+
font-size: 20px !important;
214+
pointer-events: auto !important;
215+
}
216+
.extraClass:hover {
217+
visibility: visible !important;
218+
opacity: 1 !important;
219+
}
220+
.customeTheme {
221+
color: #ff6e00 !important;
222+
background-color: orange !important;
223+
}
224+
.customeTheme.place-top:after {
225+
border-top-color: orange !important;
226+
border-top-style: solid !important;
227+
border-top-width: 6px !important;
228+
}

example/src/index.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
import "./index.css";
12
import React from 'react'
23
import ReactDOM from 'react-dom'
34
import ReactTooltip from 'react-tooltip'

0 commit comments

Comments
 (0)