This repository has been archived by the owner on Aug 25, 2021. It is now read-only.
forked from ridjohansen/css_browser_selector
-
Notifications
You must be signed in to change notification settings - Fork 0
/
index_pt.html
587 lines (527 loc) · 20.2 KB
/
index_pt.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
<!DOCTYPE html>
<html lang="pt-br" class="no-js">
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
<title>CSS Browser Selector + | Um Auxiliador no Desenvovimento Responsivo Cross-Browser</title>
<meta name="description" content="CSS Browser Selector + é um javascript muito pequeno, que habilita seletores CSS. Um Auxiliador no Desenvolvimento Responsivo Cross-Browser">
<meta name="viewport"
content="initial-scale=1.0, width=device-width, height=device-height, minimum-scale=1.0, maximum-scale=1.0, user-scalable=no">
<!-- <link rel="stylesheet" href="css/bootstrap.min.css"> <!--(original)-->
<!-- Veja mais em: http://bootswatch.com/ -->
<!-- <link rel="stylesheet" href="http://bootswatch.com/amelia/bootstrap.min.css"> <!--(skin)-->
<!-- <link rel="stylesheet" href="http://bootswatch.com/cerulean/bootstrap.min.css"> <!--(skin)-->
<!-- -->
<link rel="stylesheet" href="http://bootswatch.com/cyborg/bootstrap.min.css">
<!--(skin)-->
<!-- <link rel="stylesheet" href="http://bootswatch.com/journal/bootstrap.min.css"> <!--(skin)-->
<!-- <link rel="stylesheet" href="http://bootswatch.com/readable/bootstrap.min.css"> <!--(skin)-->
<!-- <link rel="stylesheet" href="http://bootswatch.com/simplex/bootstrap.min.css"> <!--(skin)-->
<!-- <link rel="stylesheet" href="http://bootswatch.com/slate/bootstrap.min.css"> <!--(skin)-->
<!-- <link rel="stylesheet" href="http://bootswatch.com/spacelab/bootstrap.min.css"> <!--(skin)-->
<!-- <link rel="stylesheet" href="http://bootswatch.com/spruce/bootstrap.min.css"> <!--(skin)-->
<!-- <link rel="stylesheet" href="http://bootswatch.com/superhero/bootstrap.min.css"> <!--(skin)-->
<!-- <link rel="stylesheet" href="http://bootswatch.com/united/bootstrap.min.css"> <!--(skin)-->
<link rel="stylesheet" href="css/bootstrap-responsive.min.css">
<!--[if lt IE 9]>
<link rel="stylesheet" href="css/bootstrap-responsive_lt-ie9.css">
<![endif]-->
<link rel="stylesheet" href="css/style.css">
<script src="js/vendor/modernizr-2.6.1-respond-1.1.0.min.js"></script>
<script src="js/vendor/css_browser_selector.js"></script>
<!-- <script src="js/vendor/css_browser_selector.min.js"></script> -->
<script src="//ajax.googleapis.com/ajax/libs/jquery/1.8.1/jquery.min.js"></script>
<script>window.jQuery || document.write('<script src="js/vendor/jquery-1.8.1.min.js"><\/script>')</script>
<script src="js/vendor/bootstrap.min.js"></script>
<script src="js/plugins.js"></script>
<script src="js/main.js"></script>
</head>
<body data-spy="scroll" data-target=".navbar">
<!--[if lt IE 7]>
<div class="container">
<div class="hero-unit chromeframe">
<p>
Você está usando um navegador desatualizado!
</p>
<p>
<a href="http://browsehappy.com/">Atualize seu navegador hoje</a>
ou
<a href="http://www.google.com/chromeframe/?redirect=true">instalação do Google Chrome Frame</a>
para melhor experimentar este site.
</p>
</div>
</div>
<![endif]-->
<header class="navbar navbar-inverse navbar-fixed-top">
<div class="navbar-inner">
<div class="container">
<a class="btn btn-navbar" data-toggle="collapse" data-target=".nav-collapse">
<span class="icon-bar"></span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
</a>
<a class="brand" href="#">CSS Browser Selector +</a>
<nav class="nav-collapse collapse">
<ul class="nav">
<li><a href="#Home">Home</a></li>
<li><a href="#Identifies">Ele identifica</a></li>
<li><a href="#Recursos">Recursos</a></li>
<li><a href="#Exemplo">Exemplo</a></li>
<li><a href="#License">License</a></li>
<li><a href="#Contribuidores">Contribuidores</a></li>
</ul>
</nav>
<!--/.nav-collapse -->
</div>
</div>
</header>
<article class="container">
<!-- Main hero unit for a primary marketing message or call to action -->
<div class="hero-unit" id="Home">
<h1>CSS Browser Selector +</h1>
<style>
.test {
display: none;
}
.hidpi .ret { display: block!important; }
.retina_1x .ret_1x { display: block!important; }
.retina_2x .ret_2x { display: block!important; }
</style>
<p>
<span class="test ret">
Hi-dpi screen
</span>
<span class="test ret_1x">
Pixel-ratio > 1 and < 2
</span>
<span class="test ret_2x">
Pixel-ratio >= 2
</span>
</p>
<h2>Um Auxiliador no Desenvovimento Responsivo Cross-Browser</h2>
<p>
CSS Browser Selector + é um javascript muito pequeno, que habilita seletores CSS.
</p>
<h4>Veja o exemplo:</h4>
<pre>
<html lang="pt-br" class="webkit chrome chrome21 win win8 js orientation_landscape minw_980 maxw_1199">
</pre>
<div class="container-fluid">
<div class="row-fluid">
<div class="span12">
<p>
<a href="https://github.com/ridjohansen/css_browser_selector/zipball/master"
class="btn btn-block btn-large btn-success">
CSS Browser Selector Download
</a>
</p>
<p>
<a href="https://github.com/ridjohansen/css_browser_selector/"
class="btn btn-block btn-large btn-warning">
Github
</a>
</p>
</div>
</div>
<div class="row-fluid">
<ul class="unstyled">
<li class="span4">
<h3 class="btn btn-block btn-large btn-primary">Melhor parte</h3>
<ul>
<li>chega de sujeira (hacks)</li>
<li>todo o código compatível.</li>
</ul>
</li>
<li class="span4">
<h3 class="btn btn-block btn-large btn-primary">Auxiliador parecido com Media Queries (CSS3)</h3>
<p>Método alternativo de Media Queries para o desenvolvimento de projeto ágil para navegadores mais
antigos.</p>
</li>
<li class="span4">
<h3 class="btn btn-block btn-large btn-primary">Agora você pode escrever código para</h3>
<ul>
<li>navegador</li>
<li>versão do navegador</li>
<li>plataforma</li>
<li>versão de plataforma</li>
<li>dispositivos</li>
<li>versão do dispositivo</li>
<li>min-width e max-width</li>
<li>detecção de orientação da tela (paisagem ou retrato)</li>
</ul>
</li>
</ul>
</div>
</div>
<p>
<strong>Mais Informações:</strong>
<br/>(http://rafael.adm.br/css_browser_selector)
</p>
<p>
<strong>Versões Experimentais:</strong>
<br/>(http://github.com/ridjohansen/css_browser_selector/)
<br/>(http://github.com/verbatim/css_browser_selector/)
</p>
</div>
<!-- Example row of columns -->
<div class="row">
<div class="span12">
<h2 id="Identifies">Ele identifica</h2>
<ul>
<li>Navegadores: Firefox; IE; Opera; Safari; Chrome, Konqueror, Iron</li>
<li>Versões dos navegadores: (most importantly: ie6, ie7, ie8, ie9)</li>
<li>Motores de renderização: Webkit; Mozilla; Gecko</li>
<li>Sistemas Operacionais/Plataformas: Mac; Win: Win8, Win7, Vista, WinXP, Win2k, WinNT; FreeBSD; Linux/x11</li>
<li>Dispositivos: Ipod; Ipad; Iphone; WebTV; Blackberry; Android; J2me; RIM Playbook; mobile (generico)</li>
<li>Tecnologia habilitada: JS (usado em conjunto com <html class="no-js"> para ainda ter mais controle)</li>
<li>detecção de max-width e min-width (Método alternativo de Media Queries para o detecçãode largura)</li>
<li>detecção da orientação navegador (Método alternativo de Media Queries para a detecçãode da orientação)</li>
<li>Detecção de idioma</li>
</ul>
<h4>Contribuidores recentes to 0.5, 0.6, 0.6.2:</h4>
<ul>
<li>
<strong>melhorar e atualizar recursos para o desenvolvimento cross-browser</strong>
<br/>https://github.com/ridjohansen/css_browser_selector/
</li>
<li>
<strong>Detecção IE mais detalhada</strong>
<br/>https://github.com/kevingessner/css_browser_selector/
</li>
<li>
<strong>Detecção do Windows mais detalhada</strong>
<br/>https://github.com/saar/css_browser_selector
</li>
<li>
<strong>no-js para js:</strong>
<br/>http://paulirish.com/2009/avoiding-the-fouc-v3/
</li>
<li>
<strong>Detecção do Mac mais detalhada</strong>
<br/>https://github.com/haraldmartin/css_browser_selector
</li>
</ul>
<h4>Histórico de versões</h4>
<ul>
<li>
<strong>v0.6.2 2012-09-10</strong>
<br/>adicionar novos recursos para o desenvolvimento cross-browser
<br/>atualizar a largura dispositivos comuns (com base em Bootstrap Twitter)
<br/>melhorar continuamente avalia navegador max-width e min-width (auxiliar para mediaqueries-como tela aulas
de largura)
<br/>melhorar continuamente avalia orientação navegador (auxiliar para mediaqueries-como orientação classes)
</li>
<li>
<strong>v0.6.1 2012-03-14</strong>
<br/>iOS versão detecção
<br/>beta: detectar se está sendo executado em aplicativo para iPad.
<br/>(de: http://stackoverflow.com/questions/4460205/detect-ipad-iphone-webview-via-javascript)
</li>
<li>
<strong>v0.6.0 2012-01-24</strong>
<br/>apoio mais detalhada para o Opera, Chrome, Safari (e revisão no suporte ao Firefox)
<br/>versão para o Chrome, Blackberry, Android, Mac
<br/>detecção de dispositivos Android
<br/>alterado como 'mobile' é deterimed para ser adicionado à classe String
<br/>detecção de idioma
<br/>suporte ao RIM Playbook
<br/>avalia continuamente largura do navegador max (em caso de redimensionamento)
<br/>avalia continuamente orientação navegador (retrato ou paisagem)
</li>
<li>
<strong>v0.5.0 2011-08-24</strong>
<br/>qualquer versão do Firefox
<br/>mais versões do Windows (Win8 [provisória], Win2k Win7, Vista, XP,)
<br/>mais versões do IE em condições únicas
<br/>se "não-js" na aula de HTML: remove e substitui por "js" (<html class="no-js">)
</li>
</ul>
<h2 id="Recursos">Recursos</h2>
<ul>
<li>
<strong>navigator.userAgent strings:</strong>
<br/>http://en.wikipedia.org/wiki/User_agent
<br/>http://www.useragentstring.com/pages/useragentstring.php
<br/>http://www.user-agents.org
<br/>http://www.zytrax.com/tech/web/mobile_ids.html
</li>
<li>
<strong>história da userAgent string:</strong>
<br/>http://www.nczonline.net/blog/2010/01/12/history-of-the-user-agent-string/
</li>
<li>
<strong>lista de idiomas:</strong>
<br/>http://msdn.microsoft.com/en-us/library/ms533052%28v=vs.85%29.aspx
</li>
<li>
<strong>Lista dos windows nt</strong>
<br/>http://en.wikipedia.org/wiki/Windows_NT
</li>
<li>
<strong>interpretação do userAgent string do blackberry:</strong>
<br/>http://supportforums.blackberry.com/t5/Web-and-WebWorks-Development/How-to-detect-the-BlackBerry-Browser/ta-p/559862
</li>
<li>
<strong>compressão do javascript:</strong>
<br/>http://minifyjavascript.com
</li>
<li>
<strong>resoluções de tela</strong>
<br/>http://responsinator.com/
</li>
<li>
<strong>aspect ratio:</strong>
<br/>http://www.htmlgoodies.com/beyond/webmaster/toolbox/article.php/3889591/Detect-and-Set-the-iPhone--iPads-Viewport-Orientation-Using-JavaScript-CSS-and-Meta-Tags.htm
</li>
<li>
<strong>Detecção do iOS:</strong>
<br/>http://stackoverflow.com/questions/4460205/detect-ipad-iphone-webview-via-javascript
</li>
</ul>
<h4>Other Versions</h4>
<ul>
<li>
<strong>Ruby on Rails Plugin por Reid MacDonald</strong>
<br/>http://latimes.rubyforge.org/svn/plugins/css_browser_selector/
</li>
<li>
<strong>PHP CSS Browser Selector por Bastian Allgeier</strong>
<br/>http://bastian-allgeier.de/css_browser_selector/
<li>
<strong>Wordpress Plugin por Adrian hanft</strong>
<br/>http://wordpress.org/extend/plugins/browser-specific-css/
</li>
</ul>
<h2 id="Exemplo">Exemplo</h2>
<div class="container-fluid">
<div class="row-fluid">
<div class="span4">
<h3 class="btn btn-block btn-large btn-primary">Navegador, dispositivo, sistema operacional e detecção de
Javascript</h3>
<pre>
<style>
.ie .exemplo { background-color: yellow; }
.ie7 .exemplo { background-color: orange }
.gecko .exemplo { background-color: gray; }
.win.gecko .exemplo { background-color: red; }
.linux.gecko .exemplo { background-color: pink; }
.opera .exemplo { background-color: green; }
.konqueror .exemplo { background-color: blue; }
.webkit .exemplo { background-color: black; }
.chrome .exemplo { background-color: cyan; }
.exemplo { width: 100px; height: 100px; }
.no-js, .no_js, .nojs { display: block; }
.js { display: none; }
</style>
</pre>
</div>
<div class="span4">
<h3 class="btn btn-block btn-large btn-primary">dataURI Selector</h3>
<pre>
<style>
.datauri .example_bg {
background-image: url('data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQAQMAAAAlPW0iAAAABlBMVEUAAAD///+l2Z/dAAAAM0lEQVR4nGP4/5/h/1+G/58ZDrAz3D/McH8yw83NDDeNGe4Ug9C9zwz3gVLMDA/A6P9/AFGGFyjOXZtQAAAAAElFTkSuQmCC');
}
.no-datauri .example_bg {
background-image: url('bg_default.png');
}
.datauri .img_default, .no-datauri .img_uri {
display: none !important;
}
</style>
<div class="example_bg">
<img class="img_uri" src="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQAQMAAAAlPW0iAAAABlBMVEUAAAD///+l2Z/dAAAAM0lEQVR4nGP4/5/h/1+G/58ZDrAz3D/McH8yw83NDDeNGe4Ug9C9zwz3gVLMDA/A6P9/AFGGFyjOXZtQAAAAAElFTkSuQmCC" alt="with dataURI" />
<img class="img_default" src="img_default.png" alt="without dataURI" />
</div>
</pre>
</div>
<div class="span4">
<h3 class="btn btn-block btn-large btn-primary">Hi-dpi and Pixel-Ratio Selector</h3>
<pre>
<style>
.img_hidpi {
display: none;
}
.no-hidpi .example_bg {
background-image: url('bg_default.png');
}
.hidpi .img_default, .no-hidpi .img_hidpi {
display: none !important;
}
.retina_1x .example_bg {
background-image: url('bg_hidpi_1x.png');
}
.retina_2x .example_bg {
background-image: url('bg_hidpi_2x.png');
}
.retina_2x .img_default, .retina_2x .x1 {
display: none !important;
}
.retina_1x .img_default, .retina_1x .x2 {
display: none !important;
}
or /* http://bjango.com/articles/min-device-pixel-ratio/ */
@media
only screen and (min--moz-device-pixel-ratio: 1.5),
only screen and (-o-min-device-pixel-ratio: 3/2),
only screen and (-webkit-min-device-pixel-ratio: 1.5),
only screen and (min-device-pixel-ratio: 1.5) {
.example_bg {
background-image: url('bg_hidpi_1x.png');
}
.img_default, .x2 {
display: none;
}
}
@media
only screen and (-webkit-min-device-pixel-ratio: 2),
only screen and ( min--moz-device-pixel-ratio: 2),
only screen and ( -o-min-device-pixel-ratio: 2/1),
only screen and ( min-device-pixel-ratio: 2),
only screen and ( min-resolution: 192dpi),
only screen and ( min-resolution: 2dppx) {
.example_bg {
background-image: url('bg_hidpi_2x.png');
}
.img_default, .x1 {
display: none;
}
}
</style>
<div class="example_bg">
<img class="img_hidpi x2" src="img_hidpi_2x.png" alt="with pixel-ratio >= 2" />
<img class="img_hidpi x1" src="img_hidpi_1x.png" alt="with pixel-ratio > 1 and < 2" />
<img class="img_default" src="img_default.png" alt="with pixel-ratio 1 or default" />
</div>
</pre>
</div>
<div class="span4">
<h3 class="btn btn-block btn-large btn-primary">Media Queries (Largura da tela)</h3>
<pre>
<style>
@media (max-width: 767px) {
.exemplo {
border: 2px solid purple!important;
}
}
/* or */
.minw_0 .exemplo, .maxw_767 .exemplo {
border: 2px solid purple!important;
}
@media (min-width: 768px) and (max-width: 979px) {
.exemplo {
border: 2px solid green!important;
}
}
/* or */
.minw_768.maxw_979 .exemplo {
border: 2px solid green!important;
}
@media (min-width: 1200px) {
.exemplo {
border: 2px solid orange!important;
}
}
/* or */
.minw_1200 .exemplo {
border: 2px solid orange!important;
}
</style>
</pre>
</div>
<div class="span4">
<h3 class="btn btn-block btn-large btn-primary">Media Queries (Orientação)</h3>
<pre>
<style>
@media (orientation: landscape) {
.exemplo {
border: 2px solid red!important;
}
}
/* or */
.orientation_landscape .exemplo {
border: 2px solid red!important;
}
@media (orientation: portrait) {
.exemplo {
border: 2px solid blue!important;
}
}
/* or */
.orientation_portrait .exemplo {
border: 2px solid blue!important;
}
</style>
</pre>
</div>
</div>
</div>
<h2 id="License">Licença</h2>
<p>http://creativecommons.org/licenses/by/2.5/</p>
<h4>Autor original:</h4>
<p>
<strong>Rafael Lima:</strong>
http://rafael.adm.br
</p>
<h4>Com base na idéia do site 37signals</h4>
<p>http://37signals.com/svn/archives2/browser_selectors_in_css.php</p>
<h2 id="Contribuidores">Contribuidores</h2>
<ul>
<li>Richard Duchatsch Johansen @ridjohansen (http://github.com/ridjohansen)</li>
<li>Niyaz (http://github.com/niyazpk)</li>
<li>Marcio Trindade (http://github.com/marciotrindade)</li>
<li>rbottarelli (http://github.com/rbottarelli)</li>
<li>Bryan Chow (http://github.com/bryanchow)</li>
<li>Derek Lio (http://github.com/dereklio)</li>
<li>Paul Irish (http://github.com/paulirish)</li>
<li>Preston Badeer</li>
<li>Upekshapriya</li>
<li>André Lopes</li>
<li>Tazio Mirandola - copiaincolla pubblicità</li>
<li>Reid MacDonald (http://geminstallthat.wordpress.com)</li>
<li>Vinicius Braga (http://viniciusbraga.com)</li>
<li>Chris Preece (http://www.mmtdigital.co.uk)</li>
<li>Dominykas</li>
<li>M@ McCray</li>
<li>Daniel Westermann-Clark</li>
<li>Steve Clay (http://mrclay.org/)</li>
<li>Jeff Bellsey</li>
<li>Jean Pierre</li>
<li>Micah Snyder</li>
<li>Derek (http://amphibian.info)</li>
<li>Jesse Scott</li>
<li>Moises Kirsch (http://www.moiblog.com/)</li>
<li>Alex Wiltschko</li>
<li>Chris Warren and Tony Nelson (http://www.imagetrend.com)</li>
<li>glasser</li>
</ul>
</div>
</div>
</article>
<!-- /container -->
<hr class="container">
<footer class="container">
<p>
Richard Duchatsch Johansen (ridjohansen)
| <a href="http://twitter.com/ridjohansen">Twitter</a>
| <a href="http://facebook.com/ridjohansen">Facebook</a>
| <a href="http://linkedin.com/in/ridjohansen">LinkedIn</a>
| <a href="http://slideshare.net/ridjohansen">Slideshare</a>
| <a href="http://klout.com/ridjohansen">Klout</a>
</p>
</footer>
<script type="text/javascript">
var _gaq = _gaq || [];
_gaq.push(['_setAccount', 'UA-34735780-1']);
_gaq.push(['_trackPageview']);
(function () {
var ga = document.createElement('script');
ga.type = 'text/javascript';
ga.async = true;
ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js';
var s = document.getElementsByTagName('script')[0];
s.parentNode.insertBefore(ga, s);
})();
</script>
</body>
</html>