SlideShare una empresa de Scribd logo
1 de 54
Angels
  vs.
demons
Balancing

shiny

        and
        inclusive
Contact me!
           cmills@opera.com
            @chrisdavidmills
http://www.slideshare.net/chrisdavidmills
          http://dev.opera.com
 http://www.w3.org/community/webed/
What we’ll talk
         about
‣ Do you really need The Shiny™?
‣ Progressively enhance, don’t rely on it
‣ Built in alternatives, versus building your own
‣ ...use polyfills/shims
‣ Don’t screw over your users!
Calling all good web
       angels
‣ Accessibility
‣ Usability
‣ A whole web of devices to support
‣ Let’s be responsible!
Thou shalt make
content accessible
wherever possible
Generally this
        means text
‣ Or a text alternative
‣ Alt text or longdesc really isn’t that expensive
‣ Transcripts/text tracks?
<canvas>/WebGL
     are cool
‣ But don’t use them to build entire UIs!
‣ Use a base of HTML with enhancements on top
Optimize your
        content...
‣ As much as possible across different browsing
  contexts
‣ Responsive design rocks*
Responsive design
‣ The web is responsive by default
‣ So let’s try not to screw it up
‣ Media queries
‣ Responsive media
‣ Viewport
Thou shalt design
   defensively
Defensive design by
      default
‣ Is your content still readable without those
  shadows, or background gradients
‣ Provide background colours as fallbacks
‣ Test thoroughly on older browsers
‣ A lot of the blingy stuff gracefully degrades
Example: CSS
         animation
‣ If done properly, a lot of CSS animations and
  transitions can be used unobtrusively
‣ For example, by default the element is set to be
  in its usable state, but then the animation is
  applied over the top to bring the animation to that
  state
Example: Web fonts
‣ This is a perfect feature to use now!
‣ IE has supported EOT since IE4/5!
‣ You can use the bulletproof web font syntax - see
 fontsquirrel.com
HTML5 <video>
<video controls>
  <source src="video-file.mp4"
          type="video/mp4">
  <source src="video-file.webm"
          type="video/webm">
  <track src="en.vtt" kind="subtitles"
         srclang="en" label="English subtitles">
  <!-- Flash player often referenced in here: will
play the MP4 version of the video -->
</video>
Flash fallbacks
         viable
‣ Flash can just load the MP4 version of the video
‣ Also consider jPlayer, Sublime, etc.
‣ And http://mediaelementjs.com/
‣ mediaelements even fakes the entire media API
 in Flash/Silverlight
You can build in
       support
     for <track>
‣ Building in support when it doesn’t exist
‣ JSCaptions, Captionator, videosub, playr
Polyfills
Add in support
     where needed
‣ Using JavaScript
‣ Fake SVG in old IE versions using VML
‣ Fake box-shadow using IE filters (although they
 are evil — every time you use IE filters, god kills a
 kitten)
Adding HTML5
support to browsers
‣ Older browsers don’t support them!
‣ But you can style any unknown element, so just
  set all the “block level” elements to display as
  block, at the top of your CSS:
‣ article { display: block; }
Oh, but IE 6-8 need
 some more help
‣ They refuse to style unknown elements, unless
  you create instances of them in the DOM
‣ document.createElement('article');
CSS3 PIE for CSS
    bling support
‣ http://css3pie.com/
‣ Awesome little library
‣ Add support to IE6-8 for box-shadow, border-
 radius, gradients and transparent colours
‣ But not text-shadow, which is a little frustrating
CSS3-
    mediaqueries.js
‣ http://code.google.com/p/css3-mediaqueries-js/
‣ Add media queries support to IE
‣ A bit clunky, when you resize, but it works
Excanvas
‣ http://excanvas.sourceforge.net/
‣ Add <canvas> support to IE
Selectivizr
‣ http://selectivizr.com/
‣ Adds support for CSS3 selectors to IE6-8
Providing
 alternatives with
Modernizr/yepnope
Modernizr
‣ The mother of all feature detection libraries
‣ Available at modernizr.com
Modernizr CSS
        example
<html lang="en-US" class="no-js">
<head>
  ...
<script src="modernizr.js"></script>
  ...
