質問編集履歴
2
確認した現象を追記
test
CHANGED
File without changes
|
test
CHANGED
@@ -613,3 +613,11 @@
|
|
613
613
|
アンカーリンクの飛び位置のみ要素の先頭に来ない状態です。
|
614
614
|
|
615
615
|
どう修正すればよいのか、どなたかお教えいただけると大変助かります。
|
616
|
+
|
617
|
+
|
618
|
+
|
619
|
+
<追記>
|
620
|
+
|
621
|
+
2番目以降のタブ内のアンカーリンク、同じものを複数回クリックすると
|
622
|
+
|
623
|
+
別箇所へスクロールする現象を確認しました。
|
1
CSS追記、HTML修正
test
CHANGED
File without changes
|
test
CHANGED
@@ -32,6 +32,22 @@
|
|
32
32
|
|
33
33
|
```html
|
34
34
|
|
35
|
+
<!DOCTYPE HTML>
|
36
|
+
|
37
|
+
<html>
|
38
|
+
|
39
|
+
<head>
|
40
|
+
|
41
|
+
<title>test</title>
|
42
|
+
|
43
|
+
<link rel="stylesheet" type="text/css" href="下記cssを参照">
|
44
|
+
|
45
|
+
</head>
|
46
|
+
|
47
|
+
<body>
|
48
|
+
|
49
|
+
|
50
|
+
|
35
51
|
<!--タブ全体-->
|
36
52
|
|
37
53
|
<div class="tabs">
|
@@ -62,13 +78,13 @@
|
|
62
78
|
|
63
79
|
<!--overflow:scroll内スムーズスクロールリンク-->
|
64
80
|
|
65
|
-
<a href="#ancher01">
|
81
|
+
<a href="#aancher01" data-box=".scroll">A1</a>
|
66
|
-
|
82
|
+
|
67
|
-
<a href="#ancher10">10</a>
|
83
|
+
<a href="#aancher10" data-box=".scroll">A10</a>
|
68
|
-
|
84
|
+
|
69
|
-
<a href="#ancher20">20</a>
|
85
|
+
<a href="#aancher20" data-box=".scroll">A20</a>
|
70
|
-
|
86
|
+
|
71
|
-
<a href="#ancher30">30</a>
|
87
|
+
<a href="#aancher30" data-box=".scroll">A30</a>
|
72
88
|
|
73
89
|
<!--overflow:scroll内スムーズスクロールリンク-->
|
74
90
|
|
@@ -78,83 +94,83 @@
|
|
78
94
|
|
79
95
|
<div class="scroll">
|
80
96
|
|
81
|
-
<p id="ancher01">
|
82
|
-
|
83
|
-
<p id="ancher02">
|
84
|
-
|
85
|
-
<p id="ancher03">
|
86
|
-
|
87
|
-
<p id="ancher04">
|
88
|
-
|
89
|
-
<p id="ancher05">
|
90
|
-
|
91
|
-
<p id="ancher06">
|
92
|
-
|
93
|
-
<p id="ancher07">
|
94
|
-
|
95
|
-
<p id="ancher08">
|
96
|
-
|
97
|
-
<p id="ancher09">
|
98
|
-
|
99
|
-
<p id="ancher10">10</p>
|
100
|
-
|
101
|
-
<p id="ancher11">11</p>
|
102
|
-
|
103
|
-
<p id="ancher12">12</p>
|
104
|
-
|
105
|
-
<p id="ancher13">13</p>
|
106
|
-
|
107
|
-
<p id="ancher14">14</p>
|
108
|
-
|
109
|
-
<p id="ancher15">15</p>
|
110
|
-
|
111
|
-
<p id="ancher16">16</p>
|
112
|
-
|
113
|
-
<p id="ancher17">17</p>
|
114
|
-
|
115
|
-
<p id="ancher18">18</p>
|
116
|
-
|
117
|
-
<p id="ancher19">19</p>
|
118
|
-
|
119
|
-
<p id="ancher20">20</p>
|
120
|
-
|
121
|
-
<p id="ancher21">21</p>
|
122
|
-
|
123
|
-
<p id="ancher22">22</p>
|
124
|
-
|
125
|
-
<p id="ancher23">23</p>
|
126
|
-
|
127
|
-
<p id="ancher24">24</p>
|
128
|
-
|
129
|
-
<p id="ancher25">25</p>
|
130
|
-
|
131
|
-
<p id="ancher26">26</p>
|
132
|
-
|
133
|
-
<p id="ancher27">27</p>
|
134
|
-
|
135
|
-
<p id="ancher28">28</p>
|
136
|
-
|
137
|
-
<p id="ancher29">29</p>
|
138
|
-
|
139
|
-
<p id="ancher30">30</p>
|
140
|
-
|
141
|
-
<p id="ancher31">31</p>
|
142
|
-
|
143
|
-
<p id="ancher32">32</p>
|
144
|
-
|
145
|
-
<p id="ancher33">33</p>
|
146
|
-
|
147
|
-
<p id="ancher34">34</p>
|
148
|
-
|
149
|
-
<p id="ancher35">35</p>
|
150
|
-
|
151
|
-
<p id="ancher36">36</p>
|
152
|
-
|
153
|
-
<p id="ancher37">37</p>
|
154
|
-
|
155
|
-
<p id="ancher38">38</p>
|
156
|
-
|
157
|
-
<p id="ancher39">39</p>
|
97
|
+
<p id="aancher01">A1</p>
|
98
|
+
|
99
|
+
<p id="aancher02">A2</p>
|
100
|
+
|
101
|
+
<p id="aancher03">A3</p>
|
102
|
+
|
103
|
+
<p id="aancher04">A4</p>
|
104
|
+
|
105
|
+
<p id="aancher05">A5</p>
|
106
|
+
|
107
|
+
<p id="aancher06">A6</p>
|
108
|
+
|
109
|
+
<p id="aancher07">A7</p>
|
110
|
+
|
111
|
+
<p id="aancher08">A8</p>
|
112
|
+
|
113
|
+
<p id="aancher09">A9</p>
|
114
|
+
|
115
|
+
<p id="aancher10">A10</p>
|
116
|
+
|
117
|
+
<p id="aancher11">A11</p>
|
118
|
+
|
119
|
+
<p id="aancher12">A12</p>
|
120
|
+
|
121
|
+
<p id="aancher13">A13</p>
|
122
|
+
|
123
|
+
<p id="aancher14">A14</p>
|
124
|
+
|
125
|
+
<p id="aancher15">A15</p>
|
126
|
+
|
127
|
+
<p id="aancher16">A16</p>
|
128
|
+
|
129
|
+
<p id="aancher17">A17</p>
|
130
|
+
|
131
|
+
<p id="aancher18">A18</p>
|
132
|
+
|
133
|
+
<p id="aancher19">A19</p>
|
134
|
+
|
135
|
+
<p id="aancher20">A20</p>
|
136
|
+
|
137
|
+
<p id="aancher21">A21</p>
|
138
|
+
|
139
|
+
<p id="aancher22">A22</p>
|
140
|
+
|
141
|
+
<p id="aancher23">A23</p>
|
142
|
+
|
143
|
+
<p id="aancher24">A24</p>
|
144
|
+
|
145
|
+
<p id="aancher25">A25</p>
|
146
|
+
|
147
|
+
<p id="aancher26">A26</p>
|
148
|
+
|
149
|
+
<p id="aancher27">A27</p>
|
150
|
+
|
151
|
+
<p id="aancher28">A28</p>
|
152
|
+
|
153
|
+
<p id="aancher29">A29</p>
|
154
|
+
|
155
|
+
<p id="aancher30">A30</p>
|
156
|
+
|
157
|
+
<p id="aancher31">A31</p>
|
158
|
+
|
159
|
+
<p id="aancher32">A32</p>
|
160
|
+
|
161
|
+
<p id="aancher33">A33</p>
|
162
|
+
|
163
|
+
<p id="aancher34">A34</p>
|
164
|
+
|
165
|
+
<p id="aancher35">A35</p>
|
166
|
+
|
167
|
+
<p id="aancher36">A36</p>
|
168
|
+
|
169
|
+
<p id="aancher37">A37</p>
|
170
|
+
|
171
|
+
<p id="aancher38">A38</p>
|
172
|
+
|
173
|
+
<p id="aancher39">A39</p>
|
158
174
|
|
159
175
|
</div>
|
160
176
|
|
@@ -170,7 +186,149 @@
|
|
170
186
|
|
171
187
|
<div class="tab_content" id="programming_content">
|
172
188
|
|
189
|
+
<!--overflow:scroll内スムーズスクロールリンク-->
|
190
|
+
|
191
|
+
<a href="#bancher01" data-box=".scroll">B1</a>
|
192
|
+
|
193
|
+
<a href="#bancher10" data-box=".scroll">B10</a>
|
194
|
+
|
195
|
+
<a href="#bancher20" data-box=".scroll">B20</a>
|
196
|
+
|
197
|
+
<a href="#bancher30" data-box=".scroll">B30</a>
|
198
|
+
|
199
|
+
<a href="#bancher40" data-box=".scroll">B40</a>
|
200
|
+
|
201
|
+
<a href="#bancher50" data-box=".scroll">B50</a>
|
202
|
+
|
203
|
+
<!--overflow:scroll内スムーズスクロールリンク-->
|
204
|
+
|
205
|
+
|
206
|
+
|
207
|
+
<!--overflow:scrollエリア-->
|
208
|
+
|
209
|
+
<div class="scroll">
|
210
|
+
|
211
|
+
<p id="bancher01">B1</p>
|
212
|
+
|
213
|
+
<p id="bancher02">B2</p>
|
214
|
+
|
215
|
+
<p id="bancher03">B3</p>
|
216
|
+
|
217
|
+
<p id="bancher04">B4</p>
|
218
|
+
|
219
|
+
<p id="bancher05">B5</p>
|
220
|
+
|
221
|
+
<p id="bancher06">B6</p>
|
222
|
+
|
223
|
+
<p id="bancher07">B7</p>
|
224
|
+
|
225
|
+
<p id="bancher08">B8</p>
|
226
|
+
|
227
|
+
<p id="bancher09">B9</p>
|
228
|
+
|
229
|
+
<p id="bancher10">B10</p>
|
230
|
+
|
231
|
+
<p id="bancher11">B11</p>
|
232
|
+
|
233
|
+
<p id="bancher12">B12</p>
|
234
|
+
|
235
|
+
<p id="bancher13">B13</p>
|
236
|
+
|
237
|
+
<p id="bancher14">B14</p>
|
238
|
+
|
239
|
+
<p id="bancher15">B15</p>
|
240
|
+
|
241
|
+
<p id="bancher16">B16</p>
|
242
|
+
|
243
|
+
<p id="bancher17">B17</p>
|
244
|
+
|
245
|
+
<p id="bancher18">B18</p>
|
246
|
+
|
247
|
+
<p id="bancher19">B19</p>
|
248
|
+
|
249
|
+
<p id="bancher20">B20</p>
|
250
|
+
|
251
|
+
<p id="bancher21">B21</p>
|
252
|
+
|
253
|
+
<p id="bancher22">B22</p>
|
254
|
+
|
255
|
+
<p id="bancher23">B23</p>
|
256
|
+
|
257
|
+
<p id="bancher24">B24</p>
|
258
|
+
|
259
|
+
<p id="bancher25">B25</p>
|
260
|
+
|
261
|
+
<p id="bancher26">B26</p>
|
262
|
+
|
263
|
+
<p id="bancher27">B27</p>
|
264
|
+
|
265
|
+
<p id="bancher28">B28</p>
|
266
|
+
|
267
|
+
<p id="bancher29">B29</p>
|
268
|
+
|
269
|
+
<p id="bancher30">B30</p>
|
270
|
+
|
271
|
+
<p id="bancher31">B31</p>
|
272
|
+
|
273
|
+
<p id="bancher32">B32</p>
|
274
|
+
|
275
|
+
<p id="bancher33">B33</p>
|
276
|
+
|
277
|
+
<p id="bancher34">B34</p>
|
278
|
+
|
279
|
+
<p id="bancher35">B35</p>
|
280
|
+
|
281
|
+
<p id="bancher36">B36</p>
|
282
|
+
|
283
|
+
<p id="bancher37">B37</p>
|
284
|
+
|
285
|
+
<p id="bancher38">B38</p>
|
286
|
+
|
287
|
+
<p id="bancher39">B39</p>
|
288
|
+
|
289
|
+
<p id="bancher40">B40</p>
|
290
|
+
|
291
|
+
<p id="bancher41">B41</p>
|
292
|
+
|
293
|
+
<p id="bancher42">B42</p>
|
294
|
+
|
295
|
+
<p id="bancher43">B43</p>
|
296
|
+
|
297
|
+
<p id="bancher44">B44</p>
|
298
|
+
|
299
|
+
<p id="bancher45">B45</p>
|
300
|
+
|
301
|
+
<p id="bancher46">B46</p>
|
302
|
+
|
303
|
+
<p id="bancher47">B47</p>
|
304
|
+
|
305
|
+
<p id="bancher48">B48</p>
|
306
|
+
|
307
|
+
<p id="bancher49">B49</p>
|
308
|
+
|
309
|
+
<p id="bancher50">B50</p>
|
310
|
+
|
311
|
+
<p id="bancher51">B51</p>
|
312
|
+
|
313
|
+
<p id="bancher52">B52</p>
|
314
|
+
|
315
|
+
<p id="bancher53">B53</p>
|
316
|
+
|
317
|
+
<p id="bancher54">B54</p>
|
318
|
+
|
319
|
+
<p id="bancher55">B55</p>
|
320
|
+
|
321
|
+
<p id="bancher56">B56</p>
|
322
|
+
|
323
|
+
<p id="bancher57">B57</p>
|
324
|
+
|
325
|
+
<p id="bancher58">B58</p>
|
326
|
+
|
327
|
+
<p id="bancher59">B59</p>
|
328
|
+
|
173
|
-
|
329
|
+
</div>
|
330
|
+
|
331
|
+
<!--overflow:scrollエリア-->
|
174
332
|
|
175
333
|
</div>
|
176
334
|
|
@@ -182,7 +340,83 @@
|
|
182
340
|
|
183
341
|
<div class="tab_content" id="design_content">
|
184
342
|
|
343
|
+
<!--overflow:scroll内スムーズスクロールリンク-->
|
344
|
+
|
345
|
+
<a href="#cancher01" data-box=".scroll">C1</a>
|
346
|
+
|
347
|
+
<a href="#cancher10" data-box=".scroll">C10</a>
|
348
|
+
|
349
|
+
<a href="#cancher20" data-box=".scroll">C20</a>
|
350
|
+
|
351
|
+
<!--overflow:scroll内スムーズスクロールリンク-->
|
352
|
+
|
353
|
+
|
354
|
+
|
355
|
+
<!--overflow:scrollエリア-->
|
356
|
+
|
357
|
+
<div class="scroll">
|
358
|
+
|
359
|
+
<p id="cancher01">C1</p>
|
360
|
+
|
361
|
+
<p id="cancher02">C2</p>
|
362
|
+
|
363
|
+
<p id="cancher03">C3</p>
|
364
|
+
|
365
|
+
<p id="cancher04">C4</p>
|
366
|
+
|
367
|
+
<p id="cancher05">C5</p>
|
368
|
+
|
369
|
+
<p id="cancher06">C6</p>
|
370
|
+
|
371
|
+
<p id="cancher07">C7</p>
|
372
|
+
|
373
|
+
<p id="cancher08">C8</p>
|
374
|
+
|
375
|
+
<p id="cancher09">C9</p>
|
376
|
+
|
377
|
+
<p id="cancher10">C10</p>
|
378
|
+
|
379
|
+
<p id="cancher11">C11</p>
|
380
|
+
|
381
|
+
<p id="cancher12">C12</p>
|
382
|
+
|
383
|
+
<p id="cancher13">C13</p>
|
384
|
+
|
385
|
+
<p id="cancher14">C14</p>
|
386
|
+
|
387
|
+
<p id="cancher15">C15</p>
|
388
|
+
|
389
|
+
<p id="cancher16">C16</p>
|
390
|
+
|
391
|
+
<p id="cancher17">C17</p>
|
392
|
+
|
393
|
+
<p id="cancher18">C18</p>
|
394
|
+
|
395
|
+
<p id="cancher19">C19</p>
|
396
|
+
|
397
|
+
<p id="cancher20">C20</p>
|
398
|
+
|
399
|
+
<p id="cancher21">C21</p>
|
400
|
+
|
401
|
+
<p id="cancher22">C22</p>
|
402
|
+
|
403
|
+
<p id="cancher23">C23</p>
|
404
|
+
|
405
|
+
<p id="cancher24">C24</p>
|
406
|
+
|
407
|
+
<p id="cancher25">C25</p>
|
408
|
+
|
409
|
+
<p id="cancher26">C26</p>
|
410
|
+
|
411
|
+
<p id="cancher27">C27</p>
|
412
|
+
|
413
|
+
<p id="cancher28">C28</p>
|
414
|
+
|
415
|
+
<p id="cancher29">C29</p>
|
416
|
+
|
185
|
-
|
417
|
+
</div>
|
418
|
+
|
419
|
+
<!--overflow:scrollエリア-->
|
186
420
|
|
187
421
|
</div>
|
188
422
|
|
@@ -194,10 +428,136 @@
|
|
194
428
|
|
195
429
|
<!--タブ全体-->
|
196
430
|
|
431
|
+
|
432
|
+
|
433
|
+
<script type="text/javascript" src="jqueryファイルと下記jsファイルを参照"></script>
|
434
|
+
|
435
|
+
|
436
|
+
|
437
|
+
</div>
|
438
|
+
|
439
|
+
</body>
|
440
|
+
|
441
|
+
</html>
|
442
|
+
|
197
443
|
```
|
198
444
|
|
199
445
|
|
200
446
|
|
447
|
+
```css
|
448
|
+
|
449
|
+
/*タブ切り替え*/
|
450
|
+
|
451
|
+
.tabs {
|
452
|
+
|
453
|
+
margin-top: 50px;
|
454
|
+
|
455
|
+
padding-bottom: 40px;
|
456
|
+
|
457
|
+
background-color: #fff;
|
458
|
+
|
459
|
+
box-shadow: 0 0 10px rgba(0, 0, 0, 0.2);
|
460
|
+
|
461
|
+
width: 700px;
|
462
|
+
|
463
|
+
margin: 0 auto;}
|
464
|
+
|
465
|
+
.tab_item {
|
466
|
+
|
467
|
+
width: calc(100%/3);
|
468
|
+
|
469
|
+
height: 50px;
|
470
|
+
|
471
|
+
border-bottom: 3px solid #5ab4bd;
|
472
|
+
|
473
|
+
background-color: #d9d9d9;
|
474
|
+
|
475
|
+
line-height: 50px;
|
476
|
+
|
477
|
+
font-size: 16px;
|
478
|
+
|
479
|
+
text-align: center;
|
480
|
+
|
481
|
+
color: #565656;
|
482
|
+
|
483
|
+
display: block;
|
484
|
+
|
485
|
+
float: left;
|
486
|
+
|
487
|
+
text-align: center;
|
488
|
+
|
489
|
+
font-weight: bold;
|
490
|
+
|
491
|
+
transition: all 0.2s ease;
|
492
|
+
|
493
|
+
}
|
494
|
+
|
495
|
+
.tab_item:hover {
|
496
|
+
|
497
|
+
opacity: 0.75;
|
498
|
+
|
499
|
+
}
|
500
|
+
|
501
|
+
input[name="tab_item"] {
|
502
|
+
|
503
|
+
display: none;
|
504
|
+
|
505
|
+
}
|
506
|
+
|
507
|
+
.tab_content {
|
508
|
+
|
509
|
+
display: none;
|
510
|
+
|
511
|
+
padding: 40px 40px 0;
|
512
|
+
|
513
|
+
clear: both;
|
514
|
+
|
515
|
+
overflow: hidden;
|
516
|
+
|
517
|
+
}
|
518
|
+
|
519
|
+
|
520
|
+
|
521
|
+
#all:checked ~ #all_content,
|
522
|
+
|
523
|
+
#programming:checked ~ #programming_content,
|
524
|
+
|
525
|
+
#design:checked ~ #design_content {
|
526
|
+
|
527
|
+
display: block;
|
528
|
+
|
529
|
+
}
|
530
|
+
|
531
|
+
.tabs input:checked + .tab_item {
|
532
|
+
|
533
|
+
background-color: #5ab4bd;
|
534
|
+
|
535
|
+
color: #fff;
|
536
|
+
|
537
|
+
}
|
538
|
+
|
539
|
+
|
540
|
+
|
541
|
+
|
542
|
+
|
543
|
+
/*スクロール*/
|
544
|
+
|
545
|
+
.scroll{
|
546
|
+
|
547
|
+
height:300px;
|
548
|
+
|
549
|
+
overflow:scroll;
|
550
|
+
|
551
|
+
border:1px solid black;
|
552
|
+
|
553
|
+
padding:10px;
|
554
|
+
|
555
|
+
}
|
556
|
+
|
557
|
+
```
|
558
|
+
|
559
|
+
|
560
|
+
|
201
561
|
```javascript
|
202
562
|
|
203
563
|
$(function(){
|
@@ -230,7 +590,9 @@
|
|
230
590
|
|
231
591
|
```
|
232
592
|
|
593
|
+
|
594
|
+
|
233
|
-
*
|
595
|
+
*上記3点で再現を確認しております。
|
234
596
|
|
235
597
|
*動的なサイトのため、個々の要素の高さを固定できません。
|
236
598
|
|