</head>
Modernizr CSS
        example
<html class=" js flexbox canvas canvastext webgl no-
touch geolocation postmessage no-websqldatabase
indexeddb hashchange history draganddrop websockets
rgba hsla multiplebgs backgroundsize borderimage
borderradius boxshadow textshadow opacity
cssanimations csscolumns cssgradients no-
cssreflections csstransforms no-csstransforms3d
csstransitions fontface generatedcontent video audio
localstorage no-sessionstorage webworkers
applicationcache svg inlinesvg smil svgclippaths"
lang="en-US">
Modernizr CSS
        example
#wrapper:hover, #wrapper:focus {
  transform: rotateX(180deg);
}
Modernizr CSS
        example
.no-csstransforms3d #wrapper #front {
  transition: 0.8s all ease-in;
}

.no-csstransforms3d #wrapper:hover #front,
.no-csstransforms3d #wrapper:focus #front {
  transform: rotate(-30deg) translate(-50%,-100%);
}
Modernizr JS
         example
function rotateForm() {
  if(Modernizr.cssanimations &&
     Modernizr.csstransforms3d) {
    form.setAttribute("class","form-rotate");
  } else {
    back.style.zIndex = "5";
  };
};
YepNope
yepnope({
  test : Modernizr.geolocation,
  yep : 'normal.js',
  nope : ['polyfill.js', 'wrapper.js']
});
In general, this
          rocks
‣ Modernizr/yepnope can add a fair bit of weight to
  your page: 49KB for the full library
‣ But you can create a smaller custom version that
  just includes the tests you need
‣ There are some things that can’t be detected
Thou shalt stop
 lusting after a
  monoculture
Not on my watch!
‣ A monoculture would ruin the web
‣ Competition is vital for innovation
‣ Browser vendors control standards
‣ If we had a monoculture, a single company
  would control web standards
‣ Do we want one company to control the Web?
And we can make
   this stuff work
   cross browser
background:   -webkit-linear-gradient(#ff0000,#000000);
background:   -moz-linear-gradient(#ff0000,#000000);
background:   -ms-linear-gradient(#ff0000,#000000);
background:   -o-linear-gradient(#ff0000,#000000);
background:   linear-gradient(#ff0000, #000000);
Common sense
       prevails?
‣ If you are going to use prefixed features, use all
  the prefixes!
‣ Don’t use single vendor-only features
‣ If it’s only in one rendering engine, it means it’s
  not ready yet
Thou shalt not
browser sniff, lest
ye be struck down
UA string chaos!
‣ Mosaic: NCSA_Mosaic/2.0 (Windows 3.1)
‣ Netscape: Mozilla/1.0 (Win3.1)
‣ IE: Mozilla/1.22 (compatible; MSIE 2.0;
  Windows 95)
‣ Firefox: Mozilla/5.0 (Windows; U; Windows
  NT 5.0; en-US; rv:1.1) Gecko/20020826
‣ Konqueror: Mozilla/5.0 (compatible;
 Konqueror/3.2; FreeBSD) (KHTML, like
 Gecko)
‣ Opera: Mozilla/4.0 (compatible; MSIE
  6.0; Windows NT 5.1; en) Opera 9.51, or
  Mozilla/5.0 (Windows NT 6.0; U; en;
  rv:1.8.1) Gecko/20061208 Firefox/2.0.0
  Opera 9.51, or Opera/9.51 (Windows NT
  5.1; U; en)
‣ Safari: Mozilla/5.0 (Macintosh; U; PPC
  Mac OS X; de-de) AppleWebKit/85.7
  (KHTML, like Gecko) Safari/85.5
‣ Chrome: Mozilla/5.0 (Windows; U;
 Windows NT 5.1; en-US) AppleWebKit/
 525.13 (KHTML, like Gecko) Chrome/
 0.2.149.27 Safari/525.13
Thou shalt let user
agreements ruin your users’
       experience!
Use of any Web browsers (other than generally
available third-party browsers), engines,
software, spiders, robots, avatars, agents, tools
or other devices or mechanisms to navigate,
search or determine the NYSE Web-site is strictly
prohibited.
You agree you will not, and will not permit any
third party to obstruct, receive, modify or
otherwise interfere with the display or delivery of
advertisements on the NYSE Web-site.
You may print or download a single, unaltered,
permanent copy or one temporary copy in a
single computer’s memory of any Content for
your personal, non-commercial use only
You agree to review this Agreement each time
you access the NYSE Euronext Web-site so that
you are aware of any and all modifications made
to this Agreement since your last visit
NYSE Euronext prohibits ... unauthorized
hypertext links by others to the NYSE Euronext
Web-site. NYSE Euronext reserves the right to
disable any unauthorized links.
Compromise?
Angels versus demons: balancing shiny and inclusive

Más contenido relacionado

La actualidad más candente

How to Speed Up Your Joomla! Site
How to Speed Up Your Joomla! SiteHow to Speed Up Your Joomla! Site
How to Speed Up Your Joomla! Site
Daniel Kanchev
 

La actualidad más candente (20)

Real solutions, no tricks
Real solutions, no tricksReal solutions, no tricks
Real solutions, no tricks
 
Rapid WordPress theme development
Rapid WordPress theme developmentRapid WordPress theme development
Rapid WordPress theme development
 
Overboard.js - where are we going with with jsconfasia / devfestasia
Overboard.js - where are we going with with jsconfasia / devfestasiaOverboard.js - where are we going with with jsconfasia / devfestasia
Overboard.js - where are we going with with jsconfasia / devfestasia
 
WordCamp Birmingham 2015 - Theme building workshop
WordCamp Birmingham 2015 - Theme building workshopWordCamp Birmingham 2015 - Theme building workshop
WordCamp Birmingham 2015 - Theme building workshop
 
Hidden Secrets For A Hack-Proof Joomla! Site
Hidden Secrets For A Hack-Proof Joomla! SiteHidden Secrets For A Hack-Proof Joomla! Site
Hidden Secrets For A Hack-Proof Joomla! Site
 
Doing More with LESS for CSS
Doing More with LESS for CSSDoing More with LESS for CSS
Doing More with LESS for CSS
 
WordCamp Birmingham 2015 - Theme building tricks of the trade
WordCamp Birmingham 2015 - Theme building tricks of the tradeWordCamp Birmingham 2015 - Theme building tricks of the trade
WordCamp Birmingham 2015 - Theme building tricks of the trade
 
Firefox OS - HTML5 for a truly world-wide-web
Firefox OS - HTML5 for a truly world-wide-webFirefox OS - HTML5 for a truly world-wide-web
Firefox OS - HTML5 for a truly world-wide-web
 
Best Friend || Worst Enemy: WordPress Multisite
Best Friend || Worst Enemy: WordPress MultisiteBest Friend || Worst Enemy: WordPress Multisite
Best Friend || Worst Enemy: WordPress Multisite
 
WordCamp Bournemouth 2014 - Designing with data in WordPress
WordCamp Bournemouth 2014 - Designing with data in WordPressWordCamp Bournemouth 2014 - Designing with data in WordPress
WordCamp Bournemouth 2014 - Designing with data in WordPress
 
How to Speed Up Your Joomla! Site
How to Speed Up Your Joomla! SiteHow to Speed Up Your Joomla! Site
How to Speed Up Your Joomla! Site
 
Does This Theme Make My Website Look Fat? (Wordcamp SLC 2013)
Does This Theme Make My Website Look Fat? (Wordcamp SLC 2013)Does This Theme Make My Website Look Fat? (Wordcamp SLC 2013)
Does This Theme Make My Website Look Fat? (Wordcamp SLC 2013)
 
Herramientas de desarrollo e implementacion
Herramientas de desarrollo e implementacionHerramientas de desarrollo e implementacion
Herramientas de desarrollo e implementacion
 
WordCamp Sheffield 2014 Theme Workflow Presentation
WordCamp Sheffield 2014 Theme Workflow PresentationWordCamp Sheffield 2014 Theme Workflow Presentation
WordCamp Sheffield 2014 Theme Workflow Presentation
 
Scaling woo commerce-v2-pagely
Scaling woo commerce-v2-pagelyScaling woo commerce-v2-pagely
Scaling woo commerce-v2-pagely
 
Meet The Family
Meet The FamilyMeet The Family
Meet The Family
 
Webpack: What it is, What it does, Whether you need it
Webpack: What it is, What it does, Whether you need itWebpack: What it is, What it does, Whether you need it
Webpack: What it is, What it does, Whether you need it
 
The Realtime Web: Stateful and Programmable
The Realtime Web: Stateful and ProgrammableThe Realtime Web: Stateful and Programmable
The Realtime Web: Stateful and Programmable
 
wp-cli and plugin development with future and past compatibility (Word Camp P...
wp-cli and plugin development with future and past compatibility (Word Camp P...wp-cli and plugin development with future and past compatibility (Word Camp P...
wp-cli and plugin development with future and past compatibility (Word Camp P...
 
Webpack and Web Performance Optimization
Webpack and Web Performance OptimizationWebpack and Web Performance Optimization
Webpack and Web Performance Optimization
 

Destacado

Destacado (6)

The W3C and the web design ecosystem
The W3C and the web design ecosystemThe W3C and the web design ecosystem
The W3C and the web design ecosystem
 
Adapt and respond: keeping responsive into the future
Adapt and respond: keeping responsive into the futureAdapt and respond: keeping responsive into the future
Adapt and respond: keeping responsive into the future
 
Future layouts
Future layoutsFuture layouts
Future layouts
 
Accessibility doesn't exist
Accessibility doesn't existAccessibility doesn't exist
Accessibility doesn't exist
 
Adapt! Media queries and viewport
Adapt! Media queries and viewportAdapt! Media queries and viewport
Adapt! Media queries and viewport
 
Responsive web design standards?
Responsive web design standards?Responsive web design standards?
Responsive web design standards?
 

Similar a Angels versus demons: balancing shiny and inclusive

Building Responsive Websites and Apps with Drupal
Building Responsive Websites and Apps with DrupalBuilding Responsive Websites and Apps with Drupal
Building Responsive Websites and Apps with Drupal
Four Kitchens
 
Modern Browser Support
Modern Browser SupportModern Browser Support
Modern Browser Support
Mark Meeker
 
HTML5 and CSS3 Techniques You Can Use Today
HTML5 and CSS3 Techniques You Can Use TodayHTML5 and CSS3 Techniques You Can Use Today
HTML5 and CSS3 Techniques You Can Use Today
Todd Anglin
 
East of Toronto .NET Usergroup - Put the 5 in HTML
East of Toronto .NET Usergroup - Put the 5 in HTMLEast of Toronto .NET Usergroup - Put the 5 in HTML
East of Toronto .NET Usergroup - Put the 5 in HTML
Frédéric Harper
 
Maximiliano Firtman - Разработка приложений с помощью PhoneGap
Maximiliano Firtman - Разработка приложений с помощью PhoneGap Maximiliano Firtman - Разработка приложений с помощью PhoneGap
Maximiliano Firtman - Разработка приложений с помощью PhoneGap
.toster
 

Similar a Angels versus demons: balancing shiny and inclusive (20)

Echo HTML5
Echo HTML5Echo HTML5
Echo HTML5
 
Building Responsive Websites and Apps with Drupal
Building Responsive Websites and Apps with DrupalBuilding Responsive Websites and Apps with Drupal
Building Responsive Websites and Apps with Drupal
 
A Period of Transition
A Period of TransitionA Period of Transition
A Period of Transition
 
Modern Browser Support
Modern Browser SupportModern Browser Support
Modern Browser Support
 
(For non-developers) HTML5: A richer web for everyone
(For non-developers) HTML5: A richer web for everyone(For non-developers) HTML5: A richer web for everyone
(For non-developers) HTML5: A richer web for everyone
 
HTML5: A brave new world of markup
HTML5: A brave new world of markupHTML5: A brave new world of markup
HTML5: A brave new world of markup
 
Bruce Lawson Opera Indonesia
Bruce Lawson Opera IndonesiaBruce Lawson Opera Indonesia
Bruce Lawson Opera Indonesia
 
RWD
RWDRWD
RWD
 
Flourish2011
Flourish2011Flourish2011
Flourish2011
 
HTML5 and CSS3 Techniques You Can Use Today
HTML5 and CSS3 Techniques You Can Use TodayHTML5 and CSS3 Techniques You Can Use Today
HTML5 and CSS3 Techniques You Can Use Today
 
[In Control 2010] HTML5
[In Control 2010] HTML5[In Control 2010] HTML5
[In Control 2010] HTML5
 
More efficient, usable web
More efficient, usable webMore efficient, usable web
More efficient, usable web
 
The Rich Standard: Getting Familiar with HTML5
The Rich Standard: Getting Familiar with HTML5The Rich Standard: Getting Familiar with HTML5
The Rich Standard: Getting Familiar with HTML5
 
East of Toronto .NET Usergroup - Put the 5 in HTML
East of Toronto .NET Usergroup - Put the 5 in HTMLEast of Toronto .NET Usergroup - Put the 5 in HTML
East of Toronto .NET Usergroup - Put the 5 in HTML
 
Html 5 mobile - nitty gritty
Html 5 mobile - nitty grittyHtml 5 mobile - nitty gritty
Html 5 mobile - nitty gritty
 
The web standards gentleman: a matter of (evolving) standards)
The web standards gentleman: a matter of (evolving) standards)The web standards gentleman: a matter of (evolving) standards)
The web standards gentleman: a matter of (evolving) standards)
 
73 Less Fugly Epicenter
73 Less Fugly   Epicenter73 Less Fugly   Epicenter
73 Less Fugly Epicenter
 
From Hacker to Programmer (w/ Webpack, Babel and React)
From Hacker to Programmer (w/ Webpack, Babel and React)From Hacker to Programmer (w/ Webpack, Babel and React)
From Hacker to Programmer (w/ Webpack, Babel and React)
 
PhoneGap mobile development
PhoneGap mobile developmentPhoneGap mobile development
PhoneGap mobile development
 
Maximiliano Firtman - Разработка приложений с помощью PhoneGap
Maximiliano Firtman - Разработка приложений с помощью PhoneGap Maximiliano Firtman - Разработка приложений с помощью PhoneGap
Maximiliano Firtman - Разработка приложений с помощью PhoneGap
 

Más de Chris Mills

Empowering the "mobile web"
Empowering the "mobile web"Empowering the "mobile web"
Empowering the "mobile web"
Chris Mills
 
Documentation and publishing
Documentation and publishingDocumentation and publishing
Documentation and publishing
Chris Mills
 

Más de Chris Mills (19)

Feedback handling, community wrangling, panhandlin’
Feedback handling, community wrangling, panhandlin’Feedback handling, community wrangling, panhandlin’
Feedback handling, community wrangling, panhandlin’
 
APIs for modern web apps
APIs for modern web appsAPIs for modern web apps
APIs for modern web apps
 
APIs, now and in the future
APIs, now and in the futureAPIs, now and in the future
APIs, now and in the future
 
Guerrilla education
Guerrilla educationGuerrilla education
Guerrilla education
 
Web versus Native: round 1!
Web versus Native: round 1!Web versus Native: round 1!
Web versus Native: round 1!
 
BrazilJS MDN
BrazilJS MDNBrazilJS MDN
BrazilJS MDN
 
Empowering the "mobile web"
Empowering the "mobile web"Empowering the "mobile web"
Empowering the "mobile web"
 
Documentation and publishing
Documentation and publishingDocumentation and publishing
Documentation and publishing
 
MDN is easy!
MDN is easy!MDN is easy!
MDN is easy!
 
Getting rid of images with CSS
Getting rid of images with CSSGetting rid of images with CSS
Getting rid of images with CSS
 
Laying out the future
Laying out the futureLaying out the future
Laying out the future
 
HTML5 and CSS3: does now really mean now?
HTML5 and CSS3: does now really mean now?HTML5 and CSS3: does now really mean now?
HTML5 and CSS3: does now really mean now?
 
HTML5 Pearson preso
HTML5 Pearson presoHTML5 Pearson preso
HTML5 Pearson preso
 
Brave new world of HTML5
Brave new world of HTML5Brave new world of HTML5
Brave new world of HTML5
 
Inclusive design: real accessibility for everyone
Inclusive design: real accessibility for everyoneInclusive design: real accessibility for everyone
Inclusive design: real accessibility for everyone
 
Optimizing content for the "mobile web"
Optimizing content for the "mobile web"Optimizing content for the "mobile web"
Optimizing content for the "mobile web"
 
CSS3: stay tuned for style
CSS3: stay tuned for styleCSS3: stay tuned for style
CSS3: stay tuned for style
 
HTML5: what's new?
HTML5: what's new?HTML5: what's new?
HTML5: what's new?
 
CSS3: stay tuned for style
CSS3: stay tuned for styleCSS3: stay tuned for style
CSS3: stay tuned for style
 

Último

+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
?#DUbAI#??##{{(☎️+971_581248768%)**%*]'#abortion pills for sale in dubai@
 

Último (20)

Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
 
presentation ICT roal in 21st century education
presentation ICT roal in 21st century educationpresentation ICT roal in 21st century education
presentation ICT roal in 21st century education
 
2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...
 
Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...
 
[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf
 
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
 
AWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of TerraformAWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of Terraform
 
Advantages of Hiring UIUX Design Service Providers for Your Business
Advantages of Hiring UIUX Design Service Providers for Your BusinessAdvantages of Hiring UIUX Design Service Providers for Your Business
Advantages of Hiring UIUX Design Service Providers for Your Business
 
Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024
 
Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationScaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organization
 
Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected Worker
 
The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024
 
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data DiscoveryTrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
 
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
 
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
 
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot TakeoffStrategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
 
What Are The Drone Anti-jamming Systems Technology?
What Are The Drone Anti-jamming Systems Technology?What Are The Drone Anti-jamming Systems Technology?
What Are The Drone Anti-jamming Systems Technology?
 
Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdfUnderstanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
 
Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)
 

Angels versus demons: balancing shiny and inclusive

  • 2.
  • 3. Balancing shiny and inclusive
  • 4. Contact me! cmills@opera.com @chrisdavidmills http://www.slideshare.net/chrisdavidmills http://dev.opera.com http://www.w3.org/community/webed/
  • 5. What we’ll talk about ‣ Do you really need The Shiny™? ‣ Progressively enhance, don’t rely on it ‣ Built in alternatives, versus building your own ‣ ...use polyfills/shims ‣ Don’t screw over your users!
  • 6. Calling all good web angels ‣ Accessibility ‣ Usability ‣ A whole web of devices to support ‣ Let’s be responsible!
  • 7. Thou shalt make content accessible wherever possible
  • 8. Generally this means text ‣ Or a text alternative ‣ Alt text or longdesc really isn’t that expensive ‣ Transcripts/text tracks?
  • 9. <canvas>/WebGL are cool ‣ But don’t use them to build entire UIs! ‣ Use a base of HTML with enhancements on top
  • 10. Optimize your content... ‣ As much as possible across different browsing contexts ‣ Responsive design rocks*
  • 11. Responsive design ‣ The web is responsive by default ‣ So let’s try not to screw it up ‣ Media queries ‣ Responsive media ‣ Viewport
  • 12.
  • 13. Thou shalt design defensively
  • 14. Defensive design by default ‣ Is your content still readable without those shadows, or background gradients ‣ Provide background colours as fallbacks ‣ Test thoroughly on older browsers ‣ A lot of the blingy stuff gracefully degrades
  • 15. Example: CSS animation ‣ If done properly, a lot of CSS animations and transitions can be used unobtrusively ‣ For example, by default the element is set to be in its usable state, but then the animation is applied over the top to bring the animation to that state
  • 16. Example: Web fonts ‣ This is a perfect feature to use now! ‣ IE has supported EOT since IE4/5! ‣ You can use the bulletproof web font syntax - see fontsquirrel.com
  • 17. HTML5 <video> <video controls> <source src="video-file.mp4" type="video/mp4"> <source src="video-file.webm" type="video/webm"> <track src="en.vtt" kind="subtitles" srclang="en" label="English subtitles"> <!-- Flash player often referenced in here: will play the MP4 version of the video --> </video>
  • 18. Flash fallbacks viable ‣ Flash can just load the MP4 version of the video ‣ Also consider jPlayer, Sublime, etc. ‣ And http://mediaelementjs.com/ ‣ mediaelements even fakes the entire media API in Flash/Silverlight
  • 19. You can build in support for <track> ‣ Building in support when it doesn’t exist ‣ JSCaptions, Captionator, videosub, playr
  • 21. Add in support where needed ‣ Using JavaScript ‣ Fake SVG in old IE versions using VML ‣ Fake box-shadow using IE filters (although they are evil — every time you use IE filters, god kills a kitten)
  • 22. Adding HTML5 support to browsers ‣ Older browsers don’t support them! ‣ But you can style any unknown element, so just set all the “block level” elements to display as block, at the top of your CSS: ‣ article { display: block; }
  • 23. Oh, but IE 6-8 need some more help ‣ They refuse to style unknown elements, unless you create instances of them in the DOM ‣ document.createElement('article');
  • 24. CSS3 PIE for CSS bling support ‣ http://css3pie.com/ ‣ Awesome little library ‣ Add support to IE6-8 for box-shadow, border- radius, gradients and transparent colours ‣ But not text-shadow, which is a little frustrating
  • 25. CSS3- mediaqueries.js ‣ http://code.google.com/p/css3-mediaqueries-js/ ‣ Add media queries support to IE ‣ A bit clunky, when you resize, but it works
  • 27. Selectivizr ‣ http://selectivizr.com/ ‣ Adds support for CSS3 selectors to IE6-8
  • 29. Modernizr ‣ The mother of all feature detection libraries ‣ Available at modernizr.com
  • 30. Modernizr CSS example <html lang="en-US" class="no-js"> <head> ... <script src="modernizr.js"></script> ... </head>
  • 31. Modernizr CSS example <html class=" js flexbox canvas canvastext webgl no- touch geolocation postmessage no-websqldatabase indexeddb hashchange history draganddrop websockets rgba hsla multiplebgs backgroundsize borderimage borderradius boxshadow textshadow opacity cssanimations csscolumns cssgradients no- cssreflections csstransforms no-csstransforms3d csstransitions fontface generatedcontent video audio localstorage no-sessionstorage webworkers applicationcache svg inlinesvg smil svgclippaths" lang="en-US">
  • 32. Modernizr CSS example #wrapper:hover, #wrapper:focus { transform: rotateX(180deg); }
  • 33. Modernizr CSS example .no-csstransforms3d #wrapper #front { transition: 0.8s all ease-in; } .no-csstransforms3d #wrapper:hover #front, .no-csstransforms3d #wrapper:focus #front { transform: rotate(-30deg) translate(-50%,-100%); }
  • 34. Modernizr JS example function rotateForm() { if(Modernizr.cssanimations && Modernizr.csstransforms3d) { form.setAttribute("class","form-rotate"); } else { back.style.zIndex = "5"; }; };
  • 35. YepNope yepnope({ test : Modernizr.geolocation, yep : 'normal.js', nope : ['polyfill.js', 'wrapper.js'] });
  • 36. In general, this rocks ‣ Modernizr/yepnope can add a fair bit of weight to your page: 49KB for the full library ‣ But you can create a smaller custom version that just includes the tests you need ‣ There are some things that can’t be detected
  • 37. Thou shalt stop lusting after a monoculture
  • 38.
  • 39. Not on my watch! ‣ A monoculture would ruin the web ‣ Competition is vital for innovation ‣ Browser vendors control standards ‣ If we had a monoculture, a single company would control web standards ‣ Do we want one company to control the Web?
  • 40. And we can make this stuff work cross browser background: -webkit-linear-gradient(#ff0000,#000000); background: -moz-linear-gradient(#ff0000,#000000); background: -ms-linear-gradient(#ff0000,#000000); background: -o-linear-gradient(#ff0000,#000000); background: linear-gradient(#ff0000, #000000);
  • 41.
  • 42. Common sense prevails? ‣ If you are going to use prefixed features, use all the prefixes! ‣ Don’t use single vendor-only features ‣ If it’s only in one rendering engine, it means it’s not ready yet
  • 43. Thou shalt not browser sniff, lest ye be struck down
  • 44. UA string chaos! ‣ Mosaic: NCSA_Mosaic/2.0 (Windows 3.1) ‣ Netscape: Mozilla/1.0 (Win3.1) ‣ IE: Mozilla/1.22 (compatible; MSIE 2.0; Windows 95) ‣ Firefox: Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; rv:1.1) Gecko/20020826 ‣ Konqueror: Mozilla/5.0 (compatible; Konqueror/3.2; FreeBSD) (KHTML, like Gecko)
  • 45. ‣ Opera: Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; en) Opera 9.51, or Mozilla/5.0 (Windows NT 6.0; U; en; rv:1.8.1) Gecko/20061208 Firefox/2.0.0 Opera 9.51, or Opera/9.51 (Windows NT 5.1; U; en) ‣ Safari: Mozilla/5.0 (Macintosh; U; PPC Mac OS X; de-de) AppleWebKit/85.7 (KHTML, like Gecko) Safari/85.5 ‣ Chrome: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US) AppleWebKit/ 525.13 (KHTML, like Gecko) Chrome/ 0.2.149.27 Safari/525.13
  • 46.
  • 47. Thou shalt let user agreements ruin your users’ experience!
  • 48. Use of any Web browsers (other than generally available third-party browsers), engines, software, spiders, robots, avatars, agents, tools or other devices or mechanisms to navigate, search or determine the NYSE Web-site is strictly prohibited.
  • 49. You agree you will not, and will not permit any third party to obstruct, receive, modify or otherwise interfere with the display or delivery of advertisements on the NYSE Web-site.
  • 50. You may print or download a single, unaltered, permanent copy or one temporary copy in a single computer’s memory of any Content for your personal, non-commercial use only
  • 51. You agree to review this Agreement each time you access the NYSE Euronext Web-site so that you are aware of any and all modifications made to this Agreement since your last visit
  • 52. NYSE Euronext prohibits ... unauthorized hypertext links by others to the NYSE Euronext Web-site. NYSE Euronext reserves the right to disable any unauthorized links.

Notas del editor

  1. \n
  2. \n
  3. \n
  4. \n
  5. \n
  6. \n
  7. \n\n
  8. \n
  9. \n
  10. \n
  11. \n
  12. * I&amp;#x2019;m saying that in a very safe &amp;#x201C;government-approved rock &amp;#x2018;n roll&amp;#x201D; kind of way\n
  13. Show examples?\n\nAnd of course, this will generally work in older browsers like IE6-8\n\nmention Matt Wilcox responsive image solution\n
  14. \n
  15. Where none already exist\n\nprogressive enhancement/graceful degradation are cool again, especiallywith a wide range of mobile devices being used\n
  16. \n
  17. show simple animated menu example\n
  18. \n
  19. \n
  20. \n
  21. \n
  22. \n
  23. \n
  24. \n
  25. Look for Remy Sharp&amp;#x2019;s HTML5 shiv on Google code, which does this for you and more (Print protector too)\n
  26. again, show bling box, in IE if possible.\n
  27. respond.js is the new contender on the block.\n\n
  28. \n
  29. \n
  30. \n
  31. \n
  32. show CSS3 modernizr example in FF then Opera\n
  33. \n
  34. \n
  35. \n
  36. show modernizr JavaScript example in FF, then Opera\n
  37. show modernizr JavaScript example in FF, then Opera\n
  38. \n
  39. \n
  40. \n
  41. \n
  42. please support all the browsers you can!\n\nThe dogged refusal of many developers to support more than one or two browsers with prefixed properties has led other vendors to start looking at supporting other browser&amp;#x2019;s prefixes. \n\nBut let&amp;#x2019;s not discuss that mess in detail again. It was boring on twitter the first time around.\n\nAll I&amp;#x2019;ll say is, yes, it&amp;#x2019;s a pain in the ass, but suck it up. We&amp;#x2019;re not supposed to be using this stuff in production sites anyway\n\n\n
  43. Mention Prefixr (Jeffrey Way) and Prefixfree script (Lea) for CSS, and Modernizr.prefixed() method for JS\n\n
  44. \n
  45. \n
  46. \n
  47. \n
  48. \n
  49. \n
  50. \n
  51. \n
  52. \n
  53. \n
  54. \n
  55. \n
  56. \